6.16 gcc omit-frame pointer
keltor at keltor.org
Tue Nov 30 20:59:35 PST 2010
On Mon, Nov 29, 2010 at 11:09 AM, David Jensen
<djensenlin at windstream.net> wrote:
> Note: Section 5.10, “GCC-4.5.1 - Pass 2” does not use a case statement
> for the frame-pointer. Problematic for x86_64? Perhaps both sections
> should be:
> case `uname -m` in
> i?86 | x86_64) sed -i 's/^T_CFLAGS =$/& -fomit-frame-pointer/' \
> gcc/Makefile.in ;;
> David Jensen
> FAQ: http://www.linuxfromscratch.org/faq/
> Unsubscribe: See the above information page
gdb on AMD64 uses stack unwind instead of the frame pointer. The
default on x86 is still to use the frame pointer. The frame pointer
is really unneeded unless you have a compiler that doesn't put enough
stack info into the binaries.
<<-- more than you ever wanted to know about the call stack, frame
pointers, and unwind.
gcc-4.6 will make -fomit-frame-pointer the default on Linux/x86.
More information about the lfs-dev