#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 */
scalar_t__ ceil(double);
double cos(double);
double erf(double);
double erfc(double);
double fabs(double);
scalar_t__ round(double);
double rsqrt64(double);
double sqrt(float);
double EwaldU(double x, double y, int N, double Rc, double a, double eta,
              double *XX, double *YY) {
  double U = 0.0;
  double dx, dy, r, ir, ieta;
  double eta2;
  ieta = 0.5 / eta;
  eta2 = eta * eta;
  for (int i = 0; i < N; ++i) {
    dx = x - XX[i];
    dy = y - YY[i];
    double r2 = dx * dx + dy * dy;
    if (r2 > 1e-16 * eta2) {
      ir = rsqrt64(r2);
      if (r2 > 100 * eta2) {
        U -= ir;
      } else {
        r = 1.0 / ir;
        U -= ir * erf(r * ieta);
      }
    } else {
      U -= 1.12837916710 * ieta;
    }
  }
  int m = (int)round((x - y * 0.57735026918963) / a);
  int n = (int)round(2.0 * 0.57735026918963 * y / a);
  double Rmax = 10 * eta;
  int max = ((int)ceil(1.2 * Rmax / a)) + 1;
  double eps = 1e-6;
  for (int i = -max + m; i <= max + m; ++i) {
    for (int j = -max + n; j <= max + n; ++j) {
      double X = ((double)i + ((double)j) * 0.5);
      double Y = ((double)j) * 0.86602540378444;
      dx = x - X * a;
      dy = y - Y * a;
      if (dx * dx + dy * dy < Rmax * Rmax &&
          (fabs(0.86602540378444 * X + 0.5 * Y) > Rc + eps ||
           fabs(0.86602540378444 * X - 0.5 * Y) > Rc + eps ||
           fabs(Y) > Rc + eps)) {
        ir = rsqrt64(dx * dx + dy * dy);
        double r = 1.0 / ir;
        U += ir * erfc(r * ieta);
      }
    }
  }
  double KX, KY;
  double iK, K;
  double Kmax = 10.0 * ieta, U1;
  max = ((int)ceil(1.2 * a / 6.2831853071796f * Kmax)) + 1;
  double K0X = 6.2831853071796f / a, K0Y = K0X * 0.57735026918963;
  double omega = 6.2831853071796f / (0.86602540378444 * a * a);
  for (int k = -max; k <= max; ++k) {
    for (int l = -max; l <= max; ++l) {
      KX = K0X * ((double)k);
      KY = K0Y * ((double)(2 * l - k));
      double K2 = KX * KX + KY * KY;
      if ((k != 0 || l != 0) && K2 <= Kmax * Kmax) {
        iK = rsqrt64(K2);
        K = 1.0 / iK;
        U += omega * iK * cos(KX * x + KY * y) * erfc(K * eta);
      }
    }
  }
  U -= 4.0 * sqrt(3.1415926535898f) * eta / (a * a) * 2.0 * 0.57735026918963;
  ;
  return U;
}


