[PATCH] ppc64: fix semtimedop compat syscall

David S. Miller davem at davemloft.net
Mon Apr 25 14:07:57 EST 2005


On Mon, 25 Apr 2005 14:05:22 +1000
Stephen Rothwell <sfr at canb.auug.org.au> wrote:

> So, if we declared all the parameters to the compat syscalls to be
> "unsigned int" (or better compat_arg_t), then we would be able to do all
> the type conversions in generic C code (assuming that the syscall
> interface zero extends all the arguments) and then all the asm wrappers
> would go away, right?

It would work but it would suck :-)

You'll eat a whole entire stack frame just to extend some
arguments.

Perhaps tail-calls will eliminate this to some degress, but tail
calls result in return address branch cache misses on some platforms
so it's still not zero cost.

I think a generator for the asm stubs is the best idea, really.
I didn't write the sparc64 stubs in assembler for fun, it really
is needed to keep it cheap enough.



More information about the Linuxppc64-dev mailing list