Giovanni Mascellani (@giomasce) commented about libs/vkd3d-shader/hlsl.h:
* 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
struct hlsl_src offset; enum hlsl_regset offset_regset;* stored in the offset_type_backup field. */
- struct hlsl_type *offset_type_backup;
It's fine for me to have this field, but once we decide to have it it would probably make sense to keep it for the whole life of the `struct hlsl_deref`, not just when storing the offset. I don't know if it can be useful before that, but the information it conveys make sense at any time, so by artificially restricting when it is available just makes our life harder. Also, let's just call it `type` or `data_type`.