[clr-interpreter] Followon changes from PR #116990#117093
Merged
davidwrighton merged 1 commit intodotnet:mainfrom Jun 27, 2025
Merged
[clr-interpreter] Followon changes from PR #116990#117093davidwrighton merged 1 commit intodotnet:mainfrom
davidwrighton merged 1 commit intodotnet:mainfrom
Conversation
Member
davidwrighton
commented
Jun 27, 2025
- use static_asserts where possible
- remove the mess of casts and temp variables around helper function opcodes
- Remove the DO_GENERIC_LOOKUP macro since it wasn't doing much of use anymore
- Use the simdhash apis a little better
- use static_asserts where possible - remove the mess of casts and temp variables around helper function opcodes - Remove the DO_GENERIC_LOOKUP macro since it wasn't doing much of use anymore - Use the simdhash apis a little better
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR makes several follow-on improvements to the interpreter-related code by reducing cast and temporary variable usage, replacing the DO_GENERIC_LOOKUP macro with inline calls to DoGenericLookup, and improving the use of simdhash APIs while enhancing compile‐time assertions.
- Remove unnecessary casts and temp variables in helper function calls
- Replace DO_GENERIC_LOOKUP macro with explicit calls to DoGenericLookup
- Update static assertions to use static_assert_no_msg and minor brace/indentation cleanups
Reviewed Changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| src/native/containers/dn-simdhash-specialization-declarations.h | Added comments clarifying that the result parameter is optional |
| src/coreclr/vm/interpexec.cpp | Updated helper typedef names, replaced macro usage with inline DoGenericLookup calls, and adjusted helper call invocations |
| src/coreclr/interpreter/compiler.h | Replaced runtime asserts with static_assert_no_msg and modified braces to improve code clarity |
Comments suppressed due to low confidence (1)
src/coreclr/vm/interpexec.cpp:1771
- Ensure that the revised generic lookup logic in InterpExecMethod—especially the inline DoGenericLookup invocations—is thoroughly exercised by unit tests to cover all branch variations.
MethodTable *pMTNewObj = (MethodTable*)DoGenericLookup(LOCAL_VAR(ip[3], void*), pLookup);
kg
reviewed
Jun 27, 2025
BrzVlad
approved these changes
Jun 27, 2025
This was referenced Jun 27, 2025
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.