Fix handling of empty cell port assignments (i.e. ignore them)
authorClifford Wolf <clifford@clifford.at>
Fri, 21 Jul 2017 17:32:31 +0000 (19:32 +0200)
committerClifford Wolf <clifford@clifford.at>
Fri, 21 Jul 2017 17:32:31 +0000 (19:32 +0200)
passes/hierarchy/hierarchy.cc
passes/techmap/techmap.cc

index d71e9c574bdd3af9bcb91f570488b587f7e7596a..41c1cfdedba0c414f605ae96eed667c92b512fd2 100644 (file)
@@ -640,6 +640,9 @@ struct HierarchyPass : public Pass {
                                        if (w == nullptr || w->port_id == 0)
                                                continue;
 
+                                       if (GetSize(conn.second) == 0)
+                                               continue;
+
                                        if (GetSize(w) == GetSize(conn.second))
                                                continue;
 
index e85714b5798eb309974392d7558e447c85f7ceae..ae89453d0587508d17a26b29d0f0f323174f4d2c 100644 (file)
@@ -247,6 +247,9 @@ struct TechmapWorker
                                continue;
                        }
 
+                       if (GetSize(it.second) == 0)
+                               continue;
+
                        RTLIL::Wire *w = tpl->wires_.at(portname);
                        RTLIL::SigSig c, extra_connect;