x86 assembly (clang, -O0):
<EwaldU>:
push   %rbp
mov    %rsp,%rbp
sub    $0x140,%rsp
movsd  %xmm0,-0x8(%rbp)
movsd  %xmm1,-0x10(%rbp)
mov    %edi,-0x14(%rbp)
movsd  %xmm2,-0x20(%rbp)
movsd  %xmm3,-0x28(%rbp)
movsd  %xmm4,-0x30(%rbp)
mov    %rsi,-0x38(%rbp)
mov    %rdx,-0x40(%rbp)
xorps  %xmm0,%xmm0
movsd  %xmm0,-0x48(%rbp)
movsd  0xe51(%rip),%xmm0
divsd  -0x30(%rbp),%xmm0
movsd  %xmm0,-0x70(%rbp)
movsd  -0x30(%rbp),%xmm0
mulsd  -0x30(%rbp),%xmm0
movsd  %xmm0,-0x78(%rbp)
movl   $0x0,-0x7c(%rbp)
mov    -0x7c(%rbp),%eax
cmp    -0x14(%rbp),%eax
jge    132e <EwaldU+0x1be>
movsd  -0x8(%rbp),%xmm0
mov    -0x38(%rbp),%rax
movslq -0x7c(%rbp),%rcx
subsd  (%rax,%rcx,8),%xmm0
movsd  %xmm0,-0x50(%rbp)
movsd  -0x10(%rbp),%xmm0
mov    -0x40(%rbp),%rax
movslq -0x7c(%rbp),%rcx
subsd  (%rax,%rcx,8),%xmm0
movsd  %xmm0,-0x58(%rbp)
movsd  -0x50(%rbp),%xmm0
movsd  -0x50(%rbp),%xmm2
movsd  -0x58(%rbp),%xmm1
mulsd  -0x58(%rbp),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x88(%rbp)
ff
movsd  -0x88(%rbp),%xmm0
ff
movsd  0xe1b(%rip),%xmm1
mulsd  -0x78(%rbp),%xmm1
ucomisd %xmm1,%xmm0
jbe    12fc <EwaldU+0x18c>
movsd  -0x88(%rbp),%xmm0
ff
call   1040 <rsqrt64@plt>
movsd  %xmm0,-0x68(%rbp)
movsd  -0x88(%rbp),%xmm0
ff
movsd  0xdfa(%rip),%xmm1
mulsd  -0x78(%rbp),%xmm1
ucomisd %xmm1,%xmm0
jbe    1295 <EwaldU+0x125>
movsd  -0x68(%rbp),%xmm1
movsd  -0x48(%rbp),%xmm0
subsd  %xmm1,%xmm0
movsd  %xmm0,-0x48(%rbp)
jmp    12f7 <EwaldU+0x187>
movsd  0xdb3(%rip),%xmm0
divsd  -0x68(%rbp),%xmm0
movsd  %xmm0,-0x60(%rbp)
movsd  -0x68(%rbp),%xmm0
movsd  %xmm0,-0x128(%rbp)
ff
movsd  -0x60(%rbp),%xmm0
mulsd  -0x70(%rbp),%xmm0
call   1080 <erf@plt>
movaps %xmm0,%xmm2
movsd  -0x128(%rbp),%xmm0
ff
movsd  -0x48(%rbp),%xmm1
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x48(%rbp)
jmp    131b <EwaldU+0x1ab>
movsd  -0x70(%rbp),%xmm0
movsd  -0x48(%rbp),%xmm1
movsd  0xd52(%rip),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x48(%rbp)
jmp    1320 <EwaldU+0x1b0>
mov    -0x7c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x7c(%rbp)
jmp    11cf <EwaldU+0x5f>
movsd  -0x8(%rbp),%xmm1
movsd  -0x10(%rbp),%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
movsd  0xcd1(%rip),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
divsd  -0x28(%rbp),%xmm0
call   1060 <round@plt>
mov    %eax,-0x8c(%rbp)
movsd  0xca9(%rip),%xmm0
mulsd  -0x10(%rbp),%xmm0
divsd  -0x28(%rbp),%xmm0
call   1060 <round@plt>
mov    %eax,-0x90(%rbp)
movsd  0xc84(%rip),%xmm0
mulsd  -0x30(%rbp),%xmm0
movsd  %xmm0,-0x98(%rbp)
ff
movsd  0xc67(%rip),%xmm0
mulsd  -0x98(%rbp),%xmm0
ff
divsd  -0x28(%rbp),%xmm0
call   1030 <ceil@plt>
add    $0x1,%eax
mov    %eax,-0x9c(%rbp)
movsd  0xc3c(%rip),%xmm0
movsd  %xmm0,-0xa8(%rbp)
ff
xor    %eax,%eax
sub    -0x9c(%rbp),%eax
add    -0x8c(%rbp),%eax
mov    %eax,-0xac(%rbp)
mov    -0xac(%rbp),%eax
mov    -0x9c(%rbp),%ecx
add    -0x8c(%rbp),%ecx
cmp    %ecx,%eax
jg     1694 <EwaldU+0x524>
xor    %eax,%eax
sub    -0x9c(%rbp),%eax
add    -0x90(%rbp),%eax
mov    %eax,-0xb0(%rbp)
mov    -0xb0(%rbp),%eax
mov    -0x9c(%rbp),%ecx
add    -0x90(%rbp),%ecx
cmp    %ecx,%eax
jg     167b <EwaldU+0x50b>
cvtsi2sdl -0xac(%rbp),%xmm1
ff
cvtsi2sdl -0xb0(%rbp),%xmm0
ff
movsd  0xbb8(%rip),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0xb8(%rbp)
ff
cvtsi2sdl -0xb0(%rbp),%xmm0
ff
movsd  0xbd0(%rip),%xmm1
mulsd  %xmm1,%xmm0
movsd  %xmm0,-0xc0(%rbp)
ff
movsd  -0x8(%rbp),%xmm1
movsd  -0xb8(%rbp),%xmm0
ff
movsd  -0x28(%rbp),%xmm2
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x50(%rbp)
movsd  -0x10(%rbp),%xmm1
movsd  -0xc0(%rbp),%xmm0
ff
movsd  -0x28(%rbp),%xmm2
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x58(%rbp)
movsd  -0x50(%rbp),%xmm1
movsd  -0x50(%rbp),%xmm2
movsd  -0x58(%rbp),%xmm0
mulsd  -0x58(%rbp),%xmm0
mulsd  %xmm2,%xmm1
addsd  %xmm0,%xmm1
movsd  -0x98(%rbp),%xmm0
ff
mulsd  -0x98(%rbp),%xmm0
ff
ucomisd %xmm1,%xmm0
jbe    1662 <EwaldU+0x4f2>
movsd  -0xb8(%rbp),%xmm0
ff
movsd  0xada(%rip),%xmm1
mulsd  -0xc0(%rbp),%xmm1
ff
movsd  0xb02(%rip),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movaps 0xb3b(%rip),%xmm1
pand   %xmm1,%xmm0
movsd  -0x20(%rbp),%xmm1
addsd  -0xa8(%rbp),%xmm1
ff
ucomisd %xmm1,%xmm0
ja     15eb <EwaldU+0x47b>
movsd  -0xb8(%rbp),%xmm0
ff
movsd  0xa90(%rip),%xmm1
mulsd  -0xc0(%rbp),%xmm1
ff
movq   %xmm1,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm1
movsd  0xaa1(%rip),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movaps 0xada(%rip),%xmm1
pand   %xmm1,%xmm0
movsd  -0x20(%rbp),%xmm1
addsd  -0xa8(%rbp),%xmm1
ff
ucomisd %xmm1,%xmm0
ja     15eb <EwaldU+0x47b>
movsd  -0xc0(%rbp),%xmm0
ff
movaps 0xab0(%rip),%xmm1
pand   %xmm1,%xmm0
movsd  -0x20(%rbp),%xmm1
addsd  -0xa8(%rbp),%xmm1
ff
ucomisd %xmm1,%xmm0
jbe    1662 <EwaldU+0x4f2>
movsd  -0x50(%rbp),%xmm0
movsd  -0x50(%rbp),%xmm2
movsd  -0x58(%rbp),%xmm1
mulsd  -0x58(%rbp),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
call   1040 <rsqrt64@plt>
movsd  %xmm0,-0x68(%rbp)
movsd  0xa37(%rip),%xmm0
divsd  -0x68(%rbp),%xmm0
movsd  %xmm0,-0xc8(%rbp)
ff
movsd  -0x68(%rbp),%xmm0
movsd  %xmm0,-0x130(%rbp)
ff
movsd  -0xc8(%rbp),%xmm0
ff
mulsd  -0x70(%rbp),%xmm0
call   1090 <erfc@plt>
movaps %xmm0,%xmm2
movsd  -0x130(%rbp),%xmm0
ff
movsd  -0x48(%rbp),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x48(%rbp)
jmp    1667 <EwaldU+0x4f7>
mov    -0xb0(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xb0(%rbp)
jmp    1416 <EwaldU+0x2a6>
jmp    1680 <EwaldU+0x510>
mov    -0xac(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xac(%rbp)
jmp    13e8 <EwaldU+0x278>
movsd  0x97c(%rip),%xmm0
mulsd  -0x70(%rbp),%xmm0
movsd  %xmm0,-0xf0(%rbp)
ff
movsd  0x95f(%rip),%xmm0
mulsd  -0x28(%rbp),%xmm0
movsd  0x972(%rip),%xmm1
divsd  %xmm1,%xmm0
mulsd  -0xf0(%rbp),%xmm0
ff
call   1030 <ceil@plt>
add    $0x1,%eax
mov    %eax,-0x9c(%rbp)
movsd  0x950(%rip),%xmm0
divsd  -0x28(%rbp),%xmm0
movsd  %xmm0,-0x100(%rbp)
ff
movsd  0x933(%rip),%xmm0
mulsd  -0x100(%rbp),%xmm0
ff
movsd  %xmm0,-0x108(%rbp)
ff
movsd  0x92b(%rip),%xmm1
mulsd  -0x28(%rbp),%xmm1
mulsd  -0x28(%rbp),%xmm1
movsd  0x911(%rip),%xmm0
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x110(%rbp)
ff
xor    %eax,%eax
sub    -0x9c(%rbp),%eax
mov    %eax,-0x114(%rbp)
mov    -0x114(%rbp),%eax
cmp    -0x9c(%rbp),%eax
jg     18fe <EwaldU+0x78e>
xor    %eax,%eax
sub    -0x9c(%rbp),%eax
mov    %eax,-0x118(%rbp)
mov    -0x118(%rbp),%eax
cmp    -0x9c(%rbp),%eax
jg     18e5 <EwaldU+0x775>
movsd  -0x100(%rbp),%xmm0
ff
cvtsi2sdl -0x114(%rbp),%xmm1
ff
mulsd  %xmm1,%xmm0
movsd  %xmm0,-0xd0(%rbp)
ff
movsd  -0x108(%rbp),%xmm0
ff
mov    -0x118(%rbp),%eax
shl    $0x1,%eax
sub    -0x114(%rbp),%eax
cvtsi2sd %eax,%xmm1
mulsd  %xmm1,%xmm0
movsd  %xmm0,-0xd8(%rbp)
ff
movsd  -0xd0(%rbp),%xmm0
ff
movsd  -0xd0(%rbp),%xmm2
ff
movsd  -0xd8(%rbp),%xmm1
ff
mulsd  -0xd8(%rbp),%xmm1
ff
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x120(%rbp)
ff
cmpl   $0x0,-0x114(%rbp)
jne    17f8 <EwaldU+0x688>
cmpl   $0x0,-0x118(%rbp)
je     18cc <EwaldU+0x75c>
movsd  -0x120(%rbp),%xmm1
ff
movsd  -0xf0(%rbp),%xmm0
ff
mulsd  -0xf0(%rbp),%xmm0
ff
ucomisd %xmm1,%xmm0
jb     18cc <EwaldU+0x75c>
movsd  -0x120(%rbp),%xmm0
ff
call   1040 <rsqrt64@plt>
movsd  %xmm0,-0xe0(%rbp)
ff
movsd  0x819(%rip),%xmm0
divsd  -0xe0(%rbp),%xmm0
ff
movsd  %xmm0,-0xe8(%rbp)
ff
movsd  -0x110(%rbp),%xmm0
ff
mulsd  -0xe0(%rbp),%xmm0
ff
movsd  %xmm0,-0x140(%rbp)
ff
movsd  -0xd0(%rbp),%xmm0
ff
movsd  -0x8(%rbp),%xmm2
movsd  -0xd8(%rbp),%xmm1
ff
mulsd  -0x10(%rbp),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
call   1050 <cos@plt>
movaps %xmm0,%xmm1
movsd  -0x140(%rbp),%xmm0
ff
mulsd  %xmm1,%xmm0
movsd  %xmm0,-0x138(%rbp)
ff
movsd  -0xe8(%rbp),%xmm0
ff
mulsd  -0x30(%rbp),%xmm0
call   1090 <erfc@plt>
movaps %xmm0,%xmm2
movsd  -0x138(%rbp),%xmm0
ff
movsd  -0x48(%rbp),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x48(%rbp)
jmp    18d1 <EwaldU+0x761>
mov    -0x118(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x118(%rbp)
jmp    1759 <EwaldU+0x5e9>
jmp    18ea <EwaldU+0x77a>
mov    -0x114(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x114(%rbp)
jmp    1739 <EwaldU+0x5c9>
movss  0x76a(%rip),%xmm0
call   1070 <sqrt@plt>
movaps %xmm0,%xmm1
movsd  0x732(%rip),%xmm0
mulsd  %xmm1,%xmm0
mulsd  -0x30(%rbp),%xmm0
movsd  -0x28(%rbp),%xmm1
mulsd  -0x28(%rbp),%xmm1
divsd  %xmm1,%xmm0
movsd  0x70b(%rip),%xmm1
mulsd  %xmm1,%xmm0
movsd  -0x48(%rbp),%xmm1
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
movsd  0x6cb(%rip),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x48(%rbp)
movsd  -0x48(%rbp),%xmm0
add    $0x140,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<EwaldU>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x68,%rsp
movsd  %xmm1,0x38(%rsp)
movsd  %xmm0,0x40(%rsp)
movsd  0xe6e(%rip),%xmm5
divsd  %xmm4,%xmm5
test   %edi,%edi
movsd  %xmm3,0x8(%rsp)
movsd  %xmm5,0x10(%rsp)
movsd  %xmm4,0x48(%rsp)
movsd  %xmm2,0x28(%rsp)
jle    12c3 <EwaldU+0x153>
mov    %rdx,%r14
mov    %rsi,%r15
mulsd  %xmm4,%xmm4
movsd  0xe40(%rip),%xmm2
mulsd  %xmm4,%xmm2
mulsd  0xe3c(%rip),%xmm4
movsd  %xmm4,0x30(%rsp)
mov    %edi,%ebp
xorpd  %xmm1,%xmm1
xor    %ebx,%ebx
movsd  %xmm2,0x18(%rsp)
jmp    120d <EwaldU+0x9d>
nopw   0x0(%rax,%rax,1)
movapd %xmm5,%xmm0
mulsd  0xe1c(%rip),%xmm0
addsd  %xmm0,%xmm1
add    $0x1,%rbx
cmp    %rbx,%rbp
je     12c7 <EwaldU+0x157>
movsd  0x40(%rsp),%xmm0
subsd  (%r15,%rbx,8),%xmm0
movsd  0x38(%rsp),%xmm4
subsd  (%r14,%rbx,8),%xmm4
mulsd  %xmm4,%xmm4
mulsd  %xmm0,%xmm0
addsd  %xmm4,%xmm0
ucomisd %xmm2,%xmm0
jbe    11f0 <EwaldU+0x80>
movsd  %xmm1,(%rsp)
movsd  %xmm0,0x20(%rsp)
call   1040 <rsqrt64@plt>
movapd %xmm0,%xmm2
movsd  0x20(%rsp),%xmm0
ucomisd 0x30(%rsp),%xmm0
jbe    1280 <EwaldU+0x110>
movsd  (%rsp),%xmm1
subsd  %xmm2,%xmm1
movsd  0x8(%rsp),%xmm3
movsd  0x10(%rsp),%xmm5
movsd  0x18(%rsp),%xmm2
jmp    1200 <EwaldU+0x90>
cs nopw 0x0(%rax,%rax,1)
movsd  0xd98(%rip),%xmm0
divsd  %xmm2,%xmm0
mulsd  0x10(%rsp),%xmm0
movsd  %xmm2,0x20(%rsp)
call   1080 <erf@plt>
movsd  0x10(%rsp),%xmm5
mulsd  0x20(%rsp),%xmm0
movsd  (%rsp),%xmm1
subsd  %xmm0,%xmm1
movsd  0x8(%rsp),%xmm3
movsd  0x18(%rsp),%xmm2
jmp    1200 <EwaldU+0x90>
xorpd  %xmm1,%xmm1
movsd  %xmm1,(%rsp)
movsd  0xd54(%rip),%xmm0
mulsd  0x38(%rsp),%xmm0
addsd  0x40(%rsp),%xmm0
divsd  %xmm3,%xmm0
call   1060 <round@plt>
mov    %rax,%r14
movsd  0xd3c(%rip),%xmm0
mulsd  0x38(%rsp),%xmm0
divsd  0x8(%rsp),%xmm0
call   1060 <round@plt>
mov    %rax,%r15
movsd  0xd28(%rip),%xmm1
mulsd  0x48(%rsp),%xmm1
movsd  0xd22(%rip),%xmm0
movsd  %xmm1,0x18(%rsp)
mulsd  %xmm1,%xmm0
divsd  0x8(%rsp),%xmm0
call   1030 <ceil@plt>
lea    0x1(%rax),%ebp
mov    %eax,%r13d
not    %r13d
cmp    %r13d,%ebp
jge    13e8 <EwaldU+0x278>
movsd  0x8(%rsp),%xmm5
movsd  0x10(%rsp),%xmm1
mulsd  0xcdf(%rip),%xmm1
movsd  0xcdf(%rip),%xmm0
mulsd  %xmm5,%xmm0
divsd  0xceb(%rip),%xmm0
movsd  %xmm1,0x10(%rsp)
mulsd  %xmm1,%xmm0
call   1030 <ceil@plt>
mov    %rax,%r12
add    $0x1,%eax
mov    %r12d,%r15d
not    %r15d
cmp    %r15d,%eax
jge    1589 <EwaldU+0x419>
movsd  (%rsp),%xmm2
movsd  %xmm2,(%rsp)
movss  0xced(%rip),%xmm0
call   1070 <sqrt@plt>
mulsd  0xcb8(%rip),%xmm0
mulsd  0x48(%rsp),%xmm0
movsd  0x8(%rsp),%xmm1
mulsd  %xmm1,%xmm1
divsd  %xmm1,%xmm0
mulsd  0xca4(%rip),%xmm0
mulsd  0xc8c(%rip),%xmm0
addsd  (%rsp),%xmm0
add    $0x68,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret
lea    (%rax,%r14,1),%r12d
add    $0x1,%r12d
add    %r14d,%r13d
add    %r15d,%ebp
movsd  0x18(%rsp),%xmm9
mulsd  %xmm9,%xmm9
movsd  0x28(%rsp),%xmm8
addsd  0xc36(%rip),%xmm8
sub    %eax,%r15d
add    $0xfffffffe,%r15d
movsd  0xc2f(%rip),%xmm6
movsd  0x8(%rsp),%xmm5
movsd  0xbd1(%rip),%xmm7
movsd  %xmm8,0x28(%rsp)
movsd  %xmm9,0x18(%rsp)
jmp    1450 <EwaldU+0x2e0>
nop
lea    0x1(%r13),%eax
cmp    %r12d,%r13d
mov    %eax,%r13d
jge    134b <EwaldU+0x1db>
xorps  %xmm10,%xmm10
cvtsi2sd %r13d,%xmm10
mov    %r15d,%ebx
movsd  %xmm10,0x30(%rsp)
jmp    14dd <EwaldU+0x36d>
cs nopw 0x0(%rax,%rax,1)
nop
call   1040 <rsqrt64@plt>
movapd %xmm0,%xmm1
movsd  %xmm0,0x20(%rsp)
movsd  0xb99(%rip),%xmm0
divsd  %xmm1,%xmm0
mulsd  0x10(%rsp),%xmm0
call   1090 <erfc@plt>
movsd  0x30(%rsp),%xmm10
movsd  0xbab(%rip),%xmm6
movsd  0x18(%rsp),%xmm9
movsd  0xb4c(%rip),%xmm7
movsd  0x28(%rsp),%xmm8
movsd  0x8(%rsp),%xmm5
mulsd  0x20(%rsp),%xmm0
movsd  (%rsp),%xmm1
addsd  %xmm0,%xmm1
movsd  %xmm1,(%rsp)
cmp    %ebp,%ebx
jge    1440 <EwaldU+0x2d0>
add    $0x1,%ebx
xorps  %xmm1,%xmm1
cvtsi2sd %ebx,%xmm1
movapd %xmm1,%xmm2
mulsd  %xmm7,%xmm2
addsd  %xmm10,%xmm2
mulsd  %xmm6,%xmm1
movapd %xmm2,%xmm3
mulsd  %xmm5,%xmm3
movsd  0x40(%rsp),%xmm0
subsd  %xmm3,%xmm0
movapd %xmm1,%xmm3
mulsd  %xmm5,%xmm3
movsd  0x38(%rsp),%xmm4
subsd  %xmm3,%xmm4
mulsd  %xmm4,%xmm4
mulsd  %xmm0,%xmm0
addsd  %xmm4,%xmm0
ucomisd %xmm0,%xmm9
jbe    14d5 <EwaldU+0x365>
movapd %xmm1,%xmm3
mulsd  %xmm7,%xmm3
movapd %xmm2,%xmm4
mulsd  %xmm6,%xmm4
addsd  %xmm3,%xmm4
andpd  0xb35(%rip),%xmm4
ucomisd %xmm8,%xmm4
ja     1470 <EwaldU+0x300>
mulsd  %xmm6,%xmm2
subsd  %xmm3,%xmm2
andpd  0xb1a(%rip),%xmm2
ucomisd %xmm8,%xmm2
ja     1470 <EwaldU+0x300>
andpd  0xb07(%rip),%xmm1
ucomisd %xmm8,%xmm1
jbe    14d5 <EwaldU+0x365>
jmp    1470 <EwaldU+0x300>
movsd  0xac7(%rip),%xmm4
movapd %xmm4,%xmm0
movsd  0x8(%rsp),%xmm2
divsd  %xmm2,%xmm0
movsd  0xab9(%rip),%xmm1
movsd  %xmm0,0x50(%rsp)
mulsd  %xmm0,%xmm1
movsd  %xmm1,0x60(%rsp)
movsd  0xa91(%rip),%xmm0
mulsd  %xmm2,%xmm0
mulsd  %xmm2,%xmm0
divsd  %xmm0,%xmm4
movsd  0x10(%rsp),%xmm3
mulsd  %xmm3,%xmm3
mov    $0xfffffffe,%r14d
sub    %r12d,%r14d
mov    %r15d,%r13d
movsd  (%rsp),%xmm2
movsd  %xmm3,0x10(%rsp)
movsd  %xmm4,0x58(%rsp)
jmp    1614 <EwaldU+0x4a4>
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
lea    0x1(%r13),%eax
add    $0xffffffff,%r15d
cmp    %r12d,%r13d
mov    %eax,%r13d
jg     1396 <EwaldU+0x226>
xorps  %xmm5,%xmm5
cvtsi2sd %r13d,%xmm5
mulsd  0x50(%rsp),%xmm5
mov    %r15d,%ebx
mov    %r14d,%ebp
movsd  %xmm5,0x20(%rsp)
jmp    163b <EwaldU+0x4cb>
add    $0x1,%ebp
add    $0x2,%ebx
cmp    %r12d,%ebp
jg     1600 <EwaldU+0x490>
mov    %ebp,%eax
not    %eax
or     %r13d,%eax
je     1630 <EwaldU+0x4c0>
xorps  %xmm6,%xmm6
cvtsi2sd %ebx,%xmm6
mulsd  0x60(%rsp),%xmm6
movapd %xmm6,%xmm1
mulsd  %xmm6,%xmm1
movapd %xmm5,%xmm0
mulsd  %xmm5,%xmm0
addsd  %xmm1,%xmm0
ucomisd %xmm0,%xmm3
jb     1630 <EwaldU+0x4c0>
movsd  %xmm2,(%rsp)
movsd  %xmm6,0x18(%rsp)
call   1040 <rsqrt64@plt>
movapd %xmm0,%xmm1
movsd  0x999(%rip),%xmm0
divsd  %xmm1,%xmm0
movsd  %xmm0,0x30(%rsp)
mulsd  0x58(%rsp),%xmm1
movsd  %xmm1,0x28(%rsp)
movsd  0x18(%rsp),%xmm1
mulsd  0x38(%rsp),%xmm1
movsd  0x20(%rsp),%xmm0
mulsd  0x40(%rsp),%xmm0
addsd  %xmm1,%xmm0
call   1050 <cos@plt>
mulsd  0x28(%rsp),%xmm0
movsd  %xmm0,0x28(%rsp)
movsd  0x30(%rsp),%xmm0
mulsd  0x48(%rsp),%xmm0
call   1090 <erfc@plt>
movsd  0x20(%rsp),%xmm5
movsd  0x10(%rsp),%xmm3
movsd  (%rsp),%xmm2
mulsd  0x28(%rsp),%xmm0
addsd  %xmm0,%xmm2
jmp    1630 <EwaldU+0x4c0>

LLVM IR (-O0):
define double @EwaldU(double %0, double %1, i32 %2, double %3, double %4, double %5, double* %6, double* %7) {
%9 = alloca double
%10 = alloca double
%11 = alloca i32
%12 = alloca double
%13 = alloca double
%14 = alloca double
%15 = alloca double*
%16 = alloca double*
%17 = alloca double
%18 = alloca double
%19 = alloca double
%20 = alloca double
%21 = alloca double
%22 = alloca double
%23 = alloca double
%24 = alloca i32
%25 = alloca double
%26 = alloca i32
%27 = alloca i32
%28 = alloca double
%29 = alloca i32
%30 = alloca double
%31 = alloca i32
%32 = alloca i32
%33 = alloca double
%34 = alloca double
%35 = alloca double
%36 = alloca double
%37 = alloca double
%38 = alloca double
%39 = alloca double
%40 = alloca double
%41 = alloca double
%42 = alloca double
%43 = alloca double
%44 = alloca double
%45 = alloca i32
%46 = alloca i32
%47 = alloca double
store double %0, double* %9
store double %1, double* %10
store i32 %2, i32* %11
store double %3, double* %12
store double %4, double* %13
store double %5, double* %14
store double* %6, double** %15
store double* %7, double** %16
store double 0.000000e+00, double* %17
%48 = load double, double* %14
%49 = fdiv double 5.000000e-01, %48
store double %49, double* %22
%50 = load double, double* %14
%51 = load double, double* %14
%52 = fmul double %50, %51
store double %52, double* %23
store i32 0, i32* %24
br label %53
53: ; preds = %110, %8
%54 = load i32, i32* %24
%55 = load i32, i32* %11
%56 = icmp slt i32 %54, %55
br i1 %56, label %57, label %113
57: ; preds = %53
%58 = load double, double* %9
%59 = load double*, double** %15
%60 = load i32, i32* %24
%61 = sext i32 %60 to i64
%62 = getelementptr inbounds double, double* %59, i64 %61
%63 = load double, double* %62
%64 = fsub double %58, %63
store double %64, double* %18
%65 = load double, double* %10
%66 = load double*, double** %16
%67 = load i32, i32* %24
%68 = sext i32 %67 to i64
%69 = getelementptr inbounds double, double* %66, i64 %68
%70 = load double, double* %69
%71 = fsub double %65, %70
store double %71, double* %19
%72 = load double, double* %18
%73 = load double, double* %18
%74 = load double, double* %19
%75 = load double, double* %19
%76 = fmul double %74, %75
%77 = call double @llvm.fmuladd.f64(double %72, double %73, double %76)
store double %77, double* %25
%78 = load double, double* %25
%79 = load double, double* %23
%80 = fmul double 0x3C9CD2B297D889BC, %79
%81 = fcmp ogt double %78, %80
br i1 %81, label %82, label %105
82: ; preds = %57
%83 = load double, double* %25
%84 = call double @rsqrt64(double %83)
store double %84, double* %21
%85 = load double, double* %25
%86 = load double, double* %23
%87 = fmul double 1.000000e+02, %86
%88 = fcmp ogt double %85, %87
br i1 %88, label %89, label %93
89: ; preds = %82
%90 = load double, double* %21
%91 = load double, double* %17
%92 = fsub double %91, %90
store double %92, double* %17
br label %104
93: ; preds = %82
%94 = load double, double* %21
%95 = fdiv double 1.000000e+00, %94
store double %95, double* %20
%96 = load double, double* %21
%97 = load double, double* %20
%98 = load double, double* %22
%99 = fmul double %97, %98
%100 = call double @erf(double %99)
%101 = load double, double* %17
%102 = fneg double %96
%103 = call double @llvm.fmuladd.f64(double %102, double %100, double %101)
store double %103, double* %17
br label %104
104: ; preds = %93, %89
br label %109
105: ; preds = %57
%106 = load double, double* %22
%107 = load double, double* %17
%108 = call double @llvm.fmuladd.f64(double 0xBFF20DD75042EA5F, double %106, double %107)
store double %108, double* %17
br label %109
109: ; preds = %105, %104
br label %110
110: ; preds = %109
%111 = load i32, i32* %24
%112 = add nsw i32 %111, 1
store i32 %112, i32* %24
br label %53
113: ; preds = %53
%114 = load double, double* %9
%115 = load double, double* %10
%116 = fneg double %115
%117 = call double @llvm.fmuladd.f64(double %116, double 0x3FE279A745903342, double %114)
%118 = load double, double* %13
%119 = fdiv double %117, %118
%120 = call i64 @round(double %119)
%121 = trunc i64 %120 to i32
store i32 %121, i32* %26
%122 = load double, double* %10
%123 = fmul double 0x3FF279A745903342, %122
%124 = load double, double* %13
%125 = fdiv double %123, %124
%126 = call i64 @round(double %125)
%127 = trunc i64 %126 to i32
store i32 %127, i32* %27
%128 = load double, double* %14
%129 = fmul double 1.000000e+01, %128
store double %129, double* %28
%130 = load double, double* %28
%131 = fmul double 1.200000e+00, %130
%132 = load double, double* %13
%133 = fdiv double %131, %132
%134 = call i64 @ceil(double %133)
%135 = trunc i64 %134 to i32
%136 = add nsw i32 %135, 1
store i32 %136, i32* %29
store double 0x3EB0C6F7A0B5ED8D, double* %30
%137 = load i32, i32* %29
%138 = sub nsw i32 0, %137
%139 = load i32, i32* %26
%140 = add nsw i32 %138, %139
store i32 %140, i32* %31
br label %141
141: ; preds = %237, %113
%142 = load i32, i32* %31
%143 = load i32, i32* %29
%144 = load i32, i32* %26
%145 = add nsw i32 %143, %144
%146 = icmp sle i32 %142, %145
br i1 %146, label %147, label %240
147: ; preds = %141
%148 = load i32, i32* %29
%149 = sub nsw i32 0, %148
%150 = load i32, i32* %27
%151 = add nsw i32 %149, %150
store i32 %151, i32* %32
br label %152
152: ; preds = %233, %147
%153 = load i32, i32* %32
%154 = load i32, i32* %29
%155 = load i32, i32* %27
%156 = add nsw i32 %154, %155
%157 = icmp sle i32 %153, %156
br i1 %157, label %158, label %236
158: ; preds = %152
%159 = load i32, i32* %31
%160 = sitofp i32 %159 to double
%161 = load i32, i32* %32
%162 = sitofp i32 %161 to double
%163 = call double @llvm.fmuladd.f64(double %162, double 5.000000e-01, double %160)
store double %163, double* %33
%164 = load i32, i32* %32
%165 = sitofp i32 %164 to double
%166 = fmul double %165, 0x3FEBB67AE8584CB7
store double %166, double* %34
%167 = load double, double* %9
%168 = load double, double* %33
%169 = load double, double* %13
%170 = fneg double %168
%171 = call double @llvm.fmuladd.f64(double %170, double %169, double %167)
store double %171, double* %18
%172 = load double, double* %10
%173 = load double, double* %34
%174 = load double, double* %13
%175 = fneg double %173
%176 = call double @llvm.fmuladd.f64(double %175, double %174, double %172)
store double %176, double* %19
%177 = load double, double* %18
%178 = load double, double* %18
%179 = load double, double* %19
%180 = load double, double* %19
%181 = fmul double %179, %180
%182 = call double @llvm.fmuladd.f64(double %177, double %178, double %181)
%183 = load double, double* %28
%184 = load double, double* %28
%185 = fmul double %183, %184
%186 = fcmp olt double %182, %185
br i1 %186, label %187, label %232
187: ; preds = %158
%188 = load double, double* %33
%189 = load double, double* %34
%190 = fmul double 5.000000e-01, %189
%191 = call double @llvm.fmuladd.f64(double 0x3FEBB67AE8584CB7, double %188, double %190)
%192 = call double @llvm.fabs.f64(double %191)
%193 = load double, double* %12
%194 = load double, double* %30
%195 = fadd double %193, %194
%196 = fcmp ogt double %192, %195
br i1 %196, label %215, label %197
197: ; preds = %187
%198 = load double, double* %33
%199 = load double, double* %34
%200 = fmul double 5.000000e-01, %199
%201 = fneg double %200
%202 = call double @llvm.fmuladd.f64(double 0x3FEBB67AE8584CB7, double %198, double %201)
%203 = call double @llvm.fabs.f64(double %202)
%204 = load double, double* %12
%205 = load double, double* %30
%206 = fadd double %204, %205
%207 = fcmp ogt double %203, %206
br i1 %207, label %215, label %208
208: ; preds = %197
%209 = load double, double* %34
%210 = call double @llvm.fabs.f64(double %209)
%211 = load double, double* %12
%212 = load double, double* %30
%213 = fadd double %211, %212
%214 = fcmp ogt double %210, %213
br i1 %214, label %215, label %232
215: ; preds = %208, %197, %187
%216 = load double, double* %18
%217 = load double, double* %18
%218 = load double, double* %19
%219 = load double, double* %19
%220 = fmul double %218, %219
%221 = call double @llvm.fmuladd.f64(double %216, double %217, double %220)
%222 = call double @rsqrt64(double %221)
store double %222, double* %21
%223 = load double, double* %21
%224 = fdiv double 1.000000e+00, %223
store double %224, double* %35
%225 = load double, double* %21
%226 = load double, double* %35
%227 = load double, double* %22
%228 = fmul double %226, %227
%229 = call double @erfc(double %228)
%230 = load double, double* %17
%231 = call double @llvm.fmuladd.f64(double %225, double %229, double %230)
store double %231, double* %17
br label %232
232: ; preds = %215, %208, %158
br label %233
233: ; preds = %232
%234 = load i32, i32* %32
%235 = add nsw i32 %234, 1
store i32 %235, i32* %32
br label %152
236: ; preds = %152
br label %237
237: ; preds = %236
%238 = load i32, i32* %31
%239 = add nsw i32 %238, 1
store i32 %239, i32* %31
br label %141
240: ; preds = %141
%241 = load double, double* %22
%242 = fmul double 1.000000e+01, %241
store double %242, double* %40
%243 = load double, double* %13
%244 = fmul double 1.200000e+00, %243
%245 = fdiv double %244, 0x401921FB60000000
%246 = load double, double* %40
%247 = fmul double %245, %246
%248 = call i64 @ceil(double %247)
%249 = trunc i64 %248 to i32
%250 = add nsw i32 %249, 1
store i32 %250, i32* %29
%251 = load double, double* %13
%252 = fdiv double 0x401921FB60000000, %251
store double %252, double* %42
%253 = load double, double* %42
%254 = fmul double %253, 0x3FE279A745903342
store double %254, double* %43
%255 = load double, double* %13
%256 = fmul double 0x3FEBB67AE8584CB7, %255
%257 = load double, double* %13
%258 = fmul double %256, %257
%259 = fdiv double 0x401921FB60000000, %258
store double %259, double* %44
%260 = load i32, i32* %29
%261 = sub nsw i32 0, %260
store i32 %261, i32* %45
br label %262
262: ; preds = %329, %240
%263 = load i32, i32* %45
%264 = load i32, i32* %29
%265 = icmp sle i32 %263, %264
br i1 %265, label %266, label %332
266: ; preds = %262
%267 = load i32, i32* %29
%268 = sub nsw i32 0, %267
store i32 %268, i32* %46
br label %269
269: ; preds = %325, %266
%270 = load i32, i32* %46
%271 = load i32, i32* %29
%272 = icmp sle i32 %270, %271
br i1 %272, label %273, label %328
273: ; preds = %269
%274 = load double, double* %42
%275 = load i32, i32* %45
%276 = sitofp i32 %275 to double
%277 = fmul double %274, %276
store double %277, double* %36
%278 = load double, double* %43
%279 = load i32, i32* %46
%280 = mul nsw i32 2, %279
%281 = load i32, i32* %45
%282 = sub nsw i32 %280, %281
%283 = sitofp i32 %282 to double
%284 = fmul double %278, %283
store double %284, double* %37
%285 = load double, double* %36
%286 = load double, double* %36
%287 = load double, double* %37
%288 = load double, double* %37
%289 = fmul double %287, %288
%290 = call double @llvm.fmuladd.f64(double %285, double %286, double %289)
store double %290, double* %47
%291 = load i32, i32* %45
%292 = icmp ne i32 %291, 0
br i1 %292, label %296, label %293
293: ; preds = %273
%294 = load i32, i32* %46
%295 = icmp ne i32 %294, 0
br i1 %295, label %296, label %324
296: ; preds = %293, %273
%297 = load double, double* %47
%298 = load double, double* %40
%299 = load double, double* %40
%300 = fmul double %298, %299
%301 = fcmp ole double %297, %300
br i1 %301, label %302, label %324
302: ; preds = %296
%303 = load double, double* %47
%304 = call double @rsqrt64(double %303)
store double %304, double* %38
%305 = load double, double* %38
%306 = fdiv double 1.000000e+00, %305
store double %306, double* %39
%307 = load double, double* %44
%308 = load double, double* %38
%309 = fmul double %307, %308
%310 = load double, double* %36
%311 = load double, double* %9
%312 = load double, double* %37
%313 = load double, double* %10
%314 = fmul double %312, %313
%315 = call double @llvm.fmuladd.f64(double %310, double %311, double %314)
%316 = call double @cos(double %315)
%317 = fmul double %309, %316
%318 = load double, double* %39
%319 = load double, double* %14
%320 = fmul double %318, %319
%321 = call double @erfc(double %320)
%322 = load double, double* %17
%323 = call double @llvm.fmuladd.f64(double %317, double %321, double %322)
store double %323, double* %17
br label %324
324: ; preds = %302, %296, %293
br label %325
325: ; preds = %324
%326 = load i32, i32* %46
%327 = add nsw i32 %326, 1
store i32 %327, i32* %46
br label %269
328: ; preds = %269
br label %329
329: ; preds = %328
%330 = load i32, i32* %45
%331 = add nsw i32 %330, 1
store i32 %331, i32* %45
br label %262
332: ; preds = %262
%333 = call double @sqrt(float 0x400921FB60000000)
%334 = fmul double 4.000000e+00, %333
%335 = load double, double* %14
%336 = fmul double %334, %335
%337 = load double, double* %13
%338 = load double, double* %13
%339 = fmul double %337, %338
%340 = fdiv double %336, %339
%341 = fmul double %340, 2.000000e+00
%342 = load double, double* %17
%343 = fneg double %341
%344 = call double @llvm.fmuladd.f64(double %343, double 0x3FE279A745903342, double %342)
store double %344, double* %17
%345 = load double, double* %17
ret double %345
}

LLVM IR (-O2):
define double @EwaldU(double %0, double %1, i32 %2, double %3, double %4, double %5, double* nocapture %6, double* nocapture %7) {
%9 = fdiv double 5.000000e-01, %5
%10 = fmul double %5, %5
%11 = icmp sgt i32 %2, 0
br i1 %11, label %12, label %16
12: ; preds = %8
%13 = fmul double %10, 0x3C9CD2B297D889BC
%14 = fmul double %10, 1.000000e+02
%15 = zext i32 %2 to i64
br label %42
16: ; preds = %67, %8
%17 = phi double [ 0.000000e+00, %8 ], [ %68, %67 ]
%18 = fneg double %1
%19 = tail call double @llvm.fmuladd.f64(double %18, double 0x3FE279A745903342, double %0)
%20 = fdiv double %19, %4
%21 = tail call i64 @round(double %20)
%22 = trunc i64 %21 to i32
%23 = fmul double %1, 0x3FF279A745903342
%24 = fdiv double %23, %4
%25 = tail call i64 @round(double %24)
%26 = trunc i64 %25 to i32
%27 = fmul double %5, 1.000000e+01
%28 = fmul double %27, 1.200000e+00
%29 = fdiv double %28, %4
%30 = tail call i64 @ceil(double %29)
%31 = trunc i64 %30 to i32
%32 = add nsw i32 %31, 1
%33 = xor i32 %31, -1
%34 = add nsw i32 %32, %22
%35 = icmp slt i32 %32, %33
br i1 %35, label %71, label %36
36: ; preds = %16
%37 = add nsw i32 %33, %22
%38 = add nsw i32 %33, %26
%39 = add nsw i32 %32, %26
%40 = fmul double %27, %27
%41 = fadd double %3, 0x3EB0C6F7A0B5ED8D
br label %89
42: ; preds = %12, %67
%43 = phi i64 [ 0, %12 ], [ %69, %67 ]
%44 = phi double [ 0.000000e+00, %12 ], [ %68, %67 ]
%45 = getelementptr inbounds double, double* %6, i64 %43
%46 = load double, double* %45
%47 = fsub double %0, %46
%48 = getelementptr inbounds double, double* %7, i64 %43
%49 = load double, double* %48
%50 = fsub double %1, %49
%51 = fmul double %50, %50
%52 = tail call double @llvm.fmuladd.f64(double %47, double %47, double %51)
%53 = fcmp ogt double %52, %13
br i1 %53, label %54, label %65
54: ; preds = %42
%55 = tail call double @rsqrt64(double %52)
%56 = fcmp ogt double %52, %14
br i1 %56, label %57, label %59
57: ; preds = %54
%58 = fsub double %44, %55
br label %67
59: ; preds = %54
%60 = fdiv double 1.000000e+00, %55
%61 = fmul double %9, %60
%62 = tail call double @erf(double %61)
%63 = fneg double %55
%64 = tail call double @llvm.fmuladd.f64(double %63, double %62, double %44)
br label %67
65: ; preds = %42
%66 = tail call double @llvm.fmuladd.f64(double %9, double 0xBFF20DD75042EA5F, double %44)
br label %67
67: ; preds = %57, %59, %65
%68 = phi double [ %58, %57 ], [ %64, %59 ], [ %66, %65 ]
%69 = add nuw nsw i64 %43, 1
%70 = icmp eq i64 %69, %15
br i1 %70, label %16, label %42
71: ; preds = %93, %16
%72 = phi double [ %17, %16 ], [ %129, %93 ]
%73 = fmul double %9, 1.000000e+01
%74 = fmul double %4, 1.200000e+00
%75 = fdiv double %74, 0x401921FB60000000
%76 = fmul double %75, %73
%77 = tail call i64 @ceil(double %76)
%78 = trunc i64 %77 to i32
%79 = add nsw i32 %78, 1
%80 = fdiv double 0x401921FB60000000, %4
%81 = fmul double %80, 0x3FE279A745903342
%82 = fmul double %4, 0x3FEBB67AE8584CB7
%83 = fmul double %82, %4
%84 = fdiv double 0x401921FB60000000, %83
%85 = xor i32 %78, -1
%86 = icmp slt i32 %79, %85
br i1 %86, label %138, label %87
87: ; preds = %71
%88 = fmul double %73, %73
br label %132
89: ; preds = %93, %36
%90 = phi double [ %17, %36 ], [ %129, %93 ]
%91 = phi i32 [ %37, %36 ], [ %94, %93 ]
%92 = sitofp i32 %91 to double
br label %96
93: ; preds = %128
%94 = add nsw i32 %91, 1
%95 = icmp slt i32 %91, %34
br i1 %95, label %89, label %71
96: ; preds = %89, %128
%97 = phi double [ %90, %89 ], [ %129, %128 ]
%98 = phi i32 [ %38, %89 ], [ %130, %128 ]
%99 = sitofp i32 %98 to double
%100 = tail call double @llvm.fmuladd.f64(double %99, double 5.000000e-01, double %92)
%101 = fmul double %99, 0x3FEBB67AE8584CB7
%102 = fneg double %100
%103 = tail call double @llvm.fmuladd.f64(double %102, double %4, double %0)
%104 = fneg double %101
%105 = tail call double @llvm.fmuladd.f64(double %104, double %4, double %1)
%106 = fmul double %105, %105
%107 = tail call double @llvm.fmuladd.f64(double %103, double %103, double %106)
%108 = fcmp olt double %107, %40
br i1 %108, label %109, label %128
109: ; preds = %96
%110 = fmul double %101, 5.000000e-01
%111 = tail call double @llvm.fmuladd.f64(double %100, double 0x3FEBB67AE8584CB7, double %110)
%112 = tail call double @llvm.fabs.f64(double %111)
%113 = fcmp ogt double %112, %41
br i1 %113, label %122, label %114
114: ; preds = %109
%115 = fneg double %110
%116 = tail call double @llvm.fmuladd.f64(double %100, double 0x3FEBB67AE8584CB7, double %115)
%117 = tail call double @llvm.fabs.f64(double %116)
%118 = fcmp ogt double %117, %41
%119 = tail call double @llvm.fabs.f64(double %101)
%120 = fcmp ogt double %119, %41
%121 = select i1 %118, i1 true, i1 %120
br i1 %121, label %122, label %128
122: ; preds = %114, %109
%123 = tail call double @rsqrt64(double %107)
%124 = fdiv double 1.000000e+00, %123
%125 = fmul double %9, %124
%126 = tail call double @erfc(double %125)
%127 = tail call double @llvm.fmuladd.f64(double %123, double %126, double %97)
br label %128
128: ; preds = %114, %122, %96
%129 = phi double [ %127, %122 ], [ %97, %96 ], [ %97, %114 ]
%130 = add nsw i32 %98, 1
%131 = icmp slt i32 %98, %39
br i1 %131, label %96, label %93
132: ; preds = %147, %87
%133 = phi double [ %72, %87 ], [ %175, %147 ]
%134 = phi i32 [ %85, %87 ], [ %148, %147 ]
%135 = sitofp i32 %134 to double
%136 = fmul double %80, %135
%137 = icmp eq i32 %134, 0
br label %150
138: ; preds = %147, %71
%139 = phi double [ %72, %71 ], [ %175, %147 ]
%140 = tail call double @sqrt(float 0x400921FB60000000)
%141 = fmul double %140, 4.000000e+00
%142 = fmul double %141, %5
%143 = fmul double %4, %4
%144 = fdiv double %142, %143
%145 = fmul double %144, -2.000000e+00
%146 = tail call double @llvm.fmuladd.f64(double %145, double 0x3FE279A745903342, double %139)
ret double %146
147: ; preds = %174
%148 = add nsw i32 %134, 1
%149 = icmp sgt i32 %134, %78
br i1 %149, label %138, label %132
150: ; preds = %132, %174
%151 = phi double [ %133, %132 ], [ %175, %174 ]
%152 = phi i32 [ %85, %132 ], [ %176, %174 ]
%153 = shl nsw i32 %152, 1
%154 = sub nsw i32 %153, %134
%155 = sitofp i32 %154 to double
%156 = fmul double %81, %155
%157 = fmul double %156, %156
%158 = tail call double @llvm.fmuladd.f64(double %136, double %136, double %157)
%159 = icmp eq i32 %152, 0
%160 = select i1 %137, i1 %159, i1 false
%161 = fcmp ugt double %158, %88
%162 = select i1 %160, i1 true, i1 %161
br i1 %162, label %174, label %163
163: ; preds = %150
%164 = tail call double @rsqrt64(double %158)
%165 = fdiv double 1.000000e+00, %164
%166 = fmul double %84, %164
%167 = fmul double %156, %1
%168 = tail call double @llvm.fmuladd.f64(double %136, double %0, double %167)
%169 = tail call double @cos(double %168)
%170 = fmul double %166, %169
%171 = fmul double %165, %5
%172 = tail call double @erfc(double %171)
%173 = tail call double @llvm.fmuladd.f64(double %170, double %172, double %151)
br label %174
174: ; preds = %150, %163
%175 = phi double [ %173, %163 ], [ %151, %150 ]
%176 = add nsw i32 %152, 1
%177 = icmp sgt i32 %152, %78
br i1 %177, label %147, label %150
}