November 25, 2018 10:13 PM, "Zebediah Figura" z.figura12@gmail.com wrote:
@@ -542,20 +542,27 @@ static unsigned dump_modules(struct dump_context* dc, BOOL dump_elf)
[...]
+#ifdef __i386__ +__ASM_GLOBAL_FUNC( do_x86cpuid,
"pushl %edi\n\t""pushl %ebx\n\t""movl 4(%esp),%eax\n\t""movl 8(%esp),%esi\n\t""cpuid\n\t""movl %eax,(%esi)\n\t""movl %ebx,4(%esi)\n\t""movl %ecx,8(%esi)\n\t""movl %edx,12(%esi)\n\t""popl %ebx\n\t""popl %edi\n\t""ret" );
You save EDI here, but then clobber ESI.
Chip