llvm-6502/test/CodeGen
Chris Lattner d1980a5acd Move 3 "(add (select cc, 0, c), x) -> (select cc, x, (add, x, c))"
related transformations out of target-specific dag combine into the
ARM backend.  These were added by Evan in r37685 with no testcases
and only seems to help ARM (e.g. test/CodeGen/ARM/select_xform.ll).

Add some simple X86-specific (for now) DAG combines that turn things
like cond ? 8 : 0  -> (zext(cond) << 3).  This happens frequently
with the recently added cp constant select optimization, but is a
very general xform.  For example, we now compile the second example
in const-select.ll to:

_test:
        movsd   LCPI2_0, %xmm0
        ucomisd 8(%esp), %xmm0
        seta    %al
        movzbl  %al, %eax
        movl    4(%esp), %ecx
        movsbl  (%ecx,%eax,4), %eax
        ret

instead of:

_test:
        movl    4(%esp), %eax
        leal    4(%eax), %ecx
        movsd   LCPI2_0, %xmm0
        ucomisd 8(%esp), %xmm0
        cmovbe  %eax, %ecx
        movsbl  (%ecx), %eax
        ret

This passes multisource and dejagnu.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66779 91177308-0d34-0410-b5e6-96231b3b80d8
2009-03-12 06:52:53 +00:00
..
Alpha Fix Alpha test and support for private linkage. 2009-01-15 21:51:46 +00:00
ARM add no-unwind, remove duplicate run line. 2009-03-12 05:56:37 +00:00
CBackend
CellSPU Used "-enable-unsafe-fp-math" to allow this transformation - (a * b -c) = c - a *b. 2009-01-31 06:50:54 +00:00
CPP
Generic wire up support for emitting "special" values from inline asm 2009-03-10 05:37:13 +00:00
IA64 Add the private linkage. 2009-01-15 20:18:42 +00:00
Mips Add the private linkage. 2009-01-15 20:18:42 +00:00
PowerPC Private linkage support for PPC / Darwin. 2009-01-25 06:32:01 +00:00
SPARC Add the private linkage. 2009-01-15 20:18:42 +00:00
X86 Move 3 "(add (select cc, 0, c), x) -> (select cc, x, (add, x, c))" 2009-03-12 06:52:53 +00:00
XCore Add the private linkage. 2009-01-15 20:18:42 +00:00