From: Matthias Maier Date: Sat, 8 Jul 2023 14:39:42 +0000 (-0500) Subject: CMake: avoid "binding to none" for performance tests X-Git-Tag: relicensing~717^2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d01cd10c876790f3316bd4b490f68be8629e2518;p=dealii.git CMake: avoid "binding to none" for performance tests It turns out that this change introduces a lot of noise. Let us thus not override the mpi binding policy if we already run exclusively. --- diff --git a/cmake/macros/macro_deal_ii_add_test.cmake b/cmake/macros/macro_deal_ii_add_test.cmake index 40ede17232..43cdeb459b 100644 --- a/cmake/macros/macro_deal_ii_add_test.cmake +++ b/cmake/macros/macro_deal_ii_add_test.cmake @@ -637,7 +637,10 @@ function(deal_ii_add_test _category _test_name _comparison_file) # Ensure that the test is not executed concurrently with any other # tests. # - set_tests_properties(${_test_full} PROPERTIES RUN_SERIAL TRUE) + set_tests_properties(${_test_full} PROPERTIES + RUN_SERIAL TRUE + ENVIRONMENT "TEST_IS_EXCLUSIVE=true" + ) else() # diff --git a/cmake/scripts/run_test.sh b/cmake/scripts/run_test.sh index cb1383a088..4da68f557c 100644 --- a/cmake/scripts/run_test.sh +++ b/cmake/scripts/run_test.sh @@ -91,8 +91,15 @@ case $STAGE in # cores/processors/sockets. Otherwise we run the risk that multiple # mpi tests (for example with two ranks) are all pinned to the same # processor core, bringing everything to a grinding halt. + # + # If the test runs exclusively, however, do not override MPI binding + # policies. This is important to ensure that performance tests are + # scheduled properly. + # export OMPI_MCA_rmaps_base_oversubscribe=1 - export OMPI_MCA_hwloc_base_binding_policy=none + if [ -z "${TEST_IS_EXCLUSIVE+x}" ]; then + export OMPI_MCA_hwloc_base_binding_policy=none + fi # # Kokkos parameters: