diff options
author | Robert Ellison <[email protected]> | 2008-09-23 10:09:36 -0600 |
---|---|---|
committer | Robert Ellison <[email protected]> | 2008-09-23 10:09:36 -0600 |
commit | 6901d6ef24224c27e20c3e864d035db1552aeeb8 (patch) | |
tree | 39d261c4fd42a27503ea04604cfa8bea3cdab071 /src/gallium/auxiliary/util | |
parent | 6642380841b8cc0d166bf1c6a76be786e1c50825 (diff) |
CELL: improve legibility of CELL_DEBUG environment variable output
Diffstat (limited to 'src/gallium/auxiliary/util')
-rw-r--r-- | src/gallium/auxiliary/util/p_debug.c | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/src/gallium/auxiliary/util/p_debug.c b/src/gallium/auxiliary/util/p_debug.c index b6cff281e6d..3ed8bdfdf33 100644 --- a/src/gallium/auxiliary/util/p_debug.c +++ b/src/gallium/auxiliary/util/p_debug.c @@ -306,6 +306,13 @@ debug_get_flags_option(const char *name, str = _debug_get_option(name); if(!str) result = dfault; + else if (!util_strcmp(str, "help")) { + result = dfault; + while (flags->name) { + debug_printf("%s: help for %s: %s [0x%lx]\n", __FUNCTION__, name, flags->name, flags->value); + flags++; + } + } else { result = 0; while( flags->name ) { @@ -315,7 +322,12 @@ debug_get_flags_option(const char *name, } } - debug_printf("%s: %s = 0x%lx\n", __FUNCTION__, name, result); + if (str) { + debug_printf("%s: %s = 0x%lx (%s)\n", __FUNCTION__, name, result, str); + } + else { + debug_printf("%s: %s = 0x%lx\n", __FUNCTION__, name, result); + } return result; } |