summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* [MC] Use LShr for constant evaluation of ">>" on non-arm64 darwin.Ahmed Bougacha2015-11-115-15/+4
| | | | | | | Follow-up to r235963: this matches other assemblers and is less unexpected (e.g. PR23227). llvm-svn: 252681
* [static analyzer] Don't flag nil storage into NSMutableDictionary.Anna Zaks2015-11-112-4/+2
| | | | | | This is now allowed and has the behavior of removing the mapping. llvm-svn: 252679
* MachineInstr: addRegisterDefReadUndef() => setRegisterDefReadUndef()Matthias Braun2015-11-113-4/+4
| | | | | | This way we can not only add but also remove read undef flags. llvm-svn: 252678
* AMDGPU: Print more fields in commentsMatt Arsenault2015-11-111-3/+14
| | | | llvm-svn: 252677
* [ValueTracking] Remove untested / unreachable code, NFCSanjoy Das2015-11-111-18/+5
| | | | | | | | Right now isTruePredicate is only ever called with Pred == ICMP_SLE or ICMP_ULE, and the ICMP_SLT and ICMP_ULT cases are dead. This change removes the untested dead code so that the function is not misleading. llvm-svn: 252676
* AMDGPU: Remove dead codeMatt Arsenault2015-11-111-33/+2
| | | | llvm-svn: 252675
* AMDGPU: Set isAllocatable = 0 on VS_32/VS_64Matt Arsenault2015-11-115-19/+9
| | | | llvm-svn: 252674
* [ValueTracking] Teach isImpliedCondition a new bitwise trickSanjoy Das2015-11-102-0/+108
| | | | | | | | | | | | | | | | | | | Summary: This change teaches isImpliedCondition to prove things like (A | 15) < L ==> (A | 14) < L if the low 4 bits of A are known to be zero. Depends on D14391 Reviewers: majnemer, reames, hfinkel Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D14392 llvm-svn: 252673
* [ValueTracking] Use m_APInt instead of m_ConstantInt, NFCSanjoy Das2015-11-101-7/+8
| | | | | | | | This change would add functionality if isImpliedCondition worked on vector types; but since it bail out on vector predicates this change is an NFC. llvm-svn: 252672
* TableGen: Emit LaneMask for register classes without subregisters as ~0uMatthias Braun2015-11-102-10/+19
| | | | | | | This makes it slightly easier to handle classes with and without subregister uniformly. llvm-svn: 252671
* [WinEH] Insert the MBB for EH_RESTORE after the catchretReid Kleckner2015-11-102-1/+47
| | | | | | | Inserting it before the target block could be bad, we might already have a fallthrough edge to it. llvm-svn: 252670
* [cmake] move SONAME handling to llvm_add_libraryAndrew Wilkins2015-11-101-14/+19
| | | | | | | | | | | | | | | | | | | | Summary: Move handling of the SONAME option from add_llvm_library to llvm_add_library, so that it can be used in sub-projects. In particular, this makes it possible to have consistently named shared libraries for LLVM, Clang and LLDB. Also, base the SONAME and symlinks on the output name by extracting the OUTPUT_NAME property, rather than assuming it is the same as the target name. Reviewers: beanz Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D14539 llvm-svn: 252669
* Define __unsafe_unretained and __autoreleasing in ObjC GC mode.John McCall2015-11-102-0/+6
| | | | | | This was an accidental regression from the MRC __weak patch. llvm-svn: 252668
* Fix buildJonathan Roelofs2015-11-101-1/+1
| | | | llvm-svn: 252667
* don't repeat function/class/variable names in comments; NFCSanjay Patel2015-11-101-143/+127
| | | | llvm-svn: 252666
* Made the ClangASTImporter into a shared pointer, eliminating a race condition.Sean Callanan2015-11-107-63/+60
| | | | | | | | | | | | | | | It used to be a unique pointer, and there could be a case where ClangASTSource held onto a copy of the pointer but Target::Destroy destroyed the unique pointer in the mean time. I also ensured that there is a validity check on the target (which confirms that a ClangASTImporter can be generated) before the target's shared pointer is copied into ClangASTSource. This race condition caused a crash if Target::Destroy was called and then later the target objecct was deleted. llvm-svn: 252665
* Implement post-commit review feedback on r252662Jonathan Roelofs2015-11-102-10/+8
| | | | llvm-svn: 252664
* Introduce a way for Languages to specify whether values of "reference types" ↵Enrico Granata2015-11-108-185/+253
| | | | | | | | | | are "nil" (not pointing to anything) or uninitialized (never made to point at anything) This latter determination may or may not be possible on a per-language basis; and neither is mandatory to implement for any language Use this knowledge in the ValueObjectPrinter to generalize the notion of IsObjCNil() and the respective printout llvm-svn: 252663
* Implement the fix that r252641 should have beenJonathan Roelofs2015-11-102-15/+24
| | | | llvm-svn: 252662
* Fix Clang-tidy modernize-use-auto warnings, other minor fixes.Eugene Zelenko2015-11-1013-109/+53
| | | | | | Differential revision: http://reviews.llvm.org/D14553 llvm-svn: 252661
* [doc] Compile CUDA with LLVMJingyue Wu2015-11-102-0/+196
| | | | | | | | | | | | | | | | | | | | | | | | | Summary: This patch adds documentation on compiling CUDA with LLVM as requested by many engineers and researchers. It includes not only user guides but also some internals (mostly optimizations) so that early adopters can start hacking and contributing. Quite a few researchers who contacted us haven't used LLVM before, which is unsurprising as it hasn't been long since LLVM picked up CUDA. So I added a short summary to help these folks get started with LLVM. I expect this document to evolve substantially down the road. The user guides will be much simplified after the Clang integration is done. However, the internals should continue growing to include for example performance debugging and key areas to improve. Reviewers: chandlerc, meheff, broune, tra Subscribers: silvas, jingyue, llvm-commits, eliben Differential Revision: http://reviews.llvm.org/D14370 llvm-svn: 252660
* [COFF] Don't try to emit weak aliases on COFFReid Kleckner2015-11-102-5/+26
| | | | | | | | | | | | | | | | | This comes up when a derived class destructor is equivalent to a base class destructor defined in the same TU, and we try to alias them. A COFF weak alias cannot satisfy a normal undefined symbol reference from another TU. The other TU must also mark the referenced symbol as weak, and we can't rely on that. Clang already has a special case here for dllexport, but we failed to realize that the problem also applies to other non-discardable symbols such as those from explicit template instantiations. Fixes PR25477. llvm-svn: 252659
* [libFuzzer] add UninstrumentedTest.cpp (missing from a previous commit)Kostya Serebryany2015-11-101-0/+8
| | | | llvm-svn: 252658
* Updated a relative path in Makefile.rules to reflect the new testsuite location.Sean Callanan2015-11-101-1/+1
| | | | llvm-svn: 252657
* [WebAssembly] Remove special cases for things that are no longer special. NFC.Dan Gohman2015-11-101-16/+0
| | | | llvm-svn: 252656
* Fixed a bug where the size of a type was used instead of the size of a pointer.Sean Callanan2015-11-101-1/+1
| | | | llvm-svn: 252655
* Add PPCMIPeephole.cpp to CMakeLists.txtBill Schmidt2015-11-101-0/+1
| | | | llvm-svn: 252654
* [WebAssembly] Support for floating point min and max.Dan Gohman2015-11-104-7/+54
| | | | llvm-svn: 252653
* [CMake] Autoconf builds libLTO with -fPIC, CMake should be able to as well.Chris Bieneman2015-11-101-1/+1
| | | | llvm-svn: 252652
* [PowerPC] Add an MI SSA peephole pass.Bill Schmidt2015-11-1011-28/+322
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch adds a pass for doing PowerPC peephole optimizations at the MI level while the code is still in SSA form. This allows for easy modifications to the instructions while depending on a subsequent pass of DCE. Both passes are very fast due to the characteristics of SSA. At this time, the only peepholes added are for cleaning up various redundancies involving the XXPERMDI instruction. However, I would expect this will be a useful place to add more peepholes for inefficiencies generated during instruction selection. The pass is placed after VSX swap optimization, as it is best to let that pass remove unnecessary swaps before performing any remaining clean-ups. The utility of these clean-ups are demonstrated by changes to four existing test cases, all of which now have tighter expected code generation. I've also added Eric Schweiz's bugpoint-reduced test from PR25157, for which we now generate tight code. One other test started failing for me, and I've fixed it (test/Transforms/PlaceSafepoints/finite-loops.ll) as well; this is not related to my changes, and I'm not sure why it works before and not after. The problem is that the CHECK-NOT: of "statepoint" from test1 fails because of the "statepoint" in test2, and so forth. Adding a CHECK-LABEL in between keeps the different occurrences of that string properly scoped. llvm-svn: 252651
* dsymutil: Prune module forward decl DIEs if a uniquable definition wasAdrian Prantl2015-11-103-16/+29
| | | | | | | | | | already emitted and fix a latent bug in DIECloner where the DW_CHILDREN_yes flag is set based on the number of children in the input DIE rather than the number of children that are actually being cloned. rdar://problem/23439845 llvm-svn: 252649
* Implement __attribute__((internal_linkage)).Evgeniy Stepanov2015-11-1012-17/+279
| | | | | | | | | | | | | | The attrubite is applicable to functions and variables and changes the linkage of the subject to internal. This is the same functionality as C-style "static", but applicable to class methods; and the same as anonymouns namespaces, but can apply to individual methods of a class. Following the proposal in http://lists.llvm.org/pipermail/cfe-dev/2015-October/045580.html llvm-svn: 252648
* Ensure ModuleLinker materializes complete comdat groupsTeresa Johnson2015-11-104-16/+37
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: The module linker lazy links some "discardable if unused" global values (e.g. linkonce), materializing and linking them only if they are referenced in the module. If a comdat group contains a linkonce member that is not referenced, however, it would not be materialized and linked, leading to an incomplete comdat group. If there are other object files not part of the same LTO link that also define and use that comdat group, the linker may select the incomplete group leading to link time unsats. To solve this, whenever a global value body is linked, make sure we materialize any other members of the same comdat group that are not yet materialized. This ensures they are in the lazy link list and get linked as well. Added new test and adjusted old test to remove parts that didn't make sense with fix. Reviewers: rafael Subscribers: dexonsmith, davidxl, llvm-commits Differential Revision: http://reviews.llvm.org/D14516 llvm-svn: 252647
* [WebAssembly] Change long double to be quadruple-precision floating point.Dan Gohman2015-11-105-30/+32
| | | | llvm-svn: 252646
* [IR] Make {Call,Invoke}::cloneImpl aware of operand bundlesSanjoy Das2015-11-101-0/+8
| | | | | | | | | This was an omission in the patch that landed initial support for operand bundles. So far we haven't hit this, but we will once the inliner is able to inline calls to functions that contain calls with operand bundles. llvm-svn: 252645
* [OperandBundles] Identify operand bundles with both their names and IDsSanjoy Das2015-11-104-8/+56
| | | | | | | No code uses this functionality yet. This change just exposes information / structure that was already present. llvm-svn: 252644
* less indent; NFCISanjay Patel2015-11-101-46/+47
| | | | llvm-svn: 252643
* Updated lldb_pylint_helper to work with recent Python package changes.Todd Fiala2015-11-101-15/+27
| | | | llvm-svn: 252642
* Fix missing CMake dependency introduced in r252474Jonathan Roelofs2015-11-102-6/+12
| | | | llvm-svn: 252641
* Add the variant of __sparc_v9__ with five underscores, not just four.Joerg Sonnenberger2015-11-102-1/+6
| | | | llvm-svn: 252640
* [ARM] add overrides for isCheapToSpeculateCttz() and isCheapToSpeculateCtlz()Sanjay Patel2015-11-104-0/+59
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ARM V6T2 has instructions for efficient count-leading/trailing-zeros, so this should be considered a cheap operation (and therefore fair game for speculation) for any ARM V6T2 implementation. The net result of allowing this speculation for the regression tests in this patch is that we get this code: ctlz: clz r0, r0 bx lr cttz: rbit r0, r0 clz r0, r0 bx lr Instead of: ctlz: cmp r0, #0 moveq r0, #32 clzne r0, r0 bx lr cttz: cmp r0, #0 moveq r0, #32 rbitne r0, r0 clzne r0, r0 bx lr This will help solve a general speculation/despeculation problem noted in PR24818: https://llvm.org/bugs/show_bug.cgi?id=24818 Differential Revision: http://reviews.llvm.org/D14469 llvm-svn: 252639
* Upstream changes to the ValueObjectPrinter; nfcEnrico Granata2015-11-104-339/+467
| | | | llvm-svn: 252638
* This test is now passing on DarwinEnrico Granata2015-11-101-1/+0
| | | | llvm-svn: 252637
* llvm-lto: trivial spelling changes to distinguish custom diagnostic handler andYunzhong Gao2015-11-102-1/+4
| | | | | | | | default diagnostic handler. Differential Revision: http://reviews.llvm.org/D14520 llvm-svn: 252633
* LegalizeDAG: Implement promote for scalar_to_vectorMatt Arsenault2015-11-101-0/+28
| | | | | | | | | | | This allows avoiding the default Expand behavior which introduces stack usage. Bitcast the scalar and replace the missing elements with undef. This is covered by existing tests and used by a future commit which makes 64-bit vectors legal types on AMDGPU. llvm-svn: 252632
* LegalizeDAG: Implement promote for insert_vector_eltMatt Arsenault2015-11-101-1/+52
| | | | | | | This is covered by existing tests and used by a future commit which makes 64-bit vectors legal types on AMDGPU. llvm-svn: 252631
* LegalizeDAG: Implement promote for extract_vector_eltMatt Arsenault2015-11-101-4/+58
| | | | | | | | | | This is for AMDGPU to implement v2i64 extract as extract of half of a v4i32. This is covered by existing tests and used by a future commit which makes 64-bit vectors legal types on AMDGPU. llvm-svn: 252630
* [ValueTracking] Recognize that and(x, add (x, -1)) clears the low bitPhilip Reames2015-11-102-0/+81
| | | | | | | | | | This is a cleaned up version of a patch by John Regehr with permission. Originally found via the souper tool. If we add an odd number to x, then bitwise-and the result with x, we know that the low bit of the result must be zero. Either it was zero in x originally, or the add cleared it in the temporary value. As a result, one of the two values anded together must have the bit cleared. Differential Revision: http://reviews.llvm.org/D14315 llvm-svn: 252629
* AddLLVM: squelch CMP0007 by not adding empty elements to listRamkumar Ramachandra2015-11-101-3/+2
| | | | | | | | | | | | | When configuring various llvm projects that use AddLLVM.cmake, this warning is emitted many times, flooding the screen: Policy CMP0007 is not set: list command no longer ignores empty elements. The fix is removing an extra semicolon. Differential Revision: http://reviews.llvm.org/D14339 llvm-svn: 252628
* [ThinLTO] Update comment per change in WeakAny handling (NFC)Teresa Johnson2015-11-101-1/+3
| | | | llvm-svn: 252627
OpenPOWER on IntegriCloud