David Ferrer virtually out after straight-set loss to Tomas Berdych

Roger Federer stayed in the hunt for a semifinal spot at the ATP World Tour Finals on Thursday when he beat Richard Gasquet 6-4, 6-3 in round-robin play in Group B.

Federer, who was beaten by Novak Djokovic in his opening match, still needed six match-points to get the job done on an afternoon when he hit 29 winners and 30 unforced errors as he broke Gasquet in a marathon final game.

The 17-time Grand Slam winner frittered away his first five match points with unforced errors before Gasquet put a return wide.

“Today was just a battle for myself, making sure I move the right way, I play the right way, I have the right shot selection,” said Federer.

“Richard does a good job of making you feel uncomfortable; he uses heights, spins really well. He likes extended rallies. But I guess those are the kind of matches I need right now — straight sets against a good player. It clearly comes at the right time.”

Federer, playing the season finale for the 12th consecutive year, has now won a record 43 matches at the season wrap-up tournament.

“That win was big for me — he did beat me three times indoors straight: the Basel finals twice, and also here last year,” said the Swiss.

“I'm glad I got one back in Paris because I knew we could be in the same group again, we could be playing each other. I think that win for me in Paris was very important psychologically. I could beat top-10 guys, I beat Richard, I beat Juan-Martin (del Potro) last week.

“My confidence is higher, and that’s what I need to beat the best, and Juan-Martin is part of that group, honestly.”

Federer was momentarily rocked at the start as Gasquet won the first six points before the Swiss gathered his resources in the must-win contest.

The 32-year-old came from 0-30 in the second game to hold, and then seized a break for 2-1.

Federer lost his lead in the eighth game as he saved one break point but sent a backhand wide to bring Gasquet level at 4-4.

The Swiss broke straight back for 5-4, and set up three set points a game later with his third ace.

The longtime London crowd favourite converted on his first to take the early lead after 34 minutes.

Federer began the second set with a break and stayed in charge throughout despite struggling with his consistency before closing out victory.

The win was his 44th of the season.

Berdych kept his hopes of a semifinal spot alive on Wednesday with a 6-4, 6-4 defeat of World No.3 David Ferrer who is now virtually out of contention.

The results:

Singles: Group B: Roger Federer bt Ricahrd Gasquet 6-4, 6-3. Group A: Tomas Berdych bt David Ferrer 6-4, 6-4.

Doubles: Group A: Marcelo Melo & Ivan Dodig bt Mariusz Fyrstenberg & Marcin Matkowski 6-4, 3-6, 10-2. Group B: Alexander Peya & Bruno Soares bt Marcel Granollers & Marc Lopez 3-6, 6-4, 10-5.

More In: Tennis | Sport