Function at 0x140100970
Capabilities:
Reference sql statements

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0xe8
lea rsi, [0x14016b960]
mov rbp, qword [rsp + 0x158]
lea eax, [r8 - 6]
mov qword [rsp + 0x130], rcx
mov r14, rdx
mov ecx, 0xa
cmp eax, 0x61
mov r13d, r8d
mov r12, r9
lea rdi, [rsp + 0x78]
rep movsd dword [rdi], dword [rsi]
jbe 0x1401009e6
lea rcx, [0x1401968f0]
xor eax, eax
cmp r8d, 6
setge al
mov r15d, 1
add eax, 2
cdqe
mov rdx, qword [rsp + rax*8 + 0x78]
call fcn.140151f20
mov qword [rbp], rax
jmp 0x1401011f9
mov rcx, qword [rsp + 0x130]
mov r8d, 1
mov edx, 1
mov r15d, 7
call fcn.140156d70
mov rcx, qword [rsp + 0x130]
mov edx, 2
call fcn.140156d70
mov rcx, qword [r12 + 8]
call sub.api_ms_win_crt_string_l1_1_0.dll_strlen
mov rcx, qword [r12 + 0x10]
mov rbx, rax
call sub.api_ms_win_crt_string_l1_1_0.dll_strlen
movsxd rdx, ebx
mov rsi, rax
mov qword [rsp + 0x60], rdx
lea eax, [rax + rax]
cdqe
lea rcx, [rdx + rax + 0x3d0]
mov qword [rsp + 0x58], rcx
call fcn.140151e80
test rax, rax
mov rbx, rax
je 0x1401011f9
mov rcx, qword [rsp + 0x58]
lea r11, [rbx + 0x3c8]
test r14, r14
mov rdi, rbx
mov rdx, qword [rsp + 0x60]
setne r10b
setne r14b
xor eax, eax
movzx r14d, r14b
rep stosb byte [rdi], al
lea rax, [0x14016efe0]
mov qword [rbx + 0x30], r11
mov rdi, r11
lea r9, [r11 + rdx + 1]
mov qword [rbx], rax
movsxd rax, esi
lea rcx, [r9 + rax + 1]
mov byte [rbx + 0x26], r10b
mov qword [rbx + 0x40], rcx
mov rcx, rdx
mov qword [rbx + 0x38], r9
mov rsi, qword [r12 + 8]
mov dword [rbx + 0x48], 1
rep movsb byte [rdi], byte [rsi]
mov rdi, r9
mov rcx, rax
mov rsi, qword [r12 + 0x10]
rep movsb byte [rdi], byte [rsi]
mov rcx, rax
mov rsi, qword [r12 + 0x10]
mov rdi, qword [rbx + 0x40]
rep movsb byte [rdi], byte [rsi]
mov rcx, qword [rsp + 0x130]
mov edi, 4
lea rsi, str.__.s_REAL
add rax, qword [rbx + 0x40]
mov dword [rax], 0x646f6e5f
mov word [rax + 4], 0x65
call fcn.1401545b0
mov r9, qword [r12 + 0x18]
mov r15, rax
xor eax, eax
mov dword [rsp + 0xa0], eax
lea rax, [rsp + 0xa0]
mov rdx, rax
mov qword [rsp + 0x68], rax
mov rcx, r9
mov qword [rsp + 0x58], r9
call fcn.140124bb0
mov r9, qword [rsp + 0x58]
lea rdx, str.CREATE_TABLE_x__.s_INT
mov rcx, r15
mov r8d, eax
call fcn.140154520
mov r9, qword [r12 + rdi*8]
mov al, byte [rbx + 0x29]
cmp byte [r9], 0x2b
jne 0x140100b87
mov rdx, qword [rsp + 0x68]
inc r9
inc eax
mov byte [rbx + 0x29], al
mov rcx, r9
xor eax, eax
mov qword [rsp + 0x58], r9
mov dword [rsp + 0xa0], eax
call fcn.140124bb0
mov r9, qword [rsp + 0x58]
lea rdx, str.__.s
mov r8d, eax
jmp 0x140100bb7
test al, al
jne 0x140100bd6
mov rdx, qword [rsp + 0x68]
xor r11d, r11d
mov rcx, r9
mov qword [rsp + 0x58], r9
inc byte [rbx + 0x25]
mov dword [rsp + 0xa0], r11d
call fcn.140124bb0
mov rdx, qword [rsi + r14*8]
mov r9, qword [rsp + 0x58]
mov r8d, eax
mov rcx, r15
call fcn.140154520
lea rax, [rdi + 1]
cmp r13d, eax
jle 0x140100bd0
mov rdi, rax
jmp 0x140100b46
lea r14d, [rdi + 1]
jmp 0x140100bd9
mov r14d, edi
lea rdx, [0x14019e3ff]
mov rcx, r15
mov esi, 7
call fcn.140154520
mov rcx, r15
call fcn.140154560
test rax, rax
mov rdi, rax
je 0x140100c56
cmp r13d, r14d
jle 0x140100c20
lea rdx, str.Auxiliary_rtree_columns_must_be_last
mov esi, 1
lea rcx, [0x1401968f0]
call fcn.140151f20
mov qword [rbp], rax
jmp 0x140100c56
mov rcx, qword [rsp + 0x130]
mov rdx, rax
call fcn.1401501b0
test eax, eax
mov esi, eax
je 0x140100c56
mov rcx, qword [rsp + 0x130]
call fcn.140150720
lea rcx, [0x1401968f0]
mov rdx, rax
call fcn.140151f20
mov qword [rbp], rax
mov rcx, rdi
call fcn.140150f20
test esi, esi
jne 0x1401011ee
mov al, byte [rbx + 0x25]
mov edx, eax
shr dl, 1
cmp al, 1
mov byte [rbx + 0x24], dl
jbe 0x140100d8c
cmp al, 0xa
ja 0x140100d93
test al, 1
mov edx, 1
jne 0x140100d98
cmp dword [rsp + 0x160], 0
lea eax, [rax*4 + 8]
mov rdx, qword [rbx + 0x30]
mov byte [rbx + 0x27], al
je 0x140100cfd
lea rcx, str.PRAGMA__Q.page_size
xor r10d, r10d
mov dword [rsp + 0xa0], r10d
call fcn.140151f20
test rax, rax
mov rdi, rax
je 0x140100d31
mov r8, qword [rsp + 0x68]
mov rdx, rax
mov rcx, qword [rsp + 0x130]
call fcn.1400e73b0
test eax, eax
mov esi, eax
jne 0x140100d36
mov eax, dword [rsp + 0xa0]
lea edx, [rax - 0x40]
movzx eax, byte [rbx + 0x27]
imul eax, eax, 0x33
add eax, 4
cmp eax, edx
cmovg eax, edx
mov dword [rbx + 0x20], eax
jmp 0x140100d7a
mov r8, qword [rbx + 0x38]
lea rcx, str.SELECT_length_data__FROM__q._q_node_WHERE_nodeno__1
call fcn.140151f20
test rax, rax
mov rdi, rax
je 0x140100d31
mov rcx, qword [rsp + 0x130]
lea r8, [rbx + 0x20]
mov rdx, rax
call fcn.1400e73b0
test eax, eax
mov esi, eax
je 0x140100d58
jmp 0x140100d36
mov esi, 7
mov rcx, qword [rsp + 0x130]
call fcn.140150720
lea rcx, [0x1401968f0]
mov rdx, rax
call fcn.140151f20
mov qword [rbp], rax
jmp 0x140100d7a
cmp dword [rbx + 0x20], 0x1bf
jg 0x140100d7a
mov rdx, qword [rbx + 0x38]
lea rcx, str.undersize_RTree_blobs_in___q_node_
mov esi, 0x10b
call fcn.140151f20
mov qword [rbp], rax
mov rcx, rdi
call fcn.140150f20
test esi, esi
jne 0x1401011ee
jmp 0x140100db7
mov edx, 2
jmp 0x140100d98
mov edx, 3
mov rdx, qword [rsp + rdx*8 + 0x78]
lea rcx, [0x1401968f0]
mov esi, 1
call fcn.140151f20
mov qword [rbp], rax
jmp 0x1401011ee
mov rax, qword [r12 + 0x10]
cmp dword [rsp + 0x160], 0
mov qword [rsp + 0x58], rax
mov rax, qword [r12 + 8]
mov qword [rsp + 0x60], rax
mov rax, qword [rsp + 0x130]
mov qword [rbx + 0x18], rax
je 0x140100ece
lea r14, str._a_d
mov rcx, rax
xor r15d, r15d
call fcn.1401545b0
mov r9, qword [rsp + 0x58]
lea rdx, str.CREATE_TABLE___w_.__w_rowid__rowid_INTEGER_PRIMARY_KEY_nodeno
mov r8, qword [rsp + 0x60]
mov rcx, rax
mov rdi, rax
call fcn.140154520
movzx eax, byte [rbx + 0x29]
cmp r15d, eax
jge 0x140100e2f
mov r8d, r15d
mov rdx, r14
mov rcx, rdi
call fcn.140154520
inc r15d
jmp 0x140100e13
mov r9, qword [rsp + 0x58]
mov rcx, rdi
mov r8, qword [rsp + 0x60]
lea rdx, str.__CREATE_TABLE___w_.__w_node__nodeno_INTEGER_PRIMARY_KEY_data__
call fcn.140154520
mov r9, qword [rsp + 0x58]
mov rcx, rdi
mov r8, qword [rsp + 0x60]
lea rdx, str.CREATE_TABLE___w_.__w_parent__nodeno_INTEGER_PRIMARY_KEY_parentnode__
call fcn.140154520
mov eax, dword [rbx + 0x20]
mov rcx, rdi
mov r9, qword [rsp + 0x58]
lea rdx, str.INSERT_INTO___w_.__w_node_VALUES_1_zeroblob__d__
mov r8, qword [rsp + 0x60]
mov dword [rsp + 0x20], eax
call fcn.140154520
mov rcx, rdi
call fcn.140154560
test rax, rax
mov rdi, rax
jne 0x140100e9c
mov r15d, 7
jmp 0x1401011bc
mov rcx, qword [rsp + 0x130]
xor r9d, r9d
xor r8d, r8d
mov rdx, rax
mov qword [rsp + 0x20], r9
xor r9d, r9d
call fcn.140150890
mov rcx, rdi
mov r15d, eax
call fcn.140150f20
test r15d, r15d
jne 0x1401011bc
lea rax, [rbx + 0x78]
mov rdx, qword [rbx + 0x30]
xor r8d, r8d
xor r9d, r9d
mov qword [rsp + 0xa0], rax
lea rax, [rbx + 0x80]
mov rcx, qword [rsp + 0x130]
mov qword [rsp + 0xa8], rax
lea rax, [rbx + 0x88]
mov qword [rsp + 0xb0], rax
lea rax, [rbx + 0x90]
mov qword [rsp + 0xb8], rax
lea rax, [rbx + 0x98]
mov qword [rsp + 0xc0], rax
lea rax, [rbx + 0xa0]
mov qword [rsp + 0xc8], rax
lea rax, [rbx + 0xa8]
mov qword [rsp + 0xd0], rax
lea rax, [rbx + 0xb0]
mov qword [rsp + 0x40], r8
mov qword [rsp + 0x38], r8
mov qword [rsp + 0x30], r8
mov qword [rsp + 0x28], r8
mov qword [rsp + 0x20], r8
lea r8, str.sqlite_stat1
mov qword [rsp + 0xd8], rax
call fcn.140155c10
test eax, eax
mov r15d, eax
je 0x140100f92
cmp eax, 1
jne 0x140101027
xor r15d, r15d
jmp 0x140101027
mov rdx, qword [rbx + 0x30]
lea rcx, str.SELECT_stat_FROM__Q.sqlite_stat1_WHERE_tbl___q_rowid
mov r8, qword [rbx + 0x38]
call fcn.140151f20
test rax, rax
mov r14, rax
je 0x14010100e
xor ecx, ecx
or r8d, 0xffffffff
mov rdx, rax
mov qword [rsp + 0x20], rcx
lea r9, [rsp + 0x70]
mov edi, 0x64
mov rcx, qword [rsp + 0x130]
call fcn.140152320
test eax, eax
mov r15d, eax
jne 0x140101004
mov r15, qword [rsp + 0x70]
mov rcx, r15
call fcn.1401538e0
cmp eax, 0x64
jne 0x140100ff9
xor edx, edx
mov rcx, r15
call fcn.14014ebf0
mov rdi, rax
mov rcx, r15
call fcn.140150e80
mov r15d, eax
mov rcx, r14
call fcn.140150f20
jmp 0x140101019
mov edi, 0x64
mov r15d, 7
mov eax, 0x64
cmp rdi, rax
cmovl rdi, rax
jmp 0x14010102c
mov edi, 0x100000
mov qword [rbx + 0x50], rdi
lea r14, str.INSERT_INTO__w_.__w_rowid__rowid_nodeno_VALUES__1__2_ON_CONFLICT_rowid_DO_UPDATE_SET_nodenoexcluded.nodeno
xor r12d, r12d
lea rdi, str.INSERT_OR_REPLACE_INTO__q._q_node_VALUES__1___2_
cmp r12d, 7
jg 0x1401010bb
test r15d, r15d
jne 0x1401010bb
cmp r12, 3
jne 0x14010105b
cmp byte [rbx + 0x29], 0
mov rcx, r14
jne 0x14010105f
mov rcx, qword [rdi + r12*8]
mov r8, qword [rsp + 0x58]
mov r15d, 7
mov rdx, qword [rsp + 0x60]
call fcn.140151f20
test rax, rax
mov r13, rax
je 0x1401010ae
mov rax, qword [rsp + 0x68]
xor edx, edx
mov r9d, 5
or r8d, 0xffffffff
mov qword [rsp + 0x28], rdx
mov rcx, qword [rsp + 0x130]
mov rdx, r13
mov rax, qword [rax + r12*8]
mov qword [rsp + 0x20], rax
call fcn.140152350
mov r15d, eax
mov rcx, r13
inc r12
call fcn.140150f20
jmp 0x140101041
cmp byte [rbx + 0x29], 0
je 0x1401011b7
cmp r15d, 7
je 0x140100e91
mov r8, qword [rsp + 0x58]
lea rcx, str.SELECT__FROM___w_.__w_rowid__WHERE_rowid_1
mov rdx, qword [rsp + 0x60]
call fcn.140151f20
test rax, rax
mov qword [rbx + 0x60], rax
je 0x140100e91
mov rcx, qword [rsp + 0x130]
lea r12, [0x140195dc5]
lea r13, str.a_d__d
call fcn.1401545b0
mov r9, qword [rsp + 0x58]
lea rdx, str.UPDATE___w_.__w_rowid_SET
mov r8, qword [rsp + 0x60]
mov rcx, rax
mov rdi, rax
call fcn.140154520
movzx eax, byte [rbx + 0x29]
cmp esi, eax
jge 0x14010115c
test esi, esi
je 0x140101146
mov r8d, 1
mov rdx, r12
mov rcx, rdi
call fcn.140154450
lea r9d, [rsi + 2]
mov r8d, esi
mov rdx, r13
mov rcx, rdi
inc esi
call fcn.140154520
jmp 0x140101129
lea rdx, str._WHERE_rowid_1
mov rcx, rdi
call fcn.140154520
mov rcx, rdi
call fcn.140154560
test rax, rax
mov rsi, rax
je 0x140100e91
mov rcx, qword [rsp + 0x130]
xor eax, eax
mov r9d, 5
or r8d, 0xffffffff
mov qword [rsp + 0x28], rax
lea rax, [rbx + 0xb8]
mov rdx, rsi
mov qword [rsp + 0x20], rax
call fcn.140152350
mov rcx, rsi
mov r15d, eax
call fcn.140150f20
test r15d, r15d
je 0x1401011e1
mov rcx, qword [rsp + 0x130]
mov esi, r15d
call fcn.140150720
lea rcx, [0x1401968f0]
mov rdx, rax
call fcn.140151f20
mov qword [rbp], rax
jmp 0x1401011ee
mov rax, qword [rsp + 0x150]
mov qword [rax], rbx
jmp 0x1401011f9
mov rcx, rbx
mov r15d, esi
call fcn.140101c00
mov eax, r15d
add rsp, 0xe8
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret