Function at 0x10001e90
Capabilities:
Get thread local storage value
Resolve function by parsing pe exports

Disassembly:
push ecx
push ebx
mov ebx, dword [esp + 0xc]
imul ebx, dword [esp + 0x10]
test ebx, ebx
push esi
je 0x100077cf
mov eax, dword [esp + 0x10]
or eax, dword [esp + 0x14]
test eax, 0xffff0000
jne 0x100077d9
cmp ebx, 0xff000
ja 0x10007848
mov ecx, dword [0x1000a010]
push ecx
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
test eax, eax
je 0x1000225d
cmp ebx, 0x800
push ebp
mov esi, eax
push edi
ja 0x10001fc7
cmp ebx, 9
jb 0x100020ce
cmp ebx, 0x200
ja 0x10002009
add ebx, 0xf
and ebx, 0xfffffff0
mov eax, ebx
shr eax, 4
lea ecx, [eax + eax*8]
lea edi, [esi + ecx*8 + 0x150]
lea ebp, [esi + 4]
push ebp
mov dword [esp + 0x1c], ebp
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov edx, dword [edi]
test edx, edx
je 0x10002051
cmp dword [edx + 8], 0
jbe 0x10002051
mov eax, dword [edx + 4]
mov ecx, dword [edx + eax*4 + 0xc]
test ecx, ecx
je 0x10002124
bsf ecx, ecx
mov dword [esp + 0x1c], eax
je 0x1000781b
add ecx, 1
shl eax, 5
add ecx, 0xffffffff
add eax, ecx
imul eax, dword [edi + 0x14]
add eax, dword [edi + 0x24]
mov ebp, 1
shl ebp, cl
mov ecx, dword [esp + 0x1c]
add eax, edx
xor ebp, dword [edx + ecx*4 + 0xc]
mov dword [edx + ecx*4 + 0xc], ebp
add dword [edx + 8], 0xffffffff
mov ebp, eax
test ebp, ebp
je 0x10007829
mov edx, dword [esp + 0x18]
mov eax, 1
add dword [edi + 0x28], eax
mov ecx, 0
push edx
adc dword [edi + 0x2c], ecx
add dword [esi + 0x60], eax
adc dword [esi + 0x64], ecx
add dword [esi + 0x5c], ebx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
push ebx
push 0
push ebp
call sub.MSVCR80.dll_memset
add esp, 0xc
pop edi
mov esi, ebp
pop ebp
test esi, esi
je 0x100077ef
mov eax, esi
pop esi
pop ebx
pop ecx
ret
lea edi, [esi + 4]
add ebx, 0xfff
push edi
and ebx, 0xfffff000
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
push 1
push 1
push ebx
push esi
call fcn.10002270
add esp, 0x10
test eax, eax
push edi
je 0x1000783b
add dword [esi + 0x78], 1
mov ebp, eax
adc dword [esi + 0x7c], 0
add dword [esi + 0x70], ebx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
jmp 0x10001fb5
lea eax, [ebx - 1]
mov edx, eax
shr edx, 1
or eax, edx
mov ecx, eax
shr ecx, 2
or eax, ecx
mov edx, eax
shr edx, 4
or eax, edx
mov ecx, eax
shr ecx, 8
or eax, ecx
mov ebx, eax
shr ebx, 0x10
or ebx, eax
add ebx, 1
mov edx, ebx
shr edx, 9
bsf eax, edx
je 0x10007800
add eax, 1
lea eax, [eax + eax*8]
lea edi, [esi + eax*8 + 0xa08]
jmp 0x10001f12
mov eax, dword [edi + 4]
mov ecx, dword [eax]
lea edx, [edi + 8]
cmp ecx, edx
je 0x10002179
mov dword [esp + 0x1c], ecx
mov ecx, dword [ecx]
cmp ecx, edx
jne 0x10002061
mov eax, dword [esp + 0x1c]
cmp eax, edx
je 0x10002194
test eax, eax
je 0x10002194
lea ecx, [edi + 4]
push ecx
call fcn.10004570
mov edx, dword [esp + 0x20]
mov edx, dword [edx + 8]
add esp, 4
and edx, 0xfffff000
add dword [edi + 0x38], 1
adc dword [edi + 0x3c], 0
test edx, edx
mov dword [edi], edx
je 0x1000782d
mov eax, dword [edx + 4]
mov ecx, dword [edx + eax*4 + 0xc]
test ecx, ecx
je 0x1000222f
bsf ecx, ecx
mov dword [esp + 0x1c], eax
je 0x1000781b
add ecx, 1
jmp 0x10001f53
lea eax, [ebx - 1]
mov edx, eax
shr edx, 1
or eax, edx
mov ecx, eax
shr ecx, 2
or eax, ecx
mov edx, eax
shr edx, 4
or eax, edx
mov ecx, eax
shr ecx, 8
or eax, ecx
mov ebx, eax
shr ebx, 0x10
or ebx, eax
add ebx, 1
mov edx, ebx
shr edx, 2
bsf eax, edx
je 0x10002267
add eax, 1
cmp ebx, 2
lea eax, [eax + eax*8]
lea edi, [esi + eax*8 + 0xc0]
jae 0x10001f12
mov ebx, 2
jmp 0x10001f12
add eax, 1
cmp eax, dword [edi + 0x20]
jae 0x1000218d
lea ebp, [edx + eax*4 + 0xc]
mov ecx, dword [ebp]
test ecx, ecx
je 0x10002182
mov dword [esp + 0x1c], ecx
bsf ecx, ecx
je 0x10007822
add ecx, 1
mov ebp, eax
shl ebp, 5
add ecx, 0xffffffff
add ebp, ecx
imul ebp, dword [edi + 0x14]
add ebp, dword [edi + 0x24]
add ebp, edx
mov dword [esp + 0x10], ebp
mov ebp, 1
shl ebp, cl
xor ebp, dword [esp + 0x1c]
mov dword [edx + eax*4 + 0xc], ebp
mov dword [edx + 4], eax
mov eax, dword [esp + 0x10]
jmp 0x10001f77
mov dword [esp + 0x1c], eax
jmp 0x1000206f
add eax, 1
add ebp, 4
cmp eax, dword [edi + 0x20]
jb 0x10002130
xor eax, eax
jmp 0x10001f77
mov eax, dword [edi + 0x18]
push 0
push 0
push eax
push esi
call fcn.10002270
add esp, 0x10
test eax, eax
je 0x10007807
cmp eax, dword [edi]
je 0x10002228
mov dword [eax], edi
mov edx, dword [edi + 0x20]
xor ecx, ecx
sub edx, 1
je 0x100021e0
lea edx, [eax + 0xc]
jmp 0x100021c6
mov edx, dword [esp + 0x1c]
mov dword [edx], 0xffffffff
add edx, 4
mov dword [esp + 0x1c], edx
mov edx, dword [edi + 0x20]
add ecx, 1
sub edx, 1
cmp ecx, edx
jb 0x100021c2
mov edx, dword [edi + 0x1c]
and edx, 0x1f
mov dword [esp + 0x1c], ecx
je 0x1000780e
mov ecx, 0x20
sub ecx, edx
or edx, 0xffffffff
shr edx, cl
mov ecx, dword [esp + 0x1c]
mov dword [eax + ecx*4 + 0xc], edx
xor ecx, ecx
mov dword [eax + 4], ecx
mov edx, dword [edi + 0x1c]
mov dword [eax + 8], edx
mov edx, 1
add dword [edi + 0x30], edx
adc dword [edi + 0x34], ecx
add dword [edi + 0x44], edx
mov ecx, dword [edi + 0x44]
cmp ecx, dword [edi + 0x40]
jbe 0x10002228
mov dword [edi + 0x40], ecx
mov edx, eax
jmp 0x100020a0
add eax, 1
cmp eax, dword [edi + 0x20]
jae 0x1000218d
lea ebp, [edx + eax*4 + 0xc]
nop
mov ecx, dword [ebp]
test ecx, ecx
jne 0x10002137
add eax, 1
add ebp, 4
cmp eax, dword [edi + 0x20]
jb 0x10002240
xor eax, eax
jmp 0x10001f77
call fcn.100010d0
jmp 0x10001ed8
xor eax, eax
jmp 0x10002107
mov ebx, 1
jmp 0x10001ec3
mov esi, dword [esp + 0x14]
xor edx, edx
mov eax, ebx
div esi
cmp eax, dword [esp + 0x10]
je 0x10001eb7
xor esi, esi
call dword [sym.imp.MSVCR80.dll__errno]
mov dword [eax], 0xc
jmp 0x10001fc1
xor eax, eax
jmp 0x10002042
xor edx, edx
jmp 0x100020a0
mov dword [eax + ecx*4 + 0xc], 0xffffffff
jmp 0x10002204
xor ecx, ecx
jmp 0x10001f53
xor ecx, ecx
jmp 0x10002147
mov ebp, dword [esp + 0x18]
push ebp
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
xor ebp, ebp
jmp 0x10001fb5
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
xor ebp, ebp
jmp 0x10001fb5
mov eax, ebx
call fcn.10005480
mov esi, eax
jmp 0x10001fb9