Re: futex(2) man page update help request

2014-05-15 Thread Peter Zijlstra
On Thu, May 15, 2014 at 10:39:09AM -0400, Carlos O'Donell wrote: For example does gettid *really* return a pid_t as considered by userspace? It's not a full out process... Yeah, PIDs and TIDs are the same namespace in the kernel. All we have are tasks and each task has an id. gettid() actually

Re: futex(2) man page update help request

2014-05-15 Thread chrubis
Hi! However, unless I'm sorely mistaken, the larger problem is that glibc removed the futex() call entirely, so these man pages don't describe something users even have access to anymore. I had to revert to calling the syscalls directly in the futextest test suite because of this:

Re: futex(2) man page update help request

2014-05-15 Thread chrubis
Hi! However, unless I'm sorely mistaken, the larger problem is that glibc removed the futex() call entirely, so these man pages don't describe something users even have access to anymore. I had to revert to calling the syscalls directly in the futextest test suite because of this:

Re: futex(2) man page update help request

2014-05-15 Thread chrubis
Hi! People have a number of times noted that there are problems with syscall(), but I'm not knowledgeable on the details. I'd happily take a patch to the man page (which, for historical reasons, is actually syscall(2)) that explains the the problems (and ideally notes those platforms where

Re: futex(2) man page update help request

2014-05-15 Thread Steven Rostedt
On Thu, 15 May 2014 17:28:35 +0200 chru...@suse.cz wrote: Hi! However, unless I'm sorely mistaken, the larger problem is that glibc removed the futex() call entirely, so these man pages don't describe something users even have access to anymore. I had to revert to calling the syscalls

Re: futex(2) man page update help request

2014-05-15 Thread Darren Hart
On 5/15/14, 6:46, Michael Kerrisk (man-pages) mtk.manpa...@gmail.com wrote: On 05/15/2014 07:21 AM, Darren Hart wrote: On 5/14/14, 17:18, H. Peter Anvin h...@zytor.com wrote: On 05/14/2014 09:18 AM, Darren Hart wrote: However, unless I'm sorely mistaken, the larger problem is that glibc

Re: futex(2) man page update help request

2014-05-15 Thread Darren Hart
On 5/15/14, 1:13, Peter Zijlstra pet...@infradead.org wrote: On Wed, May 14, 2014 at 04:23:38PM -0400, Carlos O'Donell wrote: On 05/14/2014 03:03 PM, Michael Kerrisk (man-pages) wrote: However, unless I'm sorely mistaken, the larger problem is that glibc removed the futex() call entirely, so

Re: futex(2) man page update help request

2014-05-15 Thread H. Peter Anvin
On 05/15/2014 08:42 AM, chru...@suse.cz wrote: Hi! People have a number of times noted that there are problems with syscall(), but I'm not knowledgeable on the details. I'd happily take a patch to the man page (which, for historical reasons, is actually syscall(2)) that explains the the

Re: futex(2) man page update help request

2014-05-15 Thread chrubis
Hi! Have a look at this commit that tries to deal with passing 64 bit numbers to syscalls. On 32 bit ABI (but not on X32) these needs to be split up (accordingly to machine endianity). https://github.com/linux-test-project/ltp/commit/04afb02b4280a20c262054e8f99a3fad4ad54916 That

Re: futex(2) man page update help request

2014-05-15 Thread H. Peter Anvin
On 05/15/2014 09:01 AM, chru...@suse.cz wrote: I really believe the proper fix is to use assembly syscall stubs. In klibc I build a fairly elaborate machinery to autogenerate such syscall stubs for a variety of architectures. Then it would be nice to share these between klibc and LTP (and

Re: futex(2) man page update help request

2014-05-15 Thread Darren Hart
On 5/15/14, 8:28, chru...@suse.cz chru...@suse.cz wrote: Hi! However, unless I'm sorely mistaken, the larger problem is that glibc removed the futex() call entirely, so these man pages don't describe something users even have access to anymore. I had to revert to calling the syscalls

Re: futex(2) man page update help request

2014-05-15 Thread chrubis
Hi! I really believe the proper fix is to use assembly syscall stubs. In klibc I build a fairly elaborate machinery to autogenerate such syscall stubs for a variety of architectures. Then it would be nice to share these between klibc and LTP (and possible everybody else). It

Re: futex(2) man page update help request

2014-05-15 Thread chrubis
Hi! I've used LTP in the past (quite a bit), and I felt there was some advantage to keeping futextest independent. What advantages did you have in mind? Perhaps things have changed enough since then (~2009 era) that we should reconsider. I've been working on LTP for a about three years now

Re: futex(2) man page update help request

2014-05-15 Thread H. Peter Anvin
On 05/15/2014 09:17 AM, chru...@suse.cz wrote: It should be quite easy to extract from klibc. That is not the main concern here. If I extract the code I would have to watch for any changes manually. If it was in a library or a separate repository all that would be needed is to add it as

Re: futex(2) man page update help request

2014-05-15 Thread chrubis
Hi! That is not the main concern here. If I extract the code I would have to watch for any changes manually. If it was in a library or a separate repository all that would be needed is to add it as dependency/git submodule and I would get all updates automatically. Yes, and for that

Re: futex(2) man page update help request

2014-05-15 Thread Darren Hart
On 5/15/14, 9:30, chru...@suse.cz chru...@suse.cz wrote: Hi! I've used LTP in the past (quite a bit), and I felt there was some advantage to keeping futextest independent. What advantages did you have in mind? Not CVS was a big one at the time ;-) OK, I don't mean to be disparaging here...

Re: futex(2) man page update help request

2014-05-15 Thread chrubis
Hi! I've used LTP in the past (quite a bit), and I felt there was some advantage to keeping futextest independent. What advantages did you have in mind? Not CVS was a big one at the time ;-) OK, I don't mean to be disparaging here... But since you asked, back in '09 LTP had some test

Re: futex(2) man page update help request

2014-05-15 Thread Carlos O'Donell
On 05/14/2014 08:28 PM, H. Peter Anvin wrote: On 05/14/2014 01:56 PM, Davidlohr Bueso wrote: However, unless I'm sorely mistaken, the larger problem is that glibc removed the futex() call entirely, so these man pages don't describe I don't think futex() ever was in glibc--that's by design,

Re: futex(2) man page update help request

2014-05-15 Thread Darren Hart
On 5/15/14, 12:05, chru...@suse.cz chru...@suse.cz wrote: Hi! I've used LTP in the past (quite a bit), and I felt there was some advantage to keeping futextest independent. What advantages did you have in mind? Not CVS was a big one at the time ;-) OK, I don't mean to be disparaging

Re: futex(2) man page update help request

2014-05-15 Thread Michael Kerrisk (man-pages)
On 05/15/2014 04:14 PM, Thomas Gleixner wrote: On Thu, 15 May 2014, Michael Kerrisk (man-pages) wrote: And that universe would love to have your documentation of FUTEX_WAKE_BITSET and FUTEX_WAIT_BITSET ;-), I give you almost the full treatment, but I leave REQUEUE_PI to Darren and

Re: futex(2) man page update help request

2014-05-15 Thread Darren Hart
On 5/15/14, 7:14, Thomas Gleixner t...@linutronix.de wrote: Wow Thomas, I planned to do exactly this and you beat me to it. Again. Thanks for getting this started. Michael, I imagine you want something more condensed, and I'll add to what tglx posted (inline below) to try and get you that, but

Re: futex(2) man page update help request

2014-05-14 Thread Darren Hart
On 5/14/14, 17:18, "H. Peter Anvin" wrote: >On 05/14/2014 09:18 AM, Darren Hart wrote: >> >> However, unless I'm sorely mistaken, the larger problem is that glibc >> removed the futex() call entirely, so these man pages don't describe >> something users even have access to anymore. I had to

Re: futex(2) man page update help request

2014-05-14 Thread Michael Kerrisk (man-pages)
Hi Thomas, On Thu, May 15, 2014 at 1:34 AM, Thomas Gleixner wrote: > On Wed, 14 May 2014, Carlos O'Donell wrote: > >> On 05/14/2014 03:03 PM, Michael Kerrisk (man-pages) wrote: >> >> However, unless I'm sorely mistaken, the larger problem is that glibc >> >> removed the futex() call entirely, so

Re: futex(2) man page update help request

2014-05-14 Thread Michael Kerrisk (man-pages)
On 05/15/2014 05:12 AM, Carlos O'Donell wrote: > On 05/14/2014 07:34 PM, Thomas Gleixner wrote: >> On Wed, 14 May 2014, Carlos O'Donell wrote: >> >>> On 05/14/2014 03:03 PM, Michael Kerrisk (man-pages) wrote: > However, unless I'm sorely mistaken, the larger problem is that glibc > removed

Re: futex(2) man page update help request

2014-05-14 Thread Carlos O'Donell
On 05/14/2014 07:34 PM, Thomas Gleixner wrote: > On Wed, 14 May 2014, Carlos O'Donell wrote: > >> On 05/14/2014 03:03 PM, Michael Kerrisk (man-pages) wrote: However, unless I'm sorely mistaken, the larger problem is that glibc removed the futex() call entirely, so these man pages don't

Re: futex(2) man page update help request

2014-05-14 Thread H. Peter Anvin
On 05/14/2014 05:35 PM, Andy Lutomirski wrote: >> >> More fundamentally, futex(2), like clone(2), are things that can be >> legitimately by user space without automatically breaking all of glibc. > > I'm lost -- I think the missing verb is important :) > ... legitimately *used* by user space

Re: futex(2) man page update help request

2014-05-14 Thread Andy Lutomirski
On Wed, May 14, 2014 at 5:28 PM, H. Peter Anvin wrote: > On 05/14/2014 01:56 PM, Davidlohr Bueso wrote: >>> However, unless I'm sorely mistaken, the larger problem is that glibc removed the futex() call entirely, so these man pages don't describe >>> >>> I don't think futex() ever was

Re: futex(2) man page update help request

2014-05-14 Thread H. Peter Anvin
On 05/14/2014 01:56 PM, Davidlohr Bueso wrote: >> >>> However, unless I'm sorely mistaken, the larger problem is that glibc >>> removed the futex() call entirely, so these man pages don't describe >> >> I don't think futex() ever was in glibc--that's by design, and >> completely understandable: no

Re: futex(2) man page update help request

2014-05-14 Thread H. Peter Anvin
On 05/14/2014 09:18 AM, Darren Hart wrote: > > However, unless I'm sorely mistaken, the larger problem is that glibc > removed the futex() call entirely, so these man pages don't describe > something users even have access to anymore. I had to revert to calling > the syscalls directly in the

Re: futex(2) man page update help request

2014-05-14 Thread Thomas Gleixner
On Wed, 14 May 2014, Carlos O'Donell wrote: > On 05/14/2014 03:03 PM, Michael Kerrisk (man-pages) wrote: > >> However, unless I'm sorely mistaken, the larger problem is that glibc > >> removed the futex() call entirely, so these man pages don't describe > > > > I don't think futex() ever was in

Re: futex(2) man page update help request

2014-05-14 Thread Paul E. McKenney
On Wed, May 14, 2014 at 02:03:13PM -0700, Darren Hart wrote: > On 5/14/14, 13:56, "Davidlohr Bueso" wrote: > > >On Wed, 2014-05-14 at 21:03 +0200, Michael Kerrisk (man-pages) wrote: > >> Hi Darren, > >> > >> On Wed, May 14, 2014 at 6:18 PM, Darren Hart > >>wrote: > >> > On 5/14/14, 3:35,

Re: futex(2) man page update help request

2014-05-14 Thread Davidlohr Bueso
On Wed, 2014-05-14 at 09:18 -0700, Darren Hart wrote: > On 5/14/14, 3:35, "Michael Kerrisk (man-pages)" > wrote: > > >[So, some futex recent discussions remind me I should make this request] > > > >Hello all (especially those in the To:, namely Thomas, Darren, Ingo, > >Jakub), > > > >The futex

Re: futex(2) man page update help request

2014-05-14 Thread Darren Hart
On 5/14/14, 13:56, "Davidlohr Bueso" wrote: >On Wed, 2014-05-14 at 21:03 +0200, Michael Kerrisk (man-pages) wrote: >> Hi Darren, >> >> On Wed, May 14, 2014 at 6:18 PM, Darren Hart >>wrote: >> > On 5/14/14, 3:35, "Michael Kerrisk (man-pages)" >> >> > wrote: >> > >> >>[So, some futex recent

Re: futex(2) man page update help request

2014-05-14 Thread Davidlohr Bueso
On Wed, 2014-05-14 at 21:03 +0200, Michael Kerrisk (man-pages) wrote: > Hi Darren, > > On Wed, May 14, 2014 at 6:18 PM, Darren Hart wrote: > > On 5/14/14, 3:35, "Michael Kerrisk (man-pages)" > > wrote: > > > >>[So, some futex recent discussions remind me I should make this request] > >> >

Re: futex(2) man page update help request

2014-05-14 Thread Andy Lutomirski
On Wed, May 14, 2014 at 1:23 PM, Carlos O'Donell wrote: > On 05/14/2014 03:03 PM, Michael Kerrisk (man-pages) wrote: >>> However, unless I'm sorely mistaken, the larger problem is that glibc >>> removed the futex() call entirely, so these man pages don't describe >> >> I don't think futex() ever

Re: futex(2) man page update help request

2014-05-14 Thread Carlos O'Donell
On 05/14/2014 03:03 PM, Michael Kerrisk (man-pages) wrote: >> However, unless I'm sorely mistaken, the larger problem is that glibc >> removed the futex() call entirely, so these man pages don't describe > > I don't think futex() ever was in glibc--that's by design, and > completely

Re: futex(2) man page update help request

2014-05-14 Thread Darren Hart
On 5/14/14, 12:03, "Michael Kerrisk (man-pages)" wrote: >Hi Darren, > >On Wed, May 14, 2014 at 6:18 PM, Darren Hart >wrote: >> On 5/14/14, 3:35, "Michael Kerrisk (man-pages)" >> wrote: >> >>>[So, some futex recent discussions remind me I should make this request] >>> >>>Hello all (especially

Re: futex(2) man page update help request

2014-05-14 Thread Michael Kerrisk (man-pages)
Hi Darren, On Wed, May 14, 2014 at 6:18 PM, Darren Hart wrote: > On 5/14/14, 3:35, "Michael Kerrisk (man-pages)" > wrote: > >>[So, some futex recent discussions remind me I should make this request] >> >>Hello all (especially those in the To:, namely Thomas, Darren, Ingo, >>Jakub), >> >>The

Re: futex(2) man page update help request

2014-05-14 Thread Darren Hart
On 5/14/14, 3:35, "Michael Kerrisk (man-pages)" wrote: >[So, some futex recent discussions remind me I should make this request] > >Hello all (especially those in the To:, namely Thomas, Darren, Ingo, >Jakub), > >The futex man pages: >http://man7.org/linux/man-pages/man2/futex.2.html

futex(2) man page update help request

2014-05-14 Thread Michael Kerrisk (man-pages)
[So, some futex recent discussions remind me I should make this request] Hello all (especially those in the To:, namely Thomas, Darren, Ingo, Jakub), The futex man pages: http://man7.org/linux/man-pages/man2/futex.2.html http://man7.org/linux/man-pages/man7/futex.7.html are currently in a sorry

Re: futex(2) man page update help request

2014-05-14 Thread Andy Lutomirski
On Wed, May 14, 2014 at 5:28 PM, H. Peter Anvin h...@zytor.com wrote: On 05/14/2014 01:56 PM, Davidlohr Bueso wrote: However, unless I'm sorely mistaken, the larger problem is that glibc removed the futex() call entirely, so these man pages don't describe I don't think futex() ever was in

Re: futex(2) man page update help request

2014-05-14 Thread H. Peter Anvin
On 05/14/2014 05:35 PM, Andy Lutomirski wrote: More fundamentally, futex(2), like clone(2), are things that can be legitimately by user space without automatically breaking all of glibc. I'm lost -- I think the missing verb is important :) ... legitimately *used* by user space ... As in

Re: futex(2) man page update help request

2014-05-14 Thread Carlos O'Donell
On 05/14/2014 07:34 PM, Thomas Gleixner wrote: On Wed, 14 May 2014, Carlos O'Donell wrote: On 05/14/2014 03:03 PM, Michael Kerrisk (man-pages) wrote: However, unless I'm sorely mistaken, the larger problem is that glibc removed the futex() call entirely, so these man pages don't describe I

Re: futex(2) man page update help request

2014-05-14 Thread Michael Kerrisk (man-pages)
On 05/15/2014 05:12 AM, Carlos O'Donell wrote: On 05/14/2014 07:34 PM, Thomas Gleixner wrote: On Wed, 14 May 2014, Carlos O'Donell wrote: On 05/14/2014 03:03 PM, Michael Kerrisk (man-pages) wrote: However, unless I'm sorely mistaken, the larger problem is that glibc removed the futex() call

Re: futex(2) man page update help request

2014-05-14 Thread Michael Kerrisk (man-pages)
Hi Thomas, On Thu, May 15, 2014 at 1:34 AM, Thomas Gleixner t...@linutronix.de wrote: On Wed, 14 May 2014, Carlos O'Donell wrote: On 05/14/2014 03:03 PM, Michael Kerrisk (man-pages) wrote: However, unless I'm sorely mistaken, the larger problem is that glibc removed the futex() call

Re: futex(2) man page update help request

2014-05-14 Thread Darren Hart
On 5/14/14, 17:18, H. Peter Anvin h...@zytor.com wrote: On 05/14/2014 09:18 AM, Darren Hart wrote: However, unless I'm sorely mistaken, the larger problem is that glibc removed the futex() call entirely, so these man pages don't describe something users even have access to anymore. I had to

futex(2) man page update help request

2014-05-14 Thread Michael Kerrisk (man-pages)
[So, some futex recent discussions remind me I should make this request] Hello all (especially those in the To:, namely Thomas, Darren, Ingo, Jakub), The futex man pages: http://man7.org/linux/man-pages/man2/futex.2.html http://man7.org/linux/man-pages/man7/futex.7.html are currently in a sorry

Re: futex(2) man page update help request

2014-05-14 Thread Darren Hart
On 5/14/14, 3:35, Michael Kerrisk (man-pages) mtk.manpa...@gmail.com wrote: [So, some futex recent discussions remind me I should make this request] Hello all (especially those in the To:, namely Thomas, Darren, Ingo, Jakub), The futex man pages:

Re: futex(2) man page update help request

2014-05-14 Thread Michael Kerrisk (man-pages)
Hi Darren, On Wed, May 14, 2014 at 6:18 PM, Darren Hart dvh...@linux.intel.com wrote: On 5/14/14, 3:35, Michael Kerrisk (man-pages) mtk.manpa...@gmail.com wrote: [So, some futex recent discussions remind me I should make this request] Hello all (especially those in the To:, namely Thomas,

Re: futex(2) man page update help request

2014-05-14 Thread Darren Hart
On 5/14/14, 12:03, Michael Kerrisk (man-pages) mtk.manpa...@gmail.com wrote: Hi Darren, On Wed, May 14, 2014 at 6:18 PM, Darren Hart dvh...@linux.intel.com wrote: On 5/14/14, 3:35, Michael Kerrisk (man-pages) mtk.manpa...@gmail.com wrote: [So, some futex recent discussions remind me I should

Re: futex(2) man page update help request

2014-05-14 Thread Carlos O'Donell
On 05/14/2014 03:03 PM, Michael Kerrisk (man-pages) wrote: However, unless I'm sorely mistaken, the larger problem is that glibc removed the futex() call entirely, so these man pages don't describe I don't think futex() ever was in glibc--that's by design, and completely understandable: no

Re: futex(2) man page update help request

2014-05-14 Thread Andy Lutomirski
On Wed, May 14, 2014 at 1:23 PM, Carlos O'Donell car...@redhat.com wrote: On 05/14/2014 03:03 PM, Michael Kerrisk (man-pages) wrote: However, unless I'm sorely mistaken, the larger problem is that glibc removed the futex() call entirely, so these man pages don't describe I don't think futex()

Re: futex(2) man page update help request

2014-05-14 Thread Davidlohr Bueso
On Wed, 2014-05-14 at 21:03 +0200, Michael Kerrisk (man-pages) wrote: Hi Darren, On Wed, May 14, 2014 at 6:18 PM, Darren Hart dvh...@linux.intel.com wrote: On 5/14/14, 3:35, Michael Kerrisk (man-pages) mtk.manpa...@gmail.com wrote: [So, some futex recent discussions remind me I should

Re: futex(2) man page update help request

2014-05-14 Thread Darren Hart
On 5/14/14, 13:56, Davidlohr Bueso davidl...@hp.com wrote: On Wed, 2014-05-14 at 21:03 +0200, Michael Kerrisk (man-pages) wrote: Hi Darren, On Wed, May 14, 2014 at 6:18 PM, Darren Hart dvh...@linux.intel.com wrote: On 5/14/14, 3:35, Michael Kerrisk (man-pages) mtk.manpa...@gmail.com

Re: futex(2) man page update help request

2014-05-14 Thread Davidlohr Bueso
On Wed, 2014-05-14 at 09:18 -0700, Darren Hart wrote: On 5/14/14, 3:35, Michael Kerrisk (man-pages) mtk.manpa...@gmail.com wrote: [So, some futex recent discussions remind me I should make this request] Hello all (especially those in the To:, namely Thomas, Darren, Ingo, Jakub), The

Re: futex(2) man page update help request

2014-05-14 Thread Paul E. McKenney
On Wed, May 14, 2014 at 02:03:13PM -0700, Darren Hart wrote: On 5/14/14, 13:56, Davidlohr Bueso davidl...@hp.com wrote: On Wed, 2014-05-14 at 21:03 +0200, Michael Kerrisk (man-pages) wrote: Hi Darren, On Wed, May 14, 2014 at 6:18 PM, Darren Hart dvh...@linux.intel.com wrote: On

Re: futex(2) man page update help request

2014-05-14 Thread Thomas Gleixner
On Wed, 14 May 2014, Carlos O'Donell wrote: On 05/14/2014 03:03 PM, Michael Kerrisk (man-pages) wrote: However, unless I'm sorely mistaken, the larger problem is that glibc removed the futex() call entirely, so these man pages don't describe I don't think futex() ever was in

Re: futex(2) man page update help request

2014-05-14 Thread H. Peter Anvin
On 05/14/2014 09:18 AM, Darren Hart wrote: However, unless I'm sorely mistaken, the larger problem is that glibc removed the futex() call entirely, so these man pages don't describe something users even have access to anymore. I had to revert to calling the syscalls directly in the futextest

Re: futex(2) man page update help request

2014-05-14 Thread H. Peter Anvin
On 05/14/2014 01:56 PM, Davidlohr Bueso wrote: However, unless I'm sorely mistaken, the larger problem is that glibc removed the futex() call entirely, so these man pages don't describe I don't think futex() ever was in glibc--that's by design, and completely understandable: no user-space

<    1   2