Delete unused parameter, refa
Signed-off-by: Pawel Kojma <pkojma@internships.antmicro.com>
This commit is contained in:
parent
d352fa5abf
commit
77c4f5368a
|
|
@ -120,7 +120,8 @@ class LinkResolveVisitor final : public VNVisitor {
|
||||||
}
|
}
|
||||||
void visit(AstVar* nodep) override {
|
void visit(AstVar* nodep) override {
|
||||||
iterateChildren(nodep);
|
iterateChildren(nodep);
|
||||||
if (m_classp && !nodep->isParam() && !VN_IS(nodep->backp(), SelLoopVars)) nodep->varType(VVarType::MEMBER);
|
if (m_classp && !nodep->isParam() && !VN_IS(nodep->backp(), SelLoopVars))
|
||||||
|
nodep->varType(VVarType::MEMBER);
|
||||||
if (m_ftaskp) nodep->funcLocal(true);
|
if (m_ftaskp) nodep->funcLocal(true);
|
||||||
if (nodep->isSigModPublic()) {
|
if (nodep->isSigModPublic()) {
|
||||||
nodep->sigModPublic(false); // We're done with this attribute
|
nodep->sigModPublic(false); // We're done with this attribute
|
||||||
|
|
|
||||||
|
|
@ -33,12 +33,13 @@
|
||||||
|
|
||||||
#include "verilatedos.h"
|
#include "verilatedos.h"
|
||||||
|
|
||||||
|
#include "V3Randomize.h"
|
||||||
|
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3FileLine.h"
|
#include "V3FileLine.h"
|
||||||
#include "V3Global.h"
|
#include "V3Global.h"
|
||||||
#include "V3MemberMap.h"
|
#include "V3MemberMap.h"
|
||||||
#include "V3Randomize.h"
|
|
||||||
#include "V3UniqueNames.h"
|
#include "V3UniqueNames.h"
|
||||||
|
|
||||||
#include <queue>
|
#include <queue>
|
||||||
|
|
@ -277,8 +278,7 @@ class RandomizeMarkVisitor final : public VNVisitor {
|
||||||
|
|
||||||
// Process a single constraint during nested constraint cloning
|
// Process a single constraint during nested constraint cloning
|
||||||
void processNestedConstraint(AstConstraint* const constrp, AstVarRef* rootVarRefp,
|
void processNestedConstraint(AstConstraint* const constrp, AstVarRef* rootVarRefp,
|
||||||
const std::vector<AstVar*>& newPath, AstClass* targetClassp,
|
const std::vector<AstVar*>& newPath, AstClass* targetClassp) {
|
||||||
AstClass* const memberClassp) {
|
|
||||||
std::string pathPrefix = rootVarRefp->name();
|
std::string pathPrefix = rootVarRefp->name();
|
||||||
for (AstVar* pathMemberVarp : newPath) {
|
for (AstVar* pathMemberVarp : newPath) {
|
||||||
pathPrefix += GLOBAL_CONSTRAINT_SEPARATOR + pathMemberVarp->name();
|
pathPrefix += GLOBAL_CONSTRAINT_SEPARATOR + pathMemberVarp->name();
|
||||||
|
|
@ -335,8 +335,7 @@ class RandomizeMarkVisitor final : public VNVisitor {
|
||||||
// member selections
|
// member selections
|
||||||
nestedClassp->foreachMember(
|
nestedClassp->foreachMember(
|
||||||
[&](AstClass* const containingClassp, AstConstraint* const constrp) {
|
[&](AstClass* const containingClassp, AstConstraint* const constrp) {
|
||||||
processNestedConstraint(constrp, rootVarRefp, newPath, targetClassp,
|
processNestedConstraint(constrp, rootVarRefp, newPath, targetClassp);
|
||||||
containingClassp);
|
|
||||||
});
|
});
|
||||||
cloneNestedConstraintsRecurse(rootVarRefp, nestedClassp, newPath, targetClassp);
|
cloneNestedConstraintsRecurse(rootVarRefp, nestedClassp, newPath, targetClassp);
|
||||||
}
|
}
|
||||||
|
|
@ -571,11 +570,9 @@ class RandomizeMarkVisitor final : public VNVisitor {
|
||||||
AstVarRef* rootVarRefp
|
AstVarRef* rootVarRefp
|
||||||
= new AstVarRef{nodep->fileline(), classp, memberVarp, VAccess::READ};
|
= new AstVarRef{nodep->fileline(), classp, memberVarp, VAccess::READ};
|
||||||
std::vector<AstVar*> emptyPath;
|
std::vector<AstVar*> emptyPath;
|
||||||
memberClassp->foreachMember(
|
memberClassp->foreachMember([&](AstClass* const, AstConstraint* const constrp) {
|
||||||
[&](AstClass* const containingClassp, AstConstraint* const constrp) {
|
processNestedConstraint(constrp, rootVarRefp, emptyPath, classp);
|
||||||
processNestedConstraint(constrp, rootVarRefp, emptyPath, classp,
|
});
|
||||||
containingClassp);
|
|
||||||
});
|
|
||||||
cloneNestedConstraintsRecurse(rootVarRefp, memberClassp, emptyPath, classp);
|
cloneNestedConstraintsRecurse(rootVarRefp, memberClassp, emptyPath, classp);
|
||||||
// Delete the temporary VarRef created for constraint cloning
|
// Delete the temporary VarRef created for constraint cloning
|
||||||
VL_DO_DANGLING(rootVarRefp->deleteTree(), rootVarRefp);
|
VL_DO_DANGLING(rootVarRefp->deleteTree(), rootVarRefp);
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue