// File: /workspace/github_c_makefile_star2_O1/thegenemyers[P]DASCRUBBER/align.c
// Function: iter_np
static int iter_np(char *A, int M, char *B, int N, Trace_Waves *wave, int mode, int dmax)
{ int  **PVF = wave->PVF; 
  int  **PHF = wave->PHF;
  int    D;
  int    del = M-N;

  { int  *F0, *F1, *F2;
    int  *HF;
    int   low, hgh;
    int   posl, posh;

#ifdef DEBUG_ALIGN
    printf("\n    BASE %ld,%ld: %d vs %d\n",A-wave->Aabs,B-wave->Babs,M,N);
    printf("    A = ");
    for (D = 0; D < M; D++)
      printf("%c",ToA[(int) A[D]]);
    printf("\n");
    printf("    B = ");
    for (D = 0; D < N; D++)
      printf("%c",ToA[(int) B[D]]);
    printf("\n");
#endif

    if (del >= 0)
      { low = 0;
        hgh = del;
      }
    else
      { low = del;
        hgh = 0;
      }

    posl = -dmax;
    posh =  dmax;
    if (wave->Aabs == wave->Babs)
      { if (B == A)
          { EPRINTF(EPLACE,"%s: self comparison starts on diagonal 0 (Compute_Trace)\n",Prog_Name);
            EXIT(-1);
          }
        else if (B < A)
          { if ((B-A)+1 > posl)
              posl = (B-A)+1;
          }
        else
          { if ((B-A)-1 < posh)
              posh = (B-A)-1;
          }
      }

    F1 = PVF[-2];
    F0 = PVF[-1];

    for (D = low-1; D <= hgh+1; D++)
      F1[D] = F0[D] = -2;
    F0[0] = -1;

    low += 1;
    hgh -= 1;

    for (D = 0; 1; D += 1)
      { int   k, i, j;
        int   am, ac, ap;
        char *a;

        if (D > dmax)
          { EPRINTF(EPLACE,"%s: %s\n",Prog_Name,TP_Align);
            EXIT(-1);
          }

        F2 = F1;
        F1 = F0;
        F0 = PVF[D];
        HF = PHF[D];

        if ((D & 0x1) == 0)
          { if (low > posl)
              low -= 1;
            if (hgh < posh)
              hgh += 1;
          }
        F0[hgh+1] = F0[low-1] = -2;

#define FS_MOVE(mdir,pdir)			\
  ac = F1[k]+1;					\
  if (ac < am)					\
    if (ap < am)				\
      { HF[k] = mdir;				\
        j = am;					\
      }						\
    else					\
      { HF[k] = pdir;				\
        j = ap;					\
      }						\
  else						\
    if (ap < ac)				\
      { HF[k] = 0;				\
        j = ac;					\
      }						\
    else					\
      { HF[k] = pdir;				\
        j = ap;					\
      }						\
						\
  if (N < i)					\
    while (j < N && B[j] == a[j])		\
      j += 1;					\
  else						\
    while (j < i && B[j] == a[j])		\
      j += 1;					\
  F0[k] = j;

        j = -2;
        a = A + hgh;
        i = M - hgh;
        for (k = hgh; k > del; k--)
          { ap = j+1;
            am = F2[k-1];
            FS_MOVE(-1,4)
            a -= 1;
            i += 1;
          }

        j = -2;
        a = A + low;
        i = M - low;
        for (k = low; k < del; k++)
          { ap = F2[k+1]+1;
            am = j;
            FS_MOVE(2,1)
            a += 1;
            i -= 1;
          }

        ap = F0[del+1]+1;
        am = j;
        FS_MOVE(2,4)

#ifdef DEBUG_AWAVE
        print_awave(F0,low,hgh);
        print_awave(HF,low,hgh);
#endif

        if (F0[del] >= N)
          break;
      }
  }

  { int   k, h, m, e, c;
    int   ap = (wave->Aabs-A)-1;
    int   bp = (B-wave->Babs)+1;

    PHF[0][0] = 3;

    c = N;
    k = del;
    e = PHF[D][k];
    PHF[D][k] = 3;

    if (mode == UPPERMOST)

      while (e != 3)
        { h = k+e;
          if (e > 1)
            h -= 3;
          else if (e == 0)
            D -= 1;
          else
            D -= 2;

          if (h < k)       // => e = -1 or 2,  UPPERMOST
            { char *a;
  
              a = A + k;
              if (k < 0)
                m = -k;
              else
                m = 0;
              if (PVF[D][h] <= c)
                c = PVF[D][h]-1;
              while (c >= m && a[c] == B[c])
                c -= 1;
              if (e == -1)  //  => edge is 2, others are 1, and 0
                { if (c <= PVF[D+2][k+1])
                    { e = 4;
                      h = k+1;
                      D = D+2;
                    }
                  else if (c == PVF[D+1][k])
                    { e = 0;
                      h = k;
                      D = D+1;
                    }
                  else
                    PVF[D][h] = c+1;
                }
              else      //   => edge is 0, others are 1, and 2 (if k != del), 0 (otherwise)
                { if (k == del)
                    m = D;
                  else
                    m = D-2;
                  if (c <= PVF[m][k+1])
                    { if (k == del)
                        e = 4;
                      else
                        e = 1;
                      h = k+1;
                      D = m;
                    }
                  else if (c == PVF[D-1][k])
                    { e = 0;
                      h = k;
                      D = D-1;
                    }
                  else
                    PVF[D][h] = c+1;
                }
            }

          m = PHF[D][h];
          PHF[D][h] = e;
          e = m;
          k = h;
        }

    else if (mode == LOWERMOST)

      while (e != 3)
        { h = k+e;
          if (e > 1)
            h -= 3;
          else if (e == 0)
            D -= 1;
          else
            D -= 2;

          if (h > k)       // => e = 1 or 4,   LOWERMOST
            { char *a;
  
              a = A + k;
              if (k < 0)
                m = -k;
              else
                m = 0;
              if (PVF[D][h] < c)
                c = PVF[D][h];
              while (c >= m && a[c] == B[c])
                c -= 1;
              if (e == 1)  //  => edge is 2, others are 1, and 0
                { if (c < PVF[D+2][k-1])
                    { e = 2;
                      h = k-1;
                      D = D+2;
                    }
                  else if (c == PVF[D+1][k])
                    { e = 0;
                      h = k;
                      D = D+1;
                    }
                  else
                    PVF[D][h] = c--;
                }
              else      //   => edge is 0, others are 1, and 2 (if k != del), 0 (otherwise)
                { if (k == del)
                    m = D;
                  else
                    m = D-2;
                  if (c < PVF[m][k-1])
                    { if (k == del)
                        e = 2;
                      else
                        e = -1;
                      h = k-1;
                      D = m;
                    }
                  else if (c == PVF[D-1][k])
                    { e = 0;
                      h = k;
                      D = D-1;
                    }
                  else
                    PVF[D][h] = c--;
                }
            }

          m = PHF[D][h];
          PHF[D][h] = e;
          e = m;
          k = h;
        }

    else //  mode == GREEDIEST

      while (e != 3)
        { h = k+e;
          if (e > 1)
            h -= 3;
          else if (e == 0)
            D -= 1;
          else
            D -= 2;

          m = PHF[D][h];
          PHF[D][h] = e;
          e = m;
          k = h;
        }

    k = D = 0;
    e = PHF[D][k];
    while (e != 3)
      { h = k-e;
        c = PVF[D][k];
        if (e > 1)
          h += 3;
        else if (e == 0)
          D += 1;
        else
          D += 2;
#ifdef DEBUG_SCRIPT
        if (h > k)
          printf("     D %d(%d)\n",(c-k)-(ap-1),c+bp);
        else if (h < k)
          printf("     I %d(%d)\n",c+(bp-1),(c+k)-ap);
        else
          printf("     %d S %d\n",(c+k)-(ap+1),c+(bp-1));
#endif
        if (h > k)
          *wave->Stop++ = bp+c;
        else if (h < k)
          *wave->Stop++ = ap-(c+k);
        k = h;
        e = PHF[D][h];
      }
  }

  return (D + abs(del));
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x98, %rsp
movl %ecx, %r14d
movl 0xd0(%rsp), %r11d
movq 0x20(%r8), %r13
xorl %r10d, %r10d
movl %esi, 0x3c(%rsp)
movl %esi, %eax
subl %ecx, %eax
movl %eax, 0xc(%rsp)
movl $0x0, %r15d
cmovnsl %eax, %r15d
movq 0x28(%r8), %rcx
movq %rcx, 0x20(%rsp)
cmovsl %eax, %r10d
movl %r11d, %eax
negl %eax
movl %eax, 0x1c(%rsp)
movq 0x10(%r8), %rcx
movq %r8, 0x90(%rsp)
movq 0x18(%r8), %rsi
movq %rcx, 0x60(%rsp)
cmpq %rsi, %rcx
movq %rdi, 0x28(%rsp)
movq %rsi, 0x88(%rsp)
movl %r9d, 0x74(%rsp)
je 0x10630
movl %r11d, %eax
movq %rax, 0x40(%rsp)
jmp 0x1066d
movq %rdx, %rax
subq %rdi, %rax
je 0x10dbc
jae 0x10658
movslq 0x1c(%rsp), %rcx
movl %r11d, %esi
movq %rsi, 0x40(%rsp)
cmpq %rcx, %rax
jl 0x1066d
incl %eax
movl %eax, 0x1c(%rsp)
jmp 0x10626
notq %rdi
addq %rdx, %rdi
movslq %r11d, %rax
cmpq %rax, %rdi
cmovgel %r11d, %edi
movq %rdi, 0x40(%rsp)
movq -0x10(%r13), %rax
movq -0x8(%r13), %r9
movq %r10, %rbx
leal -0x1(%r10), %ecx
leal 0x1(%r15), %esi
cmpl %esi, %ecx
jg 0x106b0
movslq %ecx, %rsi
leaq (%r9,%rsi,4), %rcx
leaq (%rax,%rsi,4), %rsi
movl %r15d, %edi
subl %ebx, %edi
addl $0x3, %edi
xorl %r8d, %r8d
movl $0xfffffffe, %r10d      # imm = 0xFFFFFFFE
movl %r10d, (%rcx,%r8,4)
movl %r10d, (%rsi,%r8,4)
incq %r8
cmpl %r8d, %edi
jne 0x106a0
movl $0xffffffff, (%r9)      # imm = 0xFFFFFFFF
testl %r11d, %r11d
js 0x109ae
movq %rbx, %rsi
decl %r15d
incl %esi
movslq 0xc(%rsp), %rcx
movq %rcx, 0x30(%rsp)
movslq %r14d, %r8
incl %r11d
movq %r11, 0x78(%rsp)
xorl %ebx, %ebx
movq %r14, 0x68(%rsp)
movq %r13, 0x48(%rsp)
movq %r9, 0x10(%rsp)
testb $0x1, %bl
jne 0x1070b
xorl %ecx, %ecx
cmpl 0x1c(%rsp), %esi
setg %cl
subl %ecx, %esi
xorl %ecx, %ecx
cmpl 0x40(%rsp), %r15d
setl %cl
addl %ecx, %r15d
movq (%r13,%rbx,8), %r9
movq 0x20(%rsp), %rcx
movq %rbx, 0x50(%rsp)
movq (%rcx,%rbx,8), %rdi
movq %rsi, 0x58(%rsp)
movslq %esi, %r13
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
movl %esi, -0x4(%r9,%r13,4)
movq %r15, 0x80(%rsp)
movslq %r15d, %rcx
movl %esi, 0x4(%r9,%rcx,4)
cmpl 0xc(%rsp), %ecx
jle 0x1080a
movl 0x3c(%rsp), %esi
subl %ecx, %esi
movq 0x28(%rsp), %r10
addq %rcx, %r10
movslq %esi, %rbx
movl $0xfffffffe, %ebp       # imm = 0xFFFFFFFE
leal 0x1(%rbp), %esi
movl -0x4(%rax,%rcx,4), %r12d
movq 0x10(%rsp), %r11
movl (%r11,%rcx,4), %r11d
leal 0x1(%r11), %r14d
cmpl %r12d, %r14d
jge 0x10792
xorl %r11d, %r11d
cmpl %r12d, %esi
setge %r11b
leal -0x1(%r11,%r11,4), %r15d
cmovgl %esi, %r12d
movl %r12d, %ebp
jmp 0x107a6
xorl %r15d, %r15d
cmpl %r11d, %ebp
setge %r15b
cmovll %r14d, %esi
shll $0x2, %r15d
movl %esi, %ebp
movq 0x68(%rsp), %r14
movl %r15d, (%rdi,%rcx,4)
cmpq %r8, %rbx
jle 0x107d3
cmpl %r14d, %ebp
jge 0x107f2
movslq %ebp, %rbp
movb (%rdx,%rbp), %sil
cmpb (%r10,%rbp), %sil
jne 0x107f2
incq %rbp
cmpq %rbp, %r8
jne 0x107bc
movl %r14d, %ebp
jmp 0x107f2
movslq %ebp, %rsi
cmpq %rsi, %rbx
jle 0x107f2
movb (%rdx,%rsi), %r11b
cmpb (%r10,%rsi), %r11b
jne 0x107f0
incq %rsi
cmpq %rbx, %rsi
jl 0x107db
movq %rbx, %rsi
movl %esi, %ebp
movl %ebp, (%r9,%rcx,4)
decq %rcx
decq %r10
incq %rbx
cmpq 0x30(%rsp), %rcx
jg 0x10760
movq 0x28(%rsp), %rcx
leaq (%rcx,%r13), %r10
movl 0x3c(%rsp), %ecx
movl %ecx, %ebx
subl %r13d, %ebx
movl $0xfffffffe, %ecx       # imm = 0xFFFFFFFE
cmpl 0xc(%rsp), %r13d
jge 0x108cd
movslq %ebx, %rbx
movl $0xfffffffe, %ecx       # imm = 0xFFFFFFFE
movl 0x4(%rax,%r13,4), %r12d
leal 0x1(%r12), %ebp
movq 0x10(%rsp), %rsi
movl (%rsi,%r13,4), %r11d
leal 0x1(%r11), %r15d
xorl %esi, %esi
cmpl %ecx, %r15d
jge 0x1085f
cmpl %ecx, %ebp
setl %sil
cmovgl %ebp, %ecx
incl %esi
jmp 0x1086d
cmpl %r11d, %r12d
setge %sil
cmovgel %ebp, %r15d
movl %r15d, %ecx
movl %esi, (%rdi,%r13,4)
cmpq %r8, %rbx
jle 0x10895
cmpl %r14d, %ecx
jge 0x108b3
movslq %ecx, %rcx
movb (%rdx,%rcx), %sil
cmpb (%r10,%rcx), %sil
jne 0x108b3
incq %rcx
cmpq %rcx, %r8
jne 0x1087e
movl %r14d, %ecx
jmp 0x108b3
movslq %ecx, %rsi
cmpq %rsi, %rbx
jle 0x108b3
movb (%rdx,%rsi), %cl
cmpb (%r10,%rsi), %cl
jne 0x108b1
incq %rsi
cmpq %rbx, %rsi
jl 0x1089d
movq %rbx, %rsi
movl %esi, %ecx
movl %ecx, (%r9,%r13,4)
incq %r13
incq %r10
decq %rbx
cmpq 0x30(%rsp), %r13
jl 0x10834
jmp 0x108d2
movq 0x58(%rsp), %r13
movq 0x30(%rsp), %rax
movl 0x4(%r9,%rax,4), %r15d
leal 0x1(%r15), %esi
movslq %r13d, %rax
movq 0x10(%rsp), %r11
movl (%r11,%rax,4), %r11d
leal 0x1(%r11), %r14d
cmpl %ecx, %r14d
jge 0x10908
xorl %r11d, %r11d
cmpl %ecx, %esi
setge %r11b
leal 0x2(%r11,%r11), %ebp
cmovgl %esi, %ecx
jmp 0x1091a
xorl %ebp, %ebp
cmpl %r11d, %r15d
setge %bpl
cmovll %r14d, %esi
shll $0x2, %ebp
movl %esi, %ecx
movq 0x48(%rsp), %r13
movl %ebp, (%rdi,%rax,4)
movq 0x68(%rsp), %r14
cmpl %r14d, %ebx
jle 0x1095d
cmpl %r14d, %ecx
movq 0x50(%rsp), %rbx
movq 0x78(%rsp), %r11
movq 0x80(%rsp), %r15
jge 0x10989
movslq %ecx, %rcx
movb (%rdx,%rcx), %sil
cmpb (%r10,%rcx), %sil
jne 0x10989
incq %rcx
cmpl %ecx, %r14d
jne 0x10946
movl %r14d, %ecx
jmp 0x10989
cmpl %ebx, %ecx
movq 0x78(%rsp), %r11
movq 0x80(%rsp), %r15
jge 0x10984
movslq %ecx, %rcx
movb (%rdx,%rcx), %sil
cmpb (%r10,%rcx), %sil
jne 0x10984
incq %rcx
cmpl %ecx, %ebx
jne 0x10971
movl %ebx, %ecx
movq 0x50(%rsp), %rbx
movl %ecx, (%r9,%rax,4)
movq 0x30(%rsp), %rax
cmpl %r14d, (%r9,%rax,4)
movq 0x58(%rsp), %rsi
jge 0x109b3
incq %rbx
movq 0x10(%rsp), %rax
cmpq %r11, %rbx
jne 0x106e9
callq 0x138e
movq 0x20(%rsp), %rax
movq (%rax), %rsi
movl $0x3, %ecx
movl %ecx, (%rsi)
movq 0x30(%rsp), %r8
movl (%rdi,%r8,4), %eax
movl %ecx, (%rdi,%r8,4)
movl 0x74(%rsp), %ecx
cmpl $0x1, %ecx
movq %rsi, 0x58(%rsp)
je 0x10b50
cmpl $-0x1, %ecx
jne 0x10cb7
cmpl $0x3, %eax
je 0x10cf7
movl 0xc(%rsp), %ecx
leal (%rax,%rcx), %edi
cmpl $0x2, %eax
jl 0x10a04
addl $-0x3, %edi
jmp 0x10a0f
testl %eax, %eax
je 0x10a0d
addl $-0x2, %ebx
jmp 0x10a0f
decl %ebx
cmpl %ecx, %edi
jle 0x10b17
movslq %ecx, %r8
movl %ecx, %r9d
negl %r9d
movq %rbx, %r10
movl %ecx, %ebx
sarl $0x1f, %ebx
andl %r9d, %ebx
movq %r10, %rsi
movslq %r10d, %r11
movq (%r13,%r11,8), %r15
movslq %edi, %r10
movl (%r15,%r10,4), %ebp
cmpl %r14d, %ebp
cmovll %ebp, %r14d
cmpl %ebx, %r14d
jl 0x10a92
movq %r15, 0x10(%rsp)
testl %ecx, %ecx
movl $0x0, %r15d
cmovgl %ecx, %r15d
movq %r14, %r9
movq 0x28(%rsp), %r14
addq %r8, %r14
movl %ecx, %ebp
notl %ebp
addl %r15d, %ebp
movl %r9d, %r15d
movb (%r14,%r15), %r12b
cmpb (%rdx,%r15), %r12b
jne 0x10a8a
leal -0x1(%r9), %r15d
cmpl %ebx, %r9d
movl %r15d, %r9d
jg 0x10a6c
movl %ebp, %r14d
jmp 0x10a8d
movq %r9, %r14
movq 0x10(%rsp), %r15
cmpl $0x1, %eax
movq %rsi, %rbx
jne 0x10ab2
movq 0x10(%r13,%r11,8), %rax
cmpl -0x4(%rax,%r8,4), %r14d
jge 0x10ae8
addl $0x2, %ebx
decl %ecx
movl $0x2, %eax
jmp 0x10b19
movq %r14, %r9
movq %rbx, %r14
addl $-0x2, %ebx
movl 0xc(%rsp), %ebp
cmpl %ebp, %ecx
cmovel %r14d, %ebx
movslq %ebx, %r14
movq (%r13,%r14,8), %r14
cmpl -0x4(%r14,%r8,4), %r9d
movq %r9, %r14
jge 0x10af7
xorl %eax, %eax
cmpl %ebp, %ecx
leal -0x1(%rcx), %ecx
sete %al
leal (%rax,%rax,2), %eax
decl %eax
jmp 0x10b19
movq 0x8(%r13,%r11,8), %rax
cmpl (%rax,%r8,4), %r14d
jne 0x10b0b
incl %ebx
jmp 0x10b07
movq -0x8(%r13,%r11,8), %r11
cmpl (%r11,%r8,4), %r14d
jne 0x10b42
movq %rsi, %rbx
decl %ebx
xorl %eax, %eax
jmp 0x10b19
movl %r14d, (%r15,%r10,4)
decl %r14d
movl $0x1, %eax
movl %edi, %ecx
movslq %ebx, %rdi
movq 0x20(%rsp), %r8
movq (%r8,%rdi,8), %rdi
movslq %ecx, %r8
movl (%rdi,%r8,4), %r9d
movl %eax, (%rdi,%r8,4)
movl %r9d, %eax
cmpl $0x3, %r9d
jne 0x109f7
jmp 0x10cf7
movl %r14d, (%r15,%r10,4)
decl %r14d
movl %edi, %ecx
movq %rsi, %rbx
jmp 0x10b19
cmpl $0x3, %eax
je 0x10cf7
movl 0xc(%rsp), %ecx
leal (%rax,%rcx), %r8d
cmpl $0x2, %eax
jl 0x10b6c
addl $-0x3, %r8d
jmp 0x10b77
testl %eax, %eax
je 0x10b75
addl $-0x2, %ebx
jmp 0x10b77
decl %ebx
cmpl %ecx, %r8d
jge 0x10c28
movslq %ecx, %r11
movl %ecx, %edi
negl %edi
movl %ecx, %ebp
sarl $0x1f, %ebp
andl %edi, %ebp
movq %rbx, %rsi
movslq %ebx, %rbx
movq (%r13,%rbx,8), %r9
movslq %r8d, %r10
movq %r14, %r15
movl (%r9,%r10,4), %r14d
leal -0x1(%r14), %edi
cmpl %r15d, %r14d
cmovgl %r15d, %edi
cmpl %ebp, %edi
jl 0x10bf0
testl %ecx, %ecx
movl $0x0, %r12d
cmovgl %ecx, %r12d
movq 0x28(%rsp), %r14
leaq (%r14,%r11), %r15
movl %ecx, %r14d
notl %r14d
addl %r12d, %r14d
movl %edi, %r12d
movb (%r15,%r12), %r13b
cmpb (%rdx,%r12), %r13b
jne 0x10beb
leal -0x1(%rdi), %r12d
cmpl %ebp, %edi
movl %r12d, %edi
jg 0x10bd0
movl %r14d, %edi
movq 0x48(%rsp), %r13
cmpl $-0x1, %eax
je 0x10c30
movq %rsi, %r14
leal -0x2(%rsi), %ebp
movl 0xc(%rsp), %r15d
cmpl %r15d, %ecx
cmovel %r14d, %ebp
movslq %ebp, %r14
movq (%r13,%r14,8), %r14
cmpl 0x4(%r14,%r11,4), %edi
jle 0x10c50
movq -0x8(%r13,%rbx,8), %rbx
cmpl (%rbx,%r11,4), %edi
jne 0x10c73
movq %rsi, %rbx
decl %ebx
jmp 0x10c4c
movl %r8d, %ecx
movl %r14d, %edi
jmp 0x10c8e
movq 0x10(%r13,%rbx,8), %rax
cmpl 0x4(%rax,%r11,4), %edi
jle 0x10c64
movq 0x8(%r13,%rbx,8), %rax
cmpl (%rax,%r11,4), %edi
jne 0x10c7c
movq %rsi, %rbx
incl %ebx
xorl %eax, %eax
jmp 0x10c8e
xorl %eax, %eax
cmpl %r15d, %ecx
leal 0x1(%rcx), %ecx
sete %al
leal (%rax,%rax,2), %eax
incl %eax
movl %ebp, %ebx
jmp 0x10c8e
movq %rsi, %rbx
addl $0x2, %ebx
incl %ecx
movl $0x4, %eax
jmp 0x10c8e
leal 0x1(%rdi), %ecx
movl %ecx, (%r9,%r10,4)
jmp 0x10c88
leal 0x1(%rdi), %eax
movl %eax, (%r9,%r10,4)
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
movl %r8d, %ecx
movq %rsi, %rbx
movslq %ebx, %r8
movq 0x20(%rsp), %r9
movq (%r9,%r8,8), %r8
movslq %ecx, %r9
movl (%r8,%r9,4), %r10d
movl %eax, (%r8,%r9,4)
movl %edi, %r14d
movl %r10d, %eax
cmpl $0x3, %r10d
jne 0x10b5d
jmp 0x10cf7
cmpl $0x3, %eax
je 0x10cf7
movl 0xc(%rsp), %ecx
addl %eax, %ecx
cmpl $0x2, %eax
jl 0x10ccc
addl $-0x3, %ecx
jmp 0x10cd7
testl %eax, %eax
je 0x10cd5
addl $-0x2, %ebx
jmp 0x10cd7
decl %ebx
movslq %ebx, %rdi
movq 0x20(%rsp), %r8
movq (%r8,%rdi,8), %rdi
movslq %ecx, %r8
movl (%rdi,%r8,4), %r9d
movl %eax, (%rdi,%r8,4)
movl %r9d, %eax
cmpl $0x3, %r9d
jne 0x10cc0
movq 0x58(%rsp), %rax
movl (%rax), %r8d
xorl %ecx, %ecx
cmpl $0x3, %r8d
je 0x10d9d
movq 0x28(%rsp), %rcx
notl %ecx
subl 0x88(%rsp), %edx
movq 0x60(%rsp), %rax
addl %ecx, %eax
movq %rax, 0x60(%rsp)
incl %edx
xorl %edi, %edi
xorl %esi, %esi
movl %esi, %eax
movq 0x90(%rsp), %r9
subl %r8d, %eax
cmpl $0x2, %r8d
jl 0x10d45
addl $0x3, %eax
movl %edi, %ecx
jmp 0x10d52
testl %r8d, %r8d
je 0x10d4f
leal 0x2(%rdi), %ecx
jmp 0x10d52
leal 0x1(%rdi), %ecx
movslq %edi, %rdi
movq (%r13,%rdi,8), %rdi
movslq %esi, %r8
movl (%rdi,%r8,4), %edi
cmpl %esi, %eax
jle 0x10d69
addl %edx, %edi
jmp 0x10d74
jge 0x10d80
addl %edi, %esi
movq 0x60(%rsp), %rdi
subl %esi, %edi
movq (%r9), %rsi
leaq 0x4(%rsi), %r8
movq %r8, (%r9)
movl %edi, (%rsi)
movslq %ecx, %rsi
movq 0x20(%rsp), %rdi
movq (%rdi,%rsi,8), %rsi
movslq %eax, %rdi
movl (%rsi,%rdi,4), %r8d
movl %ecx, %edi
movl %eax, %esi
cmpl $0x3, %r8d
jne 0x10d35
movl 0xc(%rsp), %edx
movl %edx, %eax
negl %eax
cmovsl %edx, %eax
addl %ecx, %eax
addq $0x98, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x13c0