http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51182
--- Comment #1 from Matt Hargett <matt at use dot net> 2011-11-16 23:09:22 UTC --- I see the same seeming no-op register and instruction twiddles with inflate.c from zlib, as well. Adding more iterations has a kind of ping-pong effect where it goes between the two different versions. diff inflate.o.-O3.ipa-iterations2.dump inflate.o.-O3.ipa-iterations3.dump2c2 < inflate.o.-O3.ipa-iterations2: file format elf64-x86-64 --- > inflate.o.-O3.ipa-iterations3: file format elf64-x86-64 897,898c897,898 < d22: 31 db xor %ebx,%ebx < d24: 45 31 d2 xor %r10d,%r10d --- > d22: 45 31 d2 xor %r10d,%r10d > d25: 31 db xor %ebx,%ebx 1731c1731 < 19a9: 44 39 c7 cmp %r8d,%edi --- > 19a9: 41 39 f8 cmp %edi,%r8d 2192,2193c2192,2193 < 20e0: 45 31 d2 xor %r10d,%r10d < 20e3: 31 db xor %ebx,%ebx --- > 20e0: 31 db xor %ebx,%ebx > 20e2: 45 31 d2 xor %r10d,%r10d