Internals: Update some JSON references. No functional change.

This commit is contained in:
Wilson Snyder 2025-12-22 23:49:25 -05:00
parent a2fcd37c08
commit 5dc05e1fa8
8 changed files with 14 additions and 14 deletions

View File

@ -155,7 +155,7 @@ Summary:
requires GNU Make to be available on the platform.
:vlopt:`--build` cannot be specified when using :vlopt:`-E`,
:vlopt:`--dpi-hdr-only`, :vlopt:`--lint-only`, or :vlopt:`--xml-only`.
:vlopt:`--dpi-hdr-only`, :vlopt:`--json-only` or :vlopt:`--lint-only`.
.. option:: --build-dep-bin <filename>
@ -606,7 +606,7 @@ Summary:
.. option:: --flatten
Force flattening of the design's hierarchy, with all modules, tasks, and
functions inlined. Typically used with :vlopt:`--xml-only`.
functions inlined. Typically used with :vlopt:`--json-only`.
Flattening large designs may require significant CPU time, memory and
storage.

View File

@ -957,7 +957,7 @@ class AstMemberDType final : public AstNodeDType {
//
// @astgen ptr := m_refDTypep : Optional[AstNodeDType] // Elements of this type (post-width)
string m_name; // Name of variable
string m_tag; // Holds the string of the verilator tag -- used in XML output.
string m_tag; // Holds the string of the verilator tag -- used in JSON output.
int m_lsb = -1; // Within this level's packed struct, the LSB of the first bit of the member
bool m_constrainedRand = false;
// UNSUP: int m_randType; // Randomization type (IEEE)

View File

@ -1737,7 +1737,7 @@ class AstTypedef final : public AstNode {
// @astgen op4 := attrsp : List[AstNode] // Attributes during early parse
string m_name;
string m_tag; // Holds the string of the verilator tag -- used in XML output.
string m_tag; // Holds the string of the verilator tag -- used in JSON output.
uint32_t m_declTokenNum; // Declaration token number
bool m_attrPublic = false;
bool m_isHideLocal : 1; // Verilog local
@ -1866,13 +1866,13 @@ class AstVar final : public AstNode {
string m_name; // Name of variable
string m_origName; // Original name before dot addition
string m_tag; // Holds the string of the verilator tag -- used in XML output.
string m_tag; // Holds the string of the verilator tag -- used in JSON output.
VVarType m_varType; // Type of variable
VDirection m_direction; // Direction input/output etc
VDirection m_declDirection; // Declared direction input/output etc
VLifetime m_lifetime; // Lifetime
VRandAttr m_rand; // Randomizability of this variable (rand, randc, etc)
int m_pinNum = 0; // For XML, if non-zero the connection pin number
int m_pinNum = 0; // For JSON, if non-zero the connection pin number
bool m_ansi : 1; // Params or pins declared in the module header, rather than the body
bool m_declTyped : 1; // Declared as type (for dedup check)
bool m_tristate : 1; // Inout or triwire or trireg

View File

@ -47,7 +47,7 @@
// ResolveVisitor:
// #9: Resolve general variables, which may point into the interface or modport (after #8)
// LinkResolve:
// #10: Unlink modports, not needed later except for XML/Lint
// #10: Unlink modports, not needed later except for JSON/Lint
//*************************************************************************
// TOP
// {name-of-top-modulename}
@ -2205,7 +2205,7 @@ class LinkDotParamVisitor final : public VNVisitor {
symp->exported(false);
refp->pinNum(nodep->pinNum());
// Put the variable where the port is, so that variables stay
// in pin number sorted order. Otherwise hierarchical or XML
// in pin number sorted order. Otherwise hierarchical or JSON
// may botch by-position instances.
nodep->addHereThisAsNext(refp->unlinkFrBack());
}

View File

@ -484,7 +484,7 @@ class LinkResolveVisitor final : public VNVisitor {
iterateChildren(nodep);
}
// void visit(AstModport* nodep) override { ... }
// We keep Modport's themselves around for XML dump purposes
// We keep Modport's themselves around for JSON dump purposes
void visit(AstGenFor* nodep) override {
VL_RESTORER(m_underGenerate);

View File

@ -367,7 +367,7 @@ class ScopeCleanupVisitor final : public VNVisitor {
iterateChildren(nodep);
}
void visit(AstModportFTaskRef* nodep) override {
// The modport persists only for xml dump
// The modport persists only for JSON dump
// The crossrefs are dealt with in V3LinkDot
nodep->ftaskp(nullptr);
iterateChildren(nodep);

View File

@ -282,7 +282,7 @@ void V3VariableOrder::orderAll(AstNetlist* netlistp) {
if (v3Global.opt.stats()) V3Stats::statsStage("variableorder-sort");
// Insert them back under the module, in the new order, but at
// the front of the list so they come out first in dumps/XML.
// the front of the list so they come out first in dumps/JSON.
for (AstNodeModule* modp = v3Global.rootp()->modulesp(); modp;
modp = VN_AS(modp->nextp(), NodeModule)) {
const std::vector<AstVar*>& varps = sortedVars[modp];

View File

@ -138,7 +138,7 @@ static void emitJson() VL_MT_DISABLED {
v3Global.rootp()->dumpTreeJsonFile(filename);
}
static void emitXmlOrJson() VL_MT_DISABLED {
static void emitSerialized() VL_MT_DISABLED {
if (v3Global.opt.xmlOnly()) V3EmitXml::emitxml();
if (v3Global.opt.jsonOnly()) emitJson();
}
@ -216,7 +216,7 @@ static void process() {
VlOs::DeltaWallTime cvtWallTime{true};
if (v3Global.opt.debugExitElab()) {
V3Error::abortIfErrors();
if (v3Global.opt.serializeOnly()) emitXmlOrJson();
if (v3Global.opt.serializeOnly()) emitSerialized();
cout << "--debug-exit-elab: Exiting after elaboration pass\n";
v3Global.vlExit(0);
}
@ -634,7 +634,7 @@ static void process() {
V3EmitC::emitcImp();
}
if (v3Global.opt.serializeOnly()) {
emitXmlOrJson();
emitSerialized();
} else if (v3Global.opt.debugCheck() && !v3Global.opt.lintOnly()
&& !v3Global.opt.dpiHdrOnly()) {
// Check XML/JSON when debugging to make sure no missing node types