From 8700617fae8ee1bdefcf735eee81e37ad4b3eb63 Mon Sep 17 00:00:00 2001 From: Wilson Snyder Date: Sun, 8 Feb 2026 17:53:56 -0500 Subject: [PATCH] Internals: Cleanup CRESET verilog and other misc fixes --- src/V3EmitV.cpp | 7 +------ src/V3LinkInc.cpp | 1 + test_regress/t/t_debug_emitv.out | 4 +--- 3 files changed, 3 insertions(+), 9 deletions(-) diff --git a/src/V3EmitV.cpp b/src/V3EmitV.cpp index e4cf70fba..4724e5f6d 100644 --- a/src/V3EmitV.cpp +++ b/src/V3EmitV.cpp @@ -225,12 +225,6 @@ class EmitVBaseVisitorConst VL_NOT_FINAL : public VNVisitorConst { iterateAndNextConstNull(nodep->rhsp()); if (!m_suppressSemi) puts(";\n"); } - void visit(AstAssignDly* nodep) override { - iterateAndNextConstNull(nodep->lhsp()); - putfs(nodep, " <= "); - iterateAndNextConstNull(nodep->rhsp()); - puts(";\n"); - } void visit(AstAlias* nodep) override { putbs("alias "); iterateConst(nodep->itemsp()); @@ -271,6 +265,7 @@ class EmitVBaseVisitorConst VL_NOT_FINAL : public VNVisitorConst { if (nodep->sensp()) puts(" "); iterateChildrenConst(nodep); } + void visit(AstCReset* nodep) override { puts("/*CRESET*/"); } void visit(AstCase* nodep) override { putfs(nodep, ""); if (nodep->priorityPragma()) puts("priority "); diff --git a/src/V3LinkInc.cpp b/src/V3LinkInc.cpp index ea3cff1ee..cf34778a9 100644 --- a/src/V3LinkInc.cpp +++ b/src/V3LinkInc.cpp @@ -308,6 +308,7 @@ class LinkIncVisitor final : public VNVisitor { AstVar* const varp = new AstVar{ fl, VVarType::BLOCKTEMP, name, VFlagChildDType{}, new AstRefDType{fl, AstRefDType::FlagTypeOfExpr{}, readp->cloneTree(true)}}; + varp->lifetime(VLifetime::AUTOMATIC_EXPLICIT); if (m_ftaskp) varp->funcLocal(true); // Declare the variable diff --git a/test_regress/t/t_debug_emitv.out b/test_regress/t/t_debug_emitv.out index 3b08bee77..0f4a63db9 100644 --- a/test_regress/t/t_debug_emitv.out +++ b/test_regress/t/t_debug_emitv.out @@ -33,9 +33,7 @@ module Vt_debug_emitv_t; function ident; input int signed value; begin : label0 - ident = - ???? // CRESET - ; + ident = /*CRESET*/; ident = value; disable label0; end