Commit Graph

3810 Commits

Author SHA1 Message Date
Bryan Bernhart caf6e8b3f0 Disable remap binding test on WARP.
Adds a supression to the failing test.

BUG=dawn:1106

Change-Id: Ib0cfd49b6d1af59c60d7bc4f2e3e1bec5ae80601
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/64062
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Bryan Bernhart <bryan.bernhart@intel.com>
2021-09-13 17:27:29 +00:00
Dawn Autoroller 7e9aba8eef Roll Tint from 2ebcb93cb3 to f66f651374 (1 revision)
https://dawn.googlesource.com/tint.git/+log/2ebcb93cb36c..f66f65137448

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/tint-dawn
Please CC shrekshao@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Dawn: https://bugs.chromium.org/p/dawn/issues/entry

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md

Bug: None
Tbr: shrekshao@google.com
Change-Id: Ica990c32bbe9a3b0d35df2fe1ccb855ce9691ce3
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/64141
Reviewed-by: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2021-09-13 15:51:29 +00:00
Jiawei Shao 42448dafb4 Remove descriptor from the parameter of ComputePipeline::Initialize()
This patch removes the parameter "descriptor" in the function
ComputePipeline::Initialize() so that we don't need to define
FlatComputePipelineDescriptor right now.

For render pipeline, as descriptor->vertex is being used for vertex
pulling (passed into vertexModule->CreateFunction()), we will first
refactor the related code in vertex pulling before removing the
parameter "descriptor" in the function RenderPipeline::Initialize().

BUG=dawn:529

Change-Id: Ib172ac0c76fa24070e78c0e57c3262acad9399b9
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/64000
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Jiawei Shao <jiawei.shao@intel.com>
2021-09-11 09:04:34 +00:00
Michael Tang b21ccebac8 D3D12: Use a separate space for the index offset constants
Tint's HLSL writer can now map sets to spaces, so we can use a dedicated
space  and register to store the index offset constants. Currently, we
use the first space (0) and find a free unused register.

Bug: dawn:1103
Change-Id: Ie1fe95ec314097baf0e0952a0c78222cad493c95
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63223
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Michael Tang <tangm@microsoft.com>
2021-09-10 23:16:33 +00:00
Austin Eng 2092a66ab5 dawn_native: Add RequestDevice to the Adapter
Adds a basic RequestDevice method to the adapter, only in
dawn_native. We will revisit this when we implement adapters
in dawn_wire.

RequestDevice allows us to have tests of the limit bounds
because it receives a callback which can return status codes
and error messages.

Bug: dawn:685
Change-Id: I7a68922b078c6a436f49a16346cb41fb9df9cfee
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63982
Commit-Queue: Austin Eng <enga@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
2021-09-10 21:07:39 +00:00
Austin Eng dc7971ce58 dawn_wire: Support deserializing s->c chained structs
Chained structs *may* contain objects which means
deserialization may need an ObjectIdResolver.
However, in practice, we never need to send chained
structs from the server to the client that contain objects for
a valid command.

The one upcoming need for chained server->client structs is to
serialize limit structs.

Because limit structs never need objects, we provide a dummy
implementation of the ObjectIdResolver which always yields an error.
An analogous change is done for ObjectIdProvider.
These classes will be used in a follow-up CL.

Bug: dawn:685
Change-Id: I1c0f3f2d080377f2e1a77bc6e896f24d3d9ab931
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63981
Commit-Queue: Austin Eng <enga@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
2021-09-10 20:36:20 +00:00
Corentin Wallez 8ee643c9d0 Remove suppression for fixed Tint issue
Bug: tint:449
Change-Id: I7a1ee41bbd149c211096d0ce84c35ab8a0f937f9
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63745
Commit-Queue: Austin Eng <enga@chromium.org>
Auto-Submit: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Brandon Jones <bajones@google.com>
Reviewed-by: Austin Eng <enga@chromium.org>
2021-09-10 17:46:29 +00:00
Dawn Autoroller 7c8684a8e3 Roll Tint from ebab7d2f7a to 2ebcb93cb3 (1 revision)
https://dawn.googlesource.com/tint.git/+log/ebab7d2f7a7e..2ebcb93cb36c

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/tint-dawn
Please CC bajones@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Dawn: https://bugs.chromium.org/p/dawn/issues/entry

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md

Bug: None
Tbr: bajones@google.com
Change-Id: I83a4c3a3c43fa117ed99fcfd43abe759357610cf
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/64002
Reviewed-by: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2021-09-10 16:16:49 +00:00
Bryan Bernhart d9331035a6 Skip failing CopyTexture tests on WARP
BUG=dawn:1104

Change-Id: Ie4e870fd182bcf5ec0a0007317705a0555a76e0d
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63980
Reviewed-by: Austin Eng <enga@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Bryan Bernhart <bryan.bernhart@intel.com>
2021-09-10 16:09:19 +00:00
Corentin Wallez 363c28e5d1 Remove typedefs for deprecated types.
Bug: dawn:762
Change-Id: I1581d80898d4a98010bb14c5823a1a343c229664
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63383
Auto-Submit: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Brandon Jones <bajones@google.com>
Reviewed-by: Brandon Jones <bajones@google.com>
2021-09-10 15:50:19 +00:00
Corentin Wallez d4b85fbd76 Lift suppression for incorrect VVL image layout tracking
Fixed: dawn:785
Change-Id: I618d2d44c02ae5e256841392cb2359f3992e32dc
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/64020
Auto-Submit: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Brandon Jones <bajones@google.com>
Commit-Queue: Brandon Jones <bajones@google.com>
2021-09-10 15:02:24 +00:00
Corentin Wallez 7a446220a1 Reenable / delete DISABLED tests.
- We use Tint unconditionally so binding reflection is now correct.
 - WGSL disallows textureSampleCompare in compute shaders and is not
   likely to change.
 - We now support reading back stencil in tests.

Bug: dawn:439, dawn:667, dawn:216, dawn:704
Change-Id: I7ba0026bb906ce985abb495581b56977da7be2da
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63680
Reviewed-by: Brandon Jones <bajones@google.com>
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
2021-09-10 14:56:09 +00:00
Maksim Sisov 08949a3fe7 rename use_x11 to ozone_platform_x11
Ozone is default now in Chromium and non-Ozone/X11 (aka use_x11) is
deprecated. During the transition period use_x11 == ozone_platform_x11.

Bug: c/1096425
Change-Id: Iaec1bd171423936f5a1817fae08a72079faf16fc
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63840
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Maksim Sisov <msisov@igalia.com>
2021-09-10 06:08:41 +00:00
Jiawei Shao 6fa50b5e6c Vulkan: Support extension "depth_clamp"
This patch implements the extension "depth_clamp" on Vulkan, which
we need to test if we can correctly record "PrimitiveDepthClampingState"
in FlatRenderPipelineDescriptor - Currently FlatRenderPipelineDescriptor
fails to record this because we incorrectly ignore all the members in
"nextInChain".

BUG=dawn:529, dawn:716
TEST=dawn_end2end_tests

Change-Id: Iec407245a3f37d10a3d1428b0612f0e18e80c616
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63820
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Jiawei Shao <jiawei.shao@intel.com>
2021-09-10 01:33:41 +00:00
James Price 6e1f01f32b metal: Use single-entry point transform
We only remap bindings for the target entry point, so we need to strip
all other entry points to avoid generating invalid bindings for them.

Bug: tint:1170
Change-Id: Ia1a73601e8d620341fb4f7170dfa856632a04245
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63880
Commit-Queue: James Price <jrprice@google.com>
Auto-Submit: James Price <jrprice@google.com>
Reviewed-by: Austin Eng <enga@chromium.org>
2021-09-09 20:40:31 +00:00
Dawn Autoroller 3bc6716a77 Roll Tint from 25517e9ce8 to ebab7d2f7a (2 revisions)
https://dawn.googlesource.com/tint.git/+log/25517e9ce811..ebab7d2f7a7e

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/tint-dawn
Please CC bajones@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Dawn: https://bugs.chromium.org/p/dawn/issues/entry

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md

Bug: None
Tbr: bajones@google.com
Change-Id: Id5a005b422d6c23fe7658f6a3a654b04803e0e32
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63861
Reviewed-by: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2021-09-09 19:44:11 +00:00
Dawn Autoroller fd815c15ce Roll Tint from 733addc20f to 25517e9ce8 (1 revision)
https://dawn.googlesource.com/tint.git/+log/733addc20fbf..25517e9ce811

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/tint-dawn
Please CC bajones@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Dawn: https://bugs.chromium.org/p/dawn/issues/entry

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md

