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/81388] Incorrect code generation with -O1 -fno-strict-overflow


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81388

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |UNCONFIRMED
         Resolution|INVALID                     |---

--- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
void bar();
void foo(char *dst)
{
        char *const end = dst;
        do {
                bar();
                dst += 2;
        } while (dst < end);
}

Hmm actually I am backwards here.  end + 2 < end is always false.

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