Lines Matching refs:u8

22 static u32 SearchLZ(const u8 *startp, const u8 *nextp, u32 remainSize, u16 *offset, u32 maxLength );
41 u32 MI_CompressLZImpl(const u8 *srcp, u32 size, u8 *dstp, BOOL exFormat) in MI_CompressLZImpl()
45 const u8 *srcStartp; in MI_CompressLZImpl()
46 u8 LZCompFlags; // Flag sequence indicating whether there is a compression in MI_CompressLZImpl()
47 u8 *LZCompFlagsp; // Point to memory regions storing LZCompFlags in MI_CompressLZImpl()
50 u8 i; in MI_CompressLZImpl()
95 *dstp++ = (u8)( 0x10 | (length >> 12) ); in MI_CompressLZImpl()
96 *dstp++ = (u8)( length >> 4 ); in MI_CompressLZImpl()
102 *dstp++ = (u8)( length >> 4 ); in MI_CompressLZImpl()
116 *dstp++ = (u8)( length << 4 | (lastOffset - 1) >> 8 ); in MI_CompressLZImpl()
117 *dstp++ = (u8)((lastOffset - 1) & 0xff); in MI_CompressLZImpl()
158 static u32 SearchLZ(const u8 *startp, const u8 *nextp, u32 remainSize, u16 *offset, u32 maxLength ) in SearchLZ()
160 const u8 *searchp; in SearchLZ()
161 const u8 *headp, *searchHeadp; in SearchLZ()
255 static void LZInitTable(LZCompressInfo * info, u8 *work);
256 static void SlideByte(LZCompressInfo * info, const u8 *srcp);
257 static inline void LZSlide(LZCompressInfo * info, const u8 *srcp, u32 n);
258 static u32 SearchLZFast(LZCompressInfo * info, const u8 *nextp, u32 remainSize, u16 *offset, u32 ma…
264 static void LZInitTable(LZCompressInfo * info, u8 *work) in LZInitTable()
284 static void SlideByte(LZCompressInfo * info, const u8 *srcp) in SlideByte()
287 u8 in_data = *srcp; in SlideByte()
298 u8 out_data = *(srcp - 4096); in SlideByte()
335 static inline void LZSlide(LZCompressInfo * info, const u8 *srcp, u32 n) in LZSlide()
361 u32 MI_CompressLZFastImpl(const u8 *srcp, u32 size, u8 *dstp, u8 *work, BOOL exFormat) in MI_CompressLZFastImpl()
364 u8 LZCompFlags; // Flag sequence indicating whether there is a compression in MI_CompressLZFastImpl()
365 u8 *LZCompFlagsp; // Point to memory regions storing LZCompFlags in MI_CompressLZFastImpl()
368 u8 i; in MI_CompressLZFastImpl()
414 *dstp++ = (u8)( 0x10 | (length >> 12) ); in MI_CompressLZFastImpl()
415 *dstp++ = (u8)( length >> 4 ); in MI_CompressLZFastImpl()
421 *dstp++ = (u8)( length >> 4 ); in MI_CompressLZFastImpl()
435 *dstp++ = (u8)(length << 4 | (lastOffset - 1) >> 8); in MI_CompressLZFastImpl()
436 *dstp++ = (u8)((lastOffset - 1) & 0xff); in MI_CompressLZFastImpl()
479 static u32 SearchLZFast(LZCompressInfo * info, const u8 *nextp, u32 remainSize, u16 *offset, u32 ma… in SearchLZFast()
481 const u8 *searchp; in SearchLZFast()
482 const u8 *headp, *searchHeadp; in SearchLZFast()
582 u32 MI_CompressRL(const u8 *srcp, u32 size, u8 *dstp) in MI_CompressRL()
586 u8 RLCompFlag; // 1 if performing run-length encoding in MI_CompressRL()
587 u8 runLength; // Run length in MI_CompressRL()
588 u8 rawDataLength; // Length of data not run in MI_CompressRL()
591 …const u8 *startp; // Point to the start of compression target data for each proce… in MI_CompressRL()
610 rawDataLength = (u8)(size - RLSrcCount); in MI_CompressRL()
634 dstp[RLDstCount++] = (u8)(rawDataLength - 1); // Store "data length - 1" (7 bits) in MI_CompressRL()
651 runLength = (u8)(size - RLSrcCount); in MI_CompressRL()
669 dstp[RLDstCount++] = (u8)(0x80 | (runLength - 3)); // Add 3, and store from 3 to 130 in MI_CompressRL()
696 static u8 HuffCountHWord(u16 nodeNo);
698 static void HuffMakeSubsetHuffTree(u16 huffTreeNo, u8 rightNodeFlag);
699 static u8 HuffRemainingNodeCanSetOffset(u8 costHWord);
700 static void HuffSetOneNodeOffset(u16 huffTreeNo, u8 rightNodeFlag);
711 u8 Bit; // Node's bit data
712 u8 _padding;
720 static u8 HuffTreeTop; // The number for HuffTreeTop
721 static u8 *HuffTree; // [256][2] 512B
725 u8 leftOffsetNeed; // 1 if offset to left child node is required
726 u8 rightOffsetNeed; // 1 if an offset to the right child node is required
740 u8 HuffTree[256 * 2]; // 512B
760 u32 MI_CompressHuffman(const u8 *srcp, u32 size, u8 *dstp, u8 huffBitSize, u8 *work) in MI_CompressHuffman()
763 u8 tmp; in MI_CompressHuffman()
768 u8 srcTmp; in MI_CompressHuffman()
808 tmp = (u8)((srcp[i] & 0xf0) >> 4); // Store from upper 4 bits first in MI_CompressHuffman()
810 tmp = (u8)(srcp[i] & 0x0f); in MI_CompressHuffman()
922 dstp[HuffDstCount++] = ((u8 *)HuffTree)[i]; in MI_CompressHuffman()
940 u8 val = srcp[i]; in MI_CompressHuffman()
953 dstp[HuffDstCount++] = (u8)(bitStream >> (streamLength - (ii + 1) * 8)); in MI_CompressHuffman()
963 srcTmp = (u8)( val >> 4 ); // Upper 4 bits in MI_CompressHuffman()
967 srcTmp = (u8)( val & 0x0F ); // Lower 4 bits in MI_CompressHuffman()
978 dstp[HuffDstCount++] = (u8)(bitStream >> (streamLength - (iii + 1) * 8)); in MI_CompressHuffman()
992 dstp[HuffDstCount++] = (u8)(bitStream << (8 - streamLength)); in MI_CompressHuffman()
1028 u8 offsetNeedNum; in HuffMakeHuffTree()
1029 u8 tmpKey, tmpRightFlag; in HuffMakeHuffTree()
1071 tmpCostOffsetNeed = (u8)(HuffTreeTop - i); in HuffMakeHuffTree()
1082 if (!HuffRemainingNodeCanSetOffset((u8)tmpCostHWord)) in HuffMakeHuffTree()
1109 if (!(HuffRemainingNodeCanSetOffset((u8)tmpCostHWord))) in HuffMakeHuffTree()
1131 HuffMakeSubsetHuffTree((u8)costMaxKey, (u8)costMaxRightFlag); in HuffMakeHuffTree()
1154 HuffSetOneNodeOffset((u8)i, tmpRightFlag); in HuffMakeHuffTree()
1168 static void HuffMakeSubsetHuffTree(u16 huffTreeNo, u8 rightNodeFlag) in HuffMakeSubsetHuffTree()
1170 u8 i; in HuffMakeSubsetHuffTree()
1203 static u8 HuffRemainingNodeCanSetOffset(u8 costHWord) in HuffRemainingNodeCanSetOffset()
1205 u8 i; in HuffRemainingNodeCanSetOffset()
1243 static void HuffSetOneNodeOffset(u16 huffTreeNo, u8 rightNodeFlag) in HuffSetOneNodeOffset()
1246 u8 offsetData = 0; in HuffSetOneNodeOffset()
1263 HuffTree[HuffTreeTop * 2 + 0] = (u8)HuffTable[nodeNo].ChNo[0]; in HuffSetOneNodeOffset()
1264 HuffTreeCtrl[HuffTreeTop].leftNodeNo = (u8)HuffTable[nodeNo].ChNo[0]; in HuffSetOneNodeOffset()
1276 HuffTree[HuffTreeTop * 2 + 1] = (u8)HuffTable[nodeNo].ChNo[1]; in HuffSetOneNodeOffset()
1277 HuffTreeCtrl[HuffTreeTop].rightNodeNo = (u8)HuffTable[nodeNo].ChNo[1]; in HuffSetOneNodeOffset()
1285 offsetData |= (u8)(HuffTreeTop - huffTreeNo - 1); in HuffSetOneNodeOffset()
1327 static u8 HuffCountHWord(u16 nodeNo) in HuffCountHWord()
1329 u8 leftHWord, rightHWord; in HuffCountHWord()
1345 return (u8)(leftHWord + rightHWord + 1); in HuffCountHWord()