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: forced-exception tests fail on SJLJ


On Thu, Apr 03, 2003 at 02:44:44PM +0100, Richard Earnshaw wrote:
> Getting closer.  Now it fails with:
> 
> /tmp/ccGqBsBb.o(.text+0xa8): In function `force_unwind()':
> : undefined reference to `_Unwind_ForcedUnwind'

Fixed thus.  Tested with i686 --enable-sjlj-exceptions.


r~


        * g++.dg/eh/forced1.C: Use _Unwind_SjLj_ForcedUnwind as appropriate.
        * g++.dg/eh/forced2.C: Likewise.

Index: gcc/testsuite/g++.dg/eh/forced1.C
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/g++.dg/eh/forced1.C,v
retrieving revision 1.1
diff -c -p -d -u -r1.1 forced1.C
--- gcc/testsuite/g++.dg/eh/forced1.C	2 Apr 2003 07:08:16 -0000	1.1
+++ gcc/testsuite/g++.dg/eh/forced1.C	5 Apr 2003 00:43:21 -0000
@@ -31,7 +31,11 @@ static void force_unwind ()
   exc->exception_class = 0;
   exc->exception_cleanup = 0;
                    
+#ifndef __USING_SJLJ_EXCEPTIONS__
   _Unwind_ForcedUnwind (exc, force_unwind_stop, 0);
+#else
+  _Unwind_SjLj_ForcedUnwind (exc, force_unwind_stop, 0);
+#endif
                    
   abort ();
 }
Index: gcc/testsuite/g++.dg/eh/forced2.C
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/g++.dg/eh/forced2.C,v
retrieving revision 1.1
diff -c -p -d -u -r1.1 forced2.C
--- gcc/testsuite/g++.dg/eh/forced2.C	2 Apr 2003 07:08:16 -0000	1.1
+++ gcc/testsuite/g++.dg/eh/forced2.C	5 Apr 2003 00:43:21 -0000
@@ -34,9 +34,13 @@ force_unwind () throw()
   _Unwind_Exception *exc = new _Unwind_Exception;
   exc->exception_class = 0;
   exc->exception_cleanup = 0;
-                   
+
+#ifndef __USING_SJLJ_EXCEPTIONS__
   _Unwind_ForcedUnwind (exc, force_unwind_stop, 0);
-                   
+#else
+  _Unwind_SjLj_ForcedUnwind (exc, force_unwind_stop, 0);
+#endif
+
   abort ();
 }
 


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