Gabe Black has submitted this change and it was merged. ( https://gem5-review.googlesource.com/c/public/gem5/+/12057 )

Change subject: systemc: Ensure the terminated event is notified in all cases.
......................................................................

systemc: Ensure the terminated event is notified in all cases.

The terminated event was being notified if a process was killed, but
not if it was terminated in other ways. This change moves the
notification into the helper which sets termination related state.

Change-Id: I10aa5ad25875db992c8408dc60f087efc76b336b
Reviewed-on: https://gem5-review.googlesource.com/12057
Reviewed-by: Gabe Black <[email protected]>
Maintainer: Gabe Black <[email protected]>
---
M src/systemc/core/process.cc
1 file changed, 2 insertions(+), 2 deletions(-)

Approvals:
  Gabe Black: Looks good to me, approved; Looks good to me, approved



diff --git a/src/systemc/core/process.cc b/src/systemc/core/process.cc
index a54d5c2..ef1cea6 100644
--- a/src/systemc/core/process.cc
+++ b/src/systemc/core/process.cc
@@ -220,8 +220,6 @@
     // Inject the kill exception into this process if it's started.
     if (!_needsStart)
         injectException(killException);
-
-    _terminatedEvent.notify();
 }

 void
@@ -384,6 +382,8 @@
     for (auto s: staticSensitivities)
         delete s;
     staticSensitivities.clear();
+
+    _terminatedEvent.notify();
 }

 Process *Process::_newest;

--
To view, visit https://gem5-review.googlesource.com/c/public/gem5/+/12057
To unsubscribe, or for help writing mail filters, visit https://gem5-review.googlesource.com/settings

Gerrit-Project: public/gem5
Gerrit-Branch: master
Gerrit-Change-Id: I10aa5ad25875db992c8408dc60f087efc76b336b
Gerrit-Change-Number: 12057
Gerrit-PatchSet: 9
Gerrit-Owner: Gabe Black <[email protected]>
Gerrit-Reviewer: Andreas Sandberg <[email protected]>
Gerrit-Reviewer: Gabe Black <[email protected]>
Gerrit-Reviewer: Jason Lowe-Power <[email protected]>
Gerrit-Reviewer: Matthias Jung <[email protected]>
Gerrit-MessageType: merged
_______________________________________________
gem5-dev mailing list
[email protected]
http://m5sim.org/mailman/listinfo/gem5-dev

Reply via email to