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