mirror of https://github.com/YosysHQ/yosys.git
Fixed "test_cell -simlib all"
This commit is contained in:
parent
c7f81e4e49
commit
9923762461
|
@ -108,12 +108,13 @@ parameter Y_WIDTH = 0;
|
||||||
|
|
||||||
input [A_WIDTH-1:0] A;
|
input [A_WIDTH-1:0] A;
|
||||||
output [Y_WIDTH-1:0] Y;
|
output [Y_WIDTH-1:0] Y;
|
||||||
|
wire [Y_WIDTH-1:0] tmp;
|
||||||
|
|
||||||
generate
|
generate
|
||||||
if (A_SIGNED) begin:BLOCK1
|
if (A_SIGNED) begin:BLOCK1
|
||||||
assign Y = -$signed(A);
|
assign tmp = $signed(A), Y = -tmp;
|
||||||
end else begin:BLOCK2
|
end else begin:BLOCK2
|
||||||
assign Y = -A;
|
assign tmp = A, Y = -tmp;
|
||||||
end
|
end
|
||||||
endgenerate
|
endgenerate
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue