http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53925
Bug #: 53925
Summary: dbgcnt.c:dbg_cnt_set_limit_by_index emits diagnostic
via fprintf (stderr
Classification: Unclassified
Product: gcc
Version: 4.8.0
Status: UNCONFIRMED
Keywords: diagnostic
Severity: normal
Priority: P3
Component: other
AssignedTo: [email protected]
ReportedBy: [email protected]
There is this code in dbgcnt.c
static void
dbg_cnt_set_limit_by_index (enum debug_counter index, int value)
{
limit[index] = value;
fprintf (stderr, "dbg_cnt '%s' set to %d\n", map[index].name, value);
}
If the user specifies -fdbg-cnt= that will trigger a diagnostic output.
IMO setting an option should not emit a diagnose, except in the case when the
user explicitly requests so, e.g. by means of -dbg-cnt-list, -print-multi-lib,
etc.
The fprintf (stderr should be removed or print to a dump file.
== Command line to reproduce ==
echo | gcc -fdbg-cnt=dce:0 -x c - -c