[Mesa-dev] [PATCH 23/70] mesa/compiler: add local_size_variable to shader_info

Timothy Arceri timothy.arceri at collabora.com
Fri Nov 11 00:46:05 UTC 2016


This will be used in api_validate.c in a following patch when we
switch to using gl_program pointers for the pipelines CurrentProgram
array.
---
 src/compiler/shader_info.h | 2 ++
 src/mesa/main/shaderapi.c  | 1 +
 2 files changed, 3 insertions(+)

diff --git a/src/compiler/shader_info.h b/src/compiler/shader_info.h
index 1a27bf3..e36fe09 100644
--- a/src/compiler/shader_info.h
+++ b/src/compiler/shader_info.h
@@ -122,6 +122,8 @@ typedef struct shader_info {
       struct {
          unsigned local_size[3];
 
+         bool local_size_variable;
+
          /**
           * Size of shared variables accessed by the compute shader.
           */
diff --git a/src/mesa/main/shaderapi.c b/src/mesa/main/shaderapi.c
index 62ec4df..0898e82 100644
--- a/src/mesa/main/shaderapi.c
+++ b/src/mesa/main/shaderapi.c
@@ -2215,6 +2215,7 @@ _mesa_copy_linked_program_data(const struct gl_shader_program *src,
       for (int i = 0; i < 3; i++)
          dst->info.cs.local_size[i] = src->Comp.LocalSize[i];
       dst->info.cs.shared_size = src->Comp.SharedSize;
+      dst->info.cs.local_size_variable = src->Comp.LocalSizeVariable;
       break;
    }
    default:
-- 
2.7.4



More information about the mesa-dev mailing list