From: Rhys Perry Date: Wed, 8 Jan 2020 16:13:03 +0000 (+0000) Subject: aco: error when block has no logical preds but VGPRs are live at the start X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=4e83e05e62101a5e3a4d8c30a16ca15294af18b1;p=mesa.git aco: error when block has no logical preds but VGPRs are live at the start This would have caught the liveness error fixed in the previous commit. Signed-off-by: Rhys Perry Reviewed-by: Daniel Schürmann Part-of: --- diff --git a/src/amd/compiler/aco_live_var_analysis.cpp b/src/amd/compiler/aco_live_var_analysis.cpp index c00325b92b7..1f02e67bc1a 100644 --- a/src/amd/compiler/aco_live_var_analysis.cpp +++ b/src/amd/compiler/aco_live_var_analysis.cpp @@ -220,7 +220,8 @@ void process_live_temps_per_block(Program *program, live& lives, Block* block, phi_idx--; } - if (!(block->index != 0 || (live_vgprs.empty() && live_sgprs.empty()))) { + if ((block->logical_preds.empty() && !live_vgprs.empty()) || + (block->linear_preds.empty() && !live_sgprs.empty())) { aco_print_program(program, stderr); fprintf(stderr, "These temporaries are never defined or are defined after use:\n"); for (Temp vgpr : live_vgprs)