summaryrefslogtreecommitdiff
path: root/src/systemc/core/scheduler.cc
diff options
context:
space:
mode:
authorGabe Black <gabeblack@google.com>2018-07-20 22:16:12 -0700
committerGabe Black <gabeblack@google.com>2018-09-11 21:46:48 +0000
commite27712b2d956d3a16372e5287b208335d7574684 (patch)
treee151ece343b7b3c0deec80b857303ed5009c4695 /src/systemc/core/scheduler.cc
parente58072108f137f28fa08c67602d165f53d4f03cf (diff)
downloadgem5-e27712b2d956d3a16372e5287b208335d7574684.tar.xz
systemc: Fill out process handle kill and reset mechanisms.
Some flags were being updated too early, making the functions think what they were about to do had already been done. Also, actually check for and throw the exception installed in a process when it's next supposed to run, and when injecting an exception schedule that other process to run immediately. Change-Id: I0856b69903699b2c66f9dc7f44942bbfe3cfdcc4 Reviewed-on: https://gem5-review.googlesource.com/12046 Reviewed-by: Gabe Black <gabeblack@google.com> Maintainer: Gabe Black <gabeblack@google.com>
Diffstat (limited to 'src/systemc/core/scheduler.cc')
-rw-r--r--src/systemc/core/scheduler.cc7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/systemc/core/scheduler.cc b/src/systemc/core/scheduler.cc
index c2b5ec38d..085602d7b 100644
--- a/src/systemc/core/scheduler.cc
+++ b/src/systemc/core/scheduler.cc
@@ -117,6 +117,13 @@ Scheduler::yield()
if (_current && _current->needsStart())
_current->run();
}
+ if (_current && _current->excWrapper) {
+ // Make sure this isn't a method process.
+ assert(!_current->needsStart());
+ auto ew = _current->excWrapper;
+ _current->excWrapper = nullptr;
+ ew->throw_it();
+ }
}
void