1
0
mirror of https://github.com/facebook/zstd.git synced 2025-03-06 16:56:49 +02:00

Smallish typo fixes in format documentation

This commit is contained in:
Johannes Rudolph 2016-09-09 19:02:40 +02:00 committed by GitHub
parent 2c6779f948
commit 7b0c261623

View File

@ -732,7 +732,7 @@ This size is deducted from `blockSize - literalSectionSize`.
#### `Sequences_Section_Header` #### `Sequences_Section_Header`
Consists in 2 items : Consists of 2 items:
- `Number_of_Sequences` - `Number_of_Sequences`
- Symbol compression modes - Symbol compression modes
@ -873,7 +873,7 @@ and can be translated into an `Offset_Value` using the following formulas :
Offset_Value = (1 << offsetCode) + readNBits(offsetCode); Offset_Value = (1 << offsetCode) + readNBits(offsetCode);
if (Offset_Value > 3) offset = Offset_Value - 3; if (Offset_Value > 3) offset = Offset_Value - 3;
``` ```
It means that maximum `Offset_Value` is `2^(N+1))-1` and it supports back-reference distance up to `2^(N+1))-4` It means that maximum `Offset_Value` is `(2^(N+1))-1` and it supports back-reference distance up to `(2^(N+1))-4`
but is limited by [maximum back-reference distance](#window_descriptor). but is limited by [maximum back-reference distance](#window_descriptor).
`Offset_Value` from 1 to 3 are special : they define "repeat codes", `Offset_Value` from 1 to 3 are special : they define "repeat codes",
@ -894,7 +894,7 @@ If any sequence in the compressed block requires an offset larger than this,
it's not possible to use the default distribution to represent it. it's not possible to use the default distribution to represent it.
``` ```
short offsetCodes_defaultDistribution[53] = short offsetCodes_defaultDistribution[29] =
{ 1, 1, 1, 1, 1, 1, 2, 2, 2, 1, 1, 1, 1, 1, 1, 1, { 1, 1, 1, 1, 1, 1, 2, 2, 2, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1,-1,-1,-1,-1,-1 }; 1, 1, 1, 1, 1, 1, 1, 1,-1,-1,-1,-1,-1 };
``` ```