[Bug tree-optimization/35609] [4.3/4.4 Regression] "is used uninitialized in this function" should be may warning
--- Comment #4 from rguenth at gcc dot gnu dot org 2008-03-19 10:45 --- Subject: Bug 35609 Author: rguenth Date: Wed Mar 19 10:44:52 2008 New Revision: 133341 URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=133341 Log: 2008-03-19 Richard Guenther <[EMAIL PROTECTED]> PR middle-end/35609 * tree-ssa.c (always_executed): New global flag. (warn_uninitialized_var): If !always_executed warn with "maybe" instead of "is". (execute_early_warn_uninitialized): Compute post-dominators. Initialize always_executed before processing each basic block. * gcc.dg/testsuite/uninit-15.c: New testcase. * gcc.dg/testsuite/uninit-16.c: Likewise. Added: trunk/gcc/testsuite/gcc.dg/uninit-15.c trunk/gcc/testsuite/gcc.dg/uninit-16.c Modified: trunk/gcc/ChangeLog trunk/gcc/testsuite/ChangeLog trunk/gcc/tree-ssa.c -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35609
[Bug tree-optimization/35609] [4.3/4.4 Regression] "is used uninitialized in this function" should be may warning
--- Comment #3 from rguenth at gcc dot gnu dot org 2008-03-18 16:53 --- While this is a regression the underlying problem was latent and thus this should be an enhacement report. But I'll have a look. -- rguenth at gcc dot gnu dot org changed: What|Removed |Added AssignedTo|unassigned at gcc dot gnu |rguenth at gcc dot gnu dot |dot org |org Severity|normal |enhancement Status|NEW |ASSIGNED Priority|P3 |P4 Last reconfirmed|2008-03-16 21:32:33 |2008-03-18 16:53:41 date|| http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35609
[Bug tree-optimization/35609] [4.3/4.4 Regression] "is used uninitialized in this function" should be may warning
--- Comment #2 from rguenth at gcc dot gnu dot org 2008-03-16 21:32 --- The warning works as designed, the PHI node in question that causes the warning only has a single incoming edge: testfunc () { int alt_reloc; int foo.0; : foo.0_1 = foo; if (foo.0_1 > 19) goto ; else goto ; : if (foo.0_1 > 9) goto ; else goto ; : if (alt_reloc_4(D) != 0) goto ; else goto ; : bar = 42; : return; } we don't check whether the uninitialized use post-dominates the function entry. I don't know if we should. This is just a case of 4.3 optimizing better than 4.2 which makes the warning less precise. -- rguenth at gcc dot gnu dot org changed: What|Removed |Added Status|UNCONFIRMED |NEW Ever Confirmed|0 |1 Last reconfirmed|-00-00 00:00:00 |2008-03-16 21:32:33 date|| http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35609
[Bug tree-optimization/35609] [4.3/4.4 Regression] "is used uninitialized in this function" should be may warning
--- Comment #1 from pinskia at gcc dot gnu dot org 2008-03-16 21:30 --- So Jump threading comes along and threads the jump for some reason makes the PHI node go away. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35609
[Bug tree-optimization/35609] [4.3/4.4 Regression] "is used uninitialized in this function" should be may warning
-- pinskia at gcc dot gnu dot org changed: What|Removed |Added Summary|[4.3/4.4 Regression] bogus |[4.3/4.4 Regression] "is |"is used uninitialized in |used uninitialized in this |this function" warning |function" should be may ||warning Target Milestone|--- |4.3.1 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35609