Created
April 1, 2010 08:48
-
-
Save nanki/351567 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
; ModuleID = '<stdin>' | |
define void @main() nounwind { | |
%r.1 = alloca double ; <double*> [#uses=3] | |
store double 1.000000e+00, double* %r.1 | |
%r.9 = alloca double ; <double*> [#uses=3] | |
store double 9.000000e+00, double* %r.9 | |
br label %loop | |
loop: ; preds = %switch, %0 | |
%1 = call i32 @putchar(i8 72) ; <i32> [#uses=0] | |
%tmp5 = load double* %r.9 ; <double> [#uses=1] | |
%tmp6 = load double* %r.1 ; <double> [#uses=1] | |
%tmp7 = fsub double %tmp5, %tmp6 ; <double> [#uses=2] | |
store double %tmp7, double* %r.9 | |
%tmp9 = fcmp ult double %tmp7, 0.000000e+00 ; <i1> [#uses=1] | |
br i1 %tmp9, label %exit, label %switch | |
switch: ; preds = %loop | |
%tmp10 = load double* %r.1 ; <double> [#uses=1] | |
%tmp11 = fptoui double %tmp10 to i32 ; <i32> [#uses=1] | |
switch i32 %tmp11, label %exit [ | |
i32 1, label %loop | |
] | |
exit: ; preds = %switch, %loop | |
ret void | |
} | |
declare i32 @putchar(i8) nounwind |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment