LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O3/shifengbin[P]bishe/Output/../Persistence/sqlite3.c
// Function: sqlite3_vtab_config
SQLITE_CDECL sqlite3_vtab_config(sqlite3 *db, int op, ...){
  va_list ap;
  int rc = SQLITE_OK;

#ifdef SQLITE_ENABLE_API_ARMOR
  if( !sqlite3SafetyCheckOk(db) ) return SQLITE_MISUSE_BKPT;
#endif
  sqlite3_mutex_enter(db->mutex);
  va_start(ap, op);
  switch( op ){
    case SQLITE_VTAB_CONSTRAINT_SUPPORT: {
      VtabCtx *p = db->pVtabCtx;
      if( !p ){
        rc = SQLITE_MISUSE_BKPT;
      }else{
        assert( p->pTab==0 || (p->pTab->tabFlags & TF_Virtual)!=0 );
        p->pVTable->bConstraint = (u8)va_arg(ap, int);
      }
      break;
    }
    default:
      rc = SQLITE_MISUSE_BKPT;
      break;
  }
  va_end(ap);

  if( rc!=SQLITE_OK ) sqlite3Error(db, rc);
  sqlite3_mutex_leave(db->mutex);
  return rc;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
subq $0xd0, %rsp
movl %esi, %r14d
movq %rdi, %rbx
movq %rdx, -0xd0(%rbp)
movq %rcx, -0xc8(%rbp)
movq %r8, -0xc0(%rbp)
movq %r9, -0xb8(%rbp)
testb %al, %al
je 0x175e8
movaps %xmm0, -0xb0(%rbp)
movaps %xmm1, -0xa0(%rbp)
movaps %xmm2, -0x90(%rbp)
movaps %xmm3, -0x80(%rbp)
movaps %xmm4, -0x70(%rbp)
movaps %xmm5, -0x60(%rbp)
movaps %xmm6, -0x50(%rbp)
movaps %xmm7, -0x40(%rbp)
movq 0x18(%rdi), %rdi
testq %rdi, %rdi
je 0x175f7
callq *0x79dc1(%rip)          # 0x913b8
leaq -0xe0(%rbp), %rax
movq %rax, -0x20(%rbp)
leaq 0x10(%rbp), %rax
movq %rax, -0x28(%rbp)
movabsq $0x3000000010, %rax     # imm = 0x3000000010
movq %rax, -0x30(%rbp)
movl $0x1d0d8, %edx          # imm = 0x1D0D8
cmpl $0x1, %r14d
jne 0x1764c
movq 0x1c0(%rbx), %rax
testq %rax, %rax
je 0x17647
movl -0x30(%rbp), %edx
cmpq $0x28, %rdx
ja 0x17699
movq %rdx, %rcx
addq -0x20(%rbp), %rcx
addl $0x8, %edx
movl %edx, -0x30(%rbp)
jmp 0x176a5
movl $0x1d0d0, %edx          # imm = 0x1D0D0
leaq 0x67e4f(%rip), %rsi     # 0x7f4a2
leaq 0x63b33(%rip), %rcx     # 0x7b18d
movl $0x15, %r14d
movl $0x15, %edi
xorl %eax, %eax
callq 0xa4c0
movl $0x15, 0x44(%rbx)
movq 0x140(%rbx), %rdi
testq %rdi, %rdi
je 0x176b0
movzwl 0x8(%rdi), %eax
testl $0x2460, %eax           # imm = 0x2460
je 0x17691
callq 0x2a210
jmp 0x176b0
movw $0x1, 0x8(%rdi)
jmp 0x176b0
movq -0x28(%rbp), %rcx
leaq 0x8(%rcx), %rdx
movq %rdx, -0x28(%rbp)
movb (%rcx), %cl
movq (%rax), %rax
movb %cl, 0x1c(%rax)
xorl %r14d, %r14d
movq 0x18(%rbx), %rdi
testq %rdi, %rdi
je 0x176bf
callq *0x79d09(%rip)          # 0x913c8
movl %r14d, %eax
addq $0xd0, %rsp
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/shifengbin[P]bishe/Output/../Persistence/sqlite3.c
// Function: sqlite3_busy_handler
SQLITE_STDCALL sqlite3_busy_handler(
  sqlite3 *db,
  int (*xBusy)(void*,int),
  void *pArg
){
#ifdef SQLITE_ENABLE_API_ARMOR
  if( !sqlite3SafetyCheckOk(db) ) return SQLITE_MISUSE_BKPT;
#endif
  sqlite3_mutex_enter(db->mutex);
  db->busyHandler.xFunc = xBusy;
  db->busyHandler.pArg = pArg;
  db->busyHandler.nBusy = 0;
  db->busyTimeout = 0;
  sqlite3_mutex_leave(db->mutex);
  return SQLITE_OK;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
movq 0x18(%rdi), %rdi
testq %rdi, %rdi
je 0x18b0f
callq *0x788d6(%rip)          # 0x913b8
movq 0x18(%rbx), %rdi
movq %r15, 0x2a8(%rbx)
movq %r14, 0x2b0(%rbx)
xorl %eax, %eax
movl %eax, 0x2b8(%rbx)
movl %eax, 0x308(%rbx)
testq %rdi, %rdi
je 0x18b2b
callq *0x788bb(%rip)          # 0x913c8
jmp 0x18b2b
movq %r15, 0x2a8(%rbx)
movq %r14, 0x2b0(%rbx)
xorl %eax, %eax
movl %eax, 0x2b8(%rbx)
movl %eax, 0x308(%rbx)
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/shifengbin[P]bishe/Output/../Persistence/sqlite3.c
// Function: sqlite3_progress_handler
SQLITE_STDCALL sqlite3_progress_handler(
  sqlite3 *db, 
  int nOps,
  int (*xProgress)(void*), 
  void *pArg
){
#ifdef SQLITE_ENABLE_API_ARMOR
  if( !sqlite3SafetyCheckOk(db) ){
    (void)SQLITE_MISUSE_BKPT;
    return;
  }
#endif
  sqlite3_mutex_enter(db->mutex);
  if( nOps>0 ){
    db->xProgress = xProgress;
    db->nProgressOps = (unsigned)nOps;
    db->pProgressArg = pArg;
  }else{
    db->xProgress = 0;
    db->nProgressOps = 0;
    db->pProgressArg = 0;
  }
  sqlite3_mutex_leave(db->mutex);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rcx, %rbx
movq %rdx, %r15
movl %esi, %r12d
movq %rdi, %r14
movq 0x18(%rdi), %rdi
testq %rdi, %rdi
je 0x18b5e
callq *0x7885a(%rip)          # 0x913b8
xorl %eax, %eax
testl %r12d, %r12d
cmovleq %rax, %r15
movl $0x0, %ecx
cmovgl %r12d, %ecx
cmovleq %rax, %rbx
movq %r15, 0x190(%r14)
movl %ecx, 0x1a0(%r14)
movq %rbx, 0x198(%r14)
movq 0x18(%r14), %rdi
testq %rdi, %rdi
je 0x18ba0
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmpq *0x78828(%rip)          # 0x913c8
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/shifengbin[P]bishe/Output/../Persistence/sqlite3.c
// Function: sqlite3_busy_timeout
SQLITE_STDCALL sqlite3_busy_timeout(sqlite3 *db, int ms){
#ifdef SQLITE_ENABLE_API_ARMOR
  if( !sqlite3SafetyCheckOk(db) ) return SQLITE_MISUSE_BKPT;
#endif
  if( ms>0 ){
    sqlite3_busy_handler(db, sqliteDefaultBusyCallback, (void*)db);
    db->busyTimeout = ms;
  }else{
    sqlite3_busy_handler(db, 0, 0);
  }
  return SQLITE_OK;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq %rdi, %rbx
testl %esi, %esi
jle 0x18bd5
movl %esi, %r14d
leaq 0x27(%rip), %rsi        # 0x18be8
movq %rbx, %rdi
movq %rbx, %rdx
callq 0xa200
movl %r14d, 0x308(%rbx)
jmp 0x18be1
movq %rbx, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0xa200
xorl %eax, %eax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/shifengbin[P]bishe/Output/../Persistence/sqlite3.c
// Function: sqlite3_create_function_v2
SQLITE_STDCALL sqlite3_create_function_v2(
  sqlite3 *db,
  const char *zFunc,
  int nArg,
  int enc,
  void *p,
  void (*xFunc)(sqlite3_context*,int,sqlite3_value **),
  void (*xStep)(sqlite3_context*,int,sqlite3_value **),
  void (*xFinal)(sqlite3_context*),
  void (*xDestroy)(void *)
){
  int rc = SQLITE_ERROR;
  FuncDestructor *pArg = 0;

#ifdef SQLITE_ENABLE_API_ARMOR
  if( !sqlite3SafetyCheckOk(db) ){
    return SQLITE_MISUSE_BKPT;
  }
#endif
  sqlite3_mutex_enter(db->mutex);
  if( xDestroy ){
    pArg = (FuncDestructor *)sqlite3DbMallocZero(db, sizeof(FuncDestructor));
    if( !pArg ){
      xDestroy(p);
      goto out;
    }
    pArg->xDestroy = xDestroy;
    pArg->pUserData = p;
  }
  rc = sqlite3CreateFunc(db, zFunc, nArg, enc, p, xFunc, xStep, xFinal, pArg);
  if( pArg && pArg->nRef==0 ){
    assert( rc!=SQLITE_OK );
    xDestroy(p);
    sqlite3DbFree(db, pArg);
  }

 out:
  rc = sqlite3ApiExit(db, rc);
  sqlite3_mutex_leave(db->mutex);
  return rc;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %r9, %r12
movq %r8, %r14
movl %ecx, -0x2c(%rbp)
movl %edx, %r13d
movq %rsi, %r15
movq %rdi, %rbx
movq 0x18(%rdi), %rdi
testq %rdi, %rdi
je 0x18c7a
callq *0x7873e(%rip)          # 0x913b8
cmpq $0x0, 0x20(%rbp)
je 0x18cf8
movq %r12, -0x38(%rbp)
movl $0x18, %esi
movq %rbx, %rdi
callq 0x145aa
testq %rax, %rax
je 0x18d24
movq %rax, %r12
movq $0x0, (%rax)
movq 0x20(%rbp), %rax
movq %rax, 0x8(%r12)
movq %r14, 0x10(%r12)
subq $0x8, %rsp
movq %rbx, %rdi
movq %r15, %rsi
movl %r13d, %edx
movl -0x2c(%rbp), %ecx
movq %r14, %r8
movq -0x38(%rbp), %r9
pushq %r12
pushq 0x18(%rbp)
pushq 0x10(%rbp)
callq 0x18d74
addq $0x20, %rsp
movl %eax, %r15d
cmpl $0x0, (%r12)
jne 0x18d30
movq %r14, %rdi
callq *0x20(%rbp)
movq %rbx, %rdi
movq %r12, %rsi
callq 0xb752
jmp 0x18d30
subq $0x8, %rsp
movq %rbx, %rdi
movq %r15, %rsi
movl %r13d, %edx
movl -0x2c(%rbp), %ecx
movq %r14, %r8
movq %r12, %r9
pushq $0x0
pushq 0x18(%rbp)
pushq 0x10(%rbp)
callq 0x18d74
addq $0x20, %rsp
movl %eax, %r15d
jmp 0x18d30
movq %r14, %rdi
callq *0x20(%rbp)
movl $0x1, %r15d
cmpl $0xc0a, %r15d           # imm = 0xC0A
je 0x18d45
cmpb $0x0, 0x51(%rbx)
jne 0x18d45
andl 0x48(%rbx), %r15d
jmp 0x18d53
movq %rbx, %rdi
callq 0x28667
movl $0x7, %r15d
movq 0x18(%rbx), %rdi
testq %rdi, %rdi
je 0x18d62
callq *0x78666(%rip)          # 0x913c8
movl %r15d, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/shifengbin[P]bishe/Output/../Persistence/sqlite3.c
// Function: sqlite3_overload_function
SQLITE_STDCALL sqlite3_overload_function(
  sqlite3 *db,
  const char *zName,
  int nArg
){
  int nName = sqlite3Strlen30(zName);
  int rc = SQLITE_OK;

#ifdef SQLITE_ENABLE_API_ARMOR
  if( !sqlite3SafetyCheckOk(db) || zName==0 || nArg<-2 ){
    return SQLITE_MISUSE_BKPT;
  }
#endif
  sqlite3_mutex_enter(db->mutex);
  if( sqlite3FindFunction(db, zName, nName, nArg, SQLITE_UTF8, 0)==0 ){
    rc = sqlite3CreateFunc(db, zName, nArg, SQLITE_UTF8,
                           0, sqlite3InvalidFunction, 0, 0, 0);
  }
  rc = sqlite3ApiExit(db, rc);
  sqlite3_mutex_leave(db->mutex);
  return rc;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movl %edx, %r14d
movq %rsi, %r15
movq %rdi, %rbx
testq %rsi, %rsi
je 0x1913e
movq %r15, %rdi
callq 0xa190
movq %rax, %r13
andl $0x3fffffff, %r13d      # imm = 0x3FFFFFFF
jmp 0x19141
xorl %r13d, %r13d
movq 0x18(%rbx), %rdi
testq %rdi, %rdi
je 0x19150
callq *0x78268(%rip)          # 0x913b8
xorl %r12d, %r12d
movq %rbx, %rdi
movq %r15, %rsi
movl %r13d, %edx
movl %r14d, %ecx
movl $0x1, %r8d
xorl %r9d, %r9d
callq 0x191e6
testq %rax, %rax
jne 0x191a2
xorps %xmm0, %xmm0
movups %xmm0, (%rsp)
movq $0x0, 0x10(%rsp)
leaq 0x241(%rip), %r9        # 0x193ca
movq %rbx, %rdi
movq %r15, %rsi
movl %r14d, %edx
movl $0x1, %ecx
xorl %r8d, %r8d
callq 0x18d74
movl %eax, %r12d
cmpl $0xc0a, %r12d           # imm = 0xC0A
je 0x191b7
cmpb $0x0, 0x51(%rbx)
jne 0x191b7
andl 0x48(%rbx), %r12d
jmp 0x191c5
movq %rbx, %rdi
callq 0x28667
movl $0x7, %r12d
movq 0x18(%rbx), %rdi
testq %rdi, %rdi
je 0x191d4
callq *0x781f4(%rip)          # 0x913c8
movl %r12d, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/shifengbin[P]bishe/Output/../Persistence/sqlite3.c
// Function: sqlite3_trace
SQLITE_API void *SQLITE_STDCALL sqlite3_trace(sqlite3 *db, void (*xTrace)(void*,const char*), void *pArg){
  void *pOld;

#ifdef SQLITE_ENABLE_API_ARMOR
  if( !sqlite3SafetyCheckOk(db) ){
    (void)SQLITE_MISUSE_BKPT;
    return 0;
  }
#endif
  sqlite3_mutex_enter(db->mutex);
  pOld = db->pTraceArg;
  db->xTrace = xTrace;
  db->pTraceArg = pArg;
  sqlite3_mutex_leave(db->mutex);
  return pOld;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdx, %r14
movq %rsi, %r12
movq %rdi, %r15
movq 0x18(%rdi), %rdi
testq %rdi, %rdi
je 0x19469
callq *0x77f75(%rip)          # 0x913b8
movq 0x18(%r15), %rdi
movq 0xd0(%r15), %rbx
movq %r12, 0xc8(%r15)
movq %r14, 0xd0(%r15)
testq %rdi, %rdi
je 0x1947e
callq *0x77f61(%rip)          # 0x913c8
jmp 0x1947e
movq 0xd0(%r15), %rbx
movq %r12, 0xc8(%r15)
movq %r14, 0xd0(%r15)
movq %rbx, %rax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/shifengbin[P]bishe/Output/../Persistence/sqlite3.c
// Function: sqlite3_profile
SQLITE_API void *SQLITE_STDCALL sqlite3_profile(
  sqlite3 *db,
  void (*xProfile)(void*,const char*,sqlite_uint64),
  void *pArg
){
  void *pOld;

#ifdef SQLITE_ENABLE_API_ARMOR
  if( !sqlite3SafetyCheckOk(db) ){
    (void)SQLITE_MISUSE_BKPT;
    return 0;
  }
#endif
  sqlite3_mutex_enter(db->mutex);
  pOld = db->pProfileArg;
  db->xProfile = xProfile;
  db->pProfileArg = pArg;
  sqlite3_mutex_leave(db->mutex);
  return pOld;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdx, %r14
movq %rsi, %r12
movq %rdi, %r15
movq 0x18(%rdi), %rdi
testq %rdi, %rdi
je 0x194d3
callq *0x77f0b(%rip)          # 0x913b8
movq 0x18(%r15), %rdi
movq 0xe0(%r15), %rbx
movq %r12, 0xd8(%r15)
movq %r14, 0xe0(%r15)
testq %rdi, %rdi
je 0x194e8
callq *0x77ef7(%rip)          # 0x913c8
jmp 0x194e8
movq 0xe0(%r15), %rbx
movq %r12, 0xd8(%r15)
movq %r14, 0xe0(%r15)
movq %rbx, %rax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/shifengbin[P]bishe/Output/../Persistence/sqlite3.c
// Function: sqlite3_commit_hook
SQLITE_API void *SQLITE_STDCALL sqlite3_commit_hook(
  sqlite3 *db,              /* Attach the hook to this database */
  int (*xCallback)(void*),  /* Function to invoke on each commit */
  void *pArg                /* Argument to the function */
){
  void *pOld;

#ifdef SQLITE_ENABLE_API_ARMOR
  if( !sqlite3SafetyCheckOk(db) ){
    (void)SQLITE_MISUSE_BKPT;
    return 0;
  }
#endif
  sqlite3_mutex_enter(db->mutex);
  pOld = db->pCommitArg;
  db->xCommitCallback = xCallback;
  db->pCommitArg = pArg;
  sqlite3_mutex_leave(db->mutex);
  return pOld;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdx, %r14
movq %rsi, %r12
movq %rdi, %r15
movq 0x18(%rdi), %rdi
testq %rdi, %rdi
je 0x1953d
callq *0x77ea1(%rip)          # 0x913b8
movq 0x18(%r15), %rdi
movq 0xe8(%r15), %rbx
movq %r12, 0xf0(%r15)
movq %r14, 0xe8(%r15)
testq %rdi, %rdi
je 0x19552
callq *0x77e8d(%rip)          # 0x913c8
jmp 0x19552
movq 0xe8(%r15), %rbx
movq %r12, 0xf0(%r15)
movq %r14, 0xe8(%r15)
movq %rbx, %rax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/shifengbin[P]bishe/Output/../Persistence/sqlite3.c
// Function: sqlite3_update_hook
SQLITE_API void *SQLITE_STDCALL sqlite3_update_hook(
  sqlite3 *db,              /* Attach the hook to this database */
  void (*xCallback)(void*,int,char const *,char const *,sqlite_int64),
  void *pArg                /* Argument to the function */
){
  void *pRet;

#ifdef SQLITE_ENABLE_API_ARMOR
  if( !sqlite3SafetyCheckOk(db) ){
    (void)SQLITE_MISUSE_BKPT;
    return 0;
  }
#endif
  sqlite3_mutex_enter(db->mutex);
  pRet = db->pUpdateArg;
  db->xUpdateCallback = xCallback;
  db->pUpdateArg = pArg;
  sqlite3_mutex_leave(db->mutex);
  return pRet;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdx, %r14
movq %rsi, %r12
movq %rdi, %r15
movq 0x18(%rdi), %rdi
testq %rdi, %rdi
je 0x195a7
callq *0x77e37(%rip)          # 0x913b8
movq 0x18(%r15), %rdi
movq 0x108(%r15), %rbx
movq %r12, 0x110(%r15)
movq %r14, 0x108(%r15)
testq %rdi, %rdi
je 0x195bc
callq *0x77e23(%rip)          # 0x913c8
jmp 0x195bc
movq 0x108(%r15), %rbx
movq %r12, 0x110(%r15)
movq %r14, 0x108(%r15)
movq %rbx, %rax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/shifengbin[P]bishe/Output/../Persistence/sqlite3.c
// Function: sqlite3_rollback_hook
SQLITE_API void *SQLITE_STDCALL sqlite3_rollback_hook(
  sqlite3 *db,              /* Attach the hook to this database */
  void (*xCallback)(void*), /* Callback function */
  void *pArg                /* Argument to the function */
){
  void *pRet;

#ifdef SQLITE_ENABLE_API_ARMOR
  if( !sqlite3SafetyCheckOk(db) ){
    (void)SQLITE_MISUSE_BKPT;
    return 0;
  }
#endif
  sqlite3_mutex_enter(db->mutex);
  pRet = db->pRollbackArg;
  db->xRollbackCallback = xCallback;
  db->pRollbackArg = pArg;
  sqlite3_mutex_leave(db->mutex);
  return pRet;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdx, %r14
movq %rsi, %r12
movq %rdi, %r15
movq 0x18(%rdi), %rdi
testq %rdi, %rdi
je 0x19611
callq *0x77dcd(%rip)          # 0x913b8
movq 0x18(%r15), %rdi
movq 0xf8(%r15), %rbx
movq %r12, 0x100(%r15)
movq %r14, 0xf8(%r15)
testq %rdi, %rdi
je 0x19626
callq *0x77db9(%rip)          # 0x913c8
jmp 0x19626
movq 0xf8(%r15), %rbx
movq %r12, 0x100(%r15)
movq %r14, 0xf8(%r15)
movq %rbx, %rax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/shifengbin[P]bishe/Output/../Persistence/sqlite3.c
// Function: sqlite3_wal_autocheckpoint
SQLITE_STDCALL sqlite3_wal_autocheckpoint(sqlite3 *db, int nFrame){
#ifdef SQLITE_OMIT_WAL
  UNUSED_PARAMETER(db);
  UNUSED_PARAMETER(nFrame);
#else
#ifdef SQLITE_ENABLE_API_ARMOR
  if( !sqlite3SafetyCheckOk(db) ) return SQLITE_MISUSE_BKPT;
#endif
  if( nFrame>0 ){
    sqlite3_wal_hook(db, sqlite3WalDefaultHook, SQLITE_INT_TO_PTR(nFrame));
  }else{
    sqlite3_wal_hook(db, 0, 0);
  }
#endif
  return SQLITE_OK;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq %rdi, %rbx
testl %esi, %esi
jle 0x1966d
movl %esi, %r14d
movq 0x18(%rbx), %rdi
testq %rdi, %rdi
je 0x19697
callq *0x77d66(%rip)          # 0x913b8
movq 0x18(%rbx), %rdi
leaq 0xcc(%rip), %rax        # 0x19729
movq %rax, 0x118(%rbx)
movq %r14, 0x120(%rbx)
jmp 0x1968a
movq 0x18(%rbx), %rdi
testq %rdi, %rdi
je 0x196ae
callq *0x77d3c(%rip)          # 0x913b8
movq 0x18(%rbx), %rdi
xorps %xmm0, %xmm0
movups %xmm0, 0x118(%rbx)
testq %rdi, %rdi
je 0x196b8
callq *0x77d33(%rip)          # 0x913c8
jmp 0x196b8
leaq 0x8b(%rip), %rax        # 0x19729
movq %rax, 0x118(%rbx)
movq %r14, 0x120(%rbx)
jmp 0x196b8
xorps %xmm0, %xmm0
movups %xmm0, 0x118(%rbx)
xorl %eax, %eax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/shifengbin[P]bishe/Output/../Persistence/sqlite3.c
// Function: sqlite3_wal_hook
SQLITE_API void *SQLITE_STDCALL sqlite3_wal_hook(
  sqlite3 *db,                    /* Attach the hook to this db handle */
  int(*xCallback)(void *, sqlite3*, const char*, int),
  void *pArg                      /* First argument passed to xCallback() */
){
#ifndef SQLITE_OMIT_WAL
  void *pRet;
#ifdef SQLITE_ENABLE_API_ARMOR
  if( !sqlite3SafetyCheckOk(db) ){
    (void)SQLITE_MISUSE_BKPT;
    return 0;
  }
#endif
  sqlite3_mutex_enter(db->mutex);
  pRet = db->pWalArg;
  db->xWalCallback = xCallback;
  db->pWalArg = pArg;
  sqlite3_mutex_leave(db->mutex);
  return pRet;
#else
  return 0;
#endif
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdx, %r14
movq %rsi, %r12
movq %rdi, %r15
movq 0x18(%rdi), %rdi
testq %rdi, %rdi
je 0x19708
callq *0x77cd6(%rip)          # 0x913b8
movq 0x18(%r15), %rdi
movq 0x120(%r15), %rbx
movq %r12, 0x118(%r15)
movq %r14, 0x120(%r15)
testq %rdi, %rdi
je 0x1971d
callq *0x77cc2(%rip)          # 0x913c8
jmp 0x1971d
movq 0x120(%r15), %rbx
movq %r12, 0x118(%r15)
movq %r14, 0x120(%r15)
movq %rbx, %rax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/shifengbin[P]bishe/Output/../Persistence/sqlite3.c
// Function: sqlite3_create_collation_v2
SQLITE_STDCALL sqlite3_create_collation_v2(
  sqlite3* db, 
  const char *zName, 
  int enc, 
  void* pCtx,
  int(*xCompare)(void*,int,const void*,int,const void*),
  void(*xDel)(void*)
){
  int rc;

#ifdef SQLITE_ENABLE_API_ARMOR
  if( !sqlite3SafetyCheckOk(db) || zName==0 ) return SQLITE_MISUSE_BKPT;
#endif
  sqlite3_mutex_enter(db->mutex);
  assert( !db->mallocFailed );
  rc = createCollation(db, zName, (u8)enc, pCtx, xCompare, xDel);
  rc = sqlite3ApiExit(db, rc);
  sqlite3_mutex_leave(db->mutex);
  return rc;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %edx, %r14d
movq %rsi, %r13
movq %rdi, %rbx
movq 0x18(%rdi), %rdi
testq %rdi, %rdi
je 0x1a483
movq %r9, %r15
movq %r8, %r12
movq %rcx, -0x30(%rbp)
callq *0x76f3f(%rip)          # 0x913b8
movq -0x30(%rbp), %rcx
movq %r12, %r8
movq %r15, %r9
movzbl %r14b, %edx
movq %rbx, %rdi
movq %r13, %rsi
callq 0x1a4d0
cmpb $0x0, 0x51(%rbx)
je 0x1a4a8
movq %rbx, %rdi
callq 0x28667
movl $0x7, %r14d
jmp 0x1a4af
movl %eax, %r14d
andl 0x48(%rbx), %r14d
movq 0x18(%rbx), %rdi
testq %rdi, %rdi
je 0x1a4be
callq *0x76f0a(%rip)          # 0x913c8
movl %r14d, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/shifengbin[P]bishe/Output/../Persistence/sqlite3.c
// Function: sqlite3_collation_needed
SQLITE_STDCALL sqlite3_collation_needed(
  sqlite3 *db, 
  void *pCollNeededArg, 
  void(*xCollNeeded)(void*,sqlite3*,int eTextRep,const char*)
){
#ifdef SQLITE_ENABLE_API_ARMOR
  if( !sqlite3SafetyCheckOk(db) ) return SQLITE_MISUSE_BKPT;
#endif
  sqlite3_mutex_enter(db->mutex);
  db->xCollNeeded = xCollNeeded;
  db->xCollNeeded16 = 0;
  db->pCollNeededArg = pCollNeededArg;
  sqlite3_mutex_leave(db->mutex);
  return SQLITE_OK;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdx, %r15
movq %rsi, %rbx
movq %rdi, %r14
movq 0x18(%rdi), %rdi
testq %rdi, %rdi
je 0x1a783
callq *0x76c5f(%rip)          # 0x913b8
movq 0x18(%r14), %rdi
movq %r15, 0x128(%r14)
movq $0x0, 0x130(%r14)
movq %rbx, 0x138(%r14)
testq %rdi, %rdi
je 0x1a79c
callq *0x76c47(%rip)          # 0x913c8
jmp 0x1a79c
movq %r15, 0x128(%r14)
movq $0x0, 0x130(%r14)
movq %rbx, 0x138(%r14)
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/shifengbin[P]bishe/Output/../Persistence/sqlite3.c
// Function: sqlite3_collation_needed16
SQLITE_STDCALL sqlite3_collation_needed16(
  sqlite3 *db, 
  void *pCollNeededArg, 
  void(*xCollNeeded16)(void*,sqlite3*,int eTextRep,const void*)
){
#ifdef SQLITE_ENABLE_API_ARMOR
  if( !sqlite3SafetyCheckOk(db) ) return SQLITE_MISUSE_BKPT;
#endif
  sqlite3_mutex_enter(db->mutex);
  db->xCollNeeded = 0;
  db->xCollNeeded16 = xCollNeeded16;
  db->pCollNeededArg = pCollNeededArg;
  sqlite3_mutex_leave(db->mutex);
  return SQLITE_OK;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdx, %r15
movq %rsi, %rbx
movq %rdi, %r14
movq 0x18(%rdi), %rdi
testq %rdi, %rdi
je 0x1a7f5
callq *0x76bed(%rip)          # 0x913b8
movq 0x18(%r14), %rdi
movq $0x0, 0x128(%r14)
movq %r15, 0x130(%r14)
movq %rbx, 0x138(%r14)
testq %rdi, %rdi
je 0x1a80e
callq *0x76bd5(%rip)          # 0x913c8
jmp 0x1a80e
movq $0x0, 0x128(%r14)
movq %r15, 0x130(%r14)
movq %rbx, 0x138(%r14)
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/shifengbin[P]bishe/Output/../Persistence/sqlite3.c
// Function: sqlite3Init
SQLITE_PRIVATE int sqlite3Init(sqlite3 *db, char **pzErrMsg){
  int i, rc;
  int commit_internal = !(db->flags&SQLITE_InternChanges);
  
  assert( sqlite3_mutex_held(db->mutex) );
  assert( sqlite3BtreeHoldsMutex(db->aDb[0].pBt) );
  assert( db->init.busy==0 );
  rc = SQLITE_OK;
  db->init.busy = 1;
  ENC(db) = SCHEMA_ENC(db);
  for(i=0; rc==SQLITE_OK && i<db->nDb; i++){
    if( DbHasProperty(db, i, DB_SchemaLoaded) || i==1 ) continue;
    rc = sqlite3InitOne(db, i, pzErrMsg);
    if( rc ){
      sqlite3ResetOneSchema(db, i);
    }
  }

  /* Once all the other databases have been initialized, load the schema
  ** for the TEMP database. This is loaded last, as the TEMP database
  ** schema may contain references to objects in other databases.
  */
#ifndef SQLITE_OMIT_TEMPDB
  assert( db->nDb>1 );
  if( rc==SQLITE_OK && !DbHasProperty(db, 1, DB_SchemaLoaded) ){
    rc = sqlite3InitOne(db, 1, pzErrMsg);
    if( rc ){
      sqlite3ResetOneSchema(db, 1);
    }
  }
#endif

  db->init.busy = 0;
  if( rc==SQLITE_OK && commit_internal ){
    sqlite3CommitInternalChanges(db);
  }

  return rc; 
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
movl 0x2c(%rdi), %eax
movl %eax, -0x2c(%rbp)
movb $0x1, 0xa1(%rdi)
movq 0x20(%rdi), %rax
movq 0x18(%rax), %rcx
movb 0x71(%rcx), %cl
movb %cl, 0x4e(%rdi)
cmpl $0x0, 0x28(%rdi)
jle 0x1ab58
movl $0x18, %r13d
xorl %r15d, %r15d
movq (%rax,%r13), %rax
cmpq $0x1, %r15
sete %cl
orb 0x72(%rax), %cl
testb $0x1, %cl
jne 0x1ab44
movq %rbx, %rdi
movl %r15d, %esi
movq %r14, %rdx
callq 0x766f1
testl %eax, %eax
jne 0x1ab9e
incq %r15
movslq 0x28(%rbx), %rcx
movq 0x20(%rbx), %rax
addq $0x20, %r13
cmpq %rcx, %r15
jl 0x1ab1f
movq 0x38(%rax), %rax
testb $0x1, 0x72(%rax)
jne 0x1ab88
movq %rbx, %rdi
movl $0x1, %esi
movq %r14, %rdx
callq 0x766f1
testl %eax, %eax
je 0x1ab88
movl %eax, %r12d
movq 0x20(%rbx), %rax
movq 0x38(%rax), %rdi
callq 0x36a5c
jmp 0x1abac
xorl %r12d, %r12d
movb $0x0, 0xa1(%rbx)
testb $0x2, -0x2c(%rbp)
jne 0x1abb3
andb $-0x3, 0x2c(%rbx)
jmp 0x1abb3
movl %eax, %r12d
movq %rbx, %rdi
movl %r15d, %esi
callq 0x325bb
movb $0x0, 0xa1(%rbx)
movl %r12d, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/shifengbin[P]bishe/Output/../Persistence/sqlite3.c
// Function: sqlite3FindTable
SQLITE_PRIVATE Table *sqlite3FindTable(sqlite3 *db, const char *zName, const char *zDatabase){
  Table *p = 0;
  int i;

  /* All mutexes are required for schema access.  Make sure we hold them. */
  assert( zDatabase!=0 || sqlite3BtreeHoldsAllMutexes(db) );
#if SQLITE_USER_AUTHENTICATION
  /* Only the admin user is allowed to know that the sqlite_user table
  ** exists */
  if( db->auth.authLevel<UAUTH_Admin && sqlite3UserAuthTable(zName)!=0 ){
    return 0;
  }
#endif
  for(i=OMIT_TEMPDB; i<db->nDb; i++){
    int j = (i<2) ? i^1 : i;   /* Search TEMP before MAIN */
    if( zDatabase!=0 && sqlite3StrICmp(zDatabase, db->aDb[j].zName) ) continue;
    assert( sqlite3SchemaMutexHeld(db, j, 0) );
    p = sqlite3HashFind(&db->aDb[j].pSchema->tblHash, zName);
    if( p ) break;
  }
  return p;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rsi, -0x30(%rbp)
movl 0x28(%rdi), %r12d
testl %r12d, %r12d
jle 0x1ac48
movq %rdx, %rbx
movq 0x20(%rdi), %r13
xorl %r15d, %r15d
xorl %r14d, %r14d
cmpl $0x2, %r15d
setb %r14b
xorl %r15d, %r14d
testq %rbx, %rbx
je 0x1ac18
movq %r14, %rax
shlq $0x5, %rax
movq (%r13,%rax), %rsi
movq %rbx, %rdi
callq 0xa400
testl %eax, %eax
jne 0x1ac40
shlq $0x5, %r14
movq 0x18(%r13,%r14), %rdi
addq $0x8, %rdi
movq -0x30(%rbp), %rsi
leaq -0x34(%rbp), %rdx
callq 0x3c196
testq %rax, %rax
je 0x1ac40
movq 0x10(%rax), %rax
testq %rax, %rax
jne 0x1ac4a
incl %r15d
cmpl %r15d, %r12d
jne 0x1abed
xorl %eax, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/shifengbin[P]bishe/Output/../Persistence/sqlite3.c
// Function: sqlite3_extended_result_codes
SQLITE_STDCALL sqlite3_extended_result_codes(sqlite3 *db, int onoff){
#ifdef SQLITE_ENABLE_API_ARMOR
  if( !sqlite3SafetyCheckOk(db) ) return SQLITE_MISUSE_BKPT;
#endif
  sqlite3_mutex_enter(db->mutex);
  db->errMask = onoff ? 0xffffffff : 0xff;
  sqlite3_mutex_leave(db->mutex);
  return SQLITE_OK;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movl %esi, %r14d
movq %rdi, %rbx
movq 0x18(%rdi), %rdi
testq %rdi, %rdi
je 0x1ad2a
callq *0x766ae(%rip)          # 0x913b8
xorl %eax, %eax
negl %r14d
sbbl %eax, %eax
movq 0x18(%rbx), %rdi
orl $0xff, %eax
movl %eax, 0x48(%rbx)
testq %rdi, %rdi
je 0x1ad39
callq *0x766a0(%rip)          # 0x913c8
jmp 0x1ad39
xorl %eax, %eax
negl %r14d
sbbl %eax, %eax
orl $0xff, %eax
movl %eax, 0x48(%rbx)
xorl %eax, %eax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/shifengbin[P]bishe/Output/../Persistence/sqlite3.c
// Function: sqlite3_file_control
SQLITE_STDCALL sqlite3_file_control(sqlite3 *db, const char *zDbName, int op, void *pArg){
  int rc = SQLITE_ERROR;
  Btree *pBtree;

#ifdef SQLITE_ENABLE_API_ARMOR
  if( !sqlite3SafetyCheckOk(db) ) return SQLITE_MISUSE_BKPT;
#endif
  sqlite3_mutex_enter(db->mutex);
  pBtree = sqlite3DbNameToBtree(db, zDbName);
  if( pBtree ){
    Pager *pPager;
    sqlite3_file *fd;
    sqlite3BtreeEnter(pBtree);
    pPager = sqlite3BtreePager(pBtree);
    assert( pPager!=0 );
    fd = sqlite3PagerFile(pPager);
    assert( fd!=0 );
    if( op==SQLITE_FCNTL_FILE_POINTER ){
      *(sqlite3_file**)pArg = fd;
      rc = SQLITE_OK;
    }else if( op==SQLITE_FCNTL_VFS_POINTER ){
      *(sqlite3_vfs**)pArg = sqlite3PagerVfs(pPager);
      rc = SQLITE_OK;
    }else if( op==SQLITE_FCNTL_JOURNAL_POINTER ){
      *(sqlite3_file**)pArg = sqlite3PagerJrnlFile(pPager);
      rc = SQLITE_OK;
    }else if( fd->pMethods ){
      rc = sqlite3OsFileControl(fd, op, pArg);
    }else{
      rc = SQLITE_NOTFOUND;
    }
    sqlite3BtreeLeave(pBtree);
  }
  sqlite3_mutex_leave(db->mutex);
  return rc;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rcx, %r15
movl %edx, %r12d
movq %rsi, %r14
movq %rdi, %rbx
movq 0x18(%rdi), %rdi
testq %rdi, %rdi
je 0x1ad66
callq *0x76652(%rip)          # 0x913b8
movq %rbx, %rdi
movq %r14, %rsi
callq 0x1ae29
testq %rax, %rax
je 0x1adb4
movq %rax, %r14
cmpb $0x0, 0x11(%rax)
je 0x1ad92
incl 0x14(%r14)
cmpb $0x0, 0x12(%r14)
jne 0x1ad92
movq %r14, %rdi
callq 0x2520c
movq 0x8(%r14), %rax
movq (%rax), %rax
cmpl $0x1c, %r12d
je 0x1adbc
cmpl $0x1b, %r12d
je 0x1add2
movq 0x48(%rax), %rdi
cmpl $0x7, %r12d
jne 0x1ae0b
movq %rdi, (%r15)
jmp 0x1add8
movl $0x1, %r15d
jmp 0x1adf0
movq 0x118(%rax), %rcx
leaq 0x10(%rcx), %rdx
addq $0x50, %rax
testq %rcx, %rcx
cmovneq %rdx, %rax
movq (%rax), %rax
movq %rax, (%r15)
xorl %r15d, %r15d
cmpb $0x0, 0x11(%r14)
je 0x1adf0
decl 0x14(%r14)
jne 0x1adf0
movq %r14, %rdi
callq 0x25292
movq 0x18(%rbx), %rdi
testq %rdi, %rdi
je 0x1adff
callq *0x765c9(%rip)          # 0x913c8
movl %r15d, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq (%rdi), %rax
testq %rax, %rax
je 0x1ae21
movl %r12d, %esi
movq %r15, %rdx
callq *0x50(%rax)
movl %eax, %r15d
jmp 0x1addb
movl $0xc, %r15d
jmp 0x1addb
// File: /workspace/github_c_makefile_star2_O3/shifengbin[P]bishe/Output/../Persistence/sqlite3.c
// Function: sqlite3BtreeSetPageSize
SQLITE_PRIVATE int sqlite3BtreeSetPageSize(Btree *p, int pageSize, int nReserve, int iFix){
  int rc = SQLITE_OK;
  BtShared *pBt = p->pBt;
  assert( nReserve>=-1 && nReserve<=255 );
  sqlite3BtreeEnter(p);
#if SQLITE_HAS_CODEC
  if( nReserve>pBt->optimalReserve ) pBt->optimalReserve = (u8)nReserve;
#endif
  if( pBt->btsFlags & BTS_PAGESIZE_FIXED ){
    sqlite3BtreeLeave(p);
    return SQLITE_READONLY;
  }
  if( nReserve<0 ){
    nReserve = pBt->pageSize - pBt->usableSize;
  }
  assert( nReserve>=0 && nReserve<=255 );
  if( pageSize>=512 && pageSize<=SQLITE_MAX_PAGE_SIZE &&
        ((pageSize-1)&pageSize)==0 ){
    assert( (pageSize & 7)==0 );
    assert( !pBt->pCursor );
    pBt->pageSize = (u32)pageSize;
    freeTempSpace(pBt);
  }
  rc = sqlite3PagerSetPagesize(pBt->pPager, &pBt->pageSize, nReserve);
  pBt->usableSize = pBt->pageSize - (u16)nReserve;
  if( iFix ) pBt->btsFlags |= BTS_PAGESIZE_FIXED;
  sqlite3BtreeLeave(p);
  return rc;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %ecx, %r14d
movl %edx, %r15d
movl %esi, %r12d
movq %rdi, %rbx
movq 0x8(%rdi), %r13
cmpb $0x0, 0x11(%rdi)
je 0x1b767
incl 0x14(%rbx)
cmpb $0x0, 0x12(%rbx)
jne 0x1b767
movq %rbx, %rdi
callq 0x2520c
testb $0x2, 0x26(%r13)
jne 0x1b7fe
testl %r15d, %r15d
jns 0x1b77f
movl 0x30(%r13), %r15d
subl 0x34(%r13), %r15d
leal -0x200(%r12), %eax
cmpl $0xfe00, %eax           # imm = 0xFE00
ja 0x1b7c6
leal 0x1ffff(%r12), %eax
testl %r12d, %eax
jne 0x1b7c6
movl %r12d, 0x30(%r13)
movq 0x80(%r13), %rdi
testq %rdi, %rdi
je 0x1b7c6
addq $-0x4, %rdi
movq %rdi, 0x80(%r13)
callq 0x21bb2
movq $0x0, 0x80(%r13)
movq (%r13), %rdi
leaq 0x30(%r13), %rsi
movl %r15d, %edx
callq 0x1f2e1
movl %eax, %r12d
movl 0x30(%r13), %eax
movzwl %r15w, %ecx
subl %ecx, %eax
movl %eax, 0x34(%r13)
testl %r14d, %r14d
je 0x1b7f1
orb $0x2, 0x26(%r13)
cmpb $0x0, 0x11(%rbx)
je 0x1b81f
decl 0x14(%rbx)
jne 0x1b81f
jmp 0x1b80f
cmpb $0x0, 0x11(%rbx)
je 0x1b819
decl 0x14(%rbx)
movl $0x8, %r12d
jne 0x1b81f
movq %rbx, %rdi
callq 0x25292
jmp 0x1b81f
movl $0x8, %r12d
movl %r12d, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/shifengbin[P]bishe/Output/../Persistence/sqlite3.c
// Function: sqlite3ScratchMalloc
SQLITE_PRIVATE void *sqlite3ScratchMalloc(int n){
  void *p;
  assert( n>0 );

  sqlite3_mutex_enter(mem0.mutex);
  sqlite3StatusHighwater(SQLITE_STATUS_SCRATCH_SIZE, n);
  if( mem0.nScratchFree && sqlite3GlobalConfig.szScratch>=n ){
    p = mem0.pScratchFree;
    mem0.pScratchFree = mem0.pScratchFree->pNext;
    mem0.nScratchFree--;
    sqlite3StatusUp(SQLITE_STATUS_SCRATCH_USED, 1);
    sqlite3_mutex_leave(mem0.mutex);
  }else{
    sqlite3_mutex_leave(mem0.mutex);
    p = sqlite3Malloc(n);
    if( sqlite3GlobalConfig.bMemstat && p ){
      sqlite3_mutex_enter(mem0.mutex);
      sqlite3StatusUp(SQLITE_STATUS_SCRATCH_OVERFLOW, sqlite3MallocSize(p));
      sqlite3_mutex_leave(mem0.mutex);
    }
    sqlite3MemdebugSetType(p, MEMTYPE_SCRATCH);
  }
  assert( sqlite3_mutex_notheld(mem0.mutex) );


#if SQLITE_THREADSAFE==0 && !defined(NDEBUG)
  /* EVIDENCE-OF: R-12970-05880 SQLite will not use more than one scratch
  ** buffers per thread.
  **
  ** This can only be checked in single-threaded mode.
  */
  assert( scratchAllocOut==0 );
  if( p ) scratchAllocOut++;
#endif

  return p;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movl %edi, %r14d
movq 0x77816(%rip), %rdi     # 0x93058
testq %rdi, %rdi
je 0x1b84d
callq *0x75b6b(%rip)          # 0x913b8
movslq %r14d, %rbx
cmpq %rbx, 0x777e9(%rip)     # 0x93040
jge 0x1b860
movq %rbx, 0x777e0(%rip)     # 0x93040
movl 0x77812(%rip), %eax     # 0x93078
testl %eax, %eax
je 0x1b8b0
cmpl %r14d, 0x75c07(%rip)    # 0x91478
jl 0x1b8b0
movq 0x777f6(%rip), %rbx     # 0x93070
movq (%rbx), %rcx
movq %rcx, 0x777ec(%rip)     # 0x93070
decl %eax
movl %eax, 0x777ec(%rip)     # 0x93078
movq 0x77735(%rip), %rcx     # 0x92fc8
leaq 0x1(%rcx), %rax
movq %rax, 0x7772a(%rip)     # 0x92fc8
cmpq 0x77773(%rip), %rcx     # 0x93018
jl 0x1b91f
movq %rax, 0x7776a(%rip)     # 0x93018
jmp 0x1b91f
movq 0x777a1(%rip), %rdi     # 0x93058
testq %rdi, %rdi
je 0x1b8c2
callq *0x75b06(%rip)          # 0x913c8
movq %rbx, %rdi
callq 0xc0e2
movq %rax, %rbx
cmpl $0x0, 0x75a5c(%rip)     # 0x91330
setne %al
testq %rbx, %rbx
setne %cl
andb %al, %cl
cmpb $0x1, %cl
jne 0x1b931
movq 0x7776d(%rip), %rdi     # 0x93058
testq %rdi, %rdi
je 0x1b8f6
callq *0x75ac2(%rip)          # 0x913b8
movq %rbx, %rdi
callq *0x75a71(%rip)          # 0x91370
cltq
addq 0x776c8(%rip), %rax     # 0x92fd0
movq %rax, 0x776c1(%rip)     # 0x92fd0
cmpq 0x7770a(%rip), %rax     # 0x93020
jle 0x1b91f
movq %rax, 0x77701(%rip)     # 0x93020
movq 0x77732(%rip), %rdi     # 0x93058
testq %rdi, %rdi
je 0x1b931
callq *0x75a97(%rip)          # 0x913c8
movq %rbx, %rax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/shifengbin[P]bishe/Output/../Persistence/sqlite3.c
// Function: sqlite3ScratchFree
SQLITE_PRIVATE void sqlite3ScratchFree(void *p){
  if( p ){

#if SQLITE_THREADSAFE==0 && !defined(NDEBUG)
    /* Verify that no more than two scratch allocation per thread
    ** is outstanding at one time.  (This is only checked in the
    ** single-threaded case since checking in the multi-threaded case
    ** would be much more complicated.) */
    assert( scratchAllocOut>=1 && scratchAllocOut<=2 );
    scratchAllocOut--;
#endif

    if( SQLITE_WITHIN(p, sqlite3GlobalConfig.pScratch, mem0.pScratchEnd) ){
      /* Release memory from the SQLITE_CONFIG_SCRATCH allocation */
      ScratchFreeslot *pSlot;
      pSlot = (ScratchFreeslot*)p;
      sqlite3_mutex_enter(mem0.mutex);
      pSlot->pNext = mem0.pScratchFree;
      mem0.pScratchFree = pSlot;
      mem0.nScratchFree++;
      assert( mem0.nScratchFree <= (u32)sqlite3GlobalConfig.nScratch );
      sqlite3StatusDown(SQLITE_STATUS_SCRATCH_USED, 1);
      sqlite3_mutex_leave(mem0.mutex);
    }else{
      /* Release memory back to the heap */
      assert( sqlite3MemdebugHasType(p, MEMTYPE_SCRATCH) );
      assert( sqlite3MemdebugNoType(p, (u8)~MEMTYPE_SCRATCH) );
      sqlite3MemdebugSetType(p, MEMTYPE_HEAP);
      if( sqlite3GlobalConfig.bMemstat ){
        int iSize = sqlite3MallocSize(p);
        sqlite3_mutex_enter(mem0.mutex);
        sqlite3StatusDown(SQLITE_STATUS_SCRATCH_OVERFLOW, iSize);
        sqlite3StatusDown(SQLITE_STATUS_MEMORY_USED, iSize);
        sqlite3StatusDown(SQLITE_STATUS_MALLOC_COUNT, 1);
        sqlite3GlobalConfig.m.xFree(p);
        sqlite3_mutex_leave(mem0.mutex);
      }else{
        sqlite3GlobalConfig.m.xFree(p);
      }
    }
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
testq %rdi, %rdi
je 0x1ba08
movq %rdi, %rbx
cmpq %rdi, 0x75b1d(%rip)     # 0x91470
ja 0x1b979
cmpq %rbx, 0x7770c(%rip)     # 0x93068
jbe 0x1b979
movq 0x776f3(%rip), %rdi     # 0x93058
testq %rdi, %rdi
je 0x1b9d6
callq *0x75a48(%rip)          # 0x913b8
movq 0x776e1(%rip), %rdi     # 0x93058
jmp 0x1b9d8
cmpl $0x0, 0x759b0(%rip)     # 0x91330
je 0x1b9ca
movq %rbx, %rdi
callq *0x759e5(%rip)          # 0x91370
movl %eax, %r14d
movq 0x776c3(%rip), %rdi     # 0x93058
testq %rdi, %rdi
je 0x1b9a0
callq *0x75a18(%rip)          # 0x913b8
movslq %r14d, %rax
subq %rax, 0x77626(%rip)     # 0x92fd0
subq %rax, 0x775ff(%rip)     # 0x92fb0
decq 0x77640(%rip)           # 0x92ff8
movq %rbx, %rdi
callq *0x7599f(%rip)          # 0x91360
movq 0x77690(%rip), %rdi     # 0x93058
jmp 0x1b9f6
leaq 0x7598f(%rip), %rax     # 0x91360
movq %rbx, %rdi
jmp 0x1ba02
xorl %edi, %edi
movq 0x77691(%rip), %rax     # 0x93070
movq %rax, (%rbx)
movq %rbx, 0x77687(%rip)     # 0x93070
incl 0x77689(%rip)           # 0x93078
decq 0x775d2(%rip)           # 0x92fc8
testq %rdi, %rdi
je 0x1ba08
leaq 0x759c6(%rip), %rax     # 0x913c8
popq %rbx
popq %r14
popq %rbp
jmpq *(%rax)
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/shifengbin[P]bishe/Output/../Persistence/sqlite3.c
// Function: sqlite3_uri_parameter
SQLITE_API const char *SQLITE_STDCALL sqlite3_uri_parameter(const char *zFilename, const char *zParam){
  if( zFilename==0 || zParam==0 ) return 0;
  zFilename += sqlite3Strlen30(zFilename) + 1;
  while( zFilename[0] ){
    int x = strcmp(zFilename, zParam);
    zFilename += sqlite3Strlen30(zFilename) + 1;
    if( x==0 ) return zFilename;
    zFilename += sqlite3Strlen30(zFilename) + 1;
  }
  return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
testq %rdi, %rdi
sete %al
testq %rsi, %rsi
sete %cl
orb %al, %cl
jne 0x1ba84
movq %rsi, %rbx
movq %rdi, %r14
callq 0xa190
andl $0x3fffffff, %eax       # imm = 0x3FFFFFFF
cmpb $0x0, 0x1(%r14,%rax)
je 0x1ba84
addq %rax, %r14
incq %r14
movq %r14, %rdi
movq %rbx, %rsi
callq 0xa2c0
movl %eax, %r15d
movq %r14, %rdi
callq 0xa190
andl $0x3fffffff, %eax       # imm = 0x3FFFFFFF
addq %rax, %r14
incq %r14
testl %r15d, %r15d
je 0x1ba87
movq %r14, %rdi
callq 0xa190
andl $0x3fffffff, %eax       # imm = 0x3FFFFFFF
addq %rax, %r14
incq %r14
cmpb $0x0, (%r14)
jne 0x1ba45
xorl %r14d, %r14d
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/shifengbin[P]bishe/Output/../Persistence/sqlite3.c
// Function: sqlite3_uri_int64
SQLITE_STDCALL sqlite3_uri_int64(
  const char *zFilename,    /* Filename as passed to xOpen */
  const char *zParam,       /* URI parameter sought */
  sqlite3_int64 bDflt       /* return if parameter is missing */
){
  const char *z = sqlite3_uri_parameter(zFilename, zParam);
  sqlite3_int64 v;
  if( z && sqlite3DecOrHexToI64(z, &v)==SQLITE_OK ){
    bDflt = v;
  }
  return bDflt;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq %rdx, %rbx
callq 0xa310
testq %rax, %rax
je 0x1baf6
leaq -0x10(%rbp), %rsi
movq %rax, %rdi
callq 0x1bb00
testl %eax, %eax
jne 0x1baf6
movq -0x10(%rbp), %rbx
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/shifengbin[P]bishe/Output/../Persistence/sqlite3.c
// Function: sqlite3_db_filename
SQLITE_API const char *SQLITE_STDCALL sqlite3_db_filename(sqlite3 *db, const char *zDbName){
  Btree *pBt;
#ifdef SQLITE_ENABLE_API_ARMOR
  if( !sqlite3SafetyCheckOk(db) ){
    (void)SQLITE_MISUSE_BKPT;
    return 0;
  }
#endif
  pBt = sqlite3DbNameToBtree(db, zDbName);
  return pBt ? sqlite3BtreeGetFilename(pBt) : 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
callq 0x1ae29
testq %rax, %rax
je 0x1bbef
movq 0x8(%rax), %rax
movq (%rax), %rax
cmpb $0x0, 0x13(%rax)
je 0x1bbf3
leaq 0x624b4(%rip), %rax     # 0x7e0a1
jmp 0x1bbfa
xorl %eax, %eax
jmp 0x1bbfa
movq 0xd0(%rax), %rax
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/shifengbin[P]bishe/Output/../Persistence/sqlite3.c
// Function: sqlite3AppendChar
SQLITE_PRIVATE void sqlite3AppendChar(StrAccum *p, int N, char c){
  testcase( p->nChar + (i64)N > 0x7fffffff );
  if( p->nChar+(i64)N >= p->nAlloc && (N = sqlite3StrAccumEnlarge(p, N))<=0 ){
    return;
  }
  assert( (p->zText==p->zBase)==(p->bMalloced==0) );
  while( (N--)>0 ) p->zText[p->nChar++] = c;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movl %edx, %ebx
movq %rdi, %r14
movl 0x18(%rdi), %eax
movl 0x1c(%rdi), %ecx
movl %esi, %edx
addq %rax, %rdx
cmpq %rcx, %rdx
jae 0x1bdcf
testl %esi, %esi
jg 0x1bddd
jmp 0x1bdf8
movq %r14, %rdi
callq 0x1be8f
movl %eax, %esi
testl %eax, %eax
jle 0x1bdf8
incl %esi
movq 0x10(%r14), %rax
movl 0x18(%r14), %ecx
leal 0x1(%rcx), %edx
movl %edx, 0x18(%r14)
movb %bl, (%rax,%rcx)
decl %esi
cmpl $0x1, %esi
ja 0x1bddf
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/shifengbin[P]bishe/Output/../Persistence/sqlite3.c
// Function: enlargeAndAppend
static void SQLITE_NOINLINE enlargeAndAppend(StrAccum *p, const char *z, int N){
  N = sqlite3StrAccumEnlarge(p, N);
  if( N>0 ){
    memcpy(&p->zText[p->nChar], z, N);
    p->nChar += N;
  }
  assert( (p->zText==0 || p->zText==p->zBase)==(p->bMalloced==0) );
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
movl %edx, %esi
callq 0x1be8f
testl %eax, %eax
jle 0x1be84
movl %eax, %r15d
movl 0x18(%rbx), %edi
addq 0x10(%rbx), %rdi
movl %eax, %edx
movq %r14, %rsi
callq 0xa320
addl %r15d, 0x18(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/shifengbin[P]bishe/Output/../Persistence/sqlite3.c
// Function: sqlite3DbRealloc
SQLITE_PRIVATE void *sqlite3DbRealloc(sqlite3 *db, void *p, u64 n){
  void *pNew = 0;
  assert( db!=0 );
  assert( sqlite3_mutex_held(db->mutex) );
  if( db->mallocFailed==0 ){
    if( p==0 ){
      return sqlite3DbMallocRaw(db, n);
    }
    if( isLookaside(db, p) ){
      if( n<=db->lookaside.sz ){
        return p;
      }
      pNew = sqlite3DbMallocRaw(db, n);
      if( pNew ){
        memcpy(pNew, p, db->lookaside.sz);
        sqlite3DbFree(db, p);
      }
    }else{
      assert( sqlite3MemdebugHasType(p, (MEMTYPE_LOOKASIDE|MEMTYPE_HEAP)) );
      assert( sqlite3MemdebugNoType(p, (u8)~(MEMTYPE_LOOKASIDE|MEMTYPE_HEAP)) );
      sqlite3MemdebugSetType(p, MEMTYPE_HEAP);
      pNew = sqlite3_realloc64(p, n);
      if( !pNew ){
        db->mallocFailed = 1;
      }
      sqlite3MemdebugSetType(pNew,
            (db->lookaside.bEnabled ? MEMTYPE_LOOKASIDE : MEMTYPE_HEAP));
    }
  }
  return pNew;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
cmpb $0x0, 0x51(%rdi)
je 0x1c002
xorl %ebx, %ebx
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq %rdx, %r15
movq %rsi, %rbx
movq %rdi, %r14
testq %rsi, %rsi
je 0x1c078
cmpq %rbx, 0x170(%r14)
ja 0x1c065
cmpq %rbx, 0x178(%r14)
jbe 0x1c065
movzwl 0x150(%r14), %eax
cmpq %r15, %rax
jae 0x1bff4
movq %r14, %rdi
movq %r15, %rsi
callq 0x145aa
testq %rax, %rax
je 0x1bff2
movq %rax, %r15
movzwl 0x150(%r14), %edx
movq %rax, %rdi
movq %rbx, %rsi
callq 0xa320
movq %r14, %rdi
movq %rbx, %rsi
callq 0xb752
movq %r15, %rbx
jmp 0x1bff4
callq 0xa080
testl %eax, %eax
je 0x1c08d
movb $0x1, 0x51(%r14)
jmp 0x1bff2
movq %r14, %rdi
movq %r15, %rsi
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x145aa
movq %rbx, %rdi
movq %r15, %rsi
callq 0xc2eb
movq %rax, %rbx
testq %rax, %rax
jne 0x1bff4
jmp 0x1c06e
// File: /workspace/github_c_makefile_star2_O3/shifengbin[P]bishe/Output/../Persistence/sqlite3.c
// Function: unixUnlock
static int unixUnlock(sqlite3_file *id, int eFileLock){
#if SQLITE_MAX_MMAP_SIZE>0
  assert( eFileLock==SHARED_LOCK || ((unixFile *)id)->nFetchOut==0 );
#endif
  return posixUnlock(id, eFileLock, 0);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movzbl 0x1c(%rdi), %eax
xorl %r15d, %r15d
cmpl %esi, %eax
jle 0x1c968
movl %esi, %ebx
movq %rdi, %r14
cmpl $0x0, 0x74b11(%rip)     # 0x91334
je 0x1c83e
movl $0xb, %edi
callq *0x74b78(%rip)          # 0x913a8
testq %rax, %rax
je 0x1c83e
movq %rax, %rdi
callq *0x74b7a(%rip)          # 0x913b8
leaq 0x1c(%r14), %r12
movq 0x10(%r14), %r13
cmpb $0x2, 0x1c(%r14)
jb 0x1c8da
cmpl $0x1, %ebx
jne 0x1c899
leaq -0x48(%rbp), %rsi
movl $0x0, (%rsi)
movslq 0x74f19(%rip), %rax     # 0x91780
addq $0x2, %rax
movq %rax, 0x8(%rsi)
movq $0x1fe, 0x10(%rsi)      # imm = 0x1FE
movq %r14, %rdi
callq 0x1ddc1
testl %eax, %eax
je 0x1c899
callq 0xa0b0
movl (%rax), %eax
movl %eax, 0x20(%r14)
movl $0x90a, %r15d           # imm = 0x90A
jmp 0x1c93a
leaq -0x48(%rbp), %rsi
movl $0x2, (%rsi)
movslq 0x74ed6(%rip), %rax     # 0x91780
movq %rax, 0x8(%rsi)
movq $0x2, 0x10(%rsi)
movq %r14, %rdi
callq 0x1ddc1
testl %eax, %eax
je 0x1c8d5
callq 0xa0b0
movl (%rax), %eax
movl %eax, 0x20(%r14)
movl $0x80a, %r15d           # imm = 0x80A
jmp 0x1c93a
movb $0x1, 0x14(%r13)
xorl %r15d, %r15d
testl %ebx, %ebx
jne 0x1c93a
xorl %r15d, %r15d
decl 0x10(%r13)
jne 0x1c92c
leaq -0x48(%rbp), %rsi
movl $0x2, (%rsi)
xorps %xmm0, %xmm0
movups %xmm0, 0x8(%rsi)
movq %r14, %rdi
callq 0x1ddc1
testl %eax, %eax
je 0x1c922
callq 0xa0b0
movl (%rax), %eax
movl %eax, 0x20(%r14)
movb $0x0, 0x14(%r13)
movl $0x80a, %r15d           # imm = 0x80A
movq %r12, %rax
jmp 0x1c929
leaq 0x14(%r13), %rax
xorl %r15d, %r15d
movb $0x0, (%rax)
decl 0x28(%r13)
jne 0x1c93a
movq %r14, %rdi
callq 0x1dc8a
cmpl $0x0, 0x749f3(%rip)     # 0x91334
je 0x1c95c
movl $0xb, %edi
callq *0x74a5a(%rip)          # 0x913a8
testq %rax, %rax
je 0x1c95c
movq %rax, %rdi
callq *0x74a6c(%rip)          # 0x913c8
testl %r15d, %r15d
jne 0x1c968
movb %bl, (%r12)
xorl %r15d, %r15d
movl %r15d, %eax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/shifengbin[P]bishe/Output/../Persistence/sqlite3.c
// Function: unixShmBarrier
static void unixShmBarrier(
  sqlite3_file *fd                /* Database file holding the shared memory */
){
  UNUSED_PARAMETER(fd);
  sqlite3MemoryBarrier();         /* compiler-defined memory barrier */
  unixEnterMutex();               /* Also mutex, for redundancy */
  unixLeaveMutex();
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
mfence
cmpl $0x0, 0x73bfb(%rip)     # 0x91334
je 0x1d777
movl $0xb, %edi
callq *0x73c62(%rip)          # 0x913a8
testq %rax, %rax
je 0x1d754
movq %rax, %rdi
callq *0x73c64(%rip)          # 0x913b8
cmpl $0x0, 0x73bd9(%rip)     # 0x91334
je 0x1d777
movl $0xb, %edi
callq *0x73c40(%rip)          # 0x913a8
testq %rax, %rax
je 0x1d777
movq %rax, %rdi
popq %rbp
jmpq *0x73c51(%rip)          # 0x913c8
popq %rbp
retq