public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Rusty Russell <rusty@rustcorp.com.au>
To: Ingo Molnar <mingo@elte.hu>
Cc: Ulrich Drepper <drepper@redhat.com>,
	Linus Torvalds <torvalds@transmeta.com>,
	linux-kernel@vger.kernel.org
Subject: Re: [patch] futex requeueing feature, futex-requeue-2.5.69-D3
Date: Tue, 20 May 2003 18:55:29 +1000	[thread overview]
Message-ID: <20030520085911.8AC522C12C@lists.samba.org> (raw)
In-Reply-To: Your message of "Tue, 20 May 2003 08:27:03 +0200." <Pine.LNX.4.44.0305200821010.2445-100000@localhost.localdomain>

In message <Pine.LNX.4.44.0305200821010.2445-100000@localhost.localdomain> you write:
> yes, but the damage has been done already, and now we've got to start the
> slow wait for the old syscall to flush out of our tree. It will a few
> years to get rid of the compat code, but we better start now. hch is
> perfectly right that the old futex multiplexer interface is quite ugly,
> the requeue op only made this even more prominent.

It's a judgement call: how simple it is to change vs. the amount of
damage done by not changing it.

I don't think it's worth changing, but I don't think we're going to
convince each other.

> > Comment says: /* Must be "naturally" aligned */.  This used to be true
> > in a much earlier version of the code, now AFAICT the requirement test
> > should be:
> > 

> > 	/* Handling futexes on multiple pages?  -ETOOHARD */
> > 	if (pos_in_page + sizeof(u32) > PAGE_SIZE)
> > 		return -EINVAL;
> 
> yes - but i'd rather enforce this for every futex, than to hit it in every
> 1000th app that manages to misalign a futex _and_ lay it across two pages.  

Good point.  I'd prefer to fix the comment though, since it's not
true.  How about changing it to something like:

      	/* We can't handle futexes across multiple pages: best to reject
	   any crazy alignment to save the users from themselves. */

> Also, it's only x86 that guarantees atomic instructions on misaligned
> futexes (even then it comes with a cycle penalty), are you sure this also
> works on other architectures? So i'd rather be a bit more strict with this
> requirement.

Sure.  My point was that this comment is actually from a v. early futex
version where the kernel actually did the atomic ops itself.

Hope that clarifies!
Rusty.
--
  Anyone who quotes me in their sig is an idiot. -- Rusty Russell.

  parent reply	other threads:[~2003-05-20  8:46 UTC|newest]

Thread overview: 53+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-05-19  9:31 [patch] futex requeueing feature, futex-requeue-2.5.69-D3 Ingo Molnar
2003-05-19 10:10 ` Christoph Hellwig
2003-05-19 10:16   ` Ingo Molnar
2003-05-19 11:49     ` Christoph Hellwig
2003-05-19 12:33       ` [patch] futex API cleanups, futex-api-cleanup-2.5.69-A2 Ingo Molnar
2003-05-19 12:51         ` Ingo Molnar
2003-05-19 14:47         ` bert hubert
2003-05-19 16:02           ` Ingo Molnar
2003-05-19 15:18         ` Linus Torvalds
2003-05-19 16:06           ` Ingo Molnar
2003-05-19 23:33             ` Jamie Lokier
2003-05-20  0:39               ` Rusty Russell
2003-05-20  1:14                 ` Davide Libenzi
2003-05-20  1:44                   ` Jamie Lokier
2003-05-20 16:54                     ` Davide Libenzi
2003-05-20 17:59                       ` Jamie Lokier
2003-05-21 23:56                         ` Davide Libenzi
2003-05-20  1:50                 ` Jamie Lokier
2003-05-20  0:15             ` Rusty Russell
2003-05-20  0:08   ` [patch] futex requeueing feature, futex-requeue-2.5.69-D3 Rusty Russell
2003-05-20  0:31     ` Valdis.Kletnieks
2003-05-19 10:23 ` Andrew Morton
2003-05-19 10:30   ` [patch] futex requeueing feature, futex-requeue-2.5.69-D4 Ingo Molnar
2003-05-20  0:04 ` [patch] futex requeueing feature, futex-requeue-2.5.69-D3 Rusty Russell
2003-05-20  0:40   ` Ulrich Drepper
2003-05-20  1:46     ` Rusty Russell
2003-05-20  2:11       ` Ulrich Drepper
2003-05-20  6:27       ` Ingo Molnar
2003-05-20  6:56         ` Christoph Hellwig
2003-05-20  8:57           ` Rusty Russell
2003-05-20  9:03             ` Ingo Molnar
2003-05-20  9:51               ` Christoph Hellwig
2003-05-20 12:56                 ` [patch] futex patches, futex-2.5.69-A2 Ingo Molnar
2003-05-20 14:08                   ` Christoph Hellwig
2003-05-20 16:02                     ` Ingo Molnar
2003-05-20 19:55                       ` Christoph Hellwig
2003-05-21  5:06                         ` Martin Schlemmer
2003-05-21  6:31                           ` Christoph Hellwig
2003-05-20 15:46                 ` [patch] futex requeueing feature, futex-requeue-2.5.69-D3 Linus Torvalds
2003-05-20  9:12           ` Ingo Oeser
2003-05-20 15:41           ` Linus Torvalds
2003-05-20  8:55         ` Rusty Russell [this message]
2003-05-20  6:19   ` Ingo Molnar
     [not found] <3ECAC2AE.8090401@redhat.com>
2003-05-21  2:34 ` Rusty Russell
2003-05-21  9:48   ` Ingo Molnar
2003-05-21 10:24     ` Christoph Hellwig
2003-05-22  0:30     ` Rusty Russell
2003-05-22  9:15       ` Ingo Molnar
2003-05-22 10:35         ` Rusty Russell
  -- strict thread matches above, loose matches on Subject: below --
2003-05-22 11:23 Martin Wirth
2003-05-22 11:34 ` Ingo Molnar
2003-05-22 12:04   ` William Lee Irwin III
     [not found] <3ECCB319.4060706@dlr.de.suse.lists.linux.kernel>
2003-05-22 11:38 ` Andi Kleen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20030520085911.8AC522C12C@lists.samba.org \
    --to=rusty@rustcorp.com.au \
    --cc=drepper@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=torvalds@transmeta.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox