Shared library track event: API/ABI to emit data
This commit implements:
* New ABIs to emit events to the data source:
* A low level ABI that allows users to do their own message
serialization.
* A high level ABI that accepts a representation of the data to be
traced and performs serialization in the library.
* The PERFETTO_TE macro (similar to the TRACE_EVENT macro) that can be
used to emit trace events using the high level ABI.
Bug: 237053982
Change-Id: I0ca1a9b03dfa67f7618e27e176f3113eddca871a
Perfetto is a production-grade open-source stack for performance instrumentation and trace analysis. It offers services and libraries and for recording system-level and app-level traces, native + java heap profiling, a library for analyzing traces using SQL and a web-based UI to visualize and explore multi-GB traces.
See https://perfetto.dev/docs or the /docs/ directory for documentation.