Function at 0x14008d4a0
Capabilities:
Reference sql statements

Disassembly:
push rbp
push rsi
push r13
sub rsp, 0x50
xor r13d, r13d
mov rsi, rdx
mov rbp, rcx
cmp byte [rdx + 0x28], r13b
jne 0x14008d4d1
lea r8, str.cannot_VACUUM_from_within_a_transaction
call fcn.140024ee0
lea eax, [r13 + 1]
add rsp, 0x50
pop r13
pop rsi
pop rbp
ret
cmp dword [rdx + 0xb0], 1
jle 0x14008d4f4
lea r8, str.cannot_VACUUM___SQL_statements_in_progress
call fcn.140024ee0
mov eax, 1
add rsp, 0x50
pop r13
pop rsi
pop rbp
ret
mov eax, dword [rdx + 0x18]
mov ecx, dword [rdx + 0x4c]
mov qword [rsp + 0x70], rbx
mov ebx, dword [rdx + 8]
mov dword [rsp + 0x88], eax
and eax, 0xfaffffff
or eax, 0x10050000
cmp byte [rdx + 0x29], 2
mov dword [rsp + 0x20], ecx
mov ecx, dword [rdx + 0x50]
mov dword [rdx + 0x18], eax
mov rax, qword [rdx + 0x10]
mov dword [rsp + 0x24], ecx
mov rcx, qword [rdx + 0xc0]
mov qword [rdx + 0xc0], r13
mov qword [rsp + 0x28], rcx
mov qword [rsp + 0x48], rdi
mov qword [rsp + 0x40], r12
mov r12, qword [rax + 8]
lea r8, str.ATTACH_:memory:_AS_vacuum_db_
mov qword [rsp + 0x30], r15
mov rax, qword [r12 + 8]
mov rdx, rbp
mov rcx, qword [rax]
lea rax, str.ATTACH__AS_vacuum_db_
movzx r15d, byte [rcx + 0x12]
mov rcx, rsi
cmovne r8, rax
call fcn.14008d210
mov edi, eax
movsxd rax, dword [rsi + 8]
cmp eax, ebx
jle 0x14008d591
lea ecx, [rax - 1]
movsxd r13, ecx
shl r13, 5
add r13, qword [rsi + 0x10]
test edi, edi
jne 0x14008d806
mov rcx, rax
mov rax, qword [rsi + 0x10]
mov qword [rsp + 0x38], r14
shl rcx, 5
mov r14, qword [rcx + rax - 0x18]
mov rcx, r14
call fcn.140039e40
mov rcx, r12
call fcn.1400357d0
mov rcx, qword [r12 + 8]
mov ebx, dword [rcx + 0x34]
sub ebx, dword [rcx + 0x38]
mov dword [rsp + 0x80], ebx
cmp byte [r12 + 0x11], dil
je 0x14008d5f4
add dword [r12 + 0x14], 0xffffffff
jne 0x14008d5f4
mov rcx, qword [rcx + 0x58]
test rcx, rcx
je 0x14008d5ee
call qword [0x140144100]
mov byte [r12 + 0x12], 0
mov rax, qword [r12 + 8]
mov rcx, qword [rax]
cmp byte [rcx + 9], 5
jne 0x14008d609
mov dword [rsi + 0x30], 0
mov rax, qword [r12 + 8]
xor r9d, r9d
mov r8d, ebx
mov edx, dword [rax + 0x34]
mov rcx, r14
call fcn.140038040
test eax, eax
jne 0x14008d7fc
test r15d, r15d
jne 0x14008d645
mov edx, dword [rsi + 0x30]
xor r9d, r9d
mov r8d, ebx
mov rcx, r14
call fcn.140038040
test eax, eax
jne 0x14008d7fc
cmp byte [rsi + 0x2a], 0
jne 0x14008d7fc
lea r8, str.PRAGMA_vacuum_db.synchronousOFF
mov rdx, rbp
mov rcx, rsi
call fcn.14008d210
mov edi, eax
test eax, eax
jne 0x14008d801
movzx eax, byte [rsi + 0x2c]
test al, al
js 0x14008d678
movsx eax, al
jmp 0x14008d680
mov rcx, r12
call fcn.1400382a0
mov edx, eax
mov rcx, r14
call fcn.140038210
lea r8, str.BEGIN_EXCLUSIVE_
mov rdx, rbp
mov rcx, rsi
call fcn.14008d210
mov edi, eax
test eax, eax
jne 0x14008d801
lea r8, str.SELECT_CREATE_TABLE_vacuum_db.__substr_sql_14____FROM_sqlite_master_WHERE_typetable_AND_name_sqlite_sequence___AND_rootpage_0
mov rdx, rbp
mov rcx, rsi
call fcn.14008d2e0
mov edi, eax
test eax, eax
jne 0x14008d801
lea r8, str.SELECT_CREATE_INDEX_vacuum_db.__substr_sql_14___FROM_sqlite_master_WHERE_sql_LIKE_CREATE_INDEX__
mov rdx, rbp
mov rcx, rsi
call fcn.14008d2e0
mov edi, eax
test eax, eax
jne 0x14008d801
lea r8, str.SELECT_CREATE_UNIQUE_INDEX_vacuum_db.__substr_sql_21____FROM_sqlite_master_WHERE_sql_LIKE_CREATE_UNIQUE_INDEX__
mov rdx, rbp
mov rcx, rsi
call fcn.14008d2e0
mov edi, eax
test eax, eax
jne 0x14008d801
lea r8, str.SELECT_INSERT_INTO_vacuum_db.__quote_name____SELECT__FROM_main.__quote_name____FROM_main.sqlite_master_WHERE_type__table_AND_name_sqlite_sequence___AND_rootpage_0
mov rdx, rbp
mov rcx, rsi
call fcn.14008d2e0
mov edi, eax
test eax, eax
jne 0x14008d801
lea r8, str.SELECT_DELETE_FROM_vacuum_db.__quote_name_____FROM_vacuum_db.sqlite_master_WHERE_namesqlite_sequence
mov rdx, rbp
mov rcx, rsi
call fcn.14008d2e0
mov edi, eax
test eax, eax
jne 0x14008d801
lea r8, str.SELECT_INSERT_INTO_vacuum_db.__quote_name____SELECT__FROM_main.__quote_name_____FROM_vacuum_db.sqlite_master_WHERE_namesqlite_sequence_
mov rdx, rbp
mov rcx, rsi
call fcn.14008d2e0
mov edi, eax
test eax, eax
jne 0x14008d801
lea r8, str.INSERT_INTO_vacuum_db.sqlite_master___SELECT_type__name__tbl_name__rootpage__sql____FROM_main.sqlite_master___WHERE_typeview_OR_typetrigger______OR__typetable_AND_rootpage0_
mov rdx, rbp
mov rcx, rsi
call fcn.14008d210
mov edi, eax
test eax, eax
jne 0x14008d801
xor ebx, ebx
lea rbp, [0x1401147b0]
movzx edx, byte [rbx + rbp]
lea r8, [rsp + 0x78]
mov rcx, r12
call fcn.140040c20
movzx r8d, byte [rbx + rbp + 1]
movzx edx, byte [rbx + rbp]
add r8d, dword [rsp + 0x78]
mov rcx, r14
call fcn.140040cc0
mov edi, eax
test eax, eax
jne 0x14008d801
add rbx, 2
cmp rbx, 8
jl 0x14008d773
mov rdx, r14
mov rcx, r12
call fcn.1400441b0
mov edi, eax
test eax, eax
jne 0x14008d801
mov rcx, r14
call fcn.140039e40
mov edi, eax
test eax, eax
jne 0x14008d801
mov rcx, r14
call fcn.1400382a0
mov rcx, r12
mov edx, eax
call fcn.140038210
mov r11, qword [r14 + 8]
mov r8d, dword [rsp + 0x80]
mov edx, dword [r11 + 0x34]
lea r9d, [rdi + 1]
mov rcx, r12
call fcn.140038040
mov edi, eax
jmp 0x14008d801
mov edi, 7
mov r14, qword [rsp + 0x38]
mov eax, dword [rsp + 0x88]
or r8d, 0xffffffff
mov r9d, 1
mov dword [rsi + 0x18], eax
mov eax, dword [rsp + 0x20]
or edx, r8d
mov dword [rsi + 0x4c], eax
mov eax, dword [rsp + 0x24]
mov rcx, r12
mov dword [rsi + 0x50], eax
mov rax, qword [rsp + 0x28]
mov qword [rsi + 0xc0], rax
call fcn.140038040
mov r15, qword [rsp + 0x30]
mov r12, qword [rsp + 0x40]
mov rbx, qword [rsp + 0x70]
mov byte [rsi + 0x28], 1
test r13, r13
je 0x14008d870
mov rcx, qword [r13 + 8]
call fcn.140037df0
mov qword [r13 + 8], 0
mov qword [r13 + 0x18], 0
or edx, 0xffffffff
mov rcx, rsi
call fcn.140062500
mov eax, edi
mov rdi, qword [rsp + 0x48]
add rsp, 0x50
pop r13
pop rsi
pop rbp
ret