Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ Log2SoftwareFallback()

static int System.Numerics.BitOperations.Log2SoftwareFallback ( uint value)
inlinestaticprivate

Definition at line 221 of file BitOperations.cs.

222 {
223 value |= value >> 1;
224 value |= value >> 2;
225 value |= value >> 4;
226 value |= value >> 8;
227 value |= value >> 16;
228 return Unsafe.AddByteOffset(ref MemoryMarshal.GetReference(Log2DeBruijn), (IntPtr)(int)(value * 130329821 >> 27));
229 }
static ReadOnlySpan< byte > Log2DeBruijn

References System.Numerics.BitOperations.Log2DeBruijn, and System.value.

Referenced by System.Numerics.BitOperations.LeadingZeroCount(), and System.Numerics.BitOperations.Log2().