Function at 0x471793
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x88
xor edi, edi
xor r13d, r13d
mov r12, qword [rcx]
mov rbx, qword [rcx + 0x10]
mov rax, qword [r12]
mov qword [rsp + 0xd0], rcx
movzx ebp, byte [rbx + 0x10]
mov qword [rsp + 0xd8], rdx
mov r14, qword [r12 + 8]
mov dword [rsp + 0x7c], 0
mov qword [rsp + 0x48], rax
mov rax, qword [rcx + 8]
movsxd r11, ebp
imul r11, r11, 0x68
mov qword [rsp + 0x50], rax
imul rax, rbp, 0x68
add r11, r14
mov r15, qword [r11 + 0x28]
lea rax, [r14 + rax + 8]
mov qword [rsp + 0x60], rax
mov rax, qword [r12 + 0x10]
mov qword [rsp + 0x58], rax
mov rax, qword [rsp + 0x50]
mov r10, qword [rax + 0x20]
mov eax, dword [rax + 0x14]
mov dword [rsp + 0x68], eax
cmp r13d, dword [rsp + 0x68]
jge 0x47188d
mov ax, word [r10 + 0x12]
mov edx, dword [r11 + 0x4c]
mov esi, eax
and esi, 0xffffffbf
cmp dword [r10 + 0x1c], edx
mov word [r10 + 0x12], si
jne 0x471884
test qword [r10 + 0x28], r8
jne 0x471884
movzx edx, word [r10 + 0x14]
and edx, 0xf7ff
je 0x471884
test al, 0x80
jne 0x471884
test byte [r11 + 0x44], 0x58
je 0x47187a
mov rdx, qword [rsp + 0x60]
mov qword [rsp + 0xe0], r8
mov rcx, qword [r10]
call sym.constraintCompatibleWithOuterJoin.isra.195
mov r8, qword [rsp + 0xe0]
test eax, eax
je 0x471884
or esi, 0x40
inc edi
mov word [r10 + 0x12], si
inc r13d
add r10, 0x38
jmp 0x47181b
cmp qword [rsp + 0x58], 0
jne 0x47189f
xor r14d, r14d
xor esi, esi
jmp 0x471979
mov rax, qword [rsp + 0x58]
movsxd rbp, ebp
xor esi, esi
imul rbp, rbp, 0x68
mov eax, dword [rax]
add rbp, r14
mov dword [rsp + 0x60], eax
mov rax, qword [rsp + 0x58]
lea r13, [rax + 8]
cmp dword [rsp + 0x60], esi
jle 0x47194b
mov r14, qword [r13]
mov rcx, r14
call sym.sqlite3ExprIsConstant
test eax, eax
je 0x4718e1
inc esi
add r13, 0x20
jmp 0x4718bf
test byte [r13 + 0x10], 2
jne 0x471895
mov al, byte [r14]
cmp al, 0xa7
jne 0x4718f8
mov eax, dword [rbp + 0x4c]
cmp dword [r14 + 0x2c], eax
jmp 0x471943
cmp al, 0x71
jne 0x471895
mov rax, qword [r14 + 0x10]
cmp byte [rax], 0xa7
jne 0x471895
mov ecx, dword [rbp + 0x4c]
cmp dword [rax + 0x2c], ecx
jne 0x471895
movsx rcx, word [rax + 0x30]
test cx, cx
mov word [r14 + 0x30], cx
js 0x4718d9
imul rcx, rcx, 0x18
add rcx, qword [r15 + 8]
call sym.sqlite3ColumnColl
test rax, rax
jne 0x471935
lea rax, str.BINARY
mov rcx, qword [r14 + 8]
mov rdx, rax
call sym.sqlite3_stricmp
test eax, eax
jne 0x471895
jmp 0x4718d9
jne 0x471895
mov r14d, dword [r12 + 0x3c]
test r14b, 0x80
je 0x471970
and r14w, 0x200
cmp r14w, 1
sbb r14d, r14d
add r14d, 3
jmp 0x471979
shr r14w, 6
and r14d, 1
movsxd rdi, edi
movsxd r15, esi
imul rax, rdi, 0x1c
shl r15, 3
lea rdx, [r15 + rax + 0x88]
mov rax, qword [rsp + 0x48]
mov rcx, qword [rax]
call sym.sqlite3DbMallocZero
test rax, rax
mov rbp, rax
jne 0x4719ba
mov rcx, qword [rsp + 0x48]
lea rdx, [0x004e0dcc]
call sym.sqlite3ErrorMsg
jmp 0x471bb3
lea r12, [rax + rdi*8 + 0x80]
xor r10d, r10d
imul rdi, rdi, 0xc
mov qword [rax + 8], r12
lea r13, [r12 + rdi]
xor edi, edi
add r15, r13
mov qword [rax + 0x18], r13
mov qword [rax + 0x20], r15
mov rax, qword [rsp + 0x50]
mov r15d, 1
mov dword [rbp + 0x70], r14d
xor r14d, r14d
mov dword [rbp + 0x74], 0
mov qword [rbp + 0x60], rax
mov rax, qword [rsp + 0x48]
mov qword [rbp + 0x68], rax
mov rax, qword [rsp + 0x50]
mov r11, qword [rax + 0x20]
mov eax, dword [rax + 0x14]
mov dword [rsp + 0x60], eax
cmp edi, dword [rsp + 0x60]
jge 0x471af6
mov ax, word [r11 + 0x12]
test al, 0x40
je 0x471aeb
movsxd r9, r10d
mov r8d, dword [r11 + 0x14]
imul r9, r9, 0xc
mov edx, dword [r11 + 0x20]
and r8w, 0x3fff
add r9, r12
cmp r8w, 1
mov dword [r9], edx
mov dword [r9 + 8], edi
jne 0x471a7c
test ax, ax
mov r8d, 2
js 0x471a89
xor edx, edx
cmp r10d, 0x1f
mov eax, dword [rbp + 0x74]
jg 0x471a6f
mov edx, r15d
mov ecx, r10d
shl edx, cl
or eax, edx
mov r8d, 2
mov dword [rbp + 0x74], eax
jmp 0x471a89
cmp r8w, 0x40
jne 0x471a89
mov al, byte [r11 + 0x17]
jmp 0x471a9d
test r8w, 0x180
je 0x471aa3
cmp r8w, 0x100
setne al
add eax, 0x47
mov byte [r9 + 4], al
jmp 0x471ae8
test r8b, 0x3c
mov byte [r9 + 4], r8b
je 0x471ae8
mov rax, qword [r11]
mov rcx, qword [rax + 0x18]
call sym.sqlite3ExprIsVector
test eax, eax
je 0x471ae8
cmp r10d, 0xf
jg 0x471ace
mov eax, r15d
mov ecx, r10d
shl eax, cl
or r14d, eax
cmp r8w, 0x10
jne 0x471adc
mov byte [r9 + 4], 8
jmp 0x471ae8
cmp r8w, 4
jne 0x471ae8
mov byte [r9 + 4], 0x20
inc r10d
inc edi
add r11, 0x38
jmp 0x471a14
mov rdi, qword [rsp + 0x58]
movsxd rsi, esi
mov dword [rbp], r10d
xor r12d, r12d
shl rsi, 5
add rsi, rdi
cmp rsi, rdi
je 0x471b42
mov r15, qword [rdi + 8]
mov rcx, r15
call sym.sqlite3ExprIsConstant
test eax, eax
jne 0x471b3c
movsxd rax, r12d
inc r12d
lea rdx, [r13 + rax*8]
movsx eax, word [r15 + 0x30]
mov dword [rdx], eax
mov al, byte [rdi + 0x18]
and eax, 1
mov byte [rdx + 4], al
add rdi, 0x20
jmp 0x471b0c
mov dword [rbp + 0x10], r12d
mov rdx, rbx
and byte [rbx + 0x1c], 0xfe
mov word [rbx + 0x12], 0
mov eax, dword [rbp]
mov dword [rbx + 0x38], 0x400
mov word [rbx + 0x3c], 0
mov dword [rsp + 0x60], eax
mov r8d, eax
mov rax, qword [rsp + 0x48]
mov rcx, qword [rax]
call sym.whereLoopResize
test eax, eax
je 0x471bbd
mov rax, qword [rsp + 0x48]
xor ebx, ebx
mov rsi, qword [rax]
cmp dword [rbp], ebx
jle 0x471ba8
mov rcx, qword [rbp + rbx*8 + 0x80]
call sym.sqlite3ValueFree
mov qword [rbp + rbx*8 + 0x80], 0
inc rbx
jmp 0x471b85
mov rdx, rbp
mov rcx, rsi
call sym.sqlite3DbFree
mov eax, 7
jmp 0x471e69
movzx edi, r14w
xor r9d, r9d
or r8, 0xffffffffffffffff
mov qword [rsp + 0x20], rbp
mov rdx, qword [rsp + 0xd8]
lea rax, [rsp + 0x7c]
mov dword [rsp + 0x28], edi
mov rcx, qword [rsp + 0xd0]
lea rsi, [rsp + 0x78]
mov qword [rsp + 0x38], rax
mov qword [rsp + 0x30], rsi
call sym.whereLoopAddVirtualOne
cmp dword [rsp + 0x7c], 0
je 0x471c34
mov rdx, qword [rsp + 0xd8]
mov dword [rsp + 0x28], edi
xor r9d, r9d
or r8, 0xffffffffffffffff
mov rcx, qword [rsp + 0xd0]
mov qword [rsp + 0x30], rsi
mov qword [rsp + 0x38], 0
mov qword [rsp + 0x20], rbp
call sym.whereLoopAddVirtualOne
test eax, eax
jne 0x471e0e
mov rax, qword [rsp + 0xd8]
not rax
mov qword [rsp + 0x58], rax
mov rdx, qword [rsp + 0x58]
and rdx, qword [rbx]
mov eax, dword [rsp + 0x78]
mov qword [rsp + 0x68], rdx
jne 0x471c68
test eax, eax
jne 0x471c72
jmp 0x471e0e
xor r13d, r13d
xor r15d, r15d
test eax, eax
je 0x471cb7
mov rdx, qword [rsp + 0xd8]
or r8, 0xffffffffffffffff
mov qword [rsp + 0x38], 0
mov r9d, 1
mov rcx, qword [rsp + 0xd0]
mov qword [rsp + 0x30], rsi
xor r13d, r13d
mov dword [rsp + 0x28], edi
mov qword [rsp + 0x20], rbp
call sym.whereLoopAddVirtualOne
mov r15, qword [rsp + 0x58]
and r15, qword [rbx]
sete r13b
lea r14, [rsp + 0x78]
mov r12d, r13d
xor r8d, r8d
test eax, eax
jne 0x471dcf
xor ecx, ecx
or rsi, 0xffffffffffffffff
cmp dword [rsp + 0x60], ecx
jle 0x471d10
imul rdx, rcx, 0xc
mov r11, qword [rsp + 0x50]
add rdx, qword [rbp + 8]
mov r10, qword [rsp + 0x58]
movsxd rdx, dword [rdx + 8]
imul rdx, rdx, 0x38
add rdx, qword [r11 + 0x20]
and r10, qword [rdx + 0x28]
cmp r8, r10
mov rdx, r10
jae 0x471d05
cmp rsi, r10
ja 0x471d08
mov rdx, rsi
inc rcx
mov rsi, rdx
jmp 0x471cd0
cmp rsi, 0xffffffffffffffff
je 0x471d85
cmp rsi, qword [rsp + 0x68]
je 0x471d7d
cmp rsi, r15
je 0x471d7d
mov r8, qword [rsp + 0xd8]
xor r9d, r9d
mov qword [rsp + 0x30], r14
mov rdx, qword [rsp + 0xd8]
mov dword [rsp + 0x28], edi
mov rcx, qword [rsp + 0xd0]
mov qword [rsp + 0x20], rbp
mov qword [rsp + 0x38], 0
or r8, rsi
call sym.whereLoopAddVirtualOne
mov rdx, qword [rsp + 0xd8]
cmp qword [rbx], rdx
jne 0x471d7d
cmp dword [rsp + 0x78], 0
mov ecx, 1
mov r13d, 1
cmove r12d, ecx
mov r8, rsi
jmp 0x471cc2
test r13d, r13d
jne 0x471dcf
mov r8, qword [rsp + 0xd8]
lea rax, [rsp + 0x78]
xor r9d, r9d
mov dword [rsp + 0x28], edi
mov rcx, qword [rsp + 0xd0]
mov qword [rsp + 0x30], rax
mov qword [rsp + 0x38], 0
mov qword [rsp + 0x20], rbp
mov rdx, r8
call sym.whereLoopAddVirtualOne
cmp dword [rsp + 0x78], 0
mov edx, 1
cmove r12d, edx
or r12d, eax
jne 0x471e0e
lea rax, [rsp + 0x78]
mov dword [rsp + 0x28], edi
mov r8, qword [rsp + 0xd8]
mov r9d, 1
mov rcx, qword [rsp + 0xd0]
mov qword [rsp + 0x30], rax
mov qword [rsp + 0x38], 0
mov qword [rsp + 0x20], rbp
mov rdx, r8
call sym.whereLoopAddVirtualOne
cmp dword [rbp + 0x38], 0
je 0x471e25
mov rcx, qword [rbp + 0x30]
mov dword [rsp + 0x50], eax
call sym.sqlite3_free
mov eax, dword [rsp + 0x50]
mov rbx, qword [rsp + 0x48]
mov rsi, qword [rbx]
xor ebx, ebx
cmp dword [rbp], ebx
mov dword [rsp + 0x48], eax
jle 0x471e5a
mov rcx, qword [rbp + rbx*8 + 0x80]
call sym.sqlite3ValueFree
mov eax, dword [rsp + 0x48]
mov qword [rbp + rbx*8 + 0x80], 0
inc rbx
jmp 0x471e2f
mov rdx, rbp
mov rcx, rsi
call sym.sqlite3DbFree
mov eax, dword [rsp + 0x48]
add rsp, 0x88
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret