Add GitHub Action for CI and fix broken testcases (#391)

* feat(ci): add GitHub Action for push and pull request

* fix(ci): fix broken testcases

* chore: add CODEOWNERS for ci

* ci: bump actions/upload-artifact from 6 to 7
This commit is contained in:
Kazuto Iris 2026-02-28 05:51:28 +08:00 committed by GitHub
parent 95d5ebb47c
commit a47a8dd831
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
6 changed files with 72 additions and 10 deletions

6
.github/dependabot.yml vendored Normal file
View File

@ -0,0 +1,6 @@
version: 2
updates:
- package-ecosystem: github-actions
directory: "/"
schedule:
interval: "daily"

54
.github/workflows/ci.yml vendored Normal file
View File

@ -0,0 +1,54 @@
name: CI
on:
push:
pull_request:
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v6
with:
submodules: true
- name: Set up dependencies
run: |
sudo apt-get update && sudo apt-get install -y flex libfl-dev bison tcl-dev tcl-tclreadline libeigen3-dev ninja-build
- name: Set up cudd-3.0.0
run: |
wget https://github.com/oscc-ip/artifact/releases/download/cudd-3.0.0/build.tar.gz
mkdir -p cudd
tar -zxvf build.tar.gz -Ccudd
- name: Build
run: |
mkdir build
cd build
cmake .. -G Ninja -DCUDD_DIR=$(pwd)/../cudd -DCMAKE_INSTALL_PREFIX=$(pwd)/install -DCMAKE_BUILD_TYPE=Release
cmake --build . --target all -- -j $(nproc)
cmake --install .
tar -zcvf build.tar.gz -Cinstall .
- name: Test
run: |
cd test
./regression
- name: Upload Artifacts
uses: actions/upload-artifact@v7
if: ${{ !cancelled() }}
with:
name: artifact
path: |
build/install/*
- name: Upload Test Result
uses: actions/upload-artifact@v7
if: ${{ !cancelled() }}
with:
name: result
path: |
test/results/*

2
CODEOWNERS Normal file
View File

@ -0,0 +1,2 @@
# For CI/CD issues
/.github/ @kazutoiris

View File

@ -53,4 +53,4 @@ in2
[get_ports -filter direction==output *]
out
[get_cells -filter {name ~= *r1*} *]
Error: get_filter.tcl line 48, unknown filter operand.
Error 336: get_filter.tcl line 48, unknown filter operand.

View File

@ -36,7 +36,7 @@
"net": "mid",
"arrival": 3.296e-10,
"capacitance": 1.949e-15,
"slew": 4.035e-11
"slew": 3.612e-11
},
{
"instance": "_1416_[0]",
@ -45,7 +45,7 @@
"pin": "_1416_[0]/D",
"net": "mid",
"arrival": 3.296e-10,
"slew": 4.035e-11
"slew": 3.612e-11
}
],
"target_clock": "clk",
@ -72,9 +72,9 @@
],
"data_arrival_time": 3.296e-10,
"crpr": 0.000e+00,
"margin": 1.225e-10,
"required_time": 9.877e-09,
"slack": 9.548e-09
"margin": 1.207e-10,
"required_time": 9.879e-09,
"slack": 9.550e-09
}
]
}

View File

@ -1,12 +1,12 @@
Warning 1: suppress_msg.tcl line 18, cmd warn 1
caught Error: suppress_msg.tcl line 18, cmd error 1
caught Error 2: suppress_msg.tcl line 18, cmd error 1
Warning 1: cmd warn 2
caught Error: 2cmd error 2
caught Error: 2 cmd error 2
after error
caught
caught
after error
Warning 1: suppress_msg.tcl line 51, cmd warn 7
caught Error: suppress_msg.tcl line 51, cmd error 7
caught Error 2: suppress_msg.tcl line 51, cmd error 7
Warning 1: cmd warn 8
caught Error: 2cmd error 8
caught Error: 2 cmd error 8