#define NULL ((void *)0)
typedef unsigned long size_t; // Customize by platform.
typedef long intptr_t;
typedef unsigned long uintptr_t;
typedef long scalar_t__; // Either arithmetic or pointer type.
/* By default, we understand bool (as a convenience). */
typedef int bool;
#define false 0
#define true 1

/* Forward declarations */

/* Type definitions */

/* Variables and functions */
double fabs(double);
double sqrt(int);
int ode2_(double *a, double *b, double *c__, double *rt1, double *rt2) {
  double d__1;
  double ab, df, tb, sm, rt, adf, acmn, acmx;
  sm = *a + *c__;
  df = *a - *c__;
  adf = fabs(df);
  tb = *b + *b;
  ab = fabs(tb);
  if (fabs(*a) > fabs(*c__)) {
    acmx = *a;
    acmn = *c__;
  } else {
    acmx = *c__;
    acmn = *a;
  }
  if (adf > ab) {
    d__1 = ab / adf;
    rt = adf * sqrt(d__1 * d__1 + 1.);
  } else if (adf < ab) {
    d__1 = adf / ab;
    rt = ab * sqrt(d__1 * d__1 + 1.);
  } else {
    rt = ab * sqrt(2.);
  }
  if (sm < 0.) {
    *rt1 = (sm - rt) * .5;
    *rt2 = acmx / *rt1 * acmn - *b / *rt1 * *b;
  } else if (sm > 0.) {
    *rt1 = (sm + rt) * .5;
    *rt2 = acmx / *rt1 * acmn - *b / *rt1 * *b;
  } else {
    *rt1 = rt * .5;
    *rt2 = rt * -.5;
  }
  return 0;
}


