Merge "Invoke rss_hwm_reset binary"

This commit is contained in:
Rafal Slawik
2018-12-17 10:10:16 +00:00
committed by Android (Google) Code Review
2 changed files with 5 additions and 1 deletions

View File

@@ -2627,6 +2627,8 @@ message NativeProcessMemoryState {
*
* Pulled from StatsCompanionService for all managed processes (from ActivityManagerServie)
* and for selected native processes.
*
* Pulling this atom resets high-water mark counters for all processes.
*/
message ProcessMemoryHighWaterMark {
// The uid if available. -1 means not available.

View File

@@ -74,6 +74,7 @@ import android.os.StatsDimensionsValue;
import android.os.StatsLogEventWrapper;
import android.os.SynchronousResultReceiver;
import android.os.SystemClock;
import android.os.SystemProperties;
import android.os.Temperature;
import android.os.UserHandle;
import android.os.UserManager;
@@ -1140,7 +1141,8 @@ public class StatsCompanionService extends IStatsCompanionService.Stub {
e.writeLong(rssHighWaterMarkInBytes);
pulledData.add(e);
}
// TODO(b/119598534): Reset HWM counters here.
// Invoke rss_hwm_reset binary to reset RSS HWM counters for all processes.
SystemProperties.set("sys.rss_hwm_reset.on", "1");
}
private void pullBinderCallsStats(