mirror of
https://github.com/KhronosGroup/OpenCL-CTS.git
synced 2026-03-25 08:19:02 +00:00
add SPIR-V 1.4 testing for no integer wrap decorations (#2041)
This PR adds targeted testing for SPIR-V 1.4 features. Specifically, this PR adds testing for the NoSignedWrap and NoUnsignedWrap decorations. We can reuse large parts of the testing for the `cl_khr_spirv_no_integer_wrap_decoration` extension to test the SPIR-V 1.4 feature.
This commit is contained in:
@@ -0,0 +1,45 @@
|
||||
; SPIR-V
|
||||
; Version: 1.4
|
||||
; Generator: Khronos SPIR-V Tools Assembler; 0
|
||||
; Bound: 23
|
||||
; Schema: 0
|
||||
OpCapability Addresses
|
||||
OpCapability Linkage
|
||||
OpCapability Kernel
|
||||
OpMemoryModel Physical32 OpenCL
|
||||
OpEntryPoint Kernel %2 "fmath_cl" %__spirv_BuiltInGlobalInvocationId
|
||||
OpSource OpenCL_C 200000
|
||||
OpName %__spirv_BuiltInGlobalInvocationId "__spirv_BuiltInGlobalInvocationId"
|
||||
OpName %out "out"
|
||||
OpName %lhs "lhs"
|
||||
OpName %rhs "rhs"
|
||||
OpDecorate %7 FuncParamAttr NoWrite
|
||||
%7 = OpDecorationGroup
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId BuiltIn GlobalInvocationId
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId Constant
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId LinkageAttributes "__spirv_BuiltInGlobalInvocationId" Import
|
||||
OpDecorate %8 NoSignedWrap
|
||||
OpGroupDecorate %7 %lhs %rhs
|
||||
%uint = OpTypeInt 32 0
|
||||
%v3uint = OpTypeVector %uint 3
|
||||
%_ptr_Input_v3uint = OpTypePointer Input %v3uint
|
||||
%void = OpTypeVoid
|
||||
%_ptr_CrossWorkgroup_uint = OpTypePointer CrossWorkgroup %uint
|
||||
%14 = OpTypeFunction %void %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint
|
||||
%__spirv_BuiltInGlobalInvocationId = OpVariable %_ptr_Input_v3uint Input
|
||||
%2 = OpFunction %void None %14
|
||||
%out = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%lhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%rhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%15 = OpLabel
|
||||
%16 = OpLoad %v3uint %__spirv_BuiltInGlobalInvocationId
|
||||
%17 = OpCompositeExtract %uint %16 0
|
||||
%18 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %lhs %17
|
||||
%19 = OpLoad %uint %18 Aligned 4
|
||||
%20 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %rhs %17
|
||||
%21 = OpLoad %uint %20 Aligned 4
|
||||
%8 = OpIAdd %uint %19 %21
|
||||
%22 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %out %17
|
||||
OpStore %22 %8 Aligned 4
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
@@ -0,0 +1,51 @@
|
||||
; SPIR-V
|
||||
; Version: 1.4
|
||||
; Generator: Khronos SPIR-V Tools Assembler; 0
|
||||
; Bound: 28
|
||||
; Schema: 0
|
||||
OpCapability Addresses
|
||||
OpCapability Linkage
|
||||
OpCapability Kernel
|
||||
OpCapability Int64
|
||||
OpMemoryModel Physical64 OpenCL
|
||||
OpEntryPoint Kernel %2 "fmath_cl" %__spirv_BuiltInGlobalInvocationId
|
||||
OpSource OpenCL_C 200000
|
||||
OpName %__spirv_BuiltInGlobalInvocationId "__spirv_BuiltInGlobalInvocationId"
|
||||
OpName %out "out"
|
||||
OpName %lhs "lhs"
|
||||
OpName %rhs "rhs"
|
||||
OpDecorate %7 FuncParamAttr NoWrite
|
||||
%7 = OpDecorationGroup
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId BuiltIn GlobalInvocationId
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId Constant
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId LinkageAttributes "__spirv_BuiltInGlobalInvocationId" Import
|
||||
OpDecorate %8 NoSignedWrap
|
||||
OpGroupDecorate %7 %lhs %rhs
|
||||
%ulong = OpTypeInt 64 0
|
||||
%uint = OpTypeInt 32 0
|
||||
%v3ulong = OpTypeVector %ulong 3
|
||||
%_ptr_Input_v3ulong = OpTypePointer Input %v3ulong
|
||||
%void = OpTypeVoid
|
||||
%_ptr_CrossWorkgroup_uint = OpTypePointer CrossWorkgroup %uint
|
||||
%15 = OpTypeFunction %void %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint
|
||||
%__spirv_BuiltInGlobalInvocationId = OpVariable %_ptr_Input_v3ulong Input
|
||||
%2 = OpFunction %void None %15
|
||||
%out = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%lhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%rhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%16 = OpLabel
|
||||
%17 = OpLoad %v3ulong %__spirv_BuiltInGlobalInvocationId
|
||||
%18 = OpCompositeExtract %ulong %17 0
|
||||
%19 = OpUConvert %uint %18
|
||||
%20 = OpSConvert %ulong %19
|
||||
%21 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %lhs %20
|
||||
%22 = OpLoad %uint %21 Aligned 4
|
||||
%23 = OpSConvert %ulong %19
|
||||
%24 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %rhs %23
|
||||
%25 = OpLoad %uint %24 Aligned 4
|
||||
%8 = OpIAdd %uint %22 %25
|
||||
%26 = OpSConvert %ulong %19
|
||||
%27 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %out %26
|
||||
OpStore %27 %8 Aligned 4
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
@@ -0,0 +1,45 @@
|
||||
; SPIR-V
|
||||
; Version: 1.4
|
||||
; Generator: Khronos SPIR-V Tools Assembler; 0
|
||||
; Bound: 23
|
||||
; Schema: 0
|
||||
OpCapability Addresses
|
||||
OpCapability Linkage
|
||||
OpCapability Kernel
|
||||
OpMemoryModel Physical32 OpenCL
|
||||
OpEntryPoint Kernel %2 "fmath_cl" %__spirv_BuiltInGlobalInvocationId
|
||||
OpSource OpenCL_C 200000
|
||||
OpName %__spirv_BuiltInGlobalInvocationId "__spirv_BuiltInGlobalInvocationId"
|
||||
OpName %out "out"
|
||||
OpName %lhs "lhs"
|
||||
OpName %rhs "rhs"
|
||||
OpDecorate %7 FuncParamAttr NoWrite
|
||||
%7 = OpDecorationGroup
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId BuiltIn GlobalInvocationId
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId Constant
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId LinkageAttributes "__spirv_BuiltInGlobalInvocationId" Import
|
||||
OpDecorate %8 NoUnsignedWrap
|
||||
OpGroupDecorate %7 %lhs %rhs
|
||||
%uint = OpTypeInt 32 0
|
||||
%v3uint = OpTypeVector %uint 3
|
||||
%_ptr_Input_v3uint = OpTypePointer Input %v3uint
|
||||
%void = OpTypeVoid
|
||||
%_ptr_CrossWorkgroup_uint = OpTypePointer CrossWorkgroup %uint
|
||||
%14 = OpTypeFunction %void %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint
|
||||
%__spirv_BuiltInGlobalInvocationId = OpVariable %_ptr_Input_v3uint Input
|
||||
%2 = OpFunction %void None %14
|
||||
%out = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%lhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%rhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%15 = OpLabel
|
||||
%16 = OpLoad %v3uint %__spirv_BuiltInGlobalInvocationId
|
||||
%17 = OpCompositeExtract %uint %16 0
|
||||
%18 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %lhs %17
|
||||
%19 = OpLoad %uint %18 Aligned 4
|
||||
%20 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %rhs %17
|
||||
%21 = OpLoad %uint %20 Aligned 4
|
||||
%8 = OpIAdd %uint %19 %21
|
||||
%22 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %out %17
|
||||
OpStore %22 %8 Aligned 4
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
@@ -0,0 +1,51 @@
|
||||
; SPIR-V
|
||||
; Version: 1.4
|
||||
; Generator: Khronos SPIR-V Tools Assembler; 0
|
||||
; Bound: 28
|
||||
; Schema: 0
|
||||
OpCapability Addresses
|
||||
OpCapability Linkage
|
||||
OpCapability Kernel
|
||||
OpCapability Int64
|
||||
OpMemoryModel Physical64 OpenCL
|
||||
OpEntryPoint Kernel %2 "fmath_cl" %__spirv_BuiltInGlobalInvocationId
|
||||
OpSource OpenCL_C 200000
|
||||
OpName %__spirv_BuiltInGlobalInvocationId "__spirv_BuiltInGlobalInvocationId"
|
||||
OpName %out "out"
|
||||
OpName %lhs "lhs"
|
||||
OpName %rhs "rhs"
|
||||
OpDecorate %7 FuncParamAttr NoWrite
|
||||
%7 = OpDecorationGroup
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId BuiltIn GlobalInvocationId
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId Constant
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId LinkageAttributes "__spirv_BuiltInGlobalInvocationId" Import
|
||||
OpDecorate %8 NoUnsignedWrap
|
||||
OpGroupDecorate %7 %lhs %rhs
|
||||
%ulong = OpTypeInt 64 0
|
||||
%uint = OpTypeInt 32 0
|
||||
%v3ulong = OpTypeVector %ulong 3
|
||||
%_ptr_Input_v3ulong = OpTypePointer Input %v3ulong
|
||||
%void = OpTypeVoid
|
||||
%_ptr_CrossWorkgroup_uint = OpTypePointer CrossWorkgroup %uint
|
||||
%15 = OpTypeFunction %void %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint
|
||||
%__spirv_BuiltInGlobalInvocationId = OpVariable %_ptr_Input_v3ulong Input
|
||||
%2 = OpFunction %void None %15
|
||||
%out = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%lhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%rhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%16 = OpLabel
|
||||
%17 = OpLoad %v3ulong %__spirv_BuiltInGlobalInvocationId
|
||||
%18 = OpCompositeExtract %ulong %17 0
|
||||
%19 = OpUConvert %uint %18
|
||||
%20 = OpSConvert %ulong %19
|
||||
%21 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %lhs %20
|
||||
%22 = OpLoad %uint %21 Aligned 4
|
||||
%23 = OpSConvert %ulong %19
|
||||
%24 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %rhs %23
|
||||
%25 = OpLoad %uint %24 Aligned 4
|
||||
%8 = OpIAdd %uint %22 %25
|
||||
%26 = OpSConvert %ulong %19
|
||||
%27 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %out %26
|
||||
OpStore %27 %8 Aligned 4
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
@@ -0,0 +1,45 @@
|
||||
; SPIR-V
|
||||
; Version: 1.4
|
||||
; Generator: Khronos SPIR-V Tools Assembler; 0
|
||||
; Bound: 23
|
||||
; Schema: 0
|
||||
OpCapability Addresses
|
||||
OpCapability Linkage
|
||||
OpCapability Kernel
|
||||
OpMemoryModel Physical32 OpenCL
|
||||
OpEntryPoint Kernel %2 "fmath_cl" %__spirv_BuiltInGlobalInvocationId
|
||||
OpSource OpenCL_C 200000
|
||||
OpName %__spirv_BuiltInGlobalInvocationId "__spirv_BuiltInGlobalInvocationId"
|
||||
OpName %out "out"
|
||||
OpName %lhs "lhs"
|
||||
OpName %rhs "rhs"
|
||||
OpDecorate %7 FuncParamAttr NoWrite
|
||||
%7 = OpDecorationGroup
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId BuiltIn GlobalInvocationId
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId Constant
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId LinkageAttributes "__spirv_BuiltInGlobalInvocationId" Import
|
||||
OpDecorate %8 NoSignedWrap
|
||||
OpGroupDecorate %7 %lhs %rhs
|
||||
%uint = OpTypeInt 32 0
|
||||
%v3uint = OpTypeVector %uint 3
|
||||
%_ptr_Input_v3uint = OpTypePointer Input %v3uint
|
||||
%void = OpTypeVoid
|
||||
%_ptr_CrossWorkgroup_uint = OpTypePointer CrossWorkgroup %uint
|
||||
%14 = OpTypeFunction %void %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint
|
||||
%__spirv_BuiltInGlobalInvocationId = OpVariable %_ptr_Input_v3uint Input
|
||||
%2 = OpFunction %void None %14
|
||||
%out = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%lhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%rhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%15 = OpLabel
|
||||
%16 = OpLoad %v3uint %__spirv_BuiltInGlobalInvocationId
|
||||
%17 = OpCompositeExtract %uint %16 0
|
||||
%18 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %lhs %17
|
||||
%19 = OpLoad %uint %18 Aligned 4
|
||||
%20 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %rhs %17
|
||||
%21 = OpLoad %uint %20 Aligned 4
|
||||
%8 = OpIMul %uint %19 %21
|
||||
%22 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %out %17
|
||||
OpStore %22 %8 Aligned 4
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
@@ -0,0 +1,51 @@
|
||||
; SPIR-V
|
||||
; Version: 1.4
|
||||
; Generator: Khronos SPIR-V Tools Assembler; 0
|
||||
; Bound: 28
|
||||
; Schema: 0
|
||||
OpCapability Addresses
|
||||
OpCapability Linkage
|
||||
OpCapability Kernel
|
||||
OpCapability Int64
|
||||
OpMemoryModel Physical64 OpenCL
|
||||
OpEntryPoint Kernel %2 "fmath_cl" %__spirv_BuiltInGlobalInvocationId
|
||||
OpSource OpenCL_C 200000
|
||||
OpName %__spirv_BuiltInGlobalInvocationId "__spirv_BuiltInGlobalInvocationId"
|
||||
OpName %out "out"
|
||||
OpName %lhs "lhs"
|
||||
OpName %rhs "rhs"
|
||||
OpDecorate %7 FuncParamAttr NoWrite
|
||||
%7 = OpDecorationGroup
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId BuiltIn GlobalInvocationId
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId Constant
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId LinkageAttributes "__spirv_BuiltInGlobalInvocationId" Import
|
||||
OpDecorate %8 NoSignedWrap
|
||||
OpGroupDecorate %7 %lhs %rhs
|
||||
%ulong = OpTypeInt 64 0
|
||||
%uint = OpTypeInt 32 0
|
||||
%v3ulong = OpTypeVector %ulong 3
|
||||
%_ptr_Input_v3ulong = OpTypePointer Input %v3ulong
|
||||
%void = OpTypeVoid
|
||||
%_ptr_CrossWorkgroup_uint = OpTypePointer CrossWorkgroup %uint
|
||||
%15 = OpTypeFunction %void %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint
|
||||
%__spirv_BuiltInGlobalInvocationId = OpVariable %_ptr_Input_v3ulong Input
|
||||
%2 = OpFunction %void None %15
|
||||
%out = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%lhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%rhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%16 = OpLabel
|
||||
%17 = OpLoad %v3ulong %__spirv_BuiltInGlobalInvocationId
|
||||
%18 = OpCompositeExtract %ulong %17 0
|
||||
%19 = OpUConvert %uint %18
|
||||
%20 = OpSConvert %ulong %19
|
||||
%21 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %lhs %20
|
||||
%22 = OpLoad %uint %21 Aligned 4
|
||||
%23 = OpSConvert %ulong %19
|
||||
%24 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %rhs %23
|
||||
%25 = OpLoad %uint %24 Aligned 4
|
||||
%8 = OpIMul %uint %22 %25
|
||||
%26 = OpSConvert %ulong %19
|
||||
%27 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %out %26
|
||||
OpStore %27 %8 Aligned 4
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
@@ -0,0 +1,45 @@
|
||||
; SPIR-V
|
||||
; Version: 1.4
|
||||
; Generator: Khronos SPIR-V Tools Assembler; 0
|
||||
; Bound: 23
|
||||
; Schema: 0
|
||||
OpCapability Addresses
|
||||
OpCapability Linkage
|
||||
OpCapability Kernel
|
||||
OpMemoryModel Physical32 OpenCL
|
||||
OpEntryPoint Kernel %2 "fmath_cl" %__spirv_BuiltInGlobalInvocationId
|
||||
OpSource OpenCL_C 200000
|
||||
OpName %__spirv_BuiltInGlobalInvocationId "__spirv_BuiltInGlobalInvocationId"
|
||||
OpName %out "out"
|
||||
OpName %lhs "lhs"
|
||||
OpName %rhs "rhs"
|
||||
OpDecorate %7 FuncParamAttr NoWrite
|
||||
%7 = OpDecorationGroup
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId BuiltIn GlobalInvocationId
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId Constant
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId LinkageAttributes "__spirv_BuiltInGlobalInvocationId" Import
|
||||
OpDecorate %8 NoUnsignedWrap
|
||||
OpGroupDecorate %7 %lhs %rhs
|
||||
%uint = OpTypeInt 32 0
|
||||
%v3uint = OpTypeVector %uint 3
|
||||
%_ptr_Input_v3uint = OpTypePointer Input %v3uint
|
||||
%void = OpTypeVoid
|
||||
%_ptr_CrossWorkgroup_uint = OpTypePointer CrossWorkgroup %uint
|
||||
%14 = OpTypeFunction %void %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint
|
||||
%__spirv_BuiltInGlobalInvocationId = OpVariable %_ptr_Input_v3uint Input
|
||||
%2 = OpFunction %void None %14
|
||||
%out = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%lhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%rhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%15 = OpLabel
|
||||
%16 = OpLoad %v3uint %__spirv_BuiltInGlobalInvocationId
|
||||
%17 = OpCompositeExtract %uint %16 0
|
||||
%18 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %lhs %17
|
||||
%19 = OpLoad %uint %18 Aligned 4
|
||||
%20 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %rhs %17
|
||||
%21 = OpLoad %uint %20 Aligned 4
|
||||
%8 = OpIMul %uint %19 %21
|
||||
%22 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %out %17
|
||||
OpStore %22 %8 Aligned 4
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
@@ -0,0 +1,51 @@
|
||||
; SPIR-V
|
||||
; Version: 1.3
|
||||
; Generator: Khronos SPIR-V Tools Assembler; 0
|
||||
; Bound: 28
|
||||
; Schema: 0
|
||||
OpCapability Addresses
|
||||
OpCapability Linkage
|
||||
OpCapability Kernel
|
||||
OpCapability Int64
|
||||
OpMemoryModel Physical64 OpenCL
|
||||
OpEntryPoint Kernel %2 "fmath_cl" %__spirv_BuiltInGlobalInvocationId
|
||||
OpSource OpenCL_C 200000
|
||||
OpName %__spirv_BuiltInGlobalInvocationId "__spirv_BuiltInGlobalInvocationId"
|
||||
OpName %out "out"
|
||||
OpName %lhs "lhs"
|
||||
OpName %rhs "rhs"
|
||||
OpDecorate %7 FuncParamAttr NoWrite
|
||||
%7 = OpDecorationGroup
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId BuiltIn GlobalInvocationId
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId Constant
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId LinkageAttributes "__spirv_BuiltInGlobalInvocationId" Import
|
||||
OpDecorate %8 NoUnsignedWrap
|
||||
OpGroupDecorate %7 %lhs %rhs
|
||||
%ulong = OpTypeInt 64 0
|
||||
%uint = OpTypeInt 32 0
|
||||
%v3ulong = OpTypeVector %ulong 3
|
||||
%_ptr_Input_v3ulong = OpTypePointer Input %v3ulong
|
||||
%void = OpTypeVoid
|
||||
%_ptr_CrossWorkgroup_uint = OpTypePointer CrossWorkgroup %uint
|
||||
%15 = OpTypeFunction %void %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint
|
||||
%__spirv_BuiltInGlobalInvocationId = OpVariable %_ptr_Input_v3ulong Input
|
||||
%2 = OpFunction %void None %15
|
||||
%out = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%lhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%rhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%16 = OpLabel
|
||||
%17 = OpLoad %v3ulong %__spirv_BuiltInGlobalInvocationId
|
||||
%18 = OpCompositeExtract %ulong %17 0
|
||||
%19 = OpUConvert %uint %18
|
||||
%20 = OpSConvert %ulong %19
|
||||
%21 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %lhs %20
|
||||
%22 = OpLoad %uint %21 Aligned 4
|
||||
%23 = OpSConvert %ulong %19
|
||||
%24 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %rhs %23
|
||||
%25 = OpLoad %uint %24 Aligned 4
|
||||
%8 = OpIMul %uint %22 %25
|
||||
%26 = OpSConvert %ulong %19
|
||||
%27 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %out %26
|
||||
OpStore %27 %8 Aligned 4
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
@@ -0,0 +1,44 @@
|
||||
; SPIR-V
|
||||
; Version: 1.4
|
||||
; Generator: Khronos SPIR-V Tools Assembler; 0
|
||||
; Bound: 22
|
||||
; Schema: 0
|
||||
OpCapability Addresses
|
||||
OpCapability Linkage
|
||||
OpCapability Kernel
|
||||
OpMemoryModel Physical32 OpenCL
|
||||
OpEntryPoint Kernel %2 "fmath_cl" %__spirv_BuiltInGlobalInvocationId
|
||||
OpSource OpenCL_C 200000
|
||||
OpName %__spirv_BuiltInGlobalInvocationId "__spirv_BuiltInGlobalInvocationId"
|
||||
OpName %out "out"
|
||||
OpName %lhs "lhs"
|
||||
OpName %rhs "rhs"
|
||||
OpDecorate %7 FuncParamAttr NoWrite
|
||||
OpDecorate %8 NoSignedWrap
|
||||
%7 = OpDecorationGroup
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId BuiltIn GlobalInvocationId
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId Constant
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId LinkageAttributes "__spirv_BuiltInGlobalInvocationId" Import
|
||||
OpGroupDecorate %7 %lhs %rhs
|
||||
%uint = OpTypeInt 32 0
|
||||
%uint_0 = OpConstant %uint 0
|
||||
%v3uint = OpTypeVector %uint 3
|
||||
%_ptr_Input_v3uint = OpTypePointer Input %v3uint
|
||||
%void = OpTypeVoid
|
||||
%_ptr_CrossWorkgroup_uint = OpTypePointer CrossWorkgroup %uint
|
||||
%15 = OpTypeFunction %void %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint
|
||||
%__spirv_BuiltInGlobalInvocationId = OpVariable %_ptr_Input_v3uint Input
|
||||
%2 = OpFunction %void None %15
|
||||
%out = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%lhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%rhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%16 = OpLabel
|
||||
%17 = OpLoad %v3uint %__spirv_BuiltInGlobalInvocationId
|
||||
%18 = OpCompositeExtract %uint %17 0
|
||||
%19 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %lhs %18
|
||||
%20 = OpLoad %uint %19 Aligned 4
|
||||
%8 = OpSNegate %uint %20
|
||||
%21 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %out %18
|
||||
OpStore %21 %8 Aligned 4
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
@@ -0,0 +1,49 @@
|
||||
; SPIR-V
|
||||
; Version: 1.4
|
||||
; Generator: Khronos SPIR-V Tools Assembler; 0
|
||||
; Bound: 26
|
||||
; Schema: 0
|
||||
OpCapability Addresses
|
||||
OpCapability Linkage
|
||||
OpCapability Kernel
|
||||
OpCapability Int64
|
||||
OpMemoryModel Physical64 OpenCL
|
||||
OpEntryPoint Kernel %2 "fmath_cl" %__spirv_BuiltInGlobalInvocationId
|
||||
OpSource OpenCL_C 200000
|
||||
OpName %__spirv_BuiltInGlobalInvocationId "__spirv_BuiltInGlobalInvocationId"
|
||||
OpName %out "out"
|
||||
OpName %lhs "lhs"
|
||||
OpName %rhs "rhs"
|
||||
OpDecorate %7 FuncParamAttr NoWrite
|
||||
OpDecorate %8 NoSignedWrap
|
||||
%7 = OpDecorationGroup
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId BuiltIn GlobalInvocationId
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId Constant
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId LinkageAttributes "__spirv_BuiltInGlobalInvocationId" Import
|
||||
OpGroupDecorate %7 %lhs %rhs
|
||||
%ulong = OpTypeInt 64 0
|
||||
%uint = OpTypeInt 32 0
|
||||
%uint_0 = OpConstant %uint 0
|
||||
%v3ulong = OpTypeVector %ulong 3
|
||||
%_ptr_Input_v3ulong = OpTypePointer Input %v3ulong
|
||||
%void = OpTypeVoid
|
||||
%_ptr_CrossWorkgroup_uint = OpTypePointer CrossWorkgroup %uint
|
||||
%16 = OpTypeFunction %void %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint
|
||||
%__spirv_BuiltInGlobalInvocationId = OpVariable %_ptr_Input_v3ulong Input
|
||||
%2 = OpFunction %void None %16
|
||||
%out = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%lhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%rhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%17 = OpLabel
|
||||
%18 = OpLoad %v3ulong %__spirv_BuiltInGlobalInvocationId
|
||||
%19 = OpCompositeExtract %ulong %18 0
|
||||
%20 = OpUConvert %uint %19
|
||||
%21 = OpSConvert %ulong %20
|
||||
%22 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %lhs %21
|
||||
%23 = OpLoad %uint %22 Aligned 4
|
||||
%8 = OpSNegate %uint %23
|
||||
%24 = OpSConvert %ulong %20
|
||||
%25 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %out %24
|
||||
OpStore %25 %8 Aligned 4
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
@@ -0,0 +1,47 @@
|
||||
; SPIR-V
|
||||
; Version: 1.4
|
||||
; Generator: Khronos SPIR-V Tools Assembler; 0
|
||||
; Bound: 25
|
||||
; Schema: 0
|
||||
OpCapability Addresses
|
||||
OpCapability Linkage
|
||||
OpCapability Kernel
|
||||
OpMemoryModel Physical32 OpenCL
|
||||
OpEntryPoint Kernel %2 "fmath_cl" %__spirv_BuiltInGlobalInvocationId
|
||||
OpSource OpenCL_C 200000
|
||||
OpName %__spirv_BuiltInGlobalInvocationId "__spirv_BuiltInGlobalInvocationId"
|
||||
OpName %out "out"
|
||||
OpName %lhs "lhs"
|
||||
OpName %rhs "rhs"
|
||||
OpDecorate %7 FuncParamAttr NoWrite
|
||||
%7 = OpDecorationGroup
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId BuiltIn GlobalInvocationId
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId Constant
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId LinkageAttributes "__spirv_BuiltInGlobalInvocationId" Import
|
||||
OpDecorate %8 NoSignedWrap
|
||||
OpGroupDecorate %7 %lhs %rhs
|
||||
%uint = OpTypeInt 32 0
|
||||
%uint_31 = OpConstant %uint 31
|
||||
%v3uint = OpTypeVector %uint 3
|
||||
%_ptr_Input_v3uint = OpTypePointer Input %v3uint
|
||||
%void = OpTypeVoid
|
||||
%_ptr_CrossWorkgroup_uint = OpTypePointer CrossWorkgroup %uint
|
||||
%15 = OpTypeFunction %void %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint
|
||||
%__spirv_BuiltInGlobalInvocationId = OpVariable %_ptr_Input_v3uint Input
|
||||
%2 = OpFunction %void None %15
|
||||
%out = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%lhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%rhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%16 = OpLabel
|
||||
%17 = OpLoad %v3uint %__spirv_BuiltInGlobalInvocationId
|
||||
%18 = OpCompositeExtract %uint %17 0
|
||||
%19 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %lhs %18
|
||||
%20 = OpLoad %uint %19 Aligned 4
|
||||
%21 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %rhs %18
|
||||
%22 = OpLoad %uint %21 Aligned 4
|
||||
%23 = OpBitwiseAnd %uint %22 %uint_31
|
||||
%8 = OpShiftLeftLogical %uint %20 %23
|
||||
%24 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %out %18
|
||||
OpStore %24 %8 Aligned 4
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
@@ -0,0 +1,53 @@
|
||||
; SPIR-V
|
||||
; Version: 1.4
|
||||
; Generator: Khronos SPIR-V Tools Assembler; 0
|
||||
; Bound: 30
|
||||
; Schema: 0
|
||||
OpCapability Addresses
|
||||
OpCapability Linkage
|
||||
OpCapability Kernel
|
||||
OpCapability Int64
|
||||
OpMemoryModel Physical64 OpenCL
|
||||
OpEntryPoint Kernel %2 "fmath_cl" %__spirv_BuiltInGlobalInvocationId
|
||||
OpSource OpenCL_C 200000
|
||||
OpName %__spirv_BuiltInGlobalInvocationId "__spirv_BuiltInGlobalInvocationId"
|
||||
OpName %out "out"
|
||||
OpName %lhs "lhs"
|
||||
OpName %rhs "rhs"
|
||||
OpDecorate %7 FuncParamAttr NoWrite
|
||||
%7 = OpDecorationGroup
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId BuiltIn GlobalInvocationId
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId Constant
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId LinkageAttributes "__spirv_BuiltInGlobalInvocationId" Import
|
||||
OpDecorate %8 NoSignedWrap
|
||||
OpGroupDecorate %7 %lhs %rhs
|
||||
%ulong = OpTypeInt 64 0
|
||||
%uint = OpTypeInt 32 0
|
||||
%uint_31 = OpConstant %uint 31
|
||||
%v3ulong = OpTypeVector %ulong 3
|
||||
%_ptr_Input_v3ulong = OpTypePointer Input %v3ulong
|
||||
%void = OpTypeVoid
|
||||
%_ptr_CrossWorkgroup_uint = OpTypePointer CrossWorkgroup %uint
|
||||
%16 = OpTypeFunction %void %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint
|
||||
%__spirv_BuiltInGlobalInvocationId = OpVariable %_ptr_Input_v3ulong Input
|
||||
%2 = OpFunction %void None %16
|
||||
%out = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%lhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%rhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%17 = OpLabel
|
||||
%18 = OpLoad %v3ulong %__spirv_BuiltInGlobalInvocationId
|
||||
%19 = OpCompositeExtract %ulong %18 0
|
||||
%20 = OpUConvert %uint %19
|
||||
%21 = OpSConvert %ulong %20
|
||||
%22 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %lhs %21
|
||||
%23 = OpLoad %uint %22 Aligned 4
|
||||
%24 = OpSConvert %ulong %20
|
||||
%25 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %rhs %24
|
||||
%26 = OpLoad %uint %25 Aligned 4
|
||||
%27 = OpBitwiseAnd %uint %26 %uint_31
|
||||
%8 = OpShiftLeftLogical %uint %23 %27
|
||||
%28 = OpSConvert %ulong %20
|
||||
%29 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %out %28
|
||||
OpStore %29 %8 Aligned 4
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
@@ -0,0 +1,47 @@
|
||||
; SPIR-V
|
||||
; Version: 1.4
|
||||
; Generator: Khronos SPIR-V Tools Assembler; 0
|
||||
; Bound: 25
|
||||
; Schema: 0
|
||||
OpCapability Addresses
|
||||
OpCapability Linkage
|
||||
OpCapability Kernel
|
||||
OpMemoryModel Physical32 OpenCL
|
||||
OpEntryPoint Kernel %2 "fmath_cl" %__spirv_BuiltInGlobalInvocationId
|
||||
OpSource OpenCL_C 200000
|
||||
OpName %__spirv_BuiltInGlobalInvocationId "__spirv_BuiltInGlobalInvocationId"
|
||||
OpName %out "out"
|
||||
OpName %lhs "lhs"
|
||||
OpName %rhs "rhs"
|
||||
OpDecorate %7 FuncParamAttr NoWrite
|
||||
%7 = OpDecorationGroup
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId BuiltIn GlobalInvocationId
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId Constant
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId LinkageAttributes "__spirv_BuiltInGlobalInvocationId" Import
|
||||
OpDecorate %8 NoUnsignedWrap
|
||||
OpGroupDecorate %7 %lhs %rhs
|
||||
%uint = OpTypeInt 32 0
|
||||
%uint_31 = OpConstant %uint 31
|
||||
%v3uint = OpTypeVector %uint 3
|
||||
%_ptr_Input_v3uint = OpTypePointer Input %v3uint
|
||||
%void = OpTypeVoid
|
||||
%_ptr_CrossWorkgroup_uint = OpTypePointer CrossWorkgroup %uint
|
||||
%15 = OpTypeFunction %void %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint
|
||||
%__spirv_BuiltInGlobalInvocationId = OpVariable %_ptr_Input_v3uint Input
|
||||
%2 = OpFunction %void None %15
|
||||
%out = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%lhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%rhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%16 = OpLabel
|
||||
%17 = OpLoad %v3uint %__spirv_BuiltInGlobalInvocationId
|
||||
%18 = OpCompositeExtract %uint %17 0
|
||||
%19 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %lhs %18
|
||||
%20 = OpLoad %uint %19 Aligned 4
|
||||
%21 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %rhs %18
|
||||
%22 = OpLoad %uint %21 Aligned 4
|
||||
%23 = OpBitwiseAnd %uint %22 %uint_31
|
||||
%8 = OpShiftLeftLogical %uint %20 %23
|
||||
%24 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %out %18
|
||||
OpStore %24 %8 Aligned 4
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
@@ -0,0 +1,53 @@
|
||||
; SPIR-V
|
||||
; Version: 1.4
|
||||
; Generator: Khronos SPIR-V Tools Assembler; 0
|
||||
; Bound: 30
|
||||
; Schema: 0
|
||||
OpCapability Addresses
|
||||
OpCapability Linkage
|
||||
OpCapability Kernel
|
||||
OpCapability Int64
|
||||
OpMemoryModel Physical64 OpenCL
|
||||
OpEntryPoint Kernel %2 "fmath_cl" %__spirv_BuiltInGlobalInvocationId
|
||||
OpSource OpenCL_C 200000
|
||||
OpName %__spirv_BuiltInGlobalInvocationId "__spirv_BuiltInGlobalInvocationId"
|
||||
OpName %out "out"
|
||||
OpName %lhs "lhs"
|
||||
OpName %rhs "rhs"
|
||||
OpDecorate %7 FuncParamAttr NoWrite
|
||||
%7 = OpDecorationGroup
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId BuiltIn GlobalInvocationId
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId Constant
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId LinkageAttributes "__spirv_BuiltInGlobalInvocationId" Import
|
||||
OpDecorate %8 NoUnsignedWrap
|
||||
OpGroupDecorate %7 %lhs %rhs
|
||||
%ulong = OpTypeInt 64 0
|
||||
%uint = OpTypeInt 32 0
|
||||
%uint_31 = OpConstant %uint 31
|
||||
%v3ulong = OpTypeVector %ulong 3
|
||||
%_ptr_Input_v3ulong = OpTypePointer Input %v3ulong
|
||||
%void = OpTypeVoid
|
||||
%_ptr_CrossWorkgroup_uint = OpTypePointer CrossWorkgroup %uint
|
||||
%16 = OpTypeFunction %void %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint
|
||||
%__spirv_BuiltInGlobalInvocationId = OpVariable %_ptr_Input_v3ulong Input
|
||||
%2 = OpFunction %void None %16
|
||||
%out = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%lhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%rhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%17 = OpLabel
|
||||
%18 = OpLoad %v3ulong %__spirv_BuiltInGlobalInvocationId
|
||||
%19 = OpCompositeExtract %ulong %18 0
|
||||
%20 = OpUConvert %uint %19
|
||||
%21 = OpSConvert %ulong %20
|
||||
%22 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %lhs %21
|
||||
%23 = OpLoad %uint %22 Aligned 4
|
||||
%24 = OpSConvert %ulong %20
|
||||
%25 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %rhs %24
|
||||
%26 = OpLoad %uint %25 Aligned 4
|
||||
%27 = OpBitwiseAnd %uint %26 %uint_31
|
||||
%8 = OpShiftLeftLogical %uint %23 %27
|
||||
%28 = OpSConvert %ulong %20
|
||||
%29 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %out %28
|
||||
OpStore %29 %8 Aligned 4
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
@@ -0,0 +1,45 @@
|
||||
; SPIR-V
|
||||
; Version: 1.4
|
||||
; Generator: Khronos SPIR-V Tools Assembler; 0
|
||||
; Bound: 23
|
||||
; Schema: 0
|
||||
OpCapability Addresses
|
||||
OpCapability Linkage
|
||||
OpCapability Kernel
|
||||
OpMemoryModel Physical32 OpenCL
|
||||
OpEntryPoint Kernel %2 "fmath_cl" %__spirv_BuiltInGlobalInvocationId
|
||||
OpSource OpenCL_C 200000
|
||||
OpName %__spirv_BuiltInGlobalInvocationId "__spirv_BuiltInGlobalInvocationId"
|
||||
OpName %out "out"
|
||||
OpName %lhs "lhs"
|
||||
OpName %rhs "rhs"
|
||||
OpDecorate %7 FuncParamAttr NoWrite
|
||||
%7 = OpDecorationGroup
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId BuiltIn GlobalInvocationId
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId Constant
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId LinkageAttributes "__spirv_BuiltInGlobalInvocationId" Import
|
||||
OpGroupDecorate %7 %lhs %rhs
|
||||
OpDecorate %8 NoSignedWrap
|
||||
%uint = OpTypeInt 32 0
|
||||
%v3uint = OpTypeVector %uint 3
|
||||
%_ptr_Input_v3uint = OpTypePointer Input %v3uint
|
||||
%void = OpTypeVoid
|
||||
%_ptr_CrossWorkgroup_uint = OpTypePointer CrossWorkgroup %uint
|
||||
%14 = OpTypeFunction %void %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint
|
||||
%__spirv_BuiltInGlobalInvocationId = OpVariable %_ptr_Input_v3uint Input
|
||||
%2 = OpFunction %void None %14
|
||||
%out = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%lhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%rhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%15 = OpLabel
|
||||
%16 = OpLoad %v3uint %__spirv_BuiltInGlobalInvocationId
|
||||
%17 = OpCompositeExtract %uint %16 0
|
||||
%18 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %lhs %17
|
||||
%19 = OpLoad %uint %18 Aligned 4
|
||||
%20 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %rhs %17
|
||||
%21 = OpLoad %uint %20 Aligned 4
|
||||
%8 = OpISub %uint %19 %21
|
||||
%22 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %out %17
|
||||
OpStore %22 %8 Aligned 4
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
@@ -0,0 +1,51 @@
|
||||
; SPIR-V
|
||||
; Version: 1.4
|
||||
; Generator: Khronos SPIR-V Tools Assembler; 0
|
||||
; Bound: 28
|
||||
; Schema: 0
|
||||
OpCapability Addresses
|
||||
OpCapability Linkage
|
||||
OpCapability Kernel
|
||||
OpCapability Int64
|
||||
OpMemoryModel Physical64 OpenCL
|
||||
OpEntryPoint Kernel %2 "fmath_cl" %__spirv_BuiltInGlobalInvocationId
|
||||
OpSource OpenCL_C 200000
|
||||
OpName %__spirv_BuiltInGlobalInvocationId "__spirv_BuiltInGlobalInvocationId"
|
||||
OpName %out "out"
|
||||
OpName %lhs "lhs"
|
||||
OpName %rhs "rhs"
|
||||
OpDecorate %7 FuncParamAttr NoWrite
|
||||
%7 = OpDecorationGroup
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId BuiltIn GlobalInvocationId
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId Constant
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId LinkageAttributes "__spirv_BuiltInGlobalInvocationId" Import
|
||||
OpGroupDecorate %7 %lhs %rhs
|
||||
OpDecorate %8 NoSignedWrap
|
||||
%ulong = OpTypeInt 64 0
|
||||
%uint = OpTypeInt 32 0
|
||||
%v3ulong = OpTypeVector %ulong 3
|
||||
%_ptr_Input_v3ulong = OpTypePointer Input %v3ulong
|
||||
%void = OpTypeVoid
|
||||
%_ptr_CrossWorkgroup_uint = OpTypePointer CrossWorkgroup %uint
|
||||
%15 = OpTypeFunction %void %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint
|
||||
%__spirv_BuiltInGlobalInvocationId = OpVariable %_ptr_Input_v3ulong Input
|
||||
%2 = OpFunction %void None %15
|
||||
%out = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%lhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%rhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%16 = OpLabel
|
||||
%17 = OpLoad %v3ulong %__spirv_BuiltInGlobalInvocationId
|
||||
%18 = OpCompositeExtract %ulong %17 0
|
||||
%19 = OpUConvert %uint %18
|
||||
%20 = OpSConvert %ulong %19
|
||||
%21 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %lhs %20
|
||||
%22 = OpLoad %uint %21 Aligned 4
|
||||
%23 = OpSConvert %ulong %19
|
||||
%24 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %rhs %23
|
||||
%25 = OpLoad %uint %24 Aligned 4
|
||||
%8 = OpISub %uint %22 %25
|
||||
%26 = OpSConvert %ulong %19
|
||||
%27 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %out %26
|
||||
OpStore %27 %8 Aligned 4
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
@@ -0,0 +1,45 @@
|
||||
; SPIR-V
|
||||
; Version: 1.4
|
||||
; Generator: Khronos SPIR-V Tools Assembler; 0
|
||||
; Bound: 23
|
||||
; Schema: 0
|
||||
OpCapability Addresses
|
||||
OpCapability Linkage
|
||||
OpCapability Kernel
|
||||
OpMemoryModel Physical32 OpenCL
|
||||
OpEntryPoint Kernel %2 "fmath_cl" %__spirv_BuiltInGlobalInvocationId
|
||||
OpSource OpenCL_C 200000
|
||||
OpName %__spirv_BuiltInGlobalInvocationId "__spirv_BuiltInGlobalInvocationId"
|
||||
OpName %out "out"
|
||||
OpName %lhs "lhs"
|
||||
OpName %rhs "rhs"
|
||||
OpDecorate %7 FuncParamAttr NoWrite
|
||||
%7 = OpDecorationGroup
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId BuiltIn GlobalInvocationId
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId Constant
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId LinkageAttributes "__spirv_BuiltInGlobalInvocationId" Import
|
||||
OpGroupDecorate %7 %lhs %rhs
|
||||
OpDecorate %8 NoUnsignedWrap
|
||||
%uint = OpTypeInt 32 0
|
||||
%v3uint = OpTypeVector %uint 3
|
||||
%_ptr_Input_v3uint = OpTypePointer Input %v3uint
|
||||
%void = OpTypeVoid
|
||||
%_ptr_CrossWorkgroup_uint = OpTypePointer CrossWorkgroup %uint
|
||||
%14 = OpTypeFunction %void %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint
|
||||
%__spirv_BuiltInGlobalInvocationId = OpVariable %_ptr_Input_v3uint Input
|
||||
%2 = OpFunction %void None %14
|
||||
%out = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%lhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%rhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%15 = OpLabel
|
||||
%16 = OpLoad %v3uint %__spirv_BuiltInGlobalInvocationId
|
||||
%17 = OpCompositeExtract %uint %16 0
|
||||
%18 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %lhs %17
|
||||
%19 = OpLoad %uint %18 Aligned 4
|
||||
%20 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %rhs %17
|
||||
%21 = OpLoad %uint %20 Aligned 4
|
||||
%8 = OpISub %uint %19 %21
|
||||
%22 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %out %17
|
||||
OpStore %22 %8 Aligned 4
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
@@ -0,0 +1,51 @@
|
||||
; SPIR-V
|
||||
; Version: 1.4
|
||||
; Generator: Khronos SPIR-V Tools Assembler; 0
|
||||
; Bound: 28
|
||||
; Schema: 0
|
||||
OpCapability Addresses
|
||||
OpCapability Linkage
|
||||
OpCapability Kernel
|
||||
OpCapability Int64
|
||||
OpMemoryModel Physical64 OpenCL
|
||||
OpEntryPoint Kernel %2 "fmath_cl" %__spirv_BuiltInGlobalInvocationId
|
||||
OpSource OpenCL_C 200000
|
||||
OpName %__spirv_BuiltInGlobalInvocationId "__spirv_BuiltInGlobalInvocationId"
|
||||
OpName %out "out"
|
||||
OpName %lhs "lhs"
|
||||
OpName %rhs "rhs"
|
||||
OpDecorate %7 FuncParamAttr NoWrite
|
||||
%7 = OpDecorationGroup
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId BuiltIn GlobalInvocationId
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId Constant
|
||||
OpDecorate %__spirv_BuiltInGlobalInvocationId LinkageAttributes "__spirv_BuiltInGlobalInvocationId" Import
|
||||
OpGroupDecorate %7 %lhs %rhs
|
||||
OpDecorate %8 NoUnsignedWrap
|
||||
%ulong = OpTypeInt 64 0
|
||||
%uint = OpTypeInt 32 0
|
||||
%v3ulong = OpTypeVector %ulong 3
|
||||
%_ptr_Input_v3ulong = OpTypePointer Input %v3ulong
|
||||
%void = OpTypeVoid
|
||||
%_ptr_CrossWorkgroup_uint = OpTypePointer CrossWorkgroup %uint
|
||||
%15 = OpTypeFunction %void %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint
|
||||
%__spirv_BuiltInGlobalInvocationId = OpVariable %_ptr_Input_v3ulong Input
|
||||
%2 = OpFunction %void None %15
|
||||
%out = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%lhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%rhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint
|
||||
%16 = OpLabel
|
||||
%17 = OpLoad %v3ulong %__spirv_BuiltInGlobalInvocationId
|
||||
%18 = OpCompositeExtract %ulong %17 0
|
||||
%19 = OpUConvert %uint %18
|
||||
%20 = OpSConvert %ulong %19
|
||||
%21 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %lhs %20
|
||||
%22 = OpLoad %uint %21 Aligned 4
|
||||
%23 = OpSConvert %ulong %19
|
||||
%24 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %rhs %23
|
||||
%25 = OpLoad %uint %24 Aligned 4
|
||||
%8 = OpISub %uint %22 %25
|
||||
%26 = OpSConvert %ulong %19
|
||||
%27 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %out %26
|
||||
OpStore %27 %8 Aligned 4
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
Reference in New Issue
Block a user