summaryrefslogtreecommitdiff
path: root/techlibs/xilinx/lut2lut.v
diff options
context:
space:
mode:
authorRuben Undheim <ruben.undheim@gmail.com>2018-08-30 20:46:20 +0200
committerRuben Undheim <ruben.undheim@gmail.com>2018-08-30 20:46:20 +0200
commit5033b51947a6ef02cb785b5622e993335efa750a (patch)
tree7bed18c526bd94917fa2f08e3df12209863698a1 /techlibs/xilinx/lut2lut.v
parentfefe0fc0430f4f173a25e674708aa0f4f0854b31 (diff)
New upstream version 0.7+20180830git0b7a184
Diffstat (limited to 'techlibs/xilinx/lut2lut.v')
-rw-r--r--techlibs/xilinx/lut2lut.v65
1 files changed, 65 insertions, 0 deletions
diff --git a/techlibs/xilinx/lut2lut.v b/techlibs/xilinx/lut2lut.v
new file mode 100644
index 00000000..061ad204
--- /dev/null
+++ b/techlibs/xilinx/lut2lut.v
@@ -0,0 +1,65 @@
+module LUT1(output O, input I0);
+ parameter [1:0] INIT = 0;
+ \$lut #(
+ .WIDTH(1),
+ .LUT(INIT)
+ ) _TECHMAP_REPLACE_ (
+ .A(I0),
+ .Y(O)
+ );
+endmodule
+
+module LUT2(output O, input I0, I1);
+ parameter [3:0] INIT = 0;
+ \$lut #(
+ .WIDTH(2),
+ .LUT(INIT)
+ ) _TECHMAP_REPLACE_ (
+ .A({I1, I0}),
+ .Y(O)
+ );
+endmodule
+
+module LUT3(output O, input I0, I1, I2);
+ parameter [7:0] INIT = 0;
+ \$lut #(
+ .WIDTH(3),
+ .LUT(INIT)
+ ) _TECHMAP_REPLACE_ (
+ .A({I2, I1, I0}),
+ .Y(O)
+ );
+endmodule
+
+module LUT4(output O, input I0, I1, I2, I3);
+ parameter [15:0] INIT = 0;
+ \$lut #(
+ .WIDTH(4),
+ .LUT(INIT)
+ ) _TECHMAP_REPLACE_ (
+ .A({I3, I2, I1, I0}),
+ .Y(O)
+ );
+endmodule
+
+module LUT5(output O, input I0, I1, I2, I3, I4);
+ parameter [31:0] INIT = 0;
+ \$lut #(
+ .WIDTH(5),
+ .LUT(INIT)
+ ) _TECHMAP_REPLACE_ (
+ .A({I4, I3, I2, I1, I0}),
+ .Y(O)
+ );
+endmodule
+
+module LUT6(output O, input I0, I1, I2, I3, I4, I5);
+ parameter [63:0] INIT = 0;
+ \$lut #(
+ .WIDTH(6),
+ .LUT(INIT)
+ ) _TECHMAP_REPLACE_ (
+ .A({I5, I4, I3, I2, I1, I0}),
+ .Y(O)
+ );
+endmodule