} else if (opcode == SpvOpImage) {
struct vtn_value *src_val = vtn_untyped_value(b, w[3]);
if (src_val->value_type == vtn_value_type_sampled_image) {
- vtn_push_value_pointer(b, w[2], src_val->sampled_image->image);
+ vtn_push_pointer(b, w[2], src_val->sampled_image->image);
} else {
vtn_assert(src_val->value_type == vtn_value_type_pointer);
- vtn_push_value_pointer(b, w[2], src_val->pointer);
+ vtn_push_pointer(b, w[2], src_val->pointer);
}
return;
}
type->type != NULL) {
/* This is a pointer with an actual storage type */
nir_ssa_def *ssa_ptr = nir_load_param(&b->nb, b->func_param_idx++);
- vtn_push_value_pointer(b, w[2], vtn_pointer_from_ssa(b, ssa_ptr, type));
+ vtn_push_pointer(b, w[2], vtn_pointer_from_ssa(b, ssa_ptr, type));
} else if (type->base_type == vtn_base_type_pointer ||
type->base_type == vtn_base_type_image ||
type->base_type == vtn_base_type_sampler) {
- vtn_push_value_pointer(b, w[2], vtn_load_param_pointer(b, type, b->func_param_idx++));
+ vtn_push_pointer(b, w[2], vtn_load_param_pointer(b, type, b->func_param_idx++));
} else {
/* We're a regular SSA value. */
struct vtn_ssa_value *value = vtn_create_ssa_value(b, type->type);
}
/* Consider not using this function directly and instead use
- * vtn_push_ssa/vtn_push_value_pointer so that appropriate applying of
+ * vtn_push_ssa/vtn_push_pointer so that appropriate applying of
* decorations is handled by common code.
*/
static inline struct vtn_value *
struct vtn_ssa_value *vtn_ssa_value(struct vtn_builder *b, uint32_t value_id);
-struct vtn_value *vtn_push_value_pointer(struct vtn_builder *b,
- uint32_t value_id,
- struct vtn_pointer *ptr);
+struct vtn_value *vtn_push_pointer(struct vtn_builder *b,
+ uint32_t value_id,
+ struct vtn_pointer *ptr);
struct vtn_value *vtn_push_ssa(struct vtn_builder *b, uint32_t value_id,
struct vtn_type *type, struct vtn_ssa_value *ssa);
}
struct vtn_value *
-vtn_push_value_pointer(struct vtn_builder *b, uint32_t value_id,
- struct vtn_pointer *ptr)
+vtn_push_pointer(struct vtn_builder *b, uint32_t value_id,
+ struct vtn_pointer *ptr)
{
struct vtn_value *val = vtn_push_value(b, value_id, vtn_value_type_pointer);
val->pointer = vtn_decorate_pointer(b, val, ptr);
{
struct vtn_value *val;
if (type->base_type == vtn_base_type_pointer) {
- val = vtn_push_value_pointer(b, value_id, vtn_pointer_from_ssa(b, ssa->def, type));
+ val = vtn_push_pointer(b, value_id, vtn_pointer_from_ssa(b, ssa->def, type));
} else {
val = vtn_push_value(b, value_id, vtn_value_type_ssa);
val->ssa = ssa;
vtn_pointer_dereference(b, base_val->pointer, chain);
ptr->ptr_type = ptr_type;
ptr->access |= access;
- vtn_push_value_pointer(b, w[2], ptr);
+ vtn_push_pointer(b, w[2], ptr);
}
break;
}
if (res_type->base_type == vtn_base_type_image ||
res_type->base_type == vtn_base_type_sampler) {
- vtn_push_value_pointer(b, w[2], src);
+ vtn_push_pointer(b, w[2], src);
return;
} else if (res_type->base_type == vtn_base_type_sampled_image) {
struct vtn_value *val =