Skip to content

Commit

Permalink
drt: Fix pin double count and not appearing info.
Browse files Browse the repository at this point in the history
Regression from 58b46bb.
Info message was never shown as pin count was always odd when performing
the modulo.
Also simplify code even more.

Signed-off-by: Christian Costa <[email protected]>
  • Loading branch information
titan73 committed Oct 31, 2024
1 parent 02ce90d commit 267ce64
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions src/drt/src/pa/FlexPA_prep.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1492,7 +1492,6 @@ void FlexPA::initAllAccessPoints()
{
ProfileTask profile("PA:point");
int pin_count = 0;
int pin_count_inform = 1000;

omp_set_num_threads(MAX_THREADS);
ThreadException exception;
Expand All @@ -1515,13 +1514,10 @@ void FlexPA::initAllAccessPoints()

int inst_terms_cnt = static_cast<int>(inst->getInstTerms().size());
#pragma omp critical
for (int i = 0; i < inst_terms_cnt; i++, pin_count++) {
for (int i = 0; i < inst_terms_cnt; i++) {
pin_count++;
if (pin_count % pin_count_inform == 0) {
if (pin_count % (pin_count > 10000 ? 10000 : 1000) == 0) {
logger_->info(DRT, 76, " Complete {} pins.", pin_count);
if (pin_count >= 10000) {
pin_count_inform = 10000;
}
}
}
} catch (...) {
Expand Down

0 comments on commit 267ce64

Please sign in to comment.