From owner-cvs-all@FreeBSD.ORG Sat Jun 17 17:32:40 2006 Return-Path: X-Original-To: cvs-all@FreeBSD.org Delivered-To: cvs-all@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id F13F016A47A; Sat, 17 Jun 2006 17:32:40 +0000 (UTC) (envelope-from andre@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4BEDD43D5A; Sat, 17 Jun 2006 17:32:39 +0000 (GMT) (envelope-from andre@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k5HHWdnt086273; Sat, 17 Jun 2006 17:32:39 GMT (envelope-from andre@repoman.freebsd.org) Received: (from andre@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k5HHWdl9086272; Sat, 17 Jun 2006 17:32:39 GMT (envelope-from andre) Message-Id: <200606171732.k5HHWdl9086272@repoman.freebsd.org> From: Andre Oppermann Date: Sat, 17 Jun 2006 17:32:38 +0000 (UTC) To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org X-FreeBSD-CVS-Branch: HEAD Cc: Subject: cvs commit: src/sys/netinet tcp_input.c tcp_syncache.c tcp_var.h X-BeenThere: cvs-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: CVS commit messages for the entire tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 17 Jun 2006 17:32:41 -0000 andre 2006-06-17 17:32:38 UTC FreeBSD src repository Modified files: sys/netinet tcp_input.c tcp_syncache.c tcp_var.h Log: Add locking to TCP syncache and drop the global tcpinfo lock as early as possible for the syncache_add() case. The syncache timer no longer aquires the tcpinfo lock and timeout/retransmit runs can happen in parallel with bucket granularity. On a P4 the additional locks cause a slight degression of 0.7% in tcp connections per second. When IP and TCP input are deserialized and can run in parallel this little overhead can be neglected. The syncookie handling still leaves room for improvement and its random salts may be moved to the syncache bucket head structures to remove the second lock operation currently required for it. However this would be a more involved change from the way syncookies work at the moment. Reviewed by: rwatson Tested by: rwatson, ps (earlier version) Sponsored by: TCP/IP Optimization Fundraise 2005 Revision Changes Path 1.299 +9 -6 src/sys/netinet/tcp_input.c 1.87 +286 -255 src/sys/netinet/tcp_syncache.c 1.130 +9 -6 src/sys/netinet/tcp_var.h