Cache decoration-bake shader classification #31

Open
github-bot wants to merge 1 commit from github-bot/gh-31 into main AGit
Owner

@⁠avt0m4t48 on GitHub · 2026-12-03 04:00 UTC · original
avt0m4t48:perf-cache-pipeline-bake-key → main · +8 −2 · 2 files · 1 commits · draft

Change

The texture prepass checks whether a bound shader belongs to a known decoration-bake program on each graphics draw when bake-source handling is active. Cache that classification once from the final host pipeline's bound stages. The draw still uses its current depth, render targets and texture size to classify an unfamiliar pipeline. The earlier classification before a host pipeline exists continues to use the same shader predicate.

Verification

An independent replay of the production classifier on the public and integrated source matched 28,000 classifications and 4,125 counted texture-kind lookups per source and CPU setting. The fixtures include recognized and ordinary stage combinations, depth, render-target count, and atlas dimensions. Each of these times is the median per evaluation from 15 alternating Linux x86-64 pairs, using prebuilt pipelines.

Synthetic case Before After
64 ordinary pipelines 23.86 ns 6.02 ns
Mixed known and ordinary pipelines 33.27 ns 9.39 ns
Draws reaching the texture-size fallback 26.51 ns 8.19 ns

The standalone GPU tests and integrated Windows MSVC workspace tests type-checked with diagnostics, pure-Rust BLAKE3 and metadata-only allocator configuration. Both changed files passed the staged asset policy. The full existing tree reports three policy violations in files outside this patch. Pipeline-creation time, native GPU execution and gameplay frame time were unmeasured.

**@⁠avt0m4t48** on GitHub · 2026-12-03 04:00 UTC · [original](https://github.com/linkoovosh/LinkoArts-build/pull/31) `avt0m4t48:perf-cache-pipeline-bake-key` → `main` · +8 −2 · 2 files · 1 commits · draft ### Change The texture prepass checks whether a bound shader belongs to a known decoration-bake program on each graphics draw when bake-source handling is active. Cache that classification once from the final host pipeline's bound stages. The draw still uses its current depth, render targets and texture size to classify an unfamiliar pipeline. The earlier classification before a host pipeline exists continues to use the same shader predicate. ### Verification An independent replay of the production classifier on the public and integrated source matched 28,000 classifications and 4,125 counted texture-kind lookups per source and CPU setting. The fixtures include recognized and ordinary stage combinations, depth, render-target count, and atlas dimensions. Each of these times is the median per evaluation from 15 alternating Linux x86-64 pairs, using prebuilt pipelines. | Synthetic case | Before | After | | --- | ---: | ---: | | 64 ordinary pipelines | 23.86 ns | 6.02 ns | | Mixed known and ordinary pipelines | 33.27 ns | 9.39 ns | | Draws reaching the texture-size fallback | 26.51 ns | 8.19 ns | The standalone GPU tests and integrated Windows MSVC workspace tests type-checked with diagnostics, pure-Rust BLAKE3 and metadata-only allocator configuration. Both changed files passed the staged asset policy. The full existing tree reports three policy violations in files outside this patch. Pipeline-creation time, native GPU execution and gameplay frame time were unmeasured.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-12-04 05:22:12 +00:00
This pull request can be merged automatically.
This branch is out-of-date with the base branch
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin '+refs/pull/31/head:github-bot/gh-31'
git switch 'github-bot/gh-31'

Merge

Merge the changes and update on Forgejo.
git switch 'main'
git merge --no-ff 'github-bot/gh-31'
git switch 'github-bot/gh-31'
git rebase 'main'
git switch 'main'
git merge --ff-only 'github-bot/gh-31'
git switch 'github-bot/gh-31'
git rebase 'main'
git switch 'main'
git merge --no-ff 'github-bot/gh-31'
git switch 'main'
git merge --squash 'github-bot/gh-31'
git switch 'main'
git merge --ff-only 'github-bot/gh-31'
git switch 'main'
git merge 'github-bot/gh-31'
git push origin 'main'
This discussion has been locked. Commenting is limited to contributors.
No description provided.