From 5556cf15656ad1e433ec20502411411e30a4cdc7 Mon Sep 17 00:00:00 2001 From: bellard Date: Sun, 17 Apr 2005 13:10:37 +0000 Subject: dos2unix --- win32/lib/chkstk.S | 58 +++++++++++++++++++++++++++--------------------------- 1 file changed, 29 insertions(+), 29 deletions(-) (limited to 'win32/lib/chkstk.S') diff --git a/win32/lib/chkstk.S b/win32/lib/chkstk.S index 8e16d74..837d8af 100644 --- a/win32/lib/chkstk.S +++ b/win32/lib/chkstk.S @@ -1,29 +1,29 @@ -// ================================================= -// chkstk.s - -.text -.globl __chkstk - -__chkstk: - xchg (%esp), %ebp // store ebp, get ret.addr - push %ebp // push ret.addr - lea 4(%esp), %ebp // setup frame ptr - push %ecx // save ecx - mov %ebp, %ecx -P0: - sub $4096,%ecx - test %eax,(%ecx) - sub $4096,%eax - cmp $4096,%eax - jge P0 - - sub %eax,%ecx - mov %esp,%eax - test %eax,(%ecx) - mov %ecx,%esp - - mov (%eax),%ecx // restore ecx - mov 4(%eax),%eax - push %eax - ret - +// ================================================= +// chkstk.s + +.text +.globl __chkstk + +__chkstk: + xchg (%esp), %ebp // store ebp, get ret.addr + push %ebp // push ret.addr + lea 4(%esp), %ebp // setup frame ptr + push %ecx // save ecx + mov %ebp, %ecx +P0: + sub $4096,%ecx + test %eax,(%ecx) + sub $4096,%eax + cmp $4096,%eax + jge P0 + + sub %eax,%ecx + mov %esp,%eax + test %eax,(%ecx) + mov %ecx,%esp + + mov (%eax),%ecx // restore ecx + mov 4(%eax),%eax + push %eax + ret + -- cgit v1.3.1