Andy Murray secured his place in the semi-finals of the Masters Cup after easing to victory over Gilles Simon.
Murray raced into a 4-0 lead and, although the Frenchman hit back, he held on to take the first set.
Simon started the second set well but the British number one was soon back into his stride to seal a 6-4 6-2 win.
Roger Federer kept his hopes of making the last four alive after beating Radek Stepanek - a late replacement for the injured Andy Roddick - 7-6 (7-4) 6-4.
Murray surprised by favourite tag
Defending champion Federer, who arrived in China nursing a back injury, triumphed despite suffering from a stomach bug.
Roddick pulled out of the tournament with an ankle injury so Stepanek, the world number 27 from the Czech Republic, became the second stand-in to play in Shanghai after Simon replaced Rafael Nadal.
Simon beat Federer in his first game but found Murray a different proposition, although the Scot did not have things all his own way.
Despite a strong start that saw him break Simon twice in the first four games, a number of unforced errors allowed Murray's opponent back into the first set and his own serve began to wobble.
Murray missed an easy overhead on game-point when he was serving to go 5-1 up and was eventually broken, then needed to dig deep to save three break-points in his next service game.
The start of the second set was just as close with Murray again riding his luck on serve as Simon continued to improve.
But the Frenchman was still unable to take his opportunities and instead it was Murray who struck - breaking twice in quick succession as mistakes began to creep into Simon's game.
In the end it was a comfortable win for Murray, who can relax ahead of his match with Federer knowing he is already into the last four.
"The first two matches were really important," Murray told BBC Sport. "I did not want to go into the final day having to play Federer to qualify.
"I have played really well so far and I have a chance to win the competition. I would have signed up for that at the start of the year, that is for sure."
Murray was noticeably sharper than he was against Roddick and feels he is in good shape to continue his progress.
"My first match really helped," he explained. "I'd been falling asleep around 8pm in the evenings most days and that match started at that time. I felt tired, and my legs were very heavy after some long rallies but today I felt absolutely perfect.
"I have got a lot of confidence just now and I want to try to keep it going. I have got a great record indoors and I really like these courts."
Serbia's Novak Djokovic became the first player to book his semis place on Tuesday after beating Nikolay Davydenko in three sets in the Gold Group, and Murray has definitely joined him.
Federer needed a win over Stepanek otherwise he would have been out of contention before meeting Murray in his final match on Friday.
On paper it seemed an easier task for the Swiss star than overcoming Roddick but he had to work hard to take the first set on a tie-break.
Stepanek also pressed him hard in the second before folding at the end - losing the match thanks to a double-fault which saw him drop his serve to love.
Federer revealed afterwards that he had been ill since Monday evening, explaining: "I guess I got really lucky that the match was scheduled late. Then that Andy pulled out made it a little bit more lucky.
"And then Radek is not playing with his own racquets, so that made it a little bit more lucky again," he said.
"At the end of the day I still have a chance. I hope with a day of recovery, I'll make a miracle happen here and get through into the semis."
A victory for Murray on Friday would eliminate Federer and he says he will not lack motivation against the top seed.
"I'm sure the tournament director would rather I didn't want to win that one," Murray laughed.
"But I think any time you play against Federer, who is probably the greatest player of all time, it is probably a bit disrespectful to not try to win.
"I will give it my best shot. There is a lot of pressure on him to win that match and I will just try to do my best.
"Maybe I will feel too relaxed and I won't play my best because there is not that much pressure on me but, in terms of actually wanting to win the match, not too many people beat three top ten players in the world and go through their group stage in the Masters Cup without losing and I would love to do that."
On Thursday, Djokovic, who has already qualified, takes on Jo-Wilfried Tsonga in a dead rubber, with the winner of the Davydenko and Juan Martin del Potro clash progressing from the Gold Group.
6 months ago