Mesa (staging/22.0): anv: fix variable shadowing

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Fri Apr 1 16:17:35 UTC 2022


Module: Mesa
Branch: staging/22.0
Commit: 4799f882f4e1dbdf0a8264617b79398cd0f7805f
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=4799f882f4e1dbdf0a8264617b79398cd0f7805f

Author: Lionel Landwerlin <lionel.g.landwerlin at intel.com>
Date:   Thu Mar 17 11:53:54 2022 +0200

anv: fix variable shadowing

Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin at intel.com>
Fixes: 83fee30e8596 ("anv: allow multiple command buffers in anv_queue_submit")
Reviewed-by: Jason Ekstrand <jason.ekstrand at collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15425>

---

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

diff --git a/.pick_status.json b/.pick_status.json
index 08a1e39e047..2f49a4023df 100644
--- a/.pick_status.json
+++ b/.pick_status.json
@@ -4380,7 +4380,7 @@
         "description": "anv: fix variable shadowing",
         "nominated": true,
         "nomination_type": 1,
-        "resolution": 5,
+        "resolution": 3,
         "because_sha": "83fee30e85965c9c1caffd0ad829bacaef12ae7c"
     },
     {
diff --git a/src/intel/vulkan/anv_batch_chain.c b/src/intel/vulkan/anv_batch_chain.c
index a32eb3bd9ec..46d712bb752 100644
--- a/src/intel/vulkan/anv_batch_chain.c
+++ b/src/intel/vulkan/anv_batch_chain.c
@@ -1906,8 +1906,8 @@ setup_execbuf_for_cmd_buffers(struct anv_execbuf *execbuf,
       __builtin_ia32_mfence();
       for (uint32_t i = 0; i < num_cmd_buffers; i++) {
          u_vector_foreach(bbo, &cmd_buffers[i]->seen_bbos) {
-            for (uint32_t i = 0; i < (*bbo)->length; i += CACHELINE_SIZE)
-               __builtin_ia32_clflush((*bbo)->bo->map + i);
+            for (uint32_t l = 0; l < (*bbo)->length; l += CACHELINE_SIZE)
+               __builtin_ia32_clflush((*bbo)->bo->map + l);
          }
       }
    }



More information about the mesa-commit mailing list