- Oct 04, 2022
-
-
Bjorn Pettersson authored
These tests cases were converted using the script at https://gist.github.com/nikic/98357b71fd67756b0f064c9517b62a34. Needed to also re-run update_test_checks.py, otherwise some of them would fail.
-
Bjorn Pettersson authored
These tests cases were converted using the script at https://gist.github.com/nikic/98357b71fd67756b0f064c9517b62a34, but there was also a need to re-run update_test_checks.py (impacting nonnull/dereferencable attributes). Differential Revision: https://reviews.llvm.org/D135095
-
Bjorn Pettersson authored
These tests cases were converted using the script at https://gist.github.com/nikic/98357b71fd67756b0f064c9517b62a34 Differential Revision: https://reviews.llvm.org/D135094
-
rkayaith authored
This adds a `--no-implicit-module` option, which disables the insertion of a top-level `builtin.module` during parsing. Although other ops can now be parsed as top-level, the actual reduction passes are still restricted to `builtin.module` as it didn't seem straightforward to update them. Reviewed By: rriddle Differential Revision: https://reviews.llvm.org/D134242
-
rkayaith authored
-
Louis Dionne authored
This patch incorporates the "sanitize" step of the transitive includes test into the CSV generator itself. In doing so, it removes complexity in the test but also fixes a bug where we would filter out <__mutex> from the output, leading to an incorrect list of includes for the <shared_mutex> header. Differential Revision: https://reviews.llvm.org/D134830
-
jeff authored
If we can not prove that f16 operands of a buildvector are canonicalized, then we can not lower into a V_PACK. In this scenario, we would previously lower into some combination of and(sdwa), shr, or. This patch allows for matching into V_PERM instead. Change-Id: Ifa4a74fdb81ef44f22ba490c7fdf81ec8aebc945
-
Florian Hahn authored
-
Florian Hahn authored
Also add test coverage for important debug output.
-
Philip Reames authored
We have a very common pattern of dispatching between BUILD_VECTOR and SPLAT_VECTOR creation repeated in many cases in code. Common the pattern into a utility function.
-
Erich Keane authored
As fallout of the Deferred Concept Instantiation patch (babdef27), we got a number of reports of a regression, where we asserted when instantiating a constraint on a generic lambda inside of a variable template. See: https://github.com/llvm/llvm-project/issues/57958 The problem was that getTemplateInstantiationArgs function only walked up declaration contexts, and missed that this is not necessarily the case with a lambda (which can ALSO be in a separate context). This patch refactors the getTemplateInstantiationArgs function in a way that is hopefully more readable, and fixes the problem with the concepts on a generic lambda. Differential Revision: https://reviews.llvm.org/D134874
-
Jim Kitchen authored
The region within sparse_tensor.select is used as the runtime criteria for whether to keep the existing value in the sparse tensor. While the sparse element is provided to the comparison, indices may also be used to decide on whether to keep the original value. This allows, for example, to only keep the upper triangle of a matrix. Reviewed by: aartbik Differential Revision: https://reviews.llvm.org/D134761
-
rkayaith authored
This adds a `--no-implicit-module` option, which disables the insertion of a top-level `builtin.module` during parsing. The top-level op is required to have the `SymbolTable` trait. The majority of the change here is removing `ModuleOp` from interfaces. Reviewed By: rriddle Differential Revision: https://reviews.llvm.org/D134238
-
Craig Topper authored
VMV_V_X_VL nodes should always have a passthru, a splat, and a VL. We were sometimes missing the VL. This went unnoticed because these cases were all selected into the following node to form a .vx or .vi instruction. The ComplexPattern that does this, doesn't check the VL operand. I've added an assert to the ComplexPattern to catch if the operand is missing. @qcolombet spotted some of these in D134703.
-
Jonathon Penix authored
Previously, AggregateStores were created for aggregates associated with common blocks. As a) AggregateStoreMap uses scope and offset information to search for aggregate stores and b) variables related to common blocks have their offsets set relative to the common block itself, if there were multiple equivalences and at least one involved variables defined in a common block there was an opportunity for the scope/offset pairs to match between distinct aggregate stores. As a result, entries in AggregateStoreMap could collide, resulting in incorrect stores being returned for a particular variable. To prevent these collisions, skip creating AggregateStores for aggregates which are associated with common blocks. This information was already unused as aggregates associated with common blocks are handled by instantiateCommon. Fixes https://github.com/llvm/llvm-project/issues/57749 Differential Revision: https://reviews.llvm.org/D134828
-
Craig Topper authored
This reverts commit 2138ef35. Forgot to squash
-
Craig Topper authored
This reverts commit 4c03c9f3. Forgot to squash
-
Craig Topper authored
VMV_V_X_VL nodes should always have a passthru, a splat, and a VL. We were sometimes missing the VL. This went unnoticed because these cases were all selected into the following node to form a .vx or .vi instruction. The ComplexPattern that does this, doesn't check the VL operand. I've added an assert to the ComplexPattern to catch if the operand is missing. @qcolombet spotted some of these in D134703.
-
Craig Topper authored
-
River Riddle authored
This better integrates with builder methods that use TypeRange, i.e. the recommended thing, instead of ArrayRef<Type>.
-
River Riddle authored
This is much more explicit, and prevents annoying conflicts with op specific accessors (which may have a different contract). This is similar to the past rename of getType -> getFunctionType, Fixes #58030 Differential Revision: https://reviews.llvm.org/D135007
-
Thomas Raoux authored
This is required to be able to cast integer type to a potential larger index using zero-extend cast. There is a larger change under discussion to move index ops in a separate dialect: https://discourse.llvm.org/t/rfc-index-dialect/65540/ Based on timing of this work this patch can be included as part of this effort but as a short term solution we may want to add this op to arithmetic dialect for now in order to fill the gap. Reviewed By: Mogball, stellaraccident Differential Revision: https://reviews.llvm.org/D135089
-
Guozhi Wei authored
[IVDescriptors] Before moving an instruction in SinkAfter checking if it is target of other instructions The attached test case can cause LLVM crash in buildVPlanWithVPRecipes because invalid VPlan is generated. FIRST-ORDER-RECURRENCE-PHI ir<%792> = phi ir<%501>, ir<%806> CLONE ir<%804> = fdiv ir<1.000000e+00>, vp<%17> // use of %17 CLONE ir<%806> = load ir<%805> EMIT vp<%17> = first-order splice ir<%792> ir<%806> // def of %17 ... There is a use before def error on %17. When vectorizer generates a VPlan, it generates a "first-order splice" instruction for a loop carried variable after its definition. All related PHI users are changed to use this "first-order splice" result, and are moved after it. The move is guided by a MapVector SinkAfter. And the content of SinkAfter is filled by RecurrenceDescriptor::isFixedOrderRecurrence. Let's look at the first PHI and related instructions %v792 = phi double [ %v806, %Loop ], [ %d1, %Entry ] %v802 = fdiv double %v794, %v792 %v804 = fdiv double 1.000000e+00, %v792 %v806 = load double, ptr %v805, align 8 %v806 is a loop carried variable, %v792 is related PHI instruction. Vectorizer will generated a new "first-order splice" instruction for %v806, and it will be used by %v802 and %v804. So %v802 and %v804 will be moved after %v806 and its "first-order splice" instruction. So SinkAfter contains %v802 -> %v806 %v804 -> %v802 It means %v802 should be moved after %v806 and %v804 will be moved after %v802. Please pay attention that the order is important. When isFixedOrderRecurrence processing PHI instruction %v794, related instructions are %v793 = phi double [ %v813, %Loop ], [ %d1, %Entry ] %v794 = phi double [ %v793, %Loop ], [ %d2, %Entry ] %v802 = fdiv double %v794, %v792 %v813 = load double, ptr %v812, align 8 This time its related loop carried variable is %v813, its user is %v802. So %v802 should also be moved after %v813. But %v802 is already in SinkAfter, because %v813 is later than %v806, so the original %v802 entry in SinkAfter is deleted, a new %v802 entry is added. Now SinkAfter contains %v804 -> %v802 %v802 -> %v813 With these data, %v802 can still be moved after all its operands, but %v804 can't be moved after %v806 and its "first-order splice" instruction. And causes use before def error. So when remove/re-insert an instruction I in SinkAfter, we should also recursively remove instructions targeting I and re-insert them into SinkAfter. But for simplicity I just bail out in this case. Differential Revision: https://reviews.llvm.org/D134083
-
Hussain Kadhem authored
Reviewed By: ktras Differential Revision: https://reviews.llvm.org/D134205
-
Kirsten Lee authored
Extend multi-buffering to simplify the affine map created if any of its operands are constants. This avoids downstream problems where more complex affine.apply operations cannot be expanded. Transfer attributes from the old allocation to the new allocation. Reviewed By: ThomasRaoux Differential Revision: https://reviews.llvm.org/D134894
-
oberrich authored
Adds aforementioned link switches in lld-link and ignores them. Differential revision: https://reviews.llvm.org/D135033
-
bixia1 authored
Move genReshapeDstShape to codegen utils to support the rewriting of the tensor reshape operators for the codegen path. Reviewed By: aartbik Differential Revision: https://reviews.llvm.org/D135074
-
Louis Dionne authored
There are a handful of standard library types that are intended to support CTAD but don't need any explicit deduction guides to do so. This patch adds a dummy deduction guide to those types to suppress -Wctad-maybe-unsupported (which gets emitted in user code). This is a re-application of the original patch by Eric Fiselier in fcd549a7 which had been reverted due to reasons lost at this point. I also added the macro to a few more types. Reviving this patch was prompted by the discussion on https://llvm.org/D133425. Differential Revision: https://reviews.llvm.org/D133535
-
Chris Bieneman authored
This captures the target shader model and pipeline stage into the DXIL metadata for consumption by the DirectX runtime. Reviewed By: python3kgae Differential Revision: https://reviews.llvm.org/D134469
-
Craig Topper authored
This is a refactor for another patch. For now we move the vreg creation to the caller. Reviewed By: frasercrmck Differential Revision: https://reviews.llvm.org/D135008
-
Fangrui Song authored
RenderAsInput is for -Wa,/-Wl, style options which forward their values as used by llvm::opt::Arg::renderAsInput. These short options don't use RenderAsInput.
-
Florian Hahn authored
Recent improvements to the code structure mean we don't need to reset the condition's predicate in the IR and later restore it. Remove the restorer logic.
-
natashaknk authored
Reviewed By: rsuderman Differential Revision: https://reviews.llvm.org/D133877
-
Florian Hahn authored
The comment doens't apply in the current context, remove it.
-
Aart Bik authored
Reviewed By: Peiming Differential Revision: https://reviews.llvm.org/D134971
-
Jessica Paquette authored
This adds a combine that handles ``` (x + y) - y -> x (x + y) - x -> y x - (y + x) -> 0 - y x - (x + z) -> 0 - z ``` On AArch64, we get added benefit for `0 - y` because it can be selected to a `neg` instruction. Differential Revision: https://reviews.llvm.org/D135010
-
Florian Hahn authored
The field is no unused and can be removed.
-
bixia1 authored
Reviewed By: aartbik Differential Revision: https://reviews.llvm.org/D135034
-
Keith Smiley authored
When using llvm-libtool-darwin as a drop in replacement for cctools libtool, Xcode expects you to create a dependency info file. This file is a very simple format describing the input files, the output files, and the version of the tool. This logic is mirrored from that of ld64.lld, which supports creating this file as well. Ideally we could extract it, but I don't think we want to throw this into one of the grab-bag libraries given how small the logic is. Differential Revision: https://reviews.llvm.org/D134322
-
Keith Smiley authored
cctools libtool allows you to link dynamic libraries by passing through a number of arguments to ld64. Because of this the default arguments libtool receives in Xcode contains arguments that only matter in that case. This change ignores this argument, at least until we ever support that dynamic use case, so that you can use llvm-libtool-darwin as a drop-in replacement in Xcode for cctools libtool. There are more arguments we could ignore for this case, but we can probably add those as the use case comes up. Differential Revision: https://reviews.llvm.org/D134309
-