| /src/external/bsd/zstd/dist/tests/fuzz/ |
| dictionary_decompress.c | 37 ZSTD_DDict* ddict = NULL; local 45 ddict = ZSTD_createDDict(dict.buff, dict.size); 46 FUZZ_ASSERT(ddict); 62 if (ddict) { 63 ZSTD_decompress_usingDDict(dctx, rBuf, bufSize, src, size, ddict); 71 ZSTD_freeDDict(ddict);
|
| sequence_compression_api.c | 38 static ZSTD_DDict* ddict = NULL; variable 242 FUZZ_ZASSERT(ZSTD_DCtx_refDDict(dctx, ddict)); 320 /* Create global cdict and ddict */ 327 ddict = ZSTD_createDDict_advanced(dictBuffer, ZSTD_FUZZ_GENERATED_DICT_MAXSIZE, ZSTD_dlm_byRef, ZSTD_dct_rawContent, ZSTD_defaultCMem); 329 FUZZ_ASSERT(ddict); 333 FUZZ_ASSERT(ddict);
|
| /src/external/bsd/zstd/dist/tests/ |
| invalidDictionaries.c | 45 ZSTD_DDict *ddict; local 51 ddict = ZSTD_createDDict(dict->data, dict->size); 52 if (ddict) { 53 ZSTD_freeDDict(ddict);
|
| zstreamtest.c | 1118 /* DDict scenario */ 1120 { ZSTD_DDict* const ddict = ZSTD_createDDict(dictionary.start, dictionary.filled); local 1121 size_t const initError = ZSTD_initDStream_usingDDict(zd, ddict); 1133 ZSTD_freeDDict(ddict); 1268 DISPLAYLEVEL(3, "test%3i : ZSTD_decompressStream() with ddict : ", testNb++); 1271 ZSTD_DDict* ddict = ZSTD_createDDict(dictionary.start, dictionary.filled); local 1272 /* We should succeed to decompress with the ddict. */ 1274 CHECK_Z( ZSTD_DCtx_refDDict(dctx, ddict) ); 1280 /* The ddict should persist across calls. */ 1286 /* When we reset the context the ddict is cleared. * 1322 ZSTD_DDict* ddict = ZSTD_createDDict(dictionary.start, dictionary.filled); local 1555 ZSTD_DDict* ddict; local 2316 ZSTD_DDict* ddict = NULL; local [all...] |
| fuzzer.c | 737 unsigned (* const funcptr_getDictID)(const ZSTD_DDict* ddict) = 785 DISPLAYLEVEL(3, "test%3i : decompress with null DDict : ", testNb++); 2398 DISPLAYLEVEL(3, "test%3i : decompress with DDict : ", testNb++); 2399 { ZSTD_DDict* const ddict = ZSTD_createDDict(CNBuffer, dictSize); local 2400 size_t const r = ZSTD_decompress_usingDDict(dctx, decodedBuffer, CNBuffSize, compressedBuffer, cSize, ddict); 2402 DISPLAYLEVEL(3, "OK (size of DDict : %u) \n", (unsigned)ZSTD_sizeof_DDict(ddict)); 2403 ZSTD_freeDDict(ddict); 2406 DISPLAYLEVEL(3, "test%3i : decompress with static DDict : ", testNb++); 2410 { const ZSTD_DDict* const ddict = ZSTD_initStaticDDict(ddictBuffer, ddictBufferSize, CNBuffer, dictSize, ZSTD_dlm_byCopy, ZSTD_dct (…) local 3059 ZSTD_DDict* ddict = ZSTD_createDDict(dictBuffer, dictSize); local [all...] |
| /src/external/bsd/zstd/dist/examples/ |
| dictionary_decompression.c | 24 ZSTD_DDict* const ddict = ZSTD_createDDict(dictBuffer, dictSize); local 25 CHECK(ddict != NULL, "ZSTD_createDDict() failed!"); 27 return ddict; 30 static void decompress(const char* fname, const ZSTD_DDict* ddict) 50 unsigned const expectedDictID = ZSTD_getDictID_fromDDict(ddict); 64 size_t const dSize = ZSTD_decompress_usingDDict(dctx, rBuff, rSize, cBuff, cSize, ddict);
|
| /src/external/bsd/zstd/dist/lib/decompress/ |
| zstd_ddict.c | 46 const void* ZSTD_DDict_dictContent(const ZSTD_DDict* ddict) 48 assert(ddict != NULL); 49 return ddict->dictContent; 52 size_t ZSTD_DDict_dictSize(const ZSTD_DDict* ddict) 54 assert(ddict != NULL); 55 return ddict->dictSize; 58 void ZSTD_copyDDictParameters(ZSTD_DCtx* dctx, const ZSTD_DDict* ddict) 62 assert(ddict != NULL); 63 dctx->dictID = ddict->dictID; 64 dctx->prefixStart = ddict->dictContent 152 { ZSTD_DDict* const ddict = (ZSTD_DDict*) ZSTD_customMalloc(sizeof(ZSTD_DDict), customMem); local 195 ZSTD_DDict* const ddict = (ZSTD_DDict*)sBuffer; local [all...] |
| zstd_decompress_internal.h | 82 ZSTD_seqSymbol OFTable[SEQSYMBOL_TABLE_SIZE(OffFSELog)]; /* is also used as temporary workspace while building hufTable during DDict creation */ 163 const ZSTD_DDict* ddict; /* set by ZSTD_initDStream_usingDDict(), or ZSTD_DCtx_refDDict() */ member in struct:ZSTD_DCtx_s
|
| zstd_decompress.c | 86 * the load factor of the ddict hash set. 97 /* DDict ptr table size is a multiple of 2, use size - 1 as mask to get index within [0, hashSet->ddictPtrTableSize) */ 101 /* Adds DDict to a hashset without resizing it. 102 * If inserting a DDict with a dictID that already exists in the set, replaces the one in the set. 105 static size_t ZSTD_DDictHashSet_emplaceDDict(ZSTD_DDictHashSet* hashSet, const ZSTD_DDict* ddict) { 106 const U32 dictID = ZSTD_getDictID_fromDDict(ddict); 112 /* Replace existing ddict if inserting ddict with same dictID */ 115 hashSet->ddictPtrTable[idx] = ddict; 122 hashSet->ddictPtrTable[idx] = ddict; 2143 ZSTD_DDict const* const ddict = ZSTD_getDDict(zds); local [all...] |
| /src/external/bsd/zstd/dist/contrib/diagnose_corruption/ |
| check_flipped_bits.c | 36 ZSTD_DDict* ddict; member in struct:__anon8530 47 ZSTD_freeDDict(stuff->ddict); 126 ZSTD_DDict* ddict; local 133 ddict = ZSTD_createDDict_advanced(*buf, *size, ZSTD_dlm_byRef, ZSTD_dct_auto, ZSTD_defaultCMem); 134 if (ddict == NULL) { 135 fprintf(stderr, "Failed to create ddict.\n"); 139 *dict_id = ZSTD_getDictID_fromDDict(ddict); 141 return ddict; 152 ZSTD_DDict* ddict; local 173 ddict = readDict(dict_file_name, buf, size, &read_dict_id) [all...] |
| /src/external/bsd/zstd/dist/zlibWrapper/examples/ |
| zwrapbench.c | 405 ZSTD_DDict* ddict = ZSTD_createDDict(dictBuffer, dictBufferSize); local 406 if (!ddict) EXM_THROW(2, "ZSTD_createDDict() allocation failure"); 413 ddict); 424 ZSTD_freeDDict(ddict);
|
| /src/external/bsd/zstd/dist/lib/legacy/ |
| zstd_v07.c | 4142 { ZSTDv07_DDict* const ddict = (ZSTDv07_DDict*) customMem.customAlloc(customMem.opaque, sizeof(*ddict)); local 4146 if (!dictContent || !ddict || !dctx) { 4148 customMem.customFree(customMem.opaque, ddict); 4157 customMem.customFree(customMem.opaque, ddict); 4162 ddict->dict = dictContent; 4163 ddict->dictSize = dictSize; 4164 ddict->refContext = dctx; 4165 return ddict; 4178 size_t ZSTDv07_freeDDict(ZSTDv07_DDict* ddict) [all...] |