Shaders: legacy geometry PSOs retranslate the same ES+GS pair for every pixel shader (verification help wanted) #2876

Open
opened 2026-11-26 20:37:49 +00:00 by github-bot · 0 comments
Owner

@⁠KOLESNiii on GitHub · 2026-11-26 20:33 UTC · original

Could someone verify whether legacy geometry PSOs spend measurable CPU time retranslating the same ES+GS pair when only the pixel shader or fixed-function state changes?

On main at 8b957bec, translated_gs_pso calls console_geometry before either native driver-cache lookup. console_geometry reparses and combines the ES and GS and runs direct DXIL lowering or generates HLSL before looking up the DXC result. By comparison, the NGG mesh path caches its compute pass before making the pixel-signature-specific mesh passthrough. GS caller · ES+GS translation · HLSL cache lookup · NGG compute-pass cache

A Windows check could create two valid PSOs with identical console VS/GS bytes and different PS or fixed-function state, after warming DXC and the driver blobs. Count and time the ES+GS lowering calls separately from passthrough generation and native PSO creation. Please verify whether the repeat work also shows up in a representative title before deciding if it warrants a cache.

This was a static source review on Linux. PR #2103 covers deferring direct geometry lowering during a cached-only probe. This report asks about repeated lowering across builds that proceed to translation.

AI use: Codex (GPT-6, exact serving variant unavailable) for the Graphify-assisted review and issue draft.

**@⁠KOLESNiii** on GitHub · 2026-11-26 20:33 UTC · [original](https://github.com/xcl-dev/xcl/issues/2876) Could someone verify whether legacy geometry PSOs spend measurable CPU time retranslating the same ES+GS pair when only the pixel shader or fixed-function state changes? On `main` at `8b957bec`, `translated_gs_pso` calls `console_geometry` before either native driver-cache lookup. `console_geometry` reparses and combines the ES and GS and runs direct DXIL lowering or generates HLSL before looking up the DXC result. By comparison, the NGG mesh path caches its compute pass before making the pixel-signature-specific mesh passthrough. [GS caller](https://github.com/xcl-dev/xcl/blob/8b957bec6f82495aec940944c6bf47faa02db590/crates/xcl/src/hle/d3d12x/real.rs#L6305-L6310) · [ES+GS translation](https://github.com/xcl-dev/xcl/blob/8b957bec6f82495aec940944c6bf47faa02db590/crates/xcl/src/gpu/recomp/pso.rs#L1219-L1238) · [HLSL cache lookup](https://github.com/xcl-dev/xcl/blob/8b957bec6f82495aec940944c6bf47faa02db590/crates/xcl/src/gpu/recomp/pso.rs#L1081-L1087) · [NGG compute-pass cache](https://github.com/xcl-dev/xcl/blob/8b957bec6f82495aec940944c6bf47faa02db590/crates/xcl/src/gpu/recomp/pso.rs#L1145-L1163) A Windows check could create two valid PSOs with identical console VS/GS bytes and different PS or fixed-function state, after warming DXC and the driver blobs. Count and time the ES+GS lowering calls separately from passthrough generation and native PSO creation. Please verify whether the repeat work also shows up in a representative title before deciding if it warrants a cache. This was a static source review on Linux. PR #2103 covers deferring direct geometry lowering during a cached-only probe. This report asks about repeated lowering across builds that proceed to translation. AI use: Codex (GPT-6, exact serving variant unavailable) for the Graphify-assisted review and issue draft.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 20:37:49 +00:00
github-bot changed title from Verify whether legacy geometry PSOs repeat ES+GS translation on warm caches to Shaders: legacy geometry PSOs retranslate the same ES+GS pair for every pixel shader (verification help wanted) 2026-11-27 02:06:36 +00:00
This discussion has been locked. Commenting is limited to contributors.
No description provided.