-
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
Resolve call mdtokens when making tier 1 inline observations #50675
Merged
tannergooding
merged 4 commits into
dotnet:main
from
tannergooding:resolve-tokens-inline
Apr 5, 2021
Merged
Resolve call mdtokens when making tier 1 inline observations #50675
tannergooding
merged 4 commits into
dotnet:main
from
tannergooding:resolve-tokens-inline
Apr 5, 2021
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…argets when in Tier1 making inline observations
…True/False as constants in fgFindJumpTargets
dotnet-issue-labeler
bot
added
the
area-CodeGen-coreclr
CLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMI
label
Apr 3, 2021
This change produced zero PMI diffs for CC. @jkotas, @AndyAyersMS |
jkotas
reviewed
Apr 3, 2021
Any other feedback/changes needed here? |
AndyAyersMS
approved these changes
Apr 5, 2021
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No -- looks good.
thaystg
added a commit
to thaystg/runtime
that referenced
this pull request
Apr 6, 2021
…shim_mono # By Aaron Robinson (10) and others # Via GitHub * upstream/main: (108 commits) [mbr] Add Apple sample (dotnet#50740) make EstablishProxyTunnelAsync throw on failure status code from proxy (dotnet#50763) Improve RGB Min Max evaluation performance by using 2 or 3 comparison… (dotnet#50622) [mono] More domain cleanups (dotnet#50479) Fix Crossgen2 of PlatformDefaultMemberFunction methods and calls. (dotnet#50754) Disable EventSource generator in design-time builds (dotnet#50741) Fix X509 test failures on Android (dotnet#50301) Do not confuse fgDispBasicBlocks in fgMorphBlocks (dotnet#50703) Enforce 64KB event payload size limit on EventPipe (dotnet#50600) Reorganize CoreCLR native build to reduce CMake reconfigures when the build system is untouched (dotnet#49906) [mbr] Turn on hot reload for iOS, tvOS and MacCatalyst (dotnet#50458) improve connection scavenge logic by doing zero-byte read (dotnet#50545) Resolve call mdtokens when making tier 1 inline observations (dotnet#50675) Annotate APIs in System.Private.Xml (dotnet#49682) Support compiling against OpenSSL 3 headers Change Configuration.Json to use a regular Dictionary. (dotnet#50611) Remove unused BigNumFromBinary P/Invoke (dotnet#50670) Make Ninja the default CMake generator on Windows for the repo (dotnet#49715) [AppleAppBuilder] Entitlements to run tests on catalyst using the JIT (dotnet#50637) [mono] Fix delegate invokes to dynamic methods in mixed mode. (dotnet#50547) ... # Conflicts: # src/mono/dlls/mscordbi/CMakeLists.txt
ghost
locked as resolved and limited conversation to collaborators
May 15, 2021
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Labels
area-CodeGen-coreclr
CLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMI
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This updates
Compiler::fgFindJumpTargets
to support resolving call tokens when making inline observations for Tier 1.A test of
csc
compiling a simpleHelloWorld
program (csc.dll Program.cs /r:System.Runtime.dll /r:System.Console.dll /r:System.Private.Corelib.dll
) withCOMPlus_ReadyToRun=0
andCOMPlus_TieredCompilation=0
resulted in the following impact:Compiler::fgFindJumpTarget
goes from0.48%
to0.63%
of instructions retired (28.5m
to39.25m
)CEEInfo::resolveToken
goes from0.32%
to0.34%
of instructions retired (19m
to21m
)CEEInfo::getCallInfo
goes from0.36%
to0.32%
of instructions retired (21.25m
to19.75m
)As per the flame graph (see below), the majority of time is still spent in the backend. There was no measured impact for
tier 0
methods.This change will allow us to make potential improvements to inlining for methods that involve many intrinsic calls. Some potential metrics we could use to influence inlining include:
intrinsic
(Named or Otherwise)hwintrinsic
and therefore are not calls at all, but are effectively "simple ops"Math
calls)Isa.IsSupported
string.Length
orType.op_Equality
checksWe can place this behind a
DOTNET_*
(COMPlus_*
) switch if there are any remaining concerns around impact.