Function at 0x67a360
Capabilities:
Reference sql statements

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0xb8
cmp byte [rdx + 0x65], 0
movsxd rdi, r8d
mov r15, rcx
mov rbx, rdx
mov r13, r9
lea r8, str.cannot_VACUUM_from_within_a_transaction
je 0x67a3bf
cmp dword [rdx + 0xd8], 1
lea r8, str.cannot_VACUUM___SQL_statements_in_progress
jg 0x67a3bf
test r9, r9
mov esi, dword [rdx + 0x4c]
je 0x67a3ed
mov eax, dword [r9 + 0x14]
lea rdx, [0x007ae760]
and eax, 0x3f
cmp byte [rdx + rax], 3
je 0x67a3d4
lea r8, str.non_text_filename
mov rdx, rbx
mov rcx, r15
mov edi, 1
call fcn.0067e710
jmp 0x67a8a6
mov rcx, r9
call fcn.0069cc60
mov edx, dword [rbx + 0x4c]
mov r9, rax
and edx, 0xfffffffe
or edx, 6
mov dword [rbx + 0x4c], edx
jmp 0x67a3f4
lea r9, [0x0079ecef]
mov rax, qword [rbx + 0x30]
shl rdi, 5
movabs rdx, 0xfffffffeefffafff
lea r8, str.ATTACH__Q_AS_vacuum_db
mov rcx, rbx
mov qword [rsp + 0x20], rdi
xor r12d, r12d
mov qword [rsp + 0x28], rax
mov eax, dword [rbx + 0x2c]
and rdx, qword [rsp + 0x28]
mov dword [rsp + 0x34], eax
mov rax, qword [rbx + 0x78]
or rdx, 0x201
mov qword [rsp + 0x40], rax
mov rax, qword [rbx + 0x80]
mov qword [rbx + 0x30], rdx
mov rdx, r15
mov qword [rsp + 0x48], rax
mov al, byte [rbx + 0x6e]
mov byte [rbx + 0x6e], 0
mov byte [rsp + 0x57], al
mov eax, dword [rsp + 0x34]
or eax, 6
mov dword [rbx + 0x2c], eax
mov rax, qword [rbx + 0x20]
add rax, rdi
mov rbp, qword [rax + 8]
mov r14, qword [rax]
mov rax, qword [rbp + 8]
mov rax, qword [rax]
mov rax, qword [rax + 0x10]
mov qword [rsp + 0x58], rax
mov eax, dword [rbx + 0x28]
mov dword [rsp + 0x38], eax
call fcn.00610800
test eax, eax
mov edi, eax
mov dword [rbx + 0x4c], esi
jne 0x67a832
movsxd r12, dword [rsp + 0x38]
shl r12, 5
add r12, qword [rbx + 0x20]
test r13, r13
mov rsi, qword [r12 + 8]
je 0x67a4ff
mov rax, qword [rsi + 8]
mov rax, qword [rax]
mov rcx, qword [rax + 0x48]
mov qword [rsp + 0x68], 0
cmp qword [rcx], 0
je 0x67a4fb
lea rdx, [rsp + 0x68]
call fcn.0066e7a0
test eax, eax
jne 0x67a4df
cmp qword [rsp + 0x68], 0
jle 0x67a4fb
lea r8, str.output_file_already_exists
mov rdx, rbx
mov rcx, r15
mov edi, 1
call fcn.0067e710
jmp 0x67a832
or dword [rbx + 0x2c], 8
mov rcx, rbp
call fcn.006526f0
mov rdi, qword [rsp + 0x20]
mov rcx, rsi
mov dword [rsp + 0x50], eax
mov rax, qword [rbx + 0x20]
mov rax, qword [rax + rdi + 0x18]
mov edx, dword [rax + 0x74]
call fcn.006543b0
xor edx, edx
mov rcx, rbp
call fcn.00654570
mov rcx, rsi
mov edx, eax
call fcn.00654570
mov edx, 0x21
mov rcx, rsi
call fcn.006544c0
lea r8, str.BEGIN
mov rdx, r15
mov rcx, rbx
call fcn.00610710
test eax, eax
mov edi, eax
jne 0x67a832
test r13, r13
mov eax, 2
mov rcx, rbp
cmove edi, eax
xor r8d, r8d
mov edx, edi
call fcn.006513d0
test eax, eax
mov edi, eax
jne 0x67a832
mov rax, qword [rbp + 8]
mov rdx, qword [rax]
cmp byte [rdx + 9], 5
jne 0x67a59c
test r13, r13
jne 0x67a59c
mov dword [rbx + 0x74], 0
mov edx, dword [rax + 0x34]
mov r8d, dword [rsp + 0x50]
xor r9d, r9d
mov rcx, rsi
mov edi, 7
call fcn.00654400
test eax, eax
jne 0x67a832
movabs rax, 0xff000000ff
test qword [rsp + 0x58], rax
je 0x67a5de
cmp byte [rbx + 0x67], 0
mov edi, 7
jne 0x67a832
jmp 0x67a5fb
mov edx, dword [rbx + 0x74]
mov r8d, dword [rsp + 0x50]
xor r9d, r9d
mov rcx, rsi
call fcn.00654400
test eax, eax
jne 0x67a832
jmp 0x67a5cd
movsx eax, byte [rbx + 0x6a]
test al, al
jns 0x67a60b
mov rcx, rbp
call fcn.006af510
mov edx, eax
mov rcx, rsi
call fcn.00654360
mov al, byte [rsp + 0x38]
lea r8, str.SELECT_sql_FROM___w_.sqlite_schema_WHERE_typetableAND_name__sqlite_sequence_AND_coalesce_rootpage_1__0
mov r9, r14
mov rdx, r15
mov rcx, rbx
mov byte [rbx + 0xc4], al
call fcn.00610800
test eax, eax
mov edi, eax
jne 0x67a832
lea r8, str.SELECT_sql_FROM___w_.sqlite_schema_WHERE_typeindex
mov r9, r14
mov rdx, r15
mov rcx, rbx
call fcn.00610800
test eax, eax
mov edi, eax
jne 0x67a832
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 byte [rbx + 0xc4], 0
mov r9, r14
mov rdx, r15
mov rcx, rbx
call fcn.00610800
and dword [rbx + 0x2c], 0xfffffffb
test eax, eax
mov edi, eax
jne 0x67a832
lea r8, str.INSERT_INTO_vacuum_db.sqlite_schema_SELECTFROM___w_.sqlite_schema_WHERE_type_IN_view_trigger__OR_typetableAND_rootpage0_
mov r9, r14
mov rdx, r15
mov rcx, rbx
call fcn.00610800
test eax, eax
mov edi, eax
jne 0x67a832
lea r9, [0x007ab150]
lea rax, [rsp + 0x64]
xor r15d, r15d
lea r14, [r9 + 1]
mov qword [rsp + 0x20], rax
movzx eax, byte [r9 + r15]
mov r8, qword [rsp + 0x20]
mov rcx, rbp
mov qword [rsp + 0x38], r9
mov edx, eax
mov edi, eax
call fcn.00652690
movzx r8d, byte [r15 + r14]
mov edx, edi
mov rcx, rsi
add r8d, dword [rsp + 0x64]
call fcn.00654930
test eax, eax
mov edi, eax
jne 0x67a832
add r15, 2
mov r9, qword [rsp + 0x38]
cmp r15, 0xa
jne 0x67a6be
test r13, r13
je 0x67a722
mov rcx, rsi
call fcn.00651bd0
test eax, eax
mov edi, eax
jne 0x67a832
jmp 0x67a7f9
mov rcx, rbp
lea r14, [rsp + 0x68]
call fcn.00652620
mov rcx, rsi
call fcn.00652620
mov rax, qword [rbp + 8]
mov rax, qword [rax]
mov rcx, qword [rax + 0x48]
cmp qword [rcx], 0
je 0x67a774
mov rdx, qword [rsi + 8]
mov r8, r14
movsxd rax, dword [rdx + 0x34]
mov edx, dword [rdx + 0x40]
imul rax, rdx
mov edx, 0xb
mov qword [rsp + 0x68], rax
call fcn.0066e770
cmp eax, 0xc
mov edi, eax
je 0x67a774
test eax, eax
jne 0x67a7e0
xor eax, eax
mov ecx, 0x12
mov rdi, r14
rep stosd dword [rdi], eax
mov edx, 0x7fffffff
mov rcx, r14
mov rax, qword [rsi]
mov qword [rsp + 0x90], rsi
mov qword [rsp + 0x70], rbp
mov dword [rsp + 0x80], 1
mov qword [rsp + 0x88], rax
call fcn.006941e0
mov rcx, r14
call fcn.00693fa0
test eax, eax
mov edi, eax
jne 0x67a7c9
mov rax, qword [rbp + 8]
and word [rax + 0x28], 0xfffd
jmp 0x67a7e0
mov rax, qword [rsp + 0x70]
mov rax, qword [rax + 8]
mov rcx, qword [rax]
cmp byte [rcx + 0x10], 0
jne 0x67a7e0
call fcn.0063ff90
mov rcx, rsi
call fcn.00653400
mov rcx, rbp
call fcn.00653400
test edi, edi
jne 0x67a832
jmp 0x67a70b
test r13, r13
jne 0x67a832
mov rcx, rsi
call fcn.006af510
mov rcx, rbp
mov edx, eax
call fcn.00654360
mov rcx, rsi
call fcn.006526f0
mov r8d, eax
mov rax, qword [rsi + 8]
mov r9d, 1
mov rcx, rbp
mov edx, dword [rax + 0x34]
call fcn.00654400
mov edi, eax
mov eax, dword [rsp + 0x34]
xor r8d, r8d
or edx, 0xffffffff
mov byte [rbx + 0xc4], 0
mov r9d, 1
mov rcx, rbp
mov dword [rbx + 0x2c], eax
mov rax, qword [rsp + 0x28]
mov qword [rbx + 0x30], rax
mov rax, qword [rsp + 0x40]
mov qword [rbx + 0x78], rax
mov rax, qword [rsp + 0x48]
mov qword [rbx + 0x80], rax
mov al, byte [rsp + 0x57]
mov byte [rbx + 0x6e], al
call fcn.00654400
test r12, r12
mov byte [rbx + 0x65], 1
je 0x67a89e
mov rcx, qword [r12 + 8]
call fcn.00651ab0
mov qword [r12 + 8], 0
mov qword [r12 + 0x18], 0
mov rcx, rbx
call fcn.00673df0
mov eax, edi
add rsp, 0xb8
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret