summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/amd/common/ac_nir_to_llvm.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/amd/common/ac_nir_to_llvm.c b/src/amd/common/ac_nir_to_llvm.c
index 69d7bead8c1..bd5748d80d5 100644
--- a/src/amd/common/ac_nir_to_llvm.c
+++ b/src/amd/common/ac_nir_to_llvm.c
@@ -2803,7 +2803,7 @@ store_tcs_output(struct nir_to_llvm_context *ctx,
bool store_lds = true;
if (instr->variables[0]->var->data.patch) {
- if (!(ctx->tcs_patch_outputs_read & (1U << instr->variables[0]->var->data.location)))
+ if (!(ctx->tcs_patch_outputs_read & (1U << (instr->variables[0]->var->data.location - VARYING_SLOT_PATCH0))))
store_lds = false;
} else {
if (!(ctx->tcs_outputs_read & (1ULL << instr->variables[0]->var->data.location)))