ir3: Don't double-insert the first block

The first block was being added to the list twice, once here and once in
emit_block(), leading to list corruption and infinite loops when trying
to traverse the list of blocks backwards.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4658>
This commit is contained in:
Connor Abbott 2020-04-21 11:27:46 +02:00 committed by Marge Bot
parent 66229aa169
commit 8cfa60eab8

View file

@ -3262,7 +3262,6 @@ emit_instructions(struct ir3_context *ctx)
/* Create inputs in first block: */
ctx->block = get_block(ctx, nir_start_block(fxn));
ctx->in_block = ctx->block;
list_addtail(&ctx->block->node, &ctx->ir->block_list);
/* for fragment shader, the vcoord input register is used as the
* base for bary.f varying fetch instrs: