1 # RUN: llc -start-after=machine-sink -stop-after=peephole-opt -mtriple=powerpc64-unknown-linux-gnu -o - %s | FileCheck %s
5 source_filename = "<stdin>"
6 target datalayout = "E-m:e-i64:64-n32:64"
7 target triple = "powerpc64-unknown-linux-gnu"
9 ; Function Attrs: nounwind readnone
10 declare i128 @llvm.cttz.i128(i128, i1) #0
12 define void @fn1(i128, i128, i1) {
16 loop: ; preds = %loop, %top
17 %v = phi i128 [ %3, %loop ], [ %0, %top ]
18 %u = phi i128 [ %3, %loop ], [ %1, %top ]
20 %3 = call i128 @llvm.cttz.i128(i128 %s, i1 false)
24 ; Function Attrs: nounwind
25 declare void @llvm.stackprotector(i8*, i8**) #1
27 attributes #0 = { nounwind readnone }
28 attributes #1 = { nounwind }
34 exposesReturnsTwice: false
35 tracksRegLiveness: true
37 - { id: 0, class: g8rc }
38 - { id: 1, class: g8rc }
39 - { id: 2, class: g8rc }
40 - { id: 3, class: g8rc }
41 - { id: 4, class: g8rc }
42 - { id: 5, class: g8rc }
43 - { id: 6, class: g8rc }
44 - { id: 7, class: g8rc }
45 - { id: 8, class: g8rc }
46 - { id: 9, class: g8rc }
47 - { id: 10, class: g8rc }
48 - { id: 11, class: g8rc }
49 - { id: 12, class: g8rc }
50 - { id: 13, class: g8rc }
51 - { id: 14, class: g8rc }
52 - { id: 15, class: g8rc_and_g8rc_nox0 }
53 - { id: 16, class: g8rc_and_g8rc_nox0 }
54 - { id: 17, class: g8rc }
55 - { id: 18, class: g8rc }
56 - { id: 19, class: g8rc }
57 - { id: 20, class: g8rc }
58 - { id: 21, class: g8rc }
59 - { id: 22, class: g8rc }
60 - { id: 23, class: g8rc }
61 - { id: 24, class: g8rc }
62 - { id: 25, class: crrc }
63 - { id: 26, class: g8rc_and_g8rc_nox0 }
64 - { id: 27, class: g8rc_and_g8rc_nox0 }
66 - { reg: '$x3', virtual-reg: '%6' }
67 - { reg: '$x4', virtual-reg: '%7' }
68 - { reg: '$x5', virtual-reg: '%8' }
69 - { reg: '$x6', virtual-reg: '%9' }
71 isFrameAddressTaken: false
72 isReturnAddressTaken: false
81 hasOpaqueSPAdjustment: false
83 hasMustTailInVarArgFunc: false
86 successors: %bb.1.loop
87 liveins: $x3, $x4, $x5, $x6
101 successors: %bb.2.loop, %bb.4
103 %0 = PHI %11, %bb.0.top, %4, %bb.3.loop
104 %1 = PHI %12, %bb.0.top, %5, %bb.3.loop
105 %2 = PHI %13, %bb.0.top, %4, %bb.3.loop
106 %3 = PHI %14, %bb.0.top, %5, %bb.3.loop
107 %15 = SUBFC8 %3, %1, implicit-def $carry
108 %16 = SUBFE8 %2, %0, implicit-def dead $carry, implicit $carry
111 %19 = ANDC8 killed %17, %16
112 %20 = ANDC8 killed %18, %15
113 %22 = CNTLZD killed %19
114 %24 = CNTLZD killed %20
116 BCC 76, %25, %bb.2.loop
117 ; CHECK: SUBFC8o %3, %1, implicit-def $carry, implicit-def $cr0
118 ; CHECK: COPY killed $cr0
122 successors: %bb.3.loop
128 successors: %bb.3.loop
133 successors: %bb.1.loop
135 %5 = PHI %26, %bb.2.loop, %27, %bb.4