[llvm-branch-commits] [lldb] aba4e3f - [lldb] [PECOFF] Only use PECallFrameInfo on the one supported architecture
Tom Stellard via llvm-branch-commits
llvm-branch-commits at lists.llvm.org
Mon May 18 18:27:57 PDT 2020
Author: Martin Storsjö
Date: 2020-05-18T18:24:44-07:00
New Revision: aba4e3fa3bd0aad13168f2f6e8f1874f9a0fdb57
URL: https://github.com/llvm/llvm-project/commit/aba4e3fa3bd0aad13168f2f6e8f1874f9a0fdb57
DIFF: https://github.com/llvm/llvm-project/commit/aba4e3fa3bd0aad13168f2f6e8f1874f9a0fdb57.diff
LOG: [lldb] [PECOFF] Only use PECallFrameInfo on the one supported architecture
The RuntimeFunction struct, which PECallFrameInfo interprets, has a
different layout and differnet semantics on all architectures.
Differential Revision: https://reviews.llvm.org/D77000
(cherry picked from commit aa786b881fc89a2a9883bff77912f2053126f95b)
Added:
Modified:
lldb/source/Plugins/ObjectFile/PECOFF/ObjectFilePECOFF.cpp
Removed:
################################################################################
diff --git a/lldb/source/Plugins/ObjectFile/PECOFF/ObjectFilePECOFF.cpp b/lldb/source/Plugins/ObjectFile/PECOFF/ObjectFilePECOFF.cpp
index 2e62e3292b9a..750bc77bdf74 100644
--- a/lldb/source/Plugins/ObjectFile/PECOFF/ObjectFilePECOFF.cpp
+++ b/lldb/source/Plugins/ObjectFile/PECOFF/ObjectFilePECOFF.cpp
@@ -780,6 +780,9 @@ std::unique_ptr<CallFrameInfo> ObjectFilePECOFF::CreateCallFrameInfo() {
if (!data_dir_exception.vmaddr)
return {};
+ if (m_coff_header.machine != llvm::COFF::IMAGE_FILE_MACHINE_AMD64)
+ return {};
+
return std::make_unique<PECallFrameInfo>(*this, data_dir_exception.vmaddr,
data_dir_exception.vmsize);
}
More information about the llvm-branch-commits
mailing list