Developer Guide and Reference

Contents

HLE Release _InterlockedCompareExchange Functions

Performs an atomic compare-and-exchange operation on the specified values and releases pending active HLE transaction.
This intrinsic function applies to C/C++ applications for Windows* only.

Syntax

long _InterlockedCompareExchange_HLERelease(long volatile *Destination, long Exchange, long Comparand);
__int64 _InterlockedCompareExchange64_HLERelease(__int64 volatile *Destination, __int64 Exchange, __int64 Comparand);
void * _InterlockedCompareExchangePointer_HLERelease(void * volatile *Destination, void * Exchange, void * Comparand);
Parameters
Destination [in, out]
pointer to the destination value
Exchange [in]
value which will be written at Destination if the comparison matches.
Comparand [in]
value to compare to the value referenced by Destination.
Description
Performs an atomic compare-and-exchange operation on the specified values and releases a pending HLE transaction (if one is active).
The function compares two specified values and replaces one of them with a third value if the compared values are equal.
Returns
Returns the initial value referenced by the
Destination
parameter.

Product and Performance Information

1

Intel's compilers may or may not optimize to the same degree for non-Intel microprocessors for optimizations that are not unique to Intel microprocessors. These optimizations include SSE2, SSE3, and SSSE3 instruction sets and other optimizations. Intel does not guarantee the availability, functionality, or effectiveness of any optimization on microprocessors not manufactured by Intel. Microprocessor-dependent optimizations in this product are intended for use with Intel microprocessors. Certain optimizations not specific to Intel microarchitecture are reserved for Intel microprocessors. Please refer to the applicable product User and Reference Guides for more information regarding the specific instruction sets covered by this notice.

Notice revision #20110804