]> git.ipfire.org Git - thirdparty/zstd.git/commitdiff
Add definition of "log2sup" function 3806/head
authorelasota <ejlasota@gmail.com>
Tue, 31 Oct 2023 15:42:00 +0000 (11:42 -0400)
committerelasota <ejlasota@gmail.com>
Tue, 31 Oct 2023 15:45:10 +0000 (11:45 -0400)
doc/zstd_compression_format.md

index 7b29ccec64873464240b064a7272673eccbbd962..0532a846f45ceacbb7cfe86b24b42e4aa465990c 100644 (file)
@@ -1083,7 +1083,8 @@ It depends on :
   Presuming an `Accuracy_Log` of 8,
   and presuming 100 probabilities points have already been distributed,
   the decoder may read any value from `0` to `256 - 100 + 1 == 157` (inclusive).
-  Therefore, it may read up to `log2sup(157) == 8` bits.
+  Therefore, it may read up to `log2sup(157) == 8` bits, where `log2sup(N)`
+  is the smallest integer `T` that satisfies `(1 << T) > N`.
 
 - Value decoded : small values use 1 less bit :
   __example__ :