systemc: Stop using the Accellera specific "none" global event object.
authorGabe Black <gabeblack@google.com>
Thu, 3 Jan 2019 06:14:23 +0000 (22:14 -0800)
committerGabe Black <gabeblack@google.com>
Wed, 9 Jan 2019 01:35:37 +0000 (01:35 +0000)
That event being available is nonstandard. Define our own static event
for use in that case.

Change-Id: I5e8892bd83cc1984d63949ef3e249755dca0c702
Reviewed-on: https://gem5-review.googlesource.com/c/15296
Reviewed-by: Anthony Gutierrez <anthony.gutierrez@amd.com>
Maintainer: Anthony Gutierrez <anthony.gutierrez@amd.com>

src/systemc/ext/tlm_core/1/req_rsp/ports/event_finder.hh

index 2e411ebad3d95f113a2f1f705441581e6ed916fa..cdf2d8b58ec033014f0791e3c5cee20c0bcb9316 100644 (file)
@@ -56,9 +56,10 @@ tlm_event_finder_t<IF, T>::find_event(sc_core::sc_interface *if_p) const
 {
     const IF *iface = if_p ? dynamic_cast<const IF *>(if_p) :
         dynamic_cast<const IF *>(port()->_gem5Interface(0));
+    static sc_core::sc_event none;
     if (iface == nullptr) {
         report_error(sc_core::SC_ID_FIND_EVENT_, "port is not bound");
-        return sc_core::sc_event::none;
+        return none;
     }
     return (const_cast<IF *>(iface)->*m_event_method)(nullptr);
 }