17 references to LeadingZeroCount
System.Private.CoreLib (16)
src\libraries\System.Private.CoreLib\src\System\Int64.cs (3)
292
public static long LeadingZeroCount(long value) => BitOperations.
LeadingZeroCount
((ulong)value);
484
return (sizeof(long) * 8) - BitOperations.
LeadingZeroCount
((ulong)(value));
488
return (sizeof(long) * 8) + 1 - BitOperations.
LeadingZeroCount
((ulong)(~value));
src\libraries\System.Private.CoreLib\src\System\Number.BigInteger.cs (1)
429
return 64 - (uint)BitOperations.
LeadingZeroCount
(value);
src\libraries\System.Private.CoreLib\src\System\Number.DiyFp.cs (1)
136
int lzcnt = BitOperations.
LeadingZeroCount
(f);
src\libraries\System.Private.CoreLib\src\System\Number.NumberToFloatingPointBits.cs (1)
1294
int lz = BitOperations.
LeadingZeroCount
(w);
src\libraries\System.Private.CoreLib\src\System\Numerics\BitOperations.cs (2)
133
int shift = 64 -
LeadingZeroCount
(value - 1);
263
return
LeadingZeroCount
((ulong)value);
src\libraries\System.Private.CoreLib\src\System\Runtime\Intrinsics\Vector512_1.cs (1)
698
return 63 - BitOperations.
LeadingZeroCount
(mask); // 63 = 64 (bits in Int64) - 1 (indexing from zero)
src\libraries\System.Private.CoreLib\src\System\SearchValues\ProbabilisticMap.cs (2)
916
index = 63 - BitOperations.
LeadingZeroCount
(mask);
938
index = 63 - BitOperations.
LeadingZeroCount
(mask);
src\libraries\System.Private.CoreLib\src\System\SpanHelpers.Byte.cs (1)
325
int highestSetBitIndex = 63 - BitOperations.
LeadingZeroCount
(mask);
src\libraries\System.Private.CoreLib\src\System\SpanHelpers.Char.cs (1)
341
int bitPos = 62 - BitOperations.
LeadingZeroCount
(mask);
src\libraries\System.Private.CoreLib\src\System\SpanHelpers.T.cs (1)
3369
int index = 63 - BitOperations.
LeadingZeroCount
(notEqualsElements); // 31 = 32 (bits in Int32) - 1 (indexing from zero)
src\libraries\System.Private.CoreLib\src\System\UInt64.cs (2)
289
public static ulong LeadingZeroCount(ulong value) => (ulong)BitOperations.
LeadingZeroCount
(value);
423
int IBinaryInteger<ulong>.GetShortestBitLength() => (sizeof(ulong) * 8) - BitOperations.
LeadingZeroCount
(m_value);
System.Runtime.Numerics (1)
System\Numerics\NumericsHelpers.cs (1)
53
int cbitShift = BitOperations.
LeadingZeroCount
(man) - 11;