• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
2; RUN: opt < %s -basic-aa -slp-vectorizer -dce -S -mtriple=x86_64-apple-macosx10.8.0 -mcpu=corei7 | FileCheck %s
3
4target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128-n8:16:32:64-S128"
5target triple = "x86_64-apple-macosx10.8.0"
6
7define void @updateModelQPFrame(i32 %m_Bits) {
8; CHECK-LABEL: @updateModelQPFrame(
9; CHECK-NEXT:  entry:
10; CHECK-NEXT:    ret void
11;
12entry:
13  %0 = load double, double* undef, align 8
14  %mul = fmul double undef, %0
15  %mul2 = fmul double undef, %mul
16  %mul4 = fmul double %0, %mul2
17  %mul5 = fmul double undef, 4.000000e+00
18  %mul7 = fmul double undef, %mul5
19  %conv = sitofp i32 %m_Bits to double
20  %mul8 = fmul double %conv, %mul7
21  %add = fadd double %mul4, %mul8
22  %cmp11 = fcmp olt double %add, 0.000000e+00
23  ret void
24}
25
26declare i8* @objc_msgSend(i8*, i8*, ...)
27declare i32 @personality_v0(...)
28
29define void @invoketest() personality i8* bitcast (i32 (...)* @personality_v0 to i8*) {
30; CHECK-LABEL: @invoketest(
31; CHECK-NEXT:  entry:
32; CHECK-NEXT:    br i1 undef, label [[COND_TRUE:%.*]], label [[COND_FALSE:%.*]]
33; CHECK:       cond.true:
34; CHECK-NEXT:    [[CALL49:%.*]] = invoke double bitcast (i8* (i8*, i8*, ...)* @objc_msgSend to double (i8*, i8*)*)(i8* undef, i8* undef)
35; CHECK-NEXT:    to label [[COND_TRUE54:%.*]] unwind label [[LPAD:%.*]]
36; CHECK:       cond.false:
37; CHECK-NEXT:    [[CALL51:%.*]] = invoke double bitcast (i8* (i8*, i8*, ...)* @objc_msgSend to double (i8*, i8*)*)(i8* undef, i8* undef)
38; CHECK-NEXT:    to label [[COND_FALSE57:%.*]] unwind label [[LPAD]]
39; CHECK:       cond.true54:
40; CHECK-NEXT:    [[CALL56:%.*]] = invoke double bitcast (i8* (i8*, i8*, ...)* @objc_msgSend to double (i8*, i8*)*)(i8* undef, i8* undef)
41; CHECK-NEXT:    to label [[COND_END60:%.*]] unwind label [[LPAD]]
42; CHECK:       cond.false57:
43; CHECK-NEXT:    [[CALL59:%.*]] = invoke double bitcast (i8* (i8*, i8*, ...)* @objc_msgSend to double (i8*, i8*)*)(i8* undef, i8* undef)
44; CHECK-NEXT:    to label [[COND_END60]] unwind label [[LPAD]]
45; CHECK:       cond.end60:
46; CHECK-NEXT:    br i1 undef, label [[IF_END98:%.*]], label [[IF_THEN63:%.*]]
47; CHECK:       if.then63:
48; CHECK-NEXT:    br label [[IF_END98]]
49; CHECK:       lpad:
50; CHECK-NEXT:    [[L:%.*]] = landingpad { i8*, i32 }
51; CHECK-NEXT:    cleanup
52; CHECK-NEXT:    resume { i8*, i32 } [[L]]
53; CHECK:       if.end98:
54; CHECK-NEXT:    br label [[IF_END99:%.*]]
55; CHECK:       if.end99:
56; CHECK-NEXT:    ret void
57;
58entry:
59  br i1 undef, label %cond.true, label %cond.false
60
61cond.true:
62  %call49 = invoke double bitcast (i8* (i8*, i8*, ...)* @objc_msgSend to double (i8*, i8*)*)(i8* undef, i8* undef)
63  to label %cond.true54 unwind label %lpad
64
65cond.false:
66  %call51 = invoke double bitcast (i8* (i8*, i8*, ...)* @objc_msgSend to double (i8*, i8*)*)(i8* undef, i8* undef)
67  to label %cond.false57 unwind label %lpad
68
69cond.true54:
70  %call56 = invoke double bitcast (i8* (i8*, i8*, ...)* @objc_msgSend to double (i8*, i8*)*)(i8* undef, i8* undef)
71  to label %cond.end60 unwind label %lpad
72
73cond.false57:
74  %call59 = invoke double bitcast (i8* (i8*, i8*, ...)* @objc_msgSend to double (i8*, i8*)*)(i8* undef, i8* undef)
75  to label %cond.end60 unwind label %lpad
76
77cond.end60:
78  %cond126 = phi double [ %call49, %cond.true54 ], [ %call51, %cond.false57 ]
79  %cond61 = phi double [ %call56, %cond.true54 ], [ %call59, %cond.false57 ]
80  br i1 undef, label %if.end98, label %if.then63
81
82if.then63:
83  %conv69 = fptrunc double undef to float
84  %conv70 = fpext float %conv69 to double
85  %div71 = fdiv double %cond126, %conv70
86  %conv78 = fptrunc double undef to float
87  %conv79 = fpext float %conv78 to double
88  %div80 = fdiv double %cond61, %conv79
89  br label %if.end98
90
91lpad:
92  %l = landingpad { i8*, i32 }
93  cleanup
94  resume { i8*, i32 } %l
95
96if.end98:
97  %dimensionsResult.sroa.0.0 = phi double [ %div71, %if.then63 ], [ %cond126, %cond.end60 ]
98  %dimensionsResult.sroa.6.0 = phi double [ %div80, %if.then63 ], [ %cond61, %cond.end60 ]
99  br label %if.end99
100
101if.end99:
102  ret void
103}
104