freedreno/ir3: fix const assert
authorRob Clark <robdclark@chromium.org>
Fri, 19 Apr 2019 18:32:22 +0000 (11:32 -0700)
committerRob Clark <robdclark@chromium.org>
Fri, 19 Apr 2019 19:36:06 +0000 (12:36 -0700)
Fixes: fe8c57e859d freedreno/ir3: use nir_src_as_uint in a few places
Signed-off-by: Rob Clark <robdclark@chromium.org>
src/freedreno/ir3/ir3_image.c

index a476b98dfc28854aa5ba5876741fa580e3d86ca9..835b5381d233ff9b9d323fe05f16cc8f61e100b9 100644 (file)
@@ -96,7 +96,6 @@ ir3_get_image_slot(nir_deref_instr *deref)
        while (deref->deref_type != nir_deref_type_var) {
                assert(deref->deref_type == nir_deref_type_array);
                unsigned const_index = nir_src_as_uint(deref->arr.index);
-               assert(const_index);
 
                /* Go to the next instruction */
                deref = nir_deref_instr_parent(deref);