Variable initialization blocks should be unamed.

Also add file/line info to initial process.
This commit is contained in:
Martin Whitaker 2016-03-19 14:21:10 +00:00
parent 54feb89bf5
commit 72bb63cf42
1 changed files with 4 additions and 1 deletions

View File

@ -5951,7 +5951,7 @@ bool LexicalScope::elaborate_var_inits_(Design*des, NetScope*scope) const
if (var_inits.size() == 1) {
proc = var_inits[0]->elaborate(des, scope);
} else {
NetBlock*blk = new NetBlock(NetBlock::SEQU, scope);
NetBlock*blk = new NetBlock(NetBlock::SEQU, 0);
bool flag = true;
for (unsigned idx = 0; idx < var_inits.size(); idx += 1) {
NetProc*tmp = var_inits[idx]->elaborate(des, scope);
@ -5966,6 +5966,9 @@ bool LexicalScope::elaborate_var_inits_(Design*des, NetScope*scope) const
return false;
NetProcTop*top = new NetProcTop(scope, IVL_PR_INITIAL, proc);
if (const LineInfo*li = dynamic_cast<const LineInfo*>(this)) {
top->set_line(*li);
}
if (gn_system_verilog()) {
top->attribute(perm_string::literal("_ivl_schedule_init"),
verinum(1));