On Tue, 29 Mar 2022, Jeremy Drake via Mingw-w64-public wrote:

> On Wed, 30 Mar 2022, LIU Hao wrote:
>
> > Does it make sense to use `__builtin_setjmp()` and `__builtin_longjmp()` 
> > here?
> > I am not sure whether Clang supports these. On x86 they restore only the BP
> > and SP registers (other caller-saved registers are not preserved) and do not
> > unwind the stack, so technically they shall not appear in the same function.
>
> Every time I've encountered code attempting to use the __builtin variants,
> it has ended up crashing in UCRT builds.

Correction, to get ruby working (probably the heaviest user of
setjmp/longjmp I have yet encountered) I only switched away from the
__builtin variants when building with Clang, not GCC UCRT.


_______________________________________________
Mingw-w64-public mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public

Reply via email to