Giovanni Mascellani (@giomasce) commented about libs/vkd3d-shader/vkd3d_shader_private.h:
} flat_constant_count[3]; bool use_vocp;
- /* Whether an extra temp has been allocated for VSIR compilation passes, and its index. */
- bool extra_temp_allocated;
- uint32_t extra_temp;
Why does this need to belong to `shader_desc`? It seems something that could remain inside `instruction_array_lower_texkills()`. Is it meant to be shared with other future passes? For the moment I'd say that any pass that needs a few more TEMPs can just allocate them privately (by incrementing `temp_count`), since it's not obvious that TEMPs can be shared (different passes may interfere on the same TEMP if it is shared). If in the future there is evidence for too many TEMPs being allocated this way then we can look for other solutions (i.e. supporting and using vec4 SSAs, or sharing TEMPs when we know it's safe). Or maybe I'm just missing what's the real intention here.