- Feb 02, 2024
-
-
Peter Smith authored
-
Tuan Chuong Goh authored
-
Timm Baeder authored
Fixes #79964
-
Benjamin Maxwell authored
When unrolling the reduction dimension of something like a matmul for SME, it is possible to get 3D masks, which are vectors of SME-like masks. The 2D masks for individual operations are then extracted from the 3D masks. i.e.: ```mlir %mask = vector.create_mask %nonConstantDim, %a, %b : vector<4x[4]x[4]xi1> %subMask = vector.extract %mask[2] : vector<[4]x[4]xi1> from vector<4x[4]x[4]xi1> ``` ArmSME only supports lowering 2D create_masks, so we must fold the extract into the create_mask. This can be done by checking if the extraction index is within the true region, then using that select the first dimension of the 2D mask. This is shown below. ```mlir %extractionInTrueRegion = arith.cmpi slt, %c2, %nonConstantDim : index %newMaskFrontDim = arith.select %extractionInTrueRegion, %a, %c0 : index %subMask = vector.create_mask %newMaskFrontDim, %b : vector<[4]x[4]xi1> ``` -
lorenzo chelini authored
Add write memory effect for the print operation. The exact memory behavior is implemented in other print-like operations such as `transform::PrintOp` or `gpu::printf`. Providing memory behavior allows using the operation in passes like buffer deallocation instead of emitting an error.
-
Nikita Popov authored
SCEV treats "or disjoint" the same as "add nsw nuw". However, when expanding, we cannot generally replace an add SCEV node with an "or disjoint" instruction. Just dropping the poison flag is insufficient in this case, we would have to actually convert the or into an add. This is a partial fix for #79861.
-
Mikael Holmen authored
Without this gcc warns like ../lib/Target/PowerPC/PPCAsmPrinter.cpp:1650:33: warning: suggest parentheses around '&&' within '||' [-Wparentheses] 1650 | (InstDisp >= -32768) && | ~~~~~~~~~~~~~~~~~~~~~^~ 1651 | "Expecting the instruction displacement for local-exec TLS " | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 1652 | "variables to be between [-32768, 32768)!"); | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -
Nemanja Ivanovic authored
My recent commit (67c1c1db) made the CPU ID builtins target-independent so they can be used on PPC as well. However, that had the unintended consequence of changing the behaviour of __has_builtin in that it reports these as supported at the pre-processor level. This makes it impossible to guard the use of these with this feature test macro which is clearly not ideal. This patch restores the behaviour of __has_builtin for __builtin_cpu_is, __builtin_cpu_init, __builtin_cpu_supports. Now the preprocessor queries the target to determine whether the target supports the builtin.
-
Wang Pengcheng authored
We can use `deftype` (not using `typedef` here to be consistent with `def`, `defm`, `defset`, `defvar`, etc) to define type aliases. Currently, only primitive types and type aliases are supported to be the source type and `deftype` statements can only appear at the top level. Reviewers: fpetrogalli, Artem-B, nhaehnle, jroelofs Reviewed By: jroelofs, nhaehnle, Artem-B Pull Request: https://github.com/llvm/llvm-project/pull/79570
-
NAKAMURA Takumi authored
To relax scanning record, tweak order by `Decision < Expansion`, or `Expansion` could not be distinguished whether it belonged to `Decision` or not. Relevant to #77871
-
Sander de Smalen authored
__ARM_STATE_ZA and __ARM_STATE_ZT0 are set when the compiler can parse the "za" and "zt0" strings in the SME attributes. __ARM_FEATURE_SME and __ARM_FEATURE_SME2 are set when the compiler can generate code for attributes with "za" and "zt0" state, respectively. __ARM_FEATURE_LOCALLY_STREAMING is set when the compiler supports the __arm_locally_streaming attribute.
-
Matthias Springer authored
This is a follow-up on #79865. Result strides are now also verified if the `memref.subview` op has rank reductions.
-
Timm Bäder authored
This was not working right on armv8: https://lab.llvm.org/buildbot/#/builders/245/builds/20020
-
Matthias Springer authored
Similar to `OpBuilder::clone`, operation/block insertion notifications should be sent when cloning the contents of a region. E.g., this is to ensure that the newly created operations are put on the worklist of the greedy pattern rewriter driver. Also move `cloneRegionBefore` from `RewriterBase` to `OpBuilder`. It only creates new IR, so it should be part of the builder API (like `clone(Operation &)`). The function does not have to be virtual. Now that notifications are properly sent, the override in the dialect conversion is no longer needed.
-
ManuelvOK authored
In 21551951, the "system-headers-coverage" option has been added but not used in all necessary places. This is the recommit since it has been reverted in faef68bc Potential reviewers: @gulfemsavrun @petrhosek Co-authored-by:
Manuel Kalettka <manuel.kalettka@kernkonzept.com>
-
Matthias Springer authored
This commit changes `OpBuilder::create` and `OpBuilder::createOrFold` such that `notifyOperationInserted` is no longer triggered if no insertion point is set. In such a case, an unlinked operation is created but not inserted, so `notifyOperationInserted` should not be triggered. Note: Inserting another op into a block that belongs to an unlinked op (e.g., by the builder of the unlinked op) will trigger a notification.
-
Matthias Springer authored
`OpBuilder::clone(Operation &)` should trigger not only `notifyOperationInserted` but also `notifyBlockInserted` (for all block contained in `op`).
-
Maciej Gabka authored
The masked symbols in SLEEF are incorrectly implemented as calls to non masked variants, what only works fine for functions which do not modify memory. For vector variants which modify memory we can only use a non masked symbols for now. The SVE ArmPL mappings need to be removed for now as well.
-
Timm Bäder authored
This was just an omission from an earlier commit, clearly we can print them.
-
Vlad Serebrennikov authored
GCC has changed over the past decade, and we're not implementing everything they do. Fixes #51472 --------- Co-authored-by:Aaron Ballman <aaron@aaronballman.com>
-
Timm Bäder authored
-
Matthew Devereau authored
This enables specifing "za" or "zt0" to the clobber list for inline asm. This complies with the acle SME addition to the asm extension here: https://github.com/ARM-software/acle/pull/276
-
Timm Bäder authored
The LHS of the subtraction returns 16 right now, but should return 0.
-
Kai Sasaki authored
The buildbot test running on s390x platform keeps failing since [this time](https://lab.llvm.org/buildbot/#/builders/199/builds/31136). This is because of the dependency on the endianness of the platform. It expects the format invalid in the big endian platform (s390x). We can simply skip it. See: https://discourse.llvm.org/t/mlir-s390x-linux-failure/76695
-
Timm Bäder authored
If the SubExpr results in an invalid pointer, we will otherwise reject the constant expression.
-
Timm Bäder authored
-
Timm Bäder authored
In C, they return an integer, so emit their value as such.
-
Yuta Mukai authored
Add asserts requirements for tests that verify debug output.
-
Fangrui Song authored
In a `--defsym y0=0 -T a.lds` link where a.lds contains only INSERT commands, the `script->sectionCommands` layout may be: ``` orphan sections SymbolAssignment due to --defsym sections created by INSERT commands ``` The `OutputDesc` objects are not contiguous in sortInputSections, and `compareSections` will be called with a SymbolAssignment argument, leading to an assertion failure.
-
Jason Molenda authored
David Spickett had several suggestions for https://github.com/llvm/llvm-project/pull/79962 after I'd already merged it. Address those.
-
Shengchen Kan authored
`commuteInstruction(MI, false, OpNum, CommuteOpIdx2)` should never create any new instruction, so we don't need to check and erase it.
-
Maksim Panchenko authored
Reported by cpp check static analyzer in #80111. Fixes #80111.
-
Craig Topper authored
[RISCV] Add -march support for many of the S extensions mentioned in the profile specification. (#79399) This is a good portion of the extensions mentioned in the RVA23 profile here https://github.com/riscv/riscv-profiles/blob/main/rva23-profile.adoc I don't believe these add any new CSRs. Sstc does add new CSRs, but we already added them without the extension name a while back. I tried to keep the descriptions in RISCVFeatures.td fairly short since the strings show up in `-print-supported-extensions`.
-
Philip Reames authored
-
Rahman Lavaee authored
[SHT_LLVM_BB_ADDR_MAP] Allow basic-block-sections and labels be used together by decoupling the handling of the two features. (#74128) Today `-split-machine-functions` and `-fbasic-block-sections={all,list}` cannot be combined with `-basic-block-sections=labels` (the labels option will be ignored). The inconsistency comes from the way basic block address map -- the underlying mechanism for basic block labels -- encodes basic block addresses (https://lists.llvm.org/pipermail/llvm-dev/2020-July/143512.html). Specifically, basic block offsets are computed relative to the function begin symbol. This relies on functions being contiguous which is not the case for MFS and basic block section binaries. This means Propeller cannot use binary profiles collected from these binaries, which limits the applicability of Propeller for iterative optimization. To make the `SHT_LLVM_BB_ADDR_MAP` feature work with basic block section binaries, we propose modifying the encoding of this section as follows. ... -
Yuta Mukai authored
Add AArch64 implementations for the interfaces of MachinePipeliner pass. The pass is disabled by default for AArch64. It is enabled by specifying --aarch64-enable-pipeliner. 5 tests in llvm-test-suites show performance improvement by more than 5% on a Neoverse V1 processor. | test | improvement | | ---------------------------------------------------------------- | -----------:| | MultiSource/Benchmarks/TSVC/Recurrences-dbl/Recurrences-dbl.test | 16% | | MultiSource/Benchmarks/TSVC/Recurrences-dbl/Recurrences-flt.test | 16% | | SingleSource/Benchmarks/Adobe-C++/loop_unroll.test | 14% | | SingleSource/Benchmarks/Misc/flops-5.test | 13% | | SingleSource/Benchmarks/BenchmarkGame/spectral-norm.test | 6% | (base flags: -mcpu=neoverse-v1 -O3 -mrecip, flags for pipelining: -mllvm -aarch64-enable-pipeliner -mllvm -pipeliner-max-stages=100 -mllvm -pipeliner-max-mii=100 -mllvm -pipeliner-enable-copytophi=0) On the other hand, there are cases of significant performance degradation. Algorithm improvements and adding the option/pragma will be needed in the future.
-
Aiden Grossman authored
-
Jacques Pienaar authored
-
Nico Weber authored
-
michaelrj-google authored
Similar to #80051. The epoll_pwait2 syscall isn't available on all target platforms, and this is causing downstream test failures. This patch disables it until it can be detected whether or not it is available.
-