
This PR adds a CreateParseContext() fn analogous to CreateBuiltInParseables(), to create a language specific built in parser. (This code was present before but not encapsualted in a fn). This can now be used to create a source language specific parser for builtins. Along with this, the code creating HLSL intrinsic prototypes can now produce them in HLSL syntax, rather than GLSL syntax. This relaxes certain prior restrictions at the parser level. Lower layers (e.g, SPIR-V) may still have such restrictions, such as around Nx1 matrices: this code does not impact that. This PR also fleshes out matrix types for bools and ints, both of which were partially in place before. This was easier than maintaining the restrictions in the HLSL prototype generator to avoid creating protoypes with those types. Many tests change because the result type from intrinsics moves from "global" to "temp". Several new tests are added for the new types.
134 lines
5.6 KiB
Plaintext
134 lines
5.6 KiB
Plaintext
hlsl.getsampleposition.dx10.frag
|
|
ERROR: 0:16: '' : unimplemented: GetSamplePosition
|
|
ERROR: 0:17: '' : unimplemented: GetSamplePosition
|
|
ERROR: 2 compilation errors. No code generated.
|
|
|
|
|
|
Shader version: 450
|
|
gl_FragCoord origin is upper left
|
|
ERROR: node is still EOpNull!
|
|
0:13 Function Definition: main( (temp structure{temp 4-component vector of float Color, temp float Depth})
|
|
0:13 Function Parameters:
|
|
0:? Sequence
|
|
0:16 Sequence
|
|
0:16 move second child to first child (temp 2-component vector of float)
|
|
0:16 'r00' (temp 2-component vector of float)
|
|
0:16 ERROR: Bad aggregation op
|
|
(temp 2-component vector of float)
|
|
0:16 'g_tTex2dmsf4' (uniform texture2DMS)
|
|
0:16 Constant:
|
|
0:16 1 (const int)
|
|
0:17 Sequence
|
|
0:17 move second child to first child (temp 2-component vector of float)
|
|
0:17 'r01' (temp 2-component vector of float)
|
|
0:17 ERROR: Bad aggregation op
|
|
(temp 2-component vector of float)
|
|
0:17 'g_tTex2dmsf4a' (uniform texture2DMSArray)
|
|
0:17 Constant:
|
|
0:17 2 (const int)
|
|
0:19 move second child to first child (temp 4-component vector of float)
|
|
0:19 Color: direct index for structure (temp 4-component vector of float)
|
|
0:19 'psout' (temp structure{temp 4-component vector of float Color, temp float Depth})
|
|
0:19 Constant:
|
|
0:19 0 (const int)
|
|
0:19 Constant:
|
|
0:19 1.000000
|
|
0:19 1.000000
|
|
0:19 1.000000
|
|
0:19 1.000000
|
|
0:20 move second child to first child (temp float)
|
|
0:20 Depth: direct index for structure (temp float)
|
|
0:20 'psout' (temp structure{temp 4-component vector of float Color, temp float Depth})
|
|
0:20 Constant:
|
|
0:20 1 (const int)
|
|
0:20 Constant:
|
|
0:20 1.000000
|
|
0:22 Sequence
|
|
0:22 Sequence
|
|
0:22 move second child to first child (temp 4-component vector of float)
|
|
0:? 'Color' (layout(location=0 ) out 4-component vector of float)
|
|
0:22 Color: direct index for structure (temp 4-component vector of float)
|
|
0:22 'psout' (temp structure{temp 4-component vector of float Color, temp float Depth})
|
|
0:22 Constant:
|
|
0:22 0 (const int)
|
|
0:22 move second child to first child (temp float)
|
|
0:? 'Depth' (out float FragDepth)
|
|
0:22 Depth: direct index for structure (temp float)
|
|
0:22 'psout' (temp structure{temp 4-component vector of float Color, temp float Depth})
|
|
0:22 Constant:
|
|
0:22 1 (const int)
|
|
0:22 Branch: Return
|
|
0:? Linker Objects
|
|
0:? 'Color' (layout(location=0 ) out 4-component vector of float)
|
|
0:? 'Depth' (out float FragDepth)
|
|
0:? 'g_sSamp' (layout(binding=0 ) uniform sampler)
|
|
0:? 'g_tTex2dmsf4' (uniform texture2DMS)
|
|
0:? 'g_tTex2dmsf4a' (uniform texture2DMSArray)
|
|
|
|
|
|
Linked fragment stage:
|
|
|
|
|
|
Shader version: 450
|
|
gl_FragCoord origin is upper left
|
|
ERROR: node is still EOpNull!
|
|
0:13 Function Definition: main( (temp structure{temp 4-component vector of float Color, temp float Depth})
|
|
0:13 Function Parameters:
|
|
0:? Sequence
|
|
0:16 Sequence
|
|
0:16 move second child to first child (temp 2-component vector of float)
|
|
0:16 'r00' (temp 2-component vector of float)
|
|
0:16 ERROR: Bad aggregation op
|
|
(temp 2-component vector of float)
|
|
0:16 'g_tTex2dmsf4' (uniform texture2DMS)
|
|
0:16 Constant:
|
|
0:16 1 (const int)
|
|
0:17 Sequence
|
|
0:17 move second child to first child (temp 2-component vector of float)
|
|
0:17 'r01' (temp 2-component vector of float)
|
|
0:17 ERROR: Bad aggregation op
|
|
(temp 2-component vector of float)
|
|
0:17 'g_tTex2dmsf4a' (uniform texture2DMSArray)
|
|
0:17 Constant:
|
|
0:17 2 (const int)
|
|
0:19 move second child to first child (temp 4-component vector of float)
|
|
0:19 Color: direct index for structure (temp 4-component vector of float)
|
|
0:19 'psout' (temp structure{temp 4-component vector of float Color, temp float Depth})
|
|
0:19 Constant:
|
|
0:19 0 (const int)
|
|
0:19 Constant:
|
|
0:19 1.000000
|
|
0:19 1.000000
|
|
0:19 1.000000
|
|
0:19 1.000000
|
|
0:20 move second child to first child (temp float)
|
|
0:20 Depth: direct index for structure (temp float)
|
|
0:20 'psout' (temp structure{temp 4-component vector of float Color, temp float Depth})
|
|
0:20 Constant:
|
|
0:20 1 (const int)
|
|
0:20 Constant:
|
|
0:20 1.000000
|
|
0:22 Sequence
|
|
0:22 Sequence
|
|
0:22 move second child to first child (temp 4-component vector of float)
|
|
0:? 'Color' (layout(location=0 ) out 4-component vector of float)
|
|
0:22 Color: direct index for structure (temp 4-component vector of float)
|
|
0:22 'psout' (temp structure{temp 4-component vector of float Color, temp float Depth})
|
|
0:22 Constant:
|
|
0:22 0 (const int)
|
|
0:22 move second child to first child (temp float)
|
|
0:? 'Depth' (out float FragDepth)
|
|
0:22 Depth: direct index for structure (temp float)
|
|
0:22 'psout' (temp structure{temp 4-component vector of float Color, temp float Depth})
|
|
0:22 Constant:
|
|
0:22 1 (const int)
|
|
0:22 Branch: Return
|
|
0:? Linker Objects
|
|
0:? 'Color' (layout(location=0 ) out 4-component vector of float)
|
|
0:? 'Depth' (out float FragDepth)
|
|
0:? 'g_sSamp' (layout(binding=0 ) uniform sampler)
|
|
0:? 'g_tTex2dmsf4' (uniform texture2DMS)
|
|
0:? 'g_tTex2dmsf4a' (uniform texture2DMSArray)
|
|
|
|
SPIR-V is not generated for failed compile or link
|