Module: Mesa Branch: staging/22.0 Commit: 4242ced033264ff3466d3cdc927bdc58fde61f36 URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=4242ced033264ff3466d3cdc927bdc58fde61f36
Author: Marcin Ĺšlusarz <[email protected]> Date: Thu Apr 21 17:26:52 2022 +0200 anv: update task/mesh distribution with the recommended values Fixes: ef04caea9b8 ("anv: Implement Mesh Shading pipeline") Acked-by: Caio Oliveira <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16493> (cherry picked from commit f083df87108231005889b7af92f0cad7c61e1f81) --- .pick_status.json | 2 +- src/intel/vulkan/genX_pipeline.c | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.pick_status.json b/.pick_status.json index c4914e28730..8aa0fba276c 100644 --- a/.pick_status.json +++ b/.pick_status.json @@ -188,7 +188,7 @@ "description": "anv: update task/mesh distribution with the recommended values", "nominated": true, "nomination_type": 1, - "resolution": 0, + "resolution": 1, "because_sha": "ef04caea9b8b98187340fd0ec6550aed06424b60" }, { diff --git a/src/intel/vulkan/genX_pipeline.c b/src/intel/vulkan/genX_pipeline.c index 77fb2c1cc88..b8c8a4c0fae 100644 --- a/src/intel/vulkan/genX_pipeline.c +++ b/src/intel/vulkan/genX_pipeline.c @@ -2657,10 +2657,10 @@ emit_task_state(struct anv_graphics_pipeline *pipeline) /* Recommended values from "Task and Mesh Distribution Programming". */ anv_batch_emit(&pipeline->base.batch, GENX(3DSTATE_TASK_REDISTRIB), redistrib) { redistrib.LocalBOTAccumulatorThreshold = MULTIPLIER_1; - redistrib.SmallTaskThreshold = MULTIPLIER_2; - redistrib.TargetMeshBatchSize = MULTIPLIER_4; + redistrib.SmallTaskThreshold = 1; /* 2^N */ + redistrib.TargetMeshBatchSize = devinfo->num_slices > 2 ? 3 : 5; /* 2^N */ redistrib.TaskRedistributionLevel = TASKREDISTRIB_BOM; - redistrib.TaskRedistributionMode = TASKREDISTRIB_RR_FREE; + redistrib.TaskRedistributionMode = TASKREDISTRIB_RR_STRICT; } } @@ -2731,8 +2731,8 @@ emit_mesh_state(struct anv_graphics_pipeline *pipeline) /* Recommended values from "Task and Mesh Distribution Programming". */ anv_batch_emit(&pipeline->base.batch, GENX(3DSTATE_MESH_DISTRIB), distrib) { distrib.DistributionMode = MESH_RR_FREE; - distrib.TaskDistributionBatchSize = 2; /* 2^2 thread groups */ - distrib.MeshDistributionBatchSize = 3; /* 2^3 thread groups */ + distrib.TaskDistributionBatchSize = devinfo->num_slices > 2 ? 8 : 9; /* 2^N thread groups */ + distrib.MeshDistributionBatchSize = devinfo->num_slices > 2 ? 5 : 3; /* 2^N thread groups */ } } #endif
