-
Notifications
You must be signed in to change notification settings - Fork 5k
Dump more info in JitDump for HWIHNTRINSIC nodes #115255
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
Dump more info in JitDump for HWIHNTRINSIC nodes #115255
Conversation
In particular, dump `gtSimdSize` and `gtAuxiliaryJitType`. Example: ``` old: HWINTRINSIC simd64 long InsertVector128 HWINTRINSIC mask long ConvertVectorToMask new: HWINTRINSIC simd64 64 long InsertVector128 HWINTRINSIC mask 64 long ConvertVectorToMask ```
Tagging subscribers to this area: @JulieLeeMSFT, @jakobbotsch |
I found this useful when debugging a recent issue. @tannergooding @dotnet/jit-contrib |
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.
Pull Request Overview
This PR enhances the JitDump output for HWIHNTRINSIC nodes by including additional details (gtSimdSize and gtAuxiliaryJitType) to the debug printout.
- Added printing of the SIMD size before the intrinsic type name.
- Conditionally prints the SIMD base type and auxiliary type (if available) in a formatted manner.
if (tree->OperIs(GT_HWINTRINSIC)) | ||
{ | ||
GenTreeHWIntrinsic* node = tree->AsHWIntrinsic(); | ||
printf(" %u", node->GetSimdSize()); |
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.
[nitpick] Consider combining the multiple printf calls into a single call to improve code readability and reduce potential overhead.
Copilot uses AI. Check for mistakes.
? "" | ||
: varTypeName(tree->AsHWIntrinsic()->GetSimdBaseType()), | ||
HWIntrinsicInfo::lookupName(tree->AsHWIntrinsic()->GetHWIntrinsicId())); | ||
printf(" (aux %s)", varTypeName(node->GetAuxiliaryType())); |
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.
[nitpick] Ensure that the format of printing the auxiliary type (with parentheses) is consistent with other debug outputs; consider adding a comment to clarify the intended formatting.
printf(" (aux %s)", varTypeName(node->GetAuxiliaryType())); | |
// Print the auxiliary type without parentheses for consistency with other debug outputs. | |
printf(" aux %s", varTypeName(node->GetAuxiliaryType())); |
Copilot uses AI. Check for mistakes.
/ba-g unrelated failures |
In particular, dump
gtSimdSize
andgtAuxiliaryJitType
.Example: