Commit Graph

2645 Commits

Author SHA1 Message Date
Ryan Harrison ce207be41f Use the transform manager instead of invoking the transform directly
This will allow us on the Tint side to refactor the transform code to
correctly run the type determiner at the end of transforms, instead of
hacking it into the transform itself.

Bug: tint:308

Change-Id: I4fd5693ec700b2165ce8c08028b09df6cd8591e7
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/33123
Commit-Queue: Ryan Harrison <rharrison@chromium.org>
Reviewed-by: dan sinclair <dsinclair@chromium.org>
Auto-Submit: Ryan Harrison <rharrison@chromium.org>
2020-11-18 17:07:42 +00:00
Dawn Autoroller 2ba8f3cec4 Roll Tint from 90f3253645 to 46d9c7745e (13 revisions)
https://dawn.googlesource.com/tint.git/+log/90f32536458a..46d9c7745efa

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 kainino@google.com on the revert to ensure that a human
is aware of the problem.

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/master/autoroll/README.md

Bug: None
Tbr: kainino@google.com
Change-Id: I353145b6f42572fc5090b6e9e3da874d27084138
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/33220
Reviewed-by: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2020-11-18 15:35:42 +00:00
Hao Li 01e4450729 Query API: Non Precise Occlusion Query
- Add BeginOcclusionQuery and EndOcclusionQuery in frontend
- Set occlusion query as unsafe APIs
- Add validation tests

Bug: dawn:434
Change-Id: I3d1cefed780812dd62fb082287ff71530b76ebee
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/31321
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
2020-11-18 09:47:52 +00:00
Corentin Wallez 55f251dffe RefBase: remove implicit conversion to bool.
This helps push for comparing against nullptr more consistently.

Also replaces .Get() == nullptr and .Get() != nullptr with just ==
nullptr and != nullptr.

Bug: dawn:89
Change-Id: I884a4819f97305a73c11bad84391d1d2113ab7e2
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/32922
Reviewed-by: Austin Eng <enga@chromium.org>
Reviewed-by: Stephen White <senorblanco@chromium.org>
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
2020-11-18 09:10:22 +00:00
Jiawei Shao a0758a1aef D3D12: Only enable toggle 'use_dxc' when Dawn can load DXC DLLs
This patch adds an additional check in the initialization of device
on D3D12 backend to ensure that 'use_dxc' is enabled only when Dawn
can load DXC DLLs (dxil.dll and dxcompiler.dll).

BUG=dawn:402

Change-Id: I85bc8698cf54b612244efc3673241f60a9cee209
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/33060
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Jiawei Shao <jiawei.shao@intel.com>
2020-11-18 00:14:31 +00:00
Corentin Wallez d4e7f08e0b Use hermetic XCode on Dawn standalone builders.
Bug:
Change-Id: I25fc33c01e2148ed2626ff6d1999d414c8c8f04b
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/33100
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>
2020-11-17 21:16:31 +00:00
Corentin Wallez 698385d4e2 Stop setting mac_xcode_version in DEPS
Bug: chromium:1147839
Change-Id: I86eb440df2b2297e1be38d916d3c1f0fd364ca6c
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/32981
Commit-Queue: Austin Eng <enga@chromium.org>
Auto-Submit: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
2020-11-17 17:27:51 +00:00
Dawn Autoroller af9a618b47 Roll Tint from 4ad0019df0 to 90f3253645 (17 revisions)
https://dawn.googlesource.com/tint.git/+log/4ad0019df0f0..90f32536458a

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 kainino@google.com on the revert to ensure that a human
is aware of the problem.

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/master/autoroll/README.md

