Skip to content

Add floor, ceil, round methods to FixedPoint #17

Add floor, ceil, round methods to FixedPoint

Add floor, ceil, round methods to FixedPoint #17

Workflow file for this run

name: sbt test
on:
push:
branches:
- master
- 'chisel*.*'
pull_request:
branches:
- master
- 'chisel*.*'
permissions:
contents: read
env:
JDK_VERSION: 20
JDK_DIST: temurin
VERILATOR_REPO: https://github.com/verilator/verilator
VERILATOR_DIR: verilator
VERILATOR_VERSION_TAG: v4.228
FIRTOOL_VERSION: v1.37.0
FIRTOOL_VERSION_TAG: firtool-1.37.0
jobs:
test:
runs-on: ubuntu-latest
steps:
- name: Check out repo
uses: actions/checkout@v3
- name: Set up JDK ${{ env.JDK_VERSION }} (${{ env.JDK_DIST }})
uses: actions/setup-java@v3
with:
java-version: ${{ env.JDK_VERSION }}
distribution: ${{ env.JDK_DIST }}
cache: 'sbt'
- name: Install firtool ${{ env.FIRTOOL_VERSION }}
run: |
wget -q -O - "https://github.com/llvm/circt/releases/download/${{ env.FIRTOOL_VERSION_TAG }}/firrtl-bin-ubuntu-20.04.tar.gz" | tar -zx
sudo mv "${{ env.FIRTOOL_VERSION_TAG }}/bin/firtool" /usr/local/bin
- name: "Cache: Verilator ${{ env.VERILATOR_VERSION_TAG }}"
uses: actions/cache@v3
id: install-cache
with:
path: ${{ env.VERILATOR_DIR }}
key: ${{ runner.os }}-${{ runner.arch }}-verilator-${{ env.VERILATOR_VERSION_TAG }}
- name: Install Verilator ${{ env.VERILATOR_VERSION_TAG }} from cache
if: steps.install-cache.outputs.cache-hit == 'true'
run: |
sudo apt-get update -y
sudo apt-get install -y git help2man perl python3 make autoconf g++ flex bison ccache
sudo apt-get install -y numactl perl-doc
sudo apt-get install -my libgoogle-perftools-dev || true
sudo apt-get install -my libfl2 || true # Ubuntu only (ignore if gives error)
sudo apt-get install -my libfl-dev || true # Ubuntu only (ignore if gives error)
sudo apt-get install -my zlibc zlib1g zlib1g-dev || true # Ubuntu only (ignore if gives error)
cd "$VERILATOR_DIR"
sudo make install
verilator --version
- name: Install Verilator ${{ env.VERILATOR_VERSION_TAG }} from scratch
if: steps.install-cache.outputs.cache-hit != 'true'
run: |
sudo apt-get update -y
sudo apt-get install -y git help2man perl python3 make autoconf g++ flex bison ccache
sudo apt-get install -y numactl perl-doc
sudo apt-get install -my libgoogle-perftools-dev || true
sudo apt-get install -my libfl2 || true # Ubuntu only (ignore if gives error)
sudo apt-get install -my libfl-dev || true # Ubuntu only (ignore if gives error)
sudo apt-get install -my zlibc zlib1g zlib1g-dev || true # Ubuntu only (ignore if gives error)
git clone "$VERILATOR_REPO" "$VERILATOR_DIR"
cd "$VERILATOR_DIR"
git checkout "$VERILATOR_VERSION_TAG"
autoconf
./configure
make -j "$(nproc)"
sudo make install
verilator --version
- name: Check scalafmt
run: sbt scalafmtCheckAll
- name: Run tests
run: sbt test