Function at 0x4010b0
Capabilities:
Read file on windows
Read pipe

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1c
mov ecx, dword [0x414bfc]
push 0
lea eax, [ebp - 4]
push eax
push 0
push 0
push 0
push ecx
call dword [sym.imp.KERNEL32.dll_PeekNamedPipe]
mov eax, dword [ebp - 4]
test eax, eax
je 0x401616
push esi
inc eax
push edi
push eax
call fcn.00403bd0
mov edx, dword [ebp - 4]
inc edx
push edx
mov esi, eax
push 0
push esi
call fcn.0040acc0
mov ecx, dword [ebp - 4]
mov edx, dword [0x414bfc]
add esp, 0x10
push 0
lea eax, [ebp - 0x1c]
push eax
push ecx
push esi
push edx
call dword [sym.imp.KERNEL32.dll_ReadFile]
cmp dword [0x414c20], 1
jne 0x40113c
push 0x411204
push str.log.txt
call fcn.0040397d
push esi
mov edi, eax
push 0x411210
push edi
call fcn.00403994
push edi
call fcn.00403b0d
add esp, 0x18
push ebx
push str.bestmove
push esi
call fcn.00403c50
push str.ponder
push esi
mov edi, eax
call fcn.00403c50
push str.score_cp
push esi
mov ebx, eax
call fcn.00403c50
push str.score_mate
push esi
mov dword [ebp - 8], eax
call fcn.00403c50
push str.depth
push esi
mov dword [ebp - 0xc], eax
call fcn.00403c50
push str.seldepth
push esi
mov dword [ebp - 0x10], eax
call fcn.00403c50
push str.nps
push esi
mov dword [ebp - 0x14], eax
call fcn.00403c50
add esp, 0x38
mov dword [ebp - 0x18], eax
test edi, edi
je 0x401613
mov eax, dword [0x414c28]
mov ecx, dword [0x414c2c]
cmp eax, 1
je 0x4011bc
test ecx, ecx
jne 0x4011c6
mov dword [0x414c24], 0
test eax, eax
jne 0x401613
cmp ecx, 1
jne 0x401613
movzx ecx, byte [edi + 0xb]
mov al, byte [edi + 9]
mov dl, byte [edi + 0xa]
mov byte [0x41707f], cl
movzx ecx, byte [edi + 0xc]
mov byte [0x41707e], cl
movzx ecx, byte [edi + 0xd]
mov byte [0x417081], al
mov byte [0x417080], dl
mov byte [0x41707d], cl
mov byte [0x41707b], 0x39
test ebx, ebx
je 0x401243
movzx ecx, byte [ebx + 7]
mov byte [0x41707c], cl
movzx ecx, byte [ebx + 8]
mov byte [0x41707b], cl
movzx ecx, byte [ebx + 9]
mov byte [0x41707a], cl
movzx ecx, byte [ebx + 0xa]
mov byte [0x417079], cl
movzx ecx, byte [ebx + 0xb]
mov byte [0x417078], cl
mov ecx, dword [0x414c34]
cmp ecx, 1
jne 0x40128e
movsx ecx, al
movsx edx, dl
mov eax, 0x38
sub eax, edx
movsx edx, byte [0x41707e]
mov dword [0x414c58], eax
movsx eax, byte [0x41707f]
sub ecx, 0x61
sub eax, 0x61
mov esi, 0x38
sub esi, edx
mov dword [0x414c5c], ecx
mov dword [0x414c54], eax
mov dword [0x414c50], esi
jmp 0x4012e3
test ecx, ecx
jne 0x4012d2
movsx esi, byte [0x41707e]
movsx eax, al
mov ecx, 0x68
sub ecx, eax
movsx eax, dl
movsx edx, byte [0x41707f]
sub eax, 0x31
mov dword [0x414c58], eax
mov eax, 0x68
sub eax, edx
sub esi, 0x31
mov dword [0x414c5c], ecx
mov dword [0x414c54], eax
mov dword [0x414c50], esi
jmp 0x4012e3
mov ecx, dword [0x414c5c]
mov eax, dword [0x414c54]
mov esi, dword [0x414c50]
movsx edx, byte [0x41707b]
sub edx, 0x30
mov dword [0x414c4c], edx
movsx edx, byte [0x417079]
sub edx, 0x30
mov dword [0x414c48], edx
mov edx, dword [ebp - 8]
test edx, edx
je 0x401376
push 0x414c44
push str.score_cp__d
push edx
call fcn.00403d44
mov eax, dword [0x414c70]
mov ecx, dword [0x414c44]
add esp, 0xc
cmp eax, 3
jge 0x40133c
cmp ecx, 5
jne 0x40133c
sub dword [0x414c74], 0x96
cmp eax, 2
jne 0x401365
cmp ecx, dword [0x414c1c]
jle 0x401353
mov dword [0x414c30], 0
cmp ecx, dword [0x414c18]
jle 0x401365
mov dword [0x414c74], 0x3e8
mov esi, dword [0x414c50]
mov eax, dword [0x414c54]
mov ecx, dword [0x414c5c]
mov edx, dword [ebp - 0xc]
test edx, edx
je 0x4013a1
push 0x414c44
push str.score_mate__d
push edx
call fcn.00403d44
mov ecx, dword [0x414c5c]
mov eax, dword [0x414c54]
mov esi, dword [0x414c50]
add esp, 0xc
mov edx, dword [ebp - 0x10]
test edx, edx
je 0x4013cc
push 0x414c40
push str.depth__d
push edx
call fcn.00403d44
mov ecx, dword [0x414c5c]
mov eax, dword [0x414c54]
mov esi, dword [0x414c50]
add esp, 0xc
mov edx, dword [ebp - 0x14]
test edx, edx
je 0x4013f7
push 0x414c38
push str.seldepth__d
push edx
call fcn.00403d44
mov ecx, dword [0x414c5c]
mov eax, dword [0x414c54]
mov esi, dword [0x414c50]
add esp, 0xc
mov edx, dword [ebp - 0x18]
test edx, edx
je 0x401422
push 0x414c3c
push str.nps__d
push edx
call fcn.00403d44
mov ecx, dword [0x414c5c]
mov eax, dword [0x414c54]
mov esi, dword [0x414c50]
add esp, 0xc
mov edx, dword [0x414c58]
lea edx, [ecx + edx*8]
add edx, edx
add edx, edx
mov edi, 6
cmp dword [edx + 0x414c78], edi
jne 0x401457
lea ebx, [ecx - 2]
cmp eax, ebx
jne 0x401457
xor ebx, ebx
mov dword [0x414d58], ebx
mov dword [edx + 0x414c74], 5
jmp 0x401459
xor ebx, ebx
cmp dword [edx + 0x414c78], edi
jne 0x401478
lea edi, [ecx + 2]
cmp eax, edi
jne 0x401478
mov dword [0x414d74], ebx
mov dword [edx + 0x414c7c], 5
cmp dword [edx + 0x414c78], 4
jne 0x4014aa
lea edi, [eax + esi*8]
add edi, edi
add edi, edi
cmp dword [edi + 0x414c78], ebx
jne 0x4014aa
lea ebx, [eax - 1]
cmp ecx, ebx
je 0x40149e
lea ebx, [eax + 1]
cmp ecx, ebx
jne 0x4014a8
xor ebx, ebx
mov dword [edi + 0x414c98], ebx
jmp 0x4014aa
xor ebx, ebx
mov ecx, 4
cmp dword [edx + 0x414c78], ecx
jne 0x4014c5
cmp esi, ebx
je 0x4014c5
lea edi, [eax + esi*8]
mov dword [edi*4 + 0x414c78], ecx
lea eax, [eax + esi*8]
mov dword [edx + 0x414c78], ebx
cmp dword [eax*4 + 0x414c78], ecx
je 0x4014e2
mov dword [eax*4 + 0x414c78], 5
movsx eax, byte [0x41707e]
movsx ecx, byte [0x41707f]
movsx edx, byte [0x417080]
push eax
movsx eax, byte [0x417081]
push ecx
push edx
push eax
push 0x416078
push str._s__c_c_c_c
push 0x416078
mov dword [0x414c2c], ebx
call fcn.00403d66
mov al, byte [0x41707d]
add esp, 0x1c
cmp al, 0x71
je 0x401534
cmp al, 0x72
je 0x401534
cmp al, 0x62
je 0x401534
cmp al, 0x6e
jne 0x401557
push 0x4112a4
push 0x416078
push str._s_s
push 0x416078
mov byte [0x41707d], 0x71
call fcn.00403d66
add esp, 0x10
cmp dword [0x414c30], 0
je 0x401613
mov ecx, dword [0x414c4c]
dec ecx
cmp ecx, 7
ja 0x401613
push 0x1000
push 0
push 0x415078
call fcn.0040acc0
movsx edx, byte [0x417079]
movsx eax, byte [0x41707a]
movsx ecx, byte [0x41707b]
push edx
movsx edx, byte [0x41707c]
push eax
push ecx
push edx
push 0x416078
push str._s__c_c_c_c
push 0x415078
call fcn.00403d66
mov al, byte [0x417078]
add esp, 0x28
cmp al, 0x71
je 0x4015d1
cmp al, 0x72
je 0x4015d1
cmp al, 0x62
je 0x4015d1
cmp al, 0x6e
jne 0x4015ed
push 0x4112a4
push 0x415078
push str._s_s
push 0x415078
call fcn.00403d66
add esp, 0x10
push 0x415078
push str.position_startpos_moves_s
call fcn.00401000
push str.go_wtime_3600000_btime_3600000
call fcn.00401000
add esp, 0xc
mov dword [0x414c24], 1
pop ebx
pop edi
pop esi
mov esp, ebp
pop ebp
ret