Bug: None
Tbr: kainino@google.com
Change-Id: Ifb1ab98c26be04a471d1a0e9719bdac151e6d215
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/33061
Reviewed-by: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2020-11-17 15:18:01 +00:00
Corentin Wallez d98e8b70bb Use smart Refs for IOKit and CoreFoundation objects.
Bug: dawn:89
Change-Id: Idea634bcc65ab4ec017f4e4c2431e95915f533df
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/32661
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
Reviewed-by: Stephen White <senorblanco@chromium.org>
2020-11-17 11:35:11 +00:00
Austin Eng f2bc3b3edd Print warning if errors occur and no error callback has been set
Bug: none
Change-Id: Ibbd6f90be5192ad3975bb8b24f9b3053f7f9d74f
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/32744
Commit-Queue: Austin Eng <enga@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
2020-11-16 23:32:36 +00:00
Corentin Wallez 0055d95fa7 Metal: Wrap NS classes and protocols in NSRef.
This makes refcounting of these objects more automatic to try and
prevent leaks or use-after-frees in the future.

Also removes operator* from RefBase (and Ref) because it is never used
and cannot work in a normal way for ObjectiveC protocols that cannot be
dereferenced.

Bug: dawn:89

Change-Id: I2e3fbfd638e2ba76d8c563f30bc489a384152552
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/32161
Reviewed-by: Austin Eng <enga@chromium.org>
Reviewed-by: Stephen White <senorblanco@chromium.org>
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
2020-11-16 23:07:56 +00:00
Austin Eng 1805e46a15 Remove --skip-validation test flag from Dawn tests
--enable-toggles=skip_validation is now the correct way to set
the toggle.

Bug: dawn:571
Change-Id: Ia05f542693fdd0eaadb0d87682a2f4b122e2ccb3
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/32743
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Austin Eng <enga@chromium.org>
2020-11-16 22:41:36 +00:00
dawn-autoroll 2c5b040b5c Roll Tint from e5e9617220 to 4ad0019df0 (1 revision)
https://dawn.googlesource.com/tint.git/+log/e5e961722054..4ad0019df0f0

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 kainino@google.com on the revert to ensure that a human
is aware of the problem.

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/master/autoroll/README.md

Bug: None
Tbr: kainino@google.com
Change-Id: I4ce69a5df8e0d5481a78763ab7f5f4a560339080
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/32880
Reviewed-by: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2020-11-16 15:06:29 +00:00
Robert Sesek dd6b36e880 Use the correct GN variable for the Mac deployment target.
The GN files were incorrectly using mac_min_system_version to refer to
the deployment target. The right variable is mac_deployment_target, and
using mac_min_system_version breaks Chrome's ability to update the
minimum system version without needing to update the deployment target.

Bug: chromium:1148931
Change-Id: I4c49bb24cb6c4293249c5cb26dd8971b863d260c
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/32720
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
2020-11-16 14:53:59 +00:00
Hao Li 575729e8dd Add query availability tracking in render pass encoder
The same query cannot be written twice in same render pass, so each
render pass also need to have its own query availability map.

Update timestamp query to only check the same query overwrite in same
render pass.

Bug: dawn:434
Change-Id: Icb070adf79a3d76c25367675f7432666eb0dd84f
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/31180
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Hao Li <hao.x.li@intel.com>
2020-11-16 02:24:06 +00:00
dawn-autoroll aabde6c88f Roll Tint from 8ca4561b25 to e5e9617220 (18 revisions)
https://dawn.googlesource.com/tint.git/+log/8ca4561b25dd..e5e961722054

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 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/master/autoroll/README.md

Bug: None
Tbr: sarahmashay@google.com
Change-Id: I2991f65d7ca05969cbc754eafdbe01b288361552
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/32760
Reviewed-by: <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2020-11-14 16:56:24 +00:00
Austin Eng 464aaeb558 Add InjectValidationError to command encoder
Needed to implement bytesPerRow/rowsPerImage validation
in Blink.

Bug: dawn:566
Change-Id: I60e9ebd57e40d5043e7277cdc560cbf673bc2576
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/32582
Reviewed-by: Kai Ninomiya <kainino@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Austin Eng <enga@chromium.org>
2020-11-14 01:24:03 +00:00
Austin Eng b38a9c3ee7 Add end2end tests flags --enable-toggles and --disable-toggles
Also changes test helpers to use a generic HasToggleEnabled instead
of a helper function per-toggle.

