aboutsummaryrefslogtreecommitdiffstats
path: root/fpga_interchange
diff options
context:
space:
mode:
authorgatecat <gatecat@ds0.me>2022-12-07 10:00:53 +0100
committergatecat <gatecat@ds0.me>2022-12-07 10:00:53 +0100
commite260ac33abdd175f38ea5d8367c52a154b486648 (patch)
tree56ca8a3877a1270bcac51160067e1016abcb97cf /fpga_interchange
parentcd3b76e3f7ce9d9927087f6fdd38e04968688ee7 (diff)
downloadnextpnr-e260ac33abdd175f38ea5d8367c52a154b486648.tar.gz
nextpnr-e260ac33abdd175f38ea5d8367c52a154b486648.tar.bz2
nextpnr-e260ac33abdd175f38ea5d8367c52a154b486648.zip
refactor: ArcBounds -> BoundingBox
Signed-off-by: gatecat <gatecat@ds0.me>
Diffstat (limited to 'fpga_interchange')
-rw-r--r--fpga_interchange/arch.cc2
-rw-r--r--fpga_interchange/arch.h4
-rw-r--r--fpga_interchange/arch_pack_clusters.cc4
-rw-r--r--fpga_interchange/cost_map.cc4
-rw-r--r--fpga_interchange/cost_map.h2
5 files changed, 8 insertions, 8 deletions
diff --git a/fpga_interchange/arch.cc b/fpga_interchange/arch.cc
index 4fc5d48d..d20fe253 100644
--- a/fpga_interchange/arch.cc
+++ b/fpga_interchange/arch.cc
@@ -730,7 +730,7 @@ std::vector<std::pair<IdString, std::string>> Arch::getBelAttrs(BelId bel) const
// -----------------------------------------------------------------------
-ArcBounds Arch::getRouteBoundingBox(WireId src, WireId dst) const
+BoundingBox Arch::getRouteBoundingBox(WireId src, WireId dst) const
{
int dst_tile = dst.tile == -1 ? chip_info->nodes[dst.index].tile_wires[0].tile : dst.tile;
int src_tile = src.tile == -1 ? chip_info->nodes[src.index].tile_wires[0].tile : src.tile;
diff --git a/fpga_interchange/arch.h b/fpga_interchange/arch.h
index 04f583d4..7e373a56 100644
--- a/fpga_interchange/arch.h
+++ b/fpga_interchange/arch.h
@@ -701,7 +701,7 @@ struct Arch : ArchAPI<ArchRanges>
// -------------------------------------------------
delay_t estimateDelay(WireId src, WireId dst) const final;
delay_t predictDelay(BelId src_bel, IdString src_pin, BelId dst_bel, IdString dst_pin) const final;
- ArcBounds getRouteBoundingBox(WireId src, WireId dst) const final;
+ BoundingBox getRouteBoundingBox(WireId src, WireId dst) const final;
delay_t getDelayEpsilon() const final { return 20; }
delay_t getRipupDelayPenalty() const final { return 120; }
float getDelayNS(delay_t v) const final { return v * 0.001; }
@@ -896,7 +896,7 @@ struct Arch : ArchAPI<ArchRanges>
}
CellInfo *getClusterRootCell(ClusterId cluster) const override;
- ArcBounds getClusterBounds(ClusterId cluster) const override;
+ BoundingBox getClusterBounds(ClusterId cluster) const override;
Loc getClusterOffset(const CellInfo *cell) const override;
bool isClusterStrict(const CellInfo *cell) const override;
bool normal_cluster_placement(const Context *, const Cluster &, const ClusterPOD &, CellInfo *, BelId,
diff --git a/fpga_interchange/arch_pack_clusters.cc b/fpga_interchange/arch_pack_clusters.cc
index 97a3e1a5..0dc75192 100644
--- a/fpga_interchange/arch_pack_clusters.cc
+++ b/fpga_interchange/arch_pack_clusters.cc
@@ -419,10 +419,10 @@ bool Arch::getClusterPlacement(ClusterId cluster, BelId root_bel,
}
}
-ArcBounds Arch::getClusterBounds(ClusterId cluster) const
+BoundingBox Arch::getClusterBounds(ClusterId cluster) const
{
// TODO: Implement this
- ArcBounds bounds(0, 0, 0, 0);
+ BoundingBox bounds(0, 0, 0, 0);
return bounds;
}
diff --git a/fpga_interchange/cost_map.cc b/fpga_interchange/cost_map.cc
index c20ba11b..d960c7cf 100644
--- a/fpga_interchange/cost_map.cc
+++ b/fpga_interchange/cost_map.cc
@@ -184,7 +184,7 @@ static void assign_min_entry(delay_t *dst, const delay_t &src)
}
std::pair<delay_t, int> CostMap::get_nearby_cost_entry(const boost::multi_array<delay_t, 2> &matrix, int cx, int cy,
- const ArcBounds &bounds)
+ const BoundingBox &bounds)
{
#ifdef DEBUG_FILL
log_info("Filling %d, %d within (%d, %d, %d, %d)\n", cx, cy, bounds.x0, bounds.y0, bounds.x1, bounds.y1);
@@ -249,7 +249,7 @@ void CostMap::fill_holes(const Context *ctx, const TypeWirePair &type_pair, boos
// find missing cost entries and fill them in by copying a nearby cost entry
std::vector<std::tuple<unsigned, unsigned, delay_t>> missing;
bool couldnt_fill = false;
- auto shifted_bounds = ArcBounds(0, 0, matrix.shape()[0] - 1, matrix.shape()[1] - 1);
+ auto shifted_bounds = BoundingBox(0, 0, matrix.shape()[0] - 1, matrix.shape()[1] - 1);
int max_fill = 0;
for (unsigned ix = 0; ix < matrix.shape()[0]; ix++) {
for (unsigned iy = 0; iy < matrix.shape()[1]; iy++) {
diff --git a/fpga_interchange/cost_map.h b/fpga_interchange/cost_map.h
index 88fb97e4..dfde29f9 100644
--- a/fpga_interchange/cost_map.h
+++ b/fpga_interchange/cost_map.h
@@ -58,7 +58,7 @@ class CostMap
delay_t delay_penality);
std::pair<delay_t, int> get_nearby_cost_entry(const boost::multi_array<delay_t, 2> &matrix, int cx, int cy,
- const ArcBounds &bounds);
+ const BoundingBox &bounds);
delay_t get_penalty(const boost::multi_array<delay_t, 2> &matrix) const;
};