From 9e3b4300b494b41f227b8c4e670fbe126df5b5f3 Mon Sep 17 00:00:00 2001 From: David Gardner Date: Thu, 16 May 2024 12:44:41 -0700 Subject: [PATCH 1/2] CI: Combine actions (#486) Combine some actions so it's easier to trigger all the tests manually --- .github/workflows/extended-precision.yml | 52 ------------------- .github/workflows/single-precision.yml | 52 ------------------- ...double-precision.yml => ubuntu-latest.yml} | 19 +++++-- 3 files changed, 16 insertions(+), 107 deletions(-) delete mode 100644 .github/workflows/extended-precision.yml delete mode 100644 .github/workflows/single-precision.yml rename .github/workflows/{double-precision.yml => ubuntu-latest.yml} (71%) diff --git a/.github/workflows/extended-precision.yml b/.github/workflows/extended-precision.yml deleted file mode 100644 index 2c521b2fad..0000000000 --- a/.github/workflows/extended-precision.yml +++ /dev/null @@ -1,52 +0,0 @@ -# -name: Build and Test - Ubuntu/gcc extended precision (TPLs, no GPUs) - -on: - push: - branches: - - main - - develop - pull_request: - merge_group: - workflow_dispatch: - -concurrency: - group: ${{ github.workflow }}-${{ github.head_ref || github.ref_name }} - cancel-in-progress: true - -jobs: - build_and_test: - runs-on: ubuntu-latest - container: - image: ghcr.io/llnl/sundials-ci-int${{ matrix.indexsize }}-${{ matrix.precision }}:latest - options: --user root - strategy: - matrix: - indexsize: [32, 64] - precision: ['extended'] - steps: - - name: Checkout repository - uses: actions/checkout@v3 - with: - submodules: true - - name: Run test_driver.sh - uses: ./.github/actions/test-driver - with: - indexsize: ${{ matrix.indexsize }} - precision: ${{ matrix.precision }} - - name: Archive build files from failed build - uses: actions/upload-artifact@v3 - if: failure() - with: - name: build_files - path: | - ${{ github.workspace }}/test/build_* - !${{ github.workspace }}/test/build_*/Testing/output - - name: Archive output files from failed build - uses: actions/upload-artifact@v3 - if: failure() - with: - name: output_files - path: | - ${{ github.workspace }}/test/build_*/Testing/ - \ No newline at end of file diff --git a/.github/workflows/single-precision.yml b/.github/workflows/single-precision.yml deleted file mode 100644 index d986643256..0000000000 --- a/.github/workflows/single-precision.yml +++ /dev/null @@ -1,52 +0,0 @@ -# -name: Build and Test - Ubuntu/gcc single precision (TPLs, no GPUs) - -on: - push: - branches: - - main - - develop - pull_request: - merge_group: - workflow_dispatch: - -concurrency: - group: ${{ github.workflow }}-${{ github.head_ref || github.ref_name }} - cancel-in-progress: true - -jobs: - build_and_test: - runs-on: ubuntu-latest - container: - image: ghcr.io/llnl/sundials-ci-int${{ matrix.indexsize }}-${{ matrix.precision }}:latest - options: --user root - strategy: - matrix: - indexsize: [32, 64] - precision: ['single'] - steps: - - name: Checkout repository - uses: actions/checkout@v3 - with: - submodules: true - - name: Run test_driver.sh - uses: ./.github/actions/test-driver - with: - indexsize: ${{ matrix.indexsize }} - precision: ${{ matrix.precision }} - - name: Archive build files from failed build - uses: actions/upload-artifact@v3 - if: failure() - with: - name: build_files - path: | - ${{ github.workspace }}/test/build_* - !${{ github.workspace }}/test/build_*/Testing/output - - name: Archive output files from failed build - uses: actions/upload-artifact@v3 - if: failure() - with: - name: output_files - path: | - ${{ github.workspace }}/test/build_*/Testing/ - \ No newline at end of file diff --git a/.github/workflows/double-precision.yml b/.github/workflows/ubuntu-latest.yml similarity index 71% rename from .github/workflows/double-precision.yml rename to .github/workflows/ubuntu-latest.yml index cda708a4a9..f9f24a5dd0 100644 --- a/.github/workflows/double-precision.yml +++ b/.github/workflows/ubuntu-latest.yml @@ -1,5 +1,5 @@ # -name: Build and Test - Ubuntu/gcc double precision (TPLs, no GPUs) +name: Build and Test - Ubuntu/gcc (TPLs, no GPUs) on: push: @@ -24,8 +24,21 @@ jobs: max-parallel: 2 matrix: indexsize: [32, 64] - precision: ['double'] - buildtype: ['Debug', 'Release'] + # Disable extended tests until compiler warnings are addressed + precision: ['single', 'double'] + buildtype: ['Debug', 'Release', 'RelWithDebInfo'] + exclude: + - buildtype: Debug + precision: single + # - buildtype: Debug + # precision: extended + - buildtype: Release + precision: single + # - buildtype: Release + # precision: extended + - buildtype: RelWithDebInfo + precision: double + steps: - name: Checkout repository uses: actions/checkout@v3 From 9ebc406a2d373e2fae8716c8016e1d31725c3641 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Markus=20M=C3=BCtzel?= Date: Thu, 16 May 2024 21:45:23 +0200 Subject: [PATCH 2/2] CI (mingw): Install and build with SuiteSparse library (#432) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit MSYS2 follows a rolling release model. I.e., most of its packages are quite new most of the time. Adding the SuiteSparse libraries in the CI tests for MSYS2 might help to detect potentially API changes early. Signed-off-by: Markus Mützel Co-authored-by: Cody Balos Co-authored-by: David Gardner --- .github/workflows/windows-latest-mingw.yml | 37 ++++++++++++++++------ 1 file changed, 28 insertions(+), 9 deletions(-) diff --git a/.github/workflows/windows-latest-mingw.yml b/.github/workflows/windows-latest-mingw.yml index beb55d1efe..52cacd8504 100644 --- a/.github/workflows/windows-latest-mingw.yml +++ b/.github/workflows/windows-latest-mingw.yml @@ -14,27 +14,46 @@ env: BUILD_TYPE: Release jobs: - buil_and_test: + build_and_test: runs-on: windows-latest + defaults: + run: + # Use MSYS2 as default shell + shell: msys2 {0} + steps: - uses: actions/checkout@v3 - uses: msys2/setup-msys2@v2 with: msystem: mingw64 + update: true + release: false + install: >- + base-devel + mingw-w64-x86_64-cmake + mingw-w64-x86_64-cc + mingw-w64-x86_64-openblas + mingw-w64-x86_64-suitesparse - name: Configure CMake - # Configure CMake in a 'build' subdirectory. `CMAKE_BUILD_TYPE` is only required if you are using a single-configuration generator such as make. - # See https://cmake.org/cmake/help/latest/variable/CMAKE_BUILD_TYPE.html?highlight=cmake_build_type - run: cmake -G "MinGW Makefiles" -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DSUNDIALS_BUILD_WITH_PROFILING=ON -DSUNDIALS_LOGGING_LEVEL=2 -DSUNDIALS_TEST_UNITTESTS=OFF -DEXAMPLES_ENABLE_CXX=ON + # Configure CMake in a 'build' subdirectory + run: | + cmake \ + -B ${GITHUB_WORKSPACE}/build \ + -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} \ + -DSUNDIALS_BUILD_WITH_PROFILING=ON \ + -DSUNDIALS_LOGGING_LEVEL=2 \ + -DSUNDIALS_TEST_UNITTESTS=OFF \ + -DEXAMPLES_ENABLE_CXX=ON \ + -DENABLE_KLU=ON - name: Build - # Build your program with the given configuration - run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} + # Build your program + run: cmake --build ${GITHUB_WORKSPACE}/build - 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}} + # Execute tests + run: ctest