Mary Barra, chief executive officer of General Motors Co., speaks during an event at the company's Orion Assembly Plant in Orion Township, Michigan.

General Motors will begin testing driverless cars in a matter of "quarters not years," CEO Mary Barra said Tuesday.

GM's efforts to jump-start research and development in self-driving cars seem to be paying off: The automaker's recent strides in the area have boosted its reputation among investors.

"GM and Cruise Automation recently deployed our latest generation self-driving electric test vehicle," Barra said on a conference call. "We believe it will meet the redundancy and safety requirements necessary to operate without a driver."

She spoke after the automaker reported third-quarter earnings that beat expectations on the top and bottom lines.

Barra attributed Cruise's success in part to the fact that it is testing the cars in complex environments such as San Francisco, which she called one of the most complex urban environments anywhere.

"In this environment, we encounter almost 50 times more interactions with pedestrians and other vehicles in complex road intersections, compared to driving in a suburban environment," Barra said. "This testing is accelerating our deployment of self-driving technology and we believe it will put us on the path, the fastest path, to deploying self-driving cars safely and at scale."

The company is also considering London and Berlin as test markets, Barra said. Earlier in October, GM said it plans to begin testing its cars in a section of downtown Manhattan.

GM's stock jumped in early October as buzz began to build over its position in autonomous vehicles and other trends in transportation that have captured investor attention. Share prices are up 32 percent this year.

In contrast, Ford stock has risen less than 1 percent. And Tesla's shares have risen almost 60 percent.

"We think GM's proactive approach is allowing the company to move faster than most peers, with in-house [intellectual property] related to electric drivetrains, shared vehicle platforms, and autonomous vehicle hardware/software," Piper Jaffray analyst Alexander Potter said in a note Tuesday. "Because of momentum in this segment, we think investors will grow increasingly comfortable applying a higher-than-average multiple to the GM's earnings stream."

Barra also said the company is exploring its options on how it would deploy and monetize an autonomous fleet.