Repository navigation
[precompile] Report the recorded/total split when a compiled backend is missing - #194454
Closed
bobrenjc93 wants to merge 3 commits into
Closed
bobrenjc93 wants to merge 3 commits into
bobrenjc93 wants to merge 3 commits into
Conversation
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/194454
Note: Links to docs will display an error until the docs builds have been completed. ❌ 14 New Failures, 1 Unrelated Failure, 1 Unclassified FailureAs of commit afd7f65 with merge base 1b4e490 ( NEW FAILURES - The following jobs have failed:
UNCLASSIFIED FAILURE - DrCI could not classify the following job because the workflow did not run on the merge base. The failure may be pre-existing on trunk or introduced by this PR:
BROKEN TRUNK - The following job failed but were present on the merge base:👉 Rebase onto the `viable/strict` branch to avoid these failures
This comment was automatically generated by Dr. CI and updates every 15 minutes. |
This was referenced Aug 22, 2026
Closed
Closed
This was referenced Aug 22, 2026
Contributor
Author
|
@bobrenjc93 has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator. |
This was referenced Aug 23, 2026
This was referenced Aug 28, 2026
Contributor
Author
|
@bobrenjc93 has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator. |
1 similar comment
Contributor
Author
|
@bobrenjc93 has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator. |
Contributor
Author
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.
Stack from ghstack (oldest at bottom):
Backend recording is all-or-nothing:
_collect_backendsfails the wholeartifact if any one backend id has nothing behind it. The message it failed
with said "Precompilation captured graphs but their compiled backends were
never recorded, so there is nothing to serialize", which describes a total
failure. A capture of a large sharded model that recorded 41 of its 56 backends
and missed 15 got that same sentence, and it was read -- reasonably -- as
having recorded nothing, which sends the reader looking for a cause big enough
to explain losing everything.
Report the split instead, and name the ids that are missing. The counts are
what tell a reader whether they are looking at one bad graph or a broken
capture, and they were the one thing the message did not have.
The rest of the message had also gone stale. It attributed the gap to
AOTAutogradCache declining to key the graph, which stopped being possible two
commits down: capture now pins
bypass_autograd_cache_key, so every graphgets a key and is recorded whether or not the cache could have addressed it.
The remaining cause is the other one it already named, a backward that never
compiled, so that is now the headline rather than the afterthought. The bypass
count stays, demoted to a diagnostic and only when nonzero, because rendering
re-enters AOTAutograd outside the capture config and bypasses there routinely
-- a nonzero count on a healthy capture is expected and does not explain a gap.
save()had its own copy of the paragraph, reached by string-matching thestore's RuntimeError, and the two had already drifted. They now share one
builder.
Test Plan:
Two new tests. The first pins the reason the split cannot currently be
nonzero: a capture whose graphs are unkeyable on only some sides of its graph
breaks records all four of its backends and bypasses zero times. Forcing
bypass_autograd_cache_keyback off makes that same capture report "recorded 2of 4", which is both how the new message was checked against a real partial
state and confirmation that the 41-of-56 reading was right. The second covers
the message itself, including the truncation and the absence of the old
"never recorded" claim.
Authored with an AI assistant.
Differential Revision: D117073080