Function at 0x14029c000
Capabilities:
Create thread

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x48
mov ebx, dword [rdx]
mov qword [rdx + 8], rcx
mov rdi, rcx
mov rsi, rdx
mov r12d, r8d
test ebx, ebx
jle 0x14029c120
xor ebp, ebp
nop dword [rax]
mov rax, qword [rsi + 0x18]
cmp r12d, 2
je 0x14029c250
lea r14, [rax + rbp]
mov rax, qword [r14 + 0x48]
test rax, rax
je 0x14029c111
mov edx, dword [rax + 0x20]
test edx, edx
je 0x14029c280
mov r15, qword [rax]
mov eax, dword [0x1402ba6c0]
mov qword [r15], 0
test eax, eax
je 0x14029c2a0
mov rcx, qword [0x1402ba340]
test rcx, rcx
je 0x14029c084
call qword [0x1402ba740]
mov ecx, 0x28
call sym.sqlite3Malloc.part.0
mov r13, rax
test r13, r13
je 0x14029c2b7
cmp byte [0x1402ba6c4], 0
je 0x14029c1f8
mov rax, qword [0x1402ba850]
test rax, rax
je 0x14029c0c2
mov ecx, 0xc8
call rax
test eax, eax
jne 0x14029c1f8
lea rax, [sym.vdbePmaReaderBgIncrInit]
mov qword [r13 + 0x18], r14
mov r9, r13
xor edx, edx
mov qword [r13 + 0x10], rax
lea rax, [r13 + 8]
lea r8, [sym.sqlite3ThreadProc]
xor ecx, ecx
mov qword [rsp + 0x28], rax
mov dword [rsp + 0x20], 0
call qword [sym.imp.msvcrt.dll__beginthreadex]
mov qword [r13], rax
test rax, rax
je 0x14029c1f8
cmp qword [r13 + 0x10], 0
je 0x14029c220
mov qword [r15], r13
add rbp, 0x50
sub ebx, 1
jne 0x14029c030
mov ebx, dword [rsi]
lea r12d, [rbx - 1]
test r12d, r12d
jle 0x14029c290
movsxd r13, r12d
lea rbp, [rsp + 0x3c]
shl r13, 2
jmp 0x14029c1c6
mov eax, r12d
sub eax, ebx
lea ebx, [rax + rax]
lea r14d, [rbx + 1]
movsxd rax, ebx
mov rdx, qword [rsi + 0x18]
lea rax, [rax + rax*4]
shl rax, 4
add rax, rdx
cmp qword [rax + 0x18], 0
je 0x14029c1ae
movsxd rcx, r14d
lea rcx, [rcx + rcx*4]
shl rcx, 4
add rdx, rcx
cmp qword [rdx + 0x18], 0
je 0x14029c2c0
mov r9d, dword [rax + 0x14]
mov r8, qword [rax + 0x28]
mov dword [rsp + 0x3c], 0
mov eax, dword [rdx + 0x14]
mov rcx, qword [rsi + 8]
mov dword [rsp + 0x28], eax
mov rax, qword [rdx + 0x28]
mov rdx, rbp
mov qword [rsp + 0x20], rax
call qword [rcx + 0x38]
test eax, eax
cmovle r14d, ebx
mov rax, qword [rsi + 0x10]
mov dword [rax + r13], r14d
sub r13, 4
sub r12d, 1
je 0x14029c290
mov ebx, dword [rsi]
mov eax, ebx
shr eax, 0x1f
add ebx, eax
sar ebx, 1
cmp r12d, ebx
jge 0x14029c140
lea ecx, [r12 + r12]
mov rax, qword [rsi + 0x10]
mov rdx, rcx
add edx, 1
mov ebx, dword [rax + rcx*4]
mov r14d, dword [rax + rdx*4]
jmp 0x14029c14c
mov qword [r13], 0
mov qword [r13 + 8], 0
mov qword [r13 + 0x10], 0
mov qword [r13 + 0x18], 0
mov qword [r13 + 0x20], 0
call qword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov edx, 1
mov rcx, r14
mov dword [r13 + 8], eax
call sym.vdbePmaReaderIncrMergeInit
mov rdx, qword [r14 + 0x48]
cdqe
mov rdx, qword [rdx]
mov dword [rdx + 8], 1
mov qword [r13 + 0x20], rax
jmp 0x14029c10e
mov edx, ebx
lea rdx, [rdx + rdx*4]
shl rdx, 4
lea rcx, [rax + rdx - 0x50]
call sym.vdbePmaReaderNext
test eax, eax
je 0x14029c111
add rsp, 0x48
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
xor edx, edx
mov rcx, r14
call sym.vdbePmaReaderIncrMergeInit
jmp 0x14029c264
mov rax, qword [rdi + 0x18]
movzx eax, byte [rax + 0x1f]
jmp 0x14029c26c
mov ecx, 0x28
call qword [0x1402ba6e0]
mov r13, rax
test r13, r13
jne 0x14029c09a
mov eax, 7
jmp 0x14029c26c
mov r14d, ebx
jmp 0x14029c1ae