Repository navigation
Conversation
…first compile_dxil --watch sorted pending requests by marker path and compiled the whole list before scanning again, so a request written during a pass waited for the whole backlog. As in gfx2hlsl.py (R0Y00#3396), requests whose ready marker is newer than the watcher's start now go first, newest first, in batches of up to four keys per worker, with a rescan between batches at most once per second. --requests keeps its order; outputs are unchanged. Refs R0Y00#3392.
2 tasks done
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.
Change
compile_dxil --watchsorted pending requests by marker path and compiled the whole list before it scanned again, so a request written during a pass waited for the whole backlog. Asgfx2hlsl.py --watchnow does (#3396), requests whose ready marker is newer than the watcher's start go first, newest first, in batches of up to four keys per worker, with a rescan between batches at most once per second (steady clock). A key is attempted once per pass; the first-pass retry of earlier failures,--skip-failedand--requestsare unchanged, and each key's outputs are the same.Refs #3392 (the
compile_dxilhalf; thegfx2hlsl.pyhalf is #3396).Verification
Commit
e270b240onmain6747721c(the headc901a1f2is that commit rebased onto0614f68c, which adds only #3329 in other files), Windows 11, release preset.ctest --test-dir out/build/release -R "^native_compile_dxil_watch$": passes. The new case writes five old requests and one new compute request that sorts last by path, then runs--watch --oncetwice: with every marker old (the old order) the new key is processed last; with its marker newer than the watcher's start it is processed first; the output files are byte-identical in both runs.main'scompile_dxilfails atwatch_orders["fresh"] == [fresh_key, *backlog](the new key comes last).ctest -j 6 -R "native_compile_dxil|compile_dxil|startup_gfx2hlsl_watch": 5/5 pass.Evidence and follow-up
Synthetic requests only, written by the test. Not covered by the test: a request written during the pass (the rescan between batches) and the once-per-pass filter; only the order of requests present at start is tested. If a rescan fails in the middle of the first pass,
--skip-failedis not switched on, so keys already refused in that pass get one more attempt in the next one. Not measured: the wait in a real run, and passes with several workers (the test uses one); with--jobs > 1,new_worker()now runs per worker per batch instead of per pass.Checklist