Skip to content

Commit

Permalink
mpl2: throw critical for when things happen
Browse files Browse the repository at this point in the history
Signed-off-by: Arthur Koucher <[email protected]>
  • Loading branch information
AcKoucher committed Aug 6, 2024
1 parent 281e5b3 commit 576ef6b
Showing 1 changed file with 31 additions and 13 deletions.
44 changes: 31 additions & 13 deletions src/mpl2/src/clusterEngine.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1545,11 +1545,16 @@ void ClusteringEngine::mergeChildrenBelowThresholds(

if (small_children[i]->isSameConnSignature(
*small_children[j], tree_->min_net_count_for_connection)) {
/*
Guaranteed merge.
*/
if (attemptMerge(small_children[i], small_children[j])) {
cluster_class[j] = i;
} else {
logger_->critical(
MPL,
23,
"Merge attempt between siblings {} and {} with same "
"connection signature failed!",
small_children[i]->getName(),
small_children[j]->getName());
}
}
}
Expand All @@ -1568,11 +1573,16 @@ void ClusteringEngine::mergeChildrenBelowThresholds(
|| small_children[j]->getNumStdCell() > dust_cluster_std_cell) {
continue;
}
/*
Guaranteed merge.
*/

if (attemptMerge(small_children[i], small_children[j])) {
cluster_class[j] = i;
} else {
logger_->critical(
MPL,
24,
"Merge attempt between dust siblings {} and {} failed!",
small_children[i]->getName(),
small_children[j]->getName());
}
}
}
Expand Down Expand Up @@ -1996,12 +2006,15 @@ void ClusteringEngine::groupSingleMacroClusters(
"Merging interconnected macro clusters {} and {}",
macro_clusters[j]->getId(),
macro_clusters[i]->getId());

/*
Guaranteed merge.
*/
if (attemptMerge(macro_clusters[i], macro_clusters[j])) {
macro_class[j] = i;
} else {
logger_->critical(MPL,
28,
"Merge attempt between interconnected macro "
"siblings {} and {} failed!",
macro_clusters[i]->getName(),
macro_clusters[j]->getName());
}
} else {
// We need this so we can distinguish arrays of interconnected macros
Expand All @@ -2015,11 +2028,16 @@ void ClusteringEngine::groupSingleMacroClusters(
"Merging same signature clusters {} and {}.",
macro_clusters[j]->getId(),
macro_clusters[i]->getId());
/*
Guaranteed merge.
*/
if (attemptMerge(macro_clusters[i], macro_clusters[j])) {
macro_class[j] = i;
} else {
logger_->critical(
MPL,
29,
"Merge attempt between macro siblings {} and {} with "
"same connection signature failed!",
macro_clusters[i]->getName(),
macro_clusters[j]->getName());
}
}
}
Expand Down

0 comments on commit 576ef6b

Please sign in to comment.