Home
last modified time | relevance | path

Searched refs:customMem (Results 1 – 9 of 9) sorted by relevance

/linux-6.12.1/lib/zstd/common/
Dzstd_common.c56 void* ZSTD_customMalloc(size_t size, ZSTD_customMem customMem) in ZSTD_customMalloc() argument
58 if (customMem.customAlloc) in ZSTD_customMalloc()
59 return customMem.customAlloc(customMem.opaque, size); in ZSTD_customMalloc()
63 void* ZSTD_customCalloc(size_t size, ZSTD_customMem customMem) in ZSTD_customCalloc() argument
65 if (customMem.customAlloc) { in ZSTD_customCalloc()
68 void* const ptr = customMem.customAlloc(customMem.opaque, size); in ZSTD_customCalloc()
75 void ZSTD_customFree(void* ptr, ZSTD_customMem customMem) in ZSTD_customFree() argument
78 if (customMem.customFree) in ZSTD_customFree()
79 customMem.customFree(customMem.opaque, ptr); in ZSTD_customFree()
Dzstd_internal.h348 void* ZSTD_customMalloc(size_t size, ZSTD_customMem customMem);
349 void* ZSTD_customCalloc(size_t size, ZSTD_customMem customMem);
350 void ZSTD_customFree(void* ptr, ZSTD_customMem customMem);
/linux-6.12.1/lib/zstd/decompress/
Dzstd_ddict.c145 ZSTD_customMem customMem) in ZSTD_createDDict_advanced() argument
147 if ((!customMem.customAlloc) ^ (!customMem.customFree)) return NULL; in ZSTD_createDDict_advanced()
149 { ZSTD_DDict* const ddict = (ZSTD_DDict*) ZSTD_customMalloc(sizeof(ZSTD_DDict), customMem); in ZSTD_createDDict_advanced()
151 ddict->cMem = customMem; in ZSTD_createDDict_advanced()
Dzstd_decompress.c123 static size_t ZSTD_DDictHashSet_expand(ZSTD_DDictHashSet* hashSet, ZSTD_customMem customMem) { in ZSTD_DDictHashSet_expand() argument
125 …** newTable = (const ZSTD_DDict**)ZSTD_customCalloc(sizeof(ZSTD_DDict*) * newTableSize, customMem); in ZSTD_DDictHashSet_expand()
140 ZSTD_customFree((void*)oldTable, customMem); in ZSTD_DDictHashSet_expand()
170 static ZSTD_DDictHashSet* ZSTD_createDDictHashSet(ZSTD_customMem customMem) { in ZSTD_createDDictHashSet() argument
171 …TD_DDictHashSet* ret = (ZSTD_DDictHashSet*)ZSTD_customMalloc(sizeof(ZSTD_DDictHashSet), customMem); in ZSTD_createDDictHashSet()
175 …nst ZSTD_DDict**)ZSTD_customCalloc(DDICT_HASHSET_TABLE_BASE_SIZE * sizeof(ZSTD_DDict*), customMem); in ZSTD_createDDictHashSet()
177 ZSTD_customFree(ret, customMem); in ZSTD_createDDictHashSet()
188 static void ZSTD_freeDDictHashSet(ZSTD_DDictHashSet* hashSet, ZSTD_customMem customMem) { in ZSTD_freeDDictHashSet() argument
191 ZSTD_customFree((void*)hashSet->ddictPtrTable, customMem); in ZSTD_freeDDictHashSet()
194 ZSTD_customFree(hashSet, customMem); in ZSTD_freeDDictHashSet()
[all …]
Dzstd_decompress_internal.h151 ZSTD_customMem customMem; member
/linux-6.12.1/lib/zstd/compress/
Dzstd_cwksp.h508 MEM_STATIC size_t ZSTD_cwksp_create(ZSTD_cwksp* ws, size_t size, ZSTD_customMem customMem) { in ZSTD_cwksp_create() argument
509 void* workspace = ZSTD_customMalloc(size, customMem); in ZSTD_cwksp_create()
516 MEM_STATIC void ZSTD_cwksp_free(ZSTD_cwksp* ws, ZSTD_customMem customMem) { in ZSTD_cwksp_free() argument
520 ZSTD_customFree(ptr, customMem); in ZSTD_cwksp_free()
Dzstd_compress.c80 ZSTD_customMem customMem; member
98 cctx->customMem = memManager; in ZSTD_initCCtx()
106 ZSTD_CCtx* ZSTD_createCCtx_advanced(ZSTD_customMem customMem) in ZSTD_createCCtx_advanced() argument
110 if ((!customMem.customAlloc) ^ (!customMem.customFree)) return NULL; in ZSTD_createCCtx_advanced()
111 { ZSTD_CCtx* const cctx = (ZSTD_CCtx*)ZSTD_customMalloc(sizeof(ZSTD_CCtx), customMem); in ZSTD_createCCtx_advanced()
113 ZSTD_initCCtx(cctx, customMem); in ZSTD_createCCtx_advanced()
147 ZSTD_customFree(cctx->localDict.dictBuffer, cctx->customMem); in ZSTD_clearAllDicts()
166 ZSTD_cwksp_free(&cctx->workspace, cctx->customMem); in ZSTD_freeCCtxContent()
178 ZSTD_customFree(cctx, cctx->customMem); in ZSTD_freeCCtx()
292 ZSTD_customMem customMem) in ZSTD_createCCtxParams_advanced() argument
[all …]
Dzstd_compress_internal.h326 ZSTD_customMem customMem; member
374 ZSTD_customMem customMem; member
/linux-6.12.1/include/linux/
Dzstd_lib.h1573 ZSTDLIB_STATIC_API ZSTD_CCtx* ZSTD_createCCtx_advanced(ZSTD_customMem customMem);
1574 ZSTDLIB_STATIC_API ZSTD_CStream* ZSTD_createCStream_advanced(ZSTD_customMem customMem);
1575 ZSTDLIB_STATIC_API ZSTD_DCtx* ZSTD_createDCtx_advanced(ZSTD_customMem customMem);
1576 ZSTDLIB_STATIC_API ZSTD_DStream* ZSTD_createDStream_advanced(ZSTD_customMem customMem);
1582 ZSTD_customMem customMem);
1608 ZSTD_customMem customMem);
1614 ZSTD_customMem customMem);