Imagine that in the next few decades, vehicles will slowly evolve from machines that we are entirely in control of to ones that become artificially intelligent chauffeurs, tirelessly carting us around town day and night.

We're still years away from that reality, but automakers and technology companies are working to get there -- and the ones that make the biggest moves now will likely benefit the most from their innovations later.

To help investors find a few companies that have the most potential to gain from this market, we reached out to three Motley Fool contributors for their top driverless-car stock ideas. They came back with NVIDIA Corporation (NVDA -3.33%), Alphabet (GOOG 0.74%) (GOOGL 0.55%), and General Motors (GM -0.04%). Here's why.

Graphic of two cars with computer chips on them driving on the road.

Image source: Getty Images.

The future of auto parts is...in the tech industry?

Nicholas Rossolillo (NVIDIA): Business results say yes, but investors have kept saying no to NVIDIA stock over the last few months. Despite posting record revenues from all business segments so far in 2018 -- including the automotive segment -- and a 119% year-over-year increase in earnings per share, the stock is down nearly 20% from its high-water mark set in late summer.

Much of that is likely due to investors taking a breather; after all, the stock is up more than 750% in the last three years. That could make for great timing to add to or start a position in this technology leader. The future of driving is just one such reason.

Through the first six months of 2018, NVIDIA's automotive segment pulled in $306 million in revenue, making up just 5% of the company's total. That small division of the graphics processing unit manufacturer's business is growing fast, though, posting 9% growth in 2018 to date compared with the year prior. That's in spite of the fact that self-driving vehicles aren't yet a reality.

NVIDIA is nevertheless leading the charge in autonomous vehicle development with its suite of hardware. Swedish automaker Volvo just announced a partnership with NVIDIA to develop self-driving capabilities, adding to an extensive list of start-ups and established automakers like Tesla and Toyota that the tech company already works with. The tech enables semi-autonomous and driver-assist tech now, but the ambitions are much higher in the years ahead.

Self-driving cars is just one iron in the fire for this hardware maker, but the industry's future potential and NVIDIA's leadership position make this stock worth keeping an eye on. The third-quarter report is due out on Nov. 15.

Way mo' money

Danny Vena (Alphabet): One of the biggest long-term opportunities for Alphabet is the massive profit potential for its self-driving car unit, Waymo. After topping 10 million autonomous miles driven, the company has achieved an even bigger milestone: Passengers in Arizona have begun to pay for rides in its self-driving cars, making it the first commercial autonomous ride-hailing service.

During Alphabet's third-quarter conference call, Chief Financial Officer Ruth Porat said, "We built on our Early Rider Program [by] both expanding the group of participants and beginning to test pricing models." She went on to say that Waymo had extended the service to a larger group of customers and had "moved into very early days of commercialization" -- people had begun paying for rides. Porat also said the company was developing a business-to-business (B2B) opportunity, partnering with several companies that are "sponsoring a service on behalf of their employees and customers."

Porat is referring to deals Waymo struck with Walmart, AutoNation, and Avis Budget Group -- among others -- to pick up customers and employees and transport them to the companies' places of business. 

Waymo selected these partnerships after collecting data on how those in the Early Rider Program were utilizing the service. Many riders were using Waymo for commuting to work and school, visiting restaurants and bars, grocery shopping, and running errands, so these partnerships are a natural extension of how consumers were using the service already. 

The company has also been testing a fleet of 18-wheelers across California, Arizona, and Georgia in a bid to disrupt the commercial trucking industry. 

But what does all this mean to investors?

Analysts at Morgan Stanley initially valued Waymo at more than $70 billion but have since raised estimates to a whopping $175 billion. The biggest driver of the increase was the potential from autonomous trucking and delivery services. 

If this seems like a ground-floor opportunity, it should, and that's why Waymo parent Alphabet deserves a close look.

Don't forget the gearheads

Chris Neiger (General Motors): Sure, the tech companies mentioned above are making big waves in the self-driving market, and they certainly deserve to be on this list of top driverless-car stocks. But that doesn't mean investors should overlook what traditional automakers are doing in this space and, more specifically, how General Motors is leading.

GM began focusing its attention on driverless vehicles when it bought a self-driving vehicle technology company called Cruise Automation back in 2016. Since then, GM has retooled two of its manufacturing plants to prepare for mass production of self-driving cars, built and tested a fleet of fully autonomous vehicles, announced that it will launch a self-driving vehicle service starting next year, and shown off its designs for a commercial fully autonomous vehicle -- built without a steering wheel or pedals.

It's easy for companies to announce big plans for the future but never act on them, but that's not what GM is doing. The company has already invested billions of dollars in Cruise, has released some semi-autonomous features into its existing vehicles, and has more than 100 autonomous vehicles currently being tested. Additionally, GM recently teamed up with Honda to build a self-driving car from the ground up for mass production and received an investment for its Cruise Automation company from the Japanese automaker for $750 million, with an additional $2 billion committed over the next 12 years.

So why does this matter for investors? Because GM is preparing to benefit in a future in which automotive transportation looks vastly different than it does today. IHS Markit estimates that in 2040, nearly 26% of all new vehicles sold worldwide that year will be autonomous. GM's current moves are making it a leader in the self-driving space, and when you add this to the fact that the company's shares are trading at just six times the company's forward earnings, GM looks like a great bet on the coming driverless-vehicle world.