mirror of
https://github.com/encounter/dawn-cmake.git
synced 2025-08-31 07:50:24 +00:00
This patch adds the validation on the buffer-to-buffer copies within the same buffer. When the source and destination buffer are the same one in CopyBufferToBuffer(), the copy region cannot overlap or it will cause undefined behaviors on Metal and Vulkan. BUG=dawn:17 TEST=dawn_unittests, dawn_end2end_tests Change-Id: I63ab790787ec0a973ae22787a9348bddfb6a5373 Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/21602 Reviewed-by: Austin Eng <enga@chromium.org> Commit-Queue: Jiawei Shao <jiawei.shao@intel.com>