This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[patch]: Stop printing uids in error messages
- From: Daniel Berlin <dberlin at dberlin dot org>
- To: gcc-patches at gcc dot gnu dot org
- Cc: Diego Novillo <dnovillo at redhat dot com>
- Date: Tue, 21 Sep 2004 11:59:38 -0400
- Subject: [patch]: Stop printing uids in error messages
Currently, our error messages use debug_generic_stmt, which includes
TDF_UIDS in it's options by default.
This makes our error messages look like this:
../../gccWork/gcc/libgcov.c: In function '__gcov_init':
../../gccWork/gcc/libgcov.c:460: warning: 'gcov_list.71' is used
uninitialized in this function
../../gccWork/gcc/libgcov.c:433: error: Expected an SSA_NAME object
while verifying SSA_NAME gcov_crc32.70 in statement
# VUSE <gcov_crc32D.4782>;
gcov_crc32.70D.5327 = gcov_crc32D.4782;
Which is incredibly ugly, since no variable named gcov_crc32D.4782
exists.
The attached patch changes the places printing error messages to use
print_generic_stmt (stderr, ..., TDF_VOPS).
IMHO, they should be specifically printing to stderr anyway, instead of
using debug_generic_stmt, and thus, changing them to use
print_generic_stmt is TRT anyway.
Whether debug_generic_stmt should include TDF_UID in it's default
options, and whether TDF_UID should be printing uids when things have
names, are somewhat separate issues (though if we reach consensus, i'm
happy to fix those too).
Bootstrapped and regtested on i686-pc-linux-gnu.
Okay for mainline?
Attachment:
ssaerrormessages.diff
Description: Binary data