diff options
author | Bas Nieuwenhuizen <[email protected]> | 2018-05-11 14:02:13 +0200 |
---|---|---|
committer | Jason Ekstrand <[email protected]> | 2018-06-22 20:54:00 -0700 |
commit | 1d59034de2c8cc03b0788c8d0644f3b4d0daa8c7 (patch) | |
tree | baa1649bbf6c56f84713c945ff8e661e4be48e23 /src/amd/vulkan | |
parent | 43af92edc5ca6ac8408bb694f187d93ccfd62fb1 (diff) |
radv: Remove image_var stores.
Acked-by: Rob Clark <[email protected]>
Acked-by: Bas Nieuwenhuizen <[email protected]>
Acked-by: Dave Airlie <[email protected]>
Reviewed-by: Kenneth Graunke <[email protected]>
Diffstat (limited to 'src/amd/vulkan')
-rw-r--r-- | src/amd/vulkan/radv_meta_bufimage.c | 40 | ||||
-rw-r--r-- | src/amd/vulkan/radv_meta_fast_clear.c | 10 | ||||
-rw-r--r-- | src/amd/vulkan/radv_meta_resolve_cs.c | 10 |
3 files changed, 30 insertions, 30 deletions
diff --git a/src/amd/vulkan/radv_meta_bufimage.c b/src/amd/vulkan/radv_meta_bufimage.c index 147d2ea46ef..aa17c25833b 100644 --- a/src/amd/vulkan/radv_meta_bufimage.c +++ b/src/amd/vulkan/radv_meta_bufimage.c @@ -115,11 +115,11 @@ build_nir_itob_compute_shader(struct radv_device *dev, bool is_3d) nir_ssa_def *coord = nir_vec4(&b, tmp, tmp, tmp, tmp); nir_ssa_def *outval = &tex->dest.ssa; - nir_intrinsic_instr *store = nir_intrinsic_instr_create(b.shader, nir_intrinsic_image_var_store); - store->src[0] = nir_src_for_ssa(coord); - store->src[1] = nir_src_for_ssa(nir_ssa_undef(&b, 1, 32)); - store->src[2] = nir_src_for_ssa(outval); - store->variables[0] = nir_deref_var_create(store, output_img); + nir_intrinsic_instr *store = nir_intrinsic_instr_create(b.shader, nir_intrinsic_image_deref_store); + store->src[0] = nir_src_for_ssa(&nir_build_deref_var(&b, output_img)->dest.ssa); + store->src[1] = nir_src_for_ssa(coord); + store->src[2] = nir_src_for_ssa(nir_ssa_undef(&b, 1, 32)); + store->src[3] = nir_src_for_ssa(outval); nir_builder_instr_insert(&b, &store->instr); return b.shader; @@ -341,11 +341,11 @@ build_nir_btoi_compute_shader(struct radv_device *dev, bool is_3d) nir_builder_instr_insert(&b, &tex->instr); nir_ssa_def *outval = &tex->dest.ssa; - nir_intrinsic_instr *store = nir_intrinsic_instr_create(b.shader, nir_intrinsic_image_var_store); - store->src[0] = nir_src_for_ssa(img_coord); - store->src[1] = nir_src_for_ssa(nir_ssa_undef(&b, 1, 32)); - store->src[2] = nir_src_for_ssa(outval); - store->variables[0] = nir_deref_var_create(store, output_img); + nir_intrinsic_instr *store = nir_intrinsic_instr_create(b.shader, nir_intrinsic_image_deref_store); + store->src[0] = nir_src_for_ssa(&nir_build_deref_var(&b, output_img)->dest.ssa); + store->src[1] = nir_src_for_ssa(img_coord); + store->src[2] = nir_src_for_ssa(nir_ssa_undef(&b, 1, 32)); + store->src[3] = nir_src_for_ssa(outval); nir_builder_instr_insert(&b, &store->instr); return b.shader; @@ -556,11 +556,11 @@ build_nir_itoi_compute_shader(struct radv_device *dev, bool is_3d) nir_builder_instr_insert(&b, &tex->instr); nir_ssa_def *outval = &tex->dest.ssa; - nir_intrinsic_instr *store = nir_intrinsic_instr_create(b.shader, nir_intrinsic_image_var_store); - store->src[0] = nir_src_for_ssa(dst_coord); - store->src[1] = nir_src_for_ssa(nir_ssa_undef(&b, 1, 32)); - store->src[2] = nir_src_for_ssa(outval); - store->variables[0] = nir_deref_var_create(store, output_img); + nir_intrinsic_instr *store = nir_intrinsic_instr_create(b.shader, nir_intrinsic_image_deref_store); + store->src[0] = nir_src_for_ssa(&nir_build_deref_var(&b, output_img)->dest.ssa); + store->src[1] = nir_src_for_ssa(dst_coord); + store->src[2] = nir_src_for_ssa(nir_ssa_undef(&b, 1, 32)); + store->src[3] = nir_src_for_ssa(outval); nir_builder_instr_insert(&b, &store->instr); return b.shader; @@ -752,11 +752,11 @@ build_nir_cleari_compute_shader(struct radv_device *dev, bool is_3d) comps[3] = nir_imm_int(&b, 0); global_id = nir_vec(&b, comps, 4); - nir_intrinsic_instr *store = nir_intrinsic_instr_create(b.shader, nir_intrinsic_image_var_store); - store->src[0] = nir_src_for_ssa(global_id); - store->src[1] = nir_src_for_ssa(nir_ssa_undef(&b, 1, 32)); - store->src[2] = nir_src_for_ssa(&clear_val->dest.ssa); - store->variables[0] = nir_deref_var_create(store, output_img); + nir_intrinsic_instr *store = nir_intrinsic_instr_create(b.shader, nir_intrinsic_image_deref_store); + store->src[0] = nir_src_for_ssa(&nir_build_deref_var(&b, output_img)->dest.ssa); + store->src[1] = nir_src_for_ssa(global_id); + store->src[2] = nir_src_for_ssa(nir_ssa_undef(&b, 1, 32)); + store->src[3] = nir_src_for_ssa(&clear_val->dest.ssa); nir_builder_instr_insert(&b, &store->instr); return b.shader; diff --git a/src/amd/vulkan/radv_meta_fast_clear.c b/src/amd/vulkan/radv_meta_fast_clear.c index 411d02f231f..041c9e44c45 100644 --- a/src/amd/vulkan/radv_meta_fast_clear.c +++ b/src/amd/vulkan/radv_meta_fast_clear.c @@ -91,11 +91,11 @@ build_dcc_decompress_compute_shader(struct radv_device *dev) nir_builder_instr_insert(&b, &bar->instr); nir_ssa_def *outval = &tex->dest.ssa; - nir_intrinsic_instr *store = nir_intrinsic_instr_create(b.shader, nir_intrinsic_image_var_store); - store->src[0] = nir_src_for_ssa(global_id); - store->src[1] = nir_src_for_ssa(nir_ssa_undef(&b, 1, 32)); - store->src[2] = nir_src_for_ssa(outval); - store->variables[0] = nir_deref_var_create(store, output_img); + nir_intrinsic_instr *store = nir_intrinsic_instr_create(b.shader, nir_intrinsic_image_deref_store); + store->src[0] = nir_src_for_ssa(&nir_build_deref_var(&b, output_img)->dest.ssa); + store->src[1] = nir_src_for_ssa(global_id); + store->src[2] = nir_src_for_ssa(nir_ssa_undef(&b, 1, 32)); + store->src[3] = nir_src_for_ssa(outval); nir_builder_instr_insert(&b, &store->instr); return b.shader; diff --git a/src/amd/vulkan/radv_meta_resolve_cs.c b/src/amd/vulkan/radv_meta_resolve_cs.c index 322e72e465e..4a37892b860 100644 --- a/src/amd/vulkan/radv_meta_resolve_cs.c +++ b/src/amd/vulkan/radv_meta_resolve_cs.c @@ -135,11 +135,11 @@ build_resolve_compute_shader(struct radv_device *dev, bool is_integer, bool is_s outval = radv_meta_build_resolve_srgb_conversion(&b, outval); nir_ssa_def *coord = nir_iadd(&b, global_id, &dst_offset->dest.ssa); - nir_intrinsic_instr *store = nir_intrinsic_instr_create(b.shader, nir_intrinsic_image_var_store); - store->src[0] = nir_src_for_ssa(coord); - store->src[1] = nir_src_for_ssa(nir_ssa_undef(&b, 1, 32)); - store->src[2] = nir_src_for_ssa(outval); - store->variables[0] = nir_deref_var_create(store, output_img); + nir_intrinsic_instr *store = nir_intrinsic_instr_create(b.shader, nir_intrinsic_image_deref_store); + store->src[0] = nir_src_for_ssa(&nir_build_deref_var(&b, output_img)->dest.ssa); + store->src[1] = nir_src_for_ssa(coord); + store->src[2] = nir_src_for_ssa(nir_ssa_undef(&b, 1, 32)); + store->src[3] = nir_src_for_ssa(outval); nir_builder_instr_insert(&b, &store->instr); return b.shader; } |