I have a C++ project, run rightly compiled by gcc-4.1.2-46 and gcc-4.4.5-6
But it has an abnormal dead loop while compiled by gcc-4.4.6-3 using -O2.
I use gdb to
Update:
The _Unwind_Resume function will
Resume the unwind process, called at the end of cleanup code that didn't return to the normal thread of execution (ie, not a catch).
See The Secret Life of C++: Day 3: Exceptions
which according to this
It's needed for pthread_cancel. It resumes unwinding after a cleanup.
So it seems there is an exception in a thread for which there is no catch... given that the behavior is different with different versions of gcc and different optimization levels I would venture that you are using threads and have a race condition.