Guard against integer overflow on the DiplomaticSRAM size.
A "size=(1<<31)" returns a negative integer size (and errors out in FIRRTL), while size=(1<<32) wraps around back to 1 (instead of getting a 4B entry RAM). Since comically large SRAMs aren't desirable anyways (and difficult to simulate), let us place assertion guards on the caller side of the RAM creation.
parent
171366b6
Please register or sign in to comment