aboutsummaryrefslogtreecommitdiffstats
path: root/common/placer1.cc
diff options
context:
space:
mode:
authorDavid Shah <davey1576@gmail.com>2018-09-30 15:13:18 +0100
committerDavid Shah <davey1576@gmail.com>2018-09-30 15:13:18 +0100
commitea03aafc26f8d7c6cde75b9054a508470f91965b (patch)
tree64ce318cb1e06d84a0b68719b8e895cd437639f7 /common/placer1.cc
parent2e7aeaef974c8c104e61de03bc57f0ea764bd9c0 (diff)
downloadnextpnr-ea03aafc26f8d7c6cde75b9054a508470f91965b.tar.gz
nextpnr-ea03aafc26f8d7c6cde75b9054a508470f91965b.tar.bz2
nextpnr-ea03aafc26f8d7c6cde75b9054a508470f91965b.zip
clangformat
Signed-off-by: David Shah <davey1576@gmail.com>
Diffstat (limited to 'common/placer1.cc')
-rw-r--r--common/placer1.cc14
1 files changed, 9 insertions, 5 deletions
diff --git a/common/placer1.cc b/common/placer1.cc
index 363b4d58..01f822a5 100644
--- a/common/placer1.cc
+++ b/common/placer1.cc
@@ -81,7 +81,8 @@ class SAPlacer
}
}
- ~SAPlacer() {
+ ~SAPlacer()
+ {
for (auto &net : ctx->nets)
net.second->udata = old_udata[net.second->udata];
}
@@ -351,7 +352,7 @@ class SAPlacer
// Attempt a SA position swap, return true on success or false on failure
bool try_swap_position(CellInfo *cell, BelId newBel)
{
- static std::vector<NetInfo*> updates;
+ static std::vector<NetInfo *> updates;
updates.clear();
BelId oldBel = cell->bel;
CellInfo *other_cell = ctx->getBoundBelCell(newBel);
@@ -371,7 +372,8 @@ class SAPlacer
for (const auto &port : cell->ports) {
if (port.second.net != nullptr) {
auto &cost = costs[port.second.net->udata];
- if (cost.new_cost == 0) continue;
+ if (cost.new_cost == 0)
+ continue;
cost.new_cost = 0;
updates.emplace_back(port.second.net);
}
@@ -381,7 +383,8 @@ class SAPlacer
for (const auto &port : other_cell->ports)
if (port.second.net != nullptr) {
auto &cost = costs[port.second.net->udata];
- if (cost.new_cost == 0) continue;
+ if (cost.new_cost == 0)
+ continue;
cost.new_cost = 0;
updates.emplace_back(port.second.net);
}
@@ -483,7 +486,8 @@ class SAPlacer
const float post_legalise_dia_scale = 1.5;
Placer1Cfg cfg;
- struct CostChange {
+ struct CostChange
+ {
wirelen_t curr_cost;
wirelen_t new_cost;
};