mem-cache: Explicitly define threshold of BDI's sub-compressors
authorDaniel R. Carvalho <odanrc@yahoo.com.br>
Sat, 27 Jun 2020 18:51:03 +0000 (20:51 +0200)
committerDaniel Carvalho <odanrc@yahoo.com.br>
Mon, 31 Aug 2020 17:45:43 +0000 (17:45 +0000)
Allow all sub-compressors of BDI to be successful as long as
they are able to compress. Then, BDI's actual size threshold
acts as the cutting point.

This situation arises on any multi compressor; yet, generalizing
this assumption might be too bold.

Change-Id: Iec5057d16d4a7ba5fb573133a30ea10869bd67e0
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/33386
Reviewed-by: Nikos Nikoleris <nikos.nikoleris@arm.com>
Maintainer: Nikos Nikoleris <nikos.nikoleris@arm.com>
Tested-by: kokoro <noreply+kokoro@google.com>
src/mem/cache/compressors/Compressors.py

index 9fa06f210a73058eb716ef6f73fcdf5b87e161df..2497e82e00ae5f817f83bb1fe2d4adec0bdbc8c9 100644 (file)
@@ -148,6 +148,13 @@ class ZeroCompressor(BaseDictionaryCompressor):
 
 class BDI(MultiCompressor):
     encoding_in_tags=True
-    compressors = [ZeroCompressor(), RepeatedQwordsCompressor(),
-        Base64Delta8(), Base64Delta16(), Base64Delta32(), Base32Delta8(),
-        Base32Delta16(), Base16Delta8()]
+    compressors = [
+        ZeroCompressor(size_threshold_percentage=99),
+        RepeatedQwordsCompressor(size_threshold_percentage=99),
+        Base64Delta8(size_threshold_percentage=99),
+        Base64Delta16(size_threshold_percentage=99),
+        Base64Delta32(size_threshold_percentage=99),
+        Base32Delta8(size_threshold_percentage=99),
+        Base32Delta16(size_threshold_percentage=99),
+        Base16Delta8(size_threshold_percentage=99),
+    ]