Commit bd43da7e authored by Carmen Jackson's avatar Carmen Jackson
Browse files

Only query Perfetto state at boot when necessary.

When we update the tracing state, we check both:
- Whether the user has enabled tracing
- Whether a trace is currently in progress

And then update the two to match.

In order to check whether a trace is currently in progress, we need to
start the Perfetto process and query it. We know that Perfetto will not
automatically start a Traceur trace at boot by itself, so we can skip
this query at boot time and assume it'll return false.

Since the system is under so much load at boot, this query was
occasionally causing Traceur to ANR, so it's worthwhile to skip it when
possible.

Bug: 135610481
Test: atest TraceurUiTests & manual testing
Change-Id: Ie29ab6cc7f2f993bd6a0f33c44dc99410ccf95e8
parent 1480c852
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment