Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix missing frame on inner exception stack trace in release build #105482

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions src/coreclr/vm/excep.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2509,8 +2509,7 @@ VOID DECLSPEC_NORETURN RealCOMPlusThrow(OBJECTREF throwable)
RealCOMPlusThrow(throwable, FALSE);
}

#ifdef USE_CHECKED_OBJECTREFS
VOID DECLSPEC_NORETURN RealCOMPlusThrow(Object *exceptionObj)
VOID DECLSPEC_NORETURN PropagateExceptionThroughNativeFrames(Object *exceptionObj)
{
CONTRACTL
{
Expand All @@ -2523,7 +2522,6 @@ VOID DECLSPEC_NORETURN RealCOMPlusThrow(Object *exceptionObj)
OBJECTREF throwable = ObjectToOBJECTREF(exceptionObj);
RealCOMPlusThrowWorker(throwable, FALSE);
}
#endif // USE_CHECKED_OBJECTREFS

// this function finds the managed callback to get a resource
// string from the then current local domain and calls it
Expand Down
2 changes: 1 addition & 1 deletion src/coreclr/vm/excep.h
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@ VOID DECLSPEC_NORETURN RealCOMPlusThrowNonLocalized(RuntimeExceptionKind reKind,
//==========================================================================

VOID DECLSPEC_NORETURN RealCOMPlusThrow(OBJECTREF throwable);
VOID DECLSPEC_NORETURN RealCOMPlusThrow(Object *exceptionObj);
VOID DECLSPEC_NORETURN PropagateExceptionThroughNativeFrames(Object *exceptionObj);

//==========================================================================
// Throw an undecorated runtime exception.
Expand Down
2 changes: 1 addition & 1 deletion src/coreclr/vm/exceptionhandling.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7872,7 +7872,7 @@ extern "C" void * QCALLTYPE CallCatchFunclet(QCall::ObjectHandleOnStack exceptio
#elif defined(HOST_RISCV) || defined(HOST_LOONGARCH64)
pvRegDisplay->pCurrentContext->Ra = GetIP(pvRegDisplay->pCurrentContext);
#endif
SetIP(pvRegDisplay->pCurrentContext, (PCODE)(void (*)(Object*))RealCOMPlusThrow);
SetIP(pvRegDisplay->pCurrentContext, (PCODE)(void (*)(Object*))PropagateExceptionThroughNativeFrames);
#if defined(HOST_AMD64)
SetSP(pvRegDisplay->pCurrentContext, targetSp - 8);
#elif defined(HOST_X86)
Expand Down
Loading