The Swiss star won 5-7, 6-2, 6-2 and will now face Andy Murray's conqueror Novak Djokovic or Sam Querrey in the semis.
Niokolay Davydenko is also through to the semi-finals after a 6-3, 4-6, 7-5 win over fellow Russian Igor Andreev.
After the match Davydenko said: "Maybe I was lucky (to win) this match. I think Andreev changed his tactics, started to play the first few games in the second set really slow, just trying to keep the ball in the court and I started to make mistakes."
Davydenko will next meet the winner of the all-Spanish clash between Rafael Nadal and David Ferrer.
Murray was dumped out in the fourth round of the tournament after the world number three Djokovic brushed him aside 6-0, 6-4.
We recommend William Hill for the best tennis betting experience.