From 89647cffb31ee1ea42d581b1053b4bb147b3e58a Mon Sep 17 00:00:00 2001 From: Paul Berry Date: Wed, 16 Oct 2013 13:13:20 -0700 Subject: [PATCH] i965/vec4: if register allocation fails, don't try to schedule. Otherwise the scheduler would be invoked with prog_data->total_grf == 0, causing havoc. In a future patch, this will allow us to try compiling a geometry shader in DUAL_OBJECT mode with spilling disabled, and then fall back to DUAL_INSTANCED mode if that failed. Reviewed-by: Eric Anholt --- src/mesa/drivers/dri/i965/brw_vec4.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mesa/drivers/dri/i965/brw_vec4.cpp b/src/mesa/drivers/dri/i965/brw_vec4.cpp index 589de48f33a..9cbbae0212a 100644 --- a/src/mesa/drivers/dri/i965/brw_vec4.cpp +++ b/src/mesa/drivers/dri/i965/brw_vec4.cpp @@ -1520,7 +1520,7 @@ vec4_visitor::run() while (!reg_allocate()) { if (failed) - break; + return false; } opt_schedule_instructions(); -- 2.30.2