Milos Raonic says he came to the court with a poor attitude, and it almost cost him. Fortunately for the fifth-seeded Canadian, his booming serve rescued him from a big upset.

Raonic saved a win with his 30th ace in a tense 6-7 (7), 6-3, 7-6 (4) victory over American qualifier Steve Johnson on Thursday to advance to the quarter-finals of the Western & Southern Open tennis tournament.

'My attitude was not great when I was first serving for the match. It ... made life a lot tougher. I was playing too negatively.' - Canadian tennis star Milos Raonic

While his serve was potent, Raonic said his poor play made the contest "complicated."

Raonic had to win it all in a tiebreaker after striking three double-faults as he served for victory leading 5-4 in the final set. In the end, the 23-year-old won the last four points of the tiebreaker, capping the victory with another ace.

"My attitude was not great when I was first serving for the match," said Raonic. "It added up and made life a lot tougher, it put a lot of weight on my shoulders. I was playing too negatively.

"Johnson was getting ahead a few times, but not by any great distance. I just complicated things in a lot of moments. I certainly would have rather had that final ace at 5-4 in the third."

Raonic plays on Friday against 15th seed Fabio Fognini, who beat Lu Yen-Hsun 3-6, 6-3, 6-3. He said that his downbeat demeanour that plagued his play Thursday is a temporary problem.

"It's a Milos problem, we've spoken of it many times," he said. "But the beauty of tennis is when you win, you can always play much better the next day."

Raonic lost the opening set after 45 minutes. Johnson won it in a tiebreaker when the Raonic's lob landed beyond the baseline.

In the second, Raonic began to turn the tide as he went up a break for 2-0 then levelled at a set each with a winner down the line on his second set point.

The third became hard work for Raonic due to his errors and tenacity from his American opponent. In the deciding tiebreaker, Raonic profited from Johnson's forehand into the net to take a 6-4 and claimed the win on the next point.

Raonic, the last Canadian left in singles competition, will be playing his second Cincinnati quarter-final after 2012, when he lost to Stan Wawrinka.

Meanwhile, top-seeded Novak Djokovic was upset by Tommy Robredo of Spain 7-6 (6), 7-5, in the round of 16.

Djokovic, who has never won the tournament, dropped the first set after fighting back from a 6-3 deficit in the tiebreaker. Robredo failed to convert two match points before completing the upset with a slam on a short Djokovic lob.

6 straight losses

Robredo had lost six straight matches against the Serb after winning their first encounter.

Earlier, Andy Murray fought off two late match points and edged John Isner of the U.S. 7-6 (3), 6-4, 7-6 (2) to reach the quarterfinals.

Isner, who lost to Rafael Nadal in last year's final, had two chances to win the match with a 6-5 lead in the third set, but Murray salvaged both points before taking control with a mini-break for a 3-1 lead in the tiebreaker.

Stan Wawrinka shook off losing the first set to roll through the next two and advance with a 3-6, 6-0, 6-1 win over Marin Cilic of Croatia. Wawrinka, the Australian Open champion, will meet unseeded Julien Benneteau of France in the quarterfinals.

Benneteau eliminated Jerzy Janowicz of Poland 7-5, 6-1. Fognini of Italy also needed three sets to get past Yen-Hsun Lu of Taiwan 3-6, 6-3, 6-3.

In women's play, top-seeded Serena Williams continued her pursuit of her first title in this tournament with a 6-2, 6-2 win over Flavia Pennetta. Williams immediately took command, breaking Pennetta's first serve of the match. Williams, who's never won this tournament, also led, 5-0, in the second set.

Simona Halep of Romania also reached the quarter-finals with a 6-4, 7-5 win over Lucie Safarova of the Czech Republic, but Carla Suarez Navarro of Spain was upset by unseeded Elina Svitolina of Ukraine 4-6, 6-4, 6-4.

With files from The Associated Press