Skip to content

Commit 68e4d65

Browse files
Merge branch 'openfpga' into patch-1
2 parents 993aca5 + 9eef18c commit 68e4d65

File tree

101 files changed

+5316
-4117
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

101 files changed

+5316
-4117
lines changed

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,4 +153,4 @@ tags
153153
.idea
154154
cmake-build-debug
155155
cmake-build-release
156-
/.metadata/
156+
/.metadata/

doc/src/api/vprinternals/index.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,3 +10,4 @@ VPR INTERNALS
1010
vpr_ui
1111
draw_files
1212
vpr_noc
13+
vpr_router
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
==============
2+
Router Heap
3+
==============
4+
5+
t_heap
6+
----------
7+
.. doxygenstruct:: t_heap
8+
:project: vpr
9+
:members:
10+
11+
HeapInterface
12+
----------
13+
.. doxygenclass:: HeapInterface
14+
:project: vpr
15+
:members:
16+
17+
HeapStorage
18+
----------
19+
.. doxygenclass:: HeapStorage
20+
:project: vpr
21+
:members:
22+
23+
KAryHeap
24+
----------
25+
.. doxygenclass:: KAryHeap
26+
:project: vpr
27+
28+
FourAryHeap
29+
----------
30+
.. doxygenclass:: FourAryHeap
31+
:project: vpr
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
.. _router:
2+
3+
=======
4+
VPR Router
5+
=======
6+
7+
.. toctree::
8+
:maxdepth: 1
9+
10+
router_heap

libs/libarchfpga/src/arch_util.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ const char* get_arch_file_name() {
3535
return arch_file_name;
3636
}
3737

