- Apr 23, 2020
-
-
Victor Huang authored
1. Use Subtarget.isUsingPCRelativeCalls() in LowerConstantPool to check if using PCRelative addressing. 2. Change MO_GOT_FLAG = 32 to MO_GOT_FLAG = 8 in PPC.h to use consecutive bits. Differential Revision: https://reviews.llvm.org/D78406
-
Mircea Trofin authored
Reviewers: craig.topper, dblaikie Subscribers: hiraditya, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D78666
-
Nicolas Vasilache authored
The EDSC discussion [thread](https://llvm.discourse.group/t/evolving-builder-apis-based-on-lessons-learned-from-edsc/879) points out that ValueHandle has become an unnecessary level of abstraction since MLIR switch from `Value *` to `Value` everywhere. This revision removes this level of indirection.
-
Raphael Isemann authored
Commit c9e6b701 changed the API but didn't update this macOS-specific test.
-
Peter Smith authored
The contents of the .ARM.exidx section must be ordered by SHF_LINK_ORDER rules. We don't need to know the precise address for this order, but we do need to know the relative order of sections. We have been using the sectionIndex for this purpose, this works when the OutputSection order has a monotonically increasing virtual address, but it is possible to write a linker script with non-monotonically increasing virtual address. For these cases we need to evaluate the base address of the OutputSection so that we can order the .ARM.exidx sections properly. This change moves the finalisation of .ARM.exidx till after the first call to AssignAddresses. This permits us to sort on virtual address which is linker script safe. It also permits a fix for part of pr44824 where we generate .ARM.exidx section for the vector table when that table is so far away it is out of range of the .ARM.exidx section. This fix will come in a follow up patch. Differential Revision: https://reviews.llvm.org/D78422
-
Xing GUO authored
-
Pavel Labath authored
Calling Disconnect while the read thread is running is racy because the thread can also call Disconnect. This is a follow-up to b424b0bf, which reorders other occurences of Disconnect/StopReadThread I can find, and also adds an assertion to guard against new occurences being introduced.
-
Kadir Cetinkaya authored
These buffers normally get freed after being used in a CompilerInstance. but tests don't make use of those, so we need to free them explicitly.
-
Marcel Koester authored
The current Liveness analysis does not support operations with nested regions. This causes issues when querying liveness information about blocks nested within operations. Furthermore, the live-in and live-out sets are not computed properly in these cases. Differential Revision: https://reviews.llvm.org/D77714
-
Sanjay Patel authored
(X == C) && (Y Pred1 X) --> (X == C) && (Y Pred1 C) (X != C) || (Y Pred1 X) --> (X != C) || (Y Pred1 C) This cooperates/overlaps with D78430, but it is a more general transform that gets us most of the expected simplifications and several other improvements. http://volta.cs.utah.edu:8080/z/5gxjjc PR45618: https://bugs.llvm.org/show_bug.cgi?id=45618 Differential Revision: https://reviews.llvm.org/D78582
-
Sander de Smalen authored
This patch changes the codegen of the builtins for contiguous loads to map onto the SVE specific IR intrinsics llvm.aarch64.sve.ld1/st1. Reviewers: SjoerdMeijer, efriedma, kmclaughlin, rengolin Reviewed By: efriedma Tags: #clang Differential Revision: https://reviews.llvm.org/D78673
-
Pavel Labath authored
Summary: The code in DWARFCompileUnit::BuildAddressRangeTable tries hard to avoid relying on DW_AT_low/high_pc for compile unit range information, and this logic is a big cause of llvm/lldb divergence in the lowest layers of dwarf parsing code. The implicit assumption in that code is that this information (as opposed to DW_AT_ranges) is unreliable. However, I have not been able to verify that assumption. It is definitely not true for all present-day compilers (gcc, clang, icc), and it was also not the case for the historic compilers that I have been able to get a hold of (thanks Matt Godbolt). All compiler included in my research either produced correct DW_AT_ranges or .debug_aranges entries, or they produced no DW_AT_hi/lo pc at all. The detailed findings are: - gcc >= 4.4: produces DW_AT_ranges and .debug_aranges - 4.1 <= gcc < 4.4: no DW_AT_ranges, no DW_AT_high_pc, .debug_aranges present. The upper version range here is uncertain as godbolt.org does not have intermediate versions. - gcc < 4.1: no versions on godbolt.org - clang >= 3.5: produces DW_AT_ranges, and (optionally) .debug_aranges - 3.4 <= clang < 3.5: no DW_AT_ranges, no DW_AT_high_pc, .debug_aranges present. - clang <= 3.3: no DW_AT_ranges, no DW_AT_high_pc, no .debug_aranges - icc >= 16.0.1: produces DW_AT_ranges - icc < 16.0.1: no functional versions on godbolt.org (some are present but fail to compile) Based on this analysis, I believe it is safe to start trusting DW_AT_low/high_pc information in dwarf as well as remove the code for manually reconstructing range information by traversing the DIE structure, and just keep the line table fallback. The only compilers where this will change behavior are pre-3.4 clangs, which are almost 7 years old now. However, the functionality should remain unchanged because we will be able to reconstruct this information from the line table, which seems to be needed for some line-tables-only scenarios anyway (haven't researched this too much, but at least some compilers seem to emit DW_AT_ranges even in these situations). In addition, benchmarks showed that for these compilers computing the ranges via line tables is noticably faster than doing so via the DIE tree. Other advantages include simplifying the code base, removing some untested code (the only test changes are recent tests with overly reduced synthetic dwarf), and increasing llvm convergence. Tags: #lldb Differential Revision: https://reviews.llvm.org/D78489
-
Pavel Labath authored
Both entities have the notion of error "namespaces". Map the errno namespace correctly.
-
Simon Pilgrim authored
-
Simon Pilgrim authored
-
Simon Pilgrim authored
-
Simon Pilgrim authored
-
Tim Keith authored
Summary: The name in an InputItem isn't necessarily resolved if an error occurred, so it needs to be checked. Fixes https://bugs.llvm.org/show_bug.cgi?id=45477 Reviewers: klausler, PeteSteinfeld, DavidTruby, jdoerfert, sscalpone Reviewed By: klausler, sscalpone Subscribers: llvm-commits Tags: #llvm, #flang Differential Revision: https://reviews.llvm.org/D78685
-
Sanjay Patel authored
I found 12 (6 if we compress the DeMorganized forms) patterns for logic-of-compares with a min/max constant while looking at PR45510: https://bugs.llvm.org/show_bug.cgi?id=45510 The variations on those forms multiply the test cases by 8 (unsigned/signed, swapped compare operands, commuted logic operands). We have partial logic to deal with these for the unsigned min (zero) case, but missed everything else. We are deferring the majority of these patterns to InstCombine to allow more general handling (see D78582). We could use ConstantRange instead of predicate+constant matching here. I don't expect there's any noticeable compile-time impact for either form. Here's an abuse of Alive2 to show the 12 basic signed variants of the patterns in one function: http://volta.cs.utah.edu:8080/z/5Vpiyg declare void @use(i1, i1, i1, i1, i1, i1, i1, i1, i1, i1, i1, i1) define void @src(i8 %x, i8 %y) { %m1 = icmp eq i8 %x, 127 %c1 = icmp slt i8 %x, %y %r1 = and i1 %m1, %c1 ; (X == MAX) && (X < Y) --> false %m2 = icmp ne i8 %x, 127 %c2 = icmp sge i8 %x, %y %r2 = or i1 %m2, %c2 ; (X != MAX) || (X >= Y) --> true %m3 = icmp eq i8 %x, -128 %c3 = icmp sgt i8 %x, %y %r3 = and i1 %m3, %c3 ; (X == MIN) && (X > Y) --> false %m4 = icmp ne i8 %x, -128 %c4 = icmp sle i8 %x, %y %r4 = or i1 %m4, %c4 ; (X != MIN) || (X <= Y) --> true %m5 = icmp eq i8 %x, 127 %c5 = icmp sge i8 %x, %y %r5 = and i1 %m5, %c5 ; (X == MAX) && (X >= Y) --> X == MAX %m6 = icmp ne i8 %x, 127 %c6 = icmp slt i8 %x, %y %r6 = or i1 %m6, %c6 ; (X != MAX) || (X < Y) --> X != MAX %m7 = icmp eq i8 %x, -128 %c7 = icmp sle i8 %x, %y %r7 = and i1 %m7, %c7 ; (X == MIN) && (X <= Y) --> X == MIN %m8 = icmp ne i8 %x, -128 %c8 = icmp sgt i8 %x, %y %r8 = or i1 %m8, %c8 ; (X != MIN) || (X > Y) --> X != MIN %m9 = icmp ne i8 %x, 127 %c9 = icmp slt i8 %x, %y %r9 = and i1 %m9, %c9 ; (X != MAX) && (X < Y) --> X < Y %m10 = icmp eq i8 %x, 127 %c10 = icmp sge i8 %x, %y %r10 = or i1 %m10, %c10 ; (X == MAX) || (X >= Y) --> X >= Y %m11 = icmp ne i8 %x, -128 %c11 = icmp sgt i8 %x, %y %r11 = and i1 %m11, %c11 ; (X != MIN) && (X > Y) --> X > Y %m12 = icmp eq i8 %x, -128 %c12 = icmp sle i8 %x, %y %r12 = or i1 %m12, %c12 ; (X == MIN) || (X <= Y) --> X <= Y call void @use(i1 %r1, i1 %r2, i1 %r3, i1 %r4, i1 %r5, i1 %r6, i1 %r7, i1 %r8, i1 %r9, i1 %r10, i1 %r11, i1 %r12) ret void } define void @tgt(i8 %x, i8 %y) { %m5 = icmp eq i8 %x, 127 %m6 = icmp ne i8 %x, 127 %m7 = icmp eq i8 %x, -128 %m8 = icmp ne i8 %x, -128 %c9 = icmp slt i8 %x, %y %c10 = icmp sge i8 %x, %y %c11 = icmp sgt i8 %x, %y %c12 = icmp sle i8 %x, %y call void @use(i1 0, i1 1, i1 0, i1 1, i1 %m5, i1 %m6, i1 %m7, i1 %m8, i1 %c9, i1 %c10, i1 %c11, i1 %c12) ret void } Differential Revision: https://reviews.llvm.org/D78430
-
Sanjay Patel authored
-
Kumar Harsh authored
The clang-format docs were missing mention or links for the VSCode extension, which have been added.
-
Simon Pilgrim authored
-
Simon Pilgrim authored
-
Simon Pilgrim authored
Move StringRef.h include to XCOFF.cpp
-
Jonathan Coe authored
Summary: Improve C# `{ get; set; } = default;` formatting by handling it in the UnwrappedLineParser rather than trying to merge lines later. Remove old logic to merge lines. Update tests as formatting output has changed (as intended). Reviewers: krasimir, MyDeveloperDay Reviewed By: krasimir Subscribers: cfe-commits Tags: #clang-format, #clang Differential Revision: https://reviews.llvm.org/D78642
-
Pavel Labath authored
return Expected<Socket> instead of a Status object plus a Socket*& argument.
-
Alex Richardson authored
We now use the argparse Action objects to determine the name of the flags. This fixes cases where the key for the stored result ('dest') is not the same as the command line flag (e.g. --enable/--disable). Also add a test that --disabled can be part of the initial UTC_ARGS. This is split out from D78478 Reviewed By: jdoerfert Differential Revision: https://reviews.llvm.org/D78617
-
Alex Richardson authored
Using getValueType() is not correct for architectures extended with CHERI since we need a pointer type and not the value that is loaded. While stack protector is useless when you have CHERI (since CHERI provides much stronger security guarantees), we still have a test to check that we can generate correct code for checks. Merging b281138a into our tree broke this test. Fix by using TLI.getFrameIndexTy(). Reviewed By: arsenm Differential Revision: https://reviews.llvm.org/D77785
-
Xing GUO authored
This change helps improve `dsymutil` documentation. - Add missing options - Re-arrange options in alphabetical order - Wrap inline options in double-back-quote - `-v` is for `--version` not `--verbose` Reviewed By: JDevlieghere Differential Revision: https://reviews.llvm.org/D78479
-
River Riddle authored
It currently requires that the condition match the shape of the selected value, but this is only really useful for things like masks. This revision allows for the use of i1 to mean that all of the vector/tensor is selected. This also matches the behavior of LLVM select. A benefit of this change is that transformations that want to generate selects, like those on the CFG, don't have to special case vector/tensor. Previously the only way to generate a select from an i1 was to use a splat, but that doesn't support dynamically shaped/unranked tensors. Differential Revision: https://reviews.llvm.org/D78690
-
River Riddle authored
This revision adds support for canonicalizing the following: ``` br ^bb1 ^bb1 br ^bbN(...) br ^bbN(...) ``` Differential Revision: https://reviews.llvm.org/D78683
-
River Riddle authored
This revision adds support for canonicalizing the following: ``` cond_br %cond, ^bb1(A, ..., N), ^bb1(A, ..., N) br ^bb1(A, ..., N) ``` If the operands to the successor are different and the cond_br is the only predecessor, we emit selects for the branch operands. ``` cond_br %cond, ^bb1(A), ^bb1(B) %select = select %cond, A, B br ^bb1(%select) ``` Differential Revision: https://reviews.llvm.org/D78682
-
River Riddle authored
This revision adds support for the following canonicalization: ``` cond_br %cond, ^bb1, ^bb2 ^bb1 br ^bbN(...) ^bb2 br ^bbK(...) cond_br %cond, ^bbN(...), ^bbK(...) ``` Differential Revision: https://reviews.llvm.org/D78681
-
Simon Pilgrim authored
Move VPlan.h include from VPlanVerifier.h down to VPlanVerifier.cpp
-
Jay Foad authored
This avoids more long lists of register classes that have to be updated every time we add a new one. NFC. Differential Revision: https://reviews.llvm.org/D78570
-
Serguei Katkov authored
The motivation is to be able to play with the option and change if it is required. Reviewers: fedor.sergeev, apilipenko, rnk, jdoerfert Reviewed By: fedor.sergeev Subscribers: hiraditya, dantrushin, llvm-commits Differential Revision: https://reviews.llvm.org/D78624
-
Florian Hahn authored
This patch adds VPValue version of the instruction operands to VPWidenRecipe and uses them during code-generation. Similar to D76373 this reduces ingredient def-use usage by ILV as a step towards full VPlan-based def-use relations. Reviewers: rengolin, Ayal, gilr Reviewed By: gilr Differential Revision: https://reviews.llvm.org/D76992
-
Jay Foad authored
12994a70 did this for 128-bit classes: SGPR_128 only includes the real allocatable SGPRs, and SReg_128 adds the additional non-allocatable TTMP registers. There's no point in allocating SReg_128 vregs. This shrinks the size of the classes regalloc needs to consider, which is usually good. This patch extends it to all classes > 64 bits, for consistency. Differential Revision: https://reviews.llvm.org/D78622
-
Raphael Isemann authored
-
Sander de Smalen authored
This patch changes the FP conversion intrinsics to take a predicate that matches the number of lanes for the vector with the widest element type as opposed to using <vscale x 16 x i1>. For example: ```<vscale x 4 x float> @llvm.aarch64.sve.fcvt.f32f16(<vscale x 4 x float>, <vscale x 4 x i1>, <vscale x 8 x half>)``` now uses <vscale x 4 x i1> instead of <vscale x 16 x i1> And similar for: ```<vscale x 4 x float> @llvm.aarch64.sve.fcvt.f32f64(<vscale x 4 x float>, <vscale x 2 x i1>, <vscale x 2 x double>)``` where the predicate now matches the wider type, so <vscale x 2 x i1>. Reviewers: efriedma, SjoerdMeijer, paulwalker-arm, rengolin Reviewed By: efriedma Tags: #clang Differential Revision: https://reviews.llvm.org/D78402
-