- Jul 05, 2023
-
-
Ivan Kosarev authored
Those are implicit helper operands and therefore don't need any parsers or printers. Part of <https://github.com/llvm/llvm-project/issues/62629>. Reviewed By: piotr, foad Differential Revision: https://reviews.llvm.org/D154432
-
Ivan Kosarev authored
addKImmFPOperands() duplicates the KImmFP-specific logic implemented in addLiteralImmOperand() and therefore can be removed. Part of <https://github.com/llvm/llvm-project/issues/62629>. Reviewed By: foad Differential Revision: https://reviews.llvm.org/D154427
-
Alex Bradbury authored
Reapply - the issue was that the `< %s` was missing in the RUN lines, which didn't impact update_llc_test_checks but of course caused issues for lit. The test file is copied from X86 (which is also mostly shared with Arm, PowerPC) rather than integrated into float-intrinsics.ll and double-intrinsics.ll. There's currently a compiler crash for the soft float cases (expect this is the issue in <https://github.com/llvm/llvm-project/issues/63661>) which will be a addressed with a follow-on patch posted for review.
-
Tina Jung authored
Add constant fold for tosa.reciprocal, which can be applied if the input is a dense constant tensor. The reciprocal is computed for every element and the result is a tensor with the same dimensions as the input tensor. As the input tensor might require a lot of memory and the folding might double the required memory, a heuristic decides when to actually apply the folding. Currently, the operation will be replaced only if the input constant is a splat (i.e. requires little memory) or has in single user (similar to the already existing fold for constant transposes). This keeps the additionally required space low. Differential Revision: https://reviews.llvm.org/D150578
-
Serge Pavlov authored
This is recommit of 98390ccb, reverted in 82a3969d, because it caused https://github.com/llvm/llvm-project/issues/63542. Although the problem described in the issue is independent of the reverted patch, fail of PCH/late-parsed-instantiations.cpp indeed obseved on PowerPC and is likely to be caused by wrong serialization of `LateParsedTemplate` objects. In this patch the serialization is fixed. Original commit message is below. Previously function template instantiations occurred with FP options that were in effect at the end of translation unit. It was a problem for late template parsing as these FP options were used as attributes of AST nodes and may result in crash. To fix it FP options are set to the state of the point of template definition. Differential Revision: https://reviews.llvm.org/D143241
-
Freddy Ye authored
This refactor patch means to remove CPU_SPECIFIC* MACROs in X86TargetParser.def and move those information into ProcInfo of X86TargetParser.cpp. Since these two files both maintain a table with redundant info such as cpuname and its features supported. CPU_SPECIFIC* MACROs define some different information. This patch dealt with them in these ways when moving: 1.mangling This is now moved to Mangling in ProcInfo and directly initialized at array of Processors. CPUs don't support cpu_dispatch/specific are assigned '\0' as mangling. 2.CPU alias The alias cpu will also be initialized in array of Processors, its attributes will be same as its alias target cpu. Same feature list, same mangling. 3.TUNE_NAME Before my change, some cpu names support cpu_dispatch/specific are not supported in X86.td, which means optimizer/backend doesn't recognize them. So they use a different TUNE_NAME to generate in IR. In this patch, I added these missing cpu support at X86.td by utilizing existing Features and XXXTunings, so that each cpu name can directly use its own name as TUNE_NAME to be supported by optimizer/backend. 4.Feature list The feature list of one CPU maintained in X86TargetParser.def is not same as the one in X86TargetParser.cpp. It only maintains part of features of one CPU (features defined by X86_FEATURE_COMPAT). While X86TargetParser.cpp maintains a complete one. This patch abandons the feature list maintained by CPU_SPECIFIC* MACROs because assigning a CPU with a complete one doesn't affect the functionality of cpu_dispatch/specific. Except these four info, since some of CPUs supported by cpu_dispatch/specific doesn's support clang options like -march, -mtune before, this patch also kept this behavior still by adding another member OnlyForCPUDispatchSpecific in ProcInfo. Reviewed By: pengfei, RKSimon Differential Revision: https://reviews.llvm.org/D151696
-
Alex Bradbury authored
Reverting due to weird failure. This reverts commit 4b8162fe.
-
Ivan Kosarev authored
Completes <https://reviews.llvm.org/D154337>.
-
Alex Bradbury authored
The test file is copied from X86 (which is also mostly shared with Arm, PowerPC) rather than integrated into float-intrinsics.ll and double-intrinsics.ll. There's currently a compiler crash for the soft float cases (expect this is the issue in <https://github.com/llvm/llvm-project/issues/63661>) which will be a addressed with a follow-on patch posted for review.
-
Ivan Kosarev authored
The class was renamed in <https://reviews.llvm.org/D154337>. Reviewed By: foad Differential Revision: https://reviews.llvm.org/D154426
-
LLVM GN Syncbot authored
-
Ivan Kosarev authored
Simplifies some future changes needed for <https://github.com/llvm/llvm-project/issues/62629>. Reviewed By: arsenm Differential Revision: https://reviews.llvm.org/D154337
-
David Spickett authored
Certainly with VSCode, this makes it repopulate the kernel list.
-
Andrzej Warzynski authored
This change lifts the limitation that only the trailing dimensions/sizes in dynamic index lists can be scalable. It allows us to extend `MaskedVectorizeOp` and `TileOp` from the Transform dialect so that the following is allowed: %1, %loops:3 = transform.structured.tile %0 [4, [4], [4]] This is also a follow up for https://reviews.llvm.org/D153372 that will enable the following (middle vector dimension is scalable): transform.structured.masked_vectorize %0 vector_sizes [2, [4], 8] To facilate this change, the hooks for parsing and printing dynamic index lists are updated accordingly (`printDynamicIndexList` and `parseDynamicIndexList`, respectively). `MaskedVectorizeOp` and `TileOp` are updated to include an array of attribute of bools that captures whether the corresponding vector dimension/tile size, respectively, are scalable or not. NOTE 1: I am re-landing this after the initial version was reverted. To fix the regression and in addition to the original patch, this revision updates the Python bindings for the transform dialect NOTE 2: This change is a part of a larger effort to enable scalable vectorisation in Linalg. See this RFC for more context: * https://discourse.llvm.org/t/rfc-scalable-vectorisation-in-linalg/ This relands 048764f2 with fixes. Differential Revision: https://reviews.llvm.org/D154336
-
David Spickett authored
When using VSCode it'll default to the Python kernel the first time you open the notebook. Mention this in the readme, as the fix is simple but only if you know what to look for.
-
David Spickett authored
Previously the kernel.json would always point to `python3` even if you installed using a python from a virtualenv. This meant that tools like VSCode would try to run the kernel against the system python and fail. Added a note to the readme about it. I've removed the need to add to PYTHONPTHON as well, turns out it wasn't needed. This fixes an issue reported in https://discourse.llvm.org/t/tablegen-the-playground-ipynb-file-is-not-working-as-expected/71745. Reviewed By: awarzynski Differential Revision: https://reviews.llvm.org/D154351
-
Nikita Popov authored
Loop unrolling tends to produce chains of `%x1 = add %x0, 1; %x2 = add %x1, 1; ...` with one add per unrolled iteration. This patch simplifies these adds to `%xN = add %x0, N` directly during unrolling, rather than waiting for InstCombine to do so. The motivation for this is that having a single add (rather than an add chain) on the induction variable makes it a simple recurrence, which we specially recognize in a number of places. This allows InstCombine to directly perform folds with that knowledge, instead of first folding the add chains, and then doing other folds in another InstCombine iteration. Due to the reduced number of InstCombine iterations, this also results in a small compile-time improvement. Differential Revision: https://reviews.llvm.org/D153540
-
Lorenzo Chelini authored
In `TestTensorTransforms.cpp` `replaced` is nullptr I assumed the intent was to emit the error for the `rootOp`. In `TransformInterfaces.cpp` there were some uninitialized variables. In `NVGPUTransformOps.cpp` `matmulOp` was never used. Reviewed By: ftynse Differential Revision: https://reviews.llvm.org/D154439
-
- Jul 04, 2023
-
-
Aleksandr Popov authored
IRCE expects true edge of range check's branch comes to loop. If it meets reverse case - invert the branch. Reviewed By: skatkov Differential Revision: https://reviews.llvm.org/D148244
-
- Jul 05, 2023
-
-
Nikita Popov authored
Test for D153540, with adds that have different overflow flags.
-
Kadir Cetinkaya authored
Differential Revision: https://reviews.llvm.org/D154473
-
Siva Chandra authored
Reviewed By: mikhail.ramalho Differential Revision: https://reviews.llvm.org/D151539
-
Nikita Popov authored
-
Nikita Popov authored
Differential Revision: https://reviews.llvm.org/D153949
-
Nikita Popov authored
Add an option to specify additional linker flags for unit tests only. For example, this allows using something like -DLLVM_UNITTEST_LINK_FLAGS="-Wl,-plugin-opt=O0" if you're doing LTO builds, or -DLLVM_UNITTEST_LINK_FLAGS="-fno-lto" if you're using fat LTO objects. The build system already does this itself if the LLVM_ENABLE_LTO flag is used, but this does not cover all possible LTO configurations. Differential Revision: https://reviews.llvm.org/D154212
-
Timm Bäder authored
-
Timm Bäder authored
-
Timm Bäder authored
-
Timm Bäder authored
Unused for now, but will be used in later commits.
-
Balazs Benics authored
I'm involved with the Static Analyzer for the most part. I think we should embrace newer language standard features and gradually move forward. Differential Revision: https://reviews.llvm.org/D154325
-
Timm Bäder authored
-
Matthias Springer authored
No need to fill the buffer if no padding is added. I.e., the tensor.pad is packing only. Differential Revision: https://reviews.llvm.org/D153874
-
esmeyi authored
Summary: Currently, if there are multiple definitions of the same symbol declared has weak linkage, the linker may choose the wrong one when they are compiled with integrated-as. This patch fixes the issue. If the target symbol is a weak label we must not attempt to resolve the fixup directly. Emit a relocation and leave resolution of the final target address to the linker. Reviewed By: shchenz Differential Revision: https://reviews.llvm.org/D153839
-
Tomasz Kamiński authored
This patch introduces a new `CXXLifetimeExtendedObjectRegion` as a representation of the memory for the temporary object that is lifetime extended by the reference to which they are bound. This separation provides an ability to detect the use of dangling pointers (either binding or dereference) in a robust manner. For example, the `ref` is conditionally dangling in the following example: ``` template<typename T> T const& select(bool cond, T const& t, T const& u) { return cond ? t : u; } int const& le = Composite{}.x; auto&& ref = select(cond, le, 10); ``` Before the change, regardless of the value of `cond`, the `select()` call would have returned a `temp_object` region. With the proposed change we would produce a (non-dangling) `lifetime_extended_object` region with lifetime bound to `le` or a `temp_object` region for the dangling case. We believe that such separation is desired, as such lifetime extended temporaries are closer to the variables. For example, they may have a static storage duration (this patch removes a static temporary region, which was an abomination). We also think that alternative approaches are not viable. While for some cases it may be possible to determine if the region is lifetime extended by searching the parents of the initializer expr, this quickly becomes complex in the presence of the conditions operators like this one: ``` Composite cc; // Ternary produces prvalue 'int' which is extended, as branches differ in value category auto&& x = cond ? Composite{}.x : cc.x; // Ternary produces xvalue, and extends the Composite object auto&& y = cond ? Composite{}.x : std::move(cc).x; ``` Finally, the lifetime of the `CXXLifetimeExtendedObjectRegion` is tied to the lifetime of the corresponding variables, however, the "liveness" (or reachability) of the extending variable does not imply the reachability of all symbols in the region. In conclusion `CXXLifetimeExtendedObjectRegion`, in contrast to `VarRegions`, does not need any special handling in `SymReaper`. RFC: https://discourse.llvm.org/t/rfc-detecting-uses-of-dangling-references/70731 Reviewed By: xazax.hun Differential Revision: https://reviews.llvm.org/D151325 -
Rahul Kayaith authored
This fixes a few custom printers which were printing IR that couldn't be round-tripped. Reviewed By: rriddle Differential Revision: https://reviews.llvm.org/D150080
-
Joseph Huber authored
-
Joseph Huber authored
Summary: This was not added to dynamic_hsa.h
-
Joseph Huber authored
AMDGPU provides a fixed frequency clock since some generations back. However, the frequency is variable by card and must be looked up at runtime. This patch adds a new device environment line for the clock frequency so that we can use it in the same way as NVPTX. This is the correct implementation and the version in ASO should be replaced. Reviewed By: tianshilei1992 Differential Revision: https://reviews.llvm.org/D154456
-
Craig Topper authored
-
Craig Topper authored
This is consistent with the other classes in this file. It avoids a possible name conflict with standard extensions or other vendors in the future.
-