From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 27334 invoked by alias); 2 Nov 2005 13:45:37 -0000 Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org Received: (qmail 27325 invoked by uid 22791); 2 Nov 2005 13:45:35 -0000 Received: from nevyn.them.org (HELO nevyn.them.org) (66.93.172.17) by sourceware.org (qpsmtpd/0.30-dev) with ESMTP; Wed, 02 Nov 2005 13:45:35 +0000 Received: from drow by nevyn.them.org with local (Exim 4.54) id 1EXIvg-0006yv-SA; Wed, 02 Nov 2005 08:45:28 -0500 Date: Wed, 02 Nov 2005 13:45:00 -0000 From: Daniel Jacobowitz To: MCG LU Fengcheng Cc: gdb@sourceware.org Subject: Re: Why are NOT the function parametters in the stack. They are in the register! Message-ID: <20051102134528.GC26674@nevyn.them.org> Mail-Followup-To: MCG LU Fengcheng , gdb@sourceware.org References: <7E98B33B3500C0409DBEC5C0E3FDEF120230B583@htmail.sbell.com.cn> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <7E98B33B3500C0409DBEC5C0E3FDEF120230B583@htmail.sbell.com.cn> User-Agent: Mutt/1.5.8i X-SW-Source: 2005-11/txt/msg00030.txt.bz2 On Wed, Nov 02, 2005 at 02:07:26PM +0800, MCG LU Fengcheng wrote: > (gdb) p &traceType > Address requested for identifier "traceType" which is in register $eax > (gdb) p &fmt > Address requested for identifier "fmt" which is in register $eax > > gdb complains fmt and traceType are in the register eax. Why not in the stack. In fact, lineNo and filename are in the stack. Gdb can print their address out. > > I check the eax value. It is zero. I also check the stack. I found the fmt and traceType address were in the stack. > > It's the gdb issue? I can't understand it. Usually this means they are no longer "available", but debug information has failed to represent that fact. They were loaded from the stack, used, and then not used after the current call returns. Don't worry about it. -- Daniel Jacobowitz CodeSourcery, LLC