Home | History | Annotate | Download | only in gen
History log of /src/lib/libc/arch/hppa/gen/__longjmp14.c
RevisionDateAuthorComments
 1.7  13-Apr-2025  riastradh hppa longjmp: Use _UC_SIGMASK to restore signal mask.

This way, restoring the signal mask and restoring the stack pointer
happen atomically with respect to signal handler calls, whereas using
sigprocmask would restore the signal mask _before_ the stack pointer,
breaking sigaltstack.

The motivation for using sigprocmask first and then setcontext later,
rather than _UC_SIGMASK in setcontext, was to get SA-based libpthead
sigprocmask interposition. But that's long gone and unlikely to come
back.

Tested under qemu with:

atf-run /usr/tests/lib/libc/setjmp | atf-report
atf-run /usr/tests/lib/libpthread/t_siglongjmp | atf-report

PR lib/57946: longjmp fails to restore stack first before restoring
signal mask on most architectures
 1.6  25-Jan-2016  christos branches: 1.6.28;
use __register_t
 1.5  22-Mar-2012  skrll Shut lint up about dp.

From he@
 1.4  28-Apr-2008  martin branches: 1.4.4; 1.4.8;
Remove clause 3 and 4 from TNF licenses
 1.3  24-Dec-2005  perry branches: 1.3.18;
__asm__ -> __asm, __volatile__ -> __volatile
 1.2  14-Sep-2005  he Patterned after the other fixes for __longjmp14.c, include
<compat/include/setjmp.h> also here to make these build.
 1.1  18-Jul-2004  chs split __longjmp14() into a separate file and make it use setcontext()
instead of __sigreturn14(). translated from MIPS.
 1.3.18.1  18-May-2008  yamt sync with head.
 1.4.8.2  28-Apr-2008  martin Remove clause 3 and 4 from TNF licenses
 1.4.8.1  28-Apr-2008  martin file __longjmp14.c was added on branch christos-time_t on 2008-04-28 20:22:56 +0000
 1.4.4.1  17-Apr-2012  yamt sync with head
 1.6.28.1  02-Aug-2025  perseant Sync with HEAD

RSS XML Feed