Function at 0x1400ccbe0
Capabilities:
Reference sql statements

Disassembly:
push rdi
push r13
push r15
sub rsp, 0x50
xor r13d, r13d
mov r15, rdx
mov rdi, rcx
cmp byte [rdx + 0x44], r13b
jne 0x1400ccc13
lea r8, str.cannot_VACUUM_from_within_a_transaction
call fcn.140061780
lea eax, [r13 + 1]
add rsp, 0x50
pop r15
pop r13
pop rdi
ret
cmp dword [rdx + 0x90], 1
jle 0x1400ccc37
lea r8, str.cannot_VACUUM___SQL_statements_in_progress
call fcn.140061780
mov eax, 1
add rsp, 0x50
pop r15
pop r13
pop rdi
ret
mov eax, dword [rdx + 0x2c]
lea r8, str.ATTACH_:memory:_AS_vacuum_db_
mov ecx, dword [rdx + 0x54]
mov dword [rsp + 0x80], eax
and eax, 0xfaffffff
or eax, 0x10050000
mov dword [rsp + 0x88], ecx
mov ecx, dword [rdx + 0x58]
cmp byte [rdx + 0x45], 2
mov dword [rdx + 0x2c], eax
mov rax, qword [rdx + 0x20]
mov qword [rsp + 0x70], rbx
mov ebx, dword [rdx + 0x28]
mov dword [rsp + 0x20], ecx
mov rcx, qword [rdx + 0xa8]
mov qword [rdx + 0xa8], r13
mov rdx, rdi
mov qword [rsp + 0x48], rbp
mov qword [rsp + 0x40], rsi
mov rsi, qword [rax + 8]
mov qword [rsp + 0x28], rcx
mov qword [rsp + 0x38], r12
mov qword [rsp + 0x30], r14
mov rax, qword [rsi + 8]
mov rcx, qword [rax]
lea rax, str.ATTACH__AS_vacuum_db_
cmovne r8, rax
movzx r12d, byte [rcx + 0x12]
mov rcx, r15
call fcn.1400cc8f0
mov ebp, eax
movsxd rax, dword [r15 + 0x28]
cmp eax, ebx
jle 0x1400cccdb
lea ecx, [rax - 1]
movsxd r13, ecx
shl r13, 5
add r13, qword [r15 + 0x20]
test ebp, ebp
jne 0x1400cd095
mov rcx, rax
mov rax, qword [r15 + 0x20]
shl rcx, 5
mov r14, qword [rcx + rax - 0x18]
mov rcx, r14
call fcn.1400743d0
xor edx, edx
mov rcx, r14
call fcn.140077a30
test eax, eax
jne 0x1400ccd13
xor edx, edx
mov rcx, r14
call fcn.140077ce0
cmp byte [r14 + 0x11], 0
je 0x1400ccd39
sub dword [r14 + 0x14], 1
jne 0x1400ccd39
mov rax, qword [r14 + 8]
mov rcx, qword [rax + 0x50]
test rcx, rcx
je 0x1400ccd34
call qword [0x1401194c0]
mov byte [r14 + 0x12], 0
mov rcx, rsi
call fcn.1400743d0
mov rax, qword [rsi + 8]
mov ebx, dword [rax + 0x30]
sub ebx, dword [rax + 0x34]
cmp byte [rsi + 0x11], 0
mov dword [rsp + 0x78], ebx
je 0x1400ccd6e
sub dword [rsi + 0x14], 1
jne 0x1400ccd6e
mov rcx, qword [rax + 0x50]
test rcx, rcx
je 0x1400ccd6a
call qword [0x1401194c0]
mov byte [rsi + 0x12], 0
lea r8, str.PRAGMA_vacuum_db.synchronousOFF
mov rdx, rdi
mov rcx, r15
call fcn.1400cc8f0
mov ebp, eax
test eax, eax
jne 0x1400cd095
lea r8, str.BEGIN_
mov rdx, rdi
mov rcx, r15
call fcn.1400cc8f0
mov ebp, eax
test eax, eax
jne 0x1400cd095
lea edx, [rax + 2]
mov rcx, rsi
call fcn.140076910
mov ebp, eax
test eax, eax
jne 0x1400cd095
mov rax, qword [rsi + 8]
mov rcx, qword [rax]
cmp byte [rcx + 9], 5
jne 0x1400ccdcc
mov dword [r15 + 0x4c], ebp
mov rax, qword [rsi + 8]
xor r9d, r9d
mov r8d, ebx
mov rcx, r14
mov edx, dword [rax + 0x30]
call fcn.1400762a0
test eax, eax
jne 0x1400cd090
test r12b, r12b
jne 0x1400cce08
mov edx, dword [r15 + 0x4c]
xor r9d, r9d
mov r8d, ebx
mov rcx, r14
call fcn.1400762a0
test eax, eax
jne 0x1400cd090
cmp byte [r15 + 0x46], 0
jne 0x1400cd090
movsx eax, byte [r15 + 0x48]
test al, al
js 0x1400cce20
mov ebx, eax
jmp 0x1400cce5a
mov rcx, rsi
call fcn.1400743d0
mov rax, qword [rsi + 8]
xor ebx, ebx
cmp byte [rax + 0x21], bl
je 0x1400cce3b
cmp byte [rax + 0x22], bl
setne bl
inc ebx
cmp byte [rsi + 0x11], 0
je 0x1400cce5a
sub dword [rsi + 0x14], 1
jne 0x1400cce5a
mov rcx, qword [rax + 0x50]
test rcx, rcx
je 0x1400cce56
call qword [0x1401194c0]
mov byte [rsi + 0x12], 0
mov edx, ebx
mov rcx, r14
call fcn.140076400
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, rdi
mov rcx, r15
call fcn.1400cca10
mov ebp, eax
test eax, eax
jne 0x1400cd095
lea r8, str.SELECT_CREATE_INDEX_vacuum_db.__substr_sql_14___FROM_sqlite_master_WHERE_sql_LIKE_CREATE_INDEX__
mov rdx, rdi
mov rcx, r15
call fcn.1400cca10
mov ebp, eax
test eax, eax
jne 0x1400cd095
lea r8, str.SELECT_CREATE_UNIQUE_INDEX_vacuum_db.__substr_sql_21____FROM_sqlite_master_WHERE_sql_LIKE_CREATE_UNIQUE_INDEX__
mov rdx, rdi
mov rcx, r15
call fcn.1400cca10
mov ebp, eax
test eax, eax
jne 0x1400cd095
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, rdi
mov rcx, r15
call fcn.1400cca10
mov ebp, eax
test eax, eax
jne 0x1400cd095
lea r8, str.SELECT_DELETE_FROM_vacuum_db.__quote_name_____FROM_vacuum_db.sqlite_master_WHERE_namesqlite_sequence
mov rdx, rdi
mov rcx, r15
call fcn.1400cca10
mov ebp, eax
test eax, eax
jne 0x1400cd095
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, rdi
mov rcx, r15
call fcn.1400cca10
mov ebp, eax
test eax, eax
jne 0x1400cd095
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, rdi
mov rcx, r15
call fcn.1400cc8f0
mov ebp, eax
test eax, eax
jne 0x1400cd095
xor r12d, r12d
lea rbp, [0x1400f8548]
movzx ebx, byte [r12 + rbp]
mov rcx, rsi
mov rdi, qword [rsi + 8]
call fcn.1400743d0
mov rax, qword [rdi + 0x18]
mov edx, ebx
mov rcx, qword [rax + 0x50]
movzx ebx, byte [rcx + rbx*4 + 0x24]
movzx eax, byte [rcx + rdx*4 + 0x25]
shl ebx, 8
or ebx, eax
movzx eax, byte [rcx + rdx*4 + 0x26]
shl ebx, 8
or ebx, eax
movzx eax, byte [rcx + rdx*4 + 0x27]
shl ebx, 8
or ebx, eax
cmp byte [rsi + 0x11], 0
je 0x1400ccf93
sub dword [rsi + 0x14], 1
jne 0x1400ccf93
mov rax, qword [rsi + 8]
mov rcx, qword [rax + 0x50]
test rcx, rcx
je 0x1400ccf8f
call qword [0x1401194c0]
mov byte [rsi + 0x12], 0
movzx r8d, byte [r12 + rbp + 1]
mov rcx, r14
movzx edx, byte [r12 + rbp]
add r8d, ebx
call fcn.14007de40
mov ebp, eax
test eax, eax
jne 0x1400cd095
add r12, 2
lea rbp, [0x1400f8548]
cmp r12, 8
jl 0x1400ccf32
mov rdx, r14
mov rcx, rsi
call fcn.1400804c0
mov ebp, eax
test eax, eax
jne 0x1400cd095
mov rcx, r14
call fcn.1400743d0
xor edx, edx
mov rcx, r14
call fcn.140077a30
mov ebp, eax
test eax, eax
jne 0x1400cd001
xor edx, edx
mov rcx, r14
call fcn.140077ce0
mov ebp, eax
cmp byte [r14 + 0x11], 0
je 0x1400cd027
sub dword [r14 + 0x14], 1
jne 0x1400cd027
mov rax, qword [r14 + 8]
mov rcx, qword [rax + 0x50]
test rcx, rcx
je 0x1400cd022
call qword [0x1401194c0]
mov byte [r14 + 0x12], 0
test ebp, ebp
jne 0x1400cd095
mov rcx, r14
call fcn.1400743d0
mov rax, qword [r14 + 8]
xor ebx, ebx
cmp byte [rax + 0x21], bl
je 0x1400cd046
cmp byte [rax + 0x22], bl
setne bl
inc ebx
cmp byte [r14 + 0x11], 0
je 0x1400cd068
sub dword [r14 + 0x14], 1
jne 0x1400cd068
mov rcx, qword [rax + 0x50]
test rcx, rcx
je 0x1400cd063
call qword [0x1401194c0]
mov byte [r14 + 0x12], 0
mov edx, ebx
mov rcx, rsi
call fcn.140076400
mov rax, qword [r14 + 8]
mov r9d, 1
mov r8d, dword [rsp + 0x78]
mov rcx, rsi
mov edx, dword [rax + 0x30]
call fcn.1400762a0
mov ebp, eax
jmp 0x1400cd095
mov ebp, 7
mov eax, dword [rsp + 0x80]
mov rcx, rsi
mov dword [r15 + 0x2c], eax
mov eax, dword [rsp + 0x88]
mov dword [r15 + 0x54], eax
mov eax, dword [rsp + 0x20]
mov dword [r15 + 0x58], eax
mov rax, qword [rsp + 0x28]
mov qword [r15 + 0xa8], rax
mov r14, qword [rsi + 8]
call fcn.1400743d0
test byte [r14 + 0x26], 2
mov r12, qword [rsp + 0x38]
jne 0x1400cd101
mov ebx, dword [r14 + 0x30]
lea rdx, [r14 + 0x30]
sub ebx, dword [r14 + 0x34]
mov rcx, qword [r14]
mov r8d, ebx
call fcn.14006e3c0
mov ecx, dword [r14 + 0x30]
movzx eax, bx
sub ecx, eax
or word [r14 + 0x26], 2
mov dword [r14 + 0x34], ecx
cmp byte [rsi + 0x11], 0
je 0x1400cd124
sub dword [rsi + 0x14], 1
jne 0x1400cd124
mov rax, qword [rsi + 8]
mov rcx, qword [rax + 0x50]
test rcx, rcx
je 0x1400cd120
call qword [0x1401194c0]
mov byte [rsi + 0x12], 0
mov r14, qword [rsp + 0x30]
mov rsi, qword [rsp + 0x40]
mov rbx, qword [rsp + 0x70]
mov byte [r15 + 0x44], 1
test r13, r13
je 0x1400cd150
mov rcx, qword [r13 + 8]
call fcn.140076050
xor eax, eax
mov qword [r13 + 8], rax
mov qword [r13 + 0x18], rax
mov rcx, r15
call fcn.1400a3250
mov eax, ebp
mov rbp, qword [rsp + 0x48]
add rsp, 0x50
pop r15
pop r13
pop rdi
ret