Roger Federer's hopes of winning a ninth Wimbledon title were ended by a quarter-final loss to Poland’s Hubert Hurkacz.

The 39-year-old had played himself into form through the first week at the All England Club to raise hopes of an improbable trophy run after two knee operations and a month short of his 40th birthday.

But Hurkacz is a top-20 player and 15 years Federer’s junior, and was simply too good on the day for his opponent, who suffered a straight-sets loss at Wimbledon for the first time in 19 years.

After a poor first set in breezy conditions, Federer led 4-1 in the second but he could not find his timing and Hurkacz kept his wonderfully to win 6-3 7-6 (7-4) 6-0, handing the Swiss his first ever bagel at Wimbledon.

Hurkacz, who has been compared to Andy Murray, was playing in his first grand slam quarter-final and talked glowingly after his fourth-round victory about his opponent, but he did a superb job of not playing the occasion.

Hurkacz won the biggest title of his career in Miami in April but had slumped alarmingly since, losing six straight matches heading into Wimbledon.

He had only won four tour-level matches on grass prior to this tournament but recovered from two sets to one down against second seed Daniil Medvedev on Tuesday, finishing the match under the roof on Centre Court.

He settled quickly into the match and broke the Federer serve in the sixth game before clinching the opening set.

Federer's timing was off but he made the perfect start to the second set with a break of the Hurkacz serve when the 14th seed double faulted.

Federer saved three break points to hold for 3-0 but he still did not look comfortable and it was no surprise when Hurkacz broke back in the seventh game.

The tie-break was huge for both men, and a very untimely slip on an easy volley left Federer 4-2 down and proved very costly.

The eight-time champion had not come from two sets down to win a match for five years, and the crowd willed their hero on, but Hurkacz was simply far too good for this Federer.

Hurkacz wrapped up victory in an hour and 49 minutes, becoming the second Polish man to reach the semi-finals at a grand slam after Jerzy Janowicz here eight years ago.

"It’s super special for me," he said. "Playing on this special court against Roger, it’s a dream come true."

Novak Djokovic marched into his 10th semi-final after a straight-sets win over Marton Fucsovics on Centre Court.

The five-time champion, looking to claim a record-equalling 20th grand slam title this weekend, swept aside unseeded Fucsovics 6-3 6-4 6-4.

Djokovic has still only dropped one set, against Britain's Jack Draper in the first round, and he remains firmly on course to become only the fourth man to win three consecutive Wimbledon titles alongside Federer, Bjorn Borg and Pete Sampras.

Things looked ominous for Fucsovics when Djokovic raced into a 5-0 lead and brought up two set points inside the first 25 minutes.

But the underdog fended those off to finally get a game on the board and, amid plenty of encouragement from the crowd, managed to break in the next, only the fourth time Djokovic had dropped serve in the entire tournament.

Fucsovics, the first Hungarian man to reach the last eight of a grand slam in 40 years, has a similar playing style to Djokovic and easily matches up with the Serbian on the fitness front.

Having surrendered the first set, the 29-year-old stayed with Djokovic until 4-4 in the second when one of too many forehand errors gave away a break point which the top seed devoured.

A backhand return winner brought Djokovic another break at the start of the third and he fended off four break points among some punishing rallies to wrap up another routine win.

"I think it was a solid performance," he said. "I started extremely well, did not do too many things wrong in the first five or six games.

"One break of serve in the second and third sets was enough and credit to Marton for hanging in there. He had a great tournament.

"Going for history is a huge inspiration to me – let’s keep it going."

Denis Shapovalov showed he is ready to challenge for the title by booking his first grand slam semi-final with a five-set win over Karen Khachanov.

The Canadian won the boys' crown in 2016 and is giving himself the best chance of replicating that in the men’s draw with an epic 6-4 3-6 5-7 6-1 6-4 victory over the Russian.

His biggest test is now to come as he faces world number one and defending champion Novak Djokovic in the last four on Friday.

But the 22-year-old proved he belongs on the biggest stage, coming from two sets to one down with his trademark flamboyance, and is likely to be a contender at this tournament for years to come.

He is one of two men who made it through to the last eight that have won the junior title.

So it only seemed a matter of time until he made an impact in the men’s draw and had got to this point playing some eye-catching tennis, which he brought on to Court One.

He forced four break points at 3-3 in the opening set, which Khachanov was able to wriggle out of, but there was no escape in the next service game as he took the break with a crisp volley after a smart approach.

He quickly served out the first set in his next service game and that appeared the perfect platform for him.

But Khachanov had other ideas and, as Shapovalov’s forehand went missing in action, he quickly reeled off four successive games to put a tight grip on the second set.

Shapovalov’s level came some of the way back and he regained one break but Khachanov steely averted any further comeback attempt to level the match up.

The third set was a titanic battle with both men peppering winners from the baseline, but it was Khachanov who edged it, stealing a break at 5-5 and then serving it out.

Shapovalov was staring down the barrel but immediately came out firing and dominated the fourth set, reeling off five successive games to win it 6-1 and take the match to a decider.

Khachanov’s heart must have sunk at that point, following his gruelling five-set battle with Sebastian Korda on Monday and the last thing he needed was his opponent stepping it up a level.

He almost made a breakthrough at 2-2 but Khachanov recovered from 0-40 to hold but Shapovalov kept coming back and the match was won in the ninth game of the decider.

After squandering three more break points, he finally won his fourth when Khachanov drifted a forehand long, allowing him to serve it out.

Matteo Berrettini is on course to make it a double Italian celebration on Sunday after reaching the semi-finals.

While Italy's football team have already booked their place in the Euro 2020 final at Wembley, Rome-born Berrettini is one match away from a place in the Centre Court showpiece 12 miles down the road.

The 25-year-old Fiorentina fan won his quarter-final shootout with Felix Auger-Aliassime 6-3 5-7 7-5 6-3 and will face Hurkacz in the last four.

He said: "Everything is crazy right now. Thanks to Felix, I think we made a great match. He’s one of my best friends on the tour and it’s never easy to play him, but that’s sport.

"In Australia when we did quarantine we practiced together for two weeks so we know each other pretty well. Today was pretty tricky. But now I’m happy for me.

"Hubert is having a great season and beating Federer in three sets means he’s playing well – but I’m feeling confident."

Berrettini underlined his grass court credentials by winning at Queen’s Club last month.

His huge serve, which regularly booms down at 135mph, quickly cranked into gear while 16th seed Auger-Aliassime started nervously and found himself a double-break down in the first set.

The Canadian pulled one back when Berrettini let three set points slip, only to falter in the very next game.

The duo exchanged breaks early in the second set but Auger-Aliassime grabbed the crucial one at 5-5 and served out with a pair of aces to level the match.

However, at 6-5 in the third it was the 20-year-old from Montreal who blinked first, seventh seed Berrettini unleashing his destructive forehand to go back in front.

The momentum was firmly with the higher-ranked player, who held and then broke for 2-0 when Auger-Aliassime dumped a volley into the net.

His victory was momentarily delayed by a net cord on match point but moments later he was celebrating a place in the last four.