mirror of
https://github.com/verilator/verilator.git
synced 2025-01-19 12:54:02 +00:00
Fix DPI import false BLKSEQ warnings.
This commit is contained in:
parent
e080b9d565
commit
beb7c58375
2
Changes
2
Changes
@ -15,6 +15,8 @@ indicates the contributor was also the author of the fix; Thanks!
|
||||
|
||||
**** Fix DPI import output of 64 bits, bug398. [Mike Denio]
|
||||
|
||||
**** Fix DPI import false BLKSEQ warnings. [Alex Solomatnikov]
|
||||
|
||||
**** Fix MSVC compile warning with trunc/round, bug394. [Amir Gonnen]
|
||||
|
||||
**** Fix autoconf and Makefile warnings, bug396. [Ruben Diez]
|
||||
|
@ -408,6 +408,7 @@ private:
|
||||
AstAssign* assp = new AstAssign (pinp->fileline(),
|
||||
pinp,
|
||||
new AstVarRef(outvscp->fileline(), outvscp, false));
|
||||
assp->fileline()->modifyWarnOff(V3ErrorCode::BLKSEQ, true); // Ok if in <= block
|
||||
// Put assignment BEHIND of all other statements
|
||||
beginp->addNext(assp);
|
||||
}
|
||||
@ -418,6 +419,7 @@ private:
|
||||
AstAssign* assp = new AstAssign (pinp->fileline(),
|
||||
new AstVarRef(inVscp->fileline(), inVscp, true),
|
||||
pinp);
|
||||
assp->fileline()->modifyWarnOff(V3ErrorCode::BLKSEQ, true); // Ok if in <= block
|
||||
// Put assignment in FRONT of all other statements
|
||||
if (AstNode* afterp = beginp->nextp()) {
|
||||
afterp->unlinkFrBackWithNext();
|
||||
@ -507,6 +509,7 @@ private:
|
||||
AstAssign* assp = new AstAssign (pinp->fileline(),
|
||||
pinp,
|
||||
new AstVarRef(outvscp->fileline(), outvscp, false));
|
||||
assp->fileline()->modifyWarnOff(V3ErrorCode::BLKSEQ, true); // Ok if in <= block
|
||||
// Put assignment BEHIND of all other statements
|
||||
beginp->addNext(assp);
|
||||
}
|
||||
|
@ -15,7 +15,11 @@
|
||||
`define NO_SHORTREAL
|
||||
`endif
|
||||
|
||||
module t ();
|
||||
module t (/*AUTOARG*/
|
||||
// Inputs
|
||||
clk
|
||||
);
|
||||
input clk;
|
||||
|
||||
// Allowed import return types:
|
||||
// void, byte, shortint, int, longint, real, shortreal, chandle, and string
|
||||
@ -194,4 +198,10 @@ module t ();
|
||||
$finish;
|
||||
end
|
||||
|
||||
always @ (posedge clk) begin
|
||||
i_b <= ~i_b;
|
||||
// This once mis-threw a BLKSEQ warning
|
||||
dpii_v_bit (i_b,o_b); if (o_b !== ~i_b) $stop;
|
||||
end
|
||||
|
||||
endmodule
|
||||
|
Loading…
Reference in New Issue
Block a user