Add traces around updateZenModeConfig
From field traces, it seems it often requires a lot of time (>190ms during LOCKSCREEN_TO_AOD CUJ) due to lock contention in the binder calls happening inside. Adding a slice to make it more recognizable Bug: 289485377 Test: Record Perfetto trace - check the new slice is visible Change-Id: I77a662d17237246d8c9f2c06b38b5bfa64d5c69d
This commit is contained in:
@@ -28,6 +28,7 @@ import android.database.ContentObserver;
|
||||
import android.net.Uri;
|
||||
import android.os.Handler;
|
||||
import android.os.HandlerExecutor;
|
||||
import android.os.Trace;
|
||||
import android.os.UserHandle;
|
||||
import android.os.UserManager;
|
||||
import android.provider.Settings.Global;
|
||||
@@ -122,7 +123,12 @@ public class ZenModeControllerImpl implements ZenModeController, Dumpable {
|
||||
userTracker.getUserId()) {
|
||||
@Override
|
||||
protected void handleValueChanged(int value, boolean observedChange) {
|
||||
updateZenModeConfig();
|
||||
try {
|
||||
Trace.beginSection("updateZenModeConfig");
|
||||
updateZenModeConfig();
|
||||
} finally {
|
||||
Trace.endSection();
|
||||
}
|
||||
}
|
||||
};
|
||||
mNoMan = (NotificationManager) context.getSystemService(Context.NOTIFICATION_SERVICE);
|
||||
|
||||
Reference in New Issue
Block a user