anv: Don't use the wrong ARRAY_SIZE

Even though this doesn't change anything, it's not good to use an
ARRAY_SIZE for one array to iterate over another.

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17601>
This commit is contained in:
Jason Ekstrand 2022-07-15 05:19:12 -05:00 committed by Marge Bot
parent f66192a4b3
commit cb682a1cdd

View file

@ -577,7 +577,7 @@ anv_pipeline_hash_graphics(struct anv_graphics_pipeline *pipeline,
const bool rba = pipeline->base.device->robust_buffer_access;
_mesa_sha1_update(&ctx, &rba, sizeof(rba));
for (unsigned s = 0; s < ARRAY_SIZE(pipeline->shaders); s++) {
for (uint32_t s = 0; s < ANV_GRAPHICS_SHADER_STAGE_COUNT; s++) {
if (stages[s].info) {
_mesa_sha1_update(&ctx, stages[s].shader_sha1,
sizeof(stages[s].shader_sha1));