Conditional on whether TINT_EXPECTS_UBOS_TO_BE_MULTIPLE_OF_16 is
defined, which it will be in a future Tint CL.
Bug: tint:984
Change-Id: I191cd59fe6947c9113a8fad7dbfbf79903969b27
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/57960
Commit-Queue: Antonio Maiorano <amaiorano@google.com>
Reviewed-by: Austin Eng <enga@chromium.org>
R=rharrison
Bug: chromium:1216166
Change-Id: Iabc72c400eff4a2f71179b5f4779eaccfd42d697
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/57423
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Commit-Queue: Ryan Harrison <rharrison@chromium.org>
Buffers are padded to be at least 4 bytes. Dawn would
produce invalid barriers for buffers that were "zero"
bytes large. The size for the barrier must be either
non-zero or VK_WHOLE_SIZE. Since we always intend
to transition the entire buffer, simply use
VK_WHOLE_SIZE instead of GetSize() as the size.
Fixed: dawn:969
Change-Id: Ifed4e8f9164bafa3c44917074fcf214e72919c56
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/57940
Reviewed-by: Jiawei Shao <jiawei.shao@intel.com>
Commit-Queue: Austin Eng <enga@chromium.org>
When we clear an uninitialized 3D texture, we should clear all depth
slices for each mip level. The current implementation only clears one
slice (the first slice) for each mip level. This change fixes this
bug. Dawn end2end tests of NonzeroTextureCreationTests can pass with
this fix. These tests fail on D3D12 without the fix.
This change also renames arguments for GetRTVDescriptor() for 3D
texture: change baseArrayLayer/layerCount to baseSlice/sliceCount.
Bug: dawn:547
Change-Id: Ic56f28e9e6430058c31aaa2bb21f4e42f7b7621c
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/57840
Reviewed-by: Austin Eng <enga@chromium.org>
Reviewed-by: Jiawei Shao <jiawei.shao@intel.com>
Commit-Queue: Yunchao He <yunchao.he@intel.com>
Not running the renamer can produce code that fails to compile
on the backend, resulting in device lost errors.
Change-Id: I4a841a281142bb8eda1402e1ebd6a5d23b77bfe0
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/57745
Reviewed-by: Ben Clayton <bclayton@google.com>
Commit-Queue: Austin Eng <enga@chromium.org>
crbug.com/tint/386 has been fixed.
We don't need these work arounds any more.
Original CL by bclayton@:
https://dawn-review.googlesource.com/c/dawn/+/54641
Bug: tint:386
Fixed: dawn:943
Fixed: dawn:975
Change-Id: I1b94d1e33b023b7d9b3153094f829885a75b5a5e
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/57743
Commit-Queue: Austin Eng <enga@chromium.org>
Auto-Submit: Austin Eng <enga@chromium.org>
Reviewed-by: Ben Clayton <bclayton@google.com>
This also creates a new commit to test 20% of realms :)
R=rharrison
Bug: chromium:1216166
Change-Id: I7a496c11ecba617620ae080a39c594a8800fc952
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/57422
Commit-Queue: Ryan Harrison <rharrison@chromium.org>
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
3D texture implementation has already been done. It's time to remove
the UnsafeAPI toggle for it.
Bug: dawn:547
Change-Id: Ic9e0930d7906ee5274b9e412ebacb2574744b2b3
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/56480
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Yunchao He <yunchao.he@intel.com>
R=rharrison
Bug: chromium:1216166
Change-Id: I773f502b741b26a5d591a600b08b7265abceb03c
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/57465
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Commit-Queue: Ryan Harrison <rharrison@chromium.org>
Auto-Submit: Andrii Shyshkalov <tandrii@google.com>
Also:
* remove redundant luci-scheduler permission.
* make ./main.star executable on mac/linux.
R=rharrison
Bug: chromium:1216166
Change-Id: Icd5e1612f7d201b640eeafa7217342b97e0fe5aa
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/57464
Auto-Submit: Andrii Shyshkalov <tandrii@google.com>
Commit-Queue: Ryan Harrison <rharrison@chromium.org>
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
This change moves function ViewDimensionToTextureDimension() to
TextureFormatUtils.h|.cpp.
This change also renames TextureFormatUtils.h|.cpp to TextureUtils.h|.cpp
because the new name makes more sense now.
Bug: dawn:547
Change-Id: I183c68d26365a6cda722be55b8ba3556c1b4c82b
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/57482
Reviewed-by: Jiawei Shao <jiawei.shao@intel.com>
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Jiawei Shao <jiawei.shao@intel.com>
The main part of this change is to add a few end2end tests, with
some renaming stuff like arrayLayerCount to sliceCount in order to
include both 2DArray and 3D textures.
The implementation is quite simple: just set UAV descriptor on D3D12.
The new tests can pass on Vulkan and Metal, which indicates the
implementation has been done on them.
The new tests fail on OpenGL and OpenGLES. I will take a look and
submit separate patch for GL and GLES.
Bug: dawn:547
Change-Id: Ic03eab6b06654c48341c935f64f4885be544985c
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/57160
Commit-Queue: Yunchao He <yunchao.he@intel.com>
Reviewed-by: Austin Eng <enga@chromium.org>
Change dawn read/write handle for buffer mapping to be created at buffer
creation time instead of at mapAsync time. Update related buffer mapping
tests and wire tests.
Bug: dawn:773
Change-Id: I7dd423c94e1bc15cfe561ea33ec9e348ddf2bfe0
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/51164
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Shrek Shao <shrekshao@google.com>
Tint now has a single-function API for code generation that
automatically runs the backend-specific sanitizer transforms. This API
allows for backend-specific configuration options such as the fixed
sample mask for MSL (and, in the future, information about which
compiler/version is being targeted), and returns any backend-specific
metadata such as whether a UBO of buffer sizes is required by the
shader.
This change prevents the post-sanitizer program from being exposed to
Dawn, which is a potential foot-gun (e.g. the Inspector is not
expected to be run after the sanitizer transforms, and Dawn is
currently doing this).
The old Generator class API will be removed from Tint shortly after
landing this change.
Bug: tint:697
Change-Id: I9b988d55514f810d3091ec6471731e6eb41dc27f
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/57103
Auto-Submit: James Price <jrprice@google.com>
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Austin Eng <enga@chromium.org>
Float16 is not standardized in WGSL or implemented in Tint,
so remove support of the extension for now.
Bug: dawn:571, dawn:426
Change-Id: Ia26f0ddb07cabf6057c0d7db9ade547494d2cc6e
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/56441
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Austin Eng <enga@chromium.org>
This change adds storage binding type tests for 3D texture. It turns
out that it is working. There is no additional work to be done.
Bug: dawn:547
Change-Id: Ia749200e7d371ad549405ff63c198ea4a27924c0
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/57120
Commit-Queue: Yunchao He <yunchao.he@intel.com>
Reviewed-by: Austin Eng <enga@chromium.org>
If enabled:
* Don't enable the renamer transform. Helps with readability.
* Emit the produced WGSL when combined with --force_wgsl_step
Change-Id: I336de6e6a4eee08805eee82847bd97cd5a942306
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/57040
Auto-Submit: Ben Clayton <bclayton@google.com>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Ben Clayton <bclayton@google.com>
Enough FXC workaround have been added to tint that these tests now pass again.
Fixed: tint:904
Change-Id: I6dd355d131ab903ae579391c0bfce93979dfc4f1
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/57041
Commit-Queue: Ben Clayton <bclayton@google.com>
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Auto-Submit: Ben Clayton <bclayton@google.com>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
When SPIRV-Cross we always reflect samplers as regular samplers. A
recent change implementing proper validation broke programs using
comparison samplers in that path.
Skip that bit of validation when using SPIRV-Cross, that hack can be
removed once we use Tint unconditionally for reflection.
Also reenables some BGL-ShaderModule compatibility tests with
SPIRV-Cross to cover the "fixed" validation.
Bug: dawn:571
Bug: dawn:367
Change-Id: I2d1a65aaea717b4927ac4e838942547a1b413d33
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/56900
Commit-Queue: Ben Clayton <bclayton@google.com>
Auto-Submit: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Ben Clayton <bclayton@google.com>
Removes the last remaining code paths supporting the old rowsPerImage
and bytesPerRow defaulting behavior, and updates all related tests to
strictly expect the spec-complaint behavior.
Change-Id: I022db0b142939d82e33d5989460488881e5a1ab3
Bug: dawn:520
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/56803
Commit-Queue: Brandon Jones <bajones@chromium.org>
Reviewed-by: Kai Ninomiya <kainino@chromium.org>
Also adds the new limits for maxComputeWorkgroupSize because there are
few systems where the .Z of that limit goes above 64.
Bug: dawn:796
Change-Id: I52e85e7b7c666da15493178e170ca82922d34017
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/56082
Commit-Queue: Kai Ninomiya <kainino@chromium.org>
Reviewed-by: Kai Ninomiya <kainino@chromium.org>
TimestampQueryTests.ResolveTwiceToSameBuffer fails on Intel latest
driver on Windows, because the kInternalStorageBuffer is not treated
in buffer usage when adding resource barrier.
Add missed kInternalStorageBuffer in buffer usage and remove
D3D12_RESOURCE_STATE_UNORDERED_ACCESS from QueryResolve, which will be
added by kInternalStorageBuffer.
Bug: dawn:797
Change-Id: I78607002179ba443b0db09c9c3bbc85fcc97a85b
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/56523
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Hao Li <hao.x.li@intel.com>