Federer, 31, dropped the first set before surging back in the second to crush the 13th seed in the decider for a 4-6, 7-6(4), 6-0 win Thursday.
This success marks another milestone in the career of the Swiss maestro, guaranteeing him a 300th week at the top of ATP rankings, an all-time record.
The next opponent of Federer will be Marin Cilic, who eliminated Spain's Fernando Verdasco in three sets.
The Croatian 10th seed also had to recover from a set down and secured a 4-6, 6-1, 6-4 victory.
Elsewhere, sixth seed Janko Tipsarevic was stunned by world No. 21 Tommy Haas 2-6, 1-6.
The German veteran will now face another Serbian star Novak Djokovic in the quarters.
From Our Network
- Beijing sinking by up to 11cm annually, warns a satellite study
- Did you know before ‘Ae Dil Hai Mushkil’, Aishwarya and Ranbir worked together in a movie 17 years ago?
- NSG standoff: Clouds of mistrust hovering over India-China relations
- Shekhar Kapur's daughter makes singing debut, SRK and other B-town celebs tweet love to her
- Start negotiations to ‘leave’ as soon as possible, EU chiefs tell Britain