Bug: dawn:571
Change-Id: Ifd2e787a733382dcd5ad08222616c12cb42fb62b
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/32300
Commit-Queue: Austin Eng <enga@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
2020-11-14 01:09:23 +00:00
Austin Eng da1f66c8ce Update DepthBiasTests to use WGSL
Bug: dawn:572
Change-Id: Ie221813162792229bf53f4123c262be929256f39
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/32509
Reviewed-by: dan sinclair <dsinclair@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Austin Eng <enga@chromium.org>
2020-11-13 18:41:32 +00:00
Austin Eng b1cdcffef4 Update CullingTests to use WGSL
Bug: dawn:572
Change-Id: Iacaec3b0a56b357159c8beff26229812538c68b6
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/32508
Reviewed-by: dan sinclair <dsinclair@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Austin Eng <enga@chromium.org>
2020-11-13 18:18:22 +00:00
Austin Eng 53c5cbeaf5 Update ComputeIndirectTests to use WGSL
Bug: dawn:572
Change-Id: Ib117cd2ea2a7a536c6990cc1481e179340fab4d3
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/32506
Reviewed-by: dan sinclair <dsinclair@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Austin Eng <enga@chromium.org>
2020-11-13 18:03:52 +00:00
Austin Eng c2eb8653ac Update CompressedTextureFormatTests to use WGSL
Bug: dawn:572
Change-Id: Ie2fbe2c24ee5ec93e145018a1251f8a11f457ee9
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/32504
Reviewed-by: dan sinclair <dsinclair@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Austin Eng <enga@chromium.org>
2020-11-13 17:47:29 +00:00
Austin Eng e08776ae09 Update ColorStateTests to use WGSL
Bug: dawn:572
Change-Id: Id94d249c76098bcce0351fb8cca06879db75d638
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/32503
Reviewed-by: dan sinclair <dsinclair@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Austin Eng <enga@chromium.org>
2020-11-13 17:30:59 +00:00
Austin Eng f6958ff783 Update ClipSpaceTests to use WGSL
Bug: dawn:572
Change-Id: Iad55df4f39dfa91ef4554908acb9e2bb45703124
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/32502
Reviewed-by: dan sinclair <dsinclair@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Austin Eng <enga@chromium.org>
2020-11-13 17:15:59 +00:00
dawn-autoroll 56523dff69 Roll Tint from 1980095da7 to 8ca4561b25 (2 revisions)
https://dawn.googlesource.com/tint.git/+log/1980095da7f4..8ca4561b25dd

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 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/master/autoroll/README.md

Bug: None
Tbr: sarahmashay@google.com
Change-Id: I7c9eb6e53caf8d1b8aa886185d6423c3bf987761
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/32680
Reviewed-by: <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2020-11-13 16:38:29 +00:00
Brandon Jones b6f4d53126 Only Increment Serials When Necessary On D3D12
Only increments last submitted and last completed serials from the D3D12
backend when commands were submitted to the GPU.

Bug: dawn:119
Change-Id: I01748b7f4ac90443adac4cdef29016184f992e9c
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/32162
Commit-Queue: Brandon Jones <brandon1.jones@intel.com>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
2020-11-13 02:11:12 +00:00
Austin Eng bc6a700bf5 dawn_wire: Protect against large allocations in ChunkedCommandHandler
Use std::nothrow on the allocation to catch failed allocations. Enforce
a max allocation limit a bit lower than ASAN's max 2GB allocation.

