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/46675] [4.6 Regression] profiledbootstrap failed


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

--- Comment #16 from H.J. Lu <hjl.tools at gmail dot com> 2010-11-28 16:10:08 UTC ---
--
void
foo (int n)
{
  int npairs, i;
  npairs = n - (-__INT_MAX__ - 1);

  if (npairs > 0)
    for (i = 0; i < npairs; i++)
      j++;
}
--

is miscompiled.  But

--
void
foo (int n)
{
  int npairs, i;
  npairs = n - -2147483648;

  if (npairs > 0)
    for (i = 0; i < npairs; i++)
      j++;
}
--

isn't.


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