Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:lib\zstd\decompress.c Create Date:2022-07-28 07:07:47
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:ZSTD_initDStream

Proto:ZSTD_DStream *ZSTD_initDStream(size_t maxWindowSize, void *workspace, size_t workspaceSize)

Type:ZSTD_DStream

Parameter:

TypeParameterName
size_tmaxWindowSize
void *workspace
size_tworkspaceSize
2216  stackMem = ZSTD_initStack(workspace, workspaceSize)
2217  zds = ZSTD_createDStream_advanced(stackMem)
2218  If Not zds Then
2219  Return NULL
2222  maxWindowSize = maxWindowSize
2223  stage = zdss_loadHeader
2224  lhSize = inPos = outStart = outEnd = 0
2225  ZSTD_freeDDict(ddictLocal)
2226  ddictLocal = NULL
2227  ddict = ddictLocal
2228  legacyVersion = 0
2229  hostageByte = 0
2232  blockSize = -************************************** shared macros(maxWindowSize, Define for static allocation )
2233  neededOutSize = maxWindowSize + blockSize + ! ZSTD_wildcopy() :* custom version of memcpy(), can copy up to 7 bytes too many (8 bytes if length==0) * 2
2235  inBuff = ZSTD_malloc(blockSize, customMem)
2236  inBuffSize = blockSize
2237  outBuff = ZSTD_malloc(neededOutSize, customMem)
2238  outBuffSize = neededOutSize
2239  If (inBuff == NULL || outBuff == NULL) Then
2241  Return NULL
2244  Return zds
Caller
NameDescribe
ZSTD_initDStream_usingDDict