Skip to content

Commit

Permalink
Rename configuration option and macro NAME_TBD_UNSAFE_ATOMICS -> ATOM…
Browse files Browse the repository at this point in the history
…ICS_BYPASS
  • Loading branch information
dalg24 committed Jan 3, 2024
1 parent e7ac1d2 commit 77e99c3
Show file tree
Hide file tree
Showing 7 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion cmake/KokkosCore_config.h.in
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@
#cmakedefine KOKKOS_OPT_RANGE_AGGRESSIVE_VECTORIZATION // deprecated
#cmakedefine KOKKOS_ENABLE_AGGRESSIVE_VECTORIZATION
#cmakedefine KOKKOS_ENABLE_IMPL_MDSPAN
#cmakedefine KOKKOS_ENABLE_NAME_TBD_UNSAFE_ATOMICS
#cmakedefine KOKKOS_ENABLE_ATOMICS_BYPASS

/* TPL Settings */
#cmakedefine KOKKOS_ENABLE_HWLOC
Expand Down
2 changes: 1 addition & 1 deletion cmake/kokkos_arch.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -1141,7 +1141,7 @@ FOREACH(Arch ${KOKKOS_ENABLED_ARCH_LIST})
ENDFOREACH()


IF(KOKKOS_ENABLE_NAME_TBD_UNSAFE_ATOMICS)
IF(KOKKOS_ENABLE_ATOMICS_BYPASS)
IF(NOT _HOST_PARALLEL STREQUAL "NoTypeDefined" OR NOT _DEVICE_PARALLEL STREQUAL "NoTypeDefined")
MESSAGE(FATAL_ERROR "Not allowed to disable atomics if any host parallel or device backend is enabled")
ENDIF()
Expand Down
2 changes: 1 addition & 1 deletion cmake/kokkos_enable_options.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ KOKKOS_ENABLE_OPTION(HIP_MULTIPLE_KERNEL_INSTANTIATIONS OFF "Whether multiple ke

# This option will go away eventually, but allows fallback to old implementation when needed.
KOKKOS_ENABLE_OPTION(DESUL_ATOMICS_EXTERNAL OFF "Whether to use an external desul installation")
KOKKOS_ENABLE_OPTION(NAME_TBD_UNSAFE_ATOMICS OFF "**NOT RECOMMENDED** Whether to disable atomics")
KOKKOS_ENABLE_OPTION(ATOMICS_BYPASS OFF "**NOT RECOMMENDED** Whether to disable atomics")

KOKKOS_ENABLE_OPTION(IMPL_MDSPAN OFF "Whether to enable experimental mdspan support")
KOKKOS_ENABLE_OPTION(MDSPAN_EXTERNAL OFF BOOL "Whether to use an external version of mdspan")
Expand Down
2 changes: 1 addition & 1 deletion core/src/Kokkos_Atomics_Desul_Volatile_Wrapper.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ static_assert(false,
#include <Kokkos_Atomics_Desul_Config.hpp>
#include <desul/atomics.hpp>

#ifdef KOKKOS_ENABLE_NAME_TBD_UNSAFE_ATOMICS
#ifdef KOKKOS_ENABLE_ATOMICS_BYPASS
#define KOKKOS_DESUL_MEM_SCOPE desul::MemoryScopeCaller()
#else
#define KOKKOS_DESUL_MEM_SCOPE desul::MemoryScopeDevice()
Expand Down
2 changes: 1 addition & 1 deletion core/src/Kokkos_Atomics_Desul_Wrapper.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ inline const char* atomic_query_version() { return "KOKKOS_DESUL_ATOMICS"; }
#endif
// ============================================================

#ifdef KOKKOS_ENABLE_NAME_TBD_UNSAFE_ATOMICS
#ifdef KOKKOS_ENABLE_ATOMICS_BYPASS
#define KOKKOS_DESUL_MEM_SCOPE desul::MemoryScopeCaller()
#else
#define KOKKOS_DESUL_MEM_SCOPE desul::MemoryScopeDevice()
Expand Down
2 changes: 1 addition & 1 deletion core/src/Kokkos_Macros.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@

//----------------------------------------------------------------------------

#if defined(KOKKOS_ENABLE_NAME_TBD_UNSAFE_ATOMICS)
#if defined(KOKKOS_ENABLE_ATOMICS_BYPASS)

#if !defined(KOKKOS_ENABLE_THREADS) && !defined(KOKKOS_ENABLE_CUDA) && \
!defined(KOKKOS_ENABLE_OPENMP) && !defined(KOKKOS_ENABLE_HPX) && \
Expand Down
2 changes: 1 addition & 1 deletion core/src/Serial/Kokkos_Serial.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ void Serial::print_configuration(std::ostream& os, bool /*verbose*/) const {
os << "Host Serial Execution Space:\n";
os << " KOKKOS_ENABLE_SERIAL: yes\n";

#ifdef KOKKOS_ENABLE_NAME_TBD_UNSAFE_ATOMICS
#ifdef KOKKOS_ENABLE_ATOMICS_BYPASS
os << "Kokkos atomics disabled\n";
#endif

Expand Down

0 comments on commit 77e99c3

Please sign in to comment.