-
Notifications
You must be signed in to change notification settings - Fork 15.2k
Open
Labels
crashPrefer [crash-on-valid] or [crash-on-invalid]Prefer [crash-on-valid] or [crash-on-invalid]mlir:affine
Description
MLIR built at commit 585cbe3
Reproduced with:
mlir-opt -lower-affine temp.mlir
temp.mlir:
%170 = affine.parallel (%arg3, %arg4) = (0, 0) to (11, 6) reduce ("assign") -> (memref<11x6xf32>) {
%alloc_39 = memref.alloc() : memref<11x6xf32>
affine.yield %alloc_39 : memref<11x6xf32>
}
trace:
temp.mlir:1:14: error: Reduction operation type not supported
%170 = affine.parallel (%arg3, %arg4) = (0, 0) to (11, 6) reduce ("assign") -> (memref<11x6xf32>) {
^
LLVM ERROR: Failed to infer result type(s).
PLEASE submit a bug report to https://github.com/llvm/llvm-project/issues/ and include the crash backtrace.
Stack dump:
0. Program arguments: mlir-opt -lower-affine temp.mlir
#0 0x0000000104710f18 llvm::sys::PrintStackTrace(llvm::raw_ostream&, int) (/workspace/build/bin/mlir-opt+0x1002f8f18)
#1 0x000000010470f1b4 llvm::sys::RunSignalHandlers() (/workspace/build/bin/mlir-opt+0x1002f71b4)
#2 0x00000001047115c4 SignalHandler(int) (/workspace/build/bin/mlir-opt+0x1002f95c4)
#3 0x00000001be7894c4 (/usr/lib/system/libsystem_platform.dylib+0x1803414c4)
#4 0x00000001be771ee0 (/usr/lib/system/libsystem_pthread.dylib+0x180329ee0)
#5 0x00000001be6ac340 (/usr/lib/system/libsystem_c.dylib+0x180264340)
#6 0x000000010467bd74 llvm::report_fatal_error(llvm::Twine const&, bool) (/workspace/build/bin/mlir-opt+0x100263d74)
#7 0x000000010467bba0 llvm::report_fatal_error(llvm::Twine const&, bool) (/workspace/build/bin/mlir-opt+0x100263ba0)
#8 0x00000001048adb28 mlir::arith::ConstantOp::build(mlir::OpBuilder&, mlir::OperationState&, mlir::TypedAttr) (/workspace/build/bin/mlir-opt+0x100495b28)
#9 0x00000001051a347c mlir::arith::ConstantOp mlir::OpBuilder::create<mlir::arith::ConstantOp, mlir::TypedAttr&>(mlir::Location, mlir::TypedAttr&) (/workspace/build/bin/mlir-opt+0x100d8b47c)
#10 0x000000010489e924 mlir::arith::getIdentityValue(mlir::arith::AtomicRMWKind, mlir::Type, mlir::OpBuilder&, mlir::Location) (/workspace/build/bin/mlir-opt+0x100486924)
#11 0x0000000106529534 (anonymous namespace)::AffineParallelLowering::matchAndRewrite(mlir::affine::AffineParallelOp, mlir::PatternRewriter&) const (/workspace/build/bin/mlir-opt+0x102111534)
#12 0x00000001083930f0 mlir::PatternApplicator::matchAndRewrite(mlir::Operation*, mlir::PatternRewriter&, llvm::function_ref<bool (mlir::Pattern const&)>, llvm::function_ref<void (mlir::Pattern const&)>, llvm::function_ref<mlir::LogicalResult (mlir::Pattern const&)>)::$_2::operator()() const (/workspace/build/bin/mlir-opt+0x103f7b0f0)
#13 0x00000001083903ec mlir::PatternApplicator::matchAndRewrite(mlir::Operation*, mlir::PatternRewriter&, llvm::function_ref<bool (mlir::Pattern const&)>, llvm::function_ref<void (mlir::Pattern const&)>, llvm::function_ref<mlir::LogicalResult (mlir::Pattern const&)>) (/workspace/build/bin/mlir-opt+0x103f783ec)
#14 0x0000000106db0c5c (anonymous namespace)::OperationLegalizer::legalize(mlir::Operation*, mlir::ConversionPatternRewriter&) (/workspace/build/bin/mlir-opt+0x102998c5c)
#15 0x0000000106da915c (anonymous namespace)::OperationConverter::convertOperations(llvm::ArrayRef<mlir::Operation*>, llvm::function_ref<void (mlir::Diagnostic&)>) (/workspace/build/bin/mlir-opt+0x10299115c)
#16 0x0000000106dab2a4 mlir::applyPartialConversion(mlir::Operation*, mlir::ConversionTarget&, mlir::FrozenRewritePatternSet const&, llvm::DenseSet<mlir::Operation*, llvm::DenseMapInfo<mlir::Operation*, void>>*) (/workspace/build/bin/mlir-opt+0x1029932a4)
#17 0x000000010652ecf4 (anonymous namespace)::LowerAffinePass::runOnOperation() (/workspace/build/bin/mlir-opt+0x102116cf4)
#18 0x0000000106d602a8 mlir::detail::OpToOpPassAdaptor::run(mlir::Pass*, mlir::Operation*, mlir::AnalysisManager, bool, unsigned int) (/workspace/build/bin/mlir-opt+0x1029482a8)
#19 0x0000000106d60998 mlir::detail::OpToOpPassAdaptor::runPipeline(mlir::OpPassManager&, mlir::Operation*, mlir::AnalysisManager, bool, unsigned int, mlir::PassInstrumentor*, mlir::PassInstrumentation::PipelineParentInfo const*) (/workspace/build/bin/mlir-opt+0x102948998)
#20 0x0000000106d6282c mlir::PassManager::run(mlir::Operation*) (/workspace/build/bin/mlir-opt+0x10294a82c)
#21 0x0000000106d5ad14 performActions(llvm::raw_ostream&, std::__1::shared_ptr<llvm::SourceMgr> const&, mlir::MLIRContext*, mlir::MlirOptMainConfig const&) (/workspace/build/bin/mlir-opt+0x102942d14)
#22 0x0000000106d5a368 mlir::LogicalResult llvm::function_ref<mlir::LogicalResult (std::__1::unique_ptr<llvm::MemoryBuffer, std::__1::default_delete<llvm::MemoryBuffer>>, llvm::raw_ostream&)>::callback_fn<mlir::MlirOptMain(llvm::raw_ostream&, std::__1::unique_ptr<llvm::MemoryBuffer, std::__1::default_delete<llvm::MemoryBuffer>>, mlir::DialectRegistry&, mlir::MlirOptMainConfig const&)::$_1>(long, std::__1::unique_ptr<llvm::MemoryBuffer, std::__1::default_delete<llvm::MemoryBuffer>>, llvm::raw_ostream&) (/workspace/build/bin/mlir-opt+0x102942368)
#23 0x0000000106dd834c mlir::splitAndProcessBuffer(std::__1::unique_ptr<llvm::MemoryBuffer, std::__1::default_delete<llvm::MemoryBuffer>>, llvm::function_ref<mlir::LogicalResult (std::__1::unique_ptr<llvm::MemoryBuffer, std::__1::default_delete<llvm::MemoryBuffer>>, llvm::raw_ostream&)>, llvm::raw_ostream&, bool, bool) (/workspace/build/bin/mlir-opt+0x1029c034c)
#24 0x0000000106d54d1c mlir::MlirOptMain(llvm::raw_ostream&, std::__1::unique_ptr<llvm::MemoryBuffer, std::__1::default_delete<llvm::MemoryBuffer>>, mlir::DialectRegistry&, mlir::MlirOptMainConfig const&) (/workspace/build/bin/mlir-opt+0x10293cd1c)
#25 0x0000000106d5518c mlir::MlirOptMain(int, char**, llvm::StringRef, mlir::DialectRegistry&) (/workspace/build/bin/mlir-opt+0x10293d18c)
#26 0x000000010441b510 main (/workspace/build/bin/mlir-opt+0x100003510)
#27 0x000000010faa5088
Metadata
Metadata
Assignees
Labels
crashPrefer [crash-on-valid] or [crash-on-invalid]Prefer [crash-on-valid] or [crash-on-invalid]mlir:affine