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/25985] [4.2 Regression] with optimization integer math fails



------- Comment #3 from pinskia at gcc dot gnu dot org  2006-03-15 18:40 -------
Hmm, if I change the function to be:
#include <stdio.h>

int main(void)
{
        int bits = 25;
        while (bits) {
                printf("bits=%d\n",bits);
                if (bits >= 8) {
                        bits -= 8;
                } else {
                        break;
                }

        }
        return 0;
}

And then compare 4.1 vs 4.2, I get the following observation:
in 4.1, it changed bits > 7 to use the iv, while in 4.2, it changed the bits !=
0 to use the iv


-- 


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


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