In RoutingPad, prefer Segment over Pad at constant area.
This case may arise with cells created from GDS+LEF.
This commit is contained in:
parent
c5827877f6
commit
a8d0371990
|
@ -377,6 +377,9 @@ namespace Hurricane {
|
||||||
double bestArea = getArea(bestComponent);
|
double bestArea = getArea(bestComponent);
|
||||||
|
|
||||||
if (compArea == bestArea) {
|
if (compArea == bestArea) {
|
||||||
|
if (dynamic_cast<Segment*>(component) and dynamic_cast<Pad*>(bestComponent)) {
|
||||||
|
bestComponent = component;
|
||||||
|
} else {
|
||||||
Box compBox = component->getBoundingBox();
|
Box compBox = component->getBoundingBox();
|
||||||
Box bestBox = bestComponent->getBoundingBox();
|
Box bestBox = bestComponent->getBoundingBox();
|
||||||
|
|
||||||
|
@ -391,6 +394,7 @@ namespace Hurricane {
|
||||||
if (compBox.getXMin() < bestBox.getXMin())
|
if (compBox.getXMin() < bestBox.getXMin())
|
||||||
bestComponent = component;
|
bestComponent = component;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
if (compArea > bestArea)
|
if (compArea > bestArea)
|
||||||
bestComponent = component;
|
bestComponent = component;
|
||||||
|
|
Loading…
Reference in New Issue