From 93fe10ceb1defc0d6da89febfe32ac2bec64b721 Mon Sep 17 00:00:00 2001 From: gatecat Date: Thu, 19 Mar 2026 14:59:46 +0100 Subject: [PATCH] heap: fix calculation of legalisation runtime Signed-off-by: gatecat --- common/place/placer_heap.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/common/place/placer_heap.cc b/common/place/placer_heap.cc index b4870ad3..cdd924da 100644 --- a/common/place/placer_heap.cc +++ b/common/place/placer_heap.cc @@ -911,8 +911,6 @@ class HeAPPlacer (ci->cluster != ClusterId() && ctx->getClusterRootCell(ci->cluster)->udata != dont_solve))) ctx->unbindBel(ci->bel); } - auto endt = std::chrono::high_resolution_clock::now(); - p->sl_time += std::chrono::duration(endt - startt).count(); // At the moment we don't follow the full HeAP algorithm using cuts for legalisation, instead using // the simple greedy largest-macro-first approach. @@ -947,6 +945,8 @@ class HeAPPlacer p->time_per_cell_type[ci->type] += std::chrono::duration(ci_endt - ci_startt).count(); } } + auto endt = std::chrono::high_resolution_clock::now(); + p->sl_time += std::chrono::duration(endt - startt).count(); } void legalise_cell(CellInfo *ci) {