Function at 0x100fa490
Capabilities:
Get thread local storage value

Disassembly:
push ebp
push ebx
push edi
push esi
sub esp, 0x60
mov eax, dword [0x104d5390]
test eax, eax
jne 0x100fa4aa
mov ecx, 0x104d5390
call fcn.100f2650
push eax
call sub.KERNEL32.dll_TlsGetValue
cmp eax, 2
jb 0x100fa4bf
cmp dword [eax], 1
jne 0x100fa4bf
add eax, 4
jmp 0x100fa4cc
call fcn.100f27a0
test eax, eax
je 0x100fa6c2
mov ecx, eax
call fcn.100f2870
mov esi, eax
mov dword [esp + 8], eax
xor ecx, ecx
mov eax, 2
lock cmpxchg dword [esi + 0x18], ecx
je 0x100fa638
mov ebp, esi
add ebp, 0x18
mov ecx, dword [ebp + 4]
call fcn.100f4810
mov eax, dword [0x104dec50]
test eax, eax
jne 0x100fa652
mov dword [esp], 0
lea eax, [ebp + 4]
mov dword [esp + 4], eax
mov al, byte [esi + 0x20]
test al, al
jne 0x100fa6db
mov ecx, 1
xor eax, eax
lock cmpxchg dword [ebp], ecx
jne 0x100fa597
mov ecx, dword [esi + 0x1c]
xor eax, eax
lock cmpxchg dword [esi + 0x28], ecx
je 0x100fa544
cmp eax, ecx
jne 0x100fa677
mov edi, dword [ebp + 4]
mov ebx, dword [ebp + 0xc]
mov edx, dword [0x104decc0]
test edx, edx
jne 0x100fa573
mov ecx, 0x10422624
mov edx, 0x19
call fcn.100f2ce0
test eax, eax
mov ecx, 0x100fa8b0
cmove edx, ecx
mov dword [0x104decc0], edx
push 0
push 0xffffffffffffffff
push edi
push ebx
call edx
movzx eax, byte [esi + 0x20]
test al, al
jne 0x100fa690
mov eax, 2
xor ecx, ecx
lock cmpxchg dword [ebp], ecx
jne 0x100fa530
jmp 0x100fa5b2
cmp eax, 2
jne 0x100fa6ff
xor eax, eax
xchg dword [ebp], eax
cmp eax, 2
mov dword [esp + 0xc], eax
jne 0x100fa713
cmp byte [esp], 0
jne 0x100fa5c5
mov eax, dword [0x104dec50]
test eax, eax
jne 0x100fa661
mov eax, dword [esp + 4]
mov esi, dword [eax]
mov eax, dword [0x104dec60]
test eax, eax
je 0x100fa5e9
cmp eax, 0x100f30b0
jne 0x100fa60e
mov eax, dword [esi]
mov byte [eax + 0x18], 0
push eax
call sub.KERNEL32.dll_LeaveCriticalSection
jmp 0x100fa638
mov ecx, 0x10421629
mov edx, 0x17
call fcn.100f2ce0
test eax, eax
mov eax, 0x100f30b0
cmovne eax, edx
mov dword [0x104dec60], eax
cmp eax, 0x100f30b0
je 0x100fa5db
mov eax, dword [0x104dec78]
test eax, eax
jne 0x100fa635
mov ecx, 0x10421918
mov edx, 0x17
call fcn.100f2ce0
test eax, eax
mov eax, 0x100f4ef0
cmovne eax, edx
mov dword [0x104dec78], eax
push esi
call eax
mov eax, dword [esp + 8]
lock dec dword [eax]
jne 0x100fa64a
lea ecx, [esp + 8]
call fcn.100f2c20
add esp, 0x60
pop esi
pop edi
pop ebx
pop ebp
ret
call fcn.100fa7c0
xor al, 1
mov dword [esp], eax
jmp 0x100fa50c
call fcn.100fa7c0
test al, al
jne 0x100fa5c5
mov byte [esi + 0x20], 1
jmp 0x100fa5c5
mov ecx, str.attempted_to_use_a_condition_variable_with_two_mutexes
mov edx, 0x36
push 0x10422614
call fcn.100f30d0
add esp, 4
ud2
mov eax, dword [esp + 4]
mov ecx, 0x1044a65b
mov edx, 0x2b
mov dword [esp + 0x18], eax
mov eax, dword [esp]
mov byte [esp + 0x1c], al
lea eax, [esp + 0x18]
push 0x10422640
push 0x10422578
push eax
call fcn.1000a790
add esp, 0xc
ud2
mov ecx, 0x1042153f
mov edx, 0x5e
push 0x104215a0
call fcn.1000a730
add esp, 4
ud2
mov eax, dword [esp + 4]
mov ecx, 0x1044a65b
mov edx, 0x2b
mov dword [esp + 0x18], eax
mov eax, dword [esp]
mov byte [esp + 0x1c], al
lea eax, [esp + 0x18]
push 0x10422588
jmp 0x100fa6b2
mov ecx, 0x10422598
mov edx, 0x17
push 0x104225b0
jmp 0x100fa686
lea edx, [esp + 0x10]
lea ecx, [esp + 0x14]
lea eax, [esp + 0xc]
mov dword [esp + 0x48], 0x10424378
mov dword [esp + 0x4c], 3
mov dword [esp + 0x50], 0
mov dword [esp + 0x18], 0x104225c4
mov dword [esp + 0x1c], 1
mov dword [esp + 0x20], 0
mov dword [esp + 0x28], str.formatter_errorfailed_to_write_whole_buffer
mov dword [esp + 0x14], 0x104225c0
mov dword [esp + 0x2c], 0
mov dword [esp + 0x30], edx
mov dword [esp + 0x34], 0x100b98b0
mov dword [esp + 0x38], ecx
lea ecx, [esp + 0x30]
lea edx, [esp + 0x18]
mov dword [esp + 0x3c], 0x100b98b0
mov dword [esp + 0x10], eax
mov dword [esp + 0x40], edx
mov dword [esp + 0x58], ecx
lea ecx, [esp + 0x48]
mov edx, 0x104225cc
mov dword [esp + 0x44], 0x1000b210
mov dword [esp + 0x5c], 3
call fcn.100f9210
ud2