diff --git a/crates/victory-gpu/src/pipeline/make.rs b/crates/victory-gpu/src/pipeline/make.rs index 898dcb7..921b850 100644 --- a/crates/victory-gpu/src/pipeline/make.rs +++ b/crates/victory-gpu/src/pipeline/make.rs @@ -56,7 +56,28 @@ fn named(shaders: &[Arc], name: &[u8]) -> bool { .any(|s| s.stage == "compute" && s.container.windows(name.len()).any(|w| w == name)) } +/// Shader hashes whose pipelines are left out in every build +/// (`VICTORY_LEAVE_OUT=<16 hex digits>[,..]`; `VICTORY_SKIP_PIPELINES` does +/// the same in diagnostics builds only). The decal heap's +/// `CS_DefragHeap_ComputeRelocations` (02384a60fda6f2d0), translatable for +/// 32-lane hosts through host waves that meet by spinning, took 11.85 ms of +/// the card a frame in the first gameplay area (timing run, 2026-11-26). +fn leave_out() -> &'static [String] { + static HASHES: OnceLock> = OnceLock::new(); + HASHES.get_or_init(|| { + std::env::var("VICTORY_LEAVE_OUT") + .unwrap_or_default() + .split(',') + .map(|h| h.trim().to_ascii_lowercase()) + .filter(|h| h.len() == 16 && h.bytes().all(|b| b.is_ascii_hexdigit())) + .collect() + }) +} + fn left_out(shaders: &[Arc]) -> Option<&'static str> { + if !leave_out().is_empty() && shaders.iter().any(|s| leave_out().contains(&s.hash)) { + return Some("named in VICTORY_LEAVE_OUT, left out"); + } static SKIP_RT_RESOLVE: OnceLock = OnceLock::new(); let skip_rt = *SKIP_RT_RESOLVE.get_or_init(|| { let builder = std::env::var_os("VICTORY_BVH_BUILDER").is_some_and(|v| v == "1");