Skip to content

Commit

Permalink
Clear the map at the end of V3Const
Browse files Browse the repository at this point in the history
Signed-off-by: Ryszard Rozak <[email protected]>
  • Loading branch information
RRozak committed Oct 10, 2023
1 parent ff5848a commit 5070362
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/V3Const.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3765,6 +3765,7 @@ class ConstVisitor final : public VNVisitor {
// clang-format on
}
~ConstVisitor() override {
V3Const::s_containsMemberAccess.clear();
if (m_doCpp) {
if (m_globalPass) {
V3Stats::addStat("Optimizations, Const bit op reduction", m_statBitOpReduction);
Expand All @@ -3776,7 +3777,6 @@ class ConstVisitor final : public VNVisitor {

AstNode* mainAcceptEdit(AstNode* nodep) {
VIsCached::clearCacheTree(); // Avoid using any stale isPure
V3Const::s_containsMemberAccess.clear();
// Operate starting at a random place
return iterateSubtreeReturnEdits(nodep);
}
Expand Down

0 comments on commit 5070362

Please sign in to comment.