I observed signal 33 crashes recently but couldn't find an explanation about it. The signal is normally applied to system_server process but I couldn't find any detail about why it is being applied or which process applies it. Also, this was never seen in any versions prior to Lollipop. So, what changes were made to the frameworks from Lollipop onwards?
Android from Lollipop and up reserves signal 33 (__SIGRTMIN + 1) for a signal called THREAD_SIGNAL as you can see in https://android.googlesource.com/platform/system/core/+/android-5.0.0_r2/libbacktrace/BacktraceThread.h#34
It applies a signal handler for the purpose of obtaining backtrace information (registers and most importantly the thread stack pointer) of a given thread.
Check https://android.googlesource.com/platform/system/core/+/android-5.0.0_r2/libbacktrace/BacktraceThread.cpp#158 to understand how it set the signal handler and delivers the signal.
Usually debuggerd is the one retrieving the backtrace when a process crashes but there are also wrappers available for any project wanting to retrieve a process backtrace information, for example for dumping the state of a process for profiling purposes. ART is one of this projects.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With