<div dir="ltr">For whatever reason, I thought we might have non-ssa phi sources.  However, I looked again and I don't think it's possible.  Also, this patch applies with no piglit regressions.<br></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Feb 3, 2015 at 10:49 AM, Jason Ekstrand <span dir="ltr"><<a href="mailto:jason@jlekstrand.net" target="_blank">jason@jlekstrand.net</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">---<br>
 src/glsl/nir/nir_validate.c | 13 +++----------<br>
 1 file changed, 3 insertions(+), 10 deletions(-)<br>
<br>
diff --git a/src/glsl/nir/nir_validate.c b/src/glsl/nir/nir_validate.c<br>
index 7c801b2..5b47f1a 100644<br>
--- a/src/glsl/nir/nir_validate.c<br>
+++ b/src/glsl/nir/nir_validate.c<br>
@@ -488,16 +488,9 @@ validate_phi_src(nir_phi_instr *instr, nir_block *pred, validate_state *state)<br>
    exec_list_validate(&instr->srcs);<br>
    nir_foreach_phi_src(instr, src) {<br>
       if (src->pred == pred) {<br>
-         unsigned num_components;<br>
-         if (src->src.is_ssa)<br>
-            num_components = src->src.ssa->num_components;<br>
-         else {<br>
-            if (src->src.reg.reg->is_packed)<br>
-               num_components = 4; /* can't check anything */<br>
-            else<br>
-               num_components = src->src.reg.reg->num_components;<br>
-         }<br>
-         assert(num_components == instr->dest.ssa.num_components);<br>
+         assert(src->src.is_ssa);<br>
+         assert(src->src.ssa->num_components ==<br>
+                instr->dest.ssa.num_components);<br>
<br>
          validate_src(&src->src, state);<br>
          return;<br>
<span class="HOEnZb"><font color="#888888">--<br>
2.2.2<br>
<br>
</font></span></blockquote></div><br></div>