- Nov 21, 2019
-
-
River Riddle authored
This moves the different canonicalizations of regions into one place and invokes them in the fixed-point iteration of the canonicalizer. PiperOrigin-RevId: 281617072
-
- Nov 20, 2019
-
-
Andy Davis authored
PiperOrigin-RevId: 281605471
-
Mahesh Ravishankar authored
If the sizes are specified as arguments to the subview op, then the shape must be dynamic as well. PiperOrigin-RevId: 281591608
-
MLIR Team authored
PiperOrigin-RevId: 281580028
-
Sean Silva authored
This is a simple multi-level DCE pass that operates pretty generically on the IR. Its key feature compared to the existing peephole dead op folding that happens during canonicalization is being able to delete recursively dead cycles of the use-def graph, including block arguments. PiperOrigin-RevId: 281568202
-
Mahesh Ravishankar authored
The current SubViewOp specification allows for either all offsets, shape and stride to be dynamic or all of them to be static. There are opportunities for more fine-grained canonicalization based on which of these are static. For example, if the sizes are static, the result memref is of static shape. The specification of SubViewOp is modified to allow on or more of offsets, shapes and strides to be statically specified. The verification is updated to ensure that the result type of the subview op is consistent with which of these are static and which are dynamic. PiperOrigin-RevId: 281560457
-
Nicolas Vasilache authored
This CL uses the pattern rewrite infrastructure to implement a simple VectorOps -> VectorOps legalization strategy to unroll coarse-grained vector operations into finer grained ones. The transformation is written using local pattern rewrites to allow composition with other rewrites. It proceeds by iteratively introducing fake cast ops and cleaning canonicalizing or lowering them away where appropriate. This is an example of writing transformations as compositions of local pattern rewrites that should enable us to make them significantly more declarative. PiperOrigin-RevId: 281555100
-
River Riddle authored
This interface provides more fine-grained hooks into the AsmPrinter than the dialect interface, allowing for operations to define the asm name to use for results directly on the operations themselves. The hook is also expanded to enable defining named result "groups". Get a special name to use when printing the results of this operation. The given callback is invoked with a specific result value that starts a result "pack", and the name to give this result pack. To signal that a result pack should use the default naming scheme, a None can be passed in instead of the name. For example, if you have an operation that has four results and you want to split these into three distinct groups you could do the following: setNameFn(getResult(0), "first_result"); setNameFn(getResult(1), "middle_results"); setNameFn(getResult(3), ""); // use the default numbering. This would print the operation as follows: %first_result, %middle_results:2, %0 = "my.op" ... PiperOrigin-RevId: 281546873
-
Nicolas Vasilache authored
This operator is used for internal debugging purposes. PiperOrigin-RevId: 281544152
-
Alexander Belyaev authored
PiperOrigin-RevId: 281506693
-
Alexander Belyaev authored
PiperOrigin-RevId: 281501234
-
Stephan Herhut authored
PiperOrigin-RevId: 281483447
-
Eric Schweitz authored
Closes tensorflow/mlir#246 PiperOrigin-RevId: 281442685
-
- Nov 19, 2019
-
-
Christian Sigg authored
Fix registered size of indirect MemRefType kernel arguments. PiperOrigin-RevId: 281362940
-
Nicolas Vasilache authored
The `vector.strided_slice` takes an n-D vector, k-D `offsets` integer array attribute, a k-D `sizes` integer array attribute, a k-D `strides` integer array attribute and extracts the n-D subvector at the proper offset. Returns an n-D vector where the first k-D dimensions match the `sizes` attribute. The returned subvector contains the elements starting at offset `offsets` and ending at `offsets + sizes`. Example: ``` %1 = vector.strided_slice %0 {offsets : [0, 2], sizes : [2, 4], strides : [1, 1]}: vector<4x8x16xf32> // returns a vector<2x4x16xf32> ``` This op will be useful for progressive lowering within the VectorOp dialect. PiperOrigin-RevId: 281352749
-
Nicolas Vasilache authored
In the particular case where the size of a memref dimension is 1, double printing would happen because printLast was called unconditionally. This CL fixes the print and updates an incorrect test that should have caught this in the first place. PiperOrigin-RevId: 281345142
-
Mehdi Amini authored
PiperOrigin-RevId: 281338738
-
Mehdi Amini authored
PiperOrigin-RevId: 281338448
-
Diego Caballero authored
This method is needed for N->1 conversion patterns to retrieve remapped Values used in the original N operations. Closes tensorflow/mlir#237 COPYBARA_INTEGRATE_REVIEW=https://github.com/tensorflow/mlir/pull/237 from dcaballe:dcaballe/getRemappedValue 1f64fadcf2b203f7b336ff0c5838b116ae3625db PiperOrigin-RevId: 281321881
-
Eric Schweitz authored
Closes tensorflow/mlir#245 PiperOrigin-RevId: 281321459
-
Alex Zinenko authored
The command-line flag name `lower-to-llvm` for the pass performing dialect conversion from the Standard dialect to the LLVM dialect is misleading and inconsistent with most of the conversion passses. It leads the user to believe that there are no restrictions on what can be converted, while in fact only a subset of the Standard dialect can be converted (with operations from other dialects converted by separate passes). Use `convert-std-to-llvm` that better reflects what the pass does and is consistent with most other conversions. PiperOrigin-RevId: 281238797
-
Logan Chien authored
This commit add `dialect-attribute-entry` requirements on function arguments, function results, and function attributes to the documentation. PiperOrigin-RevId: 281227740
-
Manuel Freiberger authored
The toy language uses element-wise multiplication. Transposing and multiplying two tensors with shape <2, 3> gives a tensor with shape <3, 2>. Closes tensorflow/mlir#227 COPYBARA_INTEGRATE_REVIEW=https://github.com/tensorflow/mlir/pull/227 from ombre5733:toy-ch1-docu-fix d79e5d3f9e3d5150a7ac8aac28b899df5a0d10a0 PiperOrigin-RevId: 281221671
-
Hanhan Wang authored
Iterates each element to build the array. This includes a little refactor to combine bool/int/float into a function, since they are similar. The only difference is calling different function in the end. PiperOrigin-RevId: 281210288
-
Tian Jin authored
Closes tensorflow/mlir#247 PiperOrigin-RevId: 281185661
-
Alexander Belyaev authored
PiperOrigin-RevId: 281169885
-
Uday Bondhugula authored
Closes tensorflow/mlir#243 COPYBARA_INTEGRATE_REVIEW=https://github.com/tensorflow/mlir/pull/243 from bondhugula:patch-2 fb682996efde001189414a4c7aa59ce42ace7831 PiperOrigin-RevId: 281167834
-
Andy Davis authored
Adds unit tests for subview offset and stride argument constant folding. PiperOrigin-RevId: 281161041
-
- Nov 18, 2019
-
-
River Riddle authored
The variant that accepts a type will check that the parsed attribute is a valid instance of AttrType. The non-type variant would silently fail in this case, leading to garbage attribute values. PiperOrigin-RevId: 281136528
-
Lei Zhang authored
PiperOrigin-RevId: 281131561
-
Denis Khalikov authored
Convert chained `spirv::BitcastOp` operations into one `spirv::BitcastOp` operation. Closes tensorflow/mlir#238 COPYBARA_INTEGRATE_REVIEW=https://github.com/tensorflow/mlir/pull/238 from denis0x0D:sandbox/canon_bitcast 4352ed4f81b959ec92f849c599e733b62a99c010 PiperOrigin-RevId: 281129234
-
Jing Pu authored
PiperOrigin-RevId: 281114034
-
Alex Zinenko authored
The assertion was introduced in the early days of dialect conversion infrastructure when we had the matching function separate from the rewriting function. The infrastructure evolved to have a common matchAndRewrite function and the separate matching function was dropped without chaning the rewriting that became matchAndRewrite. This has led to assertion being triggered. Return a matchFailure instead of failing an assertion on unsupported types. Closes tensorflow/mlir#230 PiperOrigin-RevId: 281113741
-
Andy Davis authored
This CL utilizies the more robust fusion feasibility analysis being built out in LoopFusionUtils, which will eventually be used to replace the current affine loop fusion pass. PiperOrigin-RevId: 281112340
-
Nicolas Vasilache authored
This improves consistency and will concretely avoid collisions between VectorExtractElementOp and ExtractElementOp when they are included in the same transforms / rewrites. PiperOrigin-RevId: 281101588
-
Stephan Herhut authored
PiperOrigin-RevId: 281042016
-
Alex Zinenko authored
This makes the flags consistent with the naming scheme used elsewhere in the codebase for dialect conversions. PiperOrigin-RevId: 281027517
-
- Nov 17, 2019
-
-
Jacques Pienaar authored
PiperOrigin-RevId: 280888290
-
- Nov 15, 2019
-
-
Logan Chien authored
This commit fixes several attribute dict syntax errors in the documentation. PiperOrigin-RevId: 280726269
-
Denis Khalikov authored
This CL added op definitions for a few bit operations: * OpBitFieldInsert * OpBitFieldSExtract * OpBitFieldUExtract Closes tensorflow/mlir#233 COPYBARA_INTEGRATE_REVIEW=https://github.com/tensorflow/mlir/pull/233 from denis0x0D:sandbox/bit_field_ops e7fd85b00d72d483d7992dc42b9cc4d673903455 PiperOrigin-RevId: 280691816
-