void Viterbi(int output_u_int[], int out0[], int state0[], int out1[],
             int state1[], double input_c[], int KK, int nn, int LL) {
  int i, t, state, mm, states;
  int number_symbols;
  float metric;
  float *prev_section, *next_section;
  int *prev_bit;
  int *prev_state;
  float *metric_c;
  float *rec_array;
  float max_val;
  mm = KK - 1;
  states = 1 << mm;
  number_symbols = 1 << nn;
  prev_section = (float *)calloc(states, sizeof(float));
  next_section = (float *)calloc(states, sizeof(float));
  prev_bit = (int *)calloc(states * (LL + mm), sizeof(int));
  prev_state = (int *)calloc(states * (LL + mm), sizeof(int));
  rec_array = (float *)calloc(nn, sizeof(float));
  metric_c = (float *)calloc(number_symbols, sizeof(float));
  for (state = 0; state < states; state++) {
    prev_section[state] = -1e7;
    next_section[state] = -1e7;
  }
  prev_section[0] = 0;
  for (t = 0; t < LL + mm; t++) {
    for (i = 0; i < nn; i++)
      rec_array[i] = (float)input_c[nn * t + i];
    for (i = 0; i < number_symbols; i++)
      metric_c[i] = Gamma(rec_array, i, nn);
    for (state = 0; state < states; state++) {
      metric = prev_section[state] + metric_c[out0[state]];
      if (metric > next_section[state0[state]]) {
        next_section[state0[state]] = metric;
        prev_state[t * states + state0[state]] = state;
        prev_bit[t * states + state0[state]] = 0;
      }
      metric = prev_section[state] + metric_c[out1[state]];
      if (metric > next_section[state1[state]]) {
        next_section[state1[state]] = metric;
        prev_state[t * states + state1[state]] = state;
        prev_bit[t * states + state1[state]] = 1;
      }
    }
    max_val = 0;
    for (state = 0; state < states; state++) {
      if (next_section[state] > max_val) {
        max_val = next_section[state];
      }
    }
    for (state = 0; state < states; state++) {
      prev_section[state] = next_section[state] - max_val;
      next_section[state] = -1e7;
    }
  }
  state = 0;
  for (t = LL + mm - 1; t >= LL; t--) {
    state = prev_state[t * states + state];
  }
  for (t = LL - 1; t >= 0; t--) {
    output_u_int[t] = prev_bit[t * states + state];
    state = prev_state[t * states + state];
  }
  free(prev_section);
  free(next_section);
  free(prev_bit);
  free(prev_state);
  free(rec_array);
  free(metric_c);
}


x86 assembly (clang, -O0):
<Viterbi>:
push   %rbp
mov    %rsp,%rbp
sub    $0x90,%rsp
mov    0x20(%rbp),%eax
mov    0x18(%rbp),%eax
mov    0x10(%rbp),%eax
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %rcx,-0x20(%rbp)
mov    %r8,-0x28(%rbp)
mov    %r9,-0x30(%rbp)
mov    0x10(%rbp),%eax
sub    $0x1,%eax
mov    %eax,-0x40(%rbp)
mov    -0x40(%rbp),%ecx
mov    $0x1,%eax
shl    %cl,%eax
mov    %eax,-0x44(%rbp)
mov    0x18(%rbp),%ecx
mov    $0x1,%eax
shl    %cl,%eax
mov    %eax,-0x48(%rbp)
movslq -0x44(%rbp),%rdi
mov    $0x4,%esi
call   1050 <calloc@plt>
mov    %rax,-0x58(%rbp)
movslq -0x44(%rbp),%rdi
mov    $0x4,%esi
call   1050 <calloc@plt>
mov    %rax,-0x60(%rbp)
mov    -0x44(%rbp),%eax
mov    0x20(%rbp),%ecx
add    -0x40(%rbp),%ecx
imul   %ecx,%eax
movslq %eax,%rdi
mov    $0x4,%esi
call   1050 <calloc@plt>
mov    %rax,-0x68(%rbp)
mov    -0x44(%rbp),%eax
mov    0x20(%rbp),%ecx
add    -0x40(%rbp),%ecx
imul   %ecx,%eax
movslq %eax,%rdi
mov    $0x4,%esi
call   1050 <calloc@plt>
mov    %rax,-0x70(%rbp)
movslq 0x18(%rbp),%rdi
mov    $0x4,%esi
call   1050 <calloc@plt>
mov    %rax,-0x80(%rbp)
movslq -0x48(%rbp),%rdi
mov    $0x4,%esi
call   1050 <calloc@plt>
mov    %rax,-0x78(%rbp)
movl   $0x0,-0x3c(%rbp)
mov    -0x3c(%rbp),%eax
cmp    -0x44(%rbp),%eax
jge    124c <Viterbi+0x11c>
mov    -0x58(%rbp),%rax
movslq -0x3c(%rbp),%rcx
movss  0xddc(%rip),%xmm0
movss  %xmm0,(%rax,%rcx,4)
mov    -0x60(%rbp),%rax
movslq -0x3c(%rbp),%rcx
movss  0xdc7(%rip),%xmm0
movss  %xmm0,(%rax,%rcx,4)
mov    -0x3c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x3c(%rbp)
jmp    1208 <Viterbi+0xd8>
mov    -0x58(%rbp),%rax
xorps  %xmm0,%xmm0
movss  %xmm0,(%rax)
movl   $0x0,-0x38(%rbp)
mov    -0x38(%rbp),%eax
mov    0x20(%rbp),%ecx
add    -0x40(%rbp),%ecx
cmp    %ecx,%eax
jge    1529 <Viterbi+0x3f9>
movl   $0x0,-0x34(%rbp)
mov    -0x34(%rbp),%eax
cmp    0x18(%rbp),%eax
jge    12b7 <Viterbi+0x187>
mov    -0x30(%rbp),%rax
mov    0x18(%rbp),%ecx
imul   -0x38(%rbp),%ecx
add    -0x34(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
cvtsd2ss %xmm0,%xmm0
mov    -0x80(%rbp),%rax
movslq -0x34(%rbp),%rcx
movss  %xmm0,(%rax,%rcx,4)
mov    -0x34(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x34(%rbp)
jmp    1276 <Viterbi+0x146>
movl   $0x0,-0x34(%rbp)
mov    -0x34(%rbp),%eax
cmp    -0x48(%rbp),%eax
jge    12fa <Viterbi+0x1ca>
mov    -0x80(%rbp),%rdi
mov    -0x34(%rbp),%esi
mov    0x18(%rbp),%edx
mov    $0x0,%al
call   1030 <Gamma@plt>
cvtsi2ss %eax,%xmm0
mov    -0x78(%rbp),%rax
movslq -0x34(%rbp),%rcx
movss  %xmm0,(%rax,%rcx,4)
mov    -0x34(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x34(%rbp)
jmp    12be <Viterbi+0x18e>
movl   $0x0,-0x3c(%rbp)
mov    -0x3c(%rbp),%eax
cmp    -0x44(%rbp),%eax
jge    145e <Viterbi+0x32e>
mov    -0x58(%rbp),%rax
movslq -0x3c(%rbp),%rcx
movss  (%rax,%rcx,4),%xmm0
mov    -0x78(%rbp),%rax
mov    -0x10(%rbp),%rcx
movslq -0x3c(%rbp),%rdx
movslq (%rcx,%rdx,4),%rcx
addss  (%rax,%rcx,4),%xmm0
movss  %xmm0,-0x4c(%rbp)
movss  -0x4c(%rbp),%xmm0
mov    -0x60(%rbp),%rax
mov    -0x18(%rbp),%rcx
movslq -0x3c(%rbp),%rdx
movslq (%rcx,%rdx,4),%rcx
ucomiss (%rax,%rcx,4),%xmm0
jbe    13ac <Viterbi+0x27c>
movss  -0x4c(%rbp),%xmm0
mov    -0x60(%rbp),%rax
mov    -0x18(%rbp),%rcx
movslq -0x3c(%rbp),%rdx
movslq (%rcx,%rdx,4),%rcx
movss  %xmm0,(%rax,%rcx,4)
mov    -0x3c(%rbp),%edx
mov    -0x70(%rbp),%rax
mov    -0x38(%rbp),%ecx
imul   -0x44(%rbp),%ecx
mov    -0x18(%rbp),%rsi
movslq -0x3c(%rbp),%rdi
add    (%rsi,%rdi,4),%ecx
movslq %ecx,%rcx
mov    %edx,(%rax,%rcx,4)
mov    -0x68(%rbp),%rax
mov    -0x38(%rbp),%ecx
imul   -0x44(%rbp),%ecx
mov    -0x18(%rbp),%rdx
movslq -0x3c(%rbp),%rsi
add    (%rdx,%rsi,4),%ecx
movslq %ecx,%rcx
movl   $0x0,(%rax,%rcx,4)
mov    -0x58(%rbp),%rax
movslq -0x3c(%rbp),%rcx
movss  (%rax,%rcx,4),%xmm0
mov    -0x78(%rbp),%rax
mov    -0x20(%rbp),%rcx
movslq -0x3c(%rbp),%rdx
movslq (%rcx,%rdx,4),%rcx
addss  (%rax,%rcx,4),%xmm0
movss  %xmm0,-0x4c(%rbp)
movss  -0x4c(%rbp),%xmm0
mov    -0x60(%rbp),%rax
mov    -0x28(%rbp),%rcx
movslq -0x3c(%rbp),%rdx
movslq (%rcx,%rdx,4),%rcx
ucomiss (%rax,%rcx,4),%xmm0
jbe    144b <Viterbi+0x31b>
movss  -0x4c(%rbp),%xmm0
mov    -0x60(%rbp),%rax
mov    -0x28(%rbp),%rcx
movslq -0x3c(%rbp),%rdx
movslq (%rcx,%rdx,4),%rcx
movss  %xmm0,(%rax,%rcx,4)
mov    -0x3c(%rbp),%edx
mov    -0x70(%rbp),%rax
mov    -0x38(%rbp),%ecx
imul   -0x44(%rbp),%ecx
mov    -0x28(%rbp),%rsi
movslq -0x3c(%rbp),%rdi
add    (%rsi,%rdi,4),%ecx
movslq %ecx,%rcx
mov    %edx,(%rax,%rcx,4)
mov    -0x68(%rbp),%rax
mov    -0x38(%rbp),%ecx
imul   -0x44(%rbp),%ecx
mov    -0x28(%rbp),%rdx
movslq -0x3c(%rbp),%rsi
add    (%rdx,%rsi,4),%ecx
movslq %ecx,%rcx
movl   $0x1,(%rax,%rcx,4)
jmp    1450 <Viterbi+0x320>
mov    -0x3c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x3c(%rbp)
jmp    1301 <Viterbi+0x1d1>
xorps  %xmm0,%xmm0
movss  %xmm0,-0x84(%rbp)
ff
movl   $0x0,-0x3c(%rbp)
mov    -0x3c(%rbp),%eax
cmp    -0x44(%rbp),%eax
jge    14be <Viterbi+0x38e>
mov    -0x60(%rbp),%rax
movslq -0x3c(%rbp),%rcx
movss  (%rax,%rcx,4),%xmm0
ucomiss -0x84(%rbp),%xmm0
jbe    14ab <Viterbi+0x37b>
mov    -0x60(%rbp),%rax
movslq -0x3c(%rbp),%rcx
movss  (%rax,%rcx,4),%xmm0
movss  %xmm0,-0x84(%rbp)
ff
jmp    14b0 <Viterbi+0x380>
mov    -0x3c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x3c(%rbp)
jmp    1470 <Viterbi+0x340>
movl   $0x0,-0x3c(%rbp)
mov    -0x3c(%rbp),%eax
cmp    -0x44(%rbp),%eax
jge    1516 <Viterbi+0x3e6>
mov    -0x60(%rbp),%rax
movslq -0x3c(%rbp),%rcx
movss  (%rax,%rcx,4),%xmm0
subss  -0x84(%rbp),%xmm0
ff
mov    -0x58(%rbp),%rax
movslq -0x3c(%rbp),%rcx
movss  %xmm0,(%rax,%rcx,4)
mov    -0x60(%rbp),%rax
movslq -0x3c(%rbp),%rcx
movss  0xafd(%rip),%xmm0
movss  %xmm0,(%rax,%rcx,4)
mov    -0x3c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x3c(%rbp)
jmp    14c5 <Viterbi+0x395>
jmp    151b <Viterbi+0x3eb>
mov    -0x38(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x38(%rbp)
jmp    125e <Viterbi+0x12e>
movl   $0x0,-0x3c(%rbp)
mov    0x20(%rbp),%eax
add    -0x40(%rbp),%eax
sub    $0x1,%eax
mov    %eax,-0x38(%rbp)
mov    -0x38(%rbp),%eax
cmp    0x20(%rbp),%eax
jl     156d <Viterbi+0x43d>
mov    -0x70(%rbp),%rax
mov    -0x38(%rbp),%ecx
imul   -0x44(%rbp),%ecx
add    -0x3c(%rbp),%ecx
movslq %ecx,%rcx
mov    (%rax,%rcx,4),%eax
mov    %eax,-0x3c(%rbp)
mov    -0x38(%rbp),%eax
add    $0xffffffff,%eax
mov    %eax,-0x38(%rbp)
jmp    153c <Viterbi+0x40c>
mov    0x20(%rbp),%eax
sub    $0x1,%eax
mov    %eax,-0x38(%rbp)
cmpl   $0x0,-0x38(%rbp)
jl     15c4 <Viterbi+0x494>
mov    -0x68(%rbp),%rax
mov    -0x38(%rbp),%ecx
imul   -0x44(%rbp),%ecx
add    -0x3c(%rbp),%ecx
movslq %ecx,%rcx
mov    (%rax,%rcx,4),%edx
mov    -0x8(%rbp),%rax
movslq -0x38(%rbp),%rcx
mov    %edx,(%rax,%rcx,4)
mov    -0x70(%rbp),%rax
mov    -0x38(%rbp),%ecx
imul   -0x44(%rbp),%ecx
add    -0x3c(%rbp),%ecx
movslq %ecx,%rcx
mov    (%rax,%rcx,4),%eax
mov    %eax,-0x3c(%rbp)
mov    -0x38(%rbp),%eax
add    $0xffffffff,%eax
mov    %eax,-0x38(%rbp)
jmp    1576 <Viterbi+0x446>
mov    -0x58(%rbp),%rdi
call   1040 <free@plt>
mov    -0x60(%rbp),%rdi
call   1040 <free@plt>
mov    -0x68(%rbp),%rdi
call   1040 <free@plt>
mov    -0x70(%rbp),%rdi
call   1040 <free@plt>
mov    -0x80(%rbp),%rdi
call   1040 <free@plt>
mov    -0x78(%rbp),%rdi
call   1040 <free@plt>
add    $0x90,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<Viterbi>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x108,%rsp
mov    %r9,0x38(%rsp)
mov    %r8,0xf0(%rsp)
mov    %rcx,0xe8(%rsp)
mov    %rdx,0xe0(%rsp)
mov    %rsi,0x100(%rsp)
mov    %rdi,0x88(%rsp)
mov    0x150(%rsp),%eax
mov    %rax,0x28(%rsp)
mov    0x148(%rsp),%edx
mov    %edx,0xc(%rsp)
mov    0x140(%rsp),%ebx
lea    -0x1(%rbx),%r15d
mov    $0x1,%r12d
mov    $0x1,%eax
mov    %r15d,%ecx
shl    %cl,%eax
mov    $0x1,%r13d
mov    %edx,%ecx
shl    %cl,%r13d
mov    %eax,0x10(%rsp)
movslq %eax,%rbp
mov    $0x4,%esi
mov    %rbp,%rdi
call   1050 <calloc@plt>
mov    %rax,0x48(%rsp)
mov    $0x4,%esi
mov    %rbp,%rdi
call   1050 <calloc@plt>
mov    %rax,%r14
mov    %rbx,0x80(%rsp)
mov    0x28(%rsp),%rax
add    %ebx,%eax
add    $0xffffffff,%eax
mov    %eax,0x18(%rsp)
mov    %r15d,%ecx
shl    %cl,%eax
movslq %eax,%rbx
mov    $0x4,%esi
mov    %rbx,%rdi
call   1050 <calloc@plt>
mov    %rax,0x58(%rsp)
mov    $0x4,%esi
mov    %rbx,%rdi
call   1050 <calloc@plt>
mov    %rax,0x50(%rsp)
movslq 0xc(%rsp),%rdi
mov    $0x4,%esi
mov    %rdi,0x30(%rsp)
call   1050 <calloc@plt>
mov    %rax,%rbp
movslq %r13d,%rdi
mov    $0x4,%esi
call   1050 <calloc@plt>
mov    0x48(%rsp),%rdi
mov    %r15d,%ecx
mov    %rax,%r15
cmp    $0x1f,%ecx
je     1388 <Viterbi+0x258>
mov    0x10(%rsp),%eax
cmp    $0x2,%eax
cmovge %eax,%r12d
cmp    $0x8,%r12d
jae    1266 <Viterbi+0x136>
xor    %eax,%eax
jmp    1370 <Viterbi+0x240>
mov    %r12d,%eax
and    $0x7ffffff8,%eax
lea    -0x8(%rax),%rsi
mov    %rsi,%rdx
shr    $0x3,%rdx
add    $0x1,%rdx
mov    %edx,%r8d
and    $0x3,%r8d
cmp    $0x18,%rsi
jae    1291 <Viterbi+0x161>
xor    %esi,%esi
jmp    1310 <Viterbi+0x1e0>
and    $0xfffffffffffffffc,%rdx
xor    %esi,%esi
movapd 0xd61(%rip),%xmm0
nop
movupd %xmm0,(%rdi,%rsi,4)
movupd %xmm0,0x10(%rdi,%rsi,4)
movupd %xmm0,(%r14,%rsi,4)
movupd %xmm0,0x10(%r14,%rsi,4)
movupd %xmm0,0x20(%rdi,%rsi,4)
movupd %xmm0,0x30(%rdi,%rsi,4)
movupd %xmm0,0x20(%r14,%rsi,4)
movupd %xmm0,0x30(%r14,%rsi,4)
movupd %xmm0,0x40(%rdi,%rsi,4)
movupd %xmm0,0x50(%rdi,%rsi,4)
movupd %xmm0,0x40(%r14,%rsi,4)
movupd %xmm0,0x50(%r14,%rsi,4)
movupd %xmm0,0x60(%rdi,%rsi,4)
movupd %xmm0,0x70(%rdi,%rsi,4)
movupd %xmm0,0x60(%r14,%rsi,4)
movupd %xmm0,0x70(%r14,%rsi,4)
add    $0x20,%rsi
add    $0xfffffffffffffffc,%rdx
jne    12a0 <Viterbi+0x170>
test   %r8,%r8
je     135f <Viterbi+0x22f>
lea    (%r14,%rsi,4),%rdx
add    $0x10,%rdx
lea    (%rdi,%rsi,4),%rsi
add    $0x10,%rsi
shl    $0x5,%r8
xor    %ebx,%ebx
movapd 0xccd(%rip),%xmm0
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
movupd %xmm0,-0x10(%rsi,%rbx,1)
movupd %xmm0,(%rsi,%rbx,1)
movupd %xmm0,-0x10(%rdx,%rbx,1)
movupd %xmm0,(%rdx,%rbx,1)
add    $0x20,%rbx
cmp    %rbx,%r8
jne    1340 <Viterbi+0x210>
cmp    %r12,%rax
je     1388 <Viterbi+0x258>
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
movl   $0xcb189680,(%rdi,%rax,4)
movl   $0xcb189680,(%r14,%rax,4)
cb
add    $0x1,%rax
cmp    %rax,%r12
jne    1370 <Viterbi+0x240>
movl   $0x0,(%rdi)
mov    0x18(%rsp),%esi
test   %esi,%esi
mov    0x58(%rsp),%r12
mov    0x50(%rsp),%r10
mov    0xc(%rsp),%edx
jle    18d2 <Viterbi+0x7a2>
cmp    $0x2,%r13d
mov    $0x1,%r9d
cmovl  %r9d,%r13d
mov    %r13,0xd8(%rsp)
mov    0x10(%rsp),%eax
cmp    $0x2,%eax
cmovge %eax,%r9d
mov    %esi,%esi
mov    %rsi,0xd0(%rsp)
mov    0x30(%rsp),%r8
mov    %r8d,%ebx
mov    %ebx,%esi
and    $0xfffffffc,%esi
mov    %rsi,0xb8(%rsp)
add    $0xfffffffffffffffc,%rsi
mov    %rsi,0xb0(%rsp)
mov    %rsi,%rax
shr    $0x2,%rax
add    $0x1,%rax
lea    -0x1(%r9),%rsi
mov    %rsi,0xa0(%rsp)
mov    %r9d,%esi
and    $0x7ffffff8,%esi
mov    %rsi,0x78(%rsp)
add    $0xfffffffffffffff8,%rsi
mov    %rsi,0x70(%rsp)
mov    %rsi,%r10
shr    $0x3,%r10
add    $0x1,%r10
mov    %rax,%rsi
mov    %rax,0xa8(%rsp)
and    $0xfffffffffffffffe,%rax
mov    %rax,0x98(%rsp)
mov    %r9d,%eax
and    $0x3,%eax
mov    %rax,0x40(%rsp)
mov    %r9,0x10(%rsp)
and    $0x7ffffffc,%r9d
mov    %r9,0x90(%rsp)
movabs $0x3ffffffffffffffc,%rsi
ff ff 3f
or     $0x2,%rsi
mov    %r10,%rax
mov    %r10,0x68(%rsp)
and    %r10,%rsi
mov    %rsi,0x60(%rsp)
mov    0x38(%rsp),%rax
lea    0x30(%rax),%r13
lea    0x0(,%r8,8),%rsi
mov    %rsi,0xc0(%rsp)
mov    %rax,%rsi
xor    %eax,%eax
mov    %rax,0x18(%rsp)
mov    %ecx,0x24(%rsp)
mov    %rbx,0xc8(%rsp)
jmp    1500 <Viterbi+0x3d0>
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax)
mov    0x18(%rsp),%rbp
add    $0x1,%rbp
mov    0xc0(%rsp),%rax
add    %rax,%r13
mov    0xf8(%rsp),%rsi
add    %rax,%rsi
mov    %rbp,%rax
mov    %rbp,0x18(%rsp)
cmp    0xd0(%rsp),%rbp
mov    %r8,%rbp
mov    0xc8(%rsp),%rbx
je     18d2 <Viterbi+0x7a2>
test   %edx,%edx
jle    15f8 <Viterbi+0x4c8>
cmp    $0x4,%edx
jae    1520 <Viterbi+0x3f0>
xor    %eax,%eax
jmp    15e0 <Viterbi+0x4b0>
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
cmpq   $0x0,0xb0(%rsp)
je     17d0 <Viterbi+0x6a0>
mov    0x98(%rsp),%rcx
xor    %eax,%eax
nopl   0x0(%rax)
movupd -0x30(%r13,%rax,8),%xmm0
movupd -0x20(%r13,%rax,8),%xmm1
cvtpd2ps %xmm0,%xmm0
cvtpd2ps %xmm1,%xmm1
unpcklpd %xmm1,%xmm0
movupd %xmm0,0x0(%rbp,%rax,4)
movupd -0x10(%r13,%rax,8),%xmm0
movupd 0x0(%r13,%rax,8),%xmm1
cvtpd2ps %xmm0,%xmm0
cvtpd2ps %xmm1,%xmm1
unpcklpd %xmm1,%xmm0
movupd %xmm0,0x10(%rbp,%rax,4)
add    $0x8,%rax
add    $0xfffffffffffffffe,%rcx
jne    1540 <Viterbi+0x410>
testb  $0x1,0xa8(%rsp)
01
je     15c8 <Viterbi+0x498>
mov    0x18(%rsp),%rcx
imul   0x30(%rsp),%rcx
add    %rax,%rcx
mov    0x38(%rsp),%rdx
movupd (%rdx,%rcx,8),%xmm0
movupd 0x10(%rdx,%rcx,8),%xmm1
mov    0xc(%rsp),%edx
cvtpd2ps %xmm0,%xmm0
cvtpd2ps %xmm1,%xmm1
unpcklpd %xmm1,%xmm0
movupd %xmm0,0x0(%rbp,%rax,4)
mov    0xb8(%rsp),%rcx
mov    %rcx,%rax
cmp    %rbx,%rcx
je     15f8 <Viterbi+0x4c8>
nopl   0x0(%rax,%rax,1)
movsd  (%rsi,%rax,8),%xmm0
cvtsd2ss %xmm0,%xmm0
movss  %xmm0,0x0(%rbp,%rax,4)
add    $0x1,%rax
cmp    %rax,%rbx
jne    15e0 <Viterbi+0x4b0>
mov    %rsi,0xf8(%rsp)
cmp    $0x1f,%edx
mov    0xd8(%rsp),%rbx
je     163b <Viterbi+0x50b>
xor    %r12d,%r12d
mov    %rbp,%rdi
mov    %r12d,%esi
mov    0xc(%rsp),%edx
xor    %eax,%eax
call   1030 <Gamma@plt>
mov    0xc(%rsp),%edx
xorps  %xmm0,%xmm0
cvtsi2ss %eax,%xmm0
movss  %xmm0,(%r15,%r12,4)
add    $0x1,%r12
cmp    %r12,%rbx
jne    1610 <Viterbi+0x4e0>
mov    %rbp,%r8
mov    0x24(%rsp),%ecx
cmp    $0x1f,%ecx
mov    0x48(%rsp),%rdi
mov    0x58(%rsp),%r12
mov    0x50(%rsp),%r10
mov    0xf0(%rsp),%r9
mov    0xe8(%rsp),%r11
mov    0xe0(%rsp),%rbp
movaps 0x98d(%rip),%xmm4
je     14c0 <Viterbi+0x390>
mov    0x18(%rsp),%rax
shl    %cl,%eax
xor    %ebx,%ebx
jmp    169b <Viterbi+0x56b>
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
add    $0x1,%rbx
cmp    %rbx,0x10(%rsp)
je     1710 <Viterbi+0x5e0>
movss  (%rdi,%rbx,4),%xmm0
mov    0x100(%rsp),%rdx
movslq (%rdx,%rbx,4),%rdx
movss  (%r15,%rdx,4),%xmm1
addss  %xmm0,%xmm1
movslq 0x0(%rbp,%rbx,4),%rdx
ucomiss (%r14,%rdx,4),%xmm1
jbe    16da <Viterbi+0x5aa>
movss  %xmm1,(%r14,%rdx,4)
movslq %eax,%rsi
add    %rdx,%rsi
mov    %ebx,(%r10,%rsi,4)
movl   $0x0,(%r12,%rsi,4)
movslq (%r11,%rbx,4),%rdx
addss  (%r15,%rdx,4),%xmm0
movslq (%r9,%rbx,4),%rdx
ucomiss (%r14,%rdx,4),%xmm0
jbe    1690 <Viterbi+0x560>
movss  %xmm0,(%r14,%rdx,4)
movslq %eax,%rsi
add    %rdx,%rsi
mov    %ebx,(%r10,%rsi,4)
movl   $0x1,(%r12,%rsi,4)
jmp    1690 <Viterbi+0x560>
nopl   0x0(%rax)
cmp    $0x1f,%ecx
mov    0xc(%rsp),%edx
je     14c0 <Viterbi+0x390>
cmpq   $0x3,0xa0(%rsp)
jae    1734 <Viterbi+0x604>
xorps  %xmm1,%xmm1
xor    %eax,%eax
mov    0x40(%rsp),%rsi
jmp    1784 <Viterbi+0x654>
xorps  %xmm1,%xmm1
xor    %eax,%eax
mov    0x40(%rsp),%rsi
mov    0x90(%rsp),%rdx
cs nopw 0x0(%rax,%rax,1)
movss  (%r14,%rax,4),%xmm0
maxss  %xmm1,%xmm0
movss  0x4(%r14,%rax,4),%xmm1
maxss  %xmm0,%xmm1
movss  0x8(%r14,%rax,4),%xmm0
maxss  %xmm1,%xmm0
movss  0xc(%r14,%rax,4),%xmm1
maxss  %xmm0,%xmm1
add    $0x4,%rax
cmp    %rax,%rdx
jne    1750 <Viterbi+0x620>
movaps %xmm1,%xmm0
test   %rsi,%rsi
je     17b5 <Viterbi+0x685>
lea    (%r14,%rax,4),%rax
xor    %edx,%edx
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax)
movss  (%rax,%rdx,4),%xmm0
maxss  %xmm1,%xmm0
add    $0x1,%rdx
movaps %xmm0,%xmm1
cmp    %rdx,%rsi
jne    17a0 <Viterbi+0x670>
cmp    $0x1f,%ecx
mov    0xc(%rsp),%edx
je     14c0 <Viterbi+0x390>
cmpl   $0x8,0x10(%rsp)
jae    17e5 <Viterbi+0x6b5>
xor    %eax,%eax
jmp    18a0 <Viterbi+0x770>
xor    %eax,%eax
testb  $0x1,0xa8(%rsp)
01
jne    1594 <Viterbi+0x464>
jmp    15c8 <Viterbi+0x498>
movaps %xmm0,%xmm1
shufps $0x0,%xmm0,%xmm1
cmpq   $0x0,0x70(%rsp)
je     18c7 <Viterbi+0x797>
mov    0x60(%rsp),%rdx
xor    %eax,%eax
nop
movups (%r14,%rax,4),%xmm2
movups 0x10(%r14,%rax,4),%xmm3
subps  %xmm1,%xmm2
subps  %xmm1,%xmm3
movups %xmm2,(%rdi,%rax,4)
movups %xmm3,0x10(%rdi,%rax,4)
movups %xmm4,(%r14,%rax,4)
movups %xmm4,0x10(%r14,%rax,4)
movups 0x20(%r14,%rax,4),%xmm2
movups 0x30(%r14,%rax,4),%xmm3
subps  %xmm1,%xmm2
subps  %xmm1,%xmm3
movups %xmm2,0x20(%rdi,%rax,4)
movups %xmm3,0x30(%rdi,%rax,4)
movups %xmm4,0x20(%r14,%rax,4)
movups %xmm4,0x30(%r14,%rax,4)
add    $0x10,%rax
add    $0xfffffffffffffffe,%rdx
jne    1800 <Viterbi+0x6d0>
testb  $0x1,0x68(%rsp)
je     1883 <Viterbi+0x753>
movups (%r14,%rax,4),%xmm2
movups 0x10(%r14,%rax,4),%xmm3
subps  %xmm1,%xmm2
subps  %xmm1,%xmm3
movups %xmm2,(%rdi,%rax,4)
movups %xmm3,0x10(%rdi,%rax,4)
movups %xmm4,(%r14,%rax,4)
movups %xmm4,0x10(%r14,%rax,4)
mov    0x78(%rsp),%rdx
mov    %rdx,%rax
cmp    0x10(%rsp),%rdx
mov    0xc(%rsp),%edx
je     14c0 <Viterbi+0x390>
nopw   0x0(%rax,%rax,1)
movss  (%r14,%rax,4),%xmm1
subss  %xmm0,%xmm1
movss  %xmm1,(%rdi,%rax,4)
movl   $0xcb189680,(%r14,%rax,4)
cb
add    $0x1,%rax
cmp    %rax,0x10(%rsp)
jne    18a0 <Viterbi+0x770>
jmp    14c0 <Viterbi+0x390>
xor    %eax,%eax
testb  $0x1,0x68(%rsp)
jne    185e <Viterbi+0x72e>
jmp    1883 <Viterbi+0x753>
xor    %eax,%eax
mov    0x80(%rsp),%rdx
cmp    $0x2,%edx
mov    0x28(%rsp),%r9
jl     1907 <Viterbi+0x7d7>
add    %r9d,%edx
add    $0xfffffffe,%edx
xor    %eax,%eax
xchg   %ax,%ax
mov    %edx,%esi
shl    %cl,%esi
add    %eax,%esi
movslq %esi,%rax
mov    (%r10,%rax,4),%eax
lea    -0x1(%rdx),%esi
cmp    %r9d,%edx
mov    %esi,%edx
jg     18f0 <Viterbi+0x7c0>
test   %r9d,%r9d
mov    0x88(%rsp),%r8
jle    197f <Viterbi+0x84f>
mov    %r9d,%edx
test   $0x1,%dl
je     1937 <Viterbi+0x807>
add    $0xffffffffffffffff,%rdx
mov    %edx,%esi
mov    %edx,%ebx
shl    %cl,%ebx
add    %eax,%ebx
movslq %ebx,%rax
mov    (%r12,%rax,4),%ebx
mov    %ebx,(%r8,%rsi,4)
mov    (%r10,%rax,4),%eax
cmp    $0x1,%r9d
je     197f <Viterbi+0x84f>
nopl   (%rax)
lea    -0x1(%rdx),%rsi
mov    %esi,%r9d
mov    %esi,%ebx
shl    %cl,%ebx
add    %eax,%ebx
movslq %ebx,%rax
mov    (%r12,%rax,4),%ebx
mov    %ebx,(%r8,%r9,4)
add    $0xfffffffffffffffe,%rdx
mov    %edx,%ebx
shl    %cl,%ebx
movslq (%r10,%rax,4),%rax
mov    %edx,%r9d
movslq %ebx,%rbx
add    %rax,%rbx
mov    (%r12,%rbx,4),%eax
mov    %eax,(%r8,%r9,4)
mov    (%r10,%rbx,4),%eax
cmp    $0x1,%rsi
ja     1940 <Viterbi+0x810>
mov    %r10,%rbx
call   1040 <free@plt>
mov    %r14,%rdi
call   1040 <free@plt>
mov    %r12,%rdi
call   1040 <free@plt>
mov    %rbx,%rdi
call   1040 <free@plt>
mov    %rbp,%rdi
call   1040 <free@plt>
mov    %r15,%rdi
add    $0x108,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
jmp    1040 <free@plt>

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

LLVM IR (-O2):
define void @Viterbi(i32* nocapture writeonly %0, i32* nocapture %1, i32* nocapture %2, i32* nocapture %3, i32* nocapture %4, double* nocapture %5, i32 %6, i32 %7, i32 %8) {
%10 = add nsw i32 %6, -1
%11 = shl nuw i32 1, %10
%12 = shl nuw i32 1, %7
%13 = sext i32 %11 to i64
%14 = tail call i8* @calloc(i64 %13, i64 4)
%15 = bitcast i8* %14 to float*
%16 = tail call i8* @calloc(i64 %13, i64 4)
%17 = bitcast i8* %16 to float*
%18 = add nsw i32 %10, %8
%19 = shl i32 %18, %10
%20 = sext i32 %19 to i64
%21 = tail call i8* @calloc(i64 %20, i64 4)
%22 = bitcast i8* %21 to i32*
%23 = tail call i8* @calloc(i64 %20, i64 4)
%24 = bitcast i8* %23 to i32*
%25 = sext i32 %7 to i64
%26 = tail call i8* @calloc(i64 %25, i64 4)
%27 = bitcast i8* %26 to float*
%28 = sext i32 %12 to i64
%29 = tail call i8* @calloc(i64 %28, i64 4)
%30 = bitcast i8* %29 to float*
%31 = icmp eq i32 %10, 31
br i1 %31, label %113, label %32
32: ; preds = %9
%33 = call i32 @llvm.smax.i32(i32 %11, i32 1)
%34 = zext i32 %33 to i64
%35 = icmp ult i32 %33, 8
br i1 %35, label %105, label %36
36: ; preds = %32
%37 = and i64 %34, 2147483640
%38 = add nsw i64 %37, -8
%39 = lshr exact i64 %38, 3
%40 = add nuw nsw i64 %39, 1
%41 = and i64 %40, 3
%42 = icmp ult i64 %38, 24
br i1 %42, label %86, label %43
43: ; preds = %36
%44 = and i64 %40, 4611686018427387900
br label %45
45: ; preds = %45, %43
%46 = phi i64 [ 0, %43 ], [ %83, %45 ]
%47 = phi i64 [ 0, %43 ], [ %84, %45 ]
%48 = getelementptr inbounds float, float* %15, i64 %46
%49 = bitcast float* %48 to <4 x float>*
store <4 x float> <float -1.000000e+07, float -1.000000e+07, float -1.000000e+07, float -1.000000e+07>, <4 x float>* %49
%50 = getelementptr inbounds float, float* %48, i64 4
%51 = bitcast float* %50 to <4 x float>*
store <4 x float> <float -1.000000e+07, float -1.000000e+07, float -1.000000e+07, float -1.000000e+07>, <4 x float>* %51
%52 = getelementptr inbounds float, float* %17, i64 %46
%53 = bitcast float* %52 to <4 x float>*
store <4 x float> <float -1.000000e+07, float -1.000000e+07, float -1.000000e+07, float -1.000000e+07>, <4 x float>* %53
%54 = getelementptr inbounds float, float* %52, i64 4
%55 = bitcast float* %54 to <4 x float>*
store <4 x float> <float -1.000000e+07, float -1.000000e+07, float -1.000000e+07, float -1.000000e+07>, <4 x float>* %55
%56 = or i64 %46, 8
%57 = getelementptr inbounds float, float* %15, i64 %56
%58 = bitcast float* %57 to <4 x float>*
store <4 x float> <float -1.000000e+07, float -1.000000e+07, float -1.000000e+07, float -1.000000e+07>, <4 x float>* %58
%59 = getelementptr inbounds float, float* %57, i64 4
%60 = bitcast float* %59 to <4 x float>*
store <4 x float> <float -1.000000e+07, float -1.000000e+07, float -1.000000e+07, float -1.000000e+07>, <4 x float>* %60
%61 = getelementptr inbounds float, float* %17, i64 %56
%62 = bitcast float* %61 to <4 x float>*
store <4 x float> <float -1.000000e+07, float -1.000000e+07, float -1.000000e+07, float -1.000000e+07>, <4 x float>* %62
%63 = getelementptr inbounds float, float* %61, i64 4
%64 = bitcast float* %63 to <4 x float>*
store <4 x float> <float -1.000000e+07, float -1.000000e+07, float -1.000000e+07, float -1.000000e+07>, <4 x float>* %64
%65 = or i64 %46, 16
%66 = getelementptr inbounds float, float* %15, i64 %65
%67 = bitcast float* %66 to <4 x float>*
store <4 x float> <float -1.000000e+07, float -1.000000e+07, float -1.000000e+07, float -1.000000e+07>, <4 x float>* %67
%68 = getelementptr inbounds float, float* %66, i64 4
%69 = bitcast float* %68 to <4 x float>*
store <4 x float> <float -1.000000e+07, float -1.000000e+07, float -1.000000e+07, float -1.000000e+07>, <4 x float>* %69
%70 = getelementptr inbounds float, float* %17, i64 %65
%71 = bitcast float* %70 to <4 x float>*
store <4 x float> <float -1.000000e+07, float -1.000000e+07, float -1.000000e+07, float -1.000000e+07>, <4 x float>* %71
%72 = getelementptr inbounds float, float* %70, i64 4
%73 = bitcast float* %72 to <4 x float>*
store <4 x float> <float -1.000000e+07, float -1.000000e+07, float -1.000000e+07, float -1.000000e+07>, <4 x float>* %73
%74 = or i64 %46, 24
%75 = getelementptr inbounds float, float* %15, i64 %74
%76 = bitcast float* %75 to <4 x float>*
store <4 x float> <float -1.000000e+07, float -1.000000e+07, float -1.000000e+07, float -1.000000e+07>, <4 x float>* %76
%77 = getelementptr inbounds float, float* %75, i64 4
%78 = bitcast float* %77 to <4 x float>*
store <4 x float> <float -1.000000e+07, float -1.000000e+07, float -1.000000e+07, float -1.000000e+07>, <4 x float>* %78
%79 = getelementptr inbounds float, float* %17, i64 %74
%80 = bitcast float* %79 to <4 x float>*
store <4 x float> <float -1.000000e+07, float -1.000000e+07, float -1.000000e+07, float -1.000000e+07>, <4 x float>* %80
%81 = getelementptr inbounds float, float* %79, i64 4
%82 = bitcast float* %81 to <4 x float>*
store <4 x float> <float -1.000000e+07, float -1.000000e+07, float -1.000000e+07, float -1.000000e+07>, <4 x float>* %82
%83 = add nuw i64 %46, 32
%84 = add i64 %47, 4
%85 = icmp eq i64 %84, %44
br i1 %85, label %86, label %45
86: ; preds = %45, %36
%87 = phi i64 [ 0, %36 ], [ %83, %45 ]
%88 = icmp eq i64 %41, 0
br i1 %88, label %103, label %89
89: ; preds = %86, %89
%90 = phi i64 [ %100, %89 ], [ %87, %86 ]
%91 = phi i64 [ %101, %89 ], [ 0, %86 ]
%92 = getelementptr inbounds float, float* %15, i64 %90
%93 = bitcast float* %92 to <4 x float>*
store <4 x float> <float -1.000000e+07, float -1.000000e+07, float -1.000000e+07, float -1.000000e+07>, <4 x float>* %93
%94 = getelementptr inbounds float, float* %92, i64 4
%95 = bitcast float* %94 to <4 x float>*
store <4 x float> <float -1.000000e+07, float -1.000000e+07, float -1.000000e+07, float -1.000000e+07>, <4 x float>* %95
%96 = getelementptr inbounds float, float* %17, i64 %90
%97 = bitcast float* %96 to <4 x float>*
store <4 x float> <float -1.000000e+07, float -1.000000e+07, float -1.000000e+07, float -1.000000e+07>, <4 x float>* %97
%98 = getelementptr inbounds float, float* %96, i64 4
%99 = bitcast float* %98 to <4 x float>*
store <4 x float> <float -1.000000e+07, float -1.000000e+07, float -1.000000e+07, float -1.000000e+07>, <4 x float>* %99
%100 = add nuw i64 %90, 8
%101 = add i64 %91, 1
%102 = icmp eq i64 %101, %41
br i1 %102, label %103, label %89
103: ; preds = %89, %86
%104 = icmp eq i64 %37, %34
br i1 %104, label %113, label %105
105: ; preds = %32, %103
%106 = phi i64 [ 0, %32 ], [ %37, %103 ]
br label %107
107: ; preds = %105, %107
%108 = phi i64 [ %111, %107 ], [ %106, %105 ]
%109 = getelementptr inbounds float, float* %15, i64 %108
store float -1.000000e+07, float* %109
%110 = getelementptr inbounds float, float* %17, i64 %108
store float -1.000000e+07, float* %110
%111 = add nuw nsw i64 %108, 1
%112 = icmp eq i64 %111, %34
br i1 %112, label %113, label %107
113: ; preds = %107, %103, %9
store float 0.000000e+00, float* %15
%114 = icmp sgt i32 %18, 0
br i1 %114, label %115, label %209
115: ; preds = %113
%116 = icmp sgt i32 %7, 0
%117 = icmp eq i32 %7, 31
%118 = call i32 @llvm.smax.i32(i32 %12, i32 1)
%119 = call i32 @llvm.smax.i32(i32 %11, i32 1)
%120 = zext i32 %18 to i64
%121 = zext i32 %7 to i64
%122 = zext i32 %118 to i64
%123 = zext i32 %119 to i64
%124 = zext i32 %119 to i64
%125 = and i64 %121, 4294967292
%126 = add nsw i64 %125, -4
%127 = lshr exact i64 %126, 2
%128 = add nuw nsw i64 %127, 1
%129 = add nsw i64 %123, -1
%130 = and i64 %123, 2147483640
%131 = add nsw i64 %130, -8
%132 = lshr exact i64 %131, 3
%133 = add nuw nsw i64 %132, 1
%134 = icmp ult i32 %7, 4
%135 = and i64 %121, 4294967292
%136 = and i64 %128, 1
%137 = icmp eq i64 %126, 0
%138 = and i64 %128, 9223372036854775806
%139 = icmp eq i64 %136, 0
%140 = icmp eq i64 %135, %121
%141 = and i64 %123, 3
%142 = icmp ult i64 %129, 3
%143 = and i64 %123, 2147483644
%144 = icmp eq i64 %141, 0
%145 = icmp ult i32 %119, 8
%146 = and i64 %123, 2147483640
%147 = and i64 %133, 1
%148 = icmp eq i64 %131, 0
%149 = and i64 %133, 4611686018427387902
%150 = icmp eq i64 %147, 0
%151 = icmp eq i64 %146, %123
br label %152
152: ; preds = %115, %391
%153 = phi i64 [ 0, %115 ], [ %392, %391 ]
br i1 %116, label %154, label %211
154: ; preds = %152
%155 = mul nsw i64 %153, %25
br i1 %134, label %207, label %156
156: ; preds = %154
br i1 %137, label %190, label %157
157: ; preds = %156, %157
%158 = phi i64 [ %187, %157 ], [ 0, %156 ]
%159 = phi i64 [ %188, %157 ], [ 0, %156 ]
%160 = add nsw i64 %158, %155
%161 = getelementptr inbounds double, double* %5, i64 %160
%162 = bitcast double* %161 to <2 x double>*
%163 = load <2 x double>, <2 x double>* %162
%164 = getelementptr inbounds double, double* %161, i64 2
%165 = bitcast double* %164 to <2 x double>*
%166 = load <2 x double>, <2 x double>* %165
%167 = fptrunc <2 x double> %163 to <2 x float>
%168 = fptrunc <2 x double> %166 to <2 x float>
%169 = getelementptr inbounds float, float* %27, i64 %158
%170 = bitcast float* %169 to <2 x float>*
store <2 x float> %167, <2 x float>* %170
%171 = getelementptr inbounds float, float* %169, i64 2
%172 = bitcast float* %171 to <2 x float>*
store <2 x float> %168, <2 x float>* %172
%173 = or i64 %158, 4
%174 = add nsw i64 %173, %155
%175 = getelementptr inbounds double, double* %5, i64 %174
%176 = bitcast double* %175 to <2 x double>*
%177 = load <2 x double>, <2 x double>* %176
%178 = getelementptr inbounds double, double* %175, i64 2
%179 = bitcast double* %178 to <2 x double>*
%180 = load <2 x double>, <2 x double>* %179
%181 = fptrunc <2 x double> %177 to <2 x float>
%182 = fptrunc <2 x double> %180 to <2 x float>
%183 = getelementptr inbounds float, float* %27, i64 %173
%184 = bitcast float* %183 to <2 x float>*
store <2 x float> %181, <2 x float>* %184
%185 = getelementptr inbounds float, float* %183, i64 2
%186 = bitcast float* %185 to <2 x float>*
store <2 x float> %182, <2 x float>* %186
%187 = add nuw i64 %158, 8
%188 = add i64 %159, 2
%189 = icmp eq i64 %188, %138
br i1 %189, label %190, label %157
190: ; preds = %157, %156
%191 = phi i64 [ 0, %156 ], [ %187, %157 ]
br i1 %139, label %206, label %192
192: ; preds = %190
%193 = add nsw i64 %191, %155
%194 = getelementptr inbounds double, double* %5, i64 %193
%195 = bitcast double* %194 to <2 x double>*
%196 = load <2 x double>, <2 x double>* %195
%197 = getelementptr inbounds double, double* %194, i64 2
%198 = bitcast double* %197 to <2 x double>*
%199 = load <2 x double>, <2 x double>* %198
%200 = fptrunc <2 x double> %196 to <2 x float>
%201 = fptrunc <2 x double> %199 to <2 x float>
%202 = getelementptr inbounds float, float* %27, i64 %191
%203 = bitcast float* %202 to <2 x float>*
store <2 x float> %200, <2 x float>* %203
%204 = getelementptr inbounds float, float* %202, i64 2
%205 = bitcast float* %204 to <2 x float>*
store <2 x float> %201, <2 x float>* %205
br label %206
206: ; preds = %190, %192
br i1 %140, label %211, label %207
207: ; preds = %154, %206
%208 = phi i64 [ 0, %154 ], [ %135, %206 ]
br label %212
209: ; preds = %391, %113
%210 = icmp sgt i32 %6, 1
br i1 %210, label %417, label %394
211: ; preds = %212, %206, %152
br i1 %117, label %221, label %225
212: ; preds = %207, %212
%213 = phi i64 [ %219, %212 ], [ %208, %207 ]
%214 = add nsw i64 %213, %155
%215 = getelementptr inbounds double, double* %5, i64 %214
%216 = load double, double* %215
%217 = fptrunc double %216 to float
%218 = getelementptr inbounds float, float* %27, i64 %213
store float %217, float* %218
%219 = add nuw nsw i64 %213, 1
%220 = icmp eq i64 %219, %121
br i1 %220, label %211, label %212
221: ; preds = %225, %211
br i1 %31, label %391, label %222
222: ; preds = %221
%223 = trunc i64 %153 to i32
%224 = shl i32 %223, %10
br label %235
225: ; preds = %211, %225
%226 = phi i64 [ %231, %225 ], [ 0, %211 ]
%227 = trunc i64 %226 to i32
%228 = tail call i32 (float*, i32, i32, ...) bitcast (i32 (...)* @Gamma to i32 (float*, i32, i32, ...)*)(float* %27, i32 %227, i32 %7)
%229 = sitofp i32 %228 to float
%230 = getelementptr inbounds float, float* %30, i64 %226
store float %229, float* %230
%231 = add nuw nsw i64 %226, 1
%232 = icmp eq i64 %231, %122
br i1 %232, label %221, label %225
233: ; preds = %276
br i1 %31, label %391, label %234
234: ; preds = %233
br i1 %142, label %279, label %357
235: ; preds = %222, %276
%236 = phi i64 [ 0, %222 ], [ %277, %276 ]
%237 = getelementptr inbounds float, float* %15, i64 %236
%238 = load float, float* %237
%239 = getelementptr inbounds i32, i32* %1, i64 %236
%240 = load i32, i32* %239
%241 = sext i32 %240 to i64
%242 = getelementptr inbounds float, float* %30, i64 %241
%243 = load float, float* %242
%244 = fadd float %238, %243
%245 = getelementptr inbounds i32, i32* %2, i64 %236
%246 = load i32, i32* %245
%247 = sext i32 %246 to i64
%248 = getelementptr inbounds float, float* %17, i64 %247
%249 = load float, float* %248
%250 = fcmp ogt float %244, %249
br i1 %250, label %251, label %257
251: ; preds = %235
store float %244, float* %248
%252 = add nsw i32 %246, %224
%253 = sext i32 %252 to i64
%254 = getelementptr inbounds i32, i32* %24, i64 %253
%255 = trunc i64 %236 to i32
store i32 %255, i32* %254
%256 = getelementptr inbounds i32, i32* %22, i64 %253
store i32 0, i32* %256
br label %257
257: ; preds = %251, %235
%258 = getelementptr inbounds i32, i32* %3, i64 %236
%259 = load i32, i32* %258
%260 = sext i32 %259 to i64
%261 = getelementptr inbounds float, float* %30, i64 %260
%262 = load float, float* %261
%263 = fadd float %238, %262
%264 = getelementptr inbounds i32, i32* %4, i64 %236
%265 = load i32, i32* %264
%266 = sext i32 %265 to i64
%267 = getelementptr inbounds float, float* %17, i64 %266
%268 = load float, float* %267
%269 = fcmp ogt float %263, %268
br i1 %269, label %270, label %276
270: ; preds = %257
store float %263, float* %267
%271 = add nsw i32 %265, %224
%272 = sext i32 %271 to i64
%273 = getelementptr inbounds i32, i32* %24, i64 %272
%274 = trunc i64 %236 to i32
store i32 %274, i32* %273
%275 = getelementptr inbounds i32, i32* %22, i64 %272
store i32 1, i32* %275
br label %276
276: ; preds = %257, %270
%277 = add nuw nsw i64 %236, 1
%278 = icmp eq i64 %277, %123
br i1 %278, label %233, label %235
279: ; preds = %357, %234
%280 = phi float [ undef, %234 ], [ %379, %357 ]
%281 = phi i64 [ 0, %234 ], [ %380, %357 ]
%282 = phi float [ 0.000000e+00, %234 ], [ %379, %357 ]
br i1 %144, label %294, label %283
283: ; preds = %279, %283
%284 = phi i64 [ %291, %283 ], [ %281, %279 ]
%285 = phi float [ %290, %283 ], [ %282, %279 ]
%286 = phi i64 [ %292, %283 ], [ 0, %279 ]
%287 = getelementptr inbounds float, float* %17, i64 %284
%288 = load float, float* %287
%289 = fcmp ogt float %288, %285
%290 = select i1 %289, float %288, float %285
%291 = add nuw nsw i64 %284, 1
%292 = add i64 %286, 1
%293 = icmp eq i64 %292, %141
br i1 %293, label %294, label %283
294: ; preds = %283, %279
%295 = phi float [ %280, %279 ], [ %290, %283 ]
br i1 %31, label %391, label %296
296: ; preds = %294
br i1 %145, label %355, label %297
297: ; preds = %296
%298 = insertelement <4 x float> poison, float %295, i64 0
%299 = shufflevector <4 x float> %298, <4 x float> poison, <4 x i32> zeroinitializer
%300 = insertelement <4 x float> poison, float %295, i64 0
%301 = shufflevector <4 x float> %300, <4 x float> poison, <4 x i32> zeroinitializer
br i1 %148, label %337, label %302
302: ; preds = %297, %302
%303 = phi i64 [ %334, %302 ], [ 0, %297 ]
%304 = phi i64 [ %335, %302 ], [ 0, %297 ]
%305 = getelementptr inbounds float, float* %17, i64 %303
%306 = bitcast float* %305 to <4 x float>*
%307 = load <4 x float>, <4 x float>* %306
%308 = getelementptr inbounds float, float* %305, i64 4
%309 = bitcast float* %308 to <4 x float>*
%310 = load <4 x float>, <4 x float>* %309
%311 = fsub <4 x float> %307, %299
%312 = fsub <4 x float> %310, %301
%313 = getelementptr inbounds float, float* %15, i64 %303
%314 = bitcast float* %313 to <4 x float>*
store <4 x float> %311, <4 x float>* %314
%315 = getelementptr inbounds float, float* %313, i64 4
%316 = bitcast float* %315 to <4 x float>*
store <4 x float> %312, <4 x float>* %316
%317 = bitcast float* %305 to <4 x float>*
store <4 x float> <float -1.000000e+07, float -1.000000e+07, float -1.000000e+07, float -1.000000e+07>, <4 x float>* %317
%318 = bitcast float* %308 to <4 x float>*
store <4 x float> <float -1.000000e+07, float -1.000000e+07, float -1.000000e+07, float -1.000000e+07>, <4 x float>* %318
%319 = or i64 %303, 8
%320 = getelementptr inbounds float, float* %17, i64 %319
%321 = bitcast float* %320 to <4 x float>*
%322 = load <4 x float>, <4 x float>* %321
%323 = getelementptr inbounds float, float* %320, i64 4
%324 = bitcast float* %323 to <4 x float>*
%325 = load <4 x float>, <4 x float>* %324
%326 = fsub <4 x float> %322, %299
%327 = fsub <4 x float> %325, %301
%328 = getelementptr inbounds float, float* %15, i64 %319
%329 = bitcast float* %328 to <4 x float>*
store <4 x float> %326, <4 x float>* %329
%330 = getelementptr inbounds float, float* %328, i64 4
%331 = bitcast float* %330 to <4 x float>*
store <4 x float> %327, <4 x float>* %331
%332 = bitcast float* %320 to <4 x float>*
store <4 x float> <float -1.000000e+07, float -1.000000e+07, float -1.000000e+07, float -1.000000e+07>, <4 x float>* %332
%333 = bitcast float* %323 to <4 x float>*
store <4 x float> <float -1.000000e+07, float -1.000000e+07, float -1.000000e+07, float -1.000000e+07>, <4 x float>* %333
%334 = add nuw i64 %303, 16
%335 = add i64 %304, 2
%336 = icmp eq i64 %335, %149
br i1 %336, label %337, label %302
337: ; preds = %302, %297
%338 = phi i64 [ 0, %297 ], [ %334, %302 ]
br i1 %150, label %354, label %339
339: ; preds = %337
%340 = getelementptr inbounds float, float* %17, i64 %338
%341 = bitcast float* %340 to <4 x float>*
%342 = load <4 x float>, <4 x float>* %341
%343 = getelementptr inbounds float, float* %340, i64 4
%344 = bitcast float* %343 to <4 x float>*
%345 = load <4 x float>, <4 x float>* %344
%346 = fsub <4 x float> %342, %299
%347 = fsub <4 x float> %345, %301
%348 = getelementptr inbounds float, float* %15, i64 %338
%349 = bitcast float* %348 to <4 x float>*
store <4 x float> %346, <4 x float>* %349
%350 = getelementptr inbounds float, float* %348, i64 4
%351 = bitcast float* %350 to <4 x float>*
store <4 x float> %347, <4 x float>* %351
%352 = bitcast float* %340 to <4 x float>*
store <4 x float> <float -1.000000e+07, float -1.000000e+07, float -1.000000e+07, float -1.000000e+07>, <4 x float>* %352
%353 = bitcast float* %343 to <4 x float>*
store <4 x float> <float -1.000000e+07, float -1.000000e+07, float -1.000000e+07, float -1.000000e+07>, <4 x float>* %353
br label %354
354: ; preds = %337, %339
br i1 %151, label %391, label %355
355: ; preds = %296, %354
%356 = phi i64 [ 0, %296 ], [ %146, %354 ]
br label %383
357: ; preds = %234, %357
%358 = phi i64 [ %380, %357 ], [ 0, %234 ]
%359 = phi float [ %379, %357 ], [ 0.000000e+00, %234 ]
%360 = phi i64 [ %381, %357 ], [ 0, %234 ]
%361 = getelementptr inbounds float, float* %17, i64 %358
%362 = load float, float* %361
%363 = fcmp ogt float %362, %359
%364 = select i1 %363, float %362, float %359
%365 = or i64 %358, 1
%366 = getelementptr inbounds float, float* %17, i64 %365
%367 = load float, float* %366
%368 = fcmp ogt float %367, %364
%369 = select i1 %368, float %367, float %364
%370 = or i64 %358, 2
%371 = getelementptr inbounds float, float* %17, i64 %370
%372 = load float, float* %371
%373 = fcmp ogt float %372, %369
%374 = select i1 %373, float %372, float %369
%375 = or i64 %358, 3
%376 = getelementptr inbounds float, float* %17, i64 %375
%377 = load float, float* %376
%378 = fcmp ogt float %377, %374
%379 = select i1 %378, float %377, float %374
%380 = add nuw nsw i64 %358, 4
%381 = add i64 %360, 4
%382 = icmp eq i64 %381, %143
br i1 %382, label %279, label %357
383: ; preds = %355, %383
%384 = phi i64 [ %389, %383 ], [ %356, %355 ]
%385 = getelementptr inbounds float, float* %17, i64 %384
%386 = load float, float* %385
%387 = fsub float %386, %295
%388 = getelementptr inbounds float, float* %15, i64 %384
store float %387, float* %388
store float -1.000000e+07, float* %385
%389 = add nuw nsw i64 %384, 1
%390 = icmp eq i64 %389, %124
br i1 %390, label %391, label %383
391: ; preds = %383, %354, %221, %233, %294
%392 = add nuw nsw i64 %153, 1
%393 = icmp eq i64 %392, %120
br i1 %393, label %209, label %152
394: ; preds = %417, %209
%395 = phi i32 [ 0, %209 ], [ %425, %417 ]
%396 = icmp sgt i32 %8, 0
br i1 %396, label %397, label %453
397: ; preds = %394
%398 = zext i32 %8 to i64
%399 = and i64 %398, 1
%400 = icmp eq i64 %399, 0
br i1 %400, label %413, label %401
401: ; preds = %397
%402 = add nsw i64 %398, -1
%403 = trunc i64 %402 to i32
%404 = shl i32 %403, %10
%405 = add nsw i32 %404, %395
%406 = sext i32 %405 to i64
%407 = getelementptr inbounds i32, i32* %22, i64 %406
%408 = load i32, i32* %407
%409 = and i64 %402, 4294967295
%410 = getelementptr inbounds i32, i32* %0, i64 %409
store i32 %408, i32* %410
%411 = getelementptr inbounds i32, i32* %24, i64 %406
%412 = load i32, i32* %411
br label %413
413: ; preds = %401, %397
%414 = phi i64 [ %398, %397 ], [ %402, %401 ]
%415 = phi i32 [ %395, %397 ], [ %412, %401 ]
%416 = icmp eq i32 %8, 1
br i1 %416, label %453, label %427
417: ; preds = %209, %417
%418 = phi i32 [ %420, %417 ], [ %18, %209 ]
%419 = phi i32 [ %425, %417 ], [ 0, %209 ]
%420 = add nsw i32 %418, -1
%421 = shl i32 %420, %10
%422 = add nsw i32 %421, %419
%423 = sext i32 %422 to i64
%424 = getelementptr inbounds i32, i32* %24, i64 %423
%425 = load i32, i32* %424
%426 = icmp sgt i32 %420, %8
br i1 %426, label %417, label %394
427: ; preds = %413, %427
%428 = phi i64 [ %441, %427 ], [ %414, %413 ]
%429 = phi i32 [ %451, %427 ], [ %415, %413 ]
%430 = add nsw i64 %428, -1
%431 = trunc i64 %430 to i32
%432 = shl i32 %431, %10
%433 = add nsw i32 %432, %429
%434 = sext i32 %433 to i64
%435 = getelementptr inbounds i32, i32* %22, i64 %434
%436 = load i32, i32* %435
%437 = and i64 %430, 4294967295
%438 = getelementptr inbounds i32, i32* %0, i64 %437
store i32 %436, i32* %438
%439 = getelementptr inbounds i32, i32* %24, i64 %434
%440 = load i32, i32* %439
%441 = add nsw i64 %428, -2
%442 = trunc i64 %441 to i32
%443 = shl i32 %442, %10
%444 = add nsw i32 %443, %440
%445 = sext i32 %444 to i64
%446 = getelementptr inbounds i32, i32* %22, i64 %445
%447 = load i32, i32* %446
%448 = and i64 %441, 4294967295
%449 = getelementptr inbounds i32, i32* %0, i64 %448
store i32 %447, i32* %449
%450 = getelementptr inbounds i32, i32* %24, i64 %445
%451 = load i32, i32* %450
%452 = icmp ugt i64 %430, 1
br i1 %452, label %427, label %453
453: ; preds = %413, %427, %394
tail call void @free(i8* %14)
tail call void @free(i8* %16)
tail call void @free(i8* %21)
tail call void @free(i8* %23)
tail call void @free(i8* %26)
tail call void @free(i8* %29)
ret void
}