Lines Matching refs:op
483 BYTE* op = (BYTE*) dest; in LZ4_compress_generic() local
484 BYTE* const olimit = op + maxOutputSize; in LZ4_compress_generic()
553 token = op++; in LZ4_compress_generic()
555 (unlikely(op + litLength + (2 + 1 + LASTLITERALS) + (litLength/255) > olimit))) in LZ4_compress_generic()
560 for(; len >= 255 ; len-=255) *op++ = 255; in LZ4_compress_generic()
561 *op++ = (BYTE)len; in LZ4_compress_generic()
566 LZ4_wildCopy(op, anchor, op+litLength); in LZ4_compress_generic()
567 op+=litLength; in LZ4_compress_generic()
572 LZ4_writeLE16(op, (U16)(ip-match)); op+=2; in LZ4_compress_generic()
595 (unlikely(op + (1 + LASTLITERALS) + (matchCode>>8) > olimit)) ) in LZ4_compress_generic()
600 LZ4_write32(op, 0xFFFFFFFF); in LZ4_compress_generic()
601 while (matchCode >= 4*255) op+=4, LZ4_write32(op, 0xFFFFFFFF), matchCode -= 4*255; in LZ4_compress_generic()
602 op += matchCode / 255; in LZ4_compress_generic()
603 *op++ = (BYTE)(matchCode % 255); in LZ4_compress_generic()
630 { token=op++; *token=0; goto _next_match; } in LZ4_compress_generic()
640 ((op - (BYTE*)dest) + lastRun + 1 + ((lastRun+255-RUN_MASK)/255) > (U32)maxOutputSize) ) in LZ4_compress_generic()
644 *op++ = RUN_MASK << ML_BITS; in LZ4_compress_generic()
645 for(; accumulator >= 255 ; accumulator-=255) *op++ = 255; in LZ4_compress_generic()
646 *op++ = (BYTE) accumulator; in LZ4_compress_generic()
648 *op++ = (BYTE)(lastRun<<ML_BITS); in LZ4_compress_generic()
650 memcpy(op, anchor, lastRun); in LZ4_compress_generic()
651 op += lastRun; in LZ4_compress_generic()
655 return (int) (((char*)op)-dest); in LZ4_compress_generic()
737 BYTE* op = (BYTE*) dst; in LZ4_compress_destSize_generic() local
738 BYTE* const oend = op + targetDstSize; in LZ4_compress_destSize_generic()
739 …BYTE* const oMaxLit = op + targetDstSize - 2 /* offset */ - 8 /* because 8+MINMATCH==MFLIMIT */ - … in LZ4_compress_destSize_generic()
740 BYTE* const oMaxMatch = op + targetDstSize - (LASTLITERALS + 1 /* token */); in LZ4_compress_destSize_generic()
788 token = op++; in LZ4_compress_destSize_generic()
789 if (op + ((litLength+240)/255) + litLength > oMaxLit) { in LZ4_compress_destSize_generic()
791 op--; in LZ4_compress_destSize_generic()
797 for(; len >= 255 ; len-=255) *op++ = 255; in LZ4_compress_destSize_generic()
798 *op++ = (BYTE)len; in LZ4_compress_destSize_generic()
803 LZ4_wildCopy(op, anchor, op+litLength); in LZ4_compress_destSize_generic()
804 op += litLength; in LZ4_compress_destSize_generic()
809 LZ4_writeLE16(op, (U16)(ip-match)); op+=2; in LZ4_compress_destSize_generic()
814 if (op + ((matchLength+240)/255) > oMaxMatch) { in LZ4_compress_destSize_generic()
816 matchLength = (15-1) + (oMaxMatch-op) * 255; in LZ4_compress_destSize_generic()
823 while (matchLength >= 255) { matchLength-=255; *op++ = 255; } in LZ4_compress_destSize_generic()
824 *op++ = (BYTE)matchLength; in LZ4_compress_destSize_generic()
833 if (op > oMaxSeq) break; in LZ4_compress_destSize_generic()
843 { token=op++; *token=0; goto _next_match; } in LZ4_compress_destSize_generic()
852 …if (op + 1 /* token */ + ((lastRunSize+240)/255) /* litLength */ + lastRunSize /* literals */ > oe… in LZ4_compress_destSize_generic()
854 lastRunSize = (oend-op) - 1; in LZ4_compress_destSize_generic()
861 *op++ = RUN_MASK << ML_BITS; in LZ4_compress_destSize_generic()
862 for(; accumulator >= 255 ; accumulator-=255) *op++ = 255; in LZ4_compress_destSize_generic()
863 *op++ = (BYTE) accumulator; in LZ4_compress_destSize_generic()
865 *op++ = (BYTE)(lastRunSize<<ML_BITS); in LZ4_compress_destSize_generic()
867 memcpy(op, anchor, lastRunSize); in LZ4_compress_destSize_generic()
868 op += lastRunSize; in LZ4_compress_destSize_generic()
873 return (int) (((char*)op)-dst); in LZ4_compress_destSize_generic()
1108 BYTE* op = (BYTE*) dest; in LZ4_decompress_generic() local
1109 BYTE* const oend = op + outputSize; in LZ4_decompress_generic()
1111 BYTE* oexit = op + targetOutputSize; in LZ4_decompress_generic()
1141 …if ((safeDecode) && unlikely((uptrval)(op)+length<(uptrval)(op))) goto _output_error; /* overflo… in LZ4_decompress_generic()
1146 cpy = op+length; in LZ4_decompress_generic()
1157 memcpy(op, ip, length); in LZ4_decompress_generic()
1159 op += length; in LZ4_decompress_generic()
1162 LZ4_wildCopy(op, ip, cpy); in LZ4_decompress_generic()
1163 ip += length; op = cpy; in LZ4_decompress_generic()
1167 match = op - offset; in LZ4_decompress_generic()
1169 LZ4_write32(op, (U32)offset); /* costs ~1%; silence an msan warning when offset==0 */ in LZ4_decompress_generic()
1180 …if ((safeDecode) && unlikely((uptrval)(op)+length<(uptrval)op)) goto _output_error; /* overflow … in LZ4_decompress_generic()
1186 …if (unlikely(op+length > oend-LASTLITERALS)) goto _output_error; /* doesn't respect parsing rest… in LZ4_decompress_generic()
1190 memmove(op, dictEnd - (lowPrefix-match), length); in LZ4_decompress_generic()
1191 op += length; in LZ4_decompress_generic()
1196 memcpy(op, dictEnd - copySize, copySize); in LZ4_decompress_generic()
1197 op += copySize; in LZ4_decompress_generic()
1198 if (restSize > (size_t)(op-lowPrefix)) { /* overlap copy */ in LZ4_decompress_generic()
1199 BYTE* const endOfMatch = op + restSize; in LZ4_decompress_generic()
1201 while (op < endOfMatch) *op++ = *copyFrom++; in LZ4_decompress_generic()
1203 memcpy(op, lowPrefix, restSize); in LZ4_decompress_generic()
1204 op += restSize; in LZ4_decompress_generic()
1210 cpy = op + length; in LZ4_decompress_generic()
1213 op[0] = match[0]; in LZ4_decompress_generic()
1214 op[1] = match[1]; in LZ4_decompress_generic()
1215 op[2] = match[2]; in LZ4_decompress_generic()
1216 op[3] = match[3]; in LZ4_decompress_generic()
1218 memcpy(op+4, match, 4); in LZ4_decompress_generic()
1220 } else { LZ4_copy8(op, match); match+=8; } in LZ4_decompress_generic()
1221 op += 8; in LZ4_decompress_generic()
1226 if (op < oCopyLimit) { in LZ4_decompress_generic()
1227 LZ4_wildCopy(op, match, oCopyLimit); in LZ4_decompress_generic()
1228 match += oCopyLimit - op; in LZ4_decompress_generic()
1229 op = oCopyLimit; in LZ4_decompress_generic()
1231 while (op<cpy) *op++ = *match++; in LZ4_decompress_generic()
1233 LZ4_copy8(op, match); in LZ4_decompress_generic()
1234 if (length>16) LZ4_wildCopy(op+8, match+8, cpy); in LZ4_decompress_generic()
1236 op=cpy; /* correction */ in LZ4_decompress_generic()
1241 return (int) (((char*)op)-dest); /* Nb of output bytes decoded */ in LZ4_decompress_generic()