This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH 01/23] all: syscall wrappers: add documentation
- From: Arnd Bergmann <arnd at arndb dot de>
- To: Heiko Carstens <heiko dot carstens at de dot ibm dot com>
- Cc: Yury Norov <ynorov at caviumnetworks dot com>, Catalin Marinas <catalin dot marinas at arm dot com>, David Miller <davem at davemloft dot net>, linux-arm-kernel at lists dot infradead dot org, linux-kernel at vger dot kernel dot org, linux-doc at vger dot kernel dot org, linux-arch at vger dot kernel dot org, linux-s390 at vger dot kernel dot org, libc-alpha at sourceware dot org, schwidefsky at de dot ibm dot com, pinskia at gmail dot com, broonie at kernel dot org, joseph at codesourcery dot com, christoph dot muellner at theobroma-systems dot com, bamvor dot zhangjian at huawei dot com, szabolcs dot nagy at arm dot com, klimov dot linux at gmail dot com, Nathan_Lynch at mentor dot com, agraf at suse dot de, Prasun dot Kapoor at caviumnetworks dot com, kilobyte at angband dot pl, geert at linux-m68k dot org, philipp dot tomsich at theobroma-systems dot com
- Date: Fri, 27 May 2016 10:42:59 +0200
- Subject: Re: [PATCH 01/23] all: syscall wrappers: add documentation
- Authentication-results: sourceware.org; auth=none
- References: <6293194 dot tGy03QJ9ME at wuerfel> <20160527003753 dot GA14247 at yury-N73SV> <20160527060357 dot GB3820 at osiris>
On Friday, May 27, 2016 8:03:57 AM CEST Heiko Carstens wrote:
> > > > > Cost wise, this seems like it all cancels out in the end, but what
> > > > > do I know?
> > > >
> > > > I think you know something, and I also think Heiko and other s390 guys
> > > > know something as well. So I'd like to listen their arguments here.
>
> If it comes to 64 bit arguments for compat system calls: s390 also has an
> x32-like ABI extension which allows user space to use full 64 bit
> registers. As far as I know hardly anybody ever made use of that.
>
> However even if that would be widely used, to me it wouldn't make sense to
> add new compat system calls which allow 64 bit arguments, simply because
> something like
>
> c = (u32)a | (u64)b << 32;
>
> can be done with a single 1-cycle instruction. It's just not worth the
> extra effort to maintain additional system call variants.
For reference, both tile and mips also have separate 32-bit ABIs that are
only used on 64-bit kernels (aside from the normal 32-bit ABI). Tile
does it like s390 and passes 64-bit arguments as pairs, while MIPS
and x86 and pass them as single registers.
Tile is very similar to arm64 because it also uses the generic system
call table, which I think is a good argument to keep them in sync.
Arnd