dawn-cmake/test/shader_io/fragment_output_builtins.wgsl.expected.spvasm
James Price 11c6fcdb51 spirv: Use generic transform to process shader IO
The refactored CanonicalizeEntryPointIO transform makes it much easier
to handle SPIR-V style IO as well, and doing this removes a lot of
duplicated code. Remove all of the SPIR-V transform code for shader IO
and vertex point size.

Bug: tint:920
Change-Id: Id1b97517619b4d2fd09b45d5aee848259f3dfa77
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/60840
Kokoro: Kokoro <noreply+kokoro@google.com>
Commit-Queue: James Price <jrprice@google.com>
Auto-Submit: James Price <jrprice@google.com>
Reviewed-by: Ben Clayton <bclayton@google.com>
2021-08-05 17:34:19 +00:00

61 lines
2.3 KiB
Plaintext

; SPIR-V
; Version: 1.3
; Generator: Google Tint Compiler; 0
; Bound: 30
; Schema: 0
OpCapability Shader
OpMemoryModel Logical GLSL450
OpEntryPoint Fragment %main1 "main1" %value
OpEntryPoint Fragment %main2 "main2" %value_1
OpExecutionMode %main1 OriginUpperLeft
OpExecutionMode %main1 DepthReplacing
OpExecutionMode %main2 OriginUpperLeft
OpName %value "value"
OpName %value_1 "value_1"
OpName %main1_inner "main1_inner"
OpName %main1 "main1"
OpName %main2_inner "main2_inner"
OpName %main2 "main2"
OpDecorate %value BuiltIn FragDepth
OpDecorate %_arr_uint_uint_1 ArrayStride 4
OpDecorate %value_1 BuiltIn SampleMask
%float = OpTypeFloat 32
%_ptr_Output_float = OpTypePointer Output %float
%4 = OpConstantNull %float
%value = OpVariable %_ptr_Output_float Output %4
%uint = OpTypeInt 32 0
%uint_1 = OpConstant %uint 1
%_arr_uint_uint_1 = OpTypeArray %uint %uint_1
%_ptr_Output__arr_uint_uint_1 = OpTypePointer Output %_arr_uint_uint_1
%10 = OpConstantNull %_arr_uint_uint_1
%value_1 = OpVariable %_ptr_Output__arr_uint_uint_1 Output %10
%11 = OpTypeFunction %float
%float_1 = OpConstant %float 1
%void = OpTypeVoid
%15 = OpTypeFunction %void
%20 = OpTypeFunction %uint
%int = OpTypeInt 32 1
%int_0 = OpConstant %int 0
%_ptr_Output_uint = OpTypePointer Output %uint
%main1_inner = OpFunction %float None %11
%13 = OpLabel
OpReturnValue %float_1
OpFunctionEnd
%main1 = OpFunction %void None %15
%18 = OpLabel
%19 = OpFunctionCall %float %main1_inner
OpStore %value %19
OpReturn
OpFunctionEnd
%main2_inner = OpFunction %uint None %20
%22 = OpLabel
OpReturnValue %uint_1
OpFunctionEnd
%main2 = OpFunction %void None %15
%24 = OpLabel
%25 = OpFunctionCall %uint %main2_inner
%29 = OpAccessChain %_ptr_Output_uint %value_1 %int_0
OpStore %29 %25
OpReturn
OpFunctionEnd