diff options
author | Gabe Black <gabeblack@google.com> | 2018-09-05 19:28:44 -0700 |
---|---|---|
committer | Gabe Black <gabeblack@google.com> | 2018-10-09 21:38:23 +0000 |
commit | 5ed90fffb6bdbbd5fe2316687faff05f641d6692 (patch) | |
tree | 842b96779ee67fec12d7ba48a017791b02cf117d /src/systemc/core/sc_spawn.cc | |
parent | dee485ff6779ef81b8d26c68041ded4065fb1402 (diff) | |
download | gem5-5ed90fffb6bdbbd5fe2316687faff05f641d6692.tar.xz |
systemc: Warn if a process is dont_initialize with no static sensitivieis.
Change-Id: I4db64f42872a6fb459faa401abdad3f168297347
Reviewed-on: https://gem5-review.googlesource.com/c/12599
Reviewed-by: Gabe Black <gabeblack@google.com>
Maintainer: Gabe Black <gabeblack@google.com>
Diffstat (limited to 'src/systemc/core/sc_spawn.cc')
-rw-r--r-- | src/systemc/core/sc_spawn.cc | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/systemc/core/sc_spawn.cc b/src/systemc/core/sc_spawn.cc index b0570a663..00fe502e6 100644 --- a/src/systemc/core/sc_spawn.cc +++ b/src/systemc/core/sc_spawn.cc @@ -83,6 +83,16 @@ spawnWork(ProcessFuncWrapper *func, const char *name, proc->addStatic(new PendingSensitivityFinder(proc, f)); } + if (opts && opts->_dontInitialize && + opts->_events.empty() && opts->_ports.empty() && + opts->_exports.empty() && opts->_interfaces.empty() && + opts->_finders.empty()) { + SC_REPORT_WARNING( + "(W558) disable() or dont_initialize() called on process " + "with no static sensitivity, it will be orphaned", + proc->name()); + } + scheduler.reg(proc); if (dontInitialize) |