From: Jason Ekstrand Date: Fri, 24 Apr 2015 00:10:42 +0000 (-0700) Subject: nir/validate: Validate SSA def parent instructions X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=7ee0216e2d576a02de9d938488a6d6ba55ccb115;p=mesa.git nir/validate: Validate SSA def parent instructions Reviewed-by: Connor Abbott --- diff --git a/src/glsl/nir/nir_validate.c b/src/glsl/nir/nir_validate.c index a7aa79837da..35a853d1484 100644 --- a/src/glsl/nir/nir_validate.c +++ b/src/glsl/nir/nir_validate.c @@ -236,6 +236,8 @@ validate_ssa_def(nir_ssa_def *def, validate_state *state) assert(!BITSET_TEST(state->ssa_defs_found, def->index)); BITSET_SET(state->ssa_defs_found, def->index); + assert(def->parent_instr == state->instr); + assert(def->num_components <= 4); ssa_def_validate_state *def_state = ralloc(state->ssa_defs,