From owner-freebsd-hackers@FreeBSD.ORG Thu Apr 12 19:50:28 2007 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 0902B16A400 for ; Thu, 12 Apr 2007 19:50:28 +0000 (UTC) (envelope-from citrin@citrin.ru) Received: from mail.classis.ru (classis.ru [213.248.60.120]) by mx1.freebsd.org (Postfix) with ESMTP id B71D813C46A for ; Thu, 12 Apr 2007 19:50:27 +0000 (UTC) (envelope-from citrin@citrin.ru) Received: from CITRIN (ppp91-76-84-245.pppoe.mtu-net.ru [91.76.84.245]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) (Authenticated sender: citrin.citrin.ru) by mail.classis.ru (Postfix) with ESMTP id 69F291227BE2 for ; Thu, 12 Apr 2007 23:50:25 +0400 (MSD) Date: Thu, 12 Apr 2007 23:49:11 +0400 From: Anton Yuzhaninov X-Mailer: The Bat! (v3.62.14) Professional Organization: Rambler X-Priority: 3 (Normal) Message-ID: <1891307882.20070412234911@citrin.ru> To: freebsd-hackers@freebsd.org In-Reply-To: <20070412190849.63355.qmail@web27705.mail.ukl.yahoo.com> References: <20070412190849.63355.qmail@web27705.mail.ukl.yahoo.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Subject: Re: tcp connection splitter X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 12 Apr 2007 19:50:28 -0000 Hello Daniel, You wrote on Thursday, April 12, 2007, 11:08:49 PM: DT> I could use read-write locks here (single writer, DT> multiple readers) but it doesn't help with write DT> lock contention. DT> There must be some clever lockless algorithm to DT> achieve the same effect. Try see FSM server model (e. g. using libevent). If all clients served by single thread, and signle process (using noblocking sockets) then no locks need. This model scale up to 50k-100k connections per host. -- Anton Yuzhaninov.