RIO DE JANEIRO — The record has stood the test of time, outlasting civilizations, wars, epochs of change and progress. It’s no match, however, for Michael Phelps.

The swimmer’s win in the 200-meter butterfly Tuesday night not only gives him more gold than Scrooge McDuck, but it means he’s drawn into a tie for the most Olympic titles ever, according to historians. For more than 2,000 years, Leonidas of Rhodes held the record and could rest pretty easy knowing that no one would ever come close. And then a kid from Baltimore learned to swim.

#Olympics With his 12th individual Olympic title Michael Phelps equal the all time Olympic record set by Leonidas of Rhodes in 152 BC — Hilary Evans (@OlympicStatman) August 10, 2016

Tied with Leonidas with 12 Olympic titles, Phelps will have a chance to break the record on Thursday when he swims the 200 individual medley race. Phelps has a total of 21 Olympic gold medals, but nine have come in relays. There were no relays in Leonidas’s day — nor was there competitive swimming — so it’s impossible to know his true Olympic potential. Historians suggest he was pretty good.

While Phelps’s gold-medal haul includes titles in five different individual events, Leonidas was a champion in three. And he won all three races at four straight Olympic Games. And he did it in the nude.

ICYMI, Leonidas won the stadion, diaulos, and hoplite race at the 164-160-156-152 BC Ancient Olympic Games. 4 consecutive in 3 diff events — Bill Mallon (@bambam1729) August 10, 2016

Of course, the stadion is a race measuring about 200 yards and diaulos is one that’s twice as long. The hoplitodromos — also called the hoplite race — might be the most intriguing. Runners competing in the ancient race were required to wear a helmet, leg armor and carry a shield. With 50 pounds of added weight, it was a test of strength as much as speed or endurance.

Even more impressive: every four years, the races apparently took place on the very same day. Leonidas was almost literally an Olympic god, winning his last three titles at the age of 36. He didn’t utilize ancient cupping techniques, had no sponsors backing him and for centuries, his record seemed safe.

Times have changed, and Phelps passed the modern mark eight years ago when he bested Ray Ewry’s record of eight Olympic titles. Ewry was a track and field athlete who competed in the 1900, ’04 and ’08 Olympics — winning titles in the high jump, the long jump and the triple jump.

Leonidas was not immediately available for comment.

Read more:

Michael Phelps extends his legacy with two more gold medals at Rio Olympics

Baltimore’s National Anthem ‘Oh!’ gives Michael Phelps a gold-medal laugh