[PATCH] D76726: Allow IndexType inside tensors.
Sean Silva via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Mar 24 12:54:34 PDT 2020
silvas updated this revision to Diff 252410.
silvas added a comment.
Fix extraneous stuff in the diff
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D76726/new/
https://reviews.llvm.org/D76726
Files:
mlir/include/mlir/IR/StandardTypes.h
mlir/test/IR/invalid.mlir
Index: mlir/test/IR/invalid.mlir
===================================================================
--- mlir/test/IR/invalid.mlir
+++ mlir/test/IR/invalid.mlir
@@ -23,10 +23,6 @@
func @indexmemref(memref<? x index>) -> () // expected-error {{invalid memref element type}}
-// -----
-
-func @indextensor(tensor<4 x index>) -> () // expected-error {{invalid tensor element type}}
-
// -----
// Test no map in memref type.
func @memrefs(memref<2x4xi8, >) // expected-error {{expected list element}}
Index: mlir/include/mlir/IR/StandardTypes.h
===================================================================
--- mlir/include/mlir/IR/StandardTypes.h
+++ mlir/include/mlir/IR/StandardTypes.h
@@ -330,7 +330,7 @@
// element type within that dialect.
return type.isa<ComplexType>() || type.isa<FloatType>() ||
type.isa<IntegerType>() || type.isa<OpaqueType>() ||
- type.isa<VectorType>() ||
+ type.isa<VectorType>() || type.isa<IndexType>() ||
(type.getKind() > Type::Kind::LAST_STANDARD_TYPE);
}
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D76726.252410.patch
Type: text/x-patch
Size: 1061 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200324/37721a1e/attachment.bin>
More information about the llvm-commits
mailing list