diff options
author | Gabe Black <gabeblack@google.com> | 2018-10-06 00:10:20 -0700 |
---|---|---|
committer | Gabe Black <gabeblack@google.com> | 2018-10-16 01:00:42 +0000 |
commit | 05f2a5f4f67c6d6b71497a0b6c75faf728f963f6 (patch) | |
tree | 9901e11e6fcefc25d8f4b4e09957e3ee12b69a76 /src/systemc/ext/core | |
parent | e9b366922b6b2dcb9e36bfa87eb58aefc3e138fb (diff) | |
download | gem5-05f2a5f4f67c6d6b71497a0b6c75faf728f963f6.tar.xz |
systemc: Distinguish internal events from normal sc_events.
The internal events aren't supposed to show up in the namespace or as
children of objects.
Change-Id: Id04b9bfe2e1f8f216390dd989797558eaf33d715
Reviewed-on: https://gem5-review.googlesource.com/c/13309
Reviewed-by: Gabe Black <gabeblack@google.com>
Maintainer: Gabe Black <gabeblack@google.com>
Diffstat (limited to 'src/systemc/ext/core')
-rw-r--r-- | src/systemc/ext/core/sc_event.hh | 19 | ||||
-rw-r--r-- | src/systemc/ext/core/sc_join.hh | 2 |
2 files changed, 19 insertions, 2 deletions
diff --git a/src/systemc/ext/core/sc_event.hh b/src/systemc/ext/core/sc_event.hh index 90c1911ca..90fd41f2a 100644 --- a/src/systemc/ext/core/sc_event.hh +++ b/src/systemc/ext/core/sc_event.hh @@ -45,6 +45,7 @@ namespace sc_gem5 class Event; class DynamicSensitivityEventAndList; class DynamicSensitivityEventOrList; +class InternalScEvent; } @@ -196,6 +197,10 @@ class sc_event sc_event_or_expr operator | (const sc_event &) const; sc_event_or_expr operator | (const sc_event_or_list &) const; + protected: + explicit sc_event(bool); + explicit sc_event(bool, const char *); + private: // Disabled sc_event(const sc_event &) {} @@ -235,7 +240,7 @@ class sc_event_finder_t : public sc_event_finder const sc_event & find_event(sc_interface *if_p=NULL) const override { - static const sc_event none; + static const sc_gem5::InternalScEvent none; const IF *iface = if_p ? dynamic_cast<const IF *>(if_p) : dynamic_cast<const IF *>(_port->get_interface()); if (!iface) { @@ -258,4 +263,16 @@ sc_event *sc_find_event(const char *); } // namespace sc_core +namespace sc_gem5 +{ + +class InternalScEvent : public ::sc_core::sc_event +{ + public: + InternalScEvent(); + InternalScEvent(const char *); +}; + +} // namespace sc_gem5 + #endif //__SYSTEMC_EXT_CORE_SC_INTERFACE_HH__ diff --git a/src/systemc/ext/core/sc_join.hh b/src/systemc/ext/core/sc_join.hh index 49e54ceee..3b227d311 100644 --- a/src/systemc/ext/core/sc_join.hh +++ b/src/systemc/ext/core/sc_join.hh @@ -52,7 +52,7 @@ class sc_join void wait_clocked(); private: - sc_event joinEvent; + sc_gem5::InternalScEvent joinEvent; int remaining; }; |