glslang/Test/baseResults/hlsl.constructexpr.frag.out
tgfrerer adfa0938a2
fix error message for hlslGrammar::acceptConstructor
Fix the error message for when an erroneous HLSL constructor statement
is detected.

Prior to this change, such error messages would not show correct file
path and line number information.

Additionally, update test data to account for updated error messages.
2021-05-11 09:42:11 +01:00

165 lines
6.4 KiB
Plaintext

hlsl.constructexpr.frag
Shader version: 500
gl_FragCoord origin is upper left
0:? Sequence
0:4 Function Definition: @main( ( temp structure{ temp 4-component vector of float color})
0:4 Function Parameters:
0:? Sequence
0:6 Constant:
0:6 3 (const int)
0:7 Constant:
0:7 4 (const int)
0:8 Constant:
0:8 5 (const int)
0:9 Constant:
0:9 6 (const int)
0:10 Constant:
0:10 7 (const int)
0:11 Constant:
0:11 8 (const int)
0:12 Comma ( temp 2-component vector of float)
0:12 Constant:
0:12 9.000000
0:12 10.000000
0:12 Constant:
0:12 11.000000
0:12 12.000000
0:15 move second child to first child ( temp 4-component vector of float)
0:15 color: direct index for structure ( temp 4-component vector of float)
0:15 'ps_output' ( temp structure{ temp 4-component vector of float color})
0:15 Constant:
0:15 0 (const int)
0:15 Constant:
0:15 1.000000
0:15 1.000000
0:15 1.000000
0:15 1.000000
0:16 Branch: Return with expression
0:16 'ps_output' ( temp structure{ temp 4-component vector of float color})
0:4 Function Definition: main( ( temp void)
0:4 Function Parameters:
0:? Sequence
0:4 Sequence
0:4 move second child to first child ( temp 4-component vector of float)
0:? '@entryPointOutput.color' (layout( location=0) out 4-component vector of float)
0:4 color: direct index for structure ( temp 4-component vector of float)
0:4 Function Call: @main( ( temp structure{ temp 4-component vector of float color})
0:4 Constant:
0:4 0 (const int)
0:? Linker Objects
0:? '@entryPointOutput.color' (layout( location=0) out 4-component vector of float)
Linked fragment stage:
Shader version: 500
gl_FragCoord origin is upper left
0:? Sequence
0:4 Function Definition: @main( ( temp structure{ temp 4-component vector of float color})
0:4 Function Parameters:
0:? Sequence
0:6 Constant:
0:6 3 (const int)
0:7 Constant:
0:7 4 (const int)
0:8 Constant:
0:8 5 (const int)
0:9 Constant:
0:9 6 (const int)
0:10 Constant:
0:10 7 (const int)
0:11 Constant:
0:11 8 (const int)
0:12 Comma ( temp 2-component vector of float)
0:12 Constant:
0:12 9.000000
0:12 10.000000
0:12 Constant:
0:12 11.000000
0:12 12.000000
0:15 move second child to first child ( temp 4-component vector of float)
0:15 color: direct index for structure ( temp 4-component vector of float)
0:15 'ps_output' ( temp structure{ temp 4-component vector of float color})
0:15 Constant:
0:15 0 (const int)
0:15 Constant:
0:15 1.000000
0:15 1.000000
0:15 1.000000
0:15 1.000000
0:16 Branch: Return with expression
0:16 'ps_output' ( temp structure{ temp 4-component vector of float color})
0:4 Function Definition: main( ( temp void)
0:4 Function Parameters:
0:? Sequence
0:4 Sequence
0:4 move second child to first child ( temp 4-component vector of float)
0:? '@entryPointOutput.color' (layout( location=0) out 4-component vector of float)
0:4 color: direct index for structure ( temp 4-component vector of float)
0:4 Function Call: @main( ( temp structure{ temp 4-component vector of float color})
0:4 Constant:
0:4 0 (const int)
0:? Linker Objects
0:? '@entryPointOutput.color' (layout( location=0) out 4-component vector of float)
// Module Version 10000
// Generated by (magic number): 8000a
// Id's are bound by 40
Capability Shader
1: ExtInstImport "GLSL.std.450"
MemoryModel Logical GLSL450
EntryPoint Fragment 4 "main" 37
ExecutionMode 4 OriginUpperLeft
Source HLSL 500
Name 4 "main"
Name 8 "PS_OUTPUT"
MemberName 8(PS_OUTPUT) 0 "color"
Name 10 "@main("
Name 27 "ps_output"
Name 37 "@entryPointOutput.color"
Decorate 37(@entryPointOutput.color) Location 0
2: TypeVoid
3: TypeFunction 2
6: TypeFloat 32
7: TypeVector 6(float) 4
8(PS_OUTPUT): TypeStruct 7(fvec4)
9: TypeFunction 8(PS_OUTPUT)
12: TypeInt 32 1
13: 12(int) Constant 3
14: 12(int) Constant 4
15: 12(int) Constant 5
16: 12(int) Constant 6
17: 12(int) Constant 7
18: 12(int) Constant 8
19: TypeVector 6(float) 2
20: 6(float) Constant 1091567616
21: 6(float) Constant 1092616192
22: 19(fvec2) ConstantComposite 20 21
23: 6(float) Constant 1093664768
24: 6(float) Constant 1094713344
25: 19(fvec2) ConstantComposite 23 24
26: TypePointer Function 8(PS_OUTPUT)
28: 12(int) Constant 0
29: 6(float) Constant 1065353216
30: 7(fvec4) ConstantComposite 29 29 29 29
31: TypePointer Function 7(fvec4)
36: TypePointer Output 7(fvec4)
37(@entryPointOutput.color): 36(ptr) Variable Output
4(main): 2 Function None 3
5: Label
38:8(PS_OUTPUT) FunctionCall 10(@main()
39: 7(fvec4) CompositeExtract 38 0
Store 37(@entryPointOutput.color) 39
Return
FunctionEnd
10(@main():8(PS_OUTPUT) Function None 9
11: Label
27(ps_output): 26(ptr) Variable Function
32: 31(ptr) AccessChain 27(ps_output) 28
Store 32 30
33:8(PS_OUTPUT) Load 27(ps_output)
ReturnValue 33
FunctionEnd