Function report |
Source Code:lib\zstd\zstd_opt.h |
Create Date:2022-07-28 07:04:46 |
Last Modify:2020-03-12 14:18:49 | Copyright©Brick |
home page | Tree |
Annotation kernel can get tool activity | Download SCCT | Chinese |
Name:ZSTD_compressBlock_opt_generic
Proto:void ZSTD_compressBlock_opt_generic(ZSTD_CCtx *ctx, const void *src, size_t srcSize, const int ultra)
Type:void
Parameter:
Type | Parameter | Name |
---|---|---|
ZSTD_CCtx * | ctx | |
const void * | src | |
size_t | srcSize | |
const int | ultra |
409 | seqStorePtr = &seqStore |
416 | prefixStart = base + dictLimit |
418 | maxSearches = 1U << searchLog |
419 | sufficient_len = targetLength |
420 | mls = searchLength |
421 | minMatch = If searchLength == 3 Then 3 Else 4 |
424 | matches = matchTable |
429 | nextToUpdate3 = nextToUpdate |
430 | ZSTD_rescaleFreqs(seqStorePtr, (constBYTE * )src, srcSize) |
431 | ip += ip == prefixStart |
442 | memset(opt, 0, sizeof(ZSTD_optimal_t)) |
443 | last_pos = 0 |
448 | last_i = umber of repcodes to check by the optimal parser + (ip == anchor) |
451 | If repCur > 0 && repCur < ip - prefixStart && safe only for comparisons == safe only for comparisons Then |
454 | If mlen > sufficient_len || mlen >= -************************************** Common constants Then |
462 | Do |
463 | price = ZSTD_getPrice(seqStorePtr, litlen, anchor, best_off, mlen - MINMATCH, ultra) |
466 | mlen-- |
472 | match_num = ZSTD_BtGetAllMatches_selectMLS(ctx, ip, iend, maxSearches, mls, matches, minMatch) |
475 | ip++ |
476 | Continue |
479 | If match_num && ( len > sufficient_len || len >= -************************************** Common constants ) Then |
511 | mlen = 1 |
518 | If mlen == 1 Then |
521 | price = price + ZSTD_getLiteralPrice(seqStorePtr, litlen, inr - litlen) |
522 | Else price = ZSTD_getLiteralPrice(seqStorePtr, litlen, anchor) |
524 | Else |
525 | litlen = 1 |
526 | price = price + ZSTD_getLiteralPrice(seqStorePtr, litlen, inr - 1) |
539 | If off > ZSTD_REP_MOVE_OPT Then |
543 | Else |
552 | last_i = umber of repcodes to check by the optimal parser + (mlen != 1) |
555 | If repCur > 0 && repCur < inr - prefixStart && safe only for comparisons == safe only for comparisons Then |
559 | If mlen > sufficient_len || cur + mlen >= -************************************** Common constants Then |
570 | Do |
591 | match_num = ZSTD_BtGetAllMatches_selectMLS(ctx, inr, iend, maxSearches, mls, matches, best_mlen) |
593 | If match_num > 0 && ( len > sufficient_len || cur + len >= -************************************** Common constants ) Then |
606 | If mlen == 1 Then |
608 | If cur > litlen Then price = price + ZSTD_getPrice(seqStorePtr, litlen, ip + cur - litlen, off - 1, mlen - MINMATCH, ultra) |
611 | Else price = ZSTD_getPrice(seqStorePtr, litlen, anchor, off - 1, mlen - MINMATCH, ultra) |
613 | Else |
614 | litlen = 0 |
615 | price = price + ZSTD_getPrice(seqStorePtr, 0, NULL, off - 1, mlen - MINMATCH, ultra) |
621 | mlen++ |
631 | _storeSequence : |
632 | mlen = 1 |
634 | When 1 cycle |
652 | If mlen == 1 Then |
661 | If offset > ZSTD_REP_MOVE_OPT Then |
666 | Else |
667 | If offset != 0 Then |
678 | ZSTD_updatePrice(seqStorePtr, litLength, anchor, offset, mlen - MINMATCH) |
687 | When i < umber of repcodes cycle repToConfirm[i] = rep[i] |
693 | lastLLSize = iend - anchor |
694 | No 3D Now!(lit, anchor, lastLLSize) |
695 | lit += lastLLSize |
Name | Describe |
---|---|
ZSTD_compressBlock_btopt | |
ZSTD_compressBlock_btopt2 |
Source code conversion tool public plug-in interface | X |
---|---|
Support c/c++/esqlc/java Oracle/Informix/Mysql Plug-in can realize: logical Report Code generation and batch code conversion |