Module: Mesa Branch: main Commit: 9d4104d4fb21813b527805cf3b40e133cab4d028 URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=9d4104d4fb21813b527805cf3b40e133cab4d028
Author: Gert Wollny <[email protected]> Date: Fri Jul 21 17:08:24 2023 +0200 r600: Explicitly force new CF in gs copy shader With that we can assert on ALU CF mission in the assembler Signed-off-by: Gert Wollny <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24297> --- src/gallium/drivers/r600/r600_shader.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/gallium/drivers/r600/r600_shader.c b/src/gallium/drivers/r600/r600_shader.c index be22e459bcd..e06b7f7e982 100644 --- a/src/gallium/drivers/r600/r600_shader.c +++ b/src/gallium/drivers/r600/r600_shader.c @@ -22,6 +22,8 @@ */ #include "nir_serialize.h" #include "pipe/p_defines.h" +#include "r600_asm.h" +#include "r600_isa.h" #include "r600_sq.h" #include "r600_formats.h" #include "r600_opcodes.h" @@ -510,6 +512,9 @@ static int emit_streamout(struct r600_shader_ctx *ctx, struct pipe_stream_output } } + if (so->num_outputs && ctx->bc->cf_last->op != CF_OP_ALU && + ctx->bc->cf_last->op != CF_OP_ALU_PUSH_BEFORE) + ctx->bc->force_add_cf = 1; /* Initialize locations where the outputs are stored. */ for (i = 0; i < so->num_outputs; i++) { @@ -728,6 +733,7 @@ int generate_gs_copy_shader(struct r600_context *rctx, alu.execute_mask = 1; alu.update_pred = 1; alu.last = 1; + ctx.bc->force_add_cf = 1; r600_bytecode_add_alu_type(ctx.bc, &alu, CF_OP_ALU_PUSH_BEFORE); r600_bytecode_add_cfinst(ctx.bc, CF_OP_JUMP);
