LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O0/barabo[P]advanced-shell-history/src/sqlite3.c
// Function: isAppropriateForFactoring
static int isAppropriateForFactoring(Expr *p){
  if( !sqlite3ExprIsConstantNotJoin(p) ){
    return 0;  /* Only constant expressions are appropriate for factoring */
  }
  if( (p->flags & EP_FixedDest)==0 ){
    return 1;  /* Any constant without a fixed destination is appropriate */
  }
  while( p->op==TK_UPLUS ) p = p->pLeft;
  switch( p->op ){
#ifndef SQLITE_OMIT_BLOB_LITERAL
    case TK_BLOB:
#endif
    case TK_VARIABLE:
    case TK_INTEGER:
    case TK_FLOAT:
    case TK_NULL:
    case TK_STRING: {
      testcase( p->op==TK_BLOB );
      testcase( p->op==TK_VARIABLE );
      testcase( p->op==TK_INTEGER );
      testcase( p->op==TK_FLOAT );
      testcase( p->op==TK_NULL );
      testcase( p->op==TK_STRING );
      /* Single-instruction constants with a fixed destination are
      ** better done in-line.  If we factor them, they will just end
      ** up generating an OP_SCopy to move the value to the destination
      ** register. */
      return 0;
    }
    case TK_UMINUS: {
      if( p->pLeft->op==TK_FLOAT || p->pLeft->op==TK_INTEGER ){
        return 0;
      }
      break;
    }
    default: {
      break;
    }
  }
  return 1;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rdi
callq 0x71d50
cmpl $0x0, %eax
jne 0x75416
movl $0x0, -0x4(%rbp)
jmp 0x754d5
movq -0x10(%rbp), %rax
movzwl 0x2(%rax), %eax
andl $0x200, %eax            # imm = 0x200
cmpl $0x0, %eax
jne 0x75434
movl $0x1, -0x4(%rbp)
jmp 0x754d5
jmp 0x75436
movq -0x10(%rbp), %rax
movzbl (%rax), %eax
cmpl $0x9d, %eax
jne 0x75452
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x10(%rbp)
jmp 0x75436
movq -0x10(%rbp), %rax
movzbl (%rax), %eax
movl %eax, -0x14(%rbp)
subl $0x5e, %eax
je 0x75494
jmp 0x75463
movl -0x14(%rbp), %eax
subl $0x62, %eax
je 0x75494
jmp 0x7546d
movl -0x14(%rbp), %eax
addl $0xffffff7f, %eax       # imm = 0xFFFFFF7F
subl $0x3, %eax
jb 0x75494
jmp 0x7547c
movl -0x14(%rbp), %eax
subl $0x85, %eax
je 0x75494
jmp 0x75488
movl -0x14(%rbp), %eax
subl $0x9c, %eax
je 0x7549d
jmp 0x754cc
movl $0x0, -0x4(%rbp)
jmp 0x754d5
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movzbl (%rax), %eax
cmpl $0x82, %eax
je 0x754c1
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movzbl (%rax), %eax
cmpl $0x81, %eax
jne 0x754ca
movl $0x0, -0x4(%rbp)
jmp 0x754d5
jmp 0x754ce
jmp 0x754ce
movl $0x1, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x20, %rsp
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O0/barabo[P]advanced-shell-history/src/sqlite3.c
// Function: whereClauseInsert
static int whereClauseInsert(WhereClause *pWC, Expr *p, u8 wtFlags){
  WhereTerm *pTerm;
  int idx;
  testcase( wtFlags & TERM_VIRTUAL );
  if( pWC->nTerm>=pWC->nSlot ){
    WhereTerm *pOld = pWC->a;
    sqlite3 *db = pWC->pWInfo->pParse->db;
    pWC->a = sqlite3DbMallocRaw(db, sizeof(pWC->a[0])*pWC->nSlot*2 );
    if( pWC->a==0 ){
      if( wtFlags & TERM_DYNAMIC ){
        sqlite3ExprDelete(db, p);
      }
      pWC->a = pOld;
      return 0;
    }
    memcpy(pWC->a, pOld, sizeof(pWC->a[0])*pWC->nTerm);
    if( pOld!=pWC->aStatic ){
      sqlite3DbFree(db, pOld);
    }
    pWC->nSlot = sqlite3DbMallocSize(db, pWC->a)/sizeof(pWC->a[0]);
  }
  pTerm = &pWC->a[idx = pWC->nTerm++];
  pTerm->pExpr = sqlite3ExprSkipCollate(p);
  pTerm->wtFlags = wtFlags;
  pTerm->pWC = pWC;
  pTerm->iParent = -1;
  return idx;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movb %dl, %al
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movb %al, -0x19(%rbp)
movq -0x10(%rbp), %rax
movl 0x14(%rax), %eax
movq -0x10(%rbp), %rcx
cmpl 0x18(%rcx), %eax
jl 0x755e8
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movq %rax, -0x38(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq (%rax), %rax
movq (%rax), %rax
movq %rax, -0x40(%rbp)
movq -0x40(%rbp), %rdi
movq -0x10(%rbp), %rax
movslq 0x18(%rax), %rax
imulq $0x38, %rax, %rax
shlq %rax
movl %eax, %esi
callq 0x134e0
movq %rax, %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x20(%rax)
movq -0x10(%rbp), %rax
cmpq $0x0, 0x20(%rax)
jne 0x75587
movzbl -0x19(%rbp), %eax
andl $0x1, %eax
cmpl $0x0, %eax
je 0x7556f
movq -0x40(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x47330
movq -0x38(%rbp), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x20(%rax)
movl $0x0, -0x4(%rbp)
jmp 0x7564a
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rdi
movq -0x38(%rbp), %rsi
movq -0x10(%rbp), %rax
movslq 0x14(%rax), %rax
imulq $0x38, %rax, %rdx
callq 0x82f0
movq -0x38(%rbp), %rax
movq -0x10(%rbp), %rcx
addq $0x28, %rcx
cmpq %rcx, %rax
je 0x755c2
movq -0x40(%rbp), %rdi
movq -0x38(%rbp), %rsi
callq 0x9cd0
movq -0x40(%rbp), %rdi
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rsi
callq 0x1bac0
cltq
movl $0x38, %ecx
xorl %edx, %edx
divq %rcx
movl %eax, %ecx
movq -0x10(%rbp), %rax
movl %ecx, 0x18(%rax)
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movq -0x10(%rbp), %rdx
movl 0x14(%rdx), %ecx
movl %ecx, %esi
addl $0x1, %esi
movl %esi, 0x14(%rdx)
movl %ecx, -0x2c(%rbp)
movslq %ecx, %rcx
imulq $0x38, %rcx, %rcx
addq %rcx, %rax
movq %rax, -0x28(%rbp)
movq -0x18(%rbp), %rdi
callq 0x648b0
movq %rax, %rcx
movq -0x28(%rbp), %rax
movq %rcx, (%rax)
movb -0x19(%rbp), %cl
movq -0x28(%rbp), %rax
movb %cl, 0x1a(%rax)
movq -0x10(%rbp), %rcx
movq -0x28(%rbp), %rax
movq %rcx, 0x20(%rax)
movq -0x28(%rbp), %rax
movl $0xffffffff, 0x8(%rax)  # imm = 0xFFFFFFFF
movl -0x2c(%rbp), %eax
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x40, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/barabo[P]advanced-shell-history/src/sqlite3.c
// Function: exprTableUsage
static Bitmask exprTableUsage(WhereMaskSet *pMaskSet, Expr *p){
  Bitmask mask = 0;
  if( p==0 ) return 0;
  if( p->op==TK_COLUMN ){
    mask = getMask(pMaskSet, p->iTable);
    return mask;
  }
  mask = exprTableUsage(pMaskSet, p->pRight);
  mask |= exprTableUsage(pMaskSet, p->pLeft);
  if( ExprHasProperty(p, EP_xIsSelect) ){
    mask |= exprSelectTableUsage(pMaskSet, p->x.pSelect);
  }else{
    mask |= exprListTableUsage(pMaskSet, p->x.pList);
  }
  return mask;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq $0x0, -0x20(%rbp)
cmpq $0x0, -0x18(%rbp)
jne 0x760fc
movq $0x0, -0x8(%rbp)
jmp 0x761a6
movq -0x18(%rbp), %rax
movzbl (%rax), %eax
cmpl $0x98, %eax
jne 0x76128
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rax
movl 0x2c(%rax), %esi
callq 0x72c50
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0x761a6
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rax
movq 0x18(%rax), %rsi
callq 0x760d0
movq %rax, -0x20(%rbp)
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rsi
callq 0x760d0
orq -0x20(%rbp), %rax
movq %rax, -0x20(%rbp)
movq -0x18(%rbp), %rax
movzwl 0x2(%rax), %eax
andl $0x800, %eax            # imm = 0x800
cmpl $0x800, %eax            # imm = 0x800
jne 0x76185
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rax
movq 0x20(%rax), %rsi
callq 0x761b0
orq -0x20(%rbp), %rax
movq %rax, -0x20(%rbp)
jmp 0x7619e
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rax
movq 0x20(%rax), %rsi
callq 0x72be0
orq -0x20(%rbp), %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x20, %rsp
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O0/barabo[P]advanced-shell-history/src/sqlite3.c
// Function: exprSelectTableUsage
static Bitmask exprSelectTableUsage(WhereMaskSet *pMaskSet, Select *pS){
  Bitmask mask = 0;
  while( pS ){
    SrcList *pSrc = pS->pSrc;
    mask |= exprListTableUsage(pMaskSet, pS->pEList);
    mask |= exprListTableUsage(pMaskSet, pS->pGroupBy);
    mask |= exprListTableUsage(pMaskSet, pS->pOrderBy);
    mask |= exprTableUsage(pMaskSet, pS->pWhere);
    mask |= exprTableUsage(pMaskSet, pS->pHaving);
    if( ALWAYS(pSrc!=0) ){
      int i;
      for(i=0; i<pSrc->nSrc; i++){
        mask |= exprSelectTableUsage(pMaskSet, pSrc->a[i].pSelect);
        mask |= exprTableUsage(pMaskSet, pSrc->a[i].pOn);
      }
    }
    pS = pS->pPrior;
  }
  return mask;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq $0x0, -0x18(%rbp)
cmpq $0x0, -0x10(%rbp)
je 0x762e5
movq -0x10(%rbp), %rax
movq 0x28(%rax), %rax
movq %rax, -0x20(%rbp)
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rax
movq (%rax), %rsi
callq 0x72be0
orq -0x18(%rbp), %rax
movq %rax, -0x18(%rbp)
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rax
movq 0x38(%rax), %rsi
callq 0x72be0
orq -0x18(%rbp), %rax
movq %rax, -0x18(%rbp)
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rax
movq 0x48(%rax), %rsi
callq 0x72be0
orq -0x18(%rbp), %rax
movq %rax, -0x18(%rbp)
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rax
movq 0x30(%rax), %rsi
callq 0x760d0
orq -0x18(%rbp), %rax
movq %rax, -0x18(%rbp)
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rax
movq 0x40(%rax), %rsi
callq 0x760d0
orq -0x18(%rbp), %rax
movq %rax, -0x18(%rbp)
cmpq $0x0, -0x20(%rbp)
je 0x762d4
movl $0x0, -0x24(%rbp)
movl -0x24(%rbp), %eax
movq -0x20(%rbp), %rcx
movzbl (%rcx), %ecx
cmpl %ecx, %eax
jge 0x762d2
movq -0x8(%rbp), %rdi
movq -0x20(%rbp), %rax
addq $0x8, %rax
movslq -0x24(%rbp), %rcx
imulq $0x68, %rcx, %rcx
addq %rcx, %rax
movq 0x28(%rax), %rsi
callq 0x761b0
orq -0x18(%rbp), %rax
movq %rax, -0x18(%rbp)
movq -0x8(%rbp), %rdi
movq -0x20(%rbp), %rax
addq $0x8, %rax
movslq -0x24(%rbp), %rcx
imulq $0x68, %rcx, %rcx
addq %rcx, %rax
movq 0x40(%rax), %rsi
callq 0x760d0
orq -0x18(%rbp), %rax
movq %rax, -0x18(%rbp)
movl -0x24(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x24(%rbp)
jmp 0x76269
jmp 0x762d4
movq -0x10(%rbp), %rax
movq 0x50(%rax), %rax
movq %rax, -0x10(%rbp)
jmp 0x761c8
movq -0x18(%rbp), %rax
addq $0x30, %rsp
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O0/barabo[P]advanced-shell-history/src/sqlite3.c
// Function: operatorMask
static u16 operatorMask(int op){
  u16 c;
  assert( allowedOp(op) );
  if( op==TK_IN ){
    c = WO_IN;
  }else if( op==TK_ISNULL ){
    c = WO_ISNULL;
  }else{
    assert( (WO_EQ<<(op-TK_EQ)) < 0x7fff );
    c = (u16)(WO_EQ<<(op-TK_EQ));
  }
  assert( op!=TK_ISNULL || c==WO_ISNULL );
  assert( op!=TK_IN || c==WO_IN );
  assert( op!=TK_EQ || c==WO_EQ );
  assert( op!=TK_LT || c==WO_LT );
  assert( op!=TK_LE || c==WO_LE );
  assert( op!=TK_GT || c==WO_GT );
  assert( op!=TK_GE || c==WO_GE );
  return c;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movl %edi, -0x4(%rbp)
cmpl $0x48, -0x4(%rbp)
jne 0x76345
movw $0x1, -0x6(%rbp)
jmp 0x76366
cmpl $0x49, -0x4(%rbp)
jne 0x76353
movw $0x80, -0x6(%rbp)
jmp 0x76364
movl -0x4(%rbp), %ecx
subl $0x4c, %ecx
movl $0x2, %eax
shll %cl, %eax
movw %ax, -0x6(%rbp)
jmp 0x76366
movw -0x6(%rbp), %ax
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/barabo[P]advanced-shell-history/src/sqlite3.c
// Function: exprCommute
static void exprCommute(Parse *pParse, Expr *pExpr){
  u16 expRight = (pExpr->pRight->flags & EP_Collate);
  u16 expLeft = (pExpr->pLeft->flags & EP_Collate);
  assert( allowedOp(pExpr->op) && pExpr->op!=TK_IN );
  if( expRight==expLeft ){
    /* Either X and Y both have COLLATE operator or neither do */
    if( expRight ){
      /* Both X and Y have COLLATE operators.  Make sure X is always
      ** used by clearing the EP_Collate flag from Y. */
      pExpr->pRight->flags &= ~EP_Collate;
    }else if( sqlite3ExprCollSeq(pParse, pExpr->pLeft)!=0 ){
      /* Neither X nor Y have COLLATE operators, but X has a non-default
      ** collating sequence.  So add the EP_Collate marker on X to cause
      ** it to be searched first. */
      pExpr->pLeft->flags |= EP_Collate;
    }
  }
  SWAP(Expr*,pExpr->pRight,pExpr->pLeft);
  if( pExpr->op>=TK_GT ){
    assert( TK_LT==TK_GT+2 );
    assert( TK_GE==TK_LE+2 );
    assert( TK_GT>TK_EQ );
    assert( TK_GT<TK_LE );
    assert( pExpr->op>=TK_GT && pExpr->op<=TK_GE );
    pExpr->op = ((pExpr->op-TK_GT)^2)+TK_GT;
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rax
movzwl 0x2(%rax), %eax
andl $0x100, %eax            # imm = 0x100
movw %ax, -0x12(%rbp)
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movzwl 0x2(%rax), %eax
andl $0x100, %eax            # imm = 0x100
movw %ax, -0x14(%rbp)
movzwl -0x12(%rbp), %eax
movzwl -0x14(%rbp), %ecx
cmpl %ecx, %eax
jne 0x76406
cmpw $0x0, -0x12(%rbp)
je 0x763d5
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rax
movzwl 0x2(%rax), %ecx
andl $0xfffffeff, %ecx       # imm = 0xFFFFFEFF
movw %cx, 0x2(%rax)
jmp 0x76404
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rsi
callq 0x659b0
cmpq $0x0, %rax
je 0x76402
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movzwl 0x2(%rax), %ecx
orl $0x100, %ecx            # imm = 0x100
movw %cx, 0x2(%rax)
jmp 0x76404
jmp 0x76406
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rax
movq %rax, -0x20(%rbp)
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x18(%rax)
movq -0x20(%rbp), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x10(%rax)
movq -0x10(%rbp), %rax
movzbl (%rax), %eax
cmpl $0x4d, %eax
jl 0x76452
movq -0x10(%rbp), %rax
movzbl (%rax), %eax
subl $0x4d, %eax
xorl $0x2, %eax
addl $0x4d, %eax
movb %al, %cl
movq -0x10(%rbp), %rax
movb %cl, (%rax)
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/barabo[P]advanced-shell-history/src/sqlite3.c
// Function: isMatchOfColumn
static int isMatchOfColumn(
  Expr *pExpr      /* Test this expression */
){
  ExprList *pList;

  if( pExpr->op!=TK_FUNCTION ){
    return 0;
  }
  if( sqlite3StrICmp(pExpr->u.zToken,"match")!=0 ){
    return 0;
  }
  pList = pExpr->x.pList;
  if( pList->nExpr!=2 ){
    return 0;
  }
  if( pList->a[1].pExpr->op != TK_COLUMN ){
    return 0;
  }
  return 1;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movzbl (%rax), %eax
cmpl $0x97, %eax
je 0x76fc3
movl $0x0, -0x4(%rbp)
jmp 0x77029
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rdi
leaq 0x3ad37(%rip), %rsi     # 0xb1d09
callq 0xc970
cmpl $0x0, %eax
je 0x76fe5
movl $0x0, -0x4(%rbp)
jmp 0x77029
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movq %rax, -0x18(%rbp)
movq -0x18(%rbp), %rax
cmpl $0x2, (%rax)
je 0x77003
movl $0x0, -0x4(%rbp)
jmp 0x77029
movq -0x18(%rbp), %rax
movq 0x8(%rax), %rax
movq 0x20(%rax), %rax
movzbl (%rax), %eax
cmpl $0x98, %eax
je 0x77022
movl $0x0, -0x4(%rbp)
jmp 0x77029
movl $0x1, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/barabo[P]advanced-shell-history/src/sqlite3.c
// Function: sqlite3IsLikeFunction
SQLITE_PRIVATE int sqlite3IsLikeFunction(sqlite3 *db, Expr *pExpr, int *pIsNocase, char *aWc){
  FuncDef *pDef;
  if( pExpr->op!=TK_FUNCTION 
   || !pExpr->x.pList 
   || pExpr->x.pList->nExpr!=2
  ){
    return 0;
  }
  assert( !ExprHasProperty(pExpr, EP_xIsSelect) );
  pDef = sqlite3FindFunction(db, pExpr->u.zToken, 
                             sqlite3Strlen30(pExpr->u.zToken),
                             2, SQLITE_UTF8, 0);
  if( NEVER(pDef==0) || (pDef->flags & SQLITE_FUNC_LIKE)==0 ){
    return 0;
  }

  /* The memcpy() statement assumes that the wildcard characters are
  ** the first three statements in the compareInfo structure.  The
  ** asserts() that follow verify that assumption
  */
  memcpy(aWc, pDef->pUserData, 3);
  assert( (char*)&likeInfoAlt == (char*)&likeInfoAlt.matchAll );
  assert( &((char*)&likeInfoAlt)[1] == (char*)&likeInfoAlt.matchOne );
  assert( &((char*)&likeInfoAlt)[2] == (char*)&likeInfoAlt.matchSet );
  *pIsNocase = (pDef->flags & SQLITE_FUNC_CASE)==0;
  return 1;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq %rcx, -0x28(%rbp)
movq -0x18(%rbp), %rax
movzbl (%rax), %eax
cmpl $0x97, %eax
jne 0x7707e
movq -0x18(%rbp), %rax
cmpq $0x0, 0x20(%rax)
je 0x7707e
movq -0x18(%rbp), %rax
movq 0x20(%rax), %rax
cmpl $0x2, (%rax)
je 0x7708a
movl $0x0, -0x4(%rbp)
jmp 0x77127
movq -0x10(%rbp), %rax
movq %rax, -0x40(%rbp)
movq -0x18(%rbp), %rax
movq 0x8(%rax), %rax
movq %rax, -0x38(%rbp)
movq -0x18(%rbp), %rax
movq 0x8(%rax), %rdi
callq 0x92f0
movq -0x40(%rbp), %rdi
movq -0x38(%rbp), %rsi
movl %eax, %edx
movl $0x2, %ecx
movl $0x1, %r8d
xorl %r9d, %r9d
callq 0x18d90
movq %rax, -0x30(%rbp)
cmpq $0x0, -0x30(%rbp)
je 0x770e3
movq -0x30(%rbp), %rax
movzbl 0x3(%rax), %eax
andl $0x1, %eax
cmpl $0x0, %eax
jne 0x770ec
movl $0x0, -0x4(%rbp)
jmp 0x77127
movq -0x28(%rbp), %rax
movq -0x30(%rbp), %rcx
movq 0x8(%rcx), %rcx
movw (%rcx), %dx
movw %dx, (%rax)
movb 0x2(%rcx), %cl
movb %cl, 0x2(%rax)
movq -0x30(%rbp), %rax
movzbl 0x3(%rax), %eax
andl $0x2, %eax
cmpl $0x0, %eax
sete %al
andb $0x1, %al
movzbl %al, %ecx
movq -0x20(%rbp), %rax
movl %ecx, (%rax)
movl $0x1, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x40, %rsp
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O0/barabo[P]advanced-shell-history/src/sqlite3.c
// Function: sqlite3VdbeGetBoundValue
SQLITE_PRIVATE sqlite3_value *sqlite3VdbeGetBoundValue(Vdbe *v, int iVar, u8 aff){
  assert( iVar>0 );
  if( v ){
    Mem *pMem = &v->aVar[iVar-1];
    if( 0==(pMem->flags & MEM_Null) ){
      sqlite3_value *pRet = sqlite3ValueNew(v->db);
      if( pRet ){
        sqlite3VdbeMemCopy((Mem *)pRet, pMem);
        sqlite3ValueApplyAffinity(pRet, aff, SQLITE_UTF8);
        sqlite3VdbeMemStoreType((Mem *)pRet);
      }
      return pRet;
    }
  }
  return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movb %dl, %al
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
movb %al, -0x15(%rbp)
cmpq $0x0, -0x10(%rbp)
je 0x771c3
movq -0x10(%rbp), %rax
movq 0x78(%rax), %rax
movl -0x14(%rbp), %ecx
subl $0x1, %ecx
movslq %ecx, %rcx
imulq $0x38, %rcx, %rcx
addq %rcx, %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rax
movzwl 0x24(%rax), %ecx
andl $0x1, %ecx
xorl %eax, %eax
cmpl %ecx, %eax
jne 0x771c1
movq -0x10(%rbp), %rax
movq (%rax), %rdi
callq 0x16f80
movq %rax, -0x28(%rbp)
cmpq $0x0, -0x28(%rbp)
je 0x771b7
movq -0x28(%rbp), %rdi
movq -0x20(%rbp), %rsi
callq 0x10eb0
movq -0x28(%rbp), %rdi
movl $0x1, %edx
movzbl -0x15(%rbp), %esi
callq 0x6b670
movq -0x28(%rbp), %rdi
callq 0x12e00
movq -0x28(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0x771cb
jmp 0x771c3
movq $0x0, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/barabo[P]advanced-shell-history/src/sqlite3.c
// Function: sqlite3VdbeSetVarmask
SQLITE_PRIVATE void sqlite3VdbeSetVarmask(Vdbe *v, int iVar){
  assert( iVar>0 );
  if( iVar>32 ){
    v->expmask = 0xffffffff;
  }else{
    v->expmask |= ((u32)1 << (iVar-1));
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
cmpl $0x20, -0xc(%rbp)
jle 0x77201
movq -0x8(%rbp), %rax
movl $0xffffffff, 0x104(%rax) # imm = 0xFFFFFFFF
jmp 0x77220
movl -0xc(%rbp), %ecx
subl $0x1, %ecx
movl $0x1, %eax
shll %cl, %eax
movl %eax, %ecx
movq -0x8(%rbp), %rax
orl 0x104(%rax), %ecx
movl %ecx, 0x104(%rax)
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/barabo[P]advanced-shell-history/src/sqlite3.c
// Function: findTerm
static WhereTerm *findTerm(
  WhereClause *pWC,     /* The WHERE clause to be searched */
  int iCur,             /* Cursor number of LHS */
  int iColumn,          /* Column number of LHS */
  Bitmask notReady,     /* RHS must not overlap with this mask */
  u32 op,               /* Mask of WO_xx values describing operator */
  Index *pIdx           /* Must be compatible with this index, if not NULL */
){
  WhereTerm *pResult = 0;
  WhereTerm *p;
  WhereScan scan;

  p = whereScanInit(&scan, pWC, iCur, iColumn, op, pIdx);
  while( p ){
    if( (p->prereqRight & notReady)==0 ){
      if( p->prereqRight==0 && (p->eOperator&WO_EQ)!=0 ){
        return p;
      }
      if( pResult==0 ) pResult = p;
    }
    p = whereScanNext(&scan);
  }
  return pResult;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xc0, %rsp
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
movl %edx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movl %r8d, -0x24(%rbp)
movq %r9, -0x30(%rbp)
movq $0x0, -0x38(%rbp)
movq -0x10(%rbp), %rsi
movl -0x14(%rbp), %edx
movl -0x18(%rbp), %ecx
movl -0x24(%rbp), %r8d
movq -0x30(%rbp), %r9
leaq -0xc0(%rbp), %rdi
callq 0x77410
movq %rax, -0x40(%rbp)
cmpq $0x0, -0x40(%rbp)
je 0x772dc
movq -0x40(%rbp), %rax
movq 0x28(%rax), %rax
andq -0x20(%rbp), %rax
cmpq $0x0, %rax
jne 0x772ca
movq -0x40(%rbp), %rax
cmpq $0x0, 0x28(%rax)
jne 0x772b9
movq -0x40(%rbp), %rax
movzwl 0x18(%rax), %eax
andl $0x2, %eax
cmpl $0x0, %eax
je 0x772b9
movq -0x40(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0x772e4
cmpq $0x0, -0x38(%rbp)
jne 0x772c8
movq -0x40(%rbp), %rax
movq %rax, -0x38(%rbp)
jmp 0x772ca
leaq -0xc0(%rbp), %rdi
callq 0x77540
movq %rax, -0x40(%rbp)
jmp 0x7727b
movq -0x38(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0xc0, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/barabo[P]advanced-shell-history/src/sqlite3.c
// Function: findIndexCol
static int findIndexCol(
  Parse *pParse,                  /* Parse context */
  ExprList *pList,                /* Expression list to search */
  int iBase,                      /* Cursor for table associated with pIdx */
  Index *pIdx,                    /* Index to match column of */
  int iCol                        /* Column of index to match */
){
  int i;
  const char *zColl = pIdx->azColl[iCol];

  for(i=0; i<pList->nExpr; i++){
    Expr *p = sqlite3ExprSkipCollate(pList->a[i].pExpr);
    if( p->op==TK_COLUMN
     && p->iColumn==pIdx->aiColumn[iCol]
     && p->iTable==iBase
    ){
      CollSeq *pColl = sqlite3ExprCollSeq(pParse, pList->a[i].pExpr);
      if( ALWAYS(pColl) && 0==sqlite3StrICmp(pColl->zName, zColl) ){
        return i;
      }
    }
  }

  return -1;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movl %edx, -0x1c(%rbp)
movq %rcx, -0x28(%rbp)
movl %r8d, -0x2c(%rbp)
movq -0x28(%rbp), %rax
movq 0x40(%rax), %rax
movslq -0x2c(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movq %rax, -0x38(%rbp)
movl $0x0, -0x30(%rbp)
movl -0x30(%rbp), %eax
movq -0x18(%rbp), %rcx
cmpl (%rcx), %eax
jge 0x773f3
movq -0x18(%rbp), %rax
movq 0x8(%rax), %rax
movslq -0x30(%rbp), %rcx
shlq $0x5, %rcx
addq %rcx, %rax
movq (%rax), %rdi
callq 0x648b0
movq %rax, -0x40(%rbp)
movq -0x40(%rbp), %rax
movzbl (%rax), %eax
cmpl $0x98, %eax
jne 0x773e3
movq -0x40(%rbp), %rax
movswl 0x30(%rax), %eax
movq -0x28(%rbp), %rcx
movq 0x8(%rcx), %rcx
movslq -0x2c(%rbp), %rdx
cmpl (%rcx,%rdx,4), %eax
jne 0x773e3
movq -0x40(%rbp), %rax
movl 0x2c(%rax), %eax
cmpl -0x1c(%rbp), %eax
jne 0x773e3
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rax
movq 0x8(%rax), %rax
movslq -0x30(%rbp), %rcx
shlq $0x5, %rcx
addq %rcx, %rax
movq (%rax), %rsi
callq 0x659b0
movq %rax, -0x48(%rbp)
cmpq $0x0, -0x48(%rbp)
je 0x773e1
movq -0x48(%rbp), %rax
movq (%rax), %rdi
movq -0x38(%rbp), %rsi
callq 0xc970
movl %eax, %ecx
xorl %eax, %eax
cmpl %ecx, %eax
jne 0x773e1
movl -0x30(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0x773fa
jmp 0x773e3
jmp 0x773e5
movl -0x30(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x30(%rbp)
jmp 0x77336
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
movl -0x4(%rbp), %eax
addq $0x50, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/barabo[P]advanced-shell-history/src/sqlite3.c
// Function: whereScanInit
static WhereTerm *whereScanInit(
  WhereScan *pScan,       /* The WhereScan object being initialized */
  WhereClause *pWC,       /* The WHERE clause to be scanned */
  int iCur,               /* Cursor to scan for */
  int iColumn,            /* Column to scan for */
  u32 opMask,             /* Operator(s) to scan for */
  Index *pIdx             /* Must be compatible with this index */
){
  int j;

  /* memset(pScan, 0, sizeof(*pScan)); */
  pScan->pOrigWC = pWC;
  pScan->pWC = pWC;
  if( pIdx && iColumn>=0 ){
    pScan->idxaff = pIdx->pTable->aCol[iColumn].affinity;
    for(j=0; pIdx->aiColumn[j]!=iColumn; j++){
      if( NEVER(j>=pIdx->nColumn) ) return 0;
    }
    pScan->zCollName = pIdx->azColl[j];
  }else{
    pScan->idxaff = 0;
    pScan->zCollName = 0;
  }
  pScan->opMask = opMask;
  pScan->k = 0;
  pScan->aEquiv[0] = iCur;
  pScan->aEquiv[1] = iColumn;
  pScan->nEquiv = 2;
  pScan->iEquiv = 2;
  return whereScanNext(pScan);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movl %edx, -0x1c(%rbp)
movl %ecx, -0x20(%rbp)
movl %r8d, -0x24(%rbp)
movq %r9, -0x30(%rbp)
movq -0x18(%rbp), %rcx
movq -0x10(%rbp), %rax
movq %rcx, (%rax)
movq -0x18(%rbp), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x8(%rax)
cmpq $0x0, -0x30(%rbp)
je 0x774d5
cmpl $0x0, -0x20(%rbp)
jl 0x774d5
movq -0x30(%rbp), %rax
movq 0x18(%rax), %rax
movq 0x8(%rax), %rax
movslq -0x20(%rbp), %rcx
imulq $0x30, %rcx, %rcx
addq %rcx, %rax
movb 0x29(%rax), %cl
movq -0x10(%rbp), %rax
movb %cl, 0x18(%rax)
movl $0x0, -0x34(%rbp)
movq -0x30(%rbp), %rax
movq 0x8(%rax), %rax
movslq -0x34(%rbp), %rcx
movl (%rax,%rcx,4), %eax
cmpl -0x20(%rbp), %eax
je 0x774bb
movl -0x34(%rbp), %eax
movq -0x30(%rbp), %rcx
movzwl 0x54(%rcx), %ecx
cmpl %ecx, %eax
jl 0x774ae
movq $0x0, -0x8(%rbp)
jmp 0x7752f
jmp 0x774b0
movl -0x34(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x34(%rbp)
jmp 0x7747e
movq -0x30(%rbp), %rax
movq 0x40(%rax), %rax
movslq -0x34(%rbp), %rcx
movq (%rax,%rcx,8), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x10(%rax)
jmp 0x774e9
movq -0x10(%rbp), %rax
movb $0x0, 0x18(%rax)
movq -0x10(%rbp), %rax
movq $0x0, 0x10(%rax)
movl -0x24(%rbp), %ecx
movq -0x10(%rbp), %rax
movl %ecx, 0x1c(%rax)
movq -0x10(%rbp), %rax
movl $0x0, 0x20(%rax)
movl -0x1c(%rbp), %ecx
movq -0x10(%rbp), %rax
movl %ecx, 0x24(%rax)
movl -0x20(%rbp), %ecx
movq -0x10(%rbp), %rax
movl %ecx, 0x28(%rax)
movq -0x10(%rbp), %rax
movb $0x2, 0x19(%rax)
movq -0x10(%rbp), %rax
movb $0x2, 0x1a(%rax)
movq -0x10(%rbp), %rdi
callq 0x77540
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x40, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/barabo[P]advanced-shell-history/src/sqlite3.c
// Function: columnsInIndex
static Bitmask columnsInIndex(Index *pIdx){
  Bitmask m = 0;
  int j;
  for(j=pIdx->nColumn-1; j>=0; j--){
    int x = pIdx->aiColumn[j];
    assert( x>=0 );
    testcase( x==BMS-1 );
    testcase( x==BMS-2 );
    if( x<BMS-1 ) m |= MASKBIT(x);
  }
  return m;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq $0x0, -0x10(%rbp)
movq -0x8(%rbp), %rax
movzwl 0x54(%rax), %eax
subl $0x1, %eax
movl %eax, -0x14(%rbp)
cmpl $0x0, -0x14(%rbp)
jl 0x778de
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rax
movslq -0x14(%rbp), %rcx
movl (%rax,%rcx,4), %eax
movl %eax, -0x18(%rbp)
cmpl $0x3f, -0x18(%rbp)
jge 0x778d1
movl -0x18(%rbp), %eax
movl %eax, %ecx
movl $0x1, %eax
shlq %cl, %rax
orq -0x10(%rbp), %rax
movq %rax, -0x10(%rbp)
jmp 0x778d3
movl -0x14(%rbp), %eax
addl $-0x1, %eax
movl %eax, -0x14(%rbp)
jmp 0x7789e
movq -0x10(%rbp), %rax
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/barabo[P]advanced-shell-history/src/sqlite3.c
// Function: whereLoopResize
static int whereLoopResize(sqlite3 *db, WhereLoop *p, int n){
  WhereTerm **paNew;
  if( p->nLSlot>=n ) return SQLITE_OK;
  n = (n+7)&~7;
  paNew = sqlite3DbMallocRaw(db, sizeof(p->aLTerm[0])*n);
  if( paNew==0 ) return SQLITE_NOMEM;
  memcpy(paNew, p->aLTerm, sizeof(p->aLTerm[0])*p->nLSlot);
  if( p->aLTerm!=p->aLTermSpace ) sqlite3DbFree(db, p->aLTerm);
  p->aLTerm = paNew;
  p->nLSlot = n;
  return SQLITE_OK;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movl %edx, -0x1c(%rbp)
movq -0x18(%rbp), %rax
movzwl 0x2e(%rax), %eax
cmpl -0x1c(%rbp), %eax
jl 0x78ffc
movl $0x0, -0x4(%rbp)
jmp 0x79095
movl -0x1c(%rbp), %eax
addl $0x7, %eax
andl $-0x8, %eax
movl %eax, -0x1c(%rbp)
movq -0x10(%rbp), %rdi
movslq -0x1c(%rbp), %rax
shlq $0x3, %rax
movl %eax, %esi
callq 0x134e0
movq %rax, -0x28(%rbp)
cmpq $0x0, -0x28(%rbp)
jne 0x7902f
movl $0x7, -0x4(%rbp)
jmp 0x79095
movq -0x28(%rbp), %rdi
movq -0x18(%rbp), %rax
movq 0x30(%rax), %rsi
movq -0x18(%rbp), %rax
movzwl 0x2e(%rax), %eax
movl %eax, %edx
shlq $0x3, %rdx
callq 0x82f0
movq -0x18(%rbp), %rax
movq 0x30(%rax), %rax
movq -0x18(%rbp), %rcx
addq $0x40, %rcx
cmpq %rcx, %rax
je 0x79074
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rax
movq 0x30(%rax), %rsi
callq 0x9cd0
movq -0x28(%rbp), %rcx
movq -0x18(%rbp), %rax
movq %rcx, 0x30(%rax)
movl -0x1c(%rbp), %eax
movw %ax, %cx
movq -0x18(%rbp), %rax
movw %cx, 0x2e(%rax)
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x30, %rsp
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O0/barabo[P]advanced-shell-history/src/sqlite3.c
// Function: vtabBestIndex
static int vtabBestIndex(Parse *pParse, Table *pTab, sqlite3_index_info *p){
  sqlite3_vtab *pVtab = sqlite3GetVTable(pParse->db, pTab)->pVtab;
  int i;
  int rc;

  TRACE_IDX_INPUTS(p);
  rc = pVtab->pModule->xBestIndex(pVtab, p);
  TRACE_IDX_OUTPUTS(p);

  if( rc!=SQLITE_OK ){
    if( rc==SQLITE_NOMEM ){
      pParse->db->mallocFailed = 1;
    }else if( !pVtab->zErrMsg ){
      sqlite3ErrorMsg(pParse, "%s", sqlite3ErrStr(rc));
    }else{
      sqlite3ErrorMsg(pParse, "%s", pVtab->zErrMsg);
    }
  }
  sqlite3_free(pVtab->zErrMsg);
  pVtab->zErrMsg = 0;

  for(i=0; i<p->nConstraint; i++){
    if( !p->aConstraint[i].usable && p->aConstraintUsage[i].argvIndex>0 ){
      sqlite3ErrorMsg(pParse, 
          "table %s: xBestIndex returned an invalid plan", pTab->zName);
    }
  }

  return pParse->nErr;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq -0x8(%rbp), %rax
movq (%rax), %rdi
movq -0x10(%rbp), %rsi
callq 0x49880
movq 0x10(%rax), %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rax
movq (%rax), %rax
movq 0x18(%rax), %rax
movq -0x20(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq *%rax
movl %eax, -0x28(%rbp)
cmpl $0x0, -0x28(%rbp)
je 0x7914d
cmpl $0x7, -0x28(%rbp)
jne 0x790fd
movq -0x8(%rbp), %rax
movq (%rax), %rax
movb $0x1, 0x50(%rax)
jmp 0x7914b
movq -0x20(%rbp), %rax
cmpq $0x0, 0x10(%rax)
jne 0x7912f
movq -0x8(%rbp), %rax
movq %rax, -0x30(%rbp)
movl -0x28(%rbp), %edi
callq 0x11060
movq -0x30(%rbp), %rdi
movq %rax, %rdx
leaq 0x350aa(%rip), %rsi     # 0xae1d0
movb $0x0, %al
callq 0x136f0
jmp 0x79149
movq -0x8(%rbp), %rdi
movq -0x20(%rbp), %rax
movq 0x10(%rax), %rdx
leaq 0x3508e(%rip), %rsi     # 0xae1d0
movb $0x0, %al
callq 0x136f0
jmp 0x7914b
jmp 0x7914d
movq -0x20(%rbp), %rax
movq 0x10(%rax), %rdi
callq 0xa420
movq -0x20(%rbp), %rax
movq $0x0, 0x10(%rax)
movl $0x0, -0x24(%rbp)
movl -0x24(%rbp), %eax
movq -0x18(%rbp), %rcx
cmpl (%rcx), %eax
jge 0x791c9
movq -0x18(%rbp), %rax
movq 0x8(%rax), %rax
movslq -0x24(%rbp), %rcx
imulq $0xc, %rcx, %rcx
addq %rcx, %rax
cmpb $0x0, 0x5(%rax)
jne 0x791bc
movq -0x18(%rbp), %rax
movq 0x20(%rax), %rax
movslq -0x24(%rbp), %rcx
cmpl $0x0, (%rax,%rcx,8)
jle 0x791bc
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rax
movq (%rax), %rdx
leaq 0x37420(%rip), %rsi     # 0xb05d5
movb $0x0, %al
callq 0x136f0
jmp 0x791be
movl -0x24(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x24(%rbp)
jmp 0x7916d
movq -0x8(%rbp), %rax
movl 0x50(%rax), %eax
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/barabo[P]advanced-shell-history/src/sqlite3.c
// Function: whereCostFromDouble
static WhereCost whereCostFromDouble(double x){
  u64 a;
  WhereCost e;
  assert( sizeof(x)==8 && sizeof(a)==8 );
  if( x<=1 ) return 0;
  if( x<=2000000000 ) return whereCost((tRowcnt)x);
  memcpy(&a, &x, 8);
  e = (a>>52) - 1022;
  return e*10;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movsd %xmm0, -0x10(%rbp)
movsd 0x34c63(%rip), %xmm0    # 0xade58
ucomisd -0x10(%rbp), %xmm0
jb 0x79204
movw $0x0, -0x2(%rbp)
jmp 0x7924b
movsd 0x34c54(%rip), %xmm0    # 0xade60
ucomisd -0x10(%rbp), %xmm0
jb 0x79226
cvttsd2si -0x10(%rbp), %rax
movl %eax, %edi
callq 0x794f0
movw %ax, -0x2(%rbp)
jmp 0x7924b
movq -0x10(%rbp), %rax
movq %rax, -0x18(%rbp)
movq -0x18(%rbp), %rax
shrq $0x34, %rax
subq $0x3fe, %rax            # imm = 0x3FE
movw %ax, -0x1a(%rbp)
movzwl -0x1a(%rbp), %eax
imull $0xa, %eax, %eax
movw %ax, -0x2(%rbp)
movw -0x2(%rbp), %ax
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/barabo[P]advanced-shell-history/src/sqlite3.c
// Function: whereCost
static WhereCost whereCost(tRowcnt x){
  static WhereCost a[] = { 0, 2, 3, 5, 6, 7, 8, 9 };
  WhereCost y = 40;
  if( x<8 ){
    if( x<2 ) return 0;
    while( x<8 ){  y -= 10; x <<= 1; }
  }else{
    while( x>255 ){ y += 40; x >>= 4; }
    while( x>15 ){  y += 10; x >>= 1; }
  }
  return a[x&7] + y - 10;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movl %edi, -0x8(%rbp)
movw $0x28, -0xa(%rbp)
cmpl $0x8, -0x8(%rbp)
jae 0x79533
cmpl $0x2, -0x8(%rbp)
jae 0x79514
movw $0x0, -0x2(%rbp)
jmp 0x79595
jmp 0x79516
cmpl $0x8, -0x8(%rbp)
jae 0x79531
movzwl -0xa(%rbp), %eax
subl $0xa, %eax
movw %ax, -0xa(%rbp)
movl -0x8(%rbp), %eax
shll %eax
movl %eax, -0x8(%rbp)
jmp 0x79516
jmp 0x79573
jmp 0x79535
cmpl $0xff, -0x8(%rbp)
jbe 0x79554
movzwl -0xa(%rbp), %eax
addl $0x28, %eax
movw %ax, -0xa(%rbp)
movl -0x8(%rbp), %eax
shrl $0x4, %eax
movl %eax, -0x8(%rbp)
jmp 0x79535
jmp 0x79556
cmpl $0xf, -0x8(%rbp)
jbe 0x79571
movzwl -0xa(%rbp), %eax
addl $0xa, %eax
movw %ax, -0xa(%rbp)
movl -0x8(%rbp), %eax
shrl %eax
movl %eax, -0x8(%rbp)
jmp 0x79556
jmp 0x79573
movl -0x8(%rbp), %eax
andl $0x7, %eax
movl %eax, %eax
movl %eax, %ecx
leaq 0x575cc(%rip), %rax     # 0xd0b50
movzwl (%rax,%rcx,2), %eax
movzwl -0xa(%rbp), %ecx
addl %ecx, %eax
subl $0xa, %eax
movw %ax, -0x2(%rbp)
movw -0x2(%rbp), %ax
popq %rbp
retq
nopl (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/barabo[P]advanced-shell-history/src/sqlite3.c
// Function: whereLoopXfer
static int whereLoopXfer(sqlite3 *db, WhereLoop *pTo, WhereLoop *pFrom){
  if( whereLoopResize(db, pTo, pFrom->nLTerm) ) return SQLITE_NOMEM;
  whereLoopClearUnion(db, pTo);
  memcpy(pTo, pFrom, WHERE_LOOP_XFER_SZ);
  memcpy(pTo->aLTerm, pFrom->aLTerm, pTo->nLTerm*sizeof(pTo->aLTerm[0]));
  if( pFrom->wsFlags & WHERE_VIRTUALTABLE ){
    pFrom->u.vtab.needFree = 0;
  }else if( (pFrom->wsFlags & WHERE_AUTO_INDEX)!=0 ){
    pFrom->u.btree.pIndex = 0;
  }
  return SQLITE_OK;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
movq -0x20(%rbp), %rax
movzwl 0x2c(%rax), %edx
callq 0x78fd0
cmpl $0x0, %eax
je 0x7979a
movl $0x7, -0x4(%rbp)
jmp 0x7981d
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x79830
movq -0x18(%rbp), %rdi
movq -0x20(%rbp), %rsi
movl $0x2e, %edx
callq 0x82f0
movq -0x18(%rbp), %rax
movq 0x30(%rax), %rdi
movq -0x20(%rbp), %rax
movq 0x30(%rax), %rsi
movq -0x18(%rbp), %rax
movzwl 0x2c(%rax), %eax
movl %eax, %edx
shlq $0x3, %rdx
callq 0x82f0
movq -0x20(%rbp), %rax
movl 0x28(%rax), %eax
andl $0x400, %eax            # imm = 0x400
cmpl $0x0, %eax
je 0x797f7
movq -0x20(%rbp), %rax
movb $0x0, 0x1c(%rax)
jmp 0x79816
movq -0x20(%rbp), %rax
movl 0x28(%rax), %eax
andl $0x4000, %eax           # imm = 0x4000
cmpl $0x0, %eax
je 0x79814
movq -0x20(%rbp), %rax
movq $0x0, 0x20(%rax)
jmp 0x79816
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/barabo[P]advanced-shell-history/src/sqlite3.c
// Function: whereLoopClearUnion
static void whereLoopClearUnion(sqlite3 *db, WhereLoop *p){
  if( p->wsFlags & (WHERE_VIRTUALTABLE|WHERE_AUTO_INDEX) ){
    if( (p->wsFlags & WHERE_VIRTUALTABLE)!=0 && p->u.vtab.needFree ){
      sqlite3_free(p->u.vtab.idxStr);
      p->u.vtab.needFree = 0;
      p->u.vtab.idxStr = 0;
    }else if( (p->wsFlags & WHERE_AUTO_INDEX)!=0 && p->u.btree.pIndex!=0 ){
      sqlite3DbFree(db, p->u.btree.pIndex->zColAff);
      sqlite3DbFree(db, p->u.btree.pIndex);
      p->u.btree.pIndex = 0;
    }
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movl 0x28(%rax), %eax
andl $0x4400, %eax           # imm = 0x4400
cmpl $0x0, %eax
je 0x798e8
movq -0x10(%rbp), %rax
movl 0x28(%rax), %eax
andl $0x400, %eax            # imm = 0x400
cmpl $0x0, %eax
je 0x79896
movq -0x10(%rbp), %rax
movzbl 0x1c(%rax), %eax
cmpl $0x0, %eax
je 0x79896
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rdi
callq 0xa420
movq -0x10(%rbp), %rax
movb $0x0, 0x1c(%rax)
movq -0x10(%rbp), %rax
movq $0x0, 0x20(%rax)
jmp 0x798e6
movq -0x10(%rbp), %rax
movl 0x28(%rax), %eax
andl $0x4000, %eax           # imm = 0x4000
cmpl $0x0, %eax
je 0x798e4
movq -0x10(%rbp), %rax
cmpq $0x0, 0x20(%rax)
je 0x798e4
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movq 0x20(%rax), %rsi
callq 0x9cd0
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rsi
callq 0x9cd0
movq -0x10(%rbp), %rax
movq $0x0, 0x20(%rax)
jmp 0x798e6
jmp 0x798e8
addq $0x10, %rsp
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O0/barabo[P]advanced-shell-history/src/sqlite3.c
// Function: termCanDriveIndex
static int termCanDriveIndex(
  WhereTerm *pTerm,              /* WHERE clause term to check */
  struct SrcList_item *pSrc,     /* Table we are trying to access */
  Bitmask notReady               /* Tables in outer loops of the join */
){
  char aff;
  if( pTerm->leftCursor!=pSrc->iCursor ) return 0;
  if( (pTerm->eOperator & WO_EQ)==0 ) return 0;
  if( (pTerm->prereqRight & notReady)!=0 ) return 0;
  if( pTerm->u.leftColumn<0 ) return 0;
  aff = pSrc->pTab->aCol[pTerm->u.leftColumn].affinity;
  if( !sqlite3IndexAffinityOk(pTerm->pExpr, aff) ) return 0;
  return 1;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq -0x10(%rbp), %rax
movl 0xc(%rax), %eax
movq -0x18(%rbp), %rcx
cmpl 0x3c(%rcx), %eax
je 0x79970
movl $0x0, -0x4(%rbp)
jmp 0x799fd
movq -0x10(%rbp), %rax
movzwl 0x18(%rax), %eax
andl $0x2, %eax
cmpl $0x0, %eax
jne 0x79989
movl $0x0, -0x4(%rbp)
jmp 0x799fd
movq -0x10(%rbp), %rax
movq 0x28(%rax), %rax
andq -0x20(%rbp), %rax
cmpq $0x0, %rax
je 0x799a4
movl $0x0, -0x4(%rbp)
jmp 0x799fd
movq -0x10(%rbp), %rax
cmpl $0x0, 0x10(%rax)
jge 0x799b7
movl $0x0, -0x4(%rbp)
jmp 0x799fd
movq -0x18(%rbp), %rax
movq 0x20(%rax), %rax
movq 0x8(%rax), %rax
movq -0x10(%rbp), %rcx
movslq 0x10(%rcx), %rcx
imulq $0x30, %rcx, %rcx
addq %rcx, %rax
movb 0x29(%rax), %al
movb %al, -0x21(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rdi
movsbl -0x21(%rbp), %esi
callq 0x6b210
cmpl $0x0, %eax
jne 0x799f6
movl $0x0, -0x4(%rbp)
jmp 0x799fd
movl $0x1, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/barabo[P]advanced-shell-history/src/sqlite3.c
// Function: whereCostAdd
static WhereCost whereCostAdd(WhereCost a, WhereCost b){
  static const unsigned char x[] = {
     10, 10,                         /* 0,1 */
      9, 9,                          /* 2,3 */
      8, 8,                          /* 4,5 */
      7, 7, 7,                       /* 6,7,8 */
      6, 6, 6,                       /* 9,10,11 */
      5, 5, 5,                       /* 12-14 */
      4, 4, 4, 4,                    /* 15-18 */
      3, 3, 3, 3, 3, 3,              /* 19-24 */
      2, 2, 2, 2, 2, 2, 2,           /* 25-31 */
  };
  if( a>=b ){
    if( a>b+49 ) return a;
    if( a>b+31 ) return a+1;
    return a+x[a-b];
  }else{
    if( b>a+49 ) return b;
    if( b>a+31 ) return b+1;
    return b+x[b-a];
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movw %si, %ax
movw %di, %cx
movw %cx, -0x4(%rbp)
movw %ax, -0x6(%rbp)
movzwl -0x4(%rbp), %eax
movzwl -0x6(%rbp), %ecx
cmpl %ecx, %eax
jl 0x79a8a
movzwl -0x4(%rbp), %eax
movzwl -0x6(%rbp), %ecx
addl $0x31, %ecx
cmpl %ecx, %eax
jle 0x79a4a
movw -0x4(%rbp), %ax
movw %ax, -0x2(%rbp)
jmp 0x79ae1
movzwl -0x4(%rbp), %eax
movzwl -0x6(%rbp), %ecx
addl $0x1f, %ecx
cmpl %ecx, %eax
jle 0x79a66
movzwl -0x4(%rbp), %eax
addl $0x1, %eax
movw %ax, -0x2(%rbp)
jmp 0x79ae1
movzwl -0x4(%rbp), %eax
movzwl -0x4(%rbp), %ecx
movzwl -0x6(%rbp), %edx
subl %edx, %ecx
movslq %ecx, %rdx
leaq 0x33982(%rip), %rcx     # 0xad400
movzbl (%rcx,%rdx), %ecx
addl %ecx, %eax
movw %ax, -0x2(%rbp)
jmp 0x79ae1
movzwl -0x6(%rbp), %eax
movzwl -0x4(%rbp), %ecx
addl $0x31, %ecx
cmpl %ecx, %eax
jle 0x79aa3
movw -0x6(%rbp), %ax
movw %ax, -0x2(%rbp)
jmp 0x79ae1
movzwl -0x6(%rbp), %eax
movzwl -0x4(%rbp), %ecx
addl $0x1f, %ecx
cmpl %ecx, %eax
jle 0x79abf
movzwl -0x6(%rbp), %eax
addl $0x1, %eax
movw %ax, -0x2(%rbp)
jmp 0x79ae1
movzwl -0x6(%rbp), %eax
movzwl -0x6(%rbp), %ecx
movzwl -0x4(%rbp), %edx
subl %edx, %ecx
movslq %ecx, %rdx
leaq 0x33929(%rip), %rcx     # 0xad400
movzbl (%rcx,%rdx), %ecx
addl %ecx, %eax
movw %ax, -0x2(%rbp)
movw -0x2(%rbp), %ax
popq %rbp
retq
nopw (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/barabo[P]advanced-shell-history/src/sqlite3.c
// Function: whereUsablePartialIndex
static int whereUsablePartialIndex(int iTab, WhereClause *pWC, Expr *pWhere){
  int i;
  WhereTerm *pTerm;
  for(i=0, pTerm=pWC->a; i<pWC->nTerm; i++, pTerm++){
    if( sqlite3ExprImpliesExpr(pTerm->pExpr, pWhere, iTab) ) return 1;
  }
  return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movl %edi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movl $0x0, -0x1c(%rbp)
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movq %rax, -0x28(%rbp)
movl -0x1c(%rbp), %eax
movq -0x10(%rbp), %rcx
cmpl 0x14(%rcx), %eax
jge 0x79b5c
movq -0x28(%rbp), %rax
movq (%rax), %rdi
movq -0x18(%rbp), %rsi
movl -0x8(%rbp), %edx
callq 0x7a420
cmpl $0x0, %eax
je 0x79b43
movl $0x1, -0x4(%rbp)
jmp 0x79b63
jmp 0x79b45
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
movq -0x28(%rbp), %rax
addq $0x38, %rax
movq %rax, -0x28(%rbp)
jmp 0x79b16
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x30, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/barabo[P]advanced-shell-history/src/sqlite3.c
// Function: indexMightHelpWithOrderBy
static int indexMightHelpWithOrderBy(
  WhereLoopBuilder *pBuilder,
  Index *pIndex,
  int iCursor
){
  ExprList *pOB;
  int ii, jj;

  if( pIndex->bUnordered ) return 0;
  if( (pOB = pBuilder->pWInfo->pOrderBy)==0 ) return 0;
  for(ii=0; ii<pOB->nExpr; ii++){
    Expr *pExpr = sqlite3ExprSkipCollate(pOB->a[ii].pExpr);
    if( pExpr->op!=TK_COLUMN ) return 0;
    if( pExpr->iTable==iCursor ){
      for(jj=0; jj<pIndex->nColumn; jj++){
        if( pExpr->iColumn==pIndex->aiColumn[jj] ) return 1;
      }
    }
  }
  return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movl %edx, -0x1c(%rbp)
movq -0x18(%rbp), %rax
movb 0x57(%rax), %al
shrb $0x2, %al
andb $0x1, %al
movzbl %al, %eax
cmpl $0x0, %eax
je 0x79ba3
movl $0x0, -0x4(%rbp)
jmp 0x79c7a
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq 0x10(%rax), %rax
movq %rax, -0x28(%rbp)
cmpq $0x0, %rax
jne 0x79bc4
movl $0x0, -0x4(%rbp)
jmp 0x79c7a
movl $0x0, -0x2c(%rbp)
movl -0x2c(%rbp), %eax
movq -0x28(%rbp), %rcx
cmpl (%rcx), %eax
jge 0x79c73
movq -0x28(%rbp), %rax
movq 0x8(%rax), %rax
movslq -0x2c(%rbp), %rcx
shlq $0x5, %rcx
addq %rcx, %rax
movq (%rax), %rdi
callq 0x648b0
movq %rax, -0x38(%rbp)
movq -0x38(%rbp), %rax
movzbl (%rax), %eax
cmpl $0x98, %eax
je 0x79c10
movl $0x0, -0x4(%rbp)
jmp 0x79c7a
movq -0x38(%rbp), %rax
movl 0x2c(%rax), %eax
cmpl -0x1c(%rbp), %eax
jne 0x79c63
movl $0x0, -0x30(%rbp)
movl -0x30(%rbp), %eax
movq -0x18(%rbp), %rcx
movzwl 0x54(%rcx), %ecx
cmpl %ecx, %eax
jge 0x79c61
movq -0x38(%rbp), %rax
movswl 0x30(%rax), %eax
movq -0x18(%rbp), %rcx
movq 0x8(%rcx), %rcx
movslq -0x30(%rbp), %rdx
cmpl (%rcx,%rdx,4), %eax
jne 0x79c54
movl $0x1, -0x4(%rbp)
jmp 0x79c7a
jmp 0x79c56
movl -0x30(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x30(%rbp)
jmp 0x79c23
jmp 0x79c63
jmp 0x79c65
movl -0x2c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x2c(%rbp)
jmp 0x79bcb
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x40, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/barabo[P]advanced-shell-history/src/sqlite3.c
// Function: sqlite3ExprImpliesExpr
SQLITE_PRIVATE int sqlite3ExprImpliesExpr(Expr *pE1, Expr *pE2, int iTab){
  if( sqlite3ExprCompare(pE1, pE2, iTab)==0 ){
    return 1;
  }
  if( pE2->op==TK_OR
   && (sqlite3ExprImpliesExpr(pE1, pE2->pLeft, iTab)
             || sqlite3ExprImpliesExpr(pE1, pE2->pRight, iTab) )
  ){
    return 1;
  }
  if( pE2->op==TK_NOTNULL
   && sqlite3ExprCompare(pE1->pLeft, pE2->pLeft, iTab)==0
   && (pE1->op!=TK_ISNULL && pE1->op!=TK_IS)
  ){
    return 1;
  }
  return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movl %edx, -0x1c(%rbp)
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
movl -0x1c(%rbp), %edx
callq 0x66220
cmpl $0x0, %eax
jne 0x7a454
movl $0x1, -0x4(%rbp)
jmp 0x7a4ec
movq -0x18(%rbp), %rax
movzbl (%rax), %eax
cmpl $0x44, %eax
jne 0x7a49b
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rsi
movl -0x1c(%rbp), %edx
callq 0x7a420
cmpl $0x0, %eax
jne 0x7a492
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rax
movq 0x18(%rax), %rsi
movl -0x1c(%rbp), %edx
callq 0x7a420
cmpl $0x0, %eax
je 0x7a49b
movl $0x1, -0x4(%rbp)
jmp 0x7a4ec
movq -0x18(%rbp), %rax
movzbl (%rax), %eax
cmpl $0x4a, %eax
jne 0x7a4e5
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rdi
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rsi
movl -0x1c(%rbp), %edx
callq 0x66220
cmpl $0x0, %eax
jne 0x7a4e5
movq -0x10(%rbp), %rax
movzbl (%rax), %eax
cmpl $0x49, %eax
je 0x7a4e5
movq -0x10(%rbp), %rax
movzbl (%rax), %eax
cmpl $0x46, %eax
je 0x7a4e5
movl $0x1, -0x4(%rbp)
jmp 0x7a4ec
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/barabo[P]advanced-shell-history/src/sqlite3.c
// Function: explainAppendTerm
static void explainAppendTerm(
  StrAccum *pStr,             /* The text expression being built */
  int iTerm,                  /* Index of this term.  First is zero */
  const char *zColumn,        /* Name of the column */
  const char *zOp             /* Name of the operator */
){
  if( iTerm ) sqlite3StrAccumAppend(pStr, " AND ", 5);
  sqlite3StrAccumAppend(pStr, zColumn, -1);
  sqlite3StrAccumAppend(pStr, zOp, 1);
  sqlite3StrAccumAppend(pStr, "?", 1);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
cmpl $0x0, -0xc(%rbp)
je 0x7b052
movq -0x8(%rbp), %rdi
leaq 0x356d2(%rip), %rsi     # 0xb071a
movl $0x5, %edx
callq 0x1bb70
movq -0x8(%rbp), %rdi
movq -0x18(%rbp), %rsi
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
callq 0x1bb70
movq -0x8(%rbp), %rdi
movq -0x20(%rbp), %rsi
movl $0x1, %edx
callq 0x1bb70
movq -0x8(%rbp), %rdi
leaq 0x3338c(%rip), %rsi     # 0xae40d
movl $0x1, %edx
callq 0x1bb70
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/barabo[P]advanced-shell-history/src/sqlite3.c
// Function: disableTerm
static void disableTerm(WhereLevel *pLevel, WhereTerm *pTerm){
  if( pTerm
      && (pTerm->wtFlags & TERM_CODED)==0
      && (pLevel->iLeftJoin==0 || ExprHasProperty(pTerm->pExpr, EP_FromJoin))
  ){
    pTerm->wtFlags |= TERM_CODED;
    if( pTerm->iParent>=0 ){
      WhereTerm *pOther = &pTerm->pWC->a[pTerm->iParent];
      if( (--pOther->nChild)==0 ){
        disableTerm(pLevel, pOther);
      }
    }
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
cmpq $0x0, -0x10(%rbp)
je 0x7b3c3
movq -0x10(%rbp), %rax
movzbl 0x1a(%rax), %eax
andl $0x4, %eax
cmpl $0x0, %eax
jne 0x7b3c3
movq -0x8(%rbp), %rax
cmpl $0x0, (%rax)
je 0x7b367
movq -0x10(%rbp), %rax
movq (%rax), %rax
movzwl 0x2(%rax), %eax
andl $0x1, %eax
cmpl $0x1, %eax
jne 0x7b3c3
movq -0x10(%rbp), %rax
movzbl 0x1a(%rax), %ecx
orl $0x4, %ecx
movb %cl, 0x1a(%rax)
movq -0x10(%rbp), %rax
cmpl $0x0, 0x8(%rax)
jl 0x7b3c1
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movq 0x20(%rax), %rax
movq -0x10(%rbp), %rcx
movslq 0x8(%rcx), %rcx
imulq $0x38, %rcx, %rcx
addq %rcx, %rax
movq %rax, -0x18(%rbp)
movq -0x18(%rbp), %rcx
movb 0x1b(%rcx), %al
addb $-0x1, %al
movb %al, 0x1b(%rcx)
movzbl %al, %eax
cmpl $0x0, %eax
jne 0x7b3bf
movq -0x8(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x7b320
jmp 0x7b3c1
jmp 0x7b3c3
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax)