diff options
author | Maciej Kurc <mkurc@antmicro.com> | 2019-06-04 10:42:42 +0200 |
---|---|---|
committer | Maciej Kurc <mkurc@antmicro.com> | 2019-06-04 10:42:42 +0200 |
commit | b79bd5b3ca086718e308c75cbece0b07bbe48733 (patch) | |
tree | cf5ea057804392bef613a5c86046ce2b35700c28 /tests/various/attrib07_func_call.v | |
parent | 5739cf52650ccb3627868d9c9d7e02888efad12b (diff) | |
download | yosys-b79bd5b3ca086718e308c75cbece0b07bbe48733.tar.gz yosys-b79bd5b3ca086718e308c75cbece0b07bbe48733.tar.bz2 yosys-b79bd5b3ca086718e308c75cbece0b07bbe48733.zip |
Moved tests that fail with Icarus Verilog to /tests/various. Those tests are just for parsing Verilog.
Signed-off-by: Maciej Kurc <mkurc@antmicro.com>
Diffstat (limited to 'tests/various/attrib07_func_call.v')
-rw-r--r-- | tests/various/attrib07_func_call.v | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/tests/various/attrib07_func_call.v b/tests/various/attrib07_func_call.v new file mode 100644 index 000000000..f55ef2316 --- /dev/null +++ b/tests/various/attrib07_func_call.v @@ -0,0 +1,21 @@ +function [7:0] do_add; + input [7:0] inp_a; + input [7:0] inp_b; + + do_add = inp_a + inp_b; + +endfunction + +module foo(clk, rst, inp_a, inp_b, out); + input wire clk; + input wire rst; + input wire [7:0] inp_a; + input wire [7:0] inp_b; + output wire [7:0] out; + + always @(posedge clk) + if (rst) out <= 0; + else out <= do_add (* combinational_adder *) (inp_a, inp_b); + +endmodule + |