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:
authordotnet-bot <dotnet-bot@microsoft.com>2017-09-26 03:31:09 +0300
committerdotnet-bot <dotnet-bot@microsoft.com>2017-09-26 06:14:34 +0300
commit94f2d8ea3943f7e90cda86ae7b7cb47d3da5a53a (patch)
tree941c381b0df93a9a335bf7d40c31c3ab94bd95f0 /src/Native/Runtime/PalRedhawkCommon.h
parent351d113aaa275354213aeb31bdc0709b56774508 (diff)
[tfs-changeset: 1676255]
Diffstat (limited to 'src/Native/Runtime/PalRedhawkCommon.h')
-rw-r--r--src/Native/Runtime/PalRedhawkCommon.h28
1 files changed, 22 insertions, 6 deletions
diff --git a/src/Native/Runtime/PalRedhawkCommon.h b/src/Native/Runtime/PalRedhawkCommon.h
index 3ee11e9a2..4edab876b 100644
--- a/src/Native/Runtime/PalRedhawkCommon.h
+++ b/src/Native/Runtime/PalRedhawkCommon.h
@@ -41,6 +41,7 @@ struct AMD64_ALIGN_16 Fp128 {
struct PAL_LIMITED_CONTEXT
{
+ // Includes special registers, callee saved registers and general purpose registers used to return values from functions (not floating point return registers)
#ifdef _TARGET_ARM_
UIntNative R0;
UIntNative R4;
@@ -65,12 +66,27 @@ struct PAL_LIMITED_CONTEXT
void SetIp(UIntNative ip) { IP = ip; }
void SetSp(UIntNative sp) { SP = sp; }
#elif defined(_TARGET_ARM64_)
- // @TODO: Add ARM64 registers
- UIntNative IP;
- UIntNative GetIp() const { PORTABILITY_ASSERT("@TODO: FIXME:ARM64"); }
- UIntNative GetSp() const { PORTABILITY_ASSERT("@TODO: FIXME:ARM64"); }
- UIntNative GetFp() const { PORTABILITY_ASSERT("@TODO: FIXME:ARM64"); }
- UIntNative GetLr() const { PORTABILITY_ASSERT("@TODO: FIXME:ARM64"); }
+#if !defined(GEN_REG_COUNT)
+#define GEN_REG_COUNT 29
+#endif
+
+ // ARM64TODO: we don't need to save X9-X15
+ // ARM64TODO: do we need X16 (IP0), X17 (IP1), X18 or can we skip them?
+ UIntNative X[GEN_REG_COUNT];
+
+ UIntNative FP;
+ UIntNative LR;
+ UIntNative SP;
+ UIntNative IP;
+
+ UIntNative D[16 - 8]; // Only the bottom 64-bit value of the V registers V8..V15 needs to be preserved
+ // (V0-V7 and V16-V31 are not preserved according to the ABI spec).
+
+
+ UIntNative GetIp() const { return IP; }
+ UIntNative GetSp() const { return SP; }
+ UIntNative GetFp() const { return FP; }
+ UIntNative GetLr() const { return LR; }
#elif defined(UNIX_AMD64_ABI)
// Param regs: rdi, rsi, rdx, rcx, r8, r9, scratch: rax, rdx (both return val), preserved: rbp, rbx, r12-r15
UIntNative IP;