mirror of
https://github.com/openhwgroup/cva6.git
synced 2025-04-20 04:07:36 -04:00
Exceptions : Add bins for Read-only CSRs (#1885)
This commit is contained in:
parent
f5662fb49f
commit
9f928e4c12
1 changed files with 14 additions and 0 deletions
14
verif/env/uvme/cov/uvme_exception_covg.sv
vendored
14
verif/env/uvme/cov/uvme_exception_covg.sv
vendored
|
@ -104,10 +104,20 @@ covergroup cg_exception(
|
|||
bins is_csr_instr = {uvma_isacov_pkg::CSR_GROUP};
|
||||
}
|
||||
|
||||
cp_is_write_csr: coverpoint instr.is_csr_write() {
|
||||
bins is_csr_write = {1};
|
||||
}
|
||||
|
||||
cp_illegal_csr: coverpoint instr.csr {
|
||||
bins UNSUPPORTED_CSR[] = {[uvma_isacov_pkg::USTATUS:uvma_isacov_pkg::VLENB]} with (cfg_illegal_csr[item] == 1) iff(instr.trap);
|
||||
}
|
||||
|
||||
cp_ro_csr: coverpoint instr.csr {
|
||||
bins ONLY_READ_CSR[] = {[uvma_isacov_pkg::CYCLE:uvma_isacov_pkg::HPMCOUNTER31],
|
||||
[uvma_isacov_pkg::CYCLEH:uvma_isacov_pkg::HPMCOUNTER31H],
|
||||
[uvma_isacov_pkg::MVENDORID:uvma_isacov_pkg::MHARTID]} with (cfg_illegal_csr[item] == 0) iff(instr.trap);
|
||||
}
|
||||
|
||||
cp_misalign_load: coverpoint instr.group {
|
||||
bins misalign_load = {uvma_isacov_pkg::MISALIGN_LOAD_GROUP};
|
||||
}
|
||||
|
@ -136,6 +146,10 @@ covergroup cg_exception(
|
|||
ignore_bins IGN = !binsof(cp_exception) intersect{2};
|
||||
}
|
||||
|
||||
cross_illegal_write_csr : cross cp_exception, cp_ro_csr, cp_is_write_csr {
|
||||
ignore_bins IGN = !binsof(cp_exception) intersect{2};
|
||||
}
|
||||
|
||||
cross_misaligned_load : cross cp_exception, cp_misalign_load, cp_add_mem iff(!unaligned_access_supported){
|
||||
ignore_bins IGN_EXC = !binsof(cp_exception) intersect{4};
|
||||
ignore_bins IGN_ADD = binsof(cp_add_mem) intersect{0};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue