Skip to content

Commit a4122d3

Browse files
authored
Problem: Using more than 1 test worker for gpu tests can cause non-de… (#611)
Problem: Using more than 1 test worker for gpu tests can cause non-determinitic failures. Fix: Use 1 test worker if gpu tests are enabled.
1 parent 4c04563 commit a4122d3

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

test/CMakeLists.txt

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,10 +44,19 @@ configure_lit_site_cfg(
4444
${CMAKE_CURRENT_SOURCE_DIR}/lit.cfg.py
4545
)
4646

47-
add_lit_testsuite(check-imex "Running the IMEX regression tests"
47+
# limit number of workers for lit test when gpu test is enabled
48+
if(IMEX_ENABLE_L0_RUNTIME OR IMEX_ENABLE_SYCL_RUNTIME OR IMEX_ENABLE_VULKAN_RUNNER)
49+
add_lit_testsuite(check-imex "Running the IMEX regression tests"
4850
${CMAKE_CURRENT_BINARY_DIR}
4951
DEPENDS ${IMEX_TEST_DEPENDS}
52+
ARGS "--workers=1"
5053
)
54+
else()
55+
add_lit_testsuite(check-imex "Running the IMEX regression tests"
56+
${CMAKE_CURRENT_BINARY_DIR}
57+
DEPENDS ${IMEX_TEST_DEPENDS}
58+
)
59+
endif()
5160
set_target_properties(check-imex PROPERTIES FOLDER "Tests")
5261

5362
add_lit_testsuite(check-ptensor "Running the IMEX/ptensor regression tests"

0 commit comments

Comments
 (0)