Date: Tue, 17 Feb 2015 18:33:18 +0000 (UTC) From: Ed Maste <emaste@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r278909 - head/contrib/llvm/tools/lldb/source/Plugins/ObjectFile/ELF Message-ID: <201502171833.t1HIXI6q064214@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: emaste Date: Tue Feb 17 18:33:17 2015 New Revision: 278909 URL: https://svnweb.freebsd.org/changeset/base/278909 Log: lldb: workaround to permit cross-arch core file debugging FreeBSD core files have no section table and thus LLDB's OS and vendor detection logic does not work. If we encounter such an ELF file, update an unknown OS to match the host. This is not really the correct way to handle this, but more extensive rework of ObjectFileELF will be needed and this change restores cross- arch core debugging until that can be completed. Modified: head/contrib/llvm/tools/lldb/source/Plugins/ObjectFile/ELF/ObjectFileELF.cpp Modified: head/contrib/llvm/tools/lldb/source/Plugins/ObjectFile/ELF/ObjectFileELF.cpp ============================================================================== --- head/contrib/llvm/tools/lldb/source/Plugins/ObjectFile/ELF/ObjectFileELF.cpp Tue Feb 17 18:10:46 2015 (r278908) +++ head/contrib/llvm/tools/lldb/source/Plugins/ObjectFile/ELF/ObjectFileELF.cpp Tue Feb 17 18:33:17 2015 (r278909) @@ -1331,8 +1331,11 @@ ObjectFileELF::GetSectionHeaderInfo(Sect } // If there are no section headers we are done. - if (header.e_shnum == 0) + if (header.e_shnum == 0) { + if (arch_spec.GetTriple().getOS() == llvm::Triple::OSType::UnknownOS) + arch_spec.GetTriple().setOSName(HostInfo::GetOSString().data()); return 0; + } Log *log(lldb_private::GetLogIfAllCategoriesSet (LIBLLDB_LOG_MODULES));
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201502171833.t1HIXI6q064214>