diff options
Diffstat (limited to 'common/placer1.cc')
-rw-r--r-- | common/placer1.cc | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/common/placer1.cc b/common/placer1.cc index ee7225b5..68db9650 100644 --- a/common/placer1.cc +++ b/common/placer1.cc @@ -138,6 +138,7 @@ class SAPlacer if ((placed_cells - constr_placed_cells) % 500 != 0) log_info(" initial placement placed %d/%d cells\n", int(placed_cells - constr_placed_cells), int(autoplaced.size())); + assign_budget(ctx); ctx->yield(); log_info("Running simulated annealing placer.\n"); @@ -152,6 +153,7 @@ class SAPlacer } int n_no_progress = 0; + wirelen_t min_metric = curr_metric; double avg_metric = curr_metric; temp = 10000; @@ -177,6 +179,11 @@ class SAPlacer } } + if (curr_metric < min_metric) { + min_metric = curr_metric; + improved = true; + } + // Heuristic to improve placement on the 8k if (improved) n_no_progress = 0; @@ -230,6 +237,8 @@ class SAPlacer diameter *= post_legalise_dia_scale; ctx->shuffle(autoplaced); assign_budget(ctx); + } else if (ctx->slack_redist_iter > 0 && iter % ctx->slack_redist_iter == 0) { + assign_budget(ctx, true /* quiet */); } // Recalculate total metric entirely to avoid rounding errors @@ -264,6 +273,7 @@ class SAPlacer } } } + timing_analysis(ctx, true /* print_fmax */); ctx->unlock(); return true; } @@ -379,8 +389,6 @@ class SAPlacer // SA acceptance criterea if (delta < 0 || (temp > 1e-6 && (ctx->rng() / float(0x3fffffff)) <= std::exp(-delta / temp))) { n_accept++; - if (delta < 2) - improved = true; } else { if (other != IdString()) ctx->unbindBel(oldBel); |