process->satisfySensitivity(this);
}
+bool
+Sensitivity::notifyWork(Event *e)
+{
+ satisfy();
+ return true;
+}
+
bool
Sensitivity::notify(Event *e)
{
+ if (scheduler.current() == process) {
+ static bool warned = false;
+ if (!warned) {
+ SC_REPORT_WARNING("(W536) immediate self-notification ignored "
+ "as of IEEE 1666-2011", process->name());
+ warned = true;
+ }
+ return false;
+ }
+
if (process->disabled())
return false;
- satisfy();
- return true;
+
+ return notifyWork(e);
}
bool
{}
bool
-DynamicSensitivityEventOrList::notify(Event *e)
+DynamicSensitivityEventOrList::notifyWork(Event *e)
{
- if (process->disabled())
- return false;
-
events.erase(e->sc_event());
// All the other events need this deleted from their lists since this
{}
bool
-DynamicSensitivityEventAndList::notify(Event *e)
+DynamicSensitivityEventAndList::notifyWork(Event *e)
{
- if (process->disabled())
- return false;
-
events.erase(e->sc_event());
// This sensitivity is satisfied if all events have triggered.
virtual void clear() = 0;
void satisfy();
- virtual bool notify(Event *e);
+ virtual bool notifyWork(Event *e);
+ bool notify(Event *e);
enum Category
{
DynamicSensitivityEventOrList(
Process *p, const sc_core::sc_event_or_list *eol);
- bool notify(Event *e) override;
+ bool notifyWork(Event *e) override;
};
//XXX This sensitivity can't be reused. To reset it, it has to be deleted and
DynamicSensitivityEventAndList(
Process *p, const sc_core::sc_event_and_list *eal);
- bool notify(Event *e) override;
+ bool notifyWork(Event *e) override;
};
} // namespace sc_gem5