Add additional regression tests for issue #1099.

This commit is contained in:
Martin Whitaker 2024-02-25 21:54:20 +00:00
parent fc29e51e41
commit 52d049b513
8 changed files with 63 additions and 5 deletions

View File

@ -0,0 +1,24 @@
module top;
reg [3:0] inp1;
reg signed [3:0] inp2;
wire [4:0] out1, out2;
initial begin
$monitor("%b %b %b %b", inp1, inp2, out1, out2);
#1 inp1 = 4'b1111;
#1 inp2 = 4'b1111;
#1;
if ((out1 === 5'b01111) && (out2 === 5'b01111))
$display("PASSED");
else
$display("FAILED");
end
mod m1(inp1[3:0], out1);
mod m2(inp2[3:0], out2);
endmodule
module mod(
input [4:0] inp,
output [4:0] out
);
assign out = inp;
endmodule

View File

@ -0,0 +1,24 @@
module top;
reg [3:0] inp1;
reg signed [3:0] inp2;
wire [4:0] out1, out2;
initial begin
$monitor("%b %b %b %b", inp1, inp2, out1, out2);
#1 inp1 = 4'b1111;
#1 inp2 = 4'b1111;
#1;
if ((out1 === 5'b01111) && (out2 === 5'b01111))
$display("PASSED");
else
$display("FAILED");
end
mod m1($unsigned(inp1), out1);
mod m2($unsigned(inp2), out2);
endmodule
module mod(
input [4:0] inp,
output [4:0] out
);
assign out = inp;
endmodule

View File

@ -42,7 +42,9 @@ br_gh1087a2 vvp_tests/br_gh1087a2.json
br_gh1087a3 vvp_tests/br_gh1087a3.json
br_gh1087b vvp_tests/br_gh1087b.json
br_gh1087c vvp_tests/br_gh1087c.json
br_gh1099 vvp_tests/br_gh1099.json
br_gh1099a vvp_tests/br_gh1099a.json
br_gh1099b vvp_tests/br_gh1099b.json
br_gh1099c vvp_tests/br_gh1099c.json
br_gh1104 vvp_tests/br_gh1104.json
ca_time_real` vvp_tests/ca_time_real.json
case1 vvp_tests/case1.json

View File

@ -1,4 +0,0 @@
{
"type" : "normal",
"source" : "br_gh1099.v"
}

View File

@ -0,0 +1,4 @@
{
"type" : "normal",
"source" : "br_gh1099a.v"
}

View File

@ -0,0 +1,4 @@
{
"type" : "normal",
"source" : "br_gh1099b.v"
}

View File

@ -0,0 +1,4 @@
{
"type" : "normal",
"source" : "br_gh1099c.v"
}