This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Patch for PR target/27880 (Use of _Unwind_GetIPInfo)


On 10/6/06, Steve Ellcey <sje@cup.hp.com> wrote:
> In addition to the uses of _Unwind_GetIPInfo that are in libstdc++ and
> libjava (already fixed), there is a use of it in unwind-c.c which is
> compiled into libgcc on IA64 Linux when using --with-system-libunwind.
>
> This patch is to ifdef that use of _Unwind_GetIPInfo so that when
> --with-system-libunwind is specified and the system unwind library does
> not contain _Unwind_GetIPInfo we will not generate any uses of it.
>
> For any cross-build, we assume that _Unwind_GetIPInfo exists.
>
> I am regression testing now (with and without --with-system-libunwind),
> OK for checkin on main line if testing goes OK?

Can you two sort out if this or

  http://gcc.gnu.org/ml/gcc-patches/2006-06/msg01023.html

or both are sufficient to fix this long-standing PR?  Steve, I see that
Geoff approves your patch, but it appearantly didn't get committed.

Thanks,
Richard.

> Steve Ellcey
> sje@cup.hp.com
>
>
>
> 2006-10-06  Steve Ellcey  <sje@cup.hp.com>
>
>         PR target/27880
>         * configure.ac (HAVE_GETIPINFO): Check for _Unwind_GetIPInfo.
>         * unwind-c.c (PERSONALITY_FUNCTION): Ifdef use of _Unwind_GetIPInfo.
>
> Index: configure.ac
> ===================================================================
> --- configure.ac        (revision 117385)
> +++ configure.ac        (working copy)
> @@ -1439,6 +1439,20 @@ if test x$enable___cxa_atexit = xyes ||
>    fi
>  fi
>
> +use_getipinfo=yes
> +if test x$with_system_libunwind = xyes; then
> +   if test x$host = x$target; then
> +     AC_SEARCH_LIBS(_Unwind_GetIPInfo, unwind,, [use_getipinfo=no])
> +   fi
> +fi
> +GCC_TARGET_TEMPLATE(HAVE_GETIPINFO)
> +if test x$use_getipinfo = xyes; then
> +   AC_DEFINE(HAVE_GETIPINFO, 1,
> +       [Define to 1 if system unwind library has _Unwind_GetIPInfo.])
> +else
> +   echo "The system unwind library does not support _Unwind_GetIPInfo."
> +fi
> +
>  # Look for a file containing extra machine modes.
>  if test -n "$extra_modes" && test -f $srcdir/config/$extra_modes; then
>    extra_modes_file='$(srcdir)'/config/${extra_modes}
>
>
> Index: unwind-c.c
> ===================================================================
> --- unwind-c.c  (revision 117385)
> +++ unwind-c.c  (working copy)
> @@ -157,7 +157,11 @@ PERSONALITY_FUNCTION (int version,
>
>    /* Parse the LSDA header.  */
>    p = parse_lsda_header (context, language_specific_data, &info);
> +#ifdef HAVE_GETIPINFO
>    ip = _Unwind_GetIPInfo (context, &ip_before_insn);
> +#else
> +  ip = _Unwind_GetIP (context);
> +#endif
>    if (! ip_before_insn)
>      --ip;
>    landing_pad = 0;
>


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]