[DO NOT MERGE] Improve signal catching and native stack dumps.
This works around the problem with abort(3) (and friends) on glibc,
and improves our ability to catch SIGSEGVs from the main thread, and
slightly improves our behavior if multiple threads are dying at once.
I think any remaining flakiness is only in this last case, and I'm
not sure whether we can actually improve that any further.
(cherry picked from commit dcaaea9d30f39622d0b1d9bbb68911173621e54b)
2 files changed