void add_point_to_cluster(unsigned int cluster_ind, double *CX,
                          const double *px, double pw, unsigned int *nr_points,
                          double *CW, unsigned int dim) {
  double *pcx = CX + cluster_ind * dim;
  if (nr_points[cluster_ind] == 0) {
    (nr_points[cluster_ind])++;
    CW[cluster_ind] = pw;
    for (unsigned int k = 0; k < dim; k++)
      pcx[k] = px[k];
  } else {
    double cw_old = CW[cluster_ind];
    (nr_points[cluster_ind])++;
    CW[cluster_ind] += pw;
    double cw_new = CW[cluster_ind];
    for (unsigned int k = 0; k < dim; k++)
      pcx[k] = (cw_old * pcx[k] + pw * px[k]) / cw_new;
  }
}


x86 assembly (clang, -O0):
<add_point_to_cluster>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
movsd  %xmm0,-0x20(%rbp)
mov    %rcx,-0x28(%rbp)
mov    %r8,-0x30(%rbp)
mov    %r9d,-0x34(%rbp)
mov    -0x10(%rbp),%rax
mov    -0x4(%rbp),%ecx
imul   -0x34(%rbp),%ecx
mov    %ecx,%ecx
shl    $0x3,%rcx
add    %rcx,%rax
mov    %rax,-0x40(%rbp)
mov    -0x28(%rbp),%rax
mov    -0x4(%rbp),%ecx
cmpl   $0x0,(%rax,%rcx,4)
jne    11a8 <add_point_to_cluster+0xa8>
mov    -0x28(%rbp),%rax
mov    -0x4(%rbp),%ecx
mov    (%rax,%rcx,4),%edx
add    $0x1,%edx
mov    %edx,(%rax,%rcx,4)
movsd  -0x20(%rbp),%xmm0
mov    -0x30(%rbp),%rax
mov    -0x4(%rbp),%ecx
movsd  %xmm0,(%rax,%rcx,8)
movl   $0x0,-0x44(%rbp)
mov    -0x44(%rbp),%eax
cmp    -0x34(%rbp),%eax
jae    11a3 <add_point_to_cluster+0xa3>
mov    -0x18(%rbp),%rax
mov    -0x44(%rbp),%ecx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x40(%rbp),%rax
mov    -0x44(%rbp),%ecx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x44(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x44(%rbp)
jmp    1171 <add_point_to_cluster+0x71>
jmp    1251 <add_point_to_cluster+0x151>
mov    -0x30(%rbp),%rax
mov    -0x4(%rbp),%ecx
movsd  (%rax,%rcx,8),%xmm0
movsd  %xmm0,-0x50(%rbp)
mov    -0x28(%rbp),%rax
mov    -0x4(%rbp),%ecx
mov    (%rax,%rcx,4),%edx
add    $0x1,%edx
mov    %edx,(%rax,%rcx,4)
movsd  -0x20(%rbp),%xmm0
mov    -0x30(%rbp),%rax
mov    -0x4(%rbp),%ecx
addsd  (%rax,%rcx,8),%xmm0
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x30(%rbp),%rax
mov    -0x4(%rbp),%ecx
movsd  (%rax,%rcx,8),%xmm0
movsd  %xmm0,-0x58(%rbp)
movl   $0x0,-0x5c(%rbp)
mov    -0x5c(%rbp),%eax
cmp    -0x34(%rbp),%eax
jae    124c <add_point_to_cluster+0x14c>
movsd  -0x50(%rbp),%xmm0
mov    -0x40(%rbp),%rax
mov    -0x5c(%rbp),%ecx
movsd  (%rax,%rcx,8),%xmm2
movsd  -0x20(%rbp),%xmm1
mov    -0x18(%rbp),%rax
mov    -0x5c(%rbp),%ecx
mulsd  (%rax,%rcx,8),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
divsd  -0x58(%rbp),%xmm0
mov    -0x40(%rbp),%rax
mov    -0x5c(%rbp),%ecx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x5c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x5c(%rbp)
jmp    11f7 <add_point_to_cluster+0xf7>
jmp    1251 <add_point_to_cluster+0x151>
pop    %rbp
ret

x86 assembly (clang, -O2):
<add_point_to_cluster>:
push   %r14
push   %rbx
mov    %r9d,%r10d
imul   %edi,%r10d
lea    (%rsi,%r10,8),%r11
mov    %edi,%eax
mov    (%rcx,%rax,4),%edi
test   %edi,%edi
je     11ff <add_point_to_cluster+0xff>
movsd  (%r8,%rax,8),%xmm1
add    $0x1,%edi
mov    %edi,(%rcx,%rax,4)
movapd %xmm1,%xmm2
addsd  %xmm0,%xmm2
movsd  %xmm2,(%r8,%rax,8)
test   %r9d,%r9d
je     1488 <add_point_to_cluster+0x388>
mov    %r9d,%r14d
cmp    $0x1,%r9d
je     1165 <add_point_to_cluster+0x65>
lea    (%rdx,%r14,8),%rax
cmp    %rax,%r11
jae    12bc <add_point_to_cluster+0x1bc>
lea    (%r14,%r10,1),%rax
lea    (%rsi,%rax,8),%rax
cmp    %rdx,%rax
jbe    12bc <add_point_to_cluster+0x1bc>
xor    %edi,%edi
mov    %rdi,%rax
not    %rax
test   $0x1,%r14b
je     1198 <add_point_to_cluster+0x98>
movsd  (%rdx,%rdi,8),%xmm3
mulsd  %xmm0,%xmm3
movsd  (%r11,%rdi,8),%xmm4
mulsd  %xmm1,%xmm4
addsd  %xmm3,%xmm4
divsd  %xmm2,%xmm4
movsd  %xmm4,(%r11,%rdi,8)
or     $0x1,%rdi
add    %r14,%rax
je     1488 <add_point_to_cluster+0x388>
lea    (%rsi,%r10,8),%rax
add    $0x8,%rax
nopl   0x0(%rax)
movsd  (%rdx,%rdi,8),%xmm3
mulsd  %xmm0,%xmm3
movsd  -0x8(%rax,%rdi,8),%xmm4
mulsd  %xmm1,%xmm4
addsd  %xmm3,%xmm4
divsd  %xmm2,%xmm4
movsd  %xmm4,-0x8(%rax,%rdi,8)
movsd  0x8(%rdx,%rdi,8),%xmm3
mulsd  %xmm0,%xmm3
movsd  (%rax,%rdi,8),%xmm4
mulsd  %xmm1,%xmm4
addsd  %xmm3,%xmm4
divsd  %xmm2,%xmm4
movsd  %xmm4,(%rax,%rdi,8)
add    $0x2,%rdi
cmp    %rdi,%r14
jne    11b0 <add_point_to_cluster+0xb0>
jmp    1488 <add_point_to_cluster+0x388>
movl   $0x1,(%rcx,%rax,4)
movsd  %xmm0,(%r8,%rax,8)
test   %r9d,%r9d
je     1488 <add_point_to_cluster+0x388>
mov    %r9d,%r14d
cmp    $0x4,%r9d
jb     123c <add_point_to_cluster+0x13c>
lea    (%rdx,%r14,8),%rax
cmp    %rax,%r11
jae    1393 <add_point_to_cluster+0x293>
lea    (%r14,%r10,1),%rax
lea    (%rsi,%rax,8),%rax
cmp    %rdx,%rax
jbe    1393 <add_point_to_cluster+0x293>
xor    %edi,%edi
mov    %rdi,%rax
not    %rax
add    %r14,%rax
mov    %r14,%rcx
and    $0x3,%rcx
je     1265 <add_point_to_cluster+0x165>
movsd  (%rdx,%rdi,8),%xmm0
movsd  %xmm0,(%r11,%rdi,8)
add    $0x1,%rdi
add    $0xffffffffffffffff,%rcx
jne    1250 <add_point_to_cluster+0x150>
cmp    $0x3,%rax
jb     1488 <add_point_to_cluster+0x388>
lea    (%rsi,%r10,8),%rax
add    $0x18,%rax
nopw   0x0(%rax,%rax,1)
movsd  (%rdx,%rdi,8),%xmm0
movsd  %xmm0,-0x18(%rax,%rdi,8)
movsd  0x8(%rdx,%rdi,8),%xmm0
movsd  %xmm0,-0x10(%rax,%rdi,8)
movsd  0x10(%rdx,%rdi,8),%xmm0
movsd  %xmm0,-0x8(%rax,%rdi,8)
movsd  0x18(%rdx,%rdi,8),%xmm0
movsd  %xmm0,(%rax,%rdi,8)
add    $0x4,%rdi
cmp    %rdi,%r14
jne    1280 <add_point_to_cluster+0x180>
jmp    1488 <add_point_to_cluster+0x388>
mov    %r14d,%edi
and    $0xfffffffe,%edi
movapd %xmm0,%xmm5
unpcklpd %xmm0,%xmm5
movapd %xmm1,%xmm3
unpcklpd %xmm1,%xmm3
movapd %xmm2,%xmm8
unpcklpd %xmm2,%xmm8
lea    -0x2(%rdi),%rax
mov    %rax,%r8
shr    %r8
add    $0x1,%r8
test   %rax,%rax
je     13bc <add_point_to_cluster+0x2bc>
mov    %r8,%rbx
and    $0xfffffffffffffffe,%rbx
lea    (%rsi,%r10,8),%rcx
add    $0x10,%rcx
xor    %eax,%eax
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
movupd (%rdx,%rax,8),%xmm6
mulpd  %xmm5,%xmm6
movupd -0x10(%rcx,%rax,8),%xmm7
movupd (%rcx,%rax,8),%xmm4
mulpd  %xmm3,%xmm7
addpd  %xmm6,%xmm7
divpd  %xmm8,%xmm7
movupd %xmm7,-0x10(%rcx,%rax,8)
movupd 0x10(%rdx,%rax,8),%xmm6
mulpd  %xmm5,%xmm6
mulpd  %xmm3,%xmm4
addpd  %xmm6,%xmm4
divpd  %xmm8,%xmm4
movupd %xmm4,(%rcx,%rax,8)
add    $0x4,%rax
add    $0xfffffffffffffffe,%rbx
jne    1310 <add_point_to_cluster+0x210>
test   $0x1,%r8b
je     1385 <add_point_to_cluster+0x285>
movupd (%r11,%rax,8),%xmm4
movupd (%rdx,%rax,8),%xmm6
mulpd  %xmm5,%xmm6
mulpd  %xmm4,%xmm3
addpd  %xmm6,%xmm3
divpd  %xmm8,%xmm3
movupd %xmm3,(%r11,%rax,8)
cmp    %r14,%rdi
je     1488 <add_point_to_cluster+0x388>
jmp    1167 <add_point_to_cluster+0x67>
mov    %r14d,%edi
and    $0xfffffffc,%edi
lea    -0x4(%rdi),%rcx
mov    %rcx,%rax
shr    $0x2,%rax
add    $0x1,%rax
mov    %eax,%r8d
and    $0x3,%r8d
cmp    $0xc,%rcx
jae    13c6 <add_point_to_cluster+0x2c6>
xor    %ecx,%ecx
jmp    143c <add_point_to_cluster+0x33c>
xor    %eax,%eax
test   $0x1,%r8b
jne    1363 <add_point_to_cluster+0x263>
jmp    1385 <add_point_to_cluster+0x285>
and    $0xfffffffffffffffc,%rax
lea    (%rsi,%r10,8),%rbx
add    $0x70,%rbx
xor    %ecx,%ecx
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
movups (%rdx,%rcx,8),%xmm0
movups 0x10(%rdx,%rcx,8),%xmm1
movups %xmm0,-0x70(%rbx,%rcx,8)
movups %xmm1,-0x60(%rbx,%rcx,8)
movups 0x20(%rdx,%rcx,8),%xmm0
movups 0x30(%rdx,%rcx,8),%xmm1
movups %xmm0,-0x50(%rbx,%rcx,8)
movups %xmm1,-0x40(%rbx,%rcx,8)
movups 0x40(%rdx,%rcx,8),%xmm0
movups 0x50(%rdx,%rcx,8),%xmm1
movups %xmm0,-0x30(%rbx,%rcx,8)
movups %xmm1,-0x20(%rbx,%rcx,8)
movupd 0x60(%rdx,%rcx,8),%xmm0
movupd 0x70(%rdx,%rcx,8),%xmm1
movupd %xmm0,-0x10(%rbx,%rcx,8)
movupd %xmm1,(%rbx,%rcx,8)
add    $0x10,%rcx
add    $0xfffffffffffffffc,%rax
jne    13e0 <add_point_to_cluster+0x2e0>
test   %r8,%r8
je     147f <add_point_to_cluster+0x37f>
lea    (%rcx,%r10,1),%rax
lea    (%rsi,%rax,8),%rax
add    $0x10,%rax
lea    (%rdx,%rcx,8),%rcx
add    $0x10,%rcx
shl    $0x5,%r8
xor    %ebx,%ebx
nopl   0x0(%rax,%rax,1)
movupd -0x10(%rcx,%rbx,1),%xmm0
movupd (%rcx,%rbx,1),%xmm1
movupd %xmm0,-0x10(%rax,%rbx,1)
movupd %xmm1,(%rax,%rbx,1)
add    $0x20,%rbx
cmp    %rbx,%r8
jne    1460 <add_point_to_cluster+0x360>
cmp    %r14,%rdi
jne    123e <add_point_to_cluster+0x13e>
pop    %rbx
pop    %r14
ret

LLVM IR (-O0):
define void @add_point_to_cluster(i32 %0, double* %1, double* %2, double %3, i32* %4, double* %5, i32 %6) {
%8 = alloca i32
%9 = alloca double*
%10 = alloca double*
%11 = alloca double
%12 = alloca i32*
%13 = alloca double*
%14 = alloca i32
%15 = alloca double*
%16 = alloca i32
%17 = alloca double
%18 = alloca double
%19 = alloca i32
store i32 %0, i32* %8
store double* %1, double** %9
store double* %2, double** %10
store double %3, double* %11
store i32* %4, i32** %12
store double* %5, double** %13
store i32 %6, i32* %14
%20 = load double*, double** %9
%21 = load i32, i32* %8
%22 = load i32, i32* %14
%23 = mul i32 %21, %22
%24 = zext i32 %23 to i64
%25 = getelementptr inbounds double, double* %20, i64 %24
store double* %25, double** %15
%26 = load i32*, i32** %12
%27 = load i32, i32* %8
%28 = zext i32 %27 to i64
%29 = getelementptr inbounds i32, i32* %26, i64 %28
%30 = load i32, i32* %29
%31 = icmp eq i32 %30, 0
br i1 %31, label %32, label %62
32: ; preds = %7
%33 = load i32*, i32** %12
%34 = load i32, i32* %8
%35 = zext i32 %34 to i64
%36 = getelementptr inbounds i32, i32* %33, i64 %35
%37 = load i32, i32* %36
%38 = add i32 %37, 1
store i32 %38, i32* %36
%39 = load double, double* %11
%40 = load double*, double** %13
%41 = load i32, i32* %8
%42 = zext i32 %41 to i64
%43 = getelementptr inbounds double, double* %40, i64 %42
store double %39, double* %43
store i32 0, i32* %16
br label %44
44: ; preds = %58, %32
%45 = load i32, i32* %16
%46 = load i32, i32* %14
%47 = icmp ult i32 %45, %46
br i1 %47, label %48, label %61
48: ; preds = %44
%49 = load double*, double** %10
%50 = load i32, i32* %16
%51 = zext i32 %50 to i64
%52 = getelementptr inbounds double, double* %49, i64 %51
%53 = load double, double* %52
%54 = load double*, double** %15
%55 = load i32, i32* %16
%56 = zext i32 %55 to i64
%57 = getelementptr inbounds double, double* %54, i64 %56
store double %53, double* %57
br label %58
58: ; preds = %48
%59 = load i32, i32* %16
%60 = add i32 %59, 1
store i32 %60, i32* %16
br label %44
61: ; preds = %44
br label %115
62: ; preds = %7
%63 = load double*, double** %13
%64 = load i32, i32* %8
%65 = zext i32 %64 to i64
%66 = getelementptr inbounds double, double* %63, i64 %65
%67 = load double, double* %66
store double %67, double* %17
%68 = load i32*, i32** %12
%69 = load i32, i32* %8
%70 = zext i32 %69 to i64
%71 = getelementptr inbounds i32, i32* %68, i64 %70
%72 = load i32, i32* %71
%73 = add i32 %72, 1
store i32 %73, i32* %71
%74 = load double, double* %11
%75 = load double*, double** %13
%76 = load i32, i32* %8
%77 = zext i32 %76 to i64
%78 = getelementptr inbounds double, double* %75, i64 %77
%79 = load double, double* %78
%80 = fadd double %79, %74
store double %80, double* %78
%81 = load double*, double** %13
%82 = load i32, i32* %8
%83 = zext i32 %82 to i64
%84 = getelementptr inbounds double, double* %81, i64 %83
%85 = load double, double* %84
store double %85, double* %18
store i32 0, i32* %19
br label %86
86: ; preds = %111, %62
%87 = load i32, i32* %19
%88 = load i32, i32* %14
%89 = icmp ult i32 %87, %88
br i1 %89, label %90, label %114
90: ; preds = %86
%91 = load double, double* %17
%92 = load double*, double** %15
%93 = load i32, i32* %19
%94 = zext i32 %93 to i64
%95 = getelementptr inbounds double, double* %92, i64 %94
%96 = load double, double* %95
%97 = load double, double* %11
%98 = load double*, double** %10
%99 = load i32, i32* %19
%100 = zext i32 %99 to i64
%101 = getelementptr inbounds double, double* %98, i64 %100
%102 = load double, double* %101
%103 = fmul double %97, %102
%104 = call double @llvm.fmuladd.f64(double %91, double %96, double %103)
%105 = load double, double* %18
%106 = fdiv double %104, %105
%107 = load double*, double** %15
%108 = load i32, i32* %19
%109 = zext i32 %108 to i64
%110 = getelementptr inbounds double, double* %107, i64 %109
store double %106, double* %110
br label %111
111: ; preds = %90
%112 = load i32, i32* %19
%113 = add i32 %112, 1
store i32 %113, i32* %19
br label %86
114: ; preds = %86
br label %115
115: ; preds = %114, %61
ret void
}

LLVM IR (-O2):
define void @add_point_to_cluster(i32 %0, double* nocapture %1, double* nocapture %2, double %3, i32* nocapture %4, double* nocapture %5, i32 %6) {
%8 = mul i32 %6, %0
%9 = zext i32 %8 to i64
%10 = getelementptr double, double* %1, i64 %9
%11 = zext i32 %0 to i64
%12 = getelementptr inbounds i32, i32* %4, i64 %11
%13 = load i32, i32* %12
%14 = icmp eq i32 %13, 0
br i1 %14, label %15, label %144
15: ; preds = %7
store i32 1, i32* %12
%16 = getelementptr inbounds double, double* %5, i64 %11
store double %3, double* %16
%17 = icmp eq i32 %6, 0
br i1 %17, label %255, label %18
18: ; preds = %15
%19 = zext i32 %6 to i64
%20 = icmp ult i32 %6, 4
br i1 %20, label %107, label %21
21: ; preds = %18
%22 = add nuw nsw i64 %19, %9
%23 = getelementptr double, double* %1, i64 %22
%24 = getelementptr double, double* %2, i64 %19
%25 = icmp ult double* %10, %24
%26 = icmp ugt double* %23, %2
%27 = and i1 %25, %26
br i1 %27, label %107, label %28
28: ; preds = %21
%29 = and i64 %19, 4294967292
%30 = add nsw i64 %29, -4
%31 = lshr exact i64 %30, 2
%32 = add nuw nsw i64 %31, 1
%33 = and i64 %32, 3
%34 = icmp ult i64 %30, 12
br i1 %34, label %86, label %35
35: ; preds = %28
%36 = and i64 %32, 9223372036854775804
br label %37
37: ; preds = %37, %35
%38 = phi i64 [ 0, %35 ], [ %83, %37 ]
%39 = phi i64 [ 0, %35 ], [ %84, %37 ]
%40 = getelementptr inbounds double, double* %2, i64 %38
%41 = bitcast double* %40 to <2 x double>*
%42 = load <2 x double>, <2 x double>* %41
%43 = getelementptr inbounds double, double* %40, i64 2
%44 = bitcast double* %43 to <2 x double>*
%45 = load <2 x double>, <2 x double>* %44
%46 = getelementptr inbounds double, double* %10, i64 %38
%47 = bitcast double* %46 to <2 x double>*
store <2 x double> %42, <2 x double>* %47
%48 = getelementptr inbounds double, double* %46, i64 2
%49 = bitcast double* %48 to <2 x double>*
store <2 x double> %45, <2 x double>* %49
%50 = or i64 %38, 4
%51 = getelementptr inbounds double, double* %2, i64 %50
%52 = bitcast double* %51 to <2 x double>*
%53 = load <2 x double>, <2 x double>* %52
%54 = getelementptr inbounds double, double* %51, i64 2
%55 = bitcast double* %54 to <2 x double>*
%56 = load <2 x double>, <2 x double>* %55
%57 = getelementptr inbounds double, double* %10, i64 %50
%58 = bitcast double* %57 to <2 x double>*
store <2 x double> %53, <2 x double>* %58
%59 = getelementptr inbounds double, double* %57, i64 2
%60 = bitcast double* %59 to <2 x double>*
store <2 x double> %56, <2 x double>* %60
%61 = or i64 %38, 8
%62 = getelementptr inbounds double, double* %2, i64 %61
%63 = bitcast double* %62 to <2 x double>*
%64 = load <2 x double>, <2 x double>* %63
%65 = getelementptr inbounds double, double* %62, i64 2
%66 = bitcast double* %65 to <2 x double>*
%67 = load <2 x double>, <2 x double>* %66
%68 = getelementptr inbounds double, double* %10, i64 %61
%69 = bitcast double* %68 to <2 x double>*
store <2 x double> %64, <2 x double>* %69
%70 = getelementptr inbounds double, double* %68, i64 2
%71 = bitcast double* %70 to <2 x double>*
store <2 x double> %67, <2 x double>* %71
%72 = or i64 %38, 12
%73 = getelementptr inbounds double, double* %2, i64 %72
%74 = bitcast double* %73 to <2 x double>*
%75 = load <2 x double>, <2 x double>* %74
%76 = getelementptr inbounds double, double* %73, i64 2
%77 = bitcast double* %76 to <2 x double>*
%78 = load <2 x double>, <2 x double>* %77
%79 = getelementptr inbounds double, double* %10, i64 %72
%80 = bitcast double* %79 to <2 x double>*
store <2 x double> %75, <2 x double>* %80
%81 = getelementptr inbounds double, double* %79, i64 2
%82 = bitcast double* %81 to <2 x double>*
store <2 x double> %78, <2 x double>* %82
%83 = add nuw i64 %38, 16
%84 = add nuw i64 %39, 4
%85 = icmp eq i64 %84, %36
br i1 %85, label %86, label %37
86: ; preds = %37, %28
%87 = phi i64 [ 0, %28 ], [ %83, %37 ]
%88 = icmp eq i64 %33, 0
br i1 %88, label %105, label %89
89: ; preds = %86, %89
%90 = phi i64 [ %102, %89 ], [ %87, %86 ]
%91 = phi i64 [ %103, %89 ], [ 0, %86 ]
%92 = getelementptr inbounds double, double* %2, i64 %90
%93 = bitcast double* %92 to <2 x double>*
%94 = load <2 x double>, <2 x double>* %93
%95 = getelementptr inbounds double, double* %92, i64 2
%96 = bitcast double* %95 to <2 x double>*
%97 = load <2 x double>, <2 x double>* %96
%98 = getelementptr inbounds double, double* %10, i64 %90
%99 = bitcast double* %98 to <2 x double>*
store <2 x double> %94, <2 x double>* %99
%100 = getelementptr inbounds double, double* %98, i64 2
%101 = bitcast double* %100 to <2 x double>*
store <2 x double> %97, <2 x double>* %101
%102 = add nuw i64 %90, 4
%103 = add i64 %91, 1
%104 = icmp eq i64 %103, %33
br i1 %104, label %105, label %89
105: ; preds = %89, %86
%106 = icmp eq i64 %29, %19
br i1 %106, label %255, label %107
107: ; preds = %21, %18, %105
%108 = phi i64 [ 0, %21 ], [ 0, %18 ], [ %29, %105 ]
%109 = xor i64 %108, -1
%110 = add nsw i64 %109, %19
%111 = and i64 %19, 3
%112 = icmp eq i64 %111, 0
br i1 %112, label %122, label %113
113: ; preds = %107, %113
%114 = phi i64 [ %119, %113 ], [ %108, %107 ]
%115 = phi i64 [ %120, %113 ], [ 0, %107 ]
%116 = getelementptr inbounds double, double* %2, i64 %114
%117 = load double, double* %116
%118 = getelementptr inbounds double, double* %10, i64 %114
store double %117, double* %118
%119 = add nuw nsw i64 %114, 1
%120 = add i64 %115, 1
%121 = icmp eq i64 %120, %111
br i1 %121, label %122, label %113
122: ; preds = %113, %107
%123 = phi i64 [ %108, %107 ], [ %119, %113 ]
%124 = icmp ult i64 %110, 3
br i1 %124, label %255, label %125
125: ; preds = %122, %125
%126 = phi i64 [ %142, %125 ], [ %123, %122 ]
%127 = getelementptr inbounds double, double* %2, i64 %126
%128 = load double, double* %127
%129 = getelementptr inbounds double, double* %10, i64 %126
store double %128, double* %129
%130 = add nuw nsw i64 %126, 1
%131 = getelementptr inbounds double, double* %2, i64 %130
%132 = load double, double* %131
%133 = getelementptr inbounds double, double* %10, i64 %130
store double %132, double* %133
%134 = add nuw nsw i64 %126, 2
%135 = getelementptr inbounds double, double* %2, i64 %134
%136 = load double, double* %135
%137 = getelementptr inbounds double, double* %10, i64 %134
store double %136, double* %137
%138 = add nuw nsw i64 %126, 3
%139 = getelementptr inbounds double, double* %2, i64 %138
%140 = load double, double* %139
%141 = getelementptr inbounds double, double* %10, i64 %138
store double %140, double* %141
%142 = add nuw nsw i64 %126, 4
%143 = icmp eq i64 %142, %19
br i1 %143, label %255, label %125
144: ; preds = %7
%145 = getelementptr inbounds double, double* %5, i64 %11
%146 = load double, double* %145
%147 = add i32 %13, 1
store i32 %147, i32* %12
%148 = fadd double %146, %3
store double %148, double* %145
%149 = icmp eq i32 %6, 0
br i1 %149, label %255, label %150
150: ; preds = %144
%151 = zext i32 %6 to i64
%152 = icmp eq i32 %6, 1
br i1 %152, label %218, label %153
153: ; preds = %150
%154 = add nuw nsw i64 %151, %9
%155 = getelementptr double, double* %1, i64 %154
%156 = getelementptr double, double* %2, i64 %151
%157 = icmp ult double* %10, %156
%158 = icmp ugt double* %155, %2
%159 = and i1 %157, %158
br i1 %159, label %218, label %160
160: ; preds = %153
%161 = and i64 %151, 4294967294
%162 = insertelement <2 x double> poison, double %3, i64 0
%163 = shufflevector <2 x double> %162, <2 x double> poison, <2 x i32> zeroinitializer
%164 = insertelement <2 x double> poison, double %146, i64 0
%165 = shufflevector <2 x double> %164, <2 x double> poison, <2 x i32> zeroinitializer
%166 = insertelement <2 x double> poison, double %148, i64 0
%167 = shufflevector <2 x double> %166, <2 x double> poison, <2 x i32> zeroinitializer
%168 = add nsw i64 %161, -2
%169 = lshr exact i64 %168, 1
%170 = add nuw i64 %169, 1
%171 = and i64 %170, 1
%172 = icmp eq i64 %168, 0
br i1 %172, label %202, label %173
173: ; preds = %160
%174 = and i64 %170, -2
br label %175
175: ; preds = %175, %173
%176 = phi i64 [ 0, %173 ], [ %199, %175 ]
%177 = phi i64 [ 0, %173 ], [ %200, %175 ]
%178 = getelementptr inbounds double, double* %10, i64 %176
%179 = bitcast double* %178 to <2 x double>*
%180 = load <2 x double>, <2 x double>* %179
%181 = getelementptr inbounds double, double* %2, i64 %176
%182 = bitcast double* %181 to <2 x double>*
%183 = load <2 x double>, <2 x double>* %182
%184 = fmul <2 x double> %183, %163
%185 = call <2 x double> @llvm.fmuladd.v2f64(<2 x double> %165, <2 x double> %180, <2 x double> %184)
%186 = fdiv <2 x double> %185, %167
%187 = bitcast double* %178 to <2 x double>*
store <2 x double> %186, <2 x double>* %187
%188 = or i64 %176, 2
%189 = getelementptr inbounds double, double* %10, i64 %188
%190 = bitcast double* %189 to <2 x double>*
%191 = load <2 x double>, <2 x double>* %190
%192 = getelementptr inbounds double, double* %2, i64 %188
%193 = bitcast double* %192 to <2 x double>*
%194 = load <2 x double>, <2 x double>* %193
%195 = fmul <2 x double> %194, %163
%196 = call <2 x double> @llvm.fmuladd.v2f64(<2 x double> %165, <2 x double> %191, <2 x double> %195)
%197 = fdiv <2 x double> %196, %167
%198 = bitcast double* %189 to <2 x double>*
store <2 x double> %197, <2 x double>* %198
%199 = add nuw i64 %176, 4
%200 = add nuw i64 %177, 2
%201 = icmp eq i64 %200, %174
br i1 %201, label %202, label %175
202: ; preds = %175, %160
%203 = phi i64 [ 0, %160 ], [ %199, %175 ]
%204 = icmp eq i64 %171, 0
br i1 %204, label %216, label %205
205: ; preds = %202
%206 = getelementptr inbounds double, double* %10, i64 %203
%207 = bitcast double* %206 to <2 x double>*
%208 = load <2 x double>, <2 x double>* %207
%209 = getelementptr inbounds double, double* %2, i64 %203
%210 = bitcast double* %209 to <2 x double>*
%211 = load <2 x double>, <2 x double>* %210
%212 = fmul <2 x double> %211, %163
%213 = call <2 x double> @llvm.fmuladd.v2f64(<2 x double> %165, <2 x double> %208, <2 x double> %212)
%214 = fdiv <2 x double> %213, %167
%215 = bitcast double* %206 to <2 x double>*
store <2 x double> %214, <2 x double>* %215
br label %216
216: ; preds = %202, %205
%217 = icmp eq i64 %161, %151
br i1 %217, label %255, label %218
218: ; preds = %153, %150, %216
%219 = phi i64 [ 0, %153 ], [ 0, %150 ], [ %161, %216 ]
%220 = xor i64 %219, -1
%221 = and i64 %151, 1
%222 = icmp eq i64 %221, 0
br i1 %222, label %232, label %223
223: ; preds = %218
%224 = getelementptr inbounds double, double* %10, i64 %219
%225 = load double, double* %224
%226 = getelementptr inbounds double, double* %2, i64 %219
%227 = load double, double* %226
%228 = fmul double %227, %3
%229 = tail call double @llvm.fmuladd.f64(double %146, double %225, double %228)
%230 = fdiv double %229, %148
store double %230, double* %224
%231 = or i64 %219, 1
br label %232
232: ; preds = %223, %218
%233 = phi i64 [ %219, %218 ], [ %231, %223 ]
%234 = sub nsw i64 0, %151
%235 = icmp eq i64 %220, %234
br i1 %235, label %255, label %236
236: ; preds = %232, %236
%237 = phi i64 [ %253, %236 ], [ %233, %232 ]
%238 = getelementptr inbounds double, double* %10, i64 %237
%239 = load double, double* %238
%240 = getelementptr inbounds double, double* %2, i64 %237
%241 = load double, double* %240
%242 = fmul double %241, %3
%243 = tail call double @llvm.fmuladd.f64(double %146, double %239, double %242)
%244 = fdiv double %243, %148
store double %244, double* %238
%245 = add nuw nsw i64 %237, 1
%246 = getelementptr inbounds double, double* %10, i64 %245
%247 = load double, double* %246
%248 = getelementptr inbounds double, double* %2, i64 %245
%249 = load double, double* %248
%250 = fmul double %249, %3
%251 = tail call double @llvm.fmuladd.f64(double %146, double %247, double %250)
%252 = fdiv double %251, %148
store double %252, double* %246
%253 = add nuw nsw i64 %237, 2
%254 = icmp eq i64 %253, %151
br i1 %254, label %255, label %236
255: ; preds = %232, %236, %122, %125, %216, %105, %144, %15
ret void
}