Exportar (0) Imprimir
Expandir todo
Expandir Minimizar

_interlockedbittestandset, _interlockedbittestandset64

Microsoft Specific

Generate the lock_bts instruction, which examines bit b of the address a and returns its current value.


unsigned char _interlockedbittestandset(
   long *a,
   long b
);
unsigned char _interlockedbittestandset64(
   __int64 *a,
   __int64 b
);

[in] a

A pointer to the memory to examine.

[in] b

The bit position to test.

The bit at the position specified.

Intrinsic

Architecture

_interlockedbittestandset

x86, x64

_interlockedbittestandset64

x64

Header file <intrin.h>

As a result of the lock_bts instruction, the bit is set to 1. The operation is atomic.

In Visual C++ 2005, these functions behave as read-write memory barriers. For more information, see _ReadWriteBarrier.

This routine is only available as an intrinsic.

Adiciones de comunidad

AGREGAR
Mostrar:
© 2014 Microsoft