misc: Collapse all uses of DTRACE(x) to Debug::x.
Also mark the DTRACE macro as deprecated. Change-Id: I99d9a9544b539117b375186e3e425d73d3c5cab7 Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/45009 Tested-by: kokoro <noreply+kokoro@google.com> Maintainer: Gabe Black <gabe.black@gmail.com> Reviewed-by: Daniel Carvalho <odanrc@yahoo.com.br>
This commit is contained in:
@@ -152,7 +152,8 @@ void dumpDebugFlags(std::ostream &os=std::cout);
|
||||
* @ingroup api_trace
|
||||
* @{
|
||||
*/
|
||||
#define DTRACE(x) (Debug::x)
|
||||
#define DTRACE(x) GEM5_DEPRECATED_MACRO(DTRACE, Debug::x, \
|
||||
"Replace DTRACE(x) with Debug::x.")
|
||||
/** @} */ // end of api_trace
|
||||
|
||||
#endif // __BASE_DEBUG_HH__
|
||||
|
||||
@@ -682,8 +682,8 @@ BaseRemoteGDB::read(Addr vaddr, size_t size, char *data)
|
||||
proxy.readBlob(vaddr, data, size);
|
||||
|
||||
#if TRACING_ON
|
||||
if (DTRACE(GDBRead)) {
|
||||
if (DTRACE(GDBExtra)) {
|
||||
if (Debug::GDBRead) {
|
||||
if (Debug::GDBExtra) {
|
||||
char buf[1024];
|
||||
mem2hex(buf, data, size);
|
||||
DPRINTFNR(": %s\n", buf);
|
||||
@@ -699,9 +699,9 @@ BaseRemoteGDB::read(Addr vaddr, size_t size, char *data)
|
||||
bool
|
||||
BaseRemoteGDB::write(Addr vaddr, size_t size, const char *data)
|
||||
{
|
||||
if (DTRACE(GDBWrite)) {
|
||||
if (Debug::GDBWrite) {
|
||||
DPRINTFN("write: addr=%#x, size=%d", vaddr, size);
|
||||
if (DTRACE(GDBExtra)) {
|
||||
if (Debug::GDBExtra) {
|
||||
char buf[1024];
|
||||
mem2hex(buf, data, size);
|
||||
DPRINTFNR(": %s\n", buf);
|
||||
|
||||
@@ -66,7 +66,7 @@ Group::regStats()
|
||||
g->regStats();
|
||||
|
||||
for (auto &g : statGroups) {
|
||||
if (DTRACE(Stats)) {
|
||||
if (Debug::Stats) {
|
||||
M5_VAR_USED const SimObject *so =
|
||||
dynamic_cast<const SimObject *>(this);
|
||||
DPRINTF(Stats, "%s: regStats in group %s\n",
|
||||
|
||||
@@ -148,10 +148,10 @@ OstreamLogger::logMessage(Tick when, const std::string &name,
|
||||
if (!name.empty() && ignore.match(name))
|
||||
return;
|
||||
|
||||
if (!DTRACE(FmtTicksOff) && (when != MaxTick))
|
||||
if (!Debug::FmtTicksOff && (when != MaxTick))
|
||||
ccprintf(stream, "%7d: ", when);
|
||||
|
||||
if (DTRACE(FmtFlag) && !flag.empty())
|
||||
if (Debug::FmtFlag && !flag.empty())
|
||||
stream << flag << ": ";
|
||||
|
||||
if (!name.empty())
|
||||
@@ -160,7 +160,7 @@ OstreamLogger::logMessage(Tick when, const std::string &name,
|
||||
stream << message;
|
||||
stream.flush();
|
||||
|
||||
if (DTRACE(FmtStackTrace)) {
|
||||
if (Debug::FmtStackTrace) {
|
||||
print_backtrace();
|
||||
STATIC_ERR("\n");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user