]> git.proxmox.com Git - ceph.git/blame - ceph/src/zstd/lib/common/huf.h
update source to Ceph Pacific 16.2.2
[ceph.git] / ceph / src / zstd / lib / common / huf.h
CommitLineData
7c673cae 1/* ******************************************************************
f67539c2
TL
2 * huff0 huffman codec,
3 * part of Finite State Entropy library
4 * Copyright (c) 2013-2020, Yann Collet, Facebook, Inc.
5 *
6 * You can contact the author at :
7 * - Source repository : https://github.com/Cyan4973/FiniteStateEntropy
8 *
9 * This source code is licensed under both the BSD-style license (found in the
10 * LICENSE file in the root directory of this source tree) and the GPLv2 (found
11 * in the COPYING file in the root directory of this source tree).
12 * You may select, at your option, one of the above-listed licenses.
7c673cae 13****************************************************************** */
7c673cae
FG
14
15#if defined (__cplusplus)
16extern "C" {
17#endif
18
11fdf7f2
TL
19#ifndef HUF_H_298734234
20#define HUF_H_298734234
7c673cae
FG
21
22/* *** Dependencies *** */
23#include <stddef.h> /* size_t */
24
25
11fdf7f2
TL
26/* *** library symbols visibility *** */
27/* Note : when linking with -fvisibility=hidden on gcc, or by default on Visual,
28 * HUF symbols remain "private" (internal symbols for library only).
29 * Set macro FSE_DLL_EXPORT to 1 if you want HUF symbols visible on DLL interface */
30#if defined(FSE_DLL_EXPORT) && (FSE_DLL_EXPORT==1) && defined(__GNUC__) && (__GNUC__ >= 4)
31# define HUF_PUBLIC_API __attribute__ ((visibility ("default")))
32#elif defined(FSE_DLL_EXPORT) && (FSE_DLL_EXPORT==1) /* Visual expected */
33# define HUF_PUBLIC_API __declspec(dllexport)
34#elif defined(FSE_DLL_IMPORT) && (FSE_DLL_IMPORT==1)
35# define HUF_PUBLIC_API __declspec(dllimport) /* not required, just to generate faster code (saves a function pointer load from IAT and an indirect jump) */
36#else
37# define HUF_PUBLIC_API
38#endif
39
40
9f95a23c
TL
41/* ========================== */
42/* *** simple functions *** */
43/* ========================== */
44
45/** HUF_compress() :
46 * Compress content from buffer 'src', of size 'srcSize', into buffer 'dst'.
47 * 'dst' buffer must be already allocated.
48 * Compression runs faster if `dstCapacity` >= HUF_compressBound(srcSize).
49 * `srcSize` must be <= `HUF_BLOCKSIZE_MAX` == 128 KB.
50 * @return : size of compressed data (<= `dstCapacity`).
51 * Special values : if return == 0, srcData is not compressible => Nothing is stored within dst !!!
52 * if HUF_isError(return), compression failed (more details using HUF_getErrorName())
53 */
11fdf7f2
TL
54HUF_PUBLIC_API size_t HUF_compress(void* dst, size_t dstCapacity,
55 const void* src, size_t srcSize);
7c673cae 56
9f95a23c
TL
57/** HUF_decompress() :
58 * Decompress HUF data from buffer 'cSrc', of size 'cSrcSize',
59 * into already allocated buffer 'dst', of minimum size 'dstSize'.
60 * `originalSize` : **must** be the ***exact*** size of original (uncompressed) data.
61 * Note : in contrast with FSE, HUF_decompress can regenerate
62 * RLE (cSrcSize==1) and uncompressed (cSrcSize==dstSize) data,
63 * because it knows size to regenerate (originalSize).
64 * @return : size of regenerated data (== originalSize),
65 * or an error code, which can be tested using HUF_isError()
66 */
11fdf7f2
TL
67HUF_PUBLIC_API size_t HUF_decompress(void* dst, size_t originalSize,
68 const void* cSrc, size_t cSrcSize);
7c673cae
FG
69
70
71/* *** Tool functions *** */
11fdf7f2
TL
72#define HUF_BLOCKSIZE_MAX (128 * 1024) /**< maximum input size for a single block compressed with HUF_compress */
73HUF_PUBLIC_API size_t HUF_compressBound(size_t size); /**< maximum compressed size (worst case) */
7c673cae
FG
74
75/* Error Management */
11fdf7f2
TL
76HUF_PUBLIC_API unsigned HUF_isError(size_t code); /**< tells if a return value is an error code */
77HUF_PUBLIC_API const char* HUF_getErrorName(size_t code); /**< provides error code string (useful for debugging) */
7c673cae
FG
78
79
80/* *** Advanced function *** */
81
82/** HUF_compress2() :
9f95a23c
TL
83 * Same as HUF_compress(), but offers control over `maxSymbolValue` and `tableLog`.
84 * `maxSymbolValue` must be <= HUF_SYMBOLVALUE_MAX .
85 * `tableLog` must be `<= HUF_TABLELOG_MAX` . */
86HUF_PUBLIC_API size_t HUF_compress2 (void* dst, size_t dstCapacity,
87 const void* src, size_t srcSize,
88 unsigned maxSymbolValue, unsigned tableLog);
7c673cae
FG
89
90/** HUF_compress4X_wksp() :
11fdf7f2 91 * Same as HUF_compress2(), but uses externally allocated `workSpace`.
9f95a23c 92 * `workspace` must have minimum alignment of 4, and be at least as large as HUF_WORKSPACE_SIZE */
f67539c2 93#define HUF_WORKSPACE_SIZE ((6 << 10) + 256)
11fdf7f2 94#define HUF_WORKSPACE_SIZE_U32 (HUF_WORKSPACE_SIZE / sizeof(U32))
9f95a23c
TL
95HUF_PUBLIC_API size_t HUF_compress4X_wksp (void* dst, size_t dstCapacity,
96 const void* src, size_t srcSize,
97 unsigned maxSymbolValue, unsigned tableLog,
98 void* workSpace, size_t wkspSize);
7c673cae 99
11fdf7f2 100#endif /* HUF_H_298734234 */
7c673cae 101
11fdf7f2
TL
102/* ******************************************************************
103 * WARNING !!
104 * The following section contains advanced and experimental definitions
9f95a23c 105 * which shall never be used in the context of a dynamic library,
11fdf7f2
TL
106 * because they are not guaranteed to remain stable in the future.
107 * Only consider them in association with static linking.
9f95a23c 108 * *****************************************************************/
11fdf7f2
TL
109#if defined(HUF_STATIC_LINKING_ONLY) && !defined(HUF_H_HUF_STATIC_LINKING_ONLY)
110#define HUF_H_HUF_STATIC_LINKING_ONLY
7c673cae
FG
111
112/* *** Dependencies *** */
113#include "mem.h" /* U32 */
114
115
116/* *** Constants *** */
9f95a23c
TL
117#define HUF_TABLELOG_MAX 12 /* max runtime value of tableLog (due to static allocation); can be modified up to HUF_ABSOLUTEMAX_TABLELOG */
118#define HUF_TABLELOG_DEFAULT 11 /* default tableLog value when none specified */
11fdf7f2
TL
119#define HUF_SYMBOLVALUE_MAX 255
120
9f95a23c 121#define HUF_TABLELOG_ABSOLUTEMAX 15 /* absolute limit of HUF_MAX_TABLELOG. Beyond that value, code does not work */
7c673cae
FG
122#if (HUF_TABLELOG_MAX > HUF_TABLELOG_ABSOLUTEMAX)
123# error "HUF_TABLELOG_MAX is too large !"
124#endif
125
126
127/* ****************************************
128* Static allocation
129******************************************/
130/* HUF buffer bounds */
131#define HUF_CTABLEBOUND 129
11fdf7f2 132#define HUF_BLOCKBOUND(size) (size + (size>>8) + 8) /* only true when incompressible is pre-filtered with fast heuristic */
7c673cae
FG
133#define HUF_COMPRESSBOUND(size) (HUF_CTABLEBOUND + HUF_BLOCKBOUND(size)) /* Macro version, useful for static allocation */
134
135/* static allocation of HUF's Compression Table */
11fdf7f2
TL
136#define HUF_CTABLE_SIZE_U32(maxSymbolValue) ((maxSymbolValue)+1) /* Use tables of U32, for proper alignment */
137#define HUF_CTABLE_SIZE(maxSymbolValue) (HUF_CTABLE_SIZE_U32(maxSymbolValue) * sizeof(U32))
7c673cae 138#define HUF_CREATE_STATIC_CTABLE(name, maxSymbolValue) \
11fdf7f2 139 U32 name##hb[HUF_CTABLE_SIZE_U32(maxSymbolValue)]; \
7c673cae
FG
140 void* name##hv = &(name##hb); \
141 HUF_CElt* name = (HUF_CElt*)(name##hv) /* no final ; */
142
143/* static allocation of HUF's DTable */
144typedef U32 HUF_DTable;
145#define HUF_DTABLE_SIZE(maxTableLog) (1 + (1<<(maxTableLog)))
9f95a23c 146#define HUF_CREATE_STATIC_DTABLEX1(DTable, maxTableLog) \
7c673cae 147 HUF_DTable DTable[HUF_DTABLE_SIZE((maxTableLog)-1)] = { ((U32)((maxTableLog)-1) * 0x01000001) }
9f95a23c 148#define HUF_CREATE_STATIC_DTABLEX2(DTable, maxTableLog) \
7c673cae
FG
149 HUF_DTable DTable[HUF_DTABLE_SIZE(maxTableLog)] = { ((U32)(maxTableLog) * 0x01000001) }
150
151
152/* ****************************************
153* Advanced decompression functions
154******************************************/
9f95a23c
TL
155size_t HUF_decompress4X1 (void* dst, size_t dstSize, const void* cSrc, size_t cSrcSize); /**< single-symbol decoder */
156#ifndef HUF_FORCE_DECOMPRESS_X1
157size_t HUF_decompress4X2 (void* dst, size_t dstSize, const void* cSrc, size_t cSrcSize); /**< double-symbols decoder */
158#endif
7c673cae
FG
159
160size_t HUF_decompress4X_DCtx (HUF_DTable* dctx, void* dst, size_t dstSize, const void* cSrc, size_t cSrcSize); /**< decodes RLE and uncompressed */
161size_t HUF_decompress4X_hufOnly(HUF_DTable* dctx, void* dst, size_t dstSize, const void* cSrc, size_t cSrcSize); /**< considers RLE and uncompressed as errors */
11fdf7f2 162size_t HUF_decompress4X_hufOnly_wksp(HUF_DTable* dctx, void* dst, size_t dstSize, const void* cSrc, size_t cSrcSize, void* workSpace, size_t wkspSize); /**< considers RLE and uncompressed as errors */
9f95a23c
TL
163size_t HUF_decompress4X1_DCtx(HUF_DTable* dctx, void* dst, size_t dstSize, const void* cSrc, size_t cSrcSize); /**< single-symbol decoder */
164size_t HUF_decompress4X1_DCtx_wksp(HUF_DTable* dctx, void* dst, size_t dstSize, const void* cSrc, size_t cSrcSize, void* workSpace, size_t wkspSize); /**< single-symbol decoder */
165#ifndef HUF_FORCE_DECOMPRESS_X1
166size_t HUF_decompress4X2_DCtx(HUF_DTable* dctx, void* dst, size_t dstSize, const void* cSrc, size_t cSrcSize); /**< double-symbols decoder */
167size_t HUF_decompress4X2_DCtx_wksp(HUF_DTable* dctx, void* dst, size_t dstSize, const void* cSrc, size_t cSrcSize, void* workSpace, size_t wkspSize); /**< double-symbols decoder */
168#endif
7c673cae
FG
169
170
171/* ****************************************
9f95a23c
TL
172 * HUF detailed API
173 * ****************************************/
174
175/*! HUF_compress() does the following:
176 * 1. count symbol occurrence from source[] into table count[] using FSE_count() (exposed within "fse.h")
177 * 2. (optional) refine tableLog using HUF_optimalTableLog()
178 * 3. build Huffman table from count using HUF_buildCTable()
179 * 4. save Huffman table to memory buffer using HUF_writeCTable()
180 * 5. encode the data stream using HUF_compress4X_usingCTable()
181 *
182 * The following API allows targeting specific sub-functions for advanced tasks.
183 * For example, it's possible to compress several blocks using the same 'CTable',
184 * or to save and regenerate 'CTable' using external methods.
185 */
7c673cae
FG
186unsigned HUF_optimalTableLog(unsigned maxTableLog, size_t srcSize, unsigned maxSymbolValue);
187typedef struct HUF_CElt_s HUF_CElt; /* incomplete type */
9f95a23c 188size_t HUF_buildCTable (HUF_CElt* CTable, const unsigned* count, unsigned maxSymbolValue, unsigned maxNbBits); /* @return : maxNbBits; CTable and count can overlap. In which case, CTable will overwrite count content */
7c673cae
FG
189size_t HUF_writeCTable (void* dst, size_t maxDstSize, const HUF_CElt* CTable, unsigned maxSymbolValue, unsigned huffLog);
190size_t HUF_compress4X_usingCTable(void* dst, size_t dstSize, const void* src, size_t srcSize, const HUF_CElt* CTable);
f67539c2
TL
191size_t HUF_estimateCompressedSize(const HUF_CElt* CTable, const unsigned* count, unsigned maxSymbolValue);
192int HUF_validateCTable(const HUF_CElt* CTable, const unsigned* count, unsigned maxSymbolValue);
7c673cae 193
11fdf7f2
TL
194typedef enum {
195 HUF_repeat_none, /**< Cannot use the previous table */
196 HUF_repeat_check, /**< Can use the previous table but it must be checked. Note : The previous table must have been constructed by HUF_compress{1, 4}X_repeat */
9f95a23c 197 HUF_repeat_valid /**< Can use the previous table and it is assumed to be valid */
11fdf7f2
TL
198 } HUF_repeat;
199/** HUF_compress4X_repeat() :
9f95a23c
TL
200 * Same as HUF_compress4X_wksp(), but considers using hufTable if *repeat != HUF_repeat_none.
201 * If it uses hufTable it does not modify hufTable or repeat.
202 * If it doesn't, it sets *repeat = HUF_repeat_none, and it sets hufTable to the table used.
203 * If preferRepeat then the old table will always be used if valid. */
204size_t HUF_compress4X_repeat(void* dst, size_t dstSize,
205 const void* src, size_t srcSize,
206 unsigned maxSymbolValue, unsigned tableLog,
207 void* workSpace, size_t wkspSize, /**< `workSpace` must be aligned on 4-bytes boundaries, `wkspSize` must be >= HUF_WORKSPACE_SIZE */
208 HUF_CElt* hufTable, HUF_repeat* repeat, int preferRepeat, int bmi2);
7c673cae
FG
209
210/** HUF_buildCTable_wksp() :
211 * Same as HUF_buildCTable(), but using externally allocated scratch buffer.
9f95a23c 212 * `workSpace` must be aligned on 4-bytes boundaries, and its size must be >= HUF_CTABLE_WORKSPACE_SIZE.
7c673cae 213 */
9f95a23c
TL
214#define HUF_CTABLE_WORKSPACE_SIZE_U32 (2*HUF_SYMBOLVALUE_MAX +1 +1)
215#define HUF_CTABLE_WORKSPACE_SIZE (HUF_CTABLE_WORKSPACE_SIZE_U32 * sizeof(unsigned))
216size_t HUF_buildCTable_wksp (HUF_CElt* tree,
217 const unsigned* count, U32 maxSymbolValue, U32 maxNbBits,
218 void* workSpace, size_t wkspSize);
7c673cae
FG
219
220/*! HUF_readStats() :
9f95a23c
TL
221 * Read compact Huffman tree, saved by HUF_writeCTable().
222 * `huffWeight` is destination buffer.
223 * @return : size read from `src` , or an error Code .
224 * Note : Needed by HUF_readCTable() and HUF_readDTableXn() . */
225size_t HUF_readStats(BYTE* huffWeight, size_t hwSize,
226 U32* rankStats, U32* nbSymbolsPtr, U32* tableLogPtr,
7c673cae
FG
227 const void* src, size_t srcSize);
228
229/** HUF_readCTable() :
9f95a23c 230 * Loading a CTable saved with HUF_writeCTable() */
f67539c2 231size_t HUF_readCTable (HUF_CElt* CTable, unsigned* maxSymbolValuePtr, const void* src, size_t srcSize, unsigned *hasZeroWeights);
7c673cae 232
9f95a23c
TL
233/** HUF_getNbBits() :
234 * Read nbBits from CTable symbolTable, for symbol `symbolValue` presumed <= HUF_SYMBOLVALUE_MAX
235 * Note 1 : is not inlined, as HUF_CElt definition is private
236 * Note 2 : const void* used, so that it can provide a statically allocated table as argument (which uses type U32) */
237U32 HUF_getNbBits(const void* symbolTable, U32 symbolValue);
7c673cae
FG
238
239/*
9f95a23c
TL
240 * HUF_decompress() does the following:
241 * 1. select the decompression algorithm (X1, X2) based on pre-computed heuristics
242 * 2. build Huffman table from save, using HUF_readDTableX?()
243 * 3. decode 1 or 4 segments in parallel using HUF_decompress?X?_usingDTable()
244 */
7c673cae
FG
245
246/** HUF_selectDecoder() :
9f95a23c
TL
247 * Tells which decoder is likely to decode faster,
248 * based on a set of pre-computed metrics.
249 * @return : 0==HUF_decompress4X1, 1==HUF_decompress4X2 .
250 * Assumption : 0 < dstSize <= 128 KB */
7c673cae
FG
251U32 HUF_selectDecoder (size_t dstSize, size_t cSrcSize);
252
9f95a23c
TL
253/**
254 * The minimum workspace size for the `workSpace` used in
255 * HUF_readDTableX1_wksp() and HUF_readDTableX2_wksp().
256 *
257 * The space used depends on HUF_TABLELOG_MAX, ranging from ~1500 bytes when
258 * HUF_TABLE_LOG_MAX=12 to ~1850 bytes when HUF_TABLE_LOG_MAX=15.
259 * Buffer overflow errors may potentially occur if code modifications result in
260 * a required workspace size greater than that specified in the following
261 * macro.
262 */
263#define HUF_DECOMPRESS_WORKSPACE_SIZE (2 << 10)
264#define HUF_DECOMPRESS_WORKSPACE_SIZE_U32 (HUF_DECOMPRESS_WORKSPACE_SIZE / sizeof(U32))
265
266#ifndef HUF_FORCE_DECOMPRESS_X2
267size_t HUF_readDTableX1 (HUF_DTable* DTable, const void* src, size_t srcSize);
268size_t HUF_readDTableX1_wksp (HUF_DTable* DTable, const void* src, size_t srcSize, void* workSpace, size_t wkspSize);
269#endif
270#ifndef HUF_FORCE_DECOMPRESS_X1
7c673cae 271size_t HUF_readDTableX2 (HUF_DTable* DTable, const void* src, size_t srcSize);
11fdf7f2 272size_t HUF_readDTableX2_wksp (HUF_DTable* DTable, const void* src, size_t srcSize, void* workSpace, size_t wkspSize);
9f95a23c 273#endif
7c673cae
FG
274
275size_t HUF_decompress4X_usingDTable(void* dst, size_t maxDstSize, const void* cSrc, size_t cSrcSize, const HUF_DTable* DTable);
9f95a23c
TL
276#ifndef HUF_FORCE_DECOMPRESS_X2
277size_t HUF_decompress4X1_usingDTable(void* dst, size_t maxDstSize, const void* cSrc, size_t cSrcSize, const HUF_DTable* DTable);
278#endif
279#ifndef HUF_FORCE_DECOMPRESS_X1
7c673cae 280size_t HUF_decompress4X2_usingDTable(void* dst, size_t maxDstSize, const void* cSrc, size_t cSrcSize, const HUF_DTable* DTable);
9f95a23c 281#endif
7c673cae
FG
282
283
9f95a23c 284/* ====================== */
7c673cae 285/* single stream variants */
9f95a23c 286/* ====================== */
7c673cae
FG
287
288size_t HUF_compress1X (void* dst, size_t dstSize, const void* src, size_t srcSize, unsigned maxSymbolValue, unsigned tableLog);
11fdf7f2 289size_t HUF_compress1X_wksp (void* dst, size_t dstSize, const void* src, size_t srcSize, unsigned maxSymbolValue, unsigned tableLog, void* workSpace, size_t wkspSize); /**< `workSpace` must be a table of at least HUF_WORKSPACE_SIZE_U32 unsigned */
7c673cae 290size_t HUF_compress1X_usingCTable(void* dst, size_t dstSize, const void* src, size_t srcSize, const HUF_CElt* CTable);
11fdf7f2 291/** HUF_compress1X_repeat() :
9f95a23c
TL
292 * Same as HUF_compress1X_wksp(), but considers using hufTable if *repeat != HUF_repeat_none.
293 * If it uses hufTable it does not modify hufTable or repeat.
294 * If it doesn't, it sets *repeat = HUF_repeat_none, and it sets hufTable to the table used.
295 * If preferRepeat then the old table will always be used if valid. */
296size_t HUF_compress1X_repeat(void* dst, size_t dstSize,
297 const void* src, size_t srcSize,
298 unsigned maxSymbolValue, unsigned tableLog,
299 void* workSpace, size_t wkspSize, /**< `workSpace` must be aligned on 4-bytes boundaries, `wkspSize` must be >= HUF_WORKSPACE_SIZE */
300 HUF_CElt* hufTable, HUF_repeat* repeat, int preferRepeat, int bmi2);
301
302size_t HUF_decompress1X1 (void* dst, size_t dstSize, const void* cSrc, size_t cSrcSize); /* single-symbol decoder */
303#ifndef HUF_FORCE_DECOMPRESS_X1
304size_t HUF_decompress1X2 (void* dst, size_t dstSize, const void* cSrc, size_t cSrcSize); /* double-symbol decoder */
305#endif
7c673cae
FG
306
307size_t HUF_decompress1X_DCtx (HUF_DTable* dctx, void* dst, size_t dstSize, const void* cSrc, size_t cSrcSize);
11fdf7f2 308size_t HUF_decompress1X_DCtx_wksp (HUF_DTable* dctx, void* dst, size_t dstSize, const void* cSrc, size_t cSrcSize, void* workSpace, size_t wkspSize);
9f95a23c
TL
309#ifndef HUF_FORCE_DECOMPRESS_X2
310size_t HUF_decompress1X1_DCtx(HUF_DTable* dctx, void* dst, size_t dstSize, const void* cSrc, size_t cSrcSize); /**< single-symbol decoder */
311size_t HUF_decompress1X1_DCtx_wksp(HUF_DTable* dctx, void* dst, size_t dstSize, const void* cSrc, size_t cSrcSize, void* workSpace, size_t wkspSize); /**< single-symbol decoder */
312#endif
313#ifndef HUF_FORCE_DECOMPRESS_X1
314size_t HUF_decompress1X2_DCtx(HUF_DTable* dctx, void* dst, size_t dstSize, const void* cSrc, size_t cSrcSize); /**< double-symbols decoder */
315size_t HUF_decompress1X2_DCtx_wksp(HUF_DTable* dctx, void* dst, size_t dstSize, const void* cSrc, size_t cSrcSize, void* workSpace, size_t wkspSize); /**< double-symbols decoder */
316#endif
7c673cae
FG
317
318size_t HUF_decompress1X_usingDTable(void* dst, size_t maxDstSize, const void* cSrc, size_t cSrcSize, const HUF_DTable* DTable); /**< automatic selection of sing or double symbol decoder, based on DTable */
9f95a23c
TL
319#ifndef HUF_FORCE_DECOMPRESS_X2
320size_t HUF_decompress1X1_usingDTable(void* dst, size_t maxDstSize, const void* cSrc, size_t cSrcSize, const HUF_DTable* DTable);
321#endif
322#ifndef HUF_FORCE_DECOMPRESS_X1
7c673cae 323size_t HUF_decompress1X2_usingDTable(void* dst, size_t maxDstSize, const void* cSrc, size_t cSrcSize, const HUF_DTable* DTable);
9f95a23c
TL
324#endif
325
326/* BMI2 variants.
327 * If the CPU has BMI2 support, pass bmi2=1, otherwise pass bmi2=0.
328 */
329size_t HUF_decompress1X_usingDTable_bmi2(void* dst, size_t maxDstSize, const void* cSrc, size_t cSrcSize, const HUF_DTable* DTable, int bmi2);
330#ifndef HUF_FORCE_DECOMPRESS_X2
331size_t HUF_decompress1X1_DCtx_wksp_bmi2(HUF_DTable* dctx, void* dst, size_t dstSize, const void* cSrc, size_t cSrcSize, void* workSpace, size_t wkspSize, int bmi2);
332#endif
333size_t HUF_decompress4X_usingDTable_bmi2(void* dst, size_t maxDstSize, const void* cSrc, size_t cSrcSize, const HUF_DTable* DTable, int bmi2);
334size_t HUF_decompress4X_hufOnly_wksp_bmi2(HUF_DTable* dctx, void* dst, size_t dstSize, const void* cSrc, size_t cSrcSize, void* workSpace, size_t wkspSize, int bmi2);
7c673cae
FG
335
336#endif /* HUF_STATIC_LINKING_ONLY */
337
7c673cae
FG
338#if defined (__cplusplus)
339}
340#endif