Function at 0x10005500
Capabilities:
Allocate thread local storage

Disassembly:
push 0x14
mov eax, 0x10024d1b
call fcn.1002476e
xor ecx, ecx
xor ebx, ebx
mov dword [ebp - 0x10], ecx
mov esi, ecx
inc ebx
mov dword [ebp - 0x18], ecx
mov dword [ebp - 0x14], esi
mov eax, dword [ebp + 0xc]
mov dword [ebp - 4], ecx
sub eax, ecx
je 0x100056aa
sub eax, ebx
je 0x10005541
dec eax
sub eax, ebx
jne 0x10005742
call fcn.10008b4e
jmp 0x10005742
mov dword [0x1002a7c0], ecx
mov dword [0x1002a7b0], ecx
mov dword [0x1002a7c8], 1
mov dword [0x1002a7cc], ecx
mov dword [0x1002a7d8], 0x10002538
mov dword [section..data], 0x1002a7b0
call fcn.100054a4
call fcn.10005cd2
mov ecx, eax
call fcn.1000832a
mov ebx, eax
test ebx, ebx
jne 0x100055c6
mov ecx, dword [section..data]
cmp ecx, section..data
je 0x10005742
test byte [ecx + 0x1c], 1
je 0x10005742
cmp byte [ecx + 0x19], 2
jb 0x10005742
push dword [ecx + 0x14]
push dword [ecx + 0x10]
push 0xa
mov edx, 0x1000259c
pop ecx
call fcn.10004d9a
jmp 0x10005742
push 0x10
mov byte [ebp - 4], 1
call fcn.10023e16
mov esi, eax
mov dword [ebp - 0x10], esi
pop ecx
test esi, esi
je 0x100055f3
xor eax, eax
mov dword [esi], 0x10001558
inc eax
mov dword [esi + 4], eax
mov dword [esi + 8], eax
mov dword [esi + 0xc], 0x10001550
jmp 0x100055f5
xor esi, esi
mov dword [ebp - 0x14], esi
lea ecx, [esi + 0xc]
mov dword [ebp - 0x18], ecx
mov byte [ebp - 4], 0
test esi, esi
je 0x1000560f
lea eax, [esi + 4]
lock inc dword [eax]
lock inc dword [eax]
mov eax, dword [0x1002a7f8]
mov dword [0x1002a7f8], esi
mov dword [0x1002a7f4], ecx
test eax, eax
je 0x1000562b
mov ecx, eax
call fcn.10005928
test esi, esi
je 0x10005636
mov ecx, esi
call fcn.10005928
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
mov dword [0x1002a2b0], eax
cmp eax, 0xffffffff
jne 0x10005679
xor ebx, ebx
mov eax, dword [section..data]
cmp eax, section..data
je 0x10005742
test byte [eax + 0x1c], 1
je 0x10005742
cmp byte [eax + 0x19], 2
jb 0x10005742
push dword [eax + 0x14]
push dword [eax + 0x10]
push 0xb
jmp 0x100055b6
mov eax, dword [section..data]
cmp eax, section..data
je 0x10005742
test byte [eax + 0x1c], 1
je 0x10005742
cmp byte [eax + 0x19], 5
jb 0x10005742
push dword [eax + 0x14]
push dword [eax + 0x10]
push 0xc
jmp 0x100055b6
push ecx
call fcn.10005c6d
mov ecx, eax
call fcn.1000a852
mov eax, dword [0x1002a2b0]
cmp eax, 0xffffffff
je 0x100056cd
cmp eax, 0x40
je 0x100056cd
push eax
call dword [sym.imp.KERNEL32.dll_TlsFree]
call fcn.10005cd2
mov ecx, eax
call fcn.100085f8
mov edi, dword [section..data]
cmp edi, section..data
je 0x10005742
test byte [edi + 0x1c], 1
je 0x1000570c
cmp byte [edi + 0x19], 5
jb 0x1000570c
push dword [edi + 0x14]
mov edx, 0x1000259c
push dword [edi + 0x10]
push 0xd
pop ecx
call fcn.10004d9a
mov edi, dword [section..data]
cmp edi, section..data
je 0x10005742
jmp 0x10005734
mov eax, dword [edi + 8]
or eax, dword [edi + 0xc]
je 0x10005732
push dword [edi + 0xc]
push dword [edi + 8]
call dword [sym.imp.ADVAPI32.dll_UnregisterTraceGuids]
and dword [edi + 8], 0
and dword [edi + 0xc], 0
mov edi, dword [edi]
test edi, edi
jne 0x10005716
mov dword [section..data], 0x1002a000
or dword [ebp - 4], 0xffffffff
test esi, esi
je 0x10005751
mov ecx, esi
call fcn.10005928
mov eax, ebx
call fcn.1002473c
ret 0xc