Bug: chromium:1145204
Change-Id: I91f2ddd5b58da6c39d4ab8bc447f7d9b7af8615f
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/32340
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Jiawei Shao <jiawei.shao@intel.com>
Commit-Queue: Austin Eng <enga@chromium.org>
2020-11-13 01:49:12 +00:00
Austin Eng 8d69298d9b Rename DepthSamplingTests to DepthStencilSamplingTests
Bug: none
Change-Id: I2d1fc8bfd35ddb80f34724639ff14ad3fd1ed4d9
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/32581
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Austin Eng <enga@chromium.org>
2020-11-12 20:57:42 +00:00
Ryan Harrison 2b4609bb02 Use remapped entry point name in D3D12
Tint may remap entry point names when translating a shader, so need to
use the Inspector to get the remapped name for calling into DXC/FXC.

Roll third_party/tint/ 1995ddf87..1980095da (1 commit)

https://dawn.googlesource.com/tint/+log/1995ddf876ef..1980095da7f4

$ git log 1995ddf87..1980095da --date=short --no-merges --format='%ad %ae%s'
2020-11-12 rharrison [inspector] Convert GetRemapped to be a pass through

Created with:
  roll-dep third_party/tint

BUG=tint:273

Change-Id: I62cdd78334d4b3dacfdd7cf5668917622bc22ea2
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/32540
Commit-Queue: Ryan Harrison <rharrison@chromium.org>
Reviewed-by: dan sinclair <dsinclair@chromium.org>
2020-11-12 19:30:32 +00:00
Austin Eng 7ceffe8511 dawn_wire: Reject new callbacks if the client is disconnected
If the wire client is disconnected, it will not receive any
messages from the server. Reject all callbacks that are created.

Bug: dawn:556
Change-Id: I2eb2c449b1ca6c8ea3e74040ef095abfc46a9061
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/31161
Commit-Queue: Austin Eng <enga@chromium.org>
Reviewed-by: Stephen White <senorblanco@chromium.org>
2020-11-12 18:03:42 +00:00
dawn-autoroll 01e969da33 Roll Tint from 0573714bfd to 1995ddf876 (19 revisions)
https://dawn.googlesource.com/tint.git/+log/0573714bfd0f..1995ddf876ef

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 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/master/autoroll/README.md

Bug: None
Tbr: sarahmashay@google.com
Change-Id: I0ccb7b928e22d0bf3f6720e70bf2dc32c486018f
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/32501
Reviewed-by: <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2020-11-12 16:26:11 +00:00
Corentin Wallez 2089adc62a Move most of Ref's functionality in RefBase for reuse.
This will allow using the same logic for other kinds of smartpointers,
like NSRef<>

Bug: dawn:89
Change-Id: Idbe08208fdb38b236f52635bc913162e60baf0f0
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/32160
Reviewed-by: Stephen White <senorblanco@chromium.org>
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
2020-11-12 11:47:59 +00:00
Austin Eng b70a5b02e9 Reject all callbacks with DeviceLost on wire client disconnect
When the wire is disconnected, the client will not receive any
messages from the server. We need to manually reject all callbacks.

Bug: dawn:556
Change-Id: Ia03456b3209dbe0e1e54543d344180d11d4c6f1e
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/31162
Commit-Queue: Austin Eng <enga@chromium.org>
Reviewed-by: Stephen White <senorblanco@chromium.org>
2020-11-11 21:01:18 +00:00
Austin Eng 3120d5ea0d Track and destroy all child objects on wire client destruction
This is needed so that:
 1. We can support multiple devices in the wire. The device will need
    to know how to destroy its child objects.
 2. The wire needs to be aware of all objects and their in-flight
    callbacks so that it can reject them if the wire is disconnnected.
    A future change will handle this.
 3. Fix leaks of objects on page teardown. When the page is torn down,
    the wire client is destroyed, and we skip calling release() for all
    objects since the object holding the proc table was also destroyed.

Bug: dawn:384, dawn:556

Change-Id: Ie23afe4e515b02e924fcfc2db92b749fd2257c9c
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/31160
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Austin Eng <enga@chromium.org>
2020-11-11 19:46:18 +00:00
dawn-autoroll f3c8290472 Roll Tint from 7b750dc733 to 0573714bfd (8 revisions)
https://dawn.googlesource.com/tint.git/+log/7b750dc7337d..0573714bfd0f

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 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/master/autoroll/README.md

