Merge pull request #1351 from coreyqh/ccov
Some checks failed
Lint / Lint (Python 312) (push) Has been cancelled
Lint / Lint (Python 39) (push) Has been cancelled

Full csru code coverage
This commit is contained in:
David Harris 2025-04-09 11:05:35 -07:00 committed by GitHub
commit 2ad4f20900
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 8 additions and 0 deletions

View file

@ -51,6 +51,8 @@ module csru import cvw::*; #(parameter cvw_t P) (
logic WriteFFLAGSM;
// Write enables
// Explicitly checking STATUS_FS != 0 is redundant since the instruction traps otherwise,
// causing CSRWriteM to go low, but it is left here for safety
assign WriteFRMM = CSRUWriteM & (STATUS_FS != 2'b00) & (CSRAdrM == FRM | CSRAdrM == FCSR);
assign WriteFFLAGSM = CSRUWriteM & (STATUS_FS != 2'b00) & (CSRAdrM == FFLAGS | CSRAdrM == FCSR);