summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* 'into' instruction should not be decoded as a valid instr in 64-bit modeAndrew V. Tischenko2017-09-202-1/+7
| | | | llvm-svn: 313735
* Revert rL313697, "Compact EhSectionPiece from 32 bytes to 16 bytes."NAKAMURA Takumi2017-09-207-47/+33
| | | | | | | It broke selfhosting. http://lab.llvm.org:8011/builders/clang-with-lto-ubuntu/builds/4896 llvm-svn: 313731
* [clangd] Introduced Logger interface.Ilya Biryukov2017-09-2016-144/+238
| | | | | | | | | | | | | | Summary: This fixes a bunch of logging-related FIXMEs. Reviewers: bkramer, krasimir, malaperle Reviewed By: malaperle Subscribers: malaperle, klimek, cfe-commits, mgorny Differential Revision: https://reviews.llvm.org/D37972 llvm-svn: 313730
* Implement C++ [basic.link]p8.Richard Smith2017-09-2015-56/+180
| | | | | | | | | | | | | | If a function or variable has a type with no linkage (and is not extern "C"), any use of it requires a definition within the same translation unit; the idea is that it is not possible to define the entity elsewhere, so any such use is necessarily an error. There is an exception, though: some types formally have no linkage but nonetheless can be referenced from other translation units (for example, this happens to anonymous structures defined within inline functions). For entities with those types, we suppress the diagnostic except under -pedantic. llvm-svn: 313729
* [asan] Try to fix windows test by fflush(stderr)Vitaly Buka2017-09-201-0/+1
| | | | llvm-svn: 313728
* [asan] Resolve FIXME by converting gtest into lit testVitaly Buka2017-09-202-17/+20
| | | | llvm-svn: 313727
* Signal polling is supported with pselect (re-land r313704 without a Windows ↵Eugene Zemtsov2017-09-202-5/+5
| | | | | | | | | breakage) Older Android API levels don't have ppoll, but LLDB works just fine, since on Android it always uses pselect anyway. llvm-svn: 313726
* Revert "Add support for attribute 'noescape'."Akira Hatanaka2017-09-2021-486/+24
| | | | | | | | | | This reverts commit r313722. It looks like compiler-rt/lib/tsan/rtl/tsan_libdispatch_mac.cc cannot be compiled because some of the functions declared in the file do not match the ones in the SDK headers (which are annotated with 'noescape'). llvm-svn: 313725
* [X86] Remove isel checks for immediate size on floating point compare and ↵Craig Topper2017-09-203-36/+26
| | | | | | | | xop compare instructions. NFCI If these checks fail we end up not selecting an instruction at all. So we are already relying on the immediate being checked upstream of isel. So doing the check in isel is just bloat to the isel table. Interestingly, we didn't check on the AVX512 version of the instructions anyway. llvm-svn: 313724
* [AMDGPU] Fixed memory leak with inliner replacedStanislav Mekhanoshin2017-09-201-1/+3
| | | | | | Delete inliner before replacing it. llvm-svn: 313723
* Add support for attribute 'noescape'.Akira Hatanaka2017-09-2021-24/+486
| | | | | | | | | | | | | | | The attribute informs the compiler that the annotated pointer parameter of a function cannot escape and enables IRGen to attach attribute 'nocapture' to parameters that are annotated with the attribute. That is the only optimization that currently takes advantage of 'noescape', but there are other optimizations that will be added later that improves IRGen for ObjC blocks. rdar://problem/19886775 Differential Revision: https://reviews.llvm.org/D32210 llvm-svn: 313722
* Revert "Add support for attribute 'noescape'."Akira Hatanaka2017-09-2021-486/+24
| | | | | | | | This reverts r313717. I closed the wrong phabricator review. llvm-svn: 313721
* Add support for attribute 'noescape'.Akira Hatanaka2017-09-2021-24/+486
| | | | | | | | | | | | | | | The attribute informs the compiler that the annotated pointer parameter of a function cannot escape and enables IRGen to attach attribute 'nocapture' to parameters that are annotated with the attribute. That is the only optimization that currently takes advantage of 'noescape', but there are other optimizations that will be added later that improves IRGen for ObjC blocks. rdar://problem/19886775 Differential Revision: https://reviews.llvm.org/D32520 llvm-svn: 313720
* AMDGPU: Move r600 only code into r600 only td fileMatt Arsenault2017-09-202-53/+54
| | | | llvm-svn: 313719
* [AMDGPU] Fix regression in test clang/test/CodeGen/backend-unsupported-error.llStanislav Mekhanoshin2017-09-201-1/+2
| | | | llvm-svn: 313718
* [Sema][ObjC] Warn about mismatches in attributes between overriding andAkira Hatanaka2017-09-205-36/+52
| | | | | | | | | | | | | overridden methods when compiling for non-ARC. Previously, clang would error out when compiling for ARC, but didn't print any diagnostics when compiling for non-ARC. This was pointed out in the patch review for attribute noescape: https://reviews.llvm.org/D32210 llvm-svn: 313717
* AMDGPU: Match load d16 hi instructionsMatt Arsenault2017-09-2010-66/+686
| | | | | | | | | | | | Also starts selecting global loads for constant address in some cases. Some end up selecting to mubuf still, which requires investigation. We still get sub-optimal regalloc and extra waitcnts inserted due to not really tracking the liveness of the separate register halves. llvm-svn: 313716
* DiagnosticInfoOptimizationBase: Appease g++-4.8.2 not confused to add an ↵NAKAMURA Takumi2017-09-201-1/+1
| | | | | | explicit type to resolve emit() as non-template function. llvm-svn: 313715
* [AMDGPU] Port of HSAIL inlinerStanislav Mekhanoshin2017-09-207-16/+375
| | | | | | Differential Revision: https://reviews.llvm.org/D36849 llvm-svn: 313714
* AMDGPU: Cleanup load/store PatFragsMatt Arsenault2017-09-207-271/+244
| | | | | | Try to use a consistent naming scheme. llvm-svn: 313713
* AMDGPU: Match store d16_hi instructionsMatt Arsenault2017-09-207-24/+678
| | | | llvm-svn: 313712
* Tighten the invariants around LoopBase::invalidateSanjoy Das2017-09-209-58/+132
| | | | | | | | | | | | | | | | | Summary: With this change: - Methods in LoopBase trip an assert if the receiver has been invalidated - LoopBase::clear frees up the memory held the LoopBase instance This change also shuffles things around as necessary to work with this stricter invariant. Reviewers: chandlerc Subscribers: mehdi_amini, mcrosier, llvm-commits Differential Revision: https://reviews.llvm.org/D38055 llvm-svn: 313708
* Rollback r313704 because of the Windows build breakEugene Zemtsov2017-09-202-6/+5
| | | | llvm-svn: 313707
* Reverting due to Green Dragon bot failure.Mike Edwards2017-09-2014-128/+8
| | | | | | http://green.lab.llvm.org/green/job/clang-stage1-cmake-RA-incremental/42594/ llvm-svn: 313706
* Clang-format few files to make later diffs leaner; NFCSanjoy Das2017-09-203-191/+186
| | | | llvm-svn: 313705
* Signal polling is supported with pselectEugene Zemtsov2017-09-202-5/+6
| | | | | | | Older Android API levels don't have ppoll, but LLDB works just fine, since on Android it always uses pselect anyway. llvm-svn: 313704
* [COFF] Adjust secrel limit checkShoaib Meenai2017-09-201-1/+4
| | | | | | | | | | | | | | | According to Microsoft's PE/COFF documentation, a SECREL relocation is "The 32-bit offset of the target from the beginning of its section". By my reading, the "from the beginning of its section" implies that the offset is unsigned. Change from an assertion to an error, since it's possible to trigger this condition normally for input files with very large sections, and we should fail gracefully for those instead of asserting. Differential Revision: https://reviews.llvm.org/D38020 llvm-svn: 313703
* GVNSink: Make ModelledPHIs constructor linear (and avoid edge case it ↵Daniel Berlin2017-09-201-7/+8
| | | | | | worries about) by avoiding getIncomingValueForBlock llvm-svn: 313702
* Revert "[GVNSink] Remove dependency on SmallPtrSet iteration order."Daniel Berlin2017-09-201-2/+0
| | | | | | This reverts commit r312156, because now the op and block arrays are not in the same order :(. llvm-svn: 313701
* NewGVN: Remove unused includesDaniel Berlin2017-09-201-21/+0
| | | | llvm-svn: 313700
* [COFF] Check for sections larger than 4 GiBShoaib Meenai2017-09-193-0/+19
| | | | | | | | | | Sections are limited to 4 GiB. Error out early if a section exceeds this size, rather than overflowing the section size and getting confusing assertion failures/segfaults later. Differential Revision: https://reviews.llvm.org/D38005 llvm-svn: 313699
* Make lit stop writing pyc files.Zachary Turner2017-09-192-0/+5
| | | | | | | | | | | | Many svn-based buildbots seem to be getting stuck continually in tree conflicts due to the output of pyc files. I'm disabling these as a temporary measure in an attempt to get everything stable again. I'll try to remove this code once I understand the problem better. llvm-svn: 313698
* Compact EhSectionPiece from 32 bytes to 16 bytes.Rui Ueyama2017-09-197-33/+47
| | | | | | | | | | | | | | EhSectionPiece used to have a pointer to a section, but that pointer was mostly redundant because we almost always know what the section is without using that pointer. This patch removes the pointer from the struct. This patch also use uint32_t/int32_t instead of size_t to represent offsets that are hardly be larger than 4 GiB. At the moment, I think it is OK even if we cannot handle .eh_frame sections larger than 4 GiB. Differential Revision: https://reviews.llvm.org/D38012 llvm-svn: 313697
* [MIRPrinter] Print empty successor lists when they cannot be guessedQuentin Colombet2017-09-193-3/+58
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This re-applies commit r313685, this time with the proper updates to the test cases. Original commit message: Unreachable blocks in the machine instr representation are these weird empty blocks with no successors. The MIR printer used to not print empty lists of successors. However, the MIR parser now treats non-printed list of successors as "please guess it for me". As a result, the parser tries to guess the list of successors and given the block is empty, just assumes it falls through the next block (if any). For instance, the following test case used to fail the verifier. The MIR printer would print entry / \ true (def) false (no list of successors) | split.true (use) The MIR parser would understand this: entry / \ true (def) false | / <-- invalid edge split.true (use) Because of the invalid edge, we get the "def does not dominate all uses" error. The fix consists in printing empty successor lists, so that the parser knows what to do for unreachable blocks. rdar://problem/34022159 llvm-svn: 313696
* [LoopInfo] Make LoopBase and Loop destructors non-publicSanjoy Das2017-09-197-175/+40
| | | | | | | | | | | | | | | | | | | Summary: See comment for why I think this is a good idea. This change also: - Removes an SCEV test case. The SCEV test was not testing anything useful (most of it was `#if 0` ed out) and it would need to be updated to deal with a private ~Loop::Loop. - Updates the loop pass manager test case to deal with a private ~Loop::Loop. - Renames markAsRemoved to markAsErased to contrast with removeLoop, via the usual remove vs. erase idiom we already have for instructions and basic blocks. Reviewers: chandlerc Subscribers: mehdi_amini, mcrosier, llvm-commits Differential Revision: https://reviews.llvm.org/D37996 llvm-svn: 313695
* [libc++] Replace __sync_* functions with __libcpp_atomic_* functionsWeiming Zhao2017-09-197-12/+34
| | | | | | | | | | | | | | | | Summary: This patch replaces __sync_* with __libcpp_atomic_* and adds a wrapper function for __atomic_exchange to support _LIBCPP_HAS_NO_THREADS. Reviewers: EricWF, jroelofs, mclow.lists, compnerd Reviewed By: EricWF, compnerd Subscribers: compnerd, efriedma, cfe-commits, joerg, llvm-commits Differential Revision: https://reviews.llvm.org/D35235 llvm-svn: 313694
* Add override for ClangDiagnosticHandler::isAnyRemarkEnabled()Adam Nemet2017-09-191-0/+6
| | | | | | | This is used by the new closure-based variant of OptimizationRemarkEmitter::emit(). llvm-svn: 313693
* [WebAssembly] Add support for naming wasm data segmentsSam Clegg2017-09-1914-8/+128
| | | | | | | | | Add adds support for naming data segments. This is useful useful linkers so that they can merge similar sections. Differential Revision: https://reviews.llvm.org/D37886 llvm-svn: 313692
* Allow ORE.emit to take a closure to delay building the remark objectAdam Nemet2017-09-198-34/+138
| | | | | | | | | | | In the lambda we are now returning the remark by value so we need to preserve its type in the insertion operator. This requires making the insertion operator generic. I've also converted a few cases to use the new API. It seems to work pretty well. See the LoopUnroller for a slightly more interesting case. llvm-svn: 313691
* [ForwardOpTree] Allow out-of-quota in examination part of forwardTree.Michael Kruse2017-09-192-32/+122
| | | | | | | | | | | | | | | | | | | | | | | | Computing the reaching definition in forwardTree() can take a long time if the coefficients are large. When the forwarding is carried-out (doIt==true), forwardTree() must execute entirely or not at all to get a consistent output, which means we cannot just allow out-of-quota errors to happen in the middle of the processing. We introduce the class IslQuotaScope which allows to opt-in code that is conformant and has been tested with out-of-quota events. In case of ForwardOpTree, out-of-quota is allowed during the operand tree examination, but not during the transformation. The same forwardTree() recursion is used for examination and execution, meaning that the reaching definition has already been computed in the examination tree walk and cached for reuse in the transformation tree walk. This should fix the time-out of grtestutils.ll of the asop buildbot. If the compilation still takes too long, we can reduce the max-operations allows for -polly-optree. Differential Revision: https://reviews.llvm.org/D37984 llvm-svn: 313690
* Revert "Introduce the llvm-cfi-verify tool."Vlad Tsyrklevich2017-09-195-366/+0
| | | | | | | This reverts commit r313688, it caused build failures for llvm-i686-linux-RA llvm-svn: 313689
* Introduce the llvm-cfi-verify tool.Vlad Tsyrklevich2017-09-195-0/+366
| | | | | | | | | | | | | | | | Summary: Introduces the llvm-cfi-verify tool to llvm. Includes the design document (docs/CFIVerify.rst). Current implementation of the tool is simply a disassembler that identifies and prints the indirect control flow instructions. Reviewers: vlad.tsyrklevich Reviewed By: vlad.tsyrklevich Patch by Mitch Phillips Subscribers: llvm-commits, kcc, pcc, mgorny Differential Revision: https://reviews.llvm.org/D37937 llvm-svn: 313688
* CodeGen: use range based for loops (NFC)Saleem Abdulrasool2017-09-191-6/+1
| | | | | | | Simplify the RPOT traversal by using a range based for loop for the iterator dereference. llvm-svn: 313687
* Revert "[MIRPrinter] Print empty successor lists when they cannot be guessed"Quentin Colombet2017-09-192-49/+2
| | | | | | | | | This reverts commit r313685. I thought I had ran ninja check, but apparently I didn't... Need to update a bunch of mir tests. llvm-svn: 313686
* [MIRPrinter] Print empty successor lists when they cannot be guessedQuentin Colombet2017-09-192-2/+49
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Unreachable blocks in the machine instr representation are these weird empty blocks with no successors. The MIR printer used to not print empty lists of successors. However, the MIR parser now treats non-printed list of successors as "please guess it for me". As a result, the parser tries to guess the list of successors and given the block is empty, just assumes it falls through the next block (if any). For instance, the following test case used to fail the verifier. The MIR printer would print entry / \ true (def) false (no list of successors) | split.true (use) The MIR parser would understand this: entry / \ true (def) false | / <-- invalid edge split.true (use) Because of the invalid edge, we get the "def does not dominate all uses" error. The fix consists in printing empty successor lists, so that the parser knows what to do for unreachable blocks. rdar://problem/34022159 llvm-svn: 313685
* Fix 32-bit buildbots by removing tests that are dependent on pointer-size ↵Andrew Kaylor2017-09-193-16/+5
| | | | | | | | comparisons. The recently behavior in the code that these tests were meant to be checking will be ammended as soon as a suitable change can be properly reviewed. llvm-svn: 313684
* Revert "[Sema] Move some stuff into -Wtautological-unsigned-enum-zero-compare"Roman Lebedev2017-09-195-138/+24
| | | | | | | | | | | | | | | | This reverts commit r313677. Buildbots fail with assertion failure Failing Tests (7): Clang :: Analysis/null-deref-ps.c Clang :: CodeGen/enum.c Clang :: Sema/compare.c Clang :: Sema/outof-range-constant-compare.c Clang :: Sema/tautological-unsigned-enum-zero-compare.c Clang :: Sema/tautological-unsigned-zero-compare.c Clang :: SemaCXX/compare.cpp llvm-svn: 313683
* Reland "[llvm-objcopy] Add support for nested and overlapping segments"Jake Ehrlich2017-09-197-6/+522
| | | | | | | | | | | I didn't initialize a pointer to be nullptr that I needed to. This change adds support for nested and even overlapping segments. This means that PT_PHDR, PT_GNU_RELRO, PT_TLS, and PT_DYNAMIC can be supported properly. Differential Revision: https://reviews.llvm.org/D36558 llvm-svn: 313682
* Rename CieRecord instance variables.Rui Ueyama2017-09-192-29/+29
| | | | | | | | CieRecord is a struct containing a CIE and FDEs, but oftentimes the struct itself is named `Cie` which caused some confusion. This patch renames them `CieRecords` or `Rec`. llvm-svn: 313681
* [ARM] Relax 'cpsie'/'cpsid' flag parsing.Jonathan Roelofs2017-09-192-1/+3
| | | | | | | | | | The ARM docs suggest in examples that the flags can have either case, and there are applications in the wild that (libopencm3, for example) that expect to be able to use the uppercase spelling. https://reviews.llvm.org/D37953 llvm-svn: 313680
OpenPOWER on IntegriCloud