Repository navigation
Conversation
sceKernelVirtualQuery reports live extents since boykopovar#1929, so msync now fails with ENOMEM for a hole punched by a partial munmap. Cover it and drop the TechnicalDebt clause that said the hole still counts as mapped. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Thank you for your interest in the project! We are sorry, but we cannot accept more PRs while we work through the existing backlog. This PR has been automatically closed and labeled "intake paused". This is not a judgment of the quality of your changes. |
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 join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
What
Since #1929,
sceKernelVirtualQueryreports a mapping's live extents after a partialmunmap(#1894).msyncasks it about every page in its range, so a page unmapped from inside a larger mapping is nowENOMEM, as FreeBSD'svm_map_syncgives for an unmapped range. The TechnicalDebt line formsync, added in #1857 before #1929, still says the hole counts as mapped. This drops that clause and adds checks toguest_msync: with the middle of three pages unmapped, the outer pages still sync, and the hole, a zero-length call at the hole, and a range spanning it areENOMEM. No code change.The checks unmap the remaining pages one at a time, because
munmapover a range with a hole fails (#3196).Tested
Windows 11 Pro (26200), MinGW-w64 GCC 15.2.0 (WinLibs r7), Release with CI's configure flags, on
mainf1ae427b(nothing underDirectMemory/changed up to06da1176):guest_msyncmsyncchecking only the first pageLinux not run (the test has no platform-specific code).
tools/check_conventions.pypasses.Checklist
main; no other open PR implements the same functionsNotImplemented_nid_no_patch); silent stubs are listed in TechnicalDebt.mdfiles or images added to the repository (attach them to this PR)🤖 Generated with Claude Code