[git commit] libubacktrace: use -funwind-tables rather than -fexecptions

Carmelo AMOROSO carmelo.amoroso at st.com
Thu Dec 22 18:19:22 UTC 2011


On 22/12/2011 15.30, Carmelo Amoroso wrote:
> commit: http://git.uclibc.org/uClibc/commit/?id=8a8434b367e0b94b9fda72c99f1c646737725403
> branch: http://git.uclibc.org/uClibc/commit/?id=refs/heads/master
> 
> For backtrace to work is enough to use -funwind-tables instead
> of -fexceptions.
> 
> Signed-off-by: Carmelo Amoroso <carmelo.amoroso at st.com>

Indeed, I'm wondering if -fasynchrous-unwind-tables should be used
rather then funwind-tables. On my arh SH4 the generated code is exactly
the same. I'm not expert of DWARF, neither gcc documentation regarding
the differences between -fexceptions, -funwind-tables or
-fasynchronous-unwind-tables helped me so much.

someone else has clearer idea ?

cheers,
carmelo

> ---
>  libubacktrace/Makefile.in |    4 ++--
>  libubacktrace/backtrace.c |    2 +-
>  2 files changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/libubacktrace/Makefile.in b/libubacktrace/Makefile.in
> index fe1fb64..a932f83 100644
> --- a/libubacktrace/Makefile.in
> +++ b/libubacktrace/Makefile.in
> @@ -26,8 +26,8 @@ libubacktrace_OUT := $(top_builddir)libubacktrace
>  libubacktrace_SRC-y :=
>  libubacktrace_SRC-$(UCLIBC_HAS_BACKTRACE) := backtrace.c backtracesyms.c backtracesymsfd.c
>  
> -# -fexections is required for backtrace to work using dwarf2
> -CFLAGS-backtrace.c := -fexceptions
> +# -funwind-tables is required for backtrace to work using dwarf2
> +CFLAGS-backtrace.c := -funwind-tables
>  
>  
>  libubacktrace_SRCS := $(addprefix $(libubacktrace_DIR)/,$(libubacktrace_SRC-y))
> diff --git a/libubacktrace/backtrace.c b/libubacktrace/backtrace.c
> index 18b91b1..e5f5130 100644
> --- a/libubacktrace/backtrace.c
> +++ b/libubacktrace/backtrace.c
> @@ -2,7 +2,7 @@
>   * Perform stack unwinding by using the _Unwind_Backtrace.
>   *
>   * User application that wants to use backtrace needs to be
> - * compiled with -fexceptions option and -rdynamic to get full
> + * compiled with -funwind-tables option and -rdynamic to get full
>   * symbols printed.
>   *
>   * Copyright (C) 2009, 2010 STMicroelectronics Ltd.
> _______________________________________________
> uClibc-cvs mailing list
> uClibc-cvs at uclibc.org
> http://lists.busybox.net/mailman/listinfo/uclibc-cvs
> 



More information about the uClibc-cvs mailing list