aboutsummaryrefslogtreecommitdiffhomepage
path: root/ptx/src/test/spirv_run/mul_lo.spvtxt
diff options
context:
space:
mode:
authorAndrzej Janik <[email protected]>2020-07-25 00:57:54 +0200
committerAndrzej Janik <[email protected]>2020-07-25 00:57:54 +0200
commitb068a89c38f4b25c3f98ad97676a518a6f4d62a8 (patch)
tree8567ef442b94b594cf1556d21782010a23a4ff40 /ptx/src/test/spirv_run/mul_lo.spvtxt
parent18e5147fdcd6d32294f3349fd5849de43cf01800 (diff)
downloadZLUDA-b068a89c38f4b25c3f98ad97676a518a6f4d62a8.tar.gz
ZLUDA-b068a89c38f4b25c3f98ad97676a518a6f4d62a8.zip
Implement integer multiplication
Diffstat (limited to 'ptx/src/test/spirv_run/mul_lo.spvtxt')
-rw-r--r--ptx/src/test/spirv_run/mul_lo.spvtxt64
1 files changed, 38 insertions, 26 deletions
diff --git a/ptx/src/test/spirv_run/mul_lo.spvtxt b/ptx/src/test/spirv_run/mul_lo.spvtxt
index 66e7bc1..4d7c2d8 100644
--- a/ptx/src/test/spirv_run/mul_lo.spvtxt
+++ b/ptx/src/test/spirv_run/mul_lo.spvtxt
@@ -1,26 +1,38 @@
-OpCapability GenericPointer
-OpCapability Linkage
-OpCapability Addresses
-OpCapability Kernel
-OpCapability Int64
-OpCapability Int8
-%1 = OpExtInstImport "OpenCL.std"
-OpMemoryModel Physical64 OpenCL
-OpEntryPoint Kernel %5 "mul_lo"
-%2 = OpTypeVoid
-%3 = OpTypeInt 64 0
-%4 = OpTypeFunction %2 %3 %3
-%19 = OpTypePointer Generic %3
-%5 = OpFunction %2 None %4
-%6 = OpFunctionParameter %3
-%7 = OpFunctionParameter %3
-%18 = OpLabel
-%13 = OpCopyObject %3 %6
-%14 = OpCopyObject %3 %7
-%15 = OpConvertUToPtr %19 %13
-%16 = OpLoad %3 %15
-%100 = OpCopyObject %3 %16
-%17 = OpConvertUToPtr %19 %14
-OpStore %17 %100
-OpReturn
-OpFunctionEnd
+ OpCapability GenericPointer
+ OpCapability Linkage
+ OpCapability Addresses
+ OpCapability Kernel
+ OpCapability Int64
+ OpCapability Int8
+ %1 = OpExtInstImport "OpenCL.std"
+ OpMemoryModel Physical64 OpenCL
+ OpEntryPoint Kernel %5 "mul_lo"
+ %void = OpTypeVoid
+ %ulong = OpTypeInt 64 0
+ %4 = OpTypeFunction %void %ulong %ulong
+%_ptr_Function_ulong = OpTypePointer Function %ulong
+%_ptr_Generic_ulong = OpTypePointer Generic %ulong
+ %ulong_2 = OpConstant %ulong 2
+ %5 = OpFunction %void None %4
+ %6 = OpFunctionParameter %ulong
+ %7 = OpFunctionParameter %ulong
+ %21 = OpLabel
+ %8 = OpVariable %_ptr_Function_ulong Function
+ %9 = OpVariable %_ptr_Function_ulong Function
+ %10 = OpVariable %_ptr_Function_ulong Function
+ %11 = OpVariable %_ptr_Function_ulong Function
+ OpStore %8 %6
+ OpStore %9 %7
+ %12 = OpLoad %ulong %8
+ %19 = OpConvertUToPtr %_ptr_Generic_ulong %12
+ %13 = OpLoad %ulong %19
+ OpStore %10 %13
+ %14 = OpLoad %ulong %10
+ %15 = OpIMul %ulong %14 %ulong_2
+ OpStore %11 %15
+ %16 = OpLoad %ulong %9
+ %17 = OpLoad %ulong %11
+ %20 = OpConvertUToPtr %_ptr_Generic_ulong %16
+ OpStore %20 %17
+ OpReturn
+ OpFunctionEnd