2007-11-23 19:30:27 +00:00
|
|
|
; RUN: llvm-as < %s | opt -basicaa -licm | llvm-dis | %prcontext sin 1 | grep Out:
|
2004-03-15 04:10:08 +00:00
|
|
|
|
2007-11-23 19:30:27 +00:00
|
|
|
declare double @sin(double) readnone
|
|
|
|
|
|
|
|
declare void @foo()
|
2004-03-15 04:10:08 +00:00
|
|
|
|
2007-11-23 19:30:27 +00:00
|
|
|
define double @test(double %X) {
|
|
|
|
br label %Loop
|
2004-03-15 04:10:08 +00:00
|
|
|
|
2007-11-23 19:30:27 +00:00
|
|
|
Loop: ; preds = %Loop, %0
|
|
|
|
call void @foo( )
|
|
|
|
%A = call double @sin( double %X ) readnone ; <double> [#uses=1]
|
|
|
|
br i1 true, label %Loop, label %Out
|
2004-03-15 04:10:08 +00:00
|
|
|
|
2007-11-23 19:30:27 +00:00
|
|
|
Out: ; preds = %Loop
|
2004-03-15 04:10:08 +00:00
|
|
|
ret double %A
|
|
|
|
}
|