From 85bb108ba40f9573571de0a785f9fbc91c4e1dd0 Mon Sep 17 00:00:00 2001 From: gatecat Date: Wed, 10 Feb 2021 11:54:54 +0000 Subject: Add getBelPinsForCellPin to Arch API This is a basic implementation, without considering "M of N" arrangements (e.g. for LUT permuation where you only want to route to 1 out of 4/6 sinks) or using a type other than IdString to identify bel pins. But this is also enough to start working out where in nextpnr will break due to removing the 1:1 cell:bel pin cardinality, as a next step. Signed-off-by: gatecat --- fpga_interchange/arch.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'fpga_interchange/arch.h') diff --git a/fpga_interchange/arch.h b/fpga_interchange/arch.h index fd2d16a2..e5c7551b 100644 --- a/fpga_interchange/arch.h +++ b/fpga_interchange/arch.h @@ -660,6 +660,7 @@ struct ArchRanges using TileBelsRangeT = BelRange; using BelAttrsRangeT = std::vector>; using BelPinsRangeT = IdStringRange; + using CellBelPinRangeT = std::array; // Wires using AllWiresRangeT = WireRange; using DownhillPipRangeT = DownhillPipRange; @@ -866,6 +867,8 @@ struct Arch : ArchAPI return str_range; } + std::array getBelPinsForCellPin(CellInfo *cell_info, IdString pin) const override { return {pin}; } + // ------------------------------------------------- WireId getWireByName(IdStringList name) const override; -- cgit v1.2.3