Function at 0x1800a0520
Capabilities:
Reference sql statements

Disassembly:
mov qword [rsp + 0x20], rbx
push rsi
push rdi
push r13
push r14
push r15
sub rsp, 0x60
xor r13d, r13d
mov r14, r9
movsxd rdi, r8d
mov rbx, rdx
mov rsi, rcx
lea r15d, [r13 + 1]
cmp byte [rdx + 0x65], r13b
jne 0x1800a05aa
lea edx, [r13 + 0x28]
mov rcx, rbx
call fcn.18000c4a0
mov rdi, rax
test rax, rax
je 0x1800a0594
mov rax, qword [str.cannot_VACUUM_from_within_a_transaction]
mov qword [rdi], rax
mov rcx, qword [0x180154be0]
mov qword [rdi + 8], rcx
mov rcx, qword [0x180154be8]
mov qword [rdi + 0x10], rcx
mov rcx, qword [0x180154bf0]
mov qword [rdi + 0x18], rcx
mov rcx, qword [0x180154bf8]
mov qword [rdi + 0x20], rcx
mov rdx, qword [rsi]
mov rcx, rbx
call fcn.18000c110
mov qword [rsi], rdi
mov eax, r15d
jmp 0x1800a0b53
cmp dword [rdx + 0xd8], r15d
jle 0x1800a0618
mov edx, 0x2b
mov rcx, rbx
call fcn.18000c4a0
mov rdi, rax
test rax, rax
je 0x1800a0594
mov rcx, qword [str.cannot_VACUUM___SQL_statements_in_progress]
mov qword [rax], rcx
mov rcx, qword [0x180154c08]
mov qword [rax + 8], rcx
mov rcx, qword [0x180154c10]
mov qword [rax + 0x10], rcx
mov rcx, qword [0x180154c18]
mov qword [rax + 0x18], rcx
mov rcx, qword [0x180154c20]
mov qword [rax + 0x20], rcx
movzx eax, word [0x180154c28]
mov word [rdi + 0x28], ax
movzx eax, byte [0x180154c2a]
mov byte [rdi + 0x2a], al
jmp 0x1800a0594
mov qword [rsp + 0x90], rbp
mov ebp, dword [rdx + 0x4c]
lea rcx, [0x180000000]
test r9, r9
je 0x1800a06a1
movzx eax, word [r9 + 0x14]
and eax, 0x3f
cmp byte [rax + rcx + 0x145b40], 3
je 0x1800a068c
mov edx, 0x12
mov rcx, rbx
call fcn.18000c4a0
mov rdi, rax
test rax, rax
je 0x1800a0676
mov rcx, qword [str.non_text_filename]
mov qword [rax], rcx
mov rcx, qword [0x180154c38]
mov qword [rax + 8], rcx
movzx ecx, word [0x180154c40]
mov word [rax + 0x10], cx
mov rdx, qword [rsi]
mov rcx, rbx
call fcn.18000c110
mov qword [rsi], rdi
mov eax, r15d
jmp 0x1800a0b4b
mov rcx, r9
call sym.sqlite.dll_sqlite3_value_text
and dword [rbx + 0x4c], 0xfffffffe
or dword [rbx + 0x4c], 6
mov r9, rax
jmp 0x1800a06a8
lea r9, [0x180144af4]
mov eax, dword [rbx + 0x2c]
mov rcx, qword [rbx + 0x30]
mov rdx, qword [rbx + 0x78]
mov dword [rsp + 0x30], eax
or eax, 6
mov qword [rsp + 0x40], rcx
mov dword [rbx + 0x2c], eax
mov rax, rcx
mov qword [rsp + 0x48], rdx
mov rdx, qword [rbx + 0x80]
movabs rcx, 0xfffffffeefffafff
mov qword [rsp + 0xa0], r12
and rax, rcx
mov qword [rsp + 0x58], rdx
movzx edx, byte [rbx + 0x6e]
mov byte [rbx + 0x6e], r13b
or rax, 0x201
mov rcx, rdi
mov qword [rbx + 0x30], rax
mov rax, qword [rbx + 0x20]
shl rcx, 5
mov r12, qword [rcx + rax + 8]
mov byte [rsp + 0x98], dl
mov rdx, qword [rcx + rax]
mov rax, qword [r12 + 8]
mov qword [rsp + 0x38], rcx
mov qword [rsp + 0x50], rdx
mov rcx, qword [rax]
cmp byte [rcx + 0x10], r13b
jne 0x1800a073b
mov dword [rsp + 0x2c], r13d
cmp byte [rcx + 0x14], r13b
je 0x1800a0740
mov dword [rsp + 0x2c], r15d
mov eax, dword [rbx + 0x28]
lea r8, str.ATTACH__Q_AS_vacuum_db
mov rdx, rsi
mov rcx, rbx
mov dword [rsp + 0x28], eax
call fcn.1800a03b0
mov dword [rbx + 0x4c], ebp
mov edi, eax
test eax, eax
jne 0x1800a0acc
movsxd r13, dword [rsp + 0x28]
shl r13, 5
add r13, qword [rbx + 0x20]
mov rbp, qword [r13 + 8]
test r14, r14
je 0x1800a082e
mov rax, qword [rbp + 8]
mov rcx, qword [rax]
mov rcx, qword [rcx + 0x48]
mov qword [rsp + 0x20], 0
mov rax, qword [rcx]
test rax, rax
je 0x1800a0810
lea rdx, [rsp + 0x20]
call qword [rax + 0x30]
test eax, eax
jne 0x1800a07b0
cmp qword [rsp + 0x20], 0
jle 0x1800a0810
mov edx, 0x1b
mov rcx, rbx
mov edi, r15d
call fcn.18000c4a0
mov rbp, rax
test rax, rax
je 0x1800a07fd
mov rcx, qword [str.output_file_already_exists]
mov qword [rax], rcx
mov rcx, qword [0x180154c68]
mov qword [rax + 8], rcx
mov rcx, qword [0x180154c70]
mov qword [rax + 0x10], rcx
movzx ecx, word [0x180154c78]
mov word [rax + 0x18], cx
movzx ecx, byte [0x180154c7a]
mov byte [rax + 0x1a], cl
mov rdx, qword [rsi]
mov rcx, rbx
call fcn.18000c110
mov qword [rsi], rbp
jmp 0x1800a0acc
mov rax, qword [rbx + 0x20]
or dword [rbx + 0x2c], 8
mov rdi, qword [rsp + 0x38]
movzx r15d, byte [rdi + rax + 0x10]
mov eax, dword [rbx + 0x30]
and eax, 0x38
or r15d, eax
jmp 0x1800a0833
mov rdi, qword [rsp + 0x38]
mov rcx, r12
call fcn.180026fe0
mov rcx, qword [rbx + 0x20]
mov rdx, qword [rdi + rcx + 0x18]
mov rcx, rbp
mov dword [rsp + 0x20], eax
mov edx, dword [rdx + 0x74]
call fcn.180026d30
xor edx, edx
mov rcx, r12
call fcn.180026dd0
mov rcx, rbp
mov edx, eax
call fcn.180026dd0
or r15d, 0x20
mov rcx, rbp
mov edx, r15d
call fcn.180026e90
lea r8, str.BEGIN
mov rdx, rsi
mov rcx, rbx
call fcn.1800a0270
mov edi, eax
test eax, eax
jne 0x1800a0acc
xor edx, edx
test r14, r14
mov eax, 2
cmove edx, eax
cmp byte [r12 + 0x11], dil
jne 0x1800a08bc
movzx eax, byte [r12 + 0x10]
test al, al
je 0x1800a08bc
cmp al, 1
jne 0x1800a0940
test edx, edx
je 0x1800a08d1
xor r8d, r8d
mov rcx, r12
call fcn.180027610
mov edi, eax
test edi, edi
jne 0x1800a0acc
mov rax, qword [r12 + 8]
mov rcx, qword [rax]
cmp byte [rcx + 9], 5
jne 0x1800a08e8
test r14, r14
jne 0x1800a08e8
mov dword [rbx + 0x74], r14d
mov rax, qword [r12 + 8]
mov edi, dword [rsp + 0x20]
xor r9d, r9d
mov edx, dword [rax + 0x34]
mov r8d, edi
mov rcx, rbp
call fcn.180026ef0
test eax, eax
jne 0x1800a0ac7
cmp dword [rsp + 0x2c], eax
jne 0x1800a0929
mov edx, dword [rbx + 0x74]
xor r9d, r9d
mov r8d, edi
mov rcx, rbp
call fcn.180026ef0
test eax, eax
jne 0x1800a0ac7
cmp byte [rbx + 0x67], 0
jne 0x1800a0ac7
movzx eax, byte [rbx + 0x6a]
test al, al
js 0x1800a0975
movsx eax, al
jmp 0x1800a097d
test edx, edx
je 0x1800a08d1
mov rax, qword [r12]
mov edx, dword [rax + 0x308]
mov rax, qword [r12 + 8]
mov rcx, qword [rax]
cmp edx, dword [rcx + 0x80]
jle 0x1800a096e
cmp byte [rcx + 0xa], 0
je 0x1800a096e
call fcn.18001faf0
jmp 0x1800a08c7
xor edi, edi
jmp 0x1800a08c9
mov rcx, r12
call fcn.1800271b0
mov edx, eax
mov rcx, rbp
call fcn.180027120
mov eax, dword [rsp + 0x28]
mov r15, qword [rsp + 0x50]
lea r8, str.SELECT_sql_FROM___w_.sqlite_schema_WHERE_typetableAND_name__sqlite_sequence_AND_coalesce_rootpage_1__0
mov r9, r15
mov rdx, rsi
mov rcx, rbx
mov byte [rbx + 0xc4], al
call fcn.1800a03b0
mov edi, eax
test eax, eax
jne 0x1800a0acc
lea r8, str.SELECT_sql_FROM___w_.sqlite_schema_WHERE_typeindex
mov r9, r15
mov rdx, rsi
mov rcx, rbx
call fcn.1800a03b0
mov edi, eax
test eax, eax
jne 0x1800a0acc
lea r8, str.SELECTINSERT_INTO_vacuum_db.quote_name__SELECTFROM__w_.quote_name_FROM_vacuum_db.sqlite_schema_WHERE_typetableAND_coalesce_rootpage_1__0
mov r9, r15
mov rdx, rsi
mov rcx, rbx
mov byte [rbx + 0xc4], al
call fcn.1800a03b0
and dword [rbx + 0x2c], 0xfffffffb
mov edi, eax
test eax, eax
jne 0x1800a0acc
lea r8, str.INSERT_INTO_vacuum_db.sqlite_schema_SELECTFROM___w_.sqlite_schema_WHERE_type_IN_view_trigger__OR_typetableAND_rootpage0_
mov r9, r15
mov rdx, rsi
mov rcx, rbx
call fcn.1800a03b0
mov edi, eax
test eax, eax
jne 0x1800a0acc
xor esi, esi
nop
lea rdi, [0x180000000]
lea r8, [rsp + 0x20]
mov rcx, r12
movzx edx, byte [rsi + rdi + 0x1472f8]
call fcn.180030920
movzx r8d, byte [rsi + rdi + 0x1472f9]
movzx edx, byte [rsi + rdi + 0x1472f8]
add r8d, dword [rsp + 0x20]
mov rcx, rbp
call fcn.1800309b0
mov edi, eax
test eax, eax
jne 0x1800a0acc
add rsi, 2
cmp rsi, 0xa
jl 0x1800a0a20
test r14, r14
jne 0x1800a0a80
mov rdx, rbp
mov rcx, r12
call fcn.180033160
mov edi, eax
test eax, eax
jne 0x1800a0acc
mov rcx, rbp
call fcn.180028810
mov edi, eax
test eax, eax
jne 0x1800a0acc
test r14, r14
jne 0x1800a0acc
mov rcx, rbp
call fcn.1800271b0
mov rcx, r12
mov edx, eax
call fcn.180027120
mov rcx, rbp
call fcn.180026fe0
mov rcx, qword [rbp + 8]
lea r9d, [rdi + 1]
mov edx, dword [rcx + 0x34]
mov r8d, eax
mov rcx, r12
call fcn.180026ef0
mov edi, eax
jmp 0x1800a0acc
mov edi, 7
mov eax, dword [rsp + 0x30]
mov r9d, 1
xor r8d, r8d
mov dword [rbx + 0x2c], eax
mov rax, qword [rsp + 0x40]
or edx, 0xffffffff
mov qword [rbx + 0x30], rax
mov rax, qword [rsp + 0x48]
mov rcx, r12
mov qword [rbx + 0x78], rax
mov rax, qword [rsp + 0x58]
mov byte [rbx + 0xc4], 0
mov qword [rbx + 0x80], rax
movzx eax, byte [rsp + 0x98]
mov byte [rbx + 0x6e], al
call fcn.180026ef0
mov r12, qword [rsp + 0xa0]
mov byte [rbx + 0x65], 1
test r13, r13
je 0x1800a0b41
mov rcx, qword [r13 + 8]
call fcn.180026c40
mov qword [r13 + 8], 0
mov qword [r13 + 0x18], 0
mov rcx, rbx
call fcn.1800658a0
mov eax, edi
mov rbp, qword [rsp + 0x90]
mov rbx, qword [rsp + 0xa8]
add rsp, 0x60
pop r15
pop r14
pop r13
pop rdi
pop rsi
ret