Skip to content

Commit

Permalink
Run mars_test on up to 16 processes
Browse files Browse the repository at this point in the history
Signed-off-by: Steven Hahn <[email protected]>
  • Loading branch information
quantumsteve committed Sep 3, 2024
1 parent 195e797 commit 3f3f5ad
Show file tree
Hide file tree
Showing 33 changed files with 11 additions and 14 deletions.
19 changes: 6 additions & 13 deletions test/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -22,13 +22,6 @@ set_property(TARGET xtest PROPERTY LINKER_LANGUAGE Fortran)
configure_file(${CMAKE_SOURCE_DIR}/test/egyro/korc_egyro.sh.in ${CMAKE_BINARY_DIR}/egyro_test/korc_egyro.sh)
configure_file(${CMAKE_SOURCE_DIR}/test/mars/korc_mars.sh.in ${CMAKE_BINARY_DIR}/mars_test/korc_mars.sh)

if(USE_PSPLINE)
add_test (NAME mars_test_1
COMMAND ${CMAKE_BINARY_DIR}/mars_test/korc_mars.sh 1
WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/bin)
set_tests_properties (mars_test_1 PROPERTIES PROCESSORS 1 ENVIRONMENT OMP_NUM_THREADS=1)
endif()

file(MAKE_DIRECTORY ${CMAKE_BINARY_DIR}/bin/egyro_test)
file(MAKE_DIRECTORY ${CMAKE_BINARY_DIR}/bin/mars_test)

Expand All @@ -39,12 +32,12 @@ foreach(RANK IN ITEMS 1 2 4 8 16)
WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/bin)
set_tests_properties (egyro_test_${RANK} PROPERTIES PROCESSORS ${RANK} ENVIRONMENT OMP_NUM_THREADS=1)

# if(USE_PSPLINE)
# add_test (NAME mars_test_${RANK}
# COMMAND ${CMAKE_BINARY_DIR}/mars_test/korc_mars.sh ${RANK}
# WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/bin)
# set_tests_properties (mars_test_${RANK} PROPERTIES PROCESSORS ${RANK} ENVIRONMENT OMP_NUM_THREADS=1)
# endif()
if(USE_PSPLINE)
add_test (NAME mars_test_${RANK}
COMMAND ${CMAKE_BINARY_DIR}/mars_test/korc_mars.sh ${RANK}
WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/bin)
set_tests_properties (mars_test_${RANK} PROPERTIES PROCESSORS ${RANK} ENVIRONMENT OMP_NUM_THREADS=1)
endif()

add_test (NAME unit_testing_${RANK}
COMMAND ${MPIEXEC_EXECUTABLE} ${MPIEXEC_NUMPROC_FLAG} ${RANK} ./xtest TEST_OUT
Expand Down
6 changes: 5 additions & 1 deletion test/mars/korc_mars.sh.in
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,8 @@ fi

${MPIEXEC_EXECUTABLE} ${MPIEXEC_NUMPROC_FLAG} $1 ./xkorc $INPUT_FILE $OUT_DIR/

h5diff -r -p 0.000008 $OUT_DIR/file_0.h5 ${CMAKE_SOURCE_DIR}/test/mars/file_0_new_random.h5
for i in $(seq 0 $(($1-1)));
do
h5diff -r -p 0.000008 $OUT_DIR/file_$i.h5 ${CMAKE_SOURCE_DIR}/test/mars/rank_$1/file_$i.h5
done

Binary file added test/mars/rank_1/file_0.h5
Binary file not shown.
Binary file added test/mars/rank_16/file_0.h5
Binary file not shown.
Binary file added test/mars/rank_16/file_1.h5
Binary file not shown.
Binary file added test/mars/rank_16/file_10.h5
Binary file not shown.
Binary file added test/mars/rank_16/file_11.h5
Binary file not shown.
Binary file added test/mars/rank_16/file_12.h5
Binary file not shown.
Binary file added test/mars/rank_16/file_13.h5
Binary file not shown.
Binary file added test/mars/rank_16/file_14.h5
Binary file not shown.
Binary file added test/mars/rank_16/file_15.h5
Binary file not shown.
Binary file added test/mars/rank_16/file_2.h5
Binary file not shown.
Binary file added test/mars/rank_16/file_3.h5
Binary file not shown.
Binary file added test/mars/rank_16/file_4.h5
Binary file not shown.
Binary file added test/mars/rank_16/file_5.h5
Binary file not shown.
Binary file added test/mars/rank_16/file_6.h5
Binary file not shown.
Binary file added test/mars/rank_16/file_7.h5
Binary file not shown.
Binary file added test/mars/rank_16/file_8.h5
Binary file not shown.
Binary file added test/mars/rank_16/file_9.h5
Binary file not shown.
Binary file added test/mars/rank_2/file_0.h5
Binary file not shown.
Binary file added test/mars/rank_2/file_1.h5
Binary file not shown.
Binary file added test/mars/rank_4/file_0.h5
Binary file not shown.
Binary file added test/mars/rank_4/file_1.h5
Binary file not shown.
Binary file added test/mars/rank_4/file_2.h5
Binary file not shown.
Binary file added test/mars/rank_4/file_3.h5
Binary file not shown.
Binary file added test/mars/rank_8/file_0.h5
Binary file not shown.
Binary file added test/mars/rank_8/file_1.h5
Binary file not shown.
Binary file added test/mars/rank_8/file_2.h5
Binary file not shown.
Binary file added test/mars/rank_8/file_3.h5
Binary file not shown.
Binary file added test/mars/rank_8/file_4.h5
Binary file not shown.
Binary file added test/mars/rank_8/file_5.h5
Binary file not shown.
Binary file added test/mars/rank_8/file_6.h5
Binary file not shown.
Binary file added test/mars/rank_8/file_7.h5
Binary file not shown.

0 comments on commit 3f3f5ad

Please sign in to comment.