HLSL: Add shape conversions for scalar -> vector assigments.
Also, this allows turning on the error check for a failed assigment when parsing. This makes 39 HLSL tests have a working assignment that was previously silently dropped, due to lack of this functionality.
This commit is contained in:
@@ -95,6 +95,16 @@ gl_FragCoord origin is upper left
|
||||
0:? Constant:
|
||||
0:? 2 (const int)
|
||||
0:? 3 (const int)
|
||||
0:62 move second child to first child (temp 4-component vector of float)
|
||||
0:62 Color: direct index for structure (temp 4-component vector of float)
|
||||
0:62 'psout' (temp structure{temp 4-component vector of float Color, temp float FragDepth Depth})
|
||||
0:62 Constant:
|
||||
0:62 0 (const int)
|
||||
0:62 Constant:
|
||||
0:62 1.000000
|
||||
0:62 1.000000
|
||||
0:62 1.000000
|
||||
0:62 1.000000
|
||||
0:63 move second child to first child (temp float)
|
||||
0:63 Depth: direct index for structure (temp float FragDepth)
|
||||
0:63 'psout' (temp structure{temp 4-component vector of float Color, temp float FragDepth Depth})
|
||||
@@ -228,6 +238,16 @@ gl_FragCoord origin is upper left
|
||||
0:? Constant:
|
||||
0:? 2 (const int)
|
||||
0:? 3 (const int)
|
||||
0:62 move second child to first child (temp 4-component vector of float)
|
||||
0:62 Color: direct index for structure (temp 4-component vector of float)
|
||||
0:62 'psout' (temp structure{temp 4-component vector of float Color, temp float FragDepth Depth})
|
||||
0:62 Constant:
|
||||
0:62 0 (const int)
|
||||
0:62 Constant:
|
||||
0:62 1.000000
|
||||
0:62 1.000000
|
||||
0:62 1.000000
|
||||
0:62 1.000000
|
||||
0:63 move second child to first child (temp float)
|
||||
0:63 Depth: direct index for structure (temp float FragDepth)
|
||||
0:63 'psout' (temp structure{temp 4-component vector of float Color, temp float FragDepth Depth})
|
||||
@@ -263,7 +283,7 @@ gl_FragCoord origin is upper left
|
||||
|
||||
// Module Version 10000
|
||||
// Generated by (magic number): 80001
|
||||
// Id's are bound by 145
|
||||
// Id's are bound by 149
|
||||
|
||||
Capability Shader
|
||||
Capability Sampled1D
|
||||
@@ -291,21 +311,21 @@ gl_FragCoord origin is upper left
|
||||
MemberName 92(PS_OUTPUT) 0 "Color"
|
||||
MemberName 92(PS_OUTPUT) 1 "Depth"
|
||||
Name 94 "psout"
|
||||
Name 102 "g_tTex3df4"
|
||||
Name 105 "g_tTex3di4"
|
||||
Name 108 "g_tTex3du4"
|
||||
Name 111 "g_tTexcdf4"
|
||||
Name 114 "g_tTexcdi4"
|
||||
Name 117 "g_tTexcdu4"
|
||||
Name 120 "g_tTex1df4a"
|
||||
Name 123 "g_tTex1di4a"
|
||||
Name 126 "g_tTex1du4a"
|
||||
Name 129 "g_tTex2df4a"
|
||||
Name 132 "g_tTex2di4a"
|
||||
Name 135 "g_tTex2du4a"
|
||||
Name 138 "g_tTexcdf4a"
|
||||
Name 141 "g_tTexcdi4a"
|
||||
Name 144 "g_tTexcdu4a"
|
||||
Name 106 "g_tTex3df4"
|
||||
Name 109 "g_tTex3di4"
|
||||
Name 112 "g_tTex3du4"
|
||||
Name 115 "g_tTexcdf4"
|
||||
Name 118 "g_tTexcdi4"
|
||||
Name 121 "g_tTexcdu4"
|
||||
Name 124 "g_tTex1df4a"
|
||||
Name 127 "g_tTex1di4a"
|
||||
Name 130 "g_tTex1du4a"
|
||||
Name 133 "g_tTex2df4a"
|
||||
Name 136 "g_tTex2di4a"
|
||||
Name 139 "g_tTex2du4a"
|
||||
Name 142 "g_tTexcdf4a"
|
||||
Name 145 "g_tTexcdi4a"
|
||||
Name 148 "g_tTexcdu4a"
|
||||
Decorate 11(g_tTex1df4) DescriptorSet 0
|
||||
Decorate 15(g_sSamp) DescriptorSet 0
|
||||
Decorate 29(g_tTex1di4) DescriptorSet 0
|
||||
@@ -314,21 +334,21 @@ gl_FragCoord origin is upper left
|
||||
Decorate 70(g_tTex2di4) DescriptorSet 0
|
||||
Decorate 82(g_tTex2du4) DescriptorSet 0
|
||||
MemberDecorate 92(PS_OUTPUT) 1 BuiltIn FragDepth
|
||||
Decorate 102(g_tTex3df4) DescriptorSet 0
|
||||
Decorate 105(g_tTex3di4) DescriptorSet 0
|
||||
Decorate 108(g_tTex3du4) DescriptorSet 0
|
||||
Decorate 111(g_tTexcdf4) DescriptorSet 0
|
||||
Decorate 114(g_tTexcdi4) DescriptorSet 0
|
||||
Decorate 117(g_tTexcdu4) DescriptorSet 0
|
||||
Decorate 120(g_tTex1df4a) DescriptorSet 0
|
||||
Decorate 123(g_tTex1di4a) DescriptorSet 0
|
||||
Decorate 126(g_tTex1du4a) DescriptorSet 0
|
||||
Decorate 129(g_tTex2df4a) DescriptorSet 0
|
||||
Decorate 132(g_tTex2di4a) DescriptorSet 0
|
||||
Decorate 135(g_tTex2du4a) DescriptorSet 0
|
||||
Decorate 138(g_tTexcdf4a) DescriptorSet 0
|
||||
Decorate 141(g_tTexcdi4a) DescriptorSet 0
|
||||
Decorate 144(g_tTexcdu4a) DescriptorSet 0
|
||||
Decorate 106(g_tTex3df4) DescriptorSet 0
|
||||
Decorate 109(g_tTex3di4) DescriptorSet 0
|
||||
Decorate 112(g_tTex3du4) DescriptorSet 0
|
||||
Decorate 115(g_tTexcdf4) DescriptorSet 0
|
||||
Decorate 118(g_tTexcdi4) DescriptorSet 0
|
||||
Decorate 121(g_tTexcdu4) DescriptorSet 0
|
||||
Decorate 124(g_tTex1df4a) DescriptorSet 0
|
||||
Decorate 127(g_tTex1di4a) DescriptorSet 0
|
||||
Decorate 130(g_tTex1du4a) DescriptorSet 0
|
||||
Decorate 133(g_tTex2df4a) DescriptorSet 0
|
||||
Decorate 136(g_tTex2di4a) DescriptorSet 0
|
||||
Decorate 139(g_tTex2du4a) DescriptorSet 0
|
||||
Decorate 142(g_tTexcdf4a) DescriptorSet 0
|
||||
Decorate 145(g_tTexcdi4a) DescriptorSet 0
|
||||
Decorate 148(g_tTexcdu4a) DescriptorSet 0
|
||||
2: TypeVoid
|
||||
3: TypeFunction 2
|
||||
6: TypeFloat 32
|
||||
@@ -380,53 +400,56 @@ gl_FragCoord origin is upper left
|
||||
91: TypeVector 6(float) 4
|
||||
92(PS_OUTPUT): TypeStruct 91(fvec4) 6(float)
|
||||
93: TypePointer Function 92(PS_OUTPUT)
|
||||
95: 22(int) Constant 1
|
||||
95: 22(int) Constant 0
|
||||
96: 6(float) Constant 1065353216
|
||||
100: TypeImage 6(float) 3D sampled format:Unknown
|
||||
101: TypePointer UniformConstant 100
|
||||
102(g_tTex3df4): 101(ptr) Variable UniformConstant
|
||||
103: TypeImage 22(int) 3D sampled format:Unknown
|
||||
104: TypePointer UniformConstant 103
|
||||
105(g_tTex3di4): 104(ptr) Variable UniformConstant
|
||||
106: TypeImage 38(int) 3D sampled format:Unknown
|
||||
107: TypePointer UniformConstant 106
|
||||
108(g_tTex3du4): 107(ptr) Variable UniformConstant
|
||||
109: TypeImage 6(float) Cube sampled format:Unknown
|
||||
110: TypePointer UniformConstant 109
|
||||
111(g_tTexcdf4): 110(ptr) Variable UniformConstant
|
||||
112: TypeImage 22(int) Cube sampled format:Unknown
|
||||
113: TypePointer UniformConstant 112
|
||||
114(g_tTexcdi4): 113(ptr) Variable UniformConstant
|
||||
115: TypeImage 38(int) Cube sampled format:Unknown
|
||||
116: TypePointer UniformConstant 115
|
||||
117(g_tTexcdu4): 116(ptr) Variable UniformConstant
|
||||
118: TypeImage 6(float) 1D array sampled format:Unknown
|
||||
119: TypePointer UniformConstant 118
|
||||
120(g_tTex1df4a): 119(ptr) Variable UniformConstant
|
||||
121: TypeImage 22(int) 1D array sampled format:Unknown
|
||||
122: TypePointer UniformConstant 121
|
||||
123(g_tTex1di4a): 122(ptr) Variable UniformConstant
|
||||
124: TypeImage 38(int) 1D array sampled format:Unknown
|
||||
125: TypePointer UniformConstant 124
|
||||
126(g_tTex1du4a): 125(ptr) Variable UniformConstant
|
||||
127: TypeImage 6(float) 2D array sampled format:Unknown
|
||||
128: TypePointer UniformConstant 127
|
||||
129(g_tTex2df4a): 128(ptr) Variable UniformConstant
|
||||
130: TypeImage 22(int) 2D array sampled format:Unknown
|
||||
131: TypePointer UniformConstant 130
|
||||
132(g_tTex2di4a): 131(ptr) Variable UniformConstant
|
||||
133: TypeImage 38(int) 2D array sampled format:Unknown
|
||||
134: TypePointer UniformConstant 133
|
||||
135(g_tTex2du4a): 134(ptr) Variable UniformConstant
|
||||
136: TypeImage 6(float) Cube array sampled format:Unknown
|
||||
137: TypePointer UniformConstant 136
|
||||
138(g_tTexcdf4a): 137(ptr) Variable UniformConstant
|
||||
139: TypeImage 22(int) Cube array sampled format:Unknown
|
||||
140: TypePointer UniformConstant 139
|
||||
141(g_tTexcdi4a): 140(ptr) Variable UniformConstant
|
||||
142: TypeImage 38(int) Cube array sampled format:Unknown
|
||||
143: TypePointer UniformConstant 142
|
||||
144(g_tTexcdu4a): 143(ptr) Variable UniformConstant
|
||||
97: 91(fvec4) ConstantComposite 96 96 96 96
|
||||
98: TypePointer Function 91(fvec4)
|
||||
100: 22(int) Constant 1
|
||||
104: TypeImage 6(float) 3D sampled format:Unknown
|
||||
105: TypePointer UniformConstant 104
|
||||
106(g_tTex3df4): 105(ptr) Variable UniformConstant
|
||||
107: TypeImage 22(int) 3D sampled format:Unknown
|
||||
108: TypePointer UniformConstant 107
|
||||
109(g_tTex3di4): 108(ptr) Variable UniformConstant
|
||||
110: TypeImage 38(int) 3D sampled format:Unknown
|
||||
111: TypePointer UniformConstant 110
|
||||
112(g_tTex3du4): 111(ptr) Variable UniformConstant
|
||||
113: TypeImage 6(float) Cube sampled format:Unknown
|
||||
114: TypePointer UniformConstant 113
|
||||
115(g_tTexcdf4): 114(ptr) Variable UniformConstant
|
||||
116: TypeImage 22(int) Cube sampled format:Unknown
|
||||
117: TypePointer UniformConstant 116
|
||||
118(g_tTexcdi4): 117(ptr) Variable UniformConstant
|
||||
119: TypeImage 38(int) Cube sampled format:Unknown
|
||||
120: TypePointer UniformConstant 119
|
||||
121(g_tTexcdu4): 120(ptr) Variable UniformConstant
|
||||
122: TypeImage 6(float) 1D array sampled format:Unknown
|
||||
123: TypePointer UniformConstant 122
|
||||
124(g_tTex1df4a): 123(ptr) Variable UniformConstant
|
||||
125: TypeImage 22(int) 1D array sampled format:Unknown
|
||||
126: TypePointer UniformConstant 125
|
||||
127(g_tTex1di4a): 126(ptr) Variable UniformConstant
|
||||
128: TypeImage 38(int) 1D array sampled format:Unknown
|
||||
129: TypePointer UniformConstant 128
|
||||
130(g_tTex1du4a): 129(ptr) Variable UniformConstant
|
||||
131: TypeImage 6(float) 2D array sampled format:Unknown
|
||||
132: TypePointer UniformConstant 131
|
||||
133(g_tTex2df4a): 132(ptr) Variable UniformConstant
|
||||
134: TypeImage 22(int) 2D array sampled format:Unknown
|
||||
135: TypePointer UniformConstant 134
|
||||
136(g_tTex2di4a): 135(ptr) Variable UniformConstant
|
||||
137: TypeImage 38(int) 2D array sampled format:Unknown
|
||||
138: TypePointer UniformConstant 137
|
||||
139(g_tTex2du4a): 138(ptr) Variable UniformConstant
|
||||
140: TypeImage 6(float) Cube array sampled format:Unknown
|
||||
141: TypePointer UniformConstant 140
|
||||
142(g_tTexcdf4a): 141(ptr) Variable UniformConstant
|
||||
143: TypeImage 22(int) Cube array sampled format:Unknown
|
||||
144: TypePointer UniformConstant 143
|
||||
145(g_tTexcdi4a): 144(ptr) Variable UniformConstant
|
||||
146: TypeImage 38(int) Cube array sampled format:Unknown
|
||||
147: TypePointer UniformConstant 146
|
||||
148(g_tTexcdu4a): 147(ptr) Variable UniformConstant
|
||||
4(main): 2 Function None 3
|
||||
5: Label
|
||||
8(r01): 7(ptr) Variable Function
|
||||
@@ -475,8 +498,10 @@ gl_FragCoord origin is upper left
|
||||
89: 6(float) CompositeExtract 88 0
|
||||
90: 6(float) ImageSampleDrefImplicitLod 87 88 89 ConstOffset 64
|
||||
Store 79(r25) 90
|
||||
97: 7(ptr) AccessChain 94(psout) 95
|
||||
Store 97 96
|
||||
98:92(PS_OUTPUT) Load 94(psout)
|
||||
ReturnValue 98
|
||||
99: 98(ptr) AccessChain 94(psout) 95
|
||||
Store 99 97
|
||||
101: 7(ptr) AccessChain 94(psout) 100
|
||||
Store 101 96
|
||||
102:92(PS_OUTPUT) Load 94(psout)
|
||||
ReturnValue 102
|
||||
FunctionEnd
|
||||
|
||||
Reference in New Issue
Block a user