Function at 0x18016dd70
Capabilities:
Get thread local storage value

Disassembly:
mov rax, rsp
mov qword [rax + 0x10], rdx
push rdi
sub rsp, 0xc0
mov rdi, qword [rcx + 0x10]
mov qword [rax + 0x18], rbx
mov qword [rax - 0x10], rbp
mov qword [rax - 0x18], rsi
xor ebx, ebx
mov qword [rax - 0x28], r13
mov qword [rax - 0x30], r14
mov qword [rax - 0x38], r15
mov qword [rsp + 0x58], rdi
mov r15, rbx
mov esi, r9d
mov r14, r8
mov r13, rcx
mov dword [rsp + 0xe8], ebx
test r9d, r9d
jne 0x18016ddc4
mov edi, 0x80004005
jmp 0x18016de42
mov ecx, dword [rcx + 0x128]
mov rax, qword [r13 + 0x30]
mov qword [rsp + 0xa8], r12
mov r12, qword [rax + rcx*8]
mov rdx, rdi
mov rcx, r12
call fcn.180199e70
test eax, eax
jne 0x18016dded
mov edi, ebx
jmp 0x18016de3a
mov edx, ebx
test esi, esi
je 0x18016de38
xorpd xmm1, xmm1
mov rdi, r14
lea r9, [0x180027d20]
mov r8, qword [rdi]
movsxd rax, dword [r8 + 0xa4]
mov ecx, dword [r9 + rax*4]
shr ecx, 9
test cl, 1
je 0x18016e3e8
movsd xmm0, qword [r8 + 0x158]
comisd xmm0, xmm1
jb 0x18016deb6
inc edx
add rdi, 8
cmp edx, esi
jb 0x18016de01
mov edi, ebx
mov r12, qword [rsp + 0xa8]
mov rcx, qword [rsp + 0x58]
mov eax, dword [rsp + 0xe8]
mov r14, qword [rsp + 0x98]
mov r13, qword [rsp + 0xa0]
mov rsi, qword [rsp + 0xb0]
mov rbp, qword [rsp + 0xb8]
mov rbx, qword [rsp + 0xe0]
add rcx, 0xd280
test r15, r15
mov r15, qword [rsp + 0x90]
je 0x18016e3fd
mov edx, 1
test rax, rax
cmove rax, rdx
mov rdx, qword [rcx]
cmp rax, qword [rdx + 8]
jae 0x18016e3f2
sub qword [rdx + 8], rax
mov eax, edi
add rsp, 0xc0
pop rdi
ret
lea eax, [rsi + rsi*4]
cmp eax, 0x1ffffffe
jbe 0x18016dec7
mov edi, 0x80070216
jmp 0x18016df05
mov rcx, qword [rsp + 0x58]
lea ebx, [rax*8]
mov eax, 8
test ebx, ebx
cmove ebx, eax
add rcx, 0xd280
mov edx, ebx
mov dword [rsp + 0xe8], ebx
call fcn.1800c58b0
mov edi, 0x8007000e
mov ebx, 0
test rax, rax
mov r15, rax
cmovne edi, ebx
test edi, edi
js 0x18016de3a
mov edx, ebx
lea rdi, [rsp + 0x60]
mov r8d, 5
nop word [rax + rax]
mov eax, edx
add rdi, 8
add edx, esi
sub r8, 1
lea rcx, [r15 + rax*8]
mov qword [rdi - 8], rcx
jne 0x18016df20
mov rbp, qword [r13 + 0x10]
mov ecx, dword [0x18025e63c]
mov rdi, qword [rbp + 0xd120]
test ecx, ecx
jns 0x18016df50
mov rcx, rbx
jmp 0x18016df59
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rcx, rax
cmp qword [rcx + 0x18], 0
je 0x18016df88
mov rbx, qword [rcx + 0x18]
test rbx, rbx
je 0x18016df9f
mov rax, qword [rbx]
mov qword [rcx + 0x18], rax
test rax, rax
jne 0x18016df79
mov qword [rcx + 0x20], rax
movabs rax, 0xfefefefefefefefe
mov qword [rbx], rax
jmp 0x18016df9f
mov rcx, qword [rcx + 0x10]
mov edx, 0x188
mov r8d, 0x10
call fcn.180243b70
mov rbx, rax
test rbx, rbx
je 0x18016e067
xor eax, eax
xor r9d, r9d
xor r8d, r8d
mov rdx, rdi
mov rcx, rbx
mov dword [rbx + 0xa0], 0xffffffff
mov qword [rbx], rax
mov qword [rbx + 8], rax
mov qword [rbx + 0x78], rax
mov qword [rbx + 0x80], rax
mov qword [rbx + 0x88], rax
mov qword [rbx + 0x90], rax
mov qword [rbx + 0x40], rax
mov qword [rbx + 0xa8], 0xffffffffffffffff
call fcn.1801992b0
mov edi, eax
test eax, eax
js 0x18016e04d
call fcn.18019c4f0
test al, al
je 0x18016e00e
or qword [rbx + 0x98], 0x20000
mov rax, qword [rbx + 0xa8]
mov rcx, qword [rax + 0x10]
test cl, 0x10
je 0x18016e02d
bt rcx, 0x15
jae 0x18016e02d
or qword [rbx + 0x98], 0x10
mov eax, dword [rbp + 0x10]
mov qword [rsp + 0xd0], rbx
mov dword [rbx + 0xa0], eax
inc dword [rbp + 0x10]
or dword [rbp + 0x28], 4
xor r11d, r11d
mov edi, r11d
jmp 0x18016e077
call fcn.1801991c0
mov rcx, rbx
call fcn.18019de00
mov rbx, qword [rsp + 0xd0]
xor r11d, r11d
jmp 0x18016e077
mov rbx, qword [rsp + 0xd0]
mov edi, 0x8007000e
xor r11d, r11d
test edi, edi
js 0x18016de3a
mov rax, qword [r13 + 0x10]
mov qword [rsp + 0x50], 0xffffffffffffffff
test byte [rax + 0xcefb], 0x10
jne 0x18016e174
mov rbp, qword [rsp + 0x70]
mov r9, qword [rsp + 0x60]
mov rax, rsi
mov rcx, r9
mov rdx, rbp
sub rcx, rbp
nop
mov qword [rcx + rdx], r12
mov qword [rdx], rbx
add rdx, 8
sub rax, 1
jne 0x18016e0b0
mov rbx, qword [rsp + 0x68]
mov r12, qword [rsp + 0xd8]
mov dword [rsp + 0x40], 0x11
mov dword [rsp + 0x38], r11d
mov qword [rsp + 0x30], r11
mov qword [rsp + 0x28], r9
mov rcx, rsi
or rax, 0xffffffffffffffff
and esi, 0xfffff
mov r8d, esi
mov rdi, rbx
mov r9, rbx
rep stosq qword [rdi], rax
mov rdx, r12
mov rcx, r13
or r8d, 0x20400000
mov qword [rsp + 0x20], r14
call fcn.18012ed20
mov edi, eax
test eax, eax
js 0x18016de3a
mov rax, qword [r13 + 0x10]
mov dword [rsp + 0x40], 0x11
or esi, 0x50400000
mov rcx, qword [rax + 0xd118]
lea r9, [rsp + 0x50]
mov r8d, esi
mov qword [rsp + 0x38], rcx
mov qword [rsp + 0x30], 0
mov rcx, r13
mov rdx, r12
mov qword [rsp + 0x28], rbp
mov qword [rsp + 0x20], rbx
call fcn.18012e1f0
mov edi, eax
test eax, eax
js 0x18016de3a
xor esi, esi
jmp 0x18016e352
mov rbp, qword [rsp + 0x68]
mov r12, qword [rsp + 0x60]
or rax, 0xffffffffffffffff
mov rcx, rsi
mov rdi, r12
mov r10, r14
rep stosq qword [rdi], rax
mov rdi, rbp
mov r9, rsi
sub r10, rbp
nop word [rax + rax]
mov rax, qword [r10 + rdi]
mov rcx, r13
mov edx, dword [rax + 0xa4]
call fcn.1801067e0
add rdi, 8
sub r9, 1
mov rcx, qword [rax]
mov qword [rdi - 8], rcx
jne 0x18016e1a0
mov rdx, qword [rsp + 0xd8]
mov dword [rsp + 0x40], 0x11
mov dword [rsp + 0x38], r11d
mov qword [rsp + 0x30], r11
mov r8d, esi
mov r9, r12
and r8d, 0xfffff
mov rcx, r13
mov qword [rsp + 0x28], rbp
or r8d, 0x21a00000
mov qword [rsp + 0x20], r14
call fcn.18012ed20
mov edi, eax
test eax, eax
js 0x18016de3a
cmp esi, 1
jbe 0x18016e2a9
mov ebx, esi
shr ebx, 1
je 0x18016e228
mov ecx, ebx
mov rdi, rbp
or rax, 0xffffffffffffffff
rep stosq qword [rdi], rax
mov rdx, qword [rsp + 0xd8]
xor ecx, ecx
mov dword [rsp + 0x40], 0x11
mov dword [rsp + 0x38], ecx
mov qword [rsp + 0x30], rcx
mov r8d, ebx
lea rax, [r12 + rbx*8]
and r8d, 0xfffff
mov r9, rbp
mov qword [rsp + 0x28], rax
or r8d, 0x22e00000
mov rcx, r13
mov qword [rsp + 0x20], r12
call fcn.18012ed20
mov edi, eax
test eax, eax
js 0x18016de3a
lea eax, [rbx + rbx]
cmp eax, esi
je 0x18016e28c
lea eax, [rsi - 1]
mov rax, qword [r12 + rax*8]
mov qword [rbp + rbx*8], rax
inc ebx
mov r8d, ebx
mov rdx, rbp
mov rcx, r12
shl r8, 3
call sub.msvcrt.dll_memcpy
mov esi, ebx
cmp ebx, 1
ja 0x18016e216
mov rbx, qword [rsp + 0x78]
xor esi, esi
mov r8d, 0x22d00001
mov dword [rsp + 0x40], esi
mov qword [rbx], 0xffffffffffffffff
mov ecx, dword [r13 + 0x128]
mov rax, qword [r13 + 0x30]
mov dword [rsp + 0x38], esi
mov qword [rsp + 0x30], rsi
lea rdx, [rax + rcx*8]
mov r9, rbx
mov rcx, r13
mov qword [rsp + 0x28], rdx
mov qword [rsp + 0x20], r12
mov r12, qword [rsp + 0xd8]
mov rdx, r12
call fcn.18012ed20
mov edi, eax
test eax, eax
js 0x18016de3a
mov rax, qword [r13 + 0x10]
mov dword [rsp + 0x40], 0x11
lea r9, [rsp + 0x50]
mov rcx, qword [rax + 0xd118]
lea rax, [rsp + 0xd0]
mov r8d, 0x70400001
mov qword [rsp + 0x38], rcx
mov qword [rsp + 0x30], rsi
mov qword [rsp + 0x28], rax
mov rcx, r13
mov rdx, r12
mov qword [rsp + 0x20], rbx
call fcn.18012e1f0
mov edi, eax
test eax, eax
js 0x18016de3a
mov rax, qword [r13 + 0x30]
mov ecx, dword [r13 + 0x64]
mov dword [rsp + 0x40], 0x11
mov rcx, qword [rax + rcx*8]
mov rax, qword [r13 + 0x10]
lea r9, [rsp + 0xd0]
mov qword [rsp + 0xd0], rcx
mov rcx, qword [rax + 0xd118]
lea rax, [rsp + 0x50]
mov qword [rsp + 0x38], rcx
mov qword [rsp + 0x30], rsi
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0xd0]
mov r8d, 0x23b00001
mov rdx, r12
mov rcx, r13
mov qword [rsp + 0x20], rax
call fcn.18012e1f0
mov edi, eax
test eax, eax
js 0x18016de3a
mov r8, qword [rsp + 0xd0]
mov eax, dword [r13 + 0x64]
mov rcx, r13
mov dword [r8 + 0xdc], eax
mov edx, dword [r13 + 0x64]
call fcn.18010a220
mov edi, eax
test eax, eax
cmovns edi, esi
jmp 0x18016de3a
mov edi, 0x80004005
jmp 0x18016de3a
mov rax, qword [rdx]
mov qword [rcx], rax
call fcn.1800c56f0
mov eax, edi
add rsp, 0xc0
pop rdi
ret