Skip to content
Success

Changes

Summary

  1. Dynamically allocate the alternate signal stack (commit: dd28ac0) (details)
  2. Update Changes (commit: 85115a8) (details)
Commit dd28ac0cf4365bd0ea1bcc374cbc5e95a6f39bea by david.allsopp
Dynamically allocate the alternate signal stack

In Glibc 2.34 and later, SIGSTKSZ may not be a compile-time constant.
It is no longer possible to statically allocate the alternate signal
stack for the main thread, as we've been doing for the last 25 years.

This commit implements dynamic allocation of the alternate signal stack
even for the main thread.  It reuses the code already in place to allocate
the alternate signal stack for other threads.

The alternate signal stack is freed when the main OCaml code / an OCaml thread
stops.

(partial back-port of PR#10266 and PR#10726)
(commit: dd28ac0)
The file was modifiedruntime/signals_nat.c (diff)
The file was modifiedruntime/startup_nat.c (diff)
The file was modifiedruntime/fail_nat.c (diff)
The file was modifiedotherlibs/systhreads/st_stubs.c (diff)
The file was modifiedruntime/sys.c (diff)
Commit 85115a869878ca98ad74d335e41d1e0d0e20d522 by david.allsopp
Update Changes

Updated separately to allow the previous patch to be used for multiple
releases.
(commit: 85115a8)
The file was modifiedChanges (diff)