Skip to content

Commit

Permalink
add directive to check for linux
Browse files Browse the repository at this point in the history
  • Loading branch information
Dysrhythmic committed Aug 21, 2024
1 parent 5b9cf50 commit e62c453
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@

#include <atomic>

#if !defined(HPX_WITH_CXX11_ATOMIC_128BIT_LOCKFREE)
/* this will only be true if the target supports cmpxchg16b */
/* Note: currently only supported on Linux */
#if !defined(HPX_WITH_CXX11_ATOMIC_128BIT_LOCKFREE) && defined(__linux__)
template <>
inline bool std::atomic<hpx::lockfree::uint128_type>::is_lock_free()
const noexcept
Expand Down Expand Up @@ -56,4 +56,4 @@ inline bool std::atomic<hpx::lockfree::uint128_type>::compare_exchange_strong(
: "cc", "memory");
return result;
}
#endif // !defined(HPX_WITH_CXX11_ATOMIC_128BIT_LOCKFREE)
#endif // !defined(HPX_WITH_CXX11_ATOMIC_128BIT_LOCKFREE) && defined(__linux__)

0 comments on commit e62c453

Please sign in to comment.