Files
yosys/docs/source/code_examples/extensions/absval_ref.v
T

4 lines
94 B
Verilog
Raw Normal View History

2014-06-22 12:50:29 +02:00
module absval_ref(input signed [3:0] a, output [3:0] y);
2023-12-13 11:34:42 +13:00
assign y = a[3] ? -a : a;
2014-06-22 12:50:29 +02:00
endmodule