summaryrefslogtreecommitdiff
path: root/lib/mesa/src/gallium/drivers/iris
diff options
context:
space:
mode:
authorJonathan Gray <jsg@cvs.openbsd.org>2022-04-21 04:23:05 +0000
committerJonathan Gray <jsg@cvs.openbsd.org>2022-04-21 04:23:05 +0000
commita09152815d99b8a68f7f5ed0e44bab39dd14a1e5 (patch)
tree2d0fdc70c25e62ac40fe0512a56b269564afb8f8 /lib/mesa/src/gallium/drivers/iris
parent5141f851e7304b6ee32a98117c378cb814079903 (diff)
Import Mesa 21.3.8
Diffstat (limited to 'lib/mesa/src/gallium/drivers/iris')
-rw-r--r--lib/mesa/src/gallium/drivers/iris/iris_program.c3
-rw-r--r--lib/mesa/src/gallium/drivers/iris/iris_state.c7
2 files changed, 5 insertions, 5 deletions
diff --git a/lib/mesa/src/gallium/drivers/iris/iris_program.c b/lib/mesa/src/gallium/drivers/iris/iris_program.c
index a5e1dc137..973999bcc 100644
--- a/lib/mesa/src/gallium/drivers/iris/iris_program.c
+++ b/lib/mesa/src/gallium/drivers/iris/iris_program.c
@@ -2820,7 +2820,8 @@ iris_bind_vs_state(struct pipe_context *ctx, void *state)
if (ice->state.vs_uses_draw_params != uses_draw_params ||
ice->state.vs_uses_derived_draw_params != uses_derived_draw_params ||
- ice->state.vs_needs_edge_flag != info->vs.needs_edge_flag) {
+ ice->state.vs_needs_edge_flag != info->vs.needs_edge_flag ||
+ ice->state.vs_needs_sgvs_element != needs_sgvs_element) {
ice->state.dirty |= IRIS_DIRTY_VERTEX_BUFFERS |
IRIS_DIRTY_VERTEX_ELEMENTS;
}
diff --git a/lib/mesa/src/gallium/drivers/iris/iris_state.c b/lib/mesa/src/gallium/drivers/iris/iris_state.c
index 40dc2d062..de553f320 100644
--- a/lib/mesa/src/gallium/drivers/iris/iris_state.c
+++ b/lib/mesa/src/gallium/drivers/iris/iris_state.c
@@ -6922,10 +6922,9 @@ iris_upload_compute_walker(struct iris_context *ice,
iris_emit_cmd(batch, GENX(CFE_STATE), cfe) {
cfe.MaximumNumberofThreads =
devinfo->max_cs_threads * devinfo->subslice_total - 1;
- if (prog_data->total_scratch > 0) {
- cfe.ScratchSpaceBuffer =
- iris_get_scratch_surf(ice, prog_data->total_scratch)->offset >> 4;
- }
+ uint32_t scratch_addr = pin_scratch_space(ice, batch, prog_data,
+ MESA_SHADER_COMPUTE);
+ cfe.ScratchSpaceBuffer = scratch_addr >> 4;
}
}