diff options
author | Caio Marcelo de Oliveira Filho <[email protected]> | 2019-05-02 15:53:22 -0700 |
---|---|---|
committer | Caio Marcelo de Oliveira Filho <[email protected]> | 2019-05-20 10:53:38 -0700 |
commit | bdf2361b87844cd5697aa895bc71b28b0d396c86 (patch) | |
tree | 630d7d8252959df91ee07c7ad1d4de9cf0470f4d /src/compiler | |
parent | f051fa6ad7363556408f69594a487a84523871a9 (diff) |
spirv: Export vtn_storage_class_to_mode()
So we can reuse in spirv_to_nir.c.
Reviewed-by: Jason Ekstrand <[email protected]>
Reviewed-by: Bas Nieuwenhuizen <[email protected]>
Diffstat (limited to 'src/compiler')
-rw-r--r-- | src/compiler/spirv/vtn_private.h | 5 | ||||
-rw-r--r-- | src/compiler/spirv/vtn_variables.c | 2 |
2 files changed, 6 insertions, 1 deletions
diff --git a/src/compiler/spirv/vtn_private.h b/src/compiler/spirv/vtn_private.h index cfe2893e04f..faaf94a40b1 100644 --- a/src/compiler/spirv/vtn_private.h +++ b/src/compiler/spirv/vtn_private.h @@ -799,6 +799,11 @@ void vtn_handle_entry_point(struct vtn_builder *b, const uint32_t *w, void vtn_handle_decoration(struct vtn_builder *b, SpvOp opcode, const uint32_t *w, unsigned count); +enum vtn_variable_mode vtn_storage_class_to_mode(struct vtn_builder *b, + SpvStorageClass class, + struct vtn_type *interface_type, + nir_variable_mode *nir_mode_out); + static inline uint32_t vtn_align_u32(uint32_t v, uint32_t a) { diff --git a/src/compiler/spirv/vtn_variables.c b/src/compiler/spirv/vtn_variables.c index 91f7002734e..1ddac6c4c1c 100644 --- a/src/compiler/spirv/vtn_variables.c +++ b/src/compiler/spirv/vtn_variables.c @@ -1716,7 +1716,7 @@ ptr_decoration_cb(struct vtn_builder *b, struct vtn_value *val, int member, } } -static enum vtn_variable_mode +enum vtn_variable_mode vtn_storage_class_to_mode(struct vtn_builder *b, SpvStorageClass class, struct vtn_type *interface_type, |