Date: Wed, 8 Apr 2009 14:16:53 +0100 (BST) From: Robert Watson <rwatson@FreeBSD.org> To: Barney Cordoba <barney_cordoba@yahoo.com> Cc: freebsd-net@freebsd.org, Ivan Voras <ivoras@freebsd.org> Subject: Re: Advice on a multithreaded netisr patch? Message-ID: <alpine.BSF.2.00.0904081412540.61921@fledge.watson.org> In-Reply-To: <871699.35154.qm@web63906.mail.re1.yahoo.com> References: <871699.35154.qm@web63906.mail.re1.yahoo.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Wed, 8 Apr 2009, Barney Cordoba wrote: > Is there any work being done on lighter weight locks for queues? It seems > ridiculous to avoid using queues because of lock contention when the locks > are only protecting a couple lines of code. My reading is that there are two, closely related, things going on: the first is lock contention, and the second is cache line contention. We have a primitive in 8.x (don't think it's been MFC'd yet) for a lockless atomic buffer primitive for use in drivers and other parts of the stack. However, that addresses only lock contention, not line contention, which at a high PPS will be an issue as well. Only by moving to independent data structures (i.e., on independent cache lines) can we reduce line contention. Robert N M Watson Computer Laboratory University of Cambridge
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?alpine.BSF.2.00.0904081412540.61921>