From e7d81913a48bffd970f7a92acc44eb36d9f996f7 Mon Sep 17 00:00:00 2001 From: Keith Rothman <537074+litghost@users.noreply.github.com> Date: Thu, 18 Mar 2021 16:31:40 -0700 Subject: Add "checkPipAvailForNet" to Arch API. This is important for distiguishing valid pseudo pips in the FPGA interchange arch. This also avoids a double or triple lookup of pip->net map. Signed-off-by: Keith Rothman <537074+litghost@users.noreply.github.com> --- fpga_interchange/arch.cc | 4 ++-- fpga_interchange/arch.h | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'fpga_interchange') diff --git a/fpga_interchange/arch.cc b/fpga_interchange/arch.cc index 1cefb6fe..5f3a5eed 100644 --- a/fpga_interchange/arch.cc +++ b/fpga_interchange/arch.cc @@ -1587,7 +1587,7 @@ void Arch::bindWire(WireId wire, NetInfo *net, PlaceStrength strength) refreshUiWire(wire); } -bool Arch::check_pip_avail_for_net(PipId pip, NetInfo *net) const +bool Arch::checkPipAvailForNet(PipId pip, NetInfo *net) const { NPNR_ASSERT(pip != PipId()); auto pip_iter = pip_to_net.find(pip); @@ -1725,7 +1725,7 @@ bool Arch::check_pip_avail_for_net(PipId pip, NetInfo *net) const return true; } -bool Arch::checkPipAvail(PipId pip) const { return check_pip_avail_for_net(pip, nullptr); } +bool Arch::checkPipAvail(PipId pip) const { return checkPipAvailForNet(pip, nullptr); } Arch::~Arch() {} diff --git a/fpga_interchange/arch.h b/fpga_interchange/arch.h index 6a3d7ad1..3185eb5d 100644 --- a/fpga_interchange/arch.h +++ b/fpga_interchange/arch.h @@ -536,7 +536,7 @@ struct Arch : ArchAPI void unbindPip(PipId pip) final; bool checkPipAvail(PipId pip) const final; - bool check_pip_avail_for_net(PipId pip, NetInfo *) const; + bool checkPipAvailForNet(PipId pip, NetInfo *net) const final; NetInfo *getBoundPipNet(PipId pip) const final { -- cgit v1.2.3