heap_graph: per-Java-frame root attribution
Surface, for ROOT_JAVA_FRAME GC roots emitted by ART's perfetto_hprof,
the kernel TID of the thread whose stack frame retains each object.
Combined with the Java thread stack samples ART now emits at heap-
dump time, this lets a consumer navigate from a heap dominator
straight to the holding thread's call stack with a single
trace_processor join.
Wire (heap_graph.proto):
HeapGraph.frame_roots: repeated HeapGraphFrameRoot
HeapGraphFrameRoot { object_id, thread_id (kernel TID) }
trace_processor:
* New nullable column heap_graph_object.root_thread_tid populated
from HeapGraphFrameRoot at FinalizeProfile.
* Stdlib helper macro propagates root_thread_tid through to
_heap_graph_dominator_class_tree.
* Public view heap_graph_object exposes root_thread_tid.
UI (dev.perfetto.HeapProfile):
* Dominator flamegraph tooltip line 'Held By Thread:
<thread_name> (tid <N>)' surfaced only for ROOT_JAVA_FRAME nodes.
Resolved via LEFT JOIN thread on the existing thread.tid.
Change-Id: I8568b424835972b3e732543ae8325a54af85f8ea
Perfetto is an open-source suite of SDKs, daemons and tools which use tracing to help developers understand the behaviour of complex systems and root-cause functional and performance issues on client and embedded systems.
It is a production-grade tool that is the default tracing system for the Android operating system and the Chromium browser.
Perfetto is not a single tool, but a collection of components that work together:
Perfetto was designed to be a versatile and powerful tracing system for a wide range of use cases.
ftrace, allowing you to visualize scheduling, syscalls, interrupts, and custom kernel tracepoints on a timeline.chrome://tracing. Use it to debug and root-cause issues in the browser, V8, and Blink.We‘ve designed our documentation to guide you to the right information as quickly as possible, whether you’re a newcomer to performance analysis or an experienced developer.
New to tracing? If you're unfamiliar with concepts like tracing and profiling, start here:
Ready to dive in? Our “Getting Started” guide is the main entry point for all users. It will help you find the right tutorials and documentation for your specific needs:
Want the full overview? For a comprehensive look at what Perfetto is, why it's useful, and who uses it, see our main documentation page:
For users interested in the Debian distribution of Perfetto, the official source of truth and packaging efforts are maintained at Debian Perfetto Salsa Repository
Have questions? Need help?
We follow Google's Open Source Community Guidelines.