38-
InstPort::InstPort(std::string str) {
38+
InstPort::InstPort(const std::string& str) {
3939
std::vector<std::string> inst_port = vtr::split(str, ".");
4040

4141
if (inst_port.size() == 1) {

libs/libarchfpga/src/arch_util.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ class InstPort {
2222
static constexpr int UNSPECIFIED = -1;
2323

2424
InstPort() = default;
25-
InstPort(std::string str);
25+
InstPort(const std::string& str);
2626
std::string instance_name() const { return instance_.name; }
2727
std::string port_name() const { return port_.name; }
2828

libs/libarchfpga/src/physical_types.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2096,6 +2096,7 @@ struct t_arch {
20962096

20972097
/* Xifan Tang: options for tileable routing architectures */
20982098
bool tileable;
2099+
bool perimeter_cb;
20992100
bool shrink_boundary;
21002101
bool through_channel;
21012102
bool opin2all_sides;

libs/libarchfpga/src/read_xml_arch_file.cpp

Lines changed: 18 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,7 @@ static void ProcessEquivalentSiteCustomConnection(pugi::xml_node Parent,
168168
t_sub_tile* SubTile,
169169
t_physical_tile_type* PhysicalTileType,
170170
t_logical_block_type* LogicalBlockType,
171-
std::string site_name,
171+
const std::string& site_name,
172172
const pugiutil::loc_data& loc_data);
173173
static void ProcessPinLocations(pugi::xml_node Locations,
174174
t_physical_tile_type* PhysicalTileType,
@@ -391,7 +391,7 @@ static bool attribute_to_bool(const pugi::xml_node node,
391391

392392
static int find_switch_by_name(const t_arch& arch, const std::string& switch_name);
393393

394-
e_side string_to_side(const std::string& side_str);
394+
static e_side string_to_side(const std::string& side_str);
395395

396396
template<typename T>
397397
static T* get_type_by_name(const char* type_name, std::vector<T>& types);
@@ -1713,10 +1713,10 @@ static void ProcessPb_TypePort_Power(pugi::xml_node Parent, t_port* port, e_powe
17131713
static void ProcessPb_TypePort(pugi::xml_node Parent, t_port* port, e_power_estimation_method power_method, const bool is_root_pb_type, const pugiutil::loc_data& loc_data) {
17141714
std::vector<std::string> expected_attributes = {"name", "num_pins", "port_class"};
17151715
if (is_root_pb_type) {
1716-
expected_attributes.push_back("equivalent");
1716+
expected_attributes.emplace_back("equivalent");
17171717

17181718
if (Parent.name() == "input"s || Parent.name() == "clock"s) {
1719-
expected_attributes.push_back("is_non_clock_global");
1719+
expected_attributes.emplace_back("is_non_clock_global");
17201720
}
17211721
}
17221722

@@ -2580,6 +2580,7 @@ static void ProcessLayout(pugi::xml_node layout_tag, t_arch* arch, const pugiuti
25802580
//expect_only_attributes(layout_tag, {}, loc_data);
25812581

25822582
arch->tileable = get_attribute(layout_tag, "tileable", loc_data, ReqOpt::OPTIONAL).as_bool(false);
2583+
arch->perimeter_cb = get_attribute(layout_tag, "perimeter_cb", loc_data, ReqOpt::OPTIONAL).as_bool(false);
25832584
arch->shrink_boundary = get_attribute(layout_tag, "shrink_boundary", loc_data, ReqOpt::OPTIONAL).as_bool(false);
25842585
arch->through_channel = get_attribute(layout_tag, "through_channel", loc_data, ReqOpt::OPTIONAL).as_bool(false);
25852586
arch->opin2all_sides = get_attribute(layout_tag, "opin2all_sides", loc_data, ReqOpt::OPTIONAL).as_bool(false);
@@ -2984,7 +2985,7 @@ static void ProcessDevice(pugi::xml_node Node, t_arch* arch, t_default_fc_spec&
29842985
//<connection_block> tag
29852986
Cur = get_single_child(Node, "connection_block", loc_data);
29862987
expect_only_attributes(Cur, {"input_switch_name", "input_inter_die_switch_name"}, loc_data);
2987-
arch->ipin_cblock_switch_name.push_back(get_attribute(Cur, "input_switch_name", loc_data).as_string());
2988+
arch->ipin_cblock_switch_name.emplace_back(get_attribute(Cur, "input_switch_name", loc_data).as_string());
29882989
std::string inter_die_conn = get_attribute(Cur, "input_inter_die_switch_name", loc_data, ReqOpt::OPTIONAL).as_string("");
29892990
if (inter_die_conn != "") {
29902991
arch->ipin_cblock_switch_name.push_back(inter_die_conn);
@@ -3404,7 +3405,7 @@ static void ProcessEquivalentSiteCustomConnection(pugi::xml_node Parent,
34043405
t_sub_tile* SubTile,
34053406
t_physical_tile_type* PhysicalTileType,
34063407
t_logical_block_type* LogicalBlockType,
3407-
std::string site_name,
3408+
const std::string& site_name,
34083409
const pugiutil::loc_data& loc_data) {
34093410
pugi::xml_node CurDirect;
34103411

@@ -3587,7 +3588,7 @@ static void ProcessPinLocations(pugi::xml_node Locations,
35873588
for (int h = 0; h < PhysicalTileType->height; ++h) {
35883589
for (e_side side : {TOP, RIGHT, BOTTOM, LEFT}) {
35893590
for (const auto& token : pin_locs->assignments[sub_tile_index][w][h][l][side]) {
3590-
InstPort inst_port(token.c_str());
3591+
InstPort inst_port(token);
35913592

35923593
//A pin specification should contain only the block name, and not any instance count information
35933594
//A pin specification may contain instance count, but should be in the range of capacity
@@ -3954,8 +3955,8 @@ static void ProcessSegments(pugi::xml_node Parent,
39543955

39553956
if (!Segs[i].longline) {
39563957
//Long line doesn't accpet <sb> or <cb> since it assumes full population
3957-
expected_subtags.push_back("sb");
3958-
expected_subtags.push_back("cb");
3958+
expected_subtags.emplace_back("sb");
3959+
expected_subtags.emplace_back("cb");
39593960
}
39603961

39613962
/* Get the type */
@@ -3964,17 +3965,18 @@ static void ProcessSegments(pugi::xml_node Parent,
39643965
Segs[i].directionality = BI_DIRECTIONAL;
39653966

39663967
//Bidir requires the following tags
3967-
expected_subtags.push_back("wire_switch");
3968-
expected_subtags.push_back("opin_switch");
3968+
expected_subtags.emplace_back("wire_switch");
3969+
expected_subtags.emplace_back("opin_switch");
39693970
}
39703971

39713972
else if (0 == strcmp(tmp, "unidir")) {
39723973
Segs[i].directionality = UNI_DIRECTIONAL;
39733974

39743975
//Unidir requires the following tags
3975-
expected_subtags.push_back("mux");
3976-
expected_subtags.push_back("bend");
3977-
expected_subtags.push_back("mux_inter_die");
3976+
expected_subtags.emplace_back("mux");
3977+
expected_subtags.emplace_back("bend");
3978+
expected_subtags.emplace_back("mux_inter_die");
3979+
39783980
}
39793981

39803982
else {
@@ -4243,8 +4245,6 @@ static void ProcessSwitchblocks(pugi::xml_node Parent, t_arch* arch, const pugiu
42434245

42444246
Node = Node.next_sibling(Node.name());
42454247
}
4246-
4247-
return;
42484248
}
42494249

42504250
static void ProcessCB_SB(pugi::xml_node Node, std::vector<bool>& list, const pugiutil::loc_data& loc_data) {
@@ -5005,7 +5005,7 @@ static int find_switch_by_name(const t_arch& arch, const std::string& switch_nam
50055005
return OPEN;
50065006
}
50075007

5008-
e_side string_to_side(const std::string& side_str) {
5008+
static e_side string_to_side(const std::string& side_str) {
50095009
e_side side = NUM_SIDES;
50105010
if (side_str.empty()) {
50115011
side = NUM_SIDES;
@@ -6017,3 +6017,4 @@ static void ProcessVibBlockTypeLocs(t_vib_grid_def& grid_def,
60176017
}
60186018
}
60196019
}
6020+

libs/libdecrypt/CMakeLists.txt

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,4 +44,6 @@ target_link_libraries(libdecrypt
4444
${OPENSSL_LIBRARIES}
4545
)
4646
install(TARGETS libdecrypt DESTINATION bin)
47-
install(FILES ${LIB_HEADERS} DESTINATION include/libdecrypt)
47+
install(FILES ${LIB_HEADERS} DESTINATION include/libdecrypt)
48+
49+
add_subdirectory(test)

0 commit comments

Comments
 (0)