changeset 130e19359857 in /z/repo/m5
details: http://repo.m5sim.org/m5?cmd=changeset;node=130e19359857
description:
        Trace: Add DPRINTFS macro that takes parameter to call name() for trace 
printing.

diffstat:

1 file changed, 7 insertions(+)
src/base/trace.hh |    7 +++++++

diffs (24 lines):

diff -r bab3cc975012 -r 130e19359857 src/base/trace.hh
--- a/src/base/trace.hh Fri Jan 23 17:19:47 2009 -0500
+++ b/src/base/trace.hh Fri Jan 23 17:19:48 2009 -0500
@@ -97,6 +97,12 @@
         Trace::dprintf(curTick, name(), __VA_ARGS__);           \
 } while (0)
 
+#define DPRINTFS(x,s, ...) do {                                    \
+    if (DTRACE(x))                                              \
+        Trace::dprintf(curTick, s->name(), __VA_ARGS__);           \
+} while (0)
+
+
 #define DPRINTFR(x, ...) do {                                   \
     if (DTRACE(x))                                              \
         Trace::dprintf((Tick)-1, std::string(), __VA_ARGS__);   \
@@ -119,6 +125,7 @@
 #define DTRACE(x) (false)
 #define DDUMP(x, data, count) do {} while (0)
 #define DPRINTF(x, ...) do {} while (0)
+#define DPRINTFS(x, ...) do {} while (0)
 #define DPRINTFR(...) do {} while (0)
 #define DDUMPN(data, count) do {} while (0)
 #define DPRINTFN(...) do {} while (0)
_______________________________________________
m5-dev mailing list
[email protected]
http://m5sim.org/mailman/listinfo/m5-dev

Reply via email to