sim: Bail on processes

Instead of silently missimulating, error out when there are processes
found in the simulation hierarchy.
This commit is contained in:
Martin Povišer 2023-10-05 19:23:48 +02:00
parent a782b15aae
commit c3fd88624a
1 changed files with 4 additions and 0 deletions

View File

@ -222,6 +222,10 @@ struct SimInstance
log_error("Cannot simulate blackbox module %s (instantiated at %s).\n",
log_id(module->name), hiername().c_str());
if (module->has_processes())
log_error("Found processes in simulation hierarchy (in module %s at %s). Run 'proc' first.\n",
log_id(module), hiername().c_str());
if (parent) {
log_assert(parent->children.count(instance) == 0);
parent->children[instance] = this;