This commit adds checks to (hopefully) all the remaining places in the
Metal backend where object creation can fail.
Bug: dawn:801
Change-Id: Ic27803e956beef822f94ca8449f7816ddd17c1bc
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/58722
Commit-Queue: Stephen White <senorblanco@chromium.org>
Auto-Submit: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
Reviewed-by: Stephen White <senorblanco@chromium.org>
BUG=dawn:1015
Change-Id: I80d5afcfe3a7fc5c3c4c79d8c423ddf9578712e0
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/58960
Commit-Queue: Ryan Harrison <rharrison@chromium.org>
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Auto-Submit: Ryan Harrison <rharrison@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
https://chromium.googlesource.com/vulkan-deps/+log/85e758a22b7a..df0528b581a1
$ git log 85e758a22..df0528b58 --date=short --no-merges --format='%ad %ae %s'
2021-07-15 chromium-autoroll Roll SPIRV-Tools from 640b17b5fbc6 to 2685c9a687b5 (1 revision)
2021-07-15 chromium-autoroll Roll Vulkan-ValidationLayers from cb03f32776a6 to 98df0682926f (2 revisions)
2021-07-15 chromium-autoroll Roll Vulkan-ValidationLayers from 8b83ca019c50 to cb03f32776a6 (2 revisions)
2021-07-15 chromium-autoroll Roll SPIRV-Cross from fe08bf4af440 to 6196e3b02968 (2 revisions)
2021-07-15 chromium-autoroll Roll SPIRV-Cross from be3988b13cb7 to fe08bf4af440 (1 revision)
2021-07-15 chromium-autoroll Roll Vulkan-ValidationLayers from dada63db181a to 8b83ca019c50 (2 revisions)
2021-07-14 chromium-autoroll Roll Vulkan-Loader from 15e1bbe99a09 to 99c0b1433a09 (1 revision)
2021-07-14 chromium-autoroll Roll SPIRV-Headers from ddf3230c14c7 to 1d4e3a7e3a04 (2 revisions)
2021-07-14 chromium-autoroll Roll SPIRV-Tools from 4baf3affe323 to 640b17b5fbc6 (1 revision)
2021-07-14 chromium-autoroll Roll SPIRV-Tools from feb05446bbc3 to 4baf3affe323 (1 revision)
2021-07-14 chromium-autoroll Roll SPIRV-Tools from 2299b710de6c to feb05446bbc3 (1 revision)
2021-07-13 chromium-autoroll Roll Vulkan-Loader from 7033871e47d6 to 15e1bbe99a09 (1 revision)
2021-07-13 chromium-autoroll Roll Vulkan-Tools from 8b86fbac17b9 to 33a87ce6daec (1 revision)
2021-07-13 chromium-autoroll Roll Vulkan-ValidationLayers from 27a26f525f92 to dada63db181a (2 revisions)
2021-07-13 chromium-autoroll Roll Vulkan-ValidationLayers from 607d1d974d22 to 27a26f525f92 (1 revision)
2021-07-13 chromium-autoroll Roll Vulkan-ValidationLayers from 5bdd45ecca5f to 607d1d974d22 (1 revision)
2021-07-13 chromium-autoroll Roll SPIRV-Tools from d432bebb113d to 2299b710de6c (1 revision)
2021-07-13 chromium-autoroll Roll Vulkan-ValidationLayers from 48b8e27e9de0 to 5bdd45ecca5f (2 revisions)
2021-07-13 chromium-autoroll Roll Vulkan-Loader from 8c45e953d0a8 to 7033871e47d6 (1 revision)
2021-07-13 chromium-autoroll Roll Vulkan-Loader from 550b23a566a2 to 8c45e953d0a8 (1 revision)
2021-07-13 chromium-autoroll Roll SPIRV-Cross from d42c0b2e08ef to be3988b13cb7 (2 revisions)
2021-07-13 chromium-autoroll Roll SPIRV-Cross from 1ae2b58f19a9 to d42c0b2e08ef (1 revision)
2021-07-13 chromium-autoroll Roll SPIRV-Tools from 3b6abf41cc72 to d432bebb113d (1 revision)
2021-07-12 chromium-autoroll Roll Vulkan-Loader from 8daad81803f5 to 550b23a566a2 (1 revision)
2021-07-12 chromium-autoroll Roll SPIRV-Headers from 07f259e68af3 to ddf3230c14c7 (6 revisions)
2021-07-12 chromium-autoroll Roll SPIRV-Headers from ddf3230c14c7 to 07f259e68af3 (0 revision)
2021-07-12 chromium-autoroll Roll Vulkan-Loader from 3bdb32d29f2d to 8daad81803f5 (50 revisions)
2021-07-12 chromium-autoroll Roll SPIRV-Tools from c26baf4c9308 to 3b6abf41cc72 (1 revision)
2021-07-10 chromium-autoroll Roll Vulkan-ValidationLayers from 1c0b96aec2a3 to 48b8e27e9de0 (2 revisions)
2021-07-09 chromium-autoroll Roll Vulkan-ValidationLayers from b5dd25f4cd9c to 1c0b96aec2a3 (1 revision)
2021-07-09 chromium-autoroll Roll Vulkan-ValidationLayers from 32de8039cd51 to b5dd25f4cd9c (2 revisions)
2021-07-09 chromium-autoroll Roll Vulkan-ValidationLayers from f4fb2a0b00d1 to 32de8039cd51 (30 revisions)
2021-07-08 chromium-autoroll Roll glslang from 9e707294f126 to 4b7b86d568b4 (1 revision)
2021-07-08 chromium-autoroll Roll Vulkan-ValidationLayers from 24abc3af2fa6 to f4fb2a0b00d1 (1 revision)
2021-07-08 chromium-autoroll Roll Vulkan-ValidationLayers from 7cdc779e82e9 to 24abc3af2fa6 (6 revisions)
2021-07-08 chromium-autoroll Roll Vulkan-ValidationLayers from f2912cd0f628 to 7cdc779e82e9 (2 revisions)
2021-07-07 chromium-autoroll Roll glslang from 89286ca56b3d to 9e707294f126 (1 revision)
2021-07-07 chromium-autoroll Roll glslang from ae2a562936cc to 89286ca56b3d (1 revision)
2021-07-07 chromium-autoroll Roll Vulkan-Tools from 697cc6c387fd to 8b86fbac17b9 (1 revision)
2021-07-07 chromium-autoroll Roll Vulkan-ValidationLayers from 394157ab5101 to f2912cd0f628 (1 revision)
2021-07-07 chromium-autoroll Roll SPIRV-Tools from 9ce7a2fb62eb to c26baf4c9308 (1 revision)
2021-07-06 chromium-autoroll Roll Vulkan-ValidationLayers from 054383987078 to 394157ab5101 (1 revision)
2021-07-06 chromium-autoroll Roll Vulkan-Tools from ed2740a8220e to 697cc6c387fd (1 revision)
2021-07-06 chromium-autoroll Roll Vulkan-ValidationLayers from 13930981cd40 to 054383987078 (2 revisions)
2021-07-06 chromium-autoroll Roll Vulkan-Tools from abfc71f051a6 to ed2740a8220e (1 revision)
2021-07-06 chromium-autoroll Roll Vulkan-ValidationLayers from 5b3013cba651 to 13930981cd40 (2 revisions)
2021-07-06 chromium-autoroll Roll SPIRV-Tools from 4d2832e3c8d7 to 9ce7a2fb62eb (1 revision)
2021-07-05 chromium-autoroll Roll SPIRV-Tools from 7763360524ec to 4d2832e3c8d7 (1 revision)
2021-07-05 chromium-autoroll Roll Vulkan-ValidationLayers from 39152e64829c to 5b3013cba651 (2 revisions)
2021-07-05 chromium-autoroll Roll Vulkan-Headers from a8964617af6b to 0193e158bc9f (1 revision)
2021-07-04 chromium-autoroll Roll SPIRV-Tools from a95bc460f924 to 7763360524ec (1 revision)
2021-07-03 chromium-autoroll Roll Vulkan-ValidationLayers from 406766a8440f to 39152e64829c (1 revision)
2021-07-02 chromium-autoroll Roll Vulkan-ValidationLayers from b3ab357b1a00 to 406766a8440f (1 revision)
2021-07-02 chromium-autoroll Roll Vulkan-ValidationLayers from a844c1288087 to b3ab357b1a00 (1 revision)
2021-07-02 chromium-autoroll Roll SPIRV-Tools from c67f132087b9 to a95bc460f924 (1 revision)
2021-07-02 chromium-autoroll Roll SPIRV-Tools from 06f114d48214 to c67f132087b9 (1 revision)
2021-07-01 chromium-autoroll Roll Vulkan-Tools from a7fc5ca82287 to abfc71f051a6 (1 revision)
2021-07-01 chromium-autoroll Roll Vulkan-ValidationLayers from 73452524742b to a844c1288087 (4 revisions)
2021-07-01 chromium-autoroll Roll Vulkan-ValidationLayers from 667cc02b6514 to 73452524742b (1 revision)
2021-07-01 chromium-autoroll Roll SPIRV-Tools from 74e8105eb801 to 06f114d48214 (1 revision)
2021-07-01 chromium-autoroll Roll Vulkan-ValidationLayers from 28198b569714 to 667cc02b6514 (3 revisions)
2021-06-30 chromium-autoroll Roll Vulkan-ValidationLayers from 7465dc3cb7a2 to 28198b569714 (1 revision)
2021-06-30 chromium-autoroll Roll Vulkan-Tools from 2b7d601bdaed to a7fc5ca82287 (1 revision)
2021-06-30 chromium-autoroll Roll SPIRV-Cross from bf746bd68019 to 1ae2b58f19a9 (1 revision)
2021-06-30 chromium-autoroll Roll Vulkan-Tools from 68b1feb2727e to 2b7d601bdaed (1 revision)
2021-06-30 chromium-autoroll Roll Vulkan-ValidationLayers from 4e28e6495717 to 7465dc3cb7a2 (1 revision)
2021-06-30 chromium-autoroll Roll SPIRV-Cross from c5b8022e615d to bf746bd68019 (1 revision)
2021-06-30 chromium-autoroll Roll Vulkan-Tools from aaebda90a9a8 to 68b1feb2727e (1 revision)
2021-06-29 chromium-autoroll Roll SPIRV-Tools from f9893c454940 to 74e8105eb801 (1 revision)
2021-06-29 chromium-autoroll Roll SPIRV-Tools from 8442a181294b to f9893c454940 (1 revision)
2021-06-29 chromium-autoroll Roll SPIRV-Tools from eeff9af1e6e1 to 8442a181294b (1 revision)
2021-06-29 chromium-autoroll Roll SPIRV-Tools from b8587c984a93 to eeff9af1e6e1 (1 revision)
2021-06-29 chromium-autoroll Roll SPIRV-Cross from 853e84e8bff8 to c5b8022e615d (1 revision)
2021-06-29 chromium-autoroll Roll SPIRV-Cross from 9338996f3b2b to 853e84e8bff8 (1 revision)
2021-06-28 chromium-autoroll Roll Vulkan-ValidationLayers from 01cf24db1331 to 4e28e6495717 (1 revision)
2021-06-28 chromium-autoroll Roll SPIRV-Tools from 4fcdc5894676 to b8587c984a93 (1 revision)
2021-06-28 chromium-autoroll Roll Vulkan-Tools from 8926213dd008 to aaebda90a9a8 (1 revision)
2021-06-28 chromium-autoroll Roll SPIRV-Tools from 237173a07083 to 4fcdc5894676 (1 revision)
2021-06-28 chromium-autoroll Roll Vulkan-ValidationLayers from c09be02a362f to 01cf24db1331 (2 revisions)
2021-06-28 chromium-autoroll Roll SPIRV-Tools from 8cc8b6562be9 to 237173a07083 (1 revision)
2021-06-28 chromium-autoroll Roll SPIRV-Cross from 31490955852b to 9338996f3b2b (1 revision)
2021-06-28 chromium-autoroll Roll SPIRV-Cross from 9cdeefb5e322 to 31490955852b (1 revision)
2021-06-28 chromium-autoroll Roll Vulkan-Headers from 37164a5726f7 to a8964617af6b (1 revision)
2021-06-25 chromium-autoroll Roll Vulkan-ValidationLayers from 6fbf8245095e to c09be02a362f (1 revision)
2021-06-25 chromium-autoroll Roll Vulkan-ValidationLayers from 7345a069cca3 to 6fbf8245095e (1 revision)
2021-06-25 chromium-autoroll Roll Vulkan-ValidationLayers from 968b6094907e to 7345a069cca3 (1 revision)
2021-06-25 chromium-autoroll Roll Vulkan-ValidationLayers from bfe4822f0d97 to 968b6094907e (1 revision)
2021-06-25 chromium-autoroll Roll Vulkan-ValidationLayers from 16266c388370 to bfe4822f0d97 (2 revisions)
2021-06-24 chromium-autoroll Roll SPIRV-Tools from 3a02d1126872 to 8cc8b6562be9 (1 revision)
2021-06-24 chromium-autoroll Roll SPIRV-Tools from e065c482c6c9 to 3a02d1126872 (1 revision)
2021-06-23 chromium-autoroll Roll Vulkan-ValidationLayers from bd7c99573d3b to 16266c388370 (1 revision)
2021-06-23 chromium-autoroll Roll glslang from 0c4c93bf615b to ae2a562936cc (1 revision)
2021-06-23 chromium-autoroll Roll Vulkan-ValidationLayers from 71916f15bc7f to bd7c99573d3b (5 revisions)
2021-06-23 chromium-autoroll Roll Vulkan-Tools from dbd221b2bc7a to 8926213dd008 (1 revision)
2021-06-23 chromium-autoroll Roll SPIRV-Tools from e992c96c89a3 to e065c482c6c9 (1 revision)
2021-06-23 chromium-autoroll Roll glslang from b38100f6bc00 to 0c4c93bf615b (1 revision)
2021-06-23 chromium-autoroll Roll SPIRV-Tools from 0c21e50922e4 to e992c96c89a3 (1 revision)
2021-06-22 chromium-autoroll Roll Vulkan-ValidationLayers from f12691a7fca2 to 71916f15bc7f (2 revisions)
2021-06-22 chromium-autoroll Roll SPIRV-Tools from f8eafd4d838c to 0c21e50922e4 (2 revisions)
TBR=enga@chromium.org
Created with:
roll-dep third_party/vulkan-deps
Change-Id: I9517b84c5eca6eb9251655c4b3afc2d72dbc5348
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/58860
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
Reviewed-by: Ben Clayton <bclayton@google.com>
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Change the ShaderModuleBase::MakeError to return a Ref<ShaderModuleBase>
rather than a naked pointer. This Ref will be used and finally detached in
DeviceBase::APICreateShaderModule.
Bug: chromium:1223546
Change-Id: Ie4213f091e37fdc61c6e1f0bb742e8787bcb4eb8
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/58660
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Zhaoming Jiang <zhaoming.jiang@intel.com>
There is nothing we can do when these errors happen except proceeding
with the clean shutdown of the Vulkan device by destroying all the
fences.
Bug: chromium:1230251
Change-Id: I5f14770bf71072616783afec7cf9538c9b103f23
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/58398
Commit-Queue: Jiawei Shao <jiawei.shao@intel.com>
Auto-Submit: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
Reviewed-by: Jiawei Shao <jiawei.shao@intel.com>
Treat color target format with "float" capabilities as
blendable format and validate when blending is enabled.
Add helpers for checking float16 texture values.
Bug: dawn:726
Change-Id: Icf8c0182e5e9a13523970c84b5af91f395a089af
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/57744
Commit-Queue: Shrek Shao <shrekshao@google.com>
Reviewed-by: Austin Eng <enga@chromium.org>
Adds some handling that ensures correct reflection of texture_external now
that Dawn uses Tint by default. Enables the previously written tests.
dawn: 1004
Change-Id: I8fd43292e9fe243aee037c70fe47b79ace8b672f
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/58540
Commit-Queue: Brandon Jones (Intel) <brandon1.jones@intel.com>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Previously Dawn was using acquireKey + 1 for the releaseKey but we
changed the code transition to requiring a specific key. We supported
both options for a time but now that Chromium uses a releaseKey, we can
remove the deprecated option.
Bug: chromium:1213977
Change-Id: Iab253673c15b83b107dcc3635ee165cfa09efeb6
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/58383
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Auto-Submit: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
Losing the device makes retreiving the problematic shader source
difficult. Change compilation failures to be less severe
validation errors.
Change-Id: Ibcee9f39be66241e26cc8cfcf09c14aa7dfe2d1c
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/58080
Auto-Submit: Austin Eng <enga@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Austin Eng <enga@chromium.org>
This was a temporary measure to be able to roll Tint into Dawn with this
change. The macro will be removed in Tint once this lands.
Bug: tint:984
Change-Id: If599e92b16b5edd96b357ce5ee57143a2c00e22d
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/58365
Reviewed-by: Austin Eng <enga@chromium.org>
Reviewed-by: Ben Clayton <bclayton@google.com>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Antonio Maiorano <amaiorano@google.com>
1. Validate the buffer range for both vertex step mode and instance step mode vertex buffers in Draw,
2. Validate the buffer range for instance step mode vertex buffers and the range of index buffer in DrawIndexed, and
3. Add related validation unit tests DrawVertexAndIndexBufferOOBValidationTests, and remove out-of-date vertex buffer robustness tests.
Bug: dawn:808
Change-Id: Ic27a95138cb1e21b72a1da392b7828368bfe2010
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/56361
Commit-Queue: Zhaoming Jiang <zhaoming.jiang@intel.com>
Reviewed-by: Austin Eng <enga@chromium.org>
TextureViewDescriptor's default values for dimension and
arrayLayerCount in Dawn are not correct according to WebGPU spec.
This change fixes these bugs.
Bug: dawn:760
Change-Id: Ic1d069838d6c0f7bb1afa1dceaf73e91bdfdb20a
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/58020
Commit-Queue: Yunchao He <yunchao.he@intel.com>
Reviewed-by: Kai Ninomiya <kainino@chromium.org>
And print this to the Dawn logger.
Tests will now print any diagnostic logging calls from Dawn.
Change-Id: Idd4bf816303c182809924f9a432570def808e1b6
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/57381
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Ben Clayton <bclayton@google.com>
Remove deprecated functions and change new functions to pure
virtual since they are implemented both on dawn and chromium
side.
Bug: dawn:773
Change-Id: I5adfe42ad1155276f533660b938b869c775025bf
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/58100
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Shrek Shao <shrekshao@google.com>
And print the WGSL program even when !force_wgsl_step
Shaders are often built through string concatenation.
Being able to always dump this is useful.
Change-Id: I5da3866b333e8a80931c7c2837f0247e8f38213d
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/57380
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Ben Clayton <bclayton@google.com>
Conditional on whether TINT_EXPECTS_UBOS_TO_BE_MULTIPLE_OF_16 is
defined, which it will be in a future Tint CL.
Bug: tint:984
Change-Id: I191cd59fe6947c9113a8fad7dbfbf79903969b27
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/57960
Commit-Queue: Antonio Maiorano <amaiorano@google.com>
Reviewed-by: Austin Eng <enga@chromium.org>
R=rharrison
Bug: chromium:1216166
Change-Id: Iabc72c400eff4a2f71179b5f4779eaccfd42d697
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/57423
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Commit-Queue: Ryan Harrison <rharrison@chromium.org>
Buffers are padded to be at least 4 bytes. Dawn would
produce invalid barriers for buffers that were "zero"
bytes large. The size for the barrier must be either
non-zero or VK_WHOLE_SIZE. Since we always intend
to transition the entire buffer, simply use
VK_WHOLE_SIZE instead of GetSize() as the size.
Fixed: dawn:969
Change-Id: Ifed4e8f9164bafa3c44917074fcf214e72919c56
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/57940
Reviewed-by: Jiawei Shao <jiawei.shao@intel.com>
Commit-Queue: Austin Eng <enga@chromium.org>
When we clear an uninitialized 3D texture, we should clear all depth
slices for each mip level. The current implementation only clears one
slice (the first slice) for each mip level. This change fixes this
bug. Dawn end2end tests of NonzeroTextureCreationTests can pass with
this fix. These tests fail on D3D12 without the fix.
This change also renames arguments for GetRTVDescriptor() for 3D
texture: change baseArrayLayer/layerCount to baseSlice/sliceCount.
Bug: dawn:547
Change-Id: Ic56f28e9e6430058c31aaa2bb21f4e42f7b7621c
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/57840
Reviewed-by: Austin Eng <enga@chromium.org>
Reviewed-by: Jiawei Shao <jiawei.shao@intel.com>
Commit-Queue: Yunchao He <yunchao.he@intel.com>
Not running the renamer can produce code that fails to compile
on the backend, resulting in device lost errors.
Change-Id: I4a841a281142bb8eda1402e1ebd6a5d23b77bfe0
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/57745
Reviewed-by: Ben Clayton <bclayton@google.com>
Commit-Queue: Austin Eng <enga@chromium.org>