Commit Graph

2787 Commits

Author SHA1 Message Date
a34cf2e64e vkd3d-shader/hlsl: Split declare_vars().
Basically, declare_vars() is separated in three functions:

1. check_invalid_in_out_modifiers(), which is to be called once per
   declaration and emits an error when in or out modifiers are used for
   these non-parameter variables.

2. declare_var(), which now handles one variable at the time and doesn't
   free any memory.

3. initialize_vars(), which takes care of preparing the initialization
   instructions of several variables and frees their struct
   parse_variable_def, using exclusively free_parse_variable_def().

This allows to declare variables individually before the initializer of
the next variable in the same declaration is parsed, which is used in
the following patches.

Also, simplifies memory management.
2023-07-04 22:39:18 +02:00
e4d94d955c vkd3d-shader/hlsl: Support fine derivates. 2023-07-04 22:39:12 +02:00
ff31284f8d vkd3d-shader/hlsl: Support coarse derivates. 2023-07-04 22:39:10 +02:00
08cece3a92 vkd3d: Print the thread id in trace messages. 2023-06-28 21:40:40 +02:00
de25e88901 vkd3d-shader/dxil: Read and validate global abbreviated operands. 2023-06-28 21:40:37 +02:00
e9a8bfb2c4 vkd3d-shader/dxil: Read and validate local abbreviated operands. 2023-06-28 21:40:36 +02:00
d3e6a3a78f include: Introduce a function to detect the DXBC source type. 2023-06-28 21:40:36 +02:00
6775f7ba66 vkd3d-shader/dxil: Read and validate DXIL bitcode unabbreviated blocks. 2023-06-28 21:40:34 +02:00
69f32796b0 vkd3d-shader: Unify static string arrays initialization pattern. 2023-06-28 21:40:21 +02:00
9ccba35dde vkd3d-shader/hlsl: Store the fields of struct parse_if_body as hlsl_block pointers. 2023-06-28 21:40:18 +02:00
8fa1750206 vkd3d-shader/hlsl: Store the "instrs" field of struct parse_initializer as a hlsl_block pointer. 2023-06-28 21:40:16 +02:00
7d521db3db vkd3d-shader/hlsl: Merge the "discard_statement" rule into "jump_statement". 2023-06-28 21:40:15 +02:00
588784e4dc vkd3d-shader/hlsl: Use add_unary_arithmetic_expr() in the subtraction rule. 2023-06-28 21:40:14 +02:00
b4bf5af475 vkd3d-shader/hlsl: Factor out add_binary_expr_merge(). 2023-06-28 21:40:12 +02:00
bdfec4886d vkd3d-shader/hlsl: Fold logical expressions. 2023-06-27 22:34:33 +02:00
5a05fabe62 vkd3d-shader/hlsl: Fold floating point minimum expressions. 2023-06-27 22:34:30 +02:00
2a2943c2cf vkd3d-shader/hlsl: Fold floating point maximum expressions. 2023-06-27 22:34:29 +02:00
358d656262 vkd3d-shader/hlsl: Fold greater-than-or-equal comparisons. 2023-06-27 22:34:28 +02:00
bf452b5907 vkd3d-shader/hlsl: Fold less-than comparisons. 2023-06-27 22:34:27 +02:00
488af14144 vkd3d-shader/hlsl: Fold equality comparisons. 2023-06-27 22:34:25 +02:00
6c9f6d0fcf vkd3d-shader/hlsl: Sort constant folding helpers alphabetically. 2023-06-27 22:34:24 +02:00
4ed60cda13 vkd3d-shader: Remove extra newlines from compiler messages. 2023-06-27 22:34:19 +02:00
9ccf291971 vkd3d-shader/hlsl: Use profile version testing helpers in more places. 2023-06-27 22:34:05 +02:00
5c02e12187 vkd3d-shader/hlsl: Make sample count optional for SM4.1+.
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
2023-06-27 22:34:03 +02:00
3aa83e877d vkd3d: Append CopyTileMappings() commands to the command queue op array. 2023-06-27 22:33:58 +02:00