diff --git a/ivtest/gold/br_gh1184-vvp-stderr.gold b/ivtest/gold/br_gh1184-vvp-stderr.gold new file mode 100644 index 000000000..d5104df81 --- /dev/null +++ b/ivtest/gold/br_gh1184-vvp-stderr.gold @@ -0,0 +1 @@ +sorry: multi-bit module path delays are currently not fully supported. diff --git a/ivtest/gold/br_gh1184-vvp-stdout.gold b/ivtest/gold/br_gh1184-vvp-stdout.gold new file mode 100644 index 000000000..5e554f522 --- /dev/null +++ b/ivtest/gold/br_gh1184-vvp-stdout.gold @@ -0,0 +1,6 @@ +1 00 xx +3 00 00 +4 11 00 +5 11 11 +7 10 11 +9 10 10 diff --git a/ivtest/ivltests/br_gh1184.v b/ivtest/ivltests/br_gh1184.v new file mode 100644 index 000000000..0311d4737 --- /dev/null +++ b/ivtest/ivltests/br_gh1184.v @@ -0,0 +1,57 @@ +module dut(input wire [1:0] i, output wire [1:0] o); + +assign o = i; + +specify + specparam tRISE = 1; + specparam tFALL = 2; + + (i => o) = (tRISE, tFALL); +endspecify + +endmodule + +module test(); + +reg [1:0] i; +wire [1:0] o; + +dut dut(i, o); + +reg failed = 0; + +initial begin + #1 $monitor("%0t %b %b", $time, i, o); + + i = 2'b00; + #0 if (o !== 2'bxx) failed = 1; + #1; #0 if (o !== 2'bxx) failed = 1; + #1; #0 if (o !== 2'b00) failed = 1; + #1; #0 if (o !== 2'b00) failed = 1; + + i = 2'b11; + #0 if (o !== 2'b00) failed = 1; + #1; #0 if (o !== 2'b11) failed = 1; + #1; #0 if (o !== 2'b11) failed = 1; + #1; #0 if (o !== 2'b11) failed = 1; + + i = 2'b10; + #0 if (o !== 2'b11) failed = 1; + #1; #0 if (o !== 2'b11) failed = 1; + #1; #0 if (o !== 2'b10) failed = 1; + #1; #0 if (o !== 2'b10) failed = 1; + + i = 2'b01; + #0 if (o !== 2'b10) failed = 1; + #1; #0 if (o !== 2'b11) failed = 1; + #1; #0 if (o !== 2'b01) failed = 1; + #1; #0 if (o !== 2'b01) failed = 1; + + #1; + if (failed) + $display("FAILED"); + else + $display("PASSED"); +end + +endmodule diff --git a/ivtest/regress-vvp.list b/ivtest/regress-vvp.list index 9ed7d9930..3dc8167b9 100644 --- a/ivtest/regress-vvp.list +++ b/ivtest/regress-vvp.list @@ -63,6 +63,7 @@ br_gh1163 vvp_tests/br_gh1163.json br_gh1180a vvp_tests/br_gh1180a.json br_gh1180b vvp_tests/br_gh1180b.json br_gh1181 vvp_tests/br_gh1181.json +br_gh1184 vvp_tests/br_gh1184.json ca_time_real` vvp_tests/ca_time_real.json case1 vvp_tests/case1.json case2 vvp_tests/case2.json diff --git a/ivtest/vvp_tests/br_gh1184.json b/ivtest/vvp_tests/br_gh1184.json new file mode 100644 index 000000000..c2c485007 --- /dev/null +++ b/ivtest/vvp_tests/br_gh1184.json @@ -0,0 +1,6 @@ +{ + "type" : "EF", + "source" : "br_gh1184.v", + "gold" : "br_gh1184", + "iverilog-args" : [ "-gspecify" ] +}