Files
wgpu/tests/out/spv/access.spvasm
T
Teodor Tanasoaia 012f2a6b2e Merge pull request #1784 from teoxoy/patch-2
[hlsl-out] fix matrix not being declared as transposed
2022-03-27 22:24:09 -07:00

208 lines
5.7 KiB
Plaintext

; SPIR-V
; Version: 1.1
; Generator: rspirv
; Bound: 128
OpCapability Shader
OpExtension "SPV_KHR_storage_buffer_storage_class"
%1 = OpExtInstImport "GLSL.std.450"
OpMemoryModel Logical GLSL450
OpEntryPoint Vertex %52 "foo_vert" %47 %50
OpEntryPoint Fragment %88 "foo_frag" %87
OpEntryPoint GLCompute %105 "atomics"
OpExecutionMode %88 OriginUpperLeft
OpExecutionMode %105 LocalSize 1 1 1
OpSource GLSL 450
OpMemberName %21 0 "value"
OpName %21 "AlignedWrapper"
OpMemberName %30 0 "matrix"
OpMemberName %30 1 "matrix_array"
OpMemberName %30 2 "atom"
OpMemberName %30 3 "arr"
OpMemberName %30 4 "data"
OpName %30 "Bar"
OpName %35 "bar"
OpName %38 "foo"
OpName %39 "read_from_private"
OpName %43 "foo"
OpName %44 "c"
OpName %47 "vi"
OpName %52 "foo_vert"
OpName %88 "foo_frag"
OpName %103 "tmp"
OpName %105 "atomics"
OpMemberDecorate %21 0 Offset 0
OpDecorate %26 ArrayStride 16
OpDecorate %28 ArrayStride 8
OpDecorate %29 ArrayStride 8
OpMemberDecorate %30 0 Offset 0
OpMemberDecorate %30 0 ColMajor
OpMemberDecorate %30 0 MatrixStride 16
OpMemberDecorate %30 1 Offset 64
OpMemberDecorate %30 1 ColMajor
OpMemberDecorate %30 1 MatrixStride 8
OpMemberDecorate %30 2 Offset 96
OpMemberDecorate %30 3 Offset 104
OpMemberDecorate %30 4 Offset 120
OpDecorate %34 ArrayStride 4
OpDecorate %35 DescriptorSet 0
OpDecorate %35 Binding 0
OpDecorate %30 Block
OpDecorate %47 BuiltIn VertexIndex
OpDecorate %50 BuiltIn Position
OpDecorate %87 Location 0
%2 = OpTypeVoid
%4 = OpTypeInt 32 1
%3 = OpConstant %4 2
%6 = OpTypeFloat 32
%5 = OpConstant %6 0.0
%7 = OpConstant %6 1.0
%9 = OpTypeInt 32 0
%8 = OpConstant %9 3
%10 = OpConstant %9 2
%11 = OpConstant %4 0
%12 = OpConstant %4 5
%13 = OpConstant %4 3
%14 = OpConstant %4 4
%15 = OpConstant %9 1
%16 = OpConstant %4 42
%17 = OpConstant %6 2.0
%18 = OpConstant %4 1
%19 = OpConstant %6 3.0
%20 = OpConstant %9 0
%21 = OpTypeStruct %4
%23 = OpTypeVector %6 3
%22 = OpTypeMatrix %23 4
%25 = OpTypeVector %6 2
%24 = OpTypeMatrix %25 2
%26 = OpTypeArray %24 %3
%27 = OpTypeVector %9 2
%28 = OpTypeArray %27 %3
%29 = OpTypeRuntimeArray %21
%30 = OpTypeStruct %22 %26 %4 %28 %29
%31 = OpTypePointer Function %6
%32 = OpTypeVector %6 4
%33 = OpTypePointer StorageBuffer %4
%34 = OpTypeArray %4 %12
%36 = OpTypePointer StorageBuffer %30
%35 = OpVariable %36 StorageBuffer
%40 = OpTypeFunction %6 %31
%45 = OpTypePointer Function %34
%48 = OpTypePointer Input %9
%47 = OpVariable %48 Input
%51 = OpTypePointer Output %32
%50 = OpVariable %51 Output
%53 = OpTypeFunction %2
%56 = OpTypePointer StorageBuffer %22
%59 = OpTypePointer StorageBuffer %28
%62 = OpTypePointer StorageBuffer %23
%63 = OpTypePointer StorageBuffer %6
%66 = OpTypePointer StorageBuffer %29
%69 = OpTypePointer StorageBuffer %21
%70 = OpConstant %9 4
%77 = OpTypePointer Function %4
%81 = OpTypeVector %4 4
%87 = OpVariable %51 Output
%107 = OpTypePointer StorageBuffer %4
%110 = OpConstant %9 64
%39 = OpFunction %6 None %40
%38 = OpFunctionParameter %31
%37 = OpLabel
OpBranch %41
%41 = OpLabel
%42 = OpLoad %6 %38
OpReturnValue %42
OpFunctionEnd
%52 = OpFunction %2 None %53
%46 = OpLabel
%43 = OpVariable %31 Function %5
%44 = OpVariable %45 Function
%49 = OpLoad %9 %47
OpBranch %54
%54 = OpLabel
%55 = OpLoad %6 %43
OpStore %43 %7
%57 = OpAccessChain %56 %35 %20
%58 = OpLoad %22 %57
%60 = OpAccessChain %59 %35 %8
%61 = OpLoad %28 %60
%64 = OpAccessChain %63 %35 %20 %8 %20
%65 = OpLoad %6 %64
%67 = OpArrayLength %9 %35 4
%68 = OpISub %9 %67 %10
%71 = OpAccessChain %33 %35 %70 %68 %20
%72 = OpLoad %4 %71
%73 = OpFunctionCall %6 %39 %43
%74 = OpConvertFToS %4 %65
%75 = OpCompositeConstruct %34 %72 %74 %13 %14 %12
OpStore %44 %75
%76 = OpIAdd %9 %49 %15
%78 = OpAccessChain %77 %44 %76
OpStore %78 %16
%79 = OpAccessChain %77 %44 %49
%80 = OpLoad %4 %79
%82 = OpCompositeConstruct %81 %80 %80 %80 %80
%83 = OpConvertSToF %32 %82
%84 = OpMatrixTimesVector %23 %58 %83
%85 = OpCompositeConstruct %32 %84 %17
OpStore %50 %85
OpReturn
OpFunctionEnd
%88 = OpFunction %2 None %53
%86 = OpLabel
OpBranch %89
%89 = OpLabel
%90 = OpAccessChain %63 %35 %20 %15 %10
OpStore %90 %7
%91 = OpCompositeConstruct %23 %5 %5 %5
%92 = OpCompositeConstruct %23 %7 %7 %7
%93 = OpCompositeConstruct %23 %17 %17 %17
%94 = OpCompositeConstruct %23 %19 %19 %19
%95 = OpCompositeConstruct %22 %91 %92 %93 %94
%96 = OpAccessChain %56 %35 %20
OpStore %96 %95
%97 = OpCompositeConstruct %27 %20 %20
%98 = OpCompositeConstruct %27 %15 %15
%99 = OpCompositeConstruct %28 %97 %98
%100 = OpAccessChain %59 %35 %8
OpStore %100 %99
%101 = OpAccessChain %33 %35 %70 %15 %20
OpStore %101 %18
%102 = OpCompositeConstruct %32 %5 %5 %5 %5
OpStore %87 %102
OpReturn
OpFunctionEnd
%105 = OpFunction %2 None %53
%104 = OpLabel
%103 = OpVariable %77 Function
OpBranch %106
%106 = OpLabel
%108 = OpAccessChain %107 %35 %10
%109 = OpAtomicLoad %4 %108 %18 %110
%112 = OpAccessChain %107 %35 %10
%111 = OpAtomicIAdd %4 %112 %18 %110 %12
OpStore %103 %111
%114 = OpAccessChain %107 %35 %10
%113 = OpAtomicISub %4 %114 %18 %110 %12
OpStore %103 %113
%116 = OpAccessChain %107 %35 %10
%115 = OpAtomicAnd %4 %116 %18 %110 %12
OpStore %103 %115
%118 = OpAccessChain %107 %35 %10
%117 = OpAtomicOr %4 %118 %18 %110 %12
OpStore %103 %117
%120 = OpAccessChain %107 %35 %10
%119 = OpAtomicXor %4 %120 %18 %110 %12
OpStore %103 %119
%122 = OpAccessChain %107 %35 %10
%121 = OpAtomicSMin %4 %122 %18 %110 %12
OpStore %103 %121
%124 = OpAccessChain %107 %35 %10
%123 = OpAtomicSMax %4 %124 %18 %110 %12
OpStore %103 %123
%126 = OpAccessChain %107 %35 %10
%125 = OpAtomicExchange %4 %126 %18 %110 %12
OpStore %103 %125
%127 = OpAccessChain %107 %35 %10
OpAtomicStore %127 %18 %110 %109
OpReturn
OpFunctionEnd