-
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
Introduce a diagnostic switch to turn off the use of file mapping in PE loader. #84151
Conversation
Tagging subscribers to this area: @agocke, @vitek-karas, @VSadov Issue DetailsWe needed this in a few scenarios recently when narrowing down the root cause of bugs. Without a switch, turning off the file mapping is nontrivial and especially so in a singlefile scenario. === in progress. Need to:
|
/azp run runtime-extra-platforms |
Azure Pipelines successfully started running 1 pipeline(s). |
CC: @tommcdon |
close/reopen to ustuck the CLA check |
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.
LGTM, thank you!
Thanks!! |
Introducing unsupported/internal
DOTNET_PELoader_DisableMapping
switch.The switch is available in both debug and release builds.
Setting
DOTNET_PELoader_DisableMapping
to not 0 will force the fallback paths in PE loader where file sections are copied to preallocated memory ranges instead of being mapped.We needed to turn off file mapping in a few scenarios recently when narrowing down the root cause of bugs.
Without a switch, turning off the file mapping is nontrivial and especially so in a singlefile scenario.