65 references to LeadingZeroCount
http2cat (2)
src\Shared\runtime\Http2\Hpack\HPackDecoder.cs (1)
314switch (BitOperations.LeadingZeroCount(b) - 24) // byte 'b' is extended to uint, so will have 24 extra 0s.
src\Shared\runtime\Http2\Hpack\IntegerDecoder.cs (1)
71if (BitOperations.LeadingZeroCount((uint)b) <= _m)
IIS.FunctionalTests (2)
src\Shared\runtime\Http2\Hpack\HPackDecoder.cs (1)
314switch (BitOperations.LeadingZeroCount(b) - 24) // byte 'b' is extended to uint, so will have 24 extra 0s.
src\Shared\runtime\Http2\Hpack\IntegerDecoder.cs (1)
71if (BitOperations.LeadingZeroCount((uint)b) <= _m)
IIS.LongTests (2)
src\Shared\runtime\Http2\Hpack\HPackDecoder.cs (1)
314switch (BitOperations.LeadingZeroCount(b) - 24) // byte 'b' is extended to uint, so will have 24 extra 0s.
src\Shared\runtime\Http2\Hpack\IntegerDecoder.cs (1)
71if (BitOperations.LeadingZeroCount((uint)b) <= _m)
IIS.NewHandler.FunctionalTests (2)
src\Shared\runtime\Http2\Hpack\HPackDecoder.cs (1)
314switch (BitOperations.LeadingZeroCount(b) - 24) // byte 'b' is extended to uint, so will have 24 extra 0s.
src\Shared\runtime\Http2\Hpack\IntegerDecoder.cs (1)
71if (BitOperations.LeadingZeroCount((uint)b) <= _m)
IIS.NewShim.FunctionalTests (2)
src\Shared\runtime\Http2\Hpack\HPackDecoder.cs (1)
314switch (BitOperations.LeadingZeroCount(b) - 24) // byte 'b' is extended to uint, so will have 24 extra 0s.
src\Shared\runtime\Http2\Hpack\IntegerDecoder.cs (1)
71if (BitOperations.LeadingZeroCount((uint)b) <= _m)
IISExpress.FunctionalTests (2)
src\Shared\runtime\Http2\Hpack\HPackDecoder.cs (1)
314switch (BitOperations.LeadingZeroCount(b) - 24) // byte 'b' is extended to uint, so will have 24 extra 0s.
src\Shared\runtime\Http2\Hpack\IntegerDecoder.cs (1)
71if (BitOperations.LeadingZeroCount((uint)b) <= _m)
Microsoft.AspNetCore.Server.HttpSys.FunctionalTests (2)
src\Shared\runtime\Http2\Hpack\HPackDecoder.cs (1)
314switch (BitOperations.LeadingZeroCount(b) - 24) // byte 'b' is extended to uint, so will have 24 extra 0s.
src\Shared\runtime\Http2\Hpack\IntegerDecoder.cs (1)
71if (BitOperations.LeadingZeroCount((uint)b) <= _m)
Microsoft.AspNetCore.Server.Kestrel.Core (3)
src\Shared\runtime\Http2\Hpack\HPackDecoder.cs (1)
314switch (BitOperations.LeadingZeroCount(b) - 24) // byte 'b' is extended to uint, so will have 24 extra 0s.
src\Shared\runtime\Http2\Hpack\IntegerDecoder.cs (1)
71if (BitOperations.LeadingZeroCount((uint)b) <= _m)
src\Shared\runtime\Http3\QPack\QPackDecoder.cs (1)
434switch (BitOperations.LeadingZeroCount(b) - 24) // byte 'b' is extended to uint, so will have 24 extra 0s.
Microsoft.AspNetCore.Shared.Tests (3)
src\Shared\runtime\Http2\Hpack\HPackDecoder.cs (1)
314switch (BitOperations.LeadingZeroCount(b) - 24) // byte 'b' is extended to uint, so will have 24 extra 0s.
src\Shared\runtime\Http2\Hpack\IntegerDecoder.cs (1)
71if (BitOperations.LeadingZeroCount((uint)b) <= _m)
src\Shared\runtime\Http3\QPack\QPackDecoder.cs (1)
434switch (BitOperations.LeadingZeroCount(b) - 24) // byte 'b' is extended to uint, so will have 24 extra 0s.
System.Net.Http (3)
src\libraries\Common\src\System\Net\Http\aspnetcore\Http2\Hpack\HPackDecoder.cs (1)
314switch (BitOperations.LeadingZeroCount(b) - 24) // byte 'b' is extended to uint, so will have 24 extra 0s.
src\libraries\Common\src\System\Net\Http\aspnetcore\Http2\Hpack\IntegerDecoder.cs (1)
71if (BitOperations.LeadingZeroCount((uint)b) <= _m)
src\libraries\Common\src\System\Net\Http\aspnetcore\Http3\QPack\QPackDecoder.cs (1)
434switch (BitOperations.LeadingZeroCount(b) - 24) // byte 'b' is extended to uint, so will have 24 extra 0s.
System.Private.CoreLib (33)
src\libraries\System.Private.CoreLib\src\System\Byte.cs (1)
282public static byte LeadingZeroCount(byte value) => (byte)(BitOperations.LeadingZeroCount(value) - 24);
src\libraries\System.Private.CoreLib\src\System\Char.cs (1)
1163static char IBinaryInteger<char>.LeadingZeroCount(char value) => (char)(BitOperations.LeadingZeroCount(value) - 16);
src\libraries\System.Private.CoreLib\src\System\Decimal.DecCalc.cs (3)
526newScale -= BitOperations.LeadingZeroCount(result[hiRes]); 1979curScale = BitOperations.LeadingZeroCount(tmp); 2260int shift = BitOperations.LeadingZeroCount(tmp);
src\libraries\System.Private.CoreLib\src\System\Half.cs (1)
1107int shiftDist = BitOperations.LeadingZeroCount(sig) - 16 - 5;
src\libraries\System.Private.CoreLib\src\System\Int16.cs (1)
285public static short LeadingZeroCount(short value) => (short)(BitOperations.LeadingZeroCount((ushort)value) - 16);
src\libraries\System.Private.CoreLib\src\System\Int32.cs (1)
295public static int LeadingZeroCount(int value) => BitOperations.LeadingZeroCount((uint)value);
src\libraries\System.Private.CoreLib\src\System\Number.BigInteger.cs (2)
424return 32 - (uint)BitOperations.LeadingZeroCount(value); 523int shiftLeft = BitOperations.LeadingZeroCount(divHi);
src\libraries\System.Private.CoreLib\src\System\Numerics\BitOperations.cs (3)
102return (uint)(0x1_0000_0000ul >> LeadingZeroCount(value - 1)); 246return 32 + LeadingZeroCount((uint)value); 249return LeadingZeroCount(hi);
src\libraries\System.Private.CoreLib\src\System\Runtime\Intrinsics\Vector128_1.cs (1)
708return 31 - BitOperations.LeadingZeroCount(mask); // 31 = 32 (bits in Int32) - 1 (indexing from zero)
src\libraries\System.Private.CoreLib\src\System\Runtime\Intrinsics\Vector256_1.cs (1)
698return 31 - BitOperations.LeadingZeroCount(mask); // 31 = 32 (bits in Int32) - 1 (indexing from zero)
src\libraries\System.Private.CoreLib\src\System\Runtime\Intrinsics\Vector64_1.cs (1)
773return 31 - BitOperations.LeadingZeroCount(mask); // 31 = 32 (bits in Int32) - 1 (indexing from zero)
src\libraries\System.Private.CoreLib\src\System\SByte.cs (1)
288public static sbyte LeadingZeroCount(sbyte value) => (sbyte)(BitOperations.LeadingZeroCount((byte)value) - 24);
src\libraries\System.Private.CoreLib\src\System\SearchValues\IndexOfAnyAsciiSearcher.cs (4)
1144int offsetInVector = 31 - BitOperations.LeadingZeroCount(mask); 1153int offsetInVector = 31 - BitOperations.LeadingZeroCount(mask); 1175int offsetInVector = 31 - BitOperations.LeadingZeroCount(mask); 1191int offsetInVector = 31 - BitOperations.LeadingZeroCount(mask);
src\libraries\System.Private.CoreLib\src\System\SearchValues\ProbabilisticMap.cs (2)
865index = 31 - BitOperations.LeadingZeroCount(mask); 887index = 31 - BitOperations.LeadingZeroCount(mask);
src\libraries\System.Private.CoreLib\src\System\SpanHelpers.Byte.cs (2)
372int highestSetBitIndex = 31 - BitOperations.LeadingZeroCount(mask); 421int highestSetBitIndex = 31 - BitOperations.LeadingZeroCount(mask);
src\libraries\System.Private.CoreLib\src\System\SpanHelpers.Char.cs (2)
391int bitPos = 30 - BitOperations.LeadingZeroCount(mask); 441int bitPos = 30 - BitOperations.LeadingZeroCount(mask);
src\libraries\System.Private.CoreLib\src\System\SpanHelpers.T.cs (2)
3353int index = 31 - BitOperations.LeadingZeroCount(notEqualsElements); // 31 = 32 (bits in Int32) - 1 (indexing from zero) 3361int index = 31 - BitOperations.LeadingZeroCount(notEqualsElements); // 31 = 32 (bits in Int32) - 1 (indexing from zero)
src\libraries\System.Private.CoreLib\src\System\UInt128.cs (1)
1204int shift = BitOperations.LeadingZeroCount(divHi);
src\libraries\System.Private.CoreLib\src\System\UInt16.cs (1)
279public static ushort LeadingZeroCount(ushort value) => (ushort)(BitOperations.LeadingZeroCount(value) - 16);
src\libraries\System.Private.CoreLib\src\System\UInt32.cs (2)
290public static uint LeadingZeroCount(uint value) => (uint)BitOperations.LeadingZeroCount(value); 424int IBinaryInteger<uint>.GetShortestBitLength() => (sizeof(uint) * 8) - BitOperations.LeadingZeroCount(m_value);
System.Runtime.Numerics (9)
System\Numerics\BigInteger.cs (7)
848int c = BitOperations.LeadingZeroCount((uint)h); 1842int z = BitOperations.LeadingZeroCount((uint)h); 3066long bitLength = bitsArrayLength * 32L - BitOperations.LeadingZeroCount(highValue); 3551return (sizeof(int) * 8) - BitOperations.LeadingZeroCount((uint)(value)); 3555return (sizeof(int) * 8) + 1 - BitOperations.LeadingZeroCount((uint)(~value)); 3563result += (sizeof(uint) * 8) - BitOperations.LeadingZeroCount(bits[^1]); 3582result += (sizeof(uint) * 8) + 1 - BitOperations.LeadingZeroCount(~part);
System\Numerics\BigIntegerCalculator.DivRem.cs (1)
130int shift = BitOperations.LeadingZeroCount(divHi);
System\Numerics\BigIntegerCalculator.GcdInv.cs (1)
267int z = BitOperations.LeadingZeroCount((uint)xh);