From mboxrd@z Thu Jan 1 00:00:00 1970 From: Andrew Cagney To: Vermeulen Jan Cc: "'gdb@sources.redhat.com'" Subject: Re: powerpc simulator questions Date: Tue, 27 Nov 2001 20:39:00 -0000 Message-id: <3C046A8F.1060704@cygnus.com> References: X-SW-Source: 2001-11/msg00296.html > Hey, > > Thanks for the suggestions. > It was indeed the memorymap that went haywire. (or the author :) > > I managed to debug/simulate my code. Very nice. > > Just one more question: > with powerpc-eabi-run, i can see how many cycles have passed for the > program. > > 1) if I want to know how long it would take on a 200MHz powerpc (and the > routine takes about 35e6 cycles), then am i correct to use this formula : > 35e6 cycles / 200e6 Mhz = 175 milliseconds ? > > 2) is the same type of performance measuring in the simulator under gdb? > for example: breakpoint before a routine, breakpoint after one, and then a > command "give me number of cycles passed between those 2 breakpoints > (please)." I wouldn't take the profile statistics too seriously. No one ever sat down and analized them (Er, there might have been one report to only indicate that they were way out :-/). I should probably delete that code (so no one is mis-lead). It is also known to go into infinite loops :-( Andrew From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 7170 invoked by alias); 28 Nov 2001 04:39:51 -0000 Mailing-List: contact gdb-help@sourceware.cygnus.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sources.redhat.com Received: (qmail 7140 invoked from network); 28 Nov 2001 04:39:44 -0000 Received: from unknown (HELO localhost.cygnus.com) (24.114.42.213) by hostedprojects.ges.redhat.com with SMTP; 28 Nov 2001 04:39:44 -0000 Received: from cygnus.com (localhost [127.0.0.1]) by localhost.cygnus.com (Postfix) with ESMTP id 9A3E43DC2; Tue, 27 Nov 2001 23:39:43 -0500 (EST) Message-ID: <3C046A8F.1060704@cygnus.com> Date: Sun, 18 Nov 2001 11:45:00 -0000 From: Andrew Cagney User-Agent: Mozilla/5.0 (X11; U; NetBSD macppc; en-US; rv:0.9.3) Gecko/20011020 X-Accept-Language: en-us MIME-Version: 1.0 To: Vermeulen Jan Cc: "'gdb@sources.redhat.com'" Subject: Re: powerpc simulator questions References: Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-SW-Source: 2001-11/txt/msg00189.txt.bz2 Message-ID: <20011118114500.1-eNwfqb2JdA9PViKnn_15dsy05QMzfa-fKQWdy5IvY@z> > Hey, > > Thanks for the suggestions. > It was indeed the memorymap that went haywire. (or the author :) > > I managed to debug/simulate my code. Very nice. > > Just one more question: > with powerpc-eabi-run, i can see how many cycles have passed for the > program. > > 1) if I want to know how long it would take on a 200MHz powerpc (and the > routine takes about 35e6 cycles), then am i correct to use this formula : > 35e6 cycles / 200e6 Mhz = 175 milliseconds ? > > 2) is the same type of performance measuring in the simulator under gdb? > for example: breakpoint before a routine, breakpoint after one, and then a > command "give me number of cycles passed between those 2 breakpoints > (please)." I wouldn't take the profile statistics too seriously. No one ever sat down and analized them (Er, there might have been one report to only indicate that they were way out :-/). I should probably delete that code (so no one is mis-lead). It is also known to go into infinite loops :-( Andrew