Commit Graph

73 Commits

Author SHA1 Message Date
Conor McCarthy
8a1eb306e8 tests/shader-runner: Introduce a 'float64' requirement directive. 2023-12-12 22:50:50 +01:00
Conor McCarthy
95c48eb98e tests/shader-runner: Introduce an 'int64' requirement directive. 2023-12-12 22:50:49 +01:00
Giovanni Mascellani
c691ad8869 tests: Immediately transition buffers after creation in the shader runner.
The resource could be destructed before the command list left open
is executed; instead, we immediately perform the transition.
2023-11-01 21:47:44 +01:00
Giovanni Mascellani
46b7fccfd7 tests: Immediately transition textures after creation in the shader runner.
The resource could be destructed before the command list left open
is executed; instead, we immediately perform the transition.
2023-11-01 21:47:43 +01:00
Giovanni Mascellani
ca7fa0c015 tests: Immediately transition resources after readback in the shader runner.
The resource could be destructed before the command list left open
is executed; instead, we immediately perform the transition.
2023-11-01 21:47:41 +01:00
Conor McCarthy
57280673e5 tests/shader-runner: Test shaders with dxcompiler.
The location of dxcompiler should be set during configuration with
'DXCOMPILER_LIBS=-L/path/to/dxcompiler', and then at runtime with
LD_LIBRARY_PATH, WINEPATH or PATH as applicable.

A new 'fail(sm<6)' decoration is needed on many shader declarations
because dxcompiler succeeds on many shaders which fail with fxc. The
opposite case is less common and is flagged with 'fail(sm>=6)'. A few
tests cause dxcompiler to crash or hang, so these are avoided using
[require], which now skips tests until reset instead of exiting. Also,
'todo(sm<6)' and 'todo(sm>=6)' are used to separate checking of results.
2023-10-11 22:21:14 +02:00
Conor McCarthy
d211160b89 tests/shader-runner: Replace immediate shader type strings with an enum. 2023-10-11 22:21:14 +02:00
Nikolay Sivov
269747dbf3 tests: Enable compiler backwards compatibility mode only for shaders that require it.
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
2023-08-28 20:40:06 +02:00
Francisco Casas
948c4145f5 tests: Test texture allocation ordering in complex scenarios. 2023-08-15 21:51:26 +02:00
Nikolay Sivov
01faf6ad9e tests: Add test file syntax to specify compiler options.
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
2023-07-24 22:41:09 +02:00
Francisco Casas
ab37b27a7d tests: Pass D3DCOMPILE_ENABLE_BACKWARDS_COMPATIBILITY when compiling with the shader-runner. 2023-07-17 22:55:43 +02:00
Nikolay Sivov
f470c00453 tests: Add support for UAV buffers to d3d12 runner.
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
2023-05-22 22:03:36 +02:00
Nikolay Sivov
74c0ad0a7a tests: Rename readback helper to be more generic.
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
2023-05-22 22:03:28 +02:00
Nikolay Sivov
a4ebde202a tests: Add support for UAV buffers in Vulkan runner.
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
2023-05-22 22:03:28 +02:00
Zebediah Figura
4ec60707e2 tests: Add a test for sampling from nonzero mipmap levels. 2023-05-08 20:24:15 +02:00
Zebediah Figura
c940486a89 tests/shader_runner: Add support for creating mipmapped textures. 2023-05-08 20:24:15 +02:00
Francisco Casas
7c2ac5b098 tests: Test objects as parameters. 2023-05-08 20:24:14 +02:00
Nikolay Sivov
c74d148cbe tests: Remove rtv clears in d3d12 runner.
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
2023-04-26 22:46:52 +02:00
Nikolay Sivov
a496e3a8ba tests: Disable culling in shader runners.
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
2023-04-13 23:05:00 +02:00
Henri Verbeet
a0a3fb0e5f tests/shader_runner: Return from run_shader_tests_d3d12() if we're unable to create a test context.
A test environment may legitimately be unable to support running d3d12 tests.
2023-04-04 22:01:15 +02:00
Zebediah Figura
9ea84ae8c9 tests/shader_runner: Use the global test_options structure.
Inspired by a patch by Giovanni Mascellani.
2023-03-10 21:13:05 +01:00
Giovanni Mascellani
c8a05a8b10 tests: Collect D3D12 test options in a dedicated structure. 2023-03-10 21:12:46 +01:00
Francisco Casas
7a7116eaab tests: Test allocation of unused objects. 2023-02-22 18:28:19 +01:00
Francisco Casas
97c9669544 tests: Add additional object references tests. 2023-01-19 12:29:39 +01:00
Zebediah Figura
75494a4ae6 tests: Add a basic shader test for compute shaders. 2022-10-19 21:59:29 +02:00
Zebediah Figura
08e2a8e9bb tests: Add a basic shader test for UAVs.
Signed-off-by: Giovanni Mascellani <gmascellani@codeweavers.com>
Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-06-09 19:13:09 +02:00
Zebediah Figura
2b69ee67bd tests/shader_runner: Make the render target into a resource.
Signed-off-by: Giovanni Mascellani <gmascellani@codeweavers.com>
Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-06-09 19:13:06 +02:00
Zebediah Figura
ac404afe93 tests/shader_runner: Allow creating UAV resources.
Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Giovanni Mascellani <gmascellani@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-06-09 19:12:59 +02:00
Zebediah Figura
4a9d675c49 tests/shader_runner: Move the check_readback_data_vec4() call to shader_runner.c.
Split the probe_vec4() directive into get_rt_readback() and release_readback().

Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Giovanni Mascellani <gmascellani@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-05-31 21:53:21 +02:00
Zebediah Figura
b5e773058c tests: Separate generic and d3d12-specific readback fields.
Move the "resource" field to a new "d3d12_resource_readback" structure
encapsulating struct resource_readback.

Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Giovanni Mascellani <gmascellani@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-05-31 21:52:49 +02:00
Zebediah Figura
c0562e2a1e tests: Introduce support for marking individual test directives as todo.
Signed-off-by: Giovanni Mascellani <gmascellani@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-04-15 21:18:04 +02:00
Zebediah Figura
26b89cc338 tests: Skip probe directives if the last render failed.
Signed-off-by: Giovanni Mascellani <gmascellani@codeweavers.com>
Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-04-15 21:18:01 +02:00
Zebediah Figura
02182ce4f7 tests: Transition back to D3D12_RESOURCE_STATE_RENDER_TARGET in d3d12_runner_probe_vec4().
Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-04-12 19:00:11 +02:00
Zebediah Figura
c7623262cc tests: Specify the primitive type from the shader runner frontend.
Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-03-22 18:41:41 +01:00
Zebediah Figura
492cd135e3 tests: Specify the vertex count from the shader runner frontend.
Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-03-22 18:41:39 +01:00
Zebediah Figura
84c73f82f7 tests: Allow specifying a custom vertex buffer.
Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-03-22 18:41:37 +01:00
Zebediah Figura
f11f7032cd tests: Make the "texture" structure more generic.
Use it to hold any type of resource, regardless of type and binding.

Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-03-22 18:41:35 +01:00
Zebediah Figura
3ed4c6fe23 tests: Allow specifying a custom input layout.
Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-03-22 18:41:32 +01:00
Zebediah Figura
16b383aef5 tests: Specify the default vertex shader in the shader runner frontend.
Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-03-22 18:41:29 +01:00
Zebediah Figura
52223250d7 tests: Add support for running shader tests with a custom vertex shader.
Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-03-22 18:41:26 +01:00
Zebediah Figura
099df706f0 tests: Use a macro to define the render target size.
Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-03-21 22:35:03 +01:00
Zebediah Figura
39459d6c3e tests: Rename struct d3d12_shader_context to struct d3d12_shader_runner.
Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-03-21 22:34:59 +01:00
Zebediah Figura
5841e79102 tests: Rename struct shader_context to struct shader_runner.
This is a bit clearer, and avoids colliding with other things named "context",
e.g. struct test_context, or d3d11 device contexts.

Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-03-21 22:34:57 +01:00
Zebediah Figura
0ca2444e9b tests: Use only one heap for textures in the d3d12 shader runner.
The d3d12 specification forbids simultaneously binding more than one heap of a
given type.

Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-03-14 18:26:50 +01:00
Zebediah Figura
721ea8fa60 tests: Mark some tests as requiring shader model 4.0.
Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-03-08 17:45:21 +01:00
Zebediah Figura
3994cec7b1 tests: Pass HLSL source to the draw_quad() function.
Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-01-27 18:00:44 +01:00
Zebediah Figura
33c845ece5 tests: Move d3d12-specific members of struct texture to a new d3d12_texture structure.
Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-01-27 18:00:41 +01:00
Zebediah Figura
c417d3f830 tests: Make texture allocation and destruction into separate shader_runner ops.
Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-01-27 18:00:39 +01:00
Zebediah Figura
09e3018b6d tests: Move the drawing and readback implementation to the d3d12 shader runner.
Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-01-27 18:00:37 +01:00
Zebediah Figura
85d61f0c64 tests: Move HLSL shader compilation to a new d3d12 shader runner backend.
Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-01-27 18:00:34 +01:00