-
Notifications
You must be signed in to change notification settings - Fork 15.2k
Closed
Closed
Copy link
Labels
crashPrefer [crash-on-valid] or [crash-on-invalid]Prefer [crash-on-valid] or [crash-on-invalid]mlir:tosa

Description
git version: 0359a78
system: Ubuntu 20.04.6 LTS (Focal Fossa)
reproduced with: mlir-opt --tosa-infer-shapes a.mlir
a.mlir:
func.func nested @func2(%arg0: tensor<9xi64>) {
%7 = tensor.empty() : tensor<9xi1>
%28 = tensor.empty() : tensor<9xi1>
%29 = tosa.logical_left_shift %7, %28 : (tensor<9xi1>, tensor<9xi1>) -> tensor<9xi1>
%32 = tosa.tile %29 {multiples = array<i64>} : (tensor<9xi1>) -> tensor<9xi1>
return
}
trace:
mlir-opt: /data/bin/llvm-project/llvm/include/llvm/ADT/ArrayRef.h:257: const T& llvm::ArrayRef<T>::operator[](size_t) const [with T = long int; size_t = long unsigned int]: Assertion `Index < Length && "Invalid index!"' failed.
PLEASE submit a bug report to https://github.com/llvm/llvm-project/issues/ and include the crash backtrace.
Stack dump:
0. Program arguments: /data/bin/llvm-project/build/bin/mlir-opt --tosa-infer-shapes reduced.mlir
#0 0x000055655709ca9f llvm::sys::PrintStackTrace(llvm::raw_ostream&, int) (/data/bin/llvm-project/build/bin/mlir-opt+0x15d2a9f)
#1 0x0000556557099b34 SignalHandler(int) Signals.cpp:0:0
#2 0x00007ff274b83420 __restore_rt (/lib/x86_64-linux-gnu/libpthread.so.0+0x14420)
#3 0x00007ff27466e00b raise (/lib/x86_64-linux-gnu/libc.so.6+0x4300b)
#4 0x00007ff27464d859 abort (/lib/x86_64-linux-gnu/libc.so.6+0x22859)
#5 0x00007ff27464d729 (/lib/x86_64-linux-gnu/libc.so.6+0x22729)
#6 0x00007ff27465efd6 (/lib/x86_64-linux-gnu/libc.so.6+0x33fd6)
#7 0x0000556558dafd45 (/data/bin/llvm-project/build/bin/mlir-opt+0x32e5d45)
#8 0x0000556558e351fd mlir::tosa::TileOp::inferReturnTypeComponents(mlir::MLIRContext*, std::optional<mlir::Location>, mlir::tosa::TileOpAdaptor, llvm::SmallVectorImpl<mlir::ShapedTypeComponents>&) (/data/bin/llvm-project/build/bin/mlir-opt+0x336b1fd)
#9 0x0000556558e35461 mlir::detail::InferShapedTypeOpInterfaceInterfaceTraits::Model<mlir::tosa::TileOp>::inferReturnTypeComponents(mlir::MLIRContext*, std::optional<mlir::Location>, mlir::ValueShapeRange, mlir::DictionaryAttr, mlir::OpaqueProperties, mlir::RegionRange, llvm::SmallVectorImpl<mlir::ShapedTypeComponents>&) (/data/bin/llvm-project/build/bin/mlir-opt+0x336b461)
#10 0x0000556558e90d0a (anonymous namespace)::propagateShapesInRegion(mlir::Region&) TosaInferShapes.cpp:0:0
#11 0x0000556558e9279e (anonymous namespace)::TosaInferShapes::runOnOperation() TosaInferShapes.cpp:0:0
#12 0x0000556559bfa86e mlir::detail::OpToOpPassAdaptor::run(mlir::Pass*, mlir::Operation*, mlir::AnalysisManager, bool, unsigned int) (/data/bin/llvm-project/build/bin/mlir-opt+0x413086e)
#13 0x0000556559bfad4a mlir::detail::OpToOpPassAdaptor::runPipeline(mlir::OpPassManager&, mlir::Operation*, mlir::AnalysisManager, bool, unsigned int, mlir::PassInstrumentor*, mlir::PassInstrumentation::PipelineParentInfo const*) (/data/bin/llvm-project/build/bin/mlir-opt+0x4130d4a)
#14 0x0000556559bfb74c mlir::detail::OpToOpPassAdaptor::runOnOperationAsyncImpl(bool)::'lambda'(mlir::detail::OpToOpPassAdaptor::runOnOperationAsyncImpl(bool)::OpPMInfo&)::operator()(mlir::detail::OpToOpPassAdaptor::runOnOperationAsyncImpl(bool)::OpPMInfo&) const Pass.cpp:0:0
#15 0x0000556559bf9ea5 mlir::detail::OpToOpPassAdaptor::runOnOperationAsyncImpl(bool) (/data/bin/llvm-project/build/bin/mlir-opt+0x412fea5)
#16 0x0000556559bfa60a mlir::detail::OpToOpPassAdaptor::run(mlir::Pass*, mlir::Operation*, mlir::AnalysisManager, bool, unsigned int) (/data/bin/llvm-project/build/bin/mlir-opt+0x413060a)
#17 0x0000556559bfad4a mlir::detail::OpToOpPassAdaptor::runPipeline(mlir::OpPassManager&, mlir::Operation*, mlir::AnalysisManager, bool, unsigned int, mlir::PassInstrumentor*, mlir::PassInstrumentation::PipelineParentInfo const*) (/data/bin/llvm-project/build/bin/mlir-opt+0x4130d4a)
#18 0x0000556559bfb574 mlir::PassManager::run(mlir::Operation*) (/data/bin/llvm-project/build/bin/mlir-opt+0x4131574)
#19 0x0000556559bebe3b performActions(llvm::raw_ostream&, std::shared_ptr<llvm::SourceMgr> const&, mlir::MLIRContext*, mlir::MlirOptMainConfig const&) MlirOptMain.cpp:0:0
#20 0x0000556559bed2f4 processBuffer(llvm::raw_ostream&, std::unique_ptr<llvm::MemoryBuffer, std::default_delete<llvm::MemoryBuffer>>, mlir::MlirOptMainConfig const&, mlir::DialectRegistry&, llvm::ThreadPool*) MlirOptMain.cpp:0:0
#21 0x0000556559bed4a4 mlir::LogicalResult llvm::function_ref<mlir::LogicalResult (std::unique_ptr<llvm::MemoryBuffer, std::default_delete<llvm::MemoryBuffer>>, llvm::raw_ostream&)>::callback_fn<mlir::MlirOptMain(llvm::raw_ostream&, std::unique_ptr<llvm::MemoryBuffer, std::default_delete<llvm::MemoryBuffer>>, mlir::DialectRegistry&, mlir::MlirOptMainConfig const&)::'lambda'(std::unique_ptr<llvm::MemoryBuffer, std::default_delete<llvm::MemoryBuffer>>, llvm::raw_ostream&)>(long, std::unique_ptr<llvm::MemoryBuffer, std::default_delete<llvm::MemoryBuffer>>, llvm::raw_ostream&) MlirOptMain.cpp:0:0
#22 0x0000556559ce9eb4 mlir::splitAndProcessBuffer(std::unique_ptr<llvm::MemoryBuffer, std::default_delete<llvm::MemoryBuffer>>, llvm::function_ref<mlir::LogicalResult (std::unique_ptr<llvm::MemoryBuffer, std::default_delete<llvm::MemoryBuffer>>, llvm::raw_ostream&)>, llvm::raw_ostream&, bool, bool) (/data/bin/llvm-project/build/bin/mlir-opt+0x421feb4)
#23 0x0000556559be6777 mlir::MlirOptMain(llvm::raw_ostream&, std::unique_ptr<llvm::MemoryBuffer, std::default_delete<llvm::MemoryBuffer>>, mlir::DialectRegistry&, mlir::MlirOptMainConfig const&) (/data/bin/llvm-project/build/bin/mlir-opt+0x411c777)
#24 0x0000556559bed7cb mlir::MlirOptMain(int, char**, llvm::StringRef, mlir::DialectRegistry&) (/data/bin/llvm-project/build/bin/mlir-opt+0x41237cb)
#25 0x0000556556fd4b8b main (/data/bin/llvm-project/build/bin/mlir-opt+0x150ab8b)
#26 0x00007ff27464f083 __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x24083)
#27 0x000055655706d33e _start (/data/bin/llvm-project/build/bin/mlir-opt+0x15a333e)
Aborted (core dumped)
Metadata
Metadata
Assignees
Labels
crashPrefer [crash-on-valid] or [crash-on-invalid]Prefer [crash-on-valid] or [crash-on-invalid]mlir:tosa