Open FoggyMist opened 3 months ago
No repro if -spirv
removed from compiler args.
No repro if
-spirv
removed from compiler args.
What do you mean?
-spirv
? => You cannot reproduce the compilation failure? It works fine for DXIL, I have mentioned as a possible clue, not a prerequisite. Sorry if it was confusing, I will update the description.-spirv
? => You cannot reproduce what I have noted?Anyway, it would be nice to be able to compile with the flag.
I think he is just doing triage, to see who will need to look at it. If it is only an issue with targeting spir-v, then it will be directed to some on my team. We will take a look at it at some point.
Description I am unable to use out-of-line initialized static member of a structure. Possibly related issues: https://github.com/microsoft/DirectXShaderCompiler/issues/5563 and https://github.com/microsoft/DirectXShaderCompiler/issues/5916
Steps to Reproduce Following code does not compile (https://godbolt.org/z/xza9oobrf):
Actual Behavior
Val at the end of first line is added in DXC 1.8.x, it is not present in older versions.
Environment
dxcompiler.dll: 1.8 - 1.8.2403.37 (11e1318c3); dxil.dll: 1.8(101.8.2403.24)
Additional notes Doing any of the following makes the code compile:
-spirv
compilation flag;+ Bonus()
from line 6;+ Val
from line 6;Val
to inline (remove line 10, change line 5 tostatic const uint Val = 3;
.