The-OpenROAD-Project / OpenSTA

OpenSTA engine
GNU General Public License v3.0
399 stars 172 forks source link

Support for hierarchical sdf annotation #37

Closed andyfox-rushc closed 4 years ago

andyfox-rushc commented 4 years ago

Annotating sdf with -path seems not to work for hierarchical design. Issue seems to be in stringPrint in findPin in SdfReader. Possible fix shown below. Test case (hier.tar.gz) showing problem attached -- run without fix yields missing pin error messages, run with fix seems ok hier_sdf.tar.gz .

Pin SdfReader::findPin(const char name) { if (path_) { string path_name; // original code, path name not used.. // stringPrint(pathname, path, divider_, name); //AF: Bug fix: include path hierarchy in name.. stringPrint(pathname, "%s%c%s",path, divider, name); Pin *pin = network->findPin(path_name.cstr()); return pin; } else return network->findPin(name); }

jjcherry56 commented 4 years ago

thanks for the concise test case. fixed in commit 679b5d7

On Wed, Jan 15, 2020 at 2:51 PM andy fox notifications@github.com wrote:

Annotating sdf with -path seems not to work for hierarchical design. Issue seems to be in stringPrint in findPin in SdfReader. Possible fix shown below. Test case (hier.tar.gz) showing problem attached -- run without fix yields missing pin error messages, run with fix seems ok hier_sdf.tar.gz https://github.com/The-OpenROAD-Project/OpenSTA/files/4067683/hier_sdf.tar.gz .

Pin SdfReader::findPin(const char name) { if (path_) { string path_name; // original code, path name not used.. // stringPrint(pathname, path, divider_, name); //AF: Bug fix: include path hierarchy in name.. stringPrint(pathname, "%s%c%s",path, divider, name); Pin *pin = network->findPin(path_name.cstr()); return pin; } else return network->findPin(name); }

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/The-OpenROAD-Project/OpenSTA/issues/37?email_source=notifications&email_token=AIJDZFJGRVPIARE7O6PESZTQ56AOPA5CNFSM4KHKN6BKYY3PNVWWK3TUL52HS4DFUVEXG43VMWVGG33NNVSW45C7NFSM4IGPGKSQ, or unsubscribe https://github.com/notifications/unsubscribe-auth/AIJDZFOVPS4N2BJGSTFLMBLQ56AOPANCNFSM4KHKN6BA .