Function at 0x140159740
Capabilities:
Encode data using base64

Disassembly:
push r14
push rsi
push rdi
push rbx
sub rsp, 0x28
mov r14, rcx
cmp rdx, 1
je 0x1401598c0
mov rdi, rdx
lea rax, [rdx - 1]
test rdx, rax
je 0x14015976d
mov rcx, rdi
call fcn.14015ad30
mov rdi, rax
mov rbx, qword [r14 + 8]
cmp rdi, rbx
jbe 0x1401598d3
mov rax, rdi
shr rax, 0x3d
jne 0x1401598e7
lea rsi, [r14 + 8]
lea rcx, [rdi*8]
call fcn.1401b9cac
mov rcx, qword [r14]
mov qword [r14], rax
test rcx, rcx
je 0x1401597a8
call fcn.1401b9ce8
mov qword [rsi], rdi
xor eax, eax
nop dword [rax]
mov rcx, qword [r14]
mov qword [rcx + rax*8], 0
inc rax
cmp rdi, rax
jne 0x1401597b0
mov rsi, qword [r14 + 0x10]
test rsi, rsi
je 0x1401598d8
lea r9, [r14 + 0x10]
mov rcx, qword [rsi + 8]
mov rax, rdi
shr rax, 1
movabs rdx, 0x5555555555555555
and rdx, rax
mov rax, rdi
sub rax, rdx
movabs rdx, 0x3333333333333333
mov rbx, rax
and rbx, rdx
shr rax, 2
and rax, rdx
add rax, rbx
mov rdx, rax
shr rdx, 4
add rdx, rax
movabs rax, 0xf0f0f0f0f0f0f0f
and rax, rdx
movabs r8, 0x101010101010101
imul r8, rax
shr r8, 0x38
cmp r8, 1
jbe 0x1401598ec
cmp rcx, rdi
jb 0x14015984e
mov rax, rcx
xor edx, edx
div rdi
mov rcx, rdx
mov rax, qword [r14]
mov qword [rax + rcx*8], r9
mov rbx, qword [rsi]
test rbx, rbx
je 0x1401598d8
lea r9, [rdi - 1]
mov rax, qword [rbx + 8]
cmp r8d, 1
jbe 0x1401598e2
cmp rax, rdi
jb 0x140159878
xor edx, edx
div rdi
mov rax, rdx
cmp rax, rcx
je 0x1401598bb
mov rdx, qword [r14]
cmp qword [rdx + rax*8], 0
jne 0x14015989b
mov qword [rdx + rax*8], rsi
mov rsi, rbx
mov rbx, qword [rbx]
mov rcx, rax
test rbx, rbx
jne 0x140159861
jmp 0x1401598d8
mov rdx, qword [rbx]
mov qword [rsi], rdx
mov rdx, qword [r14]
mov rdx, qword [rdx + rax*8]
mov rdx, qword [rdx]
mov qword [rbx], rdx
mov rdx, qword [r14]
mov rax, qword [rdx + rax*8]
mov qword [rax], rbx
mov rbx, rsi
mov rax, rcx
jmp 0x14015988b
mov rbx, qword [r14 + 8]
mov edi, 2
cmp rbx, 2
jb 0x140159787
cmp rdi, rbx
jb 0x1401598f8
add rsp, 0x28
pop rbx
pop rdi
pop rsi
pop r14
ret
and rax, r9
jmp 0x140159878
call fcn.1401f9cb0
lea rax, [rdi - 1]
and rcx, rax
jmp 0x14015984e
mov rax, qword [r14 + 0x18]
test rax, rax
js 0x140159908
cvtsi2ss xmm0, rax
jmp 0x14015991d
mov rcx, rax
shr rcx, 1
and eax, 1
or rax, rcx
cvtsi2ss xmm0, rax
addss xmm0, xmm0
divss xmm0, dword [r14 + 0x20]
call fcn.1401d9598
cvttss2si rcx, xmm0
mov rdx, rcx
subss xmm0, dword [0x14033165c]
cvttss2si rax, xmm0
sar rdx, 0x3f
and rax, rdx
or rax, rcx
cmp rbx, 3
jb 0x1401599ca
mov rcx, rbx
shr rcx, 1
movabs rdx, 0x5555555555555555
and rdx, rcx
mov rsi, rbx
sub rsi, rdx
movabs rdx, 0x3333333333333333
mov rcx, rsi
shr rcx, 2
and rsi, rdx
and rcx, rdx
add rcx, rsi
mov rdx, rcx
shr rdx, 4
add rdx, rcx
movabs rcx, 0xf0f0f0f0f0f0f0f
and rcx, rdx
movabs rdx, 0x101010101010101
imul rdx, rcx
shr rdx, 0x38
cmp edx, 1
ja 0x1401599ca
cmp rax, 2
jb 0x1401599d2
dec rax
bsr rcx, rax
xor ecx, 0x3f
neg cl
mov eax, 1
shl rax, cl
jmp 0x1401599d2
mov rcx, rax
call fcn.14015ad30
cmp rdi, rax
cmova rax, rdi
cmp rax, rbx
jae 0x1401598d8
mov rcx, r14
mov rdx, rax
add rsp, 0x28
pop rbx
pop rdi
pop rsi
pop r14
jmp 0x1401fc870
push r14
push rsi
push rdi
push rbx
sub rsp, 0x28
mov r14, rcx
test rdx, rdx
je 0x1401fc9d1
mov rdi, rdx
mov rax, rdx
shr rax, 0x3d
jne 0x1401fc9f7
lea rcx, [rdi*8]
call fcn.1401b9cac
mov rcx, qword [r14]
mov qword [r14], rax
test rcx, rcx
je 0x1401fc8b2
call fcn.1401b9ce8
mov qword [r14 + 8], rdi
xor eax, eax
mov rcx, qword [r14]
mov qword [rcx + rax*8], 0
inc rax
cmp rdi, rax
jne 0x1401fc8b8
mov rbx, qword [r14 + 0x10]
test rbx, rbx
je 0x1401fc9ed
lea r9, [r14 + 0x10]
mov rcx, qword [rbx + 8]
mov rax, rdi
shr rax, 1
movabs rdx, 0x5555555555555555
and rdx, rax
mov rax, rdi
sub rax, rdx
movabs rdx, 0x3333333333333333
mov rsi, rax
and rsi, rdx
shr rax, 2
and rax, rdx
add rax, rsi
mov rdx, rax
shr rdx, 4
add rdx, rax
movabs rax, 0xf0f0f0f0f0f0f0f
and rax, rdx
movabs r8, 0x101010101010101
imul r8, rax
shr r8, 0x38
cmp r8, 1
jbe 0x1401fc9fc
cmp rcx, rdi
jb 0x1401fc956
mov rax, rcx
xor edx, edx
div rdi
mov rcx, rdx
mov rax, qword [r14]
mov qword [rax + rcx*8], r9
mov rsi, qword [rbx]
test rsi, rsi
je 0x1401fc9ed
lea r9, [rdi - 1]
mov rax, qword [rsi + 8]
cmp r8d, 1
jbe 0x1401fc9cc
cmp rax, rdi
jb 0x1401fc984
xor edx, edx
div rdi
mov rax, rdx
cmp rax, rcx
je 0x1401fc9c7
mov rdx, qword [r14]
cmp qword [rdx + rax*8], 0
jne 0x1401fc9a7
mov qword [rdx + rax*8], rbx
mov rbx, rsi
mov rsi, qword [rsi]
mov rcx, rax
test rsi, rsi
jne 0x1401fc96d
jmp 0x1401fc9ed
mov rdx, qword [rsi]
mov qword [rbx], rdx
mov rdx, qword [r14]
mov rdx, qword [rdx + rax*8]
mov rdx, qword [rdx]
mov qword [rsi], rdx
mov rdx, qword [r14]
mov rax, qword [rdx + rax*8]
mov qword [rax], rsi
mov rsi, rbx
mov rax, rcx
jmp 0x1401fc997
and rax, r9
jmp 0x1401fc984
mov rcx, qword [r14]
mov qword [r14], 0
test rcx, rcx
je 0x1401fc9e5
call fcn.1401b9ce8
mov qword [r14 + 8], 0
add rsp, 0x28
pop rbx
pop rdi
pop rsi
pop r14
ret
call fcn.1401f9cb0
lea rax, [rdi - 1]
and rcx, rax
jmp 0x1401fc956