[Mesa-dev] [PATCH] i965/vs: Remove unnecessary NULL check on generate_code() result.

Kenneth Graunke kenneth at whitecape.org
Sat Apr 25 09:47:59 PDT 2015


Code generation is not allowed to fail for any reason - in fact,
fs_generator has no mechanism for failing.  The visitor is responsible
for that.

Signed-off-by: Kenneth Graunke <kenneth at whitecape.org>
---
 src/mesa/drivers/dri/i965/brw_vec4.cpp | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/src/mesa/drivers/dri/i965/brw_vec4.cpp b/src/mesa/drivers/dri/i965/brw_vec4.cpp
index 9398adc..8ce07637 100644
--- a/src/mesa/drivers/dri/i965/brw_vec4.cpp
+++ b/src/mesa/drivers/dri/i965/brw_vec4.cpp
@@ -1868,8 +1868,7 @@ brw_vs_emit(struct brw_context *brw,
       g.generate_code(v.cfg, 8);
       assembly = g.get_assembly(final_assembly_size);
 
-      if (assembly)
-         prog_data->base.simd8 = true;
+      prog_data->base.simd8 = true;
       c->base.last_scratch = v.last_scratch;
    }
 
-- 
2.3.6



More information about the mesa-dev mailing list