mirror of
https://github.com/YosysHQ/yosys
synced 2025-09-02 00:00:44 +00:00
Added tests for attributes
Signed-off-by: Maciej Kurc <mkurc@antmicro.com>
This commit is contained in:
parent
a6cadf6318
commit
5739cf5265
9 changed files with 219 additions and 0 deletions
23
tests/simple/attrib06_operator_suffix.v
Normal file
23
tests/simple/attrib06_operator_suffix.v
Normal file
|
@ -0,0 +1,23 @@
|
|||
module bar(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 reg [7:0] out;
|
||||
|
||||
always @(posedge clk)
|
||||
if (rst) out <= 0;
|
||||
else out <= inp_a + (* ripple_adder *) inp_b;
|
||||
|
||||
endmodule
|
||||
|
||||
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;
|
||||
|
||||
bar bar_instance (clk, rst, inp_a, inp_b, out);
|
||||
endmodule
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue