From 42e21c751b050528095c48322c43889c453f211e Mon Sep 17 00:00:00 2001 From: Connor Abbott Date: Fri, 1 Oct 2021 12:15:10 +0200 Subject: [PATCH] ir3: Insert frag coord code after preamble To match the pre-preamble behavior, and so that we can better schedule it. Part-of: --- src/freedreno/ir3/ir3_compiler_nir.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/freedreno/ir3/ir3_compiler_nir.c b/src/freedreno/ir3/ir3_compiler_nir.c index 481db2b48e7..ecaf8e77fb3 100644 --- a/src/freedreno/ir3/ir3_compiler_nir.c +++ b/src/freedreno/ir3/ir3_compiler_nir.c @@ -1825,7 +1825,7 @@ static struct ir3_instruction * get_frag_coord(struct ir3_context *ctx, nir_intrinsic_instr *intr) { if (!ctx->frag_coord) { - struct ir3_block *b = ctx->in_block; + struct ir3_block *b = ir3_after_preamble(ctx->ir); struct ir3_instruction *xyzw[4]; struct ir3_instruction *hw_frag_coord;