8 writes to bufPos
System (8)
sys\System\IO\compression\FastEncoderWindow.cs (8)
62
bufPos
= FastEncoderWindowSize;
120
bufPos
= FastEncoderWindowSize;
154
bufPos
+= (matchLen-1);
159
bufPos
++;
209
bufPos
++;
213
bufPos
++;
260
bufPos
++; // now points to X+2
277
bufPos
++; // now bufPos points to X+2
36 references to bufPos
System (36)
sys\System\IO\compression\FastEncoderWindow.cs (36)
39
Debug.Assert(bufEnd -
bufPos
>= 0, "Ending pointer can't be in front of starting pointer!");
40
return bufEnd -
bufPos
;
48
input.StartIndex =
bufPos
;
49
input.Count = bufEnd -
bufPos
;
63
bufEnd =
bufPos
;
81
Debug.Assert(
bufPos
== 2*FastEncoderWindowSize, "only call this at the end of the window");
86
Array.Copy(window,
bufPos
- FastEncoderWindowSize, window, 0, FastEncoderWindowSize);
121
bufEnd =
bufPos
;
136
hash = HashValue( hash, window[
bufPos
+2] );
140
lookup[hash & FastEncoderHashMask] = (ushort)
bufPos
;
141
prev[
bufPos
& FastEncoderWindowMask] = (ushort) search;
153
if (bufEnd -
bufPos
<= matchLen) {
169
Debug.Assert(
bufPos
>= FastEncoderWindowSize &&
bufPos
< (2*FastEncoderWindowSize), "Invalid Buffer Position!");
173
uint hash = HashValue( 0 , window[
bufPos
]);
174
hash = HashValue( hash , window[
bufPos
+ 1]);
180
if (bufEnd -
bufPos
<= 3) {
196
if (
bufPos
+ matchLen > bufEnd)
197
matchLen = bufEnd -
bufPos
;
208
match.Symbol = window[
bufPos
];
231
if (
bufPos
+ nextMatchLen > bufEnd) {
232
nextMatchLen = bufEnd -
bufPos
;
244
match.Symbol = window[
bufPos
-1];
292
if (
bufPos
== 2*FastEncoderWindowSize) {
307
Debug.Assert(
bufPos
>= 0 &&
bufPos
< 2*FastEncoderWindowSize, "Invalid Buffer position!");
308
Debug.Assert(search <
bufPos
, "Invalid starting search point!");
309
Debug.Assert(RecalculateHash((int)search) == RecalculateHash(
bufPos
));
315
int earliest =
bufPos
- FastEncoderWindowSize;
318
byte wantChar = window[
bufPos
];
321
Debug.Assert(RecalculateHash((int)search) == RecalculateHash(
bufPos
), "Corrupted hash link!");
330
if (window[
bufPos
+j] != window[search+j])
338
wantChar = window[
bufPos
+j];
352
matchPos =
bufPos
- bestMatchPos - 1; // convert absolute to relative position
370
while (where != 0 &&
bufPos
- where < FastEncoderWindowSize) {
373
if (
bufPos
- nextWhere >= FastEncoderWindowSize) {