summaryrefslogtreecommitdiffstats
path: root/src/mesa/state_tracker/st_extensions.c
diff options
context:
space:
mode:
authorKenneth Graunke <[email protected]>2019-01-23 02:04:01 -0800
committerKenneth Graunke <[email protected]>2019-02-05 13:58:46 -0800
commit8fa54bc54902960640d8140bef8c9d35677f17cb (patch)
tree88f4369ecbb6c8aa2f9445b67dc20066cb8ebc16 /src/mesa/state_tracker/st_extensions.c
parentcf731564e6d335c987c47d41817b75df8a637dde (diff)
gallium: Add a PIPE_CAP_NIR_COMPACT_ARRAYS capability bit.
Iris would like to use compact arrays for tesslevels and clip/cull distances. radeonsi will likely want to switch to these at some point, since it'll be necessary for GL_ARB_gl_spirv support, but it's not ready for them just yet. Reviewed-by: Timothy Arceri <[email protected]>
Diffstat (limited to 'src/mesa/state_tracker/st_extensions.c')
-rw-r--r--src/mesa/state_tracker/st_extensions.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/mesa/state_tracker/st_extensions.c b/src/mesa/state_tracker/st_extensions.c
index 3449b2a9645..c1a528551cd 100644
--- a/src/mesa/state_tracker/st_extensions.c
+++ b/src/mesa/state_tracker/st_extensions.c
@@ -321,7 +321,9 @@ void st_init_limits(struct pipe_screen *screen,
screen->get_shader_param(screen, sh,
PIPE_SHADER_CAP_MAX_UNROLL_ITERATIONS_HINT);
- options->LowerCombinedClipCullDistance = true;
+ if (!screen->get_param(screen, PIPE_CAP_NIR_COMPACT_ARRAYS))
+ options->LowerCombinedClipCullDistance = true;
+
options->LowerBufferInterfaceBlocks = true;
}
@@ -336,7 +338,8 @@ void st_init_limits(struct pipe_screen *screen,
screen->get_param(screen, PIPE_CAP_GLSL_OPTIMIZE_CONSERVATIVELY);
c->GLSLTessLevelsAsInputs =
screen->get_param(screen, PIPE_CAP_GLSL_TESS_LEVELS_AS_INPUTS);
- c->LowerTessLevel = true;
+ c->LowerTessLevel =
+ !screen->get_param(screen, PIPE_CAP_NIR_COMPACT_ARRAYS);
c->LowerCsDerivedVariables = true;
c->PrimitiveRestartForPatches =
screen->get_param(screen, PIPE_CAP_PRIMITIVE_RESTART_FOR_PATCHES);