Tournament hosts Japan will meet Spain in the Olynpics semi-finals.
Japan beat New Zealand on penalties on Saturday to secure a place in the final four.
The two sides played out a goalless 120 minutes at the Kashima Soccer Stadium to take the tie into a shootout, with Japan coming out 4-2 winners.
- Man Utd misery: Fernandes penalty failure and defensive injuries pile early-season pressure on Solskjaer
- Man City masterclass: Guardiola finally finds a way to take down Tuchel's Chelsea
- Why Brentford are the Premier League's most innovative and unique club
- Inside Griezmann's Atletico Madrid nightmare - no goals, no assists, no shots on target
Who else is in the semi-finals?
Spain, meanwhile, were almost knocked out of the competition in their clash with Ivory Coast, but a stoppage time goal from Rafa Mir made it 2-2 and took the game into extra time.
Mikel Oyarzabal scored a penalty in the first half of extra time before two more Mir goals saw La Roja go through with a 5-2 win.
Japan or Spain will meet either Brazil or Mexico in the final of the tournament.
Brazil went through with a 1-0 win against Egypt thanks to a first-half goal from Matheus Cunha.
Mexico, on the other hand, dominated against South Korea to ensure their hopes of picking up a medal are still alive.
Henry Martin, Luis Romo and Francisco Cordova struck to give El Tri a 3-1 half-time lead.
Korea pulled one back in the second half to give them a chance, but three minutes later Mexico restored their lead. Goals from Cordova and Eduardo Aguirre moved even further ahead before Ui-Jo Hwang struck late on to make it 6-3.
When will the semi-finals be played?
The two semi-final ties will be played on Tuesday August 3.
The clash between Brazil and Mexico in Kashima will kick off first, with Japan and Spain going head-to-head in Saitama later on.
When is the final?
The losing semi-finalists will go ahead to decide which team gets the bronze medal on August 6.
Then, the other two sides will face off for the gold and silver medals the following day in Yokohama.