summaryrefslogtreecommitdiff
path: root/src/vm/exceptionhandling.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/vm/exceptionhandling.cpp')
-rw-r--r--src/vm/exceptionhandling.cpp26
1 files changed, 2 insertions, 24 deletions
diff --git a/src/vm/exceptionhandling.cpp b/src/vm/exceptionhandling.cpp
index ba7a68dba7..a6c7651004 100644
--- a/src/vm/exceptionhandling.cpp
+++ b/src/vm/exceptionhandling.cpp
@@ -2680,7 +2680,7 @@ CLRUnwindStatus ExceptionTracker::ProcessManagedCallFrame(
EE_ILEXCEPTION_CLAUSE EHClause;
PTR_EXCEPTION_CLAUSE_TOKEN pEHClauseToken = pJitMan->GetNextEHClause(&EnumState, &EHClause);
- EH_LOG((LL_INFO100, " considering %s clause [%x,%x], ControlPc is %s clause (offset %x)",
+ EH_LOG((LL_INFO100, " considering %s clause [%x,%x), ControlPc is %s clause (offset %x)",
(IsFault(&EHClause) ? "fault" :
(IsFinally(&EHClause) ? "finally" :
(IsFilterHandler(&EHClause) ? "filter" :
@@ -4698,29 +4698,7 @@ Return value :
--*/
VOID* GetRegisterAddressByIndex(PCONTEXT pContext, UINT index)
{
-#if defined(_TARGET_AMD64_)
- _ASSERTE(index < 16);
- return &((&pContext->Rax)[index]);
-#elif defined(_TARGET_X86_)
- _ASSERTE(index < 8);
-
- static const SIZE_T OFFSET_OF_REGISTERS[] =
- {
- offsetof(CONTEXT, Eax),
- offsetof(CONTEXT, Ecx),
- offsetof(CONTEXT, Edx),
- offsetof(CONTEXT, Ebx),
- offsetof(CONTEXT, Esp),
- offsetof(CONTEXT, Ebp),
- offsetof(CONTEXT, Esi),
- offsetof(CONTEXT, Edi),
- };
-
- return (VOID*)(PBYTE(pContext) + OFFSET_OF_REGISTERS[index]);
-#else
- PORTABILITY_ASSERT("GetRegisterAddressByIndex");
- return NULL;
-#endif
+ return getRegAddr(index, pContext);
}
/*++