From mint-bounce@lists.fishpool.fi  Fri Feb 22 13:03:52 2008
From: Eero Tamminen <oak@helsinkinet.fi>
Organization: Koti
To: mint@lists.fishpool.fi
Subject: Re: [MiNT] Automatic -fomit-frame-pointer usage
Date: Fri, 22 Feb 2008 19:45:02 +0200
User-Agent: KMail/1.9.6
Cc: Vincent =?iso-8859-1?q?Rivi=E8re?= <vincent.riviere@freesbee.fr>,
        mint <mint@fishpool.com>
References: <47BECA07.8020506@freesbee.fr>
In-Reply-To: <47BECA07.8020506@freesbee.fr>
MIME-Version: 1.0
Content-Type: text/plain;
  charset="iso-8859-1"
Content-Disposition: inline
Message-Id: <200802221945.02775.oak@helsinkinet.fi>
X-ecartis-version: Ecartis v1.0.0
Sender: mint-bounce@lists.fishpool.fi
Errors-to: mint-bounce@lists.fishpool.fi
X-original-sender: oak@helsinkinet.fi
Precedence: bulk
List-help: <mailto:ecartis@lists.fishpool.fi?Subject=help>
List-unsubscribe: <mailto:mint-request@lists.fishpool.fi?Subject=unsubscribe>
List-Id: <mint.lists.fishpool.fi>
X-List-ID: <mint.lists.fishpool.fi>
List-subscribe: <mailto:mint-request@lists.fishpool.fi?Subject=subscribe>
List-owner: <mailto:tjhukkan@fishpool.fi>
List-post: <mailto:mint@lists.fishpool.fi>
Content-Transfer-Encoding: 8bit
X-MIME-Autoconverted: from quoted-printable to 8bit by mail.sparemint.org id m1MI3lX7030612

Hi,

On Friday 22 February 2008, Vincent Rivière wrote:
> The usage of the frame pointer (actually a6) allows gdb to determine
> precisely the call stack when a breakpoint is hit. It is very useful for
> debugging,

And for callgraphs which help a lot in both memory and performance
analysis. :-)

> that's why the frame pointer is always used when -O is not 
> used. When some level of optimization is used, it is very hard to use the
> debugger, because the instructions are usually reordered, most variable
> values are inaccessible because they are stored in registers.

FYI: GCC 4.x and later Gdb versions support locationlists which are supposed
to help with this.


> And without the frame pointer, it may be impossible to know from which
> functions we are called.


	- Eero


