Home
last modified time | relevance | path

Searched refs:matchLength (Results 1 – 12 of 12) sorted by relevance

/linux-5.19.10/lib/zstd/compress/
Dzstd_lazy.c98 …size_t matchLength = MIN(commonLengthSmaller, commonLengthLarger); /* guaranteed minimum nb of c… in ZSTD_insertDUBT1() local
105 || (matchIndex+matchLength >= dictLimit) /* both in current segment*/ in ZSTD_insertDUBT1()
108 || (matchIndex+matchLength >= dictLimit)) ? in ZSTD_insertDUBT1()
110 …assert( (matchIndex+matchLength >= dictLimit) /* might be wrong if extDict is incorrectly set to… in ZSTD_insertDUBT1()
113 matchLength += ZSTD_count(ip+matchLength, match+matchLength, iend); in ZSTD_insertDUBT1()
116matchLength += ZSTD_count_2segments(ip+matchLength, match+matchLength, iend, dictEnd, prefixStart); in ZSTD_insertDUBT1()
117 if (matchIndex+matchLength >= dictLimit) in ZSTD_insertDUBT1()
122 curr, matchIndex, (U32)matchLength); in ZSTD_insertDUBT1()
124 if (ip+matchLength == iend) { /* equal : no way to know if inf or sup */ in ZSTD_insertDUBT1()
128 if (match[matchLength] < ip[matchLength]) { /* necessarily within buffer */ in ZSTD_insertDUBT1()
[all …]
Dzstd_opt.c270 U32 const matchLength, in ZSTD_getMatchPrice() argument
276 U32 const mlBase = matchLength - MINMATCH; in ZSTD_getMatchPrice()
277 assert(matchLength >= MINMATCH); in ZSTD_getMatchPrice()
294 DEBUGLOG(8, "ZSTD_getMatchPrice(ml:%u) = %u", matchLength, price); in ZSTD_getMatchPrice()
302 U32 offsetCode, U32 matchLength) in ZSTD_updateStats() argument
326 { U32 const mlBase = matchLength - MINMATCH; in ZSTD_updateStats()
425 …size_t matchLength = MIN(commonLengthSmaller, commonLengthLarger); /* guaranteed minimum nb of c… in ZSTD_insertBt1() local
449 if (!extDict || (matchIndex+matchLength >= dictLimit)) { in ZSTD_insertBt1()
450 assert(matchIndex+matchLength >= dictLimit); /* might be wrong if actually extDict */ in ZSTD_insertBt1()
452 matchLength += ZSTD_count(ip+matchLength, match+matchLength, iend); in ZSTD_insertBt1()
[all …]
Dzstd_ldm.c173 size_t matchLength = 0; in ZSTD_ldm_countBackwardsMatch() local
177 matchLength++; in ZSTD_ldm_countBackwardsMatch()
179 return matchLength; in ZSTD_ldm_countBackwardsMatch()
192 size_t matchLength = ZSTD_ldm_countBackwardsMatch(pIn, pAnchor, pMatch, pMatchBase); in ZSTD_ldm_countBackwardsMatch_2segments() local
193 if (pMatch - matchLength != pMatchBase || pMatchBase == pExtDictStart) { in ZSTD_ldm_countBackwardsMatch_2segments()
195 return matchLength; in ZSTD_ldm_countBackwardsMatch_2segments()
197 …ountBackwardsMatch_2segments: found 2-parts backwards match (length in prefix==%zu)", matchLength); in ZSTD_ldm_countBackwardsMatch_2segments()
198matchLength += ZSTD_ldm_countBackwardsMatch(pIn - matchLength, pAnchor, pExtDictEnd, pExtDictStart… in ZSTD_ldm_countBackwardsMatch_2segments()
199 DEBUGLOG(7, "final backwards match length = %zu", matchLength); in ZSTD_ldm_countBackwardsMatch_2segments()
200 return matchLength; in ZSTD_ldm_countBackwardsMatch_2segments()
[all …]
Dzstd_compress_internal.h86 U32 matchLength; /* Raw length of match */ member
553 seqStorePtr->sequences[0].matchLength = (U16)mlBase; in ZSTD_storeSeq()
645 size_t const matchLength = ZSTD_count(ip, match, vEnd); in ZSTD_count_2segments() local
646 if (match + matchLength != mEnd) return matchLength; in ZSTD_count_2segments()
647 DEBUGLOG(7, "ZSTD_count_2segments: found a 2-parts match (current length==%zu)", matchLength); in ZSTD_count_2segments()
650 DEBUGLOG(7, "next byte : ip==%02X, istart==%02X", ip[matchLength], *iStart); in ZSTD_count_2segments()
651 DEBUGLOG(7, "final match length = %zu", matchLength + ZSTD_count(ip+matchLength, iStart, iEnd)); in ZSTD_count_2segments()
652 return matchLength + ZSTD_count(ip+matchLength, iStart, iEnd); in ZSTD_count_2segments()
Dzstd_compress.c2075 U32 const mlv = sequences[u].matchLength; in ZSTD_seqToCodes()
2488 outSeqs[i].matchLength = seqStoreSeqs[i].matchLength + MINMATCH; in ZSTD_copyBlockSequences()
2495 outSeqs[i].matchLength += 0x10000; in ZSTD_copyBlockSequences()
2527 outSeqs[i].matchLength = outSeqs[i].offset = outSeqs[i].rep = 0; in ZSTD_copyBlockSequences()
2556 if (sequences[in].offset == 0 && sequences[in].matchLength == 0) { in ZSTD_mergeBlockDelimiters()
4440 static size_t ZSTD_validateSequence(U32 offCode, U32 matchLength, in ZSTD_validateSequence() argument
4451 RETURN_ERROR_IF(matchLength < minMatch, corruption_detected, "Matchlength too small"); in ZSTD_validateSequence()
4488 U32 matchLength; in ZSTD_copySequencesToSeqStoreExplicitBlockDelim() local
4500 for (; (inSeqs[idx].matchLength != 0 || inSeqs[idx].offset != 0) && idx < inSeqsSize; ++idx) { in ZSTD_copySequencesToSeqStoreExplicitBlockDelim()
4502 matchLength = inSeqs[idx].matchLength; in ZSTD_copySequencesToSeqStoreExplicitBlockDelim()
[all …]
Dzstd_compress_sequences.c313 BIT_addBits(&blockStream, sequences[nbSeq-1].matchLength, ML_bits[mlCodeTable[nbSeq-1]]); in ZSTD_encodeSequences_body()
339 (unsigned)sequences[n].matchLength + MINMATCH, in ZSTD_encodeSequences_body()
351 BIT_addBits(&blockStream, sequences[n].matchLength, mlBits); in ZSTD_encodeSequences_body()
Dzstd_compress_superblock.c419 matchLengthSum += seqLen.matchLength; in ZSTD_seqDecompressedSize()
/linux-5.19.10/lib/zstd/common/
Dzstd_internal.h336 U16 matchLength; member
360 U32 matchLength; member
371 seqLen.matchLength = seq->matchLength + MINMATCH; in ZSTD_getSequenceLength()
377 seqLen.matchLength += 0xFFFF; in ZSTD_getSequenceLength()
/linux-5.19.10/lib/zstd/decompress/
Dzstd_decompress_block.c659 size_t matchLength; member
771 size_t const sequenceLength = sequence.litLength + sequence.matchLength; in ZSTD_execSequenceEnd()
792 if (match + sequence.matchLength <= dictEnd) { in ZSTD_execSequenceEnd()
793 ZSTD_memmove(oLitEnd, match, sequence.matchLength); in ZSTD_execSequenceEnd()
800 sequence.matchLength -= length1; in ZSTD_execSequenceEnd()
803 ZSTD_safecopy(op, oend_w, match, sequence.matchLength, ZSTD_overlap_src_before_dst); in ZSTD_execSequenceEnd()
814 size_t const sequenceLength = sequence.litLength + sequence.matchLength; in ZSTD_execSequence()
858 if (match + sequence.matchLength <= dictEnd) { in ZSTD_execSequence()
859 ZSTD_memmove(oLitEnd, match, sequence.matchLength); in ZSTD_execSequence()
866 sequence.matchLength -= length1; in ZSTD_execSequence()
[all …]
/linux-5.19.10/lib/lz4/
Dlz4_compress.c641 size_t matchLength = LZ4_count(ip + MINMATCH, in LZ4_compress_destSize_generic() local
644 if (op + ((matchLength + 240)/255) > oMaxMatch) { in LZ4_compress_destSize_generic()
646 matchLength = (15 - 1) + (oMaxMatch - op) * 255; in LZ4_compress_destSize_generic()
648 ip += MINMATCH + matchLength; in LZ4_compress_destSize_generic()
650 if (matchLength >= ML_MASK) { in LZ4_compress_destSize_generic()
652 matchLength -= ML_MASK; in LZ4_compress_destSize_generic()
653 while (matchLength >= 255) { in LZ4_compress_destSize_generic()
654 matchLength -= 255; in LZ4_compress_destSize_generic()
657 *op++ = (BYTE)matchLength; in LZ4_compress_destSize_generic()
659 *token += (BYTE)(matchLength); in LZ4_compress_destSize_generic()
Dlz4hc_compress.c266 int matchLength, in LZ4HC_encodeSequence() argument
304 length = (int)(matchLength - MINMATCH); in LZ4HC_encodeSequence()
332 *ip += matchLength; in LZ4HC_encodeSequence()
/linux-5.19.10/include/linux/
Dzstd_lib.h1129 unsigned int matchLength; /* Match length of the sequence. */ member