------- Comment #2 from pinskia at gcc dot gnu dot org 2007-05-07 02:36 ------- > 1) Hoists a register containing 0 out of the loop The correct thing to do. >2) Uses that *only* as a copy into another register (mov reg, #0 costs exactly the same as mov reg, reg) Interesting, but this is also true on ppc where I reported the original problem.
> 3) By doing the above, somehow prevents the post-increment sequence from being found. This might be the true issue. But is this a regression from 4.1 where loop.c would actually move this invariant? -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31849