]> git.ipfire.org Git - thirdparty/zstd.git/commitdiff
Mask Off Unused Functions When ZSTD_FORCE_DECOMPRESS_SEQUENCES_LONG 1420/head
authorW. Felix Handte <w@felixhandte.com>
Thu, 20 Dec 2018 20:20:34 +0000 (12:20 -0800)
committerW. Felix Handte <w@felixhandte.com>
Thu, 20 Dec 2018 20:20:34 +0000 (12:20 -0800)
lib/decompress/zstd_decompress_block.c

index d37c63b23914e53214cd5f744478f5e4573b693d..a4b6c4c1a2d4391e08272a217046f23235a05c28 100644 (file)
@@ -810,6 +810,7 @@ ZSTD_updateFseState(ZSTD_fseState* DStatePtr, BIT_DStream_t* bitD)
 
 typedef enum { ZSTD_lo_isRegularOffset, ZSTD_lo_isLongOffset=1 } ZSTD_longOffset_e;
 
+#ifndef ZSTD_FORCE_DECOMPRESS_SEQUENCES_LONG
 FORCE_INLINE_TEMPLATE seq_t
 ZSTD_decodeSequence(seqState_t* seqState, const ZSTD_longOffset_e longOffsets)
 {
@@ -949,6 +950,7 @@ ZSTD_decompressSequences_default(ZSTD_DCtx* dctx,
 {
     return ZSTD_decompressSequences_body(dctx, dst, maxDstSize, seqStart, seqSize, nbSeq, isLongOffset);
 }
+#endif /* ZSTD_FORCE_DECOMPRESS_SEQUENCES_LONG */
 
 
 
@@ -1123,6 +1125,7 @@ ZSTD_decompressSequencesLong_default(ZSTD_DCtx* dctx,
 
 #if DYNAMIC_BMI2
 
+#ifndef ZSTD_FORCE_DECOMPRESS_SEQUENCES_LONG
 static TARGET_ATTRIBUTE("bmi2") size_t
 ZSTD_decompressSequences_bmi2(ZSTD_DCtx* dctx,
                                  void* dst, size_t maxDstSize,
@@ -1131,6 +1134,7 @@ ZSTD_decompressSequences_bmi2(ZSTD_DCtx* dctx,
 {
     return ZSTD_decompressSequences_body(dctx, dst, maxDstSize, seqStart, seqSize, nbSeq, isLongOffset);
 }
+#endif /* ZSTD_FORCE_DECOMPRESS_SEQUENCES_LONG */
 
 #ifndef ZSTD_FORCE_DECOMPRESS_SEQUENCES_SHORT
 static TARGET_ATTRIBUTE("bmi2") size_t
@@ -1151,6 +1155,7 @@ typedef size_t (*ZSTD_decompressSequences_t)(
                             const void* seqStart, size_t seqSize, int nbSeq,
                             const ZSTD_longOffset_e isLongOffset);
 
+#ifndef ZSTD_FORCE_DECOMPRESS_SEQUENCES_LONG
 static size_t
 ZSTD_decompressSequences(ZSTD_DCtx* dctx, void* dst, size_t maxDstSize,
                    const void* seqStart, size_t seqSize, int nbSeq,
@@ -1164,6 +1169,7 @@ ZSTD_decompressSequences(ZSTD_DCtx* dctx, void* dst, size_t maxDstSize,
 #endif
   return ZSTD_decompressSequences_default(dctx, dst, maxDstSize, seqStart, seqSize, nbSeq, isLongOffset);
 }
+#endif /* ZSTD_FORCE_DECOMPRESS_SEQUENCES_LONG */
 
 
 #ifndef ZSTD_FORCE_DECOMPRESS_SEQUENCES_SHORT