We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 1ba5703 + 14d6c41 commit c80a771Copy full SHA for c80a771
1 file changed
src/mpl/src/SACoreSoftMacro.cpp
@@ -498,7 +498,9 @@ void SACoreSoftMacro::calSoftBlockagePenalty()
498
for (const odb::Rect& blockage : soft_blockages_) {
499
for (const int macro_id : pos_seq_) {
500
const SoftMacro& soft_macro = macros_[macro_id];
501
- if (soft_macro.getNumMacro() > 0) {
+ Cluster* cluster = soft_macro.getCluster();
502
+
503
+ if (soft_macro.getNumMacro() > 0 && cluster->getArea() > 0) {
504
odb::Rect overlap;
505
blockage.intersection(soft_macro.getBBox(), overlap);
506
@@ -507,7 +509,6 @@ void SACoreSoftMacro::calSoftBlockagePenalty()
507
509
continue;
508
510
}
511
- Cluster* cluster = soft_macro.getCluster();
512
const float macro_dominance
513
= cluster->getMacroArea() / static_cast<float>(cluster->getArea());
514
0 commit comments