int xx_matrix_decompose(double *matrix, int size, int *permute, int *parity) {
  int ok = 1;
  double stack_storage[5];
  double *storage = ((void *)0);
  if (size > 5) {
    storage = (double *)malloc(sizeof(double) * size);
    if (!storage)
      ok = 0;
  } else {
    storage = stack_storage;
  }
  *parity = 1;
  if (ok) {
    int i, j;
    for (i = 0; i < size; i++) {
      double max_abs_value = 0.0;
      for (j = 0; j < size; j++) {
        double test_abs_value = fabs(matrix[(((i) * (size)) + j)]);
        if (max_abs_value < test_abs_value)
          max_abs_value = test_abs_value;
      }
      if (max_abs_value == 0.0) {
        ok = 0;
        break;
      }
      storage[i] = 1.0 / max_abs_value;
    }
  }
  if (ok) {
    int i, j, k, i_max = 0;
    for (j = 0; j < size; j++) {
      for (i = 0; i < j; i++) {
        double sum = matrix[(((i) * (size)) + j)];
        for (k = 0; k < i; k++) {
          sum =
              sum - matrix[(((i) * (size)) + k)] * matrix[(((k) * (size)) + j)];
        }
        matrix[(((i) * (size)) + j)] = sum;
      }
      {
        double max_product = 0.0;
        for (i = j; i < size; i++) {
          double sum = matrix[(((i) * (size)) + j)];
          for (k = 0; k < j; k++) {
            sum = sum -
                  matrix[(((i) * (size)) + k)] * matrix[(((k) * (size)) + j)];
          }
          matrix[(((i) * (size)) + j)] = sum;
          {
            double test_product = storage[i] * fabs(sum);
            if (max_product <= test_product) {
              max_product = test_product;
              i_max = i;
            }
          }
        }
      }
      if (j != i_max) {
        for (k = 0; k < size; k++) {
          double tmp = matrix[(((i_max) * (size)) + k)];
          matrix[(((i_max) * (size)) + k)] = matrix[(((j) * (size)) + k)];
          matrix[(((j) * (size)) + k)] = tmp;
        }
        *parity = (0 - *parity);
        storage[i_max] = storage[j];
      }
      permute[j] = i_max;
      if (matrix[(((j) * (size)) + j)] == 0.0) {
        ok = 0;
        break;
      }
      if (j != (size - 1)) {
        double tmp = 1.0 / matrix[(((j) * (size)) + j)];
        for (i = j + 1; i < size; i++) {
          matrix[(((i) * (size)) + j)] *= tmp;
        }
      }
    }
  }
  if (storage && (storage != stack_storage))
    free(storage);
  return ok;
}


x86 assembly (clang, -O0):
<xx_matrix_decompose>:
push   %rbp
mov    %rsp,%rbp
sub    $0xb0,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %rcx,-0x20(%rbp)
movl   $0x1,-0x24(%rbp)
movq   $0x0,-0x58(%rbp)
cmpl   $0x5,-0xc(%rbp)
jle    117b <xx_matrix_decompose+0x5b>
movslq -0xc(%rbp),%rdi
shl    $0x3,%rdi
call   1040 <malloc@plt>
mov    %rax,-0x58(%rbp)
cmpq   $0x0,-0x58(%rbp)
jne    1176 <xx_matrix_decompose+0x56>
movl   $0x0,-0x24(%rbp)
jmp    1183 <xx_matrix_decompose+0x63>
lea    -0x50(%rbp),%rax
mov    %rax,-0x58(%rbp)
mov    -0x20(%rbp),%rax
movl   $0x1,(%rax)
cmpl   $0x0,-0x24(%rbp)
je     126d <xx_matrix_decompose+0x14d>
movl   $0x0,-0x5c(%rbp)
mov    -0x5c(%rbp),%eax
cmp    -0xc(%rbp),%eax
jge    1268 <xx_matrix_decompose+0x148>
xorps  %xmm0,%xmm0
movsd  %xmm0,-0x68(%rbp)
movl   $0x0,-0x60(%rbp)
mov    -0x60(%rbp),%eax
cmp    -0xc(%rbp),%eax
jge    121c <xx_matrix_decompose+0xfc>
mov    -0x8(%rbp),%rax
mov    -0x5c(%rbp),%ecx
imul   -0xc(%rbp),%ecx
add    -0x60(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
movaps 0xe2e(%rip),%xmm1
pand   %xmm1,%xmm0
movsd  %xmm0,-0x70(%rbp)
movsd  -0x68(%rbp),%xmm1
movsd  -0x70(%rbp),%xmm0
ucomisd %xmm1,%xmm0
jbe    1209 <xx_matrix_decompose+0xe9>
movsd  -0x70(%rbp),%xmm0
movsd  %xmm0,-0x68(%rbp)
jmp    120e <xx_matrix_decompose+0xee>
mov    -0x60(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x60(%rbp)
jmp    11b9 <xx_matrix_decompose+0x99>
movsd  -0x68(%rbp),%xmm0
xorps  %xmm1,%xmm1
ucomisd %xmm1,%xmm0
jne    1240 <xx_matrix_decompose+0x120>
jp     1240 <xx_matrix_decompose+0x120>
movl   $0x0,-0x24(%rbp)
jmp    1268 <xx_matrix_decompose+0x148>
movsd  0xdb8(%rip),%xmm0
divsd  -0x68(%rbp),%xmm0
mov    -0x58(%rbp),%rax
movslq -0x5c(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x5c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x5c(%rbp)
jmp    119e <xx_matrix_decompose+0x7e>
jmp    126d <xx_matrix_decompose+0x14d>
cmpl   $0x0,-0x24(%rbp)
je     1648 <xx_matrix_decompose+0x528>
movl   $0x0,-0x80(%rbp)
movl   $0x0,-0x78(%rbp)
mov    -0x78(%rbp),%eax
cmp    -0xc(%rbp),%eax
jge    1643 <xx_matrix_decompose+0x523>
movl   $0x0,-0x74(%rbp)
mov    -0x74(%rbp),%eax
cmp    -0x78(%rbp),%eax
jge    136a <xx_matrix_decompose+0x24a>
mov    -0x8(%rbp),%rax
mov    -0x74(%rbp),%ecx
imul   -0xc(%rbp),%ecx
add    -0x78(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
movsd  %xmm0,-0x88(%rbp)
ff
movl   $0x0,-0x7c(%rbp)
mov    -0x7c(%rbp),%eax
cmp    -0x74(%rbp),%eax
jge    133e <xx_matrix_decompose+0x21e>
movsd  -0x88(%rbp),%xmm1
ff
mov    -0x8(%rbp),%rax
mov    -0x74(%rbp),%ecx
imul   -0xc(%rbp),%ecx
add    -0x7c(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x8(%rbp),%rax
mov    -0x7c(%rbp),%ecx
imul   -0xc(%rbp),%ecx
add    -0x78(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm2
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x88(%rbp)
ff
mov    -0x7c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x7c(%rbp)
jmp    12c9 <xx_matrix_decompose+0x1a9>
movsd  -0x88(%rbp),%xmm0
ff
mov    -0x8(%rbp),%rax
mov    -0x74(%rbp),%ecx
imul   -0xc(%rbp),%ecx
add    -0x78(%rbp),%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x74(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x74(%rbp)
jmp    1298 <xx_matrix_decompose+0x178>
xorps  %xmm0,%xmm0
movsd  %xmm0,-0x90(%rbp)
ff
mov    -0x78(%rbp),%eax
mov    %eax,-0x74(%rbp)
mov    -0x74(%rbp),%eax
cmp    -0xc(%rbp),%eax
jge    14ae <xx_matrix_decompose+0x38e>
mov    -0x8(%rbp),%rax
mov    -0x74(%rbp),%ecx
imul   -0xc(%rbp),%ecx
add    -0x78(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
movsd  %xmm0,-0x98(%rbp)
ff
movl   $0x0,-0x7c(%rbp)
mov    -0x7c(%rbp),%eax
cmp    -0x78(%rbp),%eax
jge    1421 <xx_matrix_decompose+0x301>
movsd  -0x98(%rbp),%xmm1
ff
mov    -0x8(%rbp),%rax
mov    -0x74(%rbp),%ecx
imul   -0xc(%rbp),%ecx
add    -0x7c(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x8(%rbp),%rax
mov    -0x7c(%rbp),%ecx
imul   -0xc(%rbp),%ecx
add    -0x78(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm2
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x98(%rbp)
ff
mov    -0x7c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x7c(%rbp)
jmp    13ac <xx_matrix_decompose+0x28c>
movsd  -0x98(%rbp),%xmm0
ff
mov    -0x8(%rbp),%rax
mov    -0x74(%rbp),%ecx
imul   -0xc(%rbp),%ecx
add    -0x78(%rbp),%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x58(%rbp),%rax
movslq -0x74(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
movsd  -0x98(%rbp),%xmm1
ff
movaps 0xbb5(%rip),%xmm2
pand   %xmm2,%xmm1
mulsd  %xmm1,%xmm0
movsd  %xmm0,-0xa0(%rbp)
ff
movsd  -0x90(%rbp),%xmm1
ff
movsd  -0xa0(%rbp),%xmm0
ff
ucomisd %xmm1,%xmm0
jb     149b <xx_matrix_decompose+0x37b>
movsd  -0xa0(%rbp),%xmm0
ff
movsd  %xmm0,-0x90(%rbp)
ff
mov    -0x74(%rbp),%eax
mov    %eax,-0x80(%rbp)
jmp    14a0 <xx_matrix_decompose+0x380>
mov    -0x74(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x74(%rbp)
jmp    137b <xx_matrix_decompose+0x25b>
mov    -0x78(%rbp),%eax
cmp    -0x80(%rbp),%eax
je     156b <xx_matrix_decompose+0x44b>
movl   $0x0,-0x7c(%rbp)
mov    -0x7c(%rbp),%eax
cmp    -0xc(%rbp),%eax
jge    1543 <xx_matrix_decompose+0x423>
mov    -0x8(%rbp),%rax
mov    -0x80(%rbp),%ecx
imul   -0xc(%rbp),%ecx
add    -0x7c(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
movsd  %xmm0,-0xa8(%rbp)
ff
mov    -0x8(%rbp),%rax
mov    -0x78(%rbp),%ecx
imul   -0xc(%rbp),%ecx
add    -0x7c(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x8(%rbp),%rax
mov    -0x80(%rbp),%ecx
imul   -0xc(%rbp),%ecx
add    -0x7c(%rbp),%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
movsd  -0xa8(%rbp),%xmm0
ff
mov    -0x8(%rbp),%rax
mov    -0x78(%rbp),%ecx
imul   -0xc(%rbp),%ecx
add    -0x7c(%rbp),%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x7c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x7c(%rbp)
jmp    14c1 <xx_matrix_decompose+0x3a1>
mov    -0x20(%rbp),%rax
xor    %ecx,%ecx
sub    (%rax),%ecx
mov    -0x20(%rbp),%rax
mov    %ecx,(%rax)
mov    -0x58(%rbp),%rax
movslq -0x78(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x58(%rbp),%rax
movslq -0x80(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x80(%rbp),%edx
mov    -0x18(%rbp),%rax
movslq -0x78(%rbp),%rcx
mov    %edx,(%rax,%rcx,4)
mov    -0x8(%rbp),%rax
mov    -0x78(%rbp),%ecx
imul   -0xc(%rbp),%ecx
add    -0x78(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
xorps  %xmm1,%xmm1
ucomisd %xmm1,%xmm0
jne    15ae <xx_matrix_decompose+0x48e>
jp     15ae <xx_matrix_decompose+0x48e>
movl   $0x0,-0x24(%rbp)
jmp    1643 <xx_matrix_decompose+0x523>
mov    -0x78(%rbp),%eax
mov    -0xc(%rbp),%ecx
sub    $0x1,%ecx
cmp    %ecx,%eax
je     1630 <xx_matrix_decompose+0x510>
mov    -0x8(%rbp),%rax
mov    -0x78(%rbp),%ecx
imul   -0xc(%rbp),%ecx
add    -0x78(%rbp),%ecx
movslq %ecx,%rcx
movsd  0xa28(%rip),%xmm0
divsd  (%rax,%rcx,8),%xmm0
movsd  %xmm0,-0xb0(%rbp)
ff
mov    -0x78(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x74(%rbp)
mov    -0x74(%rbp),%eax
cmp    -0xc(%rbp),%eax
jge    162b <xx_matrix_decompose+0x50b>
movsd  -0xb0(%rbp),%xmm0
ff
mov    -0x8(%rbp),%rax
mov    -0x74(%rbp),%ecx
imul   -0xc(%rbp),%ecx
add    -0x78(%rbp),%ecx
movslq %ecx,%rcx
mulsd  (%rax,%rcx,8),%xmm0
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x74(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x74(%rbp)
jmp    15ee <xx_matrix_decompose+0x4ce>
jmp    1630 <xx_matrix_decompose+0x510>
jmp    1635 <xx_matrix_decompose+0x515>
mov    -0x78(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x78(%rbp)
jmp    1285 <xx_matrix_decompose+0x165>
jmp    1648 <xx_matrix_decompose+0x528>
cmpq   $0x0,-0x58(%rbp)
je     166d <xx_matrix_decompose+0x54d>
mov    -0x58(%rbp),%rax
lea    -0x50(%rbp),%rcx
cmp    %rcx,%rax
je     166d <xx_matrix_decompose+0x54d>
mov    -0x58(%rbp),%rdi
call   1030 <free@plt>
mov    -0x24(%rbp),%eax
add    $0xb0,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<xx_matrix_decompose>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0xb8,%rsp
mov    %rcx,%r14
mov    %rdx,0x88(%rsp)
mov    %esi,%r15d
mov    %rdi,%r13
mov    %esi,%edi
cmp    $0x6,%esi
mov    %rdi,0x8(%rsp)
jl     1172 <xx_matrix_decompose+0x52>
lea    0x0(,%rdi,8),%rdi
call   1040 <malloc@plt>
movl   $0x1,(%r14)
test   %rax,%rax
je     177d <xx_matrix_decompose+0x65d>
mov    0x8(%rsp),%rdi
jmp    118a <xx_matrix_decompose+0x6a>
movl   $0x1,(%r14)
test   %r15d,%r15d
jle    1786 <xx_matrix_decompose+0x666>
lea    0x90(%rsp),%rax
mov    %edi,%ecx
and    $0xfffffffe,%ecx
lea    0x8(%r13),%rdx
lea    0x0(,%rdi,8),%rsi
xor    %ebx,%ebx
xorpd  %xmm2,%xmm2
movsd  0xe67(%rip),%xmm0
movapd 0xe4f(%rip),%xmm1
movapd 0xe47(%rip),%xmm3
nopl   0x0(%rax)
cmp    $0x1,%r15d
jne    11d0 <xx_matrix_decompose+0xb0>
xor    %ebp,%ebp
xorpd  %xmm4,%xmm4
jmp    1208 <xx_matrix_decompose+0xe8>
xchg   %ax,%ax
xorpd  %xmm5,%xmm5
xor    %ebp,%ebp
cs nopw 0x0(%rax,%rax,1)
movsd  -0x8(%rdx,%rbp,8),%xmm6
movsd  (%rdx,%rbp,8),%xmm4
andpd  %xmm3,%xmm6
maxsd  %xmm5,%xmm6
andpd  %xmm3,%xmm4
maxsd  %xmm6,%xmm4
add    $0x2,%rbp
movapd %xmm4,%xmm5
cmp    %rbp,%rcx
jne    11e0 <xx_matrix_decompose+0xc0>
test   $0x1,%dil
je     1232 <xx_matrix_decompose+0x112>
mov    %rbx,%rdi
imul   0x8(%rsp),%rdi
add    %rdi,%rbp
mov    0x8(%rsp),%rdi
movsd  0x0(%r13,%rbp,8),%xmm5
andpd  %xmm1,%xmm5
maxsd  %xmm4,%xmm5
movapd %xmm5,%xmm4
ucomisd %xmm2,%xmm4
jne    123e <xx_matrix_decompose+0x11e>
jnp    177d <xx_matrix_decompose+0x65d>
movapd %xmm0,%xmm5
divsd  %xmm4,%xmm5
movsd  %xmm5,(%rax,%rbx,8)
add    $0x1,%rbx
add    %rsi,%rdx
cmp    %rdi,%rbx
jne    11c0 <xx_matrix_decompose+0xa0>
mov    %r14,0x68(%rsp)
mov    %rax,0x18(%rsp)
lea    -0x1(%r15),%eax
mov    %rax,0x70(%rsp)
movslq %r15d,%r11
lea    0x0(,%rdi,8),%r14
add    %r13,%r14
mov    %edi,%eax
and    $0xfffffffc,%eax
mov    %rax,0x58(%rsp)
add    $0xfffffffffffffffc,%rax
mov    %rax,0x50(%rsp)
mov    %rax,%rcx
shr    $0x2,%rcx
add    $0x1,%rcx
mov    %rcx,%rax
mov    %rcx,0x48(%rsp)
and    $0xfffffffffffffffe,%rcx
mov    %rcx,0x40(%rsp)
neg    %rdi
mov    %rdi,0x60(%rsp)
lea    0x8(%r13),%rax
mov    %rax,0x20(%rsp)
lea    0x0(,%r11,8),%rax
lea    0x0(%r13,%r11,8),%r10
lea    (%r11,%r11,1),%r9
lea    0x30(%r13),%rcx
mov    %rcx,0x38(%rsp)
xor    %r12d,%r12d
mov    $0x1,%ecx
mov    %rcx,0x10(%rsp)
xorpd  %xmm2,%xmm2
mov    %r11,0x28(%rsp)
xor    %r8d,%r8d
mov    %r15,0x80(%rsp)
mov    %r14,0x78(%rsp)
jmp    1326 <xx_matrix_decompose+0x206>
xchg   %ax,%ax
add    $0x1,%r12
mov    %r12,%rcx
mov    0x10(%rsp),%rbx
add    $0x1,%rbx
mov    %rbx,0x10(%rsp)
add    %r11,0x28(%rsp)
mov    %rcx,%r12
cmp    %rdi,%rcx
je     1791 <xx_matrix_decompose+0x671>
test   %r12,%r12
je     13f0 <xx_matrix_decompose+0x2d0>
mov    0x20(%rsp),%rcx
xor    %edi,%edi
jmp    1357 <xx_matrix_decompose+0x237>
nopl   0x0(%rax,%rax,1)
movsd  %xmm3,0x0(%r13,%r14,8)
add    $0x1,%rdi
add    %rax,%rcx
cmp    %r12,%rdi
je     13f0 <xx_matrix_decompose+0x2d0>
mov    %rdi,%rdx
imul   %r11,%rdx
lea    (%rdx,%r12,1),%r14
movsd  0x0(%r13,%r14,8),%xmm3
test   %rdi,%rdi
je     1340 <xx_matrix_decompose+0x220>
cmp    $0x1,%rdi
jne    1380 <xx_matrix_decompose+0x260>
xor    %esi,%esi
jmp    13bc <xx_matrix_decompose+0x29c>
nopl   0x0(%rax,%rax,1)
mov    %rdi,%rbp
and    $0xfffffffffffffffe,%rbp
mov    %r12,%rbx
xor    %esi,%esi
nopl   0x0(%rax)
movsd  -0x8(%rcx,%rsi,8),%xmm4
mulsd  0x0(%r13,%rbx,8),%xmm4
movsd  (%rcx,%rsi,8),%xmm5
subsd  %xmm4,%xmm3
mulsd  (%r10,%rbx,8),%xmm5
subsd  %xmm5,%xmm3
add    $0x2,%rsi
add    %r9,%rbx
cmp    %rsi,%rbp
jne    1390 <xx_matrix_decompose+0x270>
test   $0x1,%dil
je     1340 <xx_matrix_decompose+0x220>
add    %rsi,%rdx
movsd  0x0(%r13,%rdx,8),%xmm4
imul   %r11,%rsi
add    %r12,%rsi
mulsd  0x0(%r13,%rsi,8),%xmm4
subsd  %xmm4,%xmm3
jmp    1340 <xx_matrix_decompose+0x220>
nopw   0x0(%rax,%rax,1)
mov    %r12,%r14
and    $0xfffffffffffffffe,%r14
mov    %r11,%rbx
imul   %r12,%rbx
mov    0x20(%rsp),%rcx
lea    (%rcx,%rbx,8),%rsi
xorpd  %xmm3,%xmm3
mov    %rsi,%r15
mov    %r12,%rbp
mov    %rbx,0x30(%rsp)
jmp    146c <xx_matrix_decompose+0x34c>
nopl   0x0(%rax,%rax,1)
movsd  %xmm4,0x0(%r13,%rdx,8)
andpd  %xmm1,%xmm4
mov    0x18(%rsp),%rcx
mulsd  (%rcx,%rbp,8),%xmm4
ucomisd %xmm3,%xmm4
cmovae %ebp,%r8d
movapd %xmm3,%xmm5
cmpnlesd %xmm4,%xmm5
movapd %xmm5,%xmm6
andnpd %xmm4,%xmm6
andpd  %xmm3,%xmm5
orpd   %xmm6,%xmm5
add    $0x1,%rbp
add    %rax,%r15
movapd %xmm5,%xmm3
cmp    0x8(%rsp),%rbp
je     1500 <xx_matrix_decompose+0x3e0>
mov    %rbp,%rdi
imul   %r11,%rdi
lea    (%rdi,%r12,1),%rdx
movsd  0x0(%r13,%rdx,8),%xmm4
test   %r12,%r12
je     1420 <xx_matrix_decompose+0x300>
cmp    $0x1,%r12
jne    1490 <xx_matrix_decompose+0x370>
xor    %ecx,%ecx
jmp    14ce <xx_matrix_decompose+0x3ae>
nopl   (%rax)
mov    %r12,%rbx
xor    %ecx,%ecx
cs nopw 0x0(%rax,%rax,1)
nop
movsd  -0x8(%r15,%rcx,8),%xmm5
mulsd  0x0(%r13,%rbx,8),%xmm5
movsd  (%r15,%rcx,8),%xmm6
subsd  %xmm5,%xmm4
mulsd  (%r10,%rbx,8),%xmm6
subsd  %xmm6,%xmm4
add    $0x2,%rcx
add    %r9,%rbx
cmp    %rcx,%r14
jne    14a0 <xx_matrix_decompose+0x380>
test   $0x1,%r12b
mov    0x30(%rsp),%rbx
je     1420 <xx_matrix_decompose+0x300>
add    %rcx,%rdi
movsd  0x0(%r13,%rdi,8),%xmm5
imul   %r11,%rcx
add    %r12,%rcx
mulsd  0x0(%r13,%rcx,8),%xmm5
subsd  %xmm5,%xmm4
jmp    1420 <xx_matrix_decompose+0x300>
xchg   %ax,%ax
mov    %r8d,%ecx
cmp    %rcx,%r12
mov    0x80(%rsp),%r15
mov    0x8(%rsp),%rdi
mov    0x78(%rsp),%r14
je     16fa <xx_matrix_decompose+0x5da>
mov    %r8d,%ecx
imul   %r15d,%ecx
movslq %ecx,%rbp
cmp    $0x4,%r15d
jb     155e <xx_matrix_decompose+0x43e>
lea    0x0(,%rbp,8),%rcx
add    %r13,%rcx
lea    (%r14,%rbx,8),%rdx
cmp    %rdx,%rcx
jae    15ea <xx_matrix_decompose+0x4ca>
lea    (%r14,%rbp,8),%rcx
lea    0x0(,%rbx,8),%rdx
add    %r13,%rdx
cmp    %rcx,%rdx
jae    15ea <xx_matrix_decompose+0x4ca>
xor    %edx,%edx
mov    %rdx,%rcx
test   $0x1,%dil
je     1593 <xx_matrix_decompose+0x473>
lea    (%rdx,%rbp,1),%rcx
movsd  0x0(%r13,%rcx,8),%xmm3
add    %rdx,%rbx
movsd  0x0(%r13,%rbx,8),%xmm4
movsd  %xmm4,0x0(%r13,%rcx,8)
movsd  %xmm3,0x0(%r13,%rbx,8)
mov    %rdx,%rcx
or     $0x1,%rcx
not    %rdx
cmp    0x60(%rsp),%rdx
je     16e0 <xx_matrix_decompose+0x5c0>
mov    0x20(%rsp),%rdx
lea    (%rdx,%rbp,8),%rdx
nopw   0x0(%rax,%rax,1)
movsd  -0x8(%rdx,%rcx,8),%xmm3
movsd  -0x8(%rsi,%rcx,8),%xmm4
movsd  %xmm4,-0x8(%rdx,%rcx,8)
movsd  %xmm3,-0x8(%rsi,%rcx,8)
movsd  (%rdx,%rcx,8),%xmm3
movsd  (%rsi,%rcx,8),%xmm4
movsd  %xmm4,(%rdx,%rcx,8)
movsd  %xmm3,(%rsi,%rcx,8)
add    $0x2,%rcx
cmp    %rcx,%rdi
jne    15b0 <xx_matrix_decompose+0x490>
jmp    16e0 <xx_matrix_decompose+0x5c0>
cmpq   $0x0,0x50(%rsp)
je     1670 <xx_matrix_decompose+0x550>
mov    0x38(%rsp),%rcx
lea    (%rcx,%rbp,8),%rdx
lea    (%rcx,%rbx,8),%rdi
mov    0x40(%rsp),%rbx
xor    %ecx,%ecx
nopw   0x0(%rax,%rax,1)
movups -0x30(%rdx,%rcx,8),%xmm3
movups -0x20(%rdx,%rcx,8),%xmm4
movups -0x30(%rdi,%rcx,8),%xmm5
movups -0x20(%rdi,%rcx,8),%xmm6
movups %xmm5,-0x30(%rdx,%rcx,8)
movups %xmm6,-0x20(%rdx,%rcx,8)
movups %xmm3,-0x30(%rdi,%rcx,8)
movups %xmm4,-0x20(%rdi,%rcx,8)
movupd -0x10(%rdx,%rcx,8),%xmm3
movupd (%rdx,%rcx,8),%xmm4
movupd -0x10(%rdi,%rcx,8),%xmm5
movupd (%rdi,%rcx,8),%xmm6
movupd %xmm5,-0x10(%rdx,%rcx,8)
movupd %xmm6,(%rdx,%rcx,8)
movupd %xmm3,-0x10(%rdi,%rcx,8)
movupd %xmm4,(%rdi,%rcx,8)
add    $0x8,%rcx
add    $0xfffffffffffffffe,%rbx
jne    1610 <xx_matrix_decompose+0x4f0>
jmp    1672 <xx_matrix_decompose+0x552>
xor    %ecx,%ecx
testb  $0x1,0x48(%rsp)
mov    0x30(%rsp),%rbx
je     16bd <xx_matrix_decompose+0x59d>
lea    (%rcx,%rbp,1),%rdx
movupd 0x0(%r13,%rdx,8),%xmm3
movupd 0x10(%r13,%rdx,8),%xmm4
add    %rbx,%rcx
movupd 0x0(%r13,%rcx,8),%xmm5
movupd 0x10(%r13,%rcx,8),%xmm6
movupd %xmm5,0x0(%r13,%rdx,8)
movupd %xmm6,0x10(%r13,%rdx,8)
movupd %xmm3,0x0(%r13,%rcx,8)
movupd %xmm4,0x10(%r13,%rcx,8)
mov    0x58(%rsp),%rcx
mov    %rcx,%rdx
mov    0x8(%rsp),%rdi
cmp    %rdi,%rcx
jne    1560 <xx_matrix_decompose+0x440>
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
mov    0x68(%rsp),%rcx
negl   (%rcx)
mov    0x18(%rsp),%rdx
movsd  (%rdx,%r12,8),%xmm3
movslq %r8d,%rcx
movsd  %xmm3,(%rdx,%rcx,8)
mov    0x88(%rsp),%rcx
mov    %r8d,(%rcx,%r12,4)
mov    %r12d,%ecx
imul   %r15d,%ecx
movslq %ecx,%rcx
add    %r12,%rcx
movsd  0x0(%r13,%rcx,8),%xmm4
ucomisd %xmm2,%xmm4
jne    1722 <xx_matrix_decompose+0x602>
jnp    178d <xx_matrix_decompose+0x66d>
cmp    0x70(%rsp),%r12
je     1300 <xx_matrix_decompose+0x1e0>
lea    0x1(%r12),%rcx
cmp    %r11,%rcx
jge    1307 <xx_matrix_decompose+0x1e7>
movapd %xmm0,%xmm3
divsd  %xmm4,%xmm3
add    0x28(%rsp),%r12
lea    0x0(,%r12,8),%rdx
add    %r13,%rdx
mov    %rdi,%rsi
mov    0x10(%rsp),%rbx
nopl   0x0(%rax,%rax,1)
movsd  (%rdx),%xmm4
mulsd  %xmm3,%xmm4
movsd  %xmm4,(%rdx)
add    %rax,%rdx
add    $0xffffffffffffffff,%rsi
cmp    %rsi,%rbx
jne    1760 <xx_matrix_decompose+0x640>
jmp    130c <xx_matrix_decompose+0x1ec>
xor    %ebx,%ebx
test   %rax,%rax
jne    17a0 <xx_matrix_decompose+0x680>
jmp    17b5 <xx_matrix_decompose+0x695>
mov    $0x1,%ebx
jmp    17b5 <xx_matrix_decompose+0x695>
xor    %ebx,%ebx
jmp    1796 <xx_matrix_decompose+0x676>
mov    $0x1,%ebx
mov    0x18(%rsp),%rax
test   %rax,%rax
je     17b5 <xx_matrix_decompose+0x695>
lea    0x90(%rsp),%rcx
cmp    %rcx,%rax
je     17b5 <xx_matrix_decompose+0x695>
mov    %rax,%rdi
call   1030 <free@plt>
mov    %ebx,%eax
add    $0xb8,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

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

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