[PATCH 4/5] msvcrt: Avoid using inline assembly in call_unwind_func().

Piotr Caban piotr.caban at gmail.com
Mon Jun 11 11:48:48 CDT 2018


Hi Zeb,

On 06/05/18 00:23, Zebediah Figura wrote:
> +extern int call_unwind_func( int (*func)(void), void *ebp );
> +
> +__ASM_GLOBAL_FUNC( call_unwind_func,
> +                   "pushl %ebp\n\t"
> +                   "pushl %ebx\n\t"
> +                   "pushl %esi\n\t"
> +                   "pushl %edi\n\t"
> +                   "movl 24(%esp), %ebp\n\t"
> +                   "call *20(%esp)\n\t"
> +                   "popl %edi\n\t"
> +                   "popl %esi\n\t"
> +                   "popl %ebx\n\t"
> +                   "popl %ebp\n\t"
> +                   "ret" );

How about renaming the function to call_handler and returning void* from 
it? It looks strange that in all places where return value is used we 
need to cast it to pointer.

Thanks,
Piotr



More information about the wine-devel mailing list