-
Notifications
You must be signed in to change notification settings - Fork 5.3k
Miscellaneous cleanup #122573
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
Merged
Merged
Miscellaneous cleanup #122573
Conversation
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
jkotas
commented
Dec 16, 2025
src/libraries/System.Runtime/tests/System.IO.FileSystem.Tests/Directory/GetFiles.cs
Show resolved
Hide resolved
jkotas
commented
Dec 16, 2025
Contributor
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 performs miscellaneous cleanup across the runtime codebase, removing unused code and improving code quality without changing functionality.
- Removes unused HResults constants, PAL API declarations, and helper functions
- Generalizes platform-specific code by removing unnecessary TARGET_ARM64 conditionals
- Improves code quality with better variable scoping and const correctness
Reviewed changes
Copilot reviewed 13 out of 13 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| src/libraries/System.Runtime/tests/System.IO.FileSystem.Tests/Directory/GetFiles.cs | Simplifies Windows test for directories with trailing spaces/periods by removing \?\ prefix requirement |
| src/libraries/Common/src/System/HResults.cs | Removes unused E_BOUNDS and E_CHANGED_STATE constants |
| src/coreclr/vm/exinfo.h | Removes TARGET_ARM64 conditional around m_handlingFramePC field (now used on all platforms) |
| src/coreclr/vm/exceptionhandling.cpp | Removes TARGET_ARM64 conditionals around handlingFramePC usage |
| src/coreclr/vm/ceemain.cpp | Improves GSCookie initialization by using hires_ticks on Windows and secure random bytes on Unix |
| src/coreclr/vm/callstubgenerator.cpp | Adds static const qualifiers to read-only routine pointer arrays |
| src/coreclr/tools/Common/TypeSystem/IL/Stubs/DelegateMethodILEmitter.cs | Moves signature variable declaration closer to first use for better code organization |
| src/coreclr/runtime/CachedInterfaceDispatch.cpp | Adds const qualifier to g_rgDispatchStubs array |
| src/coreclr/pal/inc/pal.h | Removes unused PAL_RegisterForRuntimeStartup and PAL_UnregisterForRuntimeStartup declarations |
| src/coreclr/nativeaot/Runtime/startup.cpp | Updates GSCookie initialization to use secure random bytes instead of low-res ticks |
| src/coreclr/nativeaot/Runtime.Base/src/System/Runtime/ExceptionHandling.cs | Removes TARGET_ARM64 conditionals, generalizes to "some platforms" in comments |
| src/coreclr/debug/ee/rcthread.cpp | Removes unused OpenWin32EventOrThrow helper function |
| src/coreclr/debug/ee/controller.cpp | Updates comments from platform-specific (WIN64/x86) to general descriptions about funclets and optimizations |
e89c5f7 to
9832fa5
Compare
MichalStrehovsky
approved these changes
Dec 17, 2025
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Labels
needs-area-label
An area label is needed to ensure this gets routed to the appropriate area owners
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.
No description provided.