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: <20081118144053.0072d54c@lxorguk.ukuu.org.uk>
Date:	Tue, 18 Nov 2008 14:40:53 +0000
From:	Alan Cox <alan@...rguk.ukuu.org.uk>
To:	Mikulas Patocka <mpatocka@...hat.com>
Cc:	Peter Zijlstra <peterz@...radead.org>,
	linux-kernel@...r.kernel.org, mingo@...e.hu, rml@...h9.net,
	Alasdair G Kergon <agk@...hat.com>,
	Milan Broz <mbroz@...hat.com>
Subject: Re: Active waiting with yield()

> You will touch the wait queue always when finishing the last pending 
> request --- just to find out that there is no one waiting on it.

Why ? If my fast path for this something like

	if (unlikely(foo->unload_pending) && count == 0)
		wake_up(..)

chances are that I can put unload_pending somewhere in a cache line with
other stuff (certainly for L2) and it will get predicted well.

> And besides cache line, there is coding and testing overhead with wait 
> queues.

If you want correctness you don't want busy waiting with yields - as Ingo
pointed out already thats a bug in itself with hard realtime.

> So what are the reasons why you (and others) are against active waiting? 
> All you are saying is that my reasons are wrong, but you haven't single 
> example when active waiting causes trouble. If there is a workload when 

Untrue - I've given very clear reasons twice, and Ingo has given you
more. If you don't wish to accept the answers that is your problem not
mine, just expect such hacks to get a NAK and not make the kernel.

Alan
--
"I can only provide the information, I can't make you hear it."
		- Shelley Bainter

--
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