junrushao1994 opened a new pull request #5685: URL: https://github.com/apache/incubator-tvm/pull/5685
This is a pretty long discussion [thread](https://discuss.tvm.ai/t/python-debugger-segfaults-with-tvm/843/9?u=junrushao1994). We are finally able to narrow down the root cause: when libtvm.so is linked against libLLVM.so, some versions (apt-get installed ones) of which are usually linked against libedit.so, the readline in pdb/ipdb conflicts with libedit. Two workarounds: 1) import readline before loading libtvm.so. (this PR) 2) built TVM with static LLVM, so that linkage unused in libLLVM.so are ignored. Some personal experience about installing pre-built LLVM: [clangdev](https://anaconda.org/conda-forge/clangdev/files) and [llvmdev](https://anaconda.org/conda-forge/llvmdev/files) from conda-forge works best with python, and have the most comprehensive pre-built binaries. ``` conda install -c conda-forge clangdev=$VERSION ``` CC: @jwfromm @icemelon9 ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: [email protected]
