Module: Mesa
Branch: staging/22.2
Commit: 46d66bcb6f412337ff1b75227e426e5e387443ab
URL:    
http://cgit.freedesktop.org/mesa/mesa/commit/?id=46d66bcb6f412337ff1b75227e426e5e387443ab

Author: Timur Kristóf <[email protected]>
Date:   Wed Aug 31 15:04:58 2022 +0200

aco: Fix p_init_scratch for task shaders.

Fixes: d2d94b62f2a4f8686c17b7c33ae02aa2b2029a27
Signed-off-by: Timur Kristóf <[email protected]>
Reviewed-by: Rhys Perry <[email protected]>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18339>
(cherry picked from commit 16c14663e569340a301d2a1851f6df3b465fb81b)

---

 .pick_status.json                          | 2 +-
 src/amd/compiler/aco_lower_to_hw_instr.cpp | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/.pick_status.json b/.pick_status.json
index a5b13e3196e..e90425c41fd 100644
--- a/.pick_status.json
+++ b/.pick_status.json
@@ -6970,7 +6970,7 @@
         "description": "aco: Fix p_init_scratch for task shaders.",
         "nominated": true,
         "nomination_type": 1,
-        "resolution": 0,
+        "resolution": 1,
         "main_sha": null,
         "because_sha": "d2d94b62f2a4f8686c17b7c33ae02aa2b2029a27"
     },
diff --git a/src/amd/compiler/aco_lower_to_hw_instr.cpp 
b/src/amd/compiler/aco_lower_to_hw_instr.cpp
index 6250b7f285d..e59b95a21da 100644
--- a/src/amd/compiler/aco_lower_to_hw_instr.cpp
+++ b/src/amd/compiler/aco_lower_to_hw_instr.cpp
@@ -2334,7 +2334,7 @@ lower_to_hw_instr(Program* program)
 
                Operand scratch_addr = instr->operands[0];
                Operand scratch_addr_lo(scratch_addr.physReg(), s1);
-               if (program->stage != compute_cs) {
+               if (program->stage.hw != HWStage::CS) {
                   bld.smem(aco_opcode::s_load_dwordx2, instr->definitions[0], 
scratch_addr,
                            Operand::zero());
                   scratch_addr_lo.setFixed(instr->definitions[0].physReg());

Reply via email to