Function at 0x1401a5410
Capabilities:
Reference sql statements

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0xa8
movsxd r12, edx
mov r13, rcx
mov rdi, r8
mov rbx, qword [rcx + r12*8 + 0x28]
mov rsi, r12
mov r14, r9
test rbx, rbx
je 0x1401a55c0
mov qword [r8], rbx
xor ebp, ebp
mov rsi, qword [rbx]
mov rcx, qword [rsi + 0x18]
test rcx, rcx
je 0x1401a5457
call qword [0x1402b20e0]
cmp qword [rbx + 0xb8], 0
jg 0x1401a5560
cmp byte [rbx + 0xc5], 2
mov rdi, qword [rbx]
je 0x1401a557b
mov edx, dword [rbx + 0x30]
test edx, edx
js 0x1401a558e
cmp qword [rdi + 0x190], 0
je 0x1401a58e0
mov rcx, rbx
call sym.sqlite3VdbeTransferError
mov rcx, qword [rbx + 0xa8]
test rcx, rcx
je 0x1401a54e3
cmp rcx, qword [rdi + 0x1f0]
jae 0x1401a54c5
cmp rcx, qword [rdi + 0x1e0]
jae 0x1401a5940
cmp rcx, qword [rdi + 0x1e8]
jae 0x1401a5960
cmp qword [rdi + 0x308], 0
jne 0x1401a5748
call sym.sqlite3_free
mov qword [rbx + 0xa8], 0
mov edx, dword [rbx + 0x34]
mov eax, 0xffffff02
and edx, dword [rdi + 0x58]
mov qword [rbx + 0xa0], 0
mov word [rbx + 0xc2], ax
movabs rax, 0xffffffff00000001
mov byte [rbx + 0xc5], 1
mov qword [rbx + 0x2c], rax
mov qword [rbx + 0x34], 0
mov qword [rbx + 0x3c], 0
mov qword [rbx + 0x50], 0
cmp byte [rsi + 0x67], 0
jne 0x1401a55b0
test edx, edx
jne 0x1401a55b0
mov rcx, qword [rsi + 0x18]
test rcx, rcx
je 0x1401a5546
call qword [0x1402b20f0]
mov eax, ebp
add rsp, 0xa8
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
mov rdx, rbx
mov rcx, rsi
call sym.invokeProfileCallback
cmp byte [rbx + 0xc5], 2
mov rdi, qword [rbx]
jne 0x1401a5475
mov rcx, rbx
call sym.sqlite3VdbeHalt
mov edx, dword [rbx + 0x30]
test edx, edx
jns 0x1401a5480
mov rcx, qword [rbx + 0xa8]
test rcx, rcx
je 0x1401a54e3
test rdi, rdi
je 0x1401a54d3
jmp 0x1401a54a2
mov rcx, rsi
call sym.apiHandleError
jmp 0x1401a5537
lea rax, str.SELECT__s_FROM__s_T_WHERE_T._Q_____AND_T._Q_____ORDER_BY_T._Q_DESC
cmp r12d, 4
mov r15, qword [r13]
lea rdx, str.SELECT__s_FROM__s_T_WHERE_T._Q_____AND_T._Q_____ORDER_BY_T._Q_ASC
movq xmm1, rax
lea rcx, str.SELECT__s_FROM__s_T_WHERE_T._Q_
movq xmm0, rdx
lea rax, str.INSERT_INTO__Q._q_content_VALUES__s_
punpcklqdq xmm0, xmm1
movaps xmmword [rsp + 0x40], xmm0
movq xmm0, rcx
lea rdx, str.REPLACE_INTO__Q._q_content_VALUES__s_
movq xmm2, rax
lea rax, str.DELETE_FROM__Q._q_content_WHERE_id_
punpcklqdq xmm0, xmm2
movaps xmmword [rsp + 0x50], xmm0
movq xmm0, rdx
lea rdx, str.REPLACE_INTO__Q._q_docsize_VALUES_____
movq xmm3, rax
lea rax, str.DELETE_FROM__Q._q_docsize_WHERE_id_
punpcklqdq xmm0, xmm3
movaps xmmword [rsp + 0x60], xmm0
movq xmm0, rdx
lea rdx, str.SELECT_sz_FROM__Q._q_docsize_WHERE_id_
movq xmm4, rax
lea rax, str.REPLACE_INTO__Q._q_config_VALUES_____
punpcklqdq xmm0, xmm4
movaps xmmword [rsp + 0x70], xmm0
movq xmm0, rdx
movq xmm5, rax
lea rax, str.SELECT__s_FROM__s_AS_T
punpcklqdq xmm0, xmm5
movaps xmmword [rsp + 0x80], xmm0
mov qword [rsp + 0x90], rax
jg 0x1401a58a8
cmp r12d, 2
jg 0x1401a5760
je 0x1401a5900
mov r9, qword [r15 + 0x50]
mov r8, qword [r15 + 0x48]
mov rdx, qword [r15 + 0x60]
mov rcx, qword [rsp + r12*8 + 0x40]
mov qword [rsp + 0x28], r9
mov qword [rsp + 0x20], r9
call sym.sqlite3_mprintf
test rax, rax
mov rbx, rax
je 0x1401a58d0
mov r8d, 0x81
mov rax, qword [r13]
add esi, 5
xor r9d, r9d
mov rdx, rbx
mov rcx, qword [r15]
movsxd rsi, esi
add dword [rax + 0x78], 1
lea rax, [r13 + rsi*8]
mov qword [rsp + 0x28], 0
mov qword [rsp + 0x20], rax
call sym.sqlite3LockAndPrepare.constprop.0
mov rcx, rbx
mov ebp, eax
mov rax, qword [r13]
sub dword [rax + 0x78], 1
call sym.sqlite3_free
test ebp, ebp
je 0x1401a572b
test r14, r14
je 0x1401a572b
mov rcx, qword [r15]
call sym.sqlite3_errmsg
lea rcx, [0x14032a9a6]
mov rdx, rax
call sym.sqlite3_mprintf
mov qword [r14], rax
mov rbx, qword [r13 + r12*8 + 0x28]
test rbx, rbx
mov qword [rdi], rbx
je 0x1401a5546
jmp 0x1401a5445
mov rdx, rcx
mov rcx, rdi
call sym.measureAllocationSize
jmp 0x1401a54d8
mov ebx, dword [r15 + 0x18]
call sym.sqlite3_initialize
test eax, eax
mov dword [rsp + 0x34], eax
jne 0x1401a58d0
lea r9d, [rbx + 1]
lea r8d, [r9 + r9]
mov dword [rsp + 0x38], r9d
lea ecx, [r8 + 1]
mov dword [rsp + 0x3c], r8d
movsxd rcx, ecx
call sym.sqlite3Malloc
test rax, rax
mov rbp, rax
je 0x1401a58d0
mov r9d, dword [rsp + 0x38]
test r9d, r9d
jle 0x1401a5976
cmp ebx, 6
movsxd r8, dword [rsp + 0x3c]
mov edx, dword [rsp + 0x34]
jbe 0x1401a5982
mov edx, r9d
movdqa xmm0, xmmword [str.________________]
shr edx, 3
shl rdx, 4
lea rcx, [rdx + rax]
and edx, 0x10
je 0x1401a57f0
movups xmmword [rax], xmm0
lea rax, [rax + 0x10]
cmp rax, rcx
je 0x1401a5800
nop word cs:[rax + rax]
movups xmmword [rax], xmm0
add rax, 0x20
movups xmmword [rax - 0x10], xmm0
cmp rax, rcx
jne 0x1401a57f0
mov eax, r9d
and eax, 0xfffffff8
and r9d, 7
mov edx, eax
je 0x1401a586b
mov r9d, ebx
sub r9d, eax
lea ecx, [r9 + 1]
cmp r9d, 2
jbe 0x1401a5836
mov r9, qword [str.________________]
mov qword [rbp + rax*2], r9
mov eax, ecx
and eax, 0xfffffffc
add edx, eax
and ecx, 3
je 0x1401a586b
movzx ecx, word [str.________________]
lea eax, [rdx + rdx]
cmp ebx, edx
movsxd r9, eax
mov word [rbp + r9], cx
lea r9d, [rdx + 1]
jle 0x1401a586b
lea edx, [rax + 2]
cmp ebx, r9d
movsxd rdx, edx
mov word [rbp + rdx], cx
jle 0x1401a586b
add eax, 4
cdqe
mov word [rbp + rax], cx
sub r8, 1
mov byte [rbp + r8], 0
mov rcx, qword [rsp + r12*8 + 0x40]
mov r9, rbp
mov rdx, qword [r15 + 8]
mov r8, qword [r15 + 0x10]
call sym.sqlite3_mprintf
mov rcx, rbp
mov rbx, rax
call sym.sqlite3_free
test rbx, rbx
je 0x1401a58d0
mov r8d, 0x85
jmp 0x1401a56c7
cmp r12d, 0xa
jne 0x1401a5920
mov r8, qword [r15 + 0x48]
mov rcx, rax
mov rdx, qword [r15 + 0x60]
call sym.sqlite3_mprintf
mov r8d, 0x85
test rax, rax
mov rbx, rax
jne 0x1401a56c7
mov ebp, 7
jmp 0x1401a572b
cmp qword [rbx + 0xa8], 0
jne 0x1401a548e
mov edx, dword [rbx + 0x34]
mov dword [rdi + 0x50], edx
jmp 0x1401a54e6
mov rdx, qword [r15 + 0x60]
mov r9, qword [r15 + 0x50]
mov r8, qword [r15 + 0x48]
call sym.sqlite3_mprintf
test rax, rax
mov rbx, rax
jne 0x1401a56c1
jmp 0x1401a58d0
mov rdx, qword [r15 + 8]
mov rcx, qword [rsp + r12*8 + 0x40]
mov r8, qword [r15 + 0x10]
call sym.sqlite3_mprintf
test rax, rax
mov rbx, rax
jne 0x1401a589a
jmp 0x1401a58d0
mov rax, qword [rdi + 0x1d8]
mov qword [rcx], rax
mov qword [rdi + 0x1d8], rcx
jmp 0x1401a54d8
mov rax, qword [rdi + 0x1c8]
mov qword [rcx], rax
mov qword [rdi + 0x1c8], rcx
jmp 0x1401a54d8
mov r8, 0xffffffffffffffff
jmp 0x1401a586f
xor eax, eax
jmp 0x1401a580e