Bug: None
Tbr: sarahmashay@google.com
Change-Id: If7c38a11f9d7c3afc5ea4ddff9c74ca992f04da6
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/32240
Reviewed-by: <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2020-11-10 22:29:13 +00:00
Corentin Wallez c04a0132be Remove deprecated Device::CreateQueue.
Bug: dawn:22
Change-Id: I0b2c9fec3440808c9a481fe215a4e25a604c79f1
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/32022
Reviewed-by: Austin Eng <enga@chromium.org>
Reviewed-by: Stephen White <senorblanco@chromium.org>
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
2020-11-09 22:32:35 +00:00
Corentin Wallez f2df66fce8 Remove deprecated names of texture formats.
Bug: dawn:22
Change-Id: I380380d3d965e603794123739392dae32b84ab9b
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/32021
Reviewed-by: Austin Eng <enga@chromium.org>
Reviewed-by: Stephen White <senorblanco@chromium.org>
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
2020-11-09 21:19:25 +00:00
dawn-autoroll 0053fef8a4 Roll Tint from 8655b62207 to 7b750dc733 (1 revision)
https://dawn.googlesource.com/tint.git/+log/8655b62207a5..7b750dc7337d

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 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/master/autoroll/README.md

Bug: None
Tbr: sarahmashay@google.com
Change-Id: I5eae101d3088f5445fcf9d7e399691b86c72be19
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/32120
Reviewed-by: <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2020-11-09 16:28:44 +00:00
dawn-autoroll 3e17e33724 Roll Tint from cc2305dd95 to 8655b62207 (4 revisions)
https://dawn.googlesource.com/tint.git/+log/cc2305dd9537..8655b62207a5

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 cwallez@google.com on the revert to ensure that a human
is aware of the problem.

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/master/autoroll/README.md

Bug: None
Tbr: cwallez@google.com
Change-Id: I21393436da00dec6f975dd42ff244da2d1bf6925
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/32080
Reviewed-by: <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2020-11-07 17:52:46 +00:00
dawn-autoroll 56af9cbd3f Roll Tint from 795bf4c716 to cc2305dd95 (1 revision)
https://dawn.googlesource.com/tint.git/+log/795bf4c71637..cc2305dd9537

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 cwallez@google.com on the revert to ensure that a human
is aware of the problem.

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/master/autoroll/README.md

Bug: None
Tbr: cwallez@google.com
Change-Id: Ib6a1f7fed37fc61fdb9954c4b66e9bb40eabc9e6
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/31941
Reviewed-by: <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2020-11-06 17:18:50 +00:00
Corentin Wallez 3317374395 Use IsSubset in more places.
This helper function makes the code easier to read because the name
encodes the semantic of the operation compared to the bit-twiddling that
it replaces.

Bug: None
Change-Id: Iab587e04a91cf60acf8920de1f20bb55f3ea3816
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/31668
Reviewed-by: Stephen White <senorblanco@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
2020-11-06 17:11:50 +00:00
Corentin Wallez a701961ad3 SwapChainVK: Handle transform, imageCount, alphaMode.
This removes outstanding TODOs in the creation of the VkSwapChain
by correctly handling imageCount and validation that the surface
supports identity transform and opaque alpha mode.

Bug: dawn:269

Change-Id: Ifbc30a9832a6853731be0460928ddcd4966a1e6a
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/31560
Reviewed-by: Stephen White <senorblanco@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
2020-11-06 16:41:20 +00:00
Kai Ninomiya 16036cf206 Add WGPU_STRIDE_UNDEFINED and update bytesPerRow/rowsPerImage validation
This makes a nearly one-to-one mapping between the JS and C APIs, which
benefits projects like Blink and Emscripten.

