diff options
author | Gabe Black <gabeblack@google.com> | 2018-09-10 22:01:47 -0700 |
---|---|---|
committer | Gabe Black <gabeblack@google.com> | 2018-10-09 21:45:46 +0000 |
commit | 960c3500532a0ca28e4192f838e81eeb7c29860c (patch) | |
tree | d69f9fca16de85245c1be592c64f54bc186e958d /src/systemc/core/process.hh | |
parent | c8d3cb5fadfac8ad90fd81edc707d83051b275da (diff) | |
download | gem5-960c3500532a0ca28e4192f838e81eeb7c29860c.tar.xz |
systemc: Implement SC_FORK, SC_JOIN, and SC_CJOIN.
SC_CJOIN is non-standard, but relied on by the Accellera tests.
Change-Id: Ia4ddcb1749a07891157a58398137e94fcaa8e815
Reviewed-on: https://gem5-review.googlesource.com/c/12615
Reviewed-by: Gabe Black <gabeblack@google.com>
Maintainer: Gabe Black <gabeblack@google.com>
Diffstat (limited to 'src/systemc/core/process.hh')
-rw-r--r-- | src/systemc/core/process.hh | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/systemc/core/process.hh b/src/systemc/core/process.hh index 4d88e27b8..d399d7a3d 100644 --- a/src/systemc/core/process.hh +++ b/src/systemc/core/process.hh @@ -49,6 +49,13 @@ #include "systemc/ext/core/sc_process_handle.hh" #include "systemc/ext/utils/sc_report.hh" +namespace sc_core +{ + +class sc_join; + +} // namespace sc_core + namespace sc_gem5 { @@ -347,6 +354,8 @@ class Process : public ::sc_core::sc_process_b, public ListNode bool dontInitialize() { return _dontInitialize; } void dontInitialize(bool di) { _dontInitialize = di; } + void joinWait(::sc_core::sc_join *join) { joinWaiters.push_back(join); } + protected: Process(const char *name, ProcessFuncWrapper *func, bool internal=false); @@ -396,6 +405,8 @@ class Process : public ::sc_core::sc_process_b, public ListNode Sensitivity *dynamicSensitivity; std::unique_ptr<::sc_core::sc_report> _lastReport; + + std::vector<::sc_core::sc_join *> joinWaiters; }; inline void |