summaryrefslogtreecommitdiff
path: root/src/systemc/tests
diff options
context:
space:
mode:
authorGabe Black <gabeblack@google.com>2018-10-07 05:23:49 -0700
committerGabe Black <gabeblack@google.com>2018-10-16 01:12:58 +0000
commite07f7efb75f0f7322d752608eb1cb1e1145b4a98 (patch)
treec70d86ba3130636fd8c6ff3c0d159727b81932c8 /src/systemc/tests
parent3420f0e223888bf70cd502efb5a534e651891b5c (diff)
downloadgem5-e07f7efb75f0f7322d752608eb1cb1e1145b4a98.tar.xz
systemc: Switch to using predefined messages for channels.
Create and use predefined messages for channels which match the ones Accellera uses. Change-Id: I179214838bbd83604e50225926cdc6b5b1b16923 Reviewed-on: https://gem5-review.googlesource.com/c/13330 Reviewed-by: Gabe Black <gabeblack@google.com> Maintainer: Gabe Black <gabeblack@google.com>
Diffstat (limited to 'src/systemc/tests')
-rw-r--r--src/systemc/tests/include/specialized_signals/scx_signal_int.h12
-rw-r--r--src/systemc/tests/include/specialized_signals/scx_signal_signed.h21
-rw-r--r--src/systemc/tests/include/specialized_signals/scx_signal_uint.h12
-rw-r--r--src/systemc/tests/include/specialized_signals/scx_signal_unsigned.h21
-rw-r--r--src/systemc/tests/systemc/communication/sc_signal/check_writer/test16/expected_returncode1
5 files changed, 22 insertions, 45 deletions
diff --git a/src/systemc/tests/include/specialized_signals/scx_signal_int.h b/src/systemc/tests/include/specialized_signals/scx_signal_int.h
index 050521de0..b853acd18 100644
--- a/src/systemc/tests/include/specialized_signals/scx_signal_int.h
+++ b/src/systemc/tests/include/specialized_signals/scx_signal_int.h
@@ -1556,26 +1556,22 @@ sc_vpool<sc_int_sigref> sc_int_sigref::m_pool(8);
sc_dt::sc_int_base* sc_int_part_if::part_read_target()
{
- SC_REPORT_ERROR( "attempted specalized signal operation on "
- "non-specialized signal", "int" );
+ SC_REPORT_ERROR( SC_ID_OPERATION_ON_NON_SPECIALIZED_SIGNAL_, "int" );
return 0;
}
sc_dt::uint64 sc_int_part_if::read_part( int /*left*/, int /*right*/ ) const
{
- SC_REPORT_ERROR( "attempted specalized signal operation on "
- "non-specialized signal", "int" );
+ SC_REPORT_ERROR( SC_ID_OPERATION_ON_NON_SPECIALIZED_SIGNAL_, "int" );
return 0;
}
sc_int_sigref& sc_int_part_if::select_part( int /*left*/, int /*right*/ )
{
- SC_REPORT_ERROR( "attempted specalized signal operation on "
- "non-specialized signal", "int" );
+ SC_REPORT_ERROR( SC_ID_OPERATION_ON_NON_SPECIALIZED_SIGNAL_, "int" );
return *(sc_int_sigref*)0;
}
void sc_int_part_if::write_part( sc_dt::uint64 v, int /*left*/, int /*right*/ )
{
- SC_REPORT_ERROR( "attempted specalized signal operation on "
- "non-specialized signal", "int" );
+ SC_REPORT_ERROR( SC_ID_OPERATION_ON_NON_SPECIALIZED_SIGNAL_, "int" );
}
diff --git a/src/systemc/tests/include/specialized_signals/scx_signal_signed.h b/src/systemc/tests/include/specialized_signals/scx_signal_signed.h
index bb48cecb3..baa6dd9ac 100644
--- a/src/systemc/tests/include/specialized_signals/scx_signal_signed.h
+++ b/src/systemc/tests/include/specialized_signals/scx_signal_signed.h
@@ -1744,43 +1744,36 @@ sc_vpool<sc_signed_sigref> sc_signed_sigref::m_pool(8);
sc_signed* sc_signed_part_if::part_read_target()
{
- SC_REPORT_ERROR( "attempted specalized signal operation on "
- "non-specialized signal", "int" );
+ SC_REPORT_ERROR( SC_ID_OPERATION_ON_NON_SPECIALIZED_SIGNAL_, "int" );
return 0;
}
sc_signed sc_signed_part_if::read_part( int /*left*/, int /*right*/ ) const
{
- SC_REPORT_ERROR( "attempted specalized signal operation on "
- "non-specialized signal", "int" );
+ SC_REPORT_ERROR( SC_ID_OPERATION_ON_NON_SPECIALIZED_SIGNAL_, "int" );
return sc_signed(1);
}
sc_signed_sigref& sc_signed_part_if::select_part( int /*left*/, int /*right*/ )
{
- SC_REPORT_ERROR( "attempted specalized signal operation on "
- "non-specialized signal", "int" );
+ SC_REPORT_ERROR( SC_ID_OPERATION_ON_NON_SPECIALIZED_SIGNAL_, "int" );
return *(sc_signed_sigref*)0;
}
void sc_signed_part_if::write_part( int64 v, int /*left*/, int /*right*/ )
{
- SC_REPORT_ERROR( "attempted specalized signal operation on "
- "non-specialized signal", "int" );
+ SC_REPORT_ERROR( SC_ID_OPERATION_ON_NON_SPECIALIZED_SIGNAL_, "int" );
}
void sc_signed_part_if::write_part( uint64 v, int /*left*/, int /*right*/ )
{
- SC_REPORT_ERROR( "attempted specalized signal operation on "
- "non-specialized signal", "int" );
+ SC_REPORT_ERROR( SC_ID_OPERATION_ON_NON_SPECIALIZED_SIGNAL_, "int" );
}
void sc_signed_part_if::write_part(
const sc_signed& v, int /*left*/, int /*right*/ )
{
- SC_REPORT_ERROR( "attempted specalized signal operation on "
- "non-specialized signal", "int" );
+ SC_REPORT_ERROR( SC_ID_OPERATION_ON_NON_SPECIALIZED_SIGNAL_, "int" );
}
void sc_signed_part_if::write_part(
const sc_unsigned& v, int /*left*/, int /*right*/ )
{
- SC_REPORT_ERROR( "attempted specalized signal operation on "
- "non-specialized signal", "int" );
+ SC_REPORT_ERROR( SC_ID_OPERATION_ON_NON_SPECIALIZED_SIGNAL_, "int" );
}
diff --git a/src/systemc/tests/include/specialized_signals/scx_signal_uint.h b/src/systemc/tests/include/specialized_signals/scx_signal_uint.h
index acc4a4219..a0ad01b45 100644
--- a/src/systemc/tests/include/specialized_signals/scx_signal_uint.h
+++ b/src/systemc/tests/include/specialized_signals/scx_signal_uint.h
@@ -1604,26 +1604,22 @@ sc_vpool<sc_uint_sigref> sc_uint_sigref::m_pool(8);
sc_dt::sc_uint_base* sc_uint_part_if::part_read_target()
{
- SC_REPORT_ERROR( "attempted specalized signal operation on "
- "non-specialized signal", "int" );
+ SC_REPORT_ERROR( SC_ID_OPERATION_ON_NON_SPECIALIZED_SIGNAL_, "int" );
return 0;
}
sc_dt::uint64 sc_uint_part_if::read_part( int /*left*/, int /*right*/ ) const
{
- SC_REPORT_ERROR( "attempted specalized signal operation on "
- "non-specialized signal", "int" );
+ SC_REPORT_ERROR( SC_ID_OPERATION_ON_NON_SPECIALIZED_SIGNAL_, "int" );
return 0;
}
sc_uint_sigref& sc_uint_part_if::select_part( int /*left*/, int /*right*/ )
{
- SC_REPORT_ERROR( "attempted specalized signal operation on "
- "non-specialized signal", "int" );
+ SC_REPORT_ERROR( SC_ID_OPERATION_ON_NON_SPECIALIZED_SIGNAL_, "int" );
return *(sc_uint_sigref*)0;
}
void sc_uint_part_if::write_part( sc_dt::uint64 v, int /*left*/, int /*right*/ )
{
- SC_REPORT_ERROR( "attempted specalized signal operation on "
- "non-specialized signal", "int" );
+ SC_REPORT_ERROR( SC_ID_OPERATION_ON_NON_SPECIALIZED_SIGNAL_, "int" );
}
//------------------------------------------------------------------------------
diff --git a/src/systemc/tests/include/specialized_signals/scx_signal_unsigned.h b/src/systemc/tests/include/specialized_signals/scx_signal_unsigned.h
index a356d44bd..7cfc409c1 100644
--- a/src/systemc/tests/include/specialized_signals/scx_signal_unsigned.h
+++ b/src/systemc/tests/include/specialized_signals/scx_signal_unsigned.h
@@ -1743,43 +1743,36 @@ sc_vpool<sc_unsigned_sigref> sc_unsigned_sigref::m_pool(8);
//------------------------------------------------------------------------------
sc_dt::sc_unsigned* sc_unsigned_part_if::part_read_target()
{
- SC_REPORT_ERROR( "attempted specalized signal operation on "
- "non-specialized signal", "int" );
+ SC_REPORT_ERROR( SC_ID_OPERATION_ON_NON_SPECIALIZED_SIGNAL_, "int" );
return 0;
}
sc_dt::sc_unsigned sc_unsigned_part_if::read_part( int /*left*/, int /*right*/ ) const
{
- SC_REPORT_ERROR( "attempted specalized signal operation on "
- "non-specialized signal", "int" );
+ SC_REPORT_ERROR( SC_ID_OPERATION_ON_NON_SPECIALIZED_SIGNAL_, "int" );
return sc_dt::sc_unsigned(1);
}
sc_unsigned_sigref& sc_unsigned_part_if::select_part(int /*left*/, int /*right*/)
{
- SC_REPORT_ERROR( "attempted specalized signal operation on "
- "non-specialized signal", "int" );
+ SC_REPORT_ERROR( SC_ID_OPERATION_ON_NON_SPECIALIZED_SIGNAL_, "int" );
return *(sc_unsigned_sigref*)0;
}
void sc_unsigned_part_if::write_part( sc_dt::int64 v, int /*left*/, int /*right*/ )
{
- SC_REPORT_ERROR( "attempted specalized signal operation on "
- "non-specialized signal", "int" );
+ SC_REPORT_ERROR( SC_ID_OPERATION_ON_NON_SPECIALIZED_SIGNAL_, "int" );
}
void sc_unsigned_part_if::write_part( sc_dt::uint64 v, int /*left*/, int /*right*/ )
{
- SC_REPORT_ERROR( "attempted specalized signal operation on "
- "non-specialized signal", "int" );
+ SC_REPORT_ERROR( SC_ID_OPERATION_ON_NON_SPECIALIZED_SIGNAL_, "int" );
}
void sc_unsigned_part_if::write_part(
const sc_dt::sc_signed& v, int /*left*/, int /*right*/ )
{
- SC_REPORT_ERROR( "attempted specalized signal operation on "
- "non-specialized signal", "int" );
+ SC_REPORT_ERROR( SC_ID_OPERATION_ON_NON_SPECIALIZED_SIGNAL_, "int" );
}
void sc_unsigned_part_if::write_part(
const sc_dt::sc_unsigned& v, int /*left*/, int /*right*/ )
{
- SC_REPORT_ERROR( "attempted specalized signal operation on "
- "non-specialized signal", "int" );
+ SC_REPORT_ERROR( SC_ID_OPERATION_ON_NON_SPECIALIZED_SIGNAL_, "int" );
}
diff --git a/src/systemc/tests/systemc/communication/sc_signal/check_writer/test16/expected_returncode b/src/systemc/tests/systemc/communication/sc_signal/check_writer/test16/expected_returncode
deleted file mode 100644
index d00491fd7..000000000
--- a/src/systemc/tests/systemc/communication/sc_signal/check_writer/test16/expected_returncode
+++ /dev/null
@@ -1 +0,0 @@
-1