1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-26 04:32:44 +01:00
llvm-mirror/lib
Chris Lattner d7ef6d6774 Significantly simplify this code and make it more aggressive. Instead of having
a special case hack for X86, make the hack more general: if an incoming argument
register is not used in any block other than the entry block, don't copy it to
a vreg.  This helps us compile code like this:

%struct.foo = type { int, int, [0 x ubyte] }
int %test(%struct.foo* %X) {
        %tmp1 = getelementptr %struct.foo* %X, int 0, uint 2, int 100
        %tmp = load ubyte* %tmp1                ; <ubyte> [#uses=1]
        %tmp2 = cast ubyte %tmp to int          ; <int> [#uses=1]
        ret int %tmp2
}

to:

_test:
        lbz r3, 108(r3)
        blr

instead of:

_test:
        lbz r2, 108(r3)
        or r3, r2, r2
        blr

The (dead) copy emitted to copy r3 into a vreg for extra-block uses was
increasing the live range of r3 past the load, preventing the coallescing.

This implements CodeGen/PowerPC/reg-coallesce-simple.ll

llvm-svn: 24115
2005-10-30 19:42:35 +00:00
..
Analysis Fix a problem that Nate noticed with LSR: 2005-10-30 06:24:33 +00:00
AsmParser When a function takes a variable number of pointer arguments, with a zero 2005-10-23 04:37:20 +00:00
Bytecode DONT_BUILD_RELINKED is gone and implied by BUILD_ARCHIVE now 2005-10-24 02:26:13 +00:00
CodeGen Significantly simplify this code and make it more aggressive. Instead of having 2005-10-30 19:42:35 +00:00
Debugger When a function takes a variable number of pointer arguments, with a zero 2005-10-23 04:37:20 +00:00
ExecutionEngine Fix a nasty bug that was causing miscompilation of global variables 2005-10-23 23:54:56 +00:00
Linker DONT_BUILD_RELINKED is gone and implied by BUILD_ARCHIVE now 2005-10-24 02:26:13 +00:00
Support DONT_BUILD_RELINKED is gone and implied by BUILD_ARCHIVE now 2005-10-24 02:26:13 +00:00
System DONT_BUILD_RELINKED is gone and implied by BUILD_ARCHIVE now 2005-10-24 02:26:13 +00:00
Target If the module has no t-t and the host is an alpha, default to using the Alpha BE 2005-10-30 16:44:01 +00:00
Transforms This pass is now obsolete since all targets have moved to the SelectionDAG 2005-10-29 05:33:46 +00:00
VMCore Allow $ 2005-10-14 01:28:34 +00:00
Makefile