Skip to content

Commit

Permalink
mem_to_banks_detailed: Check power of 2 in a more sensible way
Browse files Browse the repository at this point in the history
  • Loading branch information
michael-platzer committed Sep 30, 2024
1 parent 647ec7d commit ed55c2a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/mem_to_banks_detailed.sv
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,7 @@ module mem_to_banks_detailed #(
// Assertions
`ifndef COMMON_CELLS_ASSERTS_OFF
initial begin
`ASSUME_I(datawidth_not_power_of_2, DataWidth != 0 && (DataWidth & (DataWidth - 1)) == 0,
`ASSUME_I(datawidth_not_power_of_2, DataWidth != 0 && 2**$clog2(DataWidth) == DataWidth,
"Data width must be a power of two!")
`ASSUME_I(datawidth_not_divisible_by_banks, DataWidth % NumBanks == 0,
"Data width must be evenly divisible over banks!")
Expand Down

0 comments on commit ed55c2a

Please sign in to comment.