diff options
Diffstat (limited to '.github/workflows')
-rw-r--r-- | .github/workflows/ci.yml | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 95c6c035c..2a41efb59 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -82,6 +82,7 @@ jobs: # # https://github.com/actions/runner/blob/master/docs/adrs/0278-env-context.md#dont-populate-the-env-context-with-environment-variables-from-runner-machine echo "image_version=$ImageVersion" >> $GITHUB_ENV + echo "num_proc=$(nproc)" >> $GITHUB_ENV echo "/usr/lib/ccache" >> $GITHUB_PATH # Note: macOS comes with a libedit; it does not need to brew-installed @@ -103,6 +104,7 @@ jobs: # # https://github.com/actions/runner/blob/master/docs/adrs/0278-env-context.md#dont-populate-the-env-context-with-environment-variables-from-runner-machine echo "image_version=$ImageVersion" >> $GITHUB_ENV + echo "num_proc=$(sysctl -n hw.logicalcpu)" >> $GITHUB_ENV echo "/usr/local/opt/ccache/libexec" >> $GITHUB_PATH - name: Install Python Dependencies @@ -191,14 +193,14 @@ jobs: --werror - name: Build - run: make -j2 + run: make -j${{ env.num_proc }} working-directory: build - name: ccache Statistics run: ccache -s - name: Run CTest - run: make -j2 check + run: make -j${{ env.num_proc }} check env: ARGS: --output-on-failure -LE regress[${{ matrix.exclude_regress }}] CVC5_REGRESSION_ARGS: --no-early-exit @@ -207,7 +209,7 @@ jobs: - name: Install Check run: | - make -j2 install + make -j${{ env.num_proc }} install echo -e "#include <cvc5/cvc5.h>\nint main() { cvc5::api::Solver s; return 0; }" > /tmp/test.cpp g++ -std=c++11 /tmp/test.cpp -I install/include -L install/lib -lcvc5 working-directory: build @@ -225,14 +227,14 @@ jobs: mkdir build cd build cmake .. -DCMAKE_PREFIX_PATH=$(pwd)/../../build/install/lib/cmake - make -j2 - ctest -j2 --output-on-failure + make -j${{ env.num_proc }} + ctest -j${{ env.num_proc }} --output-on-failure working-directory: examples - name: Build Documentation if: matrix.build-documentation run: | - make -j2 docs-gh + make -j${{ env.num_proc }} docs-gh if [ "${{ github.event_name }}" == "pull_request" ] ; then echo "${{ github.event.number }}" > docs/sphinx-gh/prnum fi |