From c54f622a93ffc33d988417b7f5625dd413ea9a7e Mon Sep 17 00:00:00 2001 From: Faith Ekstrand Date: Tue, 12 Sep 2023 14:37:58 -0500 Subject: [PATCH] nak: Set TLS size properly in the shader header We were only accounting for load/store_scratch before, not spilling. Pull the value from the Shader, that one's accurate. Part-of: --- src/nouveau/compiler/nak.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/nouveau/compiler/nak.rs b/src/nouveau/compiler/nak.rs index 4e2224db9e5..e04337585e3 100644 --- a/src/nouveau/compiler/nak.rs +++ b/src/nouveau/compiler/nak.rs @@ -496,7 +496,7 @@ pub extern "C" fn nak_compile_shader( ], smem_size: nir.info.shared_size.try_into().unwrap(), }, - hdr: encode_hdr_for_nir(nir, nir.scratch_size), + hdr: encode_hdr_for_nir(nir, s.tls_size, fs_key), }; let code = if nak.sm >= 75 {