docs: update slides #426
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: linux | |
on: | |
push: | |
branches: [main] | |
pull_request: | |
branches: [main] | |
env: | |
BUILD_TYPE: Release | |
jobs: | |
build: | |
runs-on: ubuntu-22.04 | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
lfs: true | |
fetch-depth: 20 | |
- uses: actions/checkout@v3 | |
with: | |
ref: gh-pages | |
path: pages | |
- name: Update commit information on gh-pages | |
uses: nick-fields/retry@v2 | |
if: always() | |
with: | |
timeout_minutes: 60 | |
max_attempts: 3 | |
command: | | |
cd pages | |
git reset origin/gh-pages -- | |
git clean -f -d | |
git pull | |
cd .. | |
python3 tests/SysY2022/perf/update_info.py pages | |
cd pages | |
git config user.name "github-actions[bot]" | |
git config user.email "41898282+github-actions[bot]@users.noreply.github.com" | |
git add . | |
git status | |
git commit -m "Update commit information by ${{github.sha}}" | |
git push | |
- name: Env | |
run: | | |
sudo apt update | |
sudo apt install spim ninja-build libgtest-dev g++-12-riscv64-linux-gnu g++-12-arm-linux-gnueabihf # llvm-15-dev gcc-11-riscv64-linux-gnu g++-11-riscv64-linux-gnu gcc-10-mipsel-linux-gnu g++-10-mipsel-linux-gnu | |
- name: Format | |
run: make format-check | |
# - uses: actions/checkout@v3 | |
# with: | |
# repository: dtcxzyw/qemu | |
# path: ${{github.workspace}}/qemu | |
# - name: Build qemu | |
# run: | | |
# cd qemu | |
# ./configure --target-list=riscv64-linux-user,mipsel-linux-user,arm-linux-user --enable-plugins | |
# make -j | |
# echo "QEMU_PATH=$(pwd)/build" >> $GITHUB_ENV | |
- name: Build | |
run: | | |
mkdir build && cd build | |
cmake .. -G Ninja -DCMAKE_BUILD_TYPE=Release -DCMMC_LLVM_SUPPORT=OFF | |
cmake --build . | |
- name: Test | |
run: cd build && ctest --verbose | |
- name: Generate Performance Source | |
run: cd build && python3 ../tests/test_driver.py bin/cmmc ../tests arm,riscv,compile | |
- name: Upload Performance Source | |
uses: actions/upload-artifact@v2 | |
with: | |
name: PerformanceSource | |
path: build/bin/SysY2022/ | |
arm_perf: | |
runs-on: [self-hosted, ARM64] | |
needs: build | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
lfs: true | |
- name: Download Artifacts | |
uses: actions/download-artifact@v2 | |
with: | |
name: PerformanceSource | |
path: ${{github.workspace}}/bin/SysY2022/ | |
- name: Run | |
run: | | |
cd bin | |
python3 ../tests/test_driver.py cmmc ../tests arm,run | |
- uses: actions/checkout@v3 | |
if: always() | |
with: | |
ref: gh-pages | |
path: pages | |
- name: Push perf data to gh-pages | |
uses: nick-fields/retry@v2 | |
if: always() | |
with: | |
timeout_minutes: 60 | |
max_attempts: 3 | |
command: | | |
cd pages | |
git reset origin/gh-pages -- | |
git clean -f -d | |
git pull | |
cd .. | |
python3 tests/SysY2022/perf/collect.py bin/SysY2022/performance pages arm | |
cd pages | |
git config user.name "github-actions[bot]" | |
git config user.email "41898282+github-actions[bot]@users.noreply.github.com" | |
git add . | |
git commit -m "Push perf data by ${{github.sha}} (ARM)" | |
git push | |
riscv_perf: | |
runs-on: [self-hosted, riscv64] | |
needs: build | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
lfs: true | |
- name: Download Artifacts | |
uses: actions/download-artifact@v2 | |
with: | |
name: PerformanceSource | |
path: ${{github.workspace}}/bin/SysY2022/ | |
- name: Run | |
run: | | |
cd bin | |
python3 ../tests/test_driver.py cmmc ../tests riscv,run | |
- uses: actions/checkout@v3 | |
if: always() | |
with: | |
ref: gh-pages | |
path: pages | |
- name: Push perf data to gh-pages | |
uses: nick-fields/retry@v2 | |
if: always() | |
with: | |
timeout_minutes: 60 | |
max_attempts: 3 | |
command: | | |
cd pages | |
git reset origin/gh-pages -- | |
git clean -f -d | |
git pull | |
cd .. | |
python3 tests/SysY2022/perf/collect.py bin/SysY2022/performance pages riscv | |
cd pages | |
git config user.name "github-actions[bot]" | |
git config user.email "41898282+github-actions[bot]@users.noreply.github.com" | |
git add . | |
git commit -m "Push perf data by ${{github.sha}} (RISC-V)" | |
git push |