From 0936ff39915af1920e7fac37f06fe4742a4c2bd0 Mon Sep 17 00:00:00 2001 From: zaikunzhang Date: Sun, 21 Apr 2024 18:25:53 +0800 Subject: [PATCH] 240421.182553.HKT revise the yml files regarding macos-12 and matlab R2024a --- .github/workflows/cmake.yml | 2 +- .github/workflows/compile_mex.yml | 4 +- .github/workflows/parallel_test_matlab.yml | 4 +- .github/workflows/recursive_test_matlab.yml | 41 +++++++++------- .github/workflows/stress_test_fortran.yml | 28 +++++------ .github/workflows/stress_test_matlab.yml | 38 ++++++++------- .github/workflows/test_gfortran.yml | 2 +- .github/workflows/test_ifort.yml | 6 +-- .github/workflows/test_ifx.yml | 1 - .github/workflows/test_matlab.yml | 52 +++++++-------------- .github/workflows/test_matlab_mac_intel.yml | 2 +- fortran/common/linalg.f90 | 2 +- 12 files changed, 89 insertions(+), 93 deletions(-) diff --git a/.github/workflows/cmake.yml b/.github/workflows/cmake.yml index 2d0f8b8a04..2b02331186 100644 --- a/.github/workflows/cmake.yml +++ b/.github/workflows/cmake.yml @@ -34,7 +34,7 @@ jobs: # N.B.: As of 20240401, setup-fortran fails constantly with windows-latest and intel-classic # 2021.8. Thus this combination is not included (see the Windows part below). # First define the toolchains on Linux and macOS. - os: [ubuntu-latest, macos-latest, macos-13] + os: [ubuntu-latest, macos-12, macos-13] toolchain: - {compiler: gcc, version: 11, cflags: '-Wall -Wextra -Wpedantic -Werror', fflags: '-Wall -Wextra -Wpedantic -Werror -fimplicit-none -frecursive -fcheck=all -fstack-check -Wno-function-elimination'} - {compiler: gcc, version: 12, cflags: '-Wall -Wextra -Wpedantic -Werror', fflags: '-Wall -Wextra -Wpedantic -Werror -fimplicit-none -frecursive -fcheck=all -fstack-check -Wno-function-elimination'} diff --git a/.github/workflows/compile_mex.yml b/.github/workflows/compile_mex.yml index 159ee5f6c1..031a5ad828 100644 --- a/.github/workflows/compile_mex.yml +++ b/.github/workflows/compile_mex.yml @@ -111,8 +111,8 @@ jobs: command: | ver; options.half = false; - options.single = ~(strcmp('${{ matrix.os }}', 'macos-11') && verLessThan('matlab', '9.11')); % On macos-11 with MATLAB R2021b, MEX is slow - options.quadruple = options.single; + options.single = true; + options.quadruple = ~(strcmp('${{ matrix.os }}', 'macos-11') && verLessThan('matlab', '9.11')); % On macos-11 with MATLAB R2021b, MEX is slow options.debug = true; options.classical = false; options.verbose = true; diff --git a/.github/workflows/parallel_test_matlab.yml b/.github/workflows/parallel_test_matlab.yml index 11ca5ece21..8cc07b3401 100644 --- a/.github/workflows/parallel_test_matlab.yml +++ b/.github/workflows/parallel_test_matlab.yml @@ -35,8 +35,8 @@ jobs: fail-fast: false matrix: # Only the following combinations of OS and MATLAB support parfor - os: [ubuntu-latest, windows-latest, macos-latest, macos-13] - matlab: [R2023a, latest] + os: [ubuntu-latest, windows-latest, macos-12, macos-13] + matlab: [R2023a, R2023b, R2024a, latest] solver: [uobyqa, newuoa, bobyqa, lincoa, cobyla] diff --git a/.github/workflows/recursive_test_matlab.yml b/.github/workflows/recursive_test_matlab.yml index c4f29039b8..922be72f76 100644 --- a/.github/workflows/recursive_test_matlab.yml +++ b/.github/workflows/recursive_test_matlab.yml @@ -34,59 +34,63 @@ jobs: strategy: fail-fast: false matrix: - os: [ubuntu-20.04, ubuntu-latest, windows-2019, windows-latest, macos-11, macos-latest, macos-13] + os: [ubuntu-20.04, ubuntu-latest, windows-2019, windows-latest, macos-11, macos-12, macos-13] matlab: [R2020b, R2021a, R2022a, R2023a, latest] solver: [uobyqa, newuoa, bobyqa, lincoa, cobyla] - # Exclude some versions of OS and MATLAB. In addition to the latest versions, we intend to - # test the earliest version of MATLAB on each OS. + # Exclude some versions of OS and MATLAB. We test ONLY the earliest and latest versions of MATLAB on each OS. exclude: - - os: ubuntu-latest - matlab: R2020b + # ubuntu-latest: test R2020b and latest - os: ubuntu-latest matlab: R2021a - os: ubuntu-latest matlab: R2022a + - os: ubuntu-latest + matlab: R2023a + + # ubuntu-20.04: test R2020b and latest - os: ubuntu-20.04 matlab: R2021a - os: ubuntu-20.04 matlab: R2022a - os: ubuntu-20.04 matlab: R2023a - - os: ubuntu-20.04 - matlab: latest - - os: macos-13 - matlab: R2020b + # macos-13: test R2020b and latest - os: macos-13 matlab: R2021a - os: macos-13 matlab: R2022a - - os: macos-latest + - os: macos-13 + matlab: R2023a + + # macos-12: test R2022a and latest + - os: macos-12 matlab: R2020b - - os: macos-latest + - os: macos-12 matlab: R2021a - - os: macos-latest - matlab: R2022a + - os: macos-12 + matlab: R2023a + + # macos-11: test R2022a and latest - os: macos-11 matlab: R2020b - os: macos-11 matlab: R2021a - os: macos-11 matlab: R2023a - - os: macos-11 - matlab: latest + # windows-latest: test R2023a and latest - os: windows-latest matlab: R2020b - os: windows-latest matlab: R2021a - os: windows-latest matlab: R2022a + + # windows-2019: test R2021a and R2022a - os: windows-2019 matlab: R2020b - - os: windows-2019 - matlab: R2022a - os: windows-2019 matlab: R2023a - os: windows-2019 @@ -117,6 +121,9 @@ jobs: # As of 231227, checkout with ssh fails frequently on Windows runners. submodules: recursive + - name: Miscellaneous setup + run: bash .github/scripts/misc_setup + - name: Link gfortran for MATLAB on Linux if: startsWith(matrix.os, 'ubuntu') run: | diff --git a/.github/workflows/stress_test_fortran.yml b/.github/workflows/stress_test_fortran.yml index 0184f0c0e9..a5313df5dc 100644 --- a/.github/workflows/stress_test_fortran.yml +++ b/.github/workflows/stress_test_fortran.yml @@ -26,23 +26,11 @@ jobs: strategy: fail-fast: false matrix: - os: [ubuntu-latest, macos-latest, macos-13] + os: [ubuntu-latest, macos-13, macos-14] compiler: [g, i, v, s, f, x, d] solver: [newuoa, cobyla, lincoa, bobyqa, uobyqa] testdim: [large] exclude: - - os: macos-latest - compiler: v - - os: macos-latest - compiler: s - - os: macos-latest - compiler: f - - os: macos-latest - compiler: x - - os: macos-latest - compiler: d - - compiler: s # BOBYQA fails stest for unknown reason - solver: bobyqa - os: macos-13 compiler: v - os: macos-13 @@ -53,6 +41,20 @@ jobs: compiler: x - os: macos-13 compiler: d + + - os: macos-14 + compiler: i + - os: macos-14 + compiler: v + - os: macos-14 + compiler: s + - os: macos-14 + compiler: f + - os: macos-14 + compiler: x + - os: macos-14 + compiler: d + - compiler: s # BOBYQA fails stest for unknown reason solver: bobyqa diff --git a/.github/workflows/stress_test_matlab.yml b/.github/workflows/stress_test_matlab.yml index 3a652fbc67..3cceb8abd5 100644 --- a/.github/workflows/stress_test_matlab.yml +++ b/.github/workflows/stress_test_matlab.yml @@ -31,60 +31,64 @@ jobs: strategy: fail-fast: false matrix: - os: [ubuntu-20.04, ubuntu-latest, windows-2019, windows-latest, macos-11, macos-latest, macos-13] + os: [ubuntu-20.04, ubuntu-latest, windows-2019, windows-latest, macos-11, macos-12, macos-13] matlab: [R2020b, R2021a, R2022a, R2023a, latest] solver: [uobyqa, newuoa, bobyqa, lincoa, cobyla] test: [normal, tough] - # Exclude some versions of OS and MATLAB. In addition to the latest versions, we intend to - # test the earliest version of MATLAB on each OS. + # Exclude some versions of OS and MATLAB. We test ONLY the earliest and latest versions of MATLAB on each OS. exclude: - - os: ubuntu-latest - matlab: R2020b + # ubuntu-latest: test R2020b and latest - os: ubuntu-latest matlab: R2021a - os: ubuntu-latest matlab: R2022a + - os: ubuntu-latest + matlab: R2023a + + # ubuntu-20.04: test R2020b and latest - os: ubuntu-20.04 matlab: R2021a - os: ubuntu-20.04 matlab: R2022a - os: ubuntu-20.04 matlab: R2023a - - os: ubuntu-20.04 - matlab: latest - - os: macos-13 - matlab: R2020b + # macos-13: test R2020b and latest - os: macos-13 matlab: R2021a - os: macos-13 matlab: R2022a - - os: macos-latest + - os: macos-13 + matlab: R2023a + + # macos-12: test R2022a and latest + - os: macos-12 matlab: R2020b - - os: macos-latest + - os: macos-12 matlab: R2021a - - os: macos-latest - matlab: R2022a + - os: macos-12 + matlab: R2023a + + # macos-11: test R2022a and latest - os: macos-11 matlab: R2020b - os: macos-11 matlab: R2021a - os: macos-11 matlab: R2023a - - os: macos-11 - matlab: latest + # windows-latest: test R2023a and latest - os: windows-latest matlab: R2020b - os: windows-latest matlab: R2021a - os: windows-latest matlab: R2022a + + # windows-2019: test R2021a and R2022a - os: windows-2019 matlab: R2020b - - os: windows-2019 - matlab: R2022a - os: windows-2019 matlab: R2023a - os: windows-2019 diff --git a/.github/workflows/test_gfortran.yml b/.github/workflows/test_gfortran.yml index d42d5f02b5..f3e5685d95 100644 --- a/.github/workflows/test_gfortran.yml +++ b/.github/workflows/test_gfortran.yml @@ -27,7 +27,7 @@ jobs: strategy: fail-fast: false matrix: - os: [ubuntu-latest, windows-latest, macos-latest, macos-13, macos-14] + os: [ubuntu-latest, windows-latest, macos-12, macos-13, macos-14] compiler: [gcc] version: [12, 13] # Too expensive to test all versions ikind: [i2, i8] diff --git a/.github/workflows/test_ifort.yml b/.github/workflows/test_ifort.yml index 1a5d134d97..e375886269 100644 --- a/.github/workflows/test_ifort.yml +++ b/.github/workflows/test_ifort.yml @@ -28,15 +28,15 @@ jobs: fail-fast: false matrix: # Windows does not work. On Windows, the options for ifort/ifx starts with "/" instead of "-". - os: [ubuntu-latest, macos-latest, macos-13] + os: [ubuntu-latest, macos-12, macos-13] ikind: [i2, i8] solver: [newuoa, cobyla, lincoa, bobyqa, uobyqa] fflags: [-O1, -O2, -O3, -g, -fast] testdim: [small, big] exclude: - - os: macos-13 + - os: macos-12 ikind: i8 - - os: macos-latest + - os: macos-13 ikind: i8 steps: diff --git a/.github/workflows/test_ifx.yml b/.github/workflows/test_ifx.yml index 44c9e1b21f..274f0cb2cf 100644 --- a/.github/workflows/test_ifx.yml +++ b/.github/workflows/test_ifx.yml @@ -29,7 +29,6 @@ jobs: matrix: # Windows does not work. On Windows, the options for ifort/ifx starts with "/" instead of "-". # As of 202301, ifx is not available on macOS. - #os: [ubuntu-latest, macos-latest] os: [ubuntu-latest] ikind: [i2, i8] solver: [newuoa, cobyla, lincoa, bobyqa, uobyqa] diff --git a/.github/workflows/test_matlab.yml b/.github/workflows/test_matlab.yml index 97fdbc8a2e..98aa844a86 100644 --- a/.github/workflows/test_matlab.yml +++ b/.github/workflows/test_matlab.yml @@ -25,12 +25,12 @@ jobs: strategy: fail-fast: false matrix: - os: [ubuntu-20.04, ubuntu-latest, windows-2019, windows-latest, macos-11, macos-latest, macos-13] + os: [ubuntu-20.04, ubuntu-latest, macos-11, macos-12, macos-13] matlab: [R2020b, R2021a, R2021b, R2022a, R2022b, R2023a, R2023b, R2024a, latest] exclude: - # Below R2022a, MEX is extremely slow on macOS + # Below R2022a, MEX is extremely slow on macOS 11 - os: macos-11 matlab: R2020b - os: macos-11 @@ -38,52 +38,36 @@ jobs: - os: macos-11 matlab: R2021b - - os: macos-latest + # Below R2022a, MEX is extremely slow on macOS 12 + - os: macos-12 matlab: R2020b - - os: macos-latest + - os: macos-12 matlab: R2021a - - os: macos-latest + - os: macos-12 matlab: R2021b - - os: macos-13 - matlab: R2020b - - os: macos-13 - matlab: R2021a - - os: macos-13 - matlab: R2021b + include: - # Only R2021a/b and R2022a are available on Windows 2019. Test on R2021a often fails due to overtime. - - os: windows-2019 - matlab: R2020b + # Only R2021a/b and R2022a are available on Windows 2019. - os: windows-2019 matlab: R2021a - os: windows-2019 - matlab: R2022b + matlab: R2021b - os: windows-2019 + matlab: R2022a + + # Below R2022a, MEX does not work on windows-latest due to the version of MS Visual Studio; + # R2022a/b should work according to the documentation of MathWorks and GitHub Actions, but + # they do not as of April 2024 + - os: windows-2022 matlab: R2023a - - os: windows-2019 + - os: windows-2022 matlab: R2023b - - os: windows-2019 + - os: windows-2022 matlab: R2024a - - os: windows-2019 + - os: windows-2022 matlab: latest - # Below R2022a, MEX does not work on windows-latest due to the version of MS Visual Studio; - # R2022a/b should work according to the documentation of MathWorks and GitHub Actions, but - # they do not as of March 2022 - - os: windows-latest - matlab: R2020a - - os: windows-latest - matlab: R2020b - - os: windows-latest - matlab: R2021a - - os: windows-latest - matlab: R2021b - - os: windows-latest - matlab: R2022a - - os: windows-latest - matlab: R2022b - steps: diff --git a/.github/workflows/test_matlab_mac_intel.yml b/.github/workflows/test_matlab_mac_intel.yml index bacbb3d320..b7e8302f7d 100644 --- a/.github/workflows/test_matlab_mac_intel.yml +++ b/.github/workflows/test_matlab_mac_intel.yml @@ -20,7 +20,7 @@ jobs: strategy: fail-fast: false matrix: - os: [macos-latest, macos-13] + os: [macos-12, macos-13] matlab: [latest] steps: diff --git a/fortran/common/linalg.f90 b/fortran/common/linalg.f90 index e3bbca30b9..60d39f6d1b 100644 --- a/fortran/common/linalg.f90 +++ b/fortran/common/linalg.f90 @@ -39,7 +39,7 @@ module linalg_mod ! ! Started: July 2020 ! -! Last Modified: Sunday, April 21, 2024 AM11:59:07 +! Last Modified: Sunday, April 21, 2024 PM03:49:40 !--------------------------------------------------------------------------------------------------! implicit none