From owner-cvs-all Mon Apr 1 16: 1:57 2002 Delivered-To: cvs-all@freebsd.org Received: from freefall.freebsd.org (freefall.FreeBSD.org [216.136.204.21]) by hub.freebsd.org (Postfix) with ESMTP id 886CB37B419; Mon, 1 Apr 2002 16:01:49 -0800 (PST) Received: (from des@localhost) by freefall.freebsd.org (8.11.6/8.11.6) id g3201np92735; Mon, 1 Apr 2002 16:01:49 -0800 (PST) (envelope-from des) Message-Id: <200204020001.g3201np92735@freefall.freebsd.org> From: Dag-Erling Smorgrav Date: Mon, 1 Apr 2002 16:01:49 -0800 (PST) To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: cvs commit: src/sys/conf options src/sys/kern kern_mutex.c src/sys/sys _mutex.h X-FreeBSD-CVS-Branch: HEAD Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG des 2002/04/01 16:01:49 PST Modified files: sys/conf options sys/kern kern_mutex.c sys/sys _mutex.h Log: Mutex profiling code, conditional on the MUTEX_PROFILING option. Adds the following sysctl variables: debug.mutex.prof.enable enable / disable profiling debug.mutex.prof.acquisitions number of mutex acquisitions recorded debug.mutex.prof.records number of acquisition points recorded debug.mutex.prof.maxrecords max number of acquisition points debug.mutex.prof.rejected number of rejections (due to full table) debug.mutex.prof.hashsize hash size debug.mutex.prof.collisions number of hash collisions debug.mutex.prof.stats profiling statistics The code records four numbers for each acquisition point (identified by source file name and line number): longest time held, total time held, number of non-recursive acquisitions, average time held. The measurements are in clock cycles (as returned by get_cyclecount(9)); this may cause measurements on some SMP systems to be unreliable. This can probably be worked around by replacing get_cyclecount(9) by some incarnation of nanotime(9). This work was derived from initial patches by eivind. Revision Changes Path 1.308 +3 -0 src/sys/conf/options 1.84 +159 -2 src/sys/kern/kern_mutex.c 1.5 +5 -0 src/sys/sys/_mutex.h To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message