Function at 0x4a1610
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
and esp, 0xfffffff8
sub esp, 0x28
mov esi, ecx
mov eax, dword [0x597010]
xor eax, ebp
mov dword [esp + 0x20], eax
mov ebx, dword [0x5aaba8]
cmp ebx, 1
ja 0x4a167f
mov dword [esp], 0x5aaba8
call fcn.00473460
test al, al
je 0x4a1679
mov dword [0x5aabb0], 0
mov dword [0x5aabac], 0xffffffff
mov dword [esp], 0
mov ebx, 0x5aabac
mov ecx, 0x5aabac
call fcn.004624b0
sub esp, 4
mov dword [0x5aaba8], ebx
jmp 0x4a167f
mov ebx, dword [0x5aaba8]
mov eax, dword [0x599b44]
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
sub esp, 4
xor edi, edi
and eax, 0xfffffffc
je 0x4a16a5
mov ecx, dword [ebx]
mov edx, dword [eax + ecx*8 + 4]
cmp edx, dword [ebx + 4]
jne 0x4a16a5
mov edi, dword [eax + ecx*8]
mov eax, edi
shr eax, 0xe
mov ecx, edi
shr ecx, 0x13
mov ecx, dword [ecx*4 + 0x59f9d0]
bt ecx, eax
jae 0x4a16c5
mov dword [esp], edi
call fcn.0042f0b8
jmp 0x4a16d1
mov eax, edi
shr eax, 0x15
mov byte [eax + 0x5a79d0], 1
mov dword [esi], edi
mov ebx, dword [0x5aabb4]
cmp ebx, 1
ja 0x4a1729
mov dword [esp], 0x5aabb4
call fcn.00473460
test al, al
je 0x4a1723
mov dword [0x5aabbc], 0
mov dword [0x5aabb8], 0xffffffff
mov dword [esp], 0
mov ebx, 0x5aabb8
mov ecx, 0x5aabb8
call fcn.004624b0
sub esp, 4
mov dword [0x5aabb4], ebx
jmp 0x4a1729
mov ebx, dword [0x5aabb4]
mov eax, dword [0x599b44]
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
sub esp, 4
xor edi, edi
and eax, 0xfffffffc
je 0x4a174f
mov ecx, dword [ebx]
mov edx, dword [eax + ecx*8 + 4]
cmp edx, dword [ebx + 4]
jne 0x4a174f
mov edi, dword [eax + ecx*8]
mov eax, edi
shr eax, 0xe
mov ecx, edi
shr ecx, 0x13
mov ecx, dword [ecx*4 + 0x59f9d0]
bt ecx, eax
jae 0x4a176f
mov dword [esp], edi
call fcn.0042f0b8
jmp 0x4a177b
mov eax, edi
shr eax, 0x15
mov byte [eax + 0x5a79d0], 1
mov dword [esi + 4], edi
cmp dword [ebp + 8], 1
sete bl
mov eax, ebx
je 0x4a1793
test edi, edi
je 0x4a1793
movzx eax, byte [edi + 8]
xor ebx, ebx
mov byte [esi + 8], al
mov byte [esi + 0x10], 0
mov edi, dword [0x5aabb4]
cmp edi, 1
ja 0x4a17f0
mov dword [esp], 0x5aabb4
call fcn.00473460
test al, al
je 0x4a17ea
mov dword [0x5aabbc], 0
mov dword [0x5aabb8], 0xffffffff
mov dword [esp], 0
mov edi, 0x5aabb8
mov ecx, 0x5aabb8
call fcn.004624b0
sub esp, 4
mov dword [0x5aabb4], edi
jmp 0x4a17f0
mov edi, dword [0x5aabb4]
mov eax, dword [0x599b44]
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
sub esp, 4
and eax, 0xfffffffc
je 0x4a1a17
mov ecx, dword [edi]
mov dword [eax + ecx*8], esi
mov ecx, dword [edi]
mov edx, dword [edi + 4]
mov dword [eax + ecx*8 + 4], edx
mov edi, dword [0x5aad6c]
cmp edi, 1
ja 0x4a186e
mov dword [esp], 0x5aad6c
call fcn.00473460
test al, al
je 0x4a1868
mov dword [0x5aad74], 0
mov dword [0x5aad70], 0xffffffff
mov dword [esp], 0
mov edi, 0x5aad70
mov ecx, 0x5aad70
call fcn.004624b0
sub esp, 4
mov dword [0x5aad6c], edi
jmp 0x4a186e
mov edi, dword [0x5aad6c]
mov eax, dword [0x599b44]
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
sub esp, 4
and eax, 0xfffffffc
je 0x4a189f
mov ecx, dword [edi]
mov edx, dword [eax + ecx*8 + 4]
cmp edx, dword [edi + 4]
jne 0x4a189f
mov eax, dword [eax + ecx*8]
test eax, eax
je 0x4a189f
cmp byte [eax], 0
je 0x4a1992
cmp dword [ebp + 0xc], 0
jne 0x4a18ab
cmp byte [esi + 8], 0
je 0x4a18e5
mov eax, dword [esi + 4]
test eax, eax
je 0x4a19bc
cmp byte [eax + 0x10], 0
je 0x4a19bc
mov ecx, dword [eax + 0x20]
mov dword [eax + 0x20], 0
test ecx, ecx
je 0x4a19bc
lock dec dword [ecx]
jne 0x4a19bc
call fcn.004a1c60
jmp 0x4a19bc
cmp dword [esi + 4], 0
jne 0x4a19bc
cmp byte [esi + 0x10], 0
je 0x4a194f
mov edi, dword [esi + 0x20]
test edi, edi
je 0x4a194b
mov ecx, dword [0x599b40]
call dword [section..00cfg]
lea eax, [esp + 0x18]
mov dword [esp], eax
call ecx
movsd xmm0, qword [esi + 0x18]
movsd qword [esp + 0x10], xmm0
movsd xmm0, qword [esp + 0x18]
movsd qword [esp + 8], xmm0
movsd xmm0, qword [esp + 0x10]
movsd qword [esp], xmm0
mov ecx, edi
call fcn.004a12e0
mov ecx, dword [esi + 0x20]
test ecx, ecx
je 0x4a194b
lock dec dword [ecx]
jne 0x4a194b
call fcn.004a1c60
mov byte [esi + 0x10], 0
lea edi, [esi + 0x18]
mov ecx, dword [0x599b40]
call dword [section..00cfg]
mov dword [esp], edi
call ecx
lea ecx, [esi + 0x20]
call fcn.004a1210
mov ecx, dword [esi + 0x20]
test ecx, ecx
je 0x4a198c
mov eax, dword [ecx + 0xf8]
mov ecx, dword [ecx + 0xfc]
mov edx, dword [edi + 4]
cmp dword [edi], eax
sbb edx, ecx
jge 0x4a198c
mov dword [edi], eax
mov dword [edi + 4], ecx
mov byte [esi + 0x10], 1
jmp 0x4a19bc
mov eax, dword [0x5aad7c]
mov ecx, dword [0x59b038]
mov edx, dword fs:[0x2c]
mov ecx, dword [edx + ecx*4]
cmp eax, dword [ecx + 4]
jg 0x4a1a29
cmp byte [0x5aad78], 0
je 0x4a189f
mov edi, dword [esi]
test edi, edi
je 0x4a1a00
mov eax, dword [esi + 4]
test eax, eax
je 0x4a19e6
test bl, bl
je 0x4a1a00
cmp byte [eax + 8], 0
jne 0x4a1a00
mov eax, dword [edi]
mov ebx, dword [eax + 8]
mov ecx, ebx
call dword [section..00cfg]
mov ecx, edi
call ebx
jmp 0x4a1a00
mov eax, dword [edi]
mov ebx, dword [eax + 4]
mov ecx, ebx
call dword [section..00cfg]
mov eax, dword [ebp + 8]
mov dword [esp], eax
mov ecx, edi
call ebx
sub esp, 4
mov ecx, dword [esp + 0x20]
xor ecx, ebp
call fcn.00528e13
mov eax, esi
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret 8
test esi, esi
je 0x4a1818
call fcn.004625e0
jmp 0x4a180a
mov dword [esp], 0x5aad7c
call fcn.00528497
cmp dword [0x5aad7c], 0xffffffff
jne 0x4a19af
mov ecx, dword [0x59d954]
test ecx, ecx
je 0x4a1a5b
mov dword [esp], str.enable_background_thread_pool
call fcn.00478be0
sub esp, 4
mov byte [0x5aad78], 1
mov dword [esp], 0x5aad7c
call fcn.0052850d
jmp 0x4a19af