dawn-cmake/test/tint/samples/cube.wgsl.expected.spvasm

125 lines
5.7 KiB
Plaintext

; SPIR-V
; Version: 1.3
; Generator: Google Tint Compiler; 0
; Bound: 60
; Schema: 0
OpCapability Shader
OpMemoryModel Logical GLSL450
OpEntryPoint Vertex %vtx_main "vtx_main" %cur_position_1 %color_1 %vtxFragColor_1 %Position_1 %vertex_point_size
OpEntryPoint Fragment %frag_main "frag_main" %fragColor_1 %value
OpExecutionMode %frag_main OriginUpperLeft
OpName %cur_position_1 "cur_position_1"
OpName %color_1 "color_1"
OpName %vtxFragColor_1 "vtxFragColor_1"
OpName %Position_1 "Position_1"
OpName %vertex_point_size "vertex_point_size"
OpName %fragColor_1 "fragColor_1"
OpName %value "value"
OpName %Uniforms "Uniforms"
OpMemberName %Uniforms 0 "modelViewProjectionMatrix"
OpName %uniforms "uniforms"
OpName %VertexOutput "VertexOutput"
OpMemberName %VertexOutput 0 "vtxFragColor"
OpMemberName %VertexOutput 1 "Position"
OpName %VertexInput "VertexInput"
OpMemberName %VertexInput 0 "cur_position"
OpMemberName %VertexInput 1 "color"
OpName %vtx_main_inner "vtx_main_inner"
OpName %input "input"
OpName %output "output"
OpName %vtx_main "vtx_main"
OpName %frag_main_inner "frag_main_inner"
OpName %fragColor "fragColor"
OpName %frag_main "frag_main"
OpDecorate %cur_position_1 Location 0
OpDecorate %color_1 Location 1
OpDecorate %vtxFragColor_1 Location 0
OpDecorate %Position_1 BuiltIn Position
OpDecorate %vertex_point_size BuiltIn PointSize
OpDecorate %fragColor_1 Location 0
OpDecorate %value Location 0
OpDecorate %Uniforms Block
OpMemberDecorate %Uniforms 0 Offset 0
OpMemberDecorate %Uniforms 0 ColMajor
OpMemberDecorate %Uniforms 0 MatrixStride 16
OpDecorate %uniforms NonWritable
OpDecorate %uniforms Binding 0
OpDecorate %uniforms DescriptorSet 0
OpMemberDecorate %VertexOutput 0 Offset 0
OpMemberDecorate %VertexOutput 1 Offset 16
OpMemberDecorate %VertexInput 0 Offset 0
OpMemberDecorate %VertexInput 1 Offset 16
%float = OpTypeFloat 32
%v4float = OpTypeVector %float 4
%_ptr_Input_v4float = OpTypePointer Input %v4float
%cur_position_1 = OpVariable %_ptr_Input_v4float Input
%color_1 = OpVariable %_ptr_Input_v4float Input
%_ptr_Output_v4float = OpTypePointer Output %v4float
%8 = OpConstantNull %v4float
%vtxFragColor_1 = OpVariable %_ptr_Output_v4float Output %8
%Position_1 = OpVariable %_ptr_Output_v4float Output %8
%_ptr_Output_float = OpTypePointer Output %float
%12 = OpConstantNull %float
%vertex_point_size = OpVariable %_ptr_Output_float Output %12
%fragColor_1 = OpVariable %_ptr_Input_v4float Input
%value = OpVariable %_ptr_Output_v4float Output %8
%mat4v4float = OpTypeMatrix %v4float 4
%Uniforms = OpTypeStruct %mat4v4float
%_ptr_Uniform_Uniforms = OpTypePointer Uniform %Uniforms
%uniforms = OpVariable %_ptr_Uniform_Uniforms Uniform
%VertexOutput = OpTypeStruct %v4float %v4float
%VertexInput = OpTypeStruct %v4float %v4float
%19 = OpTypeFunction %VertexOutput %VertexInput
%_ptr_Function_VertexOutput = OpTypePointer Function %VertexOutput
%27 = OpConstantNull %VertexOutput
%uint = OpTypeInt 32 0
%uint_1 = OpConstant %uint 1
%_ptr_Function_v4float = OpTypePointer Function %v4float
%uint_0 = OpConstant %uint 0
%_ptr_Uniform_mat4v4float = OpTypePointer Uniform %mat4v4float
%void = OpTypeVoid
%41 = OpTypeFunction %void
%float_1 = OpConstant %float 1
%52 = OpTypeFunction %v4float %v4float
%vtx_main_inner = OpFunction %VertexOutput None %19
%input = OpFunctionParameter %VertexInput
%24 = OpLabel
%output = OpVariable %_ptr_Function_VertexOutput Function %27
%31 = OpAccessChain %_ptr_Function_v4float %output %uint_1
%34 = OpAccessChain %_ptr_Uniform_mat4v4float %uniforms %uint_0
%35 = OpLoad %mat4v4float %34
%36 = OpCompositeExtract %v4float %input 0
%37 = OpMatrixTimesVector %v4float %35 %36
OpStore %31 %37
%38 = OpAccessChain %_ptr_Function_v4float %output %uint_0
%39 = OpCompositeExtract %v4float %input 1
OpStore %38 %39
%40 = OpLoad %VertexOutput %output
OpReturnValue %40
OpFunctionEnd
%vtx_main = OpFunction %void None %41
%44 = OpLabel
%46 = OpLoad %v4float %cur_position_1
%47 = OpLoad %v4float %color_1
%48 = OpCompositeConstruct %VertexInput %46 %47
%45 = OpFunctionCall %VertexOutput %vtx_main_inner %48
%49 = OpCompositeExtract %v4float %45 0
OpStore %vtxFragColor_1 %49
%50 = OpCompositeExtract %v4float %45 1
OpStore %Position_1 %50
OpStore %vertex_point_size %float_1
OpReturn
OpFunctionEnd
%frag_main_inner = OpFunction %v4float None %52
%fragColor = OpFunctionParameter %v4float
%55 = OpLabel
OpReturnValue %fragColor
OpFunctionEnd
%frag_main = OpFunction %void None %41
%57 = OpLabel
%59 = OpLoad %v4float %fragColor_1
%58 = OpFunctionCall %v4float %frag_main_inner %59
OpStore %value %58
OpReturn
OpFunctionEnd