Commit Graph
9013 Commits
Author SHA1 Message Date
bors[bot]andZicklag e5142b3cdc Merge #1623
1623: Enable All Backends for Trace Player r=cwfitzgerald a=zicklag

**Connections**
None

**Description**
I just spent a bit of time trying to figure out how to get the trace player to play an OpenGL trace before realizing that only the primary backends were enabled at instance creation. This just enables all backends in the trace player. I believe that this should be harmless as it shouldn't change anything for traces on the primary supported backends.

**Testing**
It's not tested specifically, but it's such a minor change it shouldn't matter, I think.


Co-authored-by: Zicklag <zicklag@katharostech.com>
2021-07-10 01:51:22 +00:00
Zicklag 0614ccea7e Enable All Backends for Trace Player 2021-07-09 20:42:59 -05:00
bors[bot]andBenoît du Garreau e27fbb821b Merge #1612
1612: Update `web-sys` r=grovesNL a=a1phyr

`wgpu` uses unstable APIs so the version has to be pinned and manually updated.

No breaking changes happened in `0.3.51` so this update is easy.

Co-authored-by: Benoît du Garreau <bdgdlm@outlook.com>
2021-07-07 18:44:46 +00:00
João Capucho 7532c2abaa [glsl-in] Remove wrong texture types
Glsl doesn't have depth textures what it has is combined image/samplerShadow
2021-07-07 12:59:20 -04:00
João Capucho bd339e5f60 [glsl-in] Add textureProj 2021-07-07 12:59:20 -04:00
João Capucho 3f2b754c42 [glsl-in] Fix proxy write type mismatch 2021-07-07 12:59:20 -04:00
João Capucho ba75ca6efe [glsl-in] Don't implicitly cast shifts 2021-07-07 12:59:20 -04:00
João Capucho 105a2ae5e1 [glsl-in] Check type dimensions in function calls 2021-07-07 12:59:20 -04:00
Gordon-F 9e61390626 [hlsl-out] Zero initialize variables. Write interpolation and sampling qualifier 2021-07-07 10:57:28 -04:00
Benoît du Garreau 8bd9e151cd Update web-sys 2021-07-07 16:09:15 +02:00
bors[bot]andConnor Fitzgerald 4781d9da7b Merge #1607
1607: Fix Downlevel Vertex Stage Storage Buffer Check r=kvark a=cwfitzgerald

**Connections**

Fixes a bug in #1599. Also follows up on #1583 marking all of hello-compute as a failure.

**Testing**

Tests now pass on rpi4.


Co-authored-by: Connor Fitzgerald <connorwadefitzgerald@gmail.com>
2021-07-07 14:01:37 +00:00
Connor Fitzgerald 90ef8141f9 Fully skip all rpi hello-compute tests due to non-determinism 2021-07-06 21:43:47 -04:00
Connor Fitzgerald bd1c153a2f Rename testing framework's segfault to skip 2021-07-06 21:43:47 -04:00
Connor Fitzgerald 8ded21862e Fix downlevel vertex stage storage buffer check 2021-07-06 21:43:47 -04:00
Jim Blandy 918183162f [spv-out]: Access BlockContext::cached directly.
Since `BlockContext` now owns the `cached` table directly, there's no point in
going through a helper function.
2021-07-06 14:57:09 -04:00
Jim Blandy 562af28773 [spv-out] Move cached expression table to BlockContext.
Since the table of cached expressions is only meaningful within a single
function, it's really something that should only be accessed from
`BlockContext`.

However, to save heap allocations, it makes sense to retain it in the `Writer`
between functions. But the `Writer` field should have a different name, to
ensure people don't use it by accident.
2021-07-06 14:57:09 -04:00
Jim Blandy a818b2e089 Document Loop, Break, and Continue statements. 2021-07-06 13:55:09 -04:00
João Capucho e8bb7f2503 [glsl-in] Parse array initializers 2021-07-06 11:24:05 -04:00
João Capucho ee1004d443 [glsl-in] Use cast for implicit conversion
Previously this was a bitcast
2021-07-06 11:24:05 -04:00
João Capucho ee343b3017 [glsl-in] Implicit splat max builtin 2021-07-06 11:24:05 -04:00
João Capucho 7bced3f4e8 [glsl-in] Add support for all texture types 2021-07-06 11:24:05 -04:00
João Capucho 2b475ecc96 [spv-out] Support object-wise select 2021-07-06 10:12:24 -04:00
Dzmitry Malyshau 9473340c16 wgsl-in: fix auto array stride 2021-07-06 02:20:26 -04:00
bors[bot]andBenoît du Garreau d2a27e0c4e Merge #1604
1604: Upgrade `arrayvec` to 0.7 r=kvark a=a1phyr

Upgrade `arrayvec` to version 0.7 (using const generics).

Co-authored-by: Benoît du Garreau <bdgdlm@outlook.com>
2021-07-06 05:31:22 +00:00
Dzmitry Malyshau c69736210a Snapshot test local variable inference 2021-07-06 01:26:03 -04:00
Dzmitry Malyshau beabd62d96 wgsl: type inference for local variables 2021-07-06 01:26:03 -04:00
Dzmitry Malyshau 2efccb2bf8 hal/vk: fix indirect stage flag 2021-07-06 00:56:43 -04:00
bors[bot]andMikko Lehtonen 782a5bc831 Merge #1606
1606: Fix macos build r=cwfitzgerald a=scoopr

Building on macos failed with
```
   Compiling wgpu-hal v0.9.0 (/Users/scoopr/Code/ext/wgpu/wgpu-hal)
error[E0609]: no field `entry` on type `&vulkan::Instance`
   --> /Users/scoopr/Code/ext/wgpu/wgpu-hal/src/vulkan/instance.rs:267:61
    |
267 |             let metal_loader = ext::MetalSurface::new(&self.entry, &self.shared.raw);
    |                                                             ^^^^^ unknown field
    |
    = note: available fields are: `shared`, `extensions`

error: aborting due to previous error
```

The PR fixes the issue.

Co-authored-by: Mikko Lehtonen <scoopr@iki.fi>
2021-07-06 00:25:08 +00:00
Mikko Lehtonen 7e277c2ed9 Fix macos build 2021-07-06 02:08:19 +03:00
Gordon-F 65fbbf1101 [hlsl-out] Return only real names on entry point in ReflectionInfo 2021-07-05 18:54:42 -04:00
Gordon-F d5776879de [hlsl-out] Enable interface snapshot testing 2021-07-05 18:54:42 -04:00
Gordon-F 2812acf8cd [hlsl-out] Handle output semantic for shader stage 2021-07-05 18:54:42 -04:00
Gordon-F 988fc90b83 [Makefile] Fix dxc params in validate-hlsl 2021-07-05 18:54:42 -04:00
Benoît du Garreau e7269e72f3 Upgrade arrayvec to 0.7 2021-07-06 00:45:24 +02:00
Joshua Groves 9192f7b882 wgsl-in: add more error tests 2021-07-05 02:24:18 -04:00
João Capucho 2f002a0594 [spv-out] Load texture arguments ahead of time 2021-07-05 02:23:00 -04:00
João Capucho c7b98f5ab9 [spv-out] accept texture trough function argument 2021-07-05 02:23:00 -04:00
bors[bot]andConnor Fitzgerald 118cf2cdba Merge #1599
1599: Fix Limits for lava/llvmpipe and re-enable and re-work CI r=kvark,groves,wumpf a=cwfitzgerald

**Connections**

No longer fixes #1551.

**Description**

This PR has a couple things going on at once.

- Fixes limits for llvmpipe, lavapipe, and rpi4.
- Added a downlevel limit to express that RPI4 does not allow storage buffers in vertex shaders on GL.
- Added a `Limits::downlevel_default()` that takes minimum limits from GLES and adds some more documentation on how to choose limits.
- Moved all examples to the new downlevel limits
- Reworks CI to re-enable software testing and unify instructions.

**Testing**

It is

Co-authored-by: Connor Fitzgerald <connorwadefitzgerald@gmail.com>
2021-07-04 19:23:23 +00:00
Connor Fitzgerald 130ddcf561 Unify CI and testing 2021-07-04 15:22:51 -04:00
Joshua Groves c5805a9e10 wgsl-in: add more error tests 2021-07-04 01:00:21 -04:00
bors[bot]andDzmitry Malyshau b5a73b6a80 Merge #1600
1600: Vulkan Timeline Semaphores r=kvark a=kvark

**Connections**
None

**Description**
One of the non-straightforward design decisions in wgpu-hal was to expose the fences with `D3D12Fence` semantics. Now that we got Vulkan, Metal, and GLES3, it became a bit concerning that all of these backends implemented this new fence API in the same convoluted way: via managing a pool of binary fences internally, which requires maintenance (done on submit() only). If that's the expected implementation, then the abstraction is wrong.

For this reason, it was important for me to try implementing this new semantics in a modern Vulkan way - via timeline semaphores. With this, we have 1:1 relation between `Api::Fence` and a Vulkan object. I believe the experiment is a success: Vulkan is now very efficient at fences!

**Testing**
Works on the examples!


Co-authored-by: Dzmitry Malyshau <dmalyshau@mozilla.com>
2021-07-04 04:57:40 +00:00
Dzmitry Malyshau 3de1681eb0 hal/vk: enable timeline semaphores 2021-07-04 00:50:05 -04:00
Dzmitry Malyshau 8ae7d51c82 hal/vk: request timeline semaphores if available 2021-07-04 00:50:05 -04:00
bors[bot]andDzmitry Malyshau 93eb33cf3b Merge #1598
1598: Fix memory leak in acquiring encoders r=kvark a=kvark

**Connections**
Fixes #1501 
Fixes #1531

**Description**
It was ... interesting. We were creating new command encoders all the time, but still trying to add them to the pool to re-use later. So we were constantly allocating and never freeing them, up until the end. Therefore, program as a whole was valid and non-leaking, if analyzed after termination.

**Testing**
Observed memory manually


Co-authored-by: Dzmitry Malyshau <dmalyshau@mozilla.com>
2021-07-04 02:34:10 +00:00
Dzmitry Malyshau b704a0542f Fix memory leak in acquiring encoders 2021-07-03 22:25:59 -04:00
Connor Fitzgerald e2bcb72bf4 Please clippy 2021-07-03 22:15:34 -04:00
Connor Fitzgerald 861e84b178 Start adjusting CI 2021-07-03 22:15:16 -04:00
Connor Fitzgerald 26f3c03150 Add downlevel limit for vertex shader access to SSBO 2021-07-03 22:15:16 -04:00
Connor Fitzgerald 93cca6d182 Fix limits for rpi on vk 2021-07-03 22:15:16 -04:00
Connor Fitzgerald a13b54ced8 Fix limits for llvmpipe 2021-07-03 22:15:16 -04:00