#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 smoothedHeaviside(double, double);
double sqrt(double);
void redistanceLevelSetCoefficientsEvaluate(int nPoints, int nSpace, double eps,
                                            double *u_levelSet, double *u,
                                            double *grad_u, double *m,
                                            double *dm, double *H, double *dH,
                                            double *r) {
  int i, I;
  double Si, normGradU;
  for (i = 0; i < nPoints; i++) {
    m[i] = u[i];
    dm[i] = 1.0;
    H[i] = 0.0;
    Si = -1.0 + 2.0 * smoothedHeaviside(eps, u_levelSet[i]);
    ;
    r[i] = -Si;
    normGradU = 0.0;
    for (I = 0; I < nSpace; I++)
      normGradU += grad_u[i * nSpace + I] * grad_u[i * nSpace + I];
    normGradU = sqrt(normGradU);
    H[i] = Si * normGradU;
    for (I = 0; I < nSpace; I++) {
      dH[i * nSpace + I] = Si * grad_u[i * nSpace + I] / (normGradU + 1.0e-12);
    }
  }
}


x86 assembly (clang, -O0):
<redistanceLevelSetCoefficientsEvaluate>:
push   %rbp
mov    %rsp,%rbp
sub    $0x50,%rsp
mov    0x28(%rbp),%rax
mov    0x20(%rbp),%rax
mov    0x18(%rbp),%rax
mov    0x10(%rbp),%rax
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
movsd  %xmm0,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %rcx,-0x20(%rbp)
mov    %r8,-0x28(%rbp)
mov    %r9,-0x30(%rbp)
movl   $0x0,-0x34(%rbp)
mov    -0x34(%rbp),%eax
cmp    -0x4(%rbp),%eax
jge    12fd <redistanceLevelSetCoefficientsEvaluate+0x1dd>
mov    -0x20(%rbp),%rax
movslq -0x34(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x30(%rbp),%rax
movslq -0x34(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    0x10(%rbp),%rax
movslq -0x34(%rbp),%rcx
movsd  0xe78(%rip),%xmm0
movsd  %xmm0,(%rax,%rcx,8)
mov    0x18(%rbp),%rax
movslq -0x34(%rbp),%rcx
xorps  %xmm0,%xmm0
movsd  %xmm0,(%rax,%rcx,8)
movsd  -0x10(%rbp),%xmm0
mov    -0x18(%rbp),%rax
movslq -0x34(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm1
call   1040 <smoothedHeaviside@plt>
addsd  %xmm0,%xmm0
movsd  0xe38(%rip),%xmm1
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x40(%rbp)
movsd  -0x40(%rbp),%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mov    0x28(%rbp),%rax
movslq -0x34(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
xorps  %xmm0,%xmm0
movsd  %xmm0,-0x48(%rbp)
movl   $0x0,-0x38(%rbp)
mov    -0x38(%rbp),%eax
cmp    -0x8(%rbp),%eax
jge    1261 <redistanceLevelSetCoefficientsEvaluate+0x141>
mov    -0x28(%rbp),%rax
mov    -0x34(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x38(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x28(%rbp),%rax
mov    -0x34(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x38(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm2
movsd  -0x48(%rbp),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x48(%rbp)
mov    -0x38(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x38(%rbp)
jmp    1209 <redistanceLevelSetCoefficientsEvaluate+0xe9>
movsd  -0x48(%rbp),%xmm0
call   1030 <sqrt@plt>
movsd  %xmm0,-0x48(%rbp)
movsd  -0x40(%rbp),%xmm0
mulsd  -0x48(%rbp),%xmm0
mov    0x18(%rbp),%rax
movslq -0x34(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
movl   $0x0,-0x38(%rbp)
mov    -0x38(%rbp),%eax
cmp    -0x8(%rbp),%eax
jge    12ea <redistanceLevelSetCoefficientsEvaluate+0x1ca>
movsd  -0x40(%rbp),%xmm0
mov    -0x28(%rbp),%rax
mov    -0x34(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x38(%rbp),%ecx
movslq %ecx,%rcx
mulsd  (%rax,%rcx,8),%xmm0
movsd  0xd53(%rip),%xmm1
addsd  -0x48(%rbp),%xmm1
divsd  %xmm1,%xmm0
mov    0x20(%rbp),%rax
mov    -0x34(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x38(%rbp),%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x38(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x38(%rbp)
jmp    128e <redistanceLevelSetCoefficientsEvaluate+0x16e>
jmp    12ef <redistanceLevelSetCoefficientsEvaluate+0x1cf>
mov    -0x34(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x34(%rbp)
jmp    115a <redistanceLevelSetCoefficientsEvaluate+0x3a>
add    $0x50,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<redistanceLevelSetCoefficientsEvaluate>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0xa8,%rsp
mov    %r9,0x88(%rsp)
mov    %rcx,0x80(%rsp)
mov    %rdx,0x78(%rsp)
movsd  %xmm0,0x70(%rsp)
mov    %esi,0x4(%rsp)
test   %edi,%edi
jle    1501 <redistanceLevelSetCoefficientsEvaluate+0x3e1>
mov    0xf0(%rsp),%rax
mov    0xe8(%rsp),%r9
movslq 0x4(%rsp),%rcx
mov    %edi,%edx
mov    %rdx,0x68(%rsp)
mov    %ecx,%r10d
lea    -0x1(%r10),%rdx
mov    %rdx,0x58(%rsp)
mov    %r10d,%edx
and    $0xfffffffe,%edx
mov    %rdx,0x38(%rsp)
add    $0xfffffffffffffffe,%rdx
mov    %rdx,0x30(%rsp)
mov    %rdx,%rsi
shr    %rsi
add    $0x1,%rsi
mov    %r10d,%r13d
and    $0x3,%r13d
mov    %r10d,%edx
and    $0xfffffffc,%edx
mov    %rdx,0x40(%rsp)
mov    %rsi,%rdx
mov    %rsi,0x28(%rsp)
and    $0xfffffffffffffffe,%rsi
mov    %rsi,0x20(%rsp)
mov    %r10,%rdx
neg    %rdx
mov    %rdx,0x48(%rsp)
lea    0x18(%r8),%rbx
mov    %rcx,0x50(%rsp)
lea    0x0(,%rcx,8),%rcx
mov    %rcx,0x60(%rsp)
lea    0x10(%rax),%rbp
lea    0x8(%rax),%r14
xor    %r12d,%r12d
mov    %r8,%r15
mov    %r8,0x18(%rsp)
mov    %r10,0x10(%rsp)
jmp    1237 <redistanceLevelSetCoefficientsEvaluate+0x117>
nopl   0x0(%rax)
mulsd  0xe08(%rip),%xmm4
movsd  %xmm4,0x0(%rbp,%r12,8)
mov    %rbp,%r9
mov    0x8(%rsp),%rbp
add    $0x1,%r12
mov    0x60(%rsp),%rax
add    %rax,%rbx
add    %rax,%r15
add    %rax,%rbp
add    %rax,%r14
cmp    0x68(%rsp),%r12
je     1501 <redistanceLevelSetCoefficientsEvaluate+0x3e1>
mov    %rbp,0x8(%rsp)
mov    0x80(%rsp),%rax
movsd  (%rax,%r12,8),%xmm0
mov    0x88(%rsp),%rax
movsd  %xmm0,(%rax,%r12,8)
mov    0xe0(%rsp),%rax
movabs $0x3ff0000000000000,%rcx
mov    %rcx,(%rax,%r12,8)
movq   $0x0,(%r9,%r12,8)
mov    0x78(%rsp),%rax
movsd  (%rax,%r12,8),%xmm1
movsd  0x70(%rsp),%xmm0
mov    %r9,%rbp
call   1040 <smoothedHeaviside@plt>
movapd %xmm0,%xmm4
addsd  %xmm0,%xmm4
addsd  0xd61(%rip),%xmm4
movapd %xmm4,%xmm0
xorpd  0xd75(%rip),%xmm0
mov    0xf8(%rsp),%rax
movlpd %xmm0,(%rax,%r12,8)
cmpl   $0x0,0x4(%rsp)
jle    1200 <redistanceLevelSetCoefficientsEvaluate+0xe0>
cmpq   $0x3,0x58(%rsp)
jae    12e0 <redistanceLevelSetCoefficientsEvaluate+0x1c0>
xorpd  %xmm0,%xmm0
xor    %eax,%eax
jmp    1330 <redistanceLevelSetCoefficientsEvaluate+0x210>
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
xorpd  %xmm0,%xmm0
xor    %eax,%eax
mov    0x40(%rsp),%rcx
nopl   0x0(%rax,%rax,1)
movsd  -0x18(%rbx,%rax,8),%xmm1
movsd  -0x10(%rbx,%rax,8),%xmm2
mulsd  %xmm1,%xmm1
addsd  %xmm0,%xmm1
mulsd  %xmm2,%xmm2
addsd  %xmm1,%xmm2
movsd  -0x8(%rbx,%rax,8),%xmm1
mulsd  %xmm1,%xmm1
addsd  %xmm2,%xmm1
movsd  (%rbx,%rax,8),%xmm0
mulsd  %xmm0,%xmm0
addsd  %xmm1,%xmm0
add    $0x4,%rax
cmp    %rax,%rcx
jne    12f0 <redistanceLevelSetCoefficientsEvaluate+0x1d0>
test   %r13,%r13
je     1356 <redistanceLevelSetCoefficientsEvaluate+0x236>
lea    (%r15,%rax,8),%rax
xor    %ecx,%ecx
nopl   0x0(%rax,%rax,1)
movsd  (%rax,%rcx,8),%xmm1
mulsd  %xmm1,%xmm1
addsd  %xmm1,%xmm0
add    $0x1,%rcx
cmp    %rcx,%r13
jne    1340 <redistanceLevelSetCoefficientsEvaluate+0x220>
ucomisd 0xcb2(%rip),%xmm0
jb     1370 <redistanceLevelSetCoefficientsEvaluate+0x250>
sqrtsd %xmm0,%xmm0
jmp    1387 <redistanceLevelSetCoefficientsEvaluate+0x267>
cs nopw 0x0(%rax,%rax,1)
movapd %xmm4,0x90(%rsp)
call   1030 <sqrt@plt>
movapd 0x90(%rsp),%xmm4
mov    0x18(%rsp),%r8
mov    0xf0(%rsp),%rdi
mov    0xe8(%rsp),%r9
mov    0x10(%rsp),%r10
mov    0x8(%rsp),%rbp
movapd %xmm4,%xmm1
mulsd  %xmm0,%xmm1
movsd  %xmm1,(%r9,%r12,8)
cmpl   $0x0,0x4(%rsp)
jle    1217 <redistanceLevelSetCoefficientsEvaluate+0xf7>
mov    %r12,%rax
imul   0x50(%rsp),%rax
addsd  0xc38(%rip),%xmm0
cmpl   $0x1,0x4(%rsp)
je     13f9 <redistanceLevelSetCoefficientsEvaluate+0x2d9>
lea    (%rax,%r10,1),%rcx
lea    (%rdi,%rax,8),%rdx
lea    (%r8,%rcx,8),%rsi
cmp    %rsi,%rdx
jae    1468 <redistanceLevelSetCoefficientsEvaluate+0x348>
lea    (%rdi,%rcx,8),%rcx
lea    (%r8,%rax,8),%rdx
cmp    %rcx,%rdx
jae    1468 <redistanceLevelSetCoefficientsEvaluate+0x348>
xor    %edx,%edx
mov    %rdx,%rcx
test   $0x1,%r10b
je     1421 <redistanceLevelSetCoefficientsEvaluate+0x301>
add    %rdx,%rax
movsd  (%r8,%rax,8),%xmm1
mulsd  %xmm4,%xmm1
divsd  %xmm0,%xmm1
movsd  %xmm1,(%rdi,%rax,8)
mov    %rdx,%rcx
or     $0x1,%rcx
not    %rdx
cmp    0x48(%rsp),%rdx
je     1217 <redistanceLevelSetCoefficientsEvaluate+0xf7>
nop
movsd  (%r15,%rcx,8),%xmm1
mulsd  %xmm4,%xmm1
divsd  %xmm0,%xmm1
movsd  %xmm1,-0x8(%r14,%rcx,8)
movsd  0x8(%r15,%rcx,8),%xmm1
mulsd  %xmm4,%xmm1
divsd  %xmm0,%xmm1
movsd  %xmm1,(%r14,%rcx,8)
add    $0x2,%rcx
cmp    %rcx,%r10
jne    1430 <redistanceLevelSetCoefficientsEvaluate+0x310>
jmp    1217 <redistanceLevelSetCoefficientsEvaluate+0xf7>
movapd %xmm4,%xmm1
unpcklpd %xmm4,%xmm1
movapd %xmm0,%xmm2
unpcklpd %xmm0,%xmm2
cmpq   $0x0,0x30(%rsp)
je     14f6 <redistanceLevelSetCoefficientsEvaluate+0x3d6>
mov    0x20(%rsp),%rdx
xor    %ecx,%ecx
nopw   0x0(%rax,%rax,1)
movupd (%r15,%rcx,8),%xmm3
mulpd  %xmm1,%xmm3
divpd  %xmm2,%xmm3
movupd %xmm3,-0x10(%rbp,%rcx,8)
movupd 0x10(%r15,%rcx,8),%xmm3
mulpd  %xmm1,%xmm3
divpd  %xmm2,%xmm3
movupd %xmm3,0x0(%rbp,%rcx,8)
add    $0x4,%rcx
add    $0xfffffffffffffffe,%rdx
jne    1490 <redistanceLevelSetCoefficientsEvaluate+0x370>
testb  $0x1,0x28(%rsp)
je     14e0 <redistanceLevelSetCoefficientsEvaluate+0x3c0>
add    %rax,%rcx
movupd (%r8,%rcx,8),%xmm3
mulpd  %xmm3,%xmm1
divpd  %xmm2,%xmm1
movupd %xmm1,(%rdi,%rcx,8)
mov    0x38(%rsp),%rcx
mov    %rcx,%rdx
cmp    %r10,%rcx
je     1217 <redistanceLevelSetCoefficientsEvaluate+0xf7>
jmp    13fb <redistanceLevelSetCoefficientsEvaluate+0x2db>
xor    %ecx,%ecx
testb  $0x1,0x28(%rsp)
jne    14ca <redistanceLevelSetCoefficientsEvaluate+0x3aa>
jmp    14e0 <redistanceLevelSetCoefficientsEvaluate+0x3c0>
add    $0xa8,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

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

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