Commit Graph

41 Commits

Author SHA1 Message Date
Henri Verbeet
f866fb95ad Release 1.11. 2024-03-05 20:39:45 +01:00
Henri Verbeet
5c637d68da tests/shader_runner: Set the SPIR-V feature flags based on the runner caps. 2024-03-04 22:34:38 +01:00
Henri Verbeet
015fde5e23 tests/shader_runner: Set the vkd3d-shader API version in the Vulkan runner. 2024-03-04 22:34:37 +01:00
Conor McCarthy
081c9dbc96 tests/shader-runner: Support structured buffer UAVs. 2024-02-22 22:45:02 +01:00
Henri Verbeet
54142eb0bd tests/shader_runner: Print information about the run configuration in run_shader_tests(). 2024-02-19 21:12:33 +01:00
Henri Verbeet
f15a0ace3e tests/shader_runner: Print a summary of the runner capabilities in run_shader_tests(). 2024-02-19 21:12:32 +01:00
Henri Verbeet
930fbcbb26 tests/shader_runner: Pass the runner capabilities to run_shader_tests().
Allowing these to be checked by run_shader_tests() itself, instead of
reimplementing those checks in each individual runner.
2024-02-19 21:12:30 +01:00
Francisco Casas
4d855611b7 tests/shader-runner: Support SRV buffers. 2024-02-19 21:11:51 +01:00
Francisco Casas
22a0f14a2f tests/shader-runner: Separate resource_type into type and dimension.
If in the same shader_test file we have both a [buffer uav n] and a
[uav n] with the same slot "n", we want the last one to override the
first one instead of passing both resources to the backends.

Same for [buffer srv n] and [texture n] after we introduce SRV buffers.
2024-02-19 21:11:49 +01:00
Evan Tang
628acb6b96 tests: Add some tests for rasteriser-ordered views. 2024-02-14 21:48:53 +01:00
Henri Verbeet
f614d98759 tests/shader_runner: Allow UAV resources to be created without initial data.
We can e.g. initialise these with a shader.
2024-02-14 21:48:51 +01:00
Francisco Casas
8379e5337c tests/shader_runner: Free extensions pointer on vulkan runner (valgrind). 2024-01-25 22:24:32 +01:00
Francisco Casas
1c73513425 tests: Use the vulkan runner to run SM1 compilation tests.
At the current moment this is a little odd because for SM1 [test]
directives are skipped, and the [shader] directives are not executed by
the shader_runner_vulkan.c:compile_shader() but by the general
shader_runner.c:compile_shader(). So in principle it is a little weird
that we go through the vulkan runner.

But fret not, because in the future we plan to make the parser agnostic
to the language of the tests, so we will get rid of the general
shader_runner.c:compile_shader() function and instead call a
runner->compile_shader() function, defined for each runner. Granted,
most of these may call a generic implementation that uses native
compiler in Windows, and vkd3d-shader on Linux, but it would be more
conceptually correct.
2024-01-24 22:37:44 +01:00
Francisco Casas
671f4ec2b2 tests/shader-runner: Call each runner only once.
If the runners require multiple calls to run_shader_tests() for
different shader model ranges, these are moved inside the sole runner
call.

For the same reason, the trace() messages are also moved inside the
runner calls.
2024-01-24 22:37:34 +01:00
Zebediah Figura
aa44f9b390 tests: Use struct vkd3d_shader_scan_signature_info to retrieve the VS input signature.
In order to allow retrieving it from d3dbc shaders.
2023-12-14 23:19:28 +01:00
Conor McCarthy
f23426ec32 tests/shader-runner: Check for int64 support in the Vulkan runner. 2023-12-14 21:00:41 +01:00
Conor McCarthy
a80ea8168f tests/shader-runner: Check for float64 support in the Vulkan runner. 2023-12-14 21:00:39 +01:00
Henri Verbeet
e53178f395 tests: Use the same viewport origin and front-face orientation in the Vulkan and D3D runners.
I.e., top-left origin, and clockwise front-facing. These end up cancelling
each other out when drawing full-screen quads, but that's not necessarily true
for other geometry.
2023-10-16 22:36:22 +02: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
Zebediah Figura
e847df9528 tests: Check the result of vkCreateGraphicsPipelines(). 2023-09-13 23:10:46 +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
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
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
Ethan Lee
e541e71532 tests: Remove rtv clears in Vulkan runner.
Signed-off-by: Ethan Lee <flibitijibibo@gmail.com>
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
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
2445743002 tests: Run d3d9 and d3d12 tests on non-cross builds too.
On cross builds, shaders are compiled with d3dcompiler_47.dll and
run with d3dN.dll. On non-cross builds, shaders are compiled with
vkd3d-shader and run with d3dN.dll (on Windows) or Vulkan and vkd3d
(on Linux).
2023-01-24 18:10:17 +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
d2d29d1b88 tests/shader_runner: Create the render pass and framebuffer in vulkan_runner_draw().
Prepare to allow for dynamically changing the bound attachments in consecutive
draw calls.

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:03 +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
e6ea409bbf tests: Move check_readback_data_vec4() to utils.h.
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:16 +02:00
Zebediah Figura
1e8e0650c9 tests/shader_runner: Use the resource_readback structure in the Vulkan shader runner.
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:11 +02:00
Zebediah Figura
beffe5f367 tests: Load libvulkan dynamically in shader_runner_vulkan.c.
We would like to allow overriding the soname of libvulkan, in which case the
tests and demos should respect that override.

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-20 16:41:44 +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
e3f78706ec tests: Introduce a Vulkan 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-04-12 19:00:19 +02:00