summaryrefslogtreecommitdiffstats
path: root/src/compiler/spirv/vtn_private.h
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2018-03-30 11:10:11 -0600
committerBrian Paul <[email protected]>2018-03-30 14:33:33 -0600
commitf3164c2ed96a119c73f16c4703bf5ad9feff1416 (patch)
tree63cad69d89138978278dc3f682dc43fd0e030419 /src/compiler/spirv/vtn_private.h
parentcb619a3c9a49d27f60a2a616f719af17bc9f54d2 (diff)
nir/spirv: s/uint32_t/SpvOp/ in various functions
The MSVC compiler warns when the function parameter types don't exactly match with respect to enum vs. uint32_t. Use SpvOp everywhere. Alternately, uint32_t could be used everywhere. There doesn't seem to be an advantage to one over the other. Reviewed-by: Neil Roberts <[email protected]>
Diffstat (limited to 'src/compiler/spirv/vtn_private.h')
-rw-r--r--src/compiler/spirv/vtn_private.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/compiler/spirv/vtn_private.h b/src/compiler/spirv/vtn_private.h
index 982b426e70d..b501bbf9b4a 100644
--- a/src/compiler/spirv/vtn_private.h
+++ b/src/compiler/spirv/vtn_private.h
@@ -230,7 +230,7 @@ struct vtn_function {
SpvFunctionControlMask control;
};
-typedef bool (*vtn_instruction_handler)(struct vtn_builder *, uint32_t,
+typedef bool (*vtn_instruction_handler)(struct vtn_builder *, SpvOp,
const uint32_t *, unsigned);
void vtn_build_cfg(struct vtn_builder *b, const uint32_t *words,
@@ -718,7 +718,7 @@ void vtn_handle_alu(struct vtn_builder *b, SpvOp opcode,
void vtn_handle_subgroup(struct vtn_builder *b, SpvOp opcode,
const uint32_t *w, unsigned count);
-bool vtn_handle_glsl450_instruction(struct vtn_builder *b, uint32_t ext_opcode,
+bool vtn_handle_glsl450_instruction(struct vtn_builder *b, SpvOp ext_opcode,
const uint32_t *words, unsigned count);
struct vtn_builder* vtn_create_builder(const uint32_t *words, size_t word_count,
@@ -744,9 +744,9 @@ vtn_u64_literal(const uint32_t *w)
return (uint64_t)w[1] << 32 | w[0];
}
-bool vtn_handle_amd_gcn_shader_instruction(struct vtn_builder *b, uint32_t ext_opcode,
+bool vtn_handle_amd_gcn_shader_instruction(struct vtn_builder *b, SpvOp ext_opcode,
const uint32_t *words, unsigned count);
-bool vtn_handle_amd_shader_trinary_minmax_instruction(struct vtn_builder *b, uint32_t ext_opcode,
+bool vtn_handle_amd_shader_trinary_minmax_instruction(struct vtn_builder *b, SpvOp ext_opcode,
const uint32_t *words, unsigned count);
#endif /* _VTN_PRIVATE_H_ */