Function at 0x101a9710
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
sub esp, 0x2c
mov esi, ecx
mov eax, dword [0x102b0014]
xor eax, ebp
mov dword [ebp - 0x10], eax
mov eax, dword [ecx + 4]
cmp eax, dword [ecx + 8]
je 0x101a973c
mov ecx, dword [edx]
mov dword [eax], ecx
add eax, 4
mov dword [esi + 4], eax
jmp 0x101a98ec
sub eax, dword [esi]
mov edi, eax
sar edi, 2
lea ecx, [edi + 1]
cmp ecx, 0x40000000
jae 0x101a9a9e
sar eax, 1
cmp eax, ecx
cmovb eax, ecx
cmp edi, 0x1fffffff
mov ebx, 0x3fffffff
cmovb ebx, eax
test ebx, ebx
mov dword [ebp - 0x38], edi
mov dword [ebp - 0x2c], ebx
je 0x101a9878
mov dword [ebp - 0x34], edx
mov dword [ebp - 0x28], esi
call fcn.101aafb0
mov dword [ebp - 0x20], eax
mov dword [ebp - 0x24], eax
lea esi, [ebx*4]
mov eax, 0x20
mov ecx, 0x20
test esi, esi
je 0x101a97a1
bsr ecx, esi
xor ecx, 0x1f
sub eax, ecx
mov cl, byte [eax + 0x102641e0]
mov edx, esi
shr edx, cl
and edx, 7
mov ecx, dword [eax*4 + 0x10264204]
mov dword [ebp - 0x30], esi
and ecx, esi
lea esi, [edx + eax*8]
cmp ecx, 1
sbb esi, 0xffffffff
mov byte [ebp - 0x11], 0
mov dword [ebp - 0x18], 0xffffffff
mov eax, dword [ebp - 0x24]
cmp byte [eax], 2
jne 0x101a97e5
mov al, byte [0x102b323c]
cmp al, 2
je 0x101a9a94
movzx ecx, word [esi + esi + 0x10263fcc]
mov eax, dword [ebp - 0x24]
cmp byte [eax + 2], 0
je 0x101a98fe
mov dword [ebp - 0x1c], ecx
mov edi, dword [0x102b910c]
call dword [sym.imp.kernel32.dll_GetLastError]
mov ebx, eax
push edi
call dword [sym.imp.kernel32.dll_TlsGetValue]
mov edi, eax
test ebx, ebx
jne 0x101a9967
cmp edi, 2
mov edx, dword [ebp - 0x1c]
jb 0x101a9973
add dword [edi + 0x310], 1
adc dword [edi + 0x314], 0
cmp dx, 0x31
jae 0x101a9992
cmp dword [edi + edx*8], 0
mov esi, dword [ebp - 0x28]
je 0x101a9a55
add dword [edi + 0x318], 1
adc dword [edi + 0x31c], 0
mov ebx, dword [edi + edx*8]
mov eax, dword [ebx]
test eax, eax
je 0x101a987c
mov ecx, eax
not ecx
cmp dword [ebx + 4], ecx
jne 0x101a9a8f
bswap eax
prefetcht0 byte [eax]
jmp 0x101a987e
xor ebx, ebx
jmp 0x101a98a4
bswap eax
add byte [edi + edx*8 + 4], 0xff
mov dword [edi + edx*8], eax
movzx eax, word [edi + edx*8 + 6]
mov dword [ebp - 0x18], eax
movzx eax, word [edi + edx*8 + 6]
sub dword [edi + 0x308], eax
test ebx, ebx
je 0x101a99ae
mov edx, dword [ebp - 0x34]
mov ecx, dword [ebp - 0x38]
lea edi, [ebx + ecx*4]
mov eax, dword [ebp - 0x2c]
lea eax, [ebx + eax*4]
mov dword [ebp - 0x2c], eax
mov eax, dword [edx]
mov dword [ebx + ecx*4], eax
lea ebx, [ebx + ecx*4]
add ebx, 4
mov ecx, dword [esi]
mov eax, dword [esi + 4]
sub eax, ecx
sub edi, eax
test eax, eax
jle 0x101a98d8
push eax
push ecx
push edi
call fcn.10208400
add esp, 0xc
mov ecx, dword [esi]
mov dword [esi], edi
mov dword [esi + 4], ebx
mov eax, dword [ebp - 0x2c]
mov dword [esi + 8], eax
test ecx, ecx
je 0x101a98ec
call fcn.101a88b0
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.10205d16
add esp, 0x2c
pop esi
pop edi
pop ebx
pop ebp
ret
shl ecx, 5
mov eax, dword [ebp - 0x20]
lea ebx, [eax + ecx]
add ebx, 0x10
add eax, 8
mov dword [ebp - 0x1c], 1
mov dword [ebp - 0x20], 0
mov edi, dword [sym.imp.kernel32.dll_TryAcquireSRWLockExclusive]
mov esi, eax
push eax
call edi
test al, al
jne 0x101a9a15
mov ecx, dword [ebp - 0x1c]
mov eax, ecx
test ecx, ecx
jle 0x101a9944
pause
add eax, 0xffffffff
jne 0x101a9937
mov eax, dword [ebp - 0x1c]
add dword [ebp - 0x20], eax
mov eax, dword [ebp - 0x1c]
add eax, eax
cmp eax, 0x40
mov ecx, 0x40
cmovge eax, ecx
mov dword [ebp - 0x1c], eax
cmp dword [ebp - 0x20], 0x3e8
mov eax, esi
jl 0x101a9921
jmp 0x101a9a0e
push ebx
call dword [sym.imp.kernel32.dll_SetLastError]
jmp 0x101a981c
lea eax, [ebp - 0x18]
mov ecx, dword [ebp - 0x24]
push eax
push edx
call fcn.101a1710
mov edx, dword [ebp - 0x1c]
mov ebx, eax
mov esi, dword [ebp - 0x28]
test ebx, ebx
jne 0x101a98a1
jmp 0x101a99ae
add dword [edi + 0x330], 1
adc dword [edi + 0x334], 0
add dword [edi + 0x320], 1
adc dword [edi + 0x324], 0
shl edx, 5
mov eax, dword [ebp - 0x20]
lea ebx, [eax + edx]
add ebx, 0x10
add eax, 8
mov dword [ebp - 0x1c], 1
mov dword [ebp - 0x20], 0
mov edi, dword [sym.imp.kernel32.dll_TryAcquireSRWLockExclusive]
mov esi, eax
push eax
call edi
test al, al
jne 0x101a9a15
mov ecx, dword [ebp - 0x1c]
mov eax, ecx
test ecx, ecx
jle 0x101a99f0
pause
add eax, 0xffffffff
jne 0x101a99e3
mov eax, dword [ebp - 0x1c]
add dword [ebp - 0x20], eax
mov eax, dword [ebp - 0x1c]
add eax, eax
cmp eax, 0x40
mov ecx, 0x40
cmovge eax, ecx
mov dword [ebp - 0x1c], eax
cmp dword [ebp - 0x20], 0x3e8
mov eax, esi
jl 0x101a99d1
push eax
call dword [sym.imp.kernel32.dll_AcquireSRWLockExclusive]
mov ecx, ebx
mov eax, dword [ebx]
mov ebx, dword [eax]
test ebx, ebx
je 0x101a9aa5
mov byte [ebp - 0x11], 0
mov ecx, dword [ebx]
test ecx, ecx
je 0x101a9a3d
mov edx, ecx
not edx
cmp dword [ebx + 4], edx
jne 0x101a9a8f
bswap ecx
prefetcht0 byte [ecx]
jmp 0x101a9a3f
bswap ecx
mov dword [eax], ecx
add word [eax + 0xc], 1
push esi
call dword [sym.imp.kernel32.dll_ReleaseSRWLockExclusive]
mov esi, dword [ebp - 0x28]
jmp 0x101a98a1
add dword [edi + 0x328], 1
adc dword [edi + 0x32c], 0
add dword [edi + 0x320], 1
adc dword [edi + 0x324], 0
mov ecx, edi
push edx
call fcn.101a3420
mov edx, dword [ebp - 0x1c]
mov esi, dword [ebp - 0x28]
mov ebx, dword [edi + edx*8]
test ebx, ebx
jne 0x101a985e
jmp 0x101a99ae
call fcn.1002c4d0
call fcn.101a12f0
jmp 0x101a97e5
mov ecx, esi
call fcn.1002bb40
lea eax, [ebp - 0x11]
push eax
push 0x4000
push dword [ebp - 0x30]
push 0
push dword [ebp - 0x24]
call fcn.1002bc80
mov ebx, eax
test eax, eax
jne 0x101a9a46
xor ebx, ebx
jmp 0x101a9a46