Function at 0x4a2640
Capabilities:
Set thread local storage value

Disassembly:
push esi
push edi
xor edi, edi
push 0x25c
inc edi
push edi
call fcn.0054acb1
pop ecx
pop ecx
push eax
push dword [0xa99c60]
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
call fcn.004a243e
mov esi, eax
test esi, esi
je 0x4a29e2
push ebx
xor ebx, ebx
mov dword [esi + 0x1c], ebx
mov dword [esi + 0x20], ebx
inc dword [esi + 0x1c]
mov eax, dword [esi + 0x1c]
mov dword [esi + eax*4 + 0x20], 0x1d
mov dword [esi + 0x228], edi
mov dword [esi + 0x170], ebx
mov dword [esi + 0x178], ebx
mov dword [esi + 0x198], ebx
mov dword [esi + 0x14], ebx
mov dword [esi + 0x1c8], ebx
mov dword [esi + 0x1cc], ebx
mov dword [esi + 0x1d0], ebx
call fcn.004a2464
mov eax, dword [esi]
mov dword [esi + 0xc], ebx
mov dword [esi + 0x10], edi
test eax, eax
jne 0x4a26cf
mov dword [esi + 0xc], 0x20
mov dword [esi + 0x10], ebx
jmp 0x4a26e6
cmp eax, edi
jbe 0x4a26e6
mov ecx, ebx
mov edx, edi
shr eax, 1
add edx, edx
inc ecx
cmp eax, edi
ja 0x4a26d7
mov dword [esi + 0xc], ecx
mov dword [esi + 0x10], edx
push 0x63
pop eax
cdq
idiv dword [esi + 8]
push 2
inc eax
pop ecx
mov dword [esi + 0x18], eax
cmp eax, ecx
jge 0x4a26fb
mov dword [esi + 0x18], ecx
mov eax, dword [esi + 0x18]
lea eax, [eax*4 + 0xc]
mov ecx, eax
mov dword [esi + 0x24c], eax
and ecx, 0x80000007
jns 0x4a271a
dec ecx
or ecx, 0xfffffff8
inc ecx
je 0x4a2727
sub eax, ecx
add eax, 8
mov dword [esi + 0x24c], eax
mov ecx, 0x401
mov dword [esi + 0x80], edi
mov dword [esi + 0x234], 0xa
mov dword [esi + 0x22c], ebx
mov dword [esi + 0x23c], ebx
mov dword [esi + 0x230], 6
mov dword [esi + 0x140], edi
mov dword [esi + 0x238], edi
mov dword [esi + 0x240], ebx
mov dword [esi + 0x244], ebx
mov dword [esi + 0x248], ebx
mov dword [esi + 0x224], 0x400
call fcn.004a5b20
mov dword [esi + 0x220], eax
lea edi, [esi + 0x98]
push 0x23
mov byte [eax], bl
mov dword [esi + 0x258], ebx
mov dword [esi + 0x254], ebx
mov dword [edi], 0x55555555
mov dword [esi + 0x9c], 0x12345678
pop ebx
mov eax, dword [edi]
lea edi, [edi + 4]
add eax, 0x1379bdf1
add eax, dword [edi]
mov dword [edi + 4], eax
dec ebx
jne 0x4a27ac
mov eax, dword [esi + 0x18]
xor edi, edi
mov dword [esi + 0x12c], 0x25
mov dword [esi + 0x130], edi
pop ebx
lea ecx, [eax*2 + 1]
mov eax, ecx
mov dword [esi + 0x18], ecx
and eax, 0x7fffffff
cmp ecx, eax
jne 0x4a29c9
cmp ecx, 0x40000000
jg 0x4a29c9
mov dword [esi + 0x138], edi
mov dword [esi + 0x148], edi
mov dword [esi + 0x14c], edi
mov dword [esi + 0x150], edi
call fcn.004a243e
imul ecx, dword [eax + 0x24c], 0x17
call fcn.004a5b20
mov ecx, eax
mov dword [esi + 0x160], edi
mov eax, dword [esi + 0x18]
dec eax
mov dword [esi + 0x250], ecx
cdq
sub eax, edx
mov dword [esi + 0x88], edi
sar eax, 1
xor edx, edx
mov dword [esi + 0x84], edi
mov dword [esi + 0x8c], 1
mov dword [esi + 0x18], eax
call fcn.004a2609
mov ecx, dword [esi + 0x250]
push 2
pop edx
mov dword [esi + 0x1d4], eax
call fcn.004a2609
mov ecx, dword [esi + 0x250]
push 3
pop edx
mov dword [esi + 0x1d8], eax
call fcn.004a2609
mov ecx, dword [esi + 0x250]
push 4
pop edx
mov dword [esi + 0x1dc], eax
call fcn.004a2609
mov ecx, dword [esi + 0x250]
push 5
pop edx
mov dword [esi + 0x1e0], eax
call fcn.004a2609
mov ecx, dword [esi + 0x250]
push 6
pop edx
mov dword [esi + 0x1e4], eax
call fcn.004a2609
mov ecx, dword [esi + 0x250]
push 8
pop edx
mov dword [esi + 0x1e8], eax
call fcn.004a2609
mov ecx, dword [esi + 0x250]
push 0xa
pop edx
mov dword [esi + 0x1ec], eax
call fcn.004a2609
mov ecx, dword [esi + 0x250]
push 0xc
pop edx
mov dword [esi + 0x1f0], eax
call fcn.004a2609
mov ecx, dword [esi + 0x250]
push 0xd
pop edx
mov dword [esi + 0x1f4], eax
call fcn.004a2609
mov ecx, dword [esi + 0x250]
push 0xe
pop edx
mov dword [esi + 0x1f8], eax
call fcn.004a2609
mov ecx, dword [esi + 0x250]
push 0xf
pop edx
mov dword [esi + 0x1fc], eax
call fcn.004a2609
mov ecx, dword [esi + 0x250]
push 0x10
pop edx
mov dword [esi + 0x200], eax
call fcn.004a2609
mov ecx, dword [esi + 0x250]
push 0x11
pop edx
mov dword [esi + 0x204], eax
call fcn.004a2609
mov ecx, dword [esi + 0x250]
push 0x12
pop edx
mov dword [esi + 0x208], eax
call fcn.004a2609
mov ecx, dword [esi + 0x250]
push 0x13
pop edx
mov dword [esi + 0x20c], eax
call fcn.004a2609
mov ecx, dword [esi + 0x250]
push 0x14
pop edx
mov dword [esi + 0x210], eax
call fcn.004a2609
mov ecx, dword [esi + 0x250]
push 0x15
pop edx
mov dword [esi + 0x214], eax
call fcn.004a2609
mov ecx, dword [esi + 0x250]
push 0x16
pop edx
mov dword [esi + 0x218], eax
call fcn.004a2609
mov dword [esi + 0x21c], eax
jmp 0x4a29dd
push 0xe
pop ecx
call fcn.004a244b
mov eax, dword [esi + 0x18]
dec eax
cdq
sub eax, edx
sar eax, 1
mov dword [esi + 0x18], eax
dec dword [esi + 0x1c]
mov eax, esi
pop edi
pop esi
ret