From owner-freebsd-questions@FreeBSD.ORG Thu May 31 02:45:16 2007 Return-Path: X-Original-To: freebsd-questions@freebsd.org Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id AC06816A41F for ; Thu, 31 May 2007 02:45:16 +0000 (UTC) (envelope-from kayama@personal-media.co.jp) Received: from net1.personal-media.co.jp (net1.personal-media.co.jp [61.197.224.164]) by mx1.freebsd.org (Postfix) with ESMTP id 769B813C44B for ; Thu, 31 May 2007 02:45:16 +0000 (UTC) (envelope-from kayama@personal-media.co.jp) Received: from pcsv1.personal-media.co.jp (net2 [192.168.201.168]) by net1.personal-media.co.jp (Postfix) with ESMTP id 5544CAE0F7; Thu, 31 May 2007 11:45:15 +0900 (JST) Received: from localhost (r53 [192.9.200.153]) by pcsv1.personal-media.co.jp (Postfix) with ESMTP id 39D143598A; Thu, 31 May 2007 11:45:15 +0900 (JST) Date: Thu, 31 May 2007 11:45:15 +0900 (GMT-9) Message-Id: <20070531.114515.133762361.kayama@personal-media.co.jp> To: cswiger@mac.com From: Akihiro KAYAMA In-Reply-To: <465DB587.6010109@mac.com> References: <20070528.154753.32719103.kayama@personal-media.co.jp> <465DB587.6010109@mac.com> X-Mailer: Mew version 3.3 on Emacs 21.2 / Mule 5.0 (SAKAKI) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: freebsd-questions@freebsd.org Subject: Re: wall-clock time profiling X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 31 May 2007 02:45:16 -0000 In article <465DB587.6010109@mac.com>, Chuck Swiger writes: cswiger> Akihiro KAYAMA wrote: cswiger> > Hi all. cswiger> > cswiger> > What is the right way to measure wall-clock time in profiling on FreeBSD? cswiger> cswiger> The time shell builtin command or "/usr/bin/time -l _program_"? cswiger> cswiger> The latter variant displays the rusage struct (ie, from "man getrusage")? Thanks for your response. Yes, we can know whether the program is I/O bound or CPU bound by time(1). But it is still unclear which part of the program is really waiting for I/O. So profiling is needed for tuning, although CPU time profiling gives me non-distinct result on I/O bound programs. It is reason why I want wall-clock time profiling. -- Akihiro KAYAMA