Dominic Thiem stunned Novak Djokovic to become the first player into the semi-finals at the ATP Finals in London.
The Austrian won a thriller 6-7 (5-7) 6-3 7-6 (7-5) to advance, ensuring Djokovic and Roger Federer will fight for the other place when they meet in their final group match on Thursday.
Federer, who had lost his opening round-robin match to Thiem on Sunday, had earlier got his campaign on track.
He beat Italy’s Matteo Berrettini 7-6 (7-2) 6-3 to keep alive his hopes.
The results set up an enticing winner-takes-all battle between 16-time Grand Slam champion Djokovic and 20-time major winner Federer, who played out an epic Wimbledon final in July that the Serb eventually won.
The top two players in each group after the round-robin stage progress to Saturday’s semi-finals.
The event, which is taking place in London for the penultimate year, features the top eight male players of 2019.Losing a close first-set tie-break sparked the turnaround for Thiem, who broke early in the second to race to a 3-0 lead and made his mark with an exciting mix of one-handed
backhands and inside-out forehands.
He racked up 51 winners, compared to 28 for Djokovic, but also hit 51 unforced errors in a fearless display of attacking tennis in what turned into the best match of the tournament so far.
Thiem broke in the first game of the deciding set and immediately backed it up with a difficult hold. He was broken back in the sixth game and then successfully challenged a line call at 30-30 in the 10th game which prevented the Serb from having a match point.
The Austrian then broke Djokovic to love in the next game but failed to serve out the victory, instead finding himself in another tie-break and trailing 4-1.
But Thiem, a French Open runner-up for the past two years, recovered once again to seal victory on his second match point when the Serb netted a forehand.
“This was a very special match, what I practised all my life for, an epic one in front of an amazing crowd and beating a legend of our game,” Thiem, 26, said.
“It is a match I will probably never forget.
“I stayed in the match. It is special to come back from a set down, especially in a tie-break.
“I stayed offensive all the time even when it didn’t always work out. I’m proud I reached my goal of the semi-finals.”
Third seed Federer has failed to qualify for the last four in the season finale on just one occasion despite this being his 17th competition.
After failing to beat Thiem in his opening group game, the match with Djokovic will now decide Federer’s progression to the semi-finals.
Federer, who said he will “hopefully play a bit better” when he comes up against the Wimbledon champion, is chasing a seventh title in the Finals, having withdrawn from the Paris Masters in October in order to “pace himself”.
Last year, Federer lost to Japan’s Kei Nishikori in his opening group match and he said it gave him “some experience” to draw on before Tuesday’s crucial win over Berrettini.
“There’s no reason to be down on yourself,” said Federer. “There were plenty of ways to get through that loss. Just hanging out with my kids did it for me.
“I didn’t think everything was bad in that first match. I was ready and prepared today and that’s what matters the most.”