For years, two knocks against Tesla were that a constant churn of executive turnover would catch up to Elon Musk, and that an onslaught of electric models from Volkswagen Group and others would put him in his place.

Now, the tables have turned.

VW’s electric offensive has sputtered, with software issues plaguing its full-electric ID3 model.

And it’s the German giant whose executive suites are turning over: in a matter of days, its trucks chief resigned, the leader of its van unit was demoted, and its head of software was reassigned.

Even CEO Herbert Diess’s job looked insecure for a moment before VW’s supervisory board settled on stripping him of responsibility for the company’s namesake division.

The circumstances of each individual’s cases vary, and VW continues to have a massive advantage over Tesla in many respects. But some investors are concerned it might not be coincidence that all four VW executives in question were external hires installed to push through deep changes at the automaker.

Their struggles of late cast a pall over the structural and cultural changes VW vowed to make after its diesel-emissions scandal a half decade ago.

“VW risks being perceived as a large, slow-moving entity that is resistant to change in an industry where the pace of change is accelerating,” said Timm Schulze-Melander, an industrials specialist at the equity-research firm Redburn. “How will such a group manage to attract and retain the software engineering skills that may prove be so critical to its future?”

The coronavirus pandemic is now posing the biggest challenge to VW since the diesel crisis erupted, while Tesla’s potential to maintain an electric-car edge has powered its stock surge.

At $286.8 billion as of Tuesday’s close, the Elon Musk-led company’s market capitalization has soared past the $220 billion mark that VW’s top management set as a goal last year.

While VW is expected to report nine times as much revenue as Tesla this year, investors value the German company at a little more than a third of its target. It’s still the third-biggest automaker by market capitalization and better positioned to weather the industry’s seismic technology shift than many of its peers.

Diess, 61, spent almost two decades rising up the ranks of BMW before VW poached him in 2015 to revive weak profit margins at its core brand. He became CEO of the group two years ago. But at an extraordinary supervisory board meeting on June 8, key stakeholders forced him to cede direct control of the VW passenger-car unit and focus on leading the group.

Diess was stripped of the role after a series of troubling signals about his job status. First, VW’s powerful labor leaders blamed him for struggles to adopt stricter emissions-tests procedures in Europe, which caused major production disruptions. Then, technical issues plagued early output of the critical Golf hatchback and new ID3.

A report that VW’s top supervisory board committee denied his request for an early contract extension further escalated tensions.

At the beginning of June, Diess accused board members of committing crimes by leaking confidential discussions, according to people familiar with the matter. While he weathered the spat with the CEO job intact, the board issued an unusual public statement, saying it had accepted Diess’s apology and would continue to support him.

The dust-up was only the beginning. On July 8, Traton, the VW truck unit that pushed through an underwhelming IPO last year after much internal wrangling, announced the abrupt departure of CEO Andreas Renschler and two other board members.

The former Daimler veteran had been bridging divides between the rival Scania and MAN brands and forging a joint global expansion strategy.

The surprise move raised questions about the prospects for MAN’s latest restructuring plan. Nord/LB analyst Frank Schwope summed up the announcement as a “bombshell.”

Another senior executive, Thomas Sedran, was reassigned to handle asset management at VW’s commercial vehicles and machinery operations. The 2015 hire who previously worked for Opel had been head of VW’s light-commercial vehicles division and a key figure behind the company’s alliance with Ford.

VW did not offer a reason for the job change. Contracts to widen cooperation with Ford to self-driving car technology were just signed in May, and he was in the early stages of executing a plan negotiated with labor unions to restructure VW’s van business.

The latest shakeup involves one of Diess’s top priorities. He wanted to establish a powerful in-house software unit that would supply all of the group’s 12 brands and ensure full control over the enormous amounts of data generated by connected cars — a space Tesla has dominated.

The issues VW has had with integrating “baby-step” software into the Golf and ID3 shows just how much work has to be done to boost the company’s competency in this area, said Chris McNally, Evercore ISI’s auto analyst.

Less than a month after the groupwide operation dubbed Car.Software.Org started, Audi CEO Markus Duesmann is taking charge, replacing IT chief Christian Senger. VW said Wednesday it is examining what his next job will be.

VW can ill afford to waste time with infighting. Musk, who remains unpredictable as ever, is not waiting to have his plant near Berlin built to start hyping its capabilities.

He has also hinted at adding a European-style hatchback to Tesla’s lineup, which would target VW’s core car business.