Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ab6a254f authored by Jing Ji's avatar Jing Ji
Browse files

Move the persistent property set to IoThread

The persistent property set caused a ~5.61ms regression in
the system_server SuccessiveBootTest. Moving it to IoThread.

Bug: 148098870
Test: atest google/perf/boottime/boottime-test
Change-Id: I737a6c5390d292b313f4436c83ec27a546c3cf0b
parent 3dd4c345
Loading
Loading
Loading
Loading
+6 −4
Original line number Original line Diff line number Diff line
@@ -189,12 +189,14 @@ public final class AppExitInfoTracker {
    }
    }


    void onSystemReady() {
    void onSystemReady() {
        registerForUserRemoval();
        registerForPackageRemoval();
        IoThread.getHandler().post(() -> {
            // Read the sysprop set by lmkd and set this to persist so app could read it.
            // Read the sysprop set by lmkd and set this to persist so app could read it.
            SystemProperties.set("persist.sys.lmk.reportkills",
            SystemProperties.set("persist.sys.lmk.reportkills",
                    Boolean.toString(SystemProperties.getBoolean("sys.lmk.reportkills", false)));
                    Boolean.toString(SystemProperties.getBoolean("sys.lmk.reportkills", false)));
        registerForUserRemoval();
            loadExistingProcessExitInfo();
        registerForPackageRemoval();
        });
        IoThread.getHandler().post(this::loadExistingProcessExitInfo);
    }
    }


    @GuardedBy("mService")
    @GuardedBy("mService")