[PATCH] Quieten arch/powerpc in a allmodconfig build.
Scott Wood
scottwood at freescale.com
Sat Apr 11 04:03:35 EST 2009
Segher Boessenkool wrote:
>> Unfortunately -Wno-uninitialized also suppresses the warnings that point
>> to real bugs.
>
> It's a double-edged sword, yes. Warnings are always like that:
> if the compiler could know that something _is_ wrong for certain,
> it wouldn't need a warning (it would use an error, instead -- and
> it does do this in certain cases); if it would know something is
> not really wrong, it would just shut up.
The problem is that GCC does not give an error (only a warning) even for
things like this where it should be trivial to detect that the usage
*is* uninitialized, not just might be:
int foo(void)
{
int a;
return a;
}
And further, there is no separation of warning classes into
might-be-uninitialized and is-uninitialized-compiler-can-tell-for-sure.
In other words, there should be a way to tell the compiler to err on the
side of not complaining if it's unsure, but still report the obvious
ones (or make the latter an error but the former a warning). That's not
ESP or DWIM.
-Scott
More information about the Linuxppc-dev
mailing list