From cf1ae6d8301a00307920742b25d61d08abd3d1da Mon Sep 17 00:00:00 2001 From: Hannes Haberl Date: Tue, 25 Apr 2023 19:09:23 +0200 Subject: [PATCH 1/2] XDC: Add missing OBUFT primitive --- xdc-plugin/xdc.cc | 1 + 1 file changed, 1 insertion(+) diff --git a/xdc-plugin/xdc.cc b/xdc-plugin/xdc.cc index 9a6602956..3b06ec8eb 100644 --- a/xdc-plugin/xdc.cc +++ b/xdc-plugin/xdc.cc @@ -56,6 +56,7 @@ const std::unordered_map set_property_options_m // corresponding PADs const std::unordered_map> supported_primitive_parameters = { {"OBUF", {"IO_LOC_PAIRS", "IOSTANDARD", "DRIVE", "SLEW", "IN_TERM"}}, + {"OBUFT", {"IO_LOC_PAIRS", "IOSTANDARD", "DRIVE", "SLEW", "IN_TERM"}}, {"OBUFDS", {"IO_LOC_PAIRS", "IOSTANDARD", "SLEW", "IN_TERM"}}, {"OBUFTDS", {"IO_LOC_PAIRS", "IOSTANDARD", "SLEW", "IN_TERM"}}, {"IBUF", {"IO_LOC_PAIRS", "IOSTANDARD"}}, From 1951b86c1156f96be950ce0a8b20e39377b8770f Mon Sep 17 00:00:00 2001 From: Hannes Haberl Date: Fri, 28 Apr 2023 17:52:37 +0200 Subject: [PATCH 2/2] XDC: Add OBUFT to io_loc_pairs testcase --- .../io_loc_pairs/io_loc_pairs.golden.json | 11 +++++++- xdc-plugin/tests/io_loc_pairs/io_loc_pairs.v | 26 ++++++++++++++++--- .../tests/io_loc_pairs/io_loc_pairs.xdc | 9 +++++++ 3 files changed, 42 insertions(+), 4 deletions(-) diff --git a/xdc-plugin/tests/io_loc_pairs/io_loc_pairs.golden.json b/xdc-plugin/tests/io_loc_pairs/io_loc_pairs.golden.json index 10d3909c7..733220e6e 100644 --- a/xdc-plugin/tests/io_loc_pairs/io_loc_pairs.golden.json +++ b/xdc-plugin/tests/io_loc_pairs/io_loc_pairs.golden.json @@ -10,6 +10,11 @@ "IO_LOC_PAIRS": "signal_p:N2,signal_n:N1", "SLEW": "FAST" }, + "OBUFT_1": { + "IOSTANDARD": "LVCMOS25", + "IO_LOC_PAIRS": "tri_top:U16", + "SLEW": "FAST" + }, "OBUF_6": { "DRIVE": "12", "IOSTANDARD": "LVCMOS33", @@ -28,6 +33,10 @@ "IO_LOC_PAIRS": "out_a:E3", "SLEW": "FAST" }, + "bottom_inst.OBUFT_2": { + "IOSTANDARD": "LVCMOS33", + "IO_LOC_PAIRS": "tri_bottom:E19" + }, "bottom_inst.OBUF_10": { "IOSTANDARD": "LVCMOS18", "IO_LOC_PAIRS": "out_b[0]:C2", @@ -50,4 +59,4 @@ "IO_LOC_PAIRS": "led[3]:N4", "SLEW": "SLOW" } -} +} \ No newline at end of file diff --git a/xdc-plugin/tests/io_loc_pairs/io_loc_pairs.v b/xdc-plugin/tests/io_loc_pairs/io_loc_pairs.v index bb08dee5f..0f1873f84 100644 --- a/xdc-plugin/tests/io_loc_pairs/io_loc_pairs.v +++ b/xdc-plugin/tests/io_loc_pairs/io_loc_pairs.v @@ -26,7 +26,9 @@ module top ( output tx_n, output tx_p, input ibufds_gte2_i, - input ibufds_gte2_ib + input ibufds_gte2_ib, + output tri_top, + output tri_bottom ); wire LD6, LD7, LD8, LD9; @@ -77,7 +79,10 @@ module top ( bottom bottom_inst ( .I (LD8), .O (led[2]), - .OB(out_b) + .OB(out_b), + .in_tri(LD7), + .t_tri(LD8), + .out_tri(tri_bottom) ); bottom_intermediate bottom_intermediate_inst ( @@ -97,6 +102,12 @@ module top ( .I (ibufds_gte2_i), .IB(ibufds_gte2_ib) ); + + OBUFT OBUFT_1 ( + .I(LD6), + .T(LD7), + .O(tri_top) + ); endmodule module bottom_intermediate ( @@ -119,7 +130,10 @@ endmodule module bottom ( input I, output [1:0] OB, - output O + output O, + input in_tri, + input t_tri, + output out_tri ); OBUF #( @@ -145,4 +159,10 @@ module bottom ( .I(I), .O(OB[1]) ); + + OBUFT OBUFT_2 ( + .I(in_tri), + .T(t_tri), + .O(out_tri) + ); endmodule diff --git a/xdc-plugin/tests/io_loc_pairs/io_loc_pairs.xdc b/xdc-plugin/tests/io_loc_pairs/io_loc_pairs.xdc index 9263df9cf..9d0513ca3 100644 --- a/xdc-plugin/tests/io_loc_pairs/io_loc_pairs.xdc +++ b/xdc-plugin/tests/io_loc_pairs/io_loc_pairs.xdc @@ -50,3 +50,12 @@ set_property LOC G4 [get_ports {tx_n}] # IBUFDS_GTE2 set_property LOC G5 [get_ports {ibufds_gte2_i}] set_property LOC G6 [get_ports {ibufds_gte2_ib}] + +# OBUFT_1 +set_property SLEW FAST [get_ports tri_top] +set_property LOC U16 [get_ports tri_top] +set_property IOSTANDARD LVCMOS25 [get_ports tri_top] + +# OBUFT_2 +set_property LOC E19 [get_ports tri_bottom] +set_property IOSTANDARD LVCMOS33 [get_ports tri_bottom]