Function at 0x610f70
Capabilities:
Get thread local storage value
Print debug messages
Set thread local storage value

Disassembly:
push esi
sub esp, 0x6c
mov eax, dword [esp + 0x78]
cmp eax, 3
je 0x610fc6
cmp eax, 1
je 0x611068
test eax, eax
jne 0x611095
cmp dword [esp + 0x7c], 0
jne 0x611095
mov esi, dword [0x715230]
test esi, esi
je 0x611095
mov ecx, dword [0x715208]
test ecx, ecx
je 0x61108b
call dword [section..00cfg]
push esi
call ecx
add esp, 4
jmp 0x61108b
mov eax, dword [0x714ea0]
cmp eax, 0xffffffff
je 0x611095
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
test eax, eax
je 0x611095
mov esi, eax
test byte [eax + 0x20], 0x30
je 0x6110a1
push dword [esi + 0xb4]
call fcn.00611d10
add esp, 4
mov eax, dword [esi + 0x14]
test eax, eax
je 0x611027
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [esi + 0x18]
test eax, eax
je 0x611019
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [esi + 0x18], 0
mov dword [esi + 0x14], 0
lea eax, [esi + 0x1c]
push eax
call fcn.00683c00
add esp, 4
mov eax, esi
add eax, 0x38
push eax
call fcn.00683dd0
add esp, 4
cmp eax, 1
je 0x611139
mov dword [esi + 0x38], 0xffffffff
mov ecx, esi
call fcn.00612040
push 0
push dword [0x714ea0]
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
jmp 0x611095
mov ecx, dword [0x715204]
test ecx, ecx
je 0x61108b
call dword [section..00cfg]
push 0x6138b0
push 1
call ecx
add esp, 8
mov dword [0x715230], eax
jmp 0x611095
mov dword [0x715230], 0
mov eax, 1
add esp, 0x6c
pop esi
ret 0xc
cmp dword [esi + 0x68], 0
mov eax, dword [esi + 0x18]
je 0x6110be
test eax, eax
je 0x6110b5
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [esi + 0x18], 0
jmp 0x6110eb
test eax, eax
je 0x6110c9
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [esi + 0x18], 0
mov dword [esi + 0x68], 1
push dword [esi + 0xb4]
call fcn.00611d10
add esp, 4
test byte [esi + 0x24], 4
jne 0x611103
lea eax, [esi + 0x1c]
push eax
call fcn.00683c00
add esp, 4
add esi, 0x38
mov ecx, esi
call fcn.00612fa0
jmp 0x611095
mov dword [esi], 0xdeadbeef
mov eax, dword [esi + 0x14]
test eax, eax
je 0x611117
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [esi + 0x14], 0
lea eax, [esi + 0x1c]
push eax
call fcn.00683c00
add esp, 4
mov ecx, esi
add ecx, 0x38
call fcn.00612fa0
jmp 0x611051
movups xmm0, xmmword [0x6e98c6]
movups xmmword [esp + 0x5b], xmm0
movups xmm0, xmmword [0x6e98bb]
movups xmmword [esp + 0x50], xmm0
movups xmm0, xmmword [0x6e98ab]
movups xmmword [esp + 0x40], xmm0
movups xmm0, xmmword [0x6e989b]
movups xmmword [esp + 0x30], xmm0
movups xmm0, xmmword [0x6e988b]
movups xmmword [esp + 0x20], xmm0
movups xmm0, xmmword [0x6e987b]
movups xmmword [esp + 0x10], xmm0
movups xmm0, xmmword [str.Error_cleaning_up_spin_keys_for_thread]
movups xmmword [esp], xmm0
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
lea ecx, [esp + 0x27]
push 0xa
push ecx
push eax
call dword [sym.imp.msvcrt.dll__ultoa]
add esp, 0xc
mov eax, 0x27
mov ecx, eax
inc eax
cmp ecx, 0x69
ja 0x6111b6
cmp byte [esp + ecx], 0
jne 0x6111a8
cmp ecx, 0x69
ja 0x6111c2
mov word [esp + eax - 1], 0xa
mov eax, esp
push eax
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
call sub.msvcrt.dll_abort
mov eax, dword [esp + 4]
mov dword [0x71520c], eax
ret