opentitan icon indicating copy to clipboard operation
opentitan copied to clipboard

[dv] Predict value after a read of an RC field in shadow_reg_errors

Open rswarbrick opened this issue 8 months ago • 2 comments

The sequence runs without the scoreboard enabled, so the sequence is responsible for updating the RAL. This commit adds a missing update.

The motivation for this was to fix the shadow_reg_errors test for ac_range_check (thanks, @martin-velay, for discovering the problem). Try that out with util/dvsim/dvsim.py hw/top_darjeeling/ip_autogen/ac_range_check/dv/ac_range_check_sim_cfg.hjson -i ac_range_check_shadow_reg_errors -t xcelium --fi=1.

rswarbrick avatar Apr 02 '25 14:04 rswarbrick

(Annoyingly, the test still fails after this change, but it gets much further and it's exploding on something unrelated, so I thought this was worth doing as a first step!)

rswarbrick avatar Apr 02 '25 14:04 rswarbrick

Thanks a lot Rupert for working on this. I wonder why it has never been raised before. Do you have any clue?

martin-velay avatar Apr 02 '25 14:04 martin-velay

@rswarbrick, I have "cherry-picked" your modification on the master and your commit fixes the issue I raised. It works well for tests ac_range_check_shadow_reg_errors and ac_range_check_shadow_reg_errors_with_csr_rw.

Command: util/dvsim/dvsim.py hw/top_darjeeling/ip_autogen/ac_range_check/dv/ac_range_check_sim_cfg.hjson -i ac_range_check_shadow_reg_errors ac_range_check_shadow_reg_errors_with_csr_rw

Thank you very much!

martin-velay avatar May 05 '25 13:05 martin-velay

Oops: it looks like I forgot about this PR (sorry). I've just rebased and force-pushed, and will merge if everything looks good in an hour or two.

rswarbrick avatar May 07 '25 09:05 rswarbrick