From 3e92388fd56170c6a7f828a1505e24314ec8bf4c Mon Sep 17 00:00:00 2001 From: Gabe Black Date: Tue, 2 Oct 2018 16:59:16 -0700 Subject: [PATCH] systemc: Make sure otherwise unnamed events get autogenerated ones. Change-Id: Iec4e0bd504e70d0096a4c90d5fbba9565dd0deed Reviewed-on: https://gem5-review.googlesource.com/c/13205 Reviewed-by: Gabe Black Maintainer: Gabe Black --- src/systemc/core/sc_event.cc | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/systemc/core/sc_event.cc b/src/systemc/core/sc_event.cc index 59581ee90..318fea624 100644 --- a/src/systemc/core/sc_event.cc +++ b/src/systemc/core/sc_event.cc @@ -30,6 +30,7 @@ #include "base/logging.hh" #include "systemc/core/event.hh" #include "systemc/ext/core/sc_event.hh" +#include "systemc/ext/core/sc_module.hh" namespace sc_core { @@ -311,7 +312,10 @@ operator | (sc_event_or_expr expr, sc_event_or_list const &eol) * sc_event */ -sc_event::sc_event() : _gem5_event(new ::sc_gem5::Event(this)) {} +sc_event::sc_event() : + _gem5_event(new ::sc_gem5::Event( + this, sc_core::sc_gen_unique_name("event"))) +{} sc_event::sc_event(const char *_name) : _gem5_event(new ::sc_gem5::Event(this, _name)) -- 2.30.2