[HLSL/Spir-V] fix for incorrect spir-v on int dot(int, int)
Decomposes OpDot into corresponding multiplies and additions.
This commit is contained in:
parent
e3cc0d35f3
commit
b16bea801c
4 changed files with 366 additions and 1 deletions
14
Test/hlsl.int.dot.frag
Normal file
14
Test/hlsl.int.dot.frag
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
float4 main() : SV_Target {
|
||||
int i = 1;
|
||||
int1 i2 = 2;
|
||||
int2 i3 = 3;
|
||||
int3 i4 = 4;
|
||||
int4 i5 = 5;
|
||||
|
||||
i = dot(i, i);
|
||||
i2 = dot(i2, i2);
|
||||
i3 = dot(i3, i3);
|
||||
i4 = dot(i4, i4);
|
||||
i5 = dot(i5, i5);
|
||||
return i + i2.xxxx + i3.xyxy + i4.xyzx + i5;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue