Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/corert.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJan Vorlicek <janvorli@microsoft.com>2016-05-04 09:10:20 +0300
committerJan Kotas <jkotas@microsoft.com>2016-05-04 09:10:20 +0300
commit2907f2df9e86fe0830659755bb50c6f2b66ed4d1 (patch)
tree336c2035b154417a604b6bc9b44915f10452e5eb /src/Native/Runtime/EHHelpers.cpp
parent6de337625995e5cacf0954b9bc3e9f7e74f98b0b (diff)
Modify context related data structures for Unix AMD64 (#1228)
This change modifies PAL_LIMITED_CONTEXT, StackFrameIterator and REGDISPLAY structs and also all related code accessing registers that are not present for Unix.
Diffstat (limited to 'src/Native/Runtime/EHHelpers.cpp')
-rw-r--r--src/Native/Runtime/EHHelpers.cpp13
1 files changed, 12 insertions, 1 deletions
diff --git a/src/Native/Runtime/EHHelpers.cpp b/src/Native/Runtime/EHHelpers.cpp
index d1010754b..b385f85c4 100644
--- a/src/Native/Runtime/EHHelpers.cpp
+++ b/src/Native/Runtime/EHHelpers.cpp
@@ -129,7 +129,18 @@ COOP_PINVOKE_HELPER(void, RhpCopyContextFromExInfo,
UNREFERENCED_PARAMETER(cbOSContext);
ASSERT(cbOSContext >= sizeof(CONTEXT));
CONTEXT* pContext = (CONTEXT *)pOSContext;
-#ifdef _AMD64_
+#if defined(UNIX_AMD64_ABI)
+ pContext->Rip = pPalContext->IP;
+ pContext->Rsp = pPalContext->Rsp;
+ pContext->Rbp = pPalContext->Rbp;
+ pContext->Rdx = pPalContext->Rdx;
+ pContext->Rax = pPalContext->Rax;
+ pContext->Rbx = pPalContext->Rbx;
+ pContext->R12 = pPalContext->R12;
+ pContext->R13 = pPalContext->R13;
+ pContext->R14 = pPalContext->R14;
+ pContext->R15 = pPalContext->R15;
+#elif defined(_AMD64_)
pContext->Rip = pPalContext->IP;
pContext->Rsp = pPalContext->Rsp;
pContext->Rbp = pPalContext->Rbp;