anv/apply_pipeline_layout: Stomp texture array size to 1
authorJason Ekstrand <jason.ekstrand@intel.com>
Fri, 15 Jan 2016 02:58:25 +0000 (18:58 -0800)
committerJason Ekstrand <jason.ekstrand@intel.com>
Fri, 15 Jan 2016 02:58:25 +0000 (18:58 -0800)
src/vulkan/anv_nir_apply_pipeline_layout.c

index 7410bd8363f6a0d605e913d8fcf58dc31fac1622..b7b8bd18ef9601305ddfc306afdecac9c0501afa 100644 (file)
@@ -203,6 +203,11 @@ lower_tex(nir_tex_instr *tex, struct apply_pipeline_layout_state *state)
    lower_tex_deref(tex, tex->sampler, &tex->sampler_index,
                    nir_tex_src_sampler_offset, state);
 
+   /* The backend only ever uses this to mark used surfaces.  We don't care
+    * about that little optimization so it just needs to be non-zero.
+    */
+   tex->texture_array_size = 1;
+
    if (tex->texture)
       cleanup_tex_deref(tex, tex->texture);
    cleanup_tex_deref(tex, tex->sampler);