reduce workload for random update into half (512MB to 256MB) as it takes too long in some devices.
bug: 8585172
Change-Id: I5b648a6e2c852daef4ffe78f7e594b840c598ba4
diff --git a/suite/pts/deviceTests/filesystemperf/src/com/android/pts/filesystemperf/AlmostFullTest.java b/suite/pts/deviceTests/filesystemperf/src/com/android/pts/filesystemperf/AlmostFullTest.java
index 75b443d..b43c80d 100644
--- a/suite/pts/deviceTests/filesystemperf/src/com/android/pts/filesystemperf/AlmostFullTest.java
+++ b/suite/pts/deviceTests/filesystemperf/src/com/android/pts/filesystemperf/AlmostFullTest.java
@@ -114,7 +114,7 @@
@TimeoutReq(minutes = 60)
public void testRandomUpdate() throws Exception {
final int BUFFER_SIZE = 4 * 1024;
- final long fileSize = 400L * 1024L * 1024L;
+ final long fileSize = 256L * 1024L * 1024L;
FileUtil.doRandomWriteTest(getContext(), DIR_RANDOM_WR, getReportLog(), fileSize,
BUFFER_SIZE);
}
diff --git a/suite/pts/deviceTests/filesystemperf/src/com/android/pts/filesystemperf/FileUtil.java b/suite/pts/deviceTests/filesystemperf/src/com/android/pts/filesystemperf/FileUtil.java
index 25dd014..2119ee5 100644
--- a/suite/pts/deviceTests/filesystemperf/src/com/android/pts/filesystemperf/FileUtil.java
+++ b/suite/pts/deviceTests/filesystemperf/src/com/android/pts/filesystemperf/FileUtil.java
@@ -331,7 +331,7 @@
~(bufferSize - 1);
}
final int runsInOneGo = 16;
- final int writesInOneMeasure = totalWriteCount / runsInOneGo; // 32MB at a time
+ final int writesInOneMeasure = totalWriteCount / runsInOneGo;
final RandomAccessFile randomFile = new RandomAccessFile(file, "rwd"); // force O_SYNC
double[] rdAmount = new double[runsInOneGo];
diff --git a/suite/pts/deviceTests/filesystemperf/src/com/android/pts/filesystemperf/RandomRWTest.java b/suite/pts/deviceTests/filesystemperf/src/com/android/pts/filesystemperf/RandomRWTest.java
index 0ac096f..6b6086b 100644
--- a/suite/pts/deviceTests/filesystemperf/src/com/android/pts/filesystemperf/RandomRWTest.java
+++ b/suite/pts/deviceTests/filesystemperf/src/com/android/pts/filesystemperf/RandomRWTest.java
@@ -43,11 +43,11 @@
READ_BUFFER_SIZE);
}
- // It is taking too long in tuna, and thus cannot run multiple times
+ // It is taking too long in some device, and thus cannot run multiple times
@TimeoutReq(minutes = 60)
public void testRandomUpdate() throws Exception {
final int WRITE_BUFFER_SIZE = 4 * 1024;
- final long fileSize = 512 * 1024 * 1024;
+ final long fileSize = 256 * 1024 * 1024;
FileUtil.doRandomWriteTest(getContext(), DIR_RANDOM_WR, getReportLog(), fileSize,
WRITE_BUFFER_SIZE);
}