changed : sufficientLength => targetLength
This commit is contained in:
+1
-1
@@ -191,7 +191,7 @@ void ZSTD_validateParams(ZSTD_parameters* params)
|
||||
CLAMP(params->hashLog, ZSTD_HASHLOG_MIN, ZSTD_HASHLOG_MAX);
|
||||
CLAMP(params->searchLog, ZSTD_SEARCHLOG_MIN, ZSTD_SEARCHLOG_MAX);
|
||||
CLAMP(params->searchLength, ZSTD_SEARCHLENGTH_MIN, ZSTD_SEARCHLENGTH_MAX);
|
||||
CLAMP(params->sufficientLength, ZSTD_TARGETLENGTH_MIN, ZSTD_TARGETLENGTH_MAX);
|
||||
CLAMP(params->targetLength, ZSTD_TARGETLENGTH_MIN, ZSTD_TARGETLENGTH_MAX);
|
||||
if ((U32)params->strategy>(U32)ZSTD_opt_bt) params->strategy = ZSTD_opt_bt;
|
||||
|
||||
/* correct params, to use less memory */
|
||||
|
||||
+2
-2
@@ -440,7 +440,7 @@ void ZSTD_compressBlock_opt_generic(ZSTD_CCtx* ctx,
|
||||
const BYTE* inr;
|
||||
U32 skip_num, cur, cur2, match_num, last_pos, litlen, price;
|
||||
|
||||
const U32 sufficient_len = ctx->params.sufficientLength;
|
||||
const U32 sufficient_len = ctx->params.targetLength;
|
||||
const U32 faster_get_matches = (ctx->params.strategy == ZSTD_opt);
|
||||
|
||||
|
||||
@@ -800,7 +800,7 @@ void ZSTD_compressBlock_opt_extDict_generic(ZSTD_CCtx* ctx,
|
||||
const BYTE* inr;
|
||||
U32 skip_num, cur, cur2, match_num, last_pos, litlen, price;
|
||||
|
||||
const U32 sufficient_len = ctx->params.sufficientLength;
|
||||
const U32 sufficient_len = ctx->params.targetLength;
|
||||
const U32 faster_get_matches = (ctx->params.strategy == ZSTD_opt);
|
||||
|
||||
|
||||
|
||||
+2
-2
@@ -27,7 +27,7 @@
|
||||
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
You can contact the author at :
|
||||
- zstd source repository : https://github.com/Cyan4973/zstd
|
||||
- zstd homepage : http://www.zstd.net
|
||||
*/
|
||||
#ifndef ZSTD_STATIC_H
|
||||
#define ZSTD_STATIC_H
|
||||
@@ -71,7 +71,7 @@ typedef enum { ZSTD_fast, ZSTD_greedy, ZSTD_lazy, ZSTD_lazy2, ZSTD_btlazy2, ZSTD
|
||||
typedef struct
|
||||
{
|
||||
U64 srcSize; /* optional : tells how much bytes are present in the frame. Use 0 if not known. */
|
||||
U32 sufficientLength; /* size of matches which is acceptable (used only by the optimal parser): larger == more compression, slower */
|
||||
U32 targetLength; /* acceptable match size for optimal parser (only) : larger == more compression, slower */
|
||||
U32 windowLog; /* largest match distance : larger == more compression, more memory needed during decompression */
|
||||
U32 contentLog; /* full search segment : larger == more compression, slower, more memory (useless for fast) */
|
||||
U32 hashLog; /* dispatch table : larger == faster, more memory */
|
||||
|
||||
Reference in New Issue
Block a user