-
Type:
Improvement
-
Resolution: Unresolved
-
Priority:
Major - P3
-
None
-
Affects Version/s: None
-
Component/s: None
-
StorEng - Defined Pipeline
-
2
Currently the number of cores is determined by greping //proc/cpuinfo:
evergreen.yml: CMAKE_BIN=$CMAKE ./configure_combinations.sh -g="${cmake_generator|Ninja}" -j=$(grep -c ^processor /proc/cpuinfo) 2>&1 evergreen.yml: smp_command: -j $(echo "`grep -c ^processor /proc/cpuinfo` * 2" | bc) evergreen.yml: smp_command: -j $(grep -c ^processor /proc/cpuinfo) evergreen.yml: smp_command: -j $(echo $(grep -c ^processor /proc/cpuinfo) / 4 | bc) evergreen.yml: smp_command: -j $(echo $(grep -c ^processor /proc/cpuinfo) / 2 | bc) evergreen.yml: smp_command: -j $(echo "`grep -c ^processor /proc/cpuinfo` * 2" | bc) evergreen_develop.yml: smp_command: -j $(echo "`grep -c ^processor /proc/cpuinfo` * 2" | bc)
This could be simplified by replacing the above with nproc.
Also greping /proc/cpuinfo will return the number of processors reported by the system. Which is *not* necessarily the number of processors available to the process, which could be restricted with a mechanism such as cgroups. While this scenario seems unlikely, it should be considered/validated.