summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* Seperate volatility and atomicity/ordering in SelectionDAGPhilip Reames2019-02-276-21/+66
| | | | | | | | | | | | | | | | | | | | | | | | | | | At the moment, we mark every atomic memory access as being also volatile. This is unnecessarily conservative and prohibits many legal transforms (DCE, folding, etc..). This patch removes MOVolatile from the MachineMemOperands of atomic, but not volatile, instructions. This should be strictly NFC after a series of previous patches which have gone in to ensure backend code is conservative about handling of isAtomic MMOs. Once it's in and baked for a bit, we'll start working through removing unnecessary bailouts one by one. We applied this same strategy to the middle end a few years ago, with good success. To make sure this patch itself is NFC, it is build on top of a series of other patches which adjust code to (for the moment) be as conservative for an atomic access as for a volatile access and build up a test corpus (mostly in test/CodeGen/X86/atomics-unordered.ll).. Previously landed D57593 Fix a bug in the definition of isUnordered on MachineMemOperand D57596 [CodeGen] Be conservative about atomic accesses as for volatile D57802 Be conservative about unordered accesses for the moment rL353959: [Tests] First batch of cornercase tests for unordered atomics. rL353966: [Tests] RMW folding tests w/unordered atomic operations. rL353972: [Tests] More unordered atomic lowering tests. rL353989: [SelectionDAG] Inline a single use helper function, and remove last non-MMO interface rL354740: [Hexagon, SystemZ] Be super conservative about atomics rL354800: [Lanai] Be super conservative about atomics rL354845: [ARM] Be super conservative about atomics Attention Out of Tree Backend Owners: This patch may break you. If it does, you can use the TLI getMMOFlags hook to restore the MOVolatile to any instruction you need to. (See llvm-dev thread titled "PSA: Changes to how atomics are handled in backends" started Feb 27, 2019.) Differential Revision: https://reviews.llvm.org/D57601 llvm-svn: 355025
* [clang-tidy] Add the abseil-time-subtraction checkHyrum Wright2019-02-2711-0/+448
| | | | | | Differential Revision: https://reviews.llvm.org/D58137 llvm-svn: 355024
* Fixed ubsan failures in r355005.Rong Xu2019-02-271-1/+1
| | | | llvm-svn: 355023
* [NFC][Sanitizer] Hard-code fast/slow unwinder at call siteJulian Lettner2019-02-2710-25/+47
| | | | | | | | | | | | | Also assert that the caller always gets what it requested. This purely mechanical change simplifies future refactorings and eventual removal of BufferedStackTrace::Unwind. Reviewers: vitalybuka Differential Revision: https://reviews.llvm.org/D58557 llvm-svn: 355022
* Revert "[llvm-cxxfilt] Split and demangle stdin input on certain ↵Matt Davis2019-02-272-101/+7
| | | | | | | | | | | | | non-alphanumerics." This reverts commit 5cd5f8f2563395f8767f94604eb4c4bea8dcbea0. The test passes on linux, but fails on the windows build-bots. This test failure seems to be a quoting issue between my test and FileCheck on Windows. I'm reverting this patch until I can replicate and fix in my Windows environment. llvm-svn: 355021
* [InstCombine] add tests for add+ext+add; NFCSanjay Patel2019-02-271-0/+86
| | | | llvm-svn: 355020
* [libFuzzer][Windows] Port fork mode to WindowsJonathan Metzman2019-02-277-16/+81
| | | | | | | | | | | | | | | | | | | | | Summary: Port libFuzzer's fork mode to Windows. Implement Windows versions of MkDir, RmDir, and IterateDirRecursive to do this. Don't print error messages under new normal uses of FileSize (on a non-existent file). Implement portable way of piping output to /dev/null. Fix test for Windows and comment fork-sigusr.test on why it won't be ported to Win. Reviewers: zturner Reviewed By: zturner Subscribers: kcc, zturner, jdoerfert, #sanitizers, llvm-commits Tags: #sanitizers, #llvm Differential Revision: https://reviews.llvm.org/D58513 llvm-svn: 355019
* [Darwin][NFC] Refactor throttling of 64bit sanitizer tests on DarwinJulian Lettner2019-02-278-29/+30
| | | | | | | | | | | | | | | | | | | Underlying condition for throttling is "has large mmap'd regions" (i.e., shadow memory) and not sanitizers in general (e.g., UBSan does not need to be throttled). Rename parallelism group `darwin-64bit-sanitizer` to `shadow-memory` and apply it unconditionally to all tests which require it. We can then have all the Darwin throttling logic in one place in the commen lit config. Throttle sanitizer_common unit tests. Configuration was previously missing from sanitizer_common/Unit/lit.site.cfg. Reviewed by: kubamracek Differential Revision: https://reviews.llvm.org/D58677 llvm-svn: 355018
* Add triples to the test I committed in r355012 to fix windows bots.Akira Hatanaka2019-02-271-2/+2
| | | | llvm-svn: 355017
* [X86][AVX] Pull out some INSERT_SUBVECTOR combines into a ↵Simon Pilgrim2019-02-271-51/+66
| | | | | | | | | | | | combineConcatVectorOps helper. NFCI A lot of the INSERT_SUBVECTOR combines can be more generally handled as if they have come from a CONCAT_VECTORS node. I've been investigating adding a CONCAT_VECTORS combine to X86, but this is a much easier first step that avoids the issue of handling a number of pre-legalization issues that I've encountered. Differential Revision: https://reviews.llvm.org/D58583 llvm-svn: 355015
* [llvm-readobj] Print section type values for unknown sections.Matt Davis2019-02-272-8/+46
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: This patch displays a hexadecimal section value (Elf_Shdr::sh_type) or section-relative offset when printing unknown sections. Here is a subset of the output (ignoring the fields following "Type" when dumping an ELF's GNU `--section-headers` table). Section Headers: ``` [Nr] Name Type [16] android_rel LOOS+0x1 [17] android_rela LOOS+0x2 [27] unknown 0x1000: <unknown> [28] loos LOOS+0 [30] hios VERSYM [31] loproc LOPROC+0 [33] hiproc LOPROC+0xFFFFFFF [34] louser LOUSER+0 [36] hiuser LOUSER+0x7FFFFFFF ``` As a comparison, the previous output looked something like the above, but with a blank "Type" field: ``` [Nr] Name Type [27] unknown [28] loos [30] hios VERSYM [31] loproc [33] hiproc [34] louser [36] hiuser ``` This fixes PR40773 Reviewers: jhenderson, rupprecht, Bigcheese Reviewed By: jhenderson, rupprecht, Bigcheese Subscribers: MaskRay, Bigcheese, srhines, jdoerfert, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D58701 llvm-svn: 355014
* Attempt to fix buildbot after r354972 [#1]. NFCI.Alexey Lapshin2019-02-272-3/+9
| | | | llvm-svn: 355013
* Avoid needlessly copying a block to the heap when a block literalAkira Hatanaka2019-02-2712-11/+234
| | | | | | | | | | | | initializes a local auto variable or is assigned to a local auto variable that is declared in the scope that introduced the block literal. rdar://problem/13289333 https://reviews.llvm.org/D58514 llvm-svn: 355012
* [llvm-cxxfilt] Re-enable the delimiters test on Windows.Matt Davis2019-02-271-1/+0
| | | | | | | | | | The original intent was to enable this test for Windows; however, that initial patch broke one of the build-bots. I temporarily disabled this test on Windows until that issue was resolved. It was resolved in my previous patch (cfd1d9742ee2d1b8dd6b7), and now I am re-enabling this test. llvm-svn: 355011
* [libc++] Add is_nothrow_convertible from P0758R1Louis Dionne2019-02-273-1/+88
| | | | | | | Reviewed as https://reviews.llvm.org/D58019. Thanks to Zoe Carver for the patch. llvm-svn: 355010
* [Reproducer] Make 'reproducer generate' a NOOP during replay.Jonas Devlieghere2019-02-271-0/+5
| | | | | | | Instead of filtering out the 'reproducer generate' command during replay, just make the operation a NOOP. llvm-svn: 355009
* Support framework import/include auto-completionDavid Goldman2019-02-272-6/+57
| | | | | | | | | | | | | | Frameworks filesystem representations: UIKit.framework/Headers/%header% Framework import format: #import <UIKit/%header%> Thus the completion code must map the input format of <UIKit/> to the path of UIKit.framework/Headers as well as strip the ".framework" suffix when auto-completing the framework name. llvm-svn: 355008
* Clean up the delimiters test.Matt Davis2019-02-271-30/+30
| | | | | | | | | | | | Ideally this is a NFCI, used single quotes in most cases. Hopefully this will make the Windows bot happy. I've marked this unsupported on windows, until I get my windows box setup with this patch to test. I'll remove that constraint after I'm confident this will pass on windows. I just want to silence the buildbots for now. llvm-svn: 355007
* [libc++] Remove visibility-related warnings with Clang 8Louis Dionne2019-02-272-8/+4
| | | | | | | The attributes were placed incorrectly -- they need to be after the "struct" keyword, not before. llvm-svn: 355006
* Recommit r354930 "[PGO] Context sensitive PGO (part 1)"Rong Xu2019-02-2714-75/+295
| | | | | | Fixed UBSan failures. llvm-svn: 355005
* [llvm-readobj]Add additional testing for various ELF featuresJames Henderson2019-02-2711-0/+1152
| | | | | | | | | | | | | This patch adds testing of areas of the code that are not fully tested, in particular dynamic table printing, ELF type printing, handling of edge cases where things are missing/empty (relocations/program header tables/section header table), and the --string-dump switch. Reviewed by: grimar, higuoxing, rupprecht Differential Revision: https://reviews.llvm.org/D58677 llvm-svn: 355003
* [Reproducers] Add more logging to reproducer instrumentationJonas Devlieghere2019-02-272-16/+87
| | | | | | | | | | | Debugging issues with instrumentation capture and replay can be particularly tricky, especially because part of the process takes places even before the debugger is initialized. This patch adds more logging capabilities to these classes, hidden behind a macro define. Differential revision: https://reviews.llvm.org/D58566 llvm-svn: 355002
* [llvm-objdump] Should print strings when dumping DT_RPATH, DT_RUNPATH, ↵Xing GUO2019-02-272-1/+205
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | DT_SONAME, DT_AUXILIARY and DT_FILTER tags in dynamic section. Summary: Before: ``` Dynamic Section: NEEDED libpthread.so.0 ... NEEDED ld-linux-x86-64.so.2 RPATH 0x00000000001c2e61 ``` After: ``` Dynamic Section: NEEDED libpthread.so.0 ... NEEDED ld-linux-x86-64.so.2 RPATH $ORIGIN/../lib ``` Only a small problem here, I have no idea on choosing test case. I see there's a test file(test/tools/llvm-objdump/private-headers-dynamic-section.test). But it has no DT_RPATH and DT_RUNPATH tags. Shall I replace the ELF file in the Inputs dir by a new one? Reviewers: jhenderson, grimar Reviewed By: jhenderson Subscribers: srhines, rupprecht, jfb, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D58707 llvm-svn: 355001
* [ASTImporter] Improve import of FileID.Balazs Keri2019-02-271-7/+16
| | | | | | | | | | | | | | | | | | | Summary: Even if the content cache has a directory and filename, it may be a virtual file. The old code returned with error in this case, but it is worth to try to handle the file as it were a memory buffer. Reviewers: a.sidorin, shafik, martong, a_sidorin Reviewed By: shafik Subscribers: efriedma, rnkovacs, cfe-commits, dkrupp, martong, Szelethus, gamesh411 Tags: #clang Differential Revision: https://reviews.llvm.org/D57590 llvm-svn: 355000
* [scudo][standalone] Add a standalone vector classKostya Kortchinsky2019-02-275-4/+167
| | | | | | | | | | | | | | | | | | | | | | | | | Summary: This CL adds a standalone vector class that will be used by the scoped strings when they land. We reimplement our own vector class because we can't use the std library one. It's mostly borrowed from the current sanitizer_common one, with LLVM code style changes. Additionnally a casing change in a function name that slipped through the previous review (the function isn't used yet). Reviewers: vitalybuka, eugenis, flowerhack, dmmoore415, mcgrathr, morehouse Reviewed By: vitalybuka Subscribers: mgorny, delcypher, #sanitizers, llvm-commits Tags: #llvm, #sanitizers Differential Revision: https://reviews.llvm.org/D58689 llvm-svn: 354999
* [llvm-cxxfilt] Split and demangle stdin input on certain non-alphanumerics.Matt Davis2019-02-272-7/+102
| | | | | | | | | | | | | | | | | | | | | | | | | | Summary: This patch attempts to replicate GNU c++-filt behavior when splitting stdin input for demangling. Previously, cxx-filt would split input only on spaces. Each delimited item is then demangled. From what I have tested, GNU c++filt also splits input on any character that does not make up the mangled name (notably commas, but also a large set of non-alphanumeric characters). This patch splits stdin input on any character that does not belong to the Itanium mangling format (since Itanium is currently the only supported format in llvm-cxxfilt). This is an update to PR39990 Reviewers: jhenderson, tejohnson, compnerd Reviewed By: compnerd Subscribers: erik.pilkington, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D58416 llvm-svn: 354998
* [InstCombine] Add additional add.sat overflow tests; NFCNikita Popov2019-02-271-0/+88
| | | | | | Baseline for D58593. llvm-svn: 354996
* I changed a 'enable_if<...>::type to' 'enable_if_t<...>' but forgot to ↵Marshall Clow2019-02-271-1/+1
| | | | | | remove the preceding 'typename' llvm-svn: 354995
* Added documentation for clangd v9+ featuresDmitri Gribenko2019-02-271-0/+34
| | | | | | | | | | | | Reviewers: ilya-biryukov Subscribers: ioeric, MaskRay, jkorous, arphaman, kadircet, jdoerfert, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D58717 llvm-svn: 354994
* [InstCombine] regenerate complete checks; NFCSanjay Patel2019-02-271-47/+119
| | | | llvm-svn: 354993
* Added more detailed documentation for clangdDmitri Gribenko2019-02-2724-172/+848
| | | | | | | | | | | | | | | | Summary: The text was written mostly by Sam McCall, screenshots are mostly made by me. Reviewers: ilya-biryukov Subscribers: ioeric, MaskRay, jkorous, arphaman, kadircet, jdoerfert, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D58710 llvm-svn: 354992
* gn build: Merge r354989Nico Weber2019-02-271-11/+11
| | | | llvm-svn: 354991
* [NFC] minor revision of r354929 [CUDA][HIP] Check calling convention based ↵Yaxun Liu2019-02-271-1/+5
| | | | | | | | | | on function target Add comments and move a variable to if block. Differential Revision: https://reviews.llvm.org/D57716 llvm-svn: 354990
* hwasan: Rename source files from cc to cppNico Weber2019-02-2712-20/+21
| | | | | | | | | | | | | | | | | | | As discussed elsewhere: LLVM uses cpp as its C++ source extension; the sanitizers should too. This updates files in hwasan. Patch generated by for f in lib/hwasan/*.cc ; do svn mv $f ${f%.cc}.cpp; done followed by for f in lib/hwasan/*.cpp ; do sed -i '' -e '1s/\.cc -/.cpp /' $f; done CMakeLists.txt updated manually. Differential Revision: https://reviews.llvm.org/D58620 llvm-svn: 354989
* Implment the last part of P1024: tuple-like interface to span. Reviewed as ↵Marshall Clow2019-02-278-11/+291
| | | | | | https://reviews.llvm.org/D58706. llvm-svn: 354988
* gn build: Merge r354692Nico Weber2019-02-271-0/+2
| | | | llvm-svn: 354987
* [DebugInfo] Apply subprogram attributes on behalf of owner CUEugene Leviant2019-02-274-3/+96
| | | | | | | | | | | | When using full LTO it is possible that template function definition DIE is bound to one compilation unit and it's declaration to another. We should add function declaration attributes on behalf of its owner CU otherwise we may end up with malformed file identifier in function declaration DW_AT_decl_file attribute. Differential revision: https://reviews.llvm.org/D58538 llvm-svn: 354978
* Remove XFAIL-Linux from two asan testsPavel Labath2019-02-272-6/+0
| | | | | | | | It turns out these tests actually succeed, if one has a clang with address sanitizer support enabled (i.e., has enabled the compiler-rt project). I guess none of the linux lldb devs have done that until now. llvm-svn: 354976
* Insert blocks of python code with swig instead of modify-python-lldb.pyPavel Labath2019-02-274-125/+98
| | | | | | | | | | | | | | | | | | | Summary: Swig is perfectly capable of inserting blocks of python code into its output (and we use those fascilities already), so there's no need for this to be done in a post-process step. lldb_iter is a general-purpose utility used from many classes, so I add it to the main swig file. The other two blocks are tied to a specific class, so I add it to the interface file of that class. Reviewers: zturner, jingham, serge-sans-paille Subscribers: jdoerfert, lldb-commits Differential Revision: https://reviews.llvm.org/D58350 llvm-svn: 354975
* [AMDGPU][MC] Added register size check for VOP3/SDWA/DPP operandsDmitry Preobrazhensky2019-02-275-36/+223
| | | | | | | | | | See bug 37943: https://bugs.llvm.org/show_bug.cgi?id=37943 Reviewers: artem.tamazov, arsenm, rampitec Differential Revision: https://reviews.llvm.org/D58287 llvm-svn: 354974
* [DebugInfo] add SectionedAddress to DebugInfo interfaces.Alexey Lapshin2019-02-2745-329/+796
| | | | | | | | | | | | | | | | | That patch is the fix for https://bugs.llvm.org/show_bug.cgi?id=40703 "wrong line number info for obj file compiled with -ffunction-sections" bug. The problem happened with only .o files. If object file contains several .text sections then line number information showed incorrectly. The reason for this is that DwarfLineTable could not detect section which corresponds to specified address(because address is the local to the section). And as the result it could not select proper sequence in the line table. The fix is to pass SectionIndex with the address. So that it would be possible to differentiate addresses from various sections. With this fix llvm-objdump shows correct line numbers for disassembled code. Differential review: https://reviews.llvm.org/D58194 llvm-svn: 354972
* [AMDGPU][MC][GFX8+] Added syntactic sugar for 'vgpr index' operand of ↵Dmitry Preobrazhensky2019-02-2715-69/+260
| | | | | | | | | | | | instructions s_set_gpr_idx_on and s_set_gpr_idx_mode See bug 39331: https://bugs.llvm.org/show_bug.cgi?id=39331 Reviewers: artem.tamazov, arsenm Differential Revision: https://reviews.llvm.org/D58288 llvm-svn: 354969
* AttrDocs.td: fix broken bullet-point indentationHans Wennborg2019-02-271-5/+5
| | | | llvm-svn: 354968
* [clangd] Improve global code completion when scope specifier is unresolved.Eric Liu2019-02-272-11/+42
| | | | | | | | | | | | | | | | | | | | | | | Summary: Suppose `clangd::` is unresolved in the following example. Currently, we simply use "clangd::" as the query scope. We can do better by combining with accessible scopes in the context. The query scopes can be `{clangd::, clang::clangd::}`. ``` namespace clang { clangd::^ } ``` Reviewers: ilya-biryukov, sammccall, hokein, kadircet Reviewed By: kadircet Subscribers: MaskRay, jkorous, arphaman, kadircet, jdoerfert, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D58448 llvm-svn: 354963
* [llvm-objcopy] - Check for invalidated relocations when removing a section.George Rimar2019-02-273-6/+77
| | | | | | | | | | | This is https://bugs.llvm.org/show_bug.cgi?id=40818 Removing a section that is used by relocation is an error we did not report. The patch fixes that. Differential revision: https://reviews.llvm.org/D58625 llvm-svn: 354962
* [X86][AVX] Only combine loads to broadcasts for legal typesSimon Pilgrim2019-02-273-9/+79
| | | | | | Thanks to @echristo for spotting this. llvm-svn: 354961
* [llvm-readobj]Fix error messages for bad archive members and add testing for ↵James Henderson2019-02-273-1/+112
| | | | | | | | | | | | | | archive handling llvm-readobj's error messages were broken for bad archive members. This patch fixes them, and also adds testing for archive and thin archive handling within llvm-readobj. Reviewed by: rupprecht, grimar, higuoxing Differential Revision: https://reviews.llvm.org/D58681 llvm-svn: 354960
* [LLD][ELF] - Improve "sh_addralign is not a power of 2" diagnostics.George Rimar2019-02-273-6/+17
| | | | | | | | | | This patch removes the precompiled binary from inputs, replacing it with a YAML. And teaches LLD to report a section name in case of such error. Differential revision: https://reviews.llvm.org/D58670 llvm-svn: 354959
* Fix Wenum-compare gcc7 warning. NFCI.Simon Pilgrim2019-02-271-3/+3
| | | | llvm-svn: 354958
* [clangd] Set thread priority on WindowsIlya Biryukov2019-02-271-0/+7
| | | | | | | | | | | | | | Reviewers: kadircet, gribozavr Reviewed By: kadircet, gribozavr Subscribers: ioeric, MaskRay, jkorous, arphaman, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D58683 llvm-svn: 354957
OpenPOWER on IntegriCloud