lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <4651F653.9060802@redhat.com>
Date:	Mon, 21 May 2007 12:43:15 -0700
From:	Ulrich Drepper <drepper@...hat.com>
To:	Eric Dumazet <dada1@...mosbay.com>
CC:	Linux Kernel <linux-kernel@...r.kernel.org>,
	Andrew Morton <akpm@...ux-foundation.org>
Subject: Re: second, bigger problem with private futexes

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Eric Dumazet wrote:
> 3) if condvar is PRIVATE and mutex is SHARED, a FUTEX_WAKE_PRIVATE
> should be done. (and loose the REQUEUE optim)
> Yes we could add a special futex primitive for this special case. But I
> cannot see how a program could use such a construct.

Very easily: mutexes are often created independently from the condvars
and they are used for many things.  Maybe a program is even creating all
mutexes as shared to be ready for all situations.  Normally doing this
is no big problem, the performance penalties are minimal.


> 4) if condvar is SHARED and mutex is private, we have a *problem*,
> because the process doing the broadcast() can be in another mm. So a
> requeue is not possible at all.

It is if we can specify the owner of the mutex.  I.e., the PID.

But yes, this case is extremely ugly.


The problem is that all these cases worked nice so far.  They all had
the same good performance.  Now we are severely penalizing code which
mismatches condvar and mutex shared attributes.  There is a good reason
why we introduced FUTEX_CMP_REQUEUE, the benefits in certain programs is
huge.

- --
➧ Ulrich Drepper ➧ Red Hat, Inc. ➧ 444 Castro St ➧ Mountain View, CA ❖
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (GNU/Linux)
Comment: Using GnuPG with Fedora - http://enigmail.mozdev.org

iD8DBQFGUfZT2ijCOnn/RHQRAkT0AJ4pgX7RtdUf8uwyP9v7o+nkv/9uMACfbx6+
kBaJLSSvDBjN09KMgmLKnSI=
=4XMz
-----END PGP SIGNATURE-----
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