Giovanni Mascellani
3ab68c1e46
vkd3d-shader/ir: Validate indices for RESOURCE registers.
2024-10-03 19:08:33 +02:00
Giovanni Mascellani
ab23038367
vkd3d-shader/ir: Validate indices for SAMPLER registers.
2024-10-03 19:08:33 +02:00
Giovanni Mascellani
7e9dc8da97
vkd3d-shader/ir: Validate index count for MISCTYPE registers.
2024-10-02 22:12:47 +02:00
Giovanni Mascellani
99aebb1b31
vkd3d-shader/ir: Validate index count for RASTOUT registers.
2024-10-02 22:12:47 +02:00
Giovanni Mascellani
19d35d89cd
vkd3d-shader/ir: Validate index count for DEPTHOUTLE registers.
2024-10-02 22:12:47 +02:00
Giovanni Mascellani
6259832680
vkd3d-shader/ir: Validate index count for DEPTHOUTGE registers.
2024-10-02 22:12:47 +02:00
Giovanni Mascellani
c3757e6930
vkd3d-shader/ir: Validate index count for DEPTHOUT registers.
2024-10-02 22:12:47 +02:00
Elizabeth Figura
4400315c4b
vkd3d-shader: Allow controlling clip planes through vkd3d-shader parameters.
2024-10-02 21:49:54 +02:00
Elizabeth Figura
85b8503995
vkd3d-shader/ir: Remove newlines from some vkd3d_shader_error() calls.
2024-10-02 21:49:54 +02:00
Giovanni Mascellani
5c2b057b56
vkd3d-shader/ir: Validate UAV registers.
2024-09-30 20:05:52 +02:00
Giovanni Mascellani
b7b5b0cff8
vkd3d-shader/ir: Validate RESOURCE registers.
2024-09-30 20:05:52 +02:00
Giovanni Mascellani
a0b98c1610
vkd3d-shader/ir: Validate SAMPLER registers.
2024-09-30 20:05:52 +02:00
Giovanni Mascellani
828e5f1249
vkd3d-shader/ir: Disallow RESOURCE registers in destination parameters.
2024-09-26 17:44:52 +02:00
Giovanni Mascellani
674ad7d655
vkd3d-shader/ir: Disallow SAMPLER registers in destination parameters.
2024-09-26 17:44:52 +02:00
Giovanni Mascellani
6de741e5e7
vkd3d-shader/ir: Do not allow NULL registers in source parameters.
2024-09-26 17:44:52 +02:00
Giovanni Mascellani
8d85ea2dc5
vkd3d-shader: Get rid of the RESOURCE data type.
2024-09-26 17:42:16 +02:00
Giovanni Mascellani
2934f820a9
vkd3d-shader: Get rid of the SAMPLER data type.
2024-09-26 17:42:16 +02:00
Henri Verbeet
f37be27bdc
vkd3d-shader/ir: Properly check the register bounds in shader_signature_find_element_for_reg().
...
Perhaps the existing code is safe in practice, but doing the check
properly avoids having to make that determination.
2024-09-24 13:39:43 +02:00
Giovanni Mascellani
637a3cabe7
vkd3d-shader/ir: Allow failure in shader_signature_find_element_for_reg().
...
shader_signature_find_element_for_reg() is also used in the TPF parser,
where the program has not been validated yet, so it must not crash
on errors.
The I/O normaliser can instead assume that the shader is already
validated.
This fixes a crash with a shader used by The Falconeer. The bug is still
present, because the shader will be incorrectly rejected, but at least
the vkd3d-shader will fail gracefully.
2024-09-20 17:01:29 +02:00
Giovanni Mascellani
56ec211d04
vkd3d-shader/ir: Introduce a helper for validating Hull Shader phases.
2024-09-16 19:32:32 +02:00
Giovanni Mascellani
259273a133
vkd3d-shader/ir: Introduce a helper for validating DCL_TESSELLATOR_PARTITIONING.
2024-09-16 19:32:32 +02:00
Giovanni Mascellani
a3c7bebc18
vkd3d-shader/ir: Introduce a helper for validating DCL_TESSELLATOR_OUTPUT_PRIMITIVE.
2024-09-16 19:32:32 +02:00
Giovanni Mascellani
48f512a83a
vkd3d-shader/ir: Introduce a helper for validating DCL_TESSELLATOR_DOMAIN.
2024-09-16 19:32:32 +02:00
Giovanni Mascellani
8aa2364381
vkd3d-shader/ir: Introduce a helper for validating DCL_OUTPUT_CONTROL_POINT_COUNT.
2024-09-16 19:32:32 +02:00
Giovanni Mascellani
c45bb5badc
vkd3d-shader/ir: Introduce a helper for validating DCL_GL_INSTANCES.
2024-09-16 13:53:52 +02:00
Giovanni Mascellani
dec7a0dbd2
vkd3d-shader/ir: Introduce a helper for validating DCL_OUTPUT_TOPOLOGY.
2024-09-16 13:53:52 +02:00
Giovanni Mascellani
22ba37c8b9
vkd3d-shader/ir: Introduce a helper for validating DCL_VERTICES_OUT.
2024-09-16 13:53:51 +02:00
Giovanni Mascellani
936adff58b
vkd3d-shader/ir: Introduce a helper for validating DCL_INPUT_PRIMITIVE.
2024-09-16 13:53:51 +02:00
Giovanni Mascellani
0f07a2c512
vkd3d-shader/ir: Introduce a helper for validating DCL_HS_MAX_TESSFACTOR.
2024-09-16 13:53:51 +02:00
Giovanni Mascellani
e1c3266793
vkd3d-shader/ir: Record entering a block in the LABEL validation handler.
2024-09-16 13:53:51 +02:00
Giovanni Mascellani
1d21588de7
vkd3d-shader/ir: Record leaving a block in the relevant validation handlers.
2024-09-16 13:53:51 +02:00
Giovanni Mascellani
3e012c355d
vkd3d-shader/ir: Validate NOP instructions.
2024-09-14 16:44:17 +02:00
Giovanni Mascellani
27b421be6a
vkd3d-shader/ir: Do not access a missing destination register when validating PHI.
2024-09-14 16:44:17 +02:00
Giovanni Mascellani
e27cf68173
vkd3d-shader/ir: Introduce a helper for validating PHI.
2024-09-14 16:44:16 +02:00
Giovanni Mascellani
9696a0cd4a
vkd3d-shader/ir: Introduce a helper for validating SWITCH_MONOLITHIC.
2024-09-14 16:44:16 +02:00
Giovanni Mascellani
ce6306c6fb
vkd3d-shader/ir: Introduce a helper for validating BRANCH.
2024-09-14 16:44:16 +02:00
Giovanni Mascellani
504f4223c2
vkd3d-shader/ir: Introduce a helper for validating LABEL.
2024-09-14 16:44:16 +02:00
Giovanni Mascellani
c447a062c4
vkd3d-shader/ir: Introduce a helper for validating RET.
2024-09-14 16:44:16 +02:00
Giovanni Mascellani
88b3d4fb3a
vkd3d-shader/ir: Introduce a helper for validating ENDSWITCH.
2024-09-14 16:44:16 +02:00
Giovanni Mascellani
4939f580a4
vkd3d-shader/ir: Introduce a helper for validating SWITCH.
2024-09-14 16:44:16 +02:00
Henri Verbeet
6b0baeb6c2
vkd3d-shader/ir: Merge vsir_program_normalise_combined_samplers() into vsir_program_lower_instructions().
2024-09-14 16:11:45 +02:00
Henri Verbeet
3b68aa5b87
vkd3d-shader/ir: Introduce vsir_src_param_init_sampler().
2024-09-14 16:11:45 +02:00
Henri Verbeet
7ea8a29036
vkd3d-shader/ir: Introduce vsir_src_param_init_resource().
2024-09-14 16:11:45 +02:00
Henri Verbeet
ca445cd832
vkd3d-shader/ir: Move the instruction helpers together.
2024-09-14 16:11:45 +02:00
Henri Verbeet
d54e2ebd7d
vkd3d-shader/ir: Move the destination parameter helpers up.
2024-09-14 16:11:45 +02:00
Henri Verbeet
4bad83c9fb
vkd3d-shader/ir: Move the source parameter helpers up.
2024-09-14 16:11:45 +02:00
Giovanni Mascellani
44222ea739
vkd3d-shader/ir: Introduce a helper for validating ENDREP.
2024-09-13 15:59:49 +02:00
Giovanni Mascellani
e9fbbf26bb
vkd3d-shader/ir: Introduce a helper for validating REP.
2024-09-13 15:59:15 +02:00
Giovanni Mascellani
bf9022d3df
vkd3d-shader/ir: Introduce a helper for validating ENDLOOP.
2024-09-13 15:58:46 +02:00
Giovanni Mascellani
5ce10b9e68
vkd3d-shader/ir: Introduce a helper for validating LOOP.
2024-09-13 15:58:01 +02:00