Fix the Windows and NetCDF unit-test CI failures (#3953) #1254
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: ERF CI (sycl) | |
| on: | |
| push: | |
| # branches: [development] | |
| paths-ignore: | |
| - Docs | |
| - README.rst | |
| - license.txt | |
| pull_request: | |
| branches: [development] | |
| types: [opened, synchronize, reopened, closed] | |
| concurrency: | |
| group: ${{ github.ref }}-${{ github.head_ref }}-sycl | |
| cancel-in-progress: true | |
| jobs: | |
| Build-And-Test-SYCL: | |
| # The closed event exists only to cancel in-progress runs via concurrency. | |
| if: github.event.action != 'closed' | |
| name: oneAPI SYCL - Mesh ${{matrix.mesh_precision}} Particles ${{matrix.particles}} ${{matrix.particles_precision}} | |
| runs-on: ubuntu-24.04 | |
| strategy: | |
| matrix: | |
| particles: [OFF, ON] | |
| particles_precision: [DOUBLE, SINGLE] | |
| mesh_precision: [DOUBLE, SINGLE] | |
| exclude: | |
| - particles: OFF | |
| particles_precision: SINGLE | |
| - mesh_precision: SINGLE | |
| particles: OFF | |
| steps: | |
| - uses: actions/checkout@v7 | |
| with: | |
| submodules: true | |
| - name: Free up disk space | |
| uses: ./.github/actions/free-space-ubuntu | |
| - name: Dependencies | |
| run: | | |
| Submodules/AMReX/.github/workflows/dependencies/ubuntu_free_disk_space.sh | |
| Submodules/AMReX/.github/workflows/dependencies/dependencies_dpcpp.sh | |
| - name: Install CCache | |
| run: Submodules/AMReX/.github/workflows/dependencies/dependencies_ccache.sh | |
| - name: Set Up Cache | |
| uses: actions/cache@v6 | |
| with: | |
| path: ~/.cache/ccache | |
| key: ccache-${{ github.workflow }}-${{ github.job }}-git-${{ github.sha }} | |
| restore-keys: | | |
| ccache-${{ github.workflow }}-${{ github.job }}-git- | |
| - name: Build & Install | |
| run: | | |
| export CCACHE_COMPRESS=1 | |
| export CCACHE_COMPRESSLEVEL=10 | |
| export CCACHE_MAXSIZE=250M | |
| export CCACHE_DEPEND=1 | |
| ccache -z | |
| set +e | |
| source /opt/intel/oneapi/setvars.sh | |
| set -e | |
| mkdir build-${{matrix.mesh_precision}}-${{matrix.particles}}-${{matrix.particles_precision}} | |
| cd build-${{matrix.mesh_precision}}-${{matrix.particles}}-${{matrix.particles_precision}} | |
| cmake .. \ | |
| -DCMAKE_VERBOSE_MAKEFILE=ON \ | |
| -DCMAKE_INSTALL_PREFIX:PATH=${{runner.workspace}}/ERF/install \ | |
| -DCMAKE_BUILD_TYPE:STRING=Release \ | |
| -DCMAKE_CXX_COMPILER_LAUNCHER=ccache \ | |
| -DERF_DIM:STRING=3 \ | |
| -DERF_ENABLE_MPI:BOOL=ON \ | |
| -DERF_ENABLE_SYCL:BOOL=ON \ | |
| -DERF_ENABLE_TESTS:BOOL=ON \ | |
| -DERF_ENABLE_ALL_WARNINGS:BOOL=ON \ | |
| -DERF_ENABLE_PARTICLES:BOOL=${{matrix.particles}} \ | |
| -DERF_PRECISION:STRING=${{matrix.mesh_precision}} \ | |
| -DERF_PARTICLES_PRECISION:STRING=${{matrix.particles_precision}} \ | |
| -DCMAKE_C_COMPILER=$(which icx) \ | |
| -DCMAKE_CXX_COMPILER=$(which icpx) \ | |
| -DCMAKE_CXX_STANDARD=17 \ | |
| -DAMReX_PARALLEL_LINK_JOBS=4 | |
| make -j 4 2>&1 | tee -a ${{runner.workspace}}/build-output.txt; | |
| ccache -s | |
| du -hs ~/.cache/ccache | |
| - name: Report | |
| run: | | |
| grep -Ei "warning:|error:" ${{runner.workspace}}/build-output.txt \ | |
| | grep -Ev "Submodules/(amrex|googletest)" | grep -Ev "lto-wrapper: warning:" | sort | uniq \ | |
| | awk 'BEGIN{i=0}{print $0}{i++}END{print "Warnings: "i}' > ${{runner.workspace}}/build-output-warnings.txt | |
| cat ${{runner.workspace}}/build-output-warnings.txt | |
| export return=$(tail -n 1 ${{runner.workspace}}/build-output-warnings.txt | awk '{print $2}') | |
| exit ${return} |