mirror of
https://gitlab.winehq.org/wine/vkd3d.git
synced 2025-09-12 18:50:22 -07:00
vkd3d-shader/hlsl: Allow derefs to provide the data_type.
After lowering the derefs path to a single offset node, there was no way of knowing the type of the referenced part of the variable. This little modification allows to avoid having to pass the data type everywhere and it is required for supporting instructions that reference objects components within struct types. Since deref->data_type allows us to retrieve the type of the deref, deref->offset_regset is no longer necessary.
This commit is contained in:
committed by
Alexandre Julliard
parent
d4b5e79c8b
commit
ae6bc398d6
Notes:
Alexandre Julliard
2023-07-17 23:25:21 +02:00
Approved-by: Giovanni Mascellani (@giomasce) Approved-by: Zebediah Figura (@zfigura) Approved-by: Henri Verbeet (@hverbeet) Approved-by: Alexandre Julliard (@julliard) Merge-Request: https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/209
@@ -607,9 +607,11 @@ struct hlsl_deref
|
||||
* components, within the pertaining regset), from the start of the variable, of the part
|
||||
* referenced.
|
||||
* The path is lowered to this single offset -- whose value may vary between SM1 and SM4 --
|
||||
* before writing the bytecode. */
|
||||
* before writing the bytecode.
|
||||
* Since the type information cannot longer be retrieved from the offset alone, the type is
|
||||
* stored in the data_type field. */
|
||||
struct hlsl_src offset;
|
||||
enum hlsl_regset offset_regset;
|
||||
struct hlsl_type *data_type;
|
||||
};
|
||||
|
||||
struct hlsl_ir_load
|
||||
|
||||
Reference in New Issue
Block a user