From owner-cvs-src@FreeBSD.ORG Thu Mar 30 20:25:53 2006 Return-Path: X-Original-To: cvs-src@FreeBSD.org Delivered-To: cvs-src@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 095AA16A401; Thu, 30 Mar 2006 20:25:53 +0000 (UTC) (envelope-from jasone@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id B91B943D8F; Thu, 30 Mar 2006 20:25:52 +0000 (GMT) (envelope-from jasone@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id k2UKPqKX072477; Thu, 30 Mar 2006 20:25:52 GMT (envelope-from jasone@repoman.freebsd.org) Received: (from jasone@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id k2UKPqs8072476; Thu, 30 Mar 2006 20:25:52 GMT (envelope-from jasone) Message-Id: <200603302025.k2UKPqs8072476@repoman.freebsd.org> From: Jason Evans Date: Thu, 30 Mar 2006 20:25:52 +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/lib/libc/stdlib malloc.c X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 30 Mar 2006 20:25:53 -0000 jasone 2006-03-30 20:25:52 UTC FreeBSD src repository Modified files: lib/libc/stdlib malloc.c Log: Optimize runtime performance, primary using the following techniques: * Avoid choosing an arena until it's certain that an arena is needed for allocation. * Convert division/multiplication to bitshifting where possible. * Avoid accessing TLS variables in single-threaded code. * Reduce the amount of pointer dereferencing. * Move lock acquisition in critical paths to only protect the the code that requires synchronization, and completely remove locking where possible. Revision Changes Path 1.120 +294 -285 src/lib/libc/stdlib/malloc.c