diff options
author | Eric Anholt <[email protected]> | 2019-07-16 11:59:35 -0700 |
---|---|---|
committer | Eric Anholt <[email protected]> | 2019-07-18 11:28:56 -0700 |
commit | 40e760960319bc8c9ee943c3d8136e23ef474d59 (patch) | |
tree | 7541abfa706d04d278c5893a324fa91d102b8aab /src/broadcom | |
parent | 1bced0fad2feeca34ef9d2a2d28b05e234d25e36 (diff) |
v3d: Fix assertion failures in debug builds.
nir_lower_io leaves around deref_var instructions after lowering away
deref intrinsics. This ends up breaking validation after v3d_nir_lower_io
removes variables not actually being stored by the shader's
store_output()s.
Reviewed-by: Iago Toral Quiroga <[email protected]>
Diffstat (limited to 'src/broadcom')
-rw-r--r-- | src/broadcom/compiler/vir.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/broadcom/compiler/vir.c b/src/broadcom/compiler/vir.c index c18318a6295..04129fa522e 100644 --- a/src/broadcom/compiler/vir.c +++ b/src/broadcom/compiler/vir.c @@ -761,6 +761,8 @@ v3d_nir_lower_vs_early(struct v3d_compile *c) NIR_PASS_V(c->s, nir_lower_io, nir_var_shader_in | nir_var_shader_out, type_size_vec4, (nir_lower_io_options)0); + /* clean up nir_lower_io's deref_var remains */ + NIR_PASS_V(c->s, nir_opt_dce); } static void |