llvm/lib
Chris Lattner 599ded1a7f Eliminate useless insertelement instructions. This implements
Transforms/InstCombine/vec_insertelt.ll and fixes PR1286.

We now compile the code from that bug into:

_foo:
        movl 4(%esp), %eax
        movdqa (%eax), %xmm0
        movl 8(%esp), %ecx
        psllw (%ecx), %xmm0
        movdqa %xmm0, (%eax)
        ret

instead of:

_foo:
        subl $4, %esp
        movl %ebp, (%esp)
        movl %esp, %ebp
        movl 12(%ebp), %eax
        movdqa (%eax), %xmm0
        #IMPLICIT_DEF %eax
        pinsrw $2, %eax, %xmm0
        xorl %ecx, %ecx
        pinsrw $3, %ecx, %xmm0
        pinsrw $4, %eax, %xmm0
        pinsrw $5, %ecx, %xmm0
        pinsrw $6, %eax, %xmm0
        pinsrw $7, %ecx, %xmm0
        movl 8(%ebp), %eax
        movdqa (%eax), %xmm1
        psllw %xmm0, %xmm1
        movdqa %xmm1, (%eax)
        movl %ebp, %esp
        popl %ebp
        ret

woo :)


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@35788 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-09 01:11:16 +00:00
..
Analysis Eliminate unnecessary APInt construction. 2007-04-07 17:48:27 +00:00
Archive Avoid a useless temporary constrution. 2007-04-07 19:51:45 +00:00
AsmParser For PR1289: Regenerate 2007-03-30 01:37:39 +00:00
Bytecode No functional change, this is just easier to read and debug. 2007-04-08 23:58:41 +00:00
CodeGen Fix CodeGen/Generic/2007-04-08-MultipleFrameIndices.ll and PR1308: 2007-04-09 00:46:10 +00:00
Debugger Make sure temporary data is not used past its life span. 2007-04-08 20:10:14 +00:00
ExecutionEngine For PR1293: 2007-03-30 16:41:50 +00:00
Linker For PR1302: 2007-04-04 06:44:18 +00:00
Support For PR1291: 2007-04-07 18:53:16 +00:00
System Unbreak VC++ build. 2007-04-07 20:47:27 +00:00
Target Squelch a warning about mismatch between sign of constant and sign of return 2007-04-04 22:07:24 +00:00
Transforms Eliminate useless insertelement instructions. This implements 2007-04-09 01:11:16 +00:00
VMCore Remove DomSet completely. This concludes work on PR1171. 2007-04-08 21:30:05 +00:00
Makefile Changes to support making the shift instructions be true BinaryOperators. 2007-02-02 02:16:23 +00:00