Subject: Re: cerror.S ignores error number returned
To: Srinivasa Kanduru <ksraghavan@yahoo.com>
From: Jaromir Dolecek <jdolecek@NetBSD.org>
List: port-i386
Date: 11/28/2003 13:07:48
Srinivasa Kanduru wrote:
> diff -u cerror.S*
> --- cerror.S Tue Nov 25 11:17:15 2003
> +++ cerror.S.orig Tue Nov 25 10:38:42 2003
> @@ -53,12 +53,10 @@
> PIC_PROLOGUE
> call PIC_PLT(_C_LABEL(__errno))
> PIC_EPILOGUE
> - popl %ecx
> #else
> call _C_LABEL(__errno)
> - popl %ecx
> #endif /* PIC */
> - movl %ecx,(%eax)
> + popl (%eax)
> movl $-1,%eax
> movl $-1,%edx
> ret
AFAICS this only optimizes the codepath (avoiding one movl),
but doesn't change any behaviour. Is that correct?
Jaromir
--
Jaromir Dolecek <jdolecek@NetBSD.org> http://www.NetBSD.cz/
-=- We should be mindful of the potential goal, but as the Buddhist -=-
-=- masters say, ``You may notice during meditation that you -=-
-=- sometimes levitate or glow. Do not let this distract you.'' -=-