diff options
author | Gabe Black <gabeblack@google.com> | 2018-10-08 19:01:38 -0700 |
---|---|---|
committer | Gabe Black <gabeblack@google.com> | 2018-10-16 01:13:23 +0000 |
commit | c9f83ec94ba1d7de0cfc46a9a23af2f9e04450e8 (patch) | |
tree | 4993ca5a6892b108ae1bc040a23366ef326f190b /src/systemc/ext/dt/bit/sc_proxy.hh | |
parent | e07f7efb75f0f7322d752608eb1cb1e1145b4a98 (diff) | |
download | gem5-c9f83ec94ba1d7de0cfc46a9a23af2f9e04450e8.tar.xz |
systemc: Switch to using predefined messages for datatypes.
Create and use predefined messages for datatypes which match the ones
Accellera uses.
Change-Id: I92dd52f62462b864264217bb81f3ff1dcec020bf
Reviewed-on: https://gem5-review.googlesource.com/c/13331
Reviewed-by: Gabe Black <gabeblack@google.com>
Maintainer: Gabe Black <gabeblack@google.com>
Diffstat (limited to 'src/systemc/ext/dt/bit/sc_proxy.hh')
-rw-r--r-- | src/systemc/ext/dt/bit/sc_proxy.hh | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/src/systemc/ext/dt/bit/sc_proxy.hh b/src/systemc/ext/dt/bit/sc_proxy.hh index 12e10725a..c20813926 100644 --- a/src/systemc/ext/dt/bit/sc_proxy.hh +++ b/src/systemc/ext/dt/bit/sc_proxy.hh @@ -68,6 +68,7 @@ #include "../int/sc_signed.hh" #include "../int/sc_uint_base.hh" #include "../int/sc_unsigned.hh" +#include "messages.hh" #include "sc_bit.hh" #include "sc_logic.hh" @@ -1261,7 +1262,7 @@ sc_proxy<X>::to_anything_unsigned() const const X &x = back_cast(); int len = x.length(); if (x.get_cword(0) != SC_DIGIT_ZERO) { - SC_REPORT_WARNING("vector contains 4-value logic", 0); + SC_REPORT_WARNING(sc_core::SC_ID_VECTOR_CONTAINS_LOGIC_VALUE_, 0); } sc_digit w = x.get_word(0); if (len >= SC_DIGIT_SIZE) { @@ -1279,12 +1280,12 @@ sc_proxy<X>::to_uint64() const const X &x = back_cast(); int len = x.length(); if (x.get_cword(0) != SC_DIGIT_ZERO) { - SC_REPORT_WARNING("vector contains 4-value logic", 0); + SC_REPORT_WARNING(sc_core::SC_ID_VECTOR_CONTAINS_LOGIC_VALUE_, 0); } uint64 w = x.get_word(0); if (len > SC_DIGIT_SIZE) { if (x.get_cword(1) != SC_DIGIT_ZERO) { - SC_REPORT_WARNING("vector contains 4-value logic", 0); + SC_REPORT_WARNING(sc_core::SC_ID_VECTOR_CONTAINS_LOGIC_VALUE_, 0); } uint64 w1 = x.get_word(1); w = w | (w1 << SC_DIGIT_SIZE); @@ -1306,11 +1307,11 @@ sc_proxy<X>::to_anything_signed() const if (len > SC_DIGIT_SIZE) { if (x.get_cword(1) != SC_DIGIT_ZERO) - SC_REPORT_WARNING("vector contains 4-value logic", 0); + SC_REPORT_WARNING(sc_core::SC_ID_VECTOR_CONTAINS_LOGIC_VALUE_, 0); w = x.get_word(1); } if (x.get_cword(0) != SC_DIGIT_ZERO) - SC_REPORT_WARNING("vector contains 4-value logic", 0); + SC_REPORT_WARNING(sc_core::SC_ID_VECTOR_CONTAINS_LOGIC_VALUE_, 0); w = (w << SC_DIGIT_SIZE) | x.get_word(0); if (len >= 64) { return w; |