x86 assembly (clang, -O0):
<ode2_>:
push   %rbp
mov    %rsp,%rbp
sub    $0x90,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %rcx,-0x20(%rbp)
mov    %r8,-0x28(%rbp)
mov    -0x8(%rbp),%rax
movsd  (%rax),%xmm0
mov    -0x18(%rbp),%rax
addsd  (%rax),%xmm0
movsd  %xmm0,-0x50(%rbp)
mov    -0x8(%rbp),%rax
movsd  (%rax),%xmm0
mov    -0x18(%rbp),%rax
subsd  (%rax),%xmm0
movsd  %xmm0,-0x40(%rbp)
movsd  -0x40(%rbp),%xmm0
movaps 0xe9b(%rip),%xmm1
pand   %xmm1,%xmm0
movsd  %xmm0,-0x60(%rbp)
mov    -0x10(%rbp),%rax
movsd  (%rax),%xmm0
mov    -0x10(%rbp),%rax
addsd  (%rax),%xmm0
movsd  %xmm0,-0x48(%rbp)
movsd  -0x48(%rbp),%xmm0
movaps 0xe71(%rip),%xmm1
pand   %xmm1,%xmm0
movsd  %xmm0,-0x38(%rbp)
mov    -0x8(%rbp),%rax
movsd  (%rax),%xmm0
movaps 0xe59(%rip),%xmm1
pand   %xmm1,%xmm0
mov    -0x18(%rbp),%rax
movsd  (%rax),%xmm1
movaps 0xe46(%rip),%xmm2
pand   %xmm2,%xmm1
ucomisd %xmm1,%xmm0
jbe    11e7 <ode2_+0xd7>
mov    -0x8(%rbp),%rax
movsd  (%rax),%xmm0
movsd  %xmm0,-0x70(%rbp)
mov    -0x18(%rbp),%rax
movsd  (%rax),%xmm0
movsd  %xmm0,-0x68(%rbp)
jmp    1201 <ode2_+0xf1>
mov    -0x18(%rbp),%rax
movsd  (%rax),%xmm0
movsd  %xmm0,-0x70(%rbp)
mov    -0x8(%rbp),%rax
movsd  (%rax),%xmm0
movsd  %xmm0,-0x68(%rbp)
movsd  -0x60(%rbp),%xmm0
ucomisd -0x38(%rbp),%xmm0
jbe    1263 <ode2_+0x153>
movsd  -0x38(%rbp),%xmm0
divsd  -0x60(%rbp),%xmm0
movsd  %xmm0,-0x30(%rbp)
movsd  -0x60(%rbp),%xmm0
movsd  %xmm0,-0x78(%rbp)
movsd  -0x30(%rbp),%xmm0
movsd  -0x30(%rbp),%xmm1
mulsd  %xmm1,%xmm0
movsd  0xdd0(%rip),%xmm1
addsd  %xmm1,%xmm0
cvttsd2si %xmm0,%edi
call   1030 <sqrt@plt>
movaps %xmm0,%xmm1
movsd  -0x78(%rbp),%xmm0
mulsd  %xmm1,%xmm0
movsd  %xmm0,-0x58(%rbp)
jmp    12f9 <ode2_+0x1e9>
movsd  -0x60(%rbp),%xmm1
movsd  -0x38(%rbp),%xmm0
ucomisd %xmm1,%xmm0
jbe    12c9 <ode2_+0x1b9>
movsd  -0x60(%rbp),%xmm0
divsd  -0x38(%rbp),%xmm0
movsd  %xmm0,-0x30(%rbp)
movsd  -0x38(%rbp),%xmm0
movsd  %xmm0,-0x80(%rbp)
movsd  -0x30(%rbp),%xmm0
movsd  -0x30(%rbp),%xmm1
mulsd  %xmm1,%xmm0
movsd  0xd6a(%rip),%xmm1
addsd  %xmm1,%xmm0
cvttsd2si %xmm0,%edi
call   1030 <sqrt@plt>
movaps %xmm0,%xmm1
movsd  -0x80(%rbp),%xmm0
mulsd  %xmm1,%xmm0
movsd  %xmm0,-0x58(%rbp)
jmp    12f4 <ode2_+0x1e4>
movsd  -0x38(%rbp),%xmm0
movsd  %xmm0,-0x88(%rbp)
ff
mov    $0x2,%edi
call   1030 <sqrt@plt>
movaps %xmm0,%xmm1
movsd  -0x88(%rbp),%xmm0
ff
mulsd  %xmm1,%xmm0
movsd  %xmm0,-0x58(%rbp)
jmp    12f9 <ode2_+0x1e9>
xorps  %xmm0,%xmm0
ucomisd -0x50(%rbp),%xmm0
jbe    137b <ode2_+0x26b>
movsd  -0x50(%rbp),%xmm0
subsd  -0x58(%rbp),%xmm0
movsd  0xd07(%rip),%xmm1
mulsd  %xmm1,%xmm0
mov    -0x20(%rbp),%rax
movsd  %xmm0,(%rax)
movsd  -0x70(%rbp),%xmm0
mov    -0x20(%rbp),%rax
divsd  (%rax),%xmm0
movsd  -0x68(%rbp),%xmm2
mov    -0x10(%rbp),%rax
movsd  (%rax),%xmm1
mov    -0x20(%rbp),%rax
divsd  (%rax),%xmm1
mov    -0x10(%rbp),%rax
mulsd  (%rax),%xmm1
movq   %xmm1,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
mov    -0x28(%rbp),%rax
movsd  %xmm0,(%rax)
jmp    1430 <ode2_+0x320>
movsd  -0x50(%rbp),%xmm0
xorps  %xmm1,%xmm1
ucomisd %xmm1,%xmm0
jbe    1401 <ode2_+0x2f1>
movsd  -0x50(%rbp),%xmm0
addsd  -0x58(%rbp),%xmm0
movsd  0xc81(%rip),%xmm1
mulsd  %xmm1,%xmm0
mov    -0x20(%rbp),%rax
movsd  %xmm0,(%rax)
movsd  -0x70(%rbp),%xmm0
mov    -0x20(%rbp),%rax
divsd  (%rax),%xmm0
movsd  -0x68(%rbp),%xmm2
mov    -0x10(%rbp),%rax
movsd  (%rax),%xmm1
mov    -0x20(%rbp),%rax
divsd  (%rax),%xmm1
mov    -0x10(%rbp),%rax
mulsd  (%rax),%xmm1
movq   %xmm1,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
mov    -0x28(%rbp),%rax
movsd  %xmm0,(%rax)
jmp    142b <ode2_+0x31b>
movsd  0xc17(%rip),%xmm0
mulsd  -0x58(%rbp),%xmm0
mov    -0x20(%rbp),%rax
movsd  %xmm0,(%rax)
movsd  0xbfa(%rip),%xmm0
mulsd  -0x58(%rbp),%xmm0
mov    -0x28(%rbp),%rax
movsd  %xmm0,(%rax)
jmp    1430 <ode2_+0x320>
xor    %eax,%eax
add    $0x90,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<ode2_>:
push   %r15
push   %r14
push   %rbx
sub    $0x40,%rsp
mov    %rsi,%rbx
movsd  (%rdi),%xmm4
movsd  (%rdx),%xmm1
movapd %xmm4,%xmm0
subsd  %xmm1,%xmm0
movapd 0xecc(%rip),%xmm3
andpd  %xmm3,%xmm0
movsd  (%rsi),%xmm6
addsd  %xmm6,%xmm6
andpd  %xmm3,%xmm6
movapd %xmm4,%xmm2
andpd  %xmm3,%xmm2
andpd  %xmm1,%xmm3
ucomisd %xmm3,%xmm2
mov    %r8,%r14
mov    %rcx,%r15
cmpltsd %xmm2,%xmm3
movapd %xmm3,%xmm2
andpd  %xmm1,%xmm2
andnpd %xmm4,%xmm3
movapd %xmm4,%xmm5
ja     1175 <ode2_+0x65>
movapd %xmm1,%xmm5
orpd   %xmm2,%xmm3
addsd  %xmm1,%xmm4
ucomisd %xmm6,%xmm0
movapd %xmm3,0x20(%rsp)
movapd %xmm4,0x30(%rsp)
movsd  %xmm5,0x8(%rsp)
jbe    11b1 <ode2_+0xa1>
divsd  %xmm0,%xmm6
mulsd  %xmm6,%xmm6
addsd  0xe6b(%rip),%xmm6
cvttsd2si %xmm6,%edi
movapd %xmm0,0x10(%rsp)
jmp    11d6 <ode2_+0xc6>
mov    $0x2,%edi
ucomisd %xmm0,%xmm6
movapd %xmm6,0x10(%rsp)
jbe    11d6 <ode2_+0xc6>
divsd  %xmm6,%xmm0
mulsd  %xmm0,%xmm0
addsd  0xe3e(%rip),%xmm0
cvttsd2si %xmm0,%edi
call   1030 <sqrt@plt>
mulsd  0x10(%rsp),%xmm0
xorpd  %xmm1,%xmm1
movapd 0x30(%rsp),%xmm3
ucomisd %xmm3,%xmm1
jbe    1228 <ode2_+0x118>
subsd  %xmm0,%xmm3
mulsd  0xe1b(%rip),%xmm3
movsd  %xmm3,(%r15)
movsd  0x8(%rsp),%xmm4
divsd  %xmm3,%xmm4
movsd  (%rbx),%xmm0
movapd %xmm0,%xmm1
divsd  %xmm3,%xmm1
mulsd  %xmm0,%xmm1
mulsd  0x20(%rsp),%xmm4
subsd  %xmm1,%xmm4
jmp    1286 <ode2_+0x176>
ucomisd %xmm1,%xmm3
movapd 0x20(%rsp),%xmm2
movsd  0x8(%rsp),%xmm4
jbe    1269 <ode2_+0x159>
addsd  %xmm0,%xmm3
mulsd  0xdd2(%rip),%xmm3
movsd  %xmm3,(%r15)
divsd  %xmm3,%xmm4
movsd  (%rbx),%xmm0
movapd %xmm0,%xmm1
divsd  %xmm3,%xmm1
mulsd  %xmm0,%xmm1
mulsd  %xmm2,%xmm4
subsd  %xmm1,%xmm4
jmp    1286 <ode2_+0x176>
movsd  0xda7(%rip),%xmm1
mulsd  %xmm0,%xmm1
movsd  %xmm1,(%r15)
mulsd  0xd9e(%rip),%xmm0
movapd %xmm0,%xmm4
movsd  %xmm4,(%r14)
xor    %eax,%eax
add    $0x40,%rsp
pop    %rbx
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
define i32 @ode2_(double* %0, double* %1, double* %2, double* %3, double* %4) {
%6 = alloca double*
%7 = alloca double*
%8 = alloca double*
%9 = alloca double*
%10 = alloca double*
%11 = alloca double
%12 = alloca double
%13 = alloca double
%14 = alloca double
%15 = alloca double
%16 = alloca double
%17 = alloca double
%18 = alloca double
%19 = alloca double
store double* %0, double** %6
store double* %1, double** %7
store double* %2, double** %8
store double* %3, double** %9
store double* %4, double** %10
%20 = load double*, double** %6
%21 = load double, double* %20
%22 = load double*, double** %8
%23 = load double, double* %22
%24 = fadd double %21, %23
store double %24, double* %15
%25 = load double*, double** %6
%26 = load double, double* %25
%27 = load double*, double** %8
%28 = load double, double* %27
%29 = fsub double %26, %28
store double %29, double* %13
%30 = load double, double* %13
%31 = call double @llvm.fabs.f64(double %30)
store double %31, double* %17
%32 = load double*, double** %7
%33 = load double, double* %32
%34 = load double*, double** %7
%35 = load double, double* %34
%36 = fadd double %33, %35
store double %36, double* %14
%37 = load double, double* %14
%38 = call double @llvm.fabs.f64(double %37)
store double %38, double* %12
%39 = load double*, double** %6
%40 = load double, double* %39
%41 = call double @llvm.fabs.f64(double %40)
%42 = load double*, double** %8
%43 = load double, double* %42
%44 = call double @llvm.fabs.f64(double %43)
%45 = fcmp ogt double %41, %44
br i1 %45, label %46, label %51
46: ; preds = %5
%47 = load double*, double** %6
%48 = load double, double* %47
store double %48, double* %19
%49 = load double*, double** %8
%50 = load double, double* %49
store double %50, double* %18
br label %56
51: ; preds = %5
%52 = load double*, double** %8
%53 = load double, double* %52
store double %53, double* %19
%54 = load double*, double** %6
%55 = load double, double* %54
store double %55, double* %18
br label %56
56: ; preds = %51, %46
%57 = load double, double* %17
%58 = load double, double* %12
%59 = fcmp ogt double %57, %58
br i1 %59, label %60, label %71
60: ; preds = %56
%61 = load double, double* %12
%62 = load double, double* %17
%63 = fdiv double %61, %62
store double %63, double* %11
%64 = load double, double* %17
%65 = load double, double* %11
%66 = load double, double* %11
%67 = call double @llvm.fmuladd.f64(double %65, double %66, double 1.000000e+00)
%68 = fptosi double %67 to i32
%69 = call double @sqrt(i32 %68)
%70 = fmul double %64, %69
store double %70, double* %16
br label %91
71: ; preds = %56
%72 = load double, double* %17
%73 = load double, double* %12
%74 = fcmp olt double %72, %73
br i1 %74, label %75, label %86
75: ; preds = %71
%76 = load double, double* %17
%77 = load double, double* %12
%78 = fdiv double %76, %77
store double %78, double* %11
%79 = load double, double* %12
%80 = load double, double* %11
%81 = load double, double* %11
%82 = call double @llvm.fmuladd.f64(double %80, double %81, double 1.000000e+00)
%83 = fptosi double %82 to i32
%84 = call double @sqrt(i32 %83)
%85 = fmul double %79, %84
store double %85, double* %16
br label %90
86: ; preds = %71
%87 = load double, double* %12
%88 = call double @sqrt(i32 2)
%89 = fmul double %87, %88
store double %89, double* %16
br label %90
90: ; preds = %86, %75
br label %91
91: ; preds = %90, %60
%92 = load double, double* %15
%93 = fcmp olt double %92, 0.000000e+00
br i1 %93, label %94, label %116
94: ; preds = %91
%95 = load double, double* %15
%96 = load double, double* %16
%97 = fsub double %95, %96
%98 = fmul double %97, 5.000000e-01
%99 = load double*, double** %9
store double %98, double* %99
%100 = load double, double* %19
%101 = load double*, double** %9
%102 = load double, double* %101
%103 = fdiv double %100, %102
%104 = load double, double* %18
%105 = load double*, double** %7
%106 = load double, double* %105
%107 = load double*, double** %9
%108 = load double, double* %107
%109 = fdiv double %106, %108
%110 = load double*, double** %7
%111 = load double, double* %110
%112 = fmul double %109, %111
%113 = fneg double %112
%114 = call double @llvm.fmuladd.f64(double %103, double %104, double %113)
%115 = load double*, double** %10
store double %114, double* %115
br label %149
116: ; preds = %91
%117 = load double, double* %15
%118 = fcmp ogt double %117, 0.000000e+00
br i1 %118, label %119, label %141
119: ; preds = %116
%120 = load double, double* %15
%121 = load double, double* %16
%122 = fadd double %120, %121
%123 = fmul double %122, 5.000000e-01
%124 = load double*, double** %9
store double %123, double* %124
%125 = load double, double* %19
%126 = load double*, double** %9
%127 = load double, double* %126
%128 = fdiv double %125, %127
%129 = load double, double* %18
%130 = load double*, double** %7
%131 = load double, double* %130
%132 = load double*, double** %9
%133 = load double, double* %132
%134 = fdiv double %131, %133
%135 = load double*, double** %7
%136 = load double, double* %135
%137 = fmul double %134, %136
%138 = fneg double %137
%139 = call double @llvm.fmuladd.f64(double %128, double %129, double %138)
%140 = load double*, double** %10
store double %139, double* %140
br label %148
141: ; preds = %116
%142 = load double, double* %16
%143 = fmul double %142, 5.000000e-01
%144 = load double*, double** %9
store double %143, double* %144
%145 = load double, double* %16
%146 = fmul double %145, -5.000000e-01
%147 = load double*, double** %10
store double %146, double* %147
br label %148
148: ; preds = %141, %119
br label %149
149: ; preds = %148, %94
ret i32 0
}

