#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);
scalar_t__ floor(double);
scalar_t__ scd2(double, int, double *, double *, double *);
int scd(double u, double K, double k, double *s, double *c, double *d) {
  double m;
  int Ndiv2 = 0;
  int N4K = 0;
  int K2 = 0;
  int NEG = 0;
  m = k * k;
  if (u < 0) {
    NEG = 1;
    u = fabs(u);
  }
  N4K = (int)floor(u / (4 * K));
  u -= 4 * K * ((double)N4K);
  if (u > 2.0 * K) {
    u -= 2.0 * K;
    K2 = 1;
  }
  while (u >= K / 2.0) {
    u /= 2;
    Ndiv2++;
  }
  if (scd2(u, 1 - m, s, c, d))
    return 1;
  else {
    if (Ndiv2) {
      double ss, cc, dd;
      double nom;
      while (Ndiv2) {
        nom = (1 - m * (*s) * (*s) * (*s) * (*s));
        ss = 2 * (*s) * (*c) * (*d) / nom;
        cc = (1 - 2 * (*s) * (*s) + m * (*s) * (*s) * (*s) * (*s)) / nom;
        dd = (1 - 2 * m * (*s) * (*s) + m * (*s) * (*s) * (*s) * (*s)) / nom;
        (*s) = ss;
        (*c) = cc;
        (*d) = dd;
        Ndiv2--;
      }
    }
    if (K2) {
      (*s) = -(*s);
      (*c) = -(*c);
    }
    if (NEG) {
      (*s) = -(*s);
      (*c) = (*c);
    }
  }
  return 0;
}


x86 assembly (clang, -O0):
<scd>:
push   %rbp
mov    %rsp,%rbp
sub    $0x70,%rsp
movsd  %xmm0,-0x10(%rbp)
movsd  %xmm1,-0x18(%rbp)
movsd  %xmm2,-0x20(%rbp)
mov    %rdi,-0x28(%rbp)
mov    %rsi,-0x30(%rbp)
mov    %rdx,-0x38(%rbp)
movl   $0x0,-0x44(%rbp)
movl   $0x0,-0x48(%rbp)
movl   $0x0,-0x4c(%rbp)
movl   $0x0,-0x50(%rbp)
movsd  -0x20(%rbp),%xmm0
mulsd  -0x20(%rbp),%xmm0
movsd  %xmm0,-0x40(%rbp)
xorps  %xmm0,%xmm0
ucomisd -0x10(%rbp),%xmm0
jbe    1198 <scd+0x78>
movl   $0x1,-0x50(%rbp)
movsd  -0x10(%rbp),%xmm0
movaps 0xe71(%rip),%xmm1
pand   %xmm1,%xmm0
movsd  %xmm0,-0x10(%rbp)
movsd  -0x10(%rbp),%xmm0
movsd  0xe73(%rip),%xmm1
mulsd  -0x18(%rbp),%xmm1
divsd  %xmm1,%xmm0
call   1040 <floor@plt>
mov    %eax,-0x48(%rbp)
movsd  0xe5a(%rip),%xmm0
mulsd  -0x18(%rbp),%xmm0
cvtsi2sdl -0x48(%rbp),%xmm2
movsd  -0x10(%rbp),%xmm1
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x10(%rbp)
movsd  -0x10(%rbp),%xmm0
movsd  0xe12(%rip),%xmm1
mulsd  -0x18(%rbp),%xmm1
ucomisd %xmm1,%xmm0
jbe    122b <scd+0x10b>
movsd  -0x18(%rbp),%xmm1
movsd  -0x10(%rbp),%xmm0
addsd  %xmm1,%xmm1
subsd  %xmm1,%xmm0
movsd  %xmm0,-0x10(%rbp)
movl   $0x1,-0x4c(%rbp)
jmp    1230 <scd+0x110>
movsd  -0x10(%rbp),%xmm0
movsd  -0x18(%rbp),%xmm1
movsd  0xdce(%rip),%xmm2
divsd  %xmm2,%xmm1
ucomisd %xmm1,%xmm0
jb     1274 <scd+0x154>
movsd  -0x10(%rbp),%xmm0
movsd  0xdb3(%rip),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x10(%rbp)
mov    -0x44(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x44(%rbp)
jmp    1230 <scd+0x110>
movsd  -0x10(%rbp),%xmm0
movsd  0xd9f(%rip),%xmm1
subsd  -0x40(%rbp),%xmm1
cvttsd2si %xmm1,%edi
mov    -0x28(%rbp),%rsi
mov    -0x30(%rbp),%rdx
mov    -0x38(%rbp),%rcx
call   1030 <scd2@plt>
cmp    $0x0,%rax
je     12b1 <scd+0x191>
movl   $0x1,-0x4(%rbp)
jmp    1515 <scd+0x3f5>
cmpl   $0x0,-0x44(%rbp)
je     1470 <scd+0x350>
jmp    12c0 <scd+0x1a0>
cmpl   $0x0,-0x44(%rbp)
je     146b <scd+0x34b>
movsd  -0x40(%rbp),%xmm0
mov    -0x28(%rbp),%rax
mulsd  (%rax),%xmm0
mov    -0x28(%rbp),%rax
mulsd  (%rax),%xmm0
mov    -0x28(%rbp),%rax
mulsd  (%rax),%xmm0
mov    -0x28(%rbp),%rax
movsd  (%rax),%xmm1
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mulsd  %xmm1,%xmm0
movsd  0xd0e(%rip),%xmm1
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x70(%rbp)
mov    -0x28(%rbp),%rax
movsd  0xce9(%rip),%xmm0
mulsd  (%rax),%xmm0
mov    -0x30(%rbp),%rax
mulsd  (%rax),%xmm0
mov    -0x38(%rbp),%rax
mulsd  (%rax),%xmm0
divsd  -0x70(%rbp),%xmm0
movsd  %xmm0,-0x58(%rbp)
mov    -0x28(%rbp),%rax
movsd  0xcbf(%rip),%xmm1
mulsd  (%rax),%xmm1
mov    -0x28(%rbp),%rax
movsd  (%rax),%xmm0
movq   %xmm1,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm1
mulsd  %xmm0,%xmm1
movsd  0xca0(%rip),%xmm0
addsd  %xmm0,%xmm1
movsd  -0x40(%rbp),%xmm0
mov    -0x28(%rbp),%rax
mulsd  (%rax),%xmm0
mov    -0x28(%rbp),%rax
mulsd  (%rax),%xmm0
mov    -0x28(%rbp),%rax
mulsd  (%rax),%xmm0
mov    -0x28(%rbp),%rax
movsd  (%rax),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
divsd  -0x70(%rbp),%xmm0
movsd  %xmm0,-0x60(%rbp)
movsd  0xc4d(%rip),%xmm1
mulsd  -0x40(%rbp),%xmm1
mov    -0x28(%rbp),%rax
mulsd  (%rax),%xmm1
mov    -0x28(%rbp),%rax
movsd  (%rax),%xmm0
movq   %xmm1,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm1
mulsd  %xmm0,%xmm1
movsd  0xc25(%rip),%xmm0
addsd  %xmm0,%xmm1
movsd  -0x40(%rbp),%xmm0
mov    -0x28(%rbp),%rax
mulsd  (%rax),%xmm0
mov    -0x28(%rbp),%rax
mulsd  (%rax),%xmm0
mov    -0x28(%rbp),%rax
mulsd  (%rax),%xmm0
mov    -0x28(%rbp),%rax
movsd  (%rax),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
divsd  -0x70(%rbp),%xmm0
movsd  %xmm0,-0x68(%rbp)
movsd  -0x58(%rbp),%xmm0
mov    -0x28(%rbp),%rax
movsd  %xmm0,(%rax)
movsd  -0x60(%rbp),%xmm0
mov    -0x30(%rbp),%rax
movsd  %xmm0,(%rax)
movsd  -0x68(%rbp),%xmm0
mov    -0x38(%rbp),%rax
movsd  %xmm0,(%rax)
mov    -0x44(%rbp),%eax
add    $0xffffffff,%eax
mov    %eax,-0x44(%rbp)
jmp    12c0 <scd+0x1a0>
jmp    1470 <scd+0x350>
cmpl   $0x0,-0x4c(%rbp)
je     14c8 <scd+0x3a8>
mov    -0x28(%rbp),%rax
movsd  (%rax),%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mov    -0x28(%rbp),%rax
movsd  %xmm0,(%rax)
mov    -0x30(%rbp),%rax
movsd  (%rax),%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mov    -0x30(%rbp),%rax
movsd  %xmm0,(%rax)
cmpl   $0x0,-0x50(%rbp)
je     1509 <scd+0x3e9>
mov    -0x28(%rbp),%rax
movsd  (%rax),%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mov    -0x28(%rbp),%rax
movsd  %xmm0,(%rax)
mov    -0x30(%rbp),%rax
movsd  (%rax),%xmm0
mov    -0x30(%rbp),%rax
movsd  %xmm0,(%rax)
jmp    150e <scd+0x3ee>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x70,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<scd>:
push   %rbp
push   %r15
push   %r14
push   %rbx
sub    $0x48,%rsp
mov    %rdx,%r15
mov    %rsi,%rbx
mov    %rdi,%r14
movsd  %xmm1,0x28(%rsp)
mulsd  %xmm2,%xmm2
movsd  %xmm2,0x8(%rsp)
movapd 0xeb5(%rip),%xmm2
andpd  %xmm0,%xmm2
xorpd  %xmm4,%xmm4
movapd %xmm0,%xmm3
cmpltsd %xmm4,%xmm3
andpd  %xmm3,%xmm2
movapd %xmm0,0x30(%rsp)
andnpd %xmm0,%xmm3
orpd   %xmm2,%xmm3
movapd %xmm3,0x10(%rsp)
movsd  0xea4(%rip),%xmm2
mulsd  %xmm1,%xmm2
movsd  %xmm2,(%rsp)
movapd %xmm3,%xmm0
divsd  %xmm2,%xmm0
call   1040 <floor@plt>
movsd  0x28(%rsp),%xmm2
xorps  %xmm0,%xmm0
cvtsi2sd %eax,%xmm0
mulsd  (%rsp),%xmm0
movapd 0x10(%rsp),%xmm3
subsd  %xmm0,%xmm3
movapd %xmm2,%xmm0
addsd  %xmm2,%xmm0
movapd %xmm3,%xmm1
subsd  %xmm0,%xmm1
movsd  %xmm0,(%rsp)
cmpltsd %xmm3,%xmm0
andpd  %xmm0,%xmm1
movapd %xmm3,0x10(%rsp)
andnpd %xmm3,%xmm0
mulsd  0xe4a(%rip),%xmm2
orpd   %xmm1,%xmm0
xor    %ebp,%ebp
ucomisd %xmm2,%xmm0
jb     120d <scd+0xed>
xor    %ebp,%ebp
movsd  0xe34(%rip),%xmm1
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
mulsd  %xmm1,%xmm0
add    $0x1,%ebp
ucomisd %xmm2,%xmm0
jae    1200 <scd+0xe0>
movsd  0xe1b(%rip),%xmm1
subsd  0x8(%rsp),%xmm1
cvttsd2si %xmm1,%edi
mov    %r14,%rsi
mov    %rbx,%rdx
mov    %r15,%rcx
call   1030 <scd2@plt>
mov    %rax,%rcx
mov    $0x1,%eax
test   %rcx,%rcx
jne    1339 <scd+0x219>
test   %ebp,%ebp
movsd  0x8(%rsp),%xmm8
movsd  0xde1(%rip),%xmm0
je     12ea <scd+0x1ca>
movsd  0xdda(%rip),%xmm9
mulsd  %xmm8,%xmm9
movsd  (%r15),%xmm1
nopl   0x0(%rax,%rax,1)
movsd  (%r14),%xmm3
movapd %xmm8,%xmm2
mulsd  %xmm3,%xmm2
mulsd  %xmm3,%xmm2
mulsd  %xmm3,%xmm2
mulsd  %xmm3,%xmm2
movapd %xmm0,%xmm4
subsd  %xmm2,%xmm4
movapd %xmm3,%xmm5
addsd  %xmm3,%xmm5
movsd  (%rbx),%xmm6
mulsd  %xmm5,%xmm6
mulsd  %xmm1,%xmm6
divsd  %xmm4,%xmm6
mulsd  %xmm3,%xmm5
movapd %xmm0,%xmm7
subsd  %xmm5,%xmm7
addsd  %xmm2,%xmm7
divsd  %xmm4,%xmm7
movapd %xmm9,%xmm1
mulsd  %xmm3,%xmm1
mulsd  %xmm3,%xmm1
addsd  %xmm0,%xmm1
addsd  %xmm2,%xmm1
divsd  %xmm4,%xmm1
movsd  %xmm6,(%r14)
movsd  %xmm7,(%rbx)
movsd  %xmm1,(%r15)
add    $0xffffffff,%ebp
jne    1270 <scd+0x150>
movapd 0x10(%rsp),%xmm0
ucomisd (%rsp),%xmm0
jbe    1319 <scd+0x1f9>
movsd  (%r14),%xmm0
movapd 0xd0c(%rip),%xmm1
xorpd  %xmm1,%xmm0
movlpd %xmm0,(%r14)
movsd  (%rbx),%xmm0
xorpd  %xmm1,%xmm0
movlpd %xmm0,(%rbx)
xor    %eax,%eax
xorpd  %xmm0,%xmm0
ucomisd 0x30(%rsp),%xmm0
jbe    1339 <scd+0x219>
movsd  (%r14),%xmm0
xorpd  0xcdc(%rip),%xmm0
movlpd %xmm0,(%r14)
add    $0x48,%rsp
pop    %rbx
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
define i32 @scd(double %0, double %1, double %2, double* %3, double* %4, double* %5) {
%7 = alloca i32
%8 = alloca double
%9 = alloca double
%10 = alloca double
%11 = alloca double*
%12 = alloca double*
%13 = alloca double*
%14 = alloca double
%15 = alloca i32
%16 = alloca i32
%17 = alloca i32
%18 = alloca i32
%19 = alloca double
%20 = alloca double
%21 = alloca double
%22 = alloca double
store double %0, double* %8
store double %1, double* %9
store double %2, double* %10
store double* %3, double** %11
store double* %4, double** %12
store double* %5, double** %13
store i32 0, i32* %15
store i32 0, i32* %16
store i32 0, i32* %17
store i32 0, i32* %18
%23 = load double, double* %10
%24 = load double, double* %10
%25 = fmul double %23, %24
store double %25, double* %14
%26 = load double, double* %8
%27 = fcmp olt double %26, 0.000000e+00
br i1 %27, label %28, label %31
28: ; preds = %6
store i32 1, i32* %18
%29 = load double, double* %8
%30 = call double @llvm.fabs.f64(double %29)
store double %30, double* %8
br label %31
31: ; preds = %28, %6
%32 = load double, double* %8
%33 = load double, double* %9
%34 = fmul double 4.000000e+00, %33
%35 = fdiv double %32, %34
%36 = call i64 @floor(double %35)
%37 = trunc i64 %36 to i32
store i32 %37, i32* %16
%38 = load double, double* %9
%39 = fmul double 4.000000e+00, %38
%40 = load i32, i32* %16
%41 = sitofp i32 %40 to double
%42 = load double, double* %8
%43 = fneg double %39
%44 = call double @llvm.fmuladd.f64(double %43, double %41, double %42)
store double %44, double* %8
%45 = load double, double* %8
%46 = load double, double* %9
%47 = fmul double 2.000000e+00, %46
%48 = fcmp ogt double %45, %47
br i1 %48, label %49, label %53
49: ; preds = %31
%50 = load double, double* %9
%51 = load double, double* %8
%52 = call double @llvm.fmuladd.f64(double -2.000000e+00, double %50, double %51)
store double %52, double* %8
store i32 1, i32* %17
br label %53
53: ; preds = %49, %31
br label %54
54: ; preds = %59, %53
%55 = load double, double* %8
%56 = load double, double* %9
%57 = fdiv double %56, 2.000000e+00
%58 = fcmp oge double %55, %57
br i1 %58, label %59, label %64
59: ; preds = %54
%60 = load double, double* %8
%61 = fdiv double %60, 2.000000e+00
store double %61, double* %8
%62 = load i32, i32* %15
%63 = add nsw i32 %62, 1
store i32 %63, i32* %15
br label %54
64: ; preds = %54
%65 = load double, double* %8
%66 = load double, double* %14
%67 = fsub double 1.000000e+00, %66
%68 = fptosi double %67 to i32
%69 = load double*, double** %11
%70 = load double*, double** %12
%71 = load double*, double** %13
%72 = call i64 @scd2(double %65, i32 %68, double* %69, double* %70, double* %71)
%73 = icmp ne i64 %72, 0
br i1 %73, label %74, label %75
74: ; preds = %64
store i32 1, i32* %7
br label %188
75: ; preds = %64
%76 = load i32, i32* %15
%77 = icmp ne i32 %76, 0
br i1 %77, label %78, label %163
78: ; preds = %75
br label %79
79: ; preds = %82, %78
%80 = load i32, i32* %15
%81 = icmp ne i32 %80, 0
br i1 %81, label %82, label %162
82: ; preds = %79
%83 = load double, double* %14
%84 = load double*, double** %11
%85 = load double, double* %84
%86 = fmul double %83, %85
%87 = load double*, double** %11
%88 = load double, double* %87
%89 = fmul double %86, %88
%90 = load double*, double** %11
%91 = load double, double* %90
%92 = fmul double %89, %91
%93 = load double*, double** %11
%94 = load double, double* %93
%95 = fneg double %92
%96 = call double @llvm.fmuladd.f64(double %95, double %94, double 1.000000e+00)
store double %96, double* %22
%97 = load double*, double** %11
%98 = load double, double* %97
%99 = fmul double 2.000000e+00, %98
%100 = load double*, double** %12
%101 = load double, double* %100
%102 = fmul double %99, %101
%103 = load double*, double** %13
%104 = load double, double* %103
%105 = fmul double %102, %104
%106 = load double, double* %22
%107 = fdiv double %105, %106
store double %107, double* %19
%108 = load double*, double** %11
%109 = load double, double* %108
%110 = fmul double 2.000000e+00, %109
%111 = load double*, double** %11
%112 = load double, double* %111
%113 = fneg double %110
%114 = call double @llvm.fmuladd.f64(double %113, double %112, double 1.000000e+00)
%115 = load double, double* %14
%116 = load double*, double** %11
%117 = load double, double* %116
%118 = fmul double %115, %117
%119 = load double*, double** %11
%120 = load double, double* %119
%121 = fmul double %118, %120
%122 = load double*, double** %11
%123 = load double, double* %122
%124 = fmul double %121, %123
%125 = load double*, double** %11
%126 = load double, double* %125
%127 = call double @llvm.fmuladd.f64(double %124, double %126, double %114)
%128 = load double, double* %22
%129 = fdiv double %127, %128
store double %129, double* %20
%130 = load double, double* %14
%131 = fmul double 2.000000e+00, %130
%132 = load double*, double** %11
%133 = load double, double* %132
%134 = fmul double %131, %133
%135 = load double*, double** %11
%136 = load double, double* %135
%137 = fneg double %134
%138 = call double @llvm.fmuladd.f64(double %137, double %136, double 1.000000e+00)
%139 = load double, double* %14
%140 = load double*, double** %11
%141 = load double, double* %140
%142 = fmul double %139, %141
%143 = load double*, double** %11
%144 = load double, double* %143
%145 = fmul double %142, %144
%146 = load double*, double** %11
%147 = load double, double* %146
%148 = fmul double %145, %147
%149 = load double*, double** %11
%150 = load double, double* %149
%151 = call double @llvm.fmuladd.f64(double %148, double %150, double %138)
%152 = load double, double* %22
%153 = fdiv double %151, %152
store double %153, double* %21
%154 = load double, double* %19
%155 = load double*, double** %11
store double %154, double* %155
%156 = load double, double* %20
%157 = load double*, double** %12
store double %156, double* %157
%158 = load double, double* %21
%159 = load double*, double** %13
store double %158, double* %159
%160 = load i32, i32* %15
%161 = add nsw i32 %160, -1
store i32 %161, i32* %15
br label %79
162: ; preds = %79
br label %163
163: ; preds = %162, %75
%164 = load i32, i32* %17
%165 = icmp ne i32 %164, 0
br i1 %165, label %166, label %175
166: ; preds = %163
%167 = load double*, double** %11
%168 = load double, double* %167
%169 = fneg double %168
%170 = load double*, double** %11
store double %169, double* %170
%171 = load double*, double** %12
%172 = load double, double* %171
%173 = fneg double %172
%174 = load double*, double** %12
store double %173, double* %174
br label %175
175: ; preds = %166, %163
%176 = load i32, i32* %18
%177 = icmp ne i32 %176, 0
br i1 %177, label %178, label %186
178: ; preds = %175
%179 = load double*, double** %11
%180 = load double, double* %179
%181 = fneg double %180
%182 = load double*, double** %11
store double %181, double* %182
%183 = load double*, double** %12
%184 = load double, double* %183
%185 = load double*, double** %12
store double %184, double* %185
br label %186
186: ; preds = %178, %175
br label %187
187: ; preds = %186
store i32 0, i32* %7
br label %188
188: ; preds = %187, %74
%189 = load i32, i32* %7
ret i32 %189
}

LLVM IR (-O2):
define i32 @scd(double %0, double %1, double %2, double* %3, double* %4, double* %5) {
%7 = fmul double %2, %2
%8 = fcmp olt double %0, 0.000000e+00
%9 = tail call double @llvm.fabs.f64(double %0)
%10 = select i1 %8, double %9, double %0
%11 = fmul double %1, 4.000000e+00
%12 = fdiv double %10, %11
%13 = tail call i64 @floor(double %12)
%14 = trunc i64 %13 to i32
%15 = sitofp i32 %14 to double
%16 = fneg double %11
%17 = tail call double @llvm.fmuladd.f64(double %16, double %15, double %10)
%18 = fmul double %1, 2.000000e+00
%19 = fcmp ogt double %17, %18
%20 = tail call double @llvm.fmuladd.f64(double %1, double -2.000000e+00, double %17)
%21 = select i1 %19, double %20, double %17
%22 = fmul double %1, 5.000000e-01
%23 = fcmp ult double %21, %22
br i1 %23, label %30, label %24
24: ; preds = %6, %24
%25 = phi double [ %27, %24 ], [ %21, %6 ]
%26 = phi i32 [ %28, %24 ], [ 0, %6 ]
%27 = fmul double %25, 5.000000e-01
%28 = add nuw nsw i32 %26, 1
%29 = fcmp ult double %27, %22
br i1 %29, label %30, label %24
30: ; preds = %24, %6
%31 = phi i32 [ 0, %6 ], [ %28, %24 ]
%32 = phi double [ %21, %6 ], [ %27, %24 ]
%33 = fsub double 1.000000e+00, %7
%34 = fptosi double %33 to i32
%35 = tail call i64 @scd2(double %32, i32 %34, double* %3, double* %4, double* %5)
%36 = icmp eq i64 %35, 0
br i1 %36, label %37, label %76
37: ; preds = %30
%38 = icmp eq i32 %31, 0
br i1 %38, label %66, label %39
39: ; preds = %37
%40 = fmul double %7, -2.000000e+00
%41 = load double, double* %5
br label %42
42: ; preds = %39, %42
%43 = phi double [ %41, %39 ], [ %63, %42 ]
%44 = phi i32 [ %31, %39 ], [ %64, %42 ]
%45 = load double, double* %3
%46 = fmul double %7, %45
%47 = fmul double %45, %46
%48 = fmul double %45, %47
%49 = fneg double %48
%50 = tail call double @llvm.fmuladd.f64(double %49, double %45, double 1.000000e+00)
%51 = fmul double %45, 2.000000e+00
%52 = load double, double* %4
%53 = fmul double %51, %52
%54 = fmul double %53, %43
%55 = fdiv double %54, %50
%56 = fneg double %51
%57 = tail call double @llvm.fmuladd.f64(double %56, double %45, double 1.000000e+00)
%58 = tail call double @llvm.fmuladd.f64(double %48, double %45, double %57)
%59 = fdiv double %58, %50
%60 = fmul double %40, %45
%61 = tail call double @llvm.fmuladd.f64(double %60, double %45, double 1.000000e+00)
%62 = tail call double @llvm.fmuladd.f64(double %48, double %45, double %61)
%63 = fdiv double %62, %50
store double %55, double* %3
store double %59, double* %4
store double %63, double* %5
%64 = add nsw i32 %44, -1
%65 = icmp eq i32 %64, 0
br i1 %65, label %66, label %42
66: ; preds = %42, %37
br i1 %19, label %67, label %72
67: ; preds = %66
%68 = load double, double* %3
%69 = fneg double %68
store double %69, double* %3
%70 = load double, double* %4
%71 = fneg double %70
store double %71, double* %4
br label %72
72: ; preds = %67, %66
br i1 %8, label %73, label %76
73: ; preds = %72
%74 = load double, double* %3
%75 = fneg double %74
store double %75, double* %3
br label %76
76: ; preds = %73, %72, %30
%77 = phi i32 [ 1, %30 ], [ 0, %72 ], [ 0, %73 ]
ret i32 %77
}