Commit a2638923 authored by Calin Juravle's avatar Calin Juravle
Browse files

Adjust ProfileSaver strategy

Change to a notification based strategy (instead of polling):
- the JIT notifies the ProfileSaver everytime it attempts a compilation
or generate (in a task) a ProfileInfo object for the method
- once a certain number of hot methods notification are received,
ProfileSaver wakes up the thread to do the analysis
- a wake up does not equal to I/O since the during processing we might
realized that's actually not enough new data.
- ProfileSaver throtles the request and ensures it doesn't do the
processing more often than kMinSavePeriodNs.

The new strategy avoids waking the thread unnecessary during extended
idle periods when we don't JIT.

Bug: 26815940

(cherry picked from commit 5fbb0fe0)

Change-Id: Ifbac3a53c025e00a3faab6784bbfa679c6b42acb
parent 31e61f1d
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment