nir: avoid segfault when ssa src not found

Without this the following line will segfault and we don't get to
see the results of the validate_assert() above.

Reviewed-by: Jason Ekstrand <jason.ekstrand@intel.com>
This commit is contained in:
Timothy Arceri 2016-08-21 18:31:40 +10:00
parent 47e3cc7557
commit 8ee909ee42

View file

@ -173,6 +173,9 @@ validate_ssa_src(nir_src *src, validate_state *state)
validate_assert(state, entry);
if (!entry)
return;
ssa_def_validate_state *def_state = (ssa_def_validate_state *)entry->data;
validate_assert(state, def_state->where_defined == state->impl &&