summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* [lldb-mi] Re-implement a few MI commands.Alexander Polyakov2018-07-028-463/+190
| | | | | | | | | | | | | | | Summary: This patch updates exec-next-instruction, exec-step-instruction, exec-finish, exec-interrupt commands to use SB API instead of HandleCommand. Reviewers: aprantl, clayborg Reviewed By: aprantl Subscribers: ki.stfu, lldb-commits Differential Revision: https://reviews.llvm.org/D48520 llvm-svn: 336155
* FIx XCode project files for lldbRaphael Isemann2018-07-021-2554/+2560
| | | | | | | | | | | | | Summary: Fixes the XCode builds that started failing when i added CompletionRequest.cpp/.h. The patch is so large because XCode decided to write the lines back in its own order, but essentially we only added on e file. Subscribers: srhines, lldb-commits Differential Revision: https://reviews.llvm.org/D48858 llvm-svn: 336154
* Per C++ [over.match.copy]p1, direct-initialization of a reference canRichard Smith2018-07-022-4/+15
| | | | | | only invoke converting constructors of the reference's underlying type. llvm-svn: 336153
* Remove absolute path in testTeresa Johnson2018-07-021-1/+1
| | | | | | | My test change in r336148 accidentally included an absolute path, clean that up to fix bot failures. llvm-svn: 336151
* [ORC] Verify modules when running LLLazyJIT in LLI, and deal with fallout.Lang Hames2018-07-022-5/+21
| | | | | | | | The verifier identified several modules that were broken due to incorrect linkage on declarations. To fix this, CompileOnDemandLayer2::extractFunction has been updated to change decls to external linkage. llvm-svn: 336150
* Fixed compilation failure after the code completion refactor patchRaphael Isemann2018-07-022-4/+4
| | | | | | | | Subscribers: lldb-commits Differential Revision: https://reviews.llvm.org/D48855 llvm-svn: 336149
* [ThinLTO] Fix printing of module paths for distributed backend indexesTeresa Johnson2018-07-022-17/+51
| | | | | | | | | | | | | | | | Summary: In the individual index files emitted for distributed ThinLTO backends, the module path ids are not contiguous. Assign slots to module paths in order to handle this better and also to get contiguous numbering in the summary assembly. Reviewers: davidxl, dexonsmith Subscribers: mehdi_amini, inglorion, eraman, llvm-commits, steven_wu Differential Revision: https://reviews.llvm.org/D48698 llvm-svn: 336148
* [lldbsuite, windows] Don't crash LLDB when we try to retrieve a register on ↵Stella Stamenova2018-07-025-12/+18
| | | | | | | | | | | | | | | | Windows Summary: 1) When ReadRegister is called with a null register into on Windows, rather than crashing due to an access violation, simply return false. Not all registers and properties will be read or calculated correctly, but that is consistent with other platforms that also return false in that case 2) Update a couple of tests to reference pr37995 as their reason for failure since it is much more accurate. Support for floating point registers doesn't exist on Windows at all, rather than having issues. Reviewers: asmith, labath, zturner Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D48844 llvm-svn: 336147
* Refactoring for for the internal command line completion API (NFC)Raphael Isemann2018-07-0224-479/+536
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: This patch refactors the internal completion API. It now takes (as far as possible) a single CompletionRequest object instead o half a dozen in/out/in-out parameters. The CompletionRequest contains a common superset of the different parameters as far as it makes sense. This includes the raw command line string and raw cursor position, which should make the `expr` command possible to implement (at least without hacks that reconstruct the command line from the args). This patch is not intended to change the observable behavior of lldb in any way. It's also as minimal as possible and doesn't attempt to fix all the problems the API has. Some Q&A: Q: Why is this not fixing all the problems in the completion API? A: Because is a blocker for the expr command completion which I want to get in ASAP. This is the smallest patch that unblocks the expr completion patch and which allows trivial refactoring in the future. The patch also doesn't really change the internal information flow in the API, so that hopefully saves us from ever having to revert and resubmit this humongous patch. Q: Can we merge all the copy-pasted code in the completion methods (like computing the current incomplete arg) into CompletionRequest class? A: Yes, but it's out of scope for this patch. Q: Why the `word_complete = request.GetWordComplete(); ... ` pattern? A: I don't want to add a getter that returns a reference to the internal integer. So we have to use a temporary variable and the Getter/Setter instead. We don't throw exceptions from what I can tell, so the behavior doesn't change. Q: Why are we not owning the list of matches? A: Because that's how the previous API works. But that should be fixed too (in another patch). Q: Can we make the constructor simpler and compute some of the values from the plain command? A: I think this works, but I rather want to have this in a follow up commit. Especially when making nested request it's a bit awkward that the parsed arguments behave as both input/output (as we should in theory propagate the changes on the nested request back to the parent request if we don't want to change the behavior too much). Q: Can't we pass one const request object and then just return another result object instead of mixing them together in one in/out parameter? A: It's hard to get keep the same behavior with that pattern, but I think we can also get a nice API with just a single request object. If we make all input parameters read-only, we have a clear separation between what is actually an input and what an output parameter (and hopefully we get rid of the in-out parameters). Q: Can we throw out the 'match' variables that are not implemented according to the comment? A: We currently just forward them as in the old code to the different methods, even though I think they are really not used. We can easily remove and readd them once every single completion method just takes a CompletionRequest, but for now I prefer NFC behavior from the perspective of the API user. Reviewers: davide, jingham, labath Reviewed By: jingham Subscribers: mgorny, friss, lldb-commits Differential Revision: https://reviews.llvm.org/D48796 llvm-svn: 336146
* [WebAssembly] Support for atomic storesHeejin Ahn2018-07-027-2/+561
| | | | | | | | | | | | Summary: Add support for atomic store instructions. Reviewers: dschuff Subscribers: sbc100, jgravelle-google, sunfish, llvm-commits Differential Revision: https://reviews.llvm.org/D48839 llvm-svn: 336145
* [ARM] Fix PR37382: Don't optimize mul.with.overflow on thumbv6m.Vadzim Dambrouski2018-07-022-2/+11
| | | | | | | | | | | | Reviewers: efriedma, rogfer01, javed.absar Reviewed By: efriedma, rogfer01 Subscribers: kristof.beyls, chrib, llvm-commits Differential Revision: https://reviews.llvm.org/D48846 llvm-svn: 336144
* [LTO] Errors in LLVM backend should manifest as lld errorsSam Clegg2018-07-024-3/+37
| | | | | | Differential Revision: https://reviews.llvm.org/D48812 llvm-svn: 336143
* [llvm-mca] Clear the content of map VariantDescriptors in InstrBuilder ↵Andrea Di Biagio2018-07-022-0/+5
| | | | | | | | | | | | | | before we start analyzing a new CodeBlock. NFCI. Different CodeBlocks don't overlap. The same MCInst cannot appear in more than one code block because all blocks are instantiated before the simulation is run. We should always clear the content of map VariantDescriptors before every simulation, since VariantDescriptors cannot possibly store useful information for the next blocks. It is also "safer" to clear its content because `MCInst*` is used as the key type for map VariantDescriptors. llvm-svn: 336142
* [Win32] Overload ==, != for locale_t and long longPirama Arumuga Nainar2018-07-021-0/+8
| | | | | | | | | | | | | | | | Summary: _is_chartype_l (needed for isxdigit_l) in MinGW compares locale_t and NULL. NULL is 'long long' for 64-bit, and this results in ambiguous overloads when compiled with Clang. Define a concrete overload for the operators to fix the ambiguity. Reviewers: mstorsjo, EricWF, srhines, danalbert Subscribers: christof, cfe-commits, ldionne Differential Revision: https://reviews.llvm.org/D48749 llvm-svn: 336141
* [SCEV] Strengthen StrengthenNoWrapFlags (reapply r334428).Tim Shen2018-07-0218-55/+70
| | | | | | | | | | | | | | | | Summary: Comment on Transforms/LoopVersioning/incorrect-phi.ll: With the change SCEV is able to prove that the loop doesn't wrap-self (due to zext i16 to i64), disabling the entire loop versioning pass. Removed the zext and just use i64. Reviewers: sanjoy Subscribers: jlebar, hiraditya, javed.absar, bixia, llvm-commits Differential Revision: https://reviews.llvm.org/D48409 llvm-svn: 336140
* [scudo] Enable Scudo memory hooks for Fuchsia.Kostya Kortchinsky2018-07-021-2/+6
| | | | | | | | | | | | | | | | | Summary: It would be useful for Flutter apps, especially, to be able to use malloc hooks to debug memory leaks on Fuchsia. They're not able to do this right now, so it'd be a nice bonus to throw in with the Scudo switchover. Reviewers: cryptoad, alekseyshl Reviewed By: cryptoad Differential Revision: https://reviews.llvm.org/D48618 llvm-svn: 336139
* [WebAssembly] Fix fast-isel optimization of branch conditions.Dan Gohman2018-07-022-1/+49
| | | | | | | | | | | LLVM doesn't guarantee anything about the high bits of a register holding an i1 value at the IR level, so don't translate LLVM IR i1 values directly into WebAssembly conditional branch operands. WebAssembly's conditional branches do demand all 32 bits be valid. Fixes PR38019. llvm-svn: 336138
* [CodeGenCXX] Emit strip.invariant.group with -fstrict-vtable-pointersPiotr Padlewski2018-07-026-20/+376
| | | | | | | | | | | | | | | Summary: Emmiting new intrinsic that strips invariant.groups to make devirtulization sound, as described in RFC: Devirtualization v2. Reviewers: rjmccall, rsmith, amharc, kuhar Subscribers: llvm-commits, cfe-commits Differential Revision: https://reviews.llvm.org/D47299 Co-authored-by: Krzysztof Pszeniczny <krzysztof.pszeniczny@gmail.com> llvm-svn: 336137
* [ELF] Fix other tests after r336129Fangrui Song2018-07-028-12/+12
| | | | llvm-svn: 336136
* [ELF] Fix just-symbols*.s after r336129Fangrui Song2018-07-022-3/+3
| | | | llvm-svn: 336135
* [X86] Add phony registers for high halves of regs with low halvesKrzysztof Parzyszek2018-07-027-44/+87
| | | | | | | | | | Add registers still missing after r328016 (D43353): - for bits 15-8 of SI, DI, BP, SP (*H), and R8-R15 (*BH), - for bits 31-16 of R8-R15 (*WH). Thanks to Craig Topper for pointing it out. llvm-svn: 336134
* Replace "Replacable" with "Replaceable". [NFC]Alina Sbirlea2018-07-021-13/+13
| | | | llvm-svn: 336133
* Implement LWG 2946, 3075 and 3076. Reviewed as https://reviews.llvm.org/D48616Marshall Clow2018-07-0228-148/+755
| | | | llvm-svn: 336132
* Replace unused output filenames with /dev/null in testsFangrui Song2018-07-029-9/+9
| | | | | | Similar to rLLD336129 llvm-svn: 336131
* [SLP] Recognize min/max pattern using instructions producing same values.Farhana Aleen2018-07-022-65/+126
| | | | | | | | | | | | | | | | | | | Summary: It is common to have the following min/max pattern during the intermediate stages of SLP since we only optimize at the end. This patch tries to catch such patterns and allow more vectorization. %1 = extractelement <2 x i32> %a, i32 0 %2 = extractelement <2 x i32> %a, i32 1 %cond = icmp sgt i32 %1, %2 %3 = extractelement <2 x i32> %a, i32 0 %4 = extractelement <2 x i32> %a, i32 1 %select = select i1 %cond, i32 %3, i32 %4 Author: FarhanaAleen Reviewed By: ABataev, RKSimon, spatel Differential Revision: https://reviews.llvm.org/D47608 llvm-svn: 336130
* [ELF] Replace unused output filenames with /dev/null in testsFangrui Song2018-07-02213-241/+241
| | | | | | Post commit review at rLLD335992 llvm-svn: 336129
* [InstCombine] reverse canonicalization of add --> or to allow more shuffle ↵Sanjay Patel2018-07-022-24/+63
| | | | | | | | | | | | | | | | folding This extends D48485 to allow another pair of binops (add/or) to be combined either with or without a leading shuffle: or X, C --> add X, C (when X and C have no common bits set) Here, we need value tracking to determine that the 'or' can be reversed into an 'add', and we've added general infrastructure to allow extending to other opcodes or moving to where other passes could use that functionality. Differential Revision: https://reviews.llvm.org/D48662 llvm-svn: 336128
* [MC] Error on a .zerofill directive in a non-virtual sectionFrancis Visoiu Mistrih2018-07-0216-21/+147
| | | | | | | | | | | | | | | On darwin, all virtual sections have zerofill type, and having a .zerofill directive in a non-virtual section is not allowed. Instead of asserting, show a nicer error. In order to use the equivalent of .zerofill in a non-virtual section, the usage of .zero of .space is required. This patch replaces the assert with an error. Differential Revision: https://reviews.llvm.org/D48517 llvm-svn: 336127
* nm: Add -no-weak flag for hiding weak symbolsDave Lee2018-07-023-1/+13
| | | | | | | | | | | | | | | | | | Summary: This adds a new -no-weak flag to nm to hide weak symbols in its output. This also adds a -W alias for this which is analogous to -U. Patch by Keith Smiley Reviewers: kastiglione, enderby, compnerd Reviewed By: kastiglione Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D48751 llvm-svn: 336126
* [SLPVectorizer][X86] Begin adding alternate tests for call operatorsSimon Pilgrim2018-07-021-0/+65
| | | | | | Alternate opcode handling only supports binary operators, these tests demonstrate a missed opportunity to vectorize ceil/floor calls llvm-svn: 336125
* [analyzer] [tests] Pass clang executable path to prefix-less executor scripts.George Karpenkov2018-07-021-0/+1
| | | | llvm-svn: 336124
* Tighten up a test for -check-debugify, NFCVedant Kumar2018-07-021-2/+1
| | | | | | | | | Use an -implicit-check-not to make sure an error which should not occur in fact does not occur before the first CHECK line. Suggested by Paul Robinson in post-commit feedback for r335897. llvm-svn: 336123
* [CostModel][X86] Add cost tests for fp rounding intrinsicsSimon Pilgrim2018-07-021-0/+519
| | | | | | Add cost tests for fp ceil, floor, nearbyint, rint and trunc. llvm-svn: 336122
* [X86] Don't use aligned load/store instructions for fp128 if the load/store ↵Craig Topper2018-07-024-8/+21
| | | | | | | | | | isn't aligned. Similarily, don't fold fp128 loads into SSE instructions if the load isn't aligned. Unless we're targeting an AMD CPU that doesn't check alignment on arithmetic instructions. Should fix PR38001 llvm-svn: 336121
* [AArch64][GlobalISel] Any-extend vararg parameters to stack slot size on Darwin.Amara Emerson2018-07-022-3/+6
| | | | | | | | | | | We currently don't any-extend vararg parameters before storing them to the stack locations on Darwin. However, SelectionDAG however does this, and so user code is in the wild which inadvertently relies on this extension. This can manifest in cases where the value stored is (int)0, but the actual parameter is interpreted by va_arg as a pointer, and so not extending to 64 bits causes the callee to load additional undefined bits. llvm-svn: 336120
* [clangd] Implement hover for "auto" and "decltype"Marc-Andre Laperle2018-07-024-3/+415
| | | | | | | | | | | | | | | | | | | Summary: This allows hovering on keywords that refer to deduced types. This should cover most useful cases. Not covered: - auto template parameters: Since this can be instantiated with many types, it would not be practical to show the types. - Structured binding: This could be done later to show multiple deduced types in the hover. - auto:: (part of concepts): Outside the scope of this patch. Signed-off-by: Marc-Andre Laperle <marc-andre.laperle@ericsson.com> Subscribers: ilya-biryukov, ioeric, MaskRay, jkorous, cfe-commits Differential Revision: https://reviews.llvm.org/D48159 llvm-svn: 336119
* [WebAssembly] Set threadmodel during LTOSam Clegg2018-07-022-1/+18
| | | | | | | | Subscribers: dschuff, mehdi_amini, inglorion, jgravelle-google, aheejin, sunfish, steven_wu, llvm-commits Differential Revision: https://reviews.llvm.org/D48689 llvm-svn: 336118
* Revert "[Dominators] Add the DomTreeUpdater class"Jakub Kuderski2018-07-026-1450/+0
| | | | | | | | Temporary revert because of a failing test on some buildbots. This reverts commit r336114. llvm-svn: 336117
* [WebAssembly] Convert remaining tests from elf to wasm output formatSam Clegg2018-07-023-11/+12
| | | | | | Differential Revision: https://reviews.llvm.org/D48748 llvm-svn: 336116
* Follow up of r335953 - [ARM][AArch64] Armv8.4-A EnablementSjoerd Meijer2018-07-022-2/+3
| | | | | | Imply dotprod for armv8.4-a, because it is mandatory from v8.4. llvm-svn: 336115
* [Dominators] Add the DomTreeUpdater classJakub Kuderski2018-07-026-0/+1450
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: This patch is the first in a series of patches related to the [[ http://lists.llvm.org/pipermail/llvm-dev/2018-June/123883.html | RFC - A new dominator tree updater for LLVM ]]. This patch introduces the DomTreeUpdater class, which provides a cleaner API to perform updates on available dominator trees (none, only DomTree, only PostDomTree, both) using different update strategies (eagerly or lazily) to simplify the updating process. —Prior to the patch— - Directly calling update functions of DominatorTree updates the data structure eagerly while DeferredDominance does updates lazily. - DeferredDominance class cannot be used when a PostDominatorTree also needs to be updated. - Functions receiving DT/DDT need to branch a lot which is currently necessary. - Functions using both DomTree and PostDomTree need to call the update function separately on both trees. - People need to construct an additional DeferredDominance class to use functions only receiving DDT. —After the patch— Patch by Chijun Sima <simachijun@gmail.com>. Reviewers: kuhar, brzycki, dmgreen, grosser, davide Reviewed By: kuhar, brzycki Subscribers: vsk, mgorny, llvm-commits Author: NutshellySima Differential Revision: https://reviews.llvm.org/D48383 llvm-svn: 336114
* [X86][SSE] Blend any v8i16/v4i32 shift with 2 shift unique valuesSimon Pilgrim2018-07-022-69/+34
| | | | | | We were only doing this for basic blends, despite shuffle lowering now being good enough to handle more complex blends. This means that the two v8i16 splat shifts are performed in parallel instead of serially as the general shift case. llvm-svn: 336113
* [X86][SSE] Add v8i16 shift test for 2 shift values that doesn't match basic ↵Simon Pilgrim2018-07-021-0/+32
| | | | | | | | blend We have special case support for 2 shift values for basic blends, but irregular shift patterns end up using the generic lowering, despite shuffle lowering being good enough to handle more complex blends. llvm-svn: 336112
* [ValueTracking] allow undef elements when matching vector absSanjay Patel2018-07-022-36/+31
| | | | llvm-svn: 336111
* Disable failing test on x86_64-pc-windows-gnu, see PR38006.Yaron Keren2018-07-021-1/+1
| | | | llvm-svn: 336110
* [CodeGen] Make block removal order deterministic in CodeGenPrepareDavid Stenberg2018-07-021-3/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: Replace use of a SmallPtrSet with a SmallSetVector to make the worklist iteration order deterministic. This is done as the order the blocks are removed may affect whether or not PHI nodes in successor blocks are removed. For example, consider the following case where %bb1 and %bb2 are removed: bb1: br i1 undef, label %bb3, label %bb4 bb2: br i1 undef, label %bb4, label %bb3 bb3: pv1 = phi type [ undef, %bb1 ], [ undef, %bb2], [ v0, %other ] br label %bb4 bb4: pv2 = phi type [ undef, %bb1 ], [ undef, %bb2 ], [ pv1, %bb3 ], [ v0, %other ] If %bb2 is removed before %bb1, the incoming values from %bb1 and %bb2 to pv1 will be removed before %bb1 is removed as a predecessor to %bb4. The pv1 node will thus be optimized out (to v0) at the time %bb1 is removed as a predecessor to %bb4, leaving the blocks as following when the incoming value from %bb1 has been removed: bb3: ; pv1 optimized out, incoming value to pv2 is v0 br label %bb4 bb4: pv2 = phi type [ v0, %bb3 ], [ v0, %other ] The pv2 PHI node will be optimized away by removePredecessor() as all incoming values are identical. In case %bb2 is removed after %bb1, pv1 will not be optimized out at the time %bb2 is removed as a predecessor to %bb4, leaving the blocks as following when the incoming value from %bb2 to pv2 has been removed: bb3: pv1 = phi type [ undef, %bb2 ], [ v0, %other ] br label %bb4 bb4: pv2 = phi type [ pv1, %bb3 ], [ v0, %other ] The pv2 PHI node will thus not be removed in this case, ultimately leading to the following output bb3: ; pv1 optimized out, incoming value to pv2 is v0 br label %bb4 bb4: pv2 = phi type [ v0, %bb3 ], [ v0, %other ] I have not looked into changing DeleteDeadBlock() so that the redundant PHI nodes are removed. I have not added a test case, as I was not able to create a particularly small and (not messy) reproducer. This is likely due to SmallPtrSet behaving deterministically when in small mode. Reviewers: void, dexonsmith, spatel, skatkov, fhahn, bkramer, nhaehnle Reviewed By: fhahn Subscribers: mgrang, llvm-commits Differential Revision: https://reviews.llvm.org/D48369 llvm-svn: 336109
* Test commit accessBalazs Keri2018-07-021-1/+1
| | | | llvm-svn: 336108
* [X86] Fix test/MC/AsmParser/exprs-invalid.s after rL336104Alex Bradbury2018-07-021-1/+1
| | | | | | | | This was my mistake for only running test/MC/X86 and test/CodeGen/X86. Arguably .word should be removed from this test, as it is not supported universally. llvm-svn: 336107
* [ELF] - Cleanup error reporting code and cover with the test. NFC.George Rimar2018-07-022-2/+21
| | | | | | | | | | | | | | | | We have the following code that is uncovered with the test: https://github.com/llvm-mirror/lld/blob/master/ELF/Target.cpp#L95 This patch: 1) Removes "!IS" check. Because at that point of execution (we are reolving the relocations during writing output) we should only have InputSection type of the sections in the vector. (because we already converted MergeInputSection in mergeSections() and combined EhInputSections in combineEhFrameSections()). 2) Covers the "!IS->getParent()" with the test. llvm-svn: 336106
* [llvm-exegesis] Change how the native architecture is determinedJohn Brawn2018-07-022-2/+3
| | | | | | | | | | | | Currently the llvm-exegesis native architecture is determined by comparing the llvm native architecture with X86, so to add a new target would mean adding a new check. Change this to building up a list of the targets llvm-exegesis supports then using that, as this means that when adding a new target you just add the target to the list of supported targets. Differential Revision: https://reviews.llvm.org/D48778 llvm-svn: 336105
OpenPOWER on IntegriCloud