Skip to content

Commit f0d592e

Browse files
committed
Merge pull request opencv#7559 from alalek:cv_xadd_24
2 parents 422154d + c585d38 commit f0d592e

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

modules/core/include/opencv2/core/operations.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,8 +52,8 @@
5252
#ifdef __cplusplus
5353

5454
/////// exchange-add operation for atomic operations on reference counters ///////
55-
#if defined __INTEL_COMPILER && !(defined WIN32 || defined _WIN32) // atomic increment on the linux version of the Intel(tm) compiler
56-
#define CV_XADD(addr,delta) _InterlockedExchangeAdd(const_cast<void*>(reinterpret_cast<volatile void*>(addr)), delta)
55+
#ifdef CV_XADD
56+
// allow to use user-defined macro
5757
#elif defined __GNUC__
5858

5959
#if defined __clang__ && __clang_major__ >= 3 && !defined __ANDROID__ && !defined __EMSCRIPTEN__ && !defined(__CUDACC__)

0 commit comments

Comments
 (0)