-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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
Removal of Helper Method Frames (HMF) #110767
Comments
Tagging subscribers to this area: @mangod9 |
Also #95695 |
Thanks, I added it. I wasn't trying to be exhaustive. Wanted to provide a bunch of examples people could reference. |
The way @VSadov consolidated lock primitives with NativeAOT, if we continue on that path, maybe it is possible to share the entire implementation with AOT (which has this HCall written in C#).
There is also a related JIT_Patchpoint HCall, which ends up using |
It was tracking issue instead of PR. There is also more context about HMF. |
Closing this one in lieu of #95695. |
Background
Over the past several releases, there has been a slow, but intentional, effort to move more runtime code from C++ into C#. A consequence of this effort has meant the removal of Helper Method Frames (HMF). Removal of HMFs simplifies the runtime for efforts like cDAC, reduces opportunities for GC holes, and in some cases can result in improved performance when the JIT can see more of the code that is can optimize.
Prior work
Below is a list of various PRs that can be referenced that demonstrate that effort across multiple authors and releases.
#70000, #70055, #71873, #87166, #95038, #96926, #97590, #100116, #101353, #106793, #107058, #107218, #107648, #108167, #109135, #109996, #110064, #110211, #110377, #110481, #110627, #110766
Remaining work
List of JIT helpers that need the removal of explicit HMFs:
JIT_GetFieldAddr_Framed
JIT_New
JIT_NewMaybeFrozen
FramedAllocateString
JIT_StrCns
JIT_NewArr1
JIT_NewArr1MaybeFrozen
JIT_NewMDArr
JIT_Box
JIT_GetRuntimeFieldStub
JIT_GetRuntimeMethodStub
JIT_GetRuntimeType_Framed
JIT_MonEnter_Helper
JIT_MonTryEnter_Helper
JIT_MonExit_Helper
JIT_MonExit_Signal
IL_Throw
IL_Rethrow
JIT_ThrowMethodAccessException
JIT_ThrowFieldAccessException
JIT_ThrowClassAccessException
JIT_UserBreakpoint
JIT_PollGC_Framed
JIT_PInvokeEndRarePath
JIT_RareDisableHelper
/JIT_RareDisableHelperWorker
JIT_StressGC
JIT_Patchpoint_Framed
JIT_PartialCompilationPatchpoint
List of JIT helpers with implicit HMFs through a use of
FCThrow
.JIT_Div
,JIT_Mod
,JIT_UDiv
,JIT_UMod
,JIT_LDiv
,JIT_LMod
,JIT_ULDiv
,JIT_ULMod
- Move arithmetic helpers to managed code #109087The following clean-up can occur after all the above is complete:
fcall.h
andfcall.cpp
The text was updated successfully, but these errors were encountered: