Commit Graph

2434 Commits

Author SHA1 Message Date
Jiawei Shao 900bd341a3 Enable TextureSubresourceTest.MipmapLevelsTest on Vulkan w/ validation
This patch re-enables TextureSubresourceTest.MipmapLevelsTest on Vulkan
with validation layer because the bug in Vulkan validation layer has
been fixed.

BUG=dawn:517
TEST=dawn_end2end_tests

Change-Id: I654603369717a32c5c9168621fb81e8a822d50d0
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/27560
Commit-Queue: Austin Eng <enga@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
2020-08-27 13:12:29 +00:00
Xinghua Cao 8c012e8796 D3D12: fix shader model comparison
D3D12_SHADER_MODEL is encoded as 0xMm with M the major version and
m the minor version. After decoding D3D12_SHADER_MODEL to a custom
shader model format as Mm, which is a decimal value, it's meaningless
to compare these two values.

Bug: dawn:426
Change-Id: I3eb9a2a1392307616a5ac4d0aa49790bcc363629
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/27300
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Jiawei Shao <jiawei.shao@intel.com>
Commit-Queue: Xinghua Cao <xinghua.cao@intel.com>
2020-08-27 02:56:05 +00:00
Brandon Jones 8575cb3ec7 Add setIndexBufferWithFormat method
First step of a multi-part change to bring the setIndexBuffer
method up-to-date with the current WebGPU spec. This change
preserves the previous setIndexBuffer semantics for backwards
compatibility until developers have been notified and given
a grace period to transition to the new signature.

BUG=dawn:502
Change-Id: Ia8c665639494d244f52296ceadaedb320fa6c985
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/27182
Commit-Queue: Brandon Jones <bajones@chromium.org>
Reviewed-by: Kai Ninomiya <kainino@chromium.org>
2020-08-27 01:13:35 +00:00
Austin Eng 320c6c87b2 Revert "Skip TextureSubresourceTest.MipmapLevelsTest on Vulkan w/ validation"
This reverts commit e8dc820fbc.

Reason for revert: The Vulkan validation layers bug has been fixed

Original change's description:
> Skip TextureSubresourceTest.MipmapLevelsTest on Vulkan w/ validation
> 
> This test is broken after a validation layers update.
> 
> Tbr=cwallez@chromium.org
> Bug: dawn:517
> Change-Id: Ia685ba7bd17d8cdb49477997aaee4e5a9f00f9c7
> 
> Change-Id: I6f05516f00c8d05b96c8af578e09df9dc416385b
> Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/27123
> Reviewed-by: Austin Eng <enga@chromium.org>
> Commit-Queue: Austin Eng <enga@chromium.org>

TBR=cwallez@chromium.org,enga@chromium.org

# Not skipping CQ checks because original CL landed > 1 day ago.

Bug: dawn:517
Change-Id: I844960bfda35be59659ee88ff8b5028fbd0ca612
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/27400
Reviewed-by: Austin Eng <enga@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Austin Eng <enga@chromium.org>
2020-08-26 15:26:32 +00:00
Corentin Wallez 4f8bdaf473 Make ShaderModuleBase use an internal EntryPointMetadata
WGSL and SPIR-V modules can contain multiple entrypoints, for different
shader stages, that the pipelines can choose from. This is the first CL
in a stack that will change Dawn internals to not rely on ShaderModules
having a single entrypoint.

EntryPointMetadata is introduced that will contain all reflection data
for an entrypoint of a shader module. To ease review this CL doesn't
introduce any functional changes and doesn't expose the
EntryPointMetadata at the ShaderModuleBase interface. Instead
ShaderModuleBase contains a single metadata object for its single entry
point, and layout-related queries and proxied to the EntryPointMetadata
object.

Finally some small renames and formatting changes are done.

Bug: dawn:216
Change-Id: I0f4d12a5075ba14c5e8fd666be4073d34288f6f9
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/27240
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
2020-08-26 09:57:52 +00:00
Ryan Harrison c3e3c30b0d Roll 4 dependencies
Roll third_party/glslang/ f257e0ea6..983698bb3 (2 commits)

f257e0ea6b..983698bb34

$ git log f257e0ea6..983698bb3 --date=short --no-merges --format='%ad %ae %s'
2020-08-23 john Revert "Merge pull request #2371 from RafaelMarinheiro/master"
2020-08-21 julius.ikkala Obey ENABLE_PCH CMake option

Created with:
  roll-dep third_party/glslang

Roll third_party/spirv-cross/ 4c7944bb4..685f86471 (6 commits)

4c7944bb42..685f86471e

$ git log 4c7944bb4..685f86471 --date=short --no-merges --format='%ad %ae %s'
2020-08-24 post Run format_all.sh.
2020-08-24 post Work around annoying warning on GCC 10.2.
2020-08-21 post Overhaul how we deal with reserved identifiers.
2020-08-20 post HLSL: Fix FragCoord.w.
2020-08-20 post HLSL: Deal with partially filled 16-byte word in cbuffers.
2020-08-20 post HLSL: Fix bug in is_packing_standard for cbuffer.

Created with:
  roll-dep third_party/spirv-cross

Roll third_party/SPIRV-Tools/ 1023dd7a0..4dd122392 (7 commits)

1023dd7a04..4dd122392f

$ git log 1023dd7a0..4dd122392 --date=short --no-merges --format='%ad %ae %s'
2020-08-21 andreperezmaselco.developer spirv-fuzz: Add words instead of logical operands (#3728)
2020-08-20 dnovillo CCP should mark IR changed if it created new constants. (#3732)
2020-08-19 antonikarp spirv-fuzz: add FuzzerPassAddCompositeInserts (#3606)
2020-08-19 antonikarp spirv-fuzz: Support pointer types in FuzzerPassAddParameters (#3627)
2020-08-18 jaebaek Let ADCE pass check DebugScope (#3703)
2020-08-18 andreperezmaselco.developer spirv-opt: Implement opt::Function::HasEarlyReturn function (#3711)
2020-08-17 andreperezmaselco.developer spirv-fuzz: Check termination instructions when donating modules (#3710)

Created with:
  roll-dep third_party/SPIRV-Tools

Roll third_party/tint/ b08e25388..c3038ddfa (23 commits)

https://dawn.googlesource.com/tint/+log/b08e25388629..c3038ddfa6eb

$ git log b08e25388..c3038ddfa --date=short --no-merges --format='%ad %ae %s'
2020-08-24 sarahmashay [validation] Adds disable test for v-0023, entry point functions accept no params
2020-08-24 tommek [wgsl-reader] Adding body_statement to statement grammar
2020-08-24 cwallez Fix triangle.wgsl's floating point literals.
2020-08-21 dneto Re-enable float emission tests
2020-08-21 sarahmashay [validation] validate if entry point functions return void
2020-08-20 sarahmashay [validation] Add disabled test for v-0024-entry point functions return void
2020-08-20 sarahmashay [validation] checks if function used in entry point exists
2020-08-20 sarahmashay [validation] Add disabled test for v-0019-entry point functions must exist
2020-08-20 sarahmashay [validation] Checks if recursions exist
2020-08-19 dsinclair [hlsl-writer] Add support for import statements.
2020-08-19 dsinclair [hlsl-writer] Generate intrinsics.
2020-08-19 dsinclair [hlsl-writer] Emit cast expressions.
2020-08-19 dsinclair [hlsl-writer] Add tests for entry point data.
2020-08-19 dsinclair [hlsl-writer] Emit module constants.
2020-08-19 dsinclair [hlsl-writer] Fix emission of struct aliases.
2020-08-19 dsinclair [hlsl-writer] Emit uniform variables.
2020-08-19 dsinclair [hlsl-writer] Add CallExpression.
2020-08-19 dsinclair [hlsl-writer] Add support for input locations and builtins.
2020-08-19 dsinclair [hlsl-writer] Add function handling.
2020-08-18 dsinclair Add missing block decoration.
2020-08-18 sarahmashay [type-determiner] return false when type determining an undeclared function
2020-08-17 sarahmashay [validation] Add Disabled test for detecting recursion
2020-08-17 dsinclair [spirv-writer] Output name for constant global variables.

Created with:
  roll-dep third_party/tint

Change-Id: Idccbaa1b9b2acd7e1180670250b2cfa37be97b64
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/27281
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Ryan Harrison <rharrison@chromium.org>
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
2020-08-24 15:58:56 +00:00
Jiawei Shao ef74473347 Fix issues in end2end tests for enabling buffer lazy clear by default
This patch cleans up some issues in the end2end tests that will cause
test failures when we enable buffer lazy initialization by default.

This patch also skips a test that always fails with Vulkan validation
layer.

BUG=dawn:414
TEST=dawn_end2end_tests

Change-Id: I40f643615b3fec4e52c90d576285534a99950915
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/26960
Reviewed-by: Austin Eng <enga@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Jiawei Shao <jiawei.shao@intel.com>
2020-08-23 06:08:05 +00:00
Corentin Wallez ce78ce2e28 Tiny cleanup of GetMappedRange.
Fix the last TODOs for the deletion of the "old mapping".

Bug: dawn:445
Change-Id: Ie7443446e4696cf38801980db3d3cfdb09094578
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/27060
Reviewed-by: Austin Eng <enga@chromium.org>
Reviewed-by: Stephen White <senorblanco@chromium.org>
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
2020-08-22 11:08:34 +00:00
Austin Eng e8dc820fbc Skip TextureSubresourceTest.MipmapLevelsTest on Vulkan w/ validation
This test is broken after a validation layers update.

Tbr=cwallez@chromium.org
Bug: dawn:517
Change-Id: Ia685ba7bd17d8cdb49477997aaee4e5a9f00f9c7

Change-Id: I6f05516f00c8d05b96c8af578e09df9dc416385b
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/27123
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Austin Eng <enga@chromium.org>
2020-08-21 00:23:59 +00:00
Bryan Bernhart ef0fee48c4 D3D12: check if resource manager exists before releasing
ClusterFuzz injects errors into the device which may not
initialize the resource manager which would later fail upon
shutdown. This adds a check to see if the resource manager
exists before releasing the pool.

BUG=chromium:1117595

Change-Id: Ie2b90f947f3ddd3906ecabc65e959915c1f7e386
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/27040
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
Reviewed-by: Rafael Cintron <rafael.cintron@microsoft.com>
Commit-Queue: Bryan Bernhart <bryan.bernhart@intel.com>
2020-08-20 17:06:39 +00:00
Jiawei Shao ab4e4feb01 Workaround Intel Mesa driver issue about T2B copy with stencil aspects
In the test DepthStencilCopyTests/FromStencilAspect we are writing into
gl_FragDepth but we disable the depth writing when creating the render
pipeline, which causes Intel Mesa driver hangs when the test is running
on it. In this patch we try to add workaround to this issue by enabling
the depth writing.

BUG=dawn:439
TEST=dawn_end2end_tests

Change-Id: I618246097a26ee62c830f0ac8dc1aa0ab4d224a9
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/27000
Commit-Queue: Austin Eng <enga@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
2020-08-20 16:17:59 +00:00
Corentin Wallez f7123d7463 Remove MapRead/WriteAsync and CreateBufferMapped
Bug: dawn:445

Change-Id: I0b0755b6bb754d1fff99aa59b08362f89950e300
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/26301
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
2020-08-20 14:22:29 +00:00
Tomek Ponitka d720785616 Refactoring Queue::WriteTexture implementation
More code is now shared across backends.

Bug: dawn:483
Change-Id: I7ca1b8cbc2f12e408c94fbe5bca9fd29e47e0004
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/27021
Commit-Queue: Tomek Ponitka <tommek@google.com>
Reviewed-by: Austin Eng <enga@chromium.org>
2020-08-20 13:29:39 +00:00
Tomek Ponitka 7f265d1d40 Fixing offset alignments when using DynamicUploader
When using a dynamic uploader we didn't align the offset
that the allocated memory might have already had.
That fixes WriteTexture, WriteBuffer, ClearTexture and
on D3D12 ClearBuffer.

Bug: dawn:512
Change-Id: I64c7511ad6b0d3d6a28a494e1324a10ad4d38091
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/27020
Commit-Queue: Tomek Ponitka <tommek@google.com>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
Reviewed-by: Jiawei Shao <jiawei.shao@intel.com>
2020-08-20 11:25:49 +00:00
Hao Li eff9ef0f22 Query API: QuerySet on Vulkan
- Implement QuerySet on Vulkan backend.
- Enable end2end tests on Vulkan. The timestamp tests will be enabled
  in following CL which implement timestamp query.

Bug: dawn:434
Change-Id: I7ee04380c5f6b5af561cc23e28637dcae70bc7b9
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/26360
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Hao Li <hao.x.li@intel.com>
2020-08-20 00:40:07 +00:00
Corentin Wallez 2f6e4ec6c0 Add wgpu::TextureFormat::RGB9E5Ufloat
Also update RG11B10Float to be name RG11B10Ufloat

Bug: dawn:22

Change-Id: I0ea76dc25c37ebaeb4c2c2c2a119d00940acc145
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/25760
Reviewed-by: Austin Eng <enga@chromium.org>
Reviewed-by: Stephen White <senorblanco@chromium.org>
Commit-Queue: Kai Ninomiya <kainino@chromium.org>
2020-08-19 21:51:20 +00:00
Austin Eng b54c82ed39 Support depth-only/stencil-only COPY_SRC on OpenGL
Bug: dawn:439
Change-Id: I09d33d3115d54c03e3ba5a32f34843065edb8020
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/24961
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Stephen White <senorblanco@chromium.org>
Commit-Queue: Austin Eng <enga@chromium.org>
2020-08-18 18:53:26 +00:00
Corentin Wallez caec4ab04a Metal: Remove usage of MTLTextureUsagePixelFormatView
This usage is only needed when reinterpreting formats, which Dawn
doesn't support yet, and has a significant cost in that textures can't
be compressed as well.

Bug: dawn:510
Change-Id: I6e416a97c84a708f97d83f9b15c60b05bbf15908
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/26881
Reviewed-by: Austin Eng <enga@chromium.org>
Reviewed-by: Stephen White <senorblanco@chromium.org>
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
2020-08-18 15:39:06 +00:00
Dirk Pranke 9aed03dcb0 Fix visibility rules for configs enforced by latest GN.
Prior versions of GN had a bug (gn:22) where visibility rules
for configs weren't enforced properly.

This CL tweaks the visibility settings of some configs to conform
to the latest version.

Change-Id: If0e9f06667d3d89bcd0bbfc938e159e590e11e27
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/26929
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
2020-08-18 13:26:26 +00:00
Corentin Wallez 7268e7d36f OpenGL: Unconditionally set glFrontFace
Previously glFrontFace was called only if some cull mode was set. This
was incorrect because the front face also influences whether a triangle
uses stencilFront or stencilBack.

Because OpenGL default to GL_CCW (which with the Y-flip is the inverse
of wgpu::FrontFace::CCW that's default in the descriptor), if
stencilFront != stencilBack and cull mode is none, then the incorrect
stencil face descriptor was used.

Also adds a regression test for this issue.

Bug: dawn:508
Change-Id: I00d93bda6d4f030cf9db472a9f2b0deefc72707f
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/26880
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
2020-08-18 12:30:06 +00:00
Ryan Harrison d95180dede Roll 4 dependencies
Roll third_party/glslang/ d253278f9..f257e0ea6 (9 commits)

d253278f98..f257e0ea6b

$ git log d253278f9..f257e0ea6 --date=short --no-merges --format='%ad %ae %s'
2020-08-14 john Build: fix a build warning
2020-08-14 rafael.fariasmarinheiro Use --test-root to pass files to Bazel tests.
2020-08-14 john Fix #2366, fix #2358, correctly separate out numerical feature checking
2020-08-14 john Non-functional (almost): Refactor when 'extensionRequested' is called.
2020-08-14 john Non-functional: Remove reinventing the scalar type, note code issues
2020-08-11 john Non-functional: spellings of "destinaton" and "addPairConversion"
2020-08-10 ezdiy GLSLANG_EXPORT for C APIs.
2020-08-07 john Non-functional: correctly do GL_EXT_buffer_reference2 semantic checking
2020-08-06 john Non-functional: consistently use 'const TSourceLoc&' to pass location.

Created with:
  roll-dep third_party/glslang

Roll third_party/shaderc/ ffd805115..21b36f736 (1 commit)

ffd805115e..21b36f7368

$ git log ffd805115..21b36f736 --date=short --no-merges --format='%ad %ae %s'
2020-08-17 rharrison Roll 4 dependencies (#1131)

Created with:
  roll-dep third_party/shaderc

Roll third_party/SPIRV-Tools/ b4c4da3e7..1023dd7a0 (6 commits)

b4c4da3e76..1023dd7a04

$ git log b4c4da3e7..1023dd7a0 --date=short --no-merges --format='%ad %ae %s'
2020-08-17 jackoalan Fix -Wrange-loop-analysis warning (#3712)
2020-08-17 andreperezmaselco.developer spirv-fuzz: Check header dominance when adding dead block (#3694)
2020-08-16 jaebaek Allow DebugTypeTemplate for Type operand (#3702)
2020-08-14 antonikarp spirv-fuzz: Improve code coverage of tests (#3686)
2020-08-14 stefanomil spirv-fuzz: Fuzzer pass to randomly apply loop preheaders (#3668)
2020-08-14 vasniktel spirv-fuzz: Support identical predecessors in TransformationPropagateInstructionUp (#3689)

Created with:
  roll-dep third_party/SPIRV-Tools

Roll third_party/tint/ 23c3fee35..b08e25388 (2 commits)

https://dawn.googlesource.com/tint/+log/23c3fee35436..b08e25388629

$ git log 23c3fee35..b08e25388 --date=short --no-merges --format='%ad %ae %s'
2020-08-17 sarahmashay [validation] Validates if return statement type matches function return type
2020-08-17 sarahmashay [validation] Validates function name uniqueness

Created with:
  roll-dep third_party/tint

Change-Id: I0c94f6a7f9f90a68ecdabfd6ce07e8e675dbfc13
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/26940
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Ryan Harrison <rharrison@chromium.org>
2020-08-17 19:25:05 +00:00
Austin Eng c0fd9d0945 D3D12: only lazy clear OutputAttachment textures with render target ops
Previously, lazy clearing always added DEPTH_STENCIL or RENDER_TARGET to
textures because we cleared using ClearDepthStencilView or
ClearRenderTargetView. Now, we're able to clear using copies.

This also allows textures to actually use the small resource heap
placement optimization. Doing so generates debug layer warnings when the
small alignment is first tried but rejected. This CL silences those
warnings.

Bug: dawn:145
Change-Id: Id385846536b337cddcfdadc5739561c7adc30c8c
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/26840
Commit-Queue: Austin Eng <enga@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
2020-08-17 18:39:25 +00:00
Bryan Bernhart 988f19e208 Pool sub-allocated resource heaps.
Allow resource heaps to be recycled when
no longer used.

BUG=dawn:496

Change-Id: I36518f8b0c0b26d2cceecc4e7b05e00a5fd5bd25
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/26126
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Bryan Bernhart <bryan.bernhart@intel.com>
2020-08-17 17:47:15 +00:00
Austin Eng 5e9b29fab9 Fix ASSERT in WindowsDebugLogger
SetEvent returns non-zero on success, not zero.

Tbr=cwallez@chromium.org
Bug: none
Change-Id: Ib6ea74b19799bc3211136a5788b2bce8880f3b17
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/26841
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Austin Eng <enga@chromium.org>
2020-08-14 22:44:02 +00:00
Austin Eng f580096468 end2end_tests: Forward Windows debug messages to stderr
When validation layers are enabled, D3D12 warnings and error
messages are logged to the shared DBWIN_BUFFER segment of memory.
This CL has makes the test environment watch for new events and
logs them to stderr so they show up in the test bot logs. This helps
debug problems in the D3D12 backend which previously just crashed
with a general Device Lost message.

Bug: none
Change-Id: I0eaddf9e16303bd65579e85fe6693bd8cdfbd8da
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/26640
Reviewed-by: Rafael Cintron <rafael.cintron@microsoft.com>
Reviewed-by: Bryan Bernhart <bryan.bernhart@intel.com>
Commit-Queue: Austin Eng <enga@chromium.org>
2020-08-14 21:02:12 +00:00
Corentin Wallez 24b5971b84 Remove deprecated wgpu::BufferCopyView members
Bug: dawn:22

Change-Id: Iec26e9945443411a8f322a80d7e63c96c74f3508
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/26702
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Kai Ninomiya <kainino@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
2020-08-14 09:31:00 +00:00
Idan Raiter d315022be5 Add Metal vertex pulling behind a flag
Implements vertex pulling on the Metal backend, hidden behind a flag
until ready for use (we are missing support for more complicated vertex
input types).

Bug: dawn:480
Change-Id: I38028b80673693ebf21309ad5336561fb99f40dc
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/26522
Commit-Queue: Idan Raiter <idanr@google.com>
Reviewed-by: Austin Eng <enga@chromium.org>
2020-08-13 23:53:59 +00:00
Idan Raiter e1604b9a64 Enable robust buffer access pass if robustness on
Turns on SPVC buffer access pass if robustness is also enabled.

Bug: dawn:480
Change-Id: Ib4d74e177f4f65139219f3ce8662566370f4a108
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/26741
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Austin Eng <enga@chromium.org>
2020-08-13 20:53:59 +00:00
Enrico Galli 76d9e34bbc Eagerly destroy CommandBuffer commands after submission
Command buffers hold references to all encoded objects. Freeing them
eagerly significantly reduces the amount memory held before the JS GC
clears the command buffers.

Bug: dawn:262, dawn:372
Change-Id: I68dfa973f980fba8d94611ed1de3c593bdb91a63
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/26562
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Rafael Cintron <rafael.cintron@microsoft.com>
Commit-Queue: Austin Eng <enga@chromium.org>
2020-08-13 20:25:39 +00:00
Austin Eng f7905c3cb5 Roll 5 dependencies
Roll third_party/glslang/ b60e067b4..d253278f9 (2 commits)

b60e067b43..d253278f98

$ git log b60e067b4..d253278f9 --date=short --no-merges --format='%ad %ae %s'
2020-08-12 alanbaker Update test expectations
2020-08-12 alanbaker Update SPIRV-Tools and SPIRV-Headers known good

Created with:
  roll-dep third_party/glslang

Change-Id: I1aea9a8360edcbc16c46fdcf36c2d0d18b544540

Roll third_party/shaderc/ c626b912d..ffd805115 (2 commits)

c626b912dc..ffd805115e

$ git log c626b912d..ffd805115 --date=short --no-merges --format='%ad %ae %s'
2020-08-13 rharrison Add support for Dawn using deprecated Options constructor (#1130)
2020-08-10 rharrison Roll 5 dependencies and update expectations (#1129)

Created with:
  roll-dep third_party/shaderc

Change-Id: I2c4482711a1951d10d5592308f5a378bfe2114f3

Roll third_party/spirv-cross/ 82d1c43e4..4c7944bb4 (1 commit)

82d1c43e40..4c7944bb42

$ git log 82d1c43e4..4c7944bb4 --date=short --no-merges --format='%ad %ae %s'
2020-08-13 lehoangq Fix #1445: MSL: Enclose args when convert distance(a,b) to abs(a-b)

Created with:
  roll-dep third_party/spirv-cross

Change-Id: I69886c8b47ebc66fd98228a97203bc8835dfb314

Roll third_party/SPIRV-Tools/ 2990a2192..b4c4da3e7 (15 commits)

2990a21926..b4c4da3e76

$ git log 2990a2192..b4c4da3e7 --date=short --no-merges --format='%ad %ae %s'
2020-08-13 alanbaker Improve non-semantic instruction handling in the optimizer (#3693)
2020-08-13 vasniktel Fix the bug (#3680)
2020-08-12 andreperezmaselco.developer spirv-fuzz: Check integer and float width capabilities (#3670)
2020-08-12 andreperezmaselco.developer spirv-fuzz: consider additional access chain instructions (#3672)
2020-08-12 andreperezmaselco.developer spirv-fuzz: Ignore specialization constants (#3664)
2020-08-12 vasniktel Fix the bug (#3683)
2020-08-12 vasniktel spirv-fuzz: Fix width in FuzzerPassAddEquationInstructions (#3685)
2020-08-12 jaebaek Preserve debug info in dead-insert-elim pass (#3652)
2020-08-12 jaebaek Validate more OpenCL.DebugInfo.100 instructions (#3684)
2020-08-11 alanbaker Only validation locations for appropriate execution models (#3656)
2020-08-11 andreperezmaselco.developer spirv-fuzz: Fix in operand type assertion (#3666)
2020-08-11 andreperezmaselco.developer spirv-opt: Add spvOpcodeIsAccessChain (#3682)
2020-08-11 vasniktel spirv-fuzz: FuzzerPassPropagateInstructionsUp (#3478)
2020-08-10 stevenperron Handle no index access chain in local access chain convert (#3678)
2020-08-10 rharrison Roll 2 dependencies (#3677)

Created with:
  roll-dep third_party/SPIRV-Tools

Change-Id: I1a07ba8931ec0b3ec8d70234f8aa871793df6fa0

Roll third_party/tint/ 5e7ef27ca..23c3fee35 (3 commits)

https://dawn.googlesource.com/tint/+log/5e7ef27ca7b1..23c3fee35436

$ git log 5e7ef27ca..23c3fee35 --date=short --no-merges --format='%ad %ae %s'
2020-08-13 sarahmashay [validation]: Add disabled test for validating return statement type matches function types
2020-08-13 sarahmashay [validation] Validates return statement
2020-08-13 rharrison Fix handling of .spvasm inputs

Created with:
  roll-dep third_party/tint

Change-Id: I70f8e484d12df835efce98db28b22d0cfa848a0b
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/26800
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Austin Eng <enga@chromium.org>
2020-08-13 20:18:39 +00:00
Corentin Wallez 13f3340173 Remove wgpu::Buffer::SetSubData
Bug: dawn:22

Change-Id: Id2bb79e84064c0d81d4dec5e85340d015806f9bc
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/26701
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
2020-08-13 16:01:08 +00:00
Corentin Wallez e236f7df27 Remove deprecated array layer descriptor members
- wgpu::TextureDescriptor::arrayLayerCount
 - wgpu::TextureCopyView::arrayLayer

Bug: dawn:22

Change-Id: I41a8b50c667f28c2496e0ad2e1d4ca655bf6c154
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/26700
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
2020-08-13 14:38:48 +00:00
Jiawei Shao 2b1c0b0e92 Clean up BufferZeroInitTests
BUG=dawn:414
TEST=dawn_end2end_tests

Change-Id: I8a9a4d45fe93e1071b8508ba7ddd2bf9545a3c63
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/26641
Commit-Queue: Jiawei Shao <jiawei.shao@intel.com>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
2020-08-13 12:03:28 +00:00
Austin Eng 4a486be696 Roll third_party/tint/ bc80805c4..5e7ef27ca (9 commits)
https://dawn.googlesource.com/tint/+log/bc80805c4b04..5e7ef27ca7b1

$ git log bc80805c4..5e7ef27ca --date=short --no-merges --format='%ad %ae %s'
2020-08-12 sarahmashay [ast] Adds get last statement to ast::Function
2020-08-12 sarahmashay [validation] Validates functions return statement
2020-08-12 dsinclair Minor updates to fix compilation.
2020-08-12 dsinclair Change output of string based data from sample app.
2020-08-12 idanr Find un-named entry points, change set number
2020-08-12 idanr Add instance step mode to vertex pulling transform
2020-08-12 idanr Add vertex pulling transform
2020-08-11 sarahmashay [validation] Validates declaration name uniqueness
2020-08-11 dsinclair Disable failing tests

Created with:
  roll-dep third_party/tint

Change-Id: I95394bd42e2a02bad36896188c7a1def2d140e78
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/26740
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Austin Eng <enga@chromium.org>
2020-08-12 23:13:08 +00:00
Corentin Wallez 2088cdec66 Update tests to use new mapping APIs
This CL updates all tests not specific to the old mapping API to use the
new mapping APIs. (a couple old tests that caused difficult diffs were
removed early).

Also fix an issue where the mapAsync callback wasn't fired with Unknown
when the buffer was destroyed.

Bug: dawn:445

Change-Id: I0101f533ecb1fd995066742b60a833dc2ad522aa
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/26300
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
2020-08-12 19:32:25 +00:00
Corentin Wallez 1aff02d444 Small nits for the implementation of WriteTexture in D3D12
Bug: None

Change-Id: Id44ff878ac3fc9762008a7f8b95ee65072aa1fcd
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/26600
Reviewed-by: Austin Eng <enga@chromium.org>
Reviewed-by: Stephen White <senorblanco@chromium.org>
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
2020-08-12 08:43:24 +00:00
Austin Eng 37f547456c Support depth-only/stencil-only copies on D3D12
Bug: dawn:439
Change-Id: I919a5e7bcb46f1817f9b15aaf49a1a72680aa47a
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/24960
Commit-Queue: Austin Eng <enga@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
2020-08-12 01:57:54 +00:00
Tomek Ponitka 11c0f579b1 Adding validation for requiredBytesInCopy overflow
Also some uint32_t computations are now done on uint64_t.

Bug: dawn:482
Change-Id: Ia0094e16999ec3a9fec193f27760e73cd14d289c
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/26540
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Jiawei Shao <jiawei.shao@intel.com>
Commit-Queue: Tomek Ponitka <tommek@google.com>
2020-08-11 12:04:52 +00:00
Natasha Lee cbec3179ef Implement Queue::WriteTexture in D3D12
Bug: dawn:483
Change-Id: I9e5f54abc6675acbb11a021a3d38aea7195017c5
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/26320
Commit-Queue: Natasha Lee <natlee@microsoft.com>
Reviewed-by: Austin Eng <enga@chromium.org>
2020-08-10 22:29:49 +00:00
Ryan Harrison 8fe202eccb Roll 3 dependencies
Roll third_party/glslang/ 2de6d657d..b60e067b4 (2 commits)

2de6d657dd..b60e067b43

$ git log 2de6d657d..b60e067b4 --date=short --no-merges --format='%ad %ae %s'
2020-08-06 john SPV: Fix #1829: don't emit OpModuleProcessed use-storage-buffer
2020-08-05 john Build/Test: Dropping 2013 allows using the latest googletests.

Created with:
  roll-dep third_party/glslang

Roll third_party/SPIRV-Tools/ 8bc27a1cf..2990a2192 (10 commits)

8bc27a1cfb..2990a21926

$ git log 8bc27a1cf..2990a2192 --date=short --no-merges --format='%ad %ae %s'
2020-08-10 stevenperron Avoid using /MP4 for clang on windows. (#3662)
2020-08-06 antonikarp spirv-fuzz: TransformationReplaceAddSubMulWithCarryingExtended (#3598)
2020-08-06 andreperezmaselco.developer spirv-fuzz: Add TransformationMakeVectorOperationDynamic (#3597)
2020-08-06 andreperezmaselco.developer spirv-fuzz: iterate over blocks in replace linear algebra pass (#3654)
2020-08-06 stefanomil spirv-fuzz: make outliner pass use additional transformations (#3604)
2020-08-05 jaebaek OpenCL.DebugInfo.100 DebugTypeArray with variable size (#3549)
2020-08-05 andreperezmaselco.developer spirv-opt: Improve the code of the Instruction class (#3610)
2020-08-05 vasniktel spirv-fuzz: Handle OpPhis in livesafe functions (#3642)
2020-08-05 vasniktel spirv-fuzz: Handle OpPhi during constant obfuscation (#3640)
2020-08-05 vasniktel spirv-fuzz: Fix FuzzerPassCopyObjects (#3638)

Created with:
  roll-dep third_party/SPIRV-Tools

Roll third_party/tint/ f18d737b4..bc80805c4 (5 commits)

https://dawn.googlesource.com/tint/+log/f18d737b4e93..bc80805c4b04

$ git log f18d737b4..bc80805c4 --date=short --no-merges --format='%ad %ae %s'
2020-08-09 dneto [spirv-writer] Infer and emit matrix layout
2020-08-07 sarahmashay [validation] v-0021: cannot re-assign constants
2020-08-06 sarahmashay [Validation] v-0006: variables must be defined before use
2020-08-05 dneto [spirv-reader] Remove support for NumWorkgroups builtin variable
2020-08-05 sarahmashay [validator] implement variable_stack_

Created with:
  roll-dep third_party/tint

Change-Id: Ieec678acb5113f7a9da92a44dbdd53b9f65b6286
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/26561
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Ryan Harrison <rharrison@chromium.org>
2020-08-10 19:12:29 +00:00
Brandon Jones ccf01e74ec Re-add heap usage tracking for textures in a pass
Heap usage tracking for textures in a pass was mistakenly removed when
texture subresource transitions was implemented. This must be re-added
for residency management to work (and not crash the application).

Bug: dawn:193
Change-Id: Ie5e9622f88a70d153232d5d72bb11846f4164e87
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/26461
Reviewed-by: Rafael Cintron <rafael.cintron@microsoft.com>
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Brandon Jones <brandon1.jones@intel.com>
2020-08-10 16:58:29 +00:00
Jiawei Shao 1662e97f32 Add tests for lazily initializing indirect buffers
This patch adds the end2end tests on the buffer lazy-initialization on
indirect buffers. In the last patch we have already supported buffer
lazy initialization on all the buffers used in a render pass and compute
pass, so in this patch we just need to add tests to ensure buffer lazy
initializations run as we expect on indirect buffers.

This patch also enables all the tests with write-only storage textures
on Metal, Vulkan and OpenGL with SPVC parser as these tests only fail
on D3D12 backends.

BUG=dawn:414
TEST=dawn_end2end_tests

Change-Id: If40b0129d6766e854cf1efdaea539a740a86ae66
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/26340
Commit-Queue: Jiawei Shao <jiawei.shao@intel.com>
Reviewed-by: Austin Eng <enga@chromium.org>
2020-08-10 00:48:58 +00:00
Enrico Galli 101a5829d5 DawnTest: Prevent infinite loops in DawnTest.
WaitABit waits forever should a device loss occurs, which
happens when a bug is introduced. This can lock up the console
preventing debugging when needed the most.

Bug: dawn:495
Change-Id: I0b13ddfa75abbb9c43f7dd545fa9c41be79a697c
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/25960
Reviewed-by: Bryan Bernhart <bryan.bernhart@intel.com>
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Bryan Bernhart <bryan.bernhart@intel.com>
2020-08-08 01:05:59 +00:00
Austin Eng 2cf5a08cfc Track depth/stencil aspects independently
This enables depth-stencil textures to track per aspect state
independently. It lifts the restriction that depth and stencil
store ops must be the same as they now have independent clear
states. It will also enable correct barriers on Vulkan and D3D12.

Bug: dawn:439
Change-Id: I8a73187df57a1d7eee6790cb4395bdecf42b63aa
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/26127
Reviewed-by: Jiawei Shao <jiawei.shao@intel.com>
Commit-Queue: Austin Eng <enga@chromium.org>
2020-08-06 17:00:29 +00:00
Ryan Harrison fa4b74d479 Remove temporary disabling of validation check
Change-Id: I8bf7f4850689c240152a7a87ed42d7637c69ed45
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/26380
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Ryan Harrison <rharrison@chromium.org>
2020-08-05 18:18:04 +00:00
Tomek Ponitka 7ce4924a35 Fixing linear texture data validation on bytesPerRow
This makes the validation match the spec more.
Since the change makes the validation throw less errors
than it used to, most of the tests should still be fine,
except for those I fixed.

Bug: dawn:482
Change-Id: I1d01356df66c897191a2305df419f088b45c8467
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/26302
Reviewed-by: Jiawei Shao <jiawei.shao@intel.com>
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Tomek Ponitka <tommek@google.com>
2020-08-05 16:43:24 +00:00
Ryan Harrison 076a4e5820 Roll 6 dependencies and bypass changed API usage
Roll third_party/glslang/ 3ee5f2f1d..2de6d657d (6 commits)

3ee5f2f1d3..2de6d657dd

$ git log 3ee5f2f1d..2de6d657d --date=short --no-merges --format='%ad %ae %s'
2020-08-04 john SPV: Standalone; sanity check the client GLSL input semantics option value.
2020-08-04 john SPV: Use more correct SPV-Tools environment, partially addressing #2290
2020-08-04 john SPV: Fix #2363: include trailing newline named text SPV output.
2020-07-03 ShabbyX Use GLSLANG_ANGLE to strip features to what ANGLE requires
2020-07-31 bclayton Revert changes that migrate to `thread_local`.
2020-07-27 dneto Avoid spurious warning about uninit var

Created with:
  roll-dep third_party/glslang

Roll third_party/shaderc/ cfacaaffd..c626b912d (1 commit)

cfacaaffd1..c626b912dc

$ git log cfacaaffd..c626b912d --date=short --no-merges --format='%ad %ae %s'
2020-07-29 dsinclair Update some language usage. (#1124)

Created with:
  roll-dep third_party/shaderc

Roll third_party/spirv-cross/ f5e9f4a17..82d1c43e4 (6 commits)

f5e9f4a172..82d1c43e40

$ git log f5e9f4a17..82d1c43e4 --date=short --no-merges --format='%ad %ae %s'
2020-08-03 cdavis MSL: Fix handling of matrices and structs in the output control point array.
2020-07-29 post Add some test cases for complex type aliasing scenario.
2020-07-29 post Ensure that we use primary alias type when emitting flattened members.
2020-07-29 post GLSL: Be more aggressive about using type_alias.
2020-07-29 post Only rewrite type aliases for the base type.
2020-07-28 post GLSL: Add option to force flattening IO blocks.

Created with:
  roll-dep third_party/spirv-cross

Roll third_party/spirv-headers/ 979924c8b..3fdabd0da (4 commits)

979924c8bc..3fdabd0da2

$ git log 979924c8b..3fdabd0da --date=short --no-merges --format='%ad %ae %s'
2020-08-03 44190824+mmerecki Reserve SPIR-V token range for upcoming Intel extensions. (#165)
2020-07-29 alanbaker Update BUILD.bazel and BUILD.gn (#166)
2020-07-29 alanbaker Publish the headers for the clspv embedded reflection non-semantic extended instruction set (#164)
2020-07-29 johnkslang Update the registry in spir-v.xml to modernize and split out opcodes. (#156)

Created with:
  roll-dep third_party/spirv-headers

Roll third_party/SPIRV-Tools/ 150be20d4..8bc27a1cf (17 commits)

150be20d43..8bc27a1cfb

$ git log 150be20d4..8bc27a1cf --date=short --no-merges --format='%ad %ae %s'
2020-08-04 vasniktel spirv-fuzz: Remove OpFunctionCall operands in correct order (#3630)
2020-08-04 vasniktel spirv-fuzz: Handle capabilities during module donation (#3651)
2020-08-04 vasniktel spirv-fuzz: Refactor boilerplate in TransformationAddParameter (#3625)
2020-08-03 vasniktel spirv-fuzz: TransformationMoveInstructionDown (#3477)
2020-07-31 jaebaek Remove DebugDeclare only for target variables in ssa-rewrite (#3511)
2020-07-31 vasniktel Fix typo in ASAN CI build (#3623)
2020-07-30 stefanomil spirv-fuzz: Transformation to add loop preheader (#3599)
2020-07-30 stefanomil spirv-fuzz: Pass to replace int operands with ints of opposite signedness (#3612)
2020-07-30 jaebaek Debug info preservation in loop-unroll pass (#3548)
2020-07-30 alanbaker Validator support for non-semantic clspv reflection (#3618)
2020-07-30 vasniktel spirv-fuzz: Fix memory bugs (#3622)
2020-07-29 andreperezmaselco.developer spirv-fuzz: Implement the OpOuterProduct linear algebra case (#3617)
2020-07-30 vasniktel spirv-fuzz: Compute corollary facts from OpBitcast (#3538)
2020-07-29 dj2 Update some language usage. (#3611)
2020-07-29 vasniktel spirv-fuzz: Relax type constraints in DataSynonym facts (#3602)
2020-07-29 vasniktel spirv-fuzz: Remove non-deterministic behaviour (#3608)
2020-07-29 afdx Avoid use of 'sanity' and 'sanity check' in the code base (#3585)

Created with:
  roll-dep third_party/SPIRV-Tools

Roll third_party/tint/ c5cd8f5bd..f18d737b4 (26 commits)

https://dawn.googlesource.com/tint/+log/c5cd8f5bd382..f18d737b4e93

$ git log c5cd8f5bd..f18d737b4 --date=short --no-merges --format='%ad %ae %s'
2020-08-04 rharrison Rolling 7 dependencies and fix BUILD.gn
2020-07-30 dsinclair [ast] Add texture types to the AST.
2020-07-30 dsinclair Add SamplerType to AST.
2020-07-30 dsinclair [hlsl-writer] Add loop support.
2020-07-30 dsinclair [hlsl-writer] Add if/else statements.
2020-07-30 dsinclair [hlsl-writer] Emit variable declarations.
2020-07-30 rharrison Add SPIR-V Reader Fuzzer
2020-07-30 rharrison Remove _exe suffix from sample program
2020-07-30 rharrison Change the default for BUILD.gn to build all the modules
2020-07-30 rharrison Simplify fuzzer targets to ease adding additional targets
2020-07-30 dsinclair Fixup build warnings
2020-07-30 dsinclair [wgsl-reader] Add stride support.
2020-07-30 dsinclair [wgsl-writer] Emit array stride decoration.
2020-07-30 idanr Add BlockStatement insert and non-const global_variables
2020-07-30 sarahmashay [Validator] Using pointers instead of refs
2020-07-29 dsinclair [hlsl-writer] Add member accessor emission.
2020-07-29 dsinclair [hlsl-writer] Add AsExpression to the HLSL backend.
2020-07-29 dsinclair [hlsl-writer] Add BlockStatement support.
2020-07-29 dsinclair [hlsl-writer] Emit discard.
2020-07-29 dsinclair [hlsl-writer] Emit array accessors.
2020-07-29 dsinclair [hlsl-writer] Add alias type support.
2020-07-29 dsinclair [hlsl-writer] Add constructor emission.
2020-07-29 dsinclair Add hlsl writer tests to BUILD.gn
2020-07-29 dsinclair [hlsl-writer] Add type emission.
2020-07-29 dsinclair Update some language usage.
2020-07-29 dneto [spirv-reader] Only support column-major matrices

Created with:
  roll-dep third_party/tint

Change-Id: I68064a00fb428d91aa00efa45f729bab1af2b103
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/26281
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Ryan Harrison <rharrison@chromium.org>
2020-08-04 21:27:58 +00:00
Austin Eng 0a4342793e Implement depth-only/stencil-only copies on Vulkan and Metal
Bug: dawn:439
Change-Id: I07ab014f4f13b73c09b2eecc48cd38b06d88166a
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/24684
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Jiawei Shao <jiawei.shao@intel.com>
Commit-Queue: Austin Eng <enga@chromium.org>
2020-08-04 19:46:37 +00:00
Jiawei Shao e84a1b1376 Add tests for lazy initializing vertex and index buffers
This patch adds the end2end tests on the buffer lazy-initialization on
vertex and index buffers. In the last patch we have already supported
buffer lazy initialization on all the buffers used in a render pass and
compute pass, so in this patch we just need to add tests to ensure
buffer lazy initializations run as we expect on vertex and index
buffers.

This patch also adds the missing checks on all the BufferZeroInitTests
to ensure the buffers are not lazily initialized when we validate if
their data is all set to zero in these tests.

BUG=dawn:414
TEST=dawn_end2end_tests

Change-Id: If2156027b23e9d90619b7814a542380f48af85ac
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/26140
Commit-Queue: Jiawei Shao <jiawei.shao@intel.com>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
2020-08-04 08:18:36 +00:00
Hao Li c0acb25318 Query API: Timestamp Query on D3D12
- Add implementation of WriteTimestamp and ResolveQuerySet on D3D12, but
not add compute shader to post-process the result yet.
- Add end2end tests for timestamp query on command encoder/render
pass/compute pass.

Bug: dawn:434
Change-Id: I7f763bc46d651818da3f69bc72ea2e403cf2674d
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/25845
Commit-Queue: Hao Li <hao.x.li@intel.com>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
2020-08-04 06:41:56 +00:00