summaryrefslogtreecommitdiff
path: root/service
diff options
context:
space:
mode:
authormukesh agrawal <quiche@google.com>2016-06-22 17:13:10 -0700
committerMukesh Agrawal <quiche@google.com>2016-06-28 22:43:47 +0000
commit1480044b958c1ee30ad1644705115b87ac8e1d6f (patch)
tree83f8af8e125a62cf8e4e47c68557cbe82be72b4e /service
parent450fee26a21eb56d536df147d3e88d3549f807c0 (diff)
WifiLogger: speed up compression
Some rough benchmarking suggests that using BEST_COMPRESSION may cause us to take 4 seconds to service a dump() request. The same benchmarking indicates that using BEST_SPEED will be about 10x as fast, and yield output that's only 5% larger. Switch to BEST_SPEED, to avoid slowing down bug report generation. BUG=28986501 TEST=manual Manual test: - Enable Wi-Fi Verbose Logging $ adb bugreport foo.zip - verify that foo.zip contains base-64 encoded ringbuffer dumps Change-Id: I0eac83def5cf393a6babdd481079086ea11a5a96 (cherry picked from commit 9a312a13ba34712f3de7f4d0c8d04ff695a41cae)
Diffstat (limited to 'service')
-rw-r--r--service/java/com/android/server/wifi/WifiLogger.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/service/java/com/android/server/wifi/WifiLogger.java b/service/java/com/android/server/wifi/WifiLogger.java
index 4251df457..093d86e36 100644
--- a/service/java/com/android/server/wifi/WifiLogger.java
+++ b/service/java/com/android/server/wifi/WifiLogger.java
@@ -536,7 +536,7 @@ class WifiLogger extends BaseWifiLogger {
String result;
//compress
Deflater compressor = new Deflater();
- compressor.setLevel(Deflater.BEST_COMPRESSION);
+ compressor.setLevel(Deflater.BEST_SPEED);
compressor.setInput(input);
compressor.finish();
ByteArrayOutputStream bos = new ByteArrayOutputStream(input.length);