diff options
author | Marek Olšák <[email protected]> | 2019-07-23 19:15:45 -0400 |
---|---|---|
committer | Marek Olšák <[email protected]> | 2019-07-30 22:06:23 -0400 |
commit | 5787bbf90df61d6ec660a30490d9b973446cda0d (patch) | |
tree | a27eb377f9adb6d0d0da6d160b58a7f0f63a0466 /src/gallium/drivers/radeonsi | |
parent | 0993dbcbef1a208b67ad2ce5b8187d41b2df5f61 (diff) |
radeonsi/nir: set tgsi_shader_info::num_memory_instructions
Diffstat (limited to 'src/gallium/drivers/radeonsi')
-rw-r--r-- | src/gallium/drivers/radeonsi/si_shader_nir.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/gallium/drivers/radeonsi/si_shader_nir.c b/src/gallium/drivers/radeonsi/si_shader_nir.c index 512dc00cf21..df46bb4cada 100644 --- a/src/gallium/drivers/radeonsi/si_shader_nir.c +++ b/src/gallium/drivers/radeonsi/si_shader_nir.c @@ -282,9 +282,11 @@ static void scan_instruction(const struct nir_shader *nir, info->uses_bindless_image_store = true; info->writes_memory = true; + info->num_memory_instructions++; /* we only care about stores */ break; case nir_intrinsic_image_deref_store: info->writes_memory = true; + info->num_memory_instructions++; /* we only care about stores */ break; case nir_intrinsic_bindless_image_atomic_add: case nir_intrinsic_bindless_image_atomic_min: @@ -302,6 +304,7 @@ static void scan_instruction(const struct nir_shader *nir, info->uses_bindless_image_atomic = true; info->writes_memory = true; + info->num_memory_instructions++; /* we only care about stores */ break; case nir_intrinsic_image_deref_atomic_add: case nir_intrinsic_image_deref_atomic_min: @@ -312,6 +315,7 @@ static void scan_instruction(const struct nir_shader *nir, case nir_intrinsic_image_deref_atomic_exchange: case nir_intrinsic_image_deref_atomic_comp_swap: info->writes_memory = true; + info->num_memory_instructions++; /* we only care about stores */ break; case nir_intrinsic_store_ssbo: case nir_intrinsic_ssbo_atomic_add: @@ -325,6 +329,7 @@ static void scan_instruction(const struct nir_shader *nir, case nir_intrinsic_ssbo_atomic_exchange: case nir_intrinsic_ssbo_atomic_comp_swap: info->writes_memory = true; + info->num_memory_instructions++; /* we only care about stores */ break; case nir_intrinsic_load_deref: { nir_variable *var = intrinsic_get_var(intr); |