[Bug libgcc/71890] when using setjmp&longjmp do context switch, libgcc crash the process when do unwind in thread cancel signal handler on X86_64

pinskia at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Fri Jul 15 07:26:00 GMT 2016


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71890

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|---                         |INVALID

--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
I don't think this is a valid thing to do with setjmp and longjmp.

Why are you not using makecontext/setcontext/getcontext/swapcontext instead?

Also why do you think this is a libgcc bug because if you try to unwind the
stack using gdb, you will get the same behavior because the stack was that one
thread is now on the other one but the that thread has now exited.


More information about the Gcc-bugs mailing list