Table of Contents

Method PopCount

Namespace
Zyl.VectorTraits.Numerics
Assembly
VectorTraits.dll

PopCount(uint)

Returns the population count (number of bits set) of a mask. Similar in behavior to the x86 instruction POPCNT.

[CLSCompliant(false)]
public static int PopCount(uint value)

Parameters

value uint

The value.

Returns

int

PopCount(ulong)

Returns the population count (number of bits set) of a mask. Similar in behavior to the x86 instruction POPCNT.

[CLSCompliant(false)]
public static int PopCount(ulong value)

Parameters

value ulong

The value.

Returns

int

PopCount(ExUInt128)

Returns the population count (number of bits set) of a mask. Similar in behavior to the x86 instruction POPCNT.

[CLSCompliant(false)]
public static int PopCount(ExUInt128 value)

Parameters

value ExUInt128

The value.

Returns

int

PopCount(UInt128)

Returns the population count (number of bits set) of a mask. Similar in behavior to the x86 instruction POPCNT.

[CLSCompliant(false)]
public static int PopCount(UInt128 value)

Parameters

value UInt128

The value.

Returns

int

PopCount(nuint)

Returns the population count (number of bits set) of a mask. Similar in behavior to the x86 instruction POPCNT.

[CLSCompliant(false)]
public static int PopCount(nuint value)

Parameters

value nuint

The value.

Returns

int