aboutsummaryrefslogtreecommitdiffstats
path: root/mistral/arch.cc
diff options
context:
space:
mode:
Diffstat (limited to 'mistral/arch.cc')
-rw-r--r--mistral/arch.cc14
1 files changed, 14 insertions, 0 deletions
diff --git a/mistral/arch.cc b/mistral/arch.cc
index ffe6e833..d5bc424c 100644
--- a/mistral/arch.cc
+++ b/mistral/arch.cc
@@ -382,6 +382,20 @@ delay_t Arch::estimateDelay(WireId src, WireId dst) const
return 100 * std::abs(y1 - y0) + 100 * std::abs(x1 - x0) + 100;
}
+ArcBounds Arch::getRouteBoundingBox(WireId src, WireId dst) const
+{
+ ArcBounds bounds;
+ int src_x = CycloneV::rn2x(src.node);
+ int src_y = CycloneV::rn2y(src.node);
+ int dst_x = CycloneV::rn2x(dst.node);
+ int dst_y = CycloneV::rn2y(dst.node);
+ bounds.x0 = std::min(src_x, dst_x);
+ bounds.y0 = std::min(src_y, dst_y);
+ bounds.x1 = std::max(src_x, dst_x);
+ bounds.y1 = std::max(src_y, dst_y);
+ return bounds;
+}
+
delay_t Arch::predictDelay(const NetInfo *net_info, const PortRef &sink) const
{
if (net_info->driver.cell == nullptr || net_info->driver.cell->bel == BelId())