summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorShih-Hsin Li <seasonl@nvidia.com>2021-10-12 11:15:46 -0700
committerterrencew <terrencew@nvidia.com>2021-10-13 16:56:57 +0800
commitcfd414517e1bf9b0a5914bcbd627fe28c8f0b87f (patch)
tree59e3e5c31a9d002f2d669e3a991c09a4d98de8b2
parente0b6a6ee3b816ae05e3ef65ad58ea597795c53c7 (diff)
downloadcts-cfd414517e1bf9b0a5914bcbd627fe28c8f0b87f.tar.gz
BitmapTest: Increase memory usage warmup loops
Debug.MemoryInfo.getTotalPss() is collecting info from /proc/pid/smaps. Initially after memory is allocated, the amount of mappings that is resident in memory(RSS, PSS) can be way smaller than the size of the allocation. If resident mapping is not catching up during warmup, increase in PSS will be treated as memory leak during test run, even though there's no new memory allocation. This change increase warmup loops to give resident mapping more time to reach steady state. Change-Id: Iee4046cfbe35892cabd9f80050778c68fa4d123f
-rw-r--r--tests/tests/graphics/src/android/graphics/cts/BitmapTest.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/tests/graphics/src/android/graphics/cts/BitmapTest.java b/tests/tests/graphics/src/android/graphics/cts/BitmapTest.java
index d8fad9348fb..25e8882fee2 100644
--- a/tests/tests/graphics/src/android/graphics/cts/BitmapTest.java
+++ b/tests/tests/graphics/src/android/graphics/cts/BitmapTest.java
@@ -2162,7 +2162,7 @@ public class BitmapTest {
Debug.MemoryInfo meminfoEnd = new Debug.MemoryInfo();
int fdCount = -1;
// Do a warmup to reach steady-state memory usage
- for (int i = 0; i < 50; i++) {
+ for (int i = 0; i < 100; i++) {
test.run();
}
runGcAndFinalizersSync();