Function at 0x180150fc0
Capabilities:
Reference sql statements

Disassembly:
mov qword [rsp + 0x20], r9
mov dword [rsp + 0x18], r8d
push rbx
push rsi
push rdi
push r13
push r14
sub rsp, 0x80
xor r10d, r10d
mov dword [rsp + 0x30], 1
mov r14, r9
mov rbx, rdx
mov rsi, rcx
mov r13d, r10d
cmp byte [rdx + 0x65], r10b
jne 0x180151052
lea edx, [r10 + 0x28]
mov rcx, rbx
call fcn.18010d770
mov rdi, rax
test rax, rax
je 0x18015102b
movups xmm0, xmmword [str.cannot_VACUUM_from_within_a_transaction]
movups xmmword [rax], xmm0
movups xmm1, xmmword [0x18024da40]
movups xmmword [rax + 0x10], xmm1
movsd xmm0, qword [0x18024da50]
movsd qword [rax + 0x20], xmm0
mov rdx, qword [rsi]
test rdx, rdx
je 0x18015103b
mov rcx, rbx
call fcn.18010d580
mov qword [rsi], rdi
mov eax, 1
add rsp, 0x80
pop r14
pop r13
pop rdi
pop rsi
pop rbx
ret
cmp dword [rdx + 0xd8], 1
jle 0x1801510ce
mov edx, 0x2b
mov rcx, rbx
call fcn.18010d770
mov rdi, rax
test rax, rax
je 0x1801510a7
movups xmm0, xmmword [str.cannot_VACUUM___SQL_statements_in_progress]
movups xmmword [rax], xmm0
movups xmm1, xmmword [0x18024da70]
movups xmmword [rax + 0x10], xmm1
movsd xmm0, qword [0x18024da80]
movsd qword [rax + 0x20], xmm0
movzx eax, word [0x18024da88]
mov word [rdi + 0x28], ax
movzx eax, byte [0x18024da8a]
mov byte [rdi + 0x2a], al
mov rdx, qword [rsi]
test rdx, rdx
je 0x18015103b
mov rcx, rbx
call fcn.18010d580
mov eax, 1
mov qword [rsi], rdi
add rsp, 0x80
pop r14
pop r13
pop rdi
pop rsi
pop rbx
ret
mov qword [rsp + 0xb0], rbp
mov ebp, dword [rdx + 0x4c]
lea rdx, [0x180000000]
test r14, r14
je 0x18015119d
movzx ecx, word [r9 + 0x14]
mov eax, ecx
and eax, 0x3f
cmp byte [rax + rdx + 0x23cbe0], 3
je 0x180151144
mov edx, 0x12
mov rcx, rbx
call fcn.18010d770
mov rdi, rax
test rax, rax
je 0x180151127
movups xmm0, xmmword [str.non_text_filename]
movups xmmword [rax], xmm0
movzx ecx, word [0x18024daa8]
mov word [rax + 0x10], cx
mov rdx, qword [rsi]
test rdx, rdx
je 0x180151137
mov rcx, rbx
call fcn.18010d580
mov qword [rsi], rdi
mov eax, 1
jmp 0x1801517b1
mov edx, 0x202
movzx eax, cx
and ax, dx
cmp ax, dx
jne 0x180151169
cmp byte [r9 + 0x16], 1
jne 0x180151169
mov r9, qword [r9 + 8]
and dword [rbx + 0x4c], 0xfffffffe
or dword [rbx + 0x4c], 6
jmp 0x1801511a4
test cl, 1
je 0x18015117b
and dword [rbx + 0x4c], 0xfffffffe
mov r9, r10
or dword [rbx + 0x4c], 6
jmp 0x1801511a4
mov dl, 1
mov rcx, r14
call fcn.180188de0
and dword [rbx + 0x4c], 0xfffffffe
xor r10d, r10d
or dword [rbx + 0x4c], 6
mov r9, rax
mov r8d, dword [rsp + 0xc0]
jmp 0x1801511a4
lea r9, [0x180238455]
mov eax, dword [rbx + 0x2c]
mov rcx, qword [rbx + 0x30]
mov rdx, qword [rbx + 0x78]
mov dword [rsp + 0x38], eax
or eax, 6
mov dword [rbx + 0x2c], eax
mov rax, rcx
mov qword [rsp + 0x58], rcx
movabs rcx, 0xfffffffeefffafff
and rax, rcx
mov qword [rsp + 0x60], rdx
mov rdx, qword [rbx + 0x80]
or rax, 0x201
mov qword [rbx + 0x30], rax
mov rax, qword [rbx + 0x20]
mov qword [rsp + 0x78], r12
mov qword [rsp + 0x68], rdx
movzx edx, byte [rbx + 0x6e]
mov byte [rbx + 0x6e], r13b
mov qword [rsp + 0x70], r15
movsxd r15, r8d
mov rcx, r15
mov byte [rsp + 0xb8], dl
shl rcx, 5
mov qword [rsp + 0x50], rcx
mov rdx, qword [rcx + rax]
mov r12, qword [rcx + rax + 8]
mov qword [rsp + 0x48], rdx
mov rax, qword [r12 + 8]
mov rcx, qword [rax]
cmp byte [rcx + 0x10], r13b
jne 0x18015123c
mov dword [rsp + 0x28], r10d
cmp byte [rcx + 0x14], r13b
je 0x180151244
mov dword [rsp + 0x28], 1
mov eax, dword [rbx + 0x28]
lea r8, str.ATTACH__Q_AS_vacuum_db
mov rdx, rsi
mov dword [rsp + 0x2c], eax
mov rcx, rbx
call fcn.18006c410
mov dword [rbx + 0x4c], ebp
mov edi, eax
test eax, eax
jne 0x18015170c
movsxd rax, dword [rsp + 0x2c]
mov rdx, qword [rbx + 0x20]
shl rax, 5
add rax, rdx
mov qword [rsp + 0x20], rax
mov r13, qword [rax + 8]
mov qword [rsp + 0x40], r13
test r14, r14
je 0x180151341
mov rax, qword [r13 + 8]
mov rcx, qword [rax]
mov rcx, qword [rcx + 0x48]
mov qword [rsp + 0x30], 0
mov rax, qword [rcx]
test rax, rax
je 0x1801512c9
lea rdx, [rsp + 0x30]
call qword [rax + 0x30]
test eax, eax
jne 0x1801512e5
cmp qword [rsp + 0x30], 0
jg 0x1801512e5
movsxd r15, dword [rsp + 0xc0]
mov rax, qword [rsp + 0x50]
or dword [rbx + 0x2c], 8
mov rdx, qword [rbx + 0x20]
movzx edi, byte [rax + rdx + 0x10]
mov eax, dword [rbx + 0x30]
and eax, 0x38
or edi, eax
jmp 0x180151345
mov edi, 1
mov rcx, rbx
lea edx, [rdi + 0x1a]
call fcn.18010d770
mov rbp, rax
test rax, rax
je 0x180151329
movups xmm0, xmmword [str.output_file_already_exists]
movups xmmword [rax], xmm0
movsd xmm0, qword [0x18024dae0]
movsd qword [rax + 0x10], xmm0
movzx ecx, word [0x18024dae8]
mov word [rax + 0x18], cx
movzx eax, byte [0x18024daea]
mov byte [rbp + 0x1a], al
mov rdx, qword [rsi]
test rdx, rdx
je 0x180151339
mov rcx, rbx
call fcn.18010d580
mov qword [rsi], rbp
jmp 0x180151707
mov edi, dword [rsp + 0x30]
mov rax, qword [r12 + 8]
movzx ecx, byte [rax + 0x26]
mov ebp, dword [rax + 0x34]
sub ebp, dword [rax + 0x38]
cmp ecx, ebp
cmovg ebp, ecx
shl r15, 5
mov rcx, r13
mov rdx, qword [r15 + rdx + 0x18]
mov edx, dword [rdx + 0x74]
call fcn.180105e10
mov rax, qword [r12 + 8]
mov rcx, qword [rax]
mov r9, qword [rcx + 0x120]
movsxd r8, dword [r9 + 0x20]
test r8d, r8d
jns 0x1801513ae
mov eax, dword [r9 + 0x2c]
add eax, dword [r9 + 0x28]
movsxd rcx, eax
mov rax, r8
neg rax
shl rax, 0xa
cqo
idiv rcx
mov r8, rax
mov eax, 0x3b9aca00
cmp r8, rax
cmovg r8, rax
mov edx, dword [r9 + 0x24]
mov rcx, r13
cmp r8d, edx
cmovge edx, r8d
call fcn.180105f50
mov rcx, qword [r13 + 8]
or edi, 0x20
mov edx, edi
mov rcx, qword [rcx]
call fcn.180143e00
lea r8, str.BEGIN
mov rdx, rsi
mov rcx, rbx
call fcn.18006c150
mov edi, eax
test eax, eax
jne 0x180151707
xor edx, edx
mov eax, 2
test r14, r14
cmove edx, eax
cmp byte [r12 + 0x11], dil
jne 0x180151415
movzx eax, byte [r12 + 0x10]
test al, al
je 0x180151415
cmp al, 1
jne 0x180151443
test r14, r14
jne 0x18015142a
xor r8d, r8d
mov rcx, r12
call fcn.18005d470
mov edi, eax
test edi, edi
jne 0x180151707
mov rax, qword [r12 + 8]
mov rcx, qword [rax]
cmp byte [rcx + 9], 5
jne 0x180151473
test r14, r14
jne 0x180151473
mov dword [rbx + 0x74], r14d
jmp 0x180151476
test r14, r14
jne 0x18015142a
mov rax, qword [r12]
mov edx, dword [rax + 0x2d0]
mov rax, qword [r12 + 8]
mov rcx, qword [rax]
cmp edx, dword [rcx + 0x80]
jle 0x18015146f
cmp byte [rcx + 0xa], r14b
je 0x18015146f
call fcn.1800e20f0
jmp 0x180151420
xor edi, edi
jmp 0x180151422
xor r14d, r14d
mov rax, qword [r12 + 8]
xor r9d, r9d
mov r8d, ebp
mov rcx, r13
mov edx, dword [rax + 0x34]
call fcn.180105e80
test eax, eax
jne 0x180151702
cmp dword [rsp + 0x28], eax
jne 0x18015150e
mov rdi, qword [r13 + 8]
mov ecx, dword [rbx + 0x74]
mov eax, dword [rdi + 0x34]
sub eax, dword [rdi + 0x38]
cmp ebp, eax
mov byte [rdi + 0x26], bpl
cmovl ebp, eax
test byte [rdi + 0x28], 2
jne 0x180151702
lea eax, [rcx - 0x200]
cmp eax, 0xfe00
ja 0x1801514ec
lea eax, [rcx - 1]
test ecx, eax
jne 0x1801514ec
cmp ebp, 0x20
jle 0x1801514e1
cmp ecx, 0x200
mov eax, 0x400
cmove ecx, eax
mov dword [rdi + 0x34], ecx
mov rcx, rdi
call fcn.180079a80
mov rcx, qword [rdi]
lea rdx, [rdi + 0x34]
mov r8d, ebp
call fcn.1801440c0
mov edx, dword [rdi + 0x34]
movzx ecx, bp
sub edx, ecx
mov dword [rdi + 0x38], edx
test eax, eax
jne 0x180151702
cmp byte [rbx + 0x67], 0
jne 0x180151702
movsx eax, byte [rbx + 0x6a]
test al, al
js 0x180151524
mov edx, eax
jmp 0x18015153b
mov rax, qword [r12 + 8]
mov edx, r14d
cmp byte [rax + 0x21], 0
je 0x18015153b
cmp byte [rax + 0x22], 0
setne dl
inc edx
mov rcx, r13
call fcn.180105dc0
mov eax, dword [rsp + 0x2c]
lea r8, str.SELECT_sql_FROM___w_.sqlite_schema_WHERE_typetableAND_name__sqlite_sequence_AND_coalesce_rootpage_1__0
mov rbp, qword [rsp + 0x48]
mov rdx, rsi
mov r9, rbp
mov byte [rbx + 0xc4], al
mov rcx, rbx
call fcn.18006c410
mov edi, eax
test eax, eax
jne 0x180151707
mov r9, rbp
lea r8, str.SELECT_sql_FROM___w_.sqlite_schema_WHERE_typeindex
mov rdx, rsi
mov rcx, rbx
call fcn.18006c410
mov edi, eax
test eax, eax
jne 0x180151707
mov r9, rbp
mov byte [rbx + 0xc4], al
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 rdx, rsi
mov rcx, rbx
call fcn.18006c410
and dword [rbx + 0x2c], 0xfffffffb
mov edi, eax
test eax, eax
jne 0x180151707
mov r9, rbp
lea r8, str.INSERT_INTO_vacuum_db.sqlite_schema_SELECTFROM___w_.sqlite_schema_WHERE_type_IN_view_trigger__OR_typetableAND_rootpage0_
mov rdx, rsi
mov rcx, rbx
call fcn.18006c410
mov edi, eax
test eax, eax
jne 0x180151707
mov rsi, r14
nop dword [rax + rax]
mov rcx, qword [r12 + 8]
lea r8, [0x180000000]
movzx r15d, byte [rsi + r8 + 0x23ce48]
cmp r15d, 0xf
jne 0x18015160b
mov rax, qword [rcx]
mov ecx, dword [rax + 0x84]
add ecx, dword [r12 + 0x1c]
jmp 0x180151620
mov rax, qword [rcx + 0x18]
lea edx, [r15*4 + 0x24]
mov rcx, qword [rax + 0x50]
mov ecx, dword [rdx + rcx]
bswap ecx
mov r13, qword [r13 + 8]
movzx ebp, byte [rsi + r8 + 0x23ce49]
add ebp, ecx
mov rcx, qword [r13 + 0x18]
mov rax, qword [rcx + 0x50]
mov rcx, qword [rcx + 0x70]
mov qword [rsp + 0x48], rax
call fcn.1801447e0
mov edi, eax
test eax, eax
jne 0x18015166b
mov rax, qword [rsp + 0x48]
mov edx, ebp
lea ecx, [r15*4 + 0x24]
bswap edx
mov dword [rcx + rax], edx
cmp r15d, 7
jne 0x18015166b
mov byte [r13 + 0x22], bpl
jmp 0x180151673
test edi, edi
jne 0x180151707
mov r13, qword [rsp + 0x40]
add rsi, 2
cmp rsi, 0xa
jl 0x1801515e0
mov rsi, qword [rsp + 0xc8]
mov rbp, r13
test rsi, rsi
jne 0x1801516a7
mov rdx, r13
mov rcx, r12
call fcn.180103300
mov edi, eax
test eax, eax
jne 0x180151707
mov rcx, rbp
call fcn.180103150
mov edi, eax
test eax, eax
jne 0x180151707
test rsi, rsi
jne 0x180151707
mov rax, qword [rbp + 8]
xor edx, edx
cmp byte [rax + 0x21], dl
je 0x1801516cd
cmp byte [rax + 0x22], dl
setne dl
inc edx
mov rcx, r12
call fcn.180105dc0
mov r10, qword [rbp + 8]
mov r9d, 1
mov rcx, r12
movzx eax, byte [r10 + 0x26]
mov edx, dword [r10 + 0x34]
mov r8d, edx
sub r8d, dword [r10 + 0x38]
cmp eax, r8d
cmovg r8d, eax
call fcn.180105e80
mov edi, eax
jmp 0x180151707
mov edi, 7
mov r13, qword [rsp + 0x20]
mov eax, dword [rsp + 0x38]
mov r15, qword [rsp + 0x70]
mov dword [rbx + 0x2c], eax
mov rax, qword [rsp + 0x58]
mov qword [rbx + 0x30], rax
mov rax, qword [rsp + 0x60]
mov qword [rbx + 0x78], rax
mov rax, qword [rsp + 0x68]
mov qword [rbx + 0x80], rax
movzx eax, byte [rsp + 0xb8]
mov byte [rbx + 0x6e], al
mov byte [rbx + 0xc4], 0
mov rsi, qword [r12 + 8]
mov r12d, 0
mov ebp, dword [rsi + 0x34]
sub ebp, dword [rsi + 0x38]
test ebp, ebp
mov byte [rsi + 0x26], 0
cmovle ebp, r12d
test byte [rsi + 0x28], 2
jne 0x180151788
mov rcx, qword [rsi]
lea rdx, [rsi + 0x34]
mov r8d, ebp
call fcn.1801440c0
mov ecx, dword [rsi + 0x34]
movzx eax, bp
sub ecx, eax
or word [rsi + 0x28], 2
mov dword [rsi + 0x38], ecx
mov byte [rbx + 0x65], 1
test r13, r13
je 0x1801517a2
mov rcx, qword [r13 + 8]
call fcn.180102d50
mov qword [r13 + 8], r12
mov qword [r13 + 0x18], r12
mov rcx, rbx
call fcn.18014f280
mov r12, qword [rsp + 0x78]
mov eax, edi
mov rbp, qword [rsp + 0xb0]
add rsp, 0x80
pop r14
pop r13
pop rdi
pop rsi
pop rbx
ret