LLVM IR (-O2):
define i32 @ode2_(double* nocapture %0, double* nocapture %1, double* nocapture %2, double* nocapture writeonly %3, double* nocapture writeonly %4) {
%6 = load double, double* %0
%7 = load double, double* %2
%8 = fadd double %6, %7
%9 = fsub double %6, %7
%10 = tail call double @llvm.fabs.f64(double %9)
%11 = load double, double* %1
%12 = fadd double %11, %11
%13 = tail call double @llvm.fabs.f64(double %12)
%14 = tail call double @llvm.fabs.f64(double %6)
%15 = tail call double @llvm.fabs.f64(double %7)
%16 = fcmp ogt double %14, %15
%17 = select i1 %16, double %7, double %6
%18 = select i1 %16, double %6, double %7
%19 = fcmp ogt double %10, %13
br i1 %19, label %20, label %24
20: ; preds = %5
%21 = fdiv double %13, %10
%22 = tail call double @llvm.fmuladd.f64(double %21, double %21, double 1.000000e+00)
%23 = fptosi double %22 to i32
br label %30
24: ; preds = %5
%25 = fcmp olt double %10, %13
br i1 %25, label %26, label %30
26: ; preds = %24
%27 = fdiv double %10, %13
%28 = tail call double @llvm.fmuladd.f64(double %27, double %27, double 1.000000e+00)
%29 = fptosi double %28 to i32
br label %30
30: ; preds = %24, %26, %20
%31 = phi i32 [ %29, %26 ], [ %23, %20 ], [ 2, %24 ]
%32 = phi double [ %13, %26 ], [ %10, %20 ], [ %13, %24 ]
%33 = tail call double @sqrt(i32 %31)
%34 = fmul double %32, %33
%35 = fcmp olt double %8, 0.000000e+00
br i1 %35, label %36, label %45
36: ; preds = %30
%37 = fsub double %8, %34
%38 = fmul double %37, 5.000000e-01
store double %38, double* %3
%39 = fdiv double %18, %38
%40 = load double, double* %1
%41 = fneg double %40
%42 = fdiv double %41, %38
%43 = fmul double %40, %42
%44 = tail call double @llvm.fmuladd.f64(double %39, double %17, double %43)
br label %59
45: ; preds = %30
%46 = fcmp ogt double %8, 0.000000e+00
br i1 %46, label %47, label %56
47: ; preds = %45
%48 = fadd double %8, %34
%49 = fmul double %48, 5.000000e-01
store double %49, double* %3
%50 = fdiv double %18, %49
%51 = load double, double* %1
%52 = fneg double %51
%53 = fdiv double %52, %49
%54 = fmul double %51, %53
%55 = tail call double @llvm.fmuladd.f64(double %50, double %17, double %54)
br label %59
56: ; preds = %45
%57 = fmul double %34, 5.000000e-01
store double %57, double* %3
%58 = fmul double %34, -5.000000e-01
br label %59
59: ; preds = %47, %56, %36
%60 = phi double [ %55, %47 ], [ %58, %56 ], [ %44, %36 ]
store double %60, double* %4
ret i32 0
}