used to show you are angry or surprised
Oxford100% of films
-Any dinosaur-shaped ones? -Oh, for crying out loud.
Definitions from the Oxford Advanced Learner's Dictionary, 9th edition