Function at 0x4bc282
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x148
mov r13, qword [rdx]
movsxd rbx, r8d
mov r12, rcx
mov r14, rdx
mov qword [rsp + 0x1a8], r9
lea rbp, [rbx + 1]
mov rsi, rbx
mov qword [rsp + 0xa0], 0
shl rbp, 4
test r9, r9
mov dword [rsp + 0x7c], 0
lea rax, [rbp + 8]
mov qword [rsp + 0x50], rax
je 0x4bc2dd
mov eax, dword [r9]
mov dword [rsp + 0x7c], eax
mov rax, qword [r12]
mov ecx, 0x1e
shl rbx, 4
lea rdx, [rsp + 0xa8]
mov eax, dword [rax + 0x5c]
mov dword [rsp + 0x84], eax
lea rax, [rsp + 0xc8]
mov qword [rsp + 0x58], rax
mov rdi, qword [rsp + 0x58]
xor eax, eax
rep stosd dword [rdi], eax
mov rdi, rdx
mov ecx, 4
rep stosd dword [rdi], eax
lea rdx, [r13 + rbx]
mov eax, dword [rdx + 0x18]
mov dword [rsp + 0x50], eax
cmp dword [rsp + 0x50], 0
lea eax, [rsi + 1]
mov dword [rsp + 0x60], eax
je 0x4bc384
lea rax, [r13 + rbp + 0x18]
mov rcx, r12
mov qword [rsp + 0x68], rax
movsxd rax, dword [rdx + 0x2c]
lea r14, [rbp + 8]
mov rdx, qword [rdx + 0x30]
add r14, r13
imul rax, rax, 0xc
lea rdi, [rdx + rax - 0xc]
mov rdx, qword [rsp + 0x58]
mov r8d, dword [rdi]
call sym.fts5WriteInit
mov eax, dword [rdi + 8]
mov dword [rsp + 0x138], 0
inc eax
mov dword [rsp + 0xd0], eax
jmp 0x4bc422
lea rdi, [r12 + 0x34]
mov rdx, r13
mov rcx, rdi
call sym.fts5AllocateSegid.isra.337
mov r15d, eax
mov eax, dword [r13 + 0x14]
dec eax
cmp eax, esi
jne 0x4bc3af
mov rdx, r14
mov rcx, rdi
call sym.fts5StructureAddLevel
mov r13, qword [r14]
cmp dword [r12 + 0x34], 0
jne 0x4bc3c9
xor r9d, r9d
mov rdx, r13
mov rcx, rdi
lea r8d, [rsi + 1]
call sym.fts5StructureExtendLevel.part.572.constprop.762
cmp dword [r12 + 0x34], 0
jne 0x4bca85
mov rdx, qword [rsp + 0x58]
add rbx, r13
mov r8d, r15d
mov rcx, r12
lea rax, [r13 + rbp + 0x18]
mov qword [rsp + 0x68], rax
lea r14, [rbp + 8]
add r14, r13
call sym.fts5WriteInit
movsxd rdi, dword [rbx + 0x2c]
mov rax, rdi
imul rdi, rdi, 0xc
inc eax
add rdi, qword [rbx + 0x30]
mov dword [rbx + 0x2c], eax
mov dword [rdi + 4], 1
mov dword [rdi], r15d
inc dword [r13 + 0x10]
mov eax, dword [rbx + 0x1c]
mov dword [rsp + 0x50], eax
mov dword [rsp + 0x80], 0
mov rax, qword [rsp + 0x68]
cmp dword [rax + 4], 1
jne 0x4bc44c
lea eax, [rsi + 2]
cmp dword [r13 + 0x14], eax
sete al
movzx eax, al
mov dword [rsp + 0x80], eax
mov dword [rsp + 0x30], esi
xor r9d, r9d
mov r8d, 0x20
mov rdx, r13
lea rax, [rsp + 0xa0]
mov dword [rsp + 0x28], 0
mov rcx, r12
xor ebp, ebp
mov qword [rsp + 0x40], rax
mov eax, dword [rsp + 0x50]
mov qword [rsp + 0x20], 0
mov dword [rsp + 0x38], eax
call sym.fts5MultiIterNew
lea rax, [rsp + 0xa8]
mov qword [rsp + 0x88], rax
lea rax, [rsp + 0xc8]
mov qword [rsp + 0x58], rax
add rax, 0x10
mov qword [rsp + 0x60], rax
cmp dword [r12 + 0x34], 0
jne 0x4bc708
mov rbx, qword [rsp + 0xa0]
cmp byte [rbx + 0x14], 0
jne 0x4bc708
mov rax, qword [rbx + 0x58]
mov ax, word [rax + 4]
movzx r15d, ax
mov word [rsp + 0x7a], ax
movsxd rax, r15d
imul rax, rax, 0x78
add rax, rbx
mov esi, dword [rax + 0xc0]
mov rax, qword [rax + 0xb8]
cmp dword [rsp + 0xb0], esi
mov qword [rsp + 0x70], rax
jne 0x4bc523
test esi, esi
jle 0x4bc55b
mov rdx, qword [rsp + 0xa8]
movsxd r8, esi
mov rcx, qword [rsp + 0x70]
call sym.memcmp
test eax, eax
je 0x4bc55b
cmp qword [rsp + 0x1a8], 0
je 0x4bc53f
mov eax, dword [rsp + 0x7c]
cmp dword [rsp + 0x114], eax
jg 0x4bc708
mov r9, qword [rsp + 0x70]
lea rcx, [r12 + 0x34]
mov r8d, esi
xor ebp, ebp
mov rdx, qword [rsp + 0x88]
call sym.sqlite3Fts5BufferSet
movsxd rax, r15d
imul rax, rax, 0x78
add rax, rbx
cmp dword [rax + 0xd0], 0
jne 0x4bc589
cmp dword [rsp + 0x80], 0
jne 0x4bc6ed
cmp byte [rax + 0xd4], 0
je 0x4bc6ed
mov eax, ebp
or eax, dword [r12 + 0x34]
jne 0x4bc5ac
mov r9, qword [rsp + 0x70]
mov r8d, esi
mov rcx, r12
mov ebp, 1
mov rdx, qword [rsp + 0x58]
call sym.fts5WriteAppendTerm
cmp dword [r12 + 0x34], 0
jne 0x4bc660
mov rdx, qword [rsp + 0xa0]
mov rax, qword [rdx + 0x58]
movzx eax, word [rax + 4]
imul rax, rax, 0x78
mov rsi, qword [rdx + rax + 0xc8]
mov rdx, qword [r12]
mov eax, dword [rsp + 0xf0]
add eax, dword [rsp + 0xe0]
cmp eax, dword [rdx + 0x88]
jl 0x4bc5fb
mov rdx, qword [rsp + 0x58]
mov rcx, r12
call sym.fts5WriteFlushLeaf
cmp byte [rsp + 0x111], 0
je 0x4bc629
mov eax, dword [rsp + 0xe0]
mov r8, rsi
mov rcx, r12
mov rdx, qword [rsp + 0xd8]
xchg al, ah
mov word [rdx], ax
mov rdx, qword [rsp + 0x58]
call sym.fts5WriteDlidxAppend
cmp word [rsp + 0x110], 0
lea rcx, [r12 + 0x34]
mov r8, rsi
jne 0x4bc644
sub r8, qword [rsp + 0x108]
mov rdx, qword [rsp + 0x60]
call sym.sqlite3Fts5BufferAppendVarint
mov qword [rsp + 0x108], rsi
mov word [rsp + 0x110], 0
imul r15, r15, 0x78
add r15, rbx
cmp dword [rsp + 0x84], 1
movzx eax, byte [r15 + 0xd4]
jne 0x4bc6ae
test al, al
je 0x4bc6ed
mov rdx, qword [rsp + 0x60]
lea rbx, [r12 + 0x34]
xor r8d, r8d
mov rcx, rbx
call sym.sqlite3Fts5BufferAppendVarint
cmp dword [r15 + 0xd0], 0
jle 0x4bc6ed
mov rdx, qword [rsp + 0x60]
xor r8d, r8d
mov rcx, rbx
call sym.sqlite3Fts5BufferAppendVarint
jmp 0x4bc6ed
mov edx, dword [r15 + 0xd0]
lea rcx, [r12 + 0x34]
lea r8d, [rax + rdx*2]
mov rdx, qword [rsp + 0x60]
movsxd r8, r8d
call sym.sqlite3Fts5BufferAppendVarint
movzx eax, word [rsp + 0x7a]
lea r9, [sym.fts5MergeChunkCallback]
mov rcx, r12
mov r8, qword [rsp + 0x58]
imul rax, rax, 0x78
lea rdx, [rbx + rax + 0x60]
call sym.fts5ChunkIterate
mov rdx, qword [rsp + 0xa0]
xor r9d, r9d
xor r8d, r8d
mov rcx, r12
call sym.fts5MultiIterNext
jmp 0x4bc4b2
lea rdx, [rsp + 0xc8]
mov rcx, r12
lea r8, [rdi + 8]
call sym.fts5WriteFinish
mov ebp, dword [r12 + 0x34]
test ebp, ebp
jne 0x4bc766
mov r15, qword [rsp + 0xa0]
cmp byte [r15 + 0x14], 0
jne 0x4bc766
lea rdx, [rsp + 0xb8]
mov eax, ebp
mov ecx, 4
lea rbx, [r15 + 0x60]
mov rdi, rdx
rep stosd dword [rdi], eax
lea rax, [rsp + 0x9c]
mov rdi, rdx
lea r13, [r12 + 0x34]
mov qword [rsp + 0x70], rax
jmp 0x4bc885
lea rbp, str.DELETE_FROM__q._q_idx_WHERE_segid_
xor ebx, ebx
lea r15, [r12 + 0x58]
cmp dword [rsp + 0x50], ebx
jle 0x4bc807
imul rax, rbx, 0xc
mov rcx, r12
add rax, qword [r14 + 8]
mov esi, dword [rax]
lea eax, [rsi + 1]
mov rdx, rsi
shl rax, 0x25
shl rdx, 0x25
lea r8, [rax - 1]
call sym.fts5DataDelete
cmp qword [r12 + 0x58], 0
jne 0x4bc7cc
mov rax, qword [r12]
mov rcx, rbp
mov rdx, qword [rax + 8]
mov r8, qword [rax + 0x10]
call sym.sqlite3_mprintf
mov rdx, r15
mov rcx, r12
mov r8, rax
call sym.fts5IndexPrepareStmt
cmp dword [r12 + 0x34], 0
jne 0x4bc7ff
mov rcx, qword [r12 + 0x58]
mov r8d, esi
mov edx, 1
call sym.sqlite3_bind_int
mov rcx, qword [r12 + 0x58]
call sym.sqlite3_step
mov rcx, qword [r12 + 0x58]
call sym.sqlite3_reset
mov dword [r12 + 0x34], eax
inc rbx
jmp 0x4bc774
mov r8d, dword [r14 + 4]
cmp r8d, dword [rsp + 0x50]
je 0x4bc833
movsxd rdx, dword [rsp + 0x50]
sub r8d, dword [rsp + 0x50]
mov rcx, qword [r14 + 8]
imul rdx, rdx, 0xc
imul r8d, r8d, 0xc
movsxd r8, r8d
add rdx, rcx
call sym.memmove
mov eax, dword [r13 + 0x10]
sub eax, dword [rsp + 0x50]
mov esi, dword [rsp + 0x50]
mov dword [r13 + 0x10], eax
sub dword [r14 + 4], esi
mov dword [r14], 0
cmp dword [rdi + 8], 0
jne 0x4bca4f
mov rdi, qword [rsp + 0x68]
dec eax
dec dword [rdi + 4]
mov dword [r13 + 0x10], eax
jmp 0x4bca4f
cmp dword [r12 + 0x34], 0
jne 0x4bca3b
mov rax, qword [rbx]
test rax, rax
jne 0x4bc890
inc ebp
add rbx, 0x78
cmp ebp, dword [r15 + 0x40]
jl 0x4bc86b
jmp 0x4bca3b
cmp qword [rbx + 0x10], 0
jne 0x4bc8a1
mov qword [rax + 4], 0
jmp 0x4bc87f
mov edx, dword [rax]
mov rcx, r12
mov esi, dword [rbx + 0x34]
mov dword [rsp + 0x9c], 0
mov rax, rdx
shl rax, 0x25
mov dword [rsp + 0x58], esi
mov qword [rsp + 0x68], rax
movsxd rax, dword [rbx + 0x30]
add rax, qword [rsp + 0x68]
mov rdx, rax
mov qword [rsp + 0x60], rax
call sym.fts5LeafRead
test rax, rax
mov rsi, rax
je 0x4bc87f
mov eax, dword [rsp + 0x58]
cmp eax, dword [rsi + 0xc]
jle 0x4bc8f9
mov dword [r12 + 0x34], 0x10b
jmp 0x4bca2e
mov dword [rsp + 0xc0], 0
mov r8d, dword [rsi + 8]
cmp r8d, dword [rsp + 0xc4]
jbe 0x4bc91d
mov rdx, rdi
mov rcx, r13
call sym.sqlite3Fts5BufferSize
mov r9, qword [rsp + 0x70]
mov r8d, 4
mov rdx, rdi
mov rcx, r13
call sym.sqlite3Fts5BufferAppendBlob
movsxd r8, dword [rbx + 0x60]
mov rdx, rdi
mov rcx, r13
call sym.sqlite3Fts5BufferAppendVarint
mov r9, qword [rbx + 0x58]
mov rdx, rdi
mov rcx, r13
mov r8d, dword [rbx + 0x60]
call sym.sqlite3Fts5BufferAppendBlob
movsxd r9, dword [rsp + 0x58]
mov rdx, rdi
mov rcx, r13
add r9, qword [rsi]
mov r8d, dword [rsi + 0xc]
sub r8d, dword [rsp + 0x58]
call sym.sqlite3Fts5BufferAppendBlob
cmp dword [r12 + 0x34], 0
jne 0x4bc98e
mov eax, dword [rsp + 0xc0]
mov rdx, qword [rsp + 0xb8]
xchg al, ah
mov word [rdx + 2], ax
mov r8d, 4
mov rdx, rdi
mov rcx, r13
call sym.sqlite3Fts5BufferAppendVarint
mov eax, dword [rbx + 0x30]
cmp dword [rbx + 0xc], eax
jne 0x4bc9f3
mov ecx, dword [rbx + 0x3c]
mov eax, dword [rsi + 0xc]
cmp ecx, eax
jge 0x4bc9f3
mov edx, dword [rsi + 8]
cmp dword [rbx + 0x38], edx
jg 0x4bc9f3
movsxd rdx, dword [rsp + 0xc0]
sub eax, ecx
mov rcx, r13
cdqe
sub rdx, rax
lea r8, [rdx - 5]
mov rdx, rdi
call sym.sqlite3Fts5BufferAppendVarint
movsxd r9, dword [rbx + 0x38]
mov rdx, rdi
mov rcx, r13
mov r8d, dword [rsi + 8]
mov rax, r9
add r9, qword [rsi]
sub r8d, eax
call sym.sqlite3Fts5BufferAppendBlob
mov edx, dword [rbx + 0x30]
mov rcx, r12
mov rax, qword [rbx]
mov r8, qword [rsp + 0x60]
mov dword [rax + 4], edx
mov rdx, qword [rsp + 0x68]
inc rdx
call sym.fts5DataDelete
mov r9d, dword [rsp + 0xc0]
mov rcx, r12
mov r8, qword [rsp + 0xb8]
mov rdx, qword [rsp + 0x60]
call sym.fts5DataWrite
mov rcx, rsi
call sym.sqlite3_free
jmp 0x4bc87f
lea rcx, [rsp + 0xb8]
call sym.sqlite3Fts5BufferFree
mov eax, dword [rsp + 0x50]
mov dword [r14], eax
mov rcx, qword [rsp + 0xa0]
call sym.fts5MultiIterFree
lea rcx, [rsp + 0xa8]
call sym.sqlite3Fts5BufferFree
cmp qword [rsp + 0x1a8], 0
je 0x4bca85
mov rdi, qword [rsp + 0x1a8]
mov eax, dword [rsp + 0x114]
sub dword [rdi], eax
add rsp, 0x148
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret