Added colbufs test case

This commit is contained in:
Clifford Wolf 2015-08-02 09:10:59 +02:00
parent 510161d651
commit dd00d41fb2
2 changed files with 42 additions and 0 deletions

View File

@ -0,0 +1,8 @@
set_io clk[0] J3
set_io clk[1] G1
set_io clk[2] R9
set_io clk[3] F7
set_io clk[4] K9
set_io clk[5] C8
set_io clk[6] H11
set_io clk[7] H16

34
icefuzz/tests/colbufs.v Normal file
View File

@ -0,0 +1,34 @@
module top #(
parameter NUM_BITS = 8
) (
input [NUM_BITS-1:0] clk,
output reg [NUM_BITS-1:0] y
);
wire [NUM_BITS-1:0] t1;
reg [NUM_BITS-1:0] t2;
genvar i;
generate for (i = 0; i < NUM_BITS; i = i+1) begin:bitslice
SB_RAM40_4K #(
.READ_MODE(0),
.WRITE_MODE(0)
) ram40 (
.WADDR(8'b0),
.RADDR(8'b0),
.MASK(~16'b0),
.WDATA(8'b0),
.RDATA(t1[i]),
.WE(1'b1),
.WCLKE(1'b1),
.WCLK(clk[i]),
.RE(1'b1),
.RCLKE(1'b1),
.RCLK(clk[i])
);
always @(posedge clk[i]) begin
t2[i] <= t1[i];
y[i] <= t2[i];
end
end endgenerate
endmodule