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

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
push rsi
push rdi
push r12
push r13
push r14
sub rsp, 0x30
mov rbp, qword [rcx]
mov edi, r9d
mov rsi, r8
mov r14, rdx
mov rbx, rcx
test r8, r8
je 0x18009b7aa
cmp dword [r8 + 8], 0
jbe 0x18009b7aa
cmp byte [rbp + 0xa1], 0
je 0x18009b77e
lea rdx, str.corrupt_database
call fcn.18003b940
inc dword [rbx + 0x4c]
jmp 0x18009bbfa
mov rcx, rbp
mov r13, r8
call fcn.18003a290
mov r12d, eax
test eax, eax
jns 0x18009b7b5
lea rdx, str.unknown_database__T
mov r8, r14
mov rcx, rbx
call fcn.18003b940
inc dword [rbx + 0x4c]
jmp 0x18009bbfa
movzx r12d, byte [rbp + 0xa0]
mov r13, rdx
test r12d, r12d
js 0x18009bbfa
mov r14d, 1
test edi, edi
je 0x18009b7ea
cmp dword [rsi + 8], 0
jbe 0x18009b7e7
cmp r12d, r14d
je 0x18009b7e7
lea rdx, str.temporary_table_name_must_be_unqualified
mov rcx, rbx
call fcn.18003b940
jmp 0x18009bbfa
mov r12d, r14d
mov rax, qword [r13]
mov rdx, r13
mov rcx, rbp
mov qword [rbx + 0x238], rax
mov rax, qword [r13 + 8]
mov qword [rbx + 0x240], rax
call fcn.1800367f0
mov rsi, rax
test rax, rax
je 0x18009bbfa
mov rdx, rax
mov rcx, rbx
call fcn.1800403d0
test eax, eax
jne 0x18009bbef
cmp byte [rbp + 0xa0], r14b
mov rax, qword [rbp + 0x20]
lea rcx, str.sqlite_master
cmove edi, r14d
movsxd r14, r12d
lea r8, str.sqlite_temp_master
shl r14, 5
cmp edi, 1
mov rax, qword [r14 + rax]
cmovne r8, rcx
xor r9d, r9d
lea edx, [r9 + 0x12]
mov rcx, rbx
mov qword [rsp + 0x60], rax
mov qword [rsp + 0x20], rax
call fcn.180045cc0
test eax, eax
jne 0x18009bbef
cmp dword [rsp + 0x80], 0
mov eax, 4
je 0x18009b891
lea edx, [rax + 4]
lea eax, [rdx - 2]
jmp 0x18009b896
mov edx, 2
test edi, edi
cmovne edx, eax
cmp dword [rsp + 0x88], 0
jne 0x18009b8c5
mov rax, qword [rsp + 0x60]
xor r9d, r9d
mov r8, rsi
mov rcx, rbx
mov qword [rsp + 0x20], rax
call fcn.180045cc0
test eax, eax
jne 0x18009bbef
cmp byte [rbx + 0x1f3], 0
jne 0x18009b955
mov rax, qword [rbp + 0x20]
mov rcx, rbx
mov rdi, qword [r14 + rax]
call fcn.18000f150
test eax, eax
jne 0x18009bbef
mov r8, rdi
mov rdx, rsi
mov rcx, rbp
call fcn.180028fb0
test rax, rax
je 0x18009b92b
cmp dword [rsp + 0x90], 0
mov rcx, rbx
jne 0x18009b91e
lea rdx, str.table__T_already_exists
mov r8, r13
call fcn.18003b940
jmp 0x18009bbef
mov edx, r12d
call fcn.180091ec0
jmp 0x18009bbef
mov r8, rdi
mov rdx, rsi
mov rcx, rbp
call fcn.180028ea0
test rax, rax
je 0x18009b955
lea rdx, str.there_is_already_an_index_named__s
mov r8, rsi
mov rcx, rbx
call fcn.18003b940
jmp 0x18009bbef
mov edx, 0x80
mov rcx, rbp
call fcn.18002e4c0
mov r13, rax
test rax, rax
je 0x18009bbe1
xor edx, edx
mov r8d, 0x80
mov rcx, rax
call fcn.180003c00
or eax, 0xffffffff
mov qword [r13], rsi
mov word [r13 + 0x40], ax
mov rcx, qword [rbp + 0x20]
mov eax, 1
mov rdx, qword [rcx + r14 + 0x18]
mov word [r13 + 0x44], ax
mov eax, 0xc8
mov qword [r13 + 0x70], rdx
mov word [r13 + 0x38], ax
cmp byte [rbx + 0x1e], 0
mov qword [rbx + 0x220], r13
jne 0x18009b9d0
lea rdi, str.sqlite_sequence
mov ecx, 0x10
repe cmpsb byte [rsi], byte [rdi]
jne 0x18009b9d0
mov rax, qword [r13 + 0x70]
mov qword [rax + 0x68], r13
cmp byte [rbp + 0xa1], 0
jne 0x18009bbfa
mov rcx, rbx
call fcn.180049910
mov rdi, rax
test rax, rax
je 0x18009bbfa
mov r8d, r12d
xor edx, edx
mov rcx, rbx
call fcn.180099b10
cmp dword [rsp + 0x88], 0
je 0x18009ba23
xor r9d, r9d
xor r8d, r8d
mov edx, 0x90
mov rcx, rdi
mov dword [rsp + 0x20], 0
call fcn.180042780
mov r14d, dword [rbx + 0x54]
mov r8d, r12d
mov edx, 0x33
inc r14d
mov rcx, rdi
mov dword [rsp + 0x20], 2
lea esi, [r14 + 1]
mov dword [rbx + 0x1a0], r14d
lea r13d, [rsi + 1]
mov dword [rbx + 0x1a4], esi
mov r9d, r13d
mov dword [rbx + 0x54], r13d
call fcn.180042780
mov edx, r12d
mov rcx, rdi
call fcn.18001bf90
xor r9d, r9d
mov r8d, r13d
lea edx, [r9 + 0x2d]
mov rcx, rdi
mov dword [rsp + 0x20], 0
call fcn.180042780
bt dword [rbp + 0x2c], 0xf
mov ecx, 1
mov r8d, 4
lea edx, [rcx + 0x18]
mov r9d, r13d
cmovb r8d, ecx
mov rcx, rdi
mov dword [rsp + 0x60], eax
mov dword [rsp + 0x20], 0
call fcn.180042780
mov r9d, 2
lea edx, [r9 + 0x32]
mov r8d, r12d
mov rcx, rdi
mov dword [rsp + 0x20], r13d
call fcn.180042780
movzx r8d, byte [rbp + 0x4e]
xor ebp, ebp
mov r9d, r13d
mov rcx, rdi
lea edx, [rbp + 0x19]
mov dword [rsp + 0x20], ebp
call fcn.180042780
lea r9d, [rbp + 5]
lea edx, [rbp + 0x34]
mov r8d, r12d
mov rcx, rdi
mov dword [rsp + 0x20], r13d
call fcn.180042780
mov edx, dword [rdi + 0x3c]
mov eax, dword [rsp + 0x60]
cmp edx, eax
jbe 0x18009bb12
lea rcx, [rax + rax*2]
mov rax, qword [rdi + 8]
mov dword [rax + rcx*8 + 8], edx
mov ecx, dword [rdi + 0x3c]
mov rax, qword [rdi + 0x30]
dec ecx
mov dword [rax + 0x64], ecx
cmp dword [rsp + 0x80], ebp
jne 0x18009bb4f
cmp dword [rsp + 0x88], ebp
jne 0x18009bb4f
mov r9d, esi
mov r8d, r12d
mov edx, 0x79
mov rcx, rdi
mov dword [rsp + 0x20], ebp
call fcn.180042780
mov dword [rbx + 0x1d0], eax
jmp 0x18009bb65
xor r8d, r8d
mov r9d, esi
mov rcx, rdi
lea edx, [r8 + 0x19]
mov dword [rsp + 0x20], ebp
call fcn.180042780
mov edx, r12d
mov rcx, rbx
call fcn.180052f00
xor r8d, r8d
mov r9d, r14d
lea edx, [r8 + 0x4a]
mov rcx, rdi
mov dword [rsp + 0x20], ebp
call fcn.180042780
xor r8d, r8d
mov r9d, r13d
lea edx, [r8 + 0x1c]
mov rcx, rdi
mov dword [rsp + 0x20], ebp
call fcn.180042780
xor r8d, r8d
mov r9d, r13d
lea edx, [r8 + 0x4b]
mov rcx, rdi
mov dword [rsp + 0x20], r14d
call fcn.180042780
mov rdx, qword [rdi + 8]
test rdx, rdx
je 0x18009bbc9
movsxd rax, dword [rdi + 0x3c]
lea rcx, [rax + rax*2]
mov byte [rdx + rcx*8 - 0x15], 8
xor r9d, r9d
xor r8d, r8d
mov rcx, rdi
lea edx, [r9 + 0x3d]
mov dword [rsp + 0x20], ebp
call fcn.180042780
jmp 0x18009bbfa
mov byte [rbp + 0x51], 1
inc dword [rbx + 0x4c]
mov dword [rbx + 0x18], 7
mov rdx, rsi
mov rcx, rbp
call fcn.18002acd0
mov rbx, qword [rsp + 0x68]
mov rbp, qword [rsp + 0x70]
add rsp, 0x30
pop r14
pop r13
pop r12
pop rdi
pop rsi
ret