- Apr 23, 2022
-
-
owenca authored
Also replace an unnecessary check with assert() in the unwrapped line parser. Differential Revision: https://reviews.llvm.org/D124215
-
Matthias Springer authored
This makes the API easier to use. Also allows us to check for incorrect API usage for easier debugging. Differential Revision: https://reviews.llvm.org/D124265
-
- Apr 22, 2022
-
-
Simon Pilgrim authored
Alive2: https://alive2.llvm.org/ce/z/Ygq26C This is the final missing fold to handle the modulo2 simplification: https://github.com/llvm/llvm-project/issues/22303 Fixes #22303 Differential Revision: https://reviews.llvm.org/D123374
-
Kadir Cetinkaya authored
Reduce peak memory usage by tearing down the intermediate representation as we build the final one. Rather than deleting it in the end. Differential Revision: https://reviews.llvm.org/D124240
-
Simon Pilgrim authored
This is a very specific fold to fix an upstream poor codegen issue. InstCombine has the much more flexible pushFreezeToPreventPoisonFromPropagating but I don't think we're quite there with DAG/TLI handling for canCreateUndefOrPoison/isGuaranteedNotToBeUndefOrPoison value tracking yet. Fixes #54911 Differential Revision: https://reviews.llvm.org/D124185
-
Matthias Springer authored
The `hasFilter` field is not needed. Instead, the filter accepts ops by default if no ALLOW rule was specified. Differential Revision: https://reviews.llvm.org/D124264
-
Vasileios Porpodas authored
This reverts commit 7ba70264.
-
Denis Antrushin authored
-
Matt Arsenault authored
-
Matt Arsenault authored
-
Nikita Popov authored
-
Matt Arsenault authored
Currently metadata is inserted in a late pass which is lowered to an AssertZext. The metadata would be more useful if it was inserted earlier after inlining, but before codegen. Probably shouldn't change anything now. Just replacing the late metadata annotation needs more work, since we lose out on optimizations after these are lowered to CopyFromReg. Seems to be slightly better than relying on the AssertZext from the metadata. The test change in cvt_f32_ubyte.ll is a quirk from it using -start-before=amdgpu-isel instead of running the usual codegen pipeline.
-
Matt Arsenault authored
The most common situation where G_ASSERT_ZEXT appears for AMDGPU is a copy from a physical register, which happens to use set the actual register class on the virtual register. After copy coalescing, the assert's source operand had a vreg with a set class. The verifier was strictly rejecting cases where the set class/bank weren't an exact match. Additionally, RegBankSelect was also expecting a register bank to be set on the register, not a class. This is much stricter than regular copies so relax this behavior. This now allows these 2 cases: 1. Source register has either class or bank, and the result does not 2. Source register has a register class, and the result is a register with a matching bank. This should avoid needing some kind of special handling to avoid violating this constraint when folding copies.
-
Nikita Popov authored
To make it easier to extend this to the congruent and case.
-
Vasileios Porpodas authored
The original patch (https://reviews.llvm.org/D121354) targets x86 and adjusts the lookahead score of splat loads ad they can be done by the `movddup` instruction that combines the load and the broadcast and is cheap to execute. A similar issue shows up on AArch64. The `ld1r` instruction performs a broadcast load and is cheap to execute. This patch implements the TargetTransformInfo hooks for AArch64. Differential Revision: https://reviews.llvm.org/D123638
-
Martin Storsjö authored
The previous case was a tautology - this is probably what was intended. Differential Revision: https://reviews.llvm.org/D124072
-
Biplob Mishra authored
InstCombine: Add tests to show or-and scenarios which can be possibly be combined by ORing the masks
-
Paul Walker authored
This reverts part of https://reviews.llvm.org/D124224 that causes an assert because the register allocator triggers a pathological situation where there's no safe way to insert a zeroing MOVPFRX instruction.
-
Nikita Popov authored
Partially based on the conjugated or tests.
-
Nico Weber authored
Differential Revision: https://reviews.llvm.org/D124254
-
Iain Sandoe authored
These command-line flags are alternates to providing the -x c++-*-header indicators that we are building a header unit. Act on fmodule-header= for headers on the c/l: If we have x.hh -fmodule-header, then we should treat that header as a header unit input (equivalent to -xc++-header-unit-header x.hh). Likewise, for fmodule-header={user,system} the source should be now recognised as a header unit input (since this can affect the job list that we need). It's not practical to recognise a header without any suffix so -fmodule-header=system foo isn't going to happen. Although -fmodule-header=system foo.hh will work OK. However we can make it work if the user indicates that the item without a suffix is a valid header. (so -fmodule-header=system -xc++-header vector) Differential Revision: https://reviews.llvm.org/D121589 -
Lei Zhang authored
vector.broadcast can inject all size one dimensions. If it's followed by a vector.shape_cast to the original type, we can cancel the op pair, like cancelling consecutive shape_cast ops. Reviewed By: mravishankar Differential Revision: https://reviews.llvm.org/D124094
-
Byoungchan Lee authored
This patch extends cc1as to export the build version load command with LC_VERSION_MIN_MACOSX. This is especially important for Mac Catalyst as Mac Catalyst uses the MacOS's compiler rt built-ins. Differential Revision: https://reviews.llvm.org/D121868
-
zhongyunde authored
Add DestructiveBinaryComm* patterns for ORR, EOR, AND and BIC. The above instructions requires that the source and destination registers are equal, so use movprfx should be beneficial to performance. note: BIC (i.e. A & ~B) is not a commutative operation. Reviewed By: paulwalker-arm, david-arm Differential Revision: https://reviews.llvm.org/D124224
-
Vasileios Porpodas authored
[SLP][AArch64][NFC] Add test for a follow-up patch that fixes the lookahead cost of splat-loads for AArch64
-
Haojian Wu authored
This is a followup cleanup of 1234b1c6 Differential Revision: https://reviews.llvm.org/D124238
-
Nico Weber authored
This reverts commit a7815d33. Test fails on Windows, see comments on https://reviews.llvm.org/D124199
-
Matthias Springer authored
Differential Revision: https://reviews.llvm.org/D124249
-
Daniel Kiss authored
autiasp, autibsp instructions are the counterpart of paciasp/pacibsp instructions therefore let's emit .cfi_negate_ra_state for these too. In case of Armv8.3 instruction set the retaa/retbb will do the return and authentication in one step here we can't emit the . cfi_negate_ra_state because that would be point after the ret* instruction. Reviewed By: nickdesaulniers, MaskRay Differential Revision: https://reviews.llvm.org/D111780
-
Ying Yi authored
attribute((__aligned__)) is present but ignored` In the original code, the 'getDeclAlignIfRequired' function is used. The 'getDeclAlignIfRequired' function will return the max alignment of all aligned attributes if the type has aligned attributes. The function doesn't consider the type at all. The 'getTypeAlignIfRequired' function uses the type's alignment value, which also used by the 'alignof' function. I think we should use the function of 'getTypeAlignIfRequired'. Reviewed By: dblaikie, jmorse, wolfgangp Differential Revision: https://reviews.llvm.org/D124006
-
Nikita Popov authored
Folds are supposed to always be added in conjugated pairs for and and or. Merge the two functions to make folds for which this is currently not the case more obvious.
-
Matthias Springer authored
* Move Module Bufferization to the bufferization dialect. The implementation is split into `OneShotModuleBufferize.cpp` and `FuncBufferizableOpInterfaceImpl.cpp`, so that the external model implementation can be easily moved to the func dialect in the future. * Split and clean up test cases. A few test cases are still remaining in Linalg and will be updated separately. * `linalg.inplaceable` is renamed to `bufferization.writable` to accurately reflect its current usage. * Attributes and their verifiers are moved from the Linalg dialect to the Bufferization dialect. * Expand documentation. * Add a new flag to One-Shot Bufferize to allow for function boundary bufferization. Differential Revision: https://reviews.llvm.org/D122229
-
Nikita Popov authored
1d90e530 switch this code to store the predicates and operands in variables, but retained a swapOperands() call here. Thus the commuted cases were no longer folded. Additionally, as the change was not reported, the next InstCombine iteration would not pick it up either.
-
Nikita Popov authored
-
Matthias Springer authored
The layout postprocessing step was removed and is now part of the FuncOp bufferization. If the user specified a certain layout map for a tensor function arg, use that layout map directly when bufferizing the function signature. Previously, the bufferization used a generic layout map for every tensor function arg and then updated function signatures and CallOps in a separate step. Differential Revision: https://reviews.llvm.org/D122228
-
Matthias Springer authored
FuncOps are now less special. They must still be analyzed + bufferized in a certain order, but they are now bufferized same as other ops that have a region: Bufferize the op first (`bufferize` interface method), then bufferize the region body with other bufferization patterns. In the case of FuncOps, the function signature is bufferized together with ReturnOps. Similar to how, e.g., scf.for ops are bufferized together with scf.yield ops. This change is essentially a reimplementation of the FuncOp bufferization, but mostly NFC from a user's perspective (apart from error messages). This change is in preparation of moving the code to the bufferization dialect. Differential Revision: https://reviews.llvm.org/D123214
-
Florian Hahn authored
-
Matthias Springer authored
The bufferization driver was previously using a GreedyPatternRewriter. This was problematic because bufferization must traverse ops top-to-bottom. The GreedyPatternRewriter was previously configured via `useTopDownTraversal`, but this was a hack; this API was just meant for performance improvements and should not affect the result of the rewrite. BEGIN_PUBLIC No public commit message needed. END_PUBLIC Differential Revision: https://reviews.llvm.org/D123618
-
jacquesguan authored
This patch replaces current fold function with the common constant fold funtion in order to cover the situation of constant splat. Reviewed By: ftynse Differential Revision: https://reviews.llvm.org/D124236
-
Andrzej Warzynski authored
This patch adds a few new member methods in the `PluginParseTreeAction` frontend action base class. With these new methods, the plugin API becomes independent of the driver internals. In particular, plugin writers no longer require the `CompilerInstance.h` header file to access various driver data structures (instead, they can use newly added hooks). This change is desirable as `CompilerInstance.h` includes various headers from Clang (both explicitly and implicitly). Some of these header files are generated at build time (through TableGen) and including them creates a dependency on some of Clang's build targets. However, plugins in Flang should not depend on Clang build targets. Note that plugins might still work fine most of the time, even without this change and without adding Clang build targets as dependency in plugin's CMake definition. Indeed, these Clang build targets are often generated early in the build process. However, that's not guaranteed and we did notice that on occasions plugins would fail to build. Differential Revision: https://reviews.llvm.org/D120999
-