Function at 0x403840
Capabilities:
Link many functions at runtime

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x48a131
mov eax, dword fs:[0]
push eax
sub esp, 0x6c
mov eax, dword [0x4b571c]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x30], 0
cmp dword [0x4cabe0], 0
je 0x403881
mov al, 1
jmp 0x403b53
xor eax, eax
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x14], 7
mov word [ebp - 0x28], ax
push 0x100
mov dword [ebp - 4], 1
mov esi, 0x80
call fcn.004515e0
add esp, 4
mov edi, eax
push esi
push edi
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
xor ecx, ecx
mov dword [ebp - 0x38], 0
mov dword [ebp - 0x34], 7
mov word [ebp - 0x48], cx
mov dword [ebp - 0x30], 1
cmp eax, esi
jne 0x403913
nop dword [eax]
push edi
add esi, esi
call fcn.004515e9
xor ecx, ecx
mov eax, esi
mov edx, 2
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.004515e0
add esp, 8
mov edi, eax
push esi
push edi
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
cmp eax, esi
je 0x4038e0
mov ecx, edi
lea edx, [ecx + 2]
nop dword [eax + eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x403920
sub ecx, edx
sar ecx, 1
push ecx
push edi
lea ecx, [ebp - 0x48]
call fcn.00404660
push edi
call fcn.004515e9
mov edi, dword [ebp - 0x34]
lea edx, [ebp - 0x48]
mov esi, dword [ebp - 0x38]
add esp, 4
cmp edi, 8
cmovae edx, dword [ebp - 0x48]
test esi, esi
je 0x4039bb
or ecx, 0xffffffff
lea eax, [esi - 1]
cmp eax, ecx
cmovb ecx, eax
cmp word [edx + ecx*2], 0x5c
lea ecx, [edx + ecx*2]
je 0x40397d
nop dword [eax + eax]
cmp ecx, edx
je 0x4039bb
sub ecx, 2
cmp word [ecx], 0x5c
jne 0x403970
sub ecx, edx
sar ecx, 1
cmp ecx, 0xffffffff
je 0x4039bb
xor eax, eax
mov dword [ebp - 0x50], 0
inc ecx
mov word [ebp - 0x60], ax
cmp esi, ecx
mov dword [ebp - 0x4c], 7
lea eax, [ebp - 0x48]
cmovb ecx, esi
cmp edi, 8
push ecx
cmovae eax, dword [ebp - 0x48]
lea ecx, [ebp - 0x60]
push eax
call fcn.00404660
mov esi, 7
jmp 0x4039d4
xor eax, eax
mov dword [ebp - 0x50], 0
mov dword [ebp - 0x4c], 7
mov esi, 3
mov word [ebp - 0x60], ax
mov dword [ebp - 0x30], esi
push 8
push str.AsIO.dll
lea ecx, [ebp - 0x60]
mov byte [ebp - 4], 2
call fcn.004044d0
xor ecx, ecx
or esi, 8
mov dword [ebp - 0x30], esi
movups xmm1, xmmword [eax]
movq xmm0, qword [eax + 0x10]
mov dword [eax + 0x10], 0
mov dword [eax + 0x14], 7
movups xmmword [ebp - 0x78], xmm1
mov word [eax], cx
movq qword [ebp - 0x68], xmm0
cmp dword [ebp - 0x64], 8
lea ecx, [ebp - 0x78]
push dword [ebp - 0x68]
movd eax, xmm1
mov byte [ebp - 4], 3
cmovae ecx, eax
push ecx
lea ecx, [ebp - 0x28]
call fcn.004044d0
lea ecx, [ebp - 0x78]
call fcn.004036f0
lea ecx, [ebp - 0x60]
call fcn.004036f0
lea ecx, [ebp - 0x48]
mov byte [ebp - 4], 0
call fcn.004036f0
cmp dword [ebp - 0x14], 8
lea eax, [ebp - 0x28]
cmovae eax, dword [ebp - 0x28]
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov dword [0x4cabe0], eax
test eax, eax
je 0x403b44
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.ASIO_Open
push eax
call esi
push str.ASIO_ReadMSR
push dword [0x4cabe0]
mov dword [0x4cabe4], eax
call esi
push str.ASIO_WriteMSR
push dword [0x4cabe0]
mov dword [0x4cabe8], eax
call esi
push str.ASIO_InPortB
push dword [0x4cabe0]
mov dword [0x4cabec], eax
call esi
push str.ASIO_OutPortB
push dword [0x4cabe0]
mov dword [0x4cabf0], eax
call esi
push str.ASIO_InPortD
push dword [0x4cabe0]
mov dword [0x4cabf4], eax
call esi
push str.ASIO_OutPortD
push dword [0x4cabe0]
mov dword [0x4cabf8], eax
call esi
push str.MapPhysToLin
push dword [0x4cabe0]
mov dword [0x4cabfc], eax
call esi
push str.UnmapPhysicalMemory
push dword [0x4cabe0]
mov dword [0x4cac00], eax
call esi
push str.ASIO_MapMem
push dword [0x4cabe0]
mov dword [0x4cac04], eax
call esi
push str.ASIO_UnmapMem
push dword [0x4cabe0]
mov dword [0x4cac08], eax
call esi
push 0
mov dword [0x4cac0c], eax
call dword [0x4cabe4]
mov byte [ebp - 0x29], 1
test eax, eax
jne 0x403b48
mov byte [ebp - 0x29], 0
lea ecx, [ebp - 0x28]
call fcn.004036f0
mov al, byte [ebp - 0x29]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004512f7
mov esp, ebp
pop ebp
ret