Function at 0x4aebd0
Capabilities:
Get thread local storage value

Disassembly:
sub esp, 0x1c8
push ebx
push ebp
push esi
push edi
mov edi, ecx
xor ebx, ebx
cmp dword [edi + 0x12c], ebx
jle 0x4aec39
xor ebp, ebp
nop dword [eax + eax]
push dword [0x884adc]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
push 0x20c
mov ecx, dword [eax + 0x2c]
mov eax, dword [ecx]
call dword [eax + 4]
mov esi, eax
test esi, esi
je 0x4aec21
push 0x20c
push 0
push esi
call fcn.00609f40
add esp, 0xc
jmp 0x4aec23
xor esi, esi
mov eax, dword [edi + 0x128]
inc ebx
mov dword [eax + ebp + 4], esi
add ebp, 0xc
cmp ebx, dword [edi + 0x12c]
jl 0x4aebf0
mov eax, dword [esp + 0x1dc]
mov esi, dword [edi + 0x110]
mov dword [esp + 0x1c], esi
mov ecx, dword [eax + 4]
mov dword [esp + 0x18], ecx
test ecx, ecx
jns 0x4aec61
mov ecx, dword [edi + 0x134]
sub ecx, dword [eax]
mov dword [esp + 0x18], ecx
cmp esi, 1
jle 0x4aec7f
push 0x4af330
lea eax, [esi - 1]
push eax
push 0
push dword [edi + 0x10c]
call fcn.004af000
add esp, 0x10
mov eax, dword [edi + 0x110]
mov edx, dword [edi + 0x10c]
mov dword [esp + 0x10], edx
lea ebx, [eax*8]
sub ebx, eax
add ebx, edx
cmp edx, ebx
jae 0x4aed9c
movzx ecx, byte [edx]
lea esi, [edx + 7]
cmp esi, ebx
jae 0x4aecbe
nop dword [eax]
movzx eax, byte [esi]
cmp eax, ecx
jne 0x4aecbe
add esi, 7
cmp esi, ebx
jb 0x4aecb0
mov eax, dword [edi + 0x128]
lea ecx, [ecx + ecx*2]
lea eax, [eax + ecx*4]
mov ecx, esi
mov dword [esp + 0x14], eax
sub ecx, edx
mov eax, 0x92492493
imul ecx
xor eax, eax
add edx, ecx
sar edx, 2
mov ebp, edx
shr ebp, 0x1f
add ebp, edx
mov dword [esp + 0x30], ebp
test ebp, ebp
jle 0x4aed1d
mov edx, dword [esp + 0x10]
add edx, 4
nop word [eax + eax]
movzx ecx, byte [edx - 3]
lea edx, [edx + 7]
mov dword [esp + eax*4 + 0x34], ecx
mov cl, byte [edx - 7]
mov byte [edx - 9], al
mov byte [esp + eax + 0xb4], cl
inc eax
cmp eax, ebp
jl 0x4aed00
mov ebp, dword [esp + 0x14]
cmp dword [ebp + 4], 0
jne 0x4aed63
push dword [0x884adc]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
push 0x20c
mov ecx, dword [eax + 0x2c]
mov eax, dword [ecx]
call dword [eax + 4]
mov ebp, eax
test ebp, ebp
je 0x4aed58
push 0x20c
push 0
push ebp
call fcn.00609f40
add esp, 0xc
jmp 0x4aed5a
xor ebp, ebp
mov eax, dword [esp + 0x14]
mov dword [eax + 4], ebp
mov ebp, eax
mov ecx, dword [ebp]
lea edx, [esp + 0x30]
push dword [ebp + 4]
push edx
mov eax, dword [ecx]
push dword [esp + 0x1e4]
call dword [eax + 0x20]
mov dword [esp + 0x10], eax
cmp eax, 1
jne 0x4aee35
mov byte [ebp + 8], al
mov edx, esi
mov dword [esp + 0x10], edx
cmp esi, ebx
jb 0x4aeca2
mov esi, dword [esp + 0x1c]
mov ebp, dword [esp + 0x1e0]
lea ecx, [esp + 0xd4]
mov ebx, dword [esp + 0x18]
mov dword [ebp + 0x200], esi
mov dword [ebp + 0x204], ebx
mov byte [ebp + 0x208], 0
call fcn.004af390
test esi, esi
jle 0x4aeeb7
xor eax, eax
mov dword [esp + 0x14], esi
mov dword [esp + 0x10], eax
nop dword [eax + eax]
mov ebp, dword [edi + 0x10c]
lea esi, [edi + 8]
add ebp, eax
movzx eax, byte [ebp]
movzx edx, byte [ebp + 2]
movzx ebx, byte [ebp + 5]
shl edx, 4
lea ecx, [eax + eax*2]
shl ebx, 4
mov eax, dword [edi + 0x128]
add ebx, dword [esp + 0x1e0]
add edx, dword [eax + ecx*4 + 4]
movzx eax, byte [ebp + 3]
mov cl, byte [edx + 8]
lea esi, [esi + eax*8]
mov ah, byte [esi]
cmp ah, cl
jne 0x4aee4d
mov al, byte [esi + 1]
cmp al, byte [edx + 9]
jne 0x4aee4d
movups xmm0, xmmword [edx]
movups xmmword [ebx], xmm0
mov byte [ebp + 6], 0xff
jmp 0x4aee96
mov ecx, edi
call fcn.004aeb50
mov eax, dword [esp + 0x10]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1c8
ret 8
cmp cl, 0xb
jne 0x4aee7a
cmp byte [edx + 9], 1
jne 0x4aee7a
cmp ah, 0xa
jne 0x4aee7a
cmp byte [esi + 1], 4
ja 0x4aee7a
movups xmm0, xmmword [edx]
movups xmmword [ebx], xmm0
mov al, byte [esi]
mov byte [ebx + 8], al
mov al, byte [esi + 1]
mov byte [ebx + 9], al
mov byte [ebp + 6], 0xff
jmp 0x4aee96
push esi
lea ecx, [esp + 0xd8]
call fcn.004af5e0
mov byte [ebp + 6], 0
mov eax, dword [esi]
mov dword [ebx + 8], eax
mov eax, dword [esi + 4]
mov dword [ebx + 0xc], eax
mov eax, dword [esp + 0x10]
add eax, 7
sub dword [esp + 0x14], 1
mov dword [esp + 0x10], eax
jne 0x4aede0
mov ebp, dword [esp + 0x1e0]
mov ebx, dword [esp + 0x18]
cmp dword [esp + 0x1d4], 0
jle 0x4aefda
lea ecx, [esp + 0xd4]
call fcn.004af490
push dword [0x884adc]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
push 0x1a8
mov ecx, dword [eax + 0x2c]
mov eax, dword [ecx]
call dword [eax + 4]
mov ecx, 0x1a8
push ebx
mov word [eax + 4], cx
lea ecx, [esp + 0xd8]
push ecx
mov ecx, eax
call fcn.004ada20
mov esi, eax
test esi, esi
je 0x4aef10
mov ecx, esi
call fcn.0045c0c0
mov ecx, dword [edi + 0x118]
test ecx, ecx
je 0x4aef1f
call fcn.0045c160
mov ecx, esi
mov dword [edi + 0x118], esi
call fcn.0045c160
mov eax, dword [esp + 0x1c]
test eax, eax
jle 0x4aefda
xor ebx, ebx
nop word [eax + eax]
mov esi, dword [edi + 0x10c]
add esi, ebx
cmp byte [esi + 6], 0
jl 0x4aefca
movzx eax, byte [esi + 3]
movzx ecx, byte [edi + eax*8 + 0xa]
movzx eax, byte [edi + eax*8 + 0xb]
push eax
push ecx
lea ecx, [esp + 0xdc]
call fcn.004af500
mov byte [esi + 6], al
lea ecx, [esp + 0x20]
push ecx
mov ecx, dword [edi + 0x118]
movsx eax, al
push eax
call fcn.004add20
test byte [esi + 4], 4
jne 0x4aefb0
push dword [esp + 0x18]
movzx ecx, byte [esi + 2]
lea eax, [esp + 0x24]
push eax
movzx eax, byte [esi]
shl ecx, 4
lea edx, [eax + eax*2]
mov eax, dword [edi + 0x128]
add ecx, dword [eax + edx*4 + 4]
push ecx
call fcn.004b1030
add esp, 0xc
movzx ecx, byte [esi + 5]
mov eax, dword [esp + 0x20]
add ecx, ecx
mov dword [ebp + ecx*8], eax
mov eax, dword [esp + 0x24]
mov dword [ebp + ecx*8 + 4], eax
mov eax, dword [esp + 0x1c]
add ebx, 7
sub eax, 1
mov dword [esp + 0x1c], eax
jne 0x4aef40
mov byte [edi + 0x138], 1
mov eax, 1
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1c8
ret 8