spirv: Use the generic dereference function for OpArrayLength
authorJason Ekstrand <jason.ekstrand@intel.com>
Sat, 12 Jan 2019 16:57:28 +0000 (10:57 -0600)
committerJason Ekstrand <jason.ekstrand@intel.com>
Tue, 5 Mar 2019 16:06:50 +0000 (10:06 -0600)
With the new deref changes, the old pointer_offset version may not be
the right one to call.  Just call the generic one and let it sort it
out.

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
src/compiler/spirv/vtn_variables.c

index f2bf09034ca9468f2b1766a19902665e01bff123..9a57438a888364f5a6b4212bfd35284edbca251b 100644 (file)
@@ -2454,7 +2454,7 @@ vtn_handle_variables(struct vtn_builder *b, SpvOp opcode,
          struct vtn_access_chain chain = {
             .length = 0,
          };
-         ptr = vtn_ssa_offset_pointer_dereference(b, ptr, &chain);
+         ptr = vtn_pointer_dereference(b, ptr, &chain);
          vtn_assert(ptr->block_index);
       }