https://bugs.winehq.org/show_bug.cgi?id=54973
Bug ID: 54973 Summary: Renegade Ops needs literal sample index. Product: vkd3d Version: 1.7 Hardware: x86-64 OS: Linux Status: NEW Severity: normal Priority: P2 Component: hlsl Assignee: wine-bugs@winehq.org Reporter: andrey.goosev@gmail.com Distribution: ---
06c8:err:d3dcompiler:D3DCompile2 Failed to compile shader, vkd3d result -4. 06c8:err:d3dcompiler:D3DCompile2 Shader log: 06c8:err:d3dcompiler:D3DCompile2 <anonymous>:6:243: E5002: Expected literal sample index.
1.7-218-g1af662ae
https://bugs.winehq.org/show_bug.cgi?id=54973
--- Comment #1 from Nikolay Sivov bunglehead@gmail.com --- Could you please attach a shader dump that shows this issue?
https://bugs.winehq.org/show_bug.cgi?id=54973
--- Comment #2 from Andrey Gusev andrey.goosev@gmail.com --- Created attachment 74510 --> https://bugs.winehq.org/attachment.cgi?id=74510 shader dump
https://bugs.winehq.org/show_bug.cgi?id=54973
Nikolay Sivov bunglehead@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Summary|Renegade Ops needs literal |Renegade Ops needs loop |sample index. |unrolling implementation.
--- Comment #3 from Nikolay Sivov bunglehead@gmail.com --- Thanks. I remember now, the real issue here is that loop unrolling is not implemented. When compiling for 4.0 profiles it is required to have literal sample index, which is why we produce this error. Compilation will fail on Windows too, if unrolling is disabled with [loop] attribute. Higher profiles do not have this issue and do accept temp registers.
Unrolling is probably nice to have in general, but in this case it's also a requirement, unless we want to "temporary" hacks to allow instructions that are never normally produced.
Let's make this bug about unrolling.
https://bugs.winehq.org/show_bug.cgi?id=54973
--- Comment #4 from Andrey Gusev andrey.goosev@gmail.com --- Yeah, I see it has '060c:err:d3dcompiler:D3DCompile2 <anonymous>:6:160: W5017: Loop unrolling is not implemented.'
https://bugs.winehq.org/show_bug.cgi?id=54973
--- Comment #5 from Nikolay Sivov bunglehead@gmail.com --- Yes, that comes from [unroll] attribute that we currently ignore. But even without it, and with disabled optimization, or enabled flow control on ps_4_0 I still get it unrolled on Windows.
https://bugs.winehq.org/show_bug.cgi?id=54973
Andrey Gusev andrey.goosev@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Resolution|--- |FIXED Status|NEW |RESOLVED
--- Comment #6 from Andrey Gusev andrey.goosev@gmail.com --- Fixed by https://source.winehq.org/git/vkd3d.git/commit/2034a8bab9acbf3e80d35d597d156...
https://bugs.winehq.org/show_bug.cgi?id=54973
Nikolay Sivov bunglehead@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED
--- Comment #7 from Nikolay Sivov bunglehead@gmail.com --- Closing bugs fixed in 1.13.