Bug: None
Tbr: bajones@google.com
Change-Id: I1bf2ebfe9f84aff3bcadbe252275acb50e07152c
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63860
Reviewed-by: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2021-09-09 14:05:01 +00:00
Dawn Autoroller 053b58cd29 Roll Tint from 5910ec1e8a to 733addc20f (1 revision)
https://dawn.googlesource.com/tint.git/+log/5910ec1e8afc..733addc20fbf

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/tint-dawn
Please CC bajones@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Dawn: https://bugs.chromium.org/p/dawn/issues/entry

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md

Bug: None
Tbr: bajones@google.com
Change-Id: I490ff195f9f7e5a1c4262ede68827d91a3606c6c
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63761
Reviewed-by: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2021-09-09 01:13:00 +00:00
Jiawei Shao d7ddfb4a91 Add FlatRenderPipelineDescriptor for CreateRenderPipelineAsync
This patch implements the struct FlatRenderPipelineDescriptor to
save all the pointer members of RenderPipelineDescriptor in
CreateRenderPipelineAsync so that the render pipeline descriptor
is always valid when the render pipeline is created asynchronously.

BUG=dawn:529
TEST=dawn_end2end_tests

Change-Id: I99e06581f84c52d484f877ba29e8cc1ca50d68b2
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63368
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Jiawei Shao <jiawei.shao@intel.com>
2021-09-09 00:59:29 +00:00
Dawn Autoroller f9d2873ef9 Roll Tint from be514a1efb to 5910ec1e8a (2 revisions)
https://dawn.googlesource.com/tint.git/+log/be514a1efb00..5910ec1e8afc

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/tint-dawn
Please CC bajones@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Dawn: https://bugs.chromium.org/p/dawn/issues/entry

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md

Bug: None
Tbr: bajones@google.com
Change-Id: I4608010eb83ad2ec99876b8fda92216544926786
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63760
Reviewed-by: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2021-09-08 20:23:10 +00:00
Dawn Autoroller dc27ecce5b Roll Tint from 676ec7cf99 to be514a1efb (1 revision)
https://dawn.googlesource.com/tint.git/+log/676ec7cf9964..be514a1efb00

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/tint-dawn
Please CC bajones@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Dawn: https://bugs.chromium.org/p/dawn/issues/entry

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md

Bug: None
Tbr: bajones@google.com
Change-Id: I3e0f91fdaddf6d243fd75e7ff1e13cdae134d7d4
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63720
Reviewed-by: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2021-09-08 14:39:18 +00:00
Zhaoming Jiang c6140d5c95 Initializing stencil reference for render pass in D3D12
When creating a new render pass in D3D12, call the OMSetStencilRef
to set the stencil reference value to zero.

Bug: dawn:1097
Change-Id: I5dd94691b1b354b601c06a02d3d5fa619d8b58ee
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63360
Commit-Queue: Jiawei Shao <jiawei.shao@intel.com>
Reviewed-by: Jiawei Shao <jiawei.shao@intel.com>
Reviewed-by: Austin Eng <enga@chromium.org>
2021-09-08 02:21:33 +00:00
Dawn Autoroller 9e10acee8a Roll Tint from c77214d52d to 676ec7cf99 (5 revisions)
https://dawn.googlesource.com/tint.git/+log/c77214d52d53..676ec7cf9964

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/tint-dawn
Please CC bajones@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Dawn: https://bugs.chromium.org/p/dawn/issues/entry

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md

Bug: None
Tbr: bajones@google.com
Change-Id: I0b50978ca7c42b134664477461213ec4b050ad50
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63601
Reviewed-by: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2021-09-07 21:29:55 +00:00
Loko Kung 37a8649f92 Adds ASTC texture compression formats and Vulkan support for them.
The end to end texture tests with the binary information for the textures are generated using the open source astc-encoder tool.

Also: Refactors end2end compressed texture tests to allow for non-4x4 texel compression formats (ASTC formats are not all 4x4).

Bug: dawn:955
Change-Id: I5311a5aa7bd017de72300bf7c87fba6c869b1db5
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63121
Commit-Queue: Loko Kung <lokokung@google.com>
Reviewed-by: Austin Eng <enga@chromium.org>
2021-09-07 18:39:04 +00:00
Dawn Autoroller e1f5934c1c Roll Tint from ed18f2f8c3 to c77214d52d (1 revision)
https://dawn.googlesource.com/tint.git/+log/ed18f2f8c325..c77214d52d53

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/tint-dawn
Please CC bajones@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Dawn: https://bugs.chromium.org/p/dawn/issues/entry

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md

