Description
Reported on the DirectX Discord server, compiling any SM6.10 shader that uses TriangleObjectPositions() with optimizations disabled fails validation.
Steps to Reproduce
https://godbolt.org/z/4vKWzv6df
Actual Behavior
%8 = insertvalue %struct.BuiltInTrianglePositions undef, <3 x float> %7, 0, !dbg !66
The insertvalue instruction isn't valid LLVM IR. With optimizations disabled, a struct is constructed one field at a time, and then values are re-extracted. With optimizations enabled, the struct disappears entirely.
Environment
- dxc(private) 1.9.0.10001 (main, a613cf9)
Description
Reported on the DirectX Discord server, compiling any SM6.10 shader that uses
TriangleObjectPositions()with optimizations disabled fails validation.Steps to Reproduce
https://godbolt.org/z/4vKWzv6df
Actual Behavior
The
insertvalueinstruction isn't valid LLVM IR. With optimizations disabled, a struct is constructed one field at a time, and then values are re-extracted. With optimizations enabled, the struct disappears entirely.Environment