Function at 0x1401d2bc0
Capabilities:
Encode data using xor

Disassembly:
push r14
push rsi
push rdi
push rbx
sub rsp, 0x48
mov r11, qword [rsp + 0x90]
mov rax, qword [0x1403a6f68]
xor rax, rsp
mov qword [rsp + 0x40], rax
mov rax, qword [rcx + 0x90]
lea r10, [rax + 1]
mov qword [rcx + 0x90], r10
mov esi, eax
and esi, 3
shl esi, 4
mov qword [rcx + rsi + 0x50], r9
mov qword [rcx + rsi + 0x58], r11
test rax, rax
jle 0x1401d2c85
cmp r10, 4
mov r9d, 4
cmovl r9, r10
lea r11, [rcx + 0x50]
dec r9
xor r10d, r10d
xor esi, esi
nop word cs:[rax + rax]
mov edi, eax
and edi, 3
shl edi, 4
mov rbx, qword [r11 + rdi + 8]
lea r14d, [rax + 1]
and r14d, 3
xor r14d, 2
shl r14d, 4
sub r10, qword [r11 + rdi]
add r10, rbx
add rsi, rbx
sub rsi, qword [r11 + r14 + 8]
dec rax
dec r9
jne 0x1401d2c30
test rsi, rsi
je 0x1401d2c85
cvtsi2sd xmm0, r10
cvtsi2sd xmm1, rsi
divsd xmm0, xmm1
mulsd xmm0, qword [0x140336df8]
cvttsd2si eax, xmm0
jmp 0x1401d2c87
xor eax, eax
mov r9, qword [rdx + 8]
add r9, qword [rdx + 0x10]
mov r10, qword [rcx + 0x10]
add r10, qword [rcx + 0x18]
sub r9, r10
test r9, r9
jle 0x1401d2d0a
mov r10, qword [rdx + 8]
add r10, qword [rdx + 0x10]
mov r11, qword [r8 + 8]
add r11, qword [r8 + 0x10]
sub r10, r11
xor r11d, r11d
test r10, r10
cmovg r11, r10
cvtsi2sd xmm2, r11
xorps xmm0, xmm0
cvtsi2sd xmm0, r9
divsd xmm2, xmm0
movsd xmm0, qword [0x140336e08]
movapd xmm1, xmm0
minsd xmm1, xmm2
movsd xmm2, qword [0x140336df8]
mulsd xmm2, xmm1
cvttsd2si r10d, xmm2
movsd xmm2, qword [rcx + 0x28]
mov r9d, dword [rcx + 0x34]
sub eax, r9d
jle 0x1401d2d12
cvtsi2sd xmm3, eax
divsd xmm3, qword [0x140336df8]
jmp 0x1401d2d1a
xor r9d, r9d
jmp 0x1401d2e1f
movsd xmm3, qword [0x140336e10]
mov rax, qword [r8 + 8]
add rax, qword [r8 + 0x10]
cvtsi2sd xmm4, rax
divsd xmm4, xmm2
cvttsd2si r11, xmm4
mov rax, qword [r8 + 8]
add rax, qword [r8 + 0x10]
sub r11, rax
lea rax, [r11 + 0xffff]
test r11, r11
cmovns rax, r11
sar rax, 0x10
test r10d, r10d
je 0x1401d2de1
movsxd r10, dword [rcx + 0x30]
test r9d, r9d
je 0x1401d2df1
test r10d, r10d
jle 0x1401d2dfd
subsd xmm0, xmm2
addsd xmm0, xmm3
xor r11d, r11d
mov r9, r10
jmp 0x1401d2d8b
dec rsi
mov r9, rsi
cmp r11, r9
jge 0x1401d2e03
lea rdi, [r9 + r11]
mov rsi, rdi
shr rsi, 0x3f
add rsi, rdi
sar rsi, 1
mov rdi, rsi
shl rdi, 0x10
add rdi, qword [r8 + 8]
add rdi, qword [r8 + 0x10]
mov rbx, qword [r8 + 8]
add rbx, qword [r8 + 0x10]
xorps xmm2, xmm2
cvtsi2sd xmm2, rdi
sub rdi, rbx
xorps xmm3, xmm3
cvtsi2sd xmm3, rdi
mulsd xmm3, xmm1
divsd xmm3, xmm2
ucomisd xmm3, xmm0
jae 0x1401d2d80
inc rsi
mov r11, rsi
cmp r11, r9
jl 0x1401d2d8b
jmp 0x1401d2e03
movsxd r9, dword [rcx + 0x30]
cmp r9, rax
cmovg rax, r9
mov r9, rax
jmp 0x1401d2e1f
cmp r10, rax
cmovg rax, r10
mov r9, rax
jmp 0x1401d2e1f
xor r11d, r11d
mov r9, r10
add r11, r9
mov r9, r11
shr r9, 0x3f
add r9, r11
sar r9, 1
cmp r9, r10
jl 0x1401d2e1f
cmp rax, r9
cmovg r9, rax
mov rax, qword [r8]
mov qword [rcx + 8], rax
mov rax, qword [r8 + 8]
mov qword [rcx + 0x10], rax
mov rax, qword [r8 + 0x10]
mov qword [rcx + 0x18], rax
mov rax, qword [rcx]
mov rax, qword [rax + 0x2a8]
test rax, rax
je 0x1401d2e94
xorps xmm0, xmm0
cvtsi2sd xmm0, r9
shl r9, 0x10
add r9, qword [r8 + 8]
add r9, qword [r8 + 0x10]
xorps xmm1, xmm1
cvtsi2sd xmm1, r9
xorps xmm2, xmm2
cvtsi2sd xmm2, rax
divsd xmm1, xmm2
mulsd xmm1, xmm1
movsd xmm2, qword [0x140336e08]
subsd xmm2, xmm1
mulsd xmm2, xmm0
cvttsd2si rax, xmm2
cmp rax, 5
mov r9d, 4
cmovge r9, rax
mov rax, qword [r8]
mov qword [rsp + 0x28], rax
mov rax, qword [r8 + 8]
mov qword [rsp + 0x30], rax
mov rax, qword [r8 + 0x10]
mov qword [rsp + 0x38], rax
mov rax, qword [rdx]
mov rax, qword [rdx + 8]
mov rax, qword [rdx + 0x10]
lea rax, [0x140337037]
mov qword [rsp + 0x20], rax
lea r8, [rsp + 0x28]
call fcn.1401d3440
mov rcx, qword [rsp + 0x40]
xor rcx, rsp
call fcn.140262cb0
nop
add rsp, 0x48
pop rbx
pop rdi
pop rsi
pop r14
ret