Skip to content

Commit 1db6573

Browse files
Fixed PR review comments
Signed-off-by: Ravi Varadarajan <[email protected]>
1 parent 5c3fe69 commit 1db6573

File tree

1 file changed

+9
-26
lines changed

1 file changed

+9
-26
lines changed

src/mpl2/src/hier_rtlmp.cpp

Lines changed: 9 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -148,9 +148,6 @@ void HierRTLMP::setClusterSize(int max_num_macro,
148148
min_num_macro_base_ = min_num_macro;
149149
max_num_inst_base_ = max_num_inst;
150150
min_num_inst_base_ = min_num_inst;
151-
logger_->report("min_num_inst_base = {}, max = {}",
152-
min_num_inst_base_,
153-
max_num_inst_base_);
154151
}
155152

156153
void HierRTLMP::setClusterSizeTolerance(float tolerance)
@@ -366,8 +363,6 @@ void HierRTLMP::hierRTLMacroPlacer()
366363
"Print Physical Hierarchy Tree after breaking mixed clusters **");
367364
printPhysicalHierarchyTree(root_cluster_, 0);
368365

369-
// logger_->error(MPL, 9991, "Force exit");
370-
371366
// Map the macros in each cluster to their HardMacro objects
372367
for (auto& [cluster_id, cluster] : cluster_map_) {
373368
mapMacroInCluster2HardMacro(cluster);
@@ -751,7 +746,7 @@ void HierRTLMP::multiLevelCluster(Cluster* parent)
751746
if (level_ == 0) {
752747
// check if root cluster is below the max size of a leaf cluster
753748
// Force create child clusters in this case
754-
int leaf_cluster_size
749+
const int leaf_cluster_size
755750
= max_num_inst_base_ / std::pow(coarsening_ratio_, max_num_level_ - 1);
756751
if (parent->getNumStdCell() < leaf_cluster_size)
757752
force_split = true;
@@ -765,15 +760,13 @@ void HierRTLMP::multiLevelCluster(Cluster* parent)
765760
}
766761
level_++;
767762

768-
if (1) {
769-
logger_->report(
770-
"[Debug][HierRTLMP::MultiLevelCluster] {} {}: num_macro {} "
771-
"num_stdcell {}",
772-
parent->getName(),
773-
level_,
774-
parent->getNumMacro(),
775-
parent->getNumStdCell());
776-
}
763+
logger_->report(
764+
"[Debug][HierRTLMP::MultiLevelCluster] {} {}: num_macro {} num_stdcell "
765+
"{}",
766+
parent->getName(),
767+
level_,
768+
parent->getNumMacro(),
769+
parent->getNumStdCell());
777770

778771
// a large coarsening_ratio_ helps the clustering process converge fast
779772
max_num_macro_
@@ -782,22 +775,12 @@ void HierRTLMP::multiLevelCluster(Cluster* parent)
782775
= min_num_macro_base_ / std::pow(coarsening_ratio_, level_ - 1);
783776
max_num_inst_ = max_num_inst_base_ / std::pow(coarsening_ratio_, level_ - 1);
784777
min_num_inst_ = min_num_inst_base_ / std::pow(coarsening_ratio_, level_ - 1);
785-
logger_->report(" max macro: {} min macro: {} max inst: {} min inst: {}",
786-
max_num_macro_,
787-
min_num_macro_,
788-
max_num_inst_,
789-
min_num_inst_);
790778
// We define the tolerance to improve the robustness of our hierarchical
791779
// clustering
792780
max_num_inst_ = max_num_inst_ * (1 + tolerance_);
793781
min_num_inst_ = min_num_inst_ * (1 - tolerance_);
794782
max_num_macro_ = max_num_macro_ * (1 + tolerance_);
795783
min_num_macro_ = min_num_macro_ * (1 - tolerance_);
796-
logger_->report(" max macro: {} min macro: {} max inst: {} min inst: {}",
797-
max_num_macro_,
798-
min_num_macro_,
799-
max_num_inst_,
800-
min_num_inst_);
801784

802785
if (force_split || (parent->getNumStdCell() > max_num_inst_)) {
803786
if ((max_num_level_ - level_) > max_hier_level_)
@@ -945,7 +928,7 @@ void HierRTLMP::breakCluster(Cluster* parent)
945928
parent->addChild(cluster);
946929
}
947930
// Check the glue logics
948-
// Glue login instances are loose instances in a given module that also
931+
// Glue logic instances are loose instances in a given module that also
949932
// contain module instances
950933
//
951934
std::string cluster_name

0 commit comments

Comments
 (0)