BitOperations.PopCount Metod

Definition

Överlagringar

Name Description
PopCount(UIntPtr)

Returnerar antalet populationer (antal bitar) för en mask. Liknar i beteendet för x86-instruktionen POPCNT.

PopCount(UInt32)

Returnerar antalet populationer (antal bitar) för en mask.

PopCount(UInt64)

Returnerar antalet populationer (antal bitar) för en osignerad 64-bitars heltalsmask.

PopCount(UIntPtr)

Källa:
BitOperations.cs
Källa:
BitOperations.cs
Källa:
BitOperations.cs
Källa:
BitOperations.cs
Källa:
BitOperations.cs

Viktigt!

Detta API uppfyller inte CLS.

Returnerar antalet populationer (antal bitar) för en mask. Liknar i beteendet för x86-instruktionen POPCNT.

public:
 static int PopCount(UIntPtr value);
[System.CLSCompliant(false)]
public static int PopCount(UIntPtr value);
[<System.CLSCompliant(false)>]
static member PopCount : unativeint -> int
Public Shared Function PopCount (value As UIntPtr) As Integer

Parametrar

value
UIntPtr

unativeint

Värdet.

Returer

Antal populationer.

Attribut

Gäller för

PopCount(UInt32)

Källa:
BitOperations.cs
Källa:
BitOperations.cs
Källa:
BitOperations.cs
Källa:
BitOperations.cs
Källa:
BitOperations.cs

Viktigt!

Detta API uppfyller inte CLS.

Returnerar antalet populationer (antal bitar) för en mask.

public:
 static int PopCount(System::UInt32 value);
[System.CLSCompliant(false)]
public static int PopCount(uint value);
[<System.CLSCompliant(false)>]
static member PopCount : uint32 -> int
Public Shared Function PopCount (value As UInteger) As Integer

Parametrar

value
UInt32

Masken.

Returer

Populationens antal masker.

Attribut

Kommentarer

Den här metoden liknar x86-instruktionen POPCNT.

Gäller för

PopCount(UInt64)

Källa:
BitOperations.cs
Källa:
BitOperations.cs
Källa:
BitOperations.cs
Källa:
BitOperations.cs
Källa:
BitOperations.cs

Viktigt!

Detta API uppfyller inte CLS.

Returnerar antalet populationer (antal bitar) för en osignerad 64-bitars heltalsmask.

public:
 static int PopCount(System::UInt64 value);
[System.CLSCompliant(false)]
public static int PopCount(ulong value);
[<System.CLSCompliant(false)>]
static member PopCount : uint64 -> int
Public Shared Function PopCount (value As ULong) As Integer

Parametrar

value
UInt64

Masken.

Returer

Maskens befolkningsantal.

Attribut

Kommentarer

Den här metoden liknar x86-instruktionen POPCNT.

Gäller för