Function at 0x14000507a
Capabilities:
Encode data using xor
Get thread local storage value
Set thread local storage value

Disassembly:
push rbp
push r15
push r14
push r13
push r12
push rsi
push rdi
push rbx
sub rsp, 0x18
lea rbp, [rsp + 0x10]
mov qword [rbp], 0xfffffffffffffffe
mov r15, rdx
mov eax, dword [0x140294d18]
mov edx, dword [0x140294d1c]
shrd edx, eax, 0x1e
mov rdi, rcx
xor edx, 0xbc36a6be
mov eax, edx
imul rax, rax, 0x68
add rax, 0xf
and rax, 0xfffffffffffffff0
call fcn.1400fe1d0
sub rsp, rax
mov rcx, rsp
mov eax, dword [0x140294d20]
mov edx, dword [0x140294d24]
shrd edx, eax, 0x15
xor edx, 0xa1598b07
mov eax, edx
lea rax, [rax + rax*2]
lea rax, [rax*8 + 0xf]
and rax, 0xfffffffffffffff0
call fcn.1400fe1d0
sub rsp, rax
mov rbx, rsp
mfence
mov edx, dword [rdi + 0x30]
mov r8d, dword [0x140294d28]
mov r9d, dword [0x140294d2c]
shrd r9d, r8d, 0xa
xor r9d, 0xed7dbf6
cmp edx, r9d
jne 0x14000514a
sub rsp, 0x20
mov rcx, rdi
call fcn.1400053ce
add rsp, 0x20
xorps xmm0, xmm0
movups xmmword [r15], xmm0
mov qword [r15 + 0x10], 0
xor eax, eax
jmp 0x140005371
mov rsi, rcx
mov eax, dword [0x140294d30]
mov edx, dword [0x140294d34]
shrd edx, eax, 0x1e
xor edx, 0x7ec27490
mov dword [rcx + 0x50], edx
add rcx, 0x58
sub rsp, 0x20
call fcn.1400d9298
add rsp, 0x20
movabs rax, 0xd5306afdf2f289bc
movabs rcx, 0x1ceab1b5041cc95b
movabs rdx, 0xb9717d132527827
movabs r8, 0x1234ca6cbc2f8a53
xor r9d, r9d
mov qword [rsi + r9*8], 0
mov r10, qword [0x140294d38]
imul r10, rax
mov r11, qword [0x140294d40]
imul r11, rcx
add r11, r10
add r9, rdx
mov r10, r9
add r10, r11
mov r9, qword [0x140294d48]
mov r11, qword [0x140294d50]
shrd r11, r9, 0x33
xor r11, r8
mov r9, r10
cmp r10, r11
jne 0x1400051a2
lea rax, [rdi + 0x28]
mov qword [rbx], rax
mov qword [rbp - 8], rsi
mov qword [rbx + 8], rsi
mov ecx, dword [0x1402bebf4]
sub rsp, 0x20
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
add rsp, 0x20
mov qword [rbx + 0x10], rax
mov ecx, dword [0x1402bebf4]
sub rsp, 0x20
mov qword [rbp - 0x10], rbx
mov rdx, rbx
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
add rsp, 0x20
movabs rbx, 0x170c9030f027e108
movabs r13, 0x63363b973e10ba9
movabs r14, 0x6dfe6f82a5c3b5ff
movabs r12, 0x43c0dfec4ed6c80f
xor esi, esi
imul eax, dword [0x140294d58], 0xe7471dcb
imul ecx, dword [0x140294d5c], 0xd5a39175
lea edx, [rax + rcx]
add edx, 0xd04b860
nop
sub rsp, 0x20
mov rcx, rdi
mov r8, qword [rbp - 8]
mov r9, r15
call fcn.1400057b2
add rsp, 0x20
nop
mov rcx, qword [0x140294d60]
movabs rdx, 0x962c9891adf4be5d
imul rcx, rdx
mov rdx, qword [0x140294d68]
movabs r8, 0x33f286b029591df7
imul rdx, r8
add rdx, rcx
movabs rcx, 0xb5b4ba43495d2198
add rdx, rcx
cmp rax, rdx
je 0x140005349
mov rax, qword [0x140294d70]
movabs rcx, 0x31e281f5781db116
imul rax, rcx
mov rcx, qword [0x140294d78]
movabs rdx, 0xdcebf80b35b46d09
imul rcx, rdx
add rcx, rax
movabs rax, 0xaad41029a829b90c
add rcx, rax
mov rax, qword [0x140294d80]
imul rax, rbx
mov rdx, qword [0x140294d88]
imul rdx, r13
add rdx, rax
mov rax, qword [0x140294d90]
mov r8, qword [0x140294d98]
shrd r8, rax, 0x3f
add rdx, rsi
add rdx, r14
xor r8, r12
cmp rsi, rcx
mov rsi, r8
cmovne rsi, rdx
jmp 0x140005256
mov rax, qword [rbp - 0x10]
mov rdx, qword [rax + 0x10]
mov ecx, dword [0x1402bebf4]
sub rsp, 0x20
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
mov rcx, qword [rbp - 8]
call fcn.14000659a
add rsp, 0x20
mov rax, rsi
lea rsp, [rbp + 8]
pop rbx
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
pop rbp
ret