mirror of
https://github.com/YosysHQ/yosys
synced 2025-11-01 20:17:55 +00:00
Add test
This commit is contained in:
parent
fb8fab4a29
commit
a701a2accf
2 changed files with 22 additions and 1 deletions
17
tests/memories/issue00710.v
Normal file
17
tests/memories/issue00710.v
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
// expect-wr-ports 1
|
||||
// expect-rd-ports 1
|
||||
// expect-rd-clk \clk
|
||||
|
||||
module top(input clk, input we, re, reset, input [7:0] addr, wdata, output reg [7:0] rdata);
|
||||
|
||||
reg [7:0] bram[0:255];
|
||||
(* keep *) reg dummy;
|
||||
|
||||
always @(posedge clk)
|
||||
if (reset)
|
||||
dummy <= 1'b0;
|
||||
else if (re)
|
||||
rdata <= bram[addr];
|
||||
else if (we)
|
||||
bram[addr] <= wdata;
|
||||
endmodule
|
||||
Loading…
Add table
Add a link
Reference in a new issue