------- Comment #7 from amonakov at gcc dot gnu dot org 2010-02-16 17:43 ------- (In reply to comment #6)
Looks like this has been fixed. We do generate good code: fred: li 0,100 mtctr 0 .L2: sthu 3,2(4) bdnz .L2 blr .size fred, .-fred .ident "GCC: (GNU) 4.5.0 20100215 (experimental)" And ivopts dump is quite sane: <bb 2>: ivtmp.13_17 = (unsigned int) out1_5(D); <bb 3>: # i_13 = PHI <i_3(4), 0(2)> # ivtmp.13_15 = PHI <ivtmp.13_16(4), ivtmp.13_17(2)> i_3 = i_13 + 1; ivtmp.13_16 = ivtmp.13_15 + 2; D.2031_18 = (void *) ivtmp.13_16; MEM[base: D.2031_18] = in_7(D); if (i_3 != 100) goto <bb 4>; else goto <bb 5>; <bb 4>: goto <bb 3>; -- amonakov at gcc dot gnu dot org changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |amonakov at gcc dot gnu dot | |org http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36905