1*9880d681SAndroid Build Coastguard Worker; RUN: llc < %s 2*9880d681SAndroid Build Coastguard Worker; PR2096 3*9880d681SAndroid Build Coastguard Worker %struct.AVClass = type { i8*, i8* (i8*)*, %struct.AVOption* } 4*9880d681SAndroid Build Coastguard Worker %struct.AVCodec = type { i8*, i32, i32, i32, i32 (%struct.AVCodecContext*)*, i32 (%struct.AVCodecContext*, i8*, i32, i8*)*, i32 (%struct.AVCodecContext*)*, i32 (%struct.AVCodecContext*, i8*, i32*, i8*, i32)*, i32, %struct.AVCodec*, void (%struct.AVCodecContext*)*, %struct.AVRational*, i32* } 5*9880d681SAndroid Build Coastguard Worker %struct.AVCodecContext = type { %struct.AVClass*, i32, i32, i32, i32, i32, i8*, i32, %struct.AVRational, i32, i32, i32, i32, i32, void (%struct.AVCodecContext*, %struct.AVFrame*, i32*, i32, i32, i32)*, i32, i32, i32, i32, i32, i32, i32, float, float, i32, i32, i32, i32, float, i32, i32, i32, %struct.AVCodec*, i8*, i32, i32, void (%struct.AVCodecContext*, i8*, i32, i32)*, i32, i32, i32, i32, i32, i32, i32, i32, i32, i8*, [32 x i8], i32, i32, i32, i32, i32, i32, i32, float, i32, i32 (%struct.AVCodecContext*, %struct.AVFrame*)*, void (%struct.AVCodecContext*, %struct.AVFrame*)*, i32, i32, i32, i32, i8*, i8*, float, float, i32, %struct.RcOverride*, i32, i8*, i32, i32, i32, float, float, float, float, i32, float, float, float, float, float, i32, i32, i32, i32*, i32, i32, i32, i32, %struct.AVRational, %struct.AVFrame*, i32, i32, [4 x i64], i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32 (%struct.AVCodecContext*, i32*)*, i32, i32, i32, i32, i32, i32, i8*, i32, i32, i32, i32, i32, i32, i16*, i16*, i32, i32, i32, i32, %struct.AVPaletteControl*, i32, i32 (%struct.AVCodecContext*, %struct.AVFrame*)*, i32, i32, i32, i32, i32, i32, i32, i32 (%struct.AVCodecContext*, i32 (%struct.AVCodecContext*, i8*)*, i8**, i32*, i32)*, i8*, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, float, i32, i32, i32, i32, i32, i32, i32, i32, float, i32, i32, i32, i32, i32, i32, float, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i64, i32, float } 6*9880d681SAndroid Build Coastguard Worker %struct.AVFrame = type { [4 x i8*], [4 x i32], [4 x i8*], i32, i32, i64, i32, i32, i32, i32, i32, i8*, i32, i8*, [2 x [2 x i16]*], i32*, i8, i8*, [4 x i64], i32, i32, i32, i32, i32, %struct.AVPanScan*, i32, i32, i16*, [2 x i8*] } 7*9880d681SAndroid Build Coastguard Worker %struct.AVOption = type opaque 8*9880d681SAndroid Build Coastguard Worker %struct.AVPaletteControl = type { i32, [256 x i32] } 9*9880d681SAndroid Build Coastguard Worker %struct.AVPanScan = type { i32, i32, i32, [3 x [2 x i16]] } 10*9880d681SAndroid Build Coastguard Worker %struct.AVRational = type { i32, i32 } 11*9880d681SAndroid Build Coastguard Worker %struct.RcOverride = type { i32, i32, i32, float } 12*9880d681SAndroid Build Coastguard Worker 13*9880d681SAndroid Build Coastguard Workerdefine i32 @sonic_encode_frame(%struct.AVCodecContext* %avctx, i8* %buf, i32 %buf_size, i8* %data) { 14*9880d681SAndroid Build Coastguard Workerentry: 15*9880d681SAndroid Build Coastguard Worker switch i32 0, label %bb429 [ 16*9880d681SAndroid Build Coastguard Worker i32 0, label %bb244.preheader 17*9880d681SAndroid Build Coastguard Worker i32 1, label %bb279.preheader 18*9880d681SAndroid Build Coastguard Worker ] 19*9880d681SAndroid Build Coastguard Worker 20*9880d681SAndroid Build Coastguard Workerbb279.preheader: ; preds = %entry 21*9880d681SAndroid Build Coastguard Worker ret i32 0 22*9880d681SAndroid Build Coastguard Worker 23*9880d681SAndroid Build Coastguard Workerbb244.preheader: ; preds = %entry 24*9880d681SAndroid Build Coastguard Worker ret i32 0 25*9880d681SAndroid Build Coastguard Worker 26*9880d681SAndroid Build Coastguard Workerbb429: ; preds = %entry 27*9880d681SAndroid Build Coastguard Worker br i1 false, label %bb.nph1770, label %bb627 28*9880d681SAndroid Build Coastguard Worker 29*9880d681SAndroid Build Coastguard Workerbb.nph1770: ; preds = %bb429 30*9880d681SAndroid Build Coastguard Worker br i1 false, label %bb471, label %bb505 31*9880d681SAndroid Build Coastguard Worker 32*9880d681SAndroid Build Coastguard Workerbb471: ; preds = %bb471, %bb.nph1770 33*9880d681SAndroid Build Coastguard Worker %tmp487 = fadd double 0.000000e+00, 0.000000e+00 ; <double> [#uses=1] 34*9880d681SAndroid Build Coastguard Worker br i1 false, label %bb505, label %bb471 35*9880d681SAndroid Build Coastguard Worker 36*9880d681SAndroid Build Coastguard Workerbb505: ; preds = %bb471, %bb.nph1770 37*9880d681SAndroid Build Coastguard Worker %xy.0.lcssa = phi double [ 0.000000e+00, %bb.nph1770 ], [ %tmp487, %bb471 ] ; <double> [#uses=1] 38*9880d681SAndroid Build Coastguard Worker %tmp507 = fsub double -0.000000e+00, %xy.0.lcssa ; <double> [#uses=1] 39*9880d681SAndroid Build Coastguard Worker %tmp509 = fdiv double %tmp507, 0.000000e+00 ; <double> [#uses=1] 40*9880d681SAndroid Build Coastguard Worker %tmp510 = fmul double %tmp509, 1.024000e+03 ; <double> [#uses=1] 41*9880d681SAndroid Build Coastguard Worker %tmp516 = fdiv double %tmp510, 0.000000e+00 ; <double> [#uses=1] 42*9880d681SAndroid Build Coastguard Worker %tmp517 = fadd double %tmp516, 5.000000e-01 ; <double> [#uses=1] 43*9880d681SAndroid Build Coastguard Worker %tmp518 = tail call double @floor( double %tmp517 ) nounwind readnone ; <double> [#uses=0] 44*9880d681SAndroid Build Coastguard Worker ret i32 0 45*9880d681SAndroid Build Coastguard Worker 46*9880d681SAndroid Build Coastguard Workerbb627: ; preds = %bb429 47*9880d681SAndroid Build Coastguard Worker ret i32 0 48*9880d681SAndroid Build Coastguard Worker} 49*9880d681SAndroid Build Coastguard Worker 50*9880d681SAndroid Build Coastguard Workerdeclare double @floor(double) nounwind readnone 51