test: add test for #2014
authorEddie Hung <eddie@fpgeh.com>
Sat, 2 May 2020 21:22:37 +0000 (14:22 -0700)
committerEddie Hung <eddie@fpgeh.com>
Sat, 2 May 2020 21:22:37 +0000 (14:22 -0700)
tests/various/bug2014.ys [new file with mode: 0644]

diff --git a/tests/various/bug2014.ys b/tests/various/bug2014.ys
new file mode 100644 (file)
index 0000000..10131fc
--- /dev/null
@@ -0,0 +1,12 @@
+read_verilog <<EOT
+module test (
+        input signed [1:0] n,
+        output [3:0] dout
+);
+        assign dout = n + 4'sd 4;
+endmodule
+EOT
+
+alumacc
+select -assert-count 1 t:$alu
+equiv_opt -assert opt -fine