1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py UTC_ARGS: --version 5
2 ; RUN: llc -verify-machineinstrs -mtriple=powerpc64-ibm-aix < %s | FileCheck %s
4 target datalayout = "E-m:a-Fi64-i64:64-n32:64-S128-v256:256:256-v512:512:512"
6 define void @baz(i64 %arg) local_unnamed_addr #0 {
8 ; CHECK: # %bb.0: # %bb
9 ; CHECK-NEXT: xxmfacc 0
10 ; CHECK-NEXT: xxmrgld 0, 0, 2
11 ; CHECK-NEXT: xxlxor 1, 1, 1
12 ; CHECK-NEXT: xvnegdp 2, 0
13 ; CHECK-NEXT: xvnegdp 0, 0
14 ; CHECK-NEXT: xvsubdp 2, 2, 1
15 ; CHECK-NEXT: xvsubdp 0, 0, 3
16 ; CHECK-NEXT: xvmuldp 2, 2, 1
17 ; CHECK-NEXT: xvmuldp 0, 0, 1
18 ; CHECK-NEXT: xvmaddadp 2, 1, 1
19 ; CHECK-NEXT: xvmaddadp 0, 1, 1
20 ; CHECK-NEXT: stxv 2, 0(3)
21 ; CHECK-NEXT: stxv 0, 0(3)
22 ; CHECK-NEXT: # implicit-def: $acc0
23 ; CHECK-NEXT: bc 12, 20, L..BB0_2
24 ; CHECK-NEXT: # %bb.1: # %bb10
25 ; CHECK-NEXT: xvf64gerpp 0, 34, 0
26 ; CHECK-NEXT: L..BB0_2: # %bb12
27 ; CHECK-NEXT: cmpdi 3, 0
28 ; CHECK-NEXT: L..BB0_3: # %bb13
30 ; CHECK-NEXT: bc 4, 2, L..BB0_3
31 ; CHECK-NEXT: # %bb.4: # %bb14
32 ; CHECK-NEXT: xxmfacc 0
33 ; CHECK-NEXT: xxlxor 0, 0, 0
34 ; CHECK-NEXT: xxlxor 2, 2, 2
35 ; CHECK-NEXT: xvsubdp 1, 0, 1
36 ; CHECK-NEXT: xvmaddadp 2, 1, 2
37 ; CHECK-NEXT: xvadddp 0, 2, 0
38 ; CHECK-NEXT: xxswapd 0, 0
39 ; CHECK-NEXT: stxv 0, 0(3)
42 %call = tail call { <16 x i8>, <16 x i8>, <16 x i8>, <16 x i8> } @llvm.ppc.mma.disassemble.acc(<512 x i1> poison)
43 %extractvalue = extractvalue { <16 x i8>, <16 x i8>, <16 x i8>, <16 x i8> } %call, 0
44 %extractvalue1 = extractvalue { <16 x i8>, <16 x i8>, <16 x i8>, <16 x i8> } %call, 2
45 %extractvalue2 = extractvalue { <16 x i8>, <16 x i8>, <16 x i8>, <16 x i8> } %call, 3
46 %bitcast = bitcast <16 x i8> %extractvalue to <2 x double>
47 %bitcast3 = bitcast <16 x i8> %extractvalue1 to <2 x double>
48 %shufflevector = shufflevector <2 x double> %bitcast, <2 x double> %bitcast3, <2 x i32> <i32 1, i32 3>
49 %shufflevector4 = shufflevector <2 x double> %shufflevector, <2 x double> poison, <4 x i32> <i32 0, i32 poison, i32 1, i32 poison>
50 %fneg = fneg <4 x double> %shufflevector4
51 %shufflevector5 = shufflevector <4 x double> %fneg, <4 x double> poison, <4 x i32> <i32 0, i32 5, i32 2, i32 7>
52 %shufflevector6 = shufflevector <16 x i8> zeroinitializer, <16 x i8> %extractvalue2, <32 x i32> <i32 0, i32 1, i32 2, i32 3, i32 4, i32 5, i32 6, i32 7, i32 8, i32 9, i32 10, i32 11, i32 12, i32 13, i32 14, i32 15, i32 16, i32 17, i32 18, i32 19, i32 20, i32 21, i32 22, i32 23, i32 24, i32 25, i32 26, i32 27, i32 28, i32 29, i32 30, i32 31>
53 %bitcast7 = bitcast <32 x i8> %shufflevector6 to <4 x double>
54 %fsub = fsub <4 x double> %shufflevector5, %bitcast7
55 %shufflevector8 = shufflevector <4 x double> poison, <4 x double> %fsub, <4 x i32> <i32 0, i32 5, i32 2, i32 7>
56 %fmul = fmul <4 x double> %shufflevector8, zeroinitializer
57 %call9 = tail call <4 x double> @llvm.fmuladd.v4f64(<4 x double> zeroinitializer, <4 x double> zeroinitializer, <4 x double> %fmul)
58 %fadd = fadd <4 x double> %call9, zeroinitializer
59 store <4 x double> %fadd, ptr poison, align 4
60 br i1 poison, label %bb10, label %bb12
63 %call11 = tail call <512 x i1> @llvm.ppc.mma.xvf64gerpp(<512 x i1> poison, <256 x i1> poison, <16 x i8> poison)
66 bb12: ; preds = %bb10, %bb
67 %phi = phi <512 x i1> [ poison, %bb ], [ %call11, %bb10 ]
70 bb13: ; preds = %bb13, %bb12
71 %icmp = icmp eq i64 0, %arg
72 br i1 %icmp, label %bb14, label %bb13
75 %call15 = tail call { <16 x i8>, <16 x i8>, <16 x i8>, <16 x i8> } @llvm.ppc.mma.disassemble.acc(<512 x i1> poison)
76 %extractvalue16 = extractvalue { <16 x i8>, <16 x i8>, <16 x i8>, <16 x i8> } %call15, 1
77 %call17 = tail call { <16 x i8>, <16 x i8>, <16 x i8>, <16 x i8> } @llvm.ppc.mma.disassemble.acc(<512 x i1> %phi)
78 %extractvalue18 = extractvalue { <16 x i8>, <16 x i8>, <16 x i8>, <16 x i8> } %call17, 1
79 %bitcast19 = bitcast <16 x i8> %extractvalue16 to <2 x double>
80 %bitcast20 = bitcast <16 x i8> %extractvalue18 to <2 x double>
81 %fsub21 = fsub <2 x double> zeroinitializer, %bitcast19
82 %fadd22 = fadd <2 x double> zeroinitializer, %fsub21
83 %fadd23 = fadd <2 x double> %fadd22, zeroinitializer
84 %fsub24 = fsub <2 x double> zeroinitializer, %bitcast20
85 %fadd25 = fadd <2 x double> zeroinitializer, %fsub24
86 %fadd26 = fadd <2 x double> %fadd25, zeroinitializer
87 %fadd27 = fadd <2 x double> %fadd26, zeroinitializer
88 %call28 = tail call <2 x double> @llvm.fmuladd.v2f64(<2 x double> %fadd27, <2 x double> zeroinitializer, <2 x double> zeroinitializer)
89 %fadd29 = fadd <2 x double> zeroinitializer, %call28
90 %shufflevector30 = shufflevector <2 x double> %fadd29, <2 x double> poison, <2 x i32> <i32 1, i32 0>
91 store <2 x double> %shufflevector30, ptr poison, align 4
95 ; Function Attrs: nocallback nofree nosync nounwind willreturn memory(none)
96 declare <512 x i1> @llvm.ppc.mma.xxsetaccz() #1
98 ; Function Attrs: nocallback nofree nosync nounwind willreturn memory(none)
99 declare <512 x i1> @llvm.ppc.mma.xvf64gerpp(<512 x i1>, <256 x i1>, <16 x i8>) #1
101 ; Function Attrs: nocallback nofree nosync nounwind willreturn memory(none)
102 declare { <16 x i8>, <16 x i8>, <16 x i8>, <16 x i8> } @llvm.ppc.mma.disassemble.acc(<512 x i1>) #1
104 ; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
105 declare double @llvm.fmuladd.f64(double, double, double) #2
107 ; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
108 declare <2 x double> @llvm.fmuladd.v2f64(<2 x double>, <2 x double>, <2 x double>) #2
110 ; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
111 declare <4 x double> @llvm.fmuladd.v4f64(<4 x double>, <4 x double>, <4 x double>) #2
113 attributes #0 = { "target-features"="+altivec,+bpermd,+crbits,+crypto,+direct-move,+extdiv,+isa-v206-instructions,+isa-v207-instructions,+isa-v30-instructions,+isa-v31-instructions,+mma,+paired-vector-memops,+pcrelative-memops,+power10-vector,+power8-vector,+power9-vector,+prefix-instrs,+quadword-atomics,+vsx,-aix-shared-lib-tls-model-opt,-aix-small-local-dynamic-tls,-aix-small-local-exec-tls,-htm,-privileged,-rop-protect,-spe" }
114 attributes #1 = { nocallback nofree nosync nounwind willreturn memory(none) }
115 attributes #2 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }