Loop stops execution without exit the program

Hello everyone! I have an application in fortran (some parts in 77 other in 90) that executes well almost all the time. But sometimes the program runs infinitely. I thought that my loop entered in an infinity cycle, but I put some prints and the prints stops to happen without exit the loop, and the last print is not always the same, and the program continues showing in the process manager, consuming cpu time and dont finish. Anyone seen something like that? Thanks!

Can you provide a code example (optimally the minimal example that reproduces the error)?

Welcome to the discourse! I think we are going to need quite a bit more detail, but some general advice would be to use a debugger.
The other piece of advice is to try to produce a simplified example you can post. People here are generous with their time and expertise, and can soon tell you if the problem can be reproduced by other compilers on other operating systems.
Welcome again and good luck

2 Likes