Module: Mesa
Branch: staging/23.0
Commit: 7f9eb9a8211838163023d2a7be9170bbf8e95b8f
URL:    
http://cgit.freedesktop.org/mesa/mesa/commit/?id=7f9eb9a8211838163023d2a7be9170bbf8e95b8f

Author: Lionel Landwerlin <[email protected]>
Date:   Thu Jan  5 17:30:19 2023 +0200

anv: fix indirect draws VF cache tracking of index buffer

Signed-off-by: Lionel Landwerlin <[email protected]>
Fixes: e2dc32d755 ("anv: move functions around to plan for generated draws")
Reviewed-by: Tapani Pälli <[email protected]>
Reviewed-by: Ivan Briano <[email protected]>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20497>
(cherry picked from commit e68615aeaab7993d7047eb2972474bc9ba9c4b4d)

---

 .pick_status.json                  | 4 ++--
 src/intel/vulkan/genX_cmd_buffer.c | 3 ++-
 2 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/.pick_status.json b/.pick_status.json
index 0e4ec0545ce..b1d022362b0 100644
--- a/.pick_status.json
+++ b/.pick_status.json
@@ -4783,7 +4783,7 @@
         "description": "anv: fix indirect draws VF cache tracking of index 
buffer",
         "nominated": true,
         "nomination_type": 1,
-        "resolution": 0,
+        "resolution": 1,
         "main_sha": null,
         "because_sha": "e2dc32d755b15697765719acec1d23f12f9c938c"
     },
@@ -4792,7 +4792,7 @@
         "description": "anv: fix 3DSTATE_PS emission in generation shaders",
         "nominated": true,
         "nomination_type": 1,
-        "resolution": 0,
+        "resolution": 1,
         "main_sha": null,
         "because_sha": "c950fe97a05ef54e8298544a4582d21e524ada08"
     },
diff --git a/src/intel/vulkan/genX_cmd_buffer.c 
b/src/intel/vulkan/genX_cmd_buffer.c
index a2f9bdf0b73..c4156fb30f3 100644
--- a/src/intel/vulkan/genX_cmd_buffer.c
+++ b/src/intel/vulkan/genX_cmd_buffer.c
@@ -4560,7 +4560,8 @@ emit_indirect_draws(struct anv_cmd_buffer *cmd_buffer,
       genX(emit_dummy_post_sync_op)(cmd_buffer, 1);
 #endif
 
-      update_dirty_vbs_for_gfx8_vb_flush(cmd_buffer, SEQUENTIAL);
+      update_dirty_vbs_for_gfx8_vb_flush(cmd_buffer,
+                                         indexed ? RANDOM : SEQUENTIAL);
 
       offset += indirect_data_stride;
    }

Reply via email to