mirror of
https://gitlab.winehq.org/wine/vkd3d.git
synced 2024-09-13 09:16:14 -07:00
tests/shader-runner: Add a 'require' directive for wave ops.
This commit is contained in:
parent
9315bcb6a1
commit
29786d7efb
Notes:
Alexandre Julliard
2024-05-02 22:40:21 +02:00
Approved-by: Giovanni Mascellani (@giomasce) Approved-by: Henri Verbeet (@hverbeet) Approved-by: Alexandre Julliard (@julliard) Merge-Request: https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/800
@ -1,5 +1,6 @@
|
||||
[require]
|
||||
shader model >= 6.0
|
||||
wave ops
|
||||
|
||||
[uav 0]
|
||||
format r32g32b32a32 float
|
||||
|
@ -1,5 +1,6 @@
|
||||
[require]
|
||||
shader model >= 6.0
|
||||
wave ops
|
||||
|
||||
[uav 0]
|
||||
format r32g32b32a32 sint
|
||||
|
@ -1,5 +1,6 @@
|
||||
[require]
|
||||
shader model >= 6.0
|
||||
wave ops
|
||||
|
||||
[uav 0]
|
||||
format r32 uint
|
||||
|
@ -339,6 +339,10 @@ static void parse_require_directive(struct shader_runner *runner, const char *li
|
||||
{
|
||||
runner->require_rov = true;
|
||||
}
|
||||
else if (match_string(line, "wave ops", &line))
|
||||
{
|
||||
runner->require_wave_ops = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
fatal_error("Unknown require directive '%s'.\n", line);
|
||||
@ -1545,6 +1549,8 @@ static bool check_requirements(const struct shader_runner *runner, const struct
|
||||
return false;
|
||||
if (runner->require_rov && !caps->rov)
|
||||
return false;
|
||||
if (runner->require_wave_ops && !caps->wave_ops)
|
||||
return false;
|
||||
|
||||
return true;
|
||||
}
|
||||
@ -1838,6 +1844,7 @@ void run_shader_tests(struct shader_runner *runner, const struct shader_runner_c
|
||||
runner->require_float64 = false;
|
||||
runner->require_int64 = false;
|
||||
runner->require_rov = false;
|
||||
runner->require_wave_ops = false;
|
||||
runner->compile_options = 0;
|
||||
skip_tests = false;
|
||||
}
|
||||
|
@ -137,6 +137,7 @@ struct shader_runner_caps
|
||||
bool float64;
|
||||
bool int64;
|
||||
bool rov;
|
||||
bool wave_ops;
|
||||
};
|
||||
|
||||
static inline unsigned int shader_runner_caps_get_feature_flags(const struct shader_runner_caps *caps)
|
||||
@ -169,6 +170,7 @@ struct shader_runner
|
||||
bool require_float64;
|
||||
bool require_int64;
|
||||
bool require_rov;
|
||||
bool require_wave_ops;
|
||||
|
||||
bool last_render_failed;
|
||||
|
||||
|
@ -751,6 +751,7 @@ static void d3d12_runner_init_caps(struct d3d12_shader_runner *runner)
|
||||
runner->caps.float64 = options.DoublePrecisionFloatShaderOps;
|
||||
runner->caps.int64 = options1.Int64ShaderOps;
|
||||
runner->caps.rov = options.ROVsSupported;
|
||||
runner->caps.wave_ops = options1.WaveOps;
|
||||
}
|
||||
|
||||
static bool device_supports_shader_model_6_0(ID3D12Device *device)
|
||||
|
Loading…
Reference in New Issue
Block a user