Only collect classes for jank perceptible processes

The goal is to not bloat the profile with classes that will
not improve jank perceptible startup latency. This will have
the benefit of lowering the memory footprint of apps.

If the process starts in a non jank perceptible state but later
moves to a jank perceptible state during the startup window,
then treat this as a jank perceptible startup. In this example
we will add some non jank perceptible classes to the profile
but we will also add the jank perceptible ones.

Bug: 485143995
Flag: com.android.art.rw.flags.skip_background_classes_in_profiles
Change-Id: I994ab5c8679b6b978aac43f27c5bf46d7ed0bb45
3 files changed