iris_update_draw_info(struct iris_context *ice,
const struct pipe_draw_info *info)
{
+ struct iris_screen *screen = (struct iris_screen *)ice->ctx.screen;
+ const struct brw_compiler *compiler = screen->compiler;
+
if (ice->state.prim_mode != info->mode) {
ice->state.prim_mode = info->mode;
ice->state.dirty |= IRIS_DIRTY_VF_TOPOLOGY;
ice->state.vertices_per_patch = info->vertices_per_patch;
ice->state.dirty |= IRIS_DIRTY_VF_TOPOLOGY;
+ /* 8_PATCH TCS needs this for key->input_vertices */
+ if (compiler->use_tcs_8_patch)
+ ice->state.dirty |= IRIS_DIRTY_UNCOMPILED_TCS;
+
/* Flag constants dirty for gl_PatchVerticesIn if needed. */
const struct shader_info *tcs_info =
iris_get_shader_info(ice, MESA_SHADER_TESS_CTRL);
struct iris_uncompiled_shader *tcs =
ice->shaders.uncompiled[MESA_SHADER_TESS_CTRL];
struct iris_screen *screen = (struct iris_screen *)ice->ctx.screen;
+ const struct brw_compiler *compiler = screen->compiler;
const struct gen_device_info *devinfo = &screen->devinfo;
const struct shader_info *tes_info =
KEY_INIT_NO_ID(devinfo->gen),
.base.program_string_id = tcs ? tcs->program_id : 0,
.tes_primitive_mode = tes_info->tess.primitive_mode,
- .input_vertices = ice->state.vertices_per_patch,
+ .input_vertices =
+ !tcs || compiler->use_tcs_8_patch ? ice->state.vertices_per_patch : 0,
};
get_unified_tess_slots(ice, &key.outputs_written,
&key.patch_outputs_written);