// File: /workspace/github_c_makefile_star2_O0/skeeto[P]flappy/sqlite3.c
// Function: sqlite3KeyInfoOfIndex
SQLITE_PRIVATE KeyInfo *sqlite3KeyInfoOfIndex(Parse *pParse, Index *pIdx){
  if( pParse->nErr ) return 0;
#ifndef SQLITE_OMIT_SHARED_CACHE
  if( pIdx->pKeyInfo && pIdx->pKeyInfo->db!=pParse->db ){
    sqlite3KeyInfoUnref(pIdx->pKeyInfo);
    pIdx->pKeyInfo = 0;
  }
#endif
  if( pIdx->pKeyInfo==0 ){
    int i;
    int nCol = pIdx->nColumn;
    int nKey = pIdx->nKeyCol;
    KeyInfo *pKey;
    if( pIdx->uniqNotNull ){
      pKey = sqlite3KeyInfoAlloc(pParse->db, nKey, nCol-nKey);
    }else{
      pKey = sqlite3KeyInfoAlloc(pParse->db, nCol, 0);
    }
    if( pKey ){
      assert( sqlite3KeyInfoIsWriteable(pKey) );
      for(i=0; i<nCol; i++){
        char *zColl = pIdx->azColl[i];
        if( NEVER(zColl==0) ) zColl = "BINARY";
        pKey->aColl[i] = sqlite3LocateCollSeq(pParse, zColl);
        pKey->aSortOrder[i] = pIdx->aSortOrder[i];
      }
      if( pParse->nErr ){
        sqlite3KeyInfoUnref(pKey);
      }else{
        pIdx->pKeyInfo = pKey;
      }
    }
  }
  return sqlite3KeyInfoRef(pIdx->pKeyInfo);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x10(%rbp), %rax
cmpl $0x0, 0x50(%rax)
je 0x64177
movq $0x0, -0x8(%rbp)
jmp 0x642d5
movq -0x18(%rbp), %rax
cmpq $0x0, 0x50(%rax)
je 0x641b0
movq -0x18(%rbp), %rax
movq 0x50(%rax), %rax
movq 0x10(%rax), %rax
movq -0x10(%rbp), %rcx
cmpq (%rcx), %rax
je 0x641b0
movq -0x18(%rbp), %rax
movq 0x50(%rax), %rdi
callq 0x328e0
movq -0x18(%rbp), %rax
movq $0x0, 0x50(%rax)
movq -0x18(%rbp), %rax
cmpq $0x0, 0x50(%rax)
jne 0x642c4
movq -0x18(%rbp), %rax
movzwl 0x60(%rax), %eax
movl %eax, -0x20(%rbp)
movq -0x18(%rbp), %rax
movzwl 0x5e(%rax), %eax
movl %eax, -0x24(%rbp)
movq -0x18(%rbp), %rax
movb 0x63(%rax), %al
shrb $0x3, %al
andb $0x1, %al
movzbl %al, %eax
cmpl $0x0, %eax
je 0x64204
movq -0x10(%rbp), %rax
movq (%rax), %rdi
movl -0x24(%rbp), %esi
movl -0x20(%rbp), %edx
subl -0x24(%rbp), %edx
callq 0x642e0
movq %rax, -0x30(%rbp)
jmp 0x64219
movq -0x10(%rbp), %rax
movq (%rax), %rdi
movl -0x20(%rbp), %esi
xorl %edx, %edx
callq 0x642e0
movq %rax, -0x30(%rbp)
cmpq $0x0, -0x30(%rbp)
je 0x642c2
movl $0x0, -0x1c(%rbp)
movl -0x1c(%rbp), %eax
cmpl -0x20(%rbp), %eax
jge 0x6429f
movq -0x18(%rbp), %rax
movq 0x40(%rax), %rax
movslq -0x1c(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movq %rax, -0x38(%rbp)
cmpq $0x0, -0x38(%rbp)
jne 0x64259
leaq 0x35390(%rip), %rax     # 0x995e5
movq %rax, -0x38(%rbp)
movq -0x10(%rbp), %rdi
movq -0x38(%rbp), %rsi
callq 0x643a0
movq %rax, %rdx
movq -0x30(%rbp), %rax
movslq -0x1c(%rbp), %rcx
movq %rdx, 0x20(%rax,%rcx,8)
movq -0x18(%rbp), %rax
movq 0x38(%rax), %rax
movslq -0x1c(%rbp), %rcx
movb (%rax,%rcx), %dl
movq -0x30(%rbp), %rax
movq 0x18(%rax), %rax
movslq -0x1c(%rbp), %rcx
movb %dl, (%rax,%rcx)
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
jmp 0x6422b
movq -0x10(%rbp), %rax
cmpl $0x0, 0x50(%rax)
je 0x642b4
movq -0x30(%rbp), %rdi
callq 0x328e0
jmp 0x642c0
movq -0x30(%rbp), %rcx
movq -0x18(%rbp), %rax
movq %rcx, 0x50(%rax)
jmp 0x642c2
jmp 0x642c4
movq -0x18(%rbp), %rax
movq 0x50(%rax), %rdi
callq 0x64440
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x40, %rsp
popq %rbp
retq
nop