]> git.ipfire.org Git - thirdparty/glibc.git/commit
htl: Make sem_*wait cancellations points
authorSamuel Thibault <samuel.thibault@ens-lyon.org>
Tue, 23 Jun 2020 22:43:32 +0000 (22:43 +0000)
committerSamuel Thibault <samuel.thibault@ens-lyon.org>
Tue, 23 Jun 2020 23:19:49 +0000 (01:19 +0200)
commiteca16db02d660242e709d4b8a11a2c5b94cca540
treefda5e40a34d5d16179bff5718f0e80a89825e639
parent3513d5af3d111f322cf2b64f2c7d415ea923bf25
htl: Make sem_*wait cancellations points

By aligning its implementation on pthread_cond_wait.

* sysdeps/htl/sem-timedwait.c (cancel_ctx): New structure.
(cancel_hook): New function.
(__sem_timedwait_internal): Check for cancellation and register
cancellation hook that wakes the thread up, and check again for
cancellation on exit.
* nptl/tst-cancel13.c, nptl/tst-cancelx13.c: Move to...
* sysdeps/pthread/: ... here.
* nptl/Makefile: Move corresponding references and rules to...
* sysdeps/pthread/Makefile: ... here.
nptl/Makefile
sysdeps/htl/sem-timedwait.c
sysdeps/pthread/Makefile
sysdeps/pthread/tst-cancel13.c [moved from nptl/tst-cancel13.c with 100% similarity]
sysdeps/pthread/tst-cancelx13.c [moved from nptl/tst-cancelx13.c with 100% similarity]