LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: applyNumericAffinity
static void applyNumericAffinity(Mem *pRec, int bTryForInt){
  double rValue;
  u8 enc = pRec->enc;
  int rc;
  assert( (pRec->flags & (MEM_Str|MEM_Int|MEM_Real|MEM_IntReal))==MEM_Str );
  rc = sqlite3AtoF(pRec->z, &rValue, pRec->n, enc);
  if( rc<=0 ) return;
  if( rc==1 && alsoAnInt(pRec, rValue, &pRec->u.i) ){
    pRec->flags |= MEM_Int;
  }else{
    pRec->u.r = rValue;
    pRec->flags |= MEM_Real;
    if( bTryForInt ) sqlite3VdbeIntegerAffinity(pRec);
  }
  /* TEXT->NUMERIC is many->one.  Hence, it is important to invalidate the
  ** string representation after computing a numeric equivalent, because the
  ** string representation might not be the canonical representation for the
  ** numeric value.  Ticket [343634942dd54ab57b7024] 2018-01-31. */
  pRec->flags &= ~MEM_Str;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movl %esi, %ebp
movq %rdi, %rbx
movq 0x10(%rdi), %r15
movl 0xc(%rdi), %r14d
movzbl 0xa(%rdi), %r12d
leaq 0x10(%rsp), %rsi
movq %r15, %rdi
movl %r14d, %edx
movl %r12d, %ecx
callq 0x23a955
testl %eax, %eax
jle 0x22664b
movsd 0x10(%rsp), %xmm0
cmpl $0x1, %eax
jne 0x226624
cvttsd2si %xmm0, %r13
movsd %xmm0, 0x8(%rsp)
movq %r13, %rdi
callq 0x24507e
testl %eax, %eax
je 0x226609
movq %r13, (%rbx)
movl 0x8(%rbx), %eax
orl $0x4, %eax
jmp 0x226642
movq %r15, %rdi
movq %rbx, %rsi
movl %r14d, %edx
movl %r12d, %ecx
callq 0x23ad9d
testl %eax, %eax
movsd 0x8(%rsp), %xmm0
je 0x226601
movsd %xmm0, (%rbx)
movl 0x8(%rbx), %eax
orl $0x8, %eax
movw %ax, 0x8(%rbx)
testl %ebp, %ebp
je 0x226642
movq %rbx, %rdi
callq 0x244f9c
movzwl 0x8(%rbx), %eax
andl $0xfffd, %eax           # imm = 0xFFFD
movw %ax, 0x8(%rbx)
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: sqlite3VdbeCreate
SQLITE_PRIVATE Vdbe *sqlite3VdbeCreate(Parse *pParse){
  sqlite3 *db = pParse->db;
  Vdbe *p;
  p = sqlite3DbMallocRawNN(db, sizeof(Vdbe) );
  if( p==0 ) return 0;
  memset(&p->aOp, 0, sizeof(Vdbe)-offsetof(Vdbe,aOp));
  p->db = db;
  if( db->pVdbe ){
    db->pVdbe->pPrev = p;
  }
  p->pNext = db->pVdbe;
  p->pPrev = 0;
  db->pVdbe = p;
  p->magic = VDBE_MAGIC_INIT;
  p->pParse = pParse;
  pParse->pVdbe = p;
  assert( pParse->aLabel==0 );
  assert( pParse->nLabel==0 );
  assert( p->nOpAlloc==0 );
  assert( pParse->szOpAlloc==0 );
  sqlite3VdbeAddOp2(p, OP_Init, 0, 1);
  return p;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %r14
movq (%rdi), %r15
movl $0x128, %esi            # imm = 0x128
movq %r15, %rdi
callq 0x22d205
movq %rax, %rbx
testq %rax, %rax
je 0x226fb9
movq %rbx, %rdi
addq $0x88, %rdi
movl $0xa0, %edx
xorl %esi, %esi
callq 0x17380
movq %r15, (%rbx)
movq 0x8(%r15), %rax
testq %rax, %rax
je 0x226f8d
movq %rbx, 0x8(%rax)
movq %rax, 0x10(%rbx)
andq $0x0, 0x8(%rbx)
movq %rbx, 0x8(%r15)
movl $0x16bceaa5, 0x24(%rbx) # imm = 0x16BCEAA5
movq %r14, 0x18(%rbx)
movq %rbx, 0x10(%r14)
pushq $0x3e
popq %rsi
pushq $0x1
popq %rcx
movq %rbx, %rdi
xorl %edx, %edx
callq 0x24d51a
movq %rbx, %rax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: sqlite3VdbeAddOp4Int
SQLITE_PRIVATE int sqlite3VdbeAddOp4Int(
  Vdbe *p,            /* Add the opcode to this VM */
  int op,             /* The new opcode */
  int p1,             /* The P1 operand */
  int p2,             /* The P2 operand */
  int p3,             /* The P3 operand */
  int p4              /* The P4 operand as an integer */
){
  int addr = sqlite3VdbeAddOp3(p, op, p1, p2, p3);
  if( p->db->mallocFailed==0 ){
    VdbeOp *pOp = &p->aOp[addr];
    pOp->p4type = P4_INT32;
    pOp->p4.i = p4;
  }
  return addr;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movl %r9d, %ebx
movq %rdi, %r14
callq 0x24d51f
movq (%r14), %rcx
cmpb $0x0, 0x61(%rcx)
jne 0x226ff1
movq 0x88(%r14), %rcx
movslq %eax, %rdx
imulq $0x18, %rdx, %rdx
movb $-0x3, 0x1(%rcx,%rdx)
movl %ebx, 0x10(%rcx,%rdx)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: sqlite3VdbeAddOpList
SQLITE_PRIVATE VdbeOp *sqlite3VdbeAddOpList(
  Vdbe *p,                     /* Add opcodes to the prepared statement */
  int nOp,                     /* Number of opcodes to add */
  VdbeOpList const *aOp,       /* The opcodes to be added */
  int iLineno                  /* Source-file line number of first opcode */
){
  int i;
  VdbeOp *pOut, *pFirst;
  assert( nOp>0 );
  assert( p->magic==VDBE_MAGIC_INIT );
  if( p->nOp + nOp > p->nOpAlloc && growOpArray(p, nOp) ){
    return 0;
  }
  pFirst = pOut = &p->aOp[p->nOp];
  for(i=0; i<nOp; i++, aOp++, pOut++){
    pOut->opcode = aOp->opcode;
    pOut->p1 = aOp->p1;
    pOut->p2 = aOp->p2;
    assert( aOp->p2>=0 );
    if( (sqlite3OpcodeProperty[aOp->opcode] & OPFLG_JUMP)!=0 && aOp->p2>0 ){
      pOut->p2 += p->nOp;
    }
    pOut->p3 = aOp->p3;
    pOut->p4type = P4_NOTUSED;
    pOut->p4.p = 0;
    pOut->p5 = 0;
#ifdef SQLITE_ENABLE_EXPLAIN_COMMENTS
    pOut->zComment = 0;
#endif
#ifdef SQLITE_VDBE_COVERAGE
    pOut->iSrcLine = iLineno+i;
#else
    (void)iLineno;
#endif
#ifdef SQLITE_DEBUG
    if( p->db->flags & SQLITE_VdbeAddopTrace ){
      sqlite3VdbePrintOp(0, i+p->nOp, &p->aOp[i+p->nOp]);
    }
#endif
  }
  p->nOp += nOp;
  return pFirst;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %r14
movl %esi, %ebx
movq %rdi, %r15
movl 0x90(%rdi), %eax
leal (%rax,%rbx), %ecx
cmpl 0x94(%rdi), %ecx
jle 0x227031
movq %r15, %rdi
callq 0x24d5b1
testl %eax, %eax
je 0x22702a
xorl %eax, %eax
jmp 0x2270b6
movl 0x90(%r15), %eax
cltq
imulq $0x18, %rax, %rax
addq 0x88(%r15), %rax
xorl %ecx, %ecx
testl %ebx, %ebx
movl $0x0, %edx
cmovgl %ebx, %edx
leaq 0x14b5cf(%rip), %rsi    # 0x372620
movq %rax, %rdi
cmpl %ecx, %edx
je 0x2270af
movzbl (%r14,%rcx,4), %r10d
movb %r10b, (%rdi)
movsbl 0x1(%r14,%rcx,4), %r8d
movl %r8d, 0x4(%rdi)
movb 0x2(%r14,%rcx,4), %r9b
movsbl %r9b, %r8d
movl %r8d, 0x8(%rdi)
testb $0x1, (%r10,%rsi)
je 0x22708e
testb %r9b, %r9b
jle 0x22708e
addl 0x90(%r15), %r8d
movl %r8d, 0x8(%rdi)
movsbl 0x3(%r14,%rcx,4), %r8d
movl %r8d, 0xc(%rdi)
movb $0x0, 0x1(%rdi)
andq $0x0, 0x10(%rdi)
andw $0x0, 0x2(%rdi)
addq $0x18, %rdi
incq %rcx
jmp 0x227054
addl %ebx, 0x90(%r15)
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: sqlite3VdbeUsesBtree
SQLITE_PRIVATE void sqlite3VdbeUsesBtree(Vdbe *p, int i){
  assert( i>=0 && i<p->db->nDb && i<(int)sizeof(yDbMask)*8 );
  assert( i<(int)sizeof(p->btreeMask)*8 );
  DbMaskSet(p->btreeMask, i);
  if( i!=1 && sqlite3BtreeSharable(p->db->aDb[i].pBt) ){
    DbMaskSet(p->lockMask, i);
  }
}

// Assembly:
movl %esi, %ecx
pushq $0x1
popq %rax
shll %cl, %eax
orl %eax, 0xc8(%rdi)
cmpl $0x1, %esi
je 0x2270ed
movq (%rdi), %rdx
movq 0x20(%rdx), %rdx
movslq %ecx, %rcx
shlq $0x5, %rcx
movq 0x8(%rdx,%rcx), %rcx
cmpb $0x0, 0x11(%rcx)
je 0x2270ed
orl %eax, 0xcc(%rdi)
retq
// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: sqlite3VdbeChangeP4
SQLITE_PRIVATE void sqlite3VdbeChangeP4(Vdbe *p, int addr, const char *zP4, int n){
  Op *pOp;
  sqlite3 *db;
  assert( p!=0 );
  db = p->db;
  assert( p->magic==VDBE_MAGIC_INIT );
  assert( p->aOp!=0 || db->mallocFailed );
  if( db->mallocFailed ){
    if( n!=P4_VTAB ) freeP4(db, n, (void*)*(char**)&zP4);
    return;
  }
  assert( p->nOp>0 );
  assert( addr<p->nOp );
  if( addr<0 ){
    addr = p->nOp - 1;
  }
  pOp = &p->aOp[addr];
  if( n>=0 || pOp->p4type ){
    vdbeChangeP4Full(p, pOp, zP4, n);
    return;
  }
  if( n==P4_INT32 ){
    /* Note: this cast is safe, because the origin data point was an int
    ** that was cast to a (const char *). */
    pOp->p4.i = SQLITE_PTR_TO_INT(zP4);
    pOp->p4type = P4_INT32;
  }else if( zP4!=0 ){
    assert( n<0 );
    pOp->p4.p = (void*)zP4;
    pOp->p4type = (signed char)n;
    if( n==P4_VTAB ) sqlite3VtabLock((VTable*)zP4);
  }
}

// Assembly:
movq (%rdi), %rax
cmpb $0x0, 0x61(%rax)
je 0x2270fd
cmpl $-0xc, %ecx
jne 0x227136
retq
testl %esi, %esi
jns 0x227109
movl 0x90(%rdi), %esi
decl %esi
movslq %esi, %rax
imulq $0x18, %rax, %rsi
addq 0x88(%rdi), %rsi
testl %ecx, %ecx
jns 0x24d635
cmpb $0x0, 0x1(%rsi)
jne 0x24d635
cmpl $-0x3, %ecx
jne 0x227140
movl %edx, 0x10(%rsi)
movb $-0x3, 0x1(%rsi)
retq
movq %rax, %rdi
movl %ecx, %esi
jmp 0x238761
testq %rdx, %rdx
je 0x2270fc
movq %rdx, 0x10(%rsi)
movb %cl, 0x1(%rsi)
cmpl $-0xc, %ecx
jne 0x2270fc
incl 0x18(%rdx)
retq
// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: sqlite3ParserReset
SQLITE_PRIVATE void sqlite3ParserReset(Parse *pParse){
  sqlite3 *db = pParse->db;
  AggInfo *pThis = pParse->pAggList;
  while( pThis ){
    AggInfo *pNext = pThis->pNext;
    agginfoFree(db, pThis);
    pThis = pNext;
  }
  sqlite3DbFree(db, pParse->aLabel);
  sqlite3ExprListDelete(db, pParse->pConstExpr);
  if( db ){
    assert( db->lookaside.bDisable >= pParse->disableLookaside );
    db->lookaside.bDisable -= pParse->disableLookaside;
    db->lookaside.sz = db->lookaside.bDisable ? 0 : db->lookaside.szTrue;
  }
  pParse->disableLookaside = 0;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq (%rdi), %r14
movq 0xb8(%rdi), %r15
testq %r15, %r15
je 0x2276c4
movq 0x20(%r15), %rsi
movq 0x40(%r15), %r12
movq %r14, %rdi
callq 0x21f26b
movq 0x30(%r15), %rsi
movq %r14, %rdi
callq 0x21f26b
movq %r14, %rdi
movq %r15, %rsi
callq 0x21f26b
movq %r12, %r15
jmp 0x227693
movq 0x50(%rbx), %rsi
movq %r14, %rdi
callq 0x21f26b
movq 0x58(%rbx), %rsi
movq %r14, %rdi
callq 0x24b63f
testq %r14, %r14
je 0x227702
movzbl 0x24(%rbx), %eax
subl %eax, 0x170(%r14)
jne 0x2276f8
movzwl 0x176(%r14), %eax
jmp 0x2276fa
xorl %eax, %eax
movw %ax, 0x174(%r14)
movb $0x0, 0x24(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: sqlite3BtreePutData
SQLITE_PRIVATE int sqlite3BtreePutData(BtCursor *pCsr, u32 offset, u32 amt, void *z){
  int rc;
  assert( cursorOwnsBtShared(pCsr) );
  assert( sqlite3_mutex_held(pCsr->pBtree->db->mutex) );
  assert( pCsr->curFlags & BTCF_Incrblob );

  rc = restoreCursorPosition(pCsr);
  if( rc!=SQLITE_OK ){
    return rc;
  }
  assert( pCsr->eState!=CURSOR_REQUIRESEEK );
  if( pCsr->eState!=CURSOR_VALID ){
    return SQLITE_ABORT;
  }

  /* Save the positions of all other cursors open on this table. This is
  ** required in case any of them are holding references to an xFetch
  ** version of the b-tree page modified by the accessPayload call below.
  **
  ** Note that pCsr must be open on a INTKEY table and saveCursorPosition()
  ** and hence saveAllCursors() cannot fail on a BTREE_INTKEY table, hence
  ** saveAllCursors can only return SQLITE_OK.
  */
  VVA_ONLY(rc =) saveAllCursors(pCsr->pBt, pCsr->pgnoRoot, pCsr);
  assert( rc==SQLITE_OK );

  /* Check some assumptions:
  **   (a) the cursor is open for writing,
  **   (b) there is a read/write transaction open,
  **   (c) the connection holds a write-lock on the table (if required),
  **   (d) there are no conflicting read-locks, and
  **   (e) the cursor points at a valid row of an intKey table.
  */
  if( (pCsr->curFlags & BTCF_WriteFlag)==0 ){
    return SQLITE_READONLY;
  }
  assert( (pCsr->pBt->btsFlags & BTS_READ_ONLY)==0
              && pCsr->pBt->inTransaction==TRANS_WRITE );
  assert( hasSharedCacheTableLock(pCsr->pBtree, pCsr->pgnoRoot, 0, 2) );
  assert( !hasReadConflicts(pCsr->pBtree, pCsr->pgnoRoot) );
  assert( pCsr->pPage->intKey );

  return accessPayload(pCsr, offset, amt, (unsigned char *)z, 1);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rcx, %rbx
movl %edx, %ebp
movl %esi, %r14d
movq %rdi, %r15
movb (%rdi), %al
cmpb $0x3, %al
jb 0x22781c
movq %r15, %rdi
callq 0x2452c2
testl %eax, %eax
jne 0x22783e
movb (%r15), %al
testb %al, %al
je 0x227824
pushq $0x4
jmp 0x22783d
movq 0x20(%r15), %rdi
movl 0x50(%r15), %esi
movq %r15, %rdx
callq 0x236e12
testb $0x1, 0x1(%r15)
jne 0x227849
pushq $0x8
popq %rax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
pushq $0x1
popq %r8
movq %r15, %rdi
movl %r14d, %esi
movl %ebp, %edx
movq %rbx, %rcx
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x2371d5
// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: sqlite3_errmsg
SQLITE_API const char *sqlite3_errmsg(sqlite3 *db){
  const char *z;
  if( !db ){
    return sqlite3ErrStr(SQLITE_NOMEM_BKPT);
  }
  if( !sqlite3SafetyCheckSickOrOk(db) ){
    return sqlite3ErrStr(SQLITE_MISUSE_BKPT);
  }
  sqlite3_mutex_enter(db->mutex);
  if( db->mallocFailed ){
    z = sqlite3ErrStr(SQLITE_NOMEM_BKPT);
  }else{
    testcase( db->pErr==0 );
    z = db->errCode ? (char*)sqlite3_value_text(db->pErr) : 0;
    assert( !db->mallocFailed );
    if( z==0 ){
      z = sqlite3ErrStr(db->errCode);
    }
  }
  sqlite3_mutex_leave(db->mutex);
  return z;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
leaq 0xec575(%rip), %r14     # 0x314631
testq %rdi, %rdi
je 0x2280d3
movq %rdi, %rbx
callq 0x22b247
testl %eax, %eax
je 0x2280de
cmpb $0x0, 0x61(%rbx)
je 0x2280f6
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movl $0x27ea7, %edi          # imm = 0x27EA7
callq 0x21ec3c
movl %eax, %edi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x224b22
cmpl $0x0, 0x50(%rbx)
je 0x228115
movq 0x160(%rbx), %rdi
callq 0x2243e3
movq %rax, %r14
testq %rax, %rax
jne 0x2280d3
movl 0x50(%rbx), %edi
jmp 0x2280ea
xorl %edi, %edi
jmp 0x2280ea
// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: sqlite3LockAndPrepare
static int sqlite3LockAndPrepare(
  sqlite3 *db,              /* Database handle. */
  const char *zSql,         /* UTF-8 encoded SQL statement. */
  int nBytes,               /* Length of zSql in bytes. */
  u32 prepFlags,            /* Zero or more SQLITE_PREPARE_* flags */
  Vdbe *pOld,               /* VM being reprepared */
  sqlite3_stmt **ppStmt,    /* OUT: A pointer to the prepared statement */
  const char **pzTail       /* OUT: End of parsed string */
){
  int rc;
  int cnt = 0;

#ifdef SQLITE_ENABLE_API_ARMOR
  if( ppStmt==0 ) return SQLITE_MISUSE_BKPT;
#endif
  *ppStmt = 0;
  if( !sqlite3SafetyCheckOk(db)||zSql==0 ){
    return SQLITE_MISUSE_BKPT;
  }
  sqlite3_mutex_enter(db->mutex);
  sqlite3BtreeEnterAll(db);
  do{
    /* Make multiple attempts to compile the SQL, until it either succeeds
    ** or encounters a permanent error.  A schema problem after one schema
    ** reset is considered a permanent error. */
    rc = sqlite3Prepare(db, zSql, nBytes, prepFlags, pOld, ppStmt, pzTail);
    assert( rc==SQLITE_OK || *ppStmt==0 );
  }while( rc==SQLITE_ERROR_RETRY
       || (rc==SQLITE_SCHEMA && (sqlite3ResetOneSchema(db,-1), cnt++)==0) );
  sqlite3BtreeLeaveAll(db);
  rc = sqlite3ApiExit(db, rc);
  assert( (rc&db->errMask)==rc );
  sqlite3_mutex_leave(db->mutex);
  return rc;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %r9, %rbx
movq %r8, %r14
movl %ecx, %r12d
movl %edx, %ebp
movq %rsi, %r13
movq %rdi, %r15
movq 0x80(%rsp), %rax
movq %rax, 0x38(%rsp)
andq $0x0, (%r9)
callq 0x228052
testq %r13, %r13
je 0x2286ee
testl %eax, %eax
je 0x2286ee
movq %r13, 0x28(%rsp)
movl %ebp, 0x18(%rsp)
movq %rbx, 0x30(%rsp)
movl %r12d, 0x1c(%rsp)
movq %r14, 0x40(%rsp)
movq %r15, %rdi
callq 0x21f0e2
movb $0x1, %al
movl %eax, 0x14(%rsp)
movq %r15, 0x20(%rsp)
movl 0x1c(%rsp), %ebx
movq 0x30(%rsp), %rbp
movl 0x18(%rsp), %r13d
movq 0x38(%rsp), %r12
movq 0x28(%rsp), %r15
movq %r12, (%rsp)
movq 0x20(%rsp), %rdi
movq %r15, %rsi
movl %r13d, %edx
movl %ebx, %ecx
movq 0x40(%rsp), %r8
movq %rbp, %r9
callq 0x24ace4
cmpl $0x201, %eax            # imm = 0x201
je 0x228689
movl %eax, %r14d
cmpl $0x11, %eax
movq 0x20(%rsp), %r15
jne 0x2286d5
movq %r15, %rdi
pushq $-0x1
popq %rsi
callq 0x242921
testb $0x1, 0x14(%rsp)
movl $0x0, 0x14(%rsp)
jne 0x228684
movq %r15, %rdi
movl %r14d, %esi
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x22417d
movl $0x1f831, %edi          # imm = 0x1F831
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x21ec3c
// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: sqlite3_free_table
SQLITE_API void sqlite3_free_table(
  char **azResult            /* Result returned from sqlite3_get_table() */
){
  if( azResult ){
    int i, n;
    azResult--;
    assert( azResult!=0 );
    n = SQLITE_PTR_TO_INT(azResult[0]);
    for(i=1; i<n; i++){ if( azResult[i] ) sqlite3_free(azResult[i]); }
    sqlite3_free(azResult);
  }
}

// Assembly:
testq %rdi, %rdi
je 0x228bd2
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq -0x8(%rdi), %r14
movslq -0x8(%rdi), %r15
pushq $0x1
popq %r12
cmpq %r15, %r12
jge 0x228bbf
movq -0x8(%rbx,%r12,8), %rdi
testq %rdi, %rdi
je 0x228bba
callq 0x21f7f9
incq %r12
jmp 0x228ba6
movq %r14, %rdi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
jmp 0x21f7f9
retq
// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: createModule
static int createModule(
  sqlite3 *db,                    /* Database in which module is registered */
  const char *zName,              /* Name assigned to this module */
  const sqlite3_module *pModule,  /* The definition of the module */
  void *pAux,                     /* Context pointer for xCreate/xConnect */
  void (*xDestroy)(void *)        /* Module destructor function */
){
  int rc = SQLITE_OK;

  sqlite3_mutex_enter(db->mutex);
  (void)sqlite3VtabCreateModule(db, zName, pModule, pAux, xDestroy);
  rc = sqlite3ApiExit(db, rc);
  if( rc!=SQLITE_OK && xDestroy ) xDestroy(pAux);
  sqlite3_mutex_leave(db->mutex);
  return rc;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %r8, %rbx
movq %rcx, %r14
movq %rdi, %r15
callq 0x24d9c0
movq %r15, %rdi
xorl %esi, %esi
callq 0x22417d
movl %eax, %ebp
testl %eax, %eax
sete %al
testq %rbx, %rbx
sete %cl
orb %al, %cl
jne 0x228c0d
movq %r14, %rdi
callq *%rbx
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: sqlite3_drop_modules
SQLITE_API int sqlite3_drop_modules(sqlite3 *db, const char** azNames){
  HashElem *pThis, *pNext;
#ifdef SQLITE_ENABLE_API_ARMOR
  if( !sqlite3SafetyCheckOk(db) ) return SQLITE_MISUSE_BKPT;
#endif
  for(pThis=sqliteHashFirst(&db->aModule); pThis; pThis=pNext){
    Module *pMod = (Module*)sqliteHashData(pThis);
    pNext = sqliteHashNext(pThis);
    if( azNames ){
      int ii;
      for(ii=0; azNames[ii]!=0 && strcmp(azNames[ii],pMod->zName)!=0; ii++){}
      if( azNames[ii]!=0 ) continue;
    }
    createModule(db, pMod->zName, 0, 0, 0);
  }
  return SQLITE_OK;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r14
movq 0x1f8(%rdi), %rax
testq %rax, %rax
je 0x228c7c
movq (%rax), %r15
movq 0x10(%rax), %r12
testq %rbx, %rbx
je 0x228c63
movq %rbx, %r13
movq (%r13), %rdi
testq %rdi, %rdi
je 0x228c63
movq 0x8(%r12), %rsi
callq 0x179e0
addq $0x8, %r13
testl %eax, %eax
jne 0x228c46
jmp 0x228c77
movq 0x8(%r12), %rsi
movq %r14, %rdi
xorl %edx, %edx
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0x228bd8
movq %r15, %rax
jmp 0x228c32
xorl %eax, %eax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: sqlite3_vtab_config
SQLITE_API int sqlite3_vtab_config(sqlite3 *db, int op, ...){
  va_list ap;
  int rc = SQLITE_OK;
  VtabCtx *p;

#ifdef SQLITE_ENABLE_API_ARMOR
  if( !sqlite3SafetyCheckOk(db) ) return SQLITE_MISUSE_BKPT;
#endif
  sqlite3_mutex_enter(db->mutex);
  p = db->pVtabCtx;
  if( !p ){
    rc = SQLITE_MISUSE_BKPT;
  }else{
    assert( p->pTab==0 || IsVirtual(p->pTab) );
    va_start(ap, op);
    switch( op ){
      case SQLITE_VTAB_CONSTRAINT_SUPPORT: {
        p->pVTable->bConstraint = (u8)va_arg(ap, int);
        break;
      }
      case SQLITE_VTAB_INNOCUOUS: {
        p->pVTable->eVtabRisk = SQLITE_VTABRISK_Low;
        break;
      }
      case SQLITE_VTAB_DIRECTONLY: {
        p->pVTable->eVtabRisk = SQLITE_VTABRISK_High;
        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
pushq %rbx
subq $0xd8, %rsp
movq %rdi, %rbx
movq %rdx, 0x30(%rsp)
movq %rcx, 0x38(%rsp)
movq %r8, 0x40(%rsp)
movq %r9, 0x48(%rsp)
testb %al, %al
je 0x22943e
movaps %xmm0, 0x50(%rsp)
movaps %xmm1, 0x60(%rsp)
movaps %xmm2, 0x70(%rsp)
movaps %xmm3, 0x80(%rsp)
movaps %xmm4, 0x90(%rsp)
movaps %xmm5, 0xa0(%rsp)
movaps %xmm6, 0xb0(%rsp)
movaps %xmm7, 0xc0(%rsp)
movq 0x208(%rdi), %rax
testq %rax, %rax
je 0x229497
leaq 0x20(%rsp), %rcx
movq %rcx, 0x10(%rsp)
leaq 0xf0(%rsp), %rcx
movq %rcx, 0x8(%rsp)
movabsq $0x3000000010, %rcx     # imm = 0x3000000010
movq %rcx, (%rsp)
cmpl $0x3, %esi
je 0x2294a7
cmpl $0x2, %esi
je 0x22949e
cmpl $0x1, %esi
jne 0x2294b0
movl (%rsp), %edx
cmpq $0x28, %rdx
ja 0x2294c8
movq %rdx, %rcx
addq 0x10(%rsp), %rcx
addl $0x8, %edx
movl %edx, (%rsp)
jmp 0x2294d6
movl $0x22641, %edi          # imm = 0x22641
jmp 0x2294b5
movq (%rax), %rax
movb $0x0, 0x1d(%rax)
jmp 0x2294de
movq (%rax), %rax
movb $0x2, 0x1d(%rax)
jmp 0x2294de
movl $0x22653, %edi          # imm = 0x22653
callq 0x21ec3c
movl %eax, %ebp
movq %rbx, %rdi
movl %eax, %esi
callq 0x222800
jmp 0x2294e0
movq 0x8(%rsp), %rcx
leaq 0x8(%rcx), %rdx
movq %rdx, 0x8(%rsp)
movb (%rcx), %cl
movq (%rax), %rax
movb %cl, 0x1c(%rax)
xorl %ebp, %ebp
movl %ebp, %eax
addq $0xd8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: sqlite3_vtab_collation
SQLITE_API const char *sqlite3_vtab_collation(sqlite3_index_info *pIdxInfo, int iCons){
  HiddenIndexInfo *pHidden = (HiddenIndexInfo*)&pIdxInfo[1];
  const char *zRet = 0;
  if( iCons>=0 && iCons<pIdxInfo->nConstraint ){
    CollSeq *pC = 0;
    int iTerm = pIdxInfo->aConstraint[iCons].iTermOffset;
    Expr *pX = pHidden->pWC->a[iTerm].pExpr;
    if( pX->pLeft ){
      pC = sqlite3ExprCompareCollSeq(pHidden->pParse, pX);
    }
    zRet = (pC ? pC->zName : sqlite3StrBINARY);
  }
  return zRet;
}

// Assembly:
pushq %rbx
testl %esi, %esi
js 0x229535
cmpl %esi, (%rdi)
jle 0x229535
movl %esi, %eax
imulq $0xc, %rax, %rax
movq 0x8(%rdi), %rcx
movq 0x60(%rdi), %rdx
movslq 0x8(%rcx,%rax), %rax
movq 0x20(%rdx), %rcx
shlq $0x6, %rax
movq (%rcx,%rax), %rsi
leaq 0x148a55(%rip), %rbx    # 0x371f70
cmpq $0x0, 0x10(%rsi)
je 0x229537
movq 0x68(%rdi), %rdi
callq 0x22953c
testq %rax, %rax
je 0x229537
movq (%rax), %rbx
jmp 0x229537
xorl %ebx, %ebx
movq %rbx, %rax
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: sqlite3_complete16
SQLITE_API int sqlite3_complete16(const void *zSql){
  sqlite3_value *pVal;
  char const *zSql8;
  int rc;

#ifndef SQLITE_OMIT_AUTOINIT
  rc = sqlite3_initialize();
  if( rc ) return rc;
#endif
  pVal = sqlite3ValueNew(0);
  sqlite3ValueSetStr(pVal, -1, zSql, SQLITE_UTF16NATIVE, SQLITE_STATIC);
  zSql8 = sqlite3ValueText(pVal, SQLITE_UTF8);
  if( zSql8 ){
    rc = sqlite3_complete(zSql8);
  }else{
    rc = SQLITE_NOMEM_BKPT;
  }
  sqlite3ValueFree(pVal);
  return rc & 0xff;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movq %rdi, %r14
callq 0x21f2bc
movl %eax, %ebp
testl %eax, %eax
jne 0x229988
xorl %edi, %edi
callq 0x22998f
movq %rax, %rbx
pushq $0x2
popq %rdx
movq %rax, %rdi
movq %r14, %rsi
xorl %ecx, %ecx
callq 0x2299ac
pushq $0x1
popq %rsi
movq %rbx, %rdi
callq 0x2244c6
testq %rax, %rax
je 0x22997d
movq %rax, %rdi
callq 0x2295cc
movzbl %al, %ebp
jmp 0x229980
pushq $0x7
popq %rbp
movq %rbx, %rdi
callq 0x2245fd
movl %ebp, %eax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: sqlite3ValueNew
SQLITE_PRIVATE sqlite3_value *sqlite3ValueNew(sqlite3 *db){
  Mem *p = sqlite3DbMallocZero(db, sizeof(*p));
  if( p ){
    p->flags = MEM_Null;
    p->db = db;
  }
  return p;
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
pushq $0x38
popq %rsi
callq 0x2258ed
testq %rax, %rax
je 0x2299aa
movw $0x1, 0x8(%rax)
movq %rbx, 0x28(%rax)
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: sqlite3_db_release_memory
SQLITE_API int sqlite3_db_release_memory(sqlite3 *db){
  int i;

#ifdef SQLITE_ENABLE_API_ARMOR
  if( !sqlite3SafetyCheckOk(db) ) return SQLITE_MISUSE_BKPT;
#endif
  sqlite3_mutex_enter(db->mutex);
  sqlite3BtreeEnterAll(db);
  for(i=0; i<db->nDb; i++){
    Btree *pBt = db->aDb[i].pBt;
    if( pBt ){
      Pager *pPager = sqlite3BtreePager(pBt);
      sqlite3PagerShrink(pPager);
    }
  }
  sqlite3BtreeLeaveAll(db);
  sqlite3_mutex_leave(db->mutex);
  return SQLITE_OK;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
callq 0x21f0e2
pushq $0x8
popq %r14
xorl %r15d, %r15d
movslq 0x28(%rbx), %rax
cmpq %rax, %r15
jge 0x22a0ab
movq 0x20(%rbx), %rax
movq (%rax,%r14), %rax
testq %rax, %rax
je 0x22a0a2
movq 0x8(%rax), %rax
movq (%rax), %rax
movq 0x118(%rax), %rax
movq 0x40(%rax), %rdi
callq *0x210676(%rip)         # 0x43a718
incq %r15
addq $0x20, %r14
jmp 0x22a074
xorl %eax, %eax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: sqlite3_db_cacheflush
SQLITE_API int sqlite3_db_cacheflush(sqlite3 *db){
  int i;
  int rc = SQLITE_OK;
  int bSeenBusy = 0;

#ifdef SQLITE_ENABLE_API_ARMOR
  if( !sqlite3SafetyCheckOk(db) ) return SQLITE_MISUSE_BKPT;
#endif
  sqlite3_mutex_enter(db->mutex);
  sqlite3BtreeEnterAll(db);
  for(i=0; rc==SQLITE_OK && i<db->nDb; i++){
    Btree *pBt = db->aDb[i].pBt;
    if( pBt && sqlite3BtreeIsInTrans(pBt) ){
      Pager *pPager = sqlite3BtreePager(pBt);
      rc = sqlite3PagerFlush(pPager);
      if( rc==SQLITE_BUSY ){
        bSeenBusy = 1;
        rc = SQLITE_OK;
      }
    }
  }
  sqlite3BtreeLeaveAll(db);
  sqlite3_mutex_leave(db->mutex);
  return ((rc==SQLITE_OK && bSeenBusy) ? SQLITE_BUSY : rc);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
callq 0x21f0e2
xorl %r13d, %r13d
xorl %r12d, %r12d
xorl %ebp, %ebp
testl %ebp, %ebp
jne 0x22a159
movslq 0x28(%rbx), %rax
cmpq %rax, %r13
jge 0x22a159
movq 0x20(%rbx), %rax
movq %r13, %rcx
shlq $0x5, %rcx
movq 0x8(%rax,%rcx), %rax
xorl %ebp, %ebp
testq %rax, %rax
je 0x22a120
cmpb $0x2, 0x10(%rax)
jne 0x22a120
movq 0x8(%rax), %rax
movq (%rax), %r14
movl 0x2c(%r14), %ebp
cmpb $0x0, 0x13(%r14)
je 0x22a125
cmpl $0x5, %ebp
pushq $0x1
popq %rax
cmovel %eax, %r12d
movl $0x0, %eax
cmovel %eax, %ebp
incq %r13
jmp 0x22a0ce
movq 0x118(%r14), %rdi
callq 0x234394
movq %rax, %r15
testl %ebp, %ebp
jne 0x22a10e
movq %r15, %rsi
testq %r15, %r15
je 0x22a10e
movq 0x20(%rsi), %r15
xorl %ebp, %ebp
cmpw $0x0, 0x36(%rsi)
jne 0x22a134
movq %r14, %rdi
callq 0x22ff53
movl %eax, %ebp
jmp 0x22a134
testl %r12d, %r12d
pushq $0x5
popq %rax
cmovel %ebp, %eax
testl %ebp, %ebp
cmovnel %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: sqlite3_busy_timeout
SQLITE_API int 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, (int(*)(void*,int))sqliteDefaultBusyCallback,
                             (void*)db);
    db->busyTimeout = ms;
  }else{
    sqlite3_busy_handler(db, 0, 0);
  }
  return SQLITE_OK;
}

// Assembly:
xorl %eax, %eax
testl %esi, %esi
leaq 0x2e(%rip), %rcx        # 0x22a778
cmovleq %rax, %rcx
movl $0x0, %edx
cmovgq %rdi, %rdx
cmovlel %eax, %esi
movq %rcx, 0x250(%rdi)
movq %rdx, 0x258(%rdi)
andl $0x0, 0x260(%rdi)
movl %esi, 0x2b4(%rdi)
xorl %eax, %eax
retq
// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: createFunctionApi
static int createFunctionApi(
  sqlite3 *db,
  const char *zFunc,
  int nArg,
  int enc,
  void *p,
  void (*xSFunc)(sqlite3_context*,int,sqlite3_value**),
  void (*xStep)(sqlite3_context*,int,sqlite3_value**),
  void (*xFinal)(sqlite3_context*),
  void (*xValue)(sqlite3_context*),
  void (*xInverse)(sqlite3_context*,int,sqlite3_value**),
  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 *)sqlite3Malloc(sizeof(FuncDestructor));
    if( !pArg ){
      sqlite3OomFault(db);
      xDestroy(p);
      goto out;
    }
    pArg->nRef = 0;
    pArg->xDestroy = xDestroy;
    pArg->pUserData = p;
  }
  rc = sqlite3CreateFunc(db, zFunc, nArg, enc, p,
      xSFunc, xStep, xFinal, xValue, xInverse, pArg
  );
  if( pArg && pArg->nRef==0 ){
    assert( rc!=SQLITE_OK );
    xDestroy(p);
    sqlite3_free(pArg);
  }

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

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movl %ecx, %ebp
movl %edx, %r13d
movq %rsi, %r12
movq %rdi, 0x8(%rsp)
movq 0x90(%rsp), %rbx
movq 0x88(%rsp), %r14
movq 0x80(%rsp), %r11
movq 0x78(%rsp), %r10
movq 0x70(%rsp), %rax
testq %rbx, %rbx
je 0x22a869
movq %r14, 0x10(%rsp)
movq %r11, 0x18(%rsp)
movq %r10, 0x20(%rsp)
movq %rax, 0x28(%rsp)
movq %r9, 0x30(%rsp)
movq %r8, %r14
pushq $0x18
popq %rdi
callq 0x21f6df
testq %rax, %rax
je 0x22a8ae
movq %rax, %r15
andl $0x0, (%rax)
movq %rbx, 0x8(%rax)
movq %r14, %r8
movq %r14, 0x10(%rax)
movq 0x30(%rsp), %r9
movq 0x28(%rsp), %rax
movq 0x20(%rsp), %r10
movq 0x18(%rsp), %r11
movq 0x10(%rsp), %r14
jmp 0x22a86c
xorl %r15d, %r15d
subq $0x8, %rsp
movq 0x10(%rsp), %rdi
movq %r12, %rsi
movl %r13d, %edx
movl %ebp, %ecx
movq %r8, %r12
pushq %r15
pushq %r14
pushq %r11
pushq %r10
pushq %rax
callq 0x22aa11
addq $0x30, %rsp
movl %eax, %ebp
testq %r15, %r15
je 0x22a8c0
cmpl $0x0, (%r15)
jne 0x22a8c0
movq %r12, %rdi
callq *%rbx
movq %r15, %rdi
callq 0x21f7f9
jmp 0x22a8c0
movq 0x8(%rsp), %rdi
callq 0x224bb1
movq %r14, %rdi
callq *%rbx
pushq $0x1
popq %rbp
movq 0x8(%rsp), %rdi
movl %ebp, %esi
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x22417d
// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: sqlite3_create_function16
SQLITE_API int sqlite3_create_function16(
  sqlite3 *db,
  const void *zFunctionName,
  int nArg,
  int eTextRep,
  void *p,
  void (*xSFunc)(sqlite3_context*,int,sqlite3_value**),
  void (*xStep)(sqlite3_context*,int,sqlite3_value**),
  void (*xFinal)(sqlite3_context*)
){
  int rc;
  char *zFunc8;

#ifdef SQLITE_ENABLE_API_ARMOR
  if( !sqlite3SafetyCheckOk(db) || zFunctionName==0 ) return SQLITE_MISUSE_BKPT;
#endif
  sqlite3_mutex_enter(db->mutex);
  assert( !db->mallocFailed );
  zFunc8 = sqlite3Utf16to8(db, zFunctionName, -1, SQLITE_UTF16NATIVE);
  rc = sqlite3CreateFunc(db, zFunc8, nArg, eTextRep, p, xSFunc,xStep,xFinal,0,0,0);
  sqlite3DbFree(db, zFunc8);
  rc = sqlite3ApiExit(db, rc);
  sqlite3_mutex_leave(db->mutex);
  return rc;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %r9, %rbx
movq %r8, %r14
movl %ecx, %ebp
movl %edx, %r15d
movq %rdi, %r12
movaps 0x80(%rsp), %xmm0
movaps %xmm0, 0x30(%rsp)
pushq $-0x1
popq %rdx
callq 0x22a9b2
movq %rax, %r13
xorps %xmm0, %xmm0
movups %xmm0, 0x10(%rsp)
movaps 0x30(%rsp), %xmm0
movups %xmm0, (%rsp)
andq $0x0, 0x20(%rsp)
movq %r12, %rdi
movq %rax, %rsi
movl %r15d, %edx
movl %ebp, %ecx
movq %r14, %r8
movq %rbx, %r9
callq 0x22aa11
movl %eax, %ebx
movq %r12, %rdi
movq %r13, %rsi
callq 0x21f26b
movq %r12, %rdi
movl %ebx, %esi
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x22417d
// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: sqlite3_overload_function
SQLITE_API int sqlite3_overload_function(
  sqlite3 *db,
  const char *zName,
  int nArg
){
  int rc;
  char *zCopy;

#ifdef SQLITE_ENABLE_API_ARMOR
  if( !sqlite3SafetyCheckOk(db) || zName==0 || nArg<-2 ){
    return SQLITE_MISUSE_BKPT;
  }
#endif
  sqlite3_mutex_enter(db->mutex);
  rc = sqlite3FindFunction(db, zName, nArg, SQLITE_UTF8, 0)!=0;
  sqlite3_mutex_leave(db->mutex);
  if( rc ) return SQLITE_OK;
  zCopy = sqlite3_mprintf(zName);
  if( zCopy==0 ) return SQLITE_NOMEM;
  return sqlite3_create_function_v2(db, zName, nArg, SQLITE_UTF8,
                           zCopy, sqlite3InvalidFunction, 0, 0, sqlite3_free);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x18, %rsp
movl %edx, %ebx
movq %rsi, %r14
movq %rdi, %r15
pushq $0x1
popq %rcx
xorl %ebp, %ebp
xorl %r8d, %r8d
callq 0x22acdc
testq %rax, %rax
je 0x22ac90
movl %ebp, %eax
jmp 0x22accc
movq %r14, %rdi
xorl %eax, %eax
callq 0x22132b
testq %rax, %rax
je 0x22acd7
leaq -0xb4ad(%rip), %rcx     # 0x21f7f9
movq %rcx, 0x10(%rsp)
xorps %xmm0, %xmm0
movups %xmm0, (%rsp)
leaq 0x1c6(%rip), %r9        # 0x22ae7f
pushq $0x1
popq %rcx
movq %r15, %rdi
movq %r14, %rsi
movl %ebx, %edx
movq %rax, %r8
callq 0x22a8da
addq $0x18, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
pushq $0x7
popq %rbp
jmp 0x22ac8c
// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: sqlite3InvalidFunction
static void sqlite3InvalidFunction(
  sqlite3_context *context,  /* The function calling context */
  int NotUsed,               /* Number of arguments to the function */
  sqlite3_value **NotUsed2   /* Value of each argument */
){
  const char *zName = (const char*)sqlite3_user_data(context);
  char *zErr;
  UNUSED_PARAMETER2(NotUsed, NotUsed2);
  zErr = sqlite3_mprintf(
      "unable to use function %s in the requested context", zName);
  sqlite3_result_error(context, zErr, -1);
  sqlite3_free(zErr);
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x8(%rdi), %rax
movq 0x8(%rax), %rsi
leaq 0x14fad4(%rip), %rdi    # 0x37a969
xorl %eax, %eax
callq 0x22132b
movq %rax, %r14
pushq $-0x1
popq %rdx
movq %rbx, %rdi
movq %rax, %rsi
callq 0x2246d3
movq %r14, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x21f7f9
// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: sqlite3_wal_checkpoint_v2
SQLITE_API int sqlite3_wal_checkpoint_v2(
  sqlite3 *db,                    /* Database handle */
  const char *zDb,                /* Name of attached database (or NULL) */
  int eMode,                      /* SQLITE_CHECKPOINT_* value */
  int *pnLog,                     /* OUT: Size of WAL log in frames */
  int *pnCkpt                     /* OUT: Total number of frames checkpointed */
){
#ifdef SQLITE_OMIT_WAL
  return SQLITE_OK;
#else
  int rc;                         /* Return code */
  int iDb = SQLITE_MAX_ATTACHED;  /* sqlite3.aDb[] index of db to checkpoint */

#ifdef SQLITE_ENABLE_API_ARMOR
  if( !sqlite3SafetyCheckOk(db) ) return SQLITE_MISUSE_BKPT;
#endif

  /* Initialize the output variables to -1 in case an error occurs. */
  if( pnLog ) *pnLog = -1;
  if( pnCkpt ) *pnCkpt = -1;

  assert( SQLITE_CHECKPOINT_PASSIVE==0 );
  assert( SQLITE_CHECKPOINT_FULL==1 );
  assert( SQLITE_CHECKPOINT_RESTART==2 );
  assert( SQLITE_CHECKPOINT_TRUNCATE==3 );
  if( eMode<SQLITE_CHECKPOINT_PASSIVE || eMode>SQLITE_CHECKPOINT_TRUNCATE ){
    /* EVIDENCE-OF: R-03996-12088 The M parameter must be a valid checkpoint
    ** mode: */
    return SQLITE_MISUSE;
  }

  sqlite3_mutex_enter(db->mutex);
  if( zDb && zDb[0] ){
    iDb = sqlite3FindDbName(db, zDb);
  }
  if( iDb<0 ){
    rc = SQLITE_ERROR;
    sqlite3ErrorWithMsg(db, SQLITE_ERROR, "unknown database: %s", zDb);
  }else{
    db->busyHandler.nBusy = 0;
    rc = sqlite3Checkpoint(db, iDb, eMode, pnLog, pnCkpt);
    sqlite3Error(db, rc);
  }
  rc = sqlite3ApiExit(db, rc);

  /* If there are no active statements, clear the interrupt flag at this
  ** point.  */
  if( db->nVdbeActive==0 ){
    AtomicStore(&db->u1.isInterrupted, 0);
  }

  sqlite3_mutex_leave(db->mutex);
  return rc;
#endif
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %r8, %r14
movq %rcx, %r15
movl %edx, %ebp
movq %rsi, %r12
movq %rdi, %rbx
testq %rcx, %rcx
je 0x22b011
orl $-0x1, (%r15)
testq %r14, %r14
je 0x22b01a
orl $-0x1, (%r14)
cmpl $0x3, %ebp
jbe 0x22b024
pushq $0x15
popq %rax
jmp 0x22b084
pushq $0xa
popq %rsi
testq %r12, %r12
je 0x22b044
cmpb $0x0, (%r12)
je 0x22b044
movq %rbx, %rdi
movq %r12, %rsi
callq 0x22b0a8
movl %eax, %esi
testl %eax, %eax
js 0x22b08d
andl $0x0, 0x260(%rbx)
movq %rbx, %rdi
movl %ebp, %edx
movq %r15, %rcx
movq %r14, %r8
callq 0x22b124
movl %eax, %ebp
movq %rbx, %rdi
movl %eax, %esi
callq 0x222800
movq %rbx, %rdi
movl %ebp, %esi
callq 0x22417d
cmpl $0x0, 0xc0(%rbx)
jne 0x22b084
movl $0x0, 0x168(%rbx)
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
leaq 0x14ad51(%rip), %rdx    # 0x375de5
pushq $0x1
popq %rbp
movq %rbx, %rdi
movl %ebp, %esi
movq %r12, %rcx
xorl %eax, %eax
callq 0x2226f3
jmp 0x22b067
// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: sqlite3FindDbName
SQLITE_PRIVATE int sqlite3FindDbName(sqlite3 *db, const char *zName){
  int i = -1;         /* Database number */
  if( zName ){
    Db *pDb;
    for(i=(db->nDb-1), pDb=&db->aDb[i]; i>=0; i--, pDb--){
      if( 0==sqlite3_stricmp(pDb->zDbSName, zName) ) break;
      /* "main" is always an acceptable alias for the primary database
      ** even if it has been renamed using SQLITE_DBCONFIG_MAINDBNAME. */
      if( i==0 && 0==sqlite3_stricmp("main", zName) ) break;
    }
  }
  return i;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
testq %rsi, %rsi
je 0x22b10d
movq %rsi, %rbx
movl 0x28(%rdi), %r15d
decl %r15d
movslq %r15d, %rax
movq %rax, %r12
shlq $0x5, %r12
addq 0x20(%rdi), %r12
cmpl $-0x1, %eax
pushq $-0x1
popq %rbp
cmovll %eax, %ebp
leaq 0xcfe42(%rip), %r14     # 0x2faf1f
testl %r15d, %r15d
js 0x22b119
movq (%r12), %rdi
movq %rbx, %rsi
callq 0x221763
testl %eax, %eax
je 0x22b112
subl $0x1, %r15d
jae 0x22b107
movq %r14, %rdi
movq %rbx, %rsi
callq 0x221779
testl %eax, %eax
je 0x22b117
addq $-0x20, %r12
jmp 0x22b0dd
pushq $-0x1
popq %rbp
jmp 0x22b119
movl %r15d, %ebp
jmp 0x22b119
xorl %ebp, %ebp
movl %ebp, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: sqlite3_errmsg16
SQLITE_API const void *sqlite3_errmsg16(sqlite3 *db){
  static const u16 outOfMem[] = {
    'o', 'u', 't', ' ', 'o', 'f', ' ', 'm', 'e', 'm', 'o', 'r', 'y', 0
  };
  static const u16 misuse[] = {
    'b', 'a', 'd', ' ', 'p', 'a', 'r', 'a', 'm', 'e', 't', 'e', 'r', ' ',
    'o', 'r', ' ', 'o', 't', 'h', 'e', 'r', ' ', 'A', 'P', 'I', ' ',
    'm', 'i', 's', 'u', 's', 'e', 0
  };

  const void *z;
  if( !db ){
    return (void *)outOfMem;
  }
  if( !sqlite3SafetyCheckSickOrOk(db) ){
    return (void *)misuse;
  }
  sqlite3_mutex_enter(db->mutex);
  if( db->mallocFailed ){
    z = (void *)outOfMem;
  }else{
    z = sqlite3_value_text16(db->pErr);
    if( z==0 ){
      sqlite3ErrorWithMsg(db, db->errCode, sqlite3ErrStr(db->errCode));
      z = sqlite3_value_text16(db->pErr);
    }
    /* A malloc() may have failed within the call to sqlite3_value_text16()
    ** above. If this is the case, then the db->mallocFailed flag needs to
    ** be cleared before returning. Do this directly, instead of via
    ** sqlite3ApiExit(), to avoid setting the database handle error message.
    */
    sqlite3OomClear(db);
  }
  sqlite3_mutex_leave(db->mutex);
  return z;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
leaq 0x146bfc(%rip), %r14    # 0x371e80
testq %rdi, %rdi
je 0x22b2e8
movq %rdi, %rbx
callq 0x22b247
testl %eax, %eax
je 0x22b2e1
cmpb $0x0, 0x61(%rbx)
jne 0x22b2e8
movq 0x160(%rbx), %rdi
callq 0x2244f4
movq %rax, %r14
testq %rax, %rax
jne 0x22b2d7
movl 0x50(%rbx), %ebp
movl %ebp, %edi
callq 0x224b22
movq %rbx, %rdi
movl %ebp, %esi
movq %rax, %rdx
xorl %eax, %eax
callq 0x2226f3
movq 0x160(%rbx), %rdi
callq 0x2244f4
movq %rax, %r14
movq %rbx, %rdi
callq 0x22b2f0
jmp 0x22b2e8
leaq 0x146bb8(%rip), %r14    # 0x371ea0
movq %r14, %rax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: sqlite3OomClear
SQLITE_PRIVATE void sqlite3OomClear(sqlite3 *db){
  if( db->mallocFailed && db->nVdbeExec==0 ){
    db->mallocFailed = 0;
    AtomicStore(&db->u1.isInterrupted, 0);
    assert( db->lookaside.bDisable>0 );
    EnableLookaside;
  }
}

// Assembly:
cmpb $0x0, 0x61(%rdi)
je 0x22b2ff
cmpl $0x0, 0xcc(%rdi)
je 0x22b300
retq
movb $0x0, 0x61(%rdi)
movl $0x0, 0x168(%rdi)
decl 0x170(%rdi)
je 0x22b31a
xorl %eax, %eax
jmp 0x22b321
movzwl 0x176(%rdi), %eax
movw %ax, 0x174(%rdi)
retq
// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: sqlite3_errcode
SQLITE_API int sqlite3_errcode(sqlite3 *db){
  if( db && !sqlite3SafetyCheckSickOrOk(db) ){
    return SQLITE_MISUSE_BKPT;
  }
  if( !db || db->mallocFailed ){
    return SQLITE_NOMEM_BKPT;
  }
  return db->errCode & db->errMask;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
pushq $0x7
popq %rbx
testq %rdi, %rdi
je 0x22b350
movq %rdi, %r14
callq 0x22b247
testl %eax, %eax
je 0x22b35a
cmpb $0x0, 0x61(%r14)
jne 0x22b350
movl 0x54(%r14), %ebx
andl 0x50(%r14), %ebx
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movl $0x27ee9, %edi          # imm = 0x27EE9
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x21ec3c
// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: sqlite3_extended_errcode
SQLITE_API int sqlite3_extended_errcode(sqlite3 *db){
  if( db && !sqlite3SafetyCheckSickOrOk(db) ){
    return SQLITE_MISUSE_BKPT;
  }
  if( !db || db->mallocFailed ){
    return SQLITE_NOMEM_BKPT;
  }
  return db->errCode;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
pushq $0x7
popq %rbx
testq %rdi, %rdi
je 0x22b38e
movq %rdi, %r14
callq 0x22b247
testl %eax, %eax
je 0x22b398
cmpb $0x0, 0x61(%r14)
jne 0x22b38e
movl 0x50(%r14), %ebx
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movl $0x27ef2, %edi          # imm = 0x27EF2
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x21ec3c
// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: sqlite3_open16
SQLITE_API int sqlite3_open16(
  const void *zFilename,
  sqlite3 **ppDb
){
  char const *zFilename8;   /* zFilename encoded in UTF-8 instead of UTF-16 */
  sqlite3_value *pVal;
  int rc;

#ifdef SQLITE_ENABLE_API_ARMOR
  if( ppDb==0 ) return SQLITE_MISUSE_BKPT;
#endif
  *ppDb = 0;
#ifndef SQLITE_OMIT_AUTOINIT
  rc = sqlite3_initialize();
  if( rc ) return rc;
#endif
  if( zFilename==0 ) zFilename = "\000\000";
  pVal = sqlite3ValueNew(0);
  sqlite3ValueSetStr(pVal, -1, zFilename, SQLITE_UTF16NATIVE, SQLITE_STATIC);
  zFilename8 = sqlite3ValueText(pVal, SQLITE_UTF8);
  if( zFilename8 ){
    rc = openDatabase(zFilename8, ppDb,
                      SQLITE_OPEN_READWRITE | SQLITE_OPEN_CREATE, 0);
    assert( *ppDb || rc==SQLITE_NOMEM );
    if( rc==SQLITE_OK && !DbHasProperty(*ppDb, 0, DB_SchemaLoaded) ){
      SCHEMA_ENC(*ppDb) = ENC(*ppDb) = SQLITE_UTF16NATIVE;
    }
  }else{
    rc = SQLITE_NOMEM_BKPT;
  }
  sqlite3ValueFree(pVal);

  return rc & 0xff;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
andq $0x0, (%rsi)
callq 0x21f2bc
testl %eax, %eax
jne 0x22b966
testq %r14, %r14
leaq 0x1465ee(%rip), %r15    # 0x371ee4
cmovneq %r14, %r15
xorl %edi, %edi
callq 0x22998f
movq %rax, %r14
pushq $0x2
popq %rdx
movq %rax, %rdi
movq %r15, %rsi
xorl %ecx, %ecx
callq 0x2299ac
pushq $0x1
popq %rsi
movq %r14, %rdi
callq 0x2244c6
testq %rax, %rax
je 0x22b957
pushq $0x6
popq %rdx
movq %rax, %rdi
movq %rbx, %rsi
xorl %ecx, %ecx
callq 0x22b3e8
movl %eax, %ebp
testl %eax, %eax
jne 0x22b95a
movq (%rbx), %rax
movq 0x20(%rax), %rcx
movq 0x18(%rcx), %rcx
testb $0x1, 0x72(%rcx)
jne 0x22b953
movb $0x2, %dl
movb %dl, 0x5e(%rax)
movb %dl, 0x71(%rcx)
xorl %ebp, %ebp
jmp 0x22b95a
pushq $0x7
popq %rbp
movq %r14, %rdi
callq 0x2245fd
movzbl %bpl, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: sqlite3_create_collation16
SQLITE_API int sqlite3_create_collation16(
  sqlite3* db,
  const void *zName,
  int enc,
  void* pCtx,
  int(*xCompare)(void*,int,const void*,int,const void*)
){
  int rc = SQLITE_OK;
  char *zName8;

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

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %r8, %r14
movq %rcx, %r15
movl %edx, %ebp
movq %rdi, %rbx
pushq $-0x1
popq %rdx
callq 0x22a9b2
testq %rax, %rax
je 0x22bb33
movq %rax, %r12
movzbl %bpl, %edx
movq %rbx, %rdi
movq %rax, %rsi
movq %r15, %rcx
movq %r14, %r8
xorl %r9d, %r9d
callq 0x22b990
movl %eax, %ebp
movq %rbx, %rdi
movq %r12, %rsi
callq 0x22d0fc
jmp 0x22bb35
xorl %ebp, %ebp
movq %rbx, %rdi
movl %ebp, %esi
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x22417d
// File: /workspace/github_c_makefile_star2_O2/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: sqlite3Init
SQLITE_PRIVATE int sqlite3Init(sqlite3 *db, char **pzErrMsg){
  int i, rc;
  int commit_internal = !(db->mDbFlags&DBFLAG_SchemaChange);

  assert( sqlite3_mutex_held(db->mutex) );
  assert( sqlite3BtreeHoldsMutex(db->aDb[0].pBt) );
  assert( db->init.busy==0 );
  ENC(db) = SCHEMA_ENC(db);
  assert( db->nDb>0 );
  /* Do the main schema first */
  if( !DbHasProperty(db, 0, DB_SchemaLoaded) ){
    rc = sqlite3InitOne(db, 0, pzErrMsg, 0);
    if( rc ) return rc;
  }
  /* All other schemas after the main schema. The "temp" schema must be last */
  for(i=db->nDb-1; i>0; i--){
    assert( i==1 || sqlite3BtreeHoldsMutex(db->aDb[i].pBt) );
    if( !DbHasProperty(db, i, DB_SchemaLoaded) ){
      rc = sqlite3InitOne(db, i, pzErrMsg, 0);
      if( rc ) return rc;
    }
  }
  if( commit_internal ){
    sqlite3CommitInternalChanges(db);
  }
  return SQLITE_OK;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rsi, %r14
movq %rdi, %rbx
movl 0x2c(%rdi), %ebp
movq 0x20(%rdi), %rax
movq 0x18(%rax), %rax
movb 0x71(%rax), %cl
movb %cl, 0x5e(%rdi)
testb $0x1, 0x72(%rax)
jne 0x22be5c
movq %rbx, %rdi
xorl %esi, %esi
movq %r14, %rdx
xorl %ecx, %ecx
callq 0x2440df
testl %eax, %eax
jne 0x22bea9
movl 0x28(%rbx), %r15d
leal -0x1(%r15), %r12d
shlq $0x5, %r12
orq $0x18, %r12
cmpl $0x2, %r15d
jl 0x22be9d
decl %r15d
movq 0x20(%rbx), %rax
movq (%rax,%r12), %rax
testb $0x1, 0x72(%rax)
jne 0x22be97
movq %rbx, %rdi
movl %r15d, %esi
movq %r14, %rdx
xorl %ecx, %ecx
callq 0x2440df
testl %eax, %eax
jne 0x22bea9
addq $-0x20, %r12
jmp 0x22be6c
xorl %eax, %eax
testb $0x1, %bpl
jne 0x22bea9
andb $-0x2, 0x2c(%rbx)
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq