Commit 50bbfb3c authored by Alexandre Julliard's avatar Alexandre Julliard

ntdll: Reimplemented _chkstk and _alloca_probe directly in assembly.

parent b48d9590
...@@ -1233,7 +1233,7 @@ ...@@ -1233,7 +1233,7 @@
@ stdcall -ret64 _alldiv(double double) @ stdcall -ret64 _alldiv(double double)
# @ stub _alldvrm # @ stub _alldvrm
@ stdcall -ret64 _allmul(double double) @ stdcall -ret64 _allmul(double double)
@ stdcall -i386 _alloca_probe() @ stdcall -i386 -norelay _alloca_probe()
@ stdcall -ret64 _allrem(double double) @ stdcall -ret64 _allrem(double double)
# @ stub _allshl # @ stub _allshl
# @ stub _allshr # @ stub _allshr
...@@ -1242,7 +1242,7 @@ ...@@ -1242,7 +1242,7 @@
# @ stub _aulldvrm # @ stub _aulldvrm
@ stdcall -ret64 _aullrem(double double) @ stdcall -ret64 _aullrem(double double)
# @ stub _aullshr # @ stub _aullshr
@ stdcall -i386 _chkstk() @ stdcall -i386 -norelay _chkstk()
@ stub _fltused @ stub _fltused
@ cdecl -ret64 _ftol() NTDLL__ftol @ cdecl -ret64 _ftol() NTDLL__ftol
@ cdecl _i64toa(double ptr long) @ cdecl _i64toa(double ptr long)
......
...@@ -391,11 +391,13 @@ DWORD WINAPI RtlDeleteSecurityObject(DWORD x1) { ...@@ -391,11 +391,13 @@ DWORD WINAPI RtlDeleteSecurityObject(DWORD x1) {
* Glorified "enter xxxx". * Glorified "enter xxxx".
*/ */
#ifdef __i386__ #ifdef __i386__
void WINAPI __regs__chkstk( CONTEXT86 *context ) __ASM_GLOBAL_FUNC( _chkstk,
{ "negl %eax\n\t"
context->Esp -= context->Eax; "addl %esp,%eax\n\t"
} "xchgl %esp,%eax\n\t"
DEFINE_REGS_ENTRYPOINT( _chkstk, 0, 0 ); "movl 0(%eax),%eax\n\t" /* copy return address from old location */
"movl %eax,0(%esp)\n\t"
"ret" );
#endif #endif
/************************************************************************** /**************************************************************************
...@@ -404,11 +406,13 @@ DEFINE_REGS_ENTRYPOINT( _chkstk, 0, 0 ); ...@@ -404,11 +406,13 @@ DEFINE_REGS_ENTRYPOINT( _chkstk, 0, 0 );
* Glorified "enter xxxx". * Glorified "enter xxxx".
*/ */
#ifdef __i386__ #ifdef __i386__
void WINAPI __regs__alloca_probe( CONTEXT86 *context ) __ASM_GLOBAL_FUNC( _alloca_probe,
{ "negl %eax\n\t"
context->Esp -= context->Eax; "addl %esp,%eax\n\t"
} "xchgl %esp,%eax\n\t"
DEFINE_REGS_ENTRYPOINT( _alloca_probe, 0, 0 ); "movl 0(%eax),%eax\n\t" /* copy return address from old location */
"movl %eax,0(%esp)\n\t"
"ret" );
#endif #endif
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment