File tree Expand file tree Collapse file tree 7 files changed +21
-24
lines changed Expand file tree Collapse file tree 7 files changed +21
-24
lines changed Original file line number Diff line number Diff line change 39
39
credentials :
40
40
username : ${{ github.actor }}
41
41
password : ${{ secrets.github_token }}
42
- options : --cpus 2
42
+ options : --cpus 4
43
43
steps :
44
44
- name : Checkout
45
45
uses : actions/checkout@main
55
55
- name : Build and check
56
56
uses : ./.github/actions/build_and_check
57
57
env :
58
- build_procs : 2
59
- check_procs : 2
58
+ build_procs : 4
59
+ check_procs : 4
60
60
myconfig : ' maxset'
61
61
with_ccache : ' true'
62
62
with_cuda : ' false'
78
78
credentials :
79
79
username : ${{ github.actor }}
80
80
password : ${{ secrets.github_token }}
81
- options : --cpus 2
81
+ options : --cpus 4
82
82
steps :
83
83
- name : Checkout
84
84
uses : actions/checkout@main
94
94
- name : Build and check
95
95
uses : ./.github/actions/build_and_check
96
96
env :
97
- build_procs : 2
98
- check_procs : 2
97
+ build_procs : 4
98
+ check_procs : 4
99
99
myconfig : ' maxset'
100
100
with_ccache : ' true'
101
101
with_cuda : ' false'
Original file line number Diff line number Diff line change @@ -372,13 +372,16 @@ else()
372
372
endif ()
373
373
374
374
# OpenMPI checks the number of processes against the number of CPUs
375
- set (ESPRESSO_MPIEXEC_OVERSUBSCRIBE "" )
375
+ set (ESPRESSO_MPIEXEC_PREFLAGS "" )
376
376
# Open MPI 4.x has a bug on NUMA archs that prevents running in singleton mode
377
377
set (ESPRESSO_MPIEXEC_GUARD_SINGLETON_NUMA OFF )
378
378
set (ESPRESSO_CPU_MODEL_NAME_OMPI_SINGLETON_NUMA_PATTERN "AMD (EPYC|Ryzen)" )
379
379
380
380
if ("${ESPRESSO_MPIEXEC_VENDOR} " STREQUAL "OpenMPI" )
381
- set (ESPRESSO_MPIEXEC_OVERSUBSCRIBE "-oversubscribe" )
381
+ list (APPEND ESPRESSO_MPIEXEC_PREFLAGS "-oversubscribe" )
382
+ if (ESPRESSO_INSIDE_DOCKER )
383
+ list (APPEND ESPRESSO_MPIEXEC_PREFLAGS "--bind-to" "none" )
384
+ endif ()
382
385
if (${ESPRESSO_MPIEXEC_VERSION} VERSION_LESS 5.0 )
383
386
if (NOT DEFINED ESPRESSO_CPU_MODEL_NAME )
384
387
if (CMAKE_SYSTEM_NAME STREQUAL Linux )
Original file line number Diff line number Diff line change @@ -52,7 +52,7 @@ function(ESPRESSO_UNIT_TEST)
52
52
set (TEST_NUM_PROC ${ESPRESSO_TEST_NP} )
53
53
endif ()
54
54
espresso_set_mpiexec_tmpdir (${TEST_NAME} )
55
- add_test (${TEST_NAME} ${MPIEXEC} ${ESPRESSO_MPIEXEC_OVERSUBSCRIBE }
55
+ add_test (${TEST_NAME} ${MPIEXEC} ${ESPRESSO_MPIEXEC_PREFLAGS }
56
56
${MPIEXEC_NUMPROC_FLAG} ${TEST_NUM_PROC} ${MPIEXEC_PREFLAGS}
57
57
${ESPRESSO_MPIEXEC_TMPDIR} ${CMAKE_CURRENT_BINARY_DIR} /${TEST_NAME}
58
58
${MPIEXEC_POSTFLAGS} )
Original file line number Diff line number Diff line change @@ -79,20 +79,14 @@ ci_procs=2
79
79
if [ " ${GITLAB_CI} " = " true" ]; then
80
80
if [[ " ${OSTYPE} " == " linux-gnu" * ]]; then
81
81
# Linux runner
82
- if grep -q " i7-3820" /proc/cpuinfo; then
83
- # communication bottleneck for more than 2 cores on Intel i7-3820
84
- ci_procs=2
85
- else
86
- ci_procs=4
87
- fi
82
+ ci_procs=4
88
83
elif [[ " ${OSTYPE} " == " darwin" * ]]; then
89
84
# macOS runner
90
- ci_procs=2
85
+ ci_procs=4
91
86
fi
92
87
elif [ " ${GITHUB_ACTIONS} " = " true" ]; then
93
- # GitHub Actions only provide 1 core; request 2 cores to run tests
94
- # in parallel (OpenMPI allows oversubscription)
95
- ci_procs=2
88
+ # GitHub Actions provide 4 cores
89
+ ci_procs=4
96
90
else
97
91
ci_procs=$( nproc)
98
92
fi
Original file line number Diff line number Diff line change @@ -28,9 +28,9 @@ if(EXISTS ${MPIEXEC})
28
28
OUTPUT_VARIABLE mpi_version_output ERROR_VARIABLE mpi_version_output )
29
29
if (mpi_version_result EQUAL 0 AND mpi_version_output MATCHES
30
30
"\\ (Open(RTE| MPI)\\ ) ([3-9]\\ .|1[0-9])" )
31
- set (ESPRESSO_MPIEXEC_OVERSUBSCRIBE "-oversubscribe" )
31
+ set (ESPRESSO_MPIEXEC_PREFLAGS "-oversubscribe" )
32
32
else ()
33
- set (ESPRESSO_MPIEXEC_OVERSUBSCRIBE "" )
33
+ set (ESPRESSO_MPIEXEC_PREFLAGS "" )
34
34
endif ()
35
35
endif ()
36
36
@@ -86,7 +86,7 @@ function(PYTHON_BENCHMARK)
86
86
add_test (
87
87
NAME ${BENCHMARK_TEST_NAME}
88
88
COMMAND
89
- ${MPIEXEC} ${ESPRESSO_MPIEXEC_OVERSUBSCRIBE } ${MPIEXEC_NUMPROC_FLAG}
89
+ ${MPIEXEC} ${ESPRESSO_MPIEXEC_PREFLAGS } ${MPIEXEC_NUMPROC_FLAG}
90
90
${BENCHMARK_NUM_PROC} ${MPIEXEC_PREFLAGS}
91
91
${CMAKE_BINARY_DIR} /pypresso ${BENCHMARK_FILE} ${BENCHMARK_ARGUMENTS}
92
92
${MPIEXEC_POSTFLAGS} )
Original file line number Diff line number Diff line change @@ -92,7 +92,7 @@ function(python_test)
92
92
add_test (
93
93
NAME ${TEST_NAME}
94
94
COMMAND
95
- ${MPIEXEC} ${ESPRESSO_MPIEXEC_OVERSUBSCRIBE } ${MPIEXEC_NUMPROC_FLAG}
95
+ ${MPIEXEC} ${ESPRESSO_MPIEXEC_PREFLAGS } ${MPIEXEC_NUMPROC_FLAG}
96
96
${TEST_NUM_PROC} ${MPIEXEC_PREFLAGS} ${ESPRESSO_MPIEXEC_TMPDIR}
97
97
${CMAKE_BINARY_DIR} /pypresso ${PYPRESSO_OPTIONS}
98
98
${TEST_FILE_CONFIGURED} ${TEST_ARGUMENTS} ${MPIEXEC_POSTFLAGS} )
Original file line number Diff line number Diff line change 8
8
"gpus" : [
9
9
{
10
10
"id" : " 0" ,
11
- "slots" : 4
11
+ "slots" : 8
12
12
}
13
13
]
14
14
}
You can’t perform that action at this time.
0 commit comments