Bug: None
Tbr: bajones@google.com
Change-Id: I4fa1f2b5f04f93eeb074aabe3bff4f0ef12274e4
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63600
Reviewed-by: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2021-09-07 16:24:24 +00:00
Jiawei Shao ba1feb07bc Always point to own members in FlatComputePipelineDescriptor
This patch fixes a use-after-free issue in FlatComputePipelineDescriptor
by always making its pointer members point to its own members.

BUG=dawn:529, chromium:1246158, chromium:1246748
TEST=dawn_end2end_tests

Change-Id: I49b98357444edcdb1b225e961d1e4d6e5b11e978
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63366
Commit-Queue: Jiawei Shao <jiawei.shao@intel.com>
Reviewed-by: Austin Eng <enga@chromium.org>
2021-09-06 07:46:49 +00:00
Dawn Autoroller 2e40f90e8c Roll Tint from 3e70f3e2ac to ed18f2f8c3 (8 revisions)
https://dawn.googlesource.com/tint.git/+log/3e70f3e2ac35..ed18f2f8c325

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/tint-dawn
Please CC sarahmashay@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Dawn: https://bugs.chromium.org/p/dawn/issues/entry

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md

Bug: None
Tbr: sarahmashay@google.com
Change-Id: I8cf1153133db2fceb1d3e36e26f9771ade16f16b
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63540
Reviewed-by: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2021-09-04 00:52:01 +00:00
Rafael Cintron 0376ebe3df Handle failed calls to ID3D12CommandQueue::GetTimestampFrequency
ID2D12CommandQueue::GetTimestampFrequency returns an error HRESULT
when there are bugs in Windows container and vGPU implementations.

To workaround, we check the return value during adapter creation
and disable the timestamp query extension upon failure.

Device creation is still allowed to succeed when the method returns
failure.

Change-Id: Ie71f8712fc9f4f50e4ce26ecfec929b5b1a126d4
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63225
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Rafael Cintron <rafael.cintron@microsoft.com>
2021-09-03 17:29:20 +00:00
Corentin Wallez 10b9cce816 Remove deprecated SetBlendColor and blend factors
Bug: chromium:1199057
Change-Id: I6fdc08f0a62b579b556c4c910611d095fcb3a66f
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63381
Reviewed-by: Austin Eng <enga@chromium.org>
Reviewed-by: Brandon Jones <bajones@chromium.org>
Commit-Queue: Brandon Jones <bajones@chromium.org>
2021-09-03 16:37:00 +00:00
Corentin Wallez fdfbb3aab3 Add dawn_wire/client/RequestTracker.h to build files
This was missed in a previous CL.

Bug: dawn:1092
Change-Id: I1915371c6a049d8c3b503c72194e568eb7fde95c
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63384
Auto-Submit: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Austin Eng <enga@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
2021-09-03 16:09:30 +00:00
Dawn Autoroller 90b41c78f9 Roll Tint from 03cd484247 to 3e70f3e2ac (1 revision)
https://dawn.googlesource.com/tint.git/+log/03cd48424797..3e70f3e2ac35

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/tint-dawn
Please CC sarahmashay@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Dawn: https://bugs.chromium.org/p/dawn/issues/entry

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md

Bug: None
Tbr: sarahmashay@google.com
Change-Id: I40874c60e8c99e35fe02511d04f51f54c99f1d04
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63364
Reviewed-by: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2021-09-02 21:27:49 +00:00
Brandon Jones 8a0b49b6d6 Add check for an invalid D3D12/Vk object in SetDebugLabel
Fixes a crash found while fuzzing by returning early when SetDebugName
is called with an empty D3D12/Vulkan object or when the device is lost.
Adds tests.

Bug: chromium:1245720
Change-Id: Ie443f690cf5635d017295a13e21c33dd2e97dc46
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63363
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Brandon Jones (Intel) <brandon1.jones@intel.com>
2021-09-02 21:15:40 +00:00
Brandon Jones c1bcbbf357 Add Labels For Pipelines and ShaderModule for D3D12/Vk
Adds labels for Pipelines and ShaderModule. Includes tests. Backend
functionality is implemented for Pipelines, and completed to best effort
for ShaderModule.

Bug: dawn:840
Change-Id: I55024a83f66d9fc2fc0e8b79e4b9a7ebc6f3cf1c
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/62860
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Brandon Jones (Intel) <brandon1.jones@intel.com>
2021-09-02 18:39:53 +00:00
Corentin Wallez 71f2214e14 vulkan: wait for fences on ErrorInjector device loss
When ErrorInjector injects a device loss, it is fake and commands are
still running on the device and we need to wait for them before we start
to deallocate stuff.

