summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* [X86][SSE] Enable target shuffle combining to combine multiple shuffle inputs.Simon Pilgrim2016-08-036-75/+97
| | | | | | | | | | | | | | We currently only support combining target shuffles that consist of a single source input (plus elements known to be undef/zero). This patch generalizes the recursive combining of the target shuffle to collect all the inputs, merging any duplicates along the way, into a full set of src ops and its shuffle mask. We uncover a number of cases where we have failed to combine a unary shuffle because the input has been duplicated and separated during lowering. This will allow us to combine to 2-input shuffles in a future patch. Differential Revision: https://reviews.llvm.org/D22859 llvm-svn: 277631
* Reapply "More fixes to get good error messages for bad archives."Vedant Kumar2016-08-0311-37/+183
| | | | | | | | This reverts commit the revert commit r277627. The build errors mentioned in r277627 were likely caused by an unclean build directory. Sorry for the noise. llvm-svn: 277630
* [InstCombine] use m_APInt to allow icmp (binop X, Y), C folds with constant ↵Sanjay Patel2016-08-036-55/+42
| | | | | | | | | splat vectors This removes the restriction for the icmp constant, but as noted by the FIXME comments, we still need to change individual checks for binop operand constants. llvm-svn: 277629
* Revert "More fixes to get good error messages for bad archives."Vedant Kumar2016-08-0311-183/+37
| | | | | | | | | | | | | This reverts commit r277540. It breaks the build with: ../lib/Object/Archive.cpp:264:41: error: return type of out-of-line definition of 'llvm::object::ArchiveMemberHeader::getUID' differs from that in the declaration Expected<unsigned> ArchiveMemberHeader::getUID() const { ~~~~~~~~~~~~~~~~~~ ^ include/llvm/Object/Archive.h:53:12: note: previous declaration is here unsigned getUID() const; ~~~~~~~~ ^ llvm-svn: 277627
* [Hexagon] Generate COPY/REG_SEQUENCE more aggressively for vectorsKrzysztof Parzyszek2016-08-033-22/+30
| | | | llvm-svn: 277626
* IR: Drop uniquing when an MDNode Value operand is deletedDuncan P. N. Exon Smith2016-08-035-5/+81
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is a fix for PR28697. An MDNode can indirectly refer to a GlobalValue, through a ConstantAsMetadata. When the GlobalValue is deleted, the MDNode operand is reset to `nullptr`. If the node is uniqued, this can lead to a hard-to-detect cache invalidation in a Metadata map that's shared across an LLVMContext. Consider: 1. A map from Metadata* to `T` called RemappedMDs. 2. A node that references a global variable, `!{i1* @GV}`. 3. Insert `!{i1* @GV} -> SomeT` in the map. 4. Delete `@GV`, leaving behind `!{null} -> SomeT`. Looking up the generic and uninteresting `!{null}` gives you `SomeT`, which is likely related to `@GV`. Worse, `SomeT`'s lifetime may be tied to the deleted `@GV`. This occurs in practice in the shared ValueMap used since r266579 in the IRMover. Other code that handles more than one Module (with different lifetimes) in the same LLVMContext could hit it too. The fix here is a partial revert of r225223: in the rare case that an MDNode operand is a ConstantAsMetadata (i.e., wrapping a node from the Value hierarchy), drop uniquing if it gets replaced with `nullptr`. This changes step #4 above to leave behind `distinct !{null} -> SomeT`, which can't be confused with the generic `!{null}`. In theory, this can cause some churn in the LLVMContext's MDNode uniquing map when Values are being deleted. However: - The number of GlobalValues referenced from uniqued MDNodes is expected to be quite small. E.g., the debug info metadata schema only references GlobalValues from distinct nodes. - Other Constants have the lifetime of the LLVMContext, whose teardown is careful to drop references before deleting the constants. As a result, I don't expect a compile time regression from this change. llvm-svn: 277625
* Adding -verify-machineinstrs option to PowerPC testsEhsan Amiri2016-08-03625-943/+943
| | | | | | | | | | | Currently we have a number of tests that fail with -verify-machineinstrs. To detect this cases earlier we add the option to the testcases with the exception of tests that will currently fail with this option. PR 27456 keeps track of this failures. No code review, as discussed with Hal Finkel. llvm-svn: 277624
* [docs] fix typo in clang-rename docsKirill Bobyrev2016-08-031-3/+3
| | | | | | clang-rename is a refactoring tool, not "linter" tool. Fix typo in docs. llvm-svn: 277623
* [Hexagon-ish] Add function to print cell map contents in bit trackerKrzysztof Parzyszek2016-08-032-5/+10
| | | | llvm-svn: 277622
* [ASan] Report illegal instruction exceptions in ASanReid Kleckner2016-08-035-19/+59
| | | | | | | | | | | | | | | | | | | Summary: Respect the handle_sigill common flag and handle_segv flags while we're at it. We still handle signals/exceptions differently on Unix and Windows. The installation process is tricky on Windows, and difficult to push down into sanitizer_common without concerning it with the different static/dynamic CRT models on Windows. Reviewers: kcc, etienneb Subscribers: llvm-commits, kubabrecka Differential Revision: https://reviews.llvm.org/D23098 llvm-svn: 277621
* Disable KMP_CANCEL_THREADS on AndroidPirama Arumuga Nainar2016-08-031-0/+6
| | | | | | | | | | | | Summary: Android does not have pthread_cancel. Disable KMP_CANCEL_THREADS if __ANDROID__ is defined. Subscribers: tberghammer, srhines, openmp-commits, danalbert Differential Revision: https://reviews.llvm.org/D23029 llvm-svn: 277618
* lld-link: Include the name of bad input files in several "input file is bad" ↵Nico Weber2016-08-031-7/+7
| | | | | | | | | | diagnostics. Also change a few getName() calls to getShortName() calls. https://reviews.llvm.org/D23123 Part of PR28553. llvm-svn: 277616
* [StreamExecutor] Add KernelLoaderSpecJason Henline2016-08-036-0/+508
| | | | | | | | | | | | | | | Summary: Add definitions for the KernelLoaderSpec and MultiKernelLoaderSpec classes to StreamExecutor. Instances of these classes are generated by the compiler in order to provide host code with a handle to device code. Reviewers: jlebar, tra Subscribers: parallel_libs-commits Differential Revision: https://reviews.llvm.org/D23038 llvm-svn: 277615
* [CloneFunction] Don't crash if the value map doesn't hold somethingDavid Majnemer2016-08-031-1/+1
| | | | | | | | | It is possible for the value map to not have an entry for some value that has already been removed. I don't have a testcase, this is fall-out from a buildbot. llvm-svn: 277614
* [RenderScript] Always create a new allocation ID in CaptureAllocationInit hookLuke Drummond2016-08-032-12/+39
| | | | | | | | | | | | | | | | Due to internal reuse of buffers in the RenderScript runtime by the system allocator, comparing pointers is not a safe way to check whether an allocation is tracked by lldb. This change updates the lldb RenderScript internal hook callback to properly identify and remove old allocations that had have an address that is currently being tracked. This change also removes the need for `lldb_private::renderscript::LookupAllocation` to take a `create` flag, as this is now always the case. Original Author: <dean@codeplay.com> Subscribers: lldb-commits llvm-svn: 277613
* use local variables; NFCSanjay Patel2016-08-031-29/+23
| | | | llvm-svn: 277612
* [CloneFunction] Don't remove side effecting callsDavid Majnemer2016-08-033-4/+59
| | | | | | | | | | | We were able to figure out that the result of a call is some constant. While propagating that fact, we added the constant to the value map. This is problematic because it results in us losing the call site when processing the value map. This fixes PR28802. llvm-svn: 277611
* [ARM] Constant Materialize: imms with specific value can be encoded into mov.wWeiming Zhao2016-08-032-1/+20
| | | | | | | | | | | | Summary: Thumb2 supports encoding immediates with specific patterns into mov.w by splatting the low 8 bits into other bytes. Reviewers: john.brawn, jmolloy Subscribers: jmolloy, aemerson, rengolin, samparker, llvm-commits Differential Revision: https://reviews.llvm.org/D23090 llvm-svn: 277610
* [msf] Make FPM reader use MappedBlockStream.Zachary Turner2016-08-036-23/+65
| | | | | | | | | | | | | MappedBlockSTream can work with any sequence of block data where the ordering is specified by a list of block numbers. So rather than manually stitch them together in the case of the FPM, reuse this functionality so that we can treat the FPM as if it were contiguous. Reviewed By: ruiu Differential Revision: https://reviews.llvm.org/D23066 llvm-svn: 277609
* Fix an unused variable warning in release builds.Luke Drummond2016-08-031-1/+1
| | | | | | | | | | | | ``num_params`` was unused in RenderScript ABI fixup pass ``cloneToStructRetFnTy`` and was only used in an `assert()` that the number of function parameters for the cloned function was correct. Now we actually use this variable, rather than recomputing it, and avoid the unused variable warning when building without asserts enabled. Subscribers: lldb-commits llvm-svn: 277608
* Revert "Teach CorrelatedValuePropagation to mark adds as no wrap"Renato Golin2016-08-032-148/+0
| | | | | | This reverts commit r277592, trying to fix the AArch64 42VMA buildbot. llvm-svn: 277607
* Hexagon: Use llvm_unreachable. NFC.Benjamin Kramer2016-08-031-1/+1
| | | | llvm-svn: 277605
* [compiler-rt] Fix CHECK coding style [NFC]Etienne Bergeron2016-08-033-8/+8
| | | | llvm-svn: 277604
* Fix bug in conflict check for Replacements::add().Manuel Klimek2016-08-032-7/+28
| | | | | | | We would not detect conflicts when inserting insertions at the same offset as previously contained replacements. llvm-svn: 277603
* Disable shrinking of SNaN constantsElliot Colp2016-08-032-11/+32
| | | | | | | | | When expanding FP constants, we attempt to shrink doubles to floats and perform an extending load. However, on SystemZ, and possibly on other targets (I've only confirmed the problem on SystemZ), the FP extending load instruction may convert SNaN into QNaN, or may cause an exception. So in the general case, we would still like to shrink FP constants, but SNaNs should be left as doubles. Differential Revision: https://reviews.llvm.org/D22685 llvm-svn: 277602
* [Hexagon] Do not check alignment for unsized types in isLegalAddressingModeKrzysztof Parzyszek2016-08-032-7/+74
| | | | | | | | When the same base address is used to load two different data types, LSR would assume a memory type of "void". This type is not sized and has no alignment information. Checking for it causes a crash. llvm-svn: 277601
* Revert an unintentional change from r277599Nico Weber2016-08-031-7/+7
| | | | llvm-svn: 277600
* Revert 277594, it caused PR28827Nico Weber2016-08-034-16/+19
| | | | llvm-svn: 277599
* add a vector variant of each testSanjay Patel2016-08-031-0/+172
| | | | llvm-svn: 277598
* Fix quadratic runtime when adding items to tooling::Replacements.Manuel Klimek2016-08-032-18/+90
| | | | | | | | | | | Previously, we would search through all replacements when inserting a new one to check for overlaps. Instead, make use of the fact that we already have a set of replacments without overlaps to find the potential overlap with lower_bound. Differential Revision: https://reviews.llvm.org/D23119 llvm-svn: 277597
* [InstCombine] Add select-bitext.ll testsNicolai Haehnle2016-08-031-0/+214
| | | | | | As requested for D22747. llvm-svn: 277596
* [Loop Vectorizer] Move store-predication into its own function, remove ↵Gil Rapaport2016-08-031-12/+18
| | | | | | | | obsolete comment (NFC) Differential Revision: https://reviews.llvm.org/D23013 llvm-svn: 277595
* Remove redundant argument.Rafael Espindola2016-08-033-12/+9
| | | | llvm-svn: 277594
* Teach CorrelatedValuePropagation to mark adds as no wrapArtur Pilipenko2016-08-032-0/+148
| | | | | | | | | | Use LVI to prove that adds do not wrap. The change is motivated by https://llvm.org/bugs/show_bug.cgi?id=28620 bug and it's the first step to fix that problem. Reviewed By: sanjoy Differential Revision: http://reviews.llvm.org/D23059 llvm-svn: 277592
* GPGPU: Mark kernel functions as polly.skipTobias Grosser2016-08-037-7/+11
| | | | | | | | | Otherwise, we would try to re-optimize them with Polly-ACC and possibly even generate kernels that try to offload themselves, which does not work as the GPURuntime is not available on the accelerator and also does not make any sense. llvm-svn: 277589
* [AVX512] Add aliases for vcvttss2si{l|q}, vcvttsd2si{l|q}, vcvttss2usi{l|q}, ↵Igor Breger2016-08-032-34/+170
| | | | | | | | vcvttsd2usi{l|q} instructions. Differential Revision: http://reviews.llvm.org/D23111 llvm-svn: 277586
* Fix the BUILD_SHARED_LIBS=ON build, was getting the following error while ↵Ismail Donmez2016-08-031-0/+1
| | | | | | | | linking liblldb.so: ../include/llvm/Target/TargetOptions.h:104: error: undefined reference to 'llvm::TargetRecip::TargetRecip()' llvm-svn: 277585
* [PM] Fix a mis-named parameter in parseLoopPass -- the pass manager wasChandler Carruth2016-08-031-6/+6
| | | | | | | called "FPM" instead of "LPM" in a hold-over from when the code was modeled on that used to parse function passes. llvm-svn: 277584
* [ELF] - Linkerscript: support all kinds of sorting (including nested).George Rimar2016-08-036-24/+150
| | | | | | | | | | | | | | | | | | | | | | | | | | | Previously we supported only sorting by name. When there are nested section sorting commands in linker script, there can be at most 1 level of nesting for section sorting commands. SORT_BY_NAME (SORT_BY_ALIGNMENT (wildcard section pattern)). It will sort the input sections by name first, then by alignment if 2 sections have the same name. SORT_BY_ALIGNMENT (SORT_BY_NAME (wildcard section pattern)). It will sort the input sections by alignment first, then by name if 2 sections have the same alignment. SORT_BY_NAME (SORT_BY_NAME (wildcard section pattern)) is treated the same as SORT_ BY_NAME (wildcard section pattern). SORT_BY_ALIGNMENT (SORT_BY_ALIGNMENT (wildcard section pattern)) is treated the same as SORT_BY_ALIGNMENT (wildcard section pattern). All other nested section sorting commands are invalid. Patch implements that all above. Differential revision: https://reviews.llvm.org/D23019 llvm-svn: 277583
* [PM] Add the explicit copy, move, swap, and assignment boilerplateChandler Carruth2016-08-031-1/+16
| | | | | | | | | | | | required by MSVC 2013. This also makes the repeating pass wrapper assignable. Mildly unfortunate as it means we can't use a const member for the int, but that is a really minor invariant to try to preserve at the cost of loss of regularity of the type. Yet another annoyance of the particular C++ object / move semantic model. llvm-svn: 277582
* [PM] Add a generic 'repeat N times' pass wrapper to the new passChandler Carruth2016-08-033-7/+188
| | | | | | | | | | | | | | | | | | | | | | | | manager. While this has some utility for debugging and testing on its own, it is primarily intended to demonstrate the technique for adding custom wrappers that can provide more interesting interation behavior in a nice, orthogonal, and composable layer. Being able to write these kinds of very dynamic and customized controls for running passes was one of the motivating use cases of the new pass manager design, and this gives a hint at how they might look. The actual logic is tiny here, and most of this is just wiring in the pipeline parsing so that this can be widely used. I'm adding this now to show the wiring without a lot of business logic. This is a precursor patch for showing how a "iterate up to N times as long as we devirtualize a call" utility can be added as a separable and composable component along side the CGSCC pass management. Differential Revision: https://reviews.llvm.org/D22405 llvm-svn: 277581
* [XRay] Make the xray_instr_map section specification more correctDean Michael Berris2016-08-032-4/+25
| | | | | | | | | | | | | | | | | | | | | | | | | Summary: We also add a test to show what currently happens when we create a section per function and emit an xray_instr_map. This illustrates the relationship (or lack thereof) between the per-function section and the xray_instr_map section. We also change the code generation slightly so that we don't always create group sections, but rather only do so if a function where the table is associated with is in a group. Also in this change: - Remove the "merge" flag on the xray_instr_map section. - Test that we're generating the right table for comdat and non-comdat functions. Reviewers: echristo, majnemer Subscribers: llvm-commits, mehdi_amini Differential Revision: https://reviews.llvm.org/D23104 llvm-svn: 277580
* [compiler-rt] Remove incorrect folder layout for scudo.Etienne Bergeron2016-08-030-0/+0
| | | | | | | | | | | | | | | | | Summary: This code got landed and it's a mistake. I suspect an incorrect patch was uploaded/applied. The folders seems to be created here: https://reviews.llvm.org/D23018 Reviewers: rnk Subscribers: llvm-commits, chrisha, kcc Differential Revision: https://reviews.llvm.org/D23109 llvm-svn: 277579
* [extra-tools] Fix extra tools build bot warnings due to incorrect docEtienne Bergeron2016-08-031-2/+2
| | | | | | | /home/llvmbb/llvm-build-dir/clang-x86_64-debian-fast/llvm.src/tools/clang/tools/extra/clang-tidy/mpi/TypeMismatchCheck.cpp:172:12: warning: parameter 'Complex' not found in the function declaration [-Wdocumentation] /home/llvmbb/llvm-build-dir/clang-x86_64-debian-fast/llvm.src/tools/clang/tools/extra/clang-tidy/mpi/TypeMismatchCheck.cpp:206:12: warning: parameter 'Complex' not fo llvm-svn: 277578
* [clang-tidy] address concerns with rL277340Kirill Bobyrev2016-08-031-18/+18
| | | | | | | | | | alexfh raised a concern with https://reviews.llvm.org/rL277340 After retabbing indentation of .. code-block:: was increased to 8, 4 spaces indentation should be enough. Reviewers: alexfh llvm-svn: 277577
* [clang/test] Fix a flaky unittest on windowsEtienne Bergeron2016-08-031-4/+10
| | | | | | | | | | | | | | | | | | | | Summary: The append operator on a shell command for quick command-line is causing trouble on windows. [NFC] The easiest way to fix them is to avoid using them. This patch is an attempt to fix this broken build bot: clang-x86-win2008-selfhost http://lab.llvm.org:8011/builders/clang-x86-win2008-selfhost/builds/9523 Reviewers: rnk Subscribers: cfe-commits, chrisha Differential Revision: https://reviews.llvm.org/D23105 llvm-svn: 277576
* Add MSVC specifics to .gitignore. Patch from STL@microsoft.comEric Fiselier2016-08-031-0/+4
| | | | llvm-svn: 277575
* Fix compile error due to mismatched iterator types. Patch from STL@microsoft.comEric Fiselier2016-08-031-1/+1
| | | | llvm-svn: 277574
* Fix an MSVC x64 compiler warning. Patch from STL@microsoft.comEric Fiselier2016-08-033-9/+12
| | | | llvm-svn: 277573
* Silence another occurrence of MSVC's suprious unused warning. Patch from ↵Eric Fiselier2016-08-031-1/+4
| | | | | | STL@microsoft.com llvm-svn: 277572
OpenPOWER on IntegriCloud