vkd3d-shader/hlsl: Add documentation to struct hlsl_reg.

This commit is contained in:
Francisco Casas 2022-11-16 00:07:03 -03:00 committed by Alexandre Julliard
parent aab9886021
commit f33d433621
Notes: Alexandre Julliard 2023-01-19 22:45:24 +01: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/61

View File

@ -210,10 +210,18 @@ struct hlsl_struct_field
size_t name_bytecode_offset;
};
/* Information of the register allocated for an instruction node or variable.
* These values are initialized at the end of hlsl_emit_bytecode(), after the compilation passes,
* just before writing the bytecode.
* For numeric registers, a writemask can be provided to indicate the reservation of only some of the
* 4 components.
* The type of register (register class) is implied from its use, so it is not stored in this
* struct. */
struct hlsl_reg
{
uint32_t id;
unsigned int writemask;
/* Whether the register has been allocated. */
bool allocated;
};
@ -553,6 +561,7 @@ struct hlsl_ir_constant
float f;
double d;
} value[4];
/* Constant register of type 'c' where the constant value is stored for SM1. */
struct hlsl_reg reg;
};