// File: /workspace/github_c_makefile_star2_O0/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: whereIndexExprTrans
static void whereIndexExprTrans(
  Index *pIdx,      /* The Index */
  int iTabCur,      /* Cursor of the table that is being indexed */
  int iIdxCur,      /* Cursor of the index itself */
  WhereInfo *pWInfo /* Transform expressions in this WHERE clause */
){
  int iIdxCol;               /* Column number of the index */
  ExprList *aColExpr;        /* Expressions that are indexed */
  Table *pTab;
  Walker w;
  IdxExprTrans x;
  aColExpr = pIdx->aColExpr;
  if( aColExpr==0 && !pIdx->bHasVCol ){
    /* The index does not reference any expressions or virtual columns
    ** so no translations are needed. */
    return;
  }
  pTab = pIdx->pTable;
  memset(&w, 0, sizeof(w));
  w.u.pIdxTrans = &x;
  x.iTabCur = iTabCur;
  x.iIdxCur = iIdxCur;
  x.pWInfo = pWInfo;
  x.db = pWInfo->pParse->db;
  for(iIdxCol=0; iIdxCol<pIdx->nColumn; iIdxCol++){
    i16 iRef = pIdx->aiColumn[iIdxCol];
    if( iRef==XN_EXPR ){
      assert( aColExpr->a[iIdxCol].pExpr!=0 );
      x.pIdxExpr = aColExpr->a[iIdxCol].pExpr;
      if( sqlite3ExprIsConstant(x.pIdxExpr) ) continue;
      w.xExprCallback = whereIndexExprTransNode;
#ifndef SQLITE_OMIT_GENERATED_COLUMNS
    }else if( iRef>=0
       && (pTab->aCol[iRef].colFlags & COLFLAG_VIRTUAL)!=0
       && (pTab->aCol[iRef].zColl==0
           || sqlite3StrICmp(pTab->aCol[iRef].zColl, sqlite3StrBINARY)==0)
    ){
      /* Check to see if there are direct references to generated columns
      ** that are contained in the index.  Pulling the generated column
      ** out of the index is an optimization only - the main table is always
      ** available if the index cannot be used.  To avoid unnecessary
      ** complication, omit this optimization if the collating sequence for
      ** the column is non-standard */
      x.iTabCol = iRef;
      w.xExprCallback = whereIndexExprTransColumn;
#endif /* SQLITE_OMIT_GENERATED_COLUMNS */
    }else{
      continue;
    }
    x.iIdxCol = iIdxCol;
    sqlite3WalkExpr(&w, pWInfo->pWhere);
    sqlite3WalkExprList(&w, pWInfo->pOrderBy);
    sqlite3WalkExprList(&w, pWInfo->pResultSet);
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x90, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movl %edx, -0x10(%rbp)
movq %rcx, -0x18(%rbp)
movq -0x8(%rbp), %rax
movq 0x50(%rax), %rax
movq %rax, -0x28(%rbp)
cmpq $0x0, -0x28(%rbp)
jne 0x456dd9
movq -0x8(%rbp), %rax
movw 0x63(%rax), %ax
shrw $0xa, %ax
andw $0x1, %ax
movzwl %ax, %eax
cmpl $0x0, %eax
jne 0x456dd9
jmp 0x456f81
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rax
movq %rax, -0x30(%rbp)
leaq -0x60(%rbp), %rdi
xorl %esi, %esi
movl $0x30, %edx
callq 0x19360
leaq -0x88(%rbp), %rax
movq %rax, -0x38(%rbp)
movl -0xc(%rbp), %eax
movl %eax, -0x80(%rbp)
movl -0x10(%rbp), %eax
movl %eax, -0x7c(%rbp)
movq -0x18(%rbp), %rax
movq %rax, -0x70(%rbp)
movq -0x18(%rbp), %rax
movq (%rax), %rax
movq (%rax), %rax
movq %rax, -0x68(%rbp)
movl $0x0, -0x1c(%rbp)
movl -0x1c(%rbp), %eax
movq -0x8(%rbp), %rcx
movzwl 0x60(%rcx), %ecx
cmpl %ecx, %eax
jge 0x456f81
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rax
movslq -0x1c(%rbp), %rcx
movw (%rax,%rcx,2), %ax
movw %ax, -0x8a(%rbp)
movswl -0x8a(%rbp), %eax
cmpl $-0x2, %eax
jne 0x456ea2
movq -0x28(%rbp), %rax
addq $0x8, %rax
movslq -0x1c(%rbp), %rcx
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
movq (%rax), %rax
movq %rax, -0x88(%rbp)
movq -0x88(%rbp), %rdi
callq 0x422b80
cmpl $0x0, %eax
je 0x456e92
jmp 0x456f73
leaq 0x597(%rip), %rax       # 0x457430
movq %rax, -0x58(%rbp)
jmp 0x456f3a
movswl -0x8a(%rbp), %eax
cmpl $0x0, %eax
jl 0x456f36
movq -0x30(%rbp), %rax
movq 0x8(%rax), %rax
movswq -0x8a(%rbp), %rcx
shlq $0x5, %rcx
addq %rcx, %rax
movzwl 0x1c(%rax), %eax
andl $0x20, %eax
cmpl $0x0, %eax
je 0x456f36
movq -0x30(%rbp), %rax
movq 0x8(%rax), %rax
movswq -0x8a(%rbp), %rcx
shlq $0x5, %rcx
addq %rcx, %rax
cmpq $0x0, 0x10(%rax)
je 0x456f1f
movq -0x30(%rbp), %rax
movq 0x8(%rax), %rax
movswq -0x8a(%rbp), %rcx
shlq $0x5, %rcx
addq %rcx, %rax
movq 0x10(%rax), %rdi
leaq 0x14fdc0(%rip), %rsi    # 0x5a6cd5
callq 0x3c3e60
cmpl $0x0, %eax
jne 0x456f36
movswl -0x8a(%rbp), %eax
movl %eax, -0x74(%rbp)
leaq 0x5c0(%rip), %rax       # 0x4574f0
movq %rax, -0x58(%rbp)
jmp 0x456f38
jmp 0x456f73
jmp 0x456f3a
movl -0x1c(%rbp), %eax
movl %eax, -0x78(%rbp)
movq -0x18(%rbp), %rax
movq 0x20(%rax), %rsi
leaq -0x60(%rbp), %rdi
callq 0x42f650
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rsi
leaq -0x60(%rbp), %rdi
callq 0x42f8b0
movq -0x18(%rbp), %rax
movq 0x18(%rax), %rsi
leaq -0x60(%rbp), %rdi
callq 0x42f8b0
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
jmp 0x456e29
addq $0x90, %rsp
popq %rbp
retq
nopw (%rax,%rax)