Skip to content

Instantly share code, notes, and snippets.

@renxida
Created May 16, 2024 19:24
Show Gist options
  • Save renxida/3e5bb069e83a3cfe4137e3709d5cc989 to your computer and use it in GitHub Desktop.
Save renxida/3e5bb069e83a3cfe4137e3709d5cc989 to your computer and use it in GitHub Desktop.
/home/azureuser/iree-build/tools/iree-compile: /home/azureuser/miniconda/lib/libtinfo.so.6: no version information available (required by /home/azureuser/iree-build/lib/libIREECompiler.so)
deit-small-distilled-patch16-224.default.pytorch.torch.mlir:1029:12: error: failed to legalize operation 'torch.aten.squeeze' that was explicitly marked illegal
%999 = torch.aten.squeeze %998 : !torch.vtensor<[1,1,384],f32> -> !torch.vtensor<[1,384],f32>
^
deit-small-distilled-patch16-224.default.pytorch.torch.mlir:1029:12: note: see current operation: %13245 = "torch.aten.squeeze"(%13244) : (!torch.vtensor<[1,1,384],f32>) -> !torch.vtensor<[1,384],f32>
iree-compile: /home/azureuser/iree/third_party/llvm-project/mlir/include/mlir/IR/UseDefLists.h:198: mlir::IRObjectWithUseList<mlir::OpOperand>::~IRObjectWithUseList() [OperandType = mlir::OpOperand]: Assertion `use_empty() && "Cannot destroy a value that still has uses!"' failed.
Please report issues to https://github.com/openxla/iree/issues and include the crash backtrace.
Stack dump:
0. Program arguments: /home/azureuser/iree-build/tools/iree-compile --iree-input-demote-i64-to-i32 --iree-hal-target-backends=llvm-cpu deit-small-distilled-patch16-224.default.pytorch.torch.mlir
#0 0x00007f8766a1c2f7 llvm::sys::PrintStackTrace(llvm::raw_ostream&, int) /home/azureuser/iree/third_party/llvm-project/llvm/lib/Support/Unix/Signals.inc:723:13
#1 0x00007f8766a1a520 llvm::sys::RunSignalHandlers() /home/azureuser/iree/third_party/llvm-project/llvm/lib/Support/Signals.cpp:106:18
#2 0x00007f8766a1c9aa SignalHandler(int) /home/azureuser/iree/third_party/llvm-project/llvm/lib/Support/Unix/Signals.inc:413:1
#3 0x00007f876003c460 (/lib/x86_64-linux-gnu/libc.so.6+0x3c460)
#4 0x00007f876009152b pthread_kill (/lib/x86_64-linux-gnu/libc.so.6+0x9152b)
#5 0x00007f876003c3b6 raise (/lib/x86_64-linux-gnu/libc.so.6+0x3c3b6)
#6 0x00007f876002287c abort (/lib/x86_64-linux-gnu/libc.so.6+0x2287c)
#7 0x00007f876002279b (/lib/x86_64-linux-gnu/libc.so.6+0x2279b)
#8 0x00007f8760033b66 (/lib/x86_64-linux-gnu/libc.so.6+0x33b66)
#9 0x00007f8766a6715f mlir::IRObjectWithUseList<mlir::BlockOperand>::~IRObjectWithUseList() /home/azureuser/iree/third_party/llvm-project/mlir/include/mlir/IR/UseDefLists.h:198:5
#10 0x00007f8766a6715f mlir::Block::~Block() /home/azureuser/iree/third_party/llvm-project/mlir/lib/IR/Block.cpp:24:1
#11 0x00007f876a05af99 (anonymous namespace)::CreateBlockRewrite::rollback() /home/azureuser/iree/third_party/llvm-project/mlir/lib/Transforms/Utils/DialectConversion.cpp:286:7
#12 0x00007f876a045cfb bool std::operator==<std::unique_ptr<(anonymous namespace)::IRRewrite, std::default_delete<(anonymous namespace)::IRRewrite>>*>(std::reverse_iterator<std::unique_ptr<(anonymous namespace)::IRRewrite, std::default_delete<(anonymous namespace)::IRRewrite>>*> const&, std::reverse_iterator<std::unique_ptr<(anonymous namespace)::IRRewrite, std::default_delete<(anonymous namespace)::IRRewrite>>*> const&) /usr/bin/../lib/gcc/x86_64-linux-gnu/12/../../../../include/c++/12/bits/stl_iterator.h:446:25
#13 0x00007f876a045cfb bool std::operator!=<std::unique_ptr<(anonymous namespace)::IRRewrite, std::default_delete<(anonymous namespace)::IRRewrite>>*>(std::reverse_iterator<std::unique_ptr<(anonymous namespace)::IRRewrite, std::default_delete<(anonymous namespace)::IRRewrite>>*> const&, std::reverse_iterator<std::unique_ptr<(anonymous namespace)::IRRewrite, std::default_delete<(anonymous namespace)::IRRewrite>>*> const&) /usr/bin/../lib/gcc/x86_64-linux-gnu/12/../../../../include/c++/12/bits/stl_iterator.h:460:20
#14 0x00007f876a045cfb mlir::detail::ConversionPatternRewriterImpl::undoRewrites(unsigned int) /home/azureuser/iree/third_party/llvm-project/mlir/lib/Transforms/Utils/DialectConversion.cpp:1224:22
#15 0x00007f876a04bd73 mlir::OperationConverter::convertOperations(llvm::ArrayRef<mlir::Operation*>) /home/azureuser/iree/third_party/llvm-project/mlir/lib/Transforms/Utils/DialectConversion.cpp:0:18
#16 0x00007f876a0529cb mlir::applyPartialConversion(llvm::ArrayRef<mlir::Operation*>, mlir::ConversionTarget const&, mlir::FrozenRewritePatternSet const&, mlir::ConversionConfig) /home/azureuser/iree/third_party/llvm-project/mlir/lib/Transforms/Utils/DialectConversion.cpp:3610:22
#17 0x00007f876a0529cb mlir::applyPartialConversion(mlir::Operation*, mlir::ConversionTarget const&, mlir::FrozenRewritePatternSet const&, mlir::ConversionConfig) /home/azureuser/iree/third_party/llvm-project/mlir/lib/Transforms/Utils/DialectConversion.cpp:3616:10
#18 0x00007f87674bb586 (anonymous namespace)::ConvertTorchToLinalg::runOnOperation() /home/azureuser/iree/third_party/torch-mlir/lib/Conversion/TorchToLinalg/TorchToLinalg.cpp:87:16
#19 0x00007f8766bae14f mlir::detail::OpToOpPassAdaptor::run(mlir::Pass*, mlir::Operation*, mlir::AnalysisManager, bool, unsigned int)::$_7::operator()() const /home/azureuser/iree/third_party/llvm-project/mlir/lib/Pass/Pass.cpp:0:17
#20 0x00007f8766bae14f void llvm::function_ref<void ()>::callback_fn<mlir::detail::OpToOpPassAdaptor::run(mlir::Pass*, mlir::Operation*, mlir::AnalysisManager, bool, unsigned int)::$_7>(long) /home/azureuser/iree/third_party/llvm-project/llvm/include/llvm/ADT/STLFunctionalExtras.h:45:12
#21 0x00007f8766bae14f llvm::function_ref<void ()>::operator()() const /home/azureuser/iree/third_party/llvm-project/llvm/include/llvm/ADT/STLFunctionalExtras.h:68:12
#22 0x00007f8766bae14f void mlir::MLIRContext::executeAction<mlir::PassExecutionAction, mlir::Pass&>(llvm::function_ref<void ()>, llvm::ArrayRef<mlir::IRUnit>, mlir::Pass&) /home/azureuser/iree/third_party/llvm-project/mlir/include/mlir/IR/MLIRContext.h:275:7
#23 0x00007f8766bae14f mlir::detail::OpToOpPassAdaptor::run(mlir::Pass*, mlir::Operation*, mlir::AnalysisManager, bool, unsigned int) /home/azureuser/iree/third_party/llvm-project/mlir/lib/Pass/Pass.cpp:513:21
#24 0x00007f8766bae8c8 mlir::LogicalResult::failed() const /home/azureuser/iree/third_party/llvm-project/mlir/include/mlir/Support/LogicalResult.h:44:33
#25 0x00007f8766bae8c8 mlir::failed(mlir::LogicalResult) /home/azureuser/iree/third_party/llvm-project/mlir/include/mlir/Support/LogicalResult.h:72:58
#26 0x00007f8766bae8c8 mlir::detail::OpToOpPassAdaptor::runPipeline(mlir::OpPassManager&, mlir::Operation*, mlir::AnalysisManager, bool, unsigned int, mlir::PassInstrumentor*, mlir::PassInstrumentation::PipelineParentInfo const*) /home/azureuser/iree/third_party/llvm-project/mlir/lib/Pass/Pass.cpp:585:9
#27 0x00007f8766bb3d6e mlir::detail::OpToOpPassAdaptor::runOnOperationAsyncImpl(bool)::$_15::operator()(mlir::detail::OpToOpPassAdaptor::runOnOperationAsyncImpl(bool)::OpPMInfo&) const /home/azureuser/iree/third_party/llvm-project/mlir/lib/Pass/Pass.cpp:810:5
#28 0x00007f8766bafe4b mlir::LogicalResult::failed() const /home/azureuser/iree/third_party/llvm-project/mlir/include/mlir/Support/LogicalResult.h:44:33
#29 0x00007f8766bafe4b mlir::failed(mlir::LogicalResult) /home/azureuser/iree/third_party/llvm-project/mlir/include/mlir/Support/LogicalResult.h:72:58
#30 0x00007f8766bafe4b mlir::LogicalResult mlir::failableParallelForEach<__gnu_cxx::__normal_iterator<mlir::detail::OpToOpPassAdaptor::runOnOperationAsyncImpl(bool)::OpPMInfo*, std::vector<mlir::detail::OpToOpPassAdaptor::runOnOperationAsyncImpl(bool)::OpPMInfo, std::allocator<mlir::detail::OpToOpPassAdaptor::runOnOperationAsyncImpl(bool)::OpPMInfo>>>, mlir::detail::OpToOpPassAdaptor::runOnOperationAsyncImpl(bool)::$_15&>(mlir::MLIRContext*, __gnu_cxx::__normal_iterator<mlir::detail::OpToOpPassAdaptor::runOnOperationAsyncImpl(bool)::OpPMInfo*, std::vector<mlir::detail::OpToOpPassAdaptor::runOnOperationAsyncImpl(bool)::OpPMInfo, std::allocator<mlir::detail::OpToOpPassAdaptor::runOnOperationAsyncImpl(bool)::OpPMInfo>>>, __gnu_cxx::__normal_iterator<mlir::detail::OpToOpPassAdaptor::runOnOperationAsyncImpl(bool)::OpPMInfo*, std::vector<mlir::detail::OpToOpPassAdaptor::runOnOperationAsyncImpl(bool)::OpPMInfo, std::allocator<mlir::detail::OpToOpPassAdaptor::runOnOperationAsyncImpl(bool)::OpPMInfo>>>, mlir::detail::OpToOpPassAdaptor::runOnOperationAsyncImpl(bool)::$_15&) /home/azureuser/iree/third_party/llvm-project/mlir/include/mlir/IR/Threading.h:46:11
#31 0x00007f8766bafe4b mlir::LogicalResult mlir::failableParallelForEach<std::vector<mlir::detail::OpToOpPassAdaptor::runOnOperationAsyncImpl(bool)::OpPMInfo, std::allocator<mlir::detail::OpToOpPassAdaptor::runOnOperationAsyncImpl(bool)::OpPMInfo>>&, mlir::detail::OpToOpPassAdaptor::runOnOperationAsyncImpl(bool)::$_15&>(mlir::MLIRContext*, std::vector<mlir::detail::OpToOpPassAdaptor::runOnOperationAsyncImpl(bool)::OpPMInfo, std::allocator<mlir::detail::OpToOpPassAdaptor::runOnOperationAsyncImpl(bool)::OpPMInfo>>&, mlir::detail::OpToOpPassAdaptor::runOnOperationAsyncImpl(bool)::$_15&) /home/azureuser/iree/third_party/llvm-project/mlir/include/mlir/IR/Threading.h:92:10
#32 0x00007f8766bafe4b mlir::detail::OpToOpPassAdaptor::runOnOperationAsyncImpl(bool) /home/azureuser/iree/third_party/llvm-project/mlir/lib/Pass/Pass.cpp:815:14
#33 0x00007f8766bae2ea mlir::detail::OpToOpPassAdaptor::runOnOperation(bool) /home/azureuser/iree/third_party/llvm-project/mlir/lib/Pass/Pass.cpp:0:5
#34 0x00007f8766bae2ea mlir::detail::OpToOpPassAdaptor::run(mlir::Pass*, mlir::Operation*, mlir::AnalysisManager, bool, unsigned int)::$_7::operator()() const /home/azureuser/iree/third_party/llvm-project/mlir/lib/Pass/Pass.cpp:517:20
#35 0x00007f8766bae2ea void llvm::function_ref<void ()>::callback_fn<mlir::detail::OpToOpPassAdaptor::run(mlir::Pass*, mlir::Operation*, mlir::AnalysisManager, bool, unsigned int)::$_7>(long) /home/azureuser/iree/third_party/llvm-project/llvm/include/llvm/ADT/STLFunctionalExtras.h:45:12
#36 0x00007f8766bae2ea llvm::function_ref<void ()>::operator()() const /home/azureuser/iree/third_party/llvm-project/llvm/include/llvm/ADT/STLFunctionalExtras.h:68:12
#37 0x00007f8766bae2ea void mlir::MLIRContext::executeAction<mlir::PassExecutionAction, mlir::Pass&>(llvm::function_ref<void ()>, llvm::ArrayRef<mlir::IRUnit>, mlir::Pass&) /home/azureuser/iree/third_party/llvm-project/mlir/include/mlir/IR/MLIRContext.h:275:7
#38 0x00007f8766bae2ea mlir::detail::OpToOpPassAdaptor::run(mlir::Pass*, mlir::Operation*, mlir::AnalysisManager, bool, unsigned int) /home/azureuser/iree/third_party/llvm-project/mlir/lib/Pass/Pass.cpp:513:21
#39 0x00007f8766bae8c8 mlir::LogicalResult::failed() const /home/azureuser/iree/third_party/llvm-project/mlir/include/mlir/Support/LogicalResult.h:44:33
#40 0x00007f8766bae8c8 mlir::failed(mlir::LogicalResult) /home/azureuser/iree/third_party/llvm-project/mlir/include/mlir/Support/LogicalResult.h:72:58
#41 0x00007f8766bae8c8 mlir::detail::OpToOpPassAdaptor::runPipeline(mlir::OpPassManager&, mlir::Operation*, mlir::AnalysisManager, bool, unsigned int, mlir::PassInstrumentor*, mlir::PassInstrumentation::PipelineParentInfo const*) /home/azureuser/iree/third_party/llvm-project/mlir/lib/Pass/Pass.cpp:585:9
#42 0x00007f8766bb3071 mlir::LogicalResult llvm::function_ref<mlir::LogicalResult (mlir::OpPassManager&, mlir::Operation*)>::callback_fn<mlir::detail::OpToOpPassAdaptor::run(mlir::Pass*, mlir::Operation*, mlir::AnalysisManager, bool, unsigned int)::$_6>(long, mlir::OpPassManager&, mlir::Operation*) /home/azureuser/iree/third_party/llvm-project/llvm/include/llvm/ADT/STLFunctionalExtras.h:45:5
#43 0x00007f8767c73284 mlir::LogicalResult::failed() const /home/azureuser/iree/third_party/llvm-project/mlir/include/mlir/Support/LogicalResult.h:44:33
#44 0x00007f8767c73284 mlir::failed(mlir::LogicalResult) /home/azureuser/iree/third_party/llvm-project/mlir/include/mlir/Support/LogicalResult.h:72:58
#45 0x00007f8767c73284 mlir::iree_compiler::(anonymous namespace)::AutoInputConversionPipelinePass::runOnOperation() /home/azureuser/iree/compiler/src/iree/compiler/InputConversion/Common/AutoInputConversionPipeline.cpp:64:7
#46 0x00007f8766bae14f mlir::detail::OpToOpPassAdaptor::run(mlir::Pass*, mlir::Operation*, mlir::AnalysisManager, bool, unsigned int)::$_7::operator()() const /home/azureuser/iree/third_party/llvm-project/mlir/lib/Pass/Pass.cpp:0:17
#47 0x00007f8766bae14f void llvm::function_ref<void ()>::callback_fn<mlir::detail::OpToOpPassAdaptor::run(mlir::Pass*, mlir::Operation*, mlir::AnalysisManager, bool, unsigned int)::$_7>(long) /home/azureuser/iree/third_party/llvm-project/llvm/include/llvm/ADT/STLFunctionalExtras.h:45:12
#48 0x00007f8766bae14f llvm::function_ref<void ()>::operator()() const /home/azureuser/iree/third_party/llvm-project/llvm/include/llvm/ADT/STLFunctionalExtras.h:68:12
#49 0x00007f8766bae14f void mlir::MLIRContext::executeAction<mlir::PassExecutionAction, mlir::Pass&>(llvm::function_ref<void ()>, llvm::ArrayRef<mlir::IRUnit>, mlir::Pass&) /home/azureuser/iree/third_party/llvm-project/mlir/include/mlir/IR/MLIRContext.h:275:7
#50 0x00007f8766bae14f mlir::detail::OpToOpPassAdaptor::run(mlir::Pass*, mlir::Operation*, mlir::AnalysisManager, bool, unsigned int) /home/azureuser/iree/third_party/llvm-project/mlir/lib/Pass/Pass.cpp:513:21
#51 0x00007f8766bae8c8 mlir::LogicalResult::failed() const /home/azureuser/iree/third_party/llvm-project/mlir/include/mlir/Support/LogicalResult.h:44:33
#52 0x00007f8766bae8c8 mlir::failed(mlir::LogicalResult) /home/azureuser/iree/third_party/llvm-project/mlir/include/mlir/Support/LogicalResult.h:72:58
#53 0x00007f8766bae8c8 mlir::detail::OpToOpPassAdaptor::runPipeline(mlir::OpPassManager&, mlir::Operation*, mlir::AnalysisManager, bool, unsigned int, mlir::PassInstrumentor*, mlir::PassInstrumentation::PipelineParentInfo const*) /home/azureuser/iree/third_party/llvm-project/mlir/lib/Pass/Pass.cpp:585:9
#54 0x00007f8766bb0cc9 mlir::PassManager::run(mlir::Operation*) /home/azureuser/iree/third_party/llvm-project/mlir/lib/Pass/Pass.cpp:0:0
#55 0x00007f8766973dd7 mlir::LogicalResult::failed() const /home/azureuser/iree/third_party/llvm-project/mlir/include/mlir/Support/LogicalResult.h:44:33
#56 0x00007f8766973dd7 mlir::failed(mlir::LogicalResult) /home/azureuser/iree/third_party/llvm-project/mlir/include/mlir/Support/LogicalResult.h:72:58
#57 0x00007f8766973dd7 mlir::iree_compiler::embed::(anonymous namespace)::Invocation::runPipeline(iree_compiler_pipeline_t) /home/azureuser/iree/compiler/src/iree/compiler/API/Internal/CompilerDriver.cpp:961:7
#58 0x00007f8766973dd7 ireeCompilerInvocationPipeline /home/azureuser/iree/compiler/src/iree/compiler/API/Internal/CompilerDriver.cpp:1391:23
#59 0x00007f8766b77685 mlir::iree_compiler::runIreecMain(int, char**)::$_2::operator()(iree_compiler_source_t*) const /home/azureuser/iree/compiler/src/iree/compiler/Tools/iree_compile_lib.cc:247:11
#60 0x00007f8766b76f1a mlir::iree_compiler::runIreecMain(int, char**) /home/azureuser/iree/compiler/src/iree/compiler/Tools/iree_compile_lib.cc:0:10
#61 0x00007f8760023a90 (/lib/x86_64-linux-gnu/libc.so.6+0x23a90)
#62 0x00007f8760023b49 __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x23b49)
#63 0x00005608084bf6f5 _start (/home/azureuser/iree-build/tools/iree-compile+0x16f5)
Aborted (core dumped)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment