mirror of
https://github.com/YosysHQ/yosys
synced 2025-08-02 17:30:24 +00:00
Added $meminit support to "memory" command
This commit is contained in:
parent
913c304fe6
commit
dcf2e24240
7 changed files with 99 additions and 49 deletions
|
@ -5,6 +5,7 @@ module \$mem (RD_CLK, RD_ADDR, RD_DATA, WR_CLK, WR_EN, WR_ADDR, WR_DATA);
|
|||
parameter OFFSET = 0;
|
||||
parameter ABITS = 8;
|
||||
parameter WIDTH = 8;
|
||||
parameter signed INIT = 1'bx;
|
||||
|
||||
parameter RD_PORTS = 1;
|
||||
parameter RD_CLK_ENABLE = 1'b1;
|
||||
|
@ -37,6 +38,10 @@ module \$mem (RD_CLK, RD_ADDR, RD_DATA, WR_CLK, WR_EN, WR_ADDR, WR_DATA);
|
|||
initial begin
|
||||
_TECHMAP_FAIL_ <= 0;
|
||||
|
||||
// no initialized memories
|
||||
if (INIT !== 1'bx)
|
||||
_TECHMAP_FAIL_ <= 1;
|
||||
|
||||
// only map cells with only one read and one write port
|
||||
if (RD_PORTS > 1 || WR_PORTS > 1)
|
||||
_TECHMAP_FAIL_ <= 1;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue