Commit Graph

118 Commits

Author SHA1 Message Date
Dzmitry Malyshau
350ceb383d WGSL support for f64, snapshot test for it 2021-05-08 21:20:23 -04:00
Gordon-F
53fe7a329f [glsl-out] Handle uninitialized global variables 2021-05-08 21:09:11 -04:00
Dzmitry Malyshau
63afb9a215 Add Capabilities bitset for validation 2021-05-05 21:39:41 -04:00
Dzmitry Malyshau
9fe75ed7f1 Barriers 2021-05-04 22:16:24 -04:00
Timo de Kort
05d3608737
HLSL CI (#788)
* Add validation-windows yml for HLSL

Add workgroup size to hlsl-out

* Update Readme with Make target information

* Change runs on to windows-latest

* Remove snapshot file
2021-05-02 11:29:35 -04:00
Lachlan Sneff
232fd65ec7
Add support for retrieving array length in msl backend (#806)
* Add support for arrayLength to the wgsl frontend

* Fix clippy warning

* Add draft support for array length to the msl backend

* Finalize support for array length in msl

* Convert buffer size to array length in msl backend

* Fix clippy warning

* Fix misleading documentation

* Changes based on review of PR

* Use a fake binding for sizes buffer in msl backend if necessary

* Only generate the msl buffer size structure if globals are present that have unsized arrays

* Make sure to generate separators

* Replace uses_unsized_buffers with !self.runtime_sized_buffers.is_empty()

* Clear self.runtime_sized_buffers

* Run snapshot of shadow.msl

* Add Expression::ArrayLength support to the spirv backend

* Remove wgsl target from the access snapshot test

* Update access.msl snapshot

* Update stack size for msl backend

* Update stack size again for msl backend
2021-04-30 22:40:32 -04:00
Dzmitry Malyshau
992bdd83ce
Report per-entry point translation errors in the MSL output snapshots (#808) 2021-04-30 13:38:20 -04:00
Igor Shaposhnik
452db33947 [glsl-out] Enable boids snapshot test 2021-04-26 09:59:05 -04:00
Gordon-F
dd1d9fe290 [wgsl-out] More improvements. Enable quad snapshot testing for wgsl backend 2021-04-26 00:20:01 -04:00
Dzmitry Malyshau
117d729ff8 [spv-in] allow non-strict check for capabilities 2021-04-25 18:32:34 -04:00
Dzmitry Malyshau
3049e3a4ac [spv-out] allow capabilities to be derived 2021-04-25 13:34:16 -04:00
Gordon-F
3accf4dc15 Improve wgsl-out 2021-04-23 16:36:49 -04:00
Dzmitry Malyshau
02105db045
[spv-out] image queries (#749) 2021-04-23 12:31:33 -04:00
Gordon-F
c37ae5e2a0 [glsl-out] Use fmt::Writer instead of io::Writer 2021-04-20 09:09:35 -04:00
Igor Shaposhnik
ce0720ac61
Add wgsl-out into test infrastructure (#730) 2021-04-19 09:19:03 -04:00
Dzmitry Malyshau
bb716f9c10
[spv-out] implement array value indexing (#723) 2021-04-16 17:11:18 -04:00
Dzmitry Malyshau
daf4c82376
Allow stepping on floats in the validator (#724) 2021-04-16 16:16:15 -04:00
Jim Blandy
2eb3e81e19 [wgsl-in] Add basic test for interpolate attribute. 2021-04-15 17:19:20 -04:00
Jim Blandy
3f958f618b [glsl-out] Let snapshot tests request a specific GLSL desktop version.
Add a Option<u16> to the snapshot `Params` to let snapshots request specific
Desktop GLSL versions. The default is GLSL ES 3.10.

It would be more general to let the params select any GLSL version, but that
would entail making glsl::Version implement Deserialize and all that, which
seems like overkill.
2021-04-15 17:19:20 -04:00
Dzmitry Malyshau
96f9cb4ce1 [wgsl] Add support for simplified vector construction, add a snapshot test 2021-04-14 19:26:20 -04:00
Dzmitry Malyshau
c2c93e4ecd Remove cargo-insta 2021-04-14 16:10:31 -04:00
Dzmitry Malyshau
3f57e4db5a Enable texture-array snapshot on Metal 2021-04-13 01:31:57 -04:00
Timo de Kort
5d487941b2
Start hlsl-out (#408)
* Add hlsl-out feature

* Integrate hlsl-out with snapshots

* Add snapshot
2021-04-11 11:36:26 -04:00
Dzmitry Malyshau
e06451777e [msl] address review comments, rename SubOptions to PipelineOptions, add more inlined states 2021-04-07 22:49:13 -04:00
Dzmitry Malyshau
7c11759041 Re-use the MSL types in snapshot code 2021-04-07 22:49:13 -04:00
Dzmitry Malyshau
dcbedd17d0 [msl] basic infrastructure for inline samplers
Also move out "allow_point_size" into SubOptions to allow
main Options to not be cloned.
2021-04-07 22:49:13 -04:00
Dzmitry Malyshau
410c242daf [spv-out] add a flag to adjust the coordinate space 2021-04-03 11:27:21 -04:00
Dzmitry Malyshau
ead052b773 [spv-in] add a flag to adjust the coordinate space 2021-04-03 11:27:21 -04:00
Dzmitry Malyshau
d4d9d7814f [msl-out] option to omit point size output 2021-04-02 00:19:52 -04:00
Dzmitry Malyshau
db455af04b Add a snapshot for image load/store ops 2021-04-01 10:47:28 -04:00
Dzmitry Malyshau
f2155d49d1 [msl] fix initialization of arrayed members, enable METAL snapshot of quad-vert 2021-03-27 10:58:01 -04:00
Dzmitry Malyshau
e47ff2dc26 [spv-in] support output interface block 2021-03-27 10:52:00 -04:00
Dzmitry Malyshau
e3ae5904ba Move AnalysisFlags into ValidationFlags, add bits for expressions and blocks 2021-03-20 22:25:49 -04:00
Dzmitry Malyshau
c992e638fe Move all the validation into a separate meta-module 2021-03-20 22:25:49 -04:00
Dzmitry Malyshau
caee860b70 Make uniformity analysis optional 2021-03-20 22:25:49 -04:00
Dzmitry Malyshau
665ac49a01 Show expression uniformity in the Dot backend 2021-03-17 01:03:00 -04:00
Igor Shaposhnik
25fe522423 [glsl-out] Properly write array type 2021-03-10 15:17:07 -05:00
Dzmitry Malyshau
13d7a353e0 Switch entry points from map to a vec 2021-03-07 12:11:49 -05:00
Dzmitry Malyshau
3fcc0759ed GraphViz backend 2021-03-03 21:20:12 -05:00
Dzmitry Malyshau
89e37d6e90 Explicitly emit expressions by Statement::Emit 2021-03-02 21:50:06 -05:00
Dzmitry Malyshau
69bf7f5f17 Miscellaneous fixes 2021-03-01 09:35:29 -05:00
Dzmitry Malyshau
99c1add358 [msl] fake bindings 2021-02-19 19:20:21 -05:00
João Capucho
19e7f456c4 Remove the call graph processor
Uses the GlobalUse in glsl-out to check for function availability
2021-02-18 11:43:18 -05:00
Dzmitry Malyshau
5f21cf360f Refactor snapshot testing to include some IR 2021-02-18 10:19:25 -05:00
Dzmitry Malyshau
8a0382a89d Move global use flags into FunctionInfo 2021-02-17 15:37:37 -05:00
Pelle Johnsen
408002815f [glsl-in] Multi entry points - address comments 2021-02-17 10:05:40 -05:00
Pelle Johnsen
1861fca4ba [glsl-in] Support multiple entrypoints 2021-02-17 10:05:40 -05:00
Dzmitry Malyshau
6d0c608626 [glsl-out] use existing Analysis instead of implementing Visitor 2021-02-15 11:13:11 -05:00
Dzmitry Malyshau
61d711b58f Remove the Header from IR 2021-02-14 20:23:31 -05:00
Systemcluster
5de69f7276 Specify line endings in ron snapshot tests 2021-02-14 11:29:25 -05:00
Dzmitry Malyshau
c1fc5d6424 [msl] re-use expression results based on the analysis 2021-02-14 01:19:15 -05:00
Dzmitry Malyshau
8183f4ff6f [spv-out] annotate function and constant names 2021-02-13 19:37:54 -05:00
Dzmitry Malyshau
5b94ecd9b2 Add a snapshot for parsing spirv input 2021-02-08 15:59:47 -05:00
Dzmitry Malyshau
10867879d4 [spv-in] support projection sampling and sampling from arrays 2021-02-08 11:31:45 -05:00
Joshua Groves
31be7099f2 Move snapshot inputs and outputs around 2021-02-07 18:16:26 -05:00
Dzmitry Malyshau
6f50ca6bee Push constant support 2021-02-07 11:54:56 -05:00
Dzmitry Malyshau
0bbeec7d55 Add shadow snapshot shader 2021-01-30 15:14:38 +01:00
Dzmitry Malyshau
162079c160 Enable collatz and boids testing for spv-out 2021-01-28 17:28:48 +01:00
Dzmitry Malyshau
0ea8a0a3c2 [wgsl] support unsigned literals 2021-01-23 10:03:25 -05:00
Dzmitry Malyshau
c758399354 Add a collatz snapshot test 2021-01-22 08:58:02 -05:00
Dzmitry Malyshau
77657b4c76 Add skybox example snapshots 2020-12-13 10:20:57 -05:00
Dzmitry Malyshau
087b5555a6 Add tests for GLSL parsing 2020-12-13 00:41:23 -05:00
Dzmitry Malyshau
0efd6e75d7 [wgsl] update texture definitions and storage access
Add more tests, enhance the snapshot testing.
2020-12-12 12:46:24 -05:00
Dzmitry Malyshau
dafca34877 Add block boolean to the structure types in IR
Also update WGSL syntax for structures.
Move the boids code into snapshots.
2020-12-12 12:46:24 -05:00
Dzmitry Malyshau
b7744a1ec5 [wgsl] function lookup, improve error reporting 2020-12-10 10:20:56 -05:00
Joshua Groves
d71ebe2881 Add snapshots for function.wgsl 2020-12-10 00:24:07 -05:00
Joshua Groves
51cdb0403a Add snapshots for simple.wgsl 2020-12-10 00:24:07 -05:00
Joshua Groves
9a625a570e Add insta prototype 2020-12-10 00:24:07 -05:00