[Bug c/58236] -Wuninitialized doesn't report uninitialised variable as expected
manu at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Thu Oct 31 00:50:00 GMT 2013
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58236
Manuel López-Ibáñez <manu at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |manu at gcc dot gnu.org
Resolution|WONTFIX |DUPLICATE
--- Comment #4 from Manuel López-Ibáñez <manu at gcc dot gnu.org> ---
(In reply to Noufal Ibrahim from comment #2)
> That solves the issue although I find the relationship between the
> optimisations and the warnings somewhat tenuous atleast from a user
> perspective. Would it not be a good idea to have this warning even by
> default?
You can find a very detailed description of the problems involved at:
http://gcc.gnu.org/wiki/Better_Uninitialized_Warnings#Current_Situation
The relationship is easy to explain:
* More precise warnings require more expensive analysis
* The expensive analysis are only done when optimizations are enabled
* So you get more precise warnings when enabling more optimizations.
There are some ideas in that page on how to tackle these issues, but nothing is
sure to work reliably and all of them require considerable effort and time.
Until someone very determined steps up to the challenge, there will be little
progress.
*** This bug has been marked as a duplicate of bug 43361 ***
More information about the Gcc-bugs
mailing list