Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a setTermNet method in SNLInstance #4

Closed
xtofalex opened this issue Apr 19, 2022 · 0 comments · Fixed by #5
Closed

Add a setTermNet method in SNLInstance #4

xtofalex opened this issue Apr 19, 2022 · 0 comments · Fixed by #5
Assignees
Labels
enhancement New feature or request

Comments

@xtofalex
Copy link
Collaborator

Following SNLBusTerm setNet method, purpose of this enhancement is to add a setTermNet method in SNLInstance, this method will avoid to connect all bits of a term to a net, provided that both have the same size.

SNLInstance* ins1;
SNLDesign* model1 = ins1->getModel();
SNLBusTerm* model1Term = model1->getBusTerm(term1Name);
SNLInstance* ins2;
SNLDesign* model2 = ins2->getModel();
SNLBusTerm* model2Term = model2->getBusTerm(term2Name);
SNLBusNet* net = SNLBusNet::create(currentDesign, model1Term->getMSB(), model1Term->getLSB());
ins1->setTermNet(model1Term,  net);
ins2->setTermNet(model2Term,  net);

ins1 and ins2 terms will be connected if model1Term, model2Term and net share the same size.

@xtofalex xtofalex added the enhancement New feature or request label Apr 19, 2022
@xtofalex xtofalex self-assigned this Apr 19, 2022
@xtofalex xtofalex linked a pull request Apr 20, 2022 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant