https://llvm.org/bugs/show_bug.cgi?id=24953
Bug ID: 24953 Summary: Unusable with LLVM_LINK_LLVM_DYLIB=ON Product: lldb Version: 3.7 Hardware: PC OS: Linux Status: NEW Severity: normal Priority: P Component: All Bugs Assignee: lldb-dev@lists.llvm.org Reporter: evange...@foutrelis.com CC: llvm-b...@lists.llvm.org Classification: Unclassified Created attachment 14941 --> https://llvm.org/bugs/attachment.cgi?id=14941&action=edit GDB backtrace The following is with LLVM/LLDB 3.7.0 with the LLVM_LINK_LLVM_DYLIB CMake option backported and enabled. (The issue is reproducible on /trunk as well.) Attempting to run a program under lldb results in a segfault as soon as the 'run' command is given. The crash occurs when AssemblyParse_x86::instruction_length() calls LLVMDisasmInstruction() with a NULL LLVMDisasmContextRef pointer (m_disasm_context). m_disasm_context is initialized in AssemblyParse_x86's constructor to the pointer returned by LLVMCreateDisasm(). The latter returns a nullptr because TargetRegistry::lookupTarget() fails to find the target (x86_64-unknown-linux-gnu) in the registry. The actual error reads "Unable to find target for this triple (no targets are registered)". Attached is a backtrace that shows where lldb crashes. Note that specifying LLVM_LINK_LLVM_DYLIB=OFF (which I believe makes lldb link statically to LLVM) results in a working LLDB. -- You are receiving this mail because: You are the assignee for the bug.
_______________________________________________ lldb-dev mailing list lldb-dev@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-dev