# This file describes the GitHub Actions workflow for continuous integration of XS Core. name: EMU Test on: push: branches: [ master ] pull_request: branches: [ master ] jobs: generate-verilog: runs-on: self-hosted continue-on-error: false name: Generate Verilog steps: - uses: actions/checkout@v2 with: submodules: 'recursive' - name: set env run: | export HEAD_SHA=${{ github.run_number }} echo "NEMU_HOME=/home/ci-runner/xsenv/NEMU" >> $GITHUB_ENV echo "WAVE_HOME=/bigdata/xs-wave/${HEAD_SHA}" >> $GITHUB_ENV mkdir -p /bigdata/xs-wave/${HEAD_SHA} - name: Check Wiring run: bash .github/workflows/check-usage.sh "BoringUtils" $GITHUB_WORKSPACE - name: generate verilog file run: python3 $GITHUB_WORKSPACE/scripts/xiangshan.py --generate --num-cores 2 - name: check pc usages run: python3 $GITHUB_WORKSPACE/.github/workflows/check_pc.py build/XSTop.v - name: build MinimalConfig emu run: | python3 $GITHUB_WORKSPACE/scripts/xiangshan.py --build \ --disable-log --threads 4 --config MinimalConfig - name: run MinimalConfig - Linux run: | python3 $GITHUB_WORKSPACE/scripts/xiangshan.py --threads 4 --numa --ci linux-hello 2> perf.log cat perf.log | sort find $GITHUB_WORKSPACE/build -name "*.vcd" | xargs -I {} mv {} $WAVE_HOME/minimal-linux-hello.vcd emu-basics: runs-on: self-hosted continue-on-error: false timeout-minutes: 720 name: EMU - Basics steps: - uses: actions/checkout@v2 with: submodules: 'recursive' - name: set env run: | export HEAD_SHA=${{ github.run_number }} echo "NEMU_HOME=/home/ci-runner/xsenv/NEMU" >> $GITHUB_ENV echo "AM_HOME=/home/ci-runner/xsenv/nexus-am" >> $GITHUB_ENV echo "PERF_HOME=/bigdata/xs-perf/${HEAD_SHA}" >> $GITHUB_ENV echo "WAVE_HOME=/bigdata/xs-wave/${HEAD_SHA}" >> $GITHUB_ENV mkdir -p /bigdata/xs-perf/${HEAD_SHA} mkdir -p /bigdata/xs-wave/${HEAD_SHA} - name: Build EMU run: | python3 $GITHUB_WORKSPACE/scripts/xiangshan.py --build --disable-log --threads 8 - name: Basic Test - cputest run: | python3 $GITHUB_WORKSPACE/scripts/xiangshan.py --threads 8 --ci cputest 2> /dev/zero - name: Basic Test - riscv-tests run: | python3 $GITHUB_WORKSPACE/scripts/xiangshan.py --threads 8 --rvtest /home/ci-runner/xsenv/riscv-tests --ci riscv-tests 2> /dev/zero - name: Basic Test - misc-tests run: | python3 $GITHUB_WORKSPACE/scripts/xiangshan.py --threads 8 --ci misc-tests 2> /dev/zero - name: Simple Test - microbench run: | python3 $GITHUB_WORKSPACE/scripts/xiangshan.py --threads 8 --ci microbench 2> perf.log cat perf.log | sort | tee $PERF_HOME/microbench.log find $GITHUB_WORKSPACE/build -name "*.vcd" | xargs -I {} mv {} $WAVE_HOME/microbench.vcd - name: Simple Test - CoreMark run: | python3 $GITHUB_WORKSPACE/scripts/xiangshan.py --threads 8 --numa --ci coremark 2> perf.log cat perf.log | sort | tee $PERF_HOME/coremark.log find $GITHUB_WORKSPACE/build -name "*.vcd" | xargs -I {} mv {} $WAVE_HOME/coremark.vcd - name: System Test - Linux run: | python3 $GITHUB_WORKSPACE/scripts/xiangshan.py --threads 8 --numa --ci linux-hello 2> perf.log cat perf.log | sort | tee $PERF_HOME/linux.log find $GITHUB_WORKSPACE/build -name "*.vcd" | xargs -I {} mv {} $WAVE_HOME/linux-hello.vcd - name: Floating-point Test - povray run: | python3 $GITHUB_WORKSPACE/scripts/xiangshan.py --threads 8 --numa --max-instr 5000000 --ci povray 2> perf.log cat perf.log | sort | tee $PERF_HOME/povray.log find $GITHUB_WORKSPACE/build -name "*.vcd" | xargs -I {} mv {} $WAVE_HOME/povray.vcd emu-performance: runs-on: self-hosted continue-on-error: false timeout-minutes: 720 name: EMU - Performance steps: - uses: actions/checkout@v2 with: submodules: 'recursive' - name: set env run: | export HEAD_SHA=${{ github.run_number }} echo "NEMU_HOME=/home/ci-runner/xsenv/NEMU" >> $GITHUB_ENV echo "AM_HOME=/home/ci-runner/xsenv/nexus-am" >> $GITHUB_ENV echo "PERF_HOME=/bigdata/xs-perf/${HEAD_SHA}" >> $GITHUB_ENV echo "WAVE_HOME=/bigdata/xs-wave/${HEAD_SHA}" >> $GITHUB_ENV mkdir -p /bigdata/xs-perf/${HEAD_SHA} mkdir -p /bigdata/xs-wave/${HEAD_SHA} - name: Build EMU run: | python3 $GITHUB_WORKSPACE/scripts/xiangshan.py --build \ --dramsim3 /home/ci-runner/xsenv/DRAMsim3 \ --disable-log --with-dramsim3 --threads 16 - name: SPEC06 Test - mcf run: | python3 $GITHUB_WORKSPACE/scripts/xiangshan.py --threads 16 --max-instr 5000000 --numa --ci mcf 2> perf.log cat perf.log | sort | tee $PERF_HOME/mcf.log find $GITHUB_WORKSPACE/build -name "*.vcd" | xargs -I {} mv {} $WAVE_HOME/mcf.vcd - name: SPEC06 Test - xalancbmk run: | python3 $GITHUB_WORKSPACE/scripts/xiangshan.py --threads 16 --max-instr 5000000 --numa --ci xalancbmk 2> perf.log cat perf.log | sort | tee $PERF_HOME/xalancbmk.log find $GITHUB_WORKSPACE/build -name "*.vcd" | xargs -I {} mv {} $WAVE_HOME/xalancbmk.vcd - name: SPEC06 Test - gcc run: | python3 $GITHUB_WORKSPACE/scripts/xiangshan.py --threads 16 --max-instr 5000000 --numa --ci gcc 2> perf.log cat perf.log | sort | tee $PERF_HOME/gcc.log find $GITHUB_WORKSPACE/build -name "*.vcd" | xargs -I {} mv {} $WAVE_HOME/gcc.vcd - name: SPEC06 Test - namd run: | python3 $GITHUB_WORKSPACE/scripts/xiangshan.py --threads 16 --max-instr 5000000 --numa --ci namd 2> perf.log cat perf.log | sort | tee $PERF_HOME/namd.log find $GITHUB_WORKSPACE/build -name "*.vcd" | xargs -I {} mv {} $WAVE_HOME/namd.vcd - name: SPEC06 Test - milc run: | python3 $GITHUB_WORKSPACE/scripts/xiangshan.py --threads 16 --max-instr 5000000 --numa --ci milc 2> perf.log cat perf.log | sort | tee $PERF_HOME/milc.log find $GITHUB_WORKSPACE/build -name "*.vcd" | xargs -I {} mv {} $WAVE_HOME/milc.vcd - name: SPEC06 Test - lbm run: | python3 $GITHUB_WORKSPACE/scripts/xiangshan.py --threads 16 --max-instr 5000000 --numa --ci lbm 2> perf.log cat perf.log | sort | tee $PERF_HOME/lbm.log find $GITHUB_WORKSPACE/build -name "*.vcd" | xargs -I {} mv {} $WAVE_HOME/lbm.vcd - name: SPEC06 Test - gromacs run: | python3 $GITHUB_WORKSPACE/scripts/xiangshan.py --threads 16 --max-instr 5000000 --numa --ci gromacs 2> perf.log cat perf.log | sort | tee $PERF_HOME/gromacs.log find $GITHUB_WORKSPACE/build -name "*.vcd" | xargs -I {} mv {} $WAVE_HOME/gromacs.vcd - name: SPEC06 Test - wrf run: | python3 $GITHUB_WORKSPACE/scripts/xiangshan.py --threads 16 --max-instr 5000000 --numa --ci wrf 2> perf.log cat perf.log | sort | tee $PERF_HOME/wrf.log find $GITHUB_WORKSPACE/build -name "*.vcd" | xargs -I {} mv {} $WAVE_HOME/wrf.vcd - name: SPEC06 Test - astar run: | python3 $GITHUB_WORKSPACE/scripts/xiangshan.py --threads 16 --max-instr 5000000 --numa --ci astar 2> perf.log cat perf.log | sort | tee $PERF_HOME/astar.log find $GITHUB_WORKSPACE/build -name "*.vcd" | xargs -I {} mv {} $WAVE_HOME/astar.vcd