Home | History | Annotate | Download | only in lib

Lines Matching refs:U32

141   typedef uint32_t U32;
148 typedef unsigned int U32;
165 const union { U32 u; BYTE c[4]; } one = { 1 }; /* don't use static : performance detrimental */
174 static U32 LZ4_read32(const void* memPtr) { return *(const U32*) memPtr; }
178 static void LZ4_write32(void* memPtr, U32 value) { *(U32*)memPtr = value; }
184 typedef union { U16 u16; U32 u32; reg_t uArch; } __attribute__((packed)) unalign;
187 static U32 LZ4_read32(const void* ptr) { return ((const unalign*)ptr)->u32; }
191 static void LZ4_write32(void* memPtr, U32 value) { ((unalign*)memPtr)->u32 = value; }
200 static U32 LZ4_read32(const void* memPtr)
202 U32 val; memcpy(&val, memPtr, sizeof(val)); return val;
215 static void LZ4_write32(void* memPtr, U32 value)
309 _BitScanForward( &r, (U32)val );
312 return (__builtin_ctz((U32)val) >> 3);
315 return DeBruijnBytePos[((U32)((val & -(S32)val) * 0x077CB531U)) >> 27];
339 return (__builtin_clz((U32)val) >> 3);
374 static const U32 LZ4_skipTrigger = 6; /* Increase this value ==> compression run slower on incompressible data */
402 static U32 LZ4_hash4(U32 sequence, tableType_t const tableType)
410 static U32 LZ4_hash5(U64 sequence, tableType_t const tableType)
414 const U32 hashLog = (tableType == byU16) ? LZ4_HASHLOG+1 : LZ4_HASHLOG;
416 return (U32)(((sequence << 24) * prime5bytes) >> (64 - hashLog));
418 return (U32)(((sequence >> 24) * prime8bytes) >> (64 - hashLog));
421 FORCE_INLINE U32 LZ4_hashPosition(const void* const p, tableType_t const tableType)
427 static void LZ4_putPositionOnHash(const BYTE* p, U32 h, void* tableBase, tableType_t const tableType, const BYTE* srcBase)
432 case byU32: { U32* hashTable = (U32*) tableBase; hashTable[h] = (U32)(p-srcBase); return; }
439 U32 const h = LZ4_hashPosition(p, tableType);
443 static const BYTE* LZ4_getPositionOnHash(U32 h, void* tableBase, tableType_t tableType, const BYTE* srcBase)
446 if (tableType == byU32) { const U32* const hashTable = (U32*) tableBase; return hashTable[h] + srcBase; }
452 U32 const h = LZ4_hashPosition(p, tableType);
469 const U32 acceleration)
486 U32 forwardH;
489 if ((U32)inputSize > (U32)LZ4_MAX_INPUT_SIZE) return 0; /* Unsupported inputSize, too large (or negative) */
524 U32 const h = forwardH;
640 ((op - (BYTE*)dest) + lastRun + 1 + ((lastRun+255-RUN_MASK)/255) > (U32)maxOutputSize) )
743 U32 forwardH;
748 if ((U32)*srcSizePtr > (U32)LZ4_MAX_INPUT_SIZE) return 0; /* Unsupported input size, too large (or negative) */
768 U32 h = forwardH;
956 dict->dictSize = (U32)(dictEnd - p);
973 U32 const delta = LZ4_dict->currentOffset - 64 KB;
1001 streamPtr->dictSize = (U32)(dictEnd - sourceEnd);
1015 streamPtr->dictSize += (U32)inputSize;
1016 streamPtr->currentOffset += (U32)inputSize;
1027 streamPtr->dictSize = (U32)inputSize;
1028 streamPtr->currentOffset += (U32)inputSize;
1048 streamPtr->dictSize = (U32)inputSize;
1049 streamPtr->currentOffset += (U32)inputSize;
1067 if ((U32)dictSize > 64 KB) dictSize = 64 KB; /* useless to define a dictionary > 64 KB */
1068 if ((U32)dictSize > dict->dictSize) dictSize = dict->dictSize;
1073 dict->dictSize = (U32)dictSize;
1169 LZ4_write32(op, (U32)offset); /* costs ~1%; silence an msan warning when offset==0 */