|
From: Nicholas N. <n.n...@gm...> - 2009-08-22 00:49:58
|
Hi, I've been thinking about Valgrind's output, in relation to these two bugs: http://bugs.kde.org/show_bug.cgi?id=203255 http://bugs.kde.org/show_bug.cgi?id=204713 Here's a summary of a proposal. -------- Aim is to make Valgrind output more consistent and understandable for the user. We'll end up with various categories of messages: - Prefix-less messages: very few - Usage messages (-h) - --gen-suppressions=yes output (for easy cut+paste) - anything else that needs to be cut+pasted - "==pid==" messages: stuff that's useful to the user, about their program, or that they requested - preamble + postamble - tool error messages - '-q' turns some of these off (eg. preamble/postamble) - '-v' turns some of these on (eg. postamble suppression summary) - "--pid--" messages: diagnostics about Valgrind's execution - always shown, even with -q - aborts: bad options, startup problems, unknown instructions - warnings: emulation warnings, unknown syscalls - "++pid++" messages: debugging messages, only useful to developers - shown with -d or -d -d - --stats=yes - --trace-XYZ=yes and similar ones - all via debuglog (so hard-wired to stderr) - "**pid**" messages: user-requested messages - VALGRIND_PRINTF - VALGRIND_PRINTF_BACKTRACE -------- I haven't thought much about XML yet, but hopefully the stuff we produce via XML matches the "==pid==" category pretty closely, and "--pid--" and "++pid++" messages won't end up in XML. Any thoughts? I think it'll help users, because if they don't understand a message at least they'll know what it pertains to (eg. their program vs. Valgrind itself). And debugging info is cleanly segregated. And currently a lot of messages don't have a prefix, so if the prefix is added at least it's clear that it comes from Valgrind. I think I'll start a branch for this. N |