Verilator Nightly #348
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: Verilator Nightly | |
on: | |
workflow_call: | |
workflow_dispatch: | |
schedule: | |
# cron format "minutes hours day-of-month month day-of-week" | |
# 5:30 PM Pacific on tuesday and friday | |
- cron: '30 0 * * 3,6' | |
jobs: | |
smoke_test: | |
name: Smoke Test | |
runs-on: n2d-highcpu-96 | |
timeout-minutes: 2800 | |
env: | |
VERILATOR_VERSION: v5.006 | |
PKG_CONFIG_PATH: /opt/verilator/share/pkgconfig | |
steps: | |
- name: Checkout repo | |
uses: actions/checkout@v3 | |
with: | |
submodules: 'true' | |
- name: Install verilator | |
run: | | |
if [ -d "/opt/verilator" ]; then | |
# The GCP runners already have verilator installed | |
exit | |
fi | |
sudo apt-get update -qy && sudo apt-get install flex bison libfl2 libfl-dev help2man | |
cd /tmp/ | |
git clone -b "${VERILATOR_VERSION}" https://github.com/verilator/verilator | |
cd verilator | |
autoconf | |
./configure --prefix=/opt/verilator | |
make -j64 | |
sudo make install | |
- name: Install nextest | |
run: | | |
cargo install cargo-nextest --locked | |
- name: Setup verilator path | |
run: | | |
echo /opt/verilator/bin >> $GITHUB_PATH | |
- name: Run all tests inside verilator (will take hours) | |
run: | | |
COMMON_ARGS=( | |
--features=verilator,itrng | |
--release | |
) | |
# Workaround https://github.com/nextest-rs/nextest/issues/267 | |
export LD_LIBRARY_PATH=$(rustc --print sysroot)/lib | |
cargo-nextest nextest list \ | |
"${COMMON_ARGS[@]}" \ | |
--message-format json > /tmp/nextest-list.json | |
cargo nextest run \ | |
"${COMMON_ARGS[@]}" \ | |
--profile=verilator | |
- name: 'Upload test results' | |
uses: actions/upload-artifact@v4 | |
if: success() || failure() | |
with: | |
name: caliptra-test-results | |
path: | | |
/tmp/junit.xml | |
/tmp/nextest-list.json |