lkml.org 
[lkml]   [2000]   [Nov]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: Where is it written?
Date
Followup to:  <20001111171749.A32100@wire.cadcamlab.org>
By author: Peter Samuelson <peter@cadcamlab.org>
In newsgroup: linux.dev.kernel
>
> [Andrea Arcangeli]
> > Can you think at one case where it's better to push the parameter on
> > the stack instead of passing them through the callee clobbered
> > ebx/eax/edx?
>
> Well it's safer if you are lazy about prototyping varargs functions.
> But of course by doing that you're treading on thin ice anyway, in
> terms of type promotion and portability. So I guess it's much better
> to say "varargs functions MUST be prototyped" and use the registers.
>

It definitely is now. At the time the original x86 ABI was created, a
lot of C code was still K&R, and thus prototypes didn't exist...

>
> AIUI gcc can cope OK with multiple ABIs to be chosen at runtime, am I
> right? IRIX, HP-UX and AIX all have both 32-bit and 64-bit ABIs.
>

I don't think we want to introduce a new ABI in user space at this
time. If we ever have to major-rev the ABI (libc.so.7), then we
should consider this.

-hpa
--
<hpa@transmeta.com> at work, <hpa@zytor.com> in private!
"Unix gives you enough rope to shoot yourself in the foot."
http://www.zytor.com/~hpa/puzzle.txt
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 12:45    [W:0.076 / U:0.676 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site