]> git.ipfire.org Git - thirdparty/zstd.git/commitdiff
Remove Chain Limit on Hash Cache Entries; Slightly Improve Compression
authorW. Felix Handte <w@felixhandte.com>
Thu, 20 Aug 2020 21:17:10 +0000 (17:17 -0400)
committerW. Felix Handte <w@felixhandte.com>
Thu, 10 Sep 2020 22:51:52 +0000 (18:51 -0400)
Entries in the hashTable chain cache aren't subject to the same aliasing that
the circular chain table is subject to. As such, we don't need to stop when we
cross the chain limit. We can delve deeper. :)

lib/compress/zstd_lazy.c

index d393984014e2a0f17d39e7fcb4f59e6445da9f30..684e7e56ea0b8047dce28dbc8dd9accd1c98f2c0 100644 (file)
@@ -611,10 +611,6 @@ size_t ZSTD_HcFindBestMatch_generic (
                     return ml;
                 }
             }
-
-            if (matchIndex <= ddsMinChain) {
-                return ml;
-            }
         }
 
         for ( ; (ddsAttempt < nbAttempts) & (matchIndex >= ddsMinChain); ddsAttempt++) {