aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Shah <davey1576@gmail.com>2018-06-28 15:48:57 +0200
committerDavid Shah <davey1576@gmail.com>2018-06-28 15:48:57 +0200
commit27a9850921c73f7d6605fd70b868ee8f1769fd13 (patch)
tree1da57ac2546be01da7d67e1091f2326e280d03d8
parentc0724a7e97f024a1d113038272fa3233366a36fb (diff)
downloadnextpnr-27a9850921c73f7d6605fd70b868ee8f1769fd13.tar.gz
nextpnr-27a9850921c73f7d6605fd70b868ee8f1769fd13.tar.bz2
nextpnr-27a9850921c73f7d6605fd70b868ee8f1769fd13.zip
Debugging carry legalisation
Signed-off-by: David Shah <davey1576@gmail.com>
-rw-r--r--ice40/place_legaliser.cc15
1 files changed, 10 insertions, 5 deletions
diff --git a/ice40/place_legaliser.cc b/ice40/place_legaliser.cc
index aeef47a1..1292d094 100644
--- a/ice40/place_legaliser.cc
+++ b/ice40/place_legaliser.cc
@@ -128,15 +128,20 @@ class PlacementLegaliser
bool legalise_carries()
{
std::vector<CellChain> carry_chains = find_chains(
- ctx, is_lc,
+ ctx,
[](const Context *ctx, const CellInfo *cell) {
+ return is_lc(ctx, cell);
+ },
+ [](const Context *ctx, const
+
+ CellInfo *cell) {
CellInfo *carry_prev =
net_driven_by(ctx, cell->ports.at(ctx->id("CIN")).net, is_lc, ctx->id("COUT"));
if (carry_prev != nullptr)
return carry_prev;
- CellInfo *i3_prev = net_driven_by(ctx, cell->ports.at(ctx->id("I3")).net, is_lc, ctx->id("COUT"));
+ /*CellInfo *i3_prev = net_driven_by(ctx, cell->ports.at(ctx->id("I3")).net, is_lc, ctx->id("COUT"));
if (i3_prev != nullptr)
- return i3_prev;
+ return i3_prev;*/
return (CellInfo *)nullptr;
},
[](const Context *ctx, const CellInfo *cell) {
@@ -144,10 +149,10 @@ class PlacementLegaliser
net_only_drives(ctx, cell->ports.at(ctx->id("COUT")).net, is_lc, ctx->id("CIN"), false);
if (carry_next != nullptr)
return carry_next;
- CellInfo *i3_next =
+ /*CellInfo *i3_next =
net_only_drives(ctx, cell->ports.at(ctx->id("COUT")).net, is_lc, ctx->id("I3"), false);
if (i3_next != nullptr)
- return i3_next;
+ return i3_next;*/
return (CellInfo *)nullptr;
});
bool success = true;