base: Collapse the DTRACE macro in DPRINTF.
We've already checked if TRACING_ON is set, so we can just check the value of Debug::x directly. Change-Id: Ifcc183b9e56fd45a2c6278ab5739ae2fbe2b32c0 Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/45005 Tested-by: kokoro <noreply+kokoro@google.com> Maintainer: Gabe Black <gabe.black@gmail.com> Reviewed-by: Daniel Carvalho <odanrc@yahoo.com.br> Reviewed-by: Bobby R. Bruce <bbruce@ucdavis.edu>
This commit is contained in:
@@ -174,27 +174,27 @@ const std::string &name();
|
||||
*/
|
||||
|
||||
#define DDUMP(x, data, count) do { \
|
||||
if (M5_UNLIKELY(TRACING_ON && DTRACE(x))) \
|
||||
if (M5_UNLIKELY(TRACING_ON && Debug::x)) \
|
||||
Trace::getDebugLogger()->dump( \
|
||||
curTick(), name(), data, count, #x); \
|
||||
} while (0)
|
||||
|
||||
#define DPRINTF(x, ...) do { \
|
||||
if (M5_UNLIKELY(TRACING_ON && DTRACE(x))) { \
|
||||
if (M5_UNLIKELY(TRACING_ON && Debug::x)) { \
|
||||
Trace::getDebugLogger()->dprintf_flag( \
|
||||
curTick(), name(), #x, __VA_ARGS__); \
|
||||
} \
|
||||
} while (0)
|
||||
|
||||
#define DPRINTFS(x, s, ...) do { \
|
||||
if (M5_UNLIKELY(TRACING_ON && DTRACE(x))) { \
|
||||
if (M5_UNLIKELY(TRACING_ON && Debug::x)) { \
|
||||
Trace::getDebugLogger()->dprintf_flag( \
|
||||
curTick(), s->name(), #x, __VA_ARGS__); \
|
||||
} \
|
||||
} while (0)
|
||||
|
||||
#define DPRINTFR(x, ...) do { \
|
||||
if (M5_UNLIKELY(TRACING_ON && DTRACE(x))) { \
|
||||
if (M5_UNLIKELY(TRACING_ON && Debug::x)) { \
|
||||
Trace::getDebugLogger()->dprintf_flag( \
|
||||
(Tick)-1, std::string(), #x, __VA_ARGS__); \
|
||||
} \
|
||||
|
||||
Reference in New Issue
Block a user