From: Francisco Jerez Date: Mon, 14 Mar 2016 02:15:45 +0000 (-0700) Subject: i965/vec4: Consider removal of no-op MOVs as progress during register coalesce. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=7d7990cf657550be4d038a0424ffdc0ef7fd8faa;p=mesa.git i965/vec4: Consider removal of no-op MOVs as progress during register coalesce. Bug found by the liveness analysis validation pass that will be introduced in a later commit. The no-op MOV check in opt_register_coalesce() was removing instructions which makes the cached liveness analysis calculation inconsistent with the shader IR. We were failing to set progress to true in that case though, which means that invalidate_live_intervals() wouldn't necessarily be called at the end of the function. Cc: mesa-stable@lists.freedesktop.org Reviewed-by: Matt Turner --- diff --git a/src/mesa/drivers/dri/i965/brw_vec4.cpp b/src/mesa/drivers/dri/i965/brw_vec4.cpp index cf62ed9a9d6..baf72a25c42 100644 --- a/src/mesa/drivers/dri/i965/brw_vec4.cpp +++ b/src/mesa/drivers/dri/i965/brw_vec4.cpp @@ -1051,6 +1051,7 @@ vec4_visitor::opt_register_coalesce() if (is_nop_mov) { inst->remove(block); + progress = true; continue; } }