From a85c76a78be70cd8f6f34ef9c59f93010b18f54a Mon Sep 17 00:00:00 2001 From: Clo91eaf Date: Sun, 6 Oct 2024 22:09:42 +0800 Subject: [PATCH] [ci] output urg report in vcs flow --- .github/workflows/main.yml | 2 +- templates/chisel/nix/gcd/vcs.nix | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index a453afa..504e5ca 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -56,7 +56,7 @@ jobs: ref: ${{ github.event.pull_request.head.sha }} - name: "Run VCS" run: | - nix build '.#gcd.vcs.tests.simple-sim' --impure -L + nix build '.#gcd.vcs.tests.simple-sim' --impure -L && cat result/urgReport/asserts.txt run-verilator: name: "Run Verilator" diff --git a/templates/chisel/nix/gcd/vcs.nix b/templates/chisel/nix/gcd/vcs.nix index fb80e05..4241498 100644 --- a/templates/chisel/nix/gcd/vcs.nix +++ b/templates/chisel/nix/gcd/vcs.nix @@ -69,8 +69,11 @@ stdenv.mkDerivation (finalAttr: { export DATA_ONLY=1 ${finalAttr.finalPackage}/bin/${binName} + ${vcs-fhs-env}/bin/vcs-fhs-env -c "urg -dir "$GCD_SIM_RESULT_DIR"/result/${coverageName} -format text" + mkdir -p "$out" cp -vr "$GCD_SIM_RESULT_DIR"/result/* "$out/" + cp -vr ./urgReport "$out/" ''; };