aboutsummaryrefslogtreecommitdiffstats
path: root/test
Commit message (Collapse)AuthorAgeFilesLines
* Add -mtriple to llc commands, attempting to fix buildbot failures.Bob Wilson2009-11-051-2/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86086 91177308-0d34-0410-b5e6-96231b3b80d8
* Attempt again to fix buildbot failures: make expected output less specificBob Wilson2009-11-051-12/+9
| | | | | | | and compile with -mtriple to specify *-apple-darwin targets. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86081 91177308-0d34-0410-b5e6-96231b3b80d8
* Update CreateMalloc so that its callers specify the size to allocate:Victor Hernandez2009-11-0510-44/+72
| | | | | | | | | | | | | | | | | | | MallocInst-autoupgrade users use non-TargetData-computed allocation sizes. Optimization uses use TargetData to compute the allocation size. Now that malloc calls can have constant sizes, update isArrayMallocHelper() to use TargetData to determine the size of the malloced type and the size of malloced arrays. Extend getMallocType() to support malloc calls that have non-bitcast uses. Update OptimizeGlobalAddressOfMalloc() to optimize malloc calls that have non-bitcast uses. The bitcast use of a malloc call has to be treated specially here because the uses of the bitcast need to be replaced and the bitcast needs to be erased (just like the malloc call) for OptimizeGlobalAddressOfMalloc() to work correctly. Update PerformHeapAllocSRoA() to optimize malloc calls that have non-bitcast uses. The bitcast use of the malloc is not handled specially here because ReplaceUsesOfMallocWithGlobal replaces through the bitcast use. Update OptimizeOnceStoredGlobal() to not care about the malloc calls' bitcast use. Update all globalopt malloc tests to not rely on autoupgraded-MallocInsts, but instead use explicit malloc calls with correct allocation sizes. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86077 91177308-0d34-0410-b5e6-96231b3b80d8
* improve DSE when TargetData is not around, based on work byChris Lattner2009-11-041-0/+15
| | | | | | | Hans Wennborg! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86067 91177308-0d34-0410-b5e6-96231b3b80d8
* Add PowerPC codegen for indirect branches.Bob Wilson2009-11-041-0/+55
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86050 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix broken test.Bob Wilson2009-11-041-2/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86045 91177308-0d34-0410-b5e6-96231b3b80d8
* Add test for ARM indirectbr codegen.Bob Wilson2009-11-041-0/+63
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86042 91177308-0d34-0410-b5e6-96231b3b80d8
* RangeIsDefinedByCopyFromReg() should check for subreg_to_reg, insert_subreg,Evan Cheng2009-11-041-0/+15
| | | | | | | | | and extract_subreg as a "copy" that defines a valno. Also fixes a typo. These two issues prevent a simple subreg coalescing from happening before. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86022 91177308-0d34-0410-b5e6-96231b3b80d8
* move two functions up higher in the file. Delete a useless argumentChris Lattner2009-11-041-1/+38
| | | | | | | | | | | | | | | to EmitGEPOffset. Implement some new transforms for optimizing subtracts of two pointer to ints into the same vector. This happens for C++ iterator idioms for example, stringmap takes a const char* that points to the start and end of a string. Once inlined, we want the pointer difference to turn back into a length. This is rdar://7362831. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86021 91177308-0d34-0410-b5e6-96231b3b80d8
* filecheckize this test.Chris Lattner2009-11-041-56/+121
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86020 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix test.Evan Cheng2009-11-041-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85986 91177308-0d34-0410-b5e6-96231b3b80d8
* reimplement multiple return value handling in IPSCCP, making it Chris Lattner2009-11-031-2/+1
| | | | | | | | more aggressive an correct. This survives building llvm in 64-bit mode with optimizations and the built llvm passes make check. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85973 91177308-0d34-0410-b5e6-96231b3b80d8
* fconsts / fconstd immediate should be proceeded with #.Evan Cheng2009-11-031-4/+4
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85952 91177308-0d34-0410-b5e6-96231b3b80d8
* Re-apply 85799. It turns out my code isn't buggy.Evan Cheng2009-11-032-4/+6
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85947 91177308-0d34-0410-b5e6-96231b3b80d8
* fix testChris Lattner2009-11-031-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85946 91177308-0d34-0410-b5e6-96231b3b80d8
* merge a test into ipsccp-basic. running llvm-ld to get one pass is... bad.Chris Lattner2009-11-032-21/+11
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85945 91177308-0d34-0410-b5e6-96231b3b80d8
* turn IPSCCP back on by default, try #3 or 4? Woo.Chris Lattner2009-11-031-1/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85929 91177308-0d34-0410-b5e6-96231b3b80d8
* fix an IPSCCP bug I introduced when I changed IPSCCP to start working on Chris Lattner2009-11-031-0/+20
| | | | | | | | | | | functions that don't have local linkage. Basically, we need to be more careful about propagating argument information to functions whose results we aren't tracking. This fixes a miscompilation of LLVMCConfigurationEmitter.cpp when built with an llvm-gcc that has ipsccp enabled. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85923 91177308-0d34-0410-b5e6-96231b3b80d8
* Parse debug info attached with insertvalue and extractvalue instructions.Devang Patel2009-11-031-0/+11
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85921 91177308-0d34-0410-b5e6-96231b3b80d8
* xfail this test since daniel turned off ipsccpChris Lattner2009-11-031-0/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85907 91177308-0d34-0410-b5e6-96231b3b80d8
* testcase for r85903Chris Lattner2009-11-031-0/+24
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85906 91177308-0d34-0410-b5e6-96231b3b80d8
* Make opt default to not adding a target data string and update tests that ↵Kenneth Uildriks2009-11-0358-1/+59
| | | | | | depend on target data to supply it within the test git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85900 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix PR5367. QPR_8 is the super regclass of DPR_8 and SPR_8.Evan Cheng2009-11-034-3/+64
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85871 91177308-0d34-0410-b5e6-96231b3b80d8
* Declare sin & cos as readonly so they match the code in SelectionDAGBuildNate Begeman2009-11-031-4/+4
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85853 91177308-0d34-0410-b5e6-96231b3b80d8
* Temporary xfail until PR5367 will be resolvedAnton Korobeynikov2009-11-032-0/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85848 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert r85049, it is causing PR5367Anton Korobeynikov2009-11-031-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85847 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert 85799 for now. It might be breaking llvm-gcc driver.Evan Cheng2009-11-022-6/+4
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85827 91177308-0d34-0410-b5e6-96231b3b80d8
* merge 2008-03-10-sret.ll into ipsccp-basic.ll, and upgrade its syntax.Chris Lattner2009-11-022-21/+26
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85811 91177308-0d34-0410-b5e6-96231b3b80d8
* disable IPSCCP support for multiple return values, it is buggy, so justChris Lattner2009-11-022-0/+3
| | | | | | | disable it until I can fix it. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85810 91177308-0d34-0410-b5e6-96231b3b80d8
* Initilize the machine LICM CSE map upon the first time an instruction is ↵Evan Cheng2009-11-022-4/+6
| | | | | | | | | | | hoisted to the loop preheader. Add instructions which are already in the preheader block that may be common expressions of those that are hoisted out. These does get a few more instructions CSE'ed. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85799 91177308-0d34-0410-b5e6-96231b3b80d8
* improve IPSCCP to be able to propagate the result of "!mayBeOverridden"Chris Lattner2009-11-021-0/+14
| | | | | | | | | | function to calls of that function, regardless of whether it has local linkage or has its address taken. Not escaping should only affect whether we make an aggressive assumption about the arguments to a function, not whether we can track the result of it. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85795 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove an irrelevant and poorly reduced test case.Evan Cheng2009-11-021-414/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85794 91177308-0d34-0410-b5e6-96231b3b80d8
* Use the libanalysis 'ConstantFoldLoadFromConstPtr' functionChris Lattner2009-11-021-2/+9
| | | | | | | | instead of reinventing SCCP-specific logic. This gives us new powers. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85789 91177308-0d34-0410-b5e6-96231b3b80d8
* Unbreak ARMBaseRegisterInfo::copyRegToReg.Evan Cheng2009-11-021-0/+29
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85787 91177308-0d34-0410-b5e6-96231b3b80d8
* fix a bug exposed by moving SRoA earlier which caused a crash building kc++Chris Lattner2009-11-021-3/+20
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85786 91177308-0d34-0410-b5e6-96231b3b80d8
* fix instcombine to only do store sinking when the alignmentsChris Lattner2009-11-021-0/+18
| | | | | | | of the two loads agree. Propagate that onto the new store. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85772 91177308-0d34-0410-b5e6-96231b3b80d8
* merge a test into store.llChris Lattner2009-11-022-37/+45
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85771 91177308-0d34-0410-b5e6-96231b3b80d8
* convert to filecheckChris Lattner2009-11-021-2/+6
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85770 91177308-0d34-0410-b5e6-96231b3b80d8
* Handle splats of undefs properly. This includes the testcase for PR5364 as well.Anton Korobeynikov2009-11-021-0/+20
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85767 91177308-0d34-0410-b5e6-96231b3b80d8
* 64-bit FP loads & stores operate on both NEON and VFP pipelines.Anton Korobeynikov2009-11-021-0/+37
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85765 91177308-0d34-0410-b5e6-96231b3b80d8
* Make use of imm12 version of Thumb2 ldr / str instructions more aggressively.Evan Cheng2009-11-011-0/+75
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85743 91177308-0d34-0410-b5e6-96231b3b80d8
* merge phi-merge.ll into phi.llChris Lattner2009-11-012-31/+33
| | | | | | | | I don't know what Dan wants to do with phi-merge-gep.ll, I'll let him deal with it because instcombine may end up sinking these. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85739 91177308-0d34-0410-b5e6-96231b3b80d8
* when merging two loads, make sure to take the min of their alignment,Chris Lattner2009-11-011-0/+26
| | | | | | | | not the max. This didn't matter until the previous patch because instcombine would refuse to sink loads with differenting alignments. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85738 91177308-0d34-0410-b5e6-96231b3b80d8
* fix a bug noticed by inspection: when instcombine sinks loads throughChris Lattner2009-11-011-0/+21
| | | | | | | | | phis, it didn't preserve the alignment of the load. This is a missed optimization of the alignment is high and a miscompilation when the alignment is low. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85736 91177308-0d34-0410-b5e6-96231b3b80d8
* convert to filecheck.Chris Lattner2009-11-011-20/+49
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85734 91177308-0d34-0410-b5e6-96231b3b80d8
* We currently only run ipsccp at LTO time, which is silly. It subsumesChris Lattner2009-11-011-0/+19
| | | | | | | | | | | | | | ipconstprop and doesn't take much time. Just run it in its place. This adds a testcase for it, which I plan to expand to cover other "integration" cases, where we expect the optimizer to be able to eliminate various things. Due to phase order issues we've regressed in a number of areas and integration tests are the only way I see to prevent this. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85729 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix tests.Evan Cheng2009-11-012-4/+4
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85723 91177308-0d34-0410-b5e6-96231b3b80d8
* improve x86 codegen support for blockaddress. We now compileChris Lattner2009-11-011-0/+16
| | | | | | | | | | | | | | | | | | | | | | | the testcase into: _test1: ## @test1 ## BB#0: ## %entry leaq L_test1_bb6(%rip), %rax jmpq *%rax L_test1_bb: ## Address Taken LBB1_1: ## %bb movb $1, %al ret L_test1_bb6: ## Address Taken LBB1_2: ## %bb6 movb $2, %al ret Note, it is very very strange that BlockAddressSDNode doesn't carry around TargetFlags. Dan, please fix this. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85703 91177308-0d34-0410-b5e6-96231b3b80d8
* Use cbz and cbnz instructions.Evan Cheng2009-10-312-0/+34
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85698 91177308-0d34-0410-b5e6-96231b3b80d8
* vml[as].f32 cause stalls in following advanced SIMD instructions. Avoid usingJim Grosbach2009-10-313-4/+6
| | | | | | them for scalar floating point operations for now. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85697 91177308-0d34-0410-b5e6-96231b3b80d8