// File: /workspace/github_c_makefile_star2_O1/barabo[P]advanced-shell-history/src/sqlite3.c
// Function: multiSelect
static int multiSelect(
  Parse *pParse,        /* Parsing context */
  Select *p,            /* The right-most of SELECTs to be coded */
  SelectDest *pDest     /* What to do with query results */
){
  int rc = SQLITE_OK;   /* Success code from a subroutine */
  Select *pPrior;       /* Another SELECT immediately to our left */
  Vdbe *v;              /* Generate code to this VDBE */
  SelectDest dest;      /* Alternative data destination */
  Select *pDelete = 0;  /* Chain of simple selects to delete */
  sqlite3 *db;          /* Database connection */
#ifndef SQLITE_OMIT_EXPLAIN
  int iSub1;            /* EQP id of left-hand query */
  int iSub2;            /* EQP id of right-hand query */
#endif

  /* Make sure there is no ORDER BY or LIMIT clause on prior SELECTs.  Only
  ** the last (right-most) SELECT in the series may have an ORDER BY or LIMIT.
  */
  assert( p && p->pPrior );  /* Calling function guarantees this much */
  db = pParse->db;
  pPrior = p->pPrior;
  assert( pPrior->pRightmost!=pPrior );
  assert( pPrior->pRightmost==p->pRightmost );
  dest = *pDest;
  if( pPrior->pOrderBy ){
    sqlite3ErrorMsg(pParse,"ORDER BY clause should come after %s not before",
      selectOpName(p->op));
    rc = 1;
    goto multi_select_end;
  }
  if( pPrior->pLimit ){
    sqlite3ErrorMsg(pParse,"LIMIT clause should come after %s not before",
      selectOpName(p->op));
    rc = 1;
    goto multi_select_end;
  }

  v = sqlite3GetVdbe(pParse);
  assert( v!=0 );  /* The VDBE already created by calling function */

  /* Create the destination temporary table if necessary
  */
  if( dest.eDest==SRT_EphemTab ){
    assert( p->pEList );
    sqlite3VdbeAddOp2(v, OP_OpenEphemeral, dest.iSDParm, p->pEList->nExpr);
    sqlite3VdbeChangeP5(v, BTREE_UNORDERED);
    dest.eDest = SRT_Table;
  }

  /* Make sure all SELECTs in the statement have the same number of elements
  ** in their result sets.
  */
  assert( p->pEList && pPrior->pEList );
  if( p->pEList->nExpr!=pPrior->pEList->nExpr ){
    if( p->selFlags & SF_Values ){
      sqlite3ErrorMsg(pParse, "all VALUES must have the same number of terms");
    }else{
      sqlite3ErrorMsg(pParse, "SELECTs to the left and right of %s"
        " do not have the same number of result columns", selectOpName(p->op));
    }
    rc = 1;
    goto multi_select_end;
  }

  /* Compound SELECTs that have an ORDER BY clause are handled separately.
  */
  if( p->pOrderBy ){
    return multiSelectOrderBy(pParse, p, pDest);
  }

  /* Generate code for the left and right SELECT statements.
  */
  switch( p->op ){
    case TK_ALL: {
      int addr = 0;
      int nLimit;
      assert( !pPrior->pLimit );
      pPrior->iLimit = p->iLimit;
      pPrior->iOffset = p->iOffset;
      pPrior->pLimit = p->pLimit;
      pPrior->pOffset = p->pOffset;
      explainSetInteger(iSub1, pParse->iNextSelectId);
      rc = sqlite3Select(pParse, pPrior, &dest);
      p->pLimit = 0;
      p->pOffset = 0;
      if( rc ){
        goto multi_select_end;
      }
      p->pPrior = 0;
      p->iLimit = pPrior->iLimit;
      p->iOffset = pPrior->iOffset;
      if( p->iLimit ){
        addr = sqlite3VdbeAddOp1(v, OP_IfZero, p->iLimit);
        VdbeComment((v, "Jump ahead if LIMIT reached"));
      }
      explainSetInteger(iSub2, pParse->iNextSelectId);
      rc = sqlite3Select(pParse, p, &dest);
      testcase( rc!=SQLITE_OK );
      pDelete = p->pPrior;
      p->pPrior = pPrior;
      p->nSelectRow += pPrior->nSelectRow;
      if( pPrior->pLimit
       && sqlite3ExprIsInteger(pPrior->pLimit, &nLimit)
       && nLimit>0 && p->nSelectRow > (u64)nLimit 
      ){
        p->nSelectRow = nLimit;
      }
      if( addr ){
        sqlite3VdbeJumpHere(v, addr);
      }
      break;
    }
    case TK_EXCEPT:
    case TK_UNION: {
      int unionTab;    /* Cursor number of the temporary table holding result */
      u8 op = 0;       /* One of the SRT_ operations to apply to self */
      int priorOp;     /* The SRT_ operation to apply to prior selects */
      Expr *pLimit, *pOffset; /* Saved values of p->nLimit and p->nOffset */
      int addr;
      SelectDest uniondest;

      testcase( p->op==TK_EXCEPT );
      testcase( p->op==TK_UNION );
      priorOp = SRT_Union;
      if( dest.eDest==priorOp && ALWAYS(!p->pLimit &&!p->pOffset) ){
        /* We can reuse a temporary table generated by a SELECT to our
        ** right.
        */
        assert( p->pRightmost!=p );  /* Can only happen for leftward elements
                                     ** of a 3-way or more compound */
        assert( p->pLimit==0 );      /* Not allowed on leftward elements */
        assert( p->pOffset==0 );     /* Not allowed on leftward elements */
        unionTab = dest.iSDParm;
      }else{
        /* We will need to create our own temporary table to hold the
        ** intermediate results.
        */
        unionTab = pParse->nTab++;
        assert( p->pOrderBy==0 );
        addr = sqlite3VdbeAddOp2(v, OP_OpenEphemeral, unionTab, 0);
        assert( p->addrOpenEphm[0] == -1 );
        p->addrOpenEphm[0] = addr;
        p->pRightmost->selFlags |= SF_UsesEphemeral;
        assert( p->pEList );
      }

      /* Code the SELECT statements to our left
      */
      assert( !pPrior->pOrderBy );
      sqlite3SelectDestInit(&uniondest, priorOp, unionTab);
      explainSetInteger(iSub1, pParse->iNextSelectId);
      rc = sqlite3Select(pParse, pPrior, &uniondest);
      if( rc ){
        goto multi_select_end;
      }

      /* Code the current SELECT statement
      */
      if( p->op==TK_EXCEPT ){
        op = SRT_Except;
      }else{
        assert( p->op==TK_UNION );
        op = SRT_Union;
      }
      p->pPrior = 0;
      pLimit = p->pLimit;
      p->pLimit = 0;
      pOffset = p->pOffset;
      p->pOffset = 0;
      uniondest.eDest = op;
      explainSetInteger(iSub2, pParse->iNextSelectId);
      rc = sqlite3Select(pParse, p, &uniondest);
      testcase( rc!=SQLITE_OK );
      /* Query flattening in sqlite3Select() might refill p->pOrderBy.
      ** Be sure to delete p->pOrderBy, therefore, to avoid a memory leak. */
      sqlite3ExprListDelete(db, p->pOrderBy);
      pDelete = p->pPrior;
      p->pPrior = pPrior;
      p->pOrderBy = 0;
      if( p->op==TK_UNION ) p->nSelectRow += pPrior->nSelectRow;
      sqlite3ExprDelete(db, p->pLimit);
      p->pLimit = pLimit;
      p->pOffset = pOffset;
      p->iLimit = 0;
      p->iOffset = 0;

      /* Convert the data in the temporary table into whatever form
      ** it is that we currently need.
      */
      assert( unionTab==dest.iSDParm || dest.eDest!=priorOp );
      if( dest.eDest!=priorOp ){
        int iCont, iBreak, iStart;
        assert( p->pEList );
        if( dest.eDest==SRT_Output ){
          Select *pFirst = p;
          while( pFirst->pPrior ) pFirst = pFirst->pPrior;
          generateColumnNames(pParse, 0, pFirst->pEList);
        }
        iBreak = sqlite3VdbeMakeLabel(v);
        iCont = sqlite3VdbeMakeLabel(v);
        computeLimitRegisters(pParse, p, iBreak);
        sqlite3VdbeAddOp2(v, OP_Rewind, unionTab, iBreak);
        iStart = sqlite3VdbeCurrentAddr(v);
        selectInnerLoop(pParse, p, p->pEList, unionTab, p->pEList->nExpr,
                        0, 0, &dest, iCont, iBreak);
        sqlite3VdbeResolveLabel(v, iCont);
        sqlite3VdbeAddOp2(v, OP_Next, unionTab, iStart);
        sqlite3VdbeResolveLabel(v, iBreak);
        sqlite3VdbeAddOp2(v, OP_Close, unionTab, 0);
      }
      break;
    }
    default: assert( p->op==TK_INTERSECT ); {
      int tab1, tab2;
      int iCont, iBreak, iStart;
      Expr *pLimit, *pOffset;
      int addr;
      SelectDest intersectdest;
      int r1;

      /* INTERSECT is different from the others since it requires
      ** two temporary tables.  Hence it has its own case.  Begin
      ** by allocating the tables we will need.
      */
      tab1 = pParse->nTab++;
      tab2 = pParse->nTab++;
      assert( p->pOrderBy==0 );

      addr = sqlite3VdbeAddOp2(v, OP_OpenEphemeral, tab1, 0);
      assert( p->addrOpenEphm[0] == -1 );
      p->addrOpenEphm[0] = addr;
      p->pRightmost->selFlags |= SF_UsesEphemeral;
      assert( p->pEList );

      /* Code the SELECTs to our left into temporary table "tab1".
      */
      sqlite3SelectDestInit(&intersectdest, SRT_Union, tab1);
      explainSetInteger(iSub1, pParse->iNextSelectId);
      rc = sqlite3Select(pParse, pPrior, &intersectdest);
      if( rc ){
        goto multi_select_end;
      }

      /* Code the current SELECT into temporary table "tab2"
      */
      addr = sqlite3VdbeAddOp2(v, OP_OpenEphemeral, tab2, 0);
      assert( p->addrOpenEphm[1] == -1 );
      p->addrOpenEphm[1] = addr;
      p->pPrior = 0;
      pLimit = p->pLimit;
      p->pLimit = 0;
      pOffset = p->pOffset;
      p->pOffset = 0;
      intersectdest.iSDParm = tab2;
      explainSetInteger(iSub2, pParse->iNextSelectId);
      rc = sqlite3Select(pParse, p, &intersectdest);
      testcase( rc!=SQLITE_OK );
      pDelete = p->pPrior;
      p->pPrior = pPrior;
      if( p->nSelectRow>pPrior->nSelectRow ) p->nSelectRow = pPrior->nSelectRow;
      sqlite3ExprDelete(db, p->pLimit);
      p->pLimit = pLimit;
      p->pOffset = pOffset;

      /* Generate code to take the intersection of the two temporary
      ** tables.
      */
      assert( p->pEList );
      if( dest.eDest==SRT_Output ){
        Select *pFirst = p;
        while( pFirst->pPrior ) pFirst = pFirst->pPrior;
        generateColumnNames(pParse, 0, pFirst->pEList);
      }
      iBreak = sqlite3VdbeMakeLabel(v);
      iCont = sqlite3VdbeMakeLabel(v);
      computeLimitRegisters(pParse, p, iBreak);
      sqlite3VdbeAddOp2(v, OP_Rewind, tab1, iBreak);
      r1 = sqlite3GetTempReg(pParse);
      iStart = sqlite3VdbeAddOp2(v, OP_RowKey, tab1, r1);
      sqlite3VdbeAddOp4Int(v, OP_NotFound, tab2, iCont, r1, 0);
      sqlite3ReleaseTempReg(pParse, r1);
      selectInnerLoop(pParse, p, p->pEList, tab1, p->pEList->nExpr,
                      0, 0, &dest, iCont, iBreak);
      sqlite3VdbeResolveLabel(v, iCont);
      sqlite3VdbeAddOp2(v, OP_Next, tab1, iStart);
      sqlite3VdbeResolveLabel(v, iBreak);
      sqlite3VdbeAddOp2(v, OP_Close, tab2, 0);
      sqlite3VdbeAddOp2(v, OP_Close, tab1, 0);
      break;
    }
  }

  explainComposite(pParse, p->op, iSub1, iSub2, p->op!=TK_ALL);

  /* Compute collating sequences used by 
  ** temporary tables needed to implement the compound select.
  ** Attach the KeyInfo structure to all temporary tables.
  **
  ** This section is run by the right-most SELECT statement only.
  ** SELECT statements to the left always skip this part.  The right-most
  ** SELECT might also skip this part if it has no ORDER BY clause and
  ** no temp tables are required.
  */
  if( p->selFlags & SF_UsesEphemeral ){
    int i;                        /* Loop counter */
    KeyInfo *pKeyInfo;            /* Collating sequence for the result set */
    Select *pLoop;                /* For looping through SELECT statements */
    CollSeq **apColl;             /* For looping through pKeyInfo->aColl[] */
    int nCol;                     /* Number of columns in result set */

    assert( p->pRightmost==p );
    nCol = p->pEList->nExpr;
    pKeyInfo = sqlite3KeyInfoAlloc(db, nCol);
    if( !pKeyInfo ){
      rc = SQLITE_NOMEM;
      goto multi_select_end;
    }
    for(i=0, apColl=pKeyInfo->aColl; i<nCol; i++, apColl++){
      *apColl = multiSelectCollSeq(pParse, p, i);
      if( 0==*apColl ){
        *apColl = db->pDfltColl;
      }
    }

    for(pLoop=p; pLoop; pLoop=pLoop->pPrior){
      for(i=0; i<2; i++){
        int addr = pLoop->addrOpenEphm[i];
        if( addr<0 ){
          /* If [0] is unused then [1] is also unused.  So we can
          ** always safely abort as soon as the first unused slot is found */
          assert( pLoop->addrOpenEphm[1]<0 );
          break;
        }
        sqlite3VdbeChangeP2(v, addr, nCol);
        sqlite3VdbeChangeP4(v, addr, (char*)pKeyInfo, P4_KEYINFO);
        pLoop->addrOpenEphm[i] = -1;
      }
    }
    sqlite3DbFree(db, pKeyInfo);
  }

multi_select_end:
  pDest->iSdst = dest.iSdst;
  pDest->nSdst = dest.nSdst;
  sqlite3SelectDelete(db, pDelete);
  return rc;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xe8, %rsp
movq %rdx, %r12
movq (%rdi), %r15
movq 0x50(%rsi), %r14
movups (%rdx), %xmm0
movaps %xmm0, -0xb0(%rbp)
cmpq $0x0, 0x48(%r14)
je 0x50757
movb 0x8(%rsi), %al
addb $-0x71, %al
cmpb $0x2, %al
ja 0x5077e
movzbl %al, %eax
leaq 0x431a7(%rip), %rcx     # 0x938f8
movq (%rcx,%rax,8), %rdx
jmp 0x50785
cmpq $0x0, 0x68(%r14)
je 0x50791
movb 0x8(%rsi), %al
addb $-0x71, %al
cmpb $0x2, %al
ja 0x509b0
movzbl %al, %eax
leaq 0x43183(%rip), %rcx     # 0x938f8
movq (%rcx,%rax,8), %rdx
jmp 0x509b7
leaq 0x2b2d7(%rip), %rdx     # 0x7ba5c
leaq 0x2b1d8(%rip), %rsi     # 0x7b964
jmp 0x509be
movq %rdi, -0x38(%rbp)
movq %rsi, -0x30(%rbp)
callq 0x45b57
movq -0x30(%rbp), %r9
movq %rax, %r13
cmpb $0x9, -0xb0(%rbp)
jne 0x507ea
movl -0xac(%rbp), %edx
movq (%r9), %rax
movl (%rax), %ecx
movq %r13, %rdi
movl $0x33, %esi
xorl %r8d, %r8d
callq 0x45b9e
movq 0x8(%r13), %rax
testq %rax, %rax
je 0x507df
movslq 0x34(%r13), %rcx
leaq (%rcx,%rcx,2), %rcx
movb $0x8, -0x15(%rax,%rcx,8)
movb $0x8, -0xb0(%rbp)
movq -0x30(%rbp), %r9
movq (%r9), %rax
movl (%rax), %eax
movq (%r14), %rcx
cmpl (%rcx), %eax
jne 0x50a03
cmpq $0x0, 0x48(%r9)
je 0x50a45
movq -0x38(%rbp), %rax
movq (%rax), %r15
movq 0x10(%rax), %rbx
movq %rbx, %rdi
callq 0x4c4bf
movq %rax, -0xe8(%rbp)
movq %rbx, -0x50(%rbp)
movq %rbx, %rdi
callq 0x4c4bf
movq -0x30(%rbp), %rsi
movl %eax, -0x90(%rbp)
movb 0x8(%rsi), %r13b
movq 0x50(%rsi), %rax
movq %rax, -0x58(%rbp)
movq 0x48(%rsi), %r14
movl (%r14), %ebx
cmpb $0x71, %r13b
movq %r15, -0x40(%rbp)
movq %r12, -0x88(%rbp)
je 0x50864
cmpb $0x0, 0x50(%r15)
je 0x5139f
movq %r14, -0x48(%rbp)
leal (,%rbx,4), %esi
movq %r15, %rdi
callq 0x115e9
movq $0x0, -0xd0(%rbp)
testq %rax, %rax
movq %rbx, -0x100(%rbp)
movq %rax, -0x78(%rbp)
movb %r13b, -0x60(%rbp)
je 0x50adb
movl %ebx, %ecx
movq %rcx, -0x80(%rbp)
testl %ebx, %ebx
movq -0x50(%rbp), %r12
movq -0x48(%rbp), %rcx
jle 0x508d1
movq 0x8(%rcx), %rdi
movq -0x80(%rbp), %rcx
leaq (,%rcx,4), %rcx
xorl %edx, %edx
movzwl 0x1a(%rdi,%rdx,8), %esi
decl %esi
movl %esi, (%rax,%rdx)
addq $0x4, %rdx
cmpq %rdx, %rcx
jne 0x508be
testl %ebx, %ebx
setle %r14b
movq %r15, %rdi
movl %ebx, %esi
callq 0x35fcd
movq %rax, %rbx
testq %rax, %rax
sete %al
orb %r14b, %al
movq %rbx, -0x70(%rbp)
jne 0x50b87
shlq $0x2, -0x80(%rbp)
xorl %r13d, %r13d
xorl %r15d, %r15d
movq -0x30(%rbp), %rcx
movq -0x48(%rbp), %rsi
movq 0x8(%rsi), %rax
movq (%rax,%r13,8), %r14
testb $0x1, 0x3(%r14)
jne 0x50961
movq -0x78(%rbp), %rax
movl (%rax,%r13), %edx
movq -0x38(%rbp), %rbx
movq %rbx, %rdi
movq %rcx, %rsi
callq 0x56460
movq %rax, %r12
testq %rax, %rax
jne 0x50940
movq -0x40(%rbp), %rax
movq 0x10(%rax), %r12
movq (%r12), %rdx
movq %rbx, %rdi
movq %r14, %rsi
callq 0x48127
movq -0x48(%rbp), %rsi
movq 0x8(%rsi), %rcx
movq %rax, (%rcx,%r13,8)
movq -0x70(%rbp), %rbx
jmp 0x50974
movq -0x38(%rbp), %rdi
movq %r14, %rsi
callq 0x4b095
movq %rax, %r12
movq -0x48(%rbp), %rsi
movq %r12, 0x18(%rbx,%r13,2)
movq 0x8(%rsi), %rax
movb 0x18(%rax,%r13,8), %al
movq 0x10(%rbx), %rcx
movb %al, (%rcx,%r15)
incq %r15
addq $0x4, %r13
cmpq %r13, -0x80(%rbp)
movq -0x30(%rbp), %rcx
jne 0x5090a
movq -0x40(%rbp), %r15
movq -0x50(%rbp), %r12
movb -0x60(%rbp), %r13b
jmp 0x50b8f
leaq 0x2b0a5(%rip), %rdx     # 0x7ba5c
leaq 0x2afd6(%rip), %rsi     # 0x7b994
xorl %ebx, %ebx
xorl %eax, %eax
callq 0x11724
movl $0x1, %r14d
movl -0xa8(%rbp), %eax
movl %eax, 0x8(%r12)
movl -0xa4(%rbp), %eax
movl %eax, 0xc(%r12)
movq %r15, %rdi
movq %rbx, %rsi
callq 0x340e4
movl %r14d, %eax
addq $0xe8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
testb $-0x80, 0xa(%r9)
jne 0x50a2f
movb 0x8(%r9), %al
addb $-0x71, %al
cmpb $0x2, %al
movq -0x38(%rbp), %rdi
ja 0x50ac8
movzbl %al, %eax
leaq 0x42ed2(%rip), %rcx     # 0x938f8
movq (%rcx,%rax,8), %rdx
jmp 0x50acf
leaq 0x2af8b(%rip), %rsi     # 0x7b9c1
xorl %ebx, %ebx
movq -0x38(%rbp), %rdi
xorl %eax, %eax
callq 0x11724
jmp 0x509c7
movzbl 0x8(%r9), %eax
cmpl $0x70, %eax
movq %r15, -0x48(%rbp)
je 0x50af0
cmpl $0x72, %eax
je 0x50af0
cmpl $0x71, %eax
jne 0x5146d
movq %r12, %r15
movl 0xc(%r9), %eax
movl %eax, 0xc(%r14)
movl 0x10(%r9), %eax
movl %eax, 0x10(%r14)
movq 0x68(%r9), %rax
movq %rax, 0x68(%r14)
movq 0x70(%r9), %rax
movq %rax, 0x70(%r14)
movq -0x38(%rbp), %rdi
movl 0x214(%rdi), %ebx
leaq -0xb0(%rbp), %rdx
movq %r14, %rsi
callq 0x3ba12
movq -0x30(%rbp), %rsi
xorl %r12d, %r12d
xorps %xmm0, %xmm0
movups %xmm0, 0x68(%rsi)
testl %eax, %eax
movl %ebx, -0x80(%rbp)
je 0x516df
xorl %ebx, %ebx
movl %eax, %r14d
jmp 0x51923
leaq 0x2af8d(%rip), %rdx     # 0x7ba5c
leaq 0x2af19(%rip), %rsi     # 0x7b9ef
jmp 0x509be
movq $0x0, -0x70(%rbp)
movq -0x30(%rbp), %rcx
movq -0x50(%rbp), %r12
jmp 0x50b8b
cmpb $0x1, -0xb0(%rbp)
jne 0x50b0b
cmpq $0x0, 0x68(%r9)
jne 0x50b0b
cmpq $0x0, 0x70(%r9)
je 0x51906
movq -0x38(%rbp), %rbx
movl 0x54(%rbx), %edx
leal 0x1(%rdx), %eax
movl %eax, 0x54(%rbx)
movq %r13, %rdi
movl $0x33, %esi
movq %rdx, -0x40(%rbp)
xorl %ecx, %ecx
xorl %r8d, %r8d
movq %r9, %r15
callq 0x45b9e
movl %eax, 0x14(%r15)
movq 0x60(%r15), %rax
movq -0x48(%rbp), %r15
orw $0x8, 0xa(%rax)
leaq -0xc0(%rbp), %rdx
movw $0x1, (%rdx)
movq -0x40(%rbp), %rax
movl %eax, 0x4(%rdx)
movq $0x0, 0x8(%rdx)
movl 0x214(%rbx), %eax
movl %eax, -0x80(%rbp)
movq %rbx, %rdi
movq %r14, %rsi
callq 0x3ba12
testl %eax, %eax
je 0x514e5
xorl %ebx, %ebx
movl %eax, %r14d
movq -0x30(%rbp), %rsi
jmp 0x518f9
movq -0x30(%rbp), %rcx
movq -0x48(%rbp), %rsi
movq %rsi, 0x48(%rcx)
movq -0x38(%rbp), %r14
movq (%r14), %rdi
xorl %edx, %edx
movq %rcx, %rbx
callq 0x48556
movq -0x58(%rbp), %rcx
movq %rax, 0x48(%rcx)
cmpb $0x71, %r13b
jne 0x50bbd
xorl %r14d, %r14d
movq %rbx, %r15
jmp 0x50c47
movq (%rbx), %rax
movl (%rax), %ebx
movl 0x58(%r14), %eax
leal (%rax,%rbx), %ecx
incl %ecx
incl %eax
movl %ecx, 0x58(%r14)
movq %r12, %rdi
movl $0x15, %esi
xorl %edx, %edx
movq %rax, -0xd0(%rbp)
movl %eax, %ecx
xorl %r8d, %r8d
callq 0x45b9e
movq %r15, %rdi
movl %ebx, %esi
callq 0x35fcd
movq %rax, %r14
testq %rax, %rax
setne %al
testl %ebx, %ebx
setg %cl
andb %al, %cl
cmpb $0x1, %cl
jne 0x50c43
movl %ebx, %r15d
xorl %ebx, %ebx
movq -0x30(%rbp), %r12
movq -0x38(%rbp), %r13
movq %r13, %rdi
movq %r12, %rsi
movl %ebx, %edx
callq 0x56460
movq %rax, 0x18(%r14,%rbx,8)
movq 0x10(%r14), %rax
movb $0x0, (%rax,%rbx)
incq %rbx
cmpq %rbx, %r15
jne 0x50c18
movq %r12, %r15
movb -0x60(%rbp), %r13b
jmp 0x50c47
movq -0x30(%rbp), %r15
movq $0x0, 0x50(%r15)
movq 0x48(%r15), %rdx
leaq 0x2a46e(%rip), %rcx     # 0x7b0c8
movq -0x38(%rbp), %r12
movq %r12, %rdi
movq %r15, %rsi
callq 0x4b85f
movq -0x58(%rbp), %rax
cmpq $0x0, 0x50(%rax)
jne 0x50c8b
movq -0x58(%rbp), %rsi
movq 0x48(%rsi), %rdx
leaq 0x2a445(%rip), %rcx     # 0x7b0c8
movq %r12, %rdi
callq 0x4b85f
cmpb $0x71, %r13b
setne %bl
movq %r12, %rdi
movq %r15, %rsi
movq -0xe8(%rbp), %rdx
callq 0x51c3c
movl 0xc(%r15), %eax
testl %eax, %eax
sete %cl
xorl %r13d, %r13d
orb %bl, %cl
movl $0x0, %ecx
movq %rcx, -0xc8(%rbp)
movl $0x0, -0x68(%rbp)
movq %r12, %rbx
movq %r15, %r12
jne 0x50d2c
movl 0x58(%rbx), %r13d
leal 0x1(%r13), %r8d
addl $0x2, %r13d
movl %r13d, 0x58(%rbx)
movl 0x10(%r12), %ecx
leal 0x1(%rcx), %edx
testl %ecx, %ecx
cmovel %eax, %edx
movq -0x50(%rbp), %r15
movq %r15, %rdi
movl $0x1c, %esi
movl %r8d, %r12d
movl %r8d, %ecx
xorl %r8d, %r8d
callq 0x45b9e
movq %r15, %rdi
movl $0x1c, %esi
movl %r12d, -0x68(%rbp)
movl %r12d, %edx
movq %r13, -0xc8(%rbp)
movl %r13d, %ecx
xorl %r13d, %r13d
xorl %r8d, %r8d
callq 0x45b9e
movq -0x30(%rbp), %r12
movq 0x68(%r12), %rsi
movq -0x40(%rbp), %r15
movq %r15, %rdi
callq 0x34068
movq %r13, 0x68(%r12)
movq 0x70(%r12), %rsi
movq %r15, %rdi
callq 0x34068
movq %r13, 0x70(%r12)
movl 0x58(%rbx), %eax
leal 0x1(%rax), %r15d
leal 0x2(%rax), %ecx
movl %ecx, -0x48(%rbp)
leal 0x3(%rax), %ecx
movl %ecx, -0x80(%rbp)
leal 0x4(%rax), %edx
movl %edx, -0x98(%rbp)
leal 0x5(%rax), %edx
movl %edx, -0x64(%rbp)
addl $0x6, %eax
movq %rax, -0xd8(%rbp)
movl %eax, 0x58(%rbx)
movw $0xa, %ax
leaq -0xc0(%rbp), %rdx
movw %ax, (%rdx)
movl %r15d, 0x4(%rdx)
movq %r13, 0x8(%rdx)
leaq -0x110(%rbp), %rdx
movw %ax, (%rdx)
movl %ecx, 0x4(%rdx)
movq $0x0, -0xe0(%rbp)
movq %r13, 0x8(%rdx)
movq -0x50(%rbp), %r13
movq %r13, %rdi
movl $0xe, %esi
xorl %edx, %edx
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0x45b9e
movl %eax, -0xec(%rbp)
movl 0x34(%r13), %eax
movl %eax, -0xf4(%rbp)
movq -0x58(%rbp), %rsi
movl -0x68(%rbp), %eax
movl %eax, 0xc(%rsi)
movl 0x214(%rbx), %eax
movl %eax, -0xf8(%rbp)
movq %rbx, %rdi
leaq -0xc0(%rbp), %rdx
callq 0x3ba12
movq %r13, %rdi
movl $0x15, %esi
movl $0x1, %edx
movl -0x48(%rbp), %ecx
xorl %r8d, %r8d
callq 0x45b9e
movq %r13, %rdi
movl $0x11, %esi
movl %r15d, -0x68(%rbp)
movl %r15d, %edx
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0x45b9e
movl 0x34(%r13), %eax
movl %eax, -0xf0(%rbp)
movq 0xc(%r12), %r15
movq -0xc8(%rbp), %rax
movl %eax, 0xc(%r12)
movl $0x0, 0x10(%r12)
movl 0x214(%rbx), %eax
movl %eax, -0xc8(%rbp)
movq %rbx, %rdi
movq %r12, %rsi
leaq -0x110(%rbp), %rdx
callq 0x3ba12
movq %r15, 0xc(%r12)
movq %r13, %rdi
movl $0x15, %esi
movl $0x1, %edx
movl -0x98(%rbp), %ecx
xorl %r8d, %r8d
callq 0x45b9e
movq %r13, %rdi
movl $0x11, %esi
movl -0x80(%rbp), %edx
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0x45b9e
subq $0x8, %rsp
movq %rbx, %rdi
movq %r12, %rsi
leaq -0xc0(%rbp), %rdx
movq -0x88(%rbp), %rcx
movl -0x64(%rbp), %r8d
movq -0xd0(%rbp), %r12
movl %r12d, %r9d
movq -0xe8(%rbp), %r13
pushq %r13
pushq $-0x10
pushq %r14
callq 0x564c6
addq $0x20, %rsp
movl %eax, %r15d
movb -0x60(%rbp), %bl
andb $-0x2, %bl
cmpb $0x70, %bl
jne 0x50f2e
subq $0x8, %rsp
leaq -0x110(%rbp), %rdx
movq -0x38(%rbp), %rdi
movq -0x30(%rbp), %rsi
movq -0x88(%rbp), %rcx
movq -0xd8(%rbp), %r8
movl %r12d, %r9d
pushq %r13
pushq $-0x11
pushq %r14
callq 0x564c6
addq $0x20, %rsp
movq %rax, -0xe0(%rbp)
cmpb $0x72, %bl
jne 0x50f55
movq -0x50(%rbp), %r12
movq %r12, %rdi
movl $0xe, %esi
xorl %edx, %edx
movl %r13d, %ecx
xorl %r8d, %r8d
callq 0x45b9e
movl %eax, %r14d
movq -0x30(%rbp), %rcx
jmp 0x50fcd
movq -0x50(%rbp), %r12
movq %r12, %rdi
movl $0x27, %esi
movl -0x98(%rbp), %edx
movl %r13d, %ecx
xorl %r8d, %r8d
callq 0x45b9e
movl %eax, %r14d
movq %r12, %rdi
movl $0xf, %esi
movq -0xd8(%rbp), %rdx
movq -0xe0(%rbp), %rcx
xorl %r8d, %r8d
callq 0x45b9e
movq %r12, %rdi
movl $0x11, %esi
movl -0x80(%rbp), %edx
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0x45b9e
movq %r12, %rdi
movl $0xe, %esi
xorl %edx, %edx
movl %r14d, %ecx
xorl %r8d, %r8d
callq 0x45b9e
movq -0x58(%rbp), %rax
movq 0x20(%rax), %rax
movq -0x30(%rbp), %rcx
addq %rax, 0x20(%rcx)
cmpb $0x73, -0x60(%rbp)
jne 0x50ff3
movq -0x58(%rbp), %rax
movq 0x20(%rax), %rax
movl %r14d, -0x50(%rbp)
cmpq %rax, 0x20(%rcx)
jbe 0x51056
movq -0x30(%rbp), %rcx
movq %rax, 0x20(%rcx)
movl %r14d, -0x50(%rbp)
jmp 0x51056
movq %r12, %rdi
movl $0x27, %esi
movl -0x48(%rbp), %edx
movl %r13d, %ecx
xorl %r8d, %r8d
callq 0x45b9e
movl %r14d, %r13d
movl %eax, %r14d
movq %r12, %rdi
movl $0xf, %esi
movl -0x64(%rbp), %edx
movl %r15d, %ecx
xorl %r8d, %r8d
callq 0x45b9e
movq %r12, %rdi
movl $0x11, %esi
movl -0x68(%rbp), %edx
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0x45b9e
movq %r12, %rdi
movl $0xe, %esi
xorl %edx, %edx
movl %r14d, -0x50(%rbp)
movl %r14d, %ecx
movl %r13d, %r14d
xorl %r8d, %r8d
callq 0x45b9e
movq %r12, %rdi
movl $0xf, %esi
movl -0x64(%rbp), %edx
movl %r15d, %ecx
xorl %r8d, %r8d
callq 0x45b9e
movl %eax, %r15d
movq %r12, %rdi
movl $0x11, %esi
movl -0x68(%rbp), %edx
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0x45b9e
movq %r12, %rdi
movl $0x27, %esi
movl -0x48(%rbp), %edx
movl %r14d, %ecx
xorl %r8d, %r8d
callq 0x45b9e
movq %r12, %rdi
movl $0xe, %esi
xorl %edx, %edx
movl -0x90(%rbp), %ecx
xorl %r8d, %r8d
callq 0x45b9e
movb -0x60(%rbp), %al
cmpb $0x71, %al
movl %r15d, -0x64(%rbp)
jne 0x510c3
movl %r15d, -0x60(%rbp)
jmp 0x5111a
cmpb $0x73, %al
jne 0x510d4
movl -0x64(%rbp), %eax
movl %eax, -0x60(%rbp)
incl %eax
movl %eax, -0x64(%rbp)
jmp 0x5111a
movq %r12, %rdi
movl $0x11, %esi
movl -0x68(%rbp), %edx
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0x45b9e
movl %eax, -0x60(%rbp)
movq %r12, %rdi
movl $0x27, %esi
movl -0x48(%rbp), %edx
movl %r14d, %ecx
xorl %r8d, %r8d
callq 0x45b9e
movq %r12, %rdi
movl $0xe, %esi
xorl %edx, %edx
movl -0x90(%rbp), %ecx
xorl %r8d, %r8d
callq 0x45b9e
movl 0x34(%r12), %eax
movl %eax, -0xd0(%rbp)
cmpb $0x70, %bl
jne 0x51148
movq %r12, %rdi
movl $0xf, %esi
movq -0xd8(%rbp), %rdx
movq -0xe0(%rbp), %rcx
xorl %r8d, %r8d
callq 0x45b9e
movq %r12, %rdi
movl $0x11, %esi
movl -0x80(%rbp), %edx
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0x45b9e
movq %r12, %rdi
movl $0x27, %esi
movl -0x98(%rbp), %edx
movl -0x50(%rbp), %ecx
xorl %r8d, %r8d
callq 0x45b9e
movq %r12, %rdi
movl $0xe, %esi
xorl %edx, %edx
movl -0x90(%rbp), %ecx
xorl %r8d, %r8d
callq 0x45b9e
movl -0xec(%rbp), %edx
testl %edx, %edx
movq -0x70(%rbp), %rbx
js 0x511b4
movl 0x34(%r12), %eax
cmpl %edx, %eax
jbe 0x511b4
movq 0x8(%r12), %rcx
movl %edx, %edx
leaq (%rdx,%rdx,2), %rdx
movl %eax, 0x8(%rcx,%rdx,8)
movq %r12, %rdi
movl $0x15, %esi
xorl %edx, %edx
movl -0x48(%rbp), %r13d
movl %r13d, %ecx
xorl %r8d, %r8d
callq 0x45b9e
movq %r12, %rdi
movl $0x15, %esi
xorl %edx, %edx
movl -0x98(%rbp), %r15d
movl %r15d, %ecx
xorl %r8d, %r8d
callq 0x45b9e
movq %r12, %rdi
movl $0xf, %esi
movl -0x68(%rbp), %edx
movl -0xf4(%rbp), %ecx
xorl %r8d, %r8d
callq 0x45b9e
movq %r12, %rdi
movl $0xf, %esi
movl -0x80(%rbp), %edx
movl -0xf0(%rbp), %ecx
xorl %r8d, %r8d
callq 0x45b9e
movq %r12, %rdi
movl $0x27, %esi
movl %r13d, %edx
movl %r14d, %ecx
xorl %r8d, %r8d
callq 0x45b9e
movq %r12, %rdi
movl $0x27, %esi
movl %r15d, %edx
movl -0x50(%rbp), %ecx
xorl %r8d, %r8d
callq 0x45b9e
cmpl $0x0, -0x90(%rbp)
jns 0x5126c
movq 0x40(%r12), %rax
testq %rax, %rax
je 0x5126c
movl -0x90(%rbp), %edx
notl %edx
movl 0x34(%r12), %ecx
movl %edx, %edx
movl %ecx, (%rax,%rdx,4)
movq %r12, %rdi
movl $0x23, %esi
xorl %edx, %edx
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0x45b9e
movq %r12, %rdi
movl %eax, %esi
movq -0x78(%rbp), %rdx
movl $0xfffffff1, %ecx       # imm = 0xFFFFFFF1
callq 0x11975
movl -0xb8(%rbp), %edx
movl -0x108(%rbp), %ecx
movq %r12, %rdi
movl $0x24, %esi
movq -0x100(%rbp), %r8
callq 0x45b9e
movq %r12, %rdi
movl %eax, %esi
movq %rbx, %rdx
movl $0xfffffff0, %ecx       # imm = 0xFFFFFFF0
callq 0x11975
movq 0x8(%r12), %rax
testq %rax, %rax
movq -0xe8(%rbp), %rbx
movl -0x64(%rbp), %edx
je 0x512e7
movslq 0x34(%r12), %rcx
leaq (%rcx,%rcx,2), %rcx
movb $0x1, -0x15(%rax,%rcx,8)
movq %r12, %rdi
movl $0x25, %esi
movl -0x60(%rbp), %ecx
movl -0xd0(%rbp), %r8d
callq 0x45b9e
testl %ebx, %ebx
jns 0x51318
movq 0x40(%r12), %rax
testq %rax, %rax
je 0x51318
notl %ebx
movl 0x34(%r12), %ecx
movl %ebx, %edx
movl %ecx, (%rax,%rdx,4)
movq -0x88(%rbp), %rax
cmpb $0x5, (%rax)
movq -0x30(%rbp), %rax
movq -0x38(%rbp), %r14
jne 0x5134d
movq -0x58(%rbp), %rcx
movq %rcx, %rax
movq 0x50(%rcx), %rcx
testq %rcx, %rcx
jne 0x51330
movq (%rax), %rdx
movq %r14, %rdi
xorl %esi, %esi
callq 0x55e08
movq -0x30(%rbp), %rax
movq 0x50(%rax), %rbx
testq %rbx, %rbx
je 0x51374
movq -0x40(%rbp), %r15
movq %r15, %rdi
movq %rbx, %rsi
callq 0x3417c
movq %r15, %rdi
movq %rbx, %rsi
callq 0x9c3a
movq -0x30(%rbp), %rax
movq -0x58(%rbp), %rcx
movq %rcx, 0x50(%rax)
movzbl 0x8(%rax), %esi
movq %r14, %rdi
xorl %r14d, %r14d
movl -0xf8(%rbp), %edx
movl -0xc8(%rbp), %ecx
xorl %r8d, %r8d
callq 0x563c9
jmp 0x509ee
movl $0x1, %r12d
movq (%rsi), %rcx
cmpl (%rcx), %r12d
jg 0x50864
testl %ebx, %ebx
jle 0x513d5
movq 0x8(%r14), %rcx
addq $0x1a, %rcx
xorl %edi, %edi
movzwl (%rcx), %edx
cmpl %edx, %r12d
je 0x513d7
incl %edi
addq $0x20, %rcx
cmpl %edi, %ebx
jne 0x513bf
movl %ebx, %edi
jmp 0x513d7
xorl %edi, %edi
movb $0x1, %r15b
cmpl %ebx, %edi
jne 0x5144d
movq $0x0, -0xc0(%rbp)
movl $0x0, -0xb8(%rbp)
movq -0x40(%rbp), %rdi
movl $0x81, %esi
leaq -0xc0(%rbp), %rdx
xorl %ecx, %ecx
callq 0x4a949
testq %rax, %rax
setne %cl
je 0x51446
orb $0x4, 0x3(%rax)
movl %r12d, 0x8(%rax)
movq -0x38(%rbp), %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0x3d42f
movq %rax, %r14
testq %rax, %rax
je 0x51449
movq 0x8(%r14), %rdx
movslq %ebx, %rcx
incl %ebx
shlq $0x5, %rcx
movw %r12w, 0x1a(%rdx,%rcx)
jmp 0x51449
movl %ecx, %r15d
movq -0x30(%rbp), %rsi
testb %r15b, %r15b
je 0x516d4
incl %r12d
movq -0x40(%rbp), %r15
cmpb $0x0, 0x50(%r15)
je 0x513a5
jmp 0x50864
movq -0x38(%rbp), %rbx
movl 0x54(%rbx), %edx
movq %rdx, -0x40(%rbp)
leal 0x2(%rdx), %eax
movl %eax, 0x54(%rbx)
movq %r13, %rdi
movl $0x33, %esi
xorl %ecx, %ecx
xorl %r8d, %r8d
movq %r9, %r15
callq 0x45b9e
movl %eax, 0x14(%r15)
movq 0x60(%r15), %rax
orw $0x8, 0xa(%rax)
leaq -0xc0(%rbp), %rdx
movw $0x1, (%rdx)
movq -0x40(%rbp), %rax
movl %eax, 0x4(%rdx)
movq $0x0, 0x8(%rdx)
movl 0x214(%rbx), %eax
movl %eax, -0x80(%rbp)
movq %rbx, %rdi
movq %r14, %rsi
callq 0x3ba12
testl %eax, %eax
je 0x517b4
movl %eax, %r14d
movq -0x48(%rbp), %r15
xorl %ebx, %ebx
jmp 0x51a92
movl %eax, -0x50(%rbp)
movq %r12, -0x88(%rbp)
movq -0x30(%rbp), %r12
cmpb $0x72, 0x8(%r12)
sete %al
incb %al
xorl %ecx, %ecx
movq %rcx, 0x50(%r12)
movq 0x68(%r12), %rcx
movq %rcx, -0x58(%rbp)
xorps %xmm0, %xmm0
movq 0x70(%r12), %rcx
movq %rcx, -0x60(%rbp)
movups %xmm0, 0x68(%r12)
leaq -0xc0(%rbp), %rdx
movb %al, (%rdx)
movl 0x214(%rbx), %eax
movl %eax, -0x70(%rbp)
movq %rbx, %rdi
movq %r12, %rsi
callq 0x3ba12
movl %eax, -0x78(%rbp)
movq 0x48(%r12), %rsi
movq %r15, %rdi
callq 0x3410b
movq 0x50(%r12), %rbx
movq %r14, 0x50(%r12)
xorl %eax, %eax
movq %rax, 0x48(%r12)
cmpb $0x70, 0x8(%r12)
jne 0x5156f
movq 0x20(%r14), %rax
addq %rax, 0x20(%r12)
movq 0x68(%r12), %rsi
movq -0x48(%rbp), %rdi
callq 0x34068
movq -0x30(%rbp), %rsi
movq -0x58(%rbp), %rax
movq %rax, 0x68(%rsi)
movq -0x60(%rbp), %rax
movq %rax, 0x70(%rsi)
movq $0x0, 0xc(%rsi)
movzbl -0xb0(%rbp), %eax
cmpl $0x1, %eax
movq -0x88(%rbp), %r12
je 0x518eb
cmpl $0x5, %eax
jne 0x515d3
movq -0x30(%rbp), %rcx
movq %rcx, %rax
movq 0x50(%rcx), %rcx
testq %rcx, %rcx
jne 0x515b9
movq (%rax), %rdx
movq -0x38(%rbp), %rdi
xorl %esi, %esi
callq 0x55e08
movq %rbx, -0x58(%rbp)
movq %r13, %rdi
callq 0x4c4bf
movl %eax, %r14d
movq %r13, %rdi
callq 0x4c4bf
movq %rax, -0x90(%rbp)
movq -0x38(%rbp), %rbx
movq %rbx, %rdi
movq -0x30(%rbp), %r15
movq %r15, %rsi
movl %r14d, %edx
callq 0x51c3c
movq %r13, %rdi
movl $0x65, %esi
movq -0x40(%rbp), %r12
movl %r12d, %edx
movl %r14d, %ecx
xorl %r8d, %r8d
callq 0x45b9e
movl 0x34(%r13), %eax
movl %eax, -0x60(%rbp)
movq (%r15), %rdx
movl (%rdx), %r8d
leaq -0xb0(%rbp), %rax
movq %rbx, %rdi
movq %r15, %rsi
movl %r12d, %ecx
xorl %r9d, %r9d
pushq %r14
movq -0x90(%rbp), %rbx
pushq %rbx
pushq %rax
pushq $0x0
callq 0x54609
movq %rbx, %rdx
addq $0x20, %rsp
testl %edx, %edx
jns 0x51672
movq 0x40(%r13), %rax
testq %rax, %rax
je 0x51672
notl %edx
movl 0x34(%r13), %ecx
movl %edx, %edx
movl %ecx, (%rax,%rdx,4)
movq %r13, %rdi
movl $0x7, %esi
movq -0x40(%rbp), %r12
movl %r12d, %edx
movl -0x60(%rbp), %ecx
xorl %r8d, %r8d
callq 0x45b9e
testl %r14d, %r14d
movq -0x48(%rbp), %r15
movq -0x58(%rbp), %rbx
jns 0x516af
movq 0x40(%r13), %rax
testq %rax, %rax
je 0x516af
notl %r14d
movl 0x34(%r13), %ecx
movl %r14d, %edx
movl %ecx, (%rax,%rdx,4)
movq %r13, %rdi
movl $0x36, %esi
movl %r12d, %edx
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0x45b9e
movq -0x88(%rbp), %r12
movq -0x30(%rbp), %rsi
jmp 0x518ef
movl $0x7, %r14d
jmp 0x509ee
movl %eax, -0x40(%rbp)
movq $0x0, 0x50(%rsi)
movl 0xc(%r14), %edx
movl %edx, 0xc(%rsi)
movl 0x10(%r14), %eax
movl %eax, 0x10(%rsi)
testl %edx, %edx
je 0x51715
movq %r13, %rdi
movl $0x80, %esi
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0x45b9e
movq -0x30(%rbp), %rsi
movl %eax, %r12d
movq -0x38(%rbp), %rdi
movl 0x214(%rdi), %eax
movl %eax, -0x70(%rbp)
leaq -0xb0(%rbp), %rdx
callq 0x3ba12
movq -0x30(%rbp), %rsi
movq 0x50(%rsi), %rbx
movq %r14, 0x50(%rsi)
movq 0x20(%r14), %rcx
addq %rcx, 0x20(%rsi)
movl %eax, -0x78(%rbp)
movq 0x68(%r14), %rdi
testq %rdi, %rdi
je 0x51786
movq %rbx, %r14
leaq -0xc0(%rbp), %rbx
movq %rbx, %rsi
callq 0x4aaf6
movq -0x30(%rbp), %rsi
testl %eax, %eax
setne %cl
movl (%rbx), %eax
movq %r14, %rbx
testl %eax, %eax
setg %dl
andb %cl, %dl
cmpb $0x1, %dl
jne 0x51786
movl %eax, %eax
cmpq %rax, 0x20(%rsi)
jbe 0x51786
movq %rax, 0x20(%rsi)
testl %r12d, %r12d
jle 0x51919
movl 0x34(%r13), %eax
cmpl %r12d, %eax
movl -0x78(%rbp), %r14d
jbe 0x5191d
movq 0x8(%r13), %rcx
movl %r12d, %edx
leaq (%rdx,%rdx,2), %rdx
movl %eax, 0x8(%rcx,%rdx,8)
jmp 0x5191d
movl %eax, -0x90(%rbp)
movq -0x40(%rbp), %rax
leal 0x1(%rax), %ebx
movq %r13, %rdi
movl $0x33, %esi
movl %ebx, %edx
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0x45b9e
movq -0x30(%rbp), %r15
movl %eax, 0x18(%r15)
movq $0x0, 0x50(%r15)
movq 0x68(%r15), %rax
movq %rax, -0x50(%rbp)
movq 0x70(%r15), %rax
movq %rax, -0x98(%rbp)
xorps %xmm0, %xmm0
movups %xmm0, 0x68(%r15)
leaq -0xc0(%rbp), %rdx
movl %ebx, -0x60(%rbp)
movl %ebx, 0x4(%rdx)
movq -0x38(%rbp), %rdi
movl 0x214(%rdi), %eax
movl %eax, -0x70(%rbp)
movq %r15, %rsi
callq 0x3ba12
movl %eax, -0x78(%rbp)
movq 0x20(%r15), %rcx
movq 0x50(%r15), %rax
movq %rax, -0x58(%rbp)
movq %r14, 0x50(%r15)
movq 0x20(%r14), %rax
cmpq %rax, %rcx
movq %r15, %rbx
jbe 0x51845
movq %rax, 0x20(%rbx)
movq 0x68(%rbx), %rsi
movq -0x48(%rbp), %rdi
callq 0x34068
movq -0x50(%rbp), %rax
movq %rax, 0x68(%rbx)
movq -0x98(%rbp), %rax
movq %rax, 0x70(%rbx)
cmpb $0x5, -0xb0(%rbp)
jne 0x5188c
movq %rbx, %rax
movq 0x50(%rbx), %rbx
testq %rbx, %rbx
jne 0x5186e
movq (%rax), %rdx
movq -0x38(%rbp), %rdi
xorl %esi, %esi
callq 0x55e08
movq -0x30(%rbp), %rbx
movq %r12, -0x88(%rbp)
movq %r13, %rdi
callq 0x4c4bf
movl %eax, %r14d
movq %r13, %rdi
callq 0x4c4bf
movq %rax, -0x50(%rbp)
movq -0x38(%rbp), %r15
movq %r15, %rdi
movq %rbx, %rsi
movl %r14d, %edx
callq 0x51c3c
movq %r13, %rdi
movl $0x65, %esi
movq -0x40(%rbp), %rdx
movl %r14d, %ecx
xorl %r8d, %r8d
callq 0x45b9e
movb 0x1f(%r15), %al
testb %al, %al
je 0x51937
decb %al
movb %al, 0x1f(%r15)
movzbl %al, %eax
movl 0x28(%r15,%rax,4), %r12d
jmp 0x51942
movq -0x48(%rbp), %r15
movl -0x78(%rbp), %r14d
movl -0x70(%rbp), %ecx
movl -0x50(%rbp), %eax
testl %eax, %eax
jne 0x509cd
jmp 0x51a9e
movl -0xac(%rbp), %eax
movq %rax, -0x40(%rbp)
movq -0x38(%rbp), %rbx
jmp 0x50b42
movl -0x78(%rbp), %r14d
movl -0x70(%rbp), %ecx
movl -0x40(%rbp), %eax
testl %eax, %eax
movq %r15, %r12
movq -0x48(%rbp), %r15
jne 0x509cd
jmp 0x51a9e
movl 0x58(%r15), %r12d
incl %r12d
movl %r12d, 0x58(%r15)
movq -0x58(%rbp), %rbx
movq %r13, %rdi
movl $0x5c, %esi
movq -0x40(%rbp), %rdx
movl %r12d, %ecx
xorl %r8d, %r8d
callq 0x45b9e
movl %eax, -0x98(%rbp)
movq %r13, %rdi
movl $0x3c, %esi
movl -0x60(%rbp), %edx
movq -0x50(%rbp), %rcx
movl %r12d, %r8d
xorl %r9d, %r9d
callq 0x4f3ff
testl %r12d, %r12d
movq -0x30(%rbp), %rsi
movq -0x48(%rbp), %r15
je 0x519ce
movq -0x38(%rbp), %rax
movzbl 0x1f(%rax), %eax
cmpq $0x7, %rax
ja 0x519ce
xorl %ecx, %ecx
movq -0x38(%rbp), %rdx
cmpl %r12d, 0x84(%rdx,%rcx)
je 0x519c5
addq $0x18, %rcx
cmpl $0xf0, %ecx
jne 0x5199e
leal 0x1(%rax), %ecx
movq -0x38(%rbp), %rdx
movb %cl, 0x1f(%rdx)
movl %r12d, 0x28(%rdx,%rax,4)
jmp 0x519ce
movq -0x38(%rbp), %rax
movb $0x1, 0x7c(%rax,%rcx)
movq (%rsi), %rdx
movl (%rdx), %r8d
leaq -0xb0(%rbp), %rax
movq -0x38(%rbp), %rdi
movq -0x40(%rbp), %r12
movl %r12d, %ecx
xorl %r9d, %r9d
movq %r14, -0x58(%rbp)
pushq %r14
movq -0x50(%rbp), %r14
pushq %r14
pushq %rax
pushq $0x0
callq 0x54609
addq $0x20, %rsp
testl %r14d, %r14d
jns 0x51a1e
movq 0x40(%r13), %rax
testq %rax, %rax
je 0x51a1e
movq -0x50(%rbp), %rdx
notl %edx
movl 0x34(%r13), %ecx
movl %edx, %edx
movl %ecx, (%rax,%rdx,4)
movq %r13, %rdi
movl $0x7, %esi
movl %r12d, %edx
movl -0x98(%rbp), %ecx
xorl %r8d, %r8d
callq 0x45b9e
movq -0x58(%rbp), %rdx
testl %edx, %edx
movq -0x88(%rbp), %r12
jns 0x51a5a
movq 0x40(%r13), %rax
testq %rax, %rax
je 0x51a5a
notl %edx
movl 0x34(%r13), %ecx
movl %edx, %edx
movl %ecx, (%rax,%rdx,4)
movq %r13, %rdi
movl $0x36, %esi
movl -0x60(%rbp), %edx
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0x45b9e
movq %r13, %rdi
movl $0x36, %esi
movq -0x40(%rbp), %rdx
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0x45b9e
movl -0x78(%rbp), %r14d
movl -0x70(%rbp), %ecx
movl -0x90(%rbp), %eax
testl %eax, %eax
movq -0x30(%rbp), %rsi
jne 0x509cd
movzbl 0x8(%rsi), %esi
xorl %r8d, %r8d
cmpl $0x71, %esi
setne %r8b
movq -0x38(%rbp), %rdi
movl -0x80(%rbp), %edx
callq 0x563c9
movq -0x30(%rbp), %rax
testb $0x8, 0xa(%rax)
je 0x509cd
movl %r14d, -0x78(%rbp)
movq %r12, -0x88(%rbp)
movq (%rax), %rax
movl (%rax), %r14d
movq %r15, %rdi
movl %r14d, %esi
callq 0x35fcd
testq %rax, %rax
je 0x51b9f
movq %rax, %r12
movq %rbx, -0x58(%rbp)
testl %r14d, %r14d
movq -0x30(%rbp), %rax
jle 0x51b77
xorl %ebx, %ebx
movq -0x38(%rbp), %rdi
movq %rax, %rsi
movl %ebx, %edx
callq 0x56460
movq %rax, 0x18(%r12,%rbx,8)
testq %rax, %rax
jne 0x51b1e
movq 0x10(%r15), %rax
movq %rax, 0x18(%r12,%rbx,8)
incq %rbx
cmpl %ebx, %r14d
movq -0x30(%rbp), %rax
jne 0x51afd
jmp 0x51b77
xorl %ebx, %ebx
movslq 0x14(%rax,%rbx,4), %rsi
testq %rsi, %rsi
js 0x51b73
movq %rax, %r15
cmpl %esi, 0x34(%r13)
jbe 0x51b4e
movq 0x8(%r13), %rax
leaq (%rsi,%rsi,2), %rcx
movl %r14d, 0x8(%rax,%rcx,8)
movq %r13, %rdi
movq %r12, %rdx
movl $0xfffffffa, %ecx       # imm = 0xFFFFFFFA
callq 0x11975
movq %r15, %rax
movl $0xffffffff, 0x14(%r15,%rbx,4) # imm = 0xFFFFFFFF
incq %rbx
cmpq $0x1, %rbx
je 0x51b2e
movq 0x50(%rax), %rax
testq %rax, %rax
jne 0x51b2c
movq -0x48(%rbp), %r15
movq %r15, %rdi
movq %r12, %rsi
callq 0x9c3a
movq -0x88(%rbp), %r12
movq -0x58(%rbp), %rbx
movl -0x78(%rbp), %r14d
jmp 0x509cd
movl $0x7, %r14d
movq -0x88(%rbp), %r12
jmp 0x509cd