Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 14d13809 authored by Zimuzo Ezeozue's avatar Zimuzo Ezeozue
Browse files

Support a PerfettoTrace Java API

Added a layer on top of the Perfetto C SDK that allows
creating equivalent 'PerfettoTeHl' structs on the heap.

This makes it possible for Java objects to control the
lifetime of these objects through JNI.

Each PerfettoTeHl struct has an equivalent C++ class allocated
on the heap which is in turn managed by an equivalent Java
class managed by the Java heap.

This design allows us to allocate objects once and re-use them
to serialize the trace event data from Java into the shmem.

The Java layer is responsible for caching the Perfetto Java
objects to avoid GC churn.

Test: atest PerfettoTraceTest
Change-Id: Ibb08e8b6cab7d86ac2c1d57c621c9074a4cb4077
Bug: 303199244
Flag: android.os.perfetto_sdk_tracing_v2
parent 921e6125
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment