Skip to content
Snippets Groups Projects
Commit a5e6df05 authored by Martyn Gigg's avatar Martyn Gigg
Browse files

Use a fixed number of omp threads for unit tests on builders

The default in conjunction with ctest -j produces a large number
of threads that compete with each other and give worse performance.
parent bed0955f
No related merge requests found
......@@ -342,7 +342,8 @@ fi
userconfig_dir=$HOME/.mantid
rm -fr $userconfig_dir
mkdir -p $userconfig_dir
touch $userconfig_dir/Mantid.user.properties
# use a fixed number of openmp threads to avoid overloading the system
echo MultiThreaded.MaxCores=2 > $userconfig_dir/Mantid.user.properties
if [[ ${DO_UNITTESTS} == true ]]; then
$CTEST_EXE -j${BUILD_THREADS:?} --schedule-random --output-on-failure
......
......@@ -170,7 +170,9 @@ del %USERPROPS%
set CONFIGDIR=%APPDATA%\mantidproject\mantid
rmdir /S /Q %CONFIGDIR%
mkdir %CONFIGDIR%
call cmake.exe -E touch %USERPROPS%
:: use a fixed number of openmp threads to avoid overloading the system
echo MultiThreaded.MaxCores=2 > %USERPROPS%
call ctest.exe -C %BUILD_CONFIG% -j%BUILD_THREADS% --schedule-random --output-on-failure
if ERRORLEVEL 1 exit /B %ERRORLEVEL%
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment