This is the mail archive of the 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]

Patch for PR target/27880 (Use of _Unwind_GetIPInfo)

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?

Steve Ellcey

2006-10-06  Steve Ellcey  <>

	PR target/27880
	* (HAVE_GETIPINFO): Check for _Unwind_GetIPInfo.
	* unwind-c.c (PERSONALITY_FUNCTION): Ifdef use of _Unwind_GetIPInfo.

---	(revision 117385)
+++	(working copy)
@@ -1439,6 +1439,20 @@ if test x$enable___cxa_atexit = xyes || 
+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
+if test x$use_getipinfo = xyes; then
+	[Define to 1 if system unwind library has _Unwind_GetIPInfo.])
+   echo "The system unwind library does not support _Unwind_GetIPInfo."
 # Look for a file containing extra machine modes.
 if test -n "$extra_modes" && test -f $srcdir/config/$extra_modes; then

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);
   ip = _Unwind_GetIPInfo (context, &ip_before_insn);
+  ip = _Unwind_GetIP (context);
   if (! ip_before_insn)
   landing_pad = 0;

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