• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1; SPIR-V
2; Version: 1.0
3; Generator: Khronos SPIR-V Tools Assembler; 0
4; Bound: 27
5; Schema: 0
6               OpCapability Float64
7               OpCapability Addresses
8               OpCapability Linkage
9               OpCapability Kernel
10               OpCapability Int64
11          %1 = OpExtInstImport "OpenCL.std"
12               OpMemoryModel Physical64 OpenCL
13               OpEntryPoint Kernel %2 "fmath_spv"
14               OpName %res "res"
15               OpName %lhs "lhs"
16               OpName %rhs "rhs"
17               OpName %entry "entry"
18               OpDecorate %7 FuncParamAttr NoCapture
19          %7 = OpDecorationGroup
20               OpDecorate %gl_GlobalInvocationID BuiltIn GlobalInvocationId
21               OpDecorate %gl_GlobalInvocationID Constant
22               OpDecorate %gl_GlobalInvocationID LinkageAttributes "__spirv_GlobalInvocationId" Import
23               OpGroupDecorate %7 %res %lhs %rhs
24      %ulong = OpTypeInt 64 0
25    %v3ulong = OpTypeVector %ulong 3
26%_ptr_UniformConstant_v3ulong = OpTypePointer UniformConstant %v3ulong
27       %void = OpTypeVoid
28     %double = OpTypeFloat 64
29%_ptr_CrossWorkgroup_double = OpTypePointer CrossWorkgroup %double
30         %15 = OpTypeFunction %void %_ptr_CrossWorkgroup_double %_ptr_CrossWorkgroup_double %_ptr_CrossWorkgroup_double
31   %ulong_32 = OpConstant %ulong 32
32%gl_GlobalInvocationID = OpVariable %_ptr_UniformConstant_v3ulong UniformConstant
33          %2 = OpFunction %void None %15
34        %res = OpFunctionParameter %_ptr_CrossWorkgroup_double
35        %lhs = OpFunctionParameter %_ptr_CrossWorkgroup_double
36        %rhs = OpFunctionParameter %_ptr_CrossWorkgroup_double
37      %entry = OpLabel
38         %17 = OpLoad %v3ulong %gl_GlobalInvocationID Aligned 0
39         %18 = OpCompositeExtract %ulong %17 0
40         %19 = OpShiftLeftLogical %ulong %18 %ulong_32
41         %20 = OpShiftRightArithmetic %ulong %19 %ulong_32
42         %21 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_double %lhs %20
43         %22 = OpLoad %double %21 Aligned 8
44         %23 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_double %rhs %20
45         %24 = OpLoad %double %23 Aligned 8
46         %25 = OpFSub %double %22 %24
47         %26 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_double %res %20
48               OpStore %26 %25 Aligned 8
49               OpReturn
50               OpFunctionEnd
51