summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2018-10-02[clangd] Cache FS stat() calls when building preamble.linaro-local/ci/tcwg-llvm-kernel-baseline-armv8l-release-stablelinaro-local/ci/tcwg-llvm-kernel-baseline-armv8l-release-nextlinaro-local/ci/tcwg-llvm-kernel-baseline-armv8l-release-ltslinaro-local/ci/tcwg-llvm-kernel-baseline-aarch64-release-nextlinaro-local/ci/llvm-kernel-armv8l-baselinelinaro-local/ci/llvm-kernel-aarch64-baselineEric Liu
Summary: The file stats can be reused when preamble is reused (e.g. code completion). It's safe to assume that cached status is not outdated as we assume preamble files to remain unchanged. On real file system, this made code completion ~20% faster on a measured file (with big preamble). The preamble build time doesn't change much. Reviewers: sammccall, ilya-biryukov Reviewed By: sammccall Subscribers: mgorny, MaskRay, jkorous, arphaman, kadircet, cfe-commits Differential Revision: https://reviews.llvm.org/D52419
2018-10-02[CodeComplete] Re-fix accessibilty of protected members from base class.Eric Liu
Summary: The initial fix (r337453) had bug and was partially reverted (r338255). This simplies the original fix by explicitly passing the naming class to the completion consumer. Reviewers: ilya-biryukov Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/D52647
2018-10-02Revert untintentionally commited changesEric Liu
2018-10-02[Lex] TokenConcatenation now takes const PreprocessorEric Liu
Differential Revision: https://reviews.llvm.org/D52502
2018-10-02[AArch64][v8.5A] Add Memory Tagging instructionsOliver Stannard
This adds new instructions to manipluate tagged pointers, and to load and store the tags associated with memory. Patch by Pablo Barrio, David Spickett and Oliver Stannard! Differential revision: https://reviews.llvm.org/D52490
2018-10-02[AArch64][v8.5A] Add Memory Tagging system registersOliver Stannard
This adds new system registers introduced by the Memory Tagging extension. Patch by Pablo Barrio! Differential revision: https://reviews.llvm.org/D52488
2018-10-02[AArch64][v8.5A] Add MTE system instructionsOliver Stannard
The Memory Tagging Extension adds system instructions for data cache maintenance, implemented as new operands to the DC instruction. Patch by Pablo Barrio! Differential revision: https://reviews.llvm.org/D52487
2018-10-02[InstCombine] Fold ~A - Min/Max(~A, O) -> Max/Min(A, ~O) - ADavid Green
This is an attempt to get out of a local-minimum that instcombine currently gets stuck in. We essentially combine two optimisations at once, ~a - ~b = b-a and min(~a, ~b) = ~max(a, b), only doing the transform if the result is at least neutral. This involves using IsFreeToInvert, which has been expanded a little to include selects that can be easily inverted. This is trying to fix PR35875, using the ideas from Sanjay. It is a large improvement to one of our rgb to cmy kernels. Differential Revision: https://reviews.llvm.org/D52177
2018-10-02[clang] Implement Override Suggestions in Sema.Kadir Cetinkaya
Summary: In clangd we had a new type of completion suggestions for cpp class/struct/unions that will show override signatures for virtual methods in base classes. This patch implements it in sema because it is hard to deduce more info about completion token outside of Sema and handle itchy cases. See the patch D50898 for more info on the functionality. In addition to above patch this one also converts the suggestion into a CK_Pattern with whole insertion text as the name of the suggestion and factors out CodeCompletionString generation for declerations so that it can be re-used by others. Reviewers: ioeric, ilya-biryukov Reviewed By: ioeric Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/D52225
2018-10-02[clangd] Remove override result handling logic from clangdKadir Cetinkaya
Summary: Since we plan to move handling of override suggestions to Sema with D52225 this patch just makes sure clangd-side has no logic related to that anymore and updates tests. Reviewers: ioeric, ilya-biryukov Reviewed By: ioeric Subscribers: MaskRay, jkorous, arphaman, cfe-commits Differential Revision: https://reviews.llvm.org/D52226
2018-10-02[AArch64][v8.5A] Test clang option for the Memory Tagging ExtensionOliver Stannard
The implementation of this is in TargetParser, so we only need to add a test for it in clang. Patch by Pablo Barrio! Differential revision: https://reviews.llvm.org/D52493
2018-10-02[clang-tidy] NFC use CHECK-NOTES in test for cppgoreguidelines-avoid-gotoJonas Toth
Reviewers: alexfh, aaron.ballman, hokein Reviewed By: alexfh Subscribers: nemanjai, xazax.hun, kbarton, cfe-commits Differential Revision: https://reviews.llvm.org/D52686
2018-10-02[clang-tidy] NFC use CHECK-NOTES in tests for cppcoreguidelines-owning-memoryJonas Toth
Reviewers: alexfh, aaron.ballman, hokein Reviewed By: alexfh Subscribers: nemanjai, xazax.hun, kbarton, cfe-commits Differential Revision: https://reviews.llvm.org/D52687
2018-10-02[AArch64][v8.5A] Add MTE as an optional AArch64 extensionOliver Stannard
This adds the memory tagging extension, which is an optional extension introduced in v8.5A. The new instructions and registers will be added by subsequent patches. Patch by Pablo Barrio! Differential revision: https://reviews.llvm.org/D52486
2018-10-02[X86] Standardize floating point assembly commentsSimon Pilgrim
Consistently try to use APFloat::toString for floating point constant comments to get rid of differences between Constant / ConstantDataSequential values - it should help stop some of the linux-windows buildbot failures matching NaN/INF etc. as well. Differential Revision: https://reviews.llvm.org/D52702
2018-10-02[InstCombine] Tests for ~A - Min/Max(~A, O) -> Max/Min(A, ~O) - A. NFCDavid Green
2018-10-02Added warning for unary minus used with unsigned typeDavid Bolvansky
Summary: Inspired by MSVC, which found some occurrences of this expression on our code base. Fixes PR38950 Reviewers: rsmith, craig.topper, spatel, RKSimon, aaron.ballman, thakis Reviewed By: rsmith Subscribers: joerg, Quuxplusone, lebedev.ri, craig.topper, RKSimon, cfe-commits Differential Revision: https://reviews.llvm.org/D52137
2018-10-02AMDGPU: Expand atomicrmw nand in IRMatt Arsenault
2018-10-02[WebAssembly] Restore slashes in SIMD conversion namesThomas Lively
Summary: Depends on D52372 and D52442. Reviewers: aheejin, dschuff, aardappel Subscribers: sbc100, jgravelle-google, sunfish, llvm-commits Differential Revision: https://reviews.llvm.org/D52512
2018-10-02[CodeGen] Before entering the loop that copies a non-trivial array fieldAkira Hatanaka
of a non-trivial C struct, copy the preceding trivial fields that haven't been copied. This commit fixes a bug where the instructions used to copy the preceding trivial fields were emitted inside the loop body. rdar://problem/44185064
2018-10-02[MCA] Remove SM.hasNext() call in FetchStage::execute.Owen Rodley
Summary: This is redundant, as FetchStage::getNextInstruction already checks this and returns llvm::ErrorSuccess() as appropriate. NFC. Reviewers: andreadb Subscribers: gbedwell, llvm-commits Differential Revision: https://reviews.llvm.org/D52642
2018-10-02[sanitizer] Include inlined frames into __sanitizer_symbolize_pc outputVitaly Buka
Summary: Behavior for existing used is not changing as the first line is going to be the same, and it was invalid to try to read more lines. New clients can read until they get empty string. Reviewers: eugenis, morehouse Subscribers: kubamracek, eraman, llvm-commits Differential Revision: https://reviews.llvm.org/D52743
2018-10-02[AArch64][DAGCombiner]: change -stop-after=isel to instruction-selectFangrui Song
"isel" is registered by AMDGPU. The test will break if the AMDGPU target is not built.
2018-10-02[ELF] Read the call graph profile from object files.Michael J. Spencer
This uses the call graph profile embedded in the object files to construct the call graph. This is read from a SHT_LLVM_CALL_GRAPH_PROFILE (0x6fff4c02) section as (uint32_t, uint32_t, uint64_t) tuples as (from symbol index, to symbol index, weight). Differential Revision: https://reviews.llvm.org/D45850
2018-10-01[SimplifyCFG] Use Value::hasNUses instead of 'getNumUses() =='. NFCICraig Topper
getNumUses is linear in the number of uses. Since we're looking for a specific use count, we can use hasNUses which will stop as soon as it determines there are more than N uses instead of walking all of them.
2018-10-01[llvm-mca] Rename the 'Subtract' method to 'subtract'Matt Davis
2018-10-01[SimplifyCFG] Update comments that refer to CondBB to say ThenBB instead. NFCCraig Topper
There is no variable in this function named CondBB, but there is one named ThenBB and I believe the comments are all refering to it.
2018-10-01[PDB] Add support for more kinds of PDB Sym Tags.Zachary Turner
DIA SDK is returning several new sym tag types, so we update the enumeration and printing code to support these.
2018-10-01Revert: r343521 and r343541: [globalisel] Add a combiner helpers for ↵Daniel Sanders
extending loads and use them in a pre-legalize combiner for AArch64 There's a strange assertion on two of the Green Dragon bots that goes away when this is reverted. The assertion is in RegBankAlloc and if it is this commit then -verify-machine-instrs should have caught it earlier in the pipeline.
2018-10-01Enable C++ tests to run in the -gmodules configuration on Darwin.Adrian Prantl
This addresses PR36048 (http://llvm.org/bugs/show_bug.cgi?id=36048) rdar://problem/36776281
2018-10-01[codeview] Simplify S_DEFRANGE emission code, NFCReid Kleckner
These assembler directives are still pretty unreadable and it would be nice to clean them up at some point.
2018-10-01[codeview] Emit S_FRAMEPROC and use S_DEFRANGE_FRAMEPOINTER_RELReid Kleckner
Summary: Before this change, LLVM would always describe locals on the stack as being relative to some specific register, RSP, ESP, EBP, ESI, etc. Variables in stack memory are pretty common, so there is a special S_DEFRANGE_FRAMEPOINTER_REL symbol for them. This change uses it to reduce the size of our debug info. On top of the size savings, there are cases on 32-bit x86 where local variables are addressed from ESP, but ESP changes across the function. Unlike in DWARF, there is no FPO data to describe the stack adjustments made to push arguments onto the stack and pop them off after the call, which makes it hard for the debugger to find the local variables in frames further up the stack. To handle this, CodeView has a special VFRAME register, which corresponds to the $T0 variable set by our FPO data in 32-bit. Offsets to local variables are instead relative to this value. This is part of PR38857. Reviewers: hans, zturner, javed.absar Subscribers: aprantl, hiraditya, JDevlieghere, llvm-commits Differential Revision: https://reviews.llvm.org/D52217
2018-10-01Distinguish `__block` variables that are captured by escaping blocksAkira Hatanaka
from those that aren't. This patch changes the way __block variables that aren't captured by escaping blocks are handled: - Since non-escaping blocks on the stack never get copied to the heap (see https://reviews.llvm.org/D49303), Sema shouldn't error out when the type of a non-escaping __block variable doesn't have an accessible copy constructor. - IRGen doesn't have to use the specialized byref structure (see https://clang.llvm.org/docs/Block-ABI-Apple.html#id8) for a non-escaping __block variable anymore. Instead IRGen can emit the variable as a normal variable and copy the reference to the block literal. Byref copy/dispose helpers aren't needed either. This reapplies r343518 after fixing a use-after-free bug in function Sema::ActOnBlockStmtExpr where the BlockScopeInfo was dereferenced after it was popped and deleted. rdar://problem/39352313 Differential Revision: https://reviews.llvm.org/D51564
2018-10-01Fix the Windows build in GlobalISelReid Kleckner
Clang-cl was complaining about some sort of constexpr narrowing bug: C:\src\llvm-project\llvm\lib\CodeGen\GlobalISel\CombinerHelper.cpp(136,31): error: non-constant-expression cannot be narrowed from type 'llvm::TargetOpcode::(anonymous enum at C:\src\llvm-project\llvm\include\llvm/CodeGen/TargetOpcodes.h:22:1)' to 'unsigned int' in initializer list [-Wc++11-narrowing] unsigned(MI.getOpcode()) == unsigned(TargetOpcode::G_LOAD) ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ C:\src\llvm-project\llvm\lib\CodeGen\GlobalISel\CombinerHelper.cpp(136,31): note: insert an explicit cast to silence this issue unsigned(MI.getOpcode()) == unsigned(TargetOpcode::G_LOAD) ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ static_cast<unsigned int>(
2018-10-01Recommit r343499 "[X86] Enable load folding in the test shrinking code"Craig Topper
Original message: This patch adds load folding support to the test shrinking code. This was noticed missing in the review for D52669
2018-10-01Recommit r343498 "[X86] Improve test instruction shrinking when the sign ↵Craig Topper
flag is used and the output of the and is truncated." This includes a fix to prevent i16 compares with i32/i64 ands from being shrunk if bit 15 of the and is set and the sign bit is used. Original commit message: Currently we skip looking through truncates if the sign flag is used. But that's overly restrictive. It's safe to look through the truncate as long as we ensure one of the 3 things when we shrink. Either the MSB of the mask at the shrunken size isn't set. If the mask bit is set then either the shrunk size needs to be equal to the compare size or the sign There are still missed opportunities to shrink a load and fold it in here. This will be fixed in a future patch.
2018-10-01Sort expected test output after previous commitStephen Kelly
2018-10-01[MinGW] Allow using ASanMartin Storsjo
Linking to ASan for MinGW is similar to MSVC, but MinGW always links the MSVCRT dynamically, so there is only one of the MSVC cases to consider. When linking to a shared compiler runtime library on MinGW, the suffix of the import library is .dll.a. The existing case of .dll as suffix for windows in general doesn't seem correct (since this is used for linking). As long as callers never actually set the Shared flag, the default static suffix of .lib also worked fine for import libraries as well. Differential Revision: https://reviews.llvm.org/D52538
2018-10-01[clang-query] Test non-code-completion on single letter shortcutsStephen Kelly
2018-10-01[clang-query] Add missing quit testStephen Kelly
2018-10-01[sanitizer] Small buffer tests for __sanitizer_symbolize_pcVitaly Buka
2018-10-01[clang-query] Add missing 'l' command handlingStephen Kelly
The `let` command was added in commit 045c15ba (Add new 'let' command to bind arbitrary values into constants., 2014-04-23). The `let` command and the non-existant `l` command were documented in commit 233092a0 (Add 'let' to the help message., 2015-02-27). Implement the `l` command now for completeness.
2018-10-01[clang-query] Sort command optionsStephen Kelly
2018-10-01Revert r343518.Akira Hatanaka
Bots are still failing. http://lab.llvm.org:8011/builders/sanitizer-x86_64-linux-fast/builds/24420 http://lab.llvm.org:8011/builders/llvm-clang-x86_64-expensive-checks-win/builds/12958
2018-10-01Update CMakeLists.txt snippet so that example compilesStephen Kelly
Summary: Previous to this the example didn't work out of the box, it seems some cmake config changed between when this was written and now. Author: Dan Zimmerman <daniel.zimmerman@me.com> Reviewers: modocache, steveire Reviewed By: steveire Subscribers: smeenai, steveire, cfe-commits Differential Revision: https://reviews.llvm.org/D52664
2018-10-01[InstCombine] add inverse test for vector trunc canonical form; NFCSanjay Patel
2018-10-01[clang-tidy] Build it even without static analyzerStephen Kelly
Conditionally compile the parts of clang-tidy which depend on the static analyzer. Funnily enough, I made the patch to exclude this from the build in 2013, and it was committed with the comment that the tool should not be fully excluded, but only the parts of it which depend on the analyzer should be excluded. http://lists.llvm.org/pipermail/cfe-commits/Week-of-Mon-20130617/081797.html This commit implements that idea. Reviewed By: aaron.ballman Tags: #clang-tools-extra Differential Revision: https://reviews.llvm.org/D52334
2018-10-01[InstCombine] regenerate test checks; NFCSanjay Patel
These files used an old version of the script. We regex more now.
2018-10-01[clangd] exclude check-clangd from check-all, fix buildbot failure.Haojian Wu
check-clangd is included via check-clang-tools, otherwise we will run two instances of check-clangd in parallel when running 'check-all', which may have race condition.
2018-10-01[PowerPC] Folding XForm to DForm loads requires alignment for some DForm loads.Stefan Pintilie
Going from XForm Load to DSForm Load requires that the immediate be 4 byte aligned. If we are not aligned we must leave the load as LDX (XForm). This bug is causing a compile-time failure in the benchmark h264ref. Differential Revision: https://reviews.llvm.org/D51988