Lines Matching refs:seqStore

208 const seqStore_t* ZSTD_getSeqStore(const ZSTD_CCtx* ctx) { return &(ctx->seqStore); }
1860 zc->seqStore.litStart = ZSTD_cwksp_reserve_buffer(ws, blockSize + WILDCOPY_OVERLENGTH);
1861 zc->seqStore.maxNbLit = blockSize;
1882 zc->seqStore.maxNbSeq = maxNbSeq;
1883 zc->seqStore.llCode = ZSTD_cwksp_reserve_buffer(ws, maxNbSeq * sizeof(BYTE));
1884 zc->seqStore.mlCode = ZSTD_cwksp_reserve_buffer(ws, maxNbSeq * sizeof(BYTE));
1885 zc->seqStore.ofCode = ZSTD_cwksp_reserve_buffer(ws, maxNbSeq * sizeof(BYTE));
1886 zc->seqStore.sequencesStart = (seqDef*)ZSTD_cwksp_reserve_aligned(ws, maxNbSeq * sizeof(seqDef));
2738 ZSTD_resetSeqStore(&(zc->seqStore));
2769 ms, &zc->seqStore,
2786 ms, &zc->seqStore,
2796 lastLLSize = blockCompressor(ms, &zc->seqStore, zc->blockState.nextCBlock->rep, src, srcSize);
2799 ZSTD_storeLastLiterals(&zc->seqStore, lastLiterals, lastLLSize);
2806 const seqStore_t* seqStore = ZSTD_getSeqStore(zc);
2807 const seqDef* seqStoreSeqs = seqStore->sequencesStart;
2808 size_t seqStoreSeqSize = seqStore->sequences - seqStoreSeqs;
2809 size_t seqStoreLiteralsSize = (size_t)(seqStore->lit - seqStore->litStart);
2827 if (i == seqStore->longLengthPos) {
2828 if (seqStore->longLengthType == ZSTD_llt_literalLength) {
2830 } else if (seqStore->longLengthType == ZSTD_llt_matchLength) {
2933 static int ZSTD_maybeRLE(seqStore_t const* seqStore)
2935 size_t const nbSeqs = (size_t)(seqStore->sequences - seqStore->sequencesStart);
2936 size_t const nbLits = (size_t)(seqStore->lit - seqStore->litStart);
3257 * Returns the estimated compressed size of the seqStore, or a zstd error.
3259 static size_t ZSTD_buildEntropyStatisticsAndEstimateSubBlockSize(seqStore_t* seqStore, ZSTD_CCtx* zc) {
3262 FORWARD_IF_ERROR(ZSTD_buildBlockEntropyStats(seqStore,
3268 return ZSTD_estimateBlockSize(seqStore->litStart, (size_t)(seqStore->lit - seqStore->litStart),
3269 seqStore->ofCode, seqStore->llCode, seqStore->mlCode,
3270 (size_t)(seqStore->sequences - seqStore->sequencesStart),
3275 /* Returns literals bytes represented in a seqStore */
3276 static size_t ZSTD_countSeqStoreLiteralsBytes(const seqStore_t* const seqStore) {
3278 size_t const nbSeqs = seqStore->sequences - seqStore->sequencesStart;
3281 seqDef seq = seqStore->sequencesStart[i];
3283 if (i == seqStore->longLengthPos && seqStore->longLengthType == ZSTD_llt_literalLength) {
3290 /* Returns match bytes represented in a seqStore */
3291 static size_t ZSTD_countSeqStoreMatchBytes(const seqStore_t* const seqStore) {
3293 size_t const nbSeqs = seqStore->sequences - seqStore->sequencesStart;
3296 seqDef seq = seqStore->sequencesStart[i];
3298 if (i == seqStore->longLengthPos && seqStore->longLengthType == ZSTD_llt_matchLength) {
3305 /* Derives the seqStore that is a chunk of the originalSeqStore from [startIdx, endIdx).
3364 * and replaces any repcodes within the seqStore that may be invalid.
3367 * cRepcodes are updated exactly in accordance with the seqStore.
3375 seqStore_t* const seqStore, U32 const nbSeq) {
3378 seqDef* const seq = seqStore->sequencesStart + idx;
3393 /* Compression repcode history is always updated with values directly from the unmodified seqStore.
3402 * Compresses a seqStore into a block with a block header, into the buffer dst.
3407 ZSTD_compressSeqStore_singleBlock(ZSTD_CCtx* zc, seqStore_t* const seqStore,
3423 ZSTD_seqStore_resolveOffCodes(dRep, cRep, seqStore, (U32)(seqStore->sequences - seqStore->sequencesStart));
3426 cSeqsSize = ZSTD_entropyCompressSeqStore(seqStore,
3483 * Estimates the cost of seqStore prior to split, and estimates the cost of splitting the sequences in half.
3541 ZSTD_deriveBlockSplitsHelper(&splits, 0, nbSeq, zc, &zc->seqStore);
3591 size_t cSizeSingleBlock = ZSTD_compressSeqStore_singleBlock(zc, &zc->seqStore,
3602 ZSTD_deriveSeqStoreChunk(currSeqStore, &zc->seqStore, 0, partitions[0]);
3616 ZSTD_deriveSeqStoreChunk(nextSeqStore, &zc->seqStore, partitions[i], partitions[i+1]);
3663 nbSeq = (U32)(zc->seqStore.sequences - zc->seqStore.sequencesStart);
3700 cSize = ZSTD_entropyCompressSeqStore(&zc->seqStore,
3747 ZSTD_maybeRLE(&zc->seqStore) &&
5632 RETURN_ERROR_IF(idx - seqPos->idx > cctx->seqStore.maxNbSeq, memory_allocation,
5634 ZSTD_storeSeq(&cctx->seqStore, litLength, ip, iend, offCode, matchLength);
5641 ZSTD_storeLastLiterals(&cctx->seqStore, ip, inSeqs[idx].litLength);
5756 RETURN_ERROR_IF(idx - seqPos->idx > cctx->seqStore.maxNbSeq, memory_allocation,
5758 ZSTD_storeSeq(&cctx->seqStore, litLength, ip, iend, offCode, matchLength);
5773 ZSTD_storeLastLiterals(&cctx->seqStore, ip, lastLLSize);
5834 ZSTD_resetSeqStore(&cctx->seqStore);
5854 compressedSeqsSize = ZSTD_entropyCompressSeqStore(&cctx->seqStore,
5865 ZSTD_maybeRLE(&cctx->seqStore) &&