Introduce LongMethodTracer: signal-based method tracing utility
Adds a new utility (LongMethodTracer) to trigger method tracing in native processes via signal, as part of the pre-ANR tracing mechanism. - Adds LongMethodTracer class in Java, providing APIs to trigger tracing for one or multiple processes. - Implements JNI bindings for LongMethodTracer, handling signal delivery using sigqueue with packed payloads. - Introduces a type-tagging convention in sigval to differentiate tracing requests (LONG_METHOD_TRACING_TYPE_ID). This utility abstracts the signal-based tracing trigger, enabling lightweight integration for pre-ANR diagnostics. Test: ran multiple scenarios and verified signal delivery and tracing manually Bug: 413119509 Flag: com.android.server.utils.long_method_trace Design Document: go/long-method-tracing-for-anrs Change-Id: I545e2724cec3db5bed1fc884700ac2338e1ccec9
Loading
Please register or sign in to comment