diff --git a/.github/workflows/hipo-macos.yml b/.github/workflows/hipo-macos.yml deleted file mode 100644 index f3efcc4c1d..0000000000 --- a/.github/workflows/hipo-macos.yml +++ /dev/null @@ -1,39 +0,0 @@ -name: hipo-macos - -on: [push, pull_request] - -jobs: - macos: - runs-on: macos-latest - strategy: - fail-fast: false - matrix: - config: [Release, Debug] - all_tests: [ON, OFF] - - steps: - - uses: actions/checkout@v4 - - - name: Create Build Environment - run: cmake -E make_directory ${{runner.workspace}}/build - - - name: Configure CMake - working-directory: ${{runner.workspace}}/build - run: | - cmake $GITHUB_WORKSPACE -DHIPO=ON \ - -DCMAKE_BUILD_TYPE=${{ matrix.config }} \ - -DALL_TESTS=${{ matrix.all_tests }} - - - name: Build - working-directory: ${{runner.workspace}}/build - run: | - cmake --build . --parallel - - - name: Test executable - working-directory: ${{runner.workspace}}/build - run: ./bin/highs --solver=hipo $GITHUB_WORKSPACE/check/instances/afiro.mps - - - name: Ctest - working-directory: ${{runner.workspace}}/build - run: | - ctest --parallel --timeout 300 --output-on-failure diff --git a/.github/workflows/hipo-ubuntu-cblas.yml b/.github/workflows/hipo-ubuntu-cblas.yml deleted file mode 100644 index a8160bd974..0000000000 --- a/.github/workflows/hipo-ubuntu-cblas.yml +++ /dev/null @@ -1,107 +0,0 @@ -name: hipo-ubuntu-cblas - -on: [push, pull_request] - -jobs: - ubuntu_gh: - runs-on: ubuntu-latest - strategy: - fail-fast: false - matrix: - # config: [Release, Debug] - config: [Release] - all_tests: [OFF] - - steps: - - uses: actions/checkout@v4 - - - name: Checkout GKlib - uses: actions/checkout@v4 - with: - repository: KarypisLab/GKlib - ref: master - path: GKlib - - - name: Checkout METIS - uses: actions/checkout@v4 - with: - repository: KarypisLab/METIS - ref: master - path: METIS - - - name: Create installs dir - working-directory: ${{runner.workspace}} - run: | - mkdir installs - ls - - - name: Install GKlib - run: | - cd GKlib - make config shared=1 prefix=${{runner.workspace}}/installs - make - make install - - # - name: Check installs - # working-directory: ${{runner.workspace}} - # run: | - # cd installs - # ls - # ls lib - - - name: Copy GKlib shared (bug) - working-directory: ${{runner.workspace}} - run: | - cd installs - cd lib - ln libGKlib.so.0 libGKlib.so - ls - - - name: Install METIS - run: | - cd METIS - make config shared=1 prefix=${{runner.workspace}}/installs - make - make install - - # no default blas available on runner - - - name: Cache APT packages - uses: actions/cache@v4 - with: - path: | - /var/cache/apt/archives - /var/lib/apt/lists - key: ${{ runner.os }}-apt-libblas - - - name: Install BLAS - shell: bash - run: | - sudo apt update - sudo apt install libblas-dev - - - name: Create Build Environment - run: cmake -E make_directory ${{runner.workspace}}/build - - - name: Configure CMake - working-directory: ${{runner.workspace}}/build - run: | - cmake $GITHUB_WORKSPACE -DHIPO=ON \ - -DCMAKE_BUILD_TYPE=${{ matrix.config }} \ - -DALL_TESTS=${{ matrix.all_tests }} \ - -DMETIS_ROOT=${{runner.workspace}}/installs \ - -DGKLIB_ROOT=${{runner.workspace}}/installs - - - name: Build - working-directory: ${{runner.workspace}}/build - run: | - cmake --build . --parallel - - - name: Test executable - working-directory: ${{runner.workspace}}/build - run: ./bin/highs --solver=hipo $GITHUB_WORKSPACE/check/instances/afiro.mps - - - name: Ctest - working-directory: ${{runner.workspace}}/build - run: | - ctest --parallel --timeout 300 --output-on-failure diff --git a/.github/workflows/hipo-win.yml b/.github/workflows/hipo-win.yml deleted file mode 100644 index a6e3672262..0000000000 --- a/.github/workflows/hipo-win.yml +++ /dev/null @@ -1,208 +0,0 @@ -name: hipo-win - -on: [push, pull_request] - -jobs: - win-vcpkg: - runs-on: windows-latest - strategy: - fail-fast: false - matrix: - config: [Release, Debug] - all_tests: [OFF] - - steps: - - uses: actions/checkout@v4 - - - name: Checkout metis overlay ports - uses: actions/checkout@v4 - with: - repository: galabovaa/metis-overlay-ports - ref: main - path: overlay-ports - - - name: List overlay contents - shell: pwsh - run: Get-ChildItem -Recurse "$env:GITHUB_WORKSPACE/overlay-ports" - - - name: Install metis with overlay port - shell: pwsh - run: | - vcpkg install metis gklib ` - --overlay-ports="$env:GITHUB_WORKSPACE/overlay-ports/ports/metis" ` - --overlay-ports="$env:GITHUB_WORKSPACE/overlay-ports/ports/gklib" - - - name: Install OpenBLAS - shell: pwsh - run: vcpkg install openblas[threads] - - - name: Configure CMake - shell: pwsh - run: | - cmake ` - -S "$env:GITHUB_WORKSPACE" ` - -B "${{ runner.workspace }}/build" ` - -DHIPO=ON ` - -DCMAKE_TOOLCHAIN_FILE="C:/vcpkg/scripts/buildsystems/vcpkg.cmake" ` - -DALL_TESTS=${{ matrix.all_tests }} - - - name: Build - shell: pwsh - working-directory: ${{runner.workspace}}/build - run: | - cmake --build . --parallel --config ${{ matrix.config }} - - - name: Test executable - shell: pwsh - working-directory: ${{runner.workspace}}/build - run: | - & ".\${{ matrix.config }}\bin\highs.exe" --solver=hipo ` - "$env:GITHUB_WORKSPACE/check/instances/afiro.mps" - - - name: Ctest - shell: pwsh - working-directory: ${{runner.workspace}}/build - run: | - ctest --parallel --timeout 300 --output-on-failure -C ${{ matrix.config }} - - win-510-ts: - runs-on: windows-latest - strategy: - fail-fast: false - matrix: - config: [Release, Debug] - all_tests: [ON, OFF] - - steps: - - uses: actions/checkout@v4 - - - name: Checkout METIS - uses: actions/checkout@v4 - with: - repository: galabovaa/METIS - ref: 510-ts - path: METIS - - - name: Create installs dir - working-directory: ${{runner.workspace}} - run: | - ls - mkdir installs - ls - - - name: Install METIS - shell: pwsh - run: | - cd METIS - pwd - cmake -S. -B build ` - -DGKLIB_PATH="$env:GITHUB_WORKSPACE/METIS/GKlib" ` - -DCMAKE_INSTALL_PREFIX="${{ runner.workspace }}/installs" ` - -DCMAKE_BUILD_TYPE=${{ matrix.config }} - cmake --build build --parallel --config ${{ matrix.config }} - cmake --install build --config ${{ matrix.config }} - - - name: Install OpenBLAS - shell: pwsh - run: vcpkg install openblas[threads] - - - name: Configure CMake - shell: pwsh - run: | - cmake ` - -S "$env:GITHUB_WORKSPACE" ` - -B "${{ runner.workspace }}/build" ` - -DHIPO=ON ` - -DCMAKE_TOOLCHAIN_FILE="C:/vcpkg/scripts/buildsystems/vcpkg.cmake" ` - -DMETIS_ROOT="${{ runner.workspace }}/installs" ` - -DALL_TESTS=${{ matrix.all_tests }} - - - name: Build - shell: pwsh - working-directory: ${{runner.workspace}}/build - run: | - cmake --build . --parallel --config ${{ matrix.config }} - - - name: Test executable - shell: pwsh - working-directory: ${{runner.workspace}}/build - run: | - & ".\${{ matrix.config }}\bin\highs.exe" --solver=hipo ` - "$env:GITHUB_WORKSPACE/check/instances/afiro.mps" - - - name: Ctest - shell: pwsh - working-directory: ${{runner.workspace}}/build - run: | - ctest --parallel --timeout 300 --output-on-failure -C ${{ matrix.config }} - - win-521-ts: - runs-on: windows-latest - strategy: - fail-fast: false - matrix: - config: [Release, Debug] - all_tests: [ON, OFF] - - steps: - - uses: actions/checkout@v4 - - - name: Checkout METIS - uses: actions/checkout@v4 - with: - repository: galabovaa/METIS - ref: 521-ts - path: METIS - - - name: Create installs dir - working-directory: ${{runner.workspace}} - run: | - ls - mkdir installs - ls - - - name: Install METIS - shell: pwsh - run: | - cd METIS - pwd - cmake -S. -B build ` - -DGKLIB_PATH="$env:GITHUB_WORKSPACE/METIS/GKlib" ` - -DCMAKE_INSTALL_PREFIX="${{ runner.workspace }}/installs" ` - -DCMAKE_BUILD_TYPE=${{ matrix.config }} - cmake --build build --parallel --config ${{ matrix.config }} - cmake --install build --config ${{ matrix.config }} - - - name: Install OpenBLAS - shell: pwsh - run: vcpkg install openblas[threads] - - - name: Configure CMake - shell: pwsh - run: | - cmake ` - -S "$env:GITHUB_WORKSPACE" ` - -B "${{ runner.workspace }}/build" ` - -DHIPO=ON ` - -DCMAKE_TOOLCHAIN_FILE="C:/vcpkg/scripts/buildsystems/vcpkg.cmake" ` - -DMETIS_ROOT="${{ runner.workspace }}/installs" ` - -DALL_TESTS=${{ matrix.all_tests }} - - - name: Build - shell: pwsh - working-directory: ${{runner.workspace}}/build - run: | - cmake --build . --parallel --config ${{ matrix.config }} - - - name: Test executable - shell: pwsh - working-directory: ${{runner.workspace}}/build - run: | - & ".\${{ matrix.config }}\bin\highs.exe" --solver=hipo ` - "$env:GITHUB_WORKSPACE/check/instances/afiro.mps" - - - name: Ctest - shell: pwsh - working-directory: ${{runner.workspace}}/build - run: | - ctest --parallel --timeout 300 --output-on-failure -C ${{ matrix.config }} diff --git a/.github/workflows/hipo-ubuntu.yml b/.github/workflows/hipo.yml similarity index 53% rename from .github/workflows/hipo-ubuntu.yml rename to .github/workflows/hipo.yml index 84aab111d8..84727731ec 100644 --- a/.github/workflows/hipo-ubuntu.yml +++ b/.github/workflows/hipo.yml @@ -1,8 +1,105 @@ -name: hipo-ubuntu +name: hipo on: [push, pull_request] jobs: + win-vcpkg: + runs-on: windows-latest + strategy: + fail-fast: false + matrix: + config: [Release, Debug] + all_tests: [OFF] + + steps: + - uses: actions/checkout@v4 + + - name: Checkout metis overlay ports + uses: actions/checkout@v4 + with: + repository: galabovaa/metis-overlay-ports + ref: main + path: overlay-ports + + - name: List overlay contents + shell: pwsh + run: Get-ChildItem -Recurse "$env:GITHUB_WORKSPACE/overlay-ports" + + - name: Install metis with overlay port + shell: pwsh + run: | + vcpkg install metis gklib ` + --overlay-ports="$env:GITHUB_WORKSPACE/overlay-ports/ports/metis" ` + --overlay-ports="$env:GITHUB_WORKSPACE/overlay-ports/ports/gklib" + + - name: Install OpenBLAS + shell: pwsh + run: vcpkg install openblas[threads] + + - name: Configure CMake + shell: pwsh + run: | + cmake ` + -S "$env:GITHUB_WORKSPACE" ` + -B "${{ runner.workspace }}/build" ` + -DHIPO=ON ` + -DCMAKE_TOOLCHAIN_FILE="C:/vcpkg/scripts/buildsystems/vcpkg.cmake" ` + -DALL_TESTS=${{ matrix.all_tests }} + + - name: Build + shell: pwsh + working-directory: ${{runner.workspace}}/build + run: | + cmake --build . --parallel --config ${{ matrix.config }} + + - name: Test executable + shell: pwsh + working-directory: ${{runner.workspace}}/build + run: | + & ".\${{ matrix.config }}\bin\highs.exe" --solver=hipo ` + "$env:GITHUB_WORKSPACE/check/instances/afiro.mps" + + - name: Ctest + shell: pwsh + working-directory: ${{runner.workspace}}/build + run: | + ctest --parallel --timeout 300 --output-on-failure -C ${{ matrix.config }} + + macos: + runs-on: macos-latest + strategy: + fail-fast: false + matrix: + config: [Release, Debug] + all_tests: [ON, OFF] + + steps: + - uses: actions/checkout@v4 + + - name: Create Build Environment + run: cmake -E make_directory ${{runner.workspace}}/build + + - name: Configure CMake + working-directory: ${{runner.workspace}}/build + run: | + cmake $GITHUB_WORKSPACE -DHIPO=ON \ + -DCMAKE_BUILD_TYPE=${{ matrix.config }} \ + -DALL_TESTS=${{ matrix.all_tests }} + + - name: Build + working-directory: ${{runner.workspace}}/build + run: | + cmake --build . --parallel + + - name: Test executable + working-directory: ${{runner.workspace}}/build + run: ./bin/highs --solver=hipo $GITHUB_WORKSPACE/check/instances/afiro.mps + + - name: Ctest + working-directory: ${{runner.workspace}}/build + run: | + ctest --parallel --timeout 300 --output-on-failure + ubuntu_gh: runs-on: ubuntu-latest strategy: @@ -105,56 +202,23 @@ jobs: run: | ctest --parallel --timeout 300 --output-on-failure - ubuntu_510-ts: + ubuntu_cblas: runs-on: ubuntu-latest strategy: fail-fast: false matrix: - config: [Release, Debug] - all_tests: [ON, OFF] + # config: [Release, Debug] + config: [Release] + all_tests: [OFF] steps: - uses: actions/checkout@v4 - - name: Checkout METIS - uses: actions/checkout@v4 - with: - repository: galabovaa/METIS - ref: 510-ts - path: METIS - - - name: Create installs dir - working-directory: ${{runner.workspace}} - run: | - mkdir installs - ls - - - name: Install METIS - run: | - cmake \ - -S $GITHUB_WORKSPACE/METIS \ - -B build \ - -DGKLIB_PATH=${{ github.workspace }}/METIS/GKlib \ - -DCMAKE_INSTALL_PREFIX=${{ runner.workspace }}/installs \ - -DCMAKE_BUILD_TYPE=${{ matrix.config }} - cmake --build build --parallel - cmake --install build - - # no default blas available on runner - - - name: Cache APT packages - uses: actions/cache@v4 - with: - path: | - /var/cache/apt/archives - /var/lib/apt/lists - key: ${{ runner.os }}-apt-libopenblas - - - name: Install OpenBLAS + - name: Install BLAS shell: bash run: | sudo apt update - sudo apt install libopenblas-dev + sudo apt install libblas-dev - name: Create Build Environment run: cmake -E make_directory ${{runner.workspace}}/build @@ -164,8 +228,7 @@ jobs: run: | cmake $GITHUB_WORKSPACE -DHIPO=ON \ -DCMAKE_BUILD_TYPE=${{ matrix.config }} \ - -DALL_TESTS=${{ matrix.all_tests }} \ - -DMETIS_ROOT=${{runner.workspace}}/installs + -DALL_TESTS=${{ matrix.all_tests }} - name: Build working-directory: ${{runner.workspace}}/build @@ -181,78 +244,80 @@ jobs: run: | ctest --parallel --timeout 300 --output-on-failure - ubuntu_521-ts: - runs-on: ubuntu-latest + ubuntu_debug: + runs-on: ${{ matrix.os }} + strategy: fail-fast: false matrix: - config: [Release, Debug] - all_tests: [ON, OFF] + os: [ubuntu-latest] + config: [Debug] + all_tests: [ON] steps: - uses: actions/checkout@v4 - - name: Checkout METIS - uses: actions/checkout@v4 - with: - repository: galabovaa/METIS - ref: 521-ts - path: METIS + - name: Create Build Environment + run: cmake -E make_directory ${{runner.workspace}}/build - - name: Create installs dir - working-directory: ${{runner.workspace}} + - name: Configure CMake + working-directory: ${{runner.workspace}}/build run: | - mkdir installs - ls + cmake $GITHUB_WORKSPACE -DHIPO=ON -DBUILD_OPENBLAS=ON \ + -DALL_TESTS=${{ matrix.all_tests }} - - name: Install METIS + - name: Build + working-directory: ${{runner.workspace}}/build run: | - cmake \ - -S $GITHUB_WORKSPACE/METIS \ - -B build \ - -DGKLIB_PATH=${{ github.workspace }}/METIS/GKlib \ - -DCMAKE_INSTALL_PREFIX=${{ runner.workspace }}/installs \ - -DCMAKE_BUILD_TYPE=${{ matrix.config }} - cmake --build build --parallel - cmake --install build + cmake --build . -j2 - # no default blas available on runner - - - name: Cache APT packages - uses: actions/cache@v4 - with: - path: | - /var/cache/apt/archives - /var/lib/apt/lists - key: ${{ runner.os }}-apt-libopenblas + - name: Test executable + working-directory: ${{runner.workspace}}/build + run: ./bin/highs --solver=hipo $GITHUB_WORKSPACE/check/instances/afiro.mps - - name: Install OpenBLAS - shell: bash + - name: Ctest + working-directory: ${{runner.workspace}}/build run: | - sudo apt update - sudo apt install libopenblas-dev + ctest --parallel --timeout 300 --output-on-failure - - name: Create Build Environment - run: cmake -E make_directory ${{runner.workspace}}/build + windows_debug: + runs-on: [windows-latest] + strategy: + fail-fast: false + matrix: + config: [Debug] + all_tests: [ON] + arch: ["x64"] + + steps: + - uses: actions/checkout@v4 - name: Configure CMake - working-directory: ${{runner.workspace}}/build + shell: pwsh run: | - cmake $GITHUB_WORKSPACE -DHIPO=ON \ - -DCMAKE_BUILD_TYPE=${{ matrix.config }} \ - -DALL_TESTS=${{ matrix.all_tests }} \ - -DMETIS_ROOT=${{runner.workspace}}/installs + cmake ` + -S "$env:GITHUB_WORKSPACE" ` + -B "${{ runner.workspace }}/build" ` + -A ${{ matrix.arch }} ` + -DHIPO=ON ` + -DALL_TESTS=${{ matrix.all_tests }} ` + -DBUILD_OPENBLAS=ON - name: Build + shell: pwsh working-directory: ${{runner.workspace}}/build run: | - cmake --build . --parallel + cmake --build . --parallel --config ${{ matrix.config }} - name: Test executable + shell: pwsh working-directory: ${{runner.workspace}}/build - run: ./bin/highs --solver=hipo $GITHUB_WORKSPACE/check/instances/afiro.mps + run: | + & ".\${{ matrix.config }}\bin\highs.exe" --solver=hipo ` + "$env:GITHUB_WORKSPACE/check/instances/afiro.mps" - name: Ctest + shell: pwsh working-directory: ${{runner.workspace}}/build run: | - ctest --parallel --timeout 300 --output-on-failure + ctest --parallel --timeout 300 --output-on-failure -C ${{ matrix.config }} \ No newline at end of file diff --git a/.github/workflows/release-cpack.yml b/.github/workflows/release-cpack.yml index fbe1bbd273..12a679e8f8 100644 --- a/.github/workflows/release-cpack.yml +++ b/.github/workflows/release-cpack.yml @@ -261,7 +261,8 @@ jobs: - uses: actions/checkout@v3 - name: Build run: | - cmake -B build -G "Visual Studio 17 2022" -A ${{ matrix.arch }} + cmake -B build -G "Visual Studio 17 2022" -A ${{ matrix.arch }} ` + -DBUILD_SHARED_LIBS=ON cmake --build build --config Release --parallel cd build cpack -C Release diff --git a/.github/workflows/valgrind-hipo-md.yml b/.github/workflows/valgrind-hipo-md.yml deleted file mode 100644 index 469d87632e..0000000000 --- a/.github/workflows/valgrind-hipo-md.yml +++ /dev/null @@ -1,316 +0,0 @@ -name: valgrind-hipo-md - -on: [push, pull_request] - -jobs: - unit_tests: - runs-on: ubuntu-latest - - steps: - - uses: actions/checkout@v4 - - - name: Install Valgrind - run: sudo apt-get update && sudo apt-get install valgrind - - - name: Checkout METIS - uses: actions/checkout@v4 - with: - repository: galabovaa/METIS - ref: 521-ts - path: METIS - - - name: Create installs dir - working-directory: ${{runner.workspace}} - run: | - mkdir installs - ls - - - name: Install METIS - run: | - cmake \ - -S $GITHUB_WORKSPACE/METIS \ - -B build \ - -DCMAKE_BUILD_TYPE=Debug \ - -DGKLIB_PATH=${{ github.workspace }}/METIS/GKlib \ - -DCMAKE_INSTALL_PREFIX=${{ runner.workspace }}/installs - cmake --build build --parallel - cmake --install build - - # no default blas available on runner - - - name: Cache APT packages - uses: actions/cache@v4 - with: - path: | - /var/cache/apt/archives - /var/lib/apt/lists - key: ${{ runner.os }}-apt-libopenblas - - - name: Install OpenBLAS - shell: bash - run: | - sudo apt update - sudo apt install libopenblas-dev - - name: Create Build Environment - run: cmake -E make_directory ${{runner.workspace}}/build - - - name: Configure CMake - shell: bash - working-directory: ${{runner.workspace}}/build - run: | - cmake $GITHUB_WORKSPACE -DHIPO=ON \ - -DCMAKE_BUILD_TYPE=Debug \ - -DALL_TESTS=ON \ - -DBLA_VENDOR=OpenBLAS \ - -DMETIS_ROOT=${{runner.workspace}}/installs - - - name: Build - working-directory: ${{runner.workspace}}/build - shell: bash - run: | - cmake --build . -j2 - - - name: Test - working-directory: ${{runner.workspace}}/build - shell: bash - run: | - valgrind \ - --leak-check=full \ - --show-leak-kinds=all \ - --track-origins=yes \ - -s \ - ./bin/unit_tests \ - 2>&1 | tee logfile - - - name: Check log for Errors - working-directory: ${{runner.workspace}}/build - shell: bash - run: | - cat logfile - OUTPUT='ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 0 from 0)' - if grep -q "$OUTPUT" logfile; then - exit 0 - fi - exit 1 - - instance_tests: - runs-on: ${{ matrix.os }} - strategy: - matrix: - os: [ubuntu-latest] - - steps: - - uses: actions/checkout@v4 - - - name: Install Valgrind - run: sudo apt-get update && sudo apt-get install valgrind - - - name: Checkout METIS - uses: actions/checkout@v4 - with: - repository: galabovaa/METIS - ref: 521-ts - path: METIS - - - name: Create installs dir - working-directory: ${{runner.workspace}} - run: | - mkdir installs - ls - - - name: Install METIS - run: | - cmake \ - -S $GITHUB_WORKSPACE/METIS \ - -B build \ - -DCMAKE_BUILD_TYPE=Debug \ - -DGKLIB_PATH=${{ github.workspace }}/METIS/GKlib \ - -DCMAKE_INSTALL_PREFIX=${{ runner.workspace }}/installs - cmake --build build --parallel - cmake --install build - - # no default blas available on runner - - - name: Cache APT packages - uses: actions/cache@v4 - with: - path: | - /var/cache/apt/archives - /var/lib/apt/lists - key: ${{ runner.os }}-apt-libopenblas - - - name: Install OpenBLAS - shell: bash - run: | - sudo apt update - sudo apt install libopenblas-dev - - name: Create Build Environment - run: cmake -E make_directory ${{runner.workspace}}/build - - - name: Create Build Environment - run: cmake -E make_directory ${{runner.workspace}}/build - - - name: Configure CMake - shell: bash - working-directory: ${{runner.workspace}}/build - run: | - cmake $GITHUB_WORKSPACE -DHIPO=ON \ - -DCMAKE_BUILD_TYPE=Debug \ - -DALL_TESTS=ON \ - -DBLA_VENDOR=OpenBLAS \ - -DMETIS_ROOT=${{runner.workspace}}/installs - - - name: Build - working-directory: ${{runner.workspace}}/build - shell: bash - run: | - cmake --build . -j2 - - - name: Test - working-directory: ${{runner.workspace}}/build - shell: bash - run: | - valgrind \ - --leak-check=full \ - --show-leak-kinds=all \ - --track-origins=yes \ - -s \ - ctest -E unit.* \ - --timeout 1000 \ - --output-on-failure \ - 2>&1 | tee logfile2 - - - name: Check log for Errors - working-directory: ${{runner.workspace}}/build - shell: bash - run: | - cat logfile2 - OUTPUT='ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 0 from 0)' - if grep -q "$OUTPUT" logfile2; then - exit 0 - fi - exit 1 - - examples: - runs-on: ${{ matrix.os }} - strategy: - matrix: - os: [ubuntu-latest] - - steps: - - uses: actions/checkout@v4 - - - name: Install Valgrind - run: sudo apt-get update && sudo apt-get install valgrind - - - name: Checkout METIS - uses: actions/checkout@v4 - with: - repository: galabovaa/METIS - ref: 521-ts - path: METIS - - - name: Create installs dir - working-directory: ${{runner.workspace}} - run: | - mkdir installs - ls - - - name: Install METIS - run: | - cmake \ - -S $GITHUB_WORKSPACE/METIS \ - -B build \ - -DCMAKE_BUILD_TYPE=Debug \ - -DGKLIB_PATH=${{ github.workspace }}/METIS/GKlib \ - -DCMAKE_INSTALL_PREFIX=${{ runner.workspace }}/installs - cmake --build build --parallel - cmake --install build - - # no default blas available on runner - - - name: Cache APT packages - uses: actions/cache@v4 - with: - path: | - /var/cache/apt/archives - /var/lib/apt/lists - key: ${{ runner.os }}-apt-libopenblas - - - name: Install OpenBLAS - shell: bash - run: | - sudo apt update - sudo apt install libopenblas-dev - - name: Create Build Environment - run: cmake -E make_directory ${{runner.workspace}}/build - - - name: Create Build Environment - run: cmake -E make_directory ${{runner.workspace}}/build - - - name: Configure CMake - shell: bash - working-directory: ${{runner.workspace}}/build - run: | - cmake $GITHUB_WORKSPACE -DHIPO=ON \ - -DCMAKE_BUILD_TYPE=Debug \ - -DALL_TESTS=ON \ - -DBLA_VENDOR=OpenBLAS \ - -DMETIS_ROOT=${{runner.workspace}}/installs - - - - name: Build - working-directory: ${{runner.workspace}}/build - shell: bash - run: | - cmake --build . -j2 - - - name: Test cpp example - working-directory: ${{runner.workspace}}/build - shell: bash - run: | - valgrind \ - --leak-check=full \ - --show-leak-kinds=all \ - --track-origins=yes \ - -s \ - ./bin/call_highs_from_cpp \ - --timeout 1000 \ - --output-on-failure \ - 2>&1 | tee logfile2 - - - name: Check log for Errors - working-directory: ${{runner.workspace}}/build - shell: bash - run: | - cat logfile2 - OUTPUT='ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 0 from 0)' - if grep -q "$OUTPUT" logfile2; then - exit 0 - fi - exit 1 - - - name: Test C example - working-directory: ${{runner.workspace}}/build - shell: bash - run: | - valgrind \ - --leak-check=full \ - --show-leak-kinds=all \ - --track-origins=yes \ - -s \ - ./bin/call_highs_from_c_minimal \ - --timeout 1000 \ - --output-on-failure \ - 2>&1 | tee logfile2 - - - name: Check log for Errors - working-directory: ${{runner.workspace}}/build - shell: bash - run: | - cat logfile2 - OUTPUT='ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 0 from 0)' - if grep -q "$OUTPUT" logfile2; then - exit 0 - fi - exit 1 \ No newline at end of file diff --git a/.github/workflows/valgrind-hipo.yml b/.github/workflows/valgrind-hipo.yml index 3770f9ff73..a32d30d81f 100644 --- a/.github/workflows/valgrind-hipo.yml +++ b/.github/workflows/valgrind-hipo.yml @@ -8,48 +8,10 @@ jobs: steps: - uses: actions/checkout@v4 - + - name: Install Valgrind run: sudo apt-get update && sudo apt-get install valgrind - - name: Checkout METIS - uses: actions/checkout@v4 - with: - repository: galabovaa/METIS - ref: 521-ts - path: METIS - - - name: Create installs dir - working-directory: ${{runner.workspace}} - run: | - mkdir installs - ls - - - name: Install METIS - run: | - cmake \ - -S $GITHUB_WORKSPACE/METIS \ - -B build \ - -DGKLIB_PATH=${{ github.workspace }}/METIS/GKlib \ - -DCMAKE_INSTALL_PREFIX=${{ runner.workspace }}/installs - cmake --build build --parallel - cmake --install build - - # no default blas available on runner - - - name: Cache APT packages - uses: actions/cache@v4 - with: - path: | - /var/cache/apt/archives - /var/lib/apt/lists - key: ${{ runner.os }}-apt-libopenblas - - - name: Install OpenBLAS - shell: bash - run: | - sudo apt update - sudo apt install libopenblas-dev - name: Create Build Environment run: cmake -E make_directory ${{runner.workspace}}/build @@ -58,10 +20,9 @@ jobs: working-directory: ${{runner.workspace}}/build run: | cmake $GITHUB_WORKSPACE -DHIPO=ON \ + -DBUILD_OPENBLAS=ON \ -DCMAKE_BUILD_TYPE=Debug \ - -DALL_TESTS=ON \ - -DBLA_VENDOR=OpenBLAS \ - -DMETIS_ROOT=${{runner.workspace}}/installs + -DALL_TESTS=ON - name: Build working-directory: ${{runner.workspace}}/build @@ -104,47 +65,6 @@ jobs: - name: Install Valgrind run: sudo apt-get update && sudo apt-get install valgrind - - name: Checkout METIS - uses: actions/checkout@v4 - with: - repository: galabovaa/METIS - ref: 521-ts - path: METIS - - - name: Create installs dir - working-directory: ${{runner.workspace}} - run: | - mkdir installs - ls - - - name: Install METIS - run: | - cmake \ - -S $GITHUB_WORKSPACE/METIS \ - -B build \ - -DGKLIB_PATH=${{ github.workspace }}/METIS/GKlib \ - -DCMAKE_INSTALL_PREFIX=${{ runner.workspace }}/installs - cmake --build build --parallel - cmake --install build - - # no default blas available on runner - - - name: Cache APT packages - uses: actions/cache@v4 - with: - path: | - /var/cache/apt/archives - /var/lib/apt/lists - key: ${{ runner.os }}-apt-libopenblas - - - name: Install OpenBLAS - shell: bash - run: | - sudo apt update - sudo apt install libopenblas-dev - - name: Create Build Environment - run: cmake -E make_directory ${{runner.workspace}}/build - - name: Create Build Environment run: cmake -E make_directory ${{runner.workspace}}/build @@ -153,10 +73,9 @@ jobs: working-directory: ${{runner.workspace}}/build run: | cmake $GITHUB_WORKSPACE -DHIPO=ON \ + -DBUILD_OPENBLAS=ON \ -DCMAKE_BUILD_TYPE=Debug \ - -DALL_TESTS=ON \ - -DBLA_VENDOR=OpenBLAS \ - -DMETIS_ROOT=${{runner.workspace}}/installs + -DALL_TESTS=ON - name: Build working-directory: ${{runner.workspace}}/build @@ -200,47 +119,6 @@ jobs: - name: Install Valgrind run: sudo apt-get update && sudo apt-get install valgrind - - - name: Checkout METIS - uses: actions/checkout@v4 - with: - repository: galabovaa/METIS - ref: 521-ts - path: METIS - - - name: Create installs dir - working-directory: ${{runner.workspace}} - run: | - mkdir installs - ls - - - name: Install METIS - run: | - cmake \ - -S $GITHUB_WORKSPACE/METIS \ - -B build \ - -DGKLIB_PATH=${{ github.workspace }}/METIS/GKlib \ - -DCMAKE_INSTALL_PREFIX=${{ runner.workspace }}/installs - cmake --build build --parallel - cmake --install build - - # no default blas available on runner - - - name: Cache APT packages - uses: actions/cache@v4 - with: - path: | - /var/cache/apt/archives - /var/lib/apt/lists - key: ${{ runner.os }}-apt-libopenblas - - - name: Install OpenBLAS - shell: bash - run: | - sudo apt update - sudo apt install libopenblas-dev - - name: Create Build Environment - run: cmake -E make_directory ${{runner.workspace}}/build - name: Create Build Environment run: cmake -E make_directory ${{runner.workspace}}/build @@ -250,11 +128,8 @@ jobs: working-directory: ${{runner.workspace}}/build run: | cmake $GITHUB_WORKSPACE -DHIPO=ON \ - -DCMAKE_BUILD_TYPE=Debug \ - -DALL_TESTS=ON \ - -DBLA_VENDOR=OpenBLAS \ - -DMETIS_ROOT=${{runner.workspace}}/installs - + -DBUILD_OPENBLAS=ON \ + -DCMAKE_BUILD_TYPE=Debug - name: Build working-directory: ${{runner.workspace}}/build @@ -286,7 +161,7 @@ jobs: exit 0 fi exit 1 - + - name: Test C example working-directory: ${{runner.workspace}}/build shell: bash diff --git a/check/CMakeLists.txt b/check/CMakeLists.txt index 55f83384a8..c35dd4cb55 100644 --- a/check/CMakeLists.txt +++ b/check/CMakeLists.txt @@ -159,7 +159,9 @@ if ((NOT FAST_BUILD OR ALL_TESTS) AND NOT (BUILD_EXTRA_UNIT_ONLY)) add_test(NAME capi_unit_tests COMMAND capi_unit_tests) # Check whether test executable builds OK. - if (NOT HIGHS_COVERAGE) + if ((NOT HIGHS_COVERAGE) AND + (NOT BUILD_OPENBLAS OR + (LINUX AND CMAKE_SYSTEM_PROCESSOR MATCHES "x86_64|amd64"))) add_test(NAME unit-test-build COMMAND ${CMAKE_COMMAND} --build ${HIGHS_BINARY_DIR} @@ -258,8 +260,8 @@ if ((NOT FAST_BUILD OR ALL_TESTS) AND NOT (BUILD_EXTRA_UNIT_ONLY)) set(failInstances ) - - set(mipInstances + + set(mipInstances "small_mip\;3.2368421\;" "flugpl\;1201500\;" "lseu\;1120|1119.9999999\;" @@ -284,7 +286,9 @@ if ((NOT FAST_BUILD OR ALL_TESTS) AND NOT (BUILD_EXTRA_UNIT_ONLY)) # "--parallel=on" ) - if (UNIX AND NOT APPLE AND NOT CMAKE_CXX_COMPILER_ID STREQUAL "IntelLLVM") + if (UNIX AND NOT APPLE AND + NOT CMAKE_CXX_COMPILER_ID STREQUAL "IntelLLVM" + AND CMAKE_SYSTEM_PROCESSOR MATCHES "x86_64|amd64") if (CUPDLP_GPU) set(pdlpInstances "25fv47\; 5.501847\;" @@ -318,7 +322,9 @@ if ((NOT FAST_BUILD OR ALL_TESTS) AND NOT (BUILD_EXTRA_UNIT_ONLY)) "standgub\; 1.25769944\;" ) endif() - elseif(WIN32 AND NOT CMAKE_CXX_COMPILER_ID STREQUAL "IntelLLVM") + elseif(WIN32 AND NOT CMAKE_CXX_COMPILER_ID STREQUAL "IntelLLVM" AND + NOT (CMAKE_SIZEOF_VOID_P EQUAL 4) AND + CMAKE_SYSTEM_PROCESSOR MATCHES "AMD64|x86_64") if (CUPDLP_GPU) set(pdlpInstances "25fv47\; 5.50184\;" @@ -435,7 +441,8 @@ if ((NOT FAST_BUILD OR ALL_TESTS) AND NOT (BUILD_EXTRA_UNIT_ONLY)) if(${CMAKE_SYSTEM_PROCESSOR} MATCHES "riscv64") add_instancetests(successRiscVInstances "Optimal") endif() - else() + elseif(NOT (CMAKE_SYSTEM_PROCESSOR MATCHES "arm|aarch64") AND + NOT (CMAKE_SIZEOF_VOID_P EQUAL 4)) add_instancetests(successInstances "Optimal") endif() diff --git a/cmake/FindHipoDeps.cmake b/cmake/FindHipoDeps.cmake index 21233a5f09..5519d4326d 100644 --- a/cmake/FindHipoDeps.cmake +++ b/cmake/FindHipoDeps.cmake @@ -121,6 +121,11 @@ if (BUILD_OPENBLAS) CMAKE_ARGS ${OPENBLAS_MINIMAL_FLAGS} ) FetchContent_MakeAvailable(openblas) + + if (ALL_TESTS) + set(BUILD_TESTING ON) + endif() + list(POP_BACK CMAKE_MESSAGE_INDENT) message(CHECK_PASS "fetched")