- JavaScript's `undefined` is equivalent to C `WGPU_STRIDE_UNDEFINED`.
- JavaScript's `0` is equivalent to C `0`.
- To implement the API correctly, Blink must special-case an actual
  value coming in from JS that is equal to WGPU_STRIDE_UNDEFINED
  (0xFFFF'FFFF), and inject an error.

Keeps but deprecates a reasonable approximation of the old behavior.

Bug: dawn:520
Change-Id: Ie9c992ffab82830090d0dfc3120731e89cd9691c
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/31140
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
2020-11-06 13:41:50 +00:00
Corentin Wallez 973d145df8 Make dawn_platform a component.
Bug: None
Change-Id: I29c20cd3dac759afee23bdaf5a4391081e29cbaa
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/31900
Commit-Queue: Jiawei Shao <jiawei.shao@intel.com>
Reviewed-by: Austin Eng <enga@chromium.org>
Reviewed-by: Jiawei Shao <jiawei.shao@intel.com>
2020-11-06 09:02:30 +00:00
Enrico Galli 2b6b0f45ff Add support for Tint's HLSL writer as a Toggle
This commit adds a Toggle that switches SPIRV-cross's HLSL generator for
Tint's HLSL writer. New Toggle currently defaults to false.

Bug: dawn:548
Change-Id: I37e238c6ba887efd65727809c8a6919df515a35e
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/31640
Reviewed-by: Bryan Bernhart <bryan.bernhart@intel.com>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Commit-Queue: Enrico Galli <enrico.galli@intel.com>
2020-11-05 18:52:49 +00:00
dawn-autoroll c1dbb2625b Roll Tint from 77f7bb5b00 to 795bf4c716 (10 revisions)
https://dawn.googlesource.com/tint.git/+log/77f7bb5b005d..795bf4c71637

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 cwallez@google.com on the revert to ensure that a human
is aware of the problem.

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/master/autoroll/README.md

Bug: None
Tbr: cwallez@google.com
Change-Id: I1c57b77f7f4d97dd4d401cce1e6f51de38a37fb9
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/31940
Reviewed-by: <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2020-11-05 17:06:29 +00:00
Corentin Wallez d42713de7a Remove support for multiple entrypoints with the same name
Previsouly having a ShaderModule with multiple entrypoints with the same
name and different stages was valid in Dawn. However it is disallowed by
the WGSL specification so change Dawn to index the ShaderModule's
entrypoints only by their name (instead of name and stage).

Bug: dawn:216
Change-Id: Id6fc80a03436b008c2f057bd30c70fdf240919e8
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/31665
Reviewed-by: dan sinclair <dsinclair@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
2020-11-05 13:25:16 +00:00
Jiawei Shao e87a8c466f DawnTest: only choose one adapter from those with same name and backendType
When running Dawn end2end tests on latest Windows 10 (20H2) in a Remote
Desktop session there can be multiple adapters with same name and type,
which will cause the crash of Dawn end2end tests as the GTest framework
doesn't allow two cases having the same name.

This patch fixes this issue by only choosing one adapter from the ones
with same name and backendType in DawnTests.

BUG=dawn:396
TEST=dawn_end2end_tests

Change-Id: I42de7fc1f3e9f8919af251c047cd873ba84d7190
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/31583
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
2020-11-05 08:38:46 +00:00
dawn-autoroll 6564890116 Roll Tint from de6938789c to 77f7bb5b00 (18 revisions)
https://dawn.googlesource.com/tint.git/+log/de6938789ccb..77f7bb5b005d

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 cwallez@google.com on the revert to ensure that a human
is aware of the problem.

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/master/autoroll/README.md

Bug: None
Tbr: cwallez@google.com
Change-Id: Ib7a5a5fcb63d3384f2e25628a4a66fb085397be9
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/31820
Reviewed-by: <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2020-11-04 16:55:22 +00:00
Corentin Wallez fb367e32c6 Reenable DepthBias tests on Swiftshader
The fix in Swiftshader has been rolled into Dawn so they pass.

Bug: dawn:524
Change-Id: I0328672f6cdb829cb28799160d9f584ebed2e422
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/31666
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
2020-11-04 15:59:11 +00:00