diff --git a/src/compiler/spirv/vtn_cfg.c b/src/compiler/spirv/vtn_cfg.c index dd91352bfbd..5a71fd98209 100644 --- a/src/compiler/spirv/vtn_cfg.c +++ b/src/compiler/spirv/vtn_cfg.c @@ -700,12 +700,10 @@ vtn_process_block(struct vtn_builder *b, return NULL; case SpvOpKill: - b->has_early_terminate = true; block->branch_type = vtn_branch_type_discard; return NULL; case SpvOpTerminateInvocation: - b->has_early_terminate = true; block->branch_type = vtn_branch_type_terminate_invocation; return NULL; @@ -1170,8 +1168,6 @@ vtn_emit_cf_list_structured(struct vtn_builder *b, struct list_head *cf_list, nir_pop_if(&b->nb, cont_if); nir_store_var(&b->nb, do_cont, nir_imm_true(&b->nb), 1); - - b->has_loop_continue = true; } nir_pop_loop(&b->nb, loop); @@ -1377,7 +1373,6 @@ vtn_function_emit(struct vtn_builder *b, struct vtn_function *func, b->func = func; b->nb.cursor = nir_after_cf_list(&impl->body); b->nb.exact = b->exact; - b->has_loop_continue = false; b->phi_table = _mesa_pointer_hash_table_create(b); if (b->shader->info.stage == MESA_SHADER_KERNEL || force_unstructured) { diff --git a/src/compiler/spirv/vtn_private.h b/src/compiler/spirv/vtn_private.h index df16b8a335d..67c2d4420ae 100644 --- a/src/compiler/spirv/vtn_private.h +++ b/src/compiler/spirv/vtn_private.h @@ -717,21 +717,6 @@ struct vtn_builder { /* Current function parameter index */ unsigned func_param_idx; - bool has_loop_continue; - - /** True if this shader has any early termination instructions like OpKill - * - * In the SPIR-V, the following instructions are block terminators: - * - * - OpKill - * - OpTerminateInvocation - * - * However, in NIR, they're represented by regular intrinsics with no - * control-flow semantics. This means that the SSA form from the SPIR-V - * may not 100% match NIR and we have to fix it up at the end. - */ - bool has_early_terminate; - /* false by default, set to true by the ContractionOff execution mode */ bool exact;