Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Missing ACT coverpoints #488

Open
7 of 28 tasks
jordancarlin opened this issue Feb 24, 2025 · 1 comment
Open
7 of 28 tasks

Missing ACT coverpoints #488

jordancarlin opened this issue Feb 24, 2025 · 1 comment

Comments

@jordancarlin
Copy link
Member

jordancarlin commented Feb 24, 2025

The following instructions have coverage holes when run against the riscv-arch-test coverpoints. The general type of hole is listed for all instructions and specific examples of coverpoints are given for some.

Uncovered ACT coverpoints

I Extension

NOTE: ea_align = (rs1_val + imm_val) % 4

Zbb Extension

  • orc.b
    • rs1_val
      • rs1_val == 0x102040801020408: 0
      • rs1_val == 0x204080102040801: 0
      • rs1_val == 0x408010204080102: 0
      • rs1_val == 0x801020408010204: 0

M Extension

Zaamo Extension

Zba Extension

Additional extensions to follow

  • Zbs
  • Zbc
  • Zca
  • Zcb
  • Zcf
  • Zcd
  • D
  • F
  • Zfh
  • Zfa
  • Zicboz
  • E
  • Zbkb
  • Zbkx
  • Zkne
  • Zknd
  • Zknh
  • Zicond
  • Zifencei
  • priv (ecall, ebreak, misalign)
@jordancarlin
Copy link
Member Author

Here is the (very rough) script I'm using to gather this data. It's still a fairly manual process and required the specific list of instructions to be tested to be listed out. It also needs the rvtest_end symbol to be inserted into the footer of each test.

#!/bin/bash

# General variables
XLEN=64
FLEN=64
EXTENSION=I

# ISACOV variables
directory=i
coverage_file=rv"$XLEN"i.cgf
instruction=srli

# Run Sail to generate a trace file
riscv_sim_rv"$XLEN"d -i -v --trace=step --pmp-count=16 --pmp-grain=0 \
"$CVW_ARCH_VERIF"/tests/lockstep/rv$XLEN/$EXTENSION/WALLY-COV-"$instruction".elf > $EXTENSION.trace

# Run ISAC to generate a coverage report
riscv_isac coverage -d -t $EXTENSION.trace \
--parser-name c_sail --decoder-name internaldecoder -o $EXTENSION.rpt \
--sig-label begin_signature end_signature \
--test-label rvtest_entry_point rvtest_end  \
-e "$CVW_ARCH_VERIF"/tests/lockstep/rv$XLEN/$EXTENSION/WALLY-COV-"$instruction".elf \
-c "$WALLY"/addins/riscv-arch-test/coverage/dataset.cgf \
-c "$WALLY"/addins/riscv-arch-test/coverage/$directory/$coverage_file \
-x $XLEN -f $FLEN \
-l "$instruction"

# -l add -l addi -l addiw -l addw -l and -l andi -l auipc -l beq -l bge -l bgeu -l blt -l bltu -l bne -l jal \
# -l jalr -l lui -l or -l ori -l sll -l slli -l slliw -l sllw \
# -l slt -l slti -l sltiu -l sltu -l sra -l srai -l sraiw -l sraw -l srl -l srli -l srliw -l srlw -l sub -l subw \
# -l xor -l xori -l fence 
# -l lb-align -l lbu-align -l lh-align -l lhu-align -l lw-align -l lwu-align -l ld-align -l sb-align -l sh-align -l sw-align -l sd-align

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant