From 1afc48fb4c95f516d5af10362c3c9cf718fee252 Mon Sep 17 00:00:00 2001 From: Jean-Paul Chaput Date: Wed, 2 Jun 2021 14:14:32 +0200 Subject: [PATCH] Forgot to update pointers to merged nets in BlifParser. --- crlcore/src/ccore/blif/BlifParser.cpp | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/crlcore/src/ccore/blif/BlifParser.cpp b/crlcore/src/ccore/blif/BlifParser.cpp index 45b5a8f9..835454ec 100644 --- a/crlcore/src/ccore/blif/BlifParser.cpp +++ b/crlcore/src/ccore/blif/BlifParser.cpp @@ -726,17 +726,23 @@ namespace { else if (not net) { // Net doesn't exist yet plugNet->addAlias( netName ); } - else if (plugNet != net){ // Plus already connected to another net + else if (plugNet != net){ // Plug already connected to another net if (not plugNet->isExternal()) { net->merge( plugNet ); + plugNet = net; + } + else { + plugNet->merge( net ); + net = plugNet; } - else plugNet->merge( net ); } // if (subckt->getModel()->getCell()->getName() == "sm0") { // cerr << "sm0 plug:" << plug->getMasterNet()->getName() << " => net:" << net->getName() << endl; // } + cerr << "plugNet=" << (void*)plugNet << endl; + cerr << "plug->getMasterNet()=" << (void*)(plug->getMasterNet()) << endl; if (plugNet->isSupply() and not plug->getMasterNet()->isSupply()) { ostringstream message; message << "In " << instance << "\n "