I don't think ending up with too many patches is ever a concern.
Okay, I split the patch into several patches, one for each function in spirv.c.
That changes behaviour though; shader_register_normalise_flat_constants() is modifying existing registers, not creating new ones. Arguably it's benign, but I'd still say it's wrong.
I see, I dropped the patch then.
Whether right or wrong, 0 above is VKD3D_DATA_FLOAT. That happens in a couple of other places as well. (I'd argue for "wrong, but largely irrelevant" for most of these; we could fix them up in follow-up patches if we care.)
Yep, in these cases I used zero to preserve the current behavior given by `memset(.,0,.)`, maybe we could also consider removing the `data_type` argument in vsir_register_init() if it is not relevant in many places, and set it up explicitly after initializing the register where needed.
I'd argue for "vsir_dimension_from_sm4()".
Okay, I renamed the function.
However, I have been told that it is better if function names start with a verb, but I guess we are not following that rule much in this part of the code base.