summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/SelectionDAG
Commit message (Collapse)AuthorAgeFilesLines
* Invert the logic of reachesChainWithoutSideEffects(). What we want to check ↵Owen Anderson2010-09-181-7/+7
| | | | | | | | | | is that there is NO path to the destination containing side effects, not that SOME path contains no side effects. In practice, this only manifests with CombinerAA enabled, because otherwise the chain has little to no branching, so "any" is effectively equivalent to "all". llvm-svn: 114268
* Check bb to ensure that alloca is in separate basic block.Devang Patel2010-09-151-7/+9
| | | | | | This fixes funcargs.exp regression reported by gdb testsuite. llvm-svn: 113992
* If dbg.declare from non-entry block is using alloca from entry block then ↵Devang Patel2010-09-151-2/+14
| | | | | | use offset available in StaticAllocaMap to emit DBG_VALUE. Right now, this has no material impact because varible info also collected using offset table maintained in machine module info. llvm-svn: 113967
* Use frame index, if available for byval argument while lowering dbg_declare. ↵Devang Patel2010-09-141-16/+20
| | | | | | Otherwise let getRegForValue() find register for this argument. llvm-svn: 113843
* Revert "CMake: Get rid of LLVMLibDeps.cmake and export the libraries normally."Michael J. Spencer2010-09-131-7/+1
| | | | | | | | | | This reverts commit r113632 Conflicts: cmake/modules/AddLLVM.cmake llvm-svn: 113819
* Silence more warnings. Two more unused variables.Eric Christopher2010-09-131-2/+0
| | | | llvm-svn: 113771
* Added skeleton for inline asm multiple alternative constraint support.John Thompson2010-09-132-45/+252
| | | | llvm-svn: 113766
* CMake: Get rid of LLVMLibDeps.cmake and export the libraries normally.Michael J. Spencer2010-09-101-1/+7
| | | | llvm-svn: 113632
* Add DEBUG message.Devang Patel2010-09-101-2/+10
| | | | llvm-svn: 113614
* Teach if-converter to be more careful with predicating instructions that wouldEvan Cheng2010-09-102-9/+8
| | | | | | | | | | | take multiple cycles to decode. For the current if-converter clients (actually only ARM), the instructions that are predicated on false are not nops. They would still take machine cycles to decode. Micro-coded instructions such as LDM / STM can potentially take multiple cycles to decode. If-converter should take treat them as non-micro-coded simple instructions. llvm-svn: 113570
* implement rdar://6653118 - fastisel should fold loads where possible.Chris Lattner2010-09-051-1/+51
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since mem2reg isn't run at -O0, we get a ton of reloads from the stack, for example, before, this code: int foo(int x, int y, int z) { return x+y+z; } used to compile into: _foo: ## @foo subq $12, %rsp movl %edi, 8(%rsp) movl %esi, 4(%rsp) movl %edx, (%rsp) movl 8(%rsp), %edx movl 4(%rsp), %esi addl %edx, %esi movl (%rsp), %edx addl %esi, %edx movl %edx, %eax addq $12, %rsp ret Now we produce: _foo: ## @foo subq $12, %rsp movl %edi, 8(%rsp) movl %esi, 4(%rsp) movl %edx, (%rsp) movl 8(%rsp), %edx addl 4(%rsp), %edx ## Folded load addl (%rsp), %edx ## Folded load movl %edx, %eax addq $12, %rsp ret Fewer instructions and less register use = faster compiles. llvm-svn: 113102
* Add a missing check when legalizing a vector extending load. This doesn'tBob Wilson2010-09-031-3/+5
| | | | | | | solve the root problem, but it corrects the bug in the code I added to support legalizing in the case where the non-extended type is also legal. llvm-svn: 112997
* Detect undef value early and save unnecessary NodeMap query.Devang Patel2010-09-021-0/+11
| | | | llvm-svn: 112864
* Don't narrow the load and store in a load+twiddle+store sequence unlessDan Gohman2010-09-021-1/+2
| | | | | | | | | | there are clearly no stores between the load and the store. This fixes this miscompile reported as PR7833. This breaks the test/CodeGen/X86/narrow_op-2.ll optimization, which is safe, but awkward to prove safe. Move it to X86's README.txt. llvm-svn: 112861
* Tidy up.Devang Patel2010-09-021-11/+9
| | | | llvm-svn: 112858
* Reapply r112623. Included additional check for unused byval argument.Devang Patel2010-08-312-1/+42
| | | | llvm-svn: 112659
* Revert r112623. It is causing self host build failures.Devang Patel2010-08-312-39/+1
| | | | llvm-svn: 112631
* Remember byval argument's frame index during argument lowering and use this ↵Devang Patel2010-08-312-1/+39
| | | | | | | | info to emit debug info. Fixes Radar 8367011. llvm-svn: 112623
* Offset is not always unsigned number.Devang Patel2010-08-312-2/+2
| | | | llvm-svn: 112584
* zap unused method. x86 is the only user and already has a more powerfull versionBruno Cardoso Lopes2010-08-311-29/+0
| | | | llvm-svn: 112571
* Revert r112461. It was failing on PPC...Bill Wendling2010-08-301-4/+2
| | | | llvm-svn: 112463
* When adding a register, we should mark it as "def" if it can optionally defineBill Wendling2010-08-301-2/+4
| | | | | | said (physical) register. llvm-svn: 112461
* remove unions from LLVM IR. They are severely buggy and notChris Lattner2010-08-281-5/+0
| | | | | | being actively maintained, improved, or extended. llvm-svn: 112356
* Completely disable tail calls when fast-isel is enabled, as fast-iselDan Gohman2010-08-281-0/+5
| | | | | | doesn't currently support dealing with this. llvm-svn: 112341
* Trim a #include.Dan Gohman2010-08-281-3/+0
| | | | llvm-svn: 112340
* Simplify.Devang Patel2010-08-271-4/+1
| | | | llvm-svn: 112305
* Revert r112213. It is not needed.Devang Patel2010-08-262-19/+8
| | | | llvm-svn: 112242
* If node is not available then use FuncInfo.ValueMap to emit debug info for ↵Devang Patel2010-08-261-5/+9
| | | | | | byval parameter. llvm-svn: 112238
* Speculatively revert r112207.Devang Patel2010-08-261-3/+1
| | | | llvm-svn: 112216
* 80 col.Devang Patel2010-08-261-1/+2
| | | | llvm-svn: 112215
* Update DanglingDebugInfo so that it can be used to track llvm.dbg.declare also.Devang Patel2010-08-262-8/+19
| | | | llvm-svn: 112213
* Donot forget to resolve dangling debug info in a case where virtual ↵Devang Patel2010-08-261-1/+3
| | | | | | register, used for a value, is initialized after a dbg intrinsic is seen. llvm-svn: 112207
* Add a hackaround for PR7993 which is causing failures on x86 builders that ↵Chris Lattner2010-08-261-0/+2
| | | | | | lack sse2. llvm-svn: 112175
* implement SplitVecOp_CONCAT_VECTORS, fixing the included testcase with SSE1.Chris Lattner2010-08-262-66/+93
| | | | llvm-svn: 112171
* zap dead code.Chris Lattner2010-08-262-37/+0
| | | | llvm-svn: 112155
* remove some llvmcontext arguments that are now dead post-refactoring.Chris Lattner2010-08-253-6/+4
| | | | llvm-svn: 112104
* Change handling of illegal vector types to widen when possible instead of Chris Lattner2010-08-252-46/+97
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | expanding: e.g. <2 x float> -> <4 x float> instead of -> 2 floats. This affects two places in the code: handling cross block values and handling function return and arguments. Since vectors are already widened by legalizetypes, this gives us much better code and unblocks x86-64 abi and SPU abi work. For example, this (which is a silly example of a cross-block value): define <4 x float> @test2(<4 x float> %A) nounwind { %B = shufflevector <4 x float> %A, <4 x float> undef, <2 x i32> <i32 0, i32 1> %C = fadd <2 x float> %B, %B br label %BB BB: %D = fadd <2 x float> %C, %C %E = shufflevector <2 x float> %D, <2 x float> undef, <4 x i32> <i32 0, i32 1, i32 undef, i32 undef> ret <4 x float> %E } Now compiles into: _test2: ## @test2 ## BB#0: addps %xmm0, %xmm0 addps %xmm0, %xmm0 ret previously it compiled into: _test2: ## @test2 ## BB#0: addps %xmm0, %xmm0 pshufd $1, %xmm0, %xmm1 ## kill: XMM0<def> XMM0<kill> XMM0<def> insertps $0, %xmm0, %xmm0 insertps $16, %xmm1, %xmm0 addps %xmm0, %xmm0 ret This implements rdar://8230384 llvm-svn: 112101
* Fix comment.Devang Patel2010-08-251-4/+3
| | | | llvm-svn: 112086
* Remove dead argument.Devang Patel2010-08-252-6/+4
| | | | llvm-svn: 112085
* split the vector case of getCopyFromParts out to its own function,Chris Lattner2010-08-241-81/+102
| | | | | | no functionality change. llvm-svn: 111994
* split the vector case out of getCopyToParts into its own function. NoChris Lattner2010-08-241-117/+126
| | | | | | functionality change. llvm-svn: 111990
* tidy up, reduce indentationChris Lattner2010-08-242-127/+123
| | | | llvm-svn: 111982
* Fix some GCC warnings by providing a virtual destructor in the base of a classChandler Carruth2010-08-231-1/+1
| | | | | | | hierarchy with virtual methods and using llvm_unreachable to properly indicate unreachable states which would otherwise leave variables uninitialized. llvm-svn: 111803
* If the target says that an extending load is not legal, regardless of whetherBob Wilson2010-08-191-7/+12
| | | | | | | | | | | it involves specific floating-point types, legalize should expand an extending load to a non-extending load followed by a separate extend operation. For example, we currently expand SEXTLOAD to EXTLOAD+SIGN_EXTEND_INREG (and assert that EXTLOAD should always be supported). Now we can expand that to LOAD+SIGN_EXTEND. This is needed to allow vector SIGN_EXTEND and ZERO_EXTEND to be used for NEON. llvm-svn: 111586
* Make fast scheduler handle asm clobbers correctly.Dale Johannesen2010-08-171-21/+53
| | | | | | PR 7882. Follows suggestion by Amaury Pouly, thanks. llvm-svn: 111306
* Fix typo.Eric Christopher2010-08-171-1/+1
| | | | llvm-svn: 111223
* Add missing null check reported by Amaury Pouly.Evan Cheng2010-08-101-2/+3
| | | | llvm-svn: 110649
* Reapply r110396, with fixes to appease the Linux buildbot gods.Owen Anderson2010-08-061-1/+1
| | | | llvm-svn: 110460
* Revert r110396 to fix buildbots.Owen Anderson2010-08-061-1/+1
| | | | llvm-svn: 110410
* Don't use PassInfo* as a type identifier for passes. Instead, use the ↵Owen Anderson2010-08-051-1/+1
| | | | | | | | address of the static ID member as the sole unique type identifier. Clean up APIs related to this change. llvm-svn: 110396
OpenPOWER on IntegriCloud