Commit Graph

2457 Commits

Author SHA1 Message Date
Giovanni Mascellani
a4c727ac40 tests: Mark some tests in calculate-lod.shader_test as buggy on MoltenVK < 1.2.11. 2025-06-04 13:04:53 +02:00
Giovanni Mascellani
c82d1aac4d tests: Mark some tests in arithmetic-int-uniform.shader_test as buggy on MoltenVK < 1.2.11.
The bug is already solved on recent MoltenVK versions, but the CI
is stuck with 1.2.9, so it's useful to filter these failures out.
2025-06-04 13:04:53 +02:00
Henri Verbeet
85d2703c03 tests/shader_runner: Introduce a "tessellation-shader" cap.
Similar to how we have the "geometry-shader" cap. In principle shader
model 5+ implies support for tessellation shaders, but the Vulkan,
OpenGL, and Metal runners are able to support most of shader model 5+
without the underlying GPU (or API) necessarily supporting tessellation
shaders.
2025-06-04 12:10:10 +02:00
Giovanni Mascellani
9f0185f304 vkd3d-shader/msl: Support the ABSNEG source modifier. 2025-06-02 20:36:42 +02:00
Giovanni Mascellani
bc0dd891c3 vkd3d-shader/glsl: Support the ABSNEG source modifier. 2025-06-02 20:35:48 +02:00
Giovanni Mascellani
ed60dd5926 tests: Add a test for the ABSNEG source modifier. 2025-06-02 20:33:13 +02:00
Giovanni Mascellani
215dfe0450 tests/hlsl: Mark some tests in wave-ops-float.shader_test as buggy on MoltenVK.
I haven't investigated the problem, but since the tests work for
other implementations and MoltenVK is not always perfect it's likely
that the problem is there.
2025-06-02 20:22:58 +02:00
Giovanni Mascellani
0b9268a91b tests/hlsl: Mark some tests in geometry.shader_test as buggy on MoltenVK.
They use geometry shaders, which MoltenVK doesn't support. However
D3D12 has no way to indicate they're unsupported, so the problem
doesn't surface as a failed draw, but rather as a draw that doesn't
do anything.
2025-06-02 20:22:43 +02:00
Giovanni Mascellani
ea4f1dece5 tests/hlsl: Mark a test in entry-point-semantics.shader_test as buggy on MoltenVK with DXIL.
It seems that SPIRV-Cross is generating bad MSL code, and Metal
rejects it.
2025-06-02 20:22:35 +02:00
Giovanni Mascellani
c8b07e9fa6 tests/hlsl: Mark a test in register-reservation-resources.shader_test as todo on MoltenVK with DXIL.
I haven't investigated what's happening.
2025-06-02 20:22:22 +02:00
Giovanni Mascellani
898bc5c4c8 tests/hlsl: Mark a test in sm6-uav-rwtexture.shader_test as todo on MoltenVK.
I haven't investigated what's happening.
2025-06-02 20:22:12 +02:00
Giovanni Mascellani
de8dbdc2cb tests/hlsl: Add a test reading from a minimum precision floating-point array. 2025-06-02 20:18:30 +02:00
Giovanni Mascellani
12da0f9d24 tests/hlsl: Add some more minimum precision floating-point tests. 2025-06-02 20:18:21 +02:00
Giovanni Mascellani
308d3aa676 tests/hlsl: Add a test reading from a minimum precision signed integer array. 2025-06-02 20:18:09 +02:00
Giovanni Mascellani
7f7077a156 tests/hlsl: Use the appropriate RTV format in shader-interstage-interface.shader_test. 2025-06-02 20:18:04 +02:00
Giovanni Mascellani
8106c5a199 tests/hlsl: Test the interstage interface for minimum precision types. 2025-06-02 20:17:56 +02:00
Giovanni Mascellani
752b13b111 tests/hlsl: Test sampling with minimum precision floating-point numbers. 2025-06-02 20:17:48 +02:00
Henri Verbeet
9983d9c4de tests/hlsl: Slightly adjust the bias values in the sample-bias tests.
The expected λ value for the tests in question is about 0.59, which
after linear mipmap interpolation should result in a sampled value of
about 0.41. The quantisation step was added to allow results as high as
0.43, as seen on some implementations.

AMD Radeon Pro Vega 20 on macOS 15.5 returns a sampled value of about
0.39, with both Vulkan/MoltenVK and MSL/Metal. This is not an issue with
the bias calculation; the same behaviour could be reproduced with
SampleLevel(), as used in the sample-level tests, if those tests used
more exciting values for the "level" parameter. It also doesn't appear
to be a general Metal issue; Intel UHD Graphics 630 does return the
expected values on the same setup. Instead, this appears to be a mipmap
interpolation issue on this particular GPU/driver. Mapping the sampled
values for "level" from 0.0 to 1.0, it seems the interpolation factor
used is "saturate(frac(λ) * 1.25 - 0.125)", instead of the normal
"frac(λ)".

Fascinating as that may be, the test here mainly cares about whether the
bias value was applied correctly, and in that regard a sampled value of
0.39 isn't any worse than the 0.43 we already accept. This commit
adjusts the bias value so that the expected sampled value is 0.45, which
makes the accepted error the same on both the positive and negative
side.
2025-06-02 20:08:04 +02:00
Shaun Ren
d5dcf31123 vkd3d-shader/hlsl: Store stream index in struct hlsl_semantic.
In addition, support stream indices in tpf_write_signature().
2025-06-02 19:59:22 +02:00
Shaun Ren
d368d18527 vkd3d-shader/hlsl: Generate vsir instructions for indexed output streams in geometry shaders. 2025-06-02 19:53:25 +02:00
Giovanni Mascellani
365f6d3be9 tests/hlsl: Mark some tests in uav-atomics.shader_test as working on MoltenVK. 2025-05-27 19:32:45 +02:00
Giovanni Mascellani
85dcd03642 tests/hlsl: Mark some tests in wave-ops-int.shader_test as buggy on MoltenVK.
It seems that SPIRV-Cross is generating bad MSL code, and Metal
rejects it.
2025-05-27 19:32:35 +02:00
Giovanni Mascellani
9ab1cadaa5 tests/hlsl: Mark some tests in wave-ops-uint.shader_test as buggy on MoltenVK.
It seems that SPIRV-Cross is generating bad MSL code, and Metal
rejects it.
2025-05-27 19:32:19 +02:00
Giovanni Mascellani
6fe0d71ae1 tests/hlsl: Mark a test in gather-offset.shader_test as buggy on MoltenVK with d3d12.
It seems that SPIRV-Cross is generating bad MSL code, and Metal
rejects it.
2025-05-27 19:31:38 +02:00
Giovanni Mascellani
70c51984c9 tests/hlsl: Mark some tests in clip-cull-distance.shader_test as buggy on MoltenVK with d3d12.
They either use geometry shaders or cull distances, which MoltenVK
doesn't support. However d3d12 has no way to indicate they're
unsupported, so the problem doesn't surface as a failed draw,
but rather as a draw that doesn't do anything.
2025-05-27 19:30:21 +02:00