summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/freedreno
diff options
context:
space:
mode:
authorKristian H. Kristensen <[email protected]>2019-10-10 15:37:19 -0700
committerKristian H. Kristensen <[email protected]>2019-10-17 13:43:53 -0700
commit8f39985b01b34cbb6a84b4614f5cb732748954d1 (patch)
treec99690731f3d796a557ed6a08432022610f1c54d /src/gallium/drivers/freedreno
parent2703844cb315a47761727da9aea4591d7fa59ce1 (diff)
freedreno/ir3: Add has_gs flag to shader key
Since the presence of GS changes how the VS operates we need to track that in the shader key. Signed-off-by: Kristian H. Kristensen <[email protected]>
Diffstat (limited to 'src/gallium/drivers/freedreno')
-rw-r--r--src/gallium/drivers/freedreno/a6xx/fd6_draw.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/gallium/drivers/freedreno/a6xx/fd6_draw.c b/src/gallium/drivers/freedreno/a6xx/fd6_draw.c
index 1d5df60c533..a0df3dbc1ea 100644
--- a/src/gallium/drivers/freedreno/a6xx/fd6_draw.c
+++ b/src/gallium/drivers/freedreno/a6xx/fd6_draw.c
@@ -157,6 +157,9 @@ fd6_draw_vbo(struct fd_context *ctx, const struct pipe_draw_info *info,
.sprite_coord_mode = ctx->rasterizer->sprite_coord_mode,
};
+ if (emit.key.gs)
+ emit.key.key.has_gs = true;
+
fixup_shader_state(ctx, &emit.key.key);
if (!(ctx->dirty & FD_DIRTY_PROG)) {
@@ -209,13 +212,12 @@ fd6_draw_vbo(struct fd_context *ctx, const struct pipe_draw_info *info,
*/
emit_marker6(ring, 7);
- /* leave vis mode blank for now, it will be patched up when
- * we know if we are binning or not
- */
uint32_t draw0 =
CP_DRAW_INDX_OFFSET_0_PRIM_TYPE(primtype) |
- CP_DRAW_INDX_OFFSET_0_VIS_CULL(USE_VISIBILITY) |
- 0x2000;
+ CP_DRAW_INDX_OFFSET_0_VIS_CULL(USE_VISIBILITY);
+
+ if (emit.key.gs)
+ draw0 |= CP_DRAW_INDX_OFFSET_0_GS_ENABLE;
if (info->index_size) {
draw0 |=