aboutsummaryrefslogtreecommitdiffstats
path: root/common/kernel/context.cc
diff options
context:
space:
mode:
authorYRabbit <rabbit@yrabbit.cyou>2022-07-10 08:05:25 +1000
committerYRabbit <rabbit@yrabbit.cyou>2022-07-10 08:05:25 +1000
commitecddac7b18526940db529389b7efdae299b7dd12 (patch)
treefb27cb7b7d8a3a79d7d1b14049396a9cf2596dd6 /common/kernel/context.cc
parent1ebfe67daf2ec3e1e64150f09ab4c194f41d1d9d (diff)
parent664cec54b92844745e21a4e86dcf8e3cca09d781 (diff)
downloadnextpnr-ecddac7b18526940db529389b7efdae299b7dd12.tar.gz
nextpnr-ecddac7b18526940db529389b7efdae299b7dd12.tar.bz2
nextpnr-ecddac7b18526940db529389b7efdae299b7dd12.zip
Merge branch 'master' into clock-wip
Diffstat (limited to 'common/kernel/context.cc')
-rw-r--r--common/kernel/context.cc5
1 files changed, 5 insertions, 0 deletions
diff --git a/common/kernel/context.cc b/common/kernel/context.cc
index e35d3e49..014394a6 100644
--- a/common/kernel/context.cc
+++ b/common/kernel/context.cc
@@ -30,6 +30,9 @@ WireId Context::getNetinfoSourceWire(const NetInfo *net_info) const
if (net_info->driver.cell == nullptr)
return WireId();
+ if (net_info->driver.cell->isPseudo())
+ return net_info->driver.cell->pseudo_cell->getPortWire(net_info->driver.port);
+
auto src_bel = net_info->driver.cell->bel;
if (src_bel == BelId())
@@ -47,6 +50,8 @@ WireId Context::getNetinfoSourceWire(const NetInfo *net_info) const
SSOArray<WireId, 2> Context::getNetinfoSinkWires(const NetInfo *net_info, const PortRef &user_info) const
{
+ if (user_info.cell->isPseudo())
+ return SSOArray<WireId, 2>(1, user_info.cell->pseudo_cell->getPortWire(user_info.port));
auto dst_bel = user_info.cell->bel;
if (dst_bel == BelId())
return SSOArray<WireId, 2>(0, WireId());