https://bugs.winehq.org/show_bug.cgi?id=54832
--- Comment #2 from Ethan Lee flibitijibibo@gmail.com --- Played with this a bit today... long story short, the hlsl_fixme is exactly where it should be (big surprise), but I'm definitely out of my league here as I'm not totally sure what a fix for this would entail. I can see how everything works for IR_CONSTANT offsets, but IR_EXPR and IR_LOAD (or maybe IR_INDEX?) seem to complicate things a _ton_ because without knowing the offset ahead of time, it can't figure out where to load or store anything from, and it doesn't seem like there's an easy way to defer that work to the shader itself. The asm isn't too helpful either:
HLSL:
const int ARRAYBASE_8 = 0; r0.xy = lerp(v1.xy, v1.zw, uniforms_float4[ARRAYBASE_8 + a0.x].xy);
SM4 asm:
add r0.yzw, -v1.yyxy, v1.wwzw mad r1.xy, cb0[r0.x + 0].xyxx, r0.zwzz, v1.xyxx
Like I said though, this is definitely uncharted waters for me, so maybe I'm missing something obvious here.