- Aug 23, 2023
-
-
Changpeng Fang authored
Summary: Under -O0, device-libs may still emit these instructions under conditions. So we need to remove them with warning if not compatible. Fixes: SWDEV-417219 Reviewers: arsenm, Pierre-vh and b-sumner Differential Revision: https://reviews.llvm.org/D158316
-
Michael Halkenhaeuser authored
This patch fixes: https://github.com/llvm/llvm-project/issues/64738 We observed multiple issues, primarily that the `DeviceId` was reported as -1 in certain scenarios. The reason for this is simply that the device is not initialized at that point. Hence, we need to move the RAII object creation just after the `checkDeviceAndCtors`, closer to the actual call we want to observe. This also solves an odering issue where one `target enter data` callback would be executed before the `Init` callback. Additionally, this change will also fix that the callbacks corresponding to `enter / exit data` and `update` in conjunction with `nowait` would not result in the emission of an OMPT callback. Added a testcase to cover initialized device number and `omp target` constructs. Reviewed By: dhruvachak Differential Revision: https://reviews.llvm.org/D157605
-
Craig Topper authored
-
David Green authored
The patch D136361 disabled GlobalISel and FastISel for some SME functions, as the saving and restoring of SM is not yet handled. There were several tests added for fp128 fadd, which will be expanded to a libcall, that only happened to work by accident and did not handle other cases such as f32/f64 frem libcalls. This extends the cases where GlobalISel / FastISel is disabled for functions with SME attributes, under the assumption that it is difficult to tell what will become a libcall reliably, and so should fall back for all function until GlobalISel and/or FastISel can handle them. Differential Revision: https://reviews.llvm.org/D158490
-
Erick Velez authored
Serialize namespaces, nested namespaces, and class relationships inside them. Depends on D157076 Reviewed By: dang Differential Revision: https://reviews.llvm.org/D158239
-
zhoujiapeng authored
The implementation is based on the X86 version, with the same code of symbol and addend extraction. The differences include the support for RelType `R_AARCH64_CALL26` and the deletion of 8-bit relocation. Reviewed By: rafauler Differential Revision: https://reviews.llvm.org/D156018
-
David Green authored
See D136361.
-
Koakuma authored
This adds the v9 SETX pseudoinstruction for convenient loading of 64-bit values. Reviewed By: barannikov88 Differential Revision: https://reviews.llvm.org/D157230
-
zhoujiapeng authored
This commit splits the createRelocation function for the X86 architecture into two parts, retaining the first half and moving the second half to a new function called extractFixupExpr. The purpose of this change is to make extractFixupExpr a shared function between AArch64 and X86 architectures, increasing code reusability and maintainability. Child revision: https://reviews.llvm.org/D156018 Reviewed By: Amir Differential Revision: https://reviews.llvm.org/D157217
-
walter erquinigo authored
https://github.com/llvm/llvm-project/commit/59237bb52c9483fce395428bfab5996eabe54ed0 changed the behavior of the `SetTimeout` and `GetTimeout` methods of `EvaluateExpressionOptions`, which broke the Mojo REPL and related services (https://docs.modular.com/mojo/) because it relies on having infinite timeouts. That's a necessity because developers often use the REPL for executing extremely long-running numeric jobs. Having said that, `EvaluateExpressionOptions` shouldn't be that opinionated on this matter anyway. Instead, it should be the responsibility of the evaluator to define which timeout to use for each specific case. Differential Revision: https://reviews.llvm.org/D157764
-
Mark Danial authored
This patch is to add cray pointer (aka integer pointer) support to flang. Syntax and semantic checking were already available in flang. Cray pointers reference (https://gcc.gnu.org/onlinedocs/gfortran/Cray-pointers.html) In order to implement the feature we create the following sequence for a simple scalar load and store: ``` integer pte, i pointer(ptr, pte) i = pte ``` ``` %1 = fir.alloca i32 {bindc_name = "i", uniq_name = "_QFEi"} %2 = fir.alloca i32 {bindc_name = "pte", uniq_name = "_QFEpte"} %3 = fir.alloca i64 {bindc_name = "ptr", uniq_name = "_QFEptr"} ... %7 = fir.embox %3 : (!fir.ref<i64>) -> !fir.box<i64> %8 = fir.box_addr %7 : (!fir.box<i64>) -> !fir.ref<i64> %9 = fir.convert %8 : (!fir.ref<i64>) -> !fir.ref<!fir.ptr<i32>> %10 = fir.load %9 : !fir.ref<!fir.ptr<i32>> %11 = fir.load %10 : !fir.ptr<i32> fir.store %11 to %1 : !fir.ref<i32> ``` ``` integer pte, i pointer(ptr, pte) pte = i ``` ``` %1 = fir.alloca i32 {bindc_name = "i", uniq_name = "_QFEi"} %2 = fir.alloca i32 {bindc_name = "pte", uniq_name = "_QFEpte"} %3 = fir.alloca i64 {bindc_name = "ptr", uniq_name = "_QFEptr"} %7 = fir.load %1 : !fir.ref<i32> %8 = fir.embox %3 : (!fir.ref<i64>) -> !fir.box<i64> %9 = fir.box_addr %8 : (!fir.box<i64>) -> !fir.ref<i64> %10 = fir.convert %9 : (!fir.ref<i64>) -> !fir.ref<!fir.ptr<i32>> %11 = fir.load %10 : !fir.ref<!fir.ptr<i32>> fir.store %7 to %11 : !fir.ptr<i32> ``` The sequence is very similar for array element cases with the addition of fir.coordinate_of for the specific element. The whole array case is slightly different but uses the same sequence before the fir.array_load and fir.array_merge_store. Reviewed By: kkwli0 Differential Revision: https://reviews.llvm.org/D151478
-
Arthur Eubanks authored
This reverts commit 133b24a3. Causes JIT breakages, see https://reviews.llvm.org/D157907.
-
Arthur Eubanks authored
Fixes some FIXMEs. Reviewed By: MaskRay Differential Revision: https://reviews.llvm.org/D158466
-
- Aug 22, 2023
-
-
Noah Goldstein authored
Use the comparison based analysis to strengthen the standard knownbits analysis rather than choosing either/or. Reviewed By: nikic Differential Revision: https://reviews.llvm.org/D157807
-
Noah Goldstein authored
This is basically a copy and paste of the same logic we do in `computeKnownBits` but adapts it for just `isKnownNonZero`. Differential Revision: https://reviews.llvm.org/D157801
-
Noah Goldstein authored
Differential Revision: https://reviews.llvm.org/D157815
-
Noah Goldstein authored
Just fill in missing cases (TODO) for `ugt`, `uge`, `sgt`, `sge`, `slt`, and `sle`. These are all in the same spirit as `ult`/`uge`, but each of the other conditions have different constraints. Proofs: https://alive2.llvm.org/ce/z/gnj4o- Differential Revision: https://reviews.llvm.org/D157800
-
Noah Goldstein authored
Differential Revision: https://reviews.llvm.org/D157798
-
Noah Goldstein authored
Differential Revision: https://reviews.llvm.org/D157797
-
Lei Zhang authored
We need to use the converted index type for index offset calculation logic; not the target bitwidth, which is typically 32-bit. Reviewed By: kuhar Differential Revision: https://reviews.llvm.org/D158482
-
Lei Zhang authored
This commit moves MemRefToSPIRV tests that involve bitwidth emulation to their own test files. This is pure NFC. Reviewed By: kuhar Differential Revision: https://reviews.llvm.org/D158481
-
Lei Zhang authored
Reviewed By: dcaballe Differential Revision: https://reviews.llvm.org/D158336
-
Alexey Bataev authored
-
Guray Ozen authored
The Warpgroup Matrix Descriptor is a 64-bit integer that holds information about a matrix used by the wgmma instruction. In this work, a new type is introduced for the descriptor. This enhances the readability of the IR and allows for easier verification using MLIR verification tools. The type contains a 'memref' related to the descriptor, which is crucial for preserving and conveying information. Depends on D157382 Reviewed By: qcolombet Differential Revision: https://reviews.llvm.org/D158403
-
Philip Reames authored
This extends the concat_vector of loads to strided_load transform to handle reversed index pattern. The previous code expected indexing of the form (a0, a1+S, a2+S,...). However, we can also see indexing of the form (a1+S, a2+S, a3+S, .., aS). This form is a strided load starting at address aN + S*(n-1) with stride -S. Note that this is also fixing what looks to be a bug in the memory location reasoning for forward strided case. A strided load with negative stride access eltsize bytes past base ptr, and then bytes *before* base ptr. (That is, the range should extend from before base ptr to after base ptr.) Differential Revision: https://reviews.llvm.org/D157886
-
David Spickett authored
To address https://github.com/llvm/llvm-project/issues/64616, this change does the following: * Links back to the "Optional Dependencies" section from the cross compilation instructions where we talk about removing libraries. In the reported issue, the host libXML was found by CMAke somehow and disabling libXML fixed it, so this link should encourage users to try as many of those options as needed. * Removes the use of CMAKE_CROSS_COMPILING. In older CMake versions it seems you could set this manually but now the advice is to set CMAKE_SYSTEM_NAME and CMAKE_SYSTEM_PROCESSOR then let CMake figure it out. There is also CMAKE_SYSTEM_VERSION which the docs say you have to set too, but I can only find examples of Windows and Android builds using this. It might be needed to "cross" compile from one version of AArch64 Linux to another, but I can't confirm that. * Removes the tablegen tools paths in favour of DLLVM_NATIVE_TOOL_DIR. This one setting deals with all build tools in llvm that must be host versions. * Updates the explanations of the common options and orders them in some rough order of relevance with the "might be needed" later. Reviewed By: JDevlieghere, bulbazord Differential Revision: https://reviews.llvm.org/D158085
-
Philip Reames authored
If we have a known (or bounded) index which definitely fits in a smaller LMUL register group size, we can reduce the LMUL of the slide and extract instructions. This loosens constraints on register allocation, and allows the hardware to do less work, at the potential cost of some additional VTYPE toggles. In practice, we appear (after prior patches) to do a decent job of eliminating the additional VTYPE toggles in most cases. Differential Revision: https://reviews.llvm.org/D158460
-
Simon Pilgrim authored
[X86] Move gather/scatter index shl(x,c) -> index:x, scale:c fold into X86DAGToDAGISel::matchIndexRecursively
-
Kadir Cetinkaya authored
We seem to be hitting limits in some windows build bots, see https://github.com/clangd/clangd/issues/1712#issuecomment-1686478931. So bumping the timeouts to 60 seconds and completely dropping them for sync requests. As mentioned in the comment above, this should improve things, considering even the tests that don't touch any complicated scheduler is failing. Differential Revision: https://reviews.llvm.org/D158426
-
Guray Ozen authored
This work introduces a new Op, `wgmma.generate.descriptor`, designed to create a wgmma descriptor for inputs of matrix multiply and accumulate operations using `wgmma.mma_async` PTX instruction. The descriptor format specifications can be found in the following link: https://docs.nvidia.com/cuda/parallel-thread-execution/index.html#asynchronous-warpgroup-level-matrix-shared-memory-layout-matrix-descriptor It's important to note that this op is in its initial phase, and it does come with certain limitations. It only supports 128b swizzling and does not incorporate interleaving. In the future, different calculations will be addressed in separate works, expanding the capabilities of the op. Reviewed By: qcolombet Differential Revision: https://reviews.llvm.org/D157382
-
zhijian authored
Summary: llvm-ar is symlinked as llvm-ranlib and will act as ranlib when invoked in that mode. llvm-ar since [[ https://github.ibm.com/compiler/llvm-project/commit/4f2cfbe5314b064625b2c87bde6ce5c8d04004c5 | compiler/llvm-project@4f2cfbe ]] supports the -X options, but doesn't seem to accept them when running as llvm-ranlib. In AIX OS , according to https://www.ibm.com/docs/en/aix/7.2?topic=r-ranlib-command -X mode Specifies the type of object file ranlib should examine. The mode must be one of the following: 32 Processes only 32-bit object files 64 Processes only 64-bit object files 32_64, any Processes both 32-bit and 64-bit object files The default is to process 32-bit object files (ignore 64-bit objects). The mode can also be set with the OBJECT_MODE environment variable. For example, OBJECT_MODE=64 causes ranlib to process any 64-bit objects and ignore 32-bit objects. The -X flag overrides the OBJECT_MODE variable. Reviewers: James Henderson, MaskRay, Stephen Peckham Differential Revision: https://reviews.llvm.org/D142660
-
David Green authored
This extends the existing legalization combine to fold G_BUILD_VECTOR where the sources are all from the same G_UNMERGE, to handle cases where some of the lanes are undef. This comes up in the legalization of <3 x ..> vectors in AArch64, where they are padded with undef. There are two choices for what to create. This patch just removes the G_BUILD_VECTOR/G_UNMERGE, losing the information about which lanes are undef. The alternative would be to generate an identity G_SHUFFLE_VECTOR with undef lanes marked as undef. I think both have advantages and disadvantages. Differential Revision: https://reviews.llvm.org/D158063
-
Nikita Popov authored
-
Alexey Bataev authored
If the masked gathers can be reordered, it may produce strided access pattern and the reordering does not affect common reodering, better to try to reorder masked gathers for better performance. Differential Revision: https://reviews.llvm.org/D157009
-
Simon Pilgrim authored
[X86] Add X86DAGToDAGISel::matchIndexRecursively helper to match/resolve address indices, scaling + displacement This currently just splits ADD/AddLike constant offset values, but we should be able to expand on this as part of handling the regressions noticed in D155472 without adding more duplicate zext/sext code inside matchAddressRecursively
-
Jolanta Jensen authored
This patch removes intrinsics that have no definitions in Intrinsics.td from mappings to vector functions in SLEEF library. It also removes mappings for non-scalar intrinsics. Differential Revision: https://reviews.llvm.org/D158089
-
Adrian Kuegel authored
Use .empty() instead of checking for size().
-
Andrzej Warzynski authored
This patch effectively enables the CastAwayElementwiseLeadingOneDim rewrite pattern for scalable vectors. To this end, `ExtractOp::inferReturnTypes` is updated so that scalable dimensions are correctly recognised. The change to ExtractOp will likely make also other conversion patterns valid for scalable vectors, but this patch focuses on just one case. Other conversion patterns will be enabled in the forthcoming patches. Depends on D157993 Differential Revision: https://reviews.llvm.org/D158335
-
Sergio Afonso authored
This patch explicitly marks supported clauses for OpenMP directives missing an implementation, so that compilation fails if they are specified, rather than silently ignoring them. Differential Revision: https://reviews.llvm.org/D158076
-
Nico Weber authored
-