• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1; RUN: opt < %s -inline -prune-eh -disable-output
2; PR993
3target datalayout = "e-p:32:32"
4target triple = "i386-unknown-openbsd3.9"
5deplibs = [ "stdc++", "c", "crtend" ]
6	%"struct.__gnu_cxx::__normal_iterator<char*,std::basic_string<char, std::char_traits<char>, std::allocator<char> > >" = type { i8* }
7	%"struct.__gnu_cxx::char_producer<char>" = type { i32 (...)** }
8	%struct.__sFILE = type { i8*, i32, i32, i16, i16, %struct.__sbuf, i32, i8*, i32 (i8*)*, i32 (i8*, i8*, i32)*, i64 (i8*, i64, i32)*, i32 (i8*, i8*, i32)*, %struct.__sbuf, i8*, i32, [3 x i8], [1 x i8], %struct.__sbuf, i32, i64 }
9	%struct.__sbuf = type { i8*, i32 }
10	%"struct.std::__basic_file<char>" = type { %struct.__sFILE*, i1 }
11	%"struct.std::__codecvt_abstract_base<char,char,__mbstate_t>" = type { %"struct.std::locale::facet" }
12	%"struct.std::bad_alloc" = type { %"struct.__gnu_cxx::char_producer<char>" }
13	%"struct.std::basic_filebuf<char,std::char_traits<char> >" = type { %"struct.std::basic_streambuf<char,std::char_traits<char> >", i32, %"struct.std::__basic_file<char>", i32, %union.__mbstate_t, %union.__mbstate_t, i8*, i32, i1, i1, i1, i1, i8, i8*, i8*, i1, %"struct.std::codecvt<char,char,__mbstate_t>"*, i8*, i32, i8*, i8* }
14	%"struct.std::basic_ios<char,std::char_traits<char> >" = type { %"struct.std::ios_base", %"struct.std::basic_ostream<char,std::char_traits<char> >"*, i8, i1, %"struct.std::basic_streambuf<char,std::char_traits<char> >"*, %"struct.std::ctype<char>"*, %"struct.std::__codecvt_abstract_base<char,char,__mbstate_t>"*, %"struct.std::__codecvt_abstract_base<char,char,__mbstate_t>"* }
15	%"struct.std::basic_iostream<char,std::char_traits<char> >" = type { %"struct.std::locale::facet", %"struct.__gnu_cxx::char_producer<char>", %"struct.std::basic_ios<char,std::char_traits<char> >" }
16	%"struct.std::basic_ofstream<char,std::char_traits<char> >" = type { %"struct.__gnu_cxx::char_producer<char>", %"struct.std::basic_filebuf<char,std::char_traits<char> >", %"struct.std::basic_ios<char,std::char_traits<char> >" }
17	%"struct.std::basic_ostream<char,std::char_traits<char> >" = type { i32 (...)**, %"struct.std::basic_ios<char,std::char_traits<char> >" }
18	%"struct.std::basic_streambuf<char,std::char_traits<char> >" = type { i32 (...)**, i8*, i8*, i8*, i8*, i8*, i8*, %"struct.std::locale" }
19	%"struct.std::basic_string<char,std::char_traits<char>,std::allocator<char> >" = type { %"struct.__gnu_cxx::__normal_iterator<char*,std::basic_string<char, std::char_traits<char>, std::allocator<char> > >" }
20	%"struct.std::basic_string<char,std::char_traits<char>,std::allocator<char> >::_Rep" = type { %"struct.std::basic_string<char,std::char_traits<char>,std::allocator<char> >::_Rep_base" }
21	%"struct.std::basic_string<char,std::char_traits<char>,std::allocator<char> >::_Rep_base" = type { i32, i32, i32 }
22	%"struct.std::codecvt<char,char,__mbstate_t>" = type { %"struct.std::__codecvt_abstract_base<char,char,__mbstate_t>", i32* }
23	%"struct.std::ctype<char>" = type { %"struct.std::__codecvt_abstract_base<char,char,__mbstate_t>", i32*, i1, i32*, i32*, i32* }
24	%"struct.std::domain_error" = type { %"struct.std::logic_error" }
25	%"struct.std::ios_base" = type { i32 (...)**, i32, i32, i32, i32, i32, %"struct.std::ios_base::_Callback_list"*, %struct.__sbuf, [8 x %struct.__sbuf], i32, %struct.__sbuf*, %"struct.std::locale" }
26	%"struct.std::ios_base::_Callback_list" = type { %"struct.std::ios_base::_Callback_list"*, void (i32, %"struct.std::ios_base"*, i32)*, i32, i32 }
27	%"struct.std::ios_base::_Words" = type { i8*, i32 }
28	%"struct.std::locale" = type { %"struct.std::locale::_Impl"* }
29	%"struct.std::locale::_Impl" = type { i32, %"struct.std::locale::facet"**, i32, %"struct.std::locale::facet"**, i8** }
30	%"struct.std::locale::facet" = type { i32 (...)**, i32 }
31	%"struct.std::logic_error" = type { %"struct.__gnu_cxx::char_producer<char>", %"struct.std::basic_string<char,std::char_traits<char>,std::allocator<char> >" }
32	%union.__mbstate_t = type { i64, [120 x i8] }
33@.str_1 = external global [17 x i8]		; <[17 x i8]*> [#uses=0]
34@.str_9 = external global [24 x i8]		; <[24 x i8]*> [#uses=0]
35
36define void @main() {
37entry:
38	call fastcc void @_ZNSt14basic_ofstreamIcSt11char_traitsIcEE4openEPKcSt13_Ios_Openmode( )
39	ret void
40}
41
42define fastcc void @_ZNSt14basic_ofstreamIcSt11char_traitsIcEE4openEPKcSt13_Ios_Openmode() {
43entry:
44	%tmp.6 = icmp eq %"struct.std::basic_filebuf<char,std::char_traits<char> >"* null, null		; <i1> [#uses=1]
45	br i1 %tmp.6, label %then, label %UnifiedReturnBlock
46
47then:		; preds = %entry
48	tail call fastcc void @_ZNSt9basic_iosIcSt11char_traitsIcEE8setstateESt12_Ios_Iostate( )
49	ret void
50
51UnifiedReturnBlock:		; preds = %entry
52	ret void
53}
54
55define fastcc void @_ZN10__cxxabiv111__terminateEPFvvE() {
56entry:
57	unreachable
58}
59
60define void @_ZNSdD0Ev() {
61entry:
62	unreachable
63}
64
65define void @_ZThn8_NSdD1Ev() {
66entry:
67	ret void
68}
69
70define void @_ZNSt13basic_filebufIcSt11char_traitsIcEED0Ev() {
71entry:
72	ret void
73}
74
75define void @_ZNSt13basic_filebufIcSt11char_traitsIcEE9pbackfailEi() {
76entry:
77	unreachable
78}
79
80define fastcc void @_ZNSoD2Ev() {
81entry:
82	unreachable
83}
84
85define fastcc void @_ZNSt9basic_iosIcSt11char_traitsIcEED2Ev() {
86entry:
87	unreachable
88}
89
90define fastcc void @_ZNSt9basic_iosIcSt11char_traitsIcEE8setstateESt12_Ios_Iostate() {
91entry:
92	tail call fastcc void @_ZSt19__throw_ios_failurePKc( )
93	ret void
94}
95
96declare fastcc void @_ZNSaIcED1Ev()
97
98define fastcc void @_ZNSsC1EPKcRKSaIcE() {
99entry:
100	tail call fastcc void @_ZNSs16_S_construct_auxIPKcEEPcT_S3_RKSaIcE12__false_type( )
101	unreachable
102}
103
104define fastcc void @_ZSt14__convert_to_vIyEvPKcRT_RSt12_Ios_IostateRKPii() {
105entry:
106	ret void
107}
108
109define fastcc void @_ZNSt7num_getIcSt19istreambuf_iteratorIcSt11char_traitsIcEEEC1Ej() {
110entry:
111	ret void
112}
113
114define fastcc void @_ZSt19__throw_ios_failurePKc() {
115entry:
116	call fastcc void @_ZNSsC1EPKcRKSaIcE( )
117	unreachable
118}
119
120define void @_GLOBAL__D__ZSt23lexicographical_compareIPKaS1_EbT_S2_T0_S3_() {
121entry:
122	ret void
123}
124
125define void @_ZNSt9bad_allocD1Ev() {
126entry:
127	unreachable
128}
129
130define fastcc void @_ZSt19__throw_logic_errorPKc() {
131entry:
132	invoke fastcc void @_ZNSt11logic_errorC1ERKSs( )
133			to label %try_exit.0 unwind label %try_catch.0
134
135try_catch.0:		; preds = %entry
136        %exn = landingpad {i8*, i32} personality i32 (...)* @__gxx_personality_v0
137                 catch i8* null
138	resume { i8*, i32 } %exn
139
140try_exit.0:		; preds = %entry
141	unreachable
142}
143
144define fastcc void @_ZNSt11logic_errorC1ERKSs() {
145entry:
146	call fastcc void @_ZNSsC1ERKSs( )
147	ret void
148}
149
150define void @_ZNSt12domain_errorD1Ev() {
151entry:
152	unreachable
153}
154
155define fastcc void @_ZSt20__throw_length_errorPKc() {
156entry:
157	call fastcc void @_ZNSt12length_errorC1ERKSs( )
158	unreachable
159}
160
161define fastcc void @_ZNSt12length_errorC1ERKSs() {
162entry:
163	invoke fastcc void @_ZNSsC1ERKSs( )
164			to label %_ZNSt11logic_errorC2ERKSs.exit unwind label %invoke_catch.i
165
166invoke_catch.i:		; preds = %entry
167        %exn = landingpad {i8*, i32} personality i32 (...)* @__gxx_personality_v0
168                 catch i8* null
169	resume { i8*, i32 } %exn
170
171_ZNSt11logic_errorC2ERKSs.exit:		; preds = %entry
172	ret void
173}
174
175define fastcc void @_ZNSs4_Rep9_S_createEjRKSaIcE() {
176entry:
177	call fastcc void @_ZSt20__throw_length_errorPKc( )
178	unreachable
179}
180
181define fastcc void @_ZNSs12_S_constructIN9__gnu_cxx17__normal_iteratorIPcSsEEEES2_T_S4_RKSaIcESt20forward_iterator_tag() {
182entry:
183	unreachable
184}
185
186define fastcc void @_ZNSs16_S_construct_auxIPKcEEPcT_S3_RKSaIcE12__false_type() {
187entry:
188	br i1 false, label %then.1.i, label %endif.1.i
189
190then.1.i:		; preds = %entry
191	call fastcc void @_ZSt19__throw_logic_errorPKc( )
192	br label %endif.1.i
193
194endif.1.i:		; preds = %then.1.i, %entry
195	call fastcc void @_ZNSs4_Rep9_S_createEjRKSaIcE( )
196	unreachable
197}
198
199define fastcc void @_ZNSsC1ERKSs() {
200entry:
201	call fastcc void @_ZNSs4_Rep7_M_grabERKSaIcES2_( )
202	invoke fastcc void @_ZNSaIcEC1ERKS_( )
203			to label %invoke_cont.1 unwind label %invoke_catch.1
204
205invoke_catch.1:		; preds = %entry
206        %exn = landingpad {i8*, i32} personality i32 (...)* @__gxx_personality_v0
207                 catch i8* null
208	call fastcc void @_ZNSaIcED1Ev( )
209	resume { i8*, i32 } %exn
210
211invoke_cont.1:		; preds = %entry
212	call fastcc void @_ZNSaIcEC2ERKS_( )
213	ret void
214}
215
216define fastcc void @_ZNSaIcEC1ERKS_() {
217entry:
218	ret void
219}
220
221define fastcc void @_ZNSs7replaceEN9__gnu_cxx17__normal_iteratorIPcSsEES2_jc() {
222entry:
223	ret void
224}
225
226define fastcc void @_ZNSs4_Rep7_M_grabERKSaIcES2_() {
227entry:
228	br i1 false, label %else.i, label %cond_true
229
230cond_true:		; preds = %entry
231	ret void
232
233else.i:		; preds = %entry
234	tail call fastcc void @_ZNSs4_Rep9_S_createEjRKSaIcE( )
235	unreachable
236}
237
238define fastcc void @_ZNSaIcEC2ERKS_() {
239entry:
240	ret void
241}
242
243define fastcc void @_ZN9__gnu_cxx12__pool_allocILb1ELi0EE8allocateEj() {
244entry:
245	ret void
246}
247
248define fastcc void @_ZN9__gnu_cxx12__pool_allocILb1ELi0EE9_S_refillEj() {
249entry:
250	unreachable
251}
252
253declare i32 @__gxx_personality_v0(...)
254