blob: a0dac7a29cc8144277791c54a5f735eaa21ebeec [file] [log] [blame]
Dan Gohman18800922009-09-11 18:01:28 +00001; RUN: opt < %s -indvars -disable-output
Chris Lattner02fd7d12005-02-17 16:53:41 +00002
Tanya Lattner5640bd12008-03-01 09:15:35 +00003declare void @q_atomic_increment()
Chris Lattner02fd7d12005-02-17 16:53:41 +00004
Tanya Lattner5640bd12008-03-01 09:15:35 +00005declare void @_Z9qt_assertPKcS0_i()
Chris Lattner02fd7d12005-02-17 16:53:41 +00006
David Majnemer7fddecc2015-06-17 20:52:32 +00007define void @_ZN13QMetaResourceC1EPKh() personality i32 (...)* @__gxx_personality_v0 {
Chris Lattner02fd7d12005-02-17 16:53:41 +00008entry:
Tanya Lattner5640bd12008-03-01 09:15:35 +00009 invoke void @_Z9qt_assertPKcS0_i( )
Chris Lattner02fd7d12005-02-17 16:53:41 +000010 to label %endif.1 unwind label %then.i.i551
11
12then.i.i551: ; preds = %entry
David Majnemer7fddecc2015-06-17 20:52:32 +000013 %exn551 = landingpad {i8*, i32}
Bill Wendling3b17c1b2011-09-01 01:02:41 +000014 cleanup
Chris Lattner02fd7d12005-02-17 16:53:41 +000015 ret void
16
17endif.1: ; preds = %entry
Tanya Lattner5640bd12008-03-01 09:15:35 +000018 br i1 false, label %then.2, label %then.i.i
Chris Lattner02fd7d12005-02-17 16:53:41 +000019
20then.2: ; preds = %endif.1
Tanya Lattner5640bd12008-03-01 09:15:35 +000021 invoke void @q_atomic_increment( )
Chris Lattner02fd7d12005-02-17 16:53:41 +000022 to label %loopentry.0 unwind label %invoke_catch.6
23
24invoke_catch.6: ; preds = %then.2
David Majnemer7fddecc2015-06-17 20:52:32 +000025 %exn6 = landingpad {i8*, i32}
Bill Wendling3b17c1b2011-09-01 01:02:41 +000026 cleanup
Chris Lattner02fd7d12005-02-17 16:53:41 +000027 ret void
28
29loopentry.0: ; preds = %then.2
Tanya Lattner5640bd12008-03-01 09:15:35 +000030 br i1 false, label %shortcirc_next.i, label %endif.3
Chris Lattner02fd7d12005-02-17 16:53:41 +000031
32endif.3: ; preds = %loopentry.0
33 ret void
34
35shortcirc_next.i: ; preds = %loopentry.0
Tanya Lattner5640bd12008-03-01 09:15:35 +000036 br i1 false, label %_ZNK7QString2atEi.exit, label %then.i
Chris Lattner02fd7d12005-02-17 16:53:41 +000037
38then.i: ; preds = %shortcirc_next.i
39 ret void
40
41_ZNK7QString2atEi.exit: ; preds = %shortcirc_next.i
Tanya Lattner5640bd12008-03-01 09:15:35 +000042 br i1 false, label %endif.4, label %then.4
Chris Lattner02fd7d12005-02-17 16:53:41 +000043
44then.4: ; preds = %_ZNK7QString2atEi.exit
45 ret void
46
47endif.4: ; preds = %_ZNK7QString2atEi.exit
David Blaikiea79ac142015-02-27 21:17:42 +000048 %tmp.115 = load i8, i8* null ; <i8> [#uses=1]
Tanya Lattner5640bd12008-03-01 09:15:35 +000049 br i1 false, label %loopexit.1, label %no_exit.0
Chris Lattner02fd7d12005-02-17 16:53:41 +000050
51no_exit.0: ; preds = %no_exit.0, %endif.4
Tanya Lattner5640bd12008-03-01 09:15:35 +000052 %bytes_in_len.4.5 = phi i8 [ %dec, %no_exit.0 ], [ %tmp.115, %endif.4 ] ; <i8> [#uses=1]
53 %off.5.5.in = phi i32 [ %off.5.5, %no_exit.0 ], [ 0, %endif.4 ] ; <i32> [#uses=1]
54 %off.5.5 = add i32 %off.5.5.in, 1 ; <i32> [#uses=2]
55 %dec = add i8 %bytes_in_len.4.5, -1 ; <i8> [#uses=2]
56 %tmp.123631 = icmp eq i8 %dec, 0 ; <i1> [#uses=1]
57 br i1 %tmp.123631, label %loopexit.1, label %no_exit.0
Chris Lattner02fd7d12005-02-17 16:53:41 +000058
59loopexit.1: ; preds = %no_exit.0, %endif.4
Tanya Lattner5640bd12008-03-01 09:15:35 +000060 %off.5.in.6 = phi i32 [ 0, %endif.4 ], [ %off.5.5, %no_exit.0 ] ; <i32> [#uses=0]
Chris Lattner02fd7d12005-02-17 16:53:41 +000061 ret void
62
63then.i.i: ; preds = %endif.1
64 ret void
65}
Bill Wendling3b17c1b2011-09-01 01:02:41 +000066
67declare i32 @__gxx_personality_v0(...)