From: Hans Kristian Rosbach Date: Thu, 9 Feb 2023 00:51:09 +0000 (+0100) Subject: Adjust thread counts for compiles and tests to avoid under-utilization and congestion. X-Git-Tag: 2.0.7~12 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=bc915bf1589d2d5a01d5aab6eff514d58f89bbc7;p=thirdparty%2Fzlib-ng.git Adjust thread counts for compiles and tests to avoid under-utilization and congestion. The free Github Actions VMs have 2 cores, the dedicated s390x VM has 4 cores. --- diff --git a/.github/workflows/analyze.yml b/.github/workflows/analyze.yml index 17333d24..cbdea0e5 100644 --- a/.github/workflows/analyze.yml +++ b/.github/workflows/analyze.yml @@ -49,7 +49,7 @@ jobs: CI: true - name: Compile source code - run: cmake --build . --config Release > /dev/null + run: cmake --build . -j2 --config Release > /dev/null Clang: runs-on: ubuntu-latest @@ -75,4 +75,4 @@ jobs: - name: Compile source code run: | scan-build --status-bugs \ - cmake --build . --config Release > /dev/null + cmake --build . -j2 --config Release > /dev/null diff --git a/.github/workflows/cmake.yml b/.github/workflows/cmake.yml index 987e35f5..aaebc303 100644 --- a/.github/workflows/cmake.yml +++ b/.github/workflows/cmake.yml @@ -196,6 +196,8 @@ jobs: packages: qemu qemu-user gcc-s390x-linux-gnu g++-s390x-linux-gnu libc-dev-s390x-cross ldflags: -static codecov: ubuntu_gcc_s390x + # The dedicated test VM has 4 cores + parallels-jobs: 4 - name: Ubuntu GCC S390X No vectorized CRC32 ASAN os: ubuntu-latest @@ -204,6 +206,8 @@ jobs: packages: qemu qemu-user gcc-s390x-linux-gnu g++-s390x-linux-gnu libc-dev-s390x-cross ldflags: -static codecov: ubuntu_gcc_s390x_no_crc32 + # The dedicated test VM has 4 cores + parallels-jobs: 4 - name: Ubuntu GCC S390X DFLTCC ASAN os: z15 @@ -212,6 +216,8 @@ jobs: asan-options: detect_leaks=0 ldflags: -static codecov: ubuntu_gcc_s390x_dfltcc + # The dedicated test VM has 4 cores + parallels-jobs: 4 - name: Ubuntu GCC S390X DFLTCC Compat UBSAN os: z15 @@ -219,11 +225,15 @@ jobs: cmake-args: -DZLIB_COMPAT=ON -DWITH_DFLTCC_DEFLATE=ON -DWITH_DFLTCC_INFLATE=ON -DWITH_SANITIZER=Undefined ldflags: -static codecov: ubuntu_gcc_s390x_dfltcc_compat + # The dedicated test VM has 4 cores + parallels-jobs: 4 - name: Ubuntu Clang S390X DFLTCC MSAN os: z15 compiler: clang-11 cmake-args: -GNinja -DWITH_DFLTCC_DEFLATE=ON -DWITH_DFLTCC_INFLATE=ON -DWITH_SANITIZER=Memory + # The dedicated test VM has 4 cores + parallels-jobs: 4 - name: Ubuntu MinGW i686 os: ubuntu-22.04 @@ -447,12 +457,12 @@ jobs: CI: true - name: Compile source code - run: cmake --build ${{ matrix.build-dir || '.' }} --config ${{ matrix.build-config || 'Release' }} + run: cmake --build ${{ matrix.build-dir || '.' }} -j2 --config ${{ matrix.build-config || 'Release' }} - name: Run test cases # Don't run tests on Windows ARM if: runner.os != 'Windows' || contains(matrix.name, 'ARM') == false - run: ctest --verbose -C Release --output-on-failure --max-width 120 -j ${{ matrix.parallels-jobs || '6' }} + run: ctest --verbose -C Release --output-on-failure --max-width 120 -j ${{ matrix.parallels-jobs || '3' }} working-directory: ${{ matrix.build-dir || '.' }} env: ASAN_OPTIONS: ${{ matrix.asan-options || 'verbosity=0' }}:abort_on_error=1:halt_on_error=1 diff --git a/.github/workflows/libpng.yml b/.github/workflows/libpng.yml index 9118a96c..c5fea574 100644 --- a/.github/workflows/libpng.yml +++ b/.github/workflows/libpng.yml @@ -21,7 +21,7 @@ jobs: CI: true - name: Compile source code (zlib-ng) - run: cmake --build . --config Release + run: cmake --build . -j2 --config Release - name: Checkout repository (libpng) uses: actions/checkout@v3 @@ -43,9 +43,9 @@ jobs: CI: true - name: Compile source code (libpng) - run: cmake --build . --config Release + run: cmake --build . -j2 --config Release working-directory: libpng - name: Run test cases (libpng) - run: ctest -C Release --output-on-failure --max-width 120 + run: ctest -j2 -C Release --output-on-failure --max-width 120 working-directory: libpng diff --git a/.github/workflows/pigz.yml b/.github/workflows/pigz.yml index e90cb63a..be4e1ce5 100644 --- a/.github/workflows/pigz.yml +++ b/.github/workflows/pigz.yml @@ -89,11 +89,11 @@ jobs: CI: true - name: Compile source code - run: cmake --build . --config ${{ matrix.build-config || 'Release' }} + run: cmake --build . -j2 --config ${{ matrix.build-config || 'Release' }} working-directory: test/pigz - name: Run test cases - run: ctest --verbose -C Release --output-on-failure --max-width 120 -j ${{ matrix.parallels-jobs || '2' }} + run: ctest --verbose -C Release --output-on-failure --max-width 120 -j ${{ matrix.parallels-jobs || '3' }} working-directory: test/pigz - name: Generate coverage report diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 768cf48b..b64933cc 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -80,7 +80,7 @@ jobs: CI: true - name: Compile source code - run: cmake --build . --config Release --target install + run: cmake --build . -j2 --config Release --target install - name: Package release (Windows) if: runner.os == 'Windows' diff --git a/test/pkgcheck.sh b/test/pkgcheck.sh index 4c757dff..832df8db 100644 --- a/test/pkgcheck.sh +++ b/test/pkgcheck.sh @@ -125,7 +125,7 @@ cd btmp1 ;; esac ../configure $CONFIGURE_ARGS - make + make -j2 make install cd ..