shader/dxil: add pack/unpack and Call folding peepholes plus pure CBV CSE #515
No reviewers
Labels
No labels
AMD
audio
bug
confirmed
crash
cutscene
dlss
documentation
duplicate
enhancement
fixed-on-main
frame-generation
hle
input
INTEL
lighting
linux-proton
memory
MULDER
needs-info
needs-logs
needs-rebase
NVIDIA
performance
post-merge
pr-diagnostics
pr-docs
pre-merge
pr-feature
pr-fix
pr-performance
pr-refactor
pr-tests
question
RAYTRACING
relevance
high
relevance
low
relevance
medium
relevance
very-high
rendering
report
roadmap-proposal
saves
series-s
shaders
startup
status
blocked-by-rework
status
needs-test-report
status
needs-triage
status
ready-for-review
status
stale
status
superseded
status
wip
tools
ui
upstream
wontfix
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
TrustNo1/Darner!515
Loading…
Reference in a new issue
No description provided.
Delete branch "hingeowl/Darner:pr/dxil-peepholes-cbv-cse"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
What it changes
Saturate/FAbs/UMin), and immutableconstants_rawrawBufferLoadinstructions un-CSE'd across UAV stores and loops.ReTerryDavis/ReVIctory(91ba689490f565ab710e60663c35bc07f097e736):Trunc(Or(..., Shl(..., 16)))andTrunc(LShr(Or(...), 16))patterns (emit/bitcode/opt.rs).Op::Callpatterns:Saturate(Saturate(x)),FAbs(FAbs|Saturate(x)), andUMin(UMin(x, k1), k2).constants_rawrawBufferLoadinstructions inModule::pure_readsso they CSE across UAV stores and loops asEffect::Pure.How it was tested
649e2af(based onmainc8258f9)cargo xtask policy— passcargo clippy --workspace --all-targets --locked -- -D warnings— passcargo clippy --workspace --all-targets --all-features --locked -- -D warnings— passcargo test -p darner-shader --locked -- opt::— pass (includes GPU bit-exact parity tests)cam-city60(RTX 4090 + Ryzen 9 7950X3D, Series X, HW RT) as part of our integration branch with clean visuals.cargo xtask policy, both workspaceclippygates,cargo test -p darner-shader --locked -- opt::.Checklist
main.docs/asset-policy.md.Checked for overlap
Standalone A/B from an RTX 4080, since the PR has none yet: no change in card time or frame time in this scene.
PC: RTX 4080 16 GB (driver 621.40), i7-13700K, 64 GB, Windows 11 26300. Series X profile, 1440p with DLSS Quality, frame generation off, hardware ray tracing on, Reflex off (so the card is the limit here),
DARNER_ALIAS_SHARE=1,DARNER_D3D12_BACKGROUND=0.Builds: A = main
9b288a7+ #303 + #457. B = A + this PR (649e2af), merged cleanly.Method: the opening scene of one save, entered the same way every run (no input after the start screen); medians of per-second values from the host log in three 45-second windows from the moment the world appears. B had two warm-up runs first (new translations); A's pipelines were warm. Order: B, A, B, A.
The run-to-run spread of the frame time here is about 1 ms, so only the card time says something: the same within 0.1 ms. The lit living room 20 to 100 s in looks the same as A's. This scene is indoors and light on half-precision work, so it says nothing about shaders that use the folded pack/unpack patterns a lot.
Not tested: other cards, other scenes, the gates.
[pr-performance][shaders] shader/dxil: add pack/unpack and Call folding peepholes plus pure CBV CSEto shader/dxil: add pack/unpack and Call folding peepholes plus pure CBV CSEView command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.