On 25 July 2015 at 00:17, Patrick Palka <patr...@parcs.ath.cx> wrote: > On Fri, Jul 24, 2015 at 5:55 PM, Manuel López-Ibáñez > <lopeziba...@gmail.com> wrote: > Is there a PR for this particular test case? I am interested in > improving the uninit analysis for gcc 6 so this potentially seems up > my alley.
We do not warn because of the infamous PR18501 (probably the -Wuninitialized bug with the highest number of duplicates), where CPP removes the default SSA definition of n and simply returns 1 unconditionally. But fixing PR18501 may not be necessary to detect this case (Clang does it before doing any optimization). There are other cases that would be better warned from the FE: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=19808 Cheers, Manuel. .