aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/System/Program.cpp
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2005-01-09 20:09:57 +0000
committerChris Lattner <sabre@nondot.org>2005-01-09 20:09:57 +0000
commit3d5d5022d577786bc8b09f6c55ac32bc3f6e1251 (patch)
tree14b5f8e34fc933fe310dee942e4acdc77008c438 /llvm/lib/System/Program.cpp
parent66d34302368c5a0c53da7e9fb851e1c319ea6cbc (diff)
downloadllvm-3d5d5022d577786bc8b09f6c55ac32bc3f6e1251.zip
llvm-3d5d5022d577786bc8b09f6c55ac32bc3f6e1251.tar.gz
llvm-3d5d5022d577786bc8b09f6c55ac32bc3f6e1251.tar.bz2
Add a simple transformation. This allows us to compile one of the inner
loops in stepanov to this: .LBB_Z5test0PdS__2: # no_exit.1 fldl data(,%eax,8) fldl 24(%esp) faddp %st(1) fstl 24(%esp) incl %eax cmpl $2000, %eax fstpl 16(%esp) #FP_REG_KILL jl .LBB_Z5test0PdS__2 instead of this: .LBB_Z5test0PdS__2: # no_exit.1 fldl data(,%eax,8) fldl 24(%esp) faddp %st(1) fstl 24(%esp) incl %eax movl $data, %ecx movl %ecx, %edx addl $16000, %edx subl %ecx, %edx movl %edx, %ecx sarl $2, %ecx shrl $29, %ecx addl %ecx, %edx sarl $3, %edx cmpl %edx, %eax fstpl 16(%esp) #FP_REG_KILL jl .LBB_Z5test0PdS__2 The old instruction selector produced: .LBB_Z5test0PdS__2: # no_exit.1 fldl 24(%esp) faddl data(,%eax,8) fstl 24(%esp) movl %eax, %ecx incl %ecx incl %eax leal data+16000, %edx movl $data, %edi subl %edi, %edx movl %edx, %edi sarl $2, %edi shrl $29, %edi addl %edi, %edx sarl $3, %edx cmpl %edx, %ecx fstpl 16(%esp) #FP_REG_KILL jl .LBB_Z5test0PdS__2 # no_exit.1 Which is even worse! llvm-svn: 19419
Diffstat (limited to 'llvm/lib/System/Program.cpp')
0 files changed, 0 insertions, 0 deletions