mirror of
https://github.com/facebook/zstd.git
synced 2025-03-06 16:56:49 +02:00
build macro ZSTD_DECODER_INTERNAL_BUFFER
just to make the topic more accessible for potential users.
This commit is contained in:
parent
6a7ede3dfc
commit
02be2a830f
@ -155,11 +155,11 @@ The file structure is designed to make this selection manually achievable for an
|
||||
- The build macro `ZSTD_NO_INTRINSICS` can be defined to disable all explicit intrinsics.
|
||||
Compiler builtins are still used.
|
||||
|
||||
- The build macro `ZSTD_LITBUFFEREXTRASIZE` can be set to control the amount of extra memory used
|
||||
during decompression to store literals. This defaults to 64kB. Reducing it can reduce the
|
||||
memory footprint required for decompression by increasing the portion of the literal buffer that
|
||||
is stored in the unwritten portion of the dst buffer, at the cost of performance impact for
|
||||
decompression.
|
||||
- The build macro `ZSTD_DECODER_INTERNAL_BUFFER` can be set to control
|
||||
the amount of extra memory used during decompression to store literals.
|
||||
This defaults to 64kB. Reducing this value reduces the memory footprint of
|
||||
`ZSTD_DCtx` decompression contexts,
|
||||
but might also result in a small decompression speed cost.
|
||||
|
||||
|
||||
#### Windows : using MinGW+MSYS to create DLL
|
||||
|
@ -106,10 +106,15 @@ typedef struct {
|
||||
size_t ddictPtrCount;
|
||||
} ZSTD_DDictHashSet;
|
||||
|
||||
#ifndef ZSTD_LITBUFFEREXTRASIZE
|
||||
#define ZSTD_LITBUFFEREXTRASIZE (1 << 16) /* extra buffer reduces amount of dst required to store litBuffer */
|
||||
#ifndef ZSTD_DECODER_INTERNAL_BUFFER
|
||||
# define ZSTD_DECODER_INTERNAL_BUFFER (1 << 16)
|
||||
#endif
|
||||
|
||||
#define ZSTD_LBMAX (128 << 10)
|
||||
|
||||
/* extra buffer, compensates amount of dst required to store litBuffer */
|
||||
#define ZSTD_LITBUFFEREXTRASIZE MIN(ZSTD_DECODER_INTERNAL_BUFFER, ZSTD_LBMAX)
|
||||
|
||||
typedef enum {
|
||||
ZSTD_not_in_dst = 0, /* Stored entirely within litExtraBuffer */
|
||||
ZSTD_in_dst = 1, /* Stored entirely within dst (in memory after current output write) */
|
||||
|
Loading…
x
Reference in New Issue
Block a user