2009-09-09 08:09:15 +08:00
|
|
|
; RUN: opt < %s -inline -S | grep nounwind
|
|
|
|
; RUN: opt < %s -inline -S | grep unreachable
|
2007-12-20 05:13:37 +08:00
|
|
|
|
|
|
|
declare i1 @extern()
|
|
|
|
|
|
|
|
define internal i32 @test() {
|
|
|
|
entry:
|
|
|
|
%n = call i1 @extern( )
|
|
|
|
br i1 %n, label %r, label %u
|
|
|
|
r:
|
2010-01-06 01:55:26 +08:00
|
|
|
ret i32 0
|
2007-12-20 05:13:37 +08:00
|
|
|
u:
|
2011-09-03 06:41:11 +08:00
|
|
|
unreachable
|
2007-12-20 05:13:37 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
define i32 @caller() {
|
|
|
|
%X = call i32 @test( ) nounwind
|
|
|
|
ret i32 %X
|
|
|
|
}
|