[llvm-commits] [llvm] r127351 - in /llvm/trunk: lib/CodeGen/SimpleRegisterCoalescing.cpp test/CodeGen/X86/2011-03-09-Physreg-Coalescing.ll test/CodeGen/X86/fold-pcmpeqd-2.ll

NAKAMURA Takumi geek4civic at gmail.com
Wed Mar 16 06:47:15 PDT 2011


Hi Jakob,

> Author: stoklund
> Date: Wed Mar  9 13:27:06 2011
> New Revision: 127351
>
> URL: http://llvm.org/viewvc/llvm-project?rev=127351&view=rev
> Log:
> Make physreg coalescing independent on the number of uses of the virtual register.
>
> The damage done by physreg coalescing only depends on the number of instructions
> the extended physreg live range covers. This fixes PR9438.
>
> The heuristic is still luck-based, and physreg coalescing really should be
> disabled completely. We need a register allocator with better hinting support
> before that is possible.
>
> Convert a test to FileCheck and force spilling by inserting an extra call. The
> previous spilling behavior was dependent on misguided physreg coalescing
> decisions.

With r127351, X86/h-registers-1.ll is emitted differently on
-mtriple=x86_64-win32.
Is it expected or possible?

llc -mtriple=x86_64-win32 < ~/llvm/test/CodeGen/X86/h-registers-1.ll \
| grep 'movzbl.%[abcd]h' \
| wc -l

; w/o r127351
        movzbl  %ah, %esi
        movzbl  %ah, %eax
        movzbl  %ah, %edi
        movzbl  %bh, %ebx
        movzbl  %dh, %edx
        movzbl  %ah, %ebp
        movzbl  %ch, %eax
        movzbl  %ch, %ecx

; with r127351;
        movzbl  %ah, %eax
        movzbl  %ah, %eax
        movzbl  %ah, %ecx
        movzbl  %bh, %eax
        movzbl  %dh, %edx
        movzbl  %bh, %esi
        movzbl  15(%rsp), %edi          # 1-byte Folded Reload
        movzbl  %bh, %ebx


...Takumi


ps. I've got lv3 earthquake just now :/




More information about the llvm-commits mailing list