- Sep 22, 2020
-
-
Nicolas Vasilache authored
This revision allows representing a reduction at the level of linalg on tensors for generic ops by uniformizing with the named ops approach.
-
Fangrui Song authored
-
Mehdi Amini authored
Instead of performing a transformation, such pass yields a new pass pipeline to run on the currently visited operation. This feature can be used for example to implement a sub-pipeline that would run only on an operation with specific attributes. Another example would be to compute a cost model and dynamic schedule a pipeline based on the result of this analysis. Discussion: https://llvm.discourse.group/t/rfc-dynamic-pass-pipeline/1637 Reviewed By: silvas Differential Revision: https://reviews.llvm.org/D86392
-
Diego Caballero authored
This patch adds a utility based on SuperVectorizer to vectorize an affine loop nest using a given vectorization strategy. This strategy allows targeting specific loops for vectorization instead of relying of the SuperVectorizer analysis to choose the right loops to vectorize. Reviewed By: nicolasvasilache Differential Revision: https://reviews.llvm.org/D85869
-
- Sep 21, 2020
-
-
Stephen Neuendorffer authored
-
Christian Sigg authored
See comments in https://reviews.llvm.org/D85631. Reviewed By: herhut Differential Revision: https://reviews.llvm.org/D86214
-
Benjamin Kramer authored
LLVM can deal with any integer or float type, don't arbitrarily restrict it to f32/f64/i32/i64. Differential Revision: https://reviews.llvm.org/D88010
-
Tres Popp authored
This adds support for the interface and provides unambigious information on the control flow as it is unconditional on any runtime values. The code is tested through confirming that buffer-placement behaves as expected. Differential Revision: https://reviews.llvm.org/D87894
-
Mehdi Amini authored
This crash only happens when a function pass is followed by a module pass. In this case the splitting of the pass pipeline didn't handle properly the verifier passes and ended up with an odd number of pass in the pipeline, breaking an assumption of the local crash reproducer executor and hitting an assertion. Differential Revision: https://reviews.llvm.org/D88000
-
Mehdi Amini authored
-
- Sep 18, 2020
-
-
Lei Zhang authored
Vendor/device information are not resource limits. Moving to target environment directly for better organization. Reviewed By: mravishankar Differential Revision: https://reviews.llvm.org/D87911
-
Stella Laurenzo authored
* Per thread https://llvm.discourse.group/t/revisiting-ownership-and-lifetime-in-the-python-bindings/1769 * Reworks contexts so it is always possible to get back to a py::object that holds the reference count for an arbitrary MlirContext. * Retrofits some of the base classes to automatically take a reference to the context, elimintating keep_alives. * More needs to be done, as discussed, when moving on to the operations/blocks/regions. Differential Revision: https://reviews.llvm.org/D87886
-
ergawy authored
Roundtripping SPIR-V modules used the same MLIRContext object for both ways of the trip. This resulted in deserialization using a context object already containing Types constructed during serialization. This commit rectifies that by creating a new MLIRContext during deserialization. Reviewed By: mravishankar, antiagainst Differential Revision: https://reviews.llvm.org/D87692
-
Valentin Clement authored
Add missing operands to represent copyin with readonly modifier, copyout with zero modifier and create with zero modifier. Reviewed By: ftynse Differential Revision: https://reviews.llvm.org/D87874
-
Valentin Clement authored
Following patch D87712, this patch switch AnyInteger for operands gangNum, gangStatic, workerNum, vectoreLength and tileOperands to Index and AnyInteger. Reviewed By: ftynse Differential Revision: https://reviews.llvm.org/D87848
-
Hanhan Wang authored
Reviewed By: mravishankar Differential Revision: https://reviews.llvm.org/D87887
-
Nicolas Vasilache authored
This revision allows representing a reduction at the level of linalg on tensors for named ops. When a structured op has a reduction and returns tensor(s), new conventions are added and documented. As an illustration, the syntax for a `linalg.matmul` writing into a buffer is: ``` linalg.matmul ins(%a, %b : memref<?x?xf32>, tensor<?x?xf32>) outs(%c : memref<?x?xf32>) ``` , whereas the syntax for a `linalg.matmul` returning a new tensor is: ``` %d = linalg.matmul ins(%a, %b : tensor<?x?xf32>, memref<?x?xf32>) init(%c : memref<?x?xf32>) -> tensor<?x?xf32> ``` Other parts of linalg will be extended accordingly to allow mixed buffer/tensor semantics in the presence of reductions.
-
Sean Silva authored
This op is a catch-all for creating witnesses from various random kinds of constraints. In particular, I when dealing with extents directly, which are of `index` type, one can directly use std ops for calculating the predicates, and then use cstr_require for the final conversion to a witness. Differential Revision: https://reviews.llvm.org/D87871
-
Rahul Joshi authored
- Change OpClass new method addition to find and eliminate any existing methods that are made redundant by the newly added method, as well as detect if the newly added method will be redundant and return nullptr in that case. - To facilitate that, add the notion of resolved and unresolved parameters, where resolved parameters have each parameter type known, so that redundancy checks on methods with same name but different parameter types can be done. - Eliminate existing code to avoid adding conflicting/redundant build methods and rely on this new mechanism to eliminate conflicting build methods. Fixes https://bugs.llvm.org/show_bug.cgi?id=47095 Differential Revision: https://reviews.llvm.org/D87059
-
- Sep 17, 2020
-
-
Navdeep Kumar authored
Add support to tile affine.for ops with parametric sizes (i.e., SSA values). Currently supports hyper-rectangular loop nests with constant lower bounds only. Move methods - moveLoopBody(*) - getTileableBands(*) - checkTilingLegality(*) - tilePerfectlyNested(*) - constructTiledIndexSetHyperRect(*) to allow reuse with constant tile size API. Add a test pass -test-affine -parametric-tile to test parametric tiling. Differential Revision: https://reviews.llvm.org/D87353
-
Abhishek Varma authored
Add support for return values in affine.for yield along the same lines as scf.for and affine.parallel. Signed-off-by:
Abhishek Varma <abhishek.varma@polymagelabs.com> Differential Revision: https://reviews.llvm.org/D87437
-
Hanhan Wang authored
Fold the operation if the source is a scalar constant or splat constant. Update transform-patterns-matmul-to-vector.mlir because the broadcast ops are folded in the conversion. Reviewed By: aartbik Differential Revision: https://reviews.llvm.org/D87703
-
Valentin Clement authored
This patch change the type of operands async, wait, numGangs, numWorkers and vectorLength from index to AnyInteger to fit with acc.loop and the OpenACC specification. Reviewed By: ftynse Differential Revision: https://reviews.llvm.org/D87712
-
Stephan Herhut authored
Adds a pattern that replaces a chain of two tensor_cast operations by a single tensor_cast operation if doing so will not remove constraints on the shapes.
-
Vincent Zhao authored
`swapId` used to be a static function in `AffineStructures.cpp`. This diff makes it accessible from the external world by turning it into a member function of `FlatAffineConstraints`. This will be very helpful for other projects that need to manipulate the content of `FlatAffineConstraints`. Differential Revision: https://reviews.llvm.org/D87766
-
Jakub Lichman authored
ConvOp vectorization supports now only convolutions of static shapes with dimensions of size either 3(vectorized) or 1(not) as underlying vectors have to be of static shape as well. In this commit we add support for convolutions of any size as well as dynamic shapes by leveraging existing matmul infrastructure for tiling of both input and kernel to sizes accepted by the previous version of ConvOp vectorization. In the future this pass can be extended to take "tiling mask" as a user input which will enable vectorization of user specified dimensions. Differential Revision: https://reviews.llvm.org/D87676
-
Tres Popp authored
These canonicalizations are already handled by folding which will occur in a superset of situations, so they are being removed. Differential Revision: https://reviews.llvm.org/D87706
-
Artur Bialas authored
Added GroupNonUniformBroadcastOp to spirv dialect. Differential Revision: https://reviews.llvm.org/D87688
-
zhanghb97 authored
This patch provides C API for MLIR affine map. - Implement C API for AffineMap class. - Add Utils.h to include/mlir/CAPI/, and move the definition of the CallbackOstream to Utils.h to make sure mlirAffineMapPrint work correct. - Add TODO for exposing the C API related to AffineExpr and mutable affine map. Differential Revision: https://reviews.llvm.org/D87617
-
- Sep 16, 2020
-
-
Valentin Clement authored
Add missing operands to represent copin with readonly modifier, copyout with zero modifier, create with zero modifier and default clause. Reviewed By: ftynse Differential Revision: https://reviews.llvm.org/D87733
-
Eugene Zhulenev authored
Enable inlining for Linalg dialect. Differential Revision: https://reviews.llvm.org/D87567
-
Alex Zinenko authored
Numerous MLIR functions return instances of `StringRef` to refer to a non-owning fragment of a string (usually owned by the context). This is a relatively simple class that is defined in LLVM. Provide a simple wrapper in the MLIR C API that contains the pointer and length of the string fragment and use it for Standard attribute functions that return StringRef instead of the previous, callback-based mechanism. Reviewed By: stellaraccident Differential Revision: https://reviews.llvm.org/D87677
-
Uday Bondhugula authored
Emit some more information when printing/dumping `Value`s of `BlockArgument` kind. This is purely to help for debugging purposes. Differential Revision: https://reviews.llvm.org/D87670
-
- Sep 15, 2020
-
-
Diego Caballero authored
Rename 'setInsertionPointAfter(Value)' API to avoid ambiguity with 'setInsertionPointAfter(Operation *)' for SingleResult operations which implicitly convert to Value (see D86756). Differential Revision: https://reviews.llvm.org/D87155
-
Valentin Clement authored
Add a verifier for the loop op in the OpenACC dialect. Check basic restriction from 2.9 Loop construct from the OpenACC 3.0 specs. Reviewed By: ftynse Differential Revision: https://reviews.llvm.org/D87546
-
Valentin Clement authored
This patch adds the missing print for the vector_length in the parallel operation. Reviewed By: ftynse Differential Revision: https://reviews.llvm.org/D87630
-
Stephan Herhut authored
This add canonicalizer for - extracting an element from a dynamic_tensor_from_elements - propagating constant operands to the type of dynamic_tensor_from_elements Differential Revision: https://reviews.llvm.org/D87525
-
Alex Zinenko authored
When packing function results into a structure during the standard-to-llvm dialect conversion, do not assume the conversion was successful and propagate nullptr as error state. Fixes PR45184. Reviewed By: nicolasvasilache Differential Revision: https://reviews.llvm.org/D87605
-
- Sep 14, 2020
-
-
Federico Lebrón authored
Now backends spell out which namespace they want to be in, instead of relying on clients #including them inside already-opened namespaces. This also means that cppNamespaces should be fully qualified, and there's no implicit "::mlir::" prepended to them anymore. Reviewed By: mehdi_amini Differential Revision: https://reviews.llvm.org/D86811
-
Lubomir Litchev authored
Added support to the Std dialect cast operations to do casts in vector types when feasible. Reviewed By: ftynse Differential Revision: https://reviews.llvm.org/D87410
-