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

Skip to content
Commit a4638166 authored by Peter Kalauskas's avatar Peter Kalauskas
Browse files

Support coroutine tracing in sysui

Also,

 - Replace CoroutineDispatcher in CoroutinesModule with
   CoroutineContext.

 - Use different CoroutineContext in ConditionalRestarter to avoid
   dependency cycle in CoroutinesModule when referencing
   FeatureFlagsClassic.

Test: adb shell cmd statusbar flag coroutine_tracing off \
  adb shell setprop log.tag.TraceUtils V \
  adb logcat -s 'TraceUtils' \
  1) Ensure no log messages appear when trace isn't being captured, and
  2) Capture perfetto trace, ensure log message appears saying
     "Experimental flag COROUTINE_TRACING is off."

Test: Turn flag on, use new traceCoroutine API on a "@Main
  CoroutineDispatcher", capture perfetto trace, ensure log message says
  "Current CoroutineContext is missing TraceContextElement."

Test: Turn flag on, capture perfetto trace, take a screenshot, ensure
  trace sections for "RequestProcessor#..." show the events on the
  thread the coroutine is executing on, that they stop when the
  coroutine is suspended, and they start again when it's resumed.

Flag: LEGACY COROUTINE_TRACING DISABLED
Test: SystemUITests
Bug: 289353932
Change-Id: I7a5a4b697e93da73b271fb7c3966df8fc7cc5d15
parent b7c89a1b
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment