Scientists have discovered a vicious type of crocodile that they say would have been one of the top predators before the dinosaurs came along.
They say the 3-metre long croc lived on land and walked on its hind legs.
It lived in what is now North Carolina in the USA - which 230 million years ago was a marshy swamp, part of an ancient huge continent known as Pangea.
The croc would have competed with other snappy reptile predators, eating smaller reptiles and mammals.
It's been called Carnufex carolinensis, or the "Carolina Butcher," and it was one of a number of super-predators alive at the time, the Late Triassic period.
"These animals hunted alongside the earliest theropod dinosaurs, creating a predator pile-up," says Lindsay Zanno of North Carolina State university, who worked on the study.
As the Triassic period came to a close, the really big crocodile-type predators died out, leaving just smaller relations to run under the mighty feet of the dinosaurs.
Smaller ones lived on
"Predatory dinosaurs went on to fill these [top predator] roles exclusively for the next 135 million years," Lindsay says.
But the smaller crocs changed their hunting style, living alongside dinosaurs as scavengers.
"The ancestors of modern crocs initially took on a role similar to foxes or jackals, with small, sleek bodies and long limbs," says Susan Drymala, who also worked on the study.
"If you want to picture these animals, just think of a modern day fox, but with alligator skin instead of fur."