http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56574



Richard Biener <rguenth at gcc dot gnu.org> changed:



           What    |Removed                     |Added

----------------------------------------------------------------------------

           Keywords|                            |diagnostic, wrong-code

             Status|UNCONFIRMED                 |NEW

   Last reconfirmed|                            |2013-03-11

     Ever Confirmed|0                           |1



--- Comment #5 from Richard Biener <rguenth at gcc dot gnu.org> 2013-03-11 
10:43:45 UTC ---

ISO C99 6.5.13 says that 'value' is not evaluated when !flag is false.  But

clearly we are not considering the "side-effect" of using an uninitialized

variable when deciding to output straight-line code sequences.



Affected are at least gimple SSA if-combine and eventually fold and

gimplification (I didn't check them).



Ok, for this testcase it is fold that ends up producing a TRUTH_AND_EXPR.



For SSA if-combine we should only linearize the code if all inner block

SSA (or memory - ugh) uses in



  if (...)

   {

     <here>

     if (...)

      {

...



have a dominating definition.

Reply via email to