Skip to content

Instantly share code, notes, and snippets.

@modocache
Created April 28, 2020 17:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save modocache/37aeef91b383531a9c067aabd8de213e to your computer and use it in GitHub Desktop.
Save modocache/37aeef91b383531a9c067aabd8de213e to your computer and use it in GitHub Desktop.
diff --git a/mlir/lib/IR/StandardTypes.cpp b/mlir/lib/IR/StandardTypes.cpp
index c61e1d9e2ab..c14d786d3e5 100644
--- a/mlir/lib/IR/StandardTypes.cpp
+++ b/mlir/lib/IR/StandardTypes.cpp
@@ -377,12 +377,6 @@ MemRefType MemRefType::getImpl(ArrayRef<int64_t> shape, Type elementType,
Optional<Location> location) {
auto *context = elementType.getContext();
- // Check that memref is formed from allowed types.
- if (!elementType.isIntOrFloat() && !elementType.isa<VectorType>() &&
- !elementType.isa<ComplexType>())
- return emitOptionalError(location, "invalid memref element type"),
- MemRefType();
-
for (int64_t s : shape) {
// Negative sizes are not allowed except for `-1` that means dynamic size.
if (s < -1)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment