musl/arch/i386/bits
Rich Felker feee98903c overhaul pthread cancellation
this patch improves the correctness, simplicity, and size of
cancellation-related code. modulo any small errors, it should now be
completely conformant, safe, and resource-leak free.

the notion of entering and exiting cancellation-point context has been
completely eliminated and replaced with alternative syscall assembly
code for cancellable syscalls. the assembly is responsible for setting
up execution context information (stack pointer and address of the
syscall instruction) which the cancellation signal handler can use to
determine whether the interrupted code was in a cancellable state.

these changes eliminate race conditions in the previous generation of
cancellation handling code (whereby a cancellation request received
just prior to the syscall would not be processed, leaving the syscall
to block, potentially indefinitely), and remedy an issue where
non-cancellable syscalls made from signal handlers became cancellable
if the signal handler interrupted a cancellation point.

x86_64 asm is untested and may need a second try to get it right.
2011-04-17 11:43:03 -04:00
..
alltypes.h.sh more types cleanup 2011-04-11 10:48:52 -04:00
endian.h preparing build system to handle ports - step 1 2011-02-15 00:33:23 -05:00
errno.h fix missing ENOTSUP error code 2011-03-11 09:50:54 -05:00
fcntl.h fix O_SYNC definition, cleanup fcntl.h 2011-04-14 22:06:30 -04:00
fenv.h preparing build system to handle ports - step 1 2011-02-15 00:33:23 -05:00
float.h add missing float.h macros 2011-04-10 18:27:47 -04:00
in.h add some missing ipv6 stuff 2011-04-05 14:05:11 -04:00
ioctl.h cleanup socketcall syscall interface to ease porting to sane(r) archs 2011-02-15 04:40:40 -05:00
ipc.h numerous fixes to sysv ipc 2011-04-13 16:45:43 -04:00
limits.h fix the types of some integer constant limits in headers 2011-02-15 19:15:45 -05:00
mman.h preparing build system to handle ports - step 1 2011-02-15 00:33:23 -05:00
msg.h numerous fixes to sysv ipc 2011-04-13 16:45:43 -04:00
posix.h preparing build system to handle ports - step 1 2011-02-15 00:33:23 -05:00
pthread.h overhaul pthread cancellation 2011-04-17 11:43:03 -04:00
reg.h preparing build system to handle ports - step 1 2011-02-15 00:33:23 -05:00
setjmp.h preparing build system to handle ports - step 1 2011-02-15 00:33:23 -05:00
shm.h numerous fixes to sysv ipc 2011-04-13 16:45:43 -04:00
signal.h make sigaltstack work (missing macros in signal.h, error conditions) 2011-03-10 10:17:29 -05:00
socket.h resolve some header namespace non-issues 2011-02-20 02:44:52 -05:00
stat.h preparing build system to handle ports - step 1 2011-02-15 00:33:23 -05:00
statfs.h preparing build system to handle ports - step 1 2011-02-15 00:33:23 -05:00
stdarg.h split off arch-specific stdarg.h stuff 2011-02-15 05:06:15 -05:00
stdint.h preparing build system to handle ports - step 1 2011-02-15 00:33:23 -05:00
syscall.h overhaul pthread cancellation 2011-04-17 11:43:03 -04:00
sysmacros.h preparing build system to handle ports - step 1 2011-02-15 00:33:23 -05:00
tcp.h preparing build system to handle ports - step 1 2011-02-15 00:33:23 -05:00
termios.h various legacy and linux-specific stuff 2011-03-18 21:52:26 -04:00
user.h preparing build system to handle ports - step 1 2011-02-15 00:33:23 -05:00
wait.h preparing build system to handle ports - step 1 2011-02-15 00:33:23 -05:00
wexitstatus.h add missing WIFCONTINUED macro and improve WIFSIGNALED 2011-02-19 02:23:29 -05:00