From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 21887 invoked by alias); 31 Dec 2006 15:39:00 -0000 Received: (qmail 21879 invoked by uid 22791); 31 Dec 2006 15:38:59 -0000 X-Spam-Check-By: sourceware.org Received: from zigzag.lvk.cs.msu.su (HELO zigzag.lvk.cs.msu.su) (158.250.17.23) by sourceware.org (qpsmtpd/0.31) with ESMTP; Sun, 31 Dec 2006 15:38:54 +0000 Received: from Debian-exim by zigzag.lvk.cs.msu.su with spam-scanned (Exim 4.50) id 1H12lr-0002m5-B8 for gdb-patches@sources.redhat.com; Sun, 31 Dec 2006 18:38:52 +0300 Received: from localhost ([127.0.0.1] helo=ip6-localhost) by zigzag.lvk.cs.msu.su with esmtp (Exim 4.50) id 1H12lf-0002Zf-GT; Sun, 31 Dec 2006 18:38:35 +0300 From: Vladimir Prus Subject: Re: [PATCH] MI: new timing command To: Mark Kettenis , gdb-patches@sources.redhat.com Date: Sun, 31 Dec 2006 15:39:00 -0000 References: <17814.10139.269708.848818@kahikatea.snap.net.nz> <17814.58031.865155.682869@kahikatea.snap.net.nz> <20061231042547.GA3236@nevyn.them.org> <17815.18190.987950.612053@kahikatea.snap.net.nz> <20061231054946.GA4873@nevyn.them.org> <17815.27092.497145.908734@kahikatea.snap.net.nz> <20061231151527.GC16449@nevyn.them.org> <200612311524.kBVFObud010411@brahms.sibelius.xs4all.nl> User-Agent: KNode/0.10.2 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7Bit Message-Id: Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2006-12/txt/msg00412.txt.bz2 Mark Kettenis wrote: >> Date: Sun, 31 Dec 2006 10:15:27 -0500 >> From: Daniel Jacobowitz >> >> On Sun, Dec 31, 2006 at 08:42:12PM +1300, Nick Roberts wrote: >> > Daniel Jacobowitz writes: >> > > In that case you can copy the necessary guards from that file. >> > > However, it does more than just getrusage - it also supports >> > > platforms with times() but without getrusage, which IIRC includes >> > > Windows, so it might be better to use it. >> > >> > But as a last resort it returns elapsed time which would be wrong. >> >> You keep saying this but I don't see why. Why is it wrong? On every >> platform where we can do it, we'll print usage; on platforms where we >> can't do it, the odds are pretty good that the OS isn't aggressively >> scheduling other tasks in while we're running, so wall time is pretty >> close to right. > > I agree completely. Is this important? This timing is entirely for diagnostic purposes, so why try to make it work on every possible platform. We need to document that -enable-timing may fail, and that's it. - Volodya