Function at 0x140012670
Capabilities:
Reference sql statements

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x68
mov r13, qword [rcx + 0x10]
mov rax, r8
mov r12, rdx
mov rdi, r8
mov r15, r9
or rax, r9
mov qword [rsp + 0xb0], rcx
mov dword [rsp + 0x4c], 0
jne 0x1400126c0
xor r15d, r15d
mov eax, r15d
add rsp, 0x68
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
mov qword [rsp + 0x50], 0
mov rax, qword [rdx]
mov rcx, qword [rax + 8]
test r8, r8
je 0x140012a4e
mov rax, r8
xor r14d, r14d
nop
mov rax, qword [rax + 0x20]
add r14d, 1
test rax, rax
jne 0x1400126e0
mov qword [rsp + 0x20], rcx
lea rdx, [rsp + 0x50]
xor r8d, r8d
mov rcx, r13
lea r9, str.PRAGMA_index_list_Q
call sym.idxPrintfPrepareStmt
mov ebx, eax
lea rax, [rsp + 0x58]
mov qword [rsp + 0x38], rax
test ebx, ebx
jne 0x140012831
mov qword [rsp + 0xb8], r12
mov rcx, qword [rsp + 0x50]
call sym.sqlite3_step
cmp eax, 0x64
jne 0x140012a56
mov rcx, qword [rsp + 0x50]
mov edx, 1
mov qword [rsp + 0x58], 0
call sym.sqlite3_column_text
test rax, rax
je 0x140012725
mov rdx, rdi
test rdi, rdi
je 0x140012770
nop dword [rax]
mov dword [rdx + 0x10], 0
mov rdx, qword [rdx + 0x20]
test rdx, rdx
jne 0x140012760
mov qword [rsp + 0x20], rax
mov rdx, qword [rsp + 0x38]
xor r8d, r8d
mov rcx, r13
lea r9, str.PRAGMA_index_xInfo_Q
call sym.idxPrintfPrepareStmt
test eax, eax
jne 0x140012af0
mov rbp, r15
mov rcx, qword [rsp + 0x58]
call sym.sqlite3_step
cmp eax, 0x64
jne 0x140012815
mov rcx, qword [rsp + 0x58]
xor edx, edx
call sym.sqlite3_column_int
mov rcx, qword [rsp + 0x58]
mov edx, 1
mov ebx, eax
call sym.sqlite3_column_int
mov rcx, qword [rsp + 0x58]
mov edx, 4
mov esi, eax
call sym.sqlite3_column_text
mov r12, rax
cmp ebx, r14d
jl 0x1400128c0
test rbp, rbp
je 0x140012797
cmp esi, dword [rbp + 0xc]
jne 0x140012900
mov rcx, qword [rbp]
mov rdx, rax
call sym.sqlite3_stricmp
test eax, eax
jne 0x140012900
mov rcx, qword [rsp + 0x58]
mov rbp, qword [rbp + 0x20]
call sym.sqlite3_step
cmp eax, 0x64
je 0x1400127a6
mov rcx, qword [rsp + 0x58]
mov r12, qword [rsp + 0xb8]
call sym.sqlite3_finalize
mov ebx, eax
test eax, eax
je 0x140012a2c
mov rcx, qword [rsp + 0x50]
call sym.sqlite3_finalize
mov dword [rsp + 0x4c], ebx
mov r14, qword [r12]
xor ebx, ebx
test rdi, rdi
je 0x140012876
lea rsi, [rsp + 0x4c]
mov rdx, rbx
nop word [rax + rax]
mov r8, qword [r14 + 0x10]
mov r9, rdi
mov rcx, rsi
call sym.idxAppendColDefn.isra.0
mov rdi, qword [rdi + 0x20]
mov rdx, rax
test rdi, rdi
jne 0x140012858
mov rbx, rax
test r15, r15
je 0x1400128a6
lea rsi, [rsp + 0x4c]
mov rdx, rbx
nop dword [rax + rax]
mov r8, qword [r14 + 0x10]
mov r9, r15
mov rcx, rsi
call sym.idxAppendColDefn.isra.0
mov r15, qword [r15 + 0x20]
mov rdx, rax
test r15, r15
jne 0x140012888
mov rbx, rax
mov r15d, dword [rsp + 0x4c]
test r15d, r15d
je 0x140012928
mov rcx, rbx
call sym.sqlite3_free
jmp 0x1400126a8
test rdi, rdi
je 0x140012900
mov rbx, rdi
jmp 0x1400128d9
mov rbx, qword [rbx + 0x20]
test rbx, rbx
je 0x140012900
mov edx, dword [rbx + 0x10]
test edx, edx
jne 0x1400128d0
cmp esi, dword [rbx + 0xc]
jne 0x1400128d0
mov rcx, qword [rbx]
mov rdx, r12
call sym.sqlite3_stricmp
test eax, eax
jne 0x1400128d0
mov dword [rbx + 0x10], 1
jmp 0x140012797
mov rcx, qword [rsp + 0x58]
call sym.sqlite3_finalize
test eax, eax
je 0x140012725
mov r12, qword [rsp + 0xb8]
mov ebx, eax
jmp 0x140012831
mov rax, qword [r12]
xor esi, esi
xor edi, edi
lea r14, str._s_idx__08x
mov rbp, rbx
mov r12, qword [rax + 8]
mov rcx, r12
call sym.idxIdentifierRequiresQuotes
mov dword [rsp + 0x38], eax
nop word [rax + rax]
mov dword [rsp + 0x58], 0
movsx eax, byte [rbp]
test al, al
je 0x14001297e
mov edx, 1
nop dword [rax]
mov dword [rsp + 0x58], edx
lea eax, [rax + rdi*8]
add rdx, 1
add edi, eax
movsx eax, byte [rbp + rdx - 1]
test al, al
jne 0x140012968
mov rcx, rsi
call sym.sqlite3_free
mov r8d, edi
mov rdx, r12
mov rcx, r14
call sym.sqlite3_mprintf
mov rsi, rax
test rax, rax
je 0x140012a3b
mov rdx, rax
lea rcx, str.SELECT_count___FROM_sqlite_schema_WHERE_name_Q_AND_type_in__index_table_view_
call sym.sqlite3_mprintf
lea r9, [rsp + 0x58]
mov rcx, r13
mov qword [rsp + 0x20], 0
lea r8, [sym.countNonzeros]
mov rdx, rax
mov dword [rsp + 0x58], 0
mov rbx, rax
call sym.sqlite3_exec
mov dword [rsp + 0x4c], eax
test eax, eax
jne 0x140012a10
mov rcx, rbx
call sym.sqlite3_free
mov eax, dword [rsp + 0x58]
test eax, eax
je 0x140012a6f
add r15d, 1
cmp r15d, 0x32
jne 0x140012950
mov rbx, rbp
mov r15d, 0x305
jmp 0x1400128b0
mov r8d, 0x3236
lea rdx, str.shell.c
lea rcx, str.rcSQLITE_OK
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__assert]
jmp 0x1400129e2
mov rcx, qword [rsp + 0x50]
call sym.sqlite3_finalize
jmp 0x1400126a5
mov rbx, rbp
test r15d, r15d
jne 0x140012a03
mov r15d, 7
jmp 0x1400128b0
xor r14d, r14d
jmp 0x1400126ed
mov rcx, qword [rsp + 0x50]
mov r12, qword [rsp + 0xb8]
call sym.sqlite3_finalize
mov ebx, eax
jmp 0x14001283b
mov rbx, rbp
mov ebp, dword [rsp + 0x38]
test rsi, rsi
je 0x140012a43
test ebp, ebp
lea rax, str.CREATE_INDEX___w__ON___w___s_
mov r9, rbx
mov r8, r12
lea rcx, str.CREATE_INDEX__s_ON__s__s_
mov rdx, rsi
mov r15d, 7
cmovne rcx, rax
call sym.sqlite3_mprintf
mov rdi, rax
test rax, rax
je 0x140012adb
xor r9d, r9d
xor r8d, r8d
mov rdx, rdi
mov rcx, r13
mov rax, qword [rsp + 0xb0]
mov r15d, 0x305
mov rax, qword [rax + 0x48]
mov qword [rsp + 0x20], rax
call sym.sqlite3_exec
mov dword [rsp + 0x4c], eax
test eax, eax
je 0x140012b09
mov rcx, rsi
call sym.sqlite3_free
mov rcx, rdi
call sym.sqlite3_free
jmp 0x1400128b0
mov rcx, qword [rsp + 0x58]
mov r12, qword [rsp + 0xb8]
mov ebx, eax
call sym.sqlite3_finalize
jmp 0x140012831
mov rax, qword [rsp + 0xb0]
lea rcx, [rsp + 0x4c]
mov r9, rdi
mov r8, rsi
lea rdx, [rax + 0x58]
call sym.idxHashAdd.isra.0
mov r15d, dword [rsp + 0x4c]
jmp 0x140012adb