https://bugs.winehq.org/show_bug.cgi?id=43567
--- Comment #6 from Jan Havran havran.jan@email.cz --- To make it complete, one last post. Here is disassembled code of full version which I prepared yesterday:
0x008058cc EntryPoint+0xffffffff in game: movl $0x8058e4,%ecx ; < here store the address 0x008058d1 EntryPoint+0xffffffff in game: movl $0x4,%eax 0x008058d6 EntryPoint+0xffffffff in game: addl $15103168,%eax 0x008058db EntryPoint+0xffffffff in game: movl 0x0(%eax),%eax 0x008058dd EntryPoint+0xffffffff in game: subl $1480757628,%eax 0x008058e2 EntryPoint+0xffffffff in game: jmp *%eax
Register dump: CS:0023 SS:002b DS:002b ES:002b FS:0063 GS:006b EIP:008058e2 ESP:0033f5a0 EBP:0033f764 EFLAGS:00000212( - -- I -A- - ) EAX:004068ec EBX:00000000 ECX:008058e4 EDX:3e800000 ESI:1013c280 EDI:00000000
the code where eax points is: 0x004068ec EntryPoint+0xffffffff in vietcong: call *0x4e4000 -> 0x00427960 EntryPoint+0xffffffff in vietcong ; < here are made some other calls, like GetCurrentThreadId() and GetTickCount() 0x004068f2 EntryPoint+0xffffffff in vietcong: jmp *%ecx ; < ecx has to be untouched
After the return from call, the registers are (ECX has been changed): Register dump: CS:0023 SS:002b DS:002b ES:002b FS:0063 GS:006b EIP:004068f2 ESP:0033f5a0 EBP:0033f764 EFLAGS:00000246( - -- I Z- -P- ) EAX:0b5b30b7 EBX:00000000 ECX:0033f590 EDX:00000000 ESI:1013c280 EDI:00000000
So except the GetTickCount(), my guess is that also the GetCurrentThreadId() can not touch the ECX register. I wanted to make some tests for it but now it looks like it would be useless to do.