diff options
author | Gabe Black <gabeblack@google.com> | 2018-10-07 00:42:04 -0700 |
---|---|---|
committer | Gabe Black <gabeblack@google.com> | 2018-10-16 01:09:20 +0000 |
commit | 4e951d414e1ffc8e17aa4935b2a6421f4fbc1e22 (patch) | |
tree | 55d5b77cfea540ecbc52f7ff4191619ad45edd49 /src/systemc/core/scheduler.cc | |
parent | 208704b23a9f95f80fb49b3bfce4bccffd128060 (diff) | |
download | gem5-4e951d414e1ffc8e17aa4935b2a6421f4fbc1e22.tar.xz |
systemc: Switch to using predefined messages for core.
Create and use predefined messages for core which match the ones
Accellera uses.
Change-Id: I05b1398933f753946d5917f39d0f39c7cb45ed9f
Reviewed-on: https://gem5-review.googlesource.com/c/13323
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.cc | 17 |
1 files changed, 10 insertions, 7 deletions
diff --git a/src/systemc/core/scheduler.cc b/src/systemc/core/scheduler.cc index 969e40155..ec91c795a 100644 --- a/src/systemc/core/scheduler.cc +++ b/src/systemc/core/scheduler.cc @@ -33,6 +33,7 @@ #include "base/logging.hh" #include "sim/eventq.hh" #include "systemc/core/kernel.hh" +#include "systemc/ext/core/messages.hh" #include "systemc/ext/core/sc_main.hh" #include "systemc/ext/utils/sc_report.hh" #include "systemc/ext/utils/sc_report_handler.hh" @@ -112,10 +113,8 @@ Scheduler::initPhase() if (p->dontInitialize()) { if (!p->hasStaticSensitivities() && !p->internal()) { - SC_REPORT_WARNING( - "(W558) disable() or dont_initialize() called on " - "process with no static sensitivity, it will be " - "orphaned", p->name()); + SC_REPORT_WARNING(sc_core::SC_ID_DISABLE_WILL_ORPHAN_PROCESS_, + p->name()); } } else { p->ready(); @@ -484,11 +483,15 @@ reportifyException() } catch (const ::sc_core::sc_unwind_exception &) { panic("Kill/reset exception escaped a Process::run()"); } catch (const std::exception &e) { - SC_REPORT_ERROR("uncaught exception", e.what()); + SC_REPORT_ERROR( + sc_core::SC_ID_SIMULATION_UNCAUGHT_EXCEPTION_, e.what()); } catch (const char *msg) { - SC_REPORT_ERROR("uncaught exception", msg); + SC_REPORT_ERROR( + sc_core::SC_ID_SIMULATION_UNCAUGHT_EXCEPTION_, msg); } catch (...) { - SC_REPORT_ERROR("uncaught exception", "UNKNOWN EXCEPTION"); + SC_REPORT_ERROR( + sc_core::SC_ID_SIMULATION_UNCAUGHT_EXCEPTION_, + "UNKNOWN EXCEPTION"); } } catch (const ::sc_core::sc_report &r) { ::sc_core::sc_report_handler::set_handler(old_handler); |