mirror of
https://github.com/verilator/verilator.git
synced 2026-10-06 01:54:01 +02:00
Refactor and test VL_MULS_MAX_WORDS
This commit is contained in:
+7
-50
@@ -888,6 +888,13 @@ public:
|
||||
}
|
||||
}
|
||||
virtual void visit(AstNodeBiop* nodep) VL_OVERRIDE {
|
||||
if (nodep->emitCheckMaxWords() && nodep->widthWords() > VL_MULS_MAX_WORDS) {
|
||||
nodep->v3warn(
|
||||
E_UNSUPPORTED,
|
||||
"Unsupported: "
|
||||
<< nodep->prettyOperatorName() << " operator of " << nodep->width()
|
||||
<< " bits exceeds hardcoded limit VL_MULS_MAX_WORDS in verilatedos.h");
|
||||
}
|
||||
if (emitSimpleOk(nodep)) {
|
||||
putbs("(");
|
||||
iterateAndNextNull(nodep->lhsp());
|
||||
@@ -915,56 +922,6 @@ public:
|
||||
puts(")");
|
||||
}
|
||||
}
|
||||
virtual void visit(AstMulS* nodep) VL_OVERRIDE {
|
||||
if (nodep->widthWords() > VL_MULS_MAX_WORDS) {
|
||||
nodep->v3warn(
|
||||
E_UNSUPPORTED,
|
||||
"Unsupported: Signed multiply of "
|
||||
<< nodep->width()
|
||||
<< " bits exceeds hardcoded limit VL_MULS_MAX_WORDS in verilatedos.h");
|
||||
}
|
||||
visit(VN_CAST(nodep, NodeBiop));
|
||||
}
|
||||
virtual void visit(AstPow* nodep) VL_OVERRIDE {
|
||||
if (nodep->widthWords() > VL_MULS_MAX_WORDS) {
|
||||
nodep->v3warn(
|
||||
E_UNSUPPORTED,
|
||||
"Unsupported: Power of "
|
||||
<< nodep->width()
|
||||
<< " bits exceeds hardcoded limit VL_MULS_MAX_WORDS in verilatedos.h");
|
||||
}
|
||||
visit(VN_CAST(nodep, NodeBiop));
|
||||
}
|
||||
virtual void visit(AstPowSS* nodep) VL_OVERRIDE {
|
||||
if (nodep->widthWords() > VL_MULS_MAX_WORDS) {
|
||||
nodep->v3warn(
|
||||
E_UNSUPPORTED,
|
||||
"Unsupported: Power of "
|
||||
<< nodep->width()
|
||||
<< " bits exceeds hardcoded limit VL_MULS_MAX_WORDS in verilatedos.h");
|
||||
}
|
||||
visit(VN_CAST(nodep, NodeBiop));
|
||||
}
|
||||
virtual void visit(AstPowSU* nodep) VL_OVERRIDE {
|
||||
if (nodep->widthWords() > VL_MULS_MAX_WORDS) {
|
||||
nodep->v3warn(
|
||||
E_UNSUPPORTED,
|
||||
"Unsupported: Power of "
|
||||
<< nodep->width()
|
||||
<< " bits exceeds hardcoded limit VL_MULS_MAX_WORDS in verilatedos.h");
|
||||
}
|
||||
visit(VN_CAST(nodep, NodeBiop));
|
||||
}
|
||||
virtual void visit(AstPowUS* nodep) VL_OVERRIDE {
|
||||
if (nodep->widthWords() > VL_MULS_MAX_WORDS) {
|
||||
nodep->v3warn(
|
||||
E_UNSUPPORTED,
|
||||
"Unsupported: Power of "
|
||||
<< nodep->width()
|
||||
<< " bits exceeds hardcoded limit VL_MULS_MAX_WORDS in verilatedos.h");
|
||||
}
|
||||
visit(VN_CAST(nodep, NodeBiop));
|
||||
}
|
||||
virtual void visit(AstCCast* nodep) VL_OVERRIDE {
|
||||
// Extending a value of the same word width is just a NOP.
|
||||
if (nodep->size() <= VL_IDATASIZE) {
|
||||
|
||||
Reference in New Issue
Block a user