This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: Enable -fomit-frame-pointer on i386
> Jan Hubicka writes:
> > > Jan Hubicka writes:
> > > > > Jan Hubicka writes:
> > > > > > Perhaps we can simply replace use of backtrace() in libjava by
> > > > > > the Jakub's unwind based implementation to break the dependency on
> > > > > > targets where unwind info shall be available (ia-64/x86-64/i386/s390 at
> > > > > > least)
> > > > >
> > > > > That's a good idea. Bryce is working on such a patch, I believe.
> > > > >
> > > > > In the meantime, this is what we do with x86-64
> > > > >
> > > > > in configure.in:
> > > > >
> > > > > BACKTRACESPEC=
> > > > > case "${host}" in
> > > > > x86_64*-*-linux*)
> > > > > BACKTRACESPEC=-fno-omit-frame-pointer
> > > > > ;;
> > > > > esac
> > > > >
> > > > > And configure.host:
> > > > >
> > > > > x86_64-*)
> > > > > CHECKREFSPEC="%{m32:-fcheck-references}"
> > > > > sysdeps_dir=x86-64
> > > > > libgcj_flags="${libgcj_flags} -ffloat-store -fno-omit-frame-pointer"
> > > >
> > > > I this still important? x86-64 glibc can do unwinding without frame
> > > > pointer for some time already.
> > >
> > > It's important until no-one uses an earlier glibc. Leave it 'til 3.5.
> >
> > When the glibc switched to dwarf2 unwinding? I was under impressions
> > that all released glibcs does it. At least glibc CVS apparently never
> > contained some other implementation
>
> AFAICS x86_64 used sysdeps/generic/backtrace.c until 2003/10/05.
>
> 2003-10-05 Jakub Jelinek <jakub@redhat.com>
>
> * sysdeps/ia64/backtrace.c: New file.
> * sysdeps/x86_64/backtrace.c: New file.
> * sysdeps/generic/unwind.h (_Unwind_Trace_Fn): New type.
> (_Unwind_Backtrace): New prototype.
I see, we had backtrace more or less broken for a while, so I guess I
will do the change just for 3.5 (if that does not sound resonable
either, just complain :)
Thanks,
Honza
>
> Andrew.