Assigned
Status Update
Comments
ap...@google.com <ap...@google.com> #2
Project: platform/frameworks/support
Branch: androidx-main
commit 05d1c03a70ab5bea21ff84da44a75bc837b3507c
Author: Chris Craik <ccraik@google.com>
Date: Mon Oct 04 17:51:50 2021
Support dropping page cache without root on API 31/S+
Bug: 200160030
Test: ./gradlew benchmark:benchmark-common:cC benchmark:benchmark-macro:cC
Test: TrivialStartupBenchmark # comparing new vs old way to drop caches on API 31
Relnote: "Support dropping page cache without root on API 31/S+"
Additionally, with this change, failure to drop page cache will throw
on a rooted build, as it may be necessary to root the adb session (run
`adb root`). I noticed this because, when attempting to verify the new
numbers, the old approach was failing on my device.
In the future, we should explore alternative approximations
(e.g. writing/reading large amounts of disk contents to flush the
cache) for older APIs.
Change-Id: Iecfdbd7b712ceaba109c7551c669845db1ff51b7
M benchmark/benchmark-macro/src/main/java/androidx/benchmark/macro/MacrobenchmarkScope.kt
https://android-review.googlesource.com/1844719
Branch: androidx-main
commit 05d1c03a70ab5bea21ff84da44a75bc837b3507c
Author: Chris Craik <ccraik@google.com>
Date: Mon Oct 04 17:51:50 2021
Support dropping page cache without root on API 31/S+
Bug: 200160030
Test: ./gradlew benchmark:benchmark-common:cC benchmark:benchmark-macro:cC
Test: TrivialStartupBenchmark # comparing new vs old way to drop caches on API 31
Relnote: "Support dropping page cache without root on API 31/S+"
Additionally, with this change, failure to drop page cache will throw
on a rooted build, as it may be necessary to root the adb session (run
`adb root`). I noticed this because, when attempting to verify the new
numbers, the old approach was failing on my device.
In the future, we should explore alternative approximations
(e.g. writing/reading large amounts of disk contents to flush the
cache) for older APIs.
Change-Id: Iecfdbd7b712ceaba109c7551c669845db1ff51b7
M benchmark/benchmark-macro/src/main/java/androidx/benchmark/macro/MacrobenchmarkScope.kt
cc...@google.com <cc...@google.com> #3
Punting further backcompat work.
Description
drop_caches doesn't work without root, so starting in S we should use the new b/178647679 )
perf.drop_caches
system property (SeeFor older devices, we should consider workarounds - can try manually flushing the disk cache by reading/writing large amounts of data to disk.