diff --git a/.pick_status.json b/.pick_status.json index bac861054e3..0cdb43e0a4e 100644 --- a/.pick_status.json +++ b/.pick_status.json @@ -1012,7 +1012,7 @@ "description": "zink: fix surface/bufferview cache comparisons", "nominated": true, "nomination_type": 0, - "resolution": 0, + "resolution": 1, "because_sha": null }, { diff --git a/src/gallium/drivers/zink/zink_resource.c b/src/gallium/drivers/zink/zink_resource.c index 2c6f7995882..cd55921f5d5 100644 --- a/src/gallium/drivers/zink/zink_resource.c +++ b/src/gallium/drivers/zink/zink_resource.c @@ -69,13 +69,19 @@ static bool equals_ivci(const void *a, const void *b) { - return memcmp(a, b, sizeof(VkImageViewCreateInfo)) == 0; + const uint8_t *pa = a; + const uint8_t *pb = b; + size_t offset = offsetof(VkImageViewCreateInfo, flags); + return memcmp(pa + offset, pb + offset, sizeof(VkImageViewCreateInfo) - offset) == 0; } static bool equals_bvci(const void *a, const void *b) { - return memcmp(a, b, sizeof(VkBufferViewCreateInfo)) == 0; + const uint8_t *pa = a; + const uint8_t *pb = b; + size_t offset = offsetof(VkBufferViewCreateInfo, flags); + return memcmp(pa + offset, pb + offset, sizeof(VkBufferViewCreateInfo) - offset) == 0; } static void