diff options
-rw-r--r-- | common/place_common.cc | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/common/place_common.cc b/common/place_common.cc index b2f0e849..370eff23 100644 --- a/common/place_common.cc +++ b/common/place_common.cc @@ -130,10 +130,11 @@ bool place_single_cell(Context *ctx, CellInfo *cell, bool require_legality) if (iters >= 4) wirelen += ctx->rng(25); if (wirelen <= best_ripup_wirelen) { - ripup_target = ctx->cells.at(ctx->getBoundBelCell(bel)).get(); - if (ripup_target->belStrength < STRENGTH_STRONG) { + CellInfo *curr_cell = ctx->cells.at(ctx->getBoundBelCell(bel)).get(); + if (curr_cell->belStrength < STRENGTH_STRONG) { best_ripup_wirelen = wirelen; ripup_bel = bel; + ripup_target = curr_cell; } } } |