Skip to content

Commit

Permalink
[arcane,tests] Ajoute test pour 'UseAccelerator=1'.
Browse files Browse the repository at this point in the history
  • Loading branch information
grospelliergilles committed Dec 2, 2024
1 parent 93c30b8 commit 1407329
Showing 1 changed file with 2 additions and 11 deletions.
13 changes: 2 additions & 11 deletions arcane/src/arcane/tests/ArcaneTests.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -460,24 +460,15 @@ endmacro()
# ----------------------------------------------------------------------------
# ----------------------------------------------------------------------------

set(ARCANE_ACCELERATOR_RUNTIME_NAME)
if (ARCANE_ACCELERATOR_MODE STREQUAL "ROCM" )
set(ARCANE_ACCELERATOR_RUNTIME_NAME hip)
endif()
if (ARCANE_ACCELERATOR_MODE STREQUAL "CUDA" )
set(ARCANE_ACCELERATOR_RUNTIME_NAME cuda)
endif()
if (ARCANE_ACCELERATOR_MODE STREQUAL "SYCL" )
set(ARCANE_ACCELERATOR_RUNTIME_NAME sycl)
endif()
set(ARCANE_ACCELERATOR_RUNTIME_NAME ${ARCANE_ACCELERATOR_RUNTIME})

# ----------------------------------------------------------------------------
# Ajoute un test séquentiel pour accélerateur si disponible
macro(arcane_add_accelerator_test_sequential test_name case_file)
if (ARCANE_ACCELERATOR_RUNTIME_NAME)
message(STATUS "ADD ACCELERATOR test name=${test_name}")
arcane_add_test_sequential(${test_name}_${ARCANE_ACCELERATOR_RUNTIME_NAME} ${case_file}
"-A,AcceleratorRuntime=${ARCANE_ACCELERATOR_RUNTIME_NAME}" ${ARGN}
"-A,UseAccelerator=1" ${ARGN}
)
endif()
endmacro()
Expand Down

0 comments on commit 1407329

Please sign in to comment.