diff options
author | David Shah <dave@ds0.me> | 2019-08-08 21:24:01 +0100 |
---|---|---|
committer | David Shah <dave@ds0.me> | 2019-08-08 21:24:01 +0100 |
commit | f0abbc71b56a54e1de0a5e775f77a1d14dfea681 (patch) | |
tree | 7bfce44ec856901a466623eab18c41c5ee4a9d5a | |
parent | eed85cda83a98aeb3979d89db73aac2091bf9bb7 (diff) | |
download | nextpnr-f0abbc71b56a54e1de0a5e775f77a1d14dfea681.tar.gz nextpnr-f0abbc71b56a54e1de0a5e775f77a1d14dfea681.tar.bz2 nextpnr-f0abbc71b56a54e1de0a5e775f77a1d14dfea681.zip |
ecp5: Fix handling of missing ports in LUT permutation
Fixes #310
Signed-off-by: David Shah <dave@ds0.me>
-rw-r--r-- | ecp5/arch_place.cc | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/ecp5/arch_place.cc b/ecp5/arch_place.cc index 18374c07..d5c345af 100644 --- a/ecp5/arch_place.cc +++ b/ecp5/arch_place.cc @@ -140,6 +140,10 @@ void Arch::permute_luts() std::vector<NetInfo *> orig_nets; for (int i = 0; i < 4; i++) { + if (!ci->ports.count(port_names.at(i))) { + ci->ports[port_names.at(i)].name = port_names.at(i); + ci->ports[port_names.at(i)].type = PORT_IN; + } auto &port = ci->ports.at(port_names.at(i)); float crit = 0; if (port.net != nullptr && nc.count(port.net->name)) { |