Function at 0x14012ffa0
Capabilities:
Reference sql statements
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, 0x178
mov edi, dword [0x14014efd4]
pxor xmm0, xmm0
mov r12, qword [rcx]
movups xmmword [rsp + 0x140], xmm0
mov r13, rcx
mov esi, edx
movups xmmword [rsp + 0x150], xmm0
mov ebx, dword [r12 + 0x18]
mov qword [rsp + 0x160], r12
test edi, edi
jne 0x140130d27
call sym.sqlite3MutexInit
test eax, eax
jne 0x140130460
call sym.sqlite3_initialize.part.0
test eax, eax
jne 0x140130460
movsxd rax, ebx
lea rcx, [rax + rax*2]
shl rcx, 2
call sym.sqlite3Malloc
mov qword [rsp + 0xd0], rax
mov rcx, rax
test rax, rax
je 0x140130460
movsxd r14, dword [r12 + 0x18]
xor edx, edx
shl r14, 3
mov r8, r14
call sym.memset
mov eax, dword [r12 + 0x40]
test eax, eax
je 0x140130b0f
test esi, esi
je 0x140130055
cmp eax, 2
je 0x140130b0f
xor r12d, r12d
mov r14, qword [r13 + 8]
mov rbx, qword [rsp + 0x150]
mov rax, qword [r14]
mov rcx, r14
mov qword [rsp + 0x110], 0
mov qword [rsp + 0x118], 0
mov eax, dword [rax + 0x60]
mov dword [rsp + 0xe0], eax
call sym.fts5StructureRead
mov r11, rax
test rax, rax
je 0x140130576
lea rax, [rsp + 0x120]
mov ecx, dword [r11 + 0x1c]
xor ebp, ebp
mov qword [rsp + 0xb0], rax
lea rax, [rsp + 0xf4]
mov qword [rsp + 0x70], rax
test ecx, ecx
jle 0x1401303ef
mov qword [rsp + 0xd8], rbx
mov dword [rsp + 0xe4], r12d
mov r12, r11
mov rbx, rbp
xor r13d, r13d
shl rbx, 4
mov r10d, dword [r12 + rbx + 0x24]
test r10d, r10d
jle 0x1401303cd
mov qword [rsp + 0xa0], r12
mov qword [rsp + 0xa8], rbx
mov qword [rsp + 0xe8], rbp
mov qword [rsp + 0x88], r13
nop dword [rax + rax]
mov rdi, qword [rsp + 0x88]
mov rbx, qword [rsp + 0xa8]
mov qword [rsp + 0x108], 0
lea rax, [rdi*8]
sub rax, rdi
mov rdi, qword [rsp + 0xa0]
mov rdx, qword [rdi + rbx + 0x28]
lea r15, [rdx + rax*8]
mov rax, qword [r14]
mov qword [rsp + 0x98], rax
mov eax, dword [rax + 0x88]
mov dword [rsp + 0xcc], eax
mov eax, dword [r15 + 4]
test eax, eax
je 0x140130397
sub eax, 1
mov r9d, dword [r15]
lea rcx, str.SELECT_segid__term___pgno__1____pgno1__FROM__Q._q_idx_WHERE_segid_d_ORDER_BY_1__2
mov dword [rsp + 0x78], eax
mov eax, dword [r15 + 8]
mov dword [rsp + 0x84], eax
mov rax, qword [rsp + 0x98]
mov rdx, qword [rax + 8]
mov r8, qword [rax + 0x10]
call sym.sqlite3_mprintf
lea rdx, [rsp + 0x108]
mov rcx, r14
mov r8, rax
call sym.fts5IndexPrepareStmt
mov rax, qword [rsp + 0x108]
mov qword [rsp + 0x58], rax
lea rax, [rsp + 0x130]
mov qword [rsp + 0x60], rax
nop word [rax + rax]
mov ebx, dword [r14 + 0x3c]
test ebx, ebx
jne 0x140130380
mov rcx, qword [rsp + 0x58]
call sym.sqlite3_step
cmp eax, 0x64
jne 0x140130380
mov rsi, qword [rsp + 0x58]
mov edx, 1
mov rcx, rsi
call sym.columnMem
mov rcx, rax
call sym.sqlite3_value_blob
mov r12, rax
test rsi, rsi
je 0x1401305c0
mov rcx, rsi
call sym.columnMallocFailure.part.0
mov edx, 1
mov rcx, rsi
call sym.columnMem
mov edx, 1
mov rcx, rax
call sym.sqlite3ValueBytes
mov rcx, rsi
mov ebp, eax
call sym.columnMallocFailure.part.0
mov edx, 2
mov rcx, rsi
call sym.columnMem
mov rcx, rax
call sym.sqlite3VdbeIntValue
mov rcx, rsi
mov edi, eax
call sym.columnMallocFailure.part.0
mov edx, 3
mov rcx, rsi
call sym.columnMem
mov rcx, rax
call sym.sqlite3VdbeIntValue
mov rcx, rsi
mov dword [rsp + 0x68], eax
call sym.columnMallocFailure.part.0
cmp dword [r15 + 4], edi
jg 0x1401301d8
movsxd rdx, dword [r15]
movsxd rax, edi
mov rcx, r14
shl rdx, 0x25
add rdx, rax
call sym.fts5DataRead
mov rsi, rax
test rax, rax
je 0x140130380
mov eax, dword [rax + 8]
cmp eax, 3
jle 0x140130610
mov r13d, dword [rsi + 0xc]
cmp eax, r13d
jl 0x140130610
jne 0x140130628
test ebp, ebp
jne 0x1401302ed
mov rbx, qword [rsp + 0x98]
cmp dword [rbx + 0x88], 5
jne 0x1401302ed
cmp eax, 4
je 0x1401302f5
mov dword [r14 + 0x3c], 0x10b
mov rcx, rsi
call sym.sqlite3_free
mov esi, dword [r14 + 0x3c]
test esi, esi
jne 0x140130380
mov ebp, dword [rsp + 0x78]
mov ebx, dword [rsp + 0x84]
add ebp, 1
movsxd r12, ebp
cmp edi, ebp
jg 0x14013032c
jmp 0x140130598
add r12, 1
cmp edi, ebp
je 0x140130598
movsxd rdx, dword [r15]
mov rcx, r14
shl rdx, 0x25
add rdx, r12
call sym.fts5DataRead
mov rcx, rax
test rax, rax
je 0x140130370
mov eax, dword [rax + 8]
cmp dword [rcx + 0xc], eax
jge 0x140130356
mov dword [r14 + 0x3c], 0x10b
cmp ebx, ebp
jge 0x140130370
mov rax, qword [rcx]
cmp word [rax], 0
je 0x140130370
mov dword [r14 + 0x3c], 0x10b
nop dword [rax + rax]
call sym.sqlite3_free
mov eax, dword [r14 + 0x3c]
add ebp, 1
test eax, eax
je 0x140130320
mov rcx, qword [rsp + 0x58]
call sym.sqlite3_finalize
mov r11d, dword [r14 + 0x3c]
test r11d, r11d
jne 0x140130397
mov dword [r14 + 0x3c], eax
mov rdi, qword [rsp + 0xa0]
mov rbx, qword [rsp + 0xa8]
add qword [rsp + 0x88], 1
mov rax, qword [rsp + 0x88]
cmp dword [rdi + rbx + 0x24], eax
jg 0x140130118
mov rbp, qword [rsp + 0xe8]
mov r12, rdi
add rbp, 1
cmp dword [r12 + 0x1c], ebp
jg 0x1401300db
mov r11, r12
mov rbx, qword [rsp + 0xd8]
mov r12d, dword [rsp + 0xe4]
mov rax, qword [rsp + 0xb0]
xor r9d, r9d
mov rdx, r11
xor esi, esi
mov dword [rsp + 0x38], 0
mov r8d, 0x20
mov rcx, r14
mov qword [rsp + 0x40], rax
mov dword [rsp + 0x30], 0xffffffff
mov dword [rsp + 0x28], 0
mov qword [rsp + 0x20], 0
mov qword [rsp + 0x58], r11
call sym.fts5MultiIterNew
mov r9d, dword [r14 + 0x3c]
mov r11, qword [rsp + 0x58]
mov r15, qword [rsp + 0x120]
test r9d, r9d
je 0x14013051c
test r15, r15
jne 0x14013052c
jmp 0x140130558
mov edi, 7
mov eax, edi
add rsp, 0x178
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
mov qword [rsp + 0x130], 0
mov rax, qword [r15 + 0x60]
mov dword [rsp + 0x108], 0
movzx eax, word [rax + 4]
mov rdx, rax
shl rax, 7
add rax, r15
cmp dword [rsp + 0xe0], 1
mov r13, qword [rax + 0xd8]
mov ebp, dword [rax + 0xd0]
mov rdi, qword [rax + 0xc8]
jne 0x1401310d0
cmp qword [rax + 0x78], 0
je 0x1401304d9
mov r8d, dword [rax + 0xe0]
test r8d, r8d
je 0x140130503
lea rax, [r13 + r13*8]
lea rax, [rax + rax*8]
test ebp, ebp
jle 0x140130500
movsxd rdx, ebp
add rdx, rdi
movsx rcx, byte [rdi]
add rdi, 1
lea rcx, [rcx + rax*8]
add rax, rcx
cmp rdi, rdx
jne 0x1401304ec
xor rsi, rax
mov rcx, r14
xor r9d, r9d
xor r8d, r8d
mov rdx, r15
call sym.fts5MultiIterNext
mov ecx, dword [r14 + 0x3c]
test ecx, ecx
jne 0x140130527
cmp byte [r15 + 0x14], 0
je 0x14013047b
mov r11, qword [rsp + 0x58]
mov rcx, r15
mov qword [rsp + 0x58], r11
call sym.fts5MultiIterFree.part.0
mov edx, dword [r14 + 0x3c]
mov r11, qword [rsp + 0x58]
test edx, edx
jne 0x140130558
cmp rbx, rsi
je 0x140130558
test r12d, r12d
je 0x140130558
mov dword [r14 + 0x3c], 0x10b
mov eax, dword [r11]
sub eax, 1
mov dword [r11], eax
test eax, eax
jle 0x140130f5c
mov rcx, qword [rsp + 0x110]
call sym.sqlite3_free
mov edi, dword [r14 + 0x3c]
mov dword [r14 + 0x3c], 0
mov rcx, qword [rsp + 0xd0]
call sym.sqlite3_free
jmp 0x140130465
mov eax, dword [rsp + 0x68]
test eax, eax
jne 0x1401308ff
mov eax, dword [r15 + 8]
mov dword [rsp + 0x84], eax
mov dword [rsp + 0x78], edi
jmp 0x1401301d8
mov edx, 1
xor ecx, ecx
call sym.columnMem
mov edx, 1
mov rcx, rax
call sym.sqlite3ValueBytes
mov edx, 2
xor ecx, ecx
mov ebp, eax
call sym.columnMem
mov rcx, rax
call sym.sqlite3VdbeIntValue
mov edx, 3
xor ecx, ecx
mov edi, eax
call sym.columnMem
mov rcx, rax
call sym.sqlite3VdbeIntValue
mov dword [rsp + 0x68], eax
jmp 0x140130289
mov dword [r14 + 0x3c], 0x10b
mov rcx, rsi
call sym.sqlite3_free
jmp 0x140130380
mov rbx, qword [rsi]
mov rdx, qword [rsp + 0x60]
movsxd rcx, r13d
add rcx, rbx
call sym.sqlite3Fts5GetVarint32
movzx eax, word [rbx]
mov r9d, dword [rsp + 0x130]
rol ax, 8
movzx eax, ax
cmp r9d, eax
jle 0x14013065b
cmp r9d, r13d
jl 0x140130a4e
mov dword [r14 + 0x3c], 0x10b
mov eax, 0x10b
lea rbx, [rsp + 0xf8]
xor ebp, ebp
mov qword [rsp + 0x120], 0
lea r12, [r14 + 0x3c]
mov qword [rsp + 0x128], 0
mov qword [rsp + 0x130], 0
mov qword [rsp + 0x138], 0
mov qword [rsp + 0x90], rbx
mov dword [rsp + 0xc0], edi
mov qword [rsp + 0xb8], r15
jmp 0x140130704
mov dword [r14 + 0x3c], 0x10b
mov rbx, qword [rsp + 0x120]
mov r10d, dword [rsp + 0x128]
mov rdx, qword [rsp + 0x60]
mov r9, rbx
mov r8d, r10d
mov rcx, r12
mov dword [rsp + 0x138], 0
call sym.sqlite3Fts5BufferAppendBlob
cmp r13d, dword [rsi + 8]
jge 0x1401308eb
mov eax, dword [r14 + 0x3c]
test eax, eax
jne 0x140130897
mov rbx, qword [rsi]
movsxd rcx, r13d
mov rdx, qword [rsp + 0x70]
add rcx, rbx
call sym.sqlite3Fts5GetVarint32
movsxd rdi, dword [rsi + 0xc]
add r13d, eax
movsxd rax, dword [rsp + 0xf4]
add rbp, rax
cmp rbp, rdi
jge 0x1401306c0
cmp rax, rbp
je 0x1401307b0
mov rdx, qword [rsp + 0x90]
lea rcx, [rbx + rbp]
call sym.sqlite3Fts5GetVarint32
lea rdx, [rsp + 0xfc]
movsxd r8, eax
lea r15, [r8 + rbp]
lea rcx, [rbx + r15]
call sym.sqlite3Fts5GetVarint32
mov r10d, dword [rsp + 0x128]
mov edx, dword [rsp + 0xf8]
cmp r10d, edx
jl 0x140130791
cdqe
lea r9, [rax + r15]
movsxd rax, dword [rsp + 0xfc]
mov r8, rax
add rax, r9
cmp rdi, rax
jge 0x1401307fb
mov dword [r14 + 0x3c], 0x10b
mov rbx, qword [rsp + 0x120]
jmp 0x1401306d8
lea rdx, [rsp + 0xfc]
lea rcx, [rbx + rbp]
call sym.sqlite3Fts5GetVarint32
movsxd r9, eax
movsxd rax, dword [rsp + 0xfc]
add r9, rbp
mov r8, rax
add rax, r9
cmp rdi, rax
jge 0x1401308c8
mov dword [r14 + 0x3c], 0x10b
mov rbx, qword [rsp + 0x120]
mov r10d, dword [rsp + 0x128]
jmp 0x1401306d8
mov dword [rsp + 0x128], edx
add r9, rbx
mov rcx, r12
mov rdx, qword [rsp + 0xb0]
call sym.sqlite3Fts5BufferAppendBlob
mov edx, dword [r14 + 0x3c]
mov rbx, qword [rsp + 0x120]
test edx, edx
jne 0x140130fe6
movsxd r10, dword [rsp + 0x128]
mov r9d, dword [rsp + 0x138]
mov rdx, qword [rsp + 0x130]
cmp r10d, r9d
movsxd r8, r9d
cmovle r8, r10
test r8d, r8d
jle 0x14013087c
mov rcx, rbx
mov dword [rsp + 0xc8], r10d
mov dword [rsp + 0xc4], r9d
call sym.memcmp
mov r9d, dword [rsp + 0xc4]
mov r10d, dword [rsp + 0xc8]
test eax, eax
jne 0x140130882
mov eax, r10d
sub eax, r9d
test eax, eax
jg 0x1401306d8
mov dword [r14 + 0x3c], 0x10b
jmp 0x1401306d8
mov edi, dword [rsp + 0xc0]
mov r15, qword [rsp + 0xb8]
mov r12, qword [rsp + 0x120]
mov rcx, r12
call sym.sqlite3_free
mov rcx, qword [rsp + 0x130]
call sym.sqlite3_free
jmp 0x1401302f5
mov rdx, qword [rsp + 0xb0]
add r9, rbx
mov rcx, r12
mov dword [rsp + 0x128], 0
call sym.sqlite3Fts5BufferAppendBlob
jmp 0x1401307e6
mov edi, dword [rsp + 0xc0]
mov r15, qword [rsp + 0xb8]
mov r12, rbx
jmp 0x1401308ae
mov ebp, dword [r15]
mov r9d, edi
xor edx, edx
mov rcx, r14
mov r8d, ebp
call sym.fts5DlidxIterInit
mov r12, rax
mov eax, dword [r14 + 0x3c]
test eax, eax
jne 0x140130a47
mov rax, rbp
xor esi, esi
mov r13d, edi
shl rax, 0x25
mov qword [rsp + 0x68], rax
mov eax, dword [r12 + 0x14]
test eax, eax
jne 0x140130a0a
lea esi, [r13 + 1]
mov rax, qword [rsp + 0x68]
mov r13d, dword [r12 + 0x1c]
movsxd rbx, esi
add rbx, rax
cmp esi, r13d
jge 0x14013099a
nop dword [rax + rax]
mov rcx, r14
mov rdx, rbx
call sym.fts5DataRead
mov rcx, rax
test rax, rax
je 0x140130989
mov rax, qword [rax]
cmp word [rax], 0
je 0x140130984
mov dword [r14 + 0x3c], 0x10b
call sym.sqlite3_free
mov r13d, dword [r12 + 0x1c]
add esi, 1
add rbx, 1
cmp esi, r13d
jl 0x140130960
mov rax, qword [rsp + 0x68]
movsxd rdx, r13d
mov rcx, r14
add rdx, rax
call sym.fts5DataRead
mov rbx, rax
test rax, rax
je 0x1401309f0
mov rdx, qword [rax]
movzx eax, word [rdx]
rol ax, 8
movzx ecx, ax
cmp ecx, dword [rbx + 0xc]
jge 0x140130b02
cmp dword [rsp + 0xcc], 5
setne bpl
test ecx, ecx
jne 0x140130ac3
test bpl, bpl
jne 0x140130ac3
mov rcx, rbx
call sym.sqlite3_free
xor r8d, r8d
mov rdx, r12
mov rcx, r14
call sym.fts5DlidxIterNextR.isra.0
mov eax, dword [r14 + 0x3c]
test eax, eax
je 0x140130932
mov r13d, dword [r12]
xor ebp, ebp
test r13d, r13d
jle 0x140130a33
nop dword [rax]
mov rax, rbp
add rbp, 1
shl rax, 5
mov rcx, qword [r12 + rax + 8]
call sym.sqlite3_free
cmp dword [r12], ebp
jg 0x140130a18
mov rcx, r12
call sym.sqlite3_free
mov dword [rsp + 0x84], esi
jmp 0x1401305af
test r12, r12
je 0x140130a3b
jmp 0x140130a0a
movsxd rcx, r9d
lea rdx, [rsp + 0xf0]
mov dword [rsp + 0x90], r9d
add rcx, rbx
call sym.sqlite3Fts5GetVarint32
movsxd r10, dword [rsp + 0xf0]
movsxd r8, ebp
cmp r10d, ebp
cmovle r8, r10
test r8d, r8d
jle 0x140130aad
mov r9d, dword [rsp + 0x90]
mov rdx, r12
mov dword [rsp + 0xc0], r10d
add eax, r9d
cdqe
lea rcx, [rbx + rax]
call sym.memcmp
mov r10d, dword [rsp + 0xc0]
test eax, eax
jne 0x140130ab2
mov eax, r10d
sub eax, ebp
test eax, eax
js 0x14013065b
mov eax, dword [r14 + 0x3c]
jmp 0x140130668
mov r9, qword [r12 + 0x20]
lea r10, [rsp + 0x130]
movzx eax, ax
lea rcx, [rdx + rax]
mov rdx, r10
mov qword [rsp + 0x78], r9
call sym.sqlite3Fts5GetVarint
mov r9, qword [rsp + 0x78]
cmp r9, qword [rsp + 0x130]
jg 0x140130b02
je 0x1401309e8
test bpl, bpl
je 0x1401309e8
mov dword [r14 + 0x3c], 0x10b
jmp 0x1401309e8
xor r9d, r9d
lea r8, [rsp + 0x100]
mov edx, 0xa
mov rcx, r13
call sym.fts5StorageGetStmt
mov edi, eax
test eax, eax
jne 0x140130582
mov rax, qword [rsp + 0xd0]
mov qword [rsp + 0x1c0], r13
add rax, r14
mov qword [rsp + 0x58], rax
lea rax, [rsp + 0x140]
mov qword [rsp + 0x60], rax
mov r14, qword [rsp + 0x100]
mov rcx, r14
call sym.sqlite3_step
cmp eax, 0x64
jne 0x140130f93
xor edx, edx
mov rcx, r14
call sym.sqlite3_column_int64
mov esi, dword [r12 + 0x58]
mov dword [rsp + 0x14c], 0
mov qword [rsp + 0x140], rax
mov rdx, rax
test esi, esi
jne 0x140130e05
cmp dword [r12 + 0x60], 1
je 0x140130d32
xor ebp, ebp
mov esi, ebp
cmp dword [r12 + 0x18], ebp
jle 0x140130dcf
mov rax, qword [r12 + 0x28]
cmp byte [rax + rbp], 0
jne 0x140130dbe
cmp dword [r12 + 0x60], 2
mov dword [rsp + 0x148], ebp
mov dword [rsp + 0x14c], 0
je 0x140130e90
add esi, 1
mov rcx, r14
mov edx, esi
call sym.columnMem
mov rbx, rax
test rax, rax
je 0x140130c27
movzx eax, word [rax + 0x14]
mov edx, eax
and dx, 0x202
cmp dx, 0x202
je 0x140130f19
test al, 1
jne 0x140130f2c
mov rcx, rbx
mov edx, 1
call sym.valueToText
mov rbx, rax
test r14, r14
je 0x140130de8
mov rcx, r14
call sym.columnMallocFailure.part.0
mov edx, esi
mov rcx, r14
call sym.columnMem
mov edx, 1
mov rcx, rax
call sym.sqlite3ValueBytes
mov rcx, r14
mov esi, eax
call sym.columnMallocFailure.part.0
test rbx, rbx
je 0x140130d90
mov rax, qword [r12 + 0x78]
lea rdi, [sym.fts5StorageIntegrityCallback]
mov rcx, qword [r12 + 0x70]
mov r9, rbx
mov qword [rsp + 0x28], rdi
mov rdx, qword [rsp + 0x60]
mov r8d, 4
mov dword [rsp + 0x20], esi
call qword [rax + 0x10]
mov edi, eax
test eax, eax
je 0x140130d90
movsxd rax, dword [rsp + 0x14c]
mov rbx, qword [rsp + 0xd0]
add qword [rbx + rbp*8], rax
cmp dword [r12 + 0x60], 2
jne 0x140130e21
mov r15, qword [rsp + 0x158]
test r15, r15
je 0x140130d1a
mov rbx, r15
lea rsi, [r15 + 0x1000]
nop
mov r13, qword [rbx]
test r13, r13
je 0x140130cf1
nop dword [rax + rax]
mov rcx, r13
mov r13, qword [r13 + 0x10]
call sym.sqlite3_free
test r13, r13
jne 0x140130ce0
add rbx, 8
cmp rsi, rbx
jne 0x140130cd0
mov rcx, r15
add rbp, 1
call sym.sqlite3_free
mov qword [rsp + 0x158], 0
test edi, edi
je 0x140130baa
mov rcx, r14
call sym.sqlite3_reset
jmp 0x140130582
lock or qword [rsp], 0
jmp 0x140130004
lea rcx, [rsp + 0x130]
mov edx, 0x1000
mov dword [rsp + 0x130], 0
call sym.sqlite3Fts5MallocZero
mov edi, dword [rsp + 0x130]
mov qword [rsp + 0x158], rax
mov rbp, rax
test edi, edi
je 0x140130ba8
test rax, rax
jne 0x140130e32
mov qword [rsp + 0x158], 0
mov rcx, r14
call sym.sqlite3_reset
jmp 0x140130582
mov r11d, dword [r12 + 0x58]
movsxd rax, dword [rsp + 0x14c]
test r11d, r11d
jne 0x140130f01
mov rdi, qword [rsp + 0xd0]
add qword [rdi + rbp*8], rax
cmp dword [r12 + 0x60], 2
je 0x1401310b3
add rbp, 1
mov esi, ebp
cmp dword [r12 + 0x18], ebp
jg 0x140130bb7
mov rbp, qword [rsp + 0x158]
test rbp, rbp
je 0x140130b56
xor edi, edi
jmp 0x140130e32
mov edx, esi
xor ecx, ecx
call sym.columnMem
mov edx, 1
mov rcx, rax
call sym.sqlite3ValueBytes
mov esi, eax
jmp 0x140130c59
mov r8, qword [rsp + 0x58]
mov rcx, qword [rsp + 0x1c0]
call sym.sqlite3Fts5StorageDocsize
mov edi, eax
test eax, eax
je 0x140130b9c
mov rbp, qword [rsp + 0x158]
test rbp, rbp
je 0x140130d1a
mov rbx, rbp
lea rsi, [rbp + 0x1000]
nop dword [rax]
mov r15, qword [rbx]
test r15, r15
je 0x140130e61
nop dword [rax + rax]
mov rcx, r15
mov r15, qword [r15 + 0x10]
call sym.sqlite3_free
test r15, r15
jne 0x140130e50
add rbx, 8
cmp rsi, rbx
jne 0x140130e40
mov rcx, rbp
call sym.sqlite3_free
mov qword [rsp + 0x158], 0
test edi, edi
je 0x140130b56
jmp 0x140130d1a
mov ebx, dword [0x14014efd4]
test ebx, ebx
jne 0x140130f51
call sym.sqlite3MutexInit
test eax, eax
jne 0x140130f33
call sym.sqlite3_initialize.part.0
test eax, eax
jne 0x140130f33
mov ecx, 0x1000
call sym.sqlite3Malloc
mov rdx, rax
test rax, rax
je 0x140130f33
lea rdi, [rax + 8]
mov rcx, rax
mov qword [rax], 0
mov qword [rax + 0xff8], 0
and rdi, 0xfffffffffffffff8
xor eax, eax
sub rcx, rdi
add ecx, 0x1000
shr ecx, 3
rep stosq qword [rdi], rax
mov qword [rsp + 0x158], rdx
jmp 0x140130be4
mov rbx, qword [rsp + 0x58]
mov edi, 0x10b
cmp dword [rbx + rbp*4], eax
jne 0x140130c9f
jmp 0x140130da6
cmp byte [rbx + 0x16], 1
jne 0x140130c0f
mov rbx, qword [rbx + 8]
jmp 0x140130c27
xor ebx, ebx
jmp 0x140130c27
movsxd rax, dword [rsp + 0x14c]
mov edi, 7
mov qword [rsp + 0x158], 0
jmp 0x140130c9f
lock or qword [rsp], 0
jmp 0x140130eb4
mov eax, dword [r11 + 0x1c]
xor ebx, ebx
mov rsi, r11
test eax, eax
jle 0x140130f86
mov rax, rbx
add rbx, 1
shl rax, 4
mov rcx, qword [rsi + rax + 0x28]
call sym.sqlite3_free
cmp dword [rsi + 0x1c], ebx
jg 0x140130f69
mov r11, rsi
mov rcx, r11
call sym.sqlite3_free
jmp 0x140130569
mov rcx, r14
mov r13, qword [rsp + 0x1c0]
call sym.sqlite3_reset
mov edi, eax
test eax, eax
jne 0x140130582
mov r10d, dword [r13 + 0x10]
test r10d, r10d
je 0x140131017
mov edx, dword [r12 + 0x18]
xor eax, eax
cmp edx, eax
jle 0x140130ff8
mov rcx, qword [r13 + 0x20]
mov rdi, qword [rsp + 0xd0]
mov rcx, qword [rcx + rax*8]
add rax, 1
cmp rcx, qword [rdi + rax*8 - 8]
je 0x140130fbd
mov edi, 0x10b
jmp 0x140130582
mov r10d, dword [rsp + 0x128]
jmp 0x1401306d8
mov r9d, dword [r12 + 0x40]
test r9d, r9d
je 0x14013106e
mov r8d, dword [r12 + 0x58]
test r8d, r8d
jne 0x14013102c
mov r12d, 1
jmp 0x140130058
xor edx, edx
mov rcx, r13
call sym.fts5StorageLoadTotals.part.0
mov edi, eax
test eax, eax
je 0x140130fb6
jmp 0x140130582
mov rcx, qword [r13]
lea r8, [rsp + 0x130]
lea rdx, str.docsize
mov qword [rsp + 0x130], 0
call sym.fts5StorageCount.constprop.0.isra.0
mov edi, eax
test eax, eax
jne 0x140130582
mov rax, qword [rsp + 0x130]
cmp qword [r13 + 0x18], rax
jne 0x140130fdc
jmp 0x14013100c
mov rcx, qword [r13]
lea r8, [rsp + 0x130]
lea rdx, str.content
mov qword [rsp + 0x130], 0
call sym.fts5StorageCount.constprop.0.isra.0
mov edi, eax
test eax, eax
jne 0x140130582
mov rax, qword [rsp + 0x130]
cmp qword [r13 + 0x18], rax
jne 0x140130fdc
jmp 0x140131002
mov r15, qword [rsp + 0x158]
xor edi, edi
test r15, r15
jne 0x140130cc4
jmp 0x140130dbe
movzx eax, dx
lea r9, [rsp + 0x110]
xor r8d, r8d
mov rcx, r14
shl rax, 7
mov qword [rsp + 0x60], r9
mov dword [rsp + 0x118], 0
lea rdx, [r15 + rax + 0x68]
call sym.fts5SegiterPoslist
movsxd rdx, dword [rsp + 0x118]
lea r8d, [rdx + 4]
cmp dword [rsp + 0x11c], r8d
jae 0x14013112f
mov rdx, qword [rsp + 0x60]
lea rcx, [r14 + 0x3c]
call sym.sqlite3Fts5BufferSize
movsxd rdx, dword [rsp + 0x118]
test eax, eax
jne 0x140131151
mov rax, qword [rsp + 0x110]
add rax, rdx
mov dword [rax], 0
mov eax, dword [rsp + 0x118]
lea edx, [rax + 4]
mov dword [rsp + 0x118], edx
lea rax, [rsp + 0x108]
mov rcx, qword [rsp + 0x110]
mov qword [rsp + 0x70], rbx
mov r11, r15
mov qword [rsp + 0x60], rax
movsxd rax, ebp
mov r15, r14
lea r10, [r13*8]
add rax, rdi
mov rbx, r10
mov r14, rcx
mov r10d, r12d
mov qword [rsp + 0x68], rax
lea r9, [rsp + 0x130]
mov r12d, edx
mov r8, qword [rsp + 0x60]
mov edx, r12d
mov rcx, r14
mov qword [rsp + 0x78], r9
mov qword [rsp + 0x88], r11
mov dword [rsp + 0x84], r10d
call sym.sqlite3Fts5PoslistNext64
mov r9, qword [rsp + 0x78]
mov r10d, dword [rsp + 0x84]
test eax, eax
mov r11, qword [rsp + 0x88]
jne 0x14013121c
mov rax, qword [rsp + 0x130]
mov rdx, rax
and eax, 0x7fffffff
sar rdx, 0x20
add rdx, r13
add rdx, rbx
add rax, rdx
lea rax, [rax + rdx*8]
test ebp, ebp
jle 0x140131214
mov rdx, rdi
movsx rcx, byte [rdx]
add rdx, 1
lea rcx, [rcx + rax*8]
add rax, rcx
cmp qword [rsp + 0x68], rdx
jne 0x1401311fe
xor rsi, rax
jmp 0x140131198
mov r14, r15
mov rbx, qword [rsp + 0x70]
mov r12d, r10d
mov r15, r11
jmp 0x140130503