mirror of
https://github.com/YosysHQ/yosys
synced 2025-04-23 00:55:32 +00:00
Add splitcmplxassign test case and silence splitcmplxassign warning
Signed-off-by: Clifford Wolf <clifford@clifford.at>
This commit is contained in:
parent
3b6a02d3a7
commit
6bbe2fdbf3
2 changed files with 23 additions and 0 deletions
|
@ -92,3 +92,25 @@ module mem2reg_test5(input ctrl, output out);
|
|||
assign out = bar[foo[0]];
|
||||
endmodule
|
||||
|
||||
// ------------------------------------------------------
|
||||
|
||||
module mem2reg_test6 (din, dout);
|
||||
input wire [3:0] din;
|
||||
output reg [3:0] dout;
|
||||
|
||||
reg [1:0] din_array [1:0];
|
||||
reg [1:0] dout_array [1:0];
|
||||
|
||||
always @* begin
|
||||
din_array[0] = din[0 +: 2];
|
||||
din_array[1] = din[2 +: 2];
|
||||
|
||||
dout_array[0] = din_array[0];
|
||||
dout_array[1] = din_array[1];
|
||||
|
||||
{dout_array[0][1], dout_array[0][0]} = dout_array[0][0] + dout_array[1][0];
|
||||
|
||||
dout[0 +: 2] = dout_array[0];
|
||||
dout[2 +: 2] = dout_array[1];
|
||||
end
|
||||
endmodule
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue