summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* [asan] Use full binary path in the Android test runner.Evgeniy Stepanov2017-10-052-4/+8
| | | | | | | | | | | | | | Summary: This prevents the confusion when there are similarly named tests in different configurations (like in test/sanitizer_common). Reviewers: vitalybuka Subscribers: srhines, llvm-commits, kubamracek Differential Revision: https://reviews.llvm.org/D38526 llvm-svn: 315011
* [sanitizer] Move %ld_flags_rpath_exe to common and use it in more tests.Evgeniy Stepanov2017-10-054-20/+20
| | | | | | | | | | Reviewers: vitalybuka Subscribers: kubamracek, llvm-commits Differential Revision: https://reviews.llvm.org/D38527 llvm-svn: 315010
* Revert "[llvm-dsymutil] Add support for __swift_ast MachO DWARF section"Francis Ricci2017-10-0510-78/+16
| | | | | | This reverts commit r315004, because of a failing test on non-apple platforms llvm-svn: 315009
* Enable breakpoints and read/write GPRs for ppc64leEugene Zemtsov2017-10-0513-2/+766
| | | | | | | | | | | | Add support for ppc64le to create breakpoints and read/write general purpose registers. Other features for ppc64le and functions to read/write other registers are being implemented. Patch by Alexandre Yukio Yamashita (alexandreyy) Differential Revision: https://reviews.llvm.org/D38323 llvm-svn: 315008
* [cfi] Mark a test as unsupported on darwin.Evgeniy Stepanov2017-10-051-1/+2
| | | | llvm-svn: 315007
* [dsymutil] Fix unused variable warningFrancis Ricci2017-10-051-1/+1
| | | | llvm-svn: 315006
* Fix two-phase name lookup for non-dependent overloaded operators.Richard Smith2017-10-054-13/+57
| | | | | | | | If we resolve an overloaded operator call to a specific function during template definition, don't perform ADL during template instantiation. Doing so finds overloads that we're not supposed to find. llvm-svn: 315005
* [llvm-dsymutil] Add support for __swift_ast MachO DWARF sectionFrancis Ricci2017-10-0510-16/+78
| | | | | | | | | | | | | | | | | | | | Summary: Xcode's dsymutil emits a __swift_ast DWARF section, which is required for debugging, and which contains a byte-for-byte dump of the swiftmodule file. Add this feature to llvm-dsymutil. Tested with `gobjdump --dwarf=info -s`, by verifying that the contents of `__DWARF.__swift_ast` match between Xcode's dsymutil and llvm-dsymutil (Xcode's dwarfdump and llvm-dwarfdump don't currently recognize the __swift_ast section). Reviewers: aprantl, friss Subscribers: llvm-commits, JDevlieghere Differential Revision: https://reviews.llvm.org/D38504 llvm-svn: 315004
* [NewPassManager] Run global dead code elimination after the inliner.Davide Italiano2017-10-053-0/+3
| | | | | | | | | This is the same exact change we did for the current pass manager in rL314997, but the new pass manager pipeline already happened to run GlobalOpt after the inliner, so we just insert a run of GDCE here. llvm-svn: 315003
* [ARM/AARCH64] Make test MachineBranchProb.ll more robust and re-enable for ↵Balaram Makam2017-10-051-3/+4
| | | | | | | | | | | | | | | | ARM/AArch64 Summary: Make test robust enough to not fail due to CFG changes and re-enable for ARM/AArch64. Reviewers: rovka, fhahn Reviewed By: fhahn Subscribers: fhahn, aemerson, rengolin, mcrosier, llvm-commits, kristof.beyls Differential Revision: https://reviews.llvm.org/D38590 llvm-svn: 315002
* [cfi] Test on all available targets.Evgeniy Stepanov2017-10-053-12/+23
| | | | | | | | | | | | | | Summary: Run CFI tests on all targets current toolchain can target. On multiarch Linux, this will run all CFI tests with -m32 and -m64. Reviewers: pcc Subscribers: mgorny, llvm-commits Differential Revision: https://reviews.llvm.org/D38572 llvm-svn: 315001
* [X86] Simplify X86 epilogue frame size calculation, NFCReid Kleckner2017-10-051-39/+28
| | | | | | | | | | | | | | | | | | | | | Sink the insertion of "pop ebp" out of the frame size calculation branches. They all check for HasFP. Our handling of CLEANUPRET and CATCHRET was equivalent, both are funclets and use the same frame size. We can eliminate the CLEANUPRET case. Hoist the hasFP(MF) query into a local bool. Rename TargetMBB to CatchRetTarget to be more descriptive. Eliminate the Optional<unsigned> RetOpcode local, now that it has one use. It's only a net savings of 10 lines, but hopefully it's *slightly* more readable. llvm-svn: 315000
* [PassManager] Improve the interaction between -O2 and ThinLTO.Davide Italiano2017-10-052-16/+14
| | | | | | | Run GDCE slightly later so that we don't have to repeat it twice when preparing for Thin. Thanks to Mehdi for the suggestion. llvm-svn: 314999
* Add vload_half helpers for ptxJeroen Ketema2017-10-054-0/+26
| | | | | | | The removes the vload_half unresolved calls from the nvptx libraries. Reviewed-by: Jan Vesely <jan.vesely@rutgers.edu> llvm-svn: 314998
* [PassManager] Run global optimizations after the inliner.Davide Italiano2017-10-053-1/+17
| | | | | | | | | | | | | | | The inliner performs some kind of dead code elimination as it goes, but there are cases that are not really caught by it. We might at some point consider teaching the inliner about them, but it is OK for now to run GlobalOpt + GlobalDCE in tandem as their benefits generally outweight the cost, making the whole pipeline faster. This fixes PR34652. Differential Revision: https://reviews.llvm.org/D38154 llvm-svn: 314997
* [SparsePropagation] Move member definitions to header (NFC)Matthew Simpson2017-10-053-381/+320
| | | | | | | | | AbstractLatticeFunction and SparseSolver are class templates parameterized by a lattice value, so we need to move these member functions over to the header. Differential Revision: https://reviews.llvm.org/D38561 llvm-svn: 314996
* [OPENMP] Fix mapping|privatization of implicitly captured variables.Alexey Bataev2017-10-053-19/+43
| | | | | | | | If the `defaultmap(tofrom:scalar)` clause is specified, the scalars must be mapped with 'tofrom' modifiers, otherwise they must be captured as firstprivates. llvm-svn: 314995
* [mips] implement .set dspr2 directivePetar Jovanovic2017-10-056-1/+35
| | | | | | | | | | | | Implement .set dspr2 directive with appropriate feature bits. This directive is a counterpart of -mattr=dspr2 command line option with the exception that it does not influence elf header flags. Patch by Milos Stojanovic. Differential Revision: https://reviews.llvm.org/D38537 llvm-svn: 314994
* AMDGPU: Set v2i32 any_extend to expandMatt Arsenault2017-10-052-8/+34
| | | | llvm-svn: 314993
* [Analyzer Tests] Run static analyzer integration tests until the end,George Karpenkov2017-10-051-8/+20
| | | | | | | | Do not stop at the first failure. Differential Revision: https://reviews.llvm.org/D38589 llvm-svn: 314992
* [RDF] Simplify construction of maximal registersKrzysztof Parzyszek2017-10-052-40/+12
| | | | | | | | The old algoritm was not correct, although it worked most of the time. Avoid the complex reachability analysis and simply calculate the maximal registers out of the set of all referenced registers. llvm-svn: 314991
* [ProfileData] Fix data racing in merging indexed profilesRong Xu2017-10-054-3/+120
| | | | | | | | | | There is data racing to the static variable RecordIndex in index profile reader when merging in multiple threads. Make it a member variable in IndexedInstrProfReader to fix this. Differential Revision: https://reviews.llvm.org/D38431 llvm-svn: 314990
* [clangd] Added async API to run code completion.Ilya Biryukov2017-10-054-26/+67
| | | | | | | | | | | | | | | | | | Summary: ClangdServer now provides async code completion API. It is still used synchronously by ClangdLSPServer, more work is needed to allow processing other requests in parallel while completion (or any other request) is running. Reviewers: klimek, bkramer, krasimir Reviewed By: klimek Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/D38583 llvm-svn: 314989
* [X86] Fix chains update when lowering BUILD_VECTOR to a vector loadArtur Pilipenko2017-10-052-19/+256
| | | | | | | | | | | | | | | | | | The code which lowers BUILD_VECTOR of consecutive loads into a single vector load doesn't update chains properly. As a result the vector load can be reordered with the store to the same location. The current code in EltsFromConsecutiveLoads only updates the chain following the first load. The fix is to update the chains following all the loads comprising the vector. This is a fix for PR10114. Reviewed By: niravd Differential Revision: https://reviews.llvm.org/D38547 llvm-svn: 314988
* AMDGPU: Add and set AMDGPU-specific e_flagsKonstantin Zhuravlyov2017-10-0513-63/+187
| | | | | | Differential Revision: https://reviews.llvm.org/D38556 llvm-svn: 314987
* [LV] Fix PR34743 - handle casts that sink after interleaved loadsAyal Zaks2017-10-052-1/+56
| | | | | | | | | | | When ignoring a load that participates in an interleaved group, make sure to move a cast that needs to sink after it. Testcase derived from reproducer of PR34743. Differential Revision: https://reviews.llvm.org/D38338 llvm-svn: 314986
* Revert "Re-land "[MergeICmps] Disable mergeicmps if the target does not want ↵Clement Courbet2017-10-057-240/+87
| | | | | | | | | | to handle memcmp expansion.""" broken test on windows This reverts commit c91479518344fd1fc071c5bd5848f6eb83e53dca. llvm-svn: 314985
* revert r314698 - [InstCombine] remove one-use restriction for icmp (shr ↵Sanjay Patel2017-10-052-7/+7
| | | | | | | | | | | exact X, C1), C2 --> icmp X, (C2<<C1) There is a bot failure that appears to be related to this change: http://lab.llvm.org:8011/builders/clang-cmake-armv7-a15-selfhost-neon/builds/2117 ...so reverting to confirm that and attempting to keep the bot green while investigating. llvm-svn: 314984
* [ScopBuilder] Introduce -polly-stmt-granularity=scalar-indep option.Michael Kruse2017-10-057-2/+517
| | | | | | | | | | | | | | | | | | | | | | | | | The option splits BasicBlocks into minimal statements such that no additional scalar dependencies are introduced. The algorithm is based on a union-find structure, and unites sets if putting them into separate statements would introduce a scalar dependencies. As a consequence, instructions may be split into separate statements such their relative order is different than the statements they are in. This is accounted for instructions whose relative order matters (e.g. memory accesses). The algorithm is generic in that heuristic changes can be made relatively easily. We might relax the order requirement for read-reads or accesses to different base pointers. Forwardable instructions can be made to not cause a join. This implementation gives us a speed-up of 82% in SPEC 2006 456.hmmer benchmark by allowing loop-distribution in a hot loop such that one of the loops can be vectorized. Differential Revision: https://reviews.llvm.org/D38403 llvm-svn: 314983
* [TablgeGen] : Tidy up CodeGenSchedule. NFC.Javed Absar2017-10-051-25/+21
| | | | | | | Reviewed by: @MatzeB Differential Revision: https://reviews.llvm.org/D38534 llvm-svn: 314982
* [LV] Fix PR34711 - widen instruction ranges when sinking castsAyal Zaks2017-10-052-23/+71
| | | | | | | | | | | | | | | | Instead of trying to keep LastWidenRecipe updated after creating each recipe, have tryToWiden() retrieve the last recipe of the current VPBasicBlock and check if it's a VPWidenRecipe when attempting to extend its range. This ensures that such extensions, optimized to maintain the original instruction order, do so only when the instructions are to maintain their relative order. The latter does not always hold, e.g., when a cast needs to sink to unravel first order recurrence (r306884). Testcase derived from reproducer of PR34711. Differential Revision: https://reviews.llvm.org/D38339 llvm-svn: 314981
* Re-land "[MergeICmps] Disable mergeicmps if the target does not want to ↵Clement Courbet2017-10-057-87/+240
| | | | | | handle memcmp expansion."" llvm-svn: 314980
* [CodeGen] Unify generation of scalar and struct-path TBAA tagsIvan A. Kosarev2017-10-057-102/+76
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch makes it possible to produce access tags in a uniform manner regardless whether the resulting tag will be a scalar or a struct-path one. getAccessTagInfo() now takes care of the actual translation of access descriptors to tags and can handle all kinds of accesses. Facilities that specific to scalar accesses are eliminated. Some more details: * DecorateInstructionWithTBAA() is not responsible for conversion of types to access tags anymore. Instead, it takes an access descriptor (TBAAAccessInfo) and generates corresponding access tag from it. * getTBAAInfoForVTablePtr() reworked to getTBAAVTablePtrAccessInfo() that now returns the virtual-pointer access descriptor and not the virtual-point type metadata. * Added function getTBAAMayAliasAccessInfo() that returns the descriptor for may-alias accesses. * getTBAAStructTagInfo() renamed to getTBAAAccessTagInfo() as now it is the only way to generate access tag by a given access descriptor. It is capable of producing both scalar and struct-path tags, depending on options and availability of the base access type. getTBAAScalarTagInfo() and its cache ScalarTagMetadataCache are eliminated. * Now that we do not need to care about whether the resulting access tag should be a scalar or struct-path one, getTBAAStructTypeInfo() is renamed to getBaseTypeInfo(). * Added function getTBAAAccessInfo() that constructs access descriptor by a given QualType access type. This is part of D37826 reworked to be a separate patch to simplify review. Differential Revision: https://reviews.llvm.org/D38503 llvm-svn: 314979
* Revert r314977 "[CodeGen] Unify generation of scalar and struct-path TBAA tags"Ivan A. Kosarev2017-10-0510-169/+183
| | | | | | | | D37826 has been mistakenly committed where it should be the patch from D38503. Differential Revision: https://reviews.llvm.org/D38503 llvm-svn: 314978
* [CodeGen] Unify generation of scalar and struct-path TBAA tagsIvan A. Kosarev2017-10-0510-183/+169
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch makes it possible to produce access tags in a uniform manner regardless whether the resulting tag will be a scalar or a struct-path one. getAccessTagInfo() now takes care of the actual translation of access descriptors to tags and can handle all kinds of accesses. Facilities that specific to scalar accesses are eliminated. Some more details: * DecorateInstructionWithTBAA() is not responsible for conversion of types to access tags anymore. Instead, it takes an access descriptor (TBAAAccessInfo) and generates corresponding access tag from it. * getTBAAInfoForVTablePtr() reworked to getTBAAVTablePtrAccessInfo() that now returns the virtual-pointer access descriptor and not the virtual-point type metadata. * Added function getTBAAMayAliasAccessInfo() that returns the descriptor for may-alias accesses. * getTBAAStructTagInfo() renamed to getTBAAAccessTagInfo() as now it is the only way to generate access tag by a given access descriptor. It is capable of producing both scalar and struct-path tags, depending on options and availability of the base access type. getTBAAScalarTagInfo() and its cache ScalarTagMetadataCache are eliminated. * Now that we do not need to care about whether the resulting access tag should be a scalar or struct-path one, getTBAAStructTypeInfo() is renamed to getBaseTypeInfo(). * Added function getTBAAAccessInfo() that constructs access descriptor by a given QualType access type. This is part of D37826 reworked to be a separate patch to simplify review. Differential Revision: https://reviews.llvm.org/D38503 llvm-svn: 314977
* [mips] Place certain 64 bit FPU instructions in their own decoder namespaceSimon Dardis2017-10-0510-25/+40
| | | | | | | | | | | Previously, instructions that were defined to use the FGR64 register class were associated with the Mips64 table which was incorrect. Reviewers: nitesh.jain, atanasyan Differential Revision: https://reviews.llvm.org/D38454 llvm-svn: 314976
* [analyzer] Fix leak false positives on stuff put in C++/ObjC initializer lists.Artem Dergachev2017-10-054-18/+109
| | | | | | | | | | | | | | | The analyzer now realizes that C++ std::initializer_list objects and Objective-C boxed structure/array/dictionary expressions can potentially maintain a reference to the objects that were put into them. This avoids false memory leak posivites and a few other issues. This is a conservative behavior; for now, we do not model what actually happens to the objects after being passed into such initializer lists. rdar://problem/32918288 Differential Revision: https://reviews.llvm.org/D35216 llvm-svn: 314975
* [DebugInfo] Insert DEBUG_VALUEs after each register redefinitionKarl-Johan Karlsson2017-10-052-18/+115
| | | | | | | | | | | | | | | | | | | | | | | | Summary: When reinserting debug values after register allocation, make sure to insert debug values after each redefinition of debug value register in the slot index range. The reason for this is that DwarfDebug will end the range of a debug variable when the physical reg is defined. For instructions with e.g. tied operands this result in prematurely ended debug range. This resolves pr34545 Patch by Karl-Johan Karlsson and Bjorn Pettersson Reviewers: rnk, aprantl Reviewed By: rnk Subscribers: bjope, llvm-commits Differential Revision: https://reviews.llvm.org/D38229 llvm-svn: 314974
* [MC] - llvm-mc hangs on non-english characters.George Rimar2017-10-054-12/+18
| | | | | | | | | | | | | | | | | | Currently llvm-mc just hangs inside infinite loop while trying to parse file which has ".section .с" inside, where section name is non-english character. Patch fixes the issue. In this patch I also moved content of non-english-characters.s to test/MC/AsmParser/Inputs folder so that non-english-characters.s becomes a single testcase for all invalid inputs containing non-english symbols. That is convinent because llvm-mc otherwise tries to parse and tokenize the whole testcase file with tools invocations and it is harder to isolate the issue. Differential revision: https://reviews.llvm.org/D38545 llvm-svn: 314973
* Revert "[MergeICmps] Disable mergeicmps if the target does not want to ↵Clement Courbet2017-10-057-230/+83
| | | | | | | | | | | handle memcmp expansion." Breaks clang-stage1-cmake-RA-incremental/llvm/test/Transforms/MergeICmps/X86/tuple-four-int8.ll This reverts commit 3038c459d67f8898ffa295d54a013b280690abfa. llvm-svn: 314972
* [InstCombine] Fix a vector splat handling bug in transformZExtICmp.Craig Topper2017-10-052-3/+10
| | | | | | | | | | We were using an i1 type and then zero extending to a vector. Instead just create the 0/1 directly as a ConstantInt with the correct type. No need to ask ConstantExpr to zero extend for us. This bug is a bit tricky to hit because it requires us to visit a zext of an icmp that would normally be simplified to true/false, but that icmp hasnt' been visited yet. In the test case this zext and icmp were created by visiting a udiv and due to worklist ordering we got to the zext first. Fixes PR34841. llvm-svn: 314971
* [MergeICmps] Disable mergeicmps if the target does not want to handle memcmp ↵Clement Courbet2017-10-057-83/+230
| | | | | | | | | | | | | | expansion. Summary: This is to avoid e.g. merging two cheap icmps if the target is not going to expand to something nice later. Reviewers: dberlin, spatel Subscribers: davide, nemanjai Differential Revision: https://reviews.llvm.org/D38232 llvm-svn: 314970
* Minor refactoring regarding Cast::isNoopCast(), NFCMikael Holmen2017-10-053-45/+7
| | | | | | | | | | | | | | | | | | | | | Summary: FastISel::hasTrivialKill() was the only user of the "IntPtrTy" version of Cast::isNoopCast(). According to review comments in D37894 we could instead use the "DataLayout" version of the method, and thus get rid of the "IntPtrTy" versions of isNoopCast() completely. With the above done, the remaining isNoopCast() could then be simplified a bit more. Reviewers: arsenm Reviewed By: arsenm Subscribers: wdng, llvm-commits Differential Revision: https://reviews.llvm.org/D38497 llvm-svn: 314969
* [XRay][compiler-rt] Write out arg1 payload in naive mode loggingDean Michael Berris2017-10-052-15/+135
| | | | | | | | | | | | | | | | | | | | | | | | Summary: This change allows the XRay basic (naive) mode logging implementation to start writing the payload entries through the arg1 logging handler. This implementation writes out the records that the llvm-xray tool and the trace reader library will start processing in D38550. This introduces a new payload record type which logs the data through the in-memory buffer. It uses the same size/alignment that the normal XRay record entries use. We use a new record type to indicate these new entries, so that the trace reader library in LLVM can start reading these entries. Depends on D38550. Reviewers: pelikan Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D38551 llvm-svn: 314968
* [XRay][tools] Support arg1 logging entries in the basic logging modeDean Michael Berris2017-10-053-21/+66
| | | | | | | | | | | | | | | | | | | | | Summary: The arg1 logging handler changed in compiler-rt to start writing a different type for entries encountered when logging the first argument of XRay-instrumented functions. This change allows the trace loader to support reading these record types as well as prepare for when the basic (naive) mode implementation starts writing down the argument payloads. Without this change, binaries with arg1 logging support enabled start writing unreadable logs for any of the XRay tracing tools. Reviewers: pelikan Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D38550 llvm-svn: 314967
* Remove dead code.Rafael Espindola2017-10-051-7/+0
| | | | llvm-svn: 314966
* [libc++] Clarify names of ABI forcing macrosShoaib Meenai2017-10-053-9/+15
| | | | | | | | | Make it clear that these are intended only to force a specific ABI when the autodetection would give the wrong result by renaming the cmake options and adding separate forcing macros, as suggested by EricWF in the post-commit review of r314949 and further discussed on IRC. llvm-svn: 314965
* Enabling new pass manager in LTO (and thinLTO) link step.Sean Fertile2017-10-052-0/+15
| | | | | | | | | | | Passes 'new-pass-manager' option to the linker plugin when the new pass manager is enabled. Patch by Graham Yiu. Differential Revision: https://reviews.llvm.org/D38517 llvm-svn: 314964
* Enabling new pass manager in LTO (and thinLTO) link step.Sean Fertile2017-10-051-0/+7
| | | | | | | | | | | Adds the option 'new-pass-manager' to the gold pluggin to enable using the new pass manager during the lto/thinlto link step. Patch by Graham Yiu. Differential Revision: https://reviews.llvm.org/D38517 llvm-svn: 314963
* Revert r314928 to investigate thinLTO bootstrap failureXinliang David Li2017-10-056-536/+0
| | | | llvm-svn: 314961
OpenPOWER on IntegriCloud