Merge "Stats: updated the order of service registration" into sc-dev

This commit is contained in:
Vova Sharaienko
2021-04-08 20:16:43 +00:00
committed by Android (Google) Code Review
2 changed files with 16 additions and 9 deletions

View File

@@ -442,15 +442,15 @@ public final class SystemServer implements Dumpable {
private final SystemServerDumper mDumper = new SystemServerDumper();
/**
* The pending WTF to be logged into dropbox.
*/
private static LinkedList<Pair<String, ApplicationErrorReport.CrashInfo>> sPendingWtfs;
/**
* Start the sensor service. This is a blocking call and can take time.
*/
/** Start the IStats services. This is a blocking call and can take time. */
private static native void startIStatsService();
/** Start the sensor service. This is a blocking call and can take time. */
private static native void startSensorService();
/**
@@ -1029,6 +1029,10 @@ public final class SystemServer implements Dumpable {
mSystemServiceManager.startService(PowerStatsService.class);
t.traceEnd();
t.traceBegin("StartIStatsService");
startIStatsService();
t.traceEnd();
// Start MemtrackProxyService before ActivityManager, so that early calls
// to Memtrack::getMemory() don't fail.
t.traceBegin("MemtrackProxyService");