forked from KhronosGroup/SPIRV-LLVM-Translator
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathOpFMul.spvasm
More file actions
55 lines (54 loc) · 1.99 KB
/
OpFMul.spvasm
File metadata and controls
55 lines (54 loc) · 1.99 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
; REQUIRES: spirv-as
; RUN: spirv-as --target-env spv1.0 -o %t.spv %s
; RUN: spirv-val %t.spv
; RUN: llvm-spirv -r -o - %t.spv | llvm-dis | FileCheck %s
OpCapability Addresses
OpCapability Kernel
OpMemoryModel Physical32 OpenCL
OpEntryPoint Kernel %1 "testFMul"
OpName %a "a"
OpName %b "b"
OpName %r1 "r1"
OpName %r2 "r2"
OpName %r3 "r3"
OpName %r4 "r4"
OpName %r5 "r5"
OpName %r6 "r6"
OpName %r7 "r7"
OpName %r8 "r8"
OpName %r9 "r9"
OpDecorate %r2 FPFastMathMode None
OpDecorate %r3 FPFastMathMode NotNaN
OpDecorate %r4 FPFastMathMode NotInf
OpDecorate %r5 FPFastMathMode NSZ
OpDecorate %r6 FPFastMathMode AllowRecip
OpDecorate %r7 FPFastMathMode Fast
OpDecorate %r8 FPFastMathMode NotNaN|NotInf
OpDecorate %r9 FPFastMathMode NotNaN|Fast
%void = OpTypeVoid
%float = OpTypeFloat 32
%5 = OpTypeFunction %void %float %float
%1 = OpFunction %void None %5
%a = OpFunctionParameter %float
%b = OpFunctionParameter %float
%6 = OpLabel
%r1 = OpFMul %float %a %b
%r2 = OpFMul %float %a %b
%r3 = OpFMul %float %a %b
%r4 = OpFMul %float %a %b
%r5 = OpFMul %float %a %b
%r6 = OpFMul %float %a %b
%r7 = OpFMul %float %a %b
%r8 = OpFMul %float %a %b
%r9 = OpFMul %float %a %b
OpReturn
OpFunctionEnd
; CHECK: %r1 = fmul float %a, %b
; CHECK: %r2 = fmul float %a, %b
; CHECK: %r3 = fmul nnan float %a, %b
; CHECK: %r4 = fmul ninf float %a, %b
; CHECK: %r5 = fmul nsz float %a, %b
; CHECK: %r6 = fmul arcp float %a, %b
; CHECK: %r7 = fmul fast float %a, %b
; CHECK: %r8 = fmul nnan ninf float %a, %b
; CHECK: %r9 = fmul fast float %a, %b