Skip to content

feat(tomasulo): resolve FRM_DYN rounding mode to frm CSR at dispatch … #64

feat(tomasulo): resolve FRM_DYN rounding mode to frm CSR at dispatch …

feat(tomasulo): resolve FRM_DYN rounding mode to frm CSR at dispatch … #64

Workflow file for this run

# Copyright 2026 Two Sigma Open Source, LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
name: CI
on:
push:
branches: [main]
pull_request:
branches: [main]
env:
# Tool versions - single source of truth (also in Dockerfile)
VERILATOR_VERSION: "5.044"
YOSYS_VERSION: "0.60"
jobs:
# Build the Docker image (shared by all jobs)
build-docker:
name: Build Docker Image
runs-on: ubuntu-24.04
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Build and export Docker image
uses: docker/build-push-action@v6
with:
context: .
tags: frost-dev:latest
outputs: type=docker,dest=/tmp/frost-dev.tar
cache-from: type=gha
cache-to: type=gha,mode=max
- name: Upload Docker image artifact
uses: actions/upload-artifact@v4
with:
name: frost-docker-image
path: /tmp/frost-dev.tar
retention-days: 1
# Run Cocotb tests with Verilator (excludes arch compliance, which has its own matrix job)
test-verilator:
name: Cocotb Tests (Verilator)
runs-on: ubuntu-24.04
needs: build-docker
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
submodules: recursive
- name: Download Docker image
uses: actions/download-artifact@v4
with:
name: frost-docker-image
path: /tmp
- name: Load Docker image
run: docker load --input /tmp/frost-dev.tar
- name: Run Cocotb tests with Verilator
run: |
docker run --rm -v ${{ github.workspace }}:/workspace frost-dev:latest \
pytest tests/ -m cocotb --sim verilator -v \
--ignore=tests/test_arch_compliance.py \
--ignore=tests/test_riscv_tests.py \
--ignore=tests/test_riscv_torture.py
# RISC-V Architecture Compliance Tests - parallelized by extension
test-arch-compliance:
name: Arch Tests (${{ matrix.extension }})
runs-on: ubuntu-24.04
needs: build-docker
strategy:
fail-fast: false
matrix:
extension: [I, M, A, F, D, C, B, K, Zicond, Zifencei, privilege, F_Zcf, D_Zcd, hints]
# Individual jobs for slow tests (>5000 test cases) that are excluded
# from the F/D extension jobs by the SIM_MAX_TEST_CASES filter.
include:
- extension: "F fadd_b11"
test_path: rv32i_m/F/src/fadd_b11-01.S
- extension: "F fmadd_b1"
test_path: rv32i_m/F/src/fmadd_b1-01.S
- extension: "F fmsub_b1"
test_path: rv32i_m/F/src/fmsub_b1-01.S
- extension: "F fnmadd_b1"
test_path: rv32i_m/F/src/fnmadd_b1-01.S
- extension: "F fnmsub_b1"
test_path: rv32i_m/F/src/fnmsub_b1-01.S
- extension: "F fsub_b11"
test_path: rv32i_m/F/src/fsub_b11-01.S
- extension: "D fadd.d_b11"
test_path: rv32i_m/D/src/fadd.d_b11-01.S
- extension: "D fmadd.d_b1"
test_path: rv32i_m/D/src/fmadd.d_b1-01.S
- extension: "D fmsub.d_b1"
test_path: rv32i_m/D/src/fmsub.d_b1-01.S
- extension: "D fnmadd.d_b1"
test_path: rv32i_m/D/src/fnmadd.d_b1-01.S
- extension: "D fnmsub.d_b1"
test_path: rv32i_m/D/src/fnmsub.d_b1-01.S
- extension: "D fssub.d_b11"
test_path: rv32i_m/D/src/fssub.d_b11-01.S
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
submodules: recursive
- name: Download Docker image
uses: actions/download-artifact@v4
with:
name: frost-docker-image
path: /tmp
- name: Load Docker image
run: docker load --input /tmp/frost-dev.tar
- name: Run arch compliance tests (${{ matrix.extension }})
run: |
if [ -n "${{ matrix.test_path }}" ]; then
docker run --rm -v ${{ github.workspace }}:/workspace frost-dev:latest \
python3 tests/test_arch_compliance.py --sim verilator --test ${{ matrix.test_path }}
else
docker run --rm -v ${{ github.workspace }}:/workspace frost-dev:latest \
python3 tests/test_arch_compliance.py --sim verilator --extensions ${{ matrix.extension }}
fi
# riscv-tests ISA Tests - parallelized by suite
test-riscv-tests:
name: riscv-tests (${{ matrix.suite }})
runs-on: ubuntu-24.04
needs: build-docker
strategy:
fail-fast: false
matrix:
suite: [rv32ui, rv32um, rv32ua, rv32uf, rv32ud, rv32uc, rv32mi, rv32uzba, rv32uzbb, rv32uzbs, rv32uzbkb]
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
submodules: recursive
- name: Download Docker image
uses: actions/download-artifact@v4
with:
name: frost-docker-image
path: /tmp
- name: Load Docker image
run: docker load --input /tmp/frost-dev.tar
- name: Run riscv-tests ISA suite (${{ matrix.suite }})
run: |
docker run --rm -v ${{ github.workspace }}:/workspace frost-dev:latest \
python3 tests/test_riscv_tests.py --sim verilator --suites ${{ matrix.suite }}
# riscv-tests Benchmarks
test-riscv-benchmarks:
name: riscv-tests Benchmarks (${{ matrix.benchmark }})
runs-on: ubuntu-24.04
needs: build-docker
strategy:
fail-fast: false
matrix:
benchmark: [median, multiply, qsort, rsort, towers, vvadd, dhrystone, mm, spmv]
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
submodules: recursive
- name: Download Docker image
uses: actions/download-artifact@v4
with:
name: frost-docker-image
path: /tmp
- name: Load Docker image
run: docker load --input /tmp/frost-dev.tar
- name: Run riscv-tests benchmark (${{ matrix.benchmark }})
run: |
docker run --rm -v ${{ github.workspace }}:/workspace frost-dev:latest \
python3 tests/test_riscv_tests.py --sim verilator --benchmarks ${{ matrix.benchmark }}
# riscv-torture Random Instruction Tests
test-riscv-torture:
name: riscv-torture Tests
runs-on: ubuntu-24.04
needs: build-docker
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
submodules: recursive
- name: Download Docker image
uses: actions/download-artifact@v4
with:
name: frost-docker-image
path: /tmp
- name: Load Docker image
run: docker load --input /tmp/frost-dev.tar
- name: Run riscv-torture tests
run: |
docker run --rm -v ${{ github.workspace }}:/workspace frost-dev:latest \
python3 tests/test_riscv_torture.py --sim verilator --all
# Run Cocotb tests with Icarus Verilog
test-icarus:
name: Cocotb Tests (Icarus)
runs-on: ubuntu-24.04
needs: build-docker
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
submodules: recursive
- name: Download Docker image
uses: actions/download-artifact@v4
with:
name: frost-docker-image
path: /tmp
- name: Load Docker image
run: docker load --input /tmp/frost-dev.tar
- name: Run Cocotb tests with Icarus
run: |
docker run --rm -v ${{ github.workspace }}:/workspace frost-dev:latest \
pytest tests/ -m cocotb --sim icarus -v
# Run Yosys synthesis check
test-synthesis:
name: Yosys Synthesis Check
runs-on: ubuntu-24.04
needs: build-docker
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
submodules: recursive
- name: Download Docker image
uses: actions/download-artifact@v4
with:
name: frost-docker-image
path: /tmp
- name: Load Docker image
run: docker load --input /tmp/frost-dev.tar
- name: Run synthesis tests
run: |
docker run --rm -v ${{ github.workspace }}:/workspace frost-dev:latest \
pytest tests/ -m synthesis -v
# Run SymbiYosys formal verification
test-formal:
name: Formal Verification
runs-on: ubuntu-24.04
needs: build-docker
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
submodules: recursive
- name: Download Docker image
uses: actions/download-artifact@v4
with:
name: frost-docker-image
path: /tmp
- name: Load Docker image
run: docker load --input /tmp/frost-dev.tar
- name: Run formal verification
run: |
docker run --rm -v ${{ github.workspace }}:/workspace frost-dev:latest \
pytest tests/ -m formal -v
# Run linting inside Docker to ensure version consistency with pre-commit
lint:
name: Lint
runs-on: ubuntu-24.04
needs: build-docker
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Download Docker image
uses: actions/download-artifact@v4
with:
name: frost-docker-image
path: /tmp
- name: Load Docker image
run: docker load --input /tmp/frost-dev.tar
- name: Run pre-commit hooks
run: |
docker run --rm -v ${{ github.workspace }}:/workspace frost-dev:latest \
pre-commit run --all-files