The purchase of Lyft’s autonomous driving unit is meant to give the automaker new speed in the global software race.