Brazil failed in yet another attempt to win a major women's football title, while host Great Britain crashed out of the Olympic Games competition.
United States and Japan, though, appear headed for another final showdown.
World champion Japan ousted Brazil 2-0 in the quarter-finals, despite being largely outplayed, while the US defeated New Zealand by the same score.
United States will now face Canada, which stunned Great Britain 2-0 to end the home side's hopes of securing a medal in its first competition as a unified team.
Japan will play France, which accounted for Sweden 2-1.
Japan defeated USA in the final of last year's FIFA World Cup, but still entered the game against Brazil as the underdog.
Brazil's women controlled play for most of the game, but Japan capitalised on the few counter-attacks it created to hand its South American opponent its earliest elimination ever from the Olympic Games.
Strikers Yuki Ogimi and Shinobu Ohno scored a goal in each half for Japan, leaving the Brazil frustrated by its inability to convert its chances.
"To see our team have so many opportunities and not score, and see the other team playing only at the back and scoring two goals is a tragedy," Brazil coach Jorge Barcellos said.
"The football that Japan presented didn't deserve to win. We will have to work a lot during the next four years before 2016 in Rio de Janeiro. We want to get the title there."
United States was far more convincing in beating New Zealand, with Abby Wambach again leading the way.
Wambach has scored in every match of the tournament, with the striker sliding onto a pass in the 27th minute and then celebrating with a cartwheel.
Sydney Leroux made it 2-0 in the 87th minute to seal victory for the two-time defending Olympic Games champion.
Great Britain's side had become increasingly popular at home, especially after defeating Brazil in its final group match at Wembley, and had not conceded a goal in its first three games.
But Canada scored twice in the first half as Britain was undone by defensive mistakes.
Jonelle Filigno scored Canada's opener after 16 minutes when she curled a half volley into the top corner.
Captain Christine Sinclair doubled Canada's lead in the 27th minute with a well struck free kick.
France took care of Sweden, who went ahead through captain Nilla Fischer, with goals from defenders Laura Georges and Wendie Renard.