mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-24 19:40:10 +01:00
amd/common: Add gep helper for pointer increment.
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
This commit is contained in:
parent
39ab4e12f7
commit
e00d9a9a72
2 changed files with 13 additions and 0 deletions
|
|
@ -923,6 +923,14 @@ ac_build_fs_interp_mov(struct ac_llvm_context *ctx,
|
|||
ctx->f32, args, 4, AC_FUNC_ATTR_READNONE);
|
||||
}
|
||||
|
||||
LLVMValueRef
|
||||
ac_build_gep_ptr(struct ac_llvm_context *ctx,
|
||||
LLVMValueRef base_ptr,
|
||||
LLVMValueRef index)
|
||||
{
|
||||
return LLVMBuildGEP(ctx->builder, base_ptr, &index, 1, "");
|
||||
}
|
||||
|
||||
LLVMValueRef
|
||||
ac_build_gep0(struct ac_llvm_context *ctx,
|
||||
LLVMValueRef base_ptr,
|
||||
|
|
|
|||
|
|
@ -223,6 +223,11 @@ ac_build_fs_interp_mov(struct ac_llvm_context *ctx,
|
|||
LLVMValueRef attr_number,
|
||||
LLVMValueRef params);
|
||||
|
||||
LLVMValueRef
|
||||
ac_build_gep_ptr(struct ac_llvm_context *ctx,
|
||||
LLVMValueRef base_ptr,
|
||||
LLVMValueRef index);
|
||||
|
||||
LLVMValueRef
|
||||
ac_build_gep0(struct ac_llvm_context *ctx,
|
||||
LLVMValueRef base_ptr,
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue