Mesa (gallium-0.1): trace: Make call no global.
Jose Fonseca
jrfonseca at kemper.freedesktop.org
Wed May 20 15:33:05 UTC 2009
Module: Mesa
Branch: gallium-0.1
Commit: a8af5ff7cf86476573f5cdc34d3976b56880e74d
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=a8af5ff7cf86476573f5cdc34d3976b56880e74d
Author: José Fonseca <jfonseca at vmware.com>
Date: Wed Apr 8 15:41:08 2009 +0100
trace: Make call no global.
---
src/gallium/drivers/trace/tr_dump.c | 7 ++++---
1 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/src/gallium/drivers/trace/tr_dump.c b/src/gallium/drivers/trace/tr_dump.c
index 724c894..29bc54f 100644
--- a/src/gallium/drivers/trace/tr_dump.c
+++ b/src/gallium/drivers/trace/tr_dump.c
@@ -55,6 +55,7 @@
static struct util_stream *stream = NULL;
static unsigned refcount = 0;
+static long unsigned call_no = 0;
static INLINE void
@@ -215,6 +216,7 @@ trace_dump_trace_close(void)
util_stream_close(stream);
stream = NULL;
refcount = 0;
+ call_no = 0;
}
}
@@ -262,11 +264,10 @@ void trace_dump_trace_end(void)
void trace_dump_call_begin(const char *klass, const char *method)
{
- static long unsigned no = 0;
- ++no;
+ ++call_no;
trace_dump_indent(1);
trace_dump_writes("<call no=\'");
- trace_dump_writef("%lu", no);
+ trace_dump_writef("%lu", call_no);
trace_dump_writes("\' class =\'");
trace_dump_escape(klass);
trace_dump_writes("\' method=\'");
More information about the mesa-commit
mailing list