This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug tree-optimization/30317] New: VRP cannot extract a range from (unsigned int) i + 0x0ffffffff > 4


fold and VRP interact badly if we have a range test like

if (i > 0 && i <=5)
  ...

as we fold that to

if ((unsigned int) i + 0x0ffffffff > 4)
  ...

for which VRP fails to extract a range for i.  If we write the
range test so that fold doesn't see it, VRP is happy:

if (i > 0)
  if (i <= 5)
    ...


-- 
           Summary: VRP cannot extract a range from (unsigned int) i +
                    0x0ffffffff > 4
           Product: gcc
           Version: 4.3.0
            Status: UNCONFIRMED
          Keywords: missed-optimization
          Severity: normal
          Priority: P3
         Component: tree-optimization
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: rguenth at gcc dot gnu dot org


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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]