forked from github/verilator
Internals: More const. No functional change intended.
This commit is contained in:
parent
9bda2cb4ad
commit
05e12ab60e
@ -299,7 +299,7 @@ private:
|
||||
// NODE STATE
|
||||
// Input:
|
||||
// AstVar::user1p // V2LatchGraphVertex* The vertex handling this node
|
||||
AstUser1InUse m_inuser1;
|
||||
const AstUser1InUse m_inuser1;
|
||||
// STATE
|
||||
LatchDetectGraph m_graph; // Graph used to detect latches in combo always
|
||||
// VISITORS
|
||||
|
@ -42,7 +42,7 @@ private:
|
||||
// AstNode::user() bool. True if processed
|
||||
// Each call to V3Const::constify
|
||||
// AstNode::user4() Used by V3Const::constify, called below
|
||||
AstUser1InUse m_inuser1;
|
||||
const AstUser1InUse m_inuser1;
|
||||
|
||||
// STATE
|
||||
SenTreeFinder m_finder; // Find global sentree's / add them under the AstTopScope
|
||||
|
@ -30,7 +30,7 @@ private:
|
||||
// NODE STATE/TYPES
|
||||
// Cleared on netlist
|
||||
// AstNode::user() -> bool. True if processed
|
||||
AstUser1InUse m_inuser1;
|
||||
const AstUser1InUse m_inuser1;
|
||||
|
||||
// STATE
|
||||
AstNodeModule* m_modp = nullptr; // Last module
|
||||
|
@ -41,7 +41,7 @@ private:
|
||||
// NODE STATE
|
||||
// Entire netlist:
|
||||
// AstNodeFTask::user1 -> bool, 1=processed
|
||||
AstUser1InUse m_inuser1;
|
||||
const AstUser1InUse m_inuser1;
|
||||
bool m_anyFuncInBegin = false;
|
||||
|
||||
public:
|
||||
|
@ -40,7 +40,7 @@ private:
|
||||
// NODE STATE
|
||||
// Entire netlist:
|
||||
// AstFTask::user1() -> int. Number of references
|
||||
AstUser1InUse m_inuser1;
|
||||
const AstUser1InUse m_inuser1;
|
||||
|
||||
// STATE
|
||||
int m_likely = false; // Excuses for branch likely taken
|
||||
|
@ -39,7 +39,7 @@
|
||||
class CUseVisitor final : public AstNVisitor {
|
||||
// NODE STATE
|
||||
// AstNode::user1() -> bool. True if already visited
|
||||
AstUser1InUse m_inuser1;
|
||||
const AstUser1InUse m_inuser1;
|
||||
|
||||
// MEMBERS
|
||||
bool m_impOnly = false; // In details needed only for implementation
|
||||
|
@ -122,7 +122,7 @@ private:
|
||||
// NODE STATE
|
||||
// Cleared each Case
|
||||
// AstIf::user3() -> bool. Set true to indicate clone not needed
|
||||
AstUser3InUse m_inuser3;
|
||||
const AstUser3InUse m_inuser3;
|
||||
|
||||
// STATE
|
||||
VDouble0 m_statCaseFast; // Statistic tracking
|
||||
|
@ -54,7 +54,7 @@ private:
|
||||
// NODE STATE
|
||||
// Entire netlist:
|
||||
// AstNode::user() // bool. Indicates node is of known size
|
||||
AstUser1InUse m_inuser1;
|
||||
const AstUser1InUse m_inuser1;
|
||||
|
||||
// STATE
|
||||
|
||||
@ -203,6 +203,6 @@ public:
|
||||
|
||||
void V3Cast::castAll(AstNetlist* nodep) {
|
||||
UINFO(2, __FUNCTION__ << ": " << endl);
|
||||
{ CastVisitor visitor{nodep}; } // Destruct before checking
|
||||
{ const CastVisitor visitor{nodep}; } // Destruct before checking
|
||||
V3Global::dumpCheckGlobalTree("cast", 0, v3Global.opt.dumpTreeLevel(__FILE__) >= 3);
|
||||
}
|
||||
|
@ -217,9 +217,9 @@ private:
|
||||
// AstVarScope::user2 -> bool Used in sensitivity list
|
||||
// {statement}Node::user1p -> CdcLogicVertex* for this statement
|
||||
// AstNode::user3 -> bool True indicates to print %% (via V3EmitV)
|
||||
AstUser1InUse m_inuser1;
|
||||
AstUser2InUse m_inuser2;
|
||||
AstUser3InUse m_inuser3;
|
||||
const AstUser1InUse m_inuser1;
|
||||
const AstUser2InUse m_inuser2;
|
||||
const AstUser3InUse m_inuser3;
|
||||
|
||||
// STATE
|
||||
V3Graph m_graph; // Scoreboard of var usages/dependencies
|
||||
|
@ -247,7 +247,7 @@ private:
|
||||
// NODE STATE
|
||||
// Entire netlist:
|
||||
// AstVarScope::user1() -> bool. True indicates processed
|
||||
AstUser1InUse m_inuser1;
|
||||
const AstUser1InUse m_inuser1;
|
||||
|
||||
// STATE
|
||||
ChangedState* m_statep; // Shared state across visitors
|
||||
|
@ -32,7 +32,7 @@
|
||||
class ClassVisitor final : public AstNVisitor {
|
||||
private:
|
||||
// MEMBERS
|
||||
AstUser1InUse m_inuser1;
|
||||
const AstUser1InUse m_inuser1;
|
||||
string m_prefix; // String prefix to add to name based on hier
|
||||
AstScope* m_classScopep = nullptr; // Package moving scopes into
|
||||
AstScope* m_packageScopep = nullptr; // Class package scope
|
||||
|
@ -42,9 +42,9 @@ private:
|
||||
// AstNode::user() -> CleanState. For this node, 0==UNKNOWN
|
||||
// AstNode::user2() -> bool. True indicates widthMin has been propagated
|
||||
// AstNodeDType::user3() -> AstNodeDType*. Alternative node with C size
|
||||
AstUser1InUse m_inuser1;
|
||||
AstUser2InUse m_inuser2;
|
||||
AstUser3InUse m_inuser3;
|
||||
const AstUser1InUse m_inuser1;
|
||||
const AstUser2InUse m_inuser2;
|
||||
const AstUser3InUse m_inuser3;
|
||||
|
||||
// TYPES
|
||||
enum CleanState : uint8_t { CS_UNKNOWN, CS_CLEAN, CS_DIRTY };
|
||||
|
@ -73,7 +73,7 @@ private:
|
||||
// NODE STATE
|
||||
// Cleared each Module:
|
||||
// AstVarScope::user1p() -> AstVarScope*. Temporary signal that was created.
|
||||
AstUser1InUse m_inuser1;
|
||||
const AstUser1InUse m_inuser1;
|
||||
|
||||
// STATE
|
||||
AstNodeModule* m_modp = nullptr; // Current module
|
||||
|
@ -121,7 +121,7 @@ class CombineVisitor final : CombBaseVisitor {
|
||||
private:
|
||||
// NODE STATE
|
||||
// Entire netlist:
|
||||
AstUser3InUse m_user3InUse; // Marks replaced AstCFuncs
|
||||
const AstUser3InUse m_user3InUse; // Marks replaced AstCFuncs
|
||||
// AstUser4InUse part of V3Hasher in V3DupFinder
|
||||
|
||||
// STATE
|
||||
|
@ -109,7 +109,7 @@ void V3Common::commonAll() {
|
||||
// NODE STATE
|
||||
// Entire netlist:
|
||||
// AstClass::user1() -> bool. True if class needs to_string dumper
|
||||
AstUser1InUse m_inuser1;
|
||||
const AstUser1InUse m_inuser1;
|
||||
// Create ToString methods
|
||||
makeVlToString(classp);
|
||||
makeToString(classp);
|
||||
|
@ -110,7 +110,7 @@ class ConstBitOpTreeVisitor final : public AstNVisitor {
|
||||
// NODE STATE
|
||||
// AstVarRef::user4u -> Base index of m_varInfos that points VarInfo
|
||||
// AstVarScope::user4u -> Same as AstVarRef::user4
|
||||
AstUser4InUse m_inuser4;
|
||||
const AstUser4InUse m_inuser4;
|
||||
|
||||
// TYPES
|
||||
|
||||
@ -1975,7 +1975,7 @@ private:
|
||||
if (m_warn && !VN_IS(nodep, AssignDly)) { // Is same var on LHS and RHS?
|
||||
// Note only do this (need user4) when m_warn, which is
|
||||
// done as unique visitor
|
||||
AstUser4InUse m_inuser4;
|
||||
const AstUser4InUse m_inuser4;
|
||||
ConstVarMarkVisitor mark{nodep->lhsp()};
|
||||
ConstVarFindVisitor find{nodep->rhsp()};
|
||||
if (find.found()) need_temp = true;
|
||||
@ -2669,7 +2669,7 @@ private:
|
||||
// SENGATE(SENITEM(x)) -> SENITEM(x), then let it collapse with the
|
||||
// other SENITEM(x).
|
||||
{
|
||||
AstUser4InUse m_inuse4;
|
||||
const AstUser4InUse m_inuse4;
|
||||
// Mark x in SENITEM(x)
|
||||
for (AstSenItem* senp = nodep->sensesp(); senp;
|
||||
senp = VN_AS(senp->nextp(), SenItem)) {
|
||||
|
@ -73,7 +73,7 @@ private:
|
||||
// NODE STATE
|
||||
// Entire netlist:
|
||||
// AstIf::user1() -> bool. True indicates ifelse processed
|
||||
AstUser1InUse m_inuser1;
|
||||
const AstUser1InUse m_inuser1;
|
||||
|
||||
// STATE
|
||||
CheckState m_state; // State save-restored on each new coverage scope/block
|
||||
|
@ -76,7 +76,7 @@ private:
|
||||
// AstVar::user1() -> int. Count of number of references
|
||||
// AstVarScope::user1() -> int. Count of number of references
|
||||
// AstNodeDType::user1() -> int. Count of number of references
|
||||
AstUser1InUse m_inuser1;
|
||||
const AstUser1InUse m_inuser1;
|
||||
|
||||
// TYPES
|
||||
using AssignMap = std::multimap<AstVarScope*, AstNodeAssign*>;
|
||||
|
@ -81,11 +81,11 @@ private:
|
||||
// Cleared each scope/active:
|
||||
// AstAssignDly::user3() -> AstVarScope*. __Vdlyvset__ created for this assign
|
||||
// AstAlwaysPost::user3() -> AstVarScope*. __Vdlyvset__ last referenced in IF
|
||||
AstUser1InUse m_inuser1;
|
||||
AstUser2InUse m_inuser2;
|
||||
AstUser3InUse m_inuser3;
|
||||
AstUser4InUse m_inuser4;
|
||||
AstUser5InUse m_inuser5;
|
||||
const AstUser1InUse m_inuser1;
|
||||
const AstUser2InUse m_inuser2;
|
||||
const AstUser3InUse m_inuser3;
|
||||
const AstUser4InUse m_inuser4;
|
||||
const AstUser5InUse m_inuser5;
|
||||
|
||||
// STATE
|
||||
AstActive* m_activep = nullptr; // Current activate
|
||||
@ -512,6 +512,6 @@ public:
|
||||
|
||||
void V3Delayed::delayedAll(AstNetlist* nodep) {
|
||||
UINFO(2, __FUNCTION__ << ": " << endl);
|
||||
{ DelayedVisitor visitor{nodep}; } // Destruct before checking
|
||||
{ const DelayedVisitor visitor{nodep}; } // Destruct before checking
|
||||
V3Global::dumpCheckGlobalTree("delayed", 0, v3Global.opt.dumpTreeLevel(__FILE__) >= 3);
|
||||
}
|
||||
|
@ -39,7 +39,7 @@ private:
|
||||
// NODE STATE
|
||||
// Cleared entire netlist
|
||||
// AstCFunc::user() // bool. Indicates processing completed
|
||||
AstUser1InUse m_inuser1;
|
||||
const AstUser1InUse m_inuser1;
|
||||
|
||||
// TYPES
|
||||
using FuncMmap = std::multimap<std::string, AstCFunc*>;
|
||||
|
@ -34,7 +34,7 @@ class EmitCParentModule final {
|
||||
// NODE STATE
|
||||
// AstFunc::user4p() AstNodeModule* Parent module pointer
|
||||
// AstVar::user4p() AstNodeModule* Parent module pointer
|
||||
AstUser4InUse user4InUse;
|
||||
const AstUser4InUse user4InUse;
|
||||
|
||||
public:
|
||||
EmitCParentModule();
|
||||
|
@ -37,7 +37,7 @@ constexpr int EMITC_NUM_CONSTW = 8;
|
||||
class EmitCLazyDecls final : public AstNVisitor {
|
||||
// NODE STATE/TYPES
|
||||
// AstNode::user2() -> bool. Already emitted decl for symbols.
|
||||
AstUser2InUse m_inuser2;
|
||||
const AstUser2InUse m_inuser2;
|
||||
|
||||
// MEMBERS
|
||||
std::unordered_set<string> m_emittedManually; // Set of names already declared manually.
|
||||
|
@ -556,7 +556,7 @@ class EmitCTrace final : EmitCFunc {
|
||||
// NODE STATE/TYPES
|
||||
// Cleared on netlist
|
||||
// AstNode::user1() -> int. Enum number
|
||||
AstUser1InUse m_inuser1;
|
||||
const AstUser1InUse m_inuser1;
|
||||
|
||||
// MEMBERS
|
||||
const bool m_slow; // Making slow file
|
||||
|
@ -34,7 +34,7 @@ class EmitCSyms final : EmitCBaseVisitor {
|
||||
// NODE STATE
|
||||
// Cleared on Netlist
|
||||
// AstNodeModule::user1() -> bool. Set true __Vconfigure called
|
||||
AstUser1InUse m_inuser1;
|
||||
const AstUser1InUse m_inuser1;
|
||||
|
||||
// TYPES
|
||||
struct ScopeData {
|
||||
|
@ -42,7 +42,7 @@ class ExpandVisitor final : public AstNVisitor {
|
||||
private:
|
||||
// NODE STATE
|
||||
// AstNode::user1() -> bool. Processed
|
||||
AstUser1InUse m_inuser1;
|
||||
const AstUser1InUse m_inuser1;
|
||||
|
||||
// STATE
|
||||
AstNode* m_stmtp = nullptr; // Current statement
|
||||
|
@ -308,8 +308,8 @@ private:
|
||||
// AstVarScope::user2 -> bool: Signal used in SenItem in *this* always statement
|
||||
// AstVar::user2 -> bool: Warned about SYNCASYNCNET
|
||||
// AstNodeVarRef::user2 -> bool: ConcatOffset visited
|
||||
AstUser1InUse m_inuser1;
|
||||
AstUser2InUse m_inuser2;
|
||||
const AstUser1InUse m_inuser1;
|
||||
const AstUser2InUse m_inuser2;
|
||||
|
||||
// STATE
|
||||
V3Graph m_graph; // Scoreboard of var usages/dependencies
|
||||
@ -907,9 +907,9 @@ private:
|
||||
// Set to nullptr if this assign's tree was later replaced
|
||||
// AstUser1InUse m_inuser1; (Allocated for use in GateVisitor)
|
||||
// AstUser2InUse m_inuser2; (Allocated for use in GateVisitor)
|
||||
AstUser3InUse m_inuser3;
|
||||
const AstUser3InUse m_inuser3;
|
||||
// AstUser4InUse m_inuser4; (Allocated for use in V3Hasher via V3DupFinder)
|
||||
AstUser5InUse m_inuser5;
|
||||
const AstUser5InUse m_inuser5;
|
||||
|
||||
V3DupFinder m_dupFinder; // Duplicate finder for rhs of assigns
|
||||
std::unordered_set<AstNode*> m_nodeDeleteds; // Any node in this hash was deleted
|
||||
|
@ -43,8 +43,8 @@ private:
|
||||
// Cleared on top scope
|
||||
// AstVarScope::user2() -> AstVarScope*. Signal replacing activation with
|
||||
// AstVarRef::user3() -> bool. Signal is replaced activation (already done)
|
||||
AstUser2InUse m_inuser2;
|
||||
AstUser3InUse m_inuser3;
|
||||
const AstUser2InUse m_inuser2;
|
||||
const AstUser3InUse m_inuser3;
|
||||
|
||||
// STATE
|
||||
AstActive* m_activep = nullptr; // Inside activate statement
|
||||
@ -141,7 +141,7 @@ private:
|
||||
// NODE STATE
|
||||
// Cleared on top scope
|
||||
// AstVarScope::user() -> bool. Set when the var has been used as clock
|
||||
AstUser1InUse m_inuser1;
|
||||
const AstUser1InUse m_inuser1;
|
||||
|
||||
// STATE
|
||||
bool m_tracingCall = false; // Iterating into a call to a cfunc
|
||||
@ -231,6 +231,6 @@ public:
|
||||
|
||||
void V3GenClk::genClkAll(AstNetlist* nodep) {
|
||||
UINFO(2, __FUNCTION__ << ": " << endl);
|
||||
{ GenClkReadVisitor visitor{nodep}; } // Destruct before checking
|
||||
{ const GenClkReadVisitor visitor{nodep}; } // Destruct before checking
|
||||
V3Global::dumpCheckGlobalTree("genclk", 0, v3Global.opt.dumpTreeLevel(__FILE__) >= 3);
|
||||
}
|
||||
|
@ -46,7 +46,7 @@ void V3Global::checkTree() const { rootp()->checkTree(); }
|
||||
void V3Global::readFiles() {
|
||||
// NODE STATE
|
||||
// AstNode::user4p() // VSymEnt* Package and typedef symbol names
|
||||
AstUser4InUse inuser4;
|
||||
const AstUser4InUse inuser4;
|
||||
|
||||
VInFilter filter(v3Global.opt.pipeFilter());
|
||||
V3ParseSym parseSyms(v3Global.rootp()); // Symbol table must be common across all parsing
|
||||
|
@ -32,7 +32,7 @@
|
||||
class V3Hasher final {
|
||||
// NODE STATE
|
||||
// AstNode::user4() -> V3Hash. Hash value of this node (hash of 0 is illegal)
|
||||
AstUser4InUse m_inuser4;
|
||||
const AstUser4InUse m_inuser4;
|
||||
|
||||
public:
|
||||
// CONSTRUCTORS
|
||||
|
@ -239,7 +239,7 @@ string V3HierBlock::commandArgsFileName(bool forCMake) const {
|
||||
class HierBlockUsageCollectVisitor final : public AstNVisitor {
|
||||
// NODE STATE
|
||||
// AstNode::user1() -> bool. Processed
|
||||
AstUser1InUse m_inuser1;
|
||||
const AstUser1InUse m_inuser1;
|
||||
|
||||
// STATE
|
||||
using ModuleSet = std::unordered_set<const AstModule*>;
|
||||
|
@ -53,9 +53,9 @@ private:
|
||||
// AstNodeModule::user2() // CIL_*. Allowed to automatically inline module
|
||||
// AstNodeModule::user3() // int. Number of cells referencing this module
|
||||
// AstNodeModule::user4() // int. Statements in module
|
||||
AstUser2InUse m_inuser2;
|
||||
AstUser3InUse m_inuser3;
|
||||
AstUser4InUse m_inuser4;
|
||||
const AstUser2InUse m_inuser2;
|
||||
const AstUser3InUse m_inuser3;
|
||||
const AstUser4InUse m_inuser4;
|
||||
|
||||
// For the user2 field:
|
||||
enum : uint8_t {
|
||||
@ -493,11 +493,10 @@ private:
|
||||
// // is a direct connect to
|
||||
// AstVar::user3() // bool Don't alias the user2, keep it as signal
|
||||
// AstCell::user4 // AstCell* of the created clone
|
||||
|
||||
AstUser2InUse m_inuser2;
|
||||
AstUser3InUse m_inuser3;
|
||||
AstUser4InUse m_inuser4;
|
||||
AstUser5InUse m_inuser5;
|
||||
const AstUser2InUse m_inuser2;
|
||||
const AstUser3InUse m_inuser3;
|
||||
const AstUser4InUse m_inuser4;
|
||||
const AstUser5InUse m_inuser5;
|
||||
|
||||
// STATE
|
||||
AstNodeModule* m_modp = nullptr; // Current module
|
||||
@ -625,8 +624,7 @@ class InlineIntfRefVisitor final : public AstNVisitor {
|
||||
private:
|
||||
// NODE STATE
|
||||
// AstVar::user1p() // AstCell which this Var points to
|
||||
|
||||
AstUser2InUse m_inuser2;
|
||||
const AstUser2InUse m_inuser2;
|
||||
|
||||
string m_scope; // Scope name
|
||||
|
||||
@ -710,8 +708,8 @@ public:
|
||||
|
||||
void V3Inline::inlineAll(AstNetlist* nodep) {
|
||||
UINFO(2, __FUNCTION__ << ": " << endl);
|
||||
AstUser1InUse m_inuser1; // output of InlineMarkVisitor,
|
||||
// input to InlineVisitor.
|
||||
const AstUser1InUse m_inuser1; // output of InlineMarkVisitor,
|
||||
// input to InlineVisitor.
|
||||
// Scoped to clean up temp userN's
|
||||
{ InlineMarkVisitor mvisitor{nodep}; }
|
||||
{ InlineVisitor visitor{nodep}; }
|
||||
|
@ -39,7 +39,7 @@ private:
|
||||
// NODE STATE
|
||||
// Cleared each Cell:
|
||||
// AstPin::user1p() -> bool. True if created assignment already
|
||||
AstUser1InUse m_inuser1;
|
||||
const AstUser1InUse m_inuser1;
|
||||
|
||||
// STATE
|
||||
AstCell* m_cellp = nullptr; // Current cell
|
||||
|
@ -34,7 +34,7 @@ private:
|
||||
// NODE STATE
|
||||
// AstNode::user4() -> int. Path cost + 1, 0 means don't dump
|
||||
// AstNode::user5() -> bool. Processed if assertNoDups
|
||||
AstUser4InUse m_inuser4;
|
||||
const AstUser4InUse m_inuser4;
|
||||
|
||||
// MEMBERS
|
||||
uint32_t m_instrCount = 0; // Running count of instructions
|
||||
|
@ -41,7 +41,7 @@
|
||||
class LifeState final {
|
||||
// NODE STATE
|
||||
// See below
|
||||
AstUser1InUse m_inuser1;
|
||||
const AstUser1InUse m_inuser1;
|
||||
|
||||
// STATE
|
||||
public:
|
||||
|
@ -133,7 +133,7 @@ private:
|
||||
// NODE STATE
|
||||
// Cleared on entire tree
|
||||
// AstVarScope::user4() -> AstVarScope*: Passed to LifePostElim to substitute this var
|
||||
AstUser4InUse m_inuser4;
|
||||
const AstUser4InUse m_inuser4;
|
||||
|
||||
// STATE
|
||||
uint32_t m_sequence = 0; // Sequence number of assigns/varrefs,
|
||||
|
@ -101,8 +101,8 @@ private:
|
||||
// AstCell::user2() // bool clone renaming completed
|
||||
// Allocated across all readFiles in V3Global::readFiles:
|
||||
// AstNode::user4p() // VSymEnt* Package and typedef symbol names
|
||||
AstUser1InUse m_inuser1;
|
||||
AstUser2InUse m_inuser2;
|
||||
const AstUser1InUse m_inuser1;
|
||||
const AstUser2InUse m_inuser2;
|
||||
|
||||
// STATE
|
||||
VInFilter* m_filterp; // Parser filter
|
||||
|
@ -129,9 +129,9 @@ private:
|
||||
// AstVar::user4() // bool. True if port set for this variable
|
||||
// AstNodeBlock::user4() // bool. Did name processing
|
||||
// AstNodeModule::user4() // bool. Live module
|
||||
AstUser1InUse m_inuser1;
|
||||
AstUser2InUse m_inuser2;
|
||||
AstUser4InUse m_inuser4;
|
||||
const AstUser1InUse m_inuser1;
|
||||
const AstUser2InUse m_inuser2;
|
||||
const AstUser4InUse m_inuser4;
|
||||
|
||||
public:
|
||||
// ENUMS
|
||||
@ -1783,8 +1783,8 @@ private:
|
||||
// *::user4() -> See LinkDotState
|
||||
// Cleared on Cell
|
||||
// AstVar::user5() // bool. True if pin used in this cell
|
||||
AstUser3InUse m_inuser3;
|
||||
AstUser5InUse m_inuser5;
|
||||
const AstUser3InUse m_inuser3;
|
||||
const AstUser5InUse m_inuser5;
|
||||
|
||||
// TYPES
|
||||
enum DotPosition : uint8_t {
|
||||
|
@ -40,8 +40,8 @@ private:
|
||||
// Cleared on netlist
|
||||
// AstNode::user1() -> bool. True if processed
|
||||
// AstNode::user2() -> bool. True if fileline recomputed
|
||||
AstUser1InUse m_inuser1;
|
||||
AstUser2InUse m_inuser2;
|
||||
const AstUser1InUse m_inuser1;
|
||||
const AstUser2InUse m_inuser2;
|
||||
|
||||
// TYPES
|
||||
using ImplTypedefMap = std::map<const std::pair<void*, std::string>, AstTypedef*>;
|
||||
|
@ -43,7 +43,7 @@ private:
|
||||
// NODE STATE
|
||||
// Entire netlist:
|
||||
// AstCaseItem::user2() // bool Moved default caseitems
|
||||
AstUser2InUse m_inuser2;
|
||||
const AstUser2InUse m_inuser2;
|
||||
|
||||
// STATE
|
||||
// Below state needs to be preserved between each module call.
|
||||
|
@ -45,10 +45,10 @@ private:
|
||||
// AstVarScope::user3p() -> Set of CFuncs referencing this VarScope. (via m_accessors)
|
||||
// AstCFunc::user4p() -> Multimap of 'VarScope -> VarRefs that reference that VarScope'
|
||||
// in this function. (via m_references)
|
||||
AstUser1InUse m_inuser1;
|
||||
AstUser2InUse m_inuser2;
|
||||
AstUser3InUse m_inuser3;
|
||||
AstUser4InUse m_inuser4;
|
||||
const AstUser1InUse m_inuser1;
|
||||
const AstUser2InUse m_inuser2;
|
||||
const AstUser3InUse m_inuser3;
|
||||
const AstUser4InUse m_inuser4;
|
||||
|
||||
AstUser3Allocator<AstVarScope, std::unordered_set<AstCFunc*>> m_accessors;
|
||||
AstUser4Allocator<AstCFunc, std::unordered_multimap<const AstVarScope*, AstVarRef*>>
|
||||
|
@ -131,8 +131,8 @@ private:
|
||||
// NODE STATE
|
||||
// AstVar::user1 -> Flag set for variables referenced by m_mgCondp
|
||||
// AstNode::user2 -> Flag marking node as included in merge because cheap to duplicate
|
||||
AstUser1InUse m_user1InUse;
|
||||
AstUser2InUse m_user2InUse;
|
||||
const AstUser1InUse m_user1InUse;
|
||||
const AstUser2InUse m_user2InUse;
|
||||
|
||||
// STATE
|
||||
VDouble0 m_statMerges; // Statistic tracking
|
||||
|
@ -37,7 +37,7 @@ private:
|
||||
// AstCell::user1() -> bool. Set true if already processed
|
||||
// AstScope::user1() -> bool. Set true if already processed
|
||||
// AstVar::user1() -> bool. Set true if already processed
|
||||
AstUser1InUse m_inuser1;
|
||||
const AstUser1InUse m_inuser1;
|
||||
|
||||
// STATE
|
||||
AstNodeModule* m_modp = nullptr;
|
||||
|
@ -364,8 +364,8 @@ class OrderBuildVisitor final : public AstNVisitor {
|
||||
// NODE STATE
|
||||
// AstVarScope::user1 -> OrderUser instance for variable (via m_orderUser)
|
||||
// AstVarScope::user2 -> VarUsage within logic blocks
|
||||
AstUser1InUse user1InUse;
|
||||
AstUser2InUse user2InUse;
|
||||
const AstUser1InUse user1InUse;
|
||||
const AstUser2InUse user2InUse;
|
||||
AstUser1Allocator<AstVarScope, OrderUser> m_orderUser;
|
||||
|
||||
// STATE
|
||||
@ -1038,7 +1038,7 @@ class OrderProcess final : AstNDeleter {
|
||||
// NODE STATE
|
||||
// AstNodeModule::user3 -> int: Number of AstCFuncs created under this module
|
||||
// AstNode::user4 -> Used by V3Const::constifyExpensiveEdit
|
||||
AstUser3InUse user3InUse;
|
||||
const AstUser3InUse user3InUse;
|
||||
|
||||
// STATE
|
||||
OrderGraph& m_graph; // The ordering graph
|
||||
|
@ -226,8 +226,8 @@ class ParamProcessor final {
|
||||
// AstGenFor::user5() // bool True if processed
|
||||
// AstVar::user5() // bool True if constant propagated
|
||||
// AstCell::user5p() // string* Generate portion of hierarchical name
|
||||
AstUser4InUse m_inuser4;
|
||||
AstUser5InUse m_inuser5;
|
||||
const AstUser4InUse m_inuser4;
|
||||
const AstUser5InUse m_inuser5;
|
||||
// User1/2/3 used by constant function simulations
|
||||
|
||||
// TYPES
|
||||
|
@ -2566,7 +2566,7 @@ void V3Partition::go(V3Graph* mtasksp) {
|
||||
{
|
||||
// The V3InstrCount within LogicMTask will set user5 on each AST
|
||||
// node, to assert that we never count any node twice.
|
||||
AstUser5InUse inUser5;
|
||||
const AstUser5InUse inUser5;
|
||||
Vx2MTaskMap vx2mtask;
|
||||
for (V3GraphVertex* vxp = m_fineDepsGraphp->verticesBeginp(); vxp;
|
||||
vxp = vxp->verticesNextp()) {
|
||||
|
@ -44,7 +44,7 @@ class PremitAssignVisitor final : public AstNVisitor {
|
||||
private:
|
||||
// NODE STATE
|
||||
// AstVar::user3() // bool; occurs on LHS of current assignment
|
||||
AstUser3InUse m_inuser3;
|
||||
const AstUser3InUse m_inuser3;
|
||||
|
||||
// STATE
|
||||
bool m_noopt = false; // Disable optimization of variables in this block
|
||||
@ -93,8 +93,8 @@ private:
|
||||
// AstShiftL::user2() -> bool. True if converted to conditional
|
||||
// AstShiftR::user2() -> bool. True if converted to conditional
|
||||
// *::user3() -> See PremitAssignVisitor
|
||||
AstUser1InUse m_inuser1;
|
||||
AstUser2InUse m_inuser2;
|
||||
const AstUser1InUse m_inuser1;
|
||||
const AstUser2InUse m_inuser2;
|
||||
|
||||
// STATE
|
||||
AstCFunc* m_cfuncp = nullptr; // Current block
|
||||
|
@ -37,7 +37,7 @@ private:
|
||||
// NODE STATE
|
||||
// Cleared on Netlist
|
||||
// AstClass::user1() -> bool. Set true to indicate needs randomize processing
|
||||
AstUser1InUse m_inuser1;
|
||||
const AstUser1InUse m_inuser1;
|
||||
|
||||
using DerivedSet = std::unordered_set<AstClass*>;
|
||||
using BaseToDerivedMap = std::unordered_map<AstClass*, DerivedSet>;
|
||||
@ -119,7 +119,7 @@ private:
|
||||
// AstClass::user1() -> bool. Set true to indicate needs randomize processing
|
||||
// AstEnumDType::user2() -> AstVar*. Pointer to table with enum values
|
||||
// AstUser1InUse m_inuser1; (Allocated for use in RandomizeMarkVisitor)
|
||||
AstUser2InUse m_inuser2;
|
||||
const AstUser2InUse m_inuser2;
|
||||
|
||||
// STATE
|
||||
size_t m_enumValueTabCount = 0; // Number of tables with enum values created
|
||||
|
@ -45,7 +45,7 @@ class ReloopVisitor final : public AstNVisitor {
|
||||
private:
|
||||
// NODE STATE
|
||||
// AstCFunc::user1p -> Var* for temp var, 0=not set yet
|
||||
AstUser1InUse m_inuser1;
|
||||
const AstUser1InUse m_inuser1;
|
||||
|
||||
// STATE
|
||||
VDouble0 m_statReloops; // Statistic tracking
|
||||
|
@ -41,8 +41,8 @@ private:
|
||||
// NODE STATE
|
||||
// AstVar::user1p -> AstVarScope replacement for this variable
|
||||
// AstTask::user2p -> AstTask*. Replacement task
|
||||
AstUser1InUse m_inuser1;
|
||||
AstUser2InUse m_inuser2;
|
||||
const AstUser1InUse m_inuser1;
|
||||
const AstUser2InUse m_inuser2;
|
||||
|
||||
// TYPES
|
||||
// These cannot be unordered unless make a specialized hashing pair (gcc-8)
|
||||
|
@ -72,9 +72,9 @@ class SimulateVisitor VL_NOT_FINAL : public AstNVisitor {
|
||||
private:
|
||||
// NODE STATE
|
||||
// Cleared on each always/assignw
|
||||
AstUser1InUse m_inuser1;
|
||||
AstUser2InUse m_inuser2;
|
||||
AstUser3InUse m_inuser3;
|
||||
const AstUser1InUse m_inuser1;
|
||||
const AstUser2InUse m_inuser2;
|
||||
const AstUser3InUse m_inuser3;
|
||||
|
||||
// Checking:
|
||||
// AstVar(Scope)::user1() -> VarUsage. Set true to indicate tracking as lvalue/rvalue
|
||||
|
@ -50,7 +50,7 @@ class SliceVisitor final : public AstNVisitor {
|
||||
// AstNodeAssign::user1() -> bool. True if find is complete
|
||||
// AstNodeUniop::user1() -> bool. True if find is complete
|
||||
// AstArraySel::user1p() -> AstVarRef. The VarRef that the final ArraySel points to
|
||||
AstUser1InUse m_inuser1;
|
||||
const AstUser1InUse m_inuser1;
|
||||
|
||||
// STATE
|
||||
AstNode* m_assignp = nullptr; // Assignment we are under
|
||||
|
@ -242,10 +242,10 @@ private:
|
||||
// AstVarScope::user2p -> Var SplitNodeVertex* for delayed assignment var, 0=not set yet
|
||||
// Ast*::user3p -> Statement SplitLogicVertex* (temporary only)
|
||||
// Ast*::user4 -> Current ordering number (reorderBlock usage)
|
||||
AstUser1InUse m_inuser1;
|
||||
AstUser2InUse m_inuser2;
|
||||
AstUser3InUse m_inuser3;
|
||||
AstUser4InUse m_inuser4;
|
||||
const AstUser1InUse m_inuser1;
|
||||
const AstUser2InUse m_inuser2;
|
||||
const AstUser3InUse m_inuser3;
|
||||
const AstUser4InUse m_inuser4;
|
||||
|
||||
protected:
|
||||
// STATE
|
||||
|
@ -128,7 +128,7 @@ class SplitAsVisitor final : public SplitAsBaseVisitor {
|
||||
private:
|
||||
// NODE STATE
|
||||
// AstAlways::user() -> bool. True if already processed
|
||||
AstUser1InUse m_inuser1;
|
||||
const AstUser1InUse m_inuser1;
|
||||
|
||||
// STATE
|
||||
VDouble0 m_statSplits; // Statistic tracking
|
||||
|
@ -127,7 +127,7 @@
|
||||
struct SplitVarImpl {
|
||||
// NODE STATE
|
||||
// AstNodeModule::user1() -> Block number counter for generating unique names
|
||||
AstUser1InUse m_user1InUse; // Only used in SplitUnpackedVarVisitor
|
||||
const AstUser1InUse m_user1InUse; // Only used in SplitUnpackedVarVisitor
|
||||
|
||||
static AstNodeAssign* newAssign(FileLine* fileline, AstNode* lhsp, AstNode* rhsp,
|
||||
const AstVar* varp) {
|
||||
|
@ -227,8 +227,8 @@ private:
|
||||
// Passed to SubstUseVisitor
|
||||
// AstVar::user1p -> SubstVar* for usage var, 0=not set yet
|
||||
// AstVar::user2 -> int step number for last assignment, 0=not set yet
|
||||
AstUser1InUse m_inuser1;
|
||||
AstUser2InUse m_inuser2;
|
||||
const AstUser1InUse m_inuser1;
|
||||
const AstUser2InUse m_inuser2;
|
||||
|
||||
// STATE
|
||||
std::vector<SubstVarEntry*> m_entryps; // Nodes to delete when we are finished
|
||||
@ -381,6 +381,6 @@ public:
|
||||
|
||||
void V3Subst::substituteAll(AstNetlist* nodep) {
|
||||
UINFO(2, __FUNCTION__ << ": " << endl);
|
||||
{ SubstVisitor visitor{nodep}; } // Destruct before checking
|
||||
{ const SubstVisitor visitor{nodep}; } // Destruct before checking
|
||||
V3Global::dumpCheckGlobalTree("subst", 0, v3Global.opt.dumpTreeLevel(__FILE__) >= 3);
|
||||
}
|
||||
|
@ -98,9 +98,8 @@ private:
|
||||
// AstNodeFTask::user3p // AstScope* this FTask is under
|
||||
// AstNodeFTask::user4p // GraphFTaskVertex* this FTask is under
|
||||
// AstVar::user4p // GraphFTaskVertex* this variable is declared in
|
||||
|
||||
AstUser3InUse m_inuser3;
|
||||
AstUser4InUse m_inuser4;
|
||||
const AstUser3InUse m_inuser3;
|
||||
const AstUser4InUse m_inuser4;
|
||||
|
||||
// TYPES
|
||||
using VarToScopeMap = std::map<std::pair<AstScope*, AstVar*>, AstVarScope*>;
|
||||
@ -370,7 +369,7 @@ struct TaskDpiUtils {
|
||||
class TaskGatherWrittenVisitor final : public AstNVisitor {
|
||||
// NODE STATE
|
||||
// AstVarScope::user5 -> Already considered variable
|
||||
AstUser5InUse m_user5InUse;
|
||||
const AstUser5InUse m_user5InUse;
|
||||
|
||||
std::vector<AstVarScope*> m_writtenVariables; // Variables written
|
||||
|
||||
@ -408,9 +407,8 @@ private:
|
||||
// Each funccall
|
||||
// to TaskRelinkVisitor:
|
||||
// AstVar::user2p // AstVarScope* to replace varref with
|
||||
|
||||
AstUser1InUse m_inuser1;
|
||||
AstUser2InUse m_inuser2;
|
||||
const AstUser1InUse m_inuser1;
|
||||
const AstUser2InUse m_inuser2;
|
||||
|
||||
// TYPES
|
||||
enum InsertMode : uint8_t {
|
||||
|
@ -162,9 +162,9 @@ private:
|
||||
// AstVarScope::user1() // V3GraphVertex* for this node
|
||||
// AstCCall::user2() // bool; walked next list for other ccalls
|
||||
// Ast*::user3() // TraceActivityVertex* for this node
|
||||
AstUser1InUse m_inuser1;
|
||||
AstUser2InUse m_inuser2;
|
||||
AstUser3InUse m_inuser3;
|
||||
const AstUser1InUse m_inuser1;
|
||||
const AstUser2InUse m_inuser2;
|
||||
const AstUser3InUse m_inuser3;
|
||||
// AstUser4InUse In V3Hasher via V3DupFinder
|
||||
|
||||
// STATE
|
||||
|
@ -327,11 +327,11 @@ class TristateVisitor final : public TristateBaseVisitor {
|
||||
// See TristateGraph:
|
||||
// AstVar::user5p -> TristateVertex* for variable being built
|
||||
// AstStmt*::user5p -> TristateVertex* for this statement
|
||||
AstUser1InUse m_inuser1;
|
||||
AstUser2InUse m_inuser2;
|
||||
AstUser3InUse m_inuser3;
|
||||
AstUser4InUse m_inuser4;
|
||||
AstUser5InUse m_inuser5;
|
||||
const AstUser1InUse m_inuser1;
|
||||
const AstUser2InUse m_inuser2;
|
||||
const AstUser3InUse m_inuser3;
|
||||
const AstUser4InUse m_inuser4;
|
||||
const AstUser5InUse m_inuser5;
|
||||
|
||||
// TYPES
|
||||
using RefVec = std::vector<AstVarRef*>;
|
||||
|
@ -240,10 +240,10 @@ private:
|
||||
// NODE STATE
|
||||
// Netlist:
|
||||
// AstVar::user1p -> UndrivenVar* for usage var, 0=not set yet
|
||||
AstUser1InUse m_inuser1;
|
||||
const AstUser1InUse m_inuser1;
|
||||
// Each always:
|
||||
// AstNode::user2p -> UndrivenVar* for usage var, 0=not set yet
|
||||
AstUser2InUse m_inuser2;
|
||||
const AstUser2InUse m_inuser2;
|
||||
|
||||
// STATE
|
||||
std::array<std::vector<UndrivenVarEntry*>, 3> m_entryps; // Nodes to delete when finished
|
||||
|
@ -49,8 +49,8 @@ private:
|
||||
// AstSel::user() -> bool. Set true if already processed
|
||||
// AstArraySel::user() -> bool. Set true if already processed
|
||||
// AstNode::user2p() -> AstIf* Inserted if assignment for conditional
|
||||
AstUser1InUse m_inuser1;
|
||||
AstUser2InUse m_inuser2;
|
||||
const AstUser1InUse m_inuser1;
|
||||
const AstUser2InUse m_inuser2;
|
||||
|
||||
// STATE
|
||||
AstNodeModule* m_modp = nullptr; // Current module
|
||||
|
@ -78,7 +78,7 @@ unsigned VarTspSorter::s_serialNext = 0;
|
||||
class VariableOrder final {
|
||||
// NODE STATE
|
||||
// AstVar::user1() -> attributes, via m_attributes
|
||||
AstUser1InUse m_user1InUse; // AstVar
|
||||
const AstUser1InUse m_user1InUse; // AstVar
|
||||
|
||||
struct VarAttributes {
|
||||
uint32_t stratum; // Roughly equivalent to alignment requirement, to avoid padding
|
||||
|
@ -67,7 +67,7 @@ public:
|
||||
class WidthCommitVisitor final : public AstNVisitor {
|
||||
// NODE STATE
|
||||
// AstVar::user1p -> bool, processed
|
||||
AstUser1InUse m_inuser1;
|
||||
const AstUser1InUse m_inuser1;
|
||||
|
||||
// STATE
|
||||
AstNodeModule* m_modp = nullptr;
|
||||
|
Loading…
Reference in New Issue
Block a user