IObundle / iob-cache

Verilog Configurable Cache
MIT License
167 stars 32 forks source link

Cant configure WORD_OFFSET_W to be 0 #302

Open epkRichi opened 5 months ago

epkRichi commented 5 months ago

Setting WORD_OFFSET_W to 0 in iob_cache.py should configure the cache to store 1 word per line, but this creates an error during the build process:

../src/iob_cache_memory.v:83: error: Indexed part widths must be constant and greater than zero.
../src/iob_cache_memory.v:83:      : This part width expression violates the rule: WORD_OFFSET_W
1 error(s) during elaboration.

I could not find any documentation stating that a word offset of 0 is not supported and iob_cache.py states that it should be possible:

{
    "name": "WORD_OFFSET_W",
    "type": "P",
    "val": "3",
    "min": "0",
    "max": "",
    "descr": "Word offset width (log2):  the value of this parameter equals the number of words per line, which is 2**OFFSET_W. ",
},

Is this a bug or is a word offset of 0 just not supported?

jjts commented 5 months ago

Currently not supported. The minimum was changed to one.