Commit Graph

8734 Commits

Author SHA1 Message Date
Austin Eng 18416ecdf9 dawn_node: Fix wgpu::ErrorFilter::None
This enum value was removed.

Bug: dawn:1206
Change-Id: Ifebceb01e817a29daec6629434d4dd792f343f74
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/72940
Auto-Submit: Austin Eng <enga@chromium.org>
Reviewed-by: Shrek Shao <shrekshao@google.com>
Reviewed-by: Brandon Jones <bajones@chromium.org>
Commit-Queue: Brandon Jones <bajones@chromium.org>
2021-12-15 00:29:46 +00:00
Austin Eng 89ddadcd1e Add feature queries to dawn_native/dawn_wire
This is so we can implement the adapter/device APIs fully
on dawn_wire.

Bug: dawn:689
Change-Id: I47f68157d081f359f871e0efe0d974dfe53de7d7
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/71521
Reviewed-by: Loko Kung <lokokung@google.com>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Austin Eng <enga@chromium.org>
2021-12-15 00:12:30 +00:00
Dawn Autoroller fe1e929d5a Roll Tint from 5ad482744d to 9360046a86 (1 revision)
https://dawn.googlesource.com/tint.git/+log/5ad482744db1..9360046a86f6

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 enga@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: enga@google.com
Change-Id: I4edc02c047dad50b875b1b6b5dc30d5122e8a4a0
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/72900
Bot-Commit: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2021-12-15 00:12:05 +00:00
Austin Eng 5397f9f9d0 Add basic or stub implementations of upstream instance/adapter APIs
Adds upstream instance/adapter APIs. In dawn_native, the basic APIs
to get limits and properties are implemented, but requestAdapter and
requestDevice are not. In dawn_wire, nothing is implemented, but the
stub definitions are put in place, as well the mechanism to inject
WGPUInstance into the wire.

There is a lifetime concern with WGPUInstance and WGPUAdapter on the
wire in that we need to ensure that the client cannot free the
instance or adapter while they are in use. In the near term, this is
not a problem because Chromium will always hold ownership of the
instance and adapters outside of the wire - i.e. it won't inject and
then release ownership.

Bug: dawn:160, dawn:689
Change-Id: Id904272983f23babc9177bc163d78c4fa1044da0
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/71520
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Loko Kung <lokokung@google.com>
Commit-Queue: Austin Eng <enga@chromium.org>
2021-12-14 23:22:46 +00:00
Austin Eng 0e6f443359 Remove dawn_native::DeviceDescriptor typedef
Bug: dawn:160, dawn:689
Change-Id: I9ec5f2056ac70c4150e6555291045690ee295403
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/70582
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Austin Eng <enga@chromium.org>
2021-12-14 22:35:35 +00:00
David Neto 9360046a86 spirv-reader: Use GenerateExpressionWithLoadIfNeeded more
* Rename GenerateNonReferenceExpression to
  GenerateExpressionWithLoadIfNeeded.
  This version takes an ast::Expression
* Add a variant that takes a sem::Expression, because the sem
  expression already knows the resolved type, and so we can save
  a lookup.
* Replace most uses of GenerateExpression ... GenerateLoadIfNeeded
  with a call to one of the above.

This is a non-functional change.
Followup to the fix in tint:1343.

Bug: tint:1343
Change-Id: If19a1bc7670edd2badc1533861d8b42f0825c7b8
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/72720
Auto-Submit: David Neto <dneto@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: Antonio Maiorano <amaiorano@google.com>
Commit-Queue: David Neto <dneto@google.com>
2021-12-14 22:15:39 +00:00
Dawn Autoroller f296710f64 Roll Tint from 9b9132c715 to 5ad482744d (1 revision)
https://dawn.googlesource.com/tint.git/+log/9b9132c71522..5ad482744db1

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 enga@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: enga@google.com
Change-Id: Id8b40868db9dcd42e93569b72283446335b4e53c
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/72820
Bot-Commit: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2021-12-14 16:13:06 +00:00
David Neto 5ad482744d spirv-writer: Generate load if needed for continue block conditional exit
Fixed: tint:1343
Change-Id: Ic105e407c572f1c309da8f21908a16c08b081f7f
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/72641
Reviewed-by: Ben Clayton <bclayton@google.com>
Auto-Submit: David Neto <dneto@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: Antonio Maiorano <amaiorano@google.com>
Commit-Queue: David Neto <dneto@google.com>
2021-12-14 15:16:11 +00:00
Dawn Autoroller 5b6107e8f2 Roll ANGLE from ea03bf47e50f to f236c8f29bbe (10 revisions)
ea03bf47e5..f236c8f29b

2021-12-14 angle-autoroll@skia-public.iam.gserviceaccount.com Roll vulkan-deps from a0a6270b47e4 to c03890076954 (1 revision)
2021-12-14 angle-autoroll@skia-public.iam.gserviceaccount.com Roll SwiftShader from 592d413edb56 to f354daff5a2b (4 revisions)
2021-12-14 angle-autoroll@skia-public.iam.gserviceaccount.com Roll Chromium from 30aeba8927a2 to 0c0a3654694f (457 revisions)
2021-12-14 abdolrashidi@google.com Vulkan: Fix the offset issue in multiDrawIndirect
2021-12-14 johncunningham@apple.com Metal: add ANGLE_metal_create_context_ownership_identity.
2021-12-13 j.vigil@samsung.com EGL: Add queries for EGL_KHR_protected_content
2021-12-13 gman@chromium.org Metal:Add debug info for shaders
2021-12-13 jmadill@chromium.org Frame Capture: Merge small frames into single sources.
2021-12-13 syoussefi@chromium.org Vulkan: Remove VK_EXT_swapchain_colorspace check
2021-12-13 jmadill@chromium.org Reduced "rx::vk::kInFlightCommandsLimit" from "100" to "50".

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

To file a bug in ANGLE: https://bugs.chromium.org/p/angleproject/issues/entry
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: enga@google.com
Change-Id: Ic681691b2f15bca8370426132da2aae95486832e
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/72780
Bot-Commit: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2021-12-14 12:19:45 +00:00
Corentin Wallez 5bd9445127 Remove CubeReflection and the dependency on GLM
Bug: None
Change-Id: Ie0948a8c14751777754360d276ce212507b74642
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/72581
Auto-Submit: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
Reviewed-by: James Price <jrprice@google.com>
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
2021-12-14 08:42:36 +00:00
Li Hao 4682ae0034 Get counterSets and counters using Objective-C style
Bug=dawn:1102

Change-Id: I656938f180ac3436a40ba8720e54618c8921504b
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/72760
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
2021-12-14 08:41:26 +00:00
Yan 483bead0e2 CopyTextureForBrowser: Support display p3 to Srgb color space conversion
This CL add color space conversion bases for CopyTextureForBrowser.
Theoretically, it could support any color space conversion. But
test cases only cover (Srgb, DisplayP3) to (Srgb).
It could be expanded to more color spaces conversions.

Bug: dawn:1140
Change-Id: I332e6d1f7cf2424fd5f5af83c71fa45c98d2d8ac
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/70780
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Kai Ninomiya <kainino@chromium.org>
Commit-Queue: Shaobo Yan <shaobo.yan@intel.com>
2021-12-14 04:51:45 +00:00
Dawn Autoroller fa2d418ee6 Roll Tint from 654149fd69 to 9b9132c715 (2 revisions)
https://dawn.googlesource.com/tint.git/+log/654149fd6938..9b9132c71522

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 enga@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: enga@google.com
Change-Id: If299b9c8bbfb507c24ff43054dc045494dcbd1fc
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/72740
Bot-Commit: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2021-12-14 04:07:31 +00:00
fujunwei d3cac111b6 Template hardcode functions in webgpu_cpp.cpp
Rename webgpu_cpp.cpp to api_cpp.cpp and make it flexible.

BUG=dawn:1201
Change-Id: Ib964be9399e9733c4fe9de5d1cd0361182bb0836
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/72460
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Junwei Fu <junwei.fu@intel.com>
2021-12-14 02:20:15 +00:00
Shrek Shao d7304d1971 Further api.h license issue fixes
Beef up the comment in the file to describe what's going on with
the licenses, as well as describe why the generated file is
a different license.

Also move the BSD text to a different file.

Change-Id: I6d08256317f3a0a150e0c35d3d902fceb7dcb44e
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/72680
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Shrek Shao <shrekshao@google.com>
2021-12-14 01:06:15 +00:00
Dawn Autoroller b7e2f36542 Roll ANGLE from 8991bf5460b6 to ea03bf47e50f (7 revisions)
8991bf5460..ea03bf47e5

2021-12-13 lfy@google.com Vulkan: fix crash when clearing stencil
2021-12-13 ynovikov@chromium.org Skip GLSLTest_ES31.StructAndArrayEqualOperator on Pixel 4
2021-12-13 jmadill@chromium.org Frame Capture: Don't unmap regenned buffers in reset.
2021-12-13 jmadill@chromium.org Frame Capture: Clear array buffer binding in MEC.
2021-12-13 bsheedy@chromium.org Suppress Mac 12 failure
2021-12-13 angle-autoroll@skia-public.iam.gserviceaccount.com Roll vulkan-deps from 267fa481ccad to a0a6270b47e4 (7 revisions)
2021-12-13 angle-autoroll@skia-public.iam.gserviceaccount.com Roll SwiftShader from 4c62980da8c1 to 592d413edb56 (4 revisions)

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

To file a bug in ANGLE: https://bugs.chromium.org/p/angleproject/issues/entry
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: enga@google.com
Change-Id: Id697bb17d2e169929e8d491d26353dfccfbdb95a
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/72700
Bot-Commit: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2021-12-13 23:37:55 +00:00
Antonio Maiorano 9b9132c715 Fix OOB access while dumping struct layout for invalid storage class layout
A one letter typo would lead to invalid memory access in the very
specific case of outputting the layout for a struct within a struct with
field alignment padding, and the inner struct has more members than the
outer.

Bug: tint:1344
Bug: oss-fuzz:72642
Change-Id: I749e3fb172e78a20ece68b40be1a0a57dc5746f4
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/72642
Reviewed-by: Ben Clayton <bclayton@google.com>
Reviewed-by: David Neto <dneto@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
Commit-Queue: Antonio Maiorano <amaiorano@google.com>
2021-12-13 23:36:38 +00:00
Dawn Autoroller c89fdf1774 Roll Tint from d733fdb85c to 654149fd69 (3 revisions)
https://dawn.googlesource.com/tint.git/+log/d733fdb85cbf..654149fd6938

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 enga@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: enga@google.com
Change-Id: I68c698d1e6e5e2b4a6a36893a69b286105eb76ab
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/72660
Bot-Commit: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2021-12-13 22:22:34 +00:00
David Neto f885941100 Add cstddef for definition of size_t
Change-Id: Ic92072a680951145f4925a2ac640f74a8f8b4335
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/72640
Auto-Submit: David Neto <dneto@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: Antonio Maiorano <amaiorano@google.com>
Commit-Queue: Antonio Maiorano <amaiorano@google.com>
2021-12-13 21:14:48 +00:00
Antonio Maiorano 654149fd69 Kokoro: run e2e tests with FXC validation
* Fixed DXC installation so that we download the latest release, and
patch it with the latest artifact build. This ensures that the correct
dxil.dll is next to dxc.exe, rather than having dxc.exe pick up whatever
dxil.dll is in PATH.

* To run tests with FXC requires the correct d3dcompiler_47.dll. To do
this, I modified the script to download the Windows SDK, and install
only the feature that contains the DLL.

* To avoid issues with DXC and FXC finding exes/dlls in PATH, modified
the script to temporarily set PATH as needed.

Bug: tint:940
Change-Id: Ic83b0b97f72ccc1f37b4b495eae6a6ab3421a95a
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/72560
Reviewed-by: James Price <jrprice@google.com>
Commit-Queue: Antonio Maiorano <amaiorano@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
2021-12-13 19:19:58 +00:00
Antonio Maiorano f748f2ae22 Kokoro: use ninja to build faster for Windows builds
Saves about 5 minutes per Windows build.

Bug: tint:940
Change-Id: Ib03fb6ca9d51575d8ee82324be7040153e5536bf
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/72540
Reviewed-by: James Price <jrprice@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
Commit-Queue: Antonio Maiorano <amaiorano@google.com>
2021-12-13 19:15:28 +00:00
David Neto 6d67dad7fe spirv-reader: Ignore duplicate decorations
Vulkan allows them, but WGSL does not.

A duplicate decoration is purely redundant.
A parameterized decoratio with different parameterization is
an inconsistency and a semantic error, at least for currently defined
SPIR-V decorations.

So for each target, only take the first decoration of each kind.

Fixed: tint:1337
Change-Id: I6ed5c39cf2e213c695cb8217ed1b97814da3db56
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/72500
Reviewed-by: Ben Clayton <bclayton@google.com>
Auto-Submit: David Neto <dneto@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: James Price <jrprice@google.com>
Commit-Queue: James Price <jrprice@google.com>
2021-12-13 17:54:21 +00:00
Corentin Wallez e00c6bd395 dawn.json revert to the "callback" name for callback arguments
These argument names were probably renamed as part of a mass rename of
the "callback" category to "function pointer". The name "callback" more
clearly represents what the argument is used for, so revert back to it.

Bug: None
Change-Id: Id7539667f5daa87aec32ce8c90c20275d2fe80fd
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/72485
Auto-Submit: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Austin Eng <enga@chromium.org>
2021-12-13 17:37:17 +00:00
Dawn Autoroller c7b9b578b0 Roll Tint from 5923803f7e to d733fdb85c (1 revision)
https://dawn.googlesource.com/tint.git/+log/5923803f7e84..d733fdb85cbf

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 bclayton@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: bclayton@google.com
Change-Id: Ib4b0bb1aca93898a3fb6f590e2c46d211e4a0219
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/72620
Bot-Commit: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2021-12-13 16:58:04 +00:00
Antonio Maiorano d733fdb85c HLSL: work around FXC failures when dynamically indexing arrays in structs
FXC fails to compile code that assigns to dynamically-indexed fixed-size
arrays in structs on internal shader variables with:

error X3500: array reference cannot be used as an l-value; not natively
addressable

This CL detects this case, and transforms such assignments into copying
out the array to a local variable, assigning to that local, and then
copying the array back.

Also manually regenerate SKIPs for HLSL/FXC after this change, which
fixes 30 tests. Also exposes some "compilation aborted unexpectedly" now
that  "array reference cannot be used as an l-value" has been fixed. For
tests that fail for both DXC and FXC, updating SKIPs to the DXC one to
help distinguish actual FXC bugs from valid errors.

Bug: tint:998
Bug: tint:1206
Change-Id: I09204d8d81ab27d1c257538ad702414ccc386543
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/71620
Reviewed-by: Ben Clayton <bclayton@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
Commit-Queue: Antonio Maiorano <amaiorano@google.com>
2021-12-13 15:55:11 +00:00
Corentin Wallez 88d5e07d73 Roll GN
Also fix a gn check failure with the new GN.

Bug: None
Change-Id: I0686dd5de7fc5804fbbe79f19db413cc67fa0aae
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/72484
Auto-Submit: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Loko Kung <lokokung@google.com>
Commit-Queue: Loko Kung <lokokung@google.com>
2021-12-13 15:24:55 +00:00
Dawn Autoroller b320f17000 Roll ANGLE from a1b9eb68e417 to 8991bf5460b6 (1 revision)
a1b9eb68e4..8991bf5460

2021-12-13 angle-autoroll@skia-public.iam.gserviceaccount.com Roll Chromium from 6214b401e0c5 to 30aeba8927a2 (473 revisions)

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

To file a bug in ANGLE: https://bugs.chromium.org/p/angleproject/issues/entry
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: cwallez@google.com
Change-Id: I03da2fa874ca18d7d6c4cced9d0027c4676272a4
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/72600
Bot-Commit: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2021-12-13 09:49:14 +00:00
jchen10 ffb0024a89 Support NV12 via ExternalImageDescriptorDmaBuf on CROS
On Intel platforms, all planes in fact have same dma-buf, so the
DISJOINT bit shouldn't be used to create the vkimage.
For multi-planar formats, VkImageDrmFormatModifierListCreateInfoEXT
has to be used instead of
VkImageDrmFormatModifierExplicitCreateInfoEXT.

Bug: chromium:1258986
Change-Id: I25306a438e7ba9fd981848e63068e486bbddf11d
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/68961
Reviewed-by: Austin Eng <enga@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Jie A Chen <jie.a.chen@intel.com>
2021-12-13 02:38:44 +00:00
Dawn Autoroller 16e3221a0e Roll ANGLE from 56aee5d6407f to a1b9eb68e417 (8 revisions)
56aee5d640..a1b9eb68e4

2021-12-11 gman@chromium.org Replace IOSurfaceSurfaceEAGL.mm table with less strict padding
2021-12-11 kpiddington@apple.com Metal: Fix M1 and iOS synchronization for readPixels
2021-12-11 gman@chromium.org Metal: Add maximum render target size validation
2021-12-11 gman@chromium.org Add early out validation in drawArraysCommon
2021-12-11 gman@chromium.org Metal: Refactor restartRange cache
2021-12-11 gman@chromium.org Metal: Fix Instanced Draw feature support on Simulator
2021-12-11 gman@chromium.org Metal: Refactors from Webkit
2021-12-10 gman@chromium.org Metal: Merge changes to mtlPixelFormatTable

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

To file a bug in ANGLE: https://bugs.chromium.org/p/angleproject/issues/entry
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: cwallez@google.com
Change-Id: I958ea11fb6752f84e96d4088cf045badecdfb210
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/72561
Bot-Commit: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2021-12-11 12:51:03 +00:00
Dawn Autoroller 8da36a7349 Roll ANGLE from ac9b2703e8fa to 56aee5d6407f (9 revisions)
ac9b2703e8..56aee5d640

2021-12-10 lubosz.sarnecki@collabora.com Reland "system_utils: Add memory protection functionality."
2021-12-10 jmadill@chromium.org Trace Tests: Ensure zillow runs on SwiftShader.
2021-12-10 abdolrashidi@google.com Update the arg types for glMultiDraw*IndirectEXT()
2021-12-10 sugoi@google.com Add debug info when loading EGL entry points fails
2021-12-10 penghuang@chromium.org Enable GL_ANGLE_texture_usage extension
2021-12-10 penghuang@chromium.org Use STL container for vulkan memory allocator
2021-12-10 angle-autoroll@skia-public.iam.gserviceaccount.com Roll vulkan-deps from 38603b300bce to 267fa481ccad (8 revisions)
2021-12-10 angle-autoroll@skia-public.iam.gserviceaccount.com Roll SwiftShader from 4625f84e8d56 to 4c62980da8c1 (6 revisions)
2021-12-10 angle-autoroll@skia-public.iam.gserviceaccount.com Roll Chromium from e1fa86b1827a to 6214b401e0c5 (1064 revisions)

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

To file a bug in ANGLE: https://bugs.chromium.org/p/angleproject/issues/entry
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: cwallez@google.com
Change-Id: I6d54fc54895f1800188b9a4d206b898c6d3b6e80
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/72520
Bot-Commit: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2021-12-10 23:13:02 +00:00
Dawn Autoroller 973b1a14b1 Roll Tint from 30d55fabc9 to 5923803f7e (1 revision)
https://dawn.googlesource.com/tint.git/+log/30d55fabc91f..5923803f7e84

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 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: cwallez@google.com
Change-Id: I14058fd1db16ed4f757bcc65196e0efda383d612
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/72521
Bot-Commit: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2021-12-10 22:49:32 +00:00
David Neto 5923803f7e Document that ast::Variable::type can be null
Change-Id: I7a29c1de49cbd082a5c3e0fc4bdcdead9dd2c956
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/70340
Auto-Submit: David Neto <dneto@google.com>
Reviewed-by: Ben Clayton <bclayton@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
Commit-Queue: David Neto <dneto@google.com>
2021-12-10 21:51:05 +00:00
Corentin Wallez 3b7e75865c Vulkan: make PNextChainBuilder require pNext==nullptr
This will hopefully help catch issues early when people forget to set
pNext before creating the PNextChainBuilder.

Bug: dawn:1223
Change-Id: Ic6b9704aeaa20731e4f7de4d1ac0207d4110c720
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/71762
Reviewed-by: Loko Kung <lokokung@google.com>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
2021-12-10 15:48:19 +00:00
Dawn Autoroller cebe8c340a Roll Tint from 0fe30b52a5 to 30d55fabc9 (18 revisions)
https://dawn.googlesource.com/tint.git/+log/0fe30b52a5c9..30d55fabc91f

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 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: cwallez@google.com
Change-Id: Icf192442b1c50b71e179f2b53538062a23d6cebb
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/72301
Bot-Commit: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
2021-12-10 15:25:13 +00:00
Dawn Autoroller 5819d52bc4 Roll ANGLE from 663831aa676c to ac9b2703e8fa (2 revisions)
663831aa67..ac9b2703e8

2021-12-10 polynomialspace@gmail.com fix typo: 'choromium' -> 'Chromium'
2021-12-10 hailinzhang@google.com fix directUpdate buffer pointer issue.

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

To file a bug in ANGLE: https://bugs.chromium.org/p/angleproject/issues/entry
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: cwallez@google.com
Change-Id: If72c33a063dc1626b96c598ea21d648f78dc8d26
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/72302
Bot-Commit: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2021-12-10 09:24:01 +00:00
Jiawei Shao 1f25ea94bb dawn_wire: Directly use the data in deserialized buffer when possible
This patch tries to use the data directly in deserialized buffer
when the data is "data-only" and doesn't affect the control flow instead
of allocating and copying into a temporary buffer. Due to the protection
of TOCTOU attacks, currently we only set "wire_is_data_only" on the
parameter "data" in Queue.WriteBuffer() and Queue.WriteTexture().

With this patch, the performance of dawn_perf_tests
BufferUploadPerf.Run/*_WriteBuffer_BufferSize_* with "-w" will
be greatly improved (~20%) when the upload buffer size is greater than
1MB.

BUG=chromium:1266727

Change-Id: I7a9d54c9b505975235ee37aa72ee97f082ad3aa3
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/72063
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Jiawei Shao <jiawei.shao@intel.com>
2021-12-10 02:05:28 +00:00
Austin Eng 6ad6278bc5 Enable dynamic storage buffers
Validation is implemented with CTS tests added in
https://github.com/gpuweb/cts/pull/850

Fixed: dawn:429
Change-Id: Iee570c712f81fbafc158c0ceec89a28011a3fed8
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/71960
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Kai Ninomiya <kainino@chromium.org>
Commit-Queue: Austin Eng <enga@chromium.org>
2021-12-10 01:50:08 +00:00
fujunwei a840574db0 Replace hardcode functions in templates
Make dawn_proc.c and dawn_thread_dispatch_proc.cpp flexible

BUG=dawn:1201

Change-Id: Ifca73b33d6aed70b2dda3cf181a4650380f0a2fb
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/72065
Reviewed-by: Jiawei Shao <jiawei.shao@intel.com>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Junwei Fu <junwei.fu@intel.com>
2021-12-10 01:35:19 +00:00
Ben Clayton 30d55fabc9 docs: Move OT changes to M99
These missed the M98 boat.

Change-Id: Ic15e8323457d78eea1ea3c59c104b2901c883b1b
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/72321
Auto-Submit: Ben Clayton <bclayton@google.com>
Kokoro: Ben Clayton <bclayton@google.com>
Reviewed-by: James Price <jrprice@google.com>
Commit-Queue: James Price <jrprice@google.com>
2021-12-09 22:53:14 +00:00
David Neto 9c179a601c wgsl-reader: hex prefix only is an error
These are errors:

    let a = 0x;
    let b = -0x;

Fixes: tint:1338
Change-Id: I9d26ad66e32deb954550c0ecfbda0a9005bcd380
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/72380
Reviewed-by: Ben Clayton <bclayton@google.com>
Commit-Queue: David Neto <dneto@google.com>
Auto-Submit: David Neto <dneto@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
2021-12-09 22:35:44 +00:00
Yunchao He 0e922b5995 Add validations for depth/stencil aspect requirement for DepthStencilState
In RenderPipelineDescriptor.DepthStencilState, if depth test or depth
write is enabled, the texture format must have depth aspect. Likewise,
if stencil test or stencil write is enabled, the texture format must
have stencil aspect.

Bug: dawn:1226

Change-Id: I9d7efb25675ff2c90704fa45703fb542bab6f1f5
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/72101
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Yunchao He <yunchao.he@intel.com>
2021-12-09 22:02:14 +00:00
Yunchao He 15fec68a4f Implement readonly depth/stencil attachment on Vulkan
It requires to revise quite a few flags in order to implement
readonly depth/stencil attachment on Vulkan. For example:
  - VkAccessFlags,
  - VkPipelineStageFlags,
  - VkImageUsageFlags,
  - and the most important: VkImageLayout.

These revised flags need to be applied to many Vulkan objects.
For examples:
  - VkImageMemoryBarriers,
  - IMAGE_LAYOUT revisions in descriptor set (bindings),
    render pass, and subpass,
  - and loadOp/storeOp revisions in render pass and subpass.

This change also does some workarounds in order to make Vulkan
validation layers happy. For example:
  - use DEPTH_STENCIL_READ_ONLY image layout for binding a
    depth/stencil texture,
  - add DEPTH_STENCIL_ATTACHMENT_BIT image usage for binding a
    depth/stencil texture.

Note that STORE_OP_STORE is used for depth/stencil's storeOp for
readonly attachment. It leads to Vulkan validation error. This
change igores that error and let it proceeds and it works well.

Bug: dawn:485
Change-Id: Ie247c9cbffbd837984b0933a905632ab5ad8862d
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/70280
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Yunchao He <yunchao.he@intel.com>
2021-12-09 21:32:28 +00:00
Dawn Autoroller 1b1b658d36 Roll ANGLE from 0e291f60ccbf to 663831aa676c (5 revisions)
0e291f60cc..663831aa67

2021-12-09 jmadill@chromium.org Revert "Reland "system_utils: Add memory protection functionality.""
2021-12-09 gman@chromium.org Metal: Fix Intel backend fails with tall texture
2021-12-09 cclao@google.com Vulkan: Append the actual buffer size when binding's size is 0
2021-12-09 angle-autoroll@skia-public.iam.gserviceaccount.com Roll SwiftShader from a4232c15e287 to 4625f84e8d56 (5 revisions)
2021-12-09 angle-autoroll@skia-public.iam.gserviceaccount.com Roll vulkan-deps from bc087f672f16 to 38603b300bce (6 revisions)

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

To file a bug in ANGLE: https://bugs.chromium.org/p/angleproject/issues/entry
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: cwallez@google.com
Change-Id: I6f91a57509b35dca72f080497a721da4bd5d080d
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/72440
Bot-Commit: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2021-12-09 20:35:58 +00:00
Austin Eng 63f65465f5 Add a build target for a webgpu_dawn library
This library binds directly to dawn_native and implements
webgpu.h. It may be built as a single library so it can
be easily used in other projects.

Bug: dawn:1220
Change-Id: I73be8c6455922fa526efd1600446cc46b07e82ed
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/53887
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Austin Eng <enga@chromium.org>
2021-12-09 20:03:48 +00:00
James Price 1461b032aa glsl: Don't emit structs with runtime-sized arrays
The GLSL emitted for these was invalid, and we don't need these
structs since they're only used as the store types of buffers, which
are handled elsewhere.

Change-Id: I17c15e408b5c36e9b895e5950528a6d02d1802a6
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/72381
Reviewed-by: Stephen White <senorblanco@chromium.org>
Kokoro: Kokoro <noreply+kokoro@google.com>
2021-12-09 18:54:35 +00:00
James Price 57489928c6 test: Remove [[block]] for recently added tests
This attribute is now deprecated, and the warning is causing these
tests to fail.

Bug: tint:1324
Change-Id: I0665c9f3b657c8cb56e2252a23eb6184ea876075
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/72420
Reviewed-by: Antonio Maiorano <amaiorano@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
2021-12-09 18:54:35 +00:00
Ben Clayton 4e6e113816 reader/spirv: Allow leading underscore in identifiers
Bug: tint:1292
Change-Id: I738c981f503545075115101a3ead30941a19d95a
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/72320
Reviewed-by: David Neto <dneto@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
Commit-Queue: Ben Clayton <bclayton@google.com>
2021-12-09 16:55:04 +00:00
David Neto 01e4b54497 null character on input is an error
Fixes: tint:1311
Change-Id: Id80adc2c14c6d2cd5ee884e081d1d84f021e6620
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/72200
Auto-Submit: David Neto <dneto@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: Ben Clayton <bclayton@google.com>
Commit-Queue: David Neto <dneto@google.com>
2021-12-09 15:57:30 +00:00
James Price 170a50353c reader/wgsl: Deprecate the [[block]] attribute
Bug: tint:1324
Change-Id: Ic8e9cd4a2e924498397659b5d23d6ac6d602588d
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/72088
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: Ben Clayton <bclayton@google.com>
2021-12-09 15:45:03 +00:00
James Price a5d3986a0a tests: Stop using the [[block]] attribute
This has been deprecated and will soon be removed.

Bug: tint:1324
Change-Id: If5dbbc3a40d7591591fb2802dbe9c8dd5f96d299
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/72087
Reviewed-by: Ben Clayton <bclayton@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
2021-12-09 15:45:03 +00:00