summaryrefslogtreecommitdiffstats
path: root/llvm/test
Commit message (Collapse)AuthorAgeFilesLines
* [Scalarizer] PR28108: Skip over nullptr rather than crashing on it.Mehdi Amini2016-07-141-0/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: In Scalarizer::gather we see if we already have a scattered form of Op, and in that case use the new form. In the particular case of PR28108, the found ValueVector SV has size 2, where the first Value is nullptr, and the second is indeed a proper Value. The nullptr then caused an assert to blow when we tried to do cast<Instruction>(SV[I]). With this patch we check SV[I] before doing the cast, and if it's nullptr we just skip over it. I don't know the Scalarizer well enough to know if this is the best fix or if something should be done else where to prevent the nullptr from being in the ValueVector at all, but at least this avoids the crash and looking at the test case output it looks reasonable. Reviewers: hfinkel, frasercrmck, wala, mehdi_amini Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D21518 llvm-svn: 275359
* Add missing test for r275347 "[IPRA] Set callee saved registers to none for ↵Mehdi Amini2016-07-141-0/+30
| | | | | | local function when IPRA is enabled." llvm-svn: 275358
* Synchronize LLVM and clang's ObjCDeclSpec::ObjCPropertyAttributeKind.Adrian Prantl2016-07-144-16/+59
| | | | | | | | | | This adds Clang-specific DWARF constants for nullability and ObjC class properties that are already generated by clang. This patch adds dwarfdump support and a more comprehensive testcase. <rdar://problem/27335745> llvm-svn: 275354
* [ConstantFolding] Fold masked loadsDavid Majnemer2016-07-141-0/+11
| | | | | | | | | We can constant fold a masked load if the operands are appropriately constant. Differential Revision: http://reviews.llvm.org/D22324 llvm-svn: 275352
* [ConstantFolding] Extend FoldReinterpretLoadFromConstPtr to handle negative ↵David Majnemer2016-07-131-0/+8
| | | | | | | | | offsets Treat loads which clip before the start of a global initializer the same way we treat clipping beyond the end of the initializer: use zeros. llvm-svn: 275345
* [DAG] Correctly chain masked loadsMichael Kuperstein2016-07-131-0/+16
| | | | | | | | | If a masked loads is not added to the chain, it should not reset the chain's root. This fixes the remaining part of PR28515. llvm-svn: 275340
* [MIR] Fix one GlobalISel test case that I missed in r275314.Quentin Colombet2016-07-131-3/+2
| | | | llvm-svn: 275333
* Add a triple to fix test on bots after 275320.Nico Weber2016-07-131-1/+1
| | | | llvm-svn: 275327
* Fix a TODO in X86CallFrameOptimization to not rely on a codegen artifact.Nico Weber2016-07-131-6/+6
| | | | | | | | | This happens to make X86CallFrameOptimization in -O0 / FastISel builds as well, but it's not clear if the pass should run in that setup. http://reviews.llvm.org/D22314 llvm-svn: 275320
* Extended LoadStoreVectorizer to vectorize subchains.Alina Sbirlea2016-07-131-7/+3
| | | | | | | | | | | | | | Summary: LSV used to abort vectorizing a chain for interleaved load/store accesses that alias. Allow a valid prefix of the chain to be vectorized, mark just the prefix and retry vectorizing the remaining chain. Reviewers: llvm-commits, jlebar, arsenm Subscribers: mzolotukhin Differential Revision: http://reviews.llvm.org/D22119 llvm-svn: 275317
* [MIR] Print on the given output instead of stderr.Quentin Colombet2016-07-1398-105/+105
| | | | | | | | | | | | Currently the MIR framework prints all its outputs (errors and actual representation) on stderr. This patch fixes that by printing the regular output in the output specified with -o. Differential Revision: http://reviews.llvm.org/D22251 llvm-svn: 275314
* AMDGPU: Remove last AMDIL intrinsicsMatt Arsenault2016-07-131-12/+1
| | | | llvm-svn: 275309
* Reverting r275284 due to platform-specific test failuresAndrew Kaylor2016-07-134-50/+0
| | | | llvm-svn: 275304
* add more tests for zexty xor sandwichesSanjay Patel2016-07-132-0/+39
| | | | | | ...mmm sandwiches llvm-svn: 275302
* [X86][SSE] Regenerate truncated shift testSimon Pilgrim2016-07-131-6/+20
| | | | | | Check SSE2 and AVX2 implementations llvm-svn: 275300
* Regenerate testSimon Pilgrim2016-07-131-2/+2
| | | | llvm-svn: 275299
* add test for zexty xor sandwichSanjay Patel2016-07-131-0/+14
| | | | llvm-svn: 275297
* Move mempcpy_call.ll to X86 subdirectoryKrzysztof Parzyszek2016-07-131-0/+0
| | | | llvm-svn: 275294
* [InstCombine] extend vector select matching for non-splat constantsSanjay Patel2016-07-131-15/+28
| | | | | | | | | | | | | | | In D21740, we discussed trying to make this a more general matcher. However, I didn't see a clean way to handle the regular m_Not cases and these non-splat vector patterns, so I've opted for the direct approach here. If there are other potential uses of areInverseVectorBitmasks(), we could move that helper function to a higher level. There is an open question as to which is of these forms should be considered the canonical IR: %sel = select <4 x i1> <i1 true, i1 false, i1 false, i1 true>, <4 x i32> %a, <4 x i32> %b %shuf = shufflevector <4 x i32> %a, <4 x i32> %b, <4 x i32> <i32 0, i32 5, i32 6, i32 3> Differential Revision: http://reviews.llvm.org/D22114 llvm-svn: 275289
* Fix for Bug 26903, adds support to inline __builtin_mempcpyAndrew Kaylor2016-07-134-0/+50
| | | | | | | | Patch by Sunita Marathe Differential Revision: http://reviews.llvm.org/D21920 llvm-svn: 275284
* PatchableFunction: Skip pseudos that do not create codeMatthias Braun2016-07-131-0/+24
| | | | | | This fixes http://llvm.org/PR28524 llvm-svn: 275278
* [ThinLTO/gold] Enable symbol resolution in distributed backend caseTeresa Johnson2016-07-131-2/+0
| | | | | | | | | | | | | | | | While testing a follow-on change to enable index-based symbol resolution and internalization in the distributed backends, I realized that a test case change I made in r275247 was only required because we were not analyzing symbols in the claimed files in thinlto-index-only mode. In the fixed test case there should be no internalization because we are linking in -shared mode, so f() is in fact exported, which is detected properly when we analyze symbols in thinlto-index-only mode. Note that this is not (yet) a correctness issue (because we are not yet performing the index-based linkage optimizations in the distributed backends - that's coming in a follow-on patch). llvm-svn: 275277
* [x86][SSE/AVX] optimize pcmp results better (PR28484)Sanjay Patel2016-07-134-41/+27
| | | | | | | | | | | | | | We know that pcmp produces all-ones/all-zeros bitmasks, so we can use that behavior to avoid unnecessary constant loading. One could argue that load+and is actually a better solution for some CPUs (Intel big cores) because shifts don't have the same throughput potential as load+and on those cores, but that should be handled as a CPU-specific later transformation if it ever comes up. Removing the load is the more general x86 optimization. Note that the uneven usage of vpbroadcast in the test cases is filed as PR28505: https://llvm.org/bugs/show_bug.cgi?id=28505 Differential Revision: http://reviews.llvm.org/D22225 llvm-svn: 275276
* [X86][AVX512] Add support for VPERMILPD/VPERMILPS variable shuffle mask commentsSimon Pilgrim2016-07-131-1/+1
| | | | llvm-svn: 275272
* [X86][AVX] Add support for target shuffle combining to VPERMILPS variable ↵Simon Pilgrim2016-07-132-0/+22
| | | | | | | | shuffle mask Added AVX512F VPERMILPS shuffle decoding support llvm-svn: 275270
* AMDGPU/SI: Add support for R_AMDGPU_GOTPCRELTom Stellard2016-07-135-23/+208
| | | | | | | | | | Reviewers: rafael, ruiu, tony-tye, arsenm, kzhuravl Subscribers: arsenm, llvm-commits, kzhuravl Differential Revision: http://reviews.llvm.org/D21484 llvm-svn: 275268
* [MC] Fix lexing ordering in assembly label parsing to preserve same lineNirav Dave2016-07-131-0/+2
| | | | | | comment placement. llvm-svn: 275265
* AMDGPU: Fold out no-op kill intrinsicsMatt Arsenault2016-07-131-1/+0
| | | | llvm-svn: 275253
* [ConstantFolding] Don't treat negative GEP offsets as positiveDavid Majnemer2016-07-131-6/+2
| | | | | | GEP offsets are signed, don't treat them as huge positive numbers. llvm-svn: 275251
* [BFI] Add new LazyBFI analysis passAdam Nemet2016-07-131-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | Summary: This is necessary for D21771. In order to add the hotness attribute to optimization remarks we need BFI to be available in all passes that emit optimization remarks. However we don't want to pay for computing BFI unless the hotness attribute is requested. This is achieved by making BFI lazy at the very high-level through a new analysis pass -- BFI is not calculated unless requested. I am adding a test to check the laziness under D21771 where the first user of the analysis is added. Reviewers: hfinkel, dexonsmith, davidxl Subscribers: davidxl, dexonsmith, llvm-commits Differential Revision: http://reviews.llvm.org/D22141 llvm-svn: 275250
* [ThinLTO/gold] ThinLTO internalization fixesTeresa Johnson2016-07-132-0/+9
| | | | | | | | | | | Internalization was missing cases where we originally had a local symbol that was promoted eagerly but not actually exported. This is because we were only internalizing the set of global (non-local) symbols that were PREVAILAING_DEF_IRONLY. Instead, collect the set of global symbols that are referenced outside of a single IR file, and skip internalization for those. llvm-svn: 275247
* [ConstantFold] Don't incorrectly infer inbounds on array GEPDavid Majnemer2016-07-131-0/+10
| | | | | | | | The many levels of nesting inside the responsible code made it easy for bugs to sneak in. Flattening the logic makes it easier to see what's going on. llvm-svn: 275244
* Fix ScalarEvolutionExpander step scaling bugKeno Fischer2016-07-131-0/+48
| | | | | | | | | | | | | | | | The expandAddRecExprLiterally function incorrectly transforms `[Start + Step * X]` into `Step * [Start + X]` instead of the correct transform of `[Step * X] + Start`. This caused https://github.com/JuliaLang/julia/issues/14704#issuecomment-174126219 due to what appeared to be sufficiently complicated loop interactions. Patch by Jameson Nash (jameson@juliacomputing.com). Reviewers: sanjoy Differential Revision: http://reviews.llvm.org/D16505 llvm-svn: 275239
* New pass manager for LICM.Dehao Chen2016-07-1224-0/+24
| | | | | | | | | | | | Summary: Port LICM to the new pass manager. Reviewers: davidxl, silvas Subscribers: krasin, vitalybuka, silvas, davide, sanjoy, llvm-commits, mehdi_amini Differential Revision: http://reviews.llvm.org/D21772 llvm-svn: 275222
* GlobalISel: freeze reserved regs after IRTranslator.Tim Northover2016-07-121-1/+1
| | | | | | | | | | We can freeze the registers after the MachineFrameInfo has been configured (by telling it about calls, inline asm, ...). This doesn't happen at all yet, but will be part of IR translation. Fixes -verify-machineinstrs assertion. llvm-svn: 275221
* AMDGPU: Follow up to r275203Matt Arsenault2016-07-121-6/+117
| | | | | | I meant to squash this into it. llvm-svn: 275220
* The test case I added is PowerPC specific but I accidentallyNemanja Ivanovic2016-07-121-0/+0
| | | | | | | | had it in the wrong directory. Moved it to CodeGen/PowerPC. Sorry about the noise. llvm-svn: 275218
* [LV] Remove wrong assumption about LCSSAMichael Kuperstein2016-07-121-0/+25
| | | | | | | | | The LCSSA pass itself will not generate several redundant PHI nodes in a single exit block. However, such redundant PHI nodes don't violate LCSSA form, and may be introduced by passes that preserve LCSSA, and/or preserved by the LCSSA pass itself. So, assuming a single PHI node per exit block is not safe. llvm-svn: 275217
* [Power9] Add codegen for VSX word insert/extract instructionsNemanja Ivanovic2016-07-121-0/+970
| | | | | | | | | | | This patch corresponds to review: http://reviews.llvm.org/D20239 It adds exploitation of XXINSERTW and XXEXTRACTUW instructions that are useful in some cases for inserting and extracting vector elements of v4[if]32 vectors. llvm-svn: 275215
* Review fixes to lit documentationPiotr Padlewski2016-07-121-1/+0
| | | | | | | | | | Reviewers: mehdi_amini Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D22245 llvm-svn: 275214
* [X86][AVX] Add support for target shuffle combining to VPERM2F128/VPERM2I128Simon Pilgrim2016-07-122-6/+29
| | | | llvm-svn: 275212
* [SCCP] Constant fold structs if all the lattice value are constant.Davide Italiano2016-07-121-0/+72
| | | | | | Differential Revision: http://reviews.llvm.org/D22269 llvm-svn: 275208
* X86FixupBWInsts: No need for forward liveness analysis.Matthias Braun2016-07-121-37/+0
| | | | | | | | | | With r274952 and r275201 in place there are no cases left where a forward liveness analysis yields different results than a backward one. So we can remove the forward stepping logic. Differential Revision: http://reviews.llvm.org/D22083 llvm-svn: 275204
* AMDGPU: Fix verifier error with kill intrinsicMatt Arsenault2016-07-122-5/+150
| | | | | | | Don't create a terminator in the middle of the block. We should probably get rid of this intrinsic. llvm-svn: 275203
* [PM] Port LoopIdiomRecognize Pass to new PMDehao Chen2016-07-121-0/+1
| | | | | | | | | | | | Summary: Port LoopIdiomRecognize Pass to new PM Reviewers: davidxl Subscribers: davide, sanjoy, mzolotukhin, llvm-commits Differential Revision: http://reviews.llvm.org/D22250 llvm-svn: 275202
* AMDGPU: Add LLVM IR Intrinsic for v_lerp_u8Wei Ding2016-07-121-0/+14
| | | | | | Differential Revision: http://reviews.llvm.org/D22239 llvm-svn: 275197
* [PGO] Don't include full file path in static function profile counter namesXinliang David Li2016-07-121-0/+11
| | | | | | | Patch by Jake VanAdrighem Differential Revision: http://reviews.llvm.org/D22028 llvm-svn: 275193
* add tests for missing DeMorgan's Law foldsSanjay Patel2016-07-121-0/+55
| | | | llvm-svn: 275192
* auto-generate checksSanjay Patel2016-07-121-20/+23
| | | | llvm-svn: 275188
* auto-generate checksSanjay Patel2016-07-121-12/+13
| | | | llvm-svn: 275187
OpenPOWER on IntegriCloud