julia
julia copied to clipboard
Add informational note to user-signalled `SIGSEGV`
If we hit a segfault from a user-triggered SIGSEGV, that usually means that someone has tampered with our signal handlers (as in https://github.com/JuliaInterop/Clang.jl/pull/549)
Prints as:
julia> Threads.@threads for i in 1:1000; zeros(1024, 1024) .+ zeros(1024, 1024); end
[29561] signal 11 (-6): Segmentation fault
signal came from user-land, signal handlers may be mis-configured.
in expression starting at REPL[3]:1
This will not help if the signal handler was dropped on the floor or intercepted by another application without forwarding, but it will at least be useful to detect bad signal forwarding from another library.
Oh, maybe this would help with PyCall and PythonCall, there are often segfaults because of multithreaded GC interacting badly with the python process.
I think the goal is to distinguish a raise from a MMU triggered segfault