[PATCH] D44822: A couple of minor build fixes for Windows Arm host
Chris January via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Mar 23 03:07:41 PDT 2018
arm-chrjan01 created this revision.
arm-chrjan01 added reviewers: zturner, rnk.
Herald added subscribers: llvm-commits, kristof.beyls, mgorny.
Use the Arm version of the Debug Interface Access SDK when cross-compiling for an Arm host using the Visual Studio compiler.
Use CONTEXT.https://reviews.llvm.org/source/libunwind/ instead of CONTEXT.Fp. Fp field does not exist in Windows SDK 10.0.16299.0, at least.
Repository:
rL LLVM
https://reviews.llvm.org/D44822
Files:
lib/DebugInfo/PDB/CMakeLists.txt
lib/Support/Windows/Signals.inc
Index: lib/Support/Windows/Signals.inc
===================================================================
--- lib/Support/Windows/Signals.inc
+++ lib/Support/Windows/Signals.inc
@@ -539,7 +539,7 @@
#elif defined(_M_ARM64) || defined(_M_ARM)
StackFrame.AddrPC.Offset = Context.Pc;
StackFrame.AddrStack.Offset = Context.Sp;
- StackFrame.AddrFrame.Offset = Context.Fp;
+ StackFrame.AddrFrame.Offset = Context.R11;
#endif
StackFrame.AddrPC.Mode = AddrModeFlat;
StackFrame.AddrStack.Mode = AddrModeFlat;
@@ -819,7 +819,7 @@
StackFrame.AddrPC.Mode = AddrModeFlat;
StackFrame.AddrStack.Offset = ep->ContextRecord->Sp;
StackFrame.AddrStack.Mode = AddrModeFlat;
- StackFrame.AddrFrame.Offset = ep->ContextRecord->Fp;
+ StackFrame.AddrFrame.Offset = ep->ContextRecord->R11;
StackFrame.AddrFrame.Mode = AddrModeFlat;
#endif
Index: lib/DebugInfo/PDB/CMakeLists.txt
===================================================================
--- lib/DebugInfo/PDB/CMakeLists.txt
+++ lib/DebugInfo/PDB/CMakeLists.txt
@@ -6,7 +6,11 @@
if(LLVM_ENABLE_DIA_SDK)
include_directories(${MSVC_DIA_SDK_DIR}/include)
set(LIBPDB_LINK_FOLDERS "${MSVC_DIA_SDK_DIR}\\lib")
- if (CMAKE_SIZEOF_VOID_P EQUAL 8)
+ if ("$ENV{VSCMD_ARG_TGT_ARCH}" STREQUAL "arm64")
+ set(LIBPDB_LINK_FOLDERS "${LIBPDB_LINK_FOLDERS}\\arm64")
+ elseif ("$ENV{VSCMD_ARG_TGT_ARCH}" STREQUAL "arm")
+ set(LIBPDB_LINK_FOLDERS "${LIBPDB_LINK_FOLDERS}\\arm")
+ elseif (CMAKE_SIZEOF_VOID_P EQUAL 8)
set(LIBPDB_LINK_FOLDERS "${LIBPDB_LINK_FOLDERS}\\amd64")
endif()
file(TO_CMAKE_PATH "${LIBPDB_LINK_FOLDERS}\\diaguids.lib" LIBPDB_ADDITIONAL_LIBRARIES)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D44822.139568.patch
Type: text/x-patch
Size: 1673 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180323/73521528/attachment.bin>
More information about the llvm-commits
mailing list