summaryrefslogtreecommitdiffstats
path: root/src/mesa
diff options
context:
space:
mode:
authorSamuel Pitoiset <[email protected]>2020-01-06 08:27:49 +0100
committerSamuel Pitoiset <[email protected]>2020-01-09 07:58:33 +0100
commit1b808d208f7ae6b7934ada37378c654991a5ca5a (patch)
tree033069ef6ba151e411a279e18550cc3bbdc28d56 /src/mesa
parent37bfd854c71be8ace37080fbca36d0a1ef68fb8a (diff)
spirv,nir: add new lod parameter to image_{load,store} intrinsics
SPV_AMD_shader_image_load_store_lod allows to use a lod parameter with OpImageRead, OpImageWrite and OpImageSparseRead. According to the specification, this parameter should be a 32-bit integer. It is initialized to 0 when no lod parameter is found during SPIR-V->NIR translation. Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Bas Nieuwenhuizen <[email protected]>
Diffstat (limited to 'src/mesa')
-rw-r--r--src/mesa/state_tracker/st_pbo.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/mesa/state_tracker/st_pbo.c b/src/mesa/state_tracker/st_pbo.c
index 639e0839245..3f11a897594 100644
--- a/src/mesa/state_tracker/st_pbo.c
+++ b/src/mesa/state_tracker/st_pbo.c
@@ -557,6 +557,7 @@ create_fs_nir(struct st_context *st,
nir_src_for_ssa(nir_vec4(&b, pbo_addr, zero, zero, zero));
intrin->src[2] = nir_src_for_ssa(zero);
intrin->src[3] = nir_src_for_ssa(result);
+ intrin->src[4] = nir_src_for_ssa(nir_imm_int(&b, 0));
intrin->num_components = 4;
nir_builder_instr_insert(&b, &intrin->instr);
} else {