nir: Add a vulkan_resource_reindex intrinsic
authorJason Ekstrand <jason.ekstrand@intel.com>
Thu, 30 Nov 2017 23:56:39 +0000 (15:56 -0800)
committerJason Ekstrand <jason.ekstrand@intel.com>
Wed, 6 Dec 2017 06:01:54 +0000 (22:01 -0800)
commitcfb81f58a0c3f5f8dfde3d0783ff5211b657f895
tree0c6a41593578f0c3e81fd4c0fffa45cb4a281c29
parentae54a4f84fb6b440d7a8a57651965a4d9eed725b
nir: Add a vulkan_resource_reindex intrinsic

This is required for being able to handle OpPtrAccessChain in SPIR-V
where the base type of the incoming pointer requires us to add to the
block index instead of the byte offset.

Reviewed-by: Kristian H. Kristensen <hoegsberg@google.com>
src/compiler/nir/nir_intrinsics.h