Skip to content

Commit

Permalink
Add assertion on the number of words in a cacheline
Browse files Browse the repository at this point in the history
  • Loading branch information
cfuguet committed Dec 10, 2024
1 parent 7ecdd92 commit c28b117
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions rtl/src/hpdcache.sv
Original file line number Diff line number Diff line change
Expand Up @@ -1225,6 +1225,9 @@ import hpdcache_pkg::*;
refill_access_width_assert:
assert (HPDcacheCfg.u.clWords >= HPDcacheCfg.u.accessWords) else
$fatal("cache access width shall be l.e. to cache-line width");
cl_words_assert:
assert (HPDcacheCfg.u.clWords > 1) else
$fatal("cacheline words shall be greater than 1");
mem_width_assert:
assert (HPDcacheCfg.u.memDataWidth >= HPDcacheCfg.reqDataWidth) else
$fatal("memory interface data width shall be g.e. to req data width");
Expand Down

0 comments on commit c28b117

Please sign in to comment.