Repository navigation
pool: make JIT-pool exhaustion name the images that consumed the pool - #639
Open
TimmyTurner51 wants to merge 1 commit into
Open
TimmyTurner51 wants to merge 1 commit into
TimmyTurner51 wants to merge 1 commit into
Conversation
[jit-pool] EXHAUSTED reports which load just failed, and [pool-capacity] reports how much is free, but nothing reports what filled the pool -- which is the question that decides the fix. The per-image copy line is ERR(...)-level, so WINEDEBUG=-all (the shipping setting) filters it and a post-mortem log cannot answer it. That gap is why a recent investigation could not attribute 736 MB of pool consumption from a captured log at all. Records cumulative pool bytes per module (top 8, lock-guarded) and dumps them from the image-exhaustion path. Cumulative is the right measure here: image pool copies are not returned while the process lives, so 'who copied the most' is 'who owns the pool'. Diagnosis only -- no allocation behaviour changes, no new allocation path, and the dump is taken at a point that already prints to stderr. Build: compiles clean for arm64 against the current tree. Host checks: 296 passed, 2 pre-existing environmental failures (missing python 'compression' module; dxmt submodule not patched), 0 regressions. Co-authored-by: Cursor <cursoragent@cursor.com>
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.
Why
When the JIT pool exhausts, the log says which load failed (
[jit-pool] EXHAUSTED) and how much is free ([pool-capacity]), but never what filled it — and that is the question that decides the fix.The existing per-image copy line is
ERR(...)-level:so under
WINEDEBUG=-all— the setting a shipping run uses — it is filtered out entirely. A post-mortem log therefore cannot attribute pool consumption at all. In a recent failure (Forza Horizon 6, 736 MB of a 768 MB pool,freelist=0) this was the missing piece: the logs could namewindows.gaming.input.dllas the load that failed, but not the images whose copies had used the 736 MB, and the breakdown was uncomputable from the capture.What
Records cumulative pool bytes per module — top 8, lock-guarded, evicting the smallest so the list always holds the largest consumers — and dumps it from the image-exhaustion path next to the existing
EXHAUSTEDline:Cumulative is the correct measure: image pool copies are not returned while the process lives, so "who copied the most" is exactly "who owns the pool".
Risk
None to allocation. This is diagnosis only:
Verification
compressionmodule; dxmt submodule not patched), 0 regressionsMade with Cursor