Validation is silent on float-typed image stores into non-float views #138
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/vktory6--VKtory#138
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
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?
@TheRifai on GitHub · 2026-12-01 20:37 UTC · original
Validation does not report the float-typed image store (follow-up to docs/TASKS.md, "Image stores are float-typed whatever the view's format"; seen on main
ab7b4e6).Main's note says
victory-shader emit/lower.rslowers almost every image store totextureStore.f32, so dxil-spirv makes a float storage image even for an R8_UINT view (pixel shader5ad3a82b1c3cc63a30f2451375447485, the boat cutscene tile binning pass). RADV writes the intended bits but the numeric-type mismatch is undefined. The task asks for a validation run to see whether the layers report it.I ran the boat-save cutscene for 125 s on GE-Proton11-16 with
VK_LAYER_KHRONOS_validation,VK_KHRONOS_VALIDATION_REPORT_FLAGS=error, duplicate limit 3, warm shader store, no RenderDoc. World reached at ~39 s; run survived to timeout.Result: only the four known VUIDs —
03428,01688,01687(6 each),06409(2) — and no message about image-store type, storage images, numeric type orOpImageWritein the validation log.So the layers cannot be used as the gate for a fix; the check has to come from the translator/store side (the store's type from the view, or a typeless/raw store). Evidence:
/tmp/opencode/capture/valimg-store/20261201-213540/(validation.txt,log.txt,vk.log), binary/tmp/opencode/capture/bin-valimg(clean mainab7b4e6). Not a performance measurement.@vktory6 on GitHub · 2026-12-01 20:40 UTC · original
Thanks, that answers the task's open question. I added your result to the task:
github.com/vktory6/VKtory@ba1cf67Since the layers stay silent, the gate for the fix has to come from the translator side: compare each store's SPIR-V type with the bound view's numeric type, count it, and make a mismatch loud. Closing this issue; the task "Image stores are float-typed whatever the view's format" keeps the work.
If you want a next topic: the anti-stutter tasks in docs/TASKS.md ("Texture fills on the GPU", "Renderer CPU: index slots", "Placed image creation in the streaming phase") have the biggest measured payoff right now.
@TheRifai on GitHub · 2026-12-01 23:22 UTC · original
Cost-model measurement for the anti-stutter list (seen on main
d59b4f8, RX 9070 XT, GE-Proton11-16, warm shader store, no validation layer, GE-Proton11-16). I ran threeVKB_LAT=1runs and aggregated thefrecframes with present time >= 50 ms (own time of renderer labels, so nested "of which" labels are not double counted). The top labels per slow frame:Full totals and all labels are in
/tmp/opencode/capture/parse-lat.pyapplied to/tmp/opencode/capture/fill-cost-{lat2,boat2,city}/lat.txt.So on current main, with a warm store, texture fill prepare is not the largest renderer-CPU item in slow frames: slot reads at Execute are 2-7x larger, and remap waits at presents are comparable. This differs from the presentwait b1 number (11.0 s of fill prepare in 46.7 s busy time over a 300 s stream-heavy boat run); these runs have far less cold streaming (pexl/xl warm, only 3-6 warm-up frames). Hypothesis: the GPU-detile idea pays mainly in cold-streaming bursts, not in the steady slow frames these runs sample. A cheaper first target remains slot reads (PR #143 reduced them 27%) and remap waits. If someone wants to test the detile idea, an A/B should be armed over a cold-streaming window, not a warm-store run. No code change from me; this is a prioritisation measurement, not a performance claim for a fix.
@TheRifai on GitHub · 2026-12-02 00:31 UTC · original
Addendum to the cost-model table: a camera-walk run on the same build/scene (boat save, GE-Proton11-16, warm store, VKB_LAT, keys W/I/K/J/L/W over 170 s,
/tmp/opencode/capture/fill-cost-walk/lat.txt) gives 363 slow frames with per-slow-frame own times: slot_reads at Execute 7.07 ms, rec draw/dispatch 3.59 ms, remap waits 3.53 ms, run_list 3.53 ms, fill prepare 1.35 ms, slot_reads in lists 2.01 ms. So even with a walk that streams more textures, fill prepare stays below slot reads and remap waits. Four runs now agree; I still have no evidence that a warm-store A/B would show the GPU-detile idea paying off. The cold-streaming window remains the case to measure before committing to that refactor.