[gem5-dev] Change in gem5/gem5[master]: systemc: Add support for deprecated integer report handler ids.

2018-08-21 Thread Gabe Black (Gerrit)
Gabe Black has submitted this change and it was merged. (  
https://gem5-review.googlesource.com/c/public/gem5/+/11256 )


Change subject: systemc: Add support for deprecated integer report handler  
ids.

..

systemc: Add support for deprecated integer report handler ids.

These are deprecated but still used in the regression tests.

Change-Id: Id59cf950fbe0530a6cdce20a256d450b243f12d3
Reviewed-on: https://gem5-review.googlesource.com/11256
Reviewed-by: Gabe Black 
Maintainer: Gabe Black 
---
M src/systemc/ext/utils/sc_report.hh
M src/systemc/ext/utils/sc_report_handler.hh
M src/systemc/utils/sc_report.cc
M src/systemc/utils/sc_report_handler.cc
4 files changed, 72 insertions(+), 0 deletions(-)

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



diff --git a/src/systemc/ext/utils/sc_report.hh  
b/src/systemc/ext/utils/sc_report.hh

index 9ba2b33..f0ed14f 100644
--- a/src/systemc/ext/utils/sc_report.hh
+++ b/src/systemc/ext/utils/sc_report.hh
@@ -74,6 +74,16 @@
 const char *get_process_name() const;

 virtual const char *what() const throw();
+
+// Deprecated
+static const char *get_message(int id);
+static bool is_suppressed(int id);
+static void make_warnings_errors(bool);
+static void register_id(int id, const char *msg);
+static void suppress_id(int id, bool); // Only for info or warning.
+static void suppress_infos(bool);
+static void suppress_warnings(bool);
+int get_id() const;
 };

 // A non-standard function the Accellera datatypes rely on.
diff --git a/src/systemc/ext/utils/sc_report_handler.hh  
b/src/systemc/ext/utils/sc_report_handler.hh

index d0eea77..6101e2b 100644
--- a/src/systemc/ext/utils/sc_report_handler.hh
+++ b/src/systemc/ext/utils/sc_report_handler.hh
@@ -68,6 +68,10 @@
 static void report(sc_severity, const char *msg_type, const char *msg,
int verbosity, const char *file, int line);

+// Deprecated
+static void report(sc_severity, int id, const char *msg, const char  
*file,

+   int line);
+
 static sc_actions set_actions(sc_severity, sc_actions=SC_UNSPECIFIED);
 static sc_actions set_actions(const char *msg_type,
   sc_actions=SC_UNSPECIFIED);
diff --git a/src/systemc/utils/sc_report.cc b/src/systemc/utils/sc_report.cc
index 0e6b8b0..6edbf2a 100644
--- a/src/systemc/utils/sc_report.cc
+++ b/src/systemc/utils/sc_report.cc
@@ -110,6 +110,57 @@
 return "";
 }

+const char *
+sc_report::get_message(int id)
+{
+warn("%s not implemented.\n", __PRETTY_FUNCTION__);
+return "";
+}
+
+bool
+sc_report::is_suppressed(int id)
+{
+warn("%s not implemented.\n", __PRETTY_FUNCTION__);
+return false;
+}
+
+void
+sc_report::make_warnings_errors(bool)
+{
+warn("%s not implemented.\n", __PRETTY_FUNCTION__);
+}
+
+void
+sc_report::register_id(int id, const char *msg)
+{
+warn("%s not implemented.\n", __PRETTY_FUNCTION__);
+}
+
+void
+sc_report::suppress_id(int id, bool)
+{
+warn("%s not implemented.\n", __PRETTY_FUNCTION__);
+}
+
+void
+sc_report::suppress_infos(bool)
+{
+warn("%s not implemented.\n", __PRETTY_FUNCTION__);
+}
+
+void
+sc_report::suppress_warnings(bool)
+{
+warn("%s not implemented.\n", __PRETTY_FUNCTION__);
+}
+
+int
+sc_report::get_id() const
+{
+warn("%s not implemented.\n", __PRETTY_FUNCTION__);
+return 0;
+}
+
 void
 sc_abort()
 {
diff --git a/src/systemc/utils/sc_report_handler.cc  
b/src/systemc/utils/sc_report_handler.cc

index 3bb9050..319851b 100644
--- a/src/systemc/utils/sc_report_handler.cc
+++ b/src/systemc/utils/sc_report_handler.cc
@@ -47,6 +47,13 @@
 warn("%s not implemented.\n", __PRETTY_FUNCTION__);
 }

+void
+sc_report_handler::report(sc_severity, int id, const char *msg,
+  const char *file, int line)
+{
+warn("%s not implemented.\n", __PRETTY_FUNCTION__);
+}
+
 sc_actions
 sc_report_handler::set_actions(sc_severity, sc_actions)
 {

--
To view, visit https://gem5-review.googlesource.com/c/public/gem5/+/11256
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: Id59cf950fbe0530a6cdce20a256d450b243f12d3
Gerrit-Change-Number: 11256
Gerrit-PatchSet: 5
Gerrit-Owner: Gabe Black 
Gerrit-Reviewer: Andreas Sandberg 
Gerrit-Reviewer: Gabe Black 
Gerrit-Reviewer: Giacomo Travaglini 
Gerrit-Reviewer: Jason Lowe-Power 
Gerrit-Reviewer: Matthias Jung 
Gerrit-MessageType: merged
___
gem5-dev mailing list
gem5-dev@gem5.org
http://m5sim.org/mailman/listinfo/gem5-dev

[gem5-dev] Change in gem5/gem5[master]: systemc: Add support for deprecated integer report handler ids.

2018-06-16 Thread Gabe Black (Gerrit)
Gabe Black has uploaded this change for review. (  
https://gem5-review.googlesource.com/11256



Change subject: systemc: Add support for deprecated integer report handler  
ids.

..

systemc: Add support for deprecated integer report handler ids.

These are deprecated but still used in the regression tests.

Change-Id: Id59cf950fbe0530a6cdce20a256d450b243f12d3
---
M src/systemc/ext/utils/sc_report.hh
M src/systemc/ext/utils/sc_report_handler.hh
M src/systemc/utils/sc_report.cc
M src/systemc/utils/sc_report_handler.cc
4 files changed, 72 insertions(+), 0 deletions(-)



diff --git a/src/systemc/ext/utils/sc_report.hh  
b/src/systemc/ext/utils/sc_report.hh

index 9ba2b33..f0ed14f 100644
--- a/src/systemc/ext/utils/sc_report.hh
+++ b/src/systemc/ext/utils/sc_report.hh
@@ -74,6 +74,16 @@
 const char *get_process_name() const;

 virtual const char *what() const throw();
+
+// Deprecated
+static const char *get_message(int id);
+static bool is_suppressed(int id);
+static void make_warnings_errors(bool);
+static void register_id(int id, const char *msg);
+static void suppress_id(int id, bool); // Only for info or warning.
+static void suppress_infos(bool);
+static void suppress_warnings(bool);
+int get_id() const;
 };

 // A non-standard function the Accellera datatypes rely on.
diff --git a/src/systemc/ext/utils/sc_report_handler.hh  
b/src/systemc/ext/utils/sc_report_handler.hh

index d0eea77..6101e2b 100644
--- a/src/systemc/ext/utils/sc_report_handler.hh
+++ b/src/systemc/ext/utils/sc_report_handler.hh
@@ -68,6 +68,10 @@
 static void report(sc_severity, const char *msg_type, const char *msg,
int verbosity, const char *file, int line);

+// Deprecated
+static void report(sc_severity, int id, const char *msg, const char  
*file,

+   int line);
+
 static sc_actions set_actions(sc_severity, sc_actions=SC_UNSPECIFIED);
 static sc_actions set_actions(const char *msg_type,
   sc_actions=SC_UNSPECIFIED);
diff --git a/src/systemc/utils/sc_report.cc b/src/systemc/utils/sc_report.cc
index 0e6b8b0..6edbf2a 100644
--- a/src/systemc/utils/sc_report.cc
+++ b/src/systemc/utils/sc_report.cc
@@ -110,6 +110,57 @@
 return "";
 }

+const char *
+sc_report::get_message(int id)
+{
+warn("%s not implemented.\n", __PRETTY_FUNCTION__);
+return "";
+}
+
+bool
+sc_report::is_suppressed(int id)
+{
+warn("%s not implemented.\n", __PRETTY_FUNCTION__);
+return false;
+}
+
+void
+sc_report::make_warnings_errors(bool)
+{
+warn("%s not implemented.\n", __PRETTY_FUNCTION__);
+}
+
+void
+sc_report::register_id(int id, const char *msg)
+{
+warn("%s not implemented.\n", __PRETTY_FUNCTION__);
+}
+
+void
+sc_report::suppress_id(int id, bool)
+{
+warn("%s not implemented.\n", __PRETTY_FUNCTION__);
+}
+
+void
+sc_report::suppress_infos(bool)
+{
+warn("%s not implemented.\n", __PRETTY_FUNCTION__);
+}
+
+void
+sc_report::suppress_warnings(bool)
+{
+warn("%s not implemented.\n", __PRETTY_FUNCTION__);
+}
+
+int
+sc_report::get_id() const
+{
+warn("%s not implemented.\n", __PRETTY_FUNCTION__);
+return 0;
+}
+
 void
 sc_abort()
 {
diff --git a/src/systemc/utils/sc_report_handler.cc  
b/src/systemc/utils/sc_report_handler.cc

index 3bb9050..319851b 100644
--- a/src/systemc/utils/sc_report_handler.cc
+++ b/src/systemc/utils/sc_report_handler.cc
@@ -47,6 +47,13 @@
 warn("%s not implemented.\n", __PRETTY_FUNCTION__);
 }

+void
+sc_report_handler::report(sc_severity, int id, const char *msg,
+  const char *file, int line)
+{
+warn("%s not implemented.\n", __PRETTY_FUNCTION__);
+}
+
 sc_actions
 sc_report_handler::set_actions(sc_severity, sc_actions)
 {

--
To view, visit https://gem5-review.googlesource.com/11256
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: Id59cf950fbe0530a6cdce20a256d450b243f12d3
Gerrit-Change-Number: 11256
Gerrit-PatchSet: 1
Gerrit-Owner: Gabe Black 
Gerrit-MessageType: newchange
___
gem5-dev mailing list
gem5-dev@gem5.org
http://m5sim.org/mailman/listinfo/gem5-dev