summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target
Commit message (Collapse)AuthorAgeFilesLines
* Generalize BuildVectorSDNode::isConstantSplat to use APInts and handleBob Wilson2009-03-021-8/+11
| | | | | | | | arbitrary vector sizes. Add an optional MinSplatBits parameter to specify a minimum for the splat element size. Update the PPC target to use the revised interface. llvm-svn: 65899
* Combine PPC's GetConstantBuildVectorBits and isConstantSplat functions to a newBob Wilson2009-03-011-106/+5
| | | | | | method in a BuildVectorSDNode "pseudo-class". llvm-svn: 65747
* Added another darwin subtargetMon P Wang2009-02-281-0/+4
| | | | llvm-svn: 65662
* Refactor TLS code and add some tests. The tests and expected results are:Rafael Espindola2009-02-272-14/+47
| | | | | | | | | | | | | | | | | | | | | pic | declaration | linkage | visibility | !pic | declaration | external | default | tls1.ll tls2.ll | local exec pic | declaration | external | default | tls1-pic.ll tls2-pic.ll | general dynamic !pic | !declaration | external | default | tls3.ll tls4.ll | initial exec pic | !declaration | external | default | tls3-pic.ll tls4-pic.ll | general dynamic !pic | declaration | external | hidden | tls7.ll tls8.ll | local exec pic | declaration | external | hidden | X | local dynamic !pic | !declaration | external | hidden | tls9.ll tls10.ll | local exec pic | !declaration | external | hidden | X | local dynamic !pic | declaration | internal | default | tls5.ll tls6.ll | local exec pic | declaration | internal | default | X | local dynamic The ones marked with an X have not been implemented since local dynamic is not implemented. llvm-svn: 65632
* Alignment values for i64 and f64 on ppc64 were wrong,Dale Johannesen2009-02-271-1/+3
| | | | | | | | possibly for the reason suggested by the comment. No wonder it didn't work very well. This unblocks bootstrap with assertions on ppc. llvm-svn: 65601
* ADDS{D|S}rr_Int and MULS{D|S}rr_Int are not commutable. The users of these ↵Evan Cheng2009-02-261-8/+4
| | | | | | intrinsics expect the high bits will not be modified. llvm-svn: 65499
* Revert BuildVectorSDNode related patches: 65426, 65427, and 65296.Evan Cheng2009-02-254-105/+225
| | | | llvm-svn: 65482
* Add a totally synthetic situation I came up with while looking at a bug inNick Lewycky2009-02-251-0/+17
| | | | | | related code. llvm-svn: 65437
* Remove all "cached" data from BuildVectorSDNode, preferring to retrieveScott Michel2009-02-251-6/+6
| | | | | | | | | results via reference parameters. This patch also appears to fix Evan's reported problem supplied as a reduced bugpoint test case. llvm-svn: 65426
* Overhaul my earlier submission due to feedback. It's a large patch, but most ofBill Wendling2009-02-2437-125/+164
| | | | | | | | | | | | them are generic changes. - Use the "fast" flag that's already being passed into the asm printers instead of shoving it into the DwarfWriter. - Instead of calling "MI->getParent()->getParent()" for every MI, set the machine function when calling "runOnMachineFunction" in the asm printers. llvm-svn: 65379
* Fast-isel can't do TLS yet, so it should fall back to SDISelDan Gohman2009-02-231-0/+6
| | | | | | if it sees TLS addresses. llvm-svn: 65341
* Only v1i16 (i.e. _m64) is returned via RAX / RDX.Evan Cheng2009-02-233-19/+50
| | | | llvm-svn: 65313
* Generate better code for v8i16 shuffles on SSE2Nate Begeman2009-02-233-249/+360
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Generate better code for v16i8 shuffles on SSE2 (avoids stack) Generate pshufb for v8i16 and v16i8 shuffles on SSSE3 where it is fewer uops. Document the shuffle matching logic and add some FIXMEs for later further cleanups. New tests that test the above. Examples: New: _shuf2: pextrw $7, %xmm0, %eax punpcklqdq %xmm1, %xmm0 pshuflw $128, %xmm0, %xmm0 pinsrw $2, %eax, %xmm0 Old: _shuf2: pextrw $2, %xmm0, %eax pextrw $7, %xmm0, %ecx pinsrw $2, %ecx, %xmm0 pinsrw $3, %eax, %xmm0 movd %xmm1, %eax pinsrw $4, %eax, %xmm0 ret ========= New: _shuf4: punpcklqdq %xmm1, %xmm0 pshufb LCPI1_0, %xmm0 Old: _shuf4: pextrw $3, %xmm0, %eax movsd %xmm1, %xmm0 pextrw $3, %xmm1, %ecx pinsrw $4, %ecx, %xmm0 pinsrw $5, %eax, %xmm0 ======== New: _shuf1: pushl %ebx pushl %edi pushl %esi pextrw $1, %xmm0, %eax rolw $8, %ax movd %xmm0, %ecx rolw $8, %cx pextrw $5, %xmm0, %edx pextrw $4, %xmm0, %esi pextrw $3, %xmm0, %edi pextrw $2, %xmm0, %ebx movaps %xmm0, %xmm1 pinsrw $0, %ecx, %xmm1 pinsrw $1, %eax, %xmm1 rolw $8, %bx pinsrw $2, %ebx, %xmm1 rolw $8, %di pinsrw $3, %edi, %xmm1 rolw $8, %si pinsrw $4, %esi, %xmm1 rolw $8, %dx pinsrw $5, %edx, %xmm1 pextrw $7, %xmm0, %eax rolw $8, %ax movaps %xmm1, %xmm0 pinsrw $7, %eax, %xmm0 popl %esi popl %edi popl %ebx ret Old: _shuf1: subl $252, %esp movaps %xmm0, (%esp) movaps %xmm0, 16(%esp) movaps %xmm0, 32(%esp) movaps %xmm0, 48(%esp) movaps %xmm0, 64(%esp) movaps %xmm0, 80(%esp) movaps %xmm0, 96(%esp) movaps %xmm0, 224(%esp) movaps %xmm0, 208(%esp) movaps %xmm0, 192(%esp) movaps %xmm0, 176(%esp) movaps %xmm0, 160(%esp) movaps %xmm0, 144(%esp) movaps %xmm0, 128(%esp) movaps %xmm0, 112(%esp) movzbl 14(%esp), %eax movd %eax, %xmm1 movzbl 22(%esp), %eax movd %eax, %xmm2 punpcklbw %xmm1, %xmm2 movzbl 42(%esp), %eax movd %eax, %xmm1 movzbl 50(%esp), %eax movd %eax, %xmm3 punpcklbw %xmm1, %xmm3 punpcklbw %xmm2, %xmm3 movzbl 77(%esp), %eax movd %eax, %xmm1 movzbl 84(%esp), %eax movd %eax, %xmm2 punpcklbw %xmm1, %xmm2 movzbl 104(%esp), %eax movd %eax, %xmm1 punpcklbw %xmm1, %xmm0 punpcklbw %xmm2, %xmm0 movaps %xmm0, %xmm1 punpcklbw %xmm3, %xmm1 movzbl 127(%esp), %eax movd %eax, %xmm0 movzbl 135(%esp), %eax movd %eax, %xmm2 punpcklbw %xmm0, %xmm2 movzbl 155(%esp), %eax movd %eax, %xmm0 movzbl 163(%esp), %eax movd %eax, %xmm3 punpcklbw %xmm0, %xmm3 punpcklbw %xmm2, %xmm3 movzbl 188(%esp), %eax movd %eax, %xmm0 movzbl 197(%esp), %eax movd %eax, %xmm2 punpcklbw %xmm0, %xmm2 movzbl 217(%esp), %eax movd %eax, %xmm4 movzbl 225(%esp), %eax movd %eax, %xmm0 punpcklbw %xmm4, %xmm0 punpcklbw %xmm2, %xmm0 punpcklbw %xmm3, %xmm0 punpcklbw %xmm1, %xmm0 addl $252, %esp ret llvm-svn: 65311
* Propagate debug loc info through prologue/epilogue.Bill Wendling2009-02-237-28/+39
| | | | llvm-svn: 65298
* Introduce the BuildVectorSDNode class that encapsulates the ISD::BUILD_VECTORScott Michel2009-02-224-215/+100
| | | | | | | | | instruction. The class also consolidates the code for detecting constant splats that's shared across PowerPC and the CellSPU backends (and might be useful for other backends.) Also introduces SelectionDAG::getBUID_VECTOR() for generating new BUILD_VECTOR nodes. llvm-svn: 65296
* Add a note.Evan Cheng2009-02-221-0/+28
| | | | llvm-svn: 65275
* Be bug compatible with gcc by returning MMX values in RAX.Evan Cheng2009-02-222-7/+13
| | | | llvm-svn: 65274
* Do not consider MMX_MOVD64rr a move instructions. The source register is in ↵Evan Cheng2009-02-221-1/+0
| | | | | | GR32, the destination is VR64. They are not compatible. llvm-svn: 65273
* Drop bunch of half-working stuff in the ext_weak linkage support.Anton Korobeynikov2009-02-211-6/+19
| | | | | | | | | | | Now we're using one gross, but quite robust hack :) (previous ones did not work, for example, when ext_weak symbol was used deep inside constant expression in the initializer). The proper fix of this problem will require some quite huge asmprinter changes and that's why was postponed. This fixes PR3629 by the way :) llvm-svn: 65230
* Make sure this doesn't access .end() too.Bill Wendling2009-02-211-3/+4
| | | | llvm-svn: 65213
* Make sure we don't dereference the .end() of the container.Bill Wendling2009-02-211-1/+2
| | | | llvm-svn: 65211
* Propagate more debug loc infos. This also includes some code cleaning.Bill Wendling2009-02-211-6/+18
| | | | llvm-svn: 65207
* We need to propagate the debug location information even when dealing with theBill Wendling2009-02-211-4/+4
| | | | | | prologue/epilogue. llvm-svn: 65206
* Support return of MMX values in 64-bit mode.Evan Cheng2009-02-201-3/+15
| | | | llvm-svn: 65152
* add note about sinTorok Edwin2009-02-201-0/+15
| | | | llvm-svn: 65137
* Put code that generates debug labels into TableGen so that it can be used byBill Wendling2009-02-187-20/+10
| | | | | | everyone. llvm-svn: 64978
* Add explicit keywords.Dan Gohman2009-02-181-1/+1
| | | | llvm-svn: 64915
* Add support to the JIT for true non-lazy operation. When a call to a functionNate Begeman2009-02-182-0/+21
| | | | | | | | | | | | | | | | | | | | that has not been JIT'd yet, the callee is put on a list of pending functions to JIT. The call is directed through a stub, which is updated with the address of the function after it has been JIT'd. A new interface for allocating and updating empty stubs is provided. Add support for removing the ModuleProvider the JIT was created with, which would otherwise invalidate the JIT's PassManager, which is initialized with the ModuleProvider's Module. Add support under a new ExecutionEngine flag for emitting the infomration necessary to update Function and GlobalVariable stubs after JITing them, by recording the address of the stub and the name of the GlobalValue. This allows code to be copied from one address space to another, where libraries may live at different virtual addresses, and have the stubs updated with their new correct target addresses. llvm-svn: 64906
* Factor out the code to add a MachineOperand to a MachineInstrBuilder.Dan Gohman2009-02-188-159/+38
| | | | llvm-svn: 64891
* GV with null value initializer shouldn't go to BSS if it's meant for a ↵Evan Cheng2009-02-183-3/+8
| | | | | | mergeable strings section. Currently it only checks for Darwin. Someone else please check if it should apply to other targets as well. llvm-svn: 64877
* Remove trailing whitespace to reduce later commit patch noise.Scott Michel2009-02-172-595/+595
| | | | | | | | (Note: Eventually, commits like this will be handled via a pre-commit hook that does this automagically, as well as expand tabs to spaces and look for 80-col violations.) llvm-svn: 64827
* add a horrible noteChris Lattner2009-02-171-0/+41
| | | | llvm-svn: 64719
* --- Merging (from foreign repository) r64714 into '.':Bill Wendling2009-02-171-7/+12
| | | | | | | | | | | | U include/llvm/CodeGen/DebugLoc.h U lib/CodeGen/SelectionDAG/LegalizeDAG.cpp U lib/CodeGen/SelectionDAG/SelectionDAGBuild.cpp U lib/Target/X86/AsmPrinter/X86ATTAsmPrinter.cpp Enable debug location generation at -Os. This goes with the reapplication of the r63639 patch. llvm-svn: 64715
* Delete trailing whitespace.Dan Gohman2009-02-161-5/+5
| | | | llvm-svn: 64694
* MachineLICM now handles these cases.Dan Gohman2009-02-151-85/+0
| | | | llvm-svn: 64620
* The x86-64 red zone is now being used.Dan Gohman2009-02-141-4/+0
| | | | llvm-svn: 64535
* Teach x86 target -soft-float.Evan Cheng2009-02-131-30/+39
| | | | llvm-svn: 64496
* Remove non-DebugLoc versions of BuildMI from IA64, Mips.Dale Johannesen2009-02-138-47/+59
| | | | llvm-svn: 64438
* Remove non-DebugLoc versions of BuildMI from X86.Dale Johannesen2009-02-136-55/+73
| | | | | | There were some that might even matter in X86FastISel. llvm-svn: 64437
* missed fileDale Johannesen2009-02-131-2/+3
| | | | llvm-svn: 64436
* Remove non-DebugLoc versions of buildMI from Sparc.Dale Johannesen2009-02-135-13/+21
| | | | llvm-svn: 64435
* Remove non-DebugLoc versions of BuildMI from Alpha and Cell.Dale Johannesen2009-02-136-65/+76
| | | | llvm-svn: 64433
* Remove refs to non-DebugLoc version of BuildMI from XCore, PIC16.Dale Johannesen2009-02-134-39/+45
| | | | llvm-svn: 64432
* Remove refs to non-DebugLoc version of BuildMI from PowerPC.Dale Johannesen2009-02-135-149/+173
| | | | llvm-svn: 64431
* and one more fileDale Johannesen2009-02-131-64/+92
| | | | llvm-svn: 64430
* Remove refs to non-DebugLoc versions of BuildMI from ARM.Dale Johannesen2009-02-135-23/+40
| | | | llvm-svn: 64429
* Revert this. It was breaking stuff.Bill Wendling2009-02-131-1/+9
| | | | llvm-svn: 64428
* Turn off the old way of handling debug information in the code generator. UseBill Wendling2009-02-131-9/+1
| | | | | | | the new way, where all of the information is passed on SDNodes and machine instructions. llvm-svn: 64427
* Check in missing file.Dale Johannesen2009-02-121-2/+4
| | | | llvm-svn: 64410
* Eliminate a couple of non-DebugLoc BuildMI variants.Dale Johannesen2009-02-1210-60/+86
| | | | | | Modify callers. llvm-svn: 64409
OpenPOWER on IntegriCloud