summaryrefslogtreecommitdiff
path: root/src/intel/vulkan/anv_pipeline.c
diff options
context:
space:
mode:
authorKarol Herbst <kherbst@redhat.com>2018-10-23 23:26:22 +0200
committerKarol Herbst <kherbst@redhat.com>2019-01-08 18:51:46 +0100
commitd0c6ef2793370a943a21c1d5e47e397c96b183f6 (patch)
treef30c52c50239a16d7a4f5b4fbd28991e581d06ea /src/intel/vulkan/anv_pipeline.c
parent401dca1c73cad4e6ac3137fdd5513e350d060f25 (diff)
nir: rename global/local to private/function memory
the naming is a bit confusing no matter how you look at it. Within SPIR-V "global" memory is memory accessible from all threads. glsl "global" memory normally refers to shader thread private memory declared at global scope. As we already use "shared" for memory shared across all thrads of a work group the solution where everybody could be happy with is to rename "global" to "private" and use "global" later for memory usually stored within system accessible memory (be it VRAM or system RAM if keeping SVM in mind). glsl "local" memory is memory only accessible within a function, while SPIR-V "local" memory is memory accessible within the same workgroup. v2: rename local to function as well v3: rename vtn_variable_mode_local as well Signed-off-by: Karol Herbst <kherbst@redhat.com> Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Diffstat (limited to 'src/intel/vulkan/anv_pipeline.c')
-rw-r--r--src/intel/vulkan/anv_pipeline.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/intel/vulkan/anv_pipeline.c b/src/intel/vulkan/anv_pipeline.c
index 750e258c2d2..d1efaaf060b 100644
--- a/src/intel/vulkan/anv_pipeline.c
+++ b/src/intel/vulkan/anv_pipeline.c
@@ -185,7 +185,7 @@ anv_shader_compile_to_nir(struct anv_pipeline *pipeline,
* inline functions. That way they get properly initialized at the top
* of the function and not at the top of its caller.
*/
- NIR_PASS_V(nir, nir_lower_constant_initializers, nir_var_local);
+ NIR_PASS_V(nir, nir_lower_constant_initializers, nir_var_function);
NIR_PASS_V(nir, nir_lower_returns);
NIR_PASS_V(nir, nir_inline_functions);
NIR_PASS_V(nir, nir_opt_deref);
@@ -788,7 +788,7 @@ anv_pipeline_link_fs(const struct brw_compiler *compiler,
!(stage->key.wm.color_outputs_valid & (1 << rt))) {
/* Unused or out-of-bounds, throw it away */
deleted_output = true;
- var->data.mode = nir_var_local;
+ var->data.mode = nir_var_function;
exec_node_remove(&var->node);
exec_list_push_tail(&impl->locals, &var->node);
continue;