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]

distribute_notes does not handle REG_EH_RETHROW


Here is a small test case to make the compiler (for target m68k-linux)
crash in distribute_notes, because it does not know how to handle
REG_EH_RETHROW notes:

struct X { int x; };
class Y : public X { protected: Y(); public: virtual ~Y(); };
class Z : public Y { public: Z(); ~Z(); };
void X_init (X *);
Z::Z () { X_init (this); }

It does not happen on ix86 because there is nothing to combine.


Tue Aug 17 16:18:18 1999  Andreas Schwab  <schwab@suse.de>

	* combine.c (distribute_notes): Handle REG_EH_RETHROW.

Index: combine.c
===================================================================
RCS file: /egcs/carton/cvsfiles/egcs/gcc/combine.c,v
retrieving revision 1.66
diff -u -a -u -r1.66 combine.c
--- combine.c	1999/08/09 13:59:42	1.66
+++ combine.c	1999/08/17 14:18:11
@@ -11407,8 +11407,9 @@
 	  break;
 
 	case REG_EH_REGION:
-	  /* This note must remain with the call.  It should not be possible
-	     for both I2 and I3 to be a call.  */
+	case REG_EH_RETHROW:
+	  /* These notes must remain with the call.  It should not be
+	     possible for both I2 and I3 to be a call.  */
 	  if (GET_CODE (i3) == CALL_INSN) 
 	    place = i3;
 	  else if (i2 && GET_CODE (i2) == CALL_INSN)

-- 
Andreas Schwab                                  "And now for something
schwab@suse.de                                   completely different."
SuSE GmbH, Schanzäckerstr. 10, D-90443 Nürnberg

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