mirror of https://github.com/YosysHQ/yosys.git
Decoding of a few more AST nodes in dumpVlog
This commit is contained in:
parent
a32d9b6c45
commit
88d9e213cb
|
@ -488,6 +488,20 @@ void AstNode::dumpVlog(FILE *f, std::string indent) const
|
||||||
fprintf(f, ";\n");
|
fprintf(f, ";\n");
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
if (0) { case AST_MEMRD: txt = "@memrd@"; }
|
||||||
|
if (0) { case AST_MEMINIT: txt = "@meminit@"; }
|
||||||
|
if (0) { case AST_MEMWR: txt = "@memwr@"; }
|
||||||
|
fprintf(f, "%s%s", indent.c_str(), txt.c_str());
|
||||||
|
for (auto child : children) {
|
||||||
|
fprintf(f, first ? "(" : ", ");
|
||||||
|
child->dumpVlog(f, "");
|
||||||
|
first = false;
|
||||||
|
}
|
||||||
|
fprintf(f, ")");
|
||||||
|
if (type != AST_MEMRD)
|
||||||
|
fprintf(f, ";\n");
|
||||||
|
break;
|
||||||
|
|
||||||
case AST_RANGE:
|
case AST_RANGE:
|
||||||
if (range_valid) {
|
if (range_valid) {
|
||||||
if (range_swapped)
|
if (range_swapped)
|
||||||
|
@ -556,6 +570,12 @@ void AstNode::dumpVlog(FILE *f, std::string indent) const
|
||||||
child->dumpVlog(f, "");
|
child->dumpVlog(f, "");
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
case AST_STRUCT:
|
||||||
|
case AST_UNION:
|
||||||
|
case AST_STRUCT_ITEM:
|
||||||
|
fprintf(f, "%s", id2vl(str).c_str());
|
||||||
|
break;
|
||||||
|
|
||||||
case AST_CONSTANT:
|
case AST_CONSTANT:
|
||||||
if (!str.empty())
|
if (!str.empty())
|
||||||
fprintf(f, "\"%s\"", str.c_str());
|
fprintf(f, "\"%s\"", str.c_str());
|
||||||
|
|
Loading…
Reference in New Issue