1 write to _mask
System.Collections.Concurrent (1)
System\Collections\Concurrent\ConcurrentBag.cs (1)
807
_mask
= (_mask << 1) | 1;
16 references to _mask
System.Collections.Concurrent (16)
System\Collections\Concurrent\ConcurrentBag.cs (16)
674
/// <summary>Head index from which to steal. This and'd with the <see cref="
_mask
"/> is the index into <see cref="_array"/>.</summary>
676
/// <summary>Tail index at which local pushes/pops happen. This and'd with the <see cref="
_mask
"/> is the index into <see cref="_array"/>.</summary>
748
_headIndex &=
_mask
;
749
_tailIndex = tail &=
_mask
;
773
if (!_frozen && (head - (tail - 1) < 0) && (tail - (head +
_mask
) < 0))
775
_array[tail &
_mask
] = item;
788
if (count >=
_mask
)
792
int headIdx = head &
_mask
;
807
_mask = (
_mask
<< 1) | 1;
811
_array[tail &
_mask
] = item;
886
int idx = tail &
_mask
;
903
int idx = tail &
_mask
;
954
result = _array[(tail - 1) &
_mask
];
996
int idx = head &
_mask
;
1014
result = _array[head &
_mask
];
1045
array[i] = _array[headIndex++ &
_mask
];