[Mesa-dev] [PATCH v2 74/78] i965/vec4: Enable NIR-vec4 pass on ARB_vertex_programs

Eduardo Lima Mitev elima at igalia.com
Thu Jul 23 03:17:54 PDT 2015


From: Antia Puentes <apuentes at igalia.com>

---
 src/mesa/drivers/dri/i965/brw_vec4.cpp | 22 ++++++++++------------
 1 file changed, 10 insertions(+), 12 deletions(-)

diff --git a/src/mesa/drivers/dri/i965/brw_vec4.cpp b/src/mesa/drivers/dri/i965/brw_vec4.cpp
index f77f570..a569c58 100644
--- a/src/mesa/drivers/dri/i965/brw_vec4.cpp
+++ b/src/mesa/drivers/dri/i965/brw_vec4.cpp
@@ -1732,18 +1732,16 @@ vec4_visitor::run(gl_clip_plane *clip_planes)
 
    emit_prolog();
 
-   if (shader) {
-      if (use_vec4_nir) {
-         assert(prog->nir != NULL);
-         emit_nir_code();
-         if (failed)
-            return false;
-      } else {
-         /* Generate VS IR for main().  (the visitor only descends into
-          * functions called "main").
-          */
-         visit_instructions(shader->base.ir);
-      }
+   if (use_vec4_nir) {
+      assert(prog->nir != NULL);
+      emit_nir_code();
+      if (failed)
+         return false;
+   } else if (shader) {
+      /* Generate VS IR for main().  (the visitor only descends into
+       * functions called "main").
+       */
+      visit_instructions(shader->base.ir);
    } else {
       emit_program_code();
    }
-- 
2.1.4



More information about the mesa-dev mailing list