When handling the error in the frontend, call WaitForIdleForDestruction
so that all the commands are finished. In the Vulkan backend
WaitForIdleForDestruction have a special code path to no allow error
injection on vkWaitForFences in this specific case, as double error
injection would make the problem appear again.

Bug: chromium:1244408

Change-Id: I710fccbb40b4b14d84f5787be5e002b469e6e2e3
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63101
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Stephen White <senorblanco@chromium.org>
2021-09-02 17:23:18 +00:00
Stephen White c0f20fbc54 Remove all "WithTint" suffixes from Dawn native.
The D3D12 and Metal backends no longer support any other
shading language translator, so the suffix is superfluous.

Bug: dawn:1099
Change-Id: I6a1a249a80d59dbf9cabf5d4ea917f852745e78e
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63400
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Stephen White <senorblanco@chromium.org>
2021-09-02 16:50:58 +00:00
Dawn Autoroller 3f249c12b5 Roll Tint from cf57896d52 to 03cd484247 (3 revisions)
https://dawn.googlesource.com/tint.git/+log/cf57896d5205..03cd48424797

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/tint-dawn
Please CC sarahmashay@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Dawn: https://bugs.chromium.org/p/dawn/issues/entry

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md

Bug: None
Tbr: sarahmashay@google.com
Change-Id: I218a76faf67ce86799160bd40e5c36f92acffa75
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63362
Reviewed-by: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2021-09-02 15:43:38 +00:00
Dawn Autoroller 1f86ce30b6 Roll Tint from 44a0adf9b4 to cf57896d52 (1 revision)
https://dawn.googlesource.com/tint.git/+log/44a0adf9b47c..cf57896d5205

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/tint-dawn
Please CC sarahmashay@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Dawn: https://bugs.chromium.org/p/dawn/issues/entry

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md

Bug: None
Tbr: sarahmashay@google.com
Change-Id: I4fc1a134f35c6cf8894bd74a81c165c61accccd0
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63361
Reviewed-by: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2021-09-02 10:59:30 +00:00
Corentin Wallez 749e14490e Add Dawn's logo and use it in README.md
Change-Id: Ia504f2025c8a7ea139b41d72140a36510ad7db0b
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63380
Reviewed-by: François Beaufort <beaufort.francois@gmail.com>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
2021-09-02 09:51:40 +00:00
Jiawei Shao 305f4df2b5 Add FlatComputePipelineDescriptor for CreateComputePipelineAsync
This patch implements the struct FlatComputePipelineDescriptor to
save all the pointer members of ComputePipelineDescriptor in
CreateComputePipelineAsyncTask to better simplify the orignal code
path.

We will also implement FlatRenderPipelineDescriptor in the next
patch, which is more important for CreateRenderPipelineAsync as
there are many more pointer members in RenderPipelineDescriptor
than those in ComputePipelineDescriptor.

BUG=dawn:529

Change-Id: I69ab0dc898f0a6dcc9886d827729e6fd7308bd2d
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63280
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Jiawei Shao <jiawei.shao@intel.com>
2021-09-02 00:30:31 +00:00
Brandon Jones 1f48c97353 Update default pipeline layout compatibility rules
Prevents bind group layouts created by a default pipeline layout from
being reusable with any other pipelines or layouts, as detailed in
https://github.com/gpuweb/gpuweb/pull/2068

Change-Id: Ic398eb6c6e089ac63ce6650f125dd20a9dfc8862
Bug: dawn:1094
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63220
Commit-Queue: Brandon Jones <bajones@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
2021-09-01 22:15:41 +00:00
Corentin Wallez baf8df396c dawn_wire/client: Add RequestTracker helper
This helper helps ensure correct handling of request maps by:

 - Forcing erasing to happen immediately when acquiring a request. This
   prevents some cases of iterator invalidation if we later change the
   container type.
 - Implements correct closure of all callbacks, including if the
   callbacks themselves add more callbacks.

Bug: dawn:1092

Change-Id: Ia0ba9f050bbf3f0dee846f537910523bebb3bf1b
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63003
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Auto-Submit: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
2021-09-01 16:40:22 +00:00
Dawn Autoroller 4a4a804476 Roll Tint from 14ac047d45 to 44a0adf9b4 (1 revision)
https://dawn.googlesource.com/tint.git/+log/14ac047d45ff..44a0adf9b47c

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/tint-dawn
Please CC sarahmashay@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Dawn: https://bugs.chromium.org/p/dawn/issues/entry

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md

Bug: None
Tbr: sarahmashay@google.com
Change-Id: Iefd7aa69fb93cb289b964eaffb5d4c363712e734
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63260
Reviewed-by: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2021-09-01 03:40:31 +00:00
Dawn Autoroller 5097f299af Roll Tint from b09723e58b to 14ac047d45 (4 revisions)
https://dawn.googlesource.com/tint.git/+log/b09723e58b8d..14ac047d45ff

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/tint-dawn
Please CC sarahmashay@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Dawn: https://bugs.chromium.org/p/dawn/issues/entry

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md

Bug: None
Tbr: sarahmashay@google.com
Change-Id: I119523b86dd4b1228bd6cdbba5946f1ac8bd1de5
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63221
Reviewed-by: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2021-08-31 22:50:41 +00:00
Dawn Autoroller 77667094be Roll Tint from 293d313bbc to b09723e58b (1 revision)
https://dawn.googlesource.com/tint.git/+log/293d313bbca2..b09723e58b8d

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/tint-dawn
Please CC sarahmashay@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Dawn: https://bugs.chromium.org/p/dawn/issues/entry

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md

Bug: None
Tbr: sarahmashay@google.com
Change-Id: I10b972d97e440c6fbb20ed0d6f3e45f5e21c7b37
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63200
Reviewed-by: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2021-08-31 17:52:34 +00:00
shrekshao 3fdfa82f7b Callback reentrancy tests
Some tests to make sure new requests inside user callback
is okay.

Bug: dawn:1091
Change-Id: I4c53d7fb6637f77e5af6fd0a78d879a2431d4ac8
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63041
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Shrek Shao <shrekshao@google.com>
2021-08-31 15:18:54 +00:00
Jiawei Shao 67fc6aeb82 Remove redundant code in CreateRenderPipeline
This patch removes the redundant code in CreateRenderPipeline so
that we can better share the common code in both CreateRenderPipeline
and CreateRenderPipelineAsync.

BUG=dawn:529

Change-Id: Ic2a7781525e5594da3d51a42b231df63c0c09339
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/62880
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Jiawei Shao <jiawei.shao@intel.com>
2021-08-31 07:47:57 +00:00
Loko Kung c7226a7624 Adds ETC2/EAC texture compression formats and Vulkan support for them
The end to end texture tests with the binary information for the textures are generated with a combination of the open source etc2comp tool and manual crafting of the data based on the specification in the Kronos Data Format Specifications (https://www.khronos.org/registry/DataFormat/specs/1.1/dataformat.1.1.pdf) for the compressed formats.

Also: Refactors end2end compressed texture tests and some utilities so that we can use parameterized tests for easier new format additions.

Bug: dawn:955
Change-Id: I91686f26a693a85cb076ef0eca3029111a64c50f
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/62740
Commit-Queue: Loko Kung <lokokung@google.com>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
2021-08-31 00:15:45 +00:00
Corentin Wallez 6bb3f6f216 vulkan: Free "in flight" fences/commands in ShutdownImpl
There might still be fences and commands marked as in-flight in
ShutdownImpl if the device was lost. Delete them anyway because since
the device was lost, it means that all objects are no longer in the
"pending" state (from the Vulkan spec point of view)

Bug: chromium:1244454
Change-Id: I905a9a8e5174591bf93e3cdac3cdcb349d75a581
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63102
Commit-Queue: Austin Eng <enga@chromium.org>
Auto-Submit: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Stephen White <senorblanco@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
2021-08-30 20:01:04 +00:00
Corentin Wallez 52ad8f6768 client: call pending GetCompilationInfo on Disconnect
Fixed: dawn:1090
Change-Id: Ia7cf692ea41ebe85aaac58e3f3aa6727e6cc8ba4
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63002
Auto-Submit: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
Reviewed-by: Shrek Shao <shrekshao@google.com>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
2021-08-30 08:00:45 +00:00
Dawn Autoroller ea487972d1 Roll Tint from a96dce9c89 to 293d313bbc (7 revisions)
https://dawn.googlesource.com/tint.git/+log/a96dce9c893e..293d313bbca2

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/tint-dawn
Please CC rharrison@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Dawn: https://bugs.chromium.org/p/dawn/issues/entry

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md

Bug: None
Tbr: rharrison@google.com
Change-Id: I568ecc400efb267d73318a40bb30cab9b7889ce2
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63040
Reviewed-by: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2021-08-27 20:26:11 +00:00