summaryrefslogtreecommitdiffstats
path: root/llvm/lib
Commit message (Collapse)AuthorAgeFilesLines
...
* The pic base can't be duplicated.Chris Lattner2008-01-061-1/+1
| | | | llvm-svn: 45668
* rename isLoad -> isSimpleLoad due to evan's desire to have such a predicate.Chris Lattner2008-01-0622-53/+52
| | | | llvm-svn: 45667
* The transform that tries to turn calls to bitcast functions intoDuncan Sands2008-01-064-74/+69
| | | | | | | | | direct calls bails out unless caller and callee have essentially equivalent parameter attributes. This is illogical - the callee's attributes should be of no relevance here. Rework the logic, which incidentally fixes a crash when removed arguments have attributes. llvm-svn: 45658
* When transforming a call to a bitcast function intoDuncan Sands2008-01-062-46/+78
| | | | | | | | | | | a direct call with cast parameters and cast return value (if any), instcombine was prepared to cast any non-void return value into any other, whether castable or not. Add a new predicate for testing whether casting is valid, and check it both for the return value and (as a cleanup) for the parameters. llvm-svn: 45657
* rename isStore -> mayStore to more accurately reflect what it captures.Chris Lattner2008-01-0611-14/+14
| | | | llvm-svn: 45656
* Remove an unused variable.Duncan Sands2008-01-061-1/+0
| | | | llvm-svn: 45655
* Change the 'isStore' inferrer to look for 'SDNPMayStore' Chris Lattner2008-01-067-216/+215
| | | | | | | | | | | instead of "ISD::STORE". This allows us to mark target-specific dag nodes as storing (such as ppc byteswap stores). This allows us to remove more explicit isStore flags from the .td files. Finally, add a warning for when a .td file contains an explicit isStore and tblgen is able to infer it. llvm-svn: 45654
* remove explicit isStore flags that are now inferrable.Chris Lattner2008-01-063-6/+3
| | | | llvm-svn: 45653
* remove some isStore flags that are now inferred automatically.Chris Lattner2008-01-063-6/+9
| | | | llvm-svn: 45652
* Fix comment.Bill Wendling2008-01-051-2/+1
| | | | llvm-svn: 45638
* make this build with newer gcc'sChris Lattner2008-01-051-2/+1
| | | | llvm-svn: 45637
* Remove an incorrect optimization that is performed correctly byNate Begeman2008-01-051-11/+1
| | | | | | the target independent legalizer. llvm-svn: 45631
* If custom lowering of insert element fails, the result Val will be 0.Nate Begeman2008-01-051-3/+3
| | | | | | | Don't overwrite a variable used by the fallthrough code path in this case. llvm-svn: 45630
* Fix build issue on certain compilers.Chris Lattner2008-01-051-1/+2
| | | | llvm-svn: 45629
* Refactoring the x86 and x86-64 calling convention implementations,Gordon Henriksen2008-01-052-879/+372
| | | | | | | | unifying the copied algorithms and saving over 500 LOC. There should be no functionality change, but please test on your favorite x86 target. llvm-svn: 45627
* Chris and Evan noticed that this check was compleatly fubared. I wasBill Wendling2008-01-051-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | checking that there was a from a global instead of a load from the stub for a global, which is the one that's safe to hoist. Consider this program: volatile char G[100]; int B(char *F, int N) { for (; N > 0; --N) F[N] = G[N]; } In static mode, we shouldn't be hoisting the load from G: $ llc -relocation-model=static -o - a.bc -march=x86 -machine-licm LBB1_1: # bb.preheader leal -1(%eax), %edx testl %edx, %edx movl $1, %edx cmovns %eax, %edx xorl %esi, %esi LBB1_2: # bb movb _G(%eax), %bl movb %bl, (%ecx,%eax) llvm-svn: 45626
* The current impl is really trivial, add some comments about how it can be ↵Chris Lattner2008-01-051-2/+24
| | | | | | made better. llvm-svn: 45625
* allow sinking to be enabled for the jitChris Lattner2008-01-051-0/+3
| | | | llvm-svn: 45624
* enable sinking and licm of loads from the argument area. I'd like to enable ↵Chris Lattner2008-01-051-0/+21
| | | | | | | | this for remat, but can't due to an RA bug. llvm-svn: 45623
* simplify some code by using shorter accessors.Chris Lattner2008-01-051-17/+17
| | | | llvm-svn: 45622
* revert my previous patch.Chris Lattner2008-01-051-10/+29
| | | | llvm-svn: 45621
* factor some code better to avoid redundancy between Chris Lattner2008-01-051-29/+10
| | | | | | | isReallySideEffectFree and isReallyTriviallyReMaterializable. Why is a load from a global considered side-effect-free but not rematable? llvm-svn: 45620
* getting the pic base has no side effects.Chris Lattner2008-01-051-0/+2
| | | | llvm-svn: 45618
* don't sink anything with side effects, this makes lots of stuff work, but ↵Chris Lattner2008-01-051-0/+4
| | | | | | sinks almost nothing. llvm-svn: 45617
* X86 JIT PIC jumptable support.Evan Cheng2008-01-054-13/+36
| | | | llvm-svn: 45616
* fix a common crash.Chris Lattner2008-01-051-0/+4
| | | | llvm-svn: 45614
* remove a couple more unsafe xforms in the face of overflow.Chris Lattner2008-01-051-9/+0
| | | | llvm-svn: 45613
* remove the (x-y) < 0 comparison xform, it miscompiles Chris Lattner2008-01-051-11/+5
| | | | | | | things that are not equality comparisons, for example: (2147479553+4096)-2147479553 < 0 != (2147479553+4096) < 2147479553 llvm-svn: 45612
* I should not be allowed to commit when sleepy.Owen Anderson2008-01-051-2/+2
| | | | llvm-svn: 45608
* Combine MovePCtoStack + POP32r into one instruction MOVPC32r so it can be ↵Evan Cheng2008-01-055-41/+49
| | | | | | moved if needed. llvm-svn: 45605
* Move some more functionality from MRegisterInfo to TargetInstrInfo.Owen Anderson2008-01-049-100/+102
| | | | llvm-svn: 45603
* Don't recalculate the loop info and loop dominators analyses if they'reBill Wendling2008-01-047-6/+26
| | | | | | preserved. llvm-svn: 45596
* fix typoWojciech Matyjewicz2008-01-041-1/+1
| | | | llvm-svn: 45594
* Unbreak tailcall opt in JIT.Evan Cheng2008-01-041-1/+2
| | | | llvm-svn: 45576
* X86 PIC JIT support fixes: encoding bugs, add lazy pointer stubs support.Evan Cheng2008-01-044-30/+118
| | | | llvm-svn: 45575
* 80-column violations.Bill Wendling2008-01-041-10/+14
| | | | llvm-svn: 45574
* Add that this preserves some analyses.Bill Wendling2008-01-041-1/+3
| | | | llvm-svn: 45573
* Move option to enable machine LICM into LLVMTargetMachine.cpp.Bill Wendling2008-01-042-13/+8
| | | | llvm-svn: 45572
* Call the parent's getAnalysisUsage.Bill Wendling2008-01-041-0/+1
| | | | llvm-svn: 45571
* Add a really quick hack at a machine code sinking pass, enabled with ↵Chris Lattner2008-01-042-0/+215
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | --enable-sinking. It is missing validity checks, so it is known broken. However, it is powerful enough to compile this contrived code: void test1(int C, double A, double B, double *P) { double Tmp = A*A+B*B; *P = C ? Tmp : A; } into: _test1: movsd 8(%esp), %xmm0 cmpl $0, 4(%esp) je LBB1_2 # entry LBB1_1: # entry movsd 16(%esp), %xmm1 mulsd %xmm1, %xmm1 mulsd %xmm0, %xmm0 addsd %xmm1, %xmm0 LBB1_2: # entry movl 24(%esp), %eax movsd %xmm0, (%eax) ret instead of: _test1: movsd 16(%esp), %xmm0 mulsd %xmm0, %xmm0 movsd 8(%esp), %xmm1 movapd %xmm1, %xmm2 mulsd %xmm2, %xmm2 addsd %xmm0, %xmm2 cmpl $0, 4(%esp) je LBB1_2 # entry LBB1_1: # entry movapd %xmm2, %xmm1 LBB1_2: # entry movl 24(%esp), %eax movsd %xmm1, (%eax) ret woo. llvm-svn: 45570
* remove dead #includes and reorder the rest.Chris Lattner2008-01-041-10/+6
| | | | llvm-svn: 45569
* Fix PR1896Chris Lattner2008-01-041-1/+1
| | | | llvm-svn: 45568
* Correct order of parameters.Evan Cheng2008-01-041-2/+2
| | | | llvm-svn: 45562
* Remove symbols that don't exist, remove tabs, fix comment typoChris Lattner2008-01-031-17/+15
| | | | llvm-svn: 45553
* First steps in in X86 calling convention cleanup.Gordon Henriksen2008-01-031-121/+128
| | | | llvm-svn: 45536
* don't hoist FP additions into unconditional adds + selects. This Chris Lattner2008-01-031-0/+2
| | | | | | | could theoretically introduce a trap, but is also a performance issue. This speeds up ptrdist/ks by 8%. llvm-svn: 45533
* Fix PR1873, a problem finding stat-related symbols on linux, due toChris Lattner2008-01-031-9/+20
| | | | | | "libc_nonshared.a". Patch by Edwin Török! llvm-svn: 45532
* Trying that again.Gordon Henriksen2008-01-031-1/+0
| | | | llvm-svn: 45529
* Fix a compile error on Windows.Gordon Henriksen2008-01-031-0/+2
| | | | llvm-svn: 45528
* Change MachineRelocation::DoesntNeedFnStub to NeedStub. This fields will be usedEvan Cheng2008-01-034-52/+54
| | | | | | for non-function GV relocations that require function address stubs (e.g. Mac OS X in non-static mode). llvm-svn: 45527
OpenPOWER on IntegriCloud