// File: /workspace/github_c_makefile_star2_O3/barabo[P]advanced-shell-history/src/sqlite3.c
// Function: sqlite3WalCheckpoint
SQLITE_PRIVATE int sqlite3WalCheckpoint(
  Wal *pWal,                      /* Wal connection */
  int eMode,                      /* PASSIVE, FULL or RESTART */
  int (*xBusy)(void*),            /* Function to call when busy */
  void *pBusyArg,                 /* Context argument for xBusyHandler */
  int sync_flags,                 /* Flags to sync db file with (or 0) */
  int nBuf,                       /* Size of temporary buffer */
  u8 *zBuf,                       /* Temporary buffer to use */
  int *pnLog,                     /* OUT: Number of frames in WAL */
  int *pnCkpt                     /* OUT: Number of backfilled frames in WAL */
){
  int rc;                         /* Return code */
  int isChanged = 0;              /* True if a new wal-index header is loaded */
  int eMode2 = eMode;             /* Mode to pass to walCheckpoint() */

  assert( pWal->ckptLock==0 );
  assert( pWal->writeLock==0 );

  if( pWal->readOnly ) return SQLITE_READONLY;
  WALTRACE(("WAL%p: checkpoint begins\n", pWal));
  rc = walLockExclusive(pWal, WAL_CKPT_LOCK, 1);
  if( rc ){
    /* Usually this is SQLITE_BUSY meaning that another thread or process
    ** is already running a checkpoint, or maybe a recovery.  But it might
    ** also be SQLITE_IOERR. */
    return rc;
  }
  pWal->ckptLock = 1;

  /* If this is a blocking-checkpoint, then obtain the write-lock as well
  ** to prevent any writers from running while the checkpoint is underway.
  ** This has to be done before the call to walIndexReadHdr() below.
  **
  ** If the writer lock cannot be obtained, then a passive checkpoint is
  ** run instead. Since the checkpointer is not holding the writer lock,
  ** there is no point in blocking waiting for any readers. Assuming no 
  ** other error occurs, this function will return SQLITE_BUSY to the caller.
  */
  if( eMode!=SQLITE_CHECKPOINT_PASSIVE ){
    rc = walBusyLock(pWal, xBusy, pBusyArg, WAL_WRITE_LOCK, 1);
    if( rc==SQLITE_OK ){
      pWal->writeLock = 1;
    }else if( rc==SQLITE_BUSY ){
      eMode2 = SQLITE_CHECKPOINT_PASSIVE;
      rc = SQLITE_OK;
    }
  }

  /* Read the wal-index header. */
  if( rc==SQLITE_OK ){
    rc = walIndexReadHdr(pWal, &isChanged);
    if( isChanged && pWal->pDbFd->pMethods->iVersion>=3 ){
      sqlite3OsUnfetch(pWal->pDbFd, 0, 0);
    }
  }

  /* Copy data from the log to the database file. */
  if( rc==SQLITE_OK ){
    if( pWal->hdr.mxFrame && walPagesize(pWal)!=nBuf ){
      rc = SQLITE_CORRUPT_BKPT;
    }else{
      rc = walCheckpoint(pWal, eMode2, xBusy, pBusyArg, sync_flags, zBuf);
    }

    /* If no error occurred, set the output variables. */
    if( rc==SQLITE_OK || rc==SQLITE_BUSY ){
      if( pnLog ) *pnLog = (int)pWal->hdr.mxFrame;
      if( pnCkpt ) *pnCkpt = (int)(walCkptInfo(pWal)->nBackfill);
    }
  }

  if( isChanged ){
    /* If a new wal-index header was loaded before the checkpoint was 
    ** performed, then the pager-cache associated with pWal is now
    ** out of date. So zero the cached wal-index header to ensure that
    ** next time the pager opens a snapshot on this database it knows that
    ** the cache needs to be reset.
    */
    memset(&pWal->hdr, 0, sizeof(WalIndexHdr));
  }

  /* Release the locks. */
  sqlite3WalEndWriteTransaction(pWal);
  walUnlockExclusive(pWal, WAL_CKPT_LOCK, 1);
  pWal->ckptLock = 0;
  WALTRACE(("WAL%p: checkpoint %s\n", pWal, rc ? "failed" : "ok"));
  return (rc==SQLITE_OK && eMode!=eMode2 ? SQLITE_BUSY : rc);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x178, %rsp            # imm = 0x178
movq %rcx, -0xa0(%rbp)
movl $0x0, -0xac(%rbp)
movl $0x8, %eax
cmpb $0x0, 0x42(%rdi)
jne 0x1d986
movl %r9d, %ebx
movl %r8d, %r12d
movl %esi, %r15d
movq %rdi, %r14
cmpb $0x0, 0x3f(%rdi)
movq %rdx, -0x88(%rbp)
je 0x1d1f8
movb $0x1, 0x41(%r14)
testl %r15d, %r15d
movq %r14, -0x30(%rbp)
movl %r12d, -0x70(%rbp)
je 0x1d235
cmpb $0x0, 0x3f(%r14)
jne 0x1d22a
movq 0x8(%r14), %rdi
movq (%rdi), %rax
xorl %esi, %esi
movl $0x1, %edx
movl $0xa, %ecx
callq *0x70(%rax)
movl %eax, %r13d
movq -0x88(%rbp), %rax
testq %rax, %rax
je 0x1d21b
cmpl $0x5, %r13d
jne 0x1d21b
movq -0xa0(%rbp), %rdi
callq *%rax
testl %eax, %eax
jne 0x1d1b7
jmp 0x1d235
movq 0x8(%r14), %rdi
movq (%rdi), %rax
movl $0x1, %esi
movl $0x1, %edx
movl $0xa, %ecx
callq *0x70(%rax)
testl %eax, %eax
jne 0x1d986
jmp 0x1d1a5
cmpl $0x5, %r13d
je 0x1d235
testl %r13d, %r13d
jne 0x1d618
movb $0x1, 0x40(%r14)
movl %r15d, -0x34(%rbp)
jmp 0x1d23c
movl $0x0, -0x34(%rbp)
leaq -0xac(%rbp), %r14
movq -0x30(%rbp), %r12
movq %r12, %rdi
movq %r14, %rsi
callq 0x1bdd5
movl %eax, %r13d
cmpl $0x0, (%r14)
je 0x1d279
movq 0x8(%r12), %rdi
movq (%rdi), %rax
cmpl $0x3, (%rax)
movq %r12, %r14
jl 0x1d275
xorl %esi, %esi
xorl %edx, %edx
callq *0x90(%rax)
xorl %esi, %esi
jmp 0x1d27f
movb $0x1, %sil
movq %r12, %r14
testl %r13d, %r13d
jne 0x1d906
movl 0x58(%r14), %edx
movzwl 0x56(%r14), %eax
movl %eax, %ecx
shll $0x10, %ecx
orl %eax, %ecx
andl $0x1fe00, %ecx          # imm = 0x1FE00
testl %edx, %edx
je 0x1d2d6
cmpl %ebx, %ecx
je 0x1d2d6
movq %rsi, %rbx
leaq 0x5c564(%rip), %rsi     # 0x79814
leaq 0x5c282(%rip), %rcx     # 0x79539
movl $0xb, %r13d
movl $0xb, %edi
movl $0xbd6c, %edx           # imm = 0xBD6C
xorl %eax, %eax
callq 0xb9c7
movq %rbx, %rsi
jmp 0x1d906
movq 0x30(%r14), %rax
movq (%rax), %rax
movq %rax, -0x58(%rbp)
movl 0x60(%rax), %eax
xorl %r13d, %r13d
cmpl %edx, %eax
jae 0x1d8e2
movl %ecx, -0x6c(%rbp)
movq %rsi, -0xa8(%rbp)
leal 0x1000(%rdx), %eax
movabsq $0xffffffff021, %r12    # imm = 0xFFFFFFFF021
addq %rax, %r12
shrq $0xc, %r12
movl %r12d, %eax
shll $0x5, %eax
leal (%rax,%rdx,2), %ebx
addl $0x28, %ebx
movl %ebx, %edi
movq %rdx, -0xb8(%rbp)
callq 0x16d29
movl $0x7, %r13d
testq %rax, %rax
je 0x1d7a5
leal 0x1(%r12), %r14d
movslq %ebx, %rdx
movq %rax, %rbx
movq %rax, %rdi
xorl %esi, %esi
callq 0x8200
movq %rbx, -0x40(%rbp)
movl %r14d, 0x4(%rbx)
movl $0x1000, %edi           # imm = 0x1000
movq -0xb8(%rbp), %rax
cmpl %edi, %eax
cmovbl %eax, %edi
addl %edi, %edi
callq 0x16d29
movq %rax, %rbx
testl %r12d, %r12d
movl %r15d, -0x44(%rbp)
js 0x1d624
testq %rbx, %rbx
je 0x1d624
movq %r12, %rcx
movq -0x40(%rbp), %rax
addq $0x8, %rax
movq %rax, -0x90(%rbp)
andl $0x7fffffff, %ecx       # imm = 0x7FFFFFFF
leaq -0x60(%rbp), %r12
xorl %r13d, %r13d
movq -0x30(%rbp), %r14
movq %rcx, -0x98(%rbp)
movq %r14, %rdi
movl %r13d, %esi
leaq -0x1a0(%rbp), %rdx
callq 0x1bf63
testl %eax, %eax
jne 0x1d78c
movq %r13, %rdx
movl %edx, %esi
shll $0xc, %esi
addl $-0x22, %esi
testq %r13, %r13
movl $0x0, %eax
movl $0x88, %ecx
cmoveq %rcx, %rax
movl $0x0, %ecx
cmovel %ecx, %esi
movq -0x1a0(%rbp), %rcx
addq %rax, %rcx
movq %rcx, -0x50(%rbp)
movl $0x4000, %ecx           # imm = 0x4000
subl %eax, %ecx
shrl $0x2, %ecx
movq -0xb8(%rbp), %rax
movl %eax, %edi
subl %esi, %edi
cmpq -0x98(%rbp), %r13
cmovnel %ecx, %edi
movq -0x40(%rbp), %rax
movslq 0x4(%rax), %rax
shlq $0x5, %rax
addq -0x90(%rbp), %rax
movq %rsi, -0xc0(%rbp)
leaq (%rax,%rsi,2), %rcx
testl %edi, %edi
movq %rcx, -0x78(%rbp)
movl %edi, -0x68(%rbp)
movq %r13, -0xc8(%rbp)
jle 0x1d541
movl %edi, %edx
xorl %eax, %eax
movw %ax, (%rcx,%rax,2)
incq %rax
cmpq %rax, %rdx
jne 0x1d454
movq %rdx, -0x80(%rbp)
movl $0xd0, %edx
leaq -0x1a0(%rbp), %rdi
xorl %esi, %esi
callq 0x8200
movq -0x80(%rbp), %rdx
movq -0x78(%rbp), %rcx
xorl %r15d, %r15d
leaq -0x38(%rbp), %r13
movl $0x1, -0x38(%rbp)
leaq (%rcx,%r15,2), %rax
movq %rax, -0x60(%rbp)
testb $0x1, %r15b
jne 0x1d4b9
movq %rax, -0x198(%rbp)
movl $0x1, -0x1a0(%rbp)
incq %r15
cmpq %rdx, %r15
jne 0x1d486
jmp 0x1d56c
movq %rbx, %r13
leaq -0x198(%rbp), %r12
xorl %r14d, %r14d
movq -0x50(%rbp), %rbx
movq (%r12), %rsi
movl -0x8(%r12), %edx
movq %rbx, %rdi
leaq -0x60(%rbp), %rcx
leaq -0x38(%rbp), %r8
movq %r13, %r9
callq 0x1dc11
movl %r15d, %eax
movl %r14d, %ecx
shrl %cl, %eax
incq %r14
addq $0x10, %r12
testb $0x2, %al
jne 0x1d4ca
movq -0x60(%rbp), %rcx
movl -0x38(%rbp), %eax
movl %r14d, %edx
shlq $0x4, %rdx
movq %rcx, -0x198(%rbp,%rdx)
movl %eax, -0x1a0(%rbp,%rdx)
incq %r15
movq -0x80(%rbp), %rdx
cmpq %rdx, %r15
leaq -0x60(%rbp), %r12
movq %r13, %rbx
leaq -0x38(%rbp), %r13
movq -0x78(%rbp), %rcx
jne 0x1d486
leaq -0x1(%r14), %rcx
cmpq $0xb, %rcx
jb 0x1d56f
jmp 0x1d5ba
movl $0x0, -0x38(%rbp)
movq $0x0, -0x60(%rbp)
movl $0xd0, %edx
leaq -0x1a0(%rbp), %rdi
xorl %esi, %esi
callq 0x8200
xorl %r14d, %r14d
leaq -0x38(%rbp), %r13
jmp 0x1d56f
xorl %r14d, %r14d
movq %r14, %r15
shlq $0x4, %r15
leaq -0x188(%rbp), %rax
addq %rax, %r15
movl -0x68(%rbp), %edx
movl %edx, %eax
movl %r14d, %ecx
shrl %cl, %eax
testb $0x2, %al
je 0x1d5aa
movq (%r15), %rsi
movl -0x8(%r15), %edx
movq -0x50(%rbp), %rdi
movq %r12, %rcx
movq %r13, %r8
movq %rbx, %r9
callq 0x1dc11
movl -0x68(%rbp), %edx
incq %r14
addq $0x10, %r15
cmpq $0xc, %r14
jne 0x1d583
movl -0x38(%rbp), %eax
movq -0xc0(%rbp), %rdi
incl %edi
movq -0xc8(%rbp), %rsi
movq %rsi, %rcx
shlq $0x5, %rcx
movq -0x90(%rbp), %rdx
movl %edi, 0x1c(%rdx,%rcx)
movl %eax, 0x18(%rdx,%rcx)
movq -0x78(%rbp), %rax
movq %rax, 0x8(%rdx,%rcx)
movq -0x50(%rbp), %rax
movq %rax, 0x10(%rdx,%rcx)
leaq 0x1(%rsi), %r13
movq -0x98(%rbp), %rcx
cmpq %rcx, %rsi
movl -0x44(%rbp), %r15d
movq -0x30(%rbp), %r14
jne 0x1d3b1
movq %rbx, %rdi
callq 0x16dea
jmp 0x1d639
movb $0x1, %sil
movl %r15d, -0x34(%rbp)
jmp 0x1d27f
movq %rbx, %rdi
callq 0x16dea
testq %rbx, %rbx
movq -0x30(%rbp), %r14
je 0x1d79c
xorl %r13d, %r13d
cmpl $0x0, -0x34(%rbp)
movq -0x88(%rbp), %rcx
cmoveq %r13, %rcx
movl 0x58(%r14), %ebx
movl 0x5c(%r14), %eax
movq %rax, -0x78(%rbp)
movl $0x1, %r15d
movq -0x58(%rbp), %rax
movl 0x64(%rax,%r15,4), %r12d
cmpl %r12d, %ebx
jbe 0x1d71f
movl %ebx, -0x50(%rbp)
movq %rcx, %r14
leal 0x3(%r15), %ebx
movq -0x30(%rbp), %rcx
cmpb $0x0, 0x3f(%rcx)
jne 0x1d6d0
movq 0x8(%rcx), %rdi
movq (%rdi), %rax
movl %ebx, %esi
movl $0x1, %edx
movl $0xa, %ecx
callq *0x70(%rax)
movl %eax, %r13d
testq %r14, %r14
je 0x1d6bd
cmpl $0x5, %r13d
jne 0x1d6bd
movq -0xa0(%rbp), %rdi
callq *%r14
testl %eax, %eax
jne 0x1d679
movl $0x5, %r13d
jmp 0x1d6f4
cmpl $0x5, %r13d
je 0x1d6f4
testl %r13d, %r13d
movq -0x30(%rbp), %rcx
jne 0x1d8c0
cmpq $0x1, %r15
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
cmovel -0x50(%rbp), %eax
movq -0x58(%rbp), %rdx
movl %eax, 0x64(%rdx,%r15,4)
xorl %r13d, %r13d
cmpb $0x0, 0x3f(%rcx)
je 0x1d6ff
movq %rdx, %rax
jmp 0x1d719
xorl %ecx, %ecx
movl %r12d, %ebx
movq -0x58(%rbp), %rax
jmp 0x1d71f
movq 0x8(%rcx), %rdi
movq (%rdi), %rax
movl %ebx, %esi
movl $0x1, %edx
movl $0x9, %ecx
callq *0x70(%rax)
movq -0x58(%rbp), %rax
movq %r14, %rcx
movl -0x50(%rbp), %ebx
incq %r15
cmpq $0x5, %r15
jne 0x1d661
movq %rcx, -0x88(%rbp)
movl 0x60(%rax), %eax
cmpl %ebx, %eax
movl -0x44(%rbp), %r15d
jae 0x1d831
movq -0x30(%rbp), %rax
cmpb $0x0, 0x3f(%rax)
jne 0x1d7b6
movq 0x8(%rax), %rdi
movq (%rdi), %rax
movl $0x3, %esi
movl $0x1, %edx
movl $0xa, %ecx
callq *0x70(%rax)
movl %eax, %r13d
movq -0x88(%rbp), %rax
testq %rax, %rax
je 0x1d7b1
cmpl $0x5, %r13d
jne 0x1d7b1
movq -0xa0(%rbp), %rdi
callq *%rax
testl %eax, %eax
jne 0x1d742
jmp 0x1d837
movl %eax, %r13d
movq %rbx, %rdi
callq 0x16dea
jmp 0x1d8c7
movq -0x40(%rbp), %rdi
callq 0x16dea
movq -0xa8(%rbp), %rsi
jmp 0x1d906
testl %r13d, %r13d
jne 0x1d831
movl %ebx, -0x50(%rbp)
movq -0x58(%rbp), %rax
movl 0x60(%rax), %r12d
movl -0x70(%rbp), %r14d
testl %r14d, %r14d
je 0x1d7df
movq -0x30(%rbp), %rax
movq 0x10(%rax), %rdi
movq (%rdi), %rax
movl %r14d, %esi
callq *0x28(%rax)
testl %eax, %eax
jne 0x1d80b
movl -0x6c(%rbp), %ebx
movq -0x78(%rbp), %rax
imulq %rbx, %rax
movq %rax, -0x60(%rbp)
movq -0x30(%rbp), %rax
movq 0x8(%rax), %rdi
movq (%rdi), %rax
leaq -0x1a0(%rbp), %rsi
callq *0x30(%rax)
testl %eax, %eax
je 0x1d998
movl %eax, %r13d
movq -0x30(%rbp), %rax
cmpb $0x0, 0x3f(%rax)
jne 0x1d831
movq 0x8(%rax), %rdi
movq (%rdi), %rax
movl $0x3, %esi
movl $0x1, %edx
movl $0x9, %ecx
callq *0x70(%rax)
cmpl $0x5, %r13d
jne 0x1d83a
xorl %r13d, %r13d
cmpl $0x0, -0x34(%rbp)
je 0x1d8ba
testl %r13d, %r13d
movq -0x30(%rbp), %r14
movq -0x40(%rbp), %rdi
jne 0x1d8cb
movq -0x58(%rbp), %rax
movl 0x60(%rax), %eax
movl $0x5, %r13d
cmpl 0x58(%r14), %eax
jb 0x1d8cb
cmpl $0x2, -0x34(%rbp)
jne 0x1dba6
cmpb $0x0, 0x3f(%r14)
jne 0x1dba6
movq 0x8(%r14), %rdi
movq (%rdi), %rax
movl $0x4, %esi
movl $0x4, %edx
movl $0xa, %ecx
callq *0x70(%rax)
movq -0x88(%rbp), %rcx
testq %rcx, %rcx
je 0x1db73
cmpl $0x5, %eax
jne 0x1db73
movq -0xa0(%rbp), %rdi
callq *%rcx
testl %eax, %eax
movq -0x40(%rbp), %rdi
jne 0x1d86a
jmp 0x1d8cb
movq -0x30(%rbp), %r14
jmp 0x1d8c7
movl -0x44(%rbp), %r15d
movq %rcx, %r14
movq -0x40(%rbp), %rdi
callq 0x16dea
cmpl $0x5, %r13d
movq -0xa8(%rbp), %rsi
je 0x1d8e2
testl %r13d, %r13d
jne 0x1d906
movq 0x20(%rbp), %rax
movq 0x18(%rbp), %rcx
testq %rcx, %rcx
je 0x1d8f5
movl 0x58(%r14), %edx
movl %edx, (%rcx)
testq %rax, %rax
je 0x1d906
movq 0x30(%r14), %rcx
movq (%rcx), %rcx
movl 0x60(%rcx), %ecx
movl %ecx, (%rax)
testb %sil, %sil
jne 0x1d91d
xorps %xmm0, %xmm0
movups %xmm0, 0x68(%r14)
movups %xmm0, 0x58(%r14)
movups %xmm0, 0x48(%r14)
cmpb $0x0, 0x40(%r14)
movb 0x3f(%r14), %al
je 0x1d950
testb %al, %al
jne 0x1d946
movq 0x8(%r14), %rdi
movq (%rdi), %rax
xorl %esi, %esi
movl $0x1, %edx
movl $0x9, %ecx
callq *0x70(%rax)
movb 0x3f(%r14), %al
xorl %ecx, %ecx
movb %cl, 0x40(%r14)
movb %cl, 0x43(%r14)
testb %al, %al
jne 0x1d96d
movq 0x8(%r14), %rdi
movq (%rdi), %rax
movl $0x1, %esi
movl $0x1, %edx
movl $0x9, %ecx
callq *0x70(%rax)
testl %r13d, %r13d
movl $0x5, %eax
cmovnel %r13d, %eax
movb $0x0, 0x41(%r14)
cmpl %r15d, -0x34(%rbp)
cmovel %r13d, %eax
addq $0x178, %rsp            # imm = 0x178
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rbx, -0x80(%rbp)
movq -0x1a0(%rbp), %rax
cmpq -0x60(%rbp), %rax
jge 0x1d9c0
movq -0x30(%rbp), %rax
movq 0x8(%rax), %rdi
movq (%rdi), %rax
leaq -0x60(%rbp), %rdx
movl $0x5, %esi
callq *0x50(%rax)
movq -0x40(%rbp), %rax
movl 0x4(%rax), %ecx
testl %ecx, %ecx
movl -0x50(%rbp), %r14d
jle 0x1db04
movq %rax, %rbx
addq $0x8, %rbx
movl -0x6c(%rbp), %edx
orl $0x18, %edx
movq %rdx, -0x98(%rbp)
movq $0x0, -0x68(%rbp)
movl %r12d, -0x90(%rbp)
movl (%rax), %eax
movl %ecx, %ecx
movl $0xffffffff, %r15d      # imm = 0xFFFFFFFF
movq %rcx, %rdx
decq %rcx
movq %rcx, %rsi
shlq $0x5, %rsi
movl 0x18(%rbx,%rsi), %edi
movslq (%rbx,%rsi), %r8
cmpl %edi, %r8d
jge 0x1da64
addq %rbx, %rsi
movq 0x10(%rsi), %r9
negl %edi
leal 0x1(%r8), %r10d
addq %r8, %r8
addq 0x8(%rsi), %r8
movzwl (%r8), %r11d
movl (%r9,%r11,4), %r13d
cmpl %eax, %r13d
ja 0x1da54
movl %r10d, (%rsi)
leal (%rdi,%r10), %r11d
incl %r11d
incl %r10d
addq $0x2, %r8
cmpl $0x1, %r11d
jne 0x1da2e
jmp 0x1da64
cmpl %r15d, %r13d
jae 0x1da64
addl 0x1c(%rsi), %r11d
movq %r11, -0x68(%rbp)
movl %r13d, %r15d
cmpq $0x1, %rdx
jg 0x1da00
movq -0x40(%rbp), %rax
movl %r15d, (%rax)
cmpl $-0x1, %r15d
je 0x1db0a
cmpl %r12d, -0x68(%rbp)
jbe 0x1daf9
cmpl %r14d, -0x68(%rbp)
ja 0x1daf9
cmpl -0x78(%rbp), %r15d
ja 0x1daf9
movq -0x68(%rbp), %rax
leal -0x1(%rax), %ecx
imulq -0x98(%rbp), %rcx
addq $0x38, %rcx
movq -0x30(%rbp), %r12
movq 0x10(%r12), %rdi
movq (%rdi), %rax
movq 0x10(%rbp), %rsi
movl -0x6c(%rbp), %r14d
movl %r14d, %edx
callq *0x10(%rax)
testl %eax, %eax
jne 0x1dbae
decl %r15d
imulq -0x80(%rbp), %r15
movq 0x8(%r12), %rdi
movq (%rdi), %rax
movq 0x10(%rbp), %rsi
movl %r14d, %edx
movq %r15, %rcx
callq *0x18(%rax)
movl %eax, %r13d
testl %eax, %eax
movq -0x40(%rbp), %rax
movl -0x50(%rbp), %r14d
movl -0x90(%rbp), %r12d
jne 0x1dbb1
movl 0x4(%rax), %ecx
testl %ecx, %ecx
jg 0x1d9f6
movl $0xffffffff, (%rax)     # imm = 0xFFFFFFFF
movq -0x30(%rbp), %rax
movq 0x30(%rax), %rax
movq (%rax), %rax
cmpl 0x10(%rax), %r14d
movl -0x44(%rbp), %r15d
jne 0x1db63
movq -0x30(%rbp), %rcx
movl 0x5c(%rcx), %eax
movq -0x80(%rbp), %rsi
imulq %rax, %rsi
movq 0x8(%rcx), %rdi
movq (%rdi), %rax
callq *0x20(%rax)
movl %eax, %r13d
cmpl $0x0, -0x70(%rbp)
je 0x1db5a
testl %r13d, %r13d
jne 0x1db5a
movq -0x30(%rbp), %rax
movq 0x8(%rax), %rdi
movq (%rdi), %rax
movl -0x70(%rbp), %esi
callq *0x28(%rax)
movl %eax, %r13d
testl %r13d, %r13d
jne 0x1d80e
movq -0x58(%rbp), %rax
movl %r14d, 0x60(%rax)
xorl %r13d, %r13d
jmp 0x1d80e
movl %eax, %r13d
testl %eax, %eax
movq -0x40(%rbp), %rdi
jne 0x1d8cb
cmpb $0x0, 0x3f(%r14)
jne 0x1dba6
movq 0x8(%r14), %rdi
movq (%rdi), %rax
movl $0x4, %esi
movl $0x4, %edx
movl $0x9, %ecx
callq *0x70(%rax)
movq -0x40(%rbp), %rdi
xorl %r13d, %r13d
jmp 0x1d8cb
movl %eax, %r13d
movl -0x44(%rbp), %r15d
jmp 0x1d80e