- Jul 17, 2021
-
-
Andrzej Warzynski authored
In the `flang` bash script, we need to be careful _when_ to use <output> from `flang -c -o <output> <input>` when generating the relocatable output file name. In particular, we should use it in this case: ```compilation only flang -c -o <output> <input> ``` but leave it for the final executable here: ```compile, assemble and link flang -o <output> <input> ``` This change is implemented in `get_relocatable_name`. I've also taken the liberty to fix how errors from sub-commands are reported (without this change, `flang` always returns `0` on failure). This is implemented in `main`. Differential Revision: https://reviews.llvm.org/D105896
-
- Jul 16, 2021
-
-
Congzhe Cao authored
We already know that we need to check whether lcssa phis are supported in inner loop exit block or in outer loop exit block, and we have logic to check them already. Presumably the inner loop latch does not have lcssa phis and there is no code that deals with lcssa phis in the inner loop latch. However, that assumption is not true, when we have loops with more than two-level nesting. This patch adds checks for lcssa phis in the inner latch. Reviewed By: Whitney Differential Revision: https://reviews.llvm.org/D102300
-
Louis Dionne authored
-
Matt Arsenault authored
NFC here since it's just using a scalar anyway.
-
Matt Arsenault authored
-
Matt Arsenault authored
-
Louis Dionne authored
This makes sure that even if a node goes down, the BuildKite agent will be started again when it goes back up.
-
Alexander Belyaev authored
-
Geoffrey Martin-Noble authored
This has been deprecated for a while. There are no users in tree and I'm not aware of any out of tree users either. Reviewed By: ftynse Differential Revision: https://reviews.llvm.org/D106114
-
Masoud Ataei authored
is needed be enable on P8 and later targets. Differential Revision: https://reviews.llvm.org/D106091
-
Louis Dionne authored
Instead of using TARGET_TRIPLE, which is always set to LLVM_DEFAULT_TARGET_TRIPLE, use that variable directly to populate the various XXXX_TARGET_TRIPLE variables in the runtimes. This re-applies 77396bbc and 5099e015, which were reverted in 850b57c5 because they broke the build. Differential Revision: https://reviews.llvm.org/D106009
-
Amy Kwan authored
This patch includes the following updates to the load/store refactoring effort introduced in D93370: - Update various VSX patterns that use to "force" an XForm, to instead just XForm. This allows the ability for the patterns to compute the most optimal addressing mode (and to produce a DForm instruction when possible) - Update pattern and test case for the LXVD2X/STXVD2X intrinsics - Update LIT test cases that use to use the XForm instruction to use the DForm instruction Differential Revision: https://reviews.llvm.org/D95115
-
Fraser Cormack authored
This reverts commit a6ca88e9. More caution is required to avoid overflow/underflow. Thanks to the santizers for catching this.
-
David Spickett authored
PackTags is used by to compress tags to go in the QMemTags packet and be passed to ptrace when writing memory tags. The behaviour of RepeatTagsForRange matches that described for QMemTags in the GDB documentation: https://sourceware.org/gdb/current/onlinedocs/gdb/General-Query-Packets.html#General-Query-Packets In addition, unpacking tags with number of tags 0 now means do not check that number of tags matches the range. This will be used by lldb-server to unpack tags before repeating them to fill the requested range. Reviewed By: omjavaid Differential Revision: https://reviews.llvm.org/D105179
-
Alex Zinenko authored
-
Alex Zinenko authored
The dialect-specific cast between builtin (ex-standard) types and LLVM dialect types was introduced long time before built-in support for unrealized_conversion_cast. It has a similar purpose, but is restricted to compatible builtin and LLVM dialect types, which may hamper progressive lowering and composition with types from other dialects. Replace llvm.mlir.cast with unrealized_conversion_cast, and drop the operation that became unnecessary. Also make unrealized_conversion_cast legal by default in LLVMConversionTarget as the majority of convesions using it are partial conversions that actually want the casts to persist in the IR. The standard-to-llvm conversion, which is still expected to run last, cleans up the remaining casts standard-to-llvm conversion, which is still expected to run last, cleans up the remaining casts Reviewed By: nicolasvasilache Differential Revision: https://reviews.llvm.org/D105880
-
Matt Arsenault authored
-
Matt Arsenault authored
-
Matt Arsenault authored
This avoids relying on G_EXTRACT on unusual types, and also properly decomposes structs into multiple registers. This also preserves the LLTs in the memory operands.
-
Jeremy Morse authored
If you attach __attribute__((optnone)) to a function when using optimisations, that function will use fast-isel instead of the usual SelectionDAG method. This is a problem for instruction referencing, because it means DBG_VALUEs of virtual registers will be created, triggering some safety assertions in LiveDebugVariables. Those assertions exist to detect exactly this scenario, where an unexpected piece of code is generating virtual register references in instruction referencing mode. Fix this by transforming the DBG_VALUEs created by fast-isel into half-formed DBG_INSTR_REFs, after which they get patched up in finalizeDebugInstrRefs. The test modified adds a fast-isel mode to the instruction referencing isel test. Differential Revision: https://reviews.llvm.org/D105694
-
Sanjay Patel authored
More coverage for D105730
-
serge-sans-paille authored
This fixes bug 36064 Differential Revision: https://reviews.llvm.org/D106093
-
Dmitry Preobrazhensky authored
Added isCall for S_CALL_B64; added isBranch for S_SUBVECTOR_LOOP_*. Differential Revision: https://reviews.llvm.org/D106072
-
Zarko Todorovski authored
https://reviews.llvm.org/D105659 implements ByVal handling in llc but some cases are not compatible with existing XL compiler on AIX. Adding a clang warning for such cases. Reviewed By: aaron.ballman Differential Revision: https://reviews.llvm.org/D105660
-
Alexander Belyaev authored
RFC: https://llvm.discourse.group/t/rfc-reshape-ops-restructuring/3310 Differential Revision: https://reviews.llvm.org/D106141
-
Serge Pavlov authored
-
Alex Zinenko authored
This may be necessary in partial multi-stage conversion when a container type from dialect A containing types from dialect B goes through the conversion where only dialect A is converted to the LLVM dialect. We will need to keep a pointer-to-non-LLVM type in the IR until a further conversion can convert dialect B types to LLVM types. Reviewed By: wsmoses Differential Revision: https://reviews.llvm.org/D106076
-
Nicholas Guy authored
Specifying the latencies of specific LDP variants appears to improve performance almost universally. Differential Revision: https://reviews.llvm.org/D105882
-
Kerry McLaughlin authored
This patch returns an Invalid cost from getInstructionCost() for alloca instructions if the VF is scalable, as otherwise loops which contain these instructions will crash when attempting to scalarize the alloca. Reviewed By: sdesmalen Differential Revision: https://reviews.llvm.org/D105824
-
Cullen Rhodes authored
This patch adds support for following contiguous load and store instructions: * LD1B, LD1H, LD1W, LD1D, LD1Q * ST1B, ST1H, ST1W, ST1D, ST1Q A new register class and operand is added for the 32-bit vector select register W12-W15. The differences in the following tests which have been re-generated are caused by the introduction of this register class: * llvm/test/CodeGen/AArch64/GlobalISel/irtranslator-inline-asm.ll * llvm/test/CodeGen/AArch64/GlobalISel/regbank-inlineasm.mir * llvm/test/CodeGen/AArch64/stp-opt-with-renaming-reserved-regs.mir * llvm/test/CodeGen/AArch64/stp-opt-with-renaming.mir D88663 attempts to resolve the issue with the store pair test differences in the AArch64 load/store optimizer. The GlobalISel differences are caused by changes in the enum values of register classes, tests have been updated with the new values. The reference can be found here: https://developer.arm.com/documentation/ddi0602/2021-06 Reviewed By: CarolineConcatto Differential Revision: https://reviews.llvm.org/D105572
-
David Spickett authored
Previously GetMemoryTagManager checked many things in one: * architecture supports memory tagging * process supports memory tagging * memory range isn't inverted * memory range is all tagged Since writing follow up patches for tag writing (in review at the moment) it has become clear that this gets unwieldy once we add the features needed for that. It also implies that the memory tag manager is tied to the range you used to request it with but it is not. It's a per process object. Instead: * GetMemoryTagManager just checks architecture and process. * Then the MemoryTagManager can later be asked to check a memory range. This is better because: * We don't imply that range and manager are tied together. * A slightly diferent range calculation for tag writing doesn't add more code to Process. * Range checking code can now be unit tested. Reviewed By: omjavaid Differential Revision: https://reviews.llvm.org/D105630
-
Sander de Smalen authored
The original patch was: https://reviews.llvm.org/D105806 There were some issues with undeterministic behaviour of the sorting function, which led to scalable-call.ll passing and/or failing. This patch fixes the issue by numbering all instructions in the array first, and using that number as the order, which should provide a consistent ordering. This reverts commit a607f641.
-
Fraser Cormack authored
This patch teaches the compiler to identify a wider variety of `BUILD_VECTOR`s which form integer arithmetic sequences, and to lower them to `vid.v` with modifications for non-unit steps and non-zero addends. The sequences handled by this optimization must either be monotonically increasing or decreasing. Consecutive elements holding the same value indicate a fractional step which, while simple mathematically, becomes more complex to handle both in the realm of lossy integer division and in the presence of `undef`s. For example, a common "interleaving" shuffle index will be lowered by LLVM to both `<0,u,1,u,2,...>` and `<u,0,u,1,u,...>` `BUILD_VECTOR` nodes. Either of these would ideally be lowered to `vid.v` shifted right by 1. Detection of this sequence in presence of general `undef` values is more complicated, however: `<0,u,u,1,>` could match either `<0,0,0,1,>` or `<0,0,1,1,>` depending on later values in the sequence. Both are possible, so backtracking or multiple passes is inevitable. Sticking to monotonic sequences keeps the logic simpler as it can be done in one pass. Fractional steps will likely be a separate optimization in a future patch. Reviewed By: craig.topper Differential Revision: https://reviews.llvm.org/D104921
-
Uday Bondhugula authored
Remove duplicate and stale doc comment on affineParallelize. NFC.
-
Timm Bäder authored
Differential Revision: https://reviews.llvm.org/D106055
-
Vince Bridgers authored
This change addresses this assertion that occurs in a downstream compiler with a custom target. ```APInt.h:1151: bool llvm::APInt::operator==(const llvm::APInt &) const: Assertion `BitWidth == RHS.BitWidth && "Comparison requires equal bit widths"'``` No covering test case is susbmitted with this change since this crash cannot be reproduced using any upstream supported target. The test case that exposes this issue is as simple as: ```lang=c++ void test(int * p) { int * q = p-1; if (q) {} if (q) {} // crash (void)q; } ``` The custom target that exposes this problem supports two address spaces, 16-bit `char`s, and a `_Bool` type that maps to 16-bits. There are no upstream supported targets with similar attributes. The assertion appears to be happening as a result of evaluating the `SymIntExpr` `(reg_$0<int * p>) != 0U` in `VisitSymIntExpr` located in `SimpleSValBuilder.cpp`. The `LHS` is evaluated to `32b` and the `RHS` is evaluated to `16b`. This eventually leads to the assertion in `APInt.h`. While this change addresses the crash and passes LITs, two follow-ups are required: 1) The remainder of `getZeroWithPtrWidth()` and `getIntWithPtrWidth()` should be cleaned up following this model to prevent future confusion. 2) We're not sure why references are found along with the modified code path, that should not be the case. A more principled fix may be found after some further comprehension of why this is the case. Acks: Thanks to @steakhal and @martong for the discussions leading to this fix. Reviewed By: NoQ Differential Revision: https://reviews.llvm.org/D105974 -
Simon Giesecke authored
Differential Revision: https://reviews.llvm.org/D105982
-
Mehdi Amini authored
Use ManagedStatic and lazy initialization of cl::opt in libSupport to make it free of global initializer We can build it with -Werror=global-constructors now. This helps in situation where libSupport is embedded as a shared library, potential with dlopen/dlclose scenario, and when command-line parsing or other facilities may not be involved. Avoiding the implicit construction of these cl::opt can avoid double-registration issues and other kind of behavior. Reviewed By: lattner, jpienaar Differential Revision: https://reviews.llvm.org/D105959
-
Mehdi Amini authored
Revert "Use ManagedStatic and lazy initialization of cl::opt in libSupport to make it free of global initializer" This reverts commit af932173. Still some specific config broken in some way that requires more investigation.
-
Timm Bäder authored
This reverts commit 7c637260.
-