Closed
Conversation
Member
Author
|
PTAL @AndyAyersMS @dotnet/jit-contrib |
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR enhances debugging capabilities by printing the top likely classes in JITDUMP and unifies constants used for type checks.
- Adds an extra parameter (verboseLogging) to control verbose logging in the type check candidate selection.
- Replaces uses of MAX_CAST_GUESSES with MAX_GDV_TYPE_CHECKS to standardize limits across casts.
- Extends debug output in gtDispTree to optionally print profiling information for cast helpers.
Reviewed Changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| src/coreclr/jit/importercalls.cpp | Adds verboseLogging parameter and adjusts logging conditions. |
| src/coreclr/jit/helperexpansion.cpp | Unifies MAX_CAST_GUESSES with MAX_GDV_TYPE_CHECKS in candidate selection. |
| src/coreclr/jit/gentree.cpp | Adds conditional debugging print for likely class data. |
| src/coreclr/jit/compiler.h | Updates function prototype to include a verboseLogging parameter with a default value. |
Comments suppressed due to low confidence (1)
src/coreclr/jit/helperexpansion.cpp:2159
- Verify that MAX_GDV_TYPE_CHECKS is defined consistently across all build configurations and update surrounding comments to fully reflect the unification with MAX_CAST_GUESSES.
const int maxTypeChecks = min(comp->getGDVMaxTypeChecks(), MAX_GDV_TYPE_CHECKS);
Contributor
|
Tagging subscribers to this area: @JulieLeeMSFT, @jakobbotsch |
Member
Author
|
Closing per #116223 (comment) |
This was referenced Jun 3, 2025
Open
This file contains hidden or 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
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
Since cast helpers may expand with PGO in late phases, it makes sense to print their top likely classes in JITDUMP, example:
Also, unify
MAX_CAST_GUESSESwithMAX_GDV_TYPE_CHECKS