General Motors and ride-hailing company Lyft are forming an unprecedented partnership that could help them beat their rivals to the self-driving future.

Lyft said Monday that GM invested $500 million in the company as part of a $1 billion round of fundraising.