diff --git a/src/coreclr/inc/corinfo.h b/src/coreclr/inc/corinfo.h index ef4e633d32db..a768f9614792 100644 --- a/src/coreclr/inc/corinfo.h +++ b/src/coreclr/inc/corinfo.h @@ -666,10 +666,10 @@ enum CorInfoHelpFunc CORINFO_HELP_LLVM_EH_CATCH, CORINFO_HELP_LLVM_EH_CATCH_POP_UNWOUND_VIRTUAL_FRAMES, CORINFO_HELP_LLVM_EH_POP_UNWOUND_VIRTUAL_FRAMES, + CORINFO_HELP_LLVM_EH_PUSH_VIRTUAL_UNWIND_FRAME, + CORINFO_HELP_LLVM_EH_POP_VIRTUAL_UNWIND_FRAME, CORINFO_HELP_LLVM_EH_UNHANDLED_EXCEPTION, CORINFO_HELP_LLVM_RESOLVE_INTERFACE_CALL_TARGET, - CORINFO_HELP_LLVM_PUSH_VIRTUAL_UNWIND_FRAME, - CORINFO_HELP_LLVM_POP_VIRTUAL_UNWIND_FRAME, CORINFO_HELP_COUNT, }; diff --git a/src/coreclr/inc/jithelpers.h b/src/coreclr/inc/jithelpers.h index 0e4e95163893..2520b5845f78 100644 --- a/src/coreclr/inc/jithelpers.h +++ b/src/coreclr/inc/jithelpers.h @@ -363,10 +363,10 @@ JITHELPER(CORINFO_HELP_LLVM_EH_CATCH, NULL, CORINFO_HELP_SIG_UNDEF) JITHELPER(CORINFO_HELP_LLVM_EH_CATCH_POP_UNWOUND_VIRTUAL_FRAMES, NULL, CORINFO_HELP_SIG_UNDEF) JITHELPER(CORINFO_HELP_LLVM_EH_POP_UNWOUND_VIRTUAL_FRAMES, NULL, CORINFO_HELP_SIG_UNDEF) + JITHELPER(CORINFO_HELP_LLVM_EH_PUSH_VIRTUAL_UNWIND_FRAME, NULL, CORINFO_HELP_SIG_UNDEF) + JITHELPER(CORINFO_HELP_LLVM_EH_POP_VIRTUAL_UNWIND_FRAME, NULL, CORINFO_HELP_SIG_UNDEF) JITHELPER(CORINFO_HELP_LLVM_EH_UNHANDLED_EXCEPTION, NULL, CORINFO_HELP_SIG_UNDEF) JITHELPER(CORINFO_HELP_LLVM_RESOLVE_INTERFACE_CALL_TARGET, NULL, CORINFO_HELP_SIG_UNDEF) - JITHELPER(CORINFO_HELP_LLVM_PUSH_VIRTUAL_UNWIND_FRAME, NULL, CORINFO_HELP_SIG_UNDEF) - JITHELPER(CORINFO_HELP_LLVM_POP_VIRTUAL_UNWIND_FRAME, NULL, CORINFO_HELP_SIG_UNDEF) #undef JITHELPER #undef DYNAMICJITHELPER diff --git a/src/coreclr/jit/llvm.cpp b/src/coreclr/jit/llvm.cpp index 3abb0c209c0d..ab50328b8904 100644 --- a/src/coreclr/jit/llvm.cpp +++ b/src/coreclr/jit/llvm.cpp @@ -587,10 +587,10 @@ bool Llvm::helperCallMayPhysicallyThrow(CorInfoHelpFunc helperFunc) const { FUNC(CORINFO_HELP_LLVM_EH_CATCH) CORINFO_TYPE_CLASS, { CORINFO_TYPE_NATIVEUINT }, HFIF_SS_ARG }, { FUNC(CORINFO_HELP_LLVM_EH_CATCH_POP_UNWOUND_VIRTUAL_FRAMES) CORINFO_TYPE_CLASS, { CORINFO_TYPE_NATIVEUINT }, HFIF_SS_ARG }, { FUNC(CORINFO_HELP_LLVM_EH_POP_UNWOUND_VIRTUAL_FRAMES) CORINFO_TYPE_VOID, { }, HFIF_SS_ARG }, + { FUNC(CORINFO_HELP_LLVM_EH_PUSH_VIRTUAL_UNWIND_FRAME) CORINFO_TYPE_VOID, { CORINFO_TYPE_PTR, CORINFO_TYPE_PTR, CORINFO_TYPE_NATIVEUINT }, HFIF_NO_RPI_OR_GC }, + { FUNC(CORINFO_HELP_LLVM_EH_POP_VIRTUAL_UNWIND_FRAME) CORINFO_TYPE_VOID, { }, HFIF_NO_RPI_OR_GC }, { FUNC(CORINFO_HELP_LLVM_EH_UNHANDLED_EXCEPTION) CORINFO_TYPE_VOID, { CORINFO_TYPE_CLASS }, HFIF_SS_ARG }, { FUNC(CORINFO_HELP_LLVM_RESOLVE_INTERFACE_CALL_TARGET) CORINFO_TYPE_PTR, { CORINFO_TYPE_CLASS, CORINFO_TYPE_PTR }, HFIF_SS_ARG }, - { FUNC(CORINFO_HELP_LLVM_PUSH_VIRTUAL_UNWIND_FRAME) CORINFO_TYPE_VOID, { CORINFO_TYPE_PTR, CORINFO_TYPE_PTR, CORINFO_TYPE_NATIVEUINT }, HFIF_NO_RPI_OR_GC }, - { FUNC(CORINFO_HELP_LLVM_POP_VIRTUAL_UNWIND_FRAME) CORINFO_TYPE_VOID, { }, HFIF_NO_RPI_OR_GC }, }; // clang-format on diff --git a/src/coreclr/jit/llvmlower.cpp b/src/coreclr/jit/llvmlower.cpp index 2d6f726ff4e2..ca0e700898b1 100644 --- a/src/coreclr/jit/llvmlower.cpp +++ b/src/coreclr/jit/llvmlower.cpp @@ -1489,7 +1489,7 @@ PhaseStatus Llvm::AddVirtualUnwindFrame() GenTree* unwindFrameLclAddr = m_compiler->gtNewLclVarAddrNode(unwindFrameLclNum); GenTreeIntCon* initialUnwindIndexNode = m_compiler->gtNewIconNode(m_initialIndexValue, TYP_I_IMPL); GenTreeCall* initializeCall = - m_compiler->gtNewHelperCallNode(CORINFO_HELP_LLVM_PUSH_VIRTUAL_UNWIND_FRAME, TYP_VOID, + m_compiler->gtNewHelperCallNode(CORINFO_HELP_LLVM_EH_PUSH_VIRTUAL_UNWIND_FRAME, TYP_VOID, unwindFrameLclAddr, unwindTableAddrNode, initialUnwindIndexNode); m_llvm->m_prologRange.InsertAtEnd(unwindFrameLclAddr); @@ -1520,7 +1520,7 @@ PhaseStatus Llvm::AddVirtualUnwindFrame() assert(lastNode->OperIs(GT_RETURN)); GenTreeCall* popCall = - m_compiler->gtNewHelperCallNode(CORINFO_HELP_LLVM_POP_VIRTUAL_UNWIND_FRAME, TYP_VOID); + m_compiler->gtNewHelperCallNode(CORINFO_HELP_LLVM_EH_POP_VIRTUAL_UNWIND_FRAME, TYP_VOID); LIR::Range popCallRange; popCallRange.InsertAtBeginning(popCall); m_llvm->lowerRange(block, popCallRange); diff --git a/src/coreclr/jit/utils.cpp b/src/coreclr/jit/utils.cpp index a06649327d36..b4e23a78263c 100644 --- a/src/coreclr/jit/utils.cpp +++ b/src/coreclr/jit/utils.cpp @@ -1563,8 +1563,8 @@ void HelperCallProperties::init() case CORINFO_HELP_LLVM_EH_CATCH: case CORINFO_HELP_LLVM_EH_CATCH_POP_UNWOUND_VIRTUAL_FRAMES: case CORINFO_HELP_LLVM_EH_POP_UNWOUND_VIRTUAL_FRAMES: - case CORINFO_HELP_LLVM_PUSH_VIRTUAL_UNWIND_FRAME: - case CORINFO_HELP_LLVM_POP_VIRTUAL_UNWIND_FRAME: + case CORINFO_HELP_LLVM_EH_PUSH_VIRTUAL_UNWIND_FRAME: + case CORINFO_HELP_LLVM_EH_POP_VIRTUAL_UNWIND_FRAME: noThrow = true; mutatesHeap = true; diff --git a/src/coreclr/tools/Common/JitInterface/CorInfoHelpFunc.cs b/src/coreclr/tools/Common/JitInterface/CorInfoHelpFunc.cs index 0ae8ea86547a..f15d6818502d 100644 --- a/src/coreclr/tools/Common/JitInterface/CorInfoHelpFunc.cs +++ b/src/coreclr/tools/Common/JitInterface/CorInfoHelpFunc.cs @@ -308,10 +308,10 @@ which is the right helper to use to allocate an object of a given type. */ CORINFO_HELP_LLVM_EH_CATCH, CORINFO_HELP_LLVM_EH_CATCH_POP_UNWOUND_VIRTUAL_FRAMES, CORINFO_HELP_LLVM_EH_POP_UNWOUND_VIRTUAL_FRAMES, + CORINFO_HELP_LLVM_EH_PUSH_VIRTUAL_UNWIND_FRAME, + CORINFO_HELP_LLVM_EH_POP_VIRTUAL_UNWIND_FRAME, CORINFO_HELP_LLVM_EH_UNHANDLED_EXCEPTION, CORINFO_HELP_LLVM_RESOLVE_INTERFACE_CALL_TARGET, - CORINFO_HELP_LLVM_PUSH_VIRTUAL_UNWIND_FRAME, - CORINFO_HELP_LLVM_POP_VIRTUAL_UNWIND_FRAME, CORINFO_HELP_COUNT, } diff --git a/src/coreclr/tools/aot/ILCompiler.RyuJit/JitInterface/CorInfoImpl.RyuJit.cs b/src/coreclr/tools/aot/ILCompiler.RyuJit/JitInterface/CorInfoImpl.RyuJit.cs index 4d74bee75c36..c6421c601c3e 100644 --- a/src/coreclr/tools/aot/ILCompiler.RyuJit/JitInterface/CorInfoImpl.RyuJit.cs +++ b/src/coreclr/tools/aot/ILCompiler.RyuJit/JitInterface/CorInfoImpl.RyuJit.cs @@ -774,18 +774,18 @@ private ISymbolNode GetHelperFtnUncached(CorInfoHelpFunc ftnNum) case CorInfoHelpFunc.CORINFO_HELP_LLVM_EH_POP_UNWOUND_VIRTUAL_FRAMES: mangledName = "RhpPopUnwoundVirtualFrames"; break; - case CorInfoHelpFunc.CORINFO_HELP_LLVM_EH_UNHANDLED_EXCEPTION: - mangledName = "RhpHandleUnhandledException"; - break; case CorInfoHelpFunc.CORINFO_HELP_LLVM_RESOLVE_INTERFACE_CALL_TARGET: mangledName = "RhpResolveInterfaceDispatch"; break; - case CorInfoHelpFunc.CORINFO_HELP_LLVM_PUSH_VIRTUAL_UNWIND_FRAME: + case CorInfoHelpFunc.CORINFO_HELP_LLVM_EH_PUSH_VIRTUAL_UNWIND_FRAME: mangledName = "RhpPushVirtualUnwindFrame"; break; - case CorInfoHelpFunc.CORINFO_HELP_LLVM_POP_VIRTUAL_UNWIND_FRAME: + case CorInfoHelpFunc.CORINFO_HELP_LLVM_EH_POP_VIRTUAL_UNWIND_FRAME: mangledName = "RhpPopVirtualUnwindFrame"; break; + case CorInfoHelpFunc.CORINFO_HELP_LLVM_EH_UNHANDLED_EXCEPTION: + mangledName = "RhpHandleUnhandledException"; + break; default: throw new NotImplementedException(ftnNum.ToString());