Commit Graph

4666 Commits

Author SHA1 Message Date
Henri Verbeet
23ee29a953 vkd3d-shader/hlsl: Implement constant folding of 'reinterpret' expressions.
As encountered in tests/hlsl/frexp.shader_test.
2025-09-09 14:59:11 +02:00
Henri Verbeet
e330ad2ac7 vkd3d-shader/hlsl: Implement constant folding of 'cos' expressions.
As encountered in tests/hlsl/trigonometry.shader_test.
2025-09-09 14:59:01 +02:00
Henri Verbeet
08e7806b7f vkd3d-shader/hlsl: Implement constant folding of 'sin' expressions.
As encountered in tests/hlsl/trigonometry.shader_test.
2025-09-09 14:51:15 +02:00
Henri Verbeet
d7a05d823c vkd3d-shader/hlsl: Implement constant folding of 'mad' expressions.
As encountered in tests/hlsl/trigonometry.shader_test.
2025-09-09 14:51:15 +02:00
Francisco Casas
7f4a186e6a vkd3d-shader/ir: Use iterators in struct vsir_cfg.
And therefore on the functions that use it, namely
vsir_program_structurize() and
vsir_program_materialize_undominated_ssas_to_temps() and their callees.
2025-09-09 14:51:15 +02:00
Francisco Casas
1aa6c767ea vkd3d-shader/ir: Merge the hull shader phase flattener into a single pass. 2025-09-09 14:50:34 +02:00
Francisco Casas
434d9dd117 vkd3d-shader/ir: Use iterators in flattener_flatten_phases(). 2025-09-09 14:24:06 +02:00
Henri Verbeet
bceb4d17ed vkd3d-shader/ir: Move the instruction array helpers to ir.c. 2025-09-09 14:17:51 +02:00
Francisco Casas
952e706883 vkd3d-shader/ir: Use iterators in control_point_normaliser_emit_hs_input(). 2025-09-09 12:40:06 +02:00
Francisco Casas
500d54d588 vkd3d-shader/ir: Avoid direct instruction array access in validation_error(). 2025-09-09 12:31:12 +02:00
Giovanni Mascellani
05b5a48c1d vkd3d-shader/msl: Reject UAV stores to multi-sampled resources.
Current versions of MSL don't support this, and it doesn't seem likely
that Direct3D source formats do either.
2025-09-09 12:10:44 +02:00
Giovanni Mascellani
26c51f53b7 vkd3d-shader/msl: Access resources as non-multisampled if the sample count is 1. 2025-09-09 12:08:36 +02:00
Henri Verbeet
6607b94ad7 vkd3d-shader/ir: Map 16-bit vsir types to 16-bit component types in vkd3d_component_type_from_data_type().
Mapping these to 32-bit types if needed is supposed to happen in the
frontends now.
2025-09-08 12:34:16 +02:00
Henri Verbeet
38078f2c51 vkd3d-shader/hlsl: Map HLSL_TYPE_HALF to VSIR_DATA_F32.
VSIR_DATA_F16 would require VKD3DSGF_FORCE_NATIVE_LOW_PRECISION, but we
don't currently implement that. vkd3d_component_type_from_data_type()
currently ends up doing this mapping for us in the SPIR-V backend, but
that's about to go away.
2025-09-08 12:34:16 +02:00
Henri Verbeet
ea90f7ae2e vkd3d-shader/dxil: Emit 16-bit indexable temporaries as 32-bit registers.
Unless the "native low precision" flag is enabled.
vkd3d_component_type_from_data_type() currently ends up doing this
mapping for us in the SPIR-V backend, but that's about to go away.
2025-09-08 12:34:16 +02:00
Henri Verbeet
e3118110bf vkd3d-shader/d3d-asm: Print data types for indexable temporary declarations. 2025-09-08 12:34:16 +02:00
Henri Verbeet
7851cbfd3d vkd3d-shader/msl: Do not pretend to support initialisers for indexable temporaries. 2025-09-08 12:33:44 +02:00
Elizabeth Figura
0096ae43e1 vkd3d-shader/hlsl: Remove liveness range tracking from the allocator.
We no longer use it.
2025-09-04 14:04:27 +02:00
Elizabeth Figura
a44d79a13c vkd3d-shader/hlsl: Use a simple counter for indexable temps. 2025-09-04 14:04:27 +02:00
Elizabeth Figura
8db9465693 vkd3d-shader/hlsl: Use unique temps for SINCOS. 2025-09-04 14:04:27 +02:00
Henri Verbeet
5f443593e3 vkd3d-shader/spirv: Use spirv_get_type_id() in spirv_compiler_emit_bool_to_int64(). 2025-09-04 14:03:34 +02:00
Henri Verbeet
441088e4df vkd3d-shader/spirv: Use spirv_get_type_id() in spirv_compiler_emit_bool_to_int(). 2025-09-04 14:03:34 +02:00
Henri Verbeet
b9b883877d vkd3d-shader/spirv: Use spirv_get_type_id() in spirv_compiler_emit_int_to_bool(). 2025-09-04 14:03:34 +02:00
Henri Verbeet
2a71e96a58 vkd3d-shader/spirv: Use spirv_get_type_id() in spirv_compiler_get_descriptor_index(). 2025-09-04 14:03:34 +02:00
Henri Verbeet
0d8acc97a3 vkd3d-shader/spirv: Use spirv_get_type_id() in spirv_compiler_emit_register_addressing(). 2025-09-04 14:03:34 +02:00