Commit ba65feb4e4bf011f8f3c85409c7ed49a51887f06

Amirali Abdolrashidi 2023-10-18T17:33:38

Vulkan: Limit mutable texture flush to one update In case there are many updates for a mutable texture, flushing it preemptively can reduce performance, especially if it is done repeatedly. * Added getLevelUpdateCount() to ImageHelper. * Previous mutable textures will now be flushed only if they have exactly one update per mip level/cubemap face (if defined). * This means that mutable textures with no data will also not be flushed. * Added unit tests for single-level texture flushing and situations with no updates or more than one update. Bug: b/285613719 Change-Id: I1592ecf502051a55ebfbb7fcd22577c9ce87bf43 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4953847 Commit-Queue: Amirali Abdolrashidi <abdolrashidi@google.com> Reviewed-by: Charlie Lao <cclao@google.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>