mirror of
https://github.com/opencv/opencv.git
synced 2024-11-29 13:47:32 +08:00
Cast to unsigned inside CV_XADD to quiet nvcc
This commit is contained in:
parent
54511b4198
commit
3107f79cea
@ -443,9 +443,9 @@ CV_INLINE int cvIsInf( double value )
|
||||
# else
|
||||
# if defined __ATOMIC_ACQ_REL && !defined __clang__
|
||||
// version for gcc >= 4.7
|
||||
# define CV_XADD(addr, delta) __atomic_fetch_add(addr, delta, __ATOMIC_ACQ_REL)
|
||||
# define CV_XADD(addr, delta) (int)__atomic_fetch_add((unsigned*)(addr), (unsigned)(delta), __ATOMIC_ACQ_REL)
|
||||
# else
|
||||
# define CV_XADD(addr, delta) __sync_fetch_and_add(addr, delta)
|
||||
# define CV_XADD(addr, delta) (int)__sync_fetch_and_add((unsigned*)(addr), (unsigned)(delta))
|
||||
# endif
|
||||
# endif
|
||||
#elif (defined WIN32 || defined _WIN32 || defined WINCE) && (!defined RC_INVOKED)
|
||||
|
Loading…
Reference in New Issue
Block a user