Serena Williams returns a shot to Andrea Hlavackova during Williams’s fourth-round victory at the U.S. Open (Julio Cortez/ASSOCIATED PRESS)

Serena Williams sailed into the U.S. Open quarterfinals Monday without losing a game. And Roger Federer did the same without lifting a racket.

Labor Day was kind to the tournament favorites, with Williams, who is seeking her fourth U.S. Open title, needing just 57 minutes to dismiss Andrea Hlackova of the Czech Republic, 6-0, 6-0.

And Federer, a six-time U.S. Open champion, advanced on a walkover when American Mardy Fish withdrew just hours before their fourth-round meeting on the advice of his doctors.

Fish, 30, missed two months of the season this year because of an irregular heartbeat. He underwent a surgical procedure to correct it and returned to competition at Wimbledon in June. But his second- and third-round matches in the U.S. Open’s first week were five- and four-set battles that sapped his strength and put him at a disadvantage to Federer long before the match was due to start.

Fish had spent nine hours and five minutes on court in his first three matches, while Federer had spent five hours and six minutes.

In a statement released Monday afternoon, Fish didn’t address the heart ailment, saying simply that he regretted having to withdraw from the tournament “for precautionary measures” but was “following medical advisement.”

“I had a good summer and look forward to resuming my tournament schedule in the fall,” the statement concluded.

Federer moves on to a quarterfinal meeting with Tomas Berdych, the Czech who ousted him in Wimbledon’s quarterfinals in 2010.

Williams, the tournament’s No. 4 seed, has been on a tear since winning her fifth Wimbledon title in July and claiming Olympic gold in singles and doubles in August.

Through four rounds at the U.S. Open, she has yet to face a worthy challenger, defeating Coco Vandeweghe, 6-1,6-1; Maria Jose Martinez Sanchez, 6-2, 6-4; Ekaterina Makarova, 6-4, 6-0; and Hlavackova, a doubles specialist, with the dreaded “double-bagel.”

Williams showed no empathy for her overwhelmed opponent during or after the match, and none was in order.

“The match is never over until you shake hands,” said Williams, who finished with 31 winners to Hlavackova’s nine and faced just one break point. “There is always a comeback available. So I didn’t want to give her that opportunity to try to come back.

Up next for Williams: 2008 French Open champion Ana Ivanovic, who easily handled Tsvetana Pironkova, 6-0. 6-4.

Quick Hits: In the men’s draw, No. 3 seed Andy Murray beat Milos Raonic of Canada without facing a single break point, 6-4, 6-4, 6-2, to advance to the quarterfinals. In a third-round women’s doubles match, Russia’s Nadia Petrova and Maria Kirilenko defeated Venus and Serena Williams, 6-1, 6-4.