summaryrefslogtreecommitdiffstats
path: root/include
Commit message (Collapse)AuthorAgeFilesLines
...
* [hwasan] Implement -fsanitize-recover=hwaddress.Evgeniy Stepanov2017-12-201-1/+1
| | | | | | | | | | | | Summary: Very similar to AddressSanitizer, with the exception of the error type encoding. Reviewers: kcc, alekseyshl Subscribers: cfe-commits, kubamracek, llvm-commits, hiraditya Differential Revision: https://reviews.llvm.org/D41417 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@321203 91177308-0d34-0410-b5e6-96231b3b80d8
* [PGO] Function section hotness prefix should look at all blocksTeresa Johnson2017-12-201-4/+4
| | | | | | | | | | | | | | | | | | | | Summary: The function section prefix for PGO based layout (e.g. hot/unlikely) should look at the hotness of all blocks not just the entry BB. A function with a cold entry but a very hot loop should be placed in the hot section, for example, so that it is located close to other hot functions it may call. For SamplePGO it was already looking at the branch weights on calls, and I made that code conditional on whether this is SamplePGO since it was essentially a noop for instrumentation PGO anyway. Reviewers: davidxl Subscribers: eraman, llvm-commits Differential Revision: https://reviews.llvm.org/D41395 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@321197 91177308-0d34-0410-b5e6-96231b3b80d8
* [JumpTables] Let targets decide which switch instructions are suitableNemanja Ivanovic2017-12-201-3/+3
| | | | | | | | | This commits the non-controversial part of https://reviews.llvm.org/D41029 (making the queries virtual). The PPC-specific portion of this will be committed in a subsequent patch once some of the finer points are ironed out. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@321182 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert r320548:[SLP] Vectorize jumbled memory loadsMohammad Shahid2017-12-201-15/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@321181 91177308-0d34-0410-b5e6-96231b3b80d8
* Add optional SelectionDAG* parameter to SValue::dump and SDValue::dumprKrzysztof Parzyszek2017-12-201-6/+6
| | | | | | | | | | These functions simply call their counterparts in the associated SDNode, which do take an optional SelectionDAG. This change makes the legalization debug trace a little easier to read, since target-specific nodes will now have their names shown instead of "Unknown node #123". git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@321180 91177308-0d34-0410-b5e6-96231b3b80d8
* [SCEV] Fix Typo. NFC.Javed Absar2017-12-201-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@321179 91177308-0d34-0410-b5e6-96231b3b80d8
* [NVPTX] Initial adaptation of MCAsmStreamer/MCTargetStreamer for debug info ↵Alexey Bataev2017-12-202-1/+13
| | | | | | | | | | | | | | | | | | | | | in Cuda. Summary: Initial changes in interfaces of MCAsmStreamer/MCTargetStreamer for correct debug info emission for Cuda. 1. PTX foramt does not support `.ascii` directives. Added the ability to nullify it. 2. The initial function label must follow the first debug `.loc` directive, not be followed by. 3. DWARF sections must be enclosed in braces. Reviewers: hfinkel, probinson, jlebar, rafael, echristo Subscribers: sdardis, nemanjai, llvm-commits, aprantl Differential Revision: https://reviews.llvm.org/D40033 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@321178 91177308-0d34-0410-b5e6-96231b3b80d8
* [globalisel][tablegen] Allow ImmLeaf predicates to use InstructionSelector ↵Daniel Sanders2017-12-202-10/+13
| | | | | | | | | | | members NFC for currently supported targets. This resolves a problem encountered by targets such as RISCV that reference `Subtarget` in ImmLeaf predicates. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@321176 91177308-0d34-0410-b5e6-96231b3b80d8
* [memcpyopt] Teach memcpyopt to optimize across basic blocksDan Gohman2017-12-201-0/+6
| | | | | | | | | | | | | | | | | | This teaches memcpyopt to make a non-local memdep query when a local query indicates that the dependency is non-local. This notably allows it to eliminate many more llvm.memcpy calls in common Rust code, often by 20-30%. This is r319482 and r319483, along with fixes for PR35519: fix the optimization that merges stores into memsets to preserve cached memdep info, and fix memdep's non-local caching strategy to not assume that larger queries are always more conservative than smaller ones. Fixes PR28958 and PR35519. Differential Revision: https://reviews.llvm.org/D40802 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@321138 91177308-0d34-0410-b5e6-96231b3b80d8
* [CodeGen] Move printing MO_BlockAddress operands to MachineOperand::printFrancis Visoiu Mistrih2017-12-191-0/+3
| | | | | | | Work towards the unification of MIR and debug output by refactoring the interfaces. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@321113 91177308-0d34-0410-b5e6-96231b3b80d8
* [CodeGen] Refactor printOffset from MO and MIRPrinterFrancis Visoiu Mistrih2017-12-191-0/+3
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@321109 91177308-0d34-0410-b5e6-96231b3b80d8
* [CodeGen] Move printing MO_CFIIndex operands to MachineOperand::printFrancis Visoiu Mistrih2017-12-191-0/+1
| | | | | | | | | | Work towards the unification of MIR and debug output by refactoring the interfaces. Before this patch we printed "<call frame instruction>" in the debug output. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@321084 91177308-0d34-0410-b5e6-96231b3b80d8
* [ThinLTO][C-API] Correct api commentsBen Dunbobbin2017-12-192-11/+12
| | | | | | | | | | | | Negative values never disabled the pruning - they simply set high values for the pruning interval. The behaviour now is that negative values set the maximum pruning interval (which appears to have been the intention from the start) see https://reviews.llvm.org/D41231. I have adjusted the comments to reflect this, removed any inaccurate statements, and corrected any typos I spotted in the English. Differential Revision: https://reviews.llvm.org/D41279 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@321078 91177308-0d34-0410-b5e6-96231b3b80d8
* [Support][CachePruning] Disable cache pruning regression fixBen Dunbobbin2017-12-191-1/+5
| | | | | | | | | | borked by: rL284966 (see: https://reviews.llvm.org/D25730). Previously, Interval was unsigned (see: CachePruning.h), replacing the type with std::chrono::seconds (which is signed) causes a regression in behaviour because the c-api intends negative values to translate to large positive intervals to *effectively* disable the pruning (see comments on: setCachePruningInterval()). Differential Revision: https://reviews.llvm.org/D41231 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@321077 91177308-0d34-0410-b5e6-96231b3b80d8
* [Support] Add WritableMemoryBuffer classPavel Labath2017-12-191-0/+60
| | | | | | | | | | | | | | | | | | | | | | | | Summary: The motivation here is LLDB, where we need to fixup relocations in mmapped files before their contents can be read correctly. The MemoryBuffer class does exactly what we need, *except* that it maps the file in read-only mode. WritableMemoryBuffer reuses the existing machinery for opening and mmapping a file. The only difference is in the argument to the mapped_file_region constructor -- we create a private copy-on-write mapping, so that we can make changes to the mapped data, but the changes aren't carried over to the underlying file. This patch is based on an initial version by Zachary Turner. Reviewers: mehdi_amini, rnk, rafael, dblaikie, zturner Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D40291 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@321071 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix: [YAML] Always double quote UTF-8 charactersFrancis Visoiu Mistrih2017-12-191-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@321069 91177308-0d34-0410-b5e6-96231b3b80d8
* [YAML] Always double quote UTF-8 charactersFrancis Visoiu Mistrih2017-12-191-3/+3
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@321068 91177308-0d34-0410-b5e6-96231b3b80d8
* [FuzzMutate] Don't crash when mutator is unable to find operationIgor Laevsky2017-12-191-1/+3
| | | | | | | | Differential Revision: https://reviews.llvm.org/D41009 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@321062 91177308-0d34-0410-b5e6-96231b3b80d8
* TargetLowering: Fix off-by-one errorMatthias Braun2017-12-191-1/+1
| | | | | | | This problem was present for a while, but somehow asan didn't catch it before the refactoring in r321036. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@321043 91177308-0d34-0410-b5e6-96231b3b80d8
* LiveStacks: Rename LiveStack.{h|cpp} to LiveStacks.{h|cpp}; NFCMatthias Braun2017-12-181-4/+4
| | | | | | Filenames should match the name of the class they contain. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@321037 91177308-0d34-0410-b5e6-96231b3b80d8
* X86/AArch64/ARM: Factor out common sincos_stret logic; NFCIMatthias Braun2017-12-182-0/+5
| | | | | | | | | | | Note: - X86ISelLowering: setLibcallName(SINCOS) was superfluous as InitLibcalls() already does it. - ARMISelLowering: Setting libcallnames for sincos/sincosf seemed superfluous as in the darwin case it wouldn't be used while for all other cases InitLibcalls already does it. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@321036 91177308-0d34-0410-b5e6-96231b3b80d8
* AArch64/X86: Factor out common bzero logic; NFCMatthias Braun2017-12-181-0/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@321035 91177308-0d34-0410-b5e6-96231b3b80d8
* Recommit "[DWARFv5] Dump an MD5 checksum in the line-table header."Paul Robinson2017-12-181-2/+6
| | | | | | | | | | | Adds missing support for DW_FORM_data16. Update of r320852/r320886, fixing the unittest again, this time use a raw char string for the test data. Differential Revision: https://reviews.llvm.org/D41090 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@321011 91177308-0d34-0410-b5e6-96231b3b80d8
* [IR] Support the new TBAA metadata format in IR verifierIvan A. Kosarev2017-12-181-3/+5
| | | | | | | Differential Revision: https://reviews.llvm.org/D40438 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@321007 91177308-0d34-0410-b5e6-96231b3b80d8
* [YAML] Add support for non-printable charactersFrancis Visoiu Mistrih2017-12-186-48/+92
| | | | | | | | | | | | | | | | | | | | | | | | | | | | LLVM IR function names which disable mangling start with '\01' (https://www.llvm.org/docs/LangRef.html#identifiers). When an identifier like "\01@abc@" gets dumped to MIR, it is quoted, but only with single quotes. http://www.yaml.org/spec/1.2/spec.html#id2770814: "The allowed character range explicitly excludes the C0 control block allowed), the surrogate block #xD800-#xDFFF, #xFFFE, and #xFFFF." http://www.yaml.org/spec/1.2/spec.html#id2776092: "All non-printable characters must be escaped. [...] Note that escape sequences are only interpreted in double-quoted scalars." This patch adds support for printing escaped non-printable characters between double quotes if needed. Should also fix PR31743. Differential Revision: https://reviews.llvm.org/D41290 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@320996 91177308-0d34-0410-b5e6-96231b3b80d8
* [IR] Add MDBuilder helpers for the new TBAA metadata formatIvan A. Kosarev2017-12-181-3/+18
| | | | | | | | | | | | The new helpers are supposed to be used in clang to generate TBAA information in the new format proposed in this thread: http://lists.llvm.org/pipermail/llvm-dev/2017-November/118748.html Differential Revision: https://reviews.llvm.org/D39956 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@320993 91177308-0d34-0410-b5e6-96231b3b80d8
* [Memcpy Loop Lowering] Remove the fixed int8 lowering.Sean Fertile2017-12-182-12/+0
| | | | | | | | Switch over to the lowering that uses target supplied operand types. Differential Revision: https://reviews.llvm.org/D41201 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@320989 91177308-0d34-0410-b5e6-96231b3b80d8
* Constexprify LaneBitmask factory methods.Benjamin Kramer2017-12-181-3/+3
| | | | | | This avoids global constructors when they're used in a global constant. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@320979 91177308-0d34-0410-b5e6-96231b3b80d8
* [ConstantRange] Support for ashr in ConstantRange computationMax Kazantsev2017-12-181-0/+4
| | | | | | | | | | | | Extend the ConstantRange implementation to compute the range of possible values resulting from an arithmetic right shift operation. There will be a follow up patch to leverage this constant range infrastructure in LazyValueInfo. Patch by Surya Kumari Jangala! Differential Revision: https://reviews.llvm.org/D40881 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@320976 91177308-0d34-0410-b5e6-96231b3b80d8
* Re-commit "Properly handle multi-element and dynamically sized allocas in ↵Bjorn Steinbrink2017-12-171-1/+1
| | | | | | | | | getPointerDereferenceableBytes()"" llvm-clang-x86_64-expensive-checks-win is still broken, so the failure seems unrelated. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@320953 91177308-0d34-0410-b5e6-96231b3b80d8
* use uint32_tSam Clegg2017-12-171-2/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@320947 91177308-0d34-0410-b5e6-96231b3b80d8
* [WebAssembly] Export some more info on wasm funtionsSam Clegg2017-12-172-2/+2
| | | | | | | | | | | | | Summary: These fields are useful for lld's gc-sections support Also remove an unused field. Subscribers: jfb, dschuff, jgravelle-google, aheejin, sunfish Differential Revision: https://reviews.llvm.org/D41320 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@320946 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert "Properly handle multi-element and dynamically sized allocas in ↵Bjorn Steinbrink2017-12-171-1/+1
| | | | | | | | | | getPointerDereferenceableBytes()" This reverts commit 217067d5179882de9deb60d2e866befea4c126e7. Fails on llvm-clang-x86_64-expensive-checks-win git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@320945 91177308-0d34-0410-b5e6-96231b3b80d8
* Properly handle multi-element and dynamically sized allocas in ↵Bjorn Steinbrink2017-12-171-1/+1
| | | | | | | | | | | | getPointerDereferenceableBytes() Reviewers: hfinkel, rnk Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D41288 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@320938 91177308-0d34-0410-b5e6-96231b3b80d8
* [X86] Remove GCCBuiltin from kand/kandn/kor/kxor/kxnor/knot intrinsics so ↵Craig Topper2017-12-161-6/+6
| | | | | | clang can implement with native IR. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@320918 91177308-0d34-0410-b5e6-96231b3b80d8
* [WebAssembly] Return ArrayRef's rather than const std::vector&Sam Clegg2017-12-161-21/+11
| | | | | | | | | | From working on lld I've learned this is generally the preferred way for several reasons (e.g. more concise, improves encapsulation). Differential Revision: https://reviews.llvm.org/D41265 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@320906 91177308-0d34-0410-b5e6-96231b3b80d8
* [LTO] Make processing of combined module more consistentVitaly Buka2017-12-161-2/+1
| | | | | | | | | | | | | | | | | Summary: 1. Use stream 0 only for combined module. Previously if combined module was not processes ThinLTO used the stream for own output. However small changes in input, could trigger combined module and shuffle outputs making life of llvm::LTO harder. 2. Always process combined module and write output to stream 0. Processing empty combined module is cheap and allows llvm::LTO users to avoid implementing processing which is already done in llvm::LTO. Subscribers: mehdi_amini, inglorion, eraman, hiraditya Differential Revision: https://reviews.llvm.org/D41267 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@320905 91177308-0d34-0410-b5e6-96231b3b80d8
* [SimplifyLibCalls] Inline calls to cabs when it's safe to do soHal Finkel2017-12-162-0/+10
| | | | | | | | | | | | When unsafe algerbra is allowed calls to cabs(r) can be replaced by: sqrt(creal(r)*creal(r) + cimag(r)*cimag(r)) Patch by Paul Walker, thanks! Differential Revision: https://reviews.llvm.org/D40069 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@320901 91177308-0d34-0410-b5e6-96231b3b80d8
* [ThinLTO] Enable importing of aliases as copy of aliaseeTeresa Johnson2017-12-163-1/+30
| | | | | | | | | | | | | | | | | | | | | | | Summary: This implements a missing feature to allow importing of aliases, which was previously disabled because alias cannot be available_externally. We instead import an alias as a copy of its aliasee. Some additional work was required in the IndexBitcodeWriter for the distributed build case, to ensure that the aliasee has a value id in the distributed index file (i.e. even when it is not being imported directly). This is a performance win in codes that have many aliases, e.g. C++ applications that have many constructor and destructor aliases. Reviewers: pcc Subscribers: mehdi_amini, inglorion, eraman, llvm-commits Differential Revision: https://reviews.llvm.org/D40747 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@320895 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert "Recommit "[DWARFv5] Dump an MD5 checksum in the line-table header.""Paul Robinson2017-12-151-6/+2
| | | | | | | This reverts commit 0afef672f63f0e4e91938656bc73424a8c058bfc. Still failing at runtime on bots. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@320888 91177308-0d34-0410-b5e6-96231b3b80d8
* Recommit "[DWARFv5] Dump an MD5 checksum in the line-table header."Paul Robinson2017-12-151-2/+6
| | | | | | | | | | | Adds missing support for DW_FORM_data16. Update of r320852, fixing the unittest to use a hand-coded struct instead of std::array to guarantee data layout. Differential Revision: https://reviews.llvm.org/D41090 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@320886 91177308-0d34-0410-b5e6-96231b3b80d8
* MachineFunction: Return reference from getFunction(); NFCMatthias Braun2017-12-155-13/+13
| | | | | | The Function can never be nullptr so we can return a reference. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@320884 91177308-0d34-0410-b5e6-96231b3b80d8
* MachineFunction: Slight refactoring; NFCMatthias Braun2017-12-151-4/+5
| | | | | | Slight cleanup/refactor in preparation for upcoming commit. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@320882 91177308-0d34-0410-b5e6-96231b3b80d8
* MachineModuleInfo: Remove unused function; NFCMatthias Braun2017-12-151-1/+0
| | | | | | | | Remove the unused setModule() function; it would be dangerous if someone actually used it as it wouldn't reset/recompute various other module related data. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@320881 91177308-0d34-0410-b5e6-96231b3b80d8
* [LTO] Remove unused RegularLTOState::HasModuleVitaly Buka2017-12-151-1/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@320859 91177308-0d34-0410-b5e6-96231b3b80d8
* Re-commit : [LICM] Allow sinking when foldable in loopJun Bum Lim2017-12-151-2/+3
| | | | | | | | | | | | | | | | | | | | | | This recommits r320823 reverted due to the test failure in sink-foldable.ll and an unused variable. Added "REQUIRES: aarch64-registered-target" in the test and removed unused variable. Original commit message: Continue trying to sink an instruction if its users in the loop is foldable. This will allow the instruction to be folded in the loop by decoupling it from the user outside of the loop. Reviewers: hfinkel, majnemer, davidxl, efriedma, danielcdh, bmakam, mcrosier Reviewed By: hfinkel Subscribers: javed.absar, bmakam, mcrosier, llvm-commits Differential Revision: https://reviews.llvm.org/D37076 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@320858 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert "[DWARFv5] Dump an MD5 checksum in the line-table header."Paul Robinson2017-12-151-6/+2
| | | | | | Unit test fails on some bots. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@320857 91177308-0d34-0410-b5e6-96231b3b80d8
* [DWARFv5] Dump an MD5 checksum in the line-table header.Paul Robinson2017-12-151-2/+6
| | | | | | | | Adds missing support for DW_FORM_data16. Differential Revision: https://reviews.llvm.org/D41090 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@320852 91177308-0d34-0410-b5e6-96231b3b80d8
* fix typo in comment and remove inaccurate comment; NFCSanjay Patel2017-12-151-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@320838 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert "Re-commit : [LICM] Allow sinking when foldable in loop"Jun Bum Lim2017-12-151-3/+2
| | | | | | This reverts commit r320833. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@320836 91177308-0d34-0410-b5e6-96231b3b80d8