Do not use magic_enum (remove external dependency) #1144
This file contains 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: CI | |
on: | |
# Allows you to run this workflow manually from the Actions tab | |
workflow_dispatch: | |
# check PRs | |
pull_request: | |
branches: | |
- master | |
# check pushes | |
push: | |
branches: | |
- master | |
jobs: | |
build: | |
runs-on: ubuntu-20.04 | |
container: | |
image: strikef/mlir-tv-ci-base:latest | |
steps: | |
- name: Fetch mlir-tv cache | |
id: cache | |
uses: actions/cache@v2 | |
with: | |
path: | | |
/src/mlir-tv | |
!/src/mlir-tv/build/Testing | |
key: cache-${{ github.sha }} | |
# if cache miss | |
- name: Create /src if not exists | |
if: steps.cache.outputs.cache-hit != 'true' | |
run: | | |
mkdir /src | |
# endif cache miss | |
- name: Checkout this repo | |
uses: actions/checkout@v2 | |
with: | |
path: mlir-tv | |
- name: Move repo to absolute location | |
run: | | |
mv mlir-tv /src/mlir-tv | |
- name: Build mlir-tv | |
run: | | |
cd /src/mlir-tv | |
cmake -B build -G Ninja \ | |
-DMLIR_ROOT=/opt/llvm \ | |
-DUSE_Z3=ON \ | |
-DUSE_cvc5=ON \ | |
-DCMAKE_BUILD_TYPE=RelWithDebInfo | |
cmake --build build | |
build-release: | |
runs-on: ubuntu-20.04 | |
container: | |
image: strikef/mlir-tv-ci-base:latest | |
steps: | |
- name: Checkout this repo | |
uses: actions/checkout@v2 | |
with: | |
path: mlir-tv | |
- name: Build mlir-tv | |
run: | | |
cd mlir-tv | |
cmake -B build -G Ninja \ | |
-DMLIR_ROOT=/opt/llvm \ | |
-DUSE_Z3=ON \ | |
-DUSE_cvc5=ON \ | |
-DCMAKE_BUILD_TYPE=Release | |
cmake --build build | |
build-Z3-only: | |
runs-on: ubuntu-20.04 | |
container: | |
image: strikef/mlir-tv-ci-base:latest | |
steps: | |
- name: Checkout this repo | |
uses: actions/checkout@v2 | |
with: | |
path: mlir-tv | |
- name: Build mlir-tv | |
run: | | |
cd mlir-tv | |
cmake -B build -G Ninja \ | |
-DMLIR_ROOT=/opt/llvm \ | |
-DUSE_Z3=ON \ | |
-DCMAKE_BUILD_TYPE=RelWithDebInfo | |
cmake --build build | |
build-CVC5-only: | |
runs-on: ubuntu-20.04 | |
container: | |
image: strikef/mlir-tv-ci-base:latest | |
steps: | |
- name: Checkout this repo | |
uses: actions/checkout@v2 | |
with: | |
path: mlir-tv | |
- name: Build mlir-tv | |
run: | | |
cd mlir-tv | |
cmake -B build -G Ninja \ | |
-DMLIR_ROOT=/opt/llvm \ | |
-DUSE_cvc5=ON \ | |
-DCMAKE_BUILD_TYPE=RelWithDebInfo | |
cmake --build build | |
opts-test: | |
needs: build | |
runs-on: ubuntu-20.04 | |
container: | |
image: strikef/mlir-tv-ci-base:latest | |
steps: | |
- name: Fetch mlir-tv cache | |
uses: actions/cache@v2 | |
with: | |
path: | | |
/src/mlir-tv | |
!/src/mlir-tv/build/Testing | |
key: cache-${{ github.sha }} | |
- name: Run ctest | |
run: | | |
cd /src/mlir-tv/build | |
. /venv/bin/activate | |
ctest --output-on-failure -R Opts | |
- name: Upload test log | |
if: ${{ failure() }} | |
uses: actions/upload-artifact@v4 | |
with: | |
name: opts-test | |
path: /src/mlir-tv/build/Testing/Temporary/LastTest.log | |
litmus-test: | |
runs-on: ubuntu-20.04 | |
needs: build | |
container: | |
image: strikef/mlir-tv-ci-base:latest | |
steps: | |
- name: Fetch mlir-tv cache | |
uses: actions/cache@v2 | |
with: | |
path: | | |
/src/mlir-tv | |
!/src/mlir-tv/build/Testing | |
key: cache-${{ github.sha }} | |
- name: Run ctest | |
run: | | |
cd /src/mlir-tv/build | |
. /venv/bin/activate | |
ctest --output-on-failure -R Litmus | |
- name: Upload test log | |
if: ${{ failure() }} | |
uses: actions/upload-artifact@v4 | |
with: | |
name: litmus-test | |
path: /src/mlir-tv/build/Testing/Temporary/LastTest.log |