diff --git a/.github/actions/test-driver/action.yml b/.github/actions/test-driver/action.yml index 47c0fab83f..7e6b71bcb0 100644 --- a/.github/actions/test-driver/action.yml +++ b/.github/actions/test-driver/action.yml @@ -32,6 +32,8 @@ runs: ./test_driver.sh \ --testtype CUSTOM \ --env env/docker.sh \ + --buildjobs $(nproc) \ + --testjobs $(nproc) \ --tpls ${{ inputs.tpls }} \ --sunrealtype ${{ inputs.precision }} \ --indexsize ${{ inputs.indexsize }} diff --git a/.github/workflows/docs-pdfs.yml b/.github/workflows/docs-pdfs.yml index b2745ebb22..14ba48fff1 100644 --- a/.github/workflows/docs-pdfs.yml +++ b/.github/workflows/docs-pdfs.yml @@ -39,7 +39,7 @@ jobs: pip install -r doc/requirements.txt - name: Build docs - run: cd doc/install_guide && make latexpdf + run: cd doc/install_guide && make -j$(nproc) latexpdf - name: Archive files from failed build uses: actions/upload-artifact@v4 @@ -91,7 +91,7 @@ jobs: pip install -r doc/requirements.txt - name: Build docs - run: cd doc/${{matrix.package}}/guide && make latexpdf + run: cd doc/${{matrix.package}}/guide && make -j$(nproc) latexpdf # run: cd doc/${{matrix.package}}/${{matrix.type}} && make latexpdf - name: Archive files from failed build @@ -146,7 +146,7 @@ jobs: pip install -r doc/requirements.txt - name: Build docs - run: cd doc/${{matrix.package}}/examples && make latexpdf + run: cd doc/${{matrix.package}}/examples && make -j$(nproc) latexpdf - name: Archive files from failed build uses: actions/upload-artifact@v4 @@ -191,7 +191,7 @@ jobs: submodules: true - name: Build docs - run: cd doc/${{matrix.package}} && make ex + run: cd doc/${{matrix.package}} && make -j$(nproc) ex - name: Archive files from failed build uses: actions/upload-artifact@v4 diff --git a/.github/workflows/macos-latest.yml b/.github/workflows/macos-latest.yml index ae0eb137d2..86711ce552 100644 --- a/.github/workflows/macos-latest.yml +++ b/.github/workflows/macos-latest.yml @@ -35,10 +35,14 @@ jobs: - name: Build # Build your program with the given configuration - run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} + run: | + cmake \ + --build ${{github.workspace}}/build \ + --parallel $(sysctl -n hw.ncpu) \ + --config ${{env.BUILD_TYPE}} - name: Test working-directory: ${{github.workspace}}/build # Execute tests defined by the CMake configuration. # See https://cmake.org/cmake/help/latest/manual/ctest.1.html for more detail - run: ctest -C ${{env.BUILD_TYPE}} + run: ctest -C ${{env.BUILD_TYPE}} --parallel $(sysctl -n hw.ncpu) diff --git a/.github/workflows/ubuntu-clang-latest.yml b/.github/workflows/ubuntu-clang-latest.yml index 2031797a42..63028044ae 100644 --- a/.github/workflows/ubuntu-clang-latest.yml +++ b/.github/workflows/ubuntu-clang-latest.yml @@ -47,13 +47,18 @@ jobs: - name: Build # Build your program with the given configuration - run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} + run: | + cmake \ + --build ${{github.workspace}}/build \ + --parallel $(nproc) \ + --config ${{env.BUILD_TYPE}} - name: Test # Run logging tests run: | ctest \ --test-dir ${{github.workspace}}/build \ + --parallel $(nproc) \ --label-regex logging \ --verbose @@ -98,7 +103,11 @@ jobs: - name: Build # Build your program with the given configuration - run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} + run: | + cmake \ + --build ${{github.workspace}}/build \ + --parallel $(nproc) \ + --config ${{env.BUILD_TYPE}} - name: Archive build files from failed build uses: actions/upload-artifact@v4 diff --git a/.github/workflows/ubuntu-latest-oneapi.yml b/.github/workflows/ubuntu-latest-oneapi.yml index bebd04efad..06c13a33a8 100644 --- a/.github/workflows/ubuntu-latest-oneapi.yml +++ b/.github/workflows/ubuntu-latest-oneapi.yml @@ -42,4 +42,8 @@ jobs: -D ENABLE_SYCL=ON - name: Build - run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} + run: | + cmake \ + --build ${{github.workspace}}/build \ + --parallel $(nproc) \ + --config ${{env.BUILD_TYPE}} diff --git a/.github/workflows/windows-latest-intel.yml b/.github/workflows/windows-latest-intel.yml index 4e3f292e04..93fafcda11 100644 --- a/.github/workflows/windows-latest-intel.yml +++ b/.github/workflows/windows-latest-intel.yml @@ -33,18 +33,18 @@ jobs: run: cmake -G "Ninja" -B ${{github.workspace}}/build_static -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DCMAKE_C_FLAGS=-Wno-deprecated-declarations -DCMAKE_C_COMPILER=icx-cl -DCMAKE_CXX_COMPILER=icx-cl -DCMAKE_Fortran_COMPILER=ifx -DBUILD_STATIC_LIBS=ON -DBUILD_SHARED_LIBS=OFF -DBUILD_FORTRAN_MODULE_INTERFACE=ON -DSUNDIALS_BUILD_WITH_PROFILING=ON -DSUNDIALS_TEST_ENABLE_UNIT_TESTS=OFF -DEXAMPLES_ENABLE_CXX=ON - name: Build (Static) - run: cmake --build ${{github.workspace}}/build_static --verbose + run: cmake --build ${{github.workspace}}/build_static --parallel $NUMBER_OF_PROCESSORS --verbose - name: Test (Static) working-directory: ${{github.workspace}}/build_static - run: ctest -C ${{env.BUILD_TYPE}} --output-on-failure + run: ctest -C ${{env.BUILD_TYPE}} --output-on-failure --parallel $NUMBER_OF_PROCESSORS - name: Configure CMake (Shared) run: cmake -G "Ninja" -B ${{github.workspace}}/build_shared -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DCMAKE_C_FLAGS=-Wno-deprecated-declarations -DCMAKE_C_COMPILER=icx-cl -DCMAKE_CXX_COMPILER=icx-cl -DCMAKE_Fortran_COMPILER=ifx -DBUILD_STATIC_LIBS=OFF -DBUILD_SHARED_LIBS=ON -DBUILD_FORTRAN_MODULE_INTERFACE=ON -DSUNDIALS_BUILD_WITH_PROFILING=ON -DSUNDIALS_TEST_ENABLE_UNIT_TESTS=OFF -DEXAMPLES_ENABLE_CXX=ON - name: Build (Shared) - run: cmake --build ${{github.workspace}}/build_shared --verbose + run: cmake --build ${{github.workspace}}/build_shared --parallel $NUMBER_OF_PROCESSORS --verbose - name: Test (Shared) working-directory: ${{github.workspace}}/build_shared - run: ctest -C ${{env.BUILD_TYPE}} --output-on-failure + run: ctest -C ${{env.BUILD_TYPE}} --output-on-failure --parallel $NUMBER_OF_PROCESSORS diff --git a/.github/workflows/windows-latest-mingw.yml b/.github/workflows/windows-latest-mingw.yml index bb103d049f..e461375feb 100644 --- a/.github/workflows/windows-latest-mingw.yml +++ b/.github/workflows/windows-latest-mingw.yml @@ -64,12 +64,12 @@ jobs: - name: Build (Static) # Build program - run: cmake --build ${GITHUB_WORKSPACE}/build_static --verbose + run: cmake --build ${GITHUB_WORKSPACE}/build_static --parallel $NUMBER_OF_PROCESSORS --verbose - name: Test (Static) working-directory: ${{github.workspace}}/build_static # Execute tests - run: ctest --output-on-failure + run: ctest --output-on-failure --parallel $NUMBER_OF_PROCESSORS # TODO(CJB): shared libraries with the fortran interfaces turned on # fail to link correctly with this toolchain see https://github.com/LLNL/sundials/issues/507. @@ -91,9 +91,9 @@ jobs: - name: Build (Shared) # Build program - run: cmake --build ${GITHUB_WORKSPACE}/build_shared --verbose + run: cmake --build ${GITHUB_WORKSPACE}/build_shared --parallel $NUMBER_OF_PROCESSORS --verbose - name: Test (Shared) working-directory: ${{github.workspace}}/build_shared # Execute tests - run: ctest --output-on-failure + run: ctest --output-on-failure --parallel $NUMBER_OF_PROCESSORS diff --git a/.github/workflows/windows-latest.yml b/.github/workflows/windows-latest.yml index ea1c4bbcfc..ee648a2b42 100644 --- a/.github/workflows/windows-latest.yml +++ b/.github/workflows/windows-latest.yml @@ -23,8 +23,8 @@ jobs: run: cmake -G "Visual Studio 17 2022" -B ${{github.workspace}}/build -DSUNDIALS_BUILD_WITH_PROFILING=ON -DSUNDIALS_TEST_ENABLE_UNIT_TESTS=ON -DEXAMPLES_ENABLE_CXX=ON - name: Build - run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} --verbose + run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} --parallel $NUMBER_OF_PROCESSORS --verbose - name: Test working-directory: ${{github.workspace}}/build - run: ctest -C ${{env.BUILD_TYPE}} --output-on-failure + run: ctest -C ${{env.BUILD_TYPE}} --output-on-failure --parallel $NUMBER_OF_PROCESSORS