Function at 0x40a410
Capabilities:
Allocate thread local storage
Query environment variable

Disassembly:
lea ecx, [esp + 4]
and esp, 0xfffffff0
push dword [ecx - 4]
push ebp
mov ebp, esp
push edi
push esi
push ebx
push ecx
sub esp, 0xc8
mov esi, dword [ecx]
mov ebx, dword [ecx + 4]
call fcn.00409a70
mov dword [esp], 1
call dword [0x40b32c]
mov dword [esp + 0xc], 0
mov dword [esp + 8], 4
mov dword [esp + 4], 0
mov dword [esp], eax
call dword [sym.imp.msvcrt.dll_setvbuf]
mov dword [0x41e308], esi
lea esi, [ebp - 0x98]
mov edi, dword [sym.imp.kernel32.dll_GetEnvironmentVariableA]
mov dword [0x41e304], ebx
mov dword [esp + 8], pe_nt_image_headers32
mov dword [esp + 4], esi
mov dword [esp], str.WINETEST_PLATFORM
call edi
sub esp, 0xc
test eax, eax
je 0x40a666
mov dword [esp], esi
call dword [sym.imp.msvcrt.dll__strdup]
mov dword [str.windows], eax
mov dword [esp + 8], pe_nt_image_headers32
mov dword [esp + 4], esi
mov dword [esp], str.WINETEST_DEBUG
call edi
sub esp, 0xc
test eax, eax
jne 0x40a82d
mov dword [esp + 8], pe_nt_image_headers32
mov dword [esp + 4], esi
mov dword [esp], str.WINETEST_INTERACTIVE
call edi
sub esp, 0xc
test eax, eax
jne 0x40a81a
mov dword [esp + 8], pe_nt_image_headers32
mov dword [esp + 4], esi
mov dword [esp], str.WINETEST_REPORT_SUCCESS
call edi
sub esp, 0xc
test eax, eax
jne 0x40a879
mov dword [esp + 8], pe_nt_image_headers32
mov dword [esp + 4], esi
mov dword [esp], str.WINETEST_TIME
call edi
sub esp, 0xc
test eax, eax
jne 0x40a866
call dword [sym.imp.kernel32.dll_GetTickCount]
mov edi, str.windows
mov ecx, 8
mov esi, dword [str.windows]
mov dword [0x41e3c4], eax
mov dword [0x41e3c0], eax
repe cmpsb byte [esi], byte es:[edi]
seta al
sbb al, 0
test al, al
je 0x40a853
mov edx, dword [0x40e2c4]
test edx, edx
je 0x40a840
mov eax, dword [ebx + 4]
mov dword [ebp - 0x9c], eax
test eax, eax
je 0x40a8c3
mov esi, dword [ebp - 0x9c]
mov edi, str.__list
mov ecx, 7
repe cmpsb byte [esi], byte es:[edi]
seta bl
sbb bl, 0
movsx ebx, bl
test ebx, ebx
je 0x40a813
mov eax, dword [ebp - 0x9c]
mov dword [esp + 4], 0x2f
mov esi, dword [sym.imp.msvcrt.dll_strrchr]
mov dword [esp], eax
call esi
test eax, eax
je 0x40a88c
lea ebx, [eax + 1]
mov dword [esp + 4], 0x5c
mov dword [esp], ebx
call esi
test eax, eax
je 0x40a5ce
lea ebx, [eax + 1]
or ecx, 0xffffffff
xor eax, eax
mov edi, ebx
repne scasb al, byte es:[edi]
mov edx, ecx
not edx
mov ecx, edx
lea edx, [edx - 1]
cmp edx, 2
jbe 0x40a60d
lea esi, [ecx - 3]
mov dword [ebp - 0xa0], edx
lea eax, [ebx + esi]
mov dword [esp + 4], 0x40d184
mov dword [esp], eax
call dword [sym.imp.msvcrt.dll_strcmp]
mov edx, dword [ebp - 0xa0]
test eax, eax
cmove edx, esi
mov dword [ebp - 0xa0], ebx
mov esi, 0x40d240
mov edi, str.drawdib
mov ebx, edx
nop
mov eax, dword [ebp - 0xa0]
mov dword [esp + 8], ebx
mov dword [esp], edi
mov dword [esp + 4], eax
call dword [sym.imp.msvcrt.dll_strncmp]
test eax, eax
jne 0x40a641
cmp byte [edi + ebx], 0
je 0x40a6a6
add esi, 8
mov edi, dword [esi]
test edi, edi
jne 0x40a620
mov eax, dword [ebp - 0x9c]
mov dword [esp], str.Fatal:_test__s_does_not_exist._n
mov dword [esp + 4], eax
call dword [sym.imp.msvcrt.dll_printf]
call fcn.00409050
mov dword [esp], 0x40d0fd
call dword [sym.imp.kernel32.dll_GetModuleHandleA]
push ecx
test eax, eax
je 0x40a4a5
mov dword [esp + 4], str.wine_server_call
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_GetProcAddress]
push edx
push edx
test eax, eax
je 0x40a4a5
mov dword [str.windows], 0x40d118
jmp 0x40a4a5
call dword [sym.imp.kernel32.dll_TlsAlloc]
mov dword [0x41e300], esi
mov dword [0x40e2cc], eax
call dword [esi + 4]
cmp dword [0x40b328], 0
je 0x40a7eb
mov ebx, dword [0x41e2e0]
mov ecx, dword [0x40e2c8]
mov edi, dword [0x41e2e4]
mov edx, dword [0x41e2e8]
mov eax, ebx
mov dword [ebp - 0xa0], ecx
mov ecx, dword [sym.imp.msvcrt.dll_printf]
or eax, edi
or eax, edx
mov dword [ebp - 0x9c], ecx
je 0x40a743
cmp dword [ebp - 0xa0], 0
mov eax, 0x40cec7
jne 0x40a8ad
mov dword [esp + 0x18], edx
mov dword [esp + 0x14], edi
mov dword [esp + 0x10], ebx
mov dword [esp + 0xc], eax
mov eax, dword [esi]
mov ecx, dword fs:[0x18]
mov dword [esp + 8], eax
mov eax, dword [ecx + 0x20]
mov dword [esp], str._04x:_s:_s_Silenced__d_todos___d_skips_and__d_traces._n
mov dword [esp + 4], eax
mov eax, dword [sym.imp.msvcrt.dll_printf]
mov dword [ebp - 0x9c], eax
call eax
mov ebx, dword [0x41e2f8]
mov eax, dword [0x41e2f4]
mov edx, str.failures
mov ecx, dword [0x41e2ec]
mov edi, dword [0x41e2f0]
mov dword [ebp - 0xa0], eax
mov eax, str.failure
add ecx, ebx
cmp ecx, 1
cmovne eax, edx
add ebx, dword [0x41e2fc]
add ebx, edi
add ebx, dword [0x41e2ec]
cmp dword [0x40e2c8], 0
mov dword [ebp - 0xa4], eax
mov eax, 0x40cec7
jne 0x40a897
mov edx, dword fs:[0x18]
mov dword [ebp - 0xa8], edx
mov edx, dword [ebp - 0xa0]
mov dword [esp + 0x18], ecx
mov dword [esp + 0x20], edx
mov edx, dword [ebp - 0xa4]
mov dword [esp + 0x14], edi
mov dword [esp + 0x1c], edx
mov dword [esp + 0x10], ebx
mov dword [esp + 0xc], eax
mov eax, dword [esi]
mov dword [esp + 8], eax
mov eax, dword [ebp - 0xa8]
mov eax, dword [eax + 0x20]
mov dword [esp], str._04x:_s:_s__d_tests_executed___d_marked_as_todo___d__s____d_skipped._n
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x9c]
call eax
mov ebx, dword [0x41e2ec]
add ebx, dword [0x41e2f8]
mov eax, 0xff
cmp ebx, 0xff
cmovg ebx, eax
lea esp, [ebp - 0x10]
mov eax, ebx
pop ecx
pop ebx
pop esi
pop edi
pop ebp
lea esp, [ecx - 4]
ret
call fcn.00409000
jmp 0x40a805
mov dword [esp], esi
call dword [sym.imp.msvcrt.dll_atoi]
mov dword [0x40e2c4], eax
jmp 0x40a4e5
mov dword [esp], esi
call dword [sym.imp.msvcrt.dll_atoi]
mov dword [0x40b328], eax
jmp 0x40a4c5
mov dword [esp], 3
call dword [sym.imp.kernel32.dll_SetErrorMode]
push eax
jmp 0x40a562
mov dword [esp], 0x409220
call dword [sym.imp.kernel32.dll_SetUnhandledExceptionFilter]
push ecx
jmp 0x40a554
mov dword [esp], esi
call dword [sym.imp.msvcrt.dll_atoi]
mov dword [0x40e2c8], eax
jmp 0x40a525
mov dword [esp], esi
call dword [sym.imp.msvcrt.dll_atoi]
mov dword [0x40e2c0], eax
jmp 0x40a505
mov ebx, dword [ebp - 0x9c]
jmp 0x40a5ba
mov dword [ebp - 0xa8], ecx
call fcn.004090d0
mov ecx, dword [ebp - 0xa8]
jmp 0x40a798
mov dword [ebp - 0x9c], edx
call fcn.004090d0
mov edx, dword [ebp - 0x9c]
jmp 0x40a70b
mov eax, dword [ebx]
mov dword [esp], str.Usage:__s_test_name_n_n
mov dword [esp + 4], eax
call dword [sym.imp.msvcrt.dll_printf]
call fcn.00409000
call fcn.00409050