H
Henry
Guest
Dear All,
If I want to implent a ROM so that it can synthesized by Synopsys's
design analyzer, what kind of syntax should I used ? Is it the following
statement ok?
always@ (posedge clk or posedge rst or posedge read_data)
begin
if (rst == 1'b1)
begin
data <= 16'd0;
end
else
begin
if (read_data==1'b1)
case (address)
0 : data <= {8'd1, 8'd2 };
1 : data <= {8'd3, 8'd4 };
2 : data <= {8'd5, 8'd6 };
...
...
endcase
end
end
or should I initialize the ROM's content when I declare the ROM's
variable:"data"
which one is better?
Thank you very much.
Henry
If I want to implent a ROM so that it can synthesized by Synopsys's
design analyzer, what kind of syntax should I used ? Is it the following
statement ok?
always@ (posedge clk or posedge rst or posedge read_data)
begin
if (rst == 1'b1)
begin
data <= 16'd0;
end
else
begin
if (read_data==1'b1)
case (address)
0 : data <= {8'd1, 8'd2 };
1 : data <= {8'd3, 8'd4 };
2 : data <= {8'd5, 8'd6 };
...
...
endcase
end
end
or should I initialize the ROM's content when I declare the ROM's
variable:"data"
which one is better?
Thank you very much.
Henry