diff options
author | David Shah <dave@ds0.me> | 2019-08-30 13:57:15 +0100 |
---|---|---|
committer | David Shah <dave@ds0.me> | 2019-08-30 13:57:15 +0100 |
commit | 6919c0f9b010c94a0a1a31cd788301e78a1bcbfb (patch) | |
tree | 4780799b6c1dc1d150b80aa142e6c53e06760cb3 /techlibs/ice40/cells_map.v | |
parent | edff79a25a802e5b1816608b48e3ac335ad87147 (diff) | |
parent | 694e30a35426b9582a1f2db730528d4d34305795 (diff) | |
download | yosys-6919c0f9b010c94a0a1a31cd788301e78a1bcbfb.tar.gz yosys-6919c0f9b010c94a0a1a31cd788301e78a1bcbfb.tar.bz2 yosys-6919c0f9b010c94a0a1a31cd788301e78a1bcbfb.zip |
Merge branch 'master' into xc7dsp
Diffstat (limited to 'techlibs/ice40/cells_map.v')
-rw-r--r-- | techlibs/ice40/cells_map.v | 23 |
1 files changed, 9 insertions, 14 deletions
diff --git a/techlibs/ice40/cells_map.v b/techlibs/ice40/cells_map.v index b4b831165..662423f0a 100644 --- a/techlibs/ice40/cells_map.v +++ b/techlibs/ice40/cells_map.v @@ -62,26 +62,21 @@ module \$lut (A, Y); endmodule `endif -`ifdef _ABC -module \$__ICE40_FULL_ADDER (output CO, O, input A, B, CI); +`ifndef NO_ADDER +module \$__ICE40_CARRY_WRAPPER (output CO, O, input A, B, CI, I0, I3); + parameter LUT = 0; SB_CARRY carry ( .I0(A), .I1(B), .CI(CI), .CO(CO) ); - SB_LUT4 #( - // I0: 1010 1010 1010 1010 - // I1: 1100 1100 1100 1100 - // I2: 1111 0000 1111 0000 - // I3: 1111 1111 0000 0000 - .LUT_INIT(16'b 0110_1001_1001_0110) - ) adder ( - .I0(1'b0), - .I1(A), - .I2(B), - .I3(CI), - .O(O) + \$lut #( + .WIDTH(4), + .LUT(LUT) + ) lut ( + .A({I0,A,B,I3}), + .Y(O) ); endmodule `endif |