spirv: Refactor the base case of offset_pointer_dereference
authorJason Ekstrand <jason.ekstrand@intel.com>
Wed, 18 Oct 2017 23:40:39 +0000 (16:40 -0700)
committerJason Ekstrand <jason.ekstrand@intel.com>
Wed, 6 Dec 2017 04:56:14 +0000 (20:56 -0800)
commit93646fb503342ecac3e5df247b90c15ca65c1e0a
tree2bb9096cf0ff699ce8e652708e5bfc7aa9c26bdd
parent98edf6bca4ba626cd0ab5da71bf09eaf3e90e444
spirv: Refactor the base case of offset_pointer_dereference

This makes us key off of !offset instead of !block_index.  It also puts
the guts inside a switch statement so that we can handle more than just
UBOs and SSBOs.

Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Kristian H. Kristensen <hoegsberg@google.com>
src/compiler/spirv/vtn_variables.c