summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* Removed two function declarations that don't have definitionsDmitri Gribenko2019-08-291-6/+0
| | | | llvm-svn: 370340
* [CostModel] Model all `extractvalue`s as free.Roman Lebedev2019-08-294-48/+53
| | | | | | | | | | | | | | | | | | | Summary: As disscussed in https://reviews.llvm.org/D65148#1606412, `extractvalue` don't actually generate any code, so we should treat them as free. Reviewers: craig.topper, RKSimon, jnspaulsson, greened, asb, t.p.northover, jmolloy, dmgreen Reviewed By: jmolloy Subscribers: javed.absar, hiraditya, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D66098 llvm-svn: 370339
* [Index] Added a ShouldSkipFunctionBody callback to libIndex, and refactored ↵Dmitri Gribenko2019-08-294-80/+75
| | | | | | | | | | | | clients to use it instead of inventing their own solution Subscribers: jkorous, arphaman, kadircet, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D66879 llvm-svn: 370338
* [Index] Stopped wrapping FrontendActions in libIndex and its usersDmitri Gribenko2019-08-296-118/+81
| | | | | | | | | Exposed a new function, createIndexingASTConsumer, that creates an ASTConsumer. ASTConsumers compose well. Removed wrapping functionality from createIndexingAction. llvm-svn: 370337
* [Index] Moved the IndexDataConsumer::finish call into the IndexASTConsumer ↵Dmitri Gribenko2019-08-291-32/+24
| | | | | | | | | from IndexAction Doing so removes the last reason to expose a FrontendAction from libIndex. llvm-svn: 370336
* [CodeGen]: don't treat structures returned in registers as memory inputsAlexander Potapenko2019-08-293-6/+139
| | | | | | | | | | | | | | | | | | | | Summary: The "=r" output constraint for a structure variable passed to inline asm shouldn't be converted to "=*r", as this changes the asm directive semantics and prevents DSE optimizations. Instead, preserve the constraints and return such structures as integers of corresponding size, which are converted back to structures when storing the result. Fixes PR42672. Subscribers: cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D65234 llvm-svn: 370335
* [DebugInfo] LiveDebugValues: correctly discriminate kinds of variable locationsJeremy Morse2019-08-293-3/+86
| | | | | | | | | | | | | | | | | The missing line added by this patch ensures that only spilt variable locations are candidates for being restored from the stack. Otherwise, register or constant-value information can be interpreted as a spill location, through a union. The added regression test replicates a scenario where this occurs: the stack load from [rsp] causes the register-location DBG_VALUE to be "restored" to rsi, when it should be left alone. See PR43058 for details. Un x-fail a test that was suffering from this from a previous patch. Differential Revision: https://reviews.llvm.org/D66895 llvm-svn: 370334
* Fix signed/unsigned comparison warning. NFCI.Simon Pilgrim2019-08-291-1/+2
| | | | llvm-svn: 370333
* Fix shadow variable warning. NFCI.Simon Pilgrim2019-08-291-4/+3
| | | | llvm-svn: 370332
* [yaml2obj] - Allow placing local symbols after globals.George Rimar2019-08-292-29/+33
| | | | | | | | | | | This allows us to produce broken binaries with local symbols placed after global in '.dynsym'/'.symtab' Also, simplifies the code. Differential revision: https://reviews.llvm.org/D66799 llvm-svn: 370331
* [llvm-readobj/llvm-readelf] - Report a proper warning when dumping a broken ↵George Rimar2019-08-294-12/+91
| | | | | | | | | | | | | dynamic relocation. When we have a dynamic relocation with a broken symbol's st_name, tools report a useless error: "Invalid data was encountered while parsing the file". After this change we report a warning + "<corrupt>" as a symbol name. Differential revision: https://reviews.llvm.org/D66734 llvm-svn: 370330
* [ARM] MVE Masked loads and storesDavid Green2019-08-296-5297/+567
| | | | | | | | | | | | | | | | | | | | | | | | Masked loads and store fit naturally with MVE, the instructions being easily predicated. This adds lowering for the simple cases of masked loads and stores. It does not yet deal with widening/narrowing or pre/post inc. The llvm masked load intrinsic will accept a "passthru" value, dictating the values used for the zero masked lanes. In MVE the instructions write 0 to the zero predicated lanes, so we need to match a passthru that isn't 0 (or undef) with a select instruction to pull in the correct data after the load. We also need to do something with unaligned loads/stores. Currently this uses a similar method used in big endian, using an VLDRB.8 (and potentially a VREV in BE). This does mean that the predicate mask is converted from, for example, a v4i1 to a v16i1. The VLDR instructions are defined as using the first bit of the relevant mask lane, so this could potentially load different results if the predicate is little odd. As the input is a v4i1 however, I believe this is OK and all the bits required should be set in the predicate, making the VLDRB.8 load the same data. Differential Revision: https://reviews.llvm.org/D66534 llvm-svn: 370329
* [DebugInfo] LiveDebugValues should always revisit backedges if it skips themJeremy Morse2019-08-296-43/+211
| | | | | | | | | | | | | | | | | | | | | | | | | | | The "join" method in LiveDebugValues does not attempt to join unseen predecessor blocks if their out-locations aren't yet initialized, instead the block should be re-visited later to see if any locations have changed validity. However, because the set of blocks were all being "process"'d once before "join" saw them, that logic in "join" was actually ignoring legitimate out-locations on the first pass through. This meant that some invalidated locations were not removed from the head of loops, allowing illegal locations to persist. Fix this by removing the run of "process" before the main join/process loop in ExtendRanges. Now the unseen predecessors that "join" skips truly are uninitialized, and we come back to the block at a later time to re-run "join", see the @baz function added. This also fixes another fault where stack/register transfers in the entry block (or any other before-any-loop-block) had their tranfers initially ignored, and were then never revisited. The MIR test added tests for this behaviour. XFail a test that exposes another bug; a fix for this is coming in D66895. Differential Revision: https://reviews.llvm.org/D66663 llvm-svn: 370328
* [X86][CodeGen][NFC] Delay `combineIncDecVector()` from DAGCombine to ↵Roman Lebedev2019-08-295-44/+60
| | | | | | | | | | | | | | | | | | | | | | | | | | X86DAGToDAGISel Summary: We were previously doing it in DAGCombine. But we also want to do `sub %x, C` -> `add %x, (sub 0, C)` for vectors in DAGCombine. So if we had `sub %x, -1`, we'll transform it to `add %x, 1`, which `combineIncDecVector()` will immediately transform back into `sub %x, -1`, and here we go again... I've marked this as NFC since not a single test changes, but since that 'changes' DAGCombine, probably this isn't fully NFC. Reviewers: RKSimon, craig.topper, spatel Reviewed By: craig.topper Subscribers: hiraditya, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D62327 llvm-svn: 370327
* [DAGCombiner] (insert_vector_elt (vector_shuffle X, Y), (extract_vector_elt ↵Amaury Sechet2019-08-293-111/+77
| | | | | | | | | | | | | | | | X, N), IdxC) -> (vector_shuffle X, Y) Summary: This is beneficial when the shuffle is only used once and end up being generated in a few places when some node is combined into a shuffle. Reviewers: craig.topper, efriedma, RKSimon, lebedev.ri Subscribers: llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D66718 llvm-svn: 370326
* [ARM] Masked load and store and predicate tests. NFCDavid Green2019-08-2913-50/+7606
| | | | llvm-svn: 370325
* [InstCombine] Shift amount reassociation in bittest: trunc-of-lshr (PR42399)Roman Lebedev2019-08-293-133/+99
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: Finally, the fold i was looking forward to :) The legality check is muddy, i doubt i've groked the full generalization, but it handles all the cases i care about, and can come up with: https://rise4fun.com/Alive/26j I.e. we can perform the fold if **any** of the following is true: * The shift amount is either zero or one less than widest bitwidth * Either of the values being shifted has at most lowest bit set * The value that is being shifted by `shl` (which is not truncated) should have no less leading zeros than the total shift amount; * The value that is being shifted by `lshr` (which **is** truncated) should have no less leading zeros than the widest bit width minus total shift amount minus one I strongly suspect there is some better generalization, but i'm not aware of it as of right now. For now i also avoided using actual `computeKnownBits()`, but restricted it to constants. Reviewers: spatel, nikic, xbolva00 Reviewed By: spatel Subscribers: hiraditya, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D66383 llvm-svn: 370324
* [Index] Create PP callbacks in the ASTConsumerDmitri Gribenko2019-08-291-45/+31
| | | | | | | | Doing so removes one reason to create a custom FrontendAction. FrontendActions are not desirable because they are difficult to compose. ASTConsumers are much easier to compose. llvm-svn: 370323
* [OpenCL] Fix diagnosing enqueue_kernel call with too few argsSven van Haastregt2019-08-292-1/+5
| | | | | | | | | | | | The err_typecheck_call_too_few_args diagnostic takes arguments, but none were provided causing clang to crash when attempting to diagnose an enqueue_kernel call with too few arguments. Fixes llvm.org/PR42045 Differential Revision: https://reviews.llvm.org/D66883 llvm-svn: 370322
* [Index] Marked a bunch of classes 'final'Dmitri Gribenko2019-08-291-4/+4
| | | | | | | This file defines multiple inheritance hierarchies and 'final' helps with readability. llvm-svn: 370321
* LegalizeSetCCCondCode - Reduce scope of NeedSwap to fix cppcheck warning. NFCI.Simon Pilgrim2019-08-291-1/+1
| | | | | | No need for this to be defined outside the only switch case its used in. llvm-svn: 370320
* Fix variable set but no used warnings on NDEBUG builds. NFCI.Simon Pilgrim2019-08-291-7/+7
| | | | llvm-svn: 370319
* Fix variable set but no used warning on NDEBUG builds. NFCI.Simon Pilgrim2019-08-291-2/+2
| | | | llvm-svn: 370317
* [lldb][NFC] Try fixing TestCompletion.py on WindowsRaphael Isemann2019-08-291-2/+1
| | | | llvm-svn: 370316
* [lldb][NFC] Also test operator new/new[]/delete/delete[]/comma/addr-ofRaphael Isemann2019-08-291-0/+18
| | | | llvm-svn: 370315
* [Analyzer] Iterator Checkers - Make range errors and invalidated access fatalAdam Balogh2019-08-295-71/+441
| | | | | | | | | | | | | | Range errors (dereferencing or incrementing the past-the-end iterator or decrementing the iterator of the first element of the range) and access of invalidated iterators lead to undefined behavior. There is no point to continue the analysis after such an error on the same execution path, but terminate it by a sink node (fatal error). This also improves the performance and helps avoiding double reports (e.g. in case of nested iterators). Differential Revision: https://reviews.llvm.org/D62893 llvm-svn: 370314
* [COFF] Add a ResourceSectionRef method for getting the data entry, print it ↵Martin Storsjo2019-08-296-0/+197
| | | | | | | | in llvm-readobj Differential Revision: https://reviews.llvm.org/D66819 llvm-svn: 370311
* [COFF] Add a bounds checking helper for iterating a coff_resource_dir_tableMartin Storsjo2019-08-293-16/+28
| | | | | | | | | | Instead of blindly incrementing pointers in llvm-readobj, use this helper, which does bounds checking against the available section data. Differential Revision: https://reviews.llvm.org/D66818 llvm-svn: 370310
* [COFF] Fix error handling in ResourceSectionRefMartin Storsjo2019-08-291-3/+6
| | | | | | | | | | | Previously, the expression (Reader.readFoo()) was expanded twice, triggering asserts as one of the Error types ends up not checked (and as it was expanded twice, the method would end up called twice if it failed first). Differential Revision: https://reviews.llvm.org/D66817 llvm-svn: 370309
* [llvm-readobj] Print the resource type textually for .res filesMartin Storsjo2019-08-2918-178/+182
| | | | | | | | This already is done when dumping resources from coff objects. Differential Revision: https://reviews.llvm.org/D66816 llvm-svn: 370308
* [llvm-readobj] Remove a leftover string trim operation. NFC.Martin Storsjo2019-08-291-1/+0
| | | | | | | | This became unnecessary in SVN r359153. Differential Revision: https://reviews.llvm.org/D66815 llvm-svn: 370307
* [clangd] Update themeRuleMatcher when color theme changes in vscode extension.Johan Vikstrom2019-08-291-0/+7
| | | | | | | | | | | | | | | | | Summary: Add event listener that listens to configuration changes and reloads the ThemeRuleMatcher when the theme changes. Right now it will not recolor the files, depends on the colorizer CL for that. Reviewers: hokein, ilya-biryukov Subscribers: MaskRay, jkorous, arphaman, kadircet, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D66406 llvm-svn: 370305
* Reland "[clangd] Migrate last tweak tests to TweakTesting.h and remove old ↵Sam McCall2019-08-291-134/+33
| | | | | | | | | helpers. NFC" This reverts commit 3dcf55aa45bad800533b36b70a14ebeb2b84e219, and avoids use of multiline raw strings in macro calls. llvm-svn: 370304
* use https for llvm.org in the docSylvestre Ledru2019-08-293-11/+11
| | | | llvm-svn: 370303
* fix the bugzilla urlSylvestre Ledru2019-08-291-1/+1
| | | | llvm-svn: 370302
* Provide a real link to the doc and remove old informationSylvestre Ledru2019-08-291-15/+2
| | | | llvm-svn: 370301
* [Test][Time profiler] Fix test for python3Anton Afanasyev2019-08-291-3/+3
| | | | | | | | | | | | | | | | Summary: Fix test checking time profiler generates correct tracing json-file. `filter` works differently for python2 and python3, so unifying this. Reviewers: mgehre, nathanchance Subscribers: cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D66873 llvm-svn: 370300
* [X86] Remove isel patterns with X86VBroadcast+scalar_to_vector+load.Craig Topper2019-08-292-47/+1
| | | | | | The DAG should have these as X86VBroadcast+load. llvm-svn: 370299
* Removed dead code from clang/AST/NSAPI.hDmitri Gribenko2019-08-292-14/+0
| | | | | | | | | | Subscribers: cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D66884 llvm-svn: 370298
* [x86] Adding support for some missing intrinsics: _mm512_cvtsi512_si32Pengfei Wang2019-08-292-0/+23
| | | | | | | | | | | | | | | | | | Summary: Adding support for some missing intrinsics: _mm512_cvtsi512_si32 Reviewers: craig.topper, pengfei, LuoYuanke, spatel, RKSimon Reviewed By: craig.topper Subscribers: llvm-commits Patch by Bing Yu (yubing) Differential Revision: https://reviews.llvm.org/D66785 llvm-svn: 370297
* [X86] Remove some unneeded X86VBroadcast isel patterns that have larger than ↵Craig Topper2019-08-292-43/+0
| | | | | | | | | 128 bit input types. We should always be shrinking the input to 128 bits or smaller when the node is created. llvm-svn: 370296
* [Attributor] Deduce "noalias" attributeHideto Ueno2019-08-293-8/+109
| | | | | | | | | | | | | | | Summary: This patch adds very basic deduction for noalias. Reviewers: jdoerfert, sstefan1 Reviewed By: jdoerfert Tags: LLVM Differential Revision: https://reviews.llvm.org/D66207 llvm-svn: 370295
* [X86] Add a DAG combine to combine INSERTPS and VBROADCAST of a scalar load. ↵Craig Topper2019-08-293-59/+53
| | | | | | | | | | Remove corresponding isel patterns. We had an isel pattern to perform this, but its better to do it in DAG combine as a simplification. This also fixes the lack of patterns for AVX512 targets. llvm-svn: 370294
* [X86] Make inline assembly 'x' and 'v' constraints work for f128.Craig Topper2019-08-293-4/+29
| | | | | | | | | Including a type legalizer fix to make bitcast operand promotion work correctly when getSoftenedFloat returns f128 instead of i128. Fixes PR43157 llvm-svn: 370293
* [LoopUnroll] Use Lazy strategy for DTU used for MergeBlockIntoPredecessor.Florian Hahn2019-08-291-1/+3
| | | | | | | | | | | | | | | | | | | | We do not access the DT in the loop, so we do not have to apply updates eagerly. We can apply them lazyly and flush them after we are done merging blocks. As follow-up work, we might be able to use the DTU above as well, instead of manually updating the DT. This brings the example from PR43134 from ~100s to ~4s for a relase + assertions build on my machine. Reviewers: efriedma, kuhar, asbirlea, brzycki Reviewed By: kuhar, brzycki Differential Revision: https://reviews.llvm.org/D66911 llvm-svn: 370292
* [ObjectYAML] Fix lifetime issue in dumpDebugLinesVitaly Buka2019-08-292-7/+7
| | | | | | | | | | Subscribers: llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D66901 llvm-svn: 370289
* [sanitizer] Support monorepo layout in symbolizer build scriptVitaly Buka2019-08-291-6/+21
| | | | llvm-svn: 370288
* [python] remove testsuite vestiges.Davide Italiano2019-08-292-193/+0
| | | | llvm-svn: 370287
* [TSanRuntime] Upstream thread swift race detector.Davide Italiano2019-08-292-6/+35
| | | | | | | | | | | | | | | | | | | Summary: This is self-contained, and doesn't need anything in the compiler to work. Mainly to reduce the diff between upstream and downstream. Patch by Kuba Mracek! Reviewers: kubamracek Subscribers: lldb-commits Tags: #lldb Differential Revision: https://reviews.llvm.org/D66915 llvm-svn: 370286
* [Attributor] Improve messages in iteration verify modeJohannes Doerfert2019-08-291-11/+12
| | | | | | | When we now verify the iteration count we will see the actual count and the expected count before the assertion is triggered. llvm-svn: 370285
OpenPOWER on IntegriCloud