|
|
|
@ -134,6 +134,7 @@ public:
|
|
|
|
bool cleanRhs() const override { return false; }
|
|
|
|
bool cleanRhs() const override { return false; }
|
|
|
|
bool sizeMattersLhs() const override { return false; }
|
|
|
|
bool sizeMattersLhs() const override { return false; }
|
|
|
|
bool sizeMattersRhs() const override { return false; }
|
|
|
|
bool sizeMattersRhs() const override { return false; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
int instrCount() const override { return INSTR_COUNT_DBL_TRIG; }
|
|
|
|
int instrCount() const override { return INSTR_COUNT_DBL_TRIG; }
|
|
|
|
void numberOperate(V3Number&, const V3Number&, const V3Number&) override { V3ERROR_NA; }
|
|
|
|
void numberOperate(V3Number&, const V3Number&, const V3Number&) override { V3ERROR_NA; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
@ -172,6 +173,7 @@ public:
|
|
|
|
bool cleanRhs() const override { return false; }
|
|
|
|
bool cleanRhs() const override { return false; }
|
|
|
|
bool sizeMattersLhs() const override { return false; }
|
|
|
|
bool sizeMattersLhs() const override { return false; }
|
|
|
|
bool sizeMattersRhs() const override { return false; }
|
|
|
|
bool sizeMattersRhs() const override { return false; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
int instrCount() const override { return INSTR_COUNT_DBL_TRIG; }
|
|
|
|
int instrCount() const override { return INSTR_COUNT_DBL_TRIG; }
|
|
|
|
bool doubleFlavor() const override { return true; }
|
|
|
|
bool doubleFlavor() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
@ -347,6 +349,7 @@ protected:
|
|
|
|
|
|
|
|
|
|
|
|
public:
|
|
|
|
public:
|
|
|
|
ASTGEN_MEMBERS_AstNodeTermop;
|
|
|
|
ASTGEN_MEMBERS_AstNodeTermop;
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstNodeTriop VL_NOT_FINAL : public AstNodeExpr {
|
|
|
|
class AstNodeTriop VL_NOT_FINAL : public AstNodeExpr {
|
|
|
|
// Ternary expression
|
|
|
|
// Ternary expression
|
|
|
|
@ -403,6 +406,7 @@ public:
|
|
|
|
bool sizeMattersLhs() const override { return false; }
|
|
|
|
bool sizeMattersLhs() const override { return false; }
|
|
|
|
bool sizeMattersRhs() const override { return false; }
|
|
|
|
bool sizeMattersRhs() const override { return false; }
|
|
|
|
bool sizeMattersThs() const override { return false; }
|
|
|
|
bool sizeMattersThs() const override { return false; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
int instrCount() const override { return INSTR_COUNT_DBL_TRIG; }
|
|
|
|
int instrCount() const override { return INSTR_COUNT_DBL_TRIG; }
|
|
|
|
void numberOperate(V3Number& out, const V3Number& lhs, const V3Number& rhs,
|
|
|
|
void numberOperate(V3Number& out, const V3Number& lhs, const V3Number& rhs,
|
|
|
|
const V3Number& ths) override {
|
|
|
|
const V3Number& ths) override {
|
|
|
|
@ -449,6 +453,7 @@ public:
|
|
|
|
bool cleanOut() const override { return true; }
|
|
|
|
bool cleanOut() const override { return true; }
|
|
|
|
bool cleanLhs() const override { return false; }
|
|
|
|
bool cleanLhs() const override { return false; }
|
|
|
|
bool sizeMattersLhs() const override { return false; }
|
|
|
|
bool sizeMattersLhs() const override { return false; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
int instrCount() const override { return INSTR_COUNT_DBL_TRIG; }
|
|
|
|
int instrCount() const override { return INSTR_COUNT_DBL_TRIG; }
|
|
|
|
bool doubleFlavor() const override { return true; }
|
|
|
|
bool doubleFlavor() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
@ -1350,6 +1355,7 @@ public:
|
|
|
|
int instrCount() const override { return widthInstrs() * 64; }
|
|
|
|
int instrCount() const override { return widthInstrs() * 64; }
|
|
|
|
bool isPredictOptimizable() const override { return false; }
|
|
|
|
bool isPredictOptimizable() const override { return false; }
|
|
|
|
bool isPure() override { return false; } // SPECIAL: $display has 'visual' ordering
|
|
|
|
bool isPure() override { return false; } // SPECIAL: $display has 'visual' ordering
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstFOpen final : public AstNodeExpr {
|
|
|
|
class AstFOpen final : public AstNodeExpr {
|
|
|
|
@ -1372,6 +1378,7 @@ public:
|
|
|
|
bool isOutputter() override { return true; }
|
|
|
|
bool isOutputter() override { return true; }
|
|
|
|
bool isUnlikely() const override { return true; }
|
|
|
|
bool isUnlikely() const override { return true; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstFOpenMcd final : public AstNodeExpr {
|
|
|
|
class AstFOpenMcd final : public AstNodeExpr {
|
|
|
|
// @astgen op2 := filenamep : AstNodeExpr
|
|
|
|
// @astgen op2 := filenamep : AstNodeExpr
|
|
|
|
@ -1415,6 +1422,7 @@ public:
|
|
|
|
bool isOutputter() override { return true; } // SPECIAL: makes output
|
|
|
|
bool isOutputter() override { return true; } // SPECIAL: makes output
|
|
|
|
bool cleanOut() const override { return false; }
|
|
|
|
bool cleanOut() const override { return false; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstFRewind final : public AstNodeExpr {
|
|
|
|
class AstFRewind final : public AstNodeExpr {
|
|
|
|
// @astgen op1 := filep : Optional[AstNode]
|
|
|
|
// @astgen op1 := filep : Optional[AstNode]
|
|
|
|
@ -1462,6 +1470,7 @@ public:
|
|
|
|
}
|
|
|
|
}
|
|
|
|
string text() const { return m_text; } // * = Text to display
|
|
|
|
string text() const { return m_text; } // * = Text to display
|
|
|
|
void text(const string& text) { m_text = text; }
|
|
|
|
void text(const string& text) { m_text = text; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstFSeek final : public AstNodeExpr {
|
|
|
|
class AstFSeek final : public AstNodeExpr {
|
|
|
|
// @astgen op1 := filep : AstNode // file (must be a VarRef)
|
|
|
|
// @astgen op1 := filep : AstNode // file (must be a VarRef)
|
|
|
|
@ -1484,6 +1493,7 @@ public:
|
|
|
|
bool isOutputter() override { return true; } // SPECIAL: makes output
|
|
|
|
bool isOutputter() override { return true; } // SPECIAL: makes output
|
|
|
|
bool cleanOut() const override { return false; }
|
|
|
|
bool cleanOut() const override { return false; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstFTell final : public AstNodeExpr {
|
|
|
|
class AstFTell final : public AstNodeExpr {
|
|
|
|
// @astgen op1 := filep : AstNode // file (must be a VarRef)
|
|
|
|
// @astgen op1 := filep : AstNode // file (must be a VarRef)
|
|
|
|
@ -1503,6 +1513,7 @@ public:
|
|
|
|
bool isUnlikely() const override { return true; }
|
|
|
|
bool isUnlikely() const override { return true; }
|
|
|
|
bool cleanOut() const override { return false; }
|
|
|
|
bool cleanOut() const override { return false; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstFalling final : public AstNodeExpr {
|
|
|
|
class AstFalling final : public AstNodeExpr {
|
|
|
|
// Verilog $falling_gclk
|
|
|
|
// Verilog $falling_gclk
|
|
|
|
@ -1519,6 +1530,7 @@ public:
|
|
|
|
bool cleanOut() const override { V3ERROR_NA_RETURN(""); }
|
|
|
|
bool cleanOut() const override { V3ERROR_NA_RETURN(""); }
|
|
|
|
int instrCount() const override { return widthInstrs(); }
|
|
|
|
int instrCount() const override { return widthInstrs(); }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstFell final : public AstNodeExpr {
|
|
|
|
class AstFell final : public AstNodeExpr {
|
|
|
|
// Verilog $fell
|
|
|
|
// Verilog $fell
|
|
|
|
@ -1537,6 +1549,7 @@ public:
|
|
|
|
bool cleanOut() const override { V3ERROR_NA_RETURN(""); }
|
|
|
|
bool cleanOut() const override { V3ERROR_NA_RETURN(""); }
|
|
|
|
int instrCount() const override { return widthInstrs(); }
|
|
|
|
int instrCount() const override { return widthInstrs(); }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstFuture final : public AstNodeExpr {
|
|
|
|
class AstFuture final : public AstNodeExpr {
|
|
|
|
// Verilog $future_gclk
|
|
|
|
// Verilog $future_gclk
|
|
|
|
@ -1555,6 +1568,7 @@ public:
|
|
|
|
bool cleanOut() const override { V3ERROR_NA_RETURN(""); }
|
|
|
|
bool cleanOut() const override { V3ERROR_NA_RETURN(""); }
|
|
|
|
int instrCount() const override { return widthInstrs(); }
|
|
|
|
int instrCount() const override { return widthInstrs(); }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstGatePin final : public AstNodeExpr {
|
|
|
|
class AstGatePin final : public AstNodeExpr {
|
|
|
|
// Possibly expand a gate primitive input pin value to match the range of the gate primitive
|
|
|
|
// Possibly expand a gate primitive input pin value to match the range of the gate primitive
|
|
|
|
@ -1835,6 +1849,7 @@ public:
|
|
|
|
bool cleanOut() const override { V3ERROR_NA_RETURN(""); }
|
|
|
|
bool cleanOut() const override { V3ERROR_NA_RETURN(""); }
|
|
|
|
int instrCount() const override { return widthInstrs(); }
|
|
|
|
int instrCount() const override { return widthInstrs(); }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstPatMember final : public AstNodeExpr {
|
|
|
|
class AstPatMember final : public AstNodeExpr {
|
|
|
|
// Verilog '{a} or '{a{b}}
|
|
|
|
// Verilog '{a} or '{a{b}}
|
|
|
|
@ -1923,6 +1938,7 @@ public:
|
|
|
|
bool isGateOptimizable() const override { return false; }
|
|
|
|
bool isGateOptimizable() const override { return false; }
|
|
|
|
bool isPredictOptimizable() const override { return false; }
|
|
|
|
bool isPredictOptimizable() const override { return false; }
|
|
|
|
bool isPure() override { return !seedp(); }
|
|
|
|
bool isPure() override { return !seedp(); }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
int instrCount() const override { return INSTR_COUNT_PLI; }
|
|
|
|
int instrCount() const override { return INSTR_COUNT_PLI; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
bool combinable(const AstRand* samep) const {
|
|
|
|
bool combinable(const AstRand* samep) const {
|
|
|
|
@ -1947,6 +1963,7 @@ public:
|
|
|
|
bool cleanOut() const override { return false; }
|
|
|
|
bool cleanOut() const override { return false; }
|
|
|
|
bool isGateOptimizable() const override { return false; }
|
|
|
|
bool isGateOptimizable() const override { return false; }
|
|
|
|
bool isPredictOptimizable() const override { return false; }
|
|
|
|
bool isPredictOptimizable() const override { return false; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
int instrCount() const override { return INSTR_COUNT_PLI; }
|
|
|
|
int instrCount() const override { return INSTR_COUNT_PLI; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
@ -1965,6 +1982,7 @@ public:
|
|
|
|
bool cleanOut() const override { V3ERROR_NA_RETURN(""); }
|
|
|
|
bool cleanOut() const override { V3ERROR_NA_RETURN(""); }
|
|
|
|
int instrCount() const override { return widthInstrs(); }
|
|
|
|
int instrCount() const override { return widthInstrs(); }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstRose final : public AstNodeExpr {
|
|
|
|
class AstRose final : public AstNodeExpr {
|
|
|
|
// Verilog $rose
|
|
|
|
// Verilog $rose
|
|
|
|
@ -1983,6 +2001,7 @@ public:
|
|
|
|
bool cleanOut() const override { V3ERROR_NA_RETURN(""); }
|
|
|
|
bool cleanOut() const override { V3ERROR_NA_RETURN(""); }
|
|
|
|
int instrCount() const override { return widthInstrs(); }
|
|
|
|
int instrCount() const override { return widthInstrs(); }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstSExpr final : public AstNodeExpr {
|
|
|
|
class AstSExpr final : public AstNodeExpr {
|
|
|
|
// Sequence expression
|
|
|
|
// Sequence expression
|
|
|
|
@ -2055,6 +2074,7 @@ public:
|
|
|
|
string emitVerilog() override { V3ERROR_NA_RETURN(""); }
|
|
|
|
string emitVerilog() override { V3ERROR_NA_RETURN(""); }
|
|
|
|
string emitC() override { V3ERROR_NA_RETURN(""); }
|
|
|
|
string emitC() override { V3ERROR_NA_RETURN(""); }
|
|
|
|
bool cleanOut() const override { V3ERROR_NA_RETURN(true); }
|
|
|
|
bool cleanOut() const override { V3ERROR_NA_RETURN(true); }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstSScanF final : public AstNodeExpr {
|
|
|
|
class AstSScanF final : public AstNodeExpr {
|
|
|
|
// @astgen op1 := exprsp : List[AstNode] // VarRefs for results
|
|
|
|
// @astgen op1 := exprsp : List[AstNode] // VarRefs for results
|
|
|
|
@ -2086,6 +2106,7 @@ public:
|
|
|
|
string text() const { return m_text; } // * = Text to display
|
|
|
|
string text() const { return m_text; } // * = Text to display
|
|
|
|
VTimescale timeunit() const { return m_timeunit; }
|
|
|
|
VTimescale timeunit() const { return m_timeunit; }
|
|
|
|
void timeunit(const VTimescale& flag) { m_timeunit = flag; }
|
|
|
|
void timeunit(const VTimescale& flag) { m_timeunit = flag; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstSampled final : public AstNodeExpr {
|
|
|
|
class AstSampled final : public AstNodeExpr {
|
|
|
|
// Verilog $sampled
|
|
|
|
// Verilog $sampled
|
|
|
|
@ -2102,6 +2123,7 @@ public:
|
|
|
|
bool cleanOut() const override { V3ERROR_NA_RETURN(""); }
|
|
|
|
bool cleanOut() const override { V3ERROR_NA_RETURN(""); }
|
|
|
|
int instrCount() const override { return 0; }
|
|
|
|
int instrCount() const override { return 0; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstScopeName final : public AstNodeExpr {
|
|
|
|
class AstScopeName final : public AstNodeExpr {
|
|
|
|
// For display %m and DPI context imports
|
|
|
|
// For display %m and DPI context imports
|
|
|
|
@ -2228,6 +2250,7 @@ public:
|
|
|
|
bool cleanOut() const override { V3ERROR_NA_RETURN(""); }
|
|
|
|
bool cleanOut() const override { V3ERROR_NA_RETURN(""); }
|
|
|
|
int instrCount() const override { return widthInstrs(); }
|
|
|
|
int instrCount() const override { return widthInstrs(); }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstStackTraceF final : public AstNodeExpr {
|
|
|
|
class AstStackTraceF final : public AstNodeExpr {
|
|
|
|
// $stacktrace used as function
|
|
|
|
// $stacktrace used as function
|
|
|
|
@ -2263,6 +2286,7 @@ public:
|
|
|
|
bool cleanOut() const override { V3ERROR_NA_RETURN(""); }
|
|
|
|
bool cleanOut() const override { V3ERROR_NA_RETURN(""); }
|
|
|
|
int instrCount() const override { return widthInstrs(); }
|
|
|
|
int instrCount() const override { return widthInstrs(); }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstStructSel final : public AstNodeExpr {
|
|
|
|
class AstStructSel final : public AstNodeExpr {
|
|
|
|
// Unpacked struct/union member access
|
|
|
|
// Unpacked struct/union member access
|
|
|
|
@ -2330,6 +2354,7 @@ public:
|
|
|
|
bool isUnlikely() const override { return true; }
|
|
|
|
bool isUnlikely() const override { return true; }
|
|
|
|
bool cleanOut() const override { return true; }
|
|
|
|
bool cleanOut() const override { return true; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstTestPlusArgs final : public AstNodeExpr {
|
|
|
|
class AstTestPlusArgs final : public AstNodeExpr {
|
|
|
|
// Search expression. If nullptr then this is a $test$plusargs instead of $value$plusargs.
|
|
|
|
// Search expression. If nullptr then this is a $test$plusargs instead of $value$plusargs.
|
|
|
|
@ -2346,6 +2371,7 @@ public:
|
|
|
|
bool isGateOptimizable() const override { return false; }
|
|
|
|
bool isGateOptimizable() const override { return false; }
|
|
|
|
bool isPredictOptimizable() const override { return false; }
|
|
|
|
bool isPredictOptimizable() const override { return false; }
|
|
|
|
// but isPure() true
|
|
|
|
// but isPure() true
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
bool cleanOut() const override { return true; }
|
|
|
|
bool cleanOut() const override { return true; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
@ -2380,6 +2406,7 @@ public:
|
|
|
|
string emitC() override { V3ERROR_NA_RETURN(""); }
|
|
|
|
string emitC() override { V3ERROR_NA_RETURN(""); }
|
|
|
|
string emitSimpleOperator() override { V3ERROR_NA_RETURN(""); }
|
|
|
|
string emitSimpleOperator() override { V3ERROR_NA_RETURN(""); }
|
|
|
|
bool cleanOut() const override { return true; }
|
|
|
|
bool cleanOut() const override { return true; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
int instrCount() const override { return widthInstrs(); }
|
|
|
|
int instrCount() const override { return widthInstrs(); }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
@ -2396,6 +2423,7 @@ public:
|
|
|
|
string emitC() override { V3ERROR_NA_RETURN(""); }
|
|
|
|
string emitC() override { V3ERROR_NA_RETURN(""); }
|
|
|
|
string emitSimpleOperator() override { V3ERROR_NA_RETURN(""); }
|
|
|
|
string emitSimpleOperator() override { V3ERROR_NA_RETURN(""); }
|
|
|
|
bool cleanOut() const override { return true; }
|
|
|
|
bool cleanOut() const override { return true; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
int instrCount() const override { return widthInstrs(); }
|
|
|
|
int instrCount() const override { return widthInstrs(); }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
VTimescale timeunit() const { return m_timeunit; }
|
|
|
|
VTimescale timeunit() const { return m_timeunit; }
|
|
|
|
@ -2450,6 +2478,7 @@ public:
|
|
|
|
bool isGateOptimizable() const override { return false; }
|
|
|
|
bool isGateOptimizable() const override { return false; }
|
|
|
|
bool isPredictOptimizable() const override { return false; }
|
|
|
|
bool isPredictOptimizable() const override { return false; }
|
|
|
|
bool isPure() override { return !outp(); }
|
|
|
|
bool isPure() override { return !outp(); }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
bool cleanOut() const override { return true; }
|
|
|
|
bool cleanOut() const override { return true; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
@ -2553,6 +2582,7 @@ public:
|
|
|
|
bool cleanRhs() const override { return true; }
|
|
|
|
bool cleanRhs() const override { return true; }
|
|
|
|
bool sizeMattersLhs() const override { return false; }
|
|
|
|
bool sizeMattersLhs() const override { return false; }
|
|
|
|
bool sizeMattersRhs() const override { return false; }
|
|
|
|
bool sizeMattersRhs() const override { return false; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
int instrCount() const override { return widthInstrs() * 20; }
|
|
|
|
int instrCount() const override { return widthInstrs() * 20; }
|
|
|
|
bool isPure() override { return false; }
|
|
|
|
bool isPure() override { return false; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
@ -2731,6 +2761,7 @@ public:
|
|
|
|
bool cleanRhs() const override { return true; }
|
|
|
|
bool cleanRhs() const override { return true; }
|
|
|
|
bool sizeMattersLhs() const override { return false; }
|
|
|
|
bool sizeMattersLhs() const override { return false; }
|
|
|
|
bool sizeMattersRhs() const override { return false; }
|
|
|
|
bool sizeMattersRhs() const override { return false; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
int instrCount() const override { return widthInstrs() * 64; }
|
|
|
|
int instrCount() const override { return widthInstrs() * 64; }
|
|
|
|
AstNode* strgp() const { return lhsp(); }
|
|
|
|
AstNode* strgp() const { return lhsp(); }
|
|
|
|
AstNode* filep() const { return rhsp(); }
|
|
|
|
AstNode* filep() const { return rhsp(); }
|
|
|
|
@ -2751,6 +2782,7 @@ public:
|
|
|
|
bool cleanRhs() const override { return true; }
|
|
|
|
bool cleanRhs() const override { return true; }
|
|
|
|
bool sizeMattersLhs() const override { return false; }
|
|
|
|
bool sizeMattersLhs() const override { return false; }
|
|
|
|
bool sizeMattersRhs() const override { return false; }
|
|
|
|
bool sizeMattersRhs() const override { return false; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
int instrCount() const override { return widthInstrs() * 64; }
|
|
|
|
int instrCount() const override { return widthInstrs() * 64; }
|
|
|
|
bool isPredictOptimizable() const override { return false; }
|
|
|
|
bool isPredictOptimizable() const override { return false; }
|
|
|
|
bool isPure() override { return false; } // SPECIAL: $display has 'visual' ordering
|
|
|
|
bool isPure() override { return false; } // SPECIAL: $display has 'visual' ordering
|
|
|
|
@ -3667,6 +3699,7 @@ public:
|
|
|
|
bool isGateOptimizable() const override { return false; }
|
|
|
|
bool isGateOptimizable() const override { return false; }
|
|
|
|
bool isPredictOptimizable() const override { return false; }
|
|
|
|
bool isPredictOptimizable() const override { return false; }
|
|
|
|
bool isPure() override { return false; }
|
|
|
|
bool isPure() override { return false; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
int instrCount() const override { return INSTR_COUNT_PLI; }
|
|
|
|
int instrCount() const override { return INSTR_COUNT_PLI; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
@ -4452,6 +4485,7 @@ public:
|
|
|
|
bool sizeMattersRhs() const override { return false; }
|
|
|
|
bool sizeMattersRhs() const override { return false; }
|
|
|
|
bool sizeMattersThs() const override { return false; }
|
|
|
|
bool sizeMattersThs() const override { return false; }
|
|
|
|
bool sizeMattersFhs() const override { return false; }
|
|
|
|
bool sizeMattersFhs() const override { return false; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
int instrCount() const override { return widthInstrs() * 16; }
|
|
|
|
int instrCount() const override { return widthInstrs() * 16; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
@ -4466,6 +4500,7 @@ public:
|
|
|
|
string emitVerilog() override { return "%f$inferred_disable"; }
|
|
|
|
string emitVerilog() override { return "%f$inferred_disable"; }
|
|
|
|
string emitC() override { V3ERROR_NA_RETURN(""); }
|
|
|
|
string emitC() override { V3ERROR_NA_RETURN(""); }
|
|
|
|
bool cleanOut() const override { return true; }
|
|
|
|
bool cleanOut() const override { return true; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstTime final : public AstNodeTermop {
|
|
|
|
class AstTime final : public AstNodeTermop {
|
|
|
|
@ -4482,6 +4517,7 @@ public:
|
|
|
|
bool cleanOut() const override { return true; }
|
|
|
|
bool cleanOut() const override { return true; }
|
|
|
|
bool isGateOptimizable() const override { return false; }
|
|
|
|
bool isGateOptimizable() const override { return false; }
|
|
|
|
bool isPredictOptimizable() const override { return false; }
|
|
|
|
bool isPredictOptimizable() const override { return false; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
int instrCount() const override { return INSTR_COUNT_TIME; }
|
|
|
|
int instrCount() const override { return INSTR_COUNT_TIME; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
void dump(std::ostream& str = std::cout) const override;
|
|
|
|
void dump(std::ostream& str = std::cout) const override;
|
|
|
|
@ -4503,6 +4539,7 @@ public:
|
|
|
|
bool cleanOut() const override { return true; }
|
|
|
|
bool cleanOut() const override { return true; }
|
|
|
|
bool isGateOptimizable() const override { return false; }
|
|
|
|
bool isGateOptimizable() const override { return false; }
|
|
|
|
bool isPredictOptimizable() const override { return false; }
|
|
|
|
bool isPredictOptimizable() const override { return false; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
int instrCount() const override { return INSTR_COUNT_TIME; }
|
|
|
|
int instrCount() const override { return INSTR_COUNT_TIME; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
bool sameNode(const AstNode* /*samep*/) const override { return true; }
|
|
|
|
void dump(std::ostream& str = std::cout) const override;
|
|
|
|
void dump(std::ostream& str = std::cout) const override;
|
|
|
|
@ -4795,6 +4832,7 @@ public:
|
|
|
|
bool cleanLhs() const override { return false; } // Eliminated before matters
|
|
|
|
bool cleanLhs() const override { return false; } // Eliminated before matters
|
|
|
|
bool sizeMattersLhs() const override { return false; } // Eliminated before matters
|
|
|
|
bool sizeMattersLhs() const override { return false; } // Eliminated before matters
|
|
|
|
int instrCount() const override { return INSTR_COUNT_DBL; }
|
|
|
|
int instrCount() const override { return INSTR_COUNT_DBL; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstCAwait final : public AstNodeUniop {
|
|
|
|
class AstCAwait final : public AstNodeUniop {
|
|
|
|
// Emit C++'s co_await expression
|
|
|
|
// Emit C++'s co_await expression
|
|
|
|
@ -4867,6 +4905,7 @@ public:
|
|
|
|
bool cleanLhs() const override { return true; }
|
|
|
|
bool cleanLhs() const override { return true; }
|
|
|
|
bool sizeMattersLhs() const override { return false; }
|
|
|
|
bool sizeMattersLhs() const override { return false; }
|
|
|
|
int instrCount() const override { return widthInstrs() * 16; }
|
|
|
|
int instrCount() const override { return widthInstrs() * 16; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstCastWrap final : public AstNodeUniop {
|
|
|
|
class AstCastWrap final : public AstNodeUniop {
|
|
|
|
// A cast which has been expanded and the LHSP does all the lifting
|
|
|
|
// A cast which has been expanded and the LHSP does all the lifting
|
|
|
|
@ -4896,6 +4935,7 @@ public:
|
|
|
|
bool cleanLhs() const override { return true; }
|
|
|
|
bool cleanLhs() const override { return true; }
|
|
|
|
bool sizeMattersLhs() const override { return false; }
|
|
|
|
bool sizeMattersLhs() const override { return false; }
|
|
|
|
int instrCount() const override { return widthInstrs() * 16; }
|
|
|
|
int instrCount() const override { return widthInstrs() * 16; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstCvtPackString final : public AstNodeUniop {
|
|
|
|
class AstCvtPackString final : public AstNodeUniop {
|
|
|
|
// Convert to Verilator Packed String (aka verilog "string")
|
|
|
|
// Convert to Verilator Packed String (aka verilog "string")
|
|
|
|
@ -4977,6 +5017,7 @@ public:
|
|
|
|
int instrCount() const override { return widthInstrs() * 16; }
|
|
|
|
int instrCount() const override { return widthInstrs() * 16; }
|
|
|
|
bool isPredictOptimizable() const override { return false; }
|
|
|
|
bool isPredictOptimizable() const override { return false; }
|
|
|
|
bool isPure() override { return false; } // SPECIAL: $display has 'visual' ordering
|
|
|
|
bool isPure() override { return false; } // SPECIAL: $display has 'visual' ordering
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
AstNode* filep() const { return lhsp(); }
|
|
|
|
AstNode* filep() const { return lhsp(); }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstFGetC final : public AstNodeUniop {
|
|
|
|
class AstFGetC final : public AstNodeUniop {
|
|
|
|
@ -4995,6 +5036,7 @@ public:
|
|
|
|
bool isPredictOptimizable() const override { return false; }
|
|
|
|
bool isPredictOptimizable() const override { return false; }
|
|
|
|
bool isPure() override { return false; } // SPECIAL: $display has 'visual' ordering
|
|
|
|
bool isPure() override { return false; } // SPECIAL: $display has 'visual' ordering
|
|
|
|
AstNode* filep() const { return lhsp(); }
|
|
|
|
AstNode* filep() const { return lhsp(); }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstISToRD final : public AstNodeUniop {
|
|
|
|
class AstISToRD final : public AstNodeUniop {
|
|
|
|
// $itor where lhs is signed
|
|
|
|
// $itor where lhs is signed
|
|
|
|
@ -5012,6 +5054,7 @@ public:
|
|
|
|
bool cleanLhs() const override { return true; }
|
|
|
|
bool cleanLhs() const override { return true; }
|
|
|
|
bool sizeMattersLhs() const override { return false; }
|
|
|
|
bool sizeMattersLhs() const override { return false; }
|
|
|
|
int instrCount() const override { return INSTR_COUNT_DBL; }
|
|
|
|
int instrCount() const override { return INSTR_COUNT_DBL; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstIToRD final : public AstNodeUniop {
|
|
|
|
class AstIToRD final : public AstNodeUniop {
|
|
|
|
// $itor where lhs is unsigned
|
|
|
|
// $itor where lhs is unsigned
|
|
|
|
@ -5028,6 +5071,7 @@ public:
|
|
|
|
bool cleanLhs() const override { return true; }
|
|
|
|
bool cleanLhs() const override { return true; }
|
|
|
|
bool sizeMattersLhs() const override { return false; }
|
|
|
|
bool sizeMattersLhs() const override { return false; }
|
|
|
|
int instrCount() const override { return INSTR_COUNT_DBL; }
|
|
|
|
int instrCount() const override { return INSTR_COUNT_DBL; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstIsUnbounded final : public AstNodeUniop {
|
|
|
|
class AstIsUnbounded final : public AstNodeUniop {
|
|
|
|
// True if is unbounded ($)
|
|
|
|
// True if is unbounded ($)
|
|
|
|
@ -5046,6 +5090,7 @@ public:
|
|
|
|
bool cleanOut() const override { return false; }
|
|
|
|
bool cleanOut() const override { return false; }
|
|
|
|
bool cleanLhs() const override { return false; }
|
|
|
|
bool cleanLhs() const override { return false; }
|
|
|
|
bool sizeMattersLhs() const override { return false; }
|
|
|
|
bool sizeMattersLhs() const override { return false; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstIsUnknown final : public AstNodeUniop {
|
|
|
|
class AstIsUnknown final : public AstNodeUniop {
|
|
|
|
// True if any unknown bits
|
|
|
|
// True if any unknown bits
|
|
|
|
@ -5061,6 +5106,7 @@ public:
|
|
|
|
bool cleanOut() const override { return false; }
|
|
|
|
bool cleanOut() const override { return false; }
|
|
|
|
bool cleanLhs() const override { return false; }
|
|
|
|
bool cleanLhs() const override { return false; }
|
|
|
|
bool sizeMattersLhs() const override { return false; }
|
|
|
|
bool sizeMattersLhs() const override { return false; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstLenN final : public AstNodeUniop {
|
|
|
|
class AstLenN final : public AstNodeUniop {
|
|
|
|
// Length of a string
|
|
|
|
// Length of a string
|
|
|
|
@ -5191,6 +5237,7 @@ public:
|
|
|
|
bool cleanLhs() const override { return true; }
|
|
|
|
bool cleanLhs() const override { return true; }
|
|
|
|
bool sizeMattersLhs() const override { return false; }
|
|
|
|
bool sizeMattersLhs() const override { return false; }
|
|
|
|
int instrCount() const override { return widthInstrs() * 4; }
|
|
|
|
int instrCount() const override { return widthInstrs() * 4; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstOneHot0 final : public AstNodeUniop {
|
|
|
|
class AstOneHot0 final : public AstNodeUniop {
|
|
|
|
// True if only single bit, or no bits set in vector
|
|
|
|
// True if only single bit, or no bits set in vector
|
|
|
|
@ -5207,6 +5254,7 @@ public:
|
|
|
|
bool cleanLhs() const override { return true; }
|
|
|
|
bool cleanLhs() const override { return true; }
|
|
|
|
bool sizeMattersLhs() const override { return false; }
|
|
|
|
bool sizeMattersLhs() const override { return false; }
|
|
|
|
int instrCount() const override { return widthInstrs() * 3; }
|
|
|
|
int instrCount() const override { return widthInstrs() * 3; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstRToIRoundS final : public AstNodeUniop {
|
|
|
|
class AstRToIRoundS final : public AstNodeUniop {
|
|
|
|
// Convert real to integer, with arbitrary sized output (not just "integer" format)
|
|
|
|
// Convert real to integer, with arbitrary sized output (not just "integer" format)
|
|
|
|
@ -5225,6 +5273,7 @@ public:
|
|
|
|
bool cleanLhs() const override { return false; }
|
|
|
|
bool cleanLhs() const override { return false; }
|
|
|
|
bool sizeMattersLhs() const override { return false; }
|
|
|
|
bool sizeMattersLhs() const override { return false; }
|
|
|
|
int instrCount() const override { return INSTR_COUNT_DBL; }
|
|
|
|
int instrCount() const override { return INSTR_COUNT_DBL; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstRToIS final : public AstNodeUniop {
|
|
|
|
class AstRToIS final : public AstNodeUniop {
|
|
|
|
// $rtoi(lhs)
|
|
|
|
// $rtoi(lhs)
|
|
|
|
@ -5241,6 +5290,7 @@ public:
|
|
|
|
bool cleanLhs() const override { return false; } // Eliminated before matters
|
|
|
|
bool cleanLhs() const override { return false; } // Eliminated before matters
|
|
|
|
bool sizeMattersLhs() const override { return false; } // Eliminated before matters
|
|
|
|
bool sizeMattersLhs() const override { return false; } // Eliminated before matters
|
|
|
|
int instrCount() const override { return INSTR_COUNT_DBL; }
|
|
|
|
int instrCount() const override { return INSTR_COUNT_DBL; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstRealToBits final : public AstNodeUniop {
|
|
|
|
class AstRealToBits final : public AstNodeUniop {
|
|
|
|
public:
|
|
|
|
public:
|
|
|
|
@ -5256,6 +5306,7 @@ public:
|
|
|
|
bool cleanLhs() const override { return false; } // Eliminated before matters
|
|
|
|
bool cleanLhs() const override { return false; } // Eliminated before matters
|
|
|
|
bool sizeMattersLhs() const override { return false; } // Eliminated before matters
|
|
|
|
bool sizeMattersLhs() const override { return false; } // Eliminated before matters
|
|
|
|
int instrCount() const override { return INSTR_COUNT_DBL; }
|
|
|
|
int instrCount() const override { return INSTR_COUNT_DBL; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstRedAnd final : public AstNodeUniop {
|
|
|
|
class AstRedAnd final : public AstNodeUniop {
|
|
|
|
public:
|
|
|
|
public:
|
|
|
|
@ -5337,6 +5388,7 @@ public:
|
|
|
|
bool cleanLhs() const override { return false; } // Eliminated before matters
|
|
|
|
bool cleanLhs() const override { return false; } // Eliminated before matters
|
|
|
|
bool sizeMattersLhs() const override { return true; } // Eliminated before matters
|
|
|
|
bool sizeMattersLhs() const override { return true; } // Eliminated before matters
|
|
|
|
int instrCount() const override { return 0; }
|
|
|
|
int instrCount() const override { return 0; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
class AstTimeImport final : public AstNodeUniop {
|
|
|
|
class AstTimeImport final : public AstNodeUniop {
|
|
|
|
// Take a constant that represents a time and needs conversion based on time units
|
|
|
|
// Take a constant that represents a time and needs conversion based on time units
|
|
|
|
@ -5419,6 +5471,7 @@ public:
|
|
|
|
bool cleanLhs() const override { return false; } // Eliminated before matters
|
|
|
|
bool cleanLhs() const override { return false; } // Eliminated before matters
|
|
|
|
bool sizeMattersLhs() const override { return true; } // Eliminated before matters
|
|
|
|
bool sizeMattersLhs() const override { return true; } // Eliminated before matters
|
|
|
|
int instrCount() const override { return 0; }
|
|
|
|
int instrCount() const override { return 0; }
|
|
|
|
|
|
|
|
bool isSystemFunc() const override { return true; }
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
// === AstNodeSystemUniopD ===
|
|
|
|
// === AstNodeSystemUniopD ===
|
|
|
|
|