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]

Fix error inlining REG_EH_REGION notes


This is an obviously-correct fix, though it took me several hours to
find.  This may have been the source of the belief that sibcall and EH
didn't work together.  This will happen if both EH and sibcall are enabled,
the RTL inliner is used, and a function getting sibcall processing has an
arg that includes a call to an inlined function that, in turn, has a call
to a const function.  

The test case here is the Ada run-time module a-nlcefu.ads compiled on
Alpha/OSF with -O2 -gnatpgn -mno-bwx.  gnat1 gets a SIGSEGV.

Tested on alphaev56-dec-osf4.0c.

Thu Dec 27 09:50:44 2001  Richard Kenner  <kenner@vlsi1.ultra.nyu.edu>

	* integrate.c (copy_insn_notes): Don't adjust REG_EH_REGION note
	if special value.

*** integrate.c	2001/11/15 03:02:23	1.176
--- integrate.c	2001/12/27 03:28:57
*************** copy_insn_notes (insns, map, eh_region_o
*** 1686,1690 ****
  	      if (REG_NOTE_KIND (note) == REG_LABEL)
  	        remove_note (new_insn, note);
! 	      else if (REG_NOTE_KIND (note) == REG_EH_REGION)
  	        XEXP (note, 0) = GEN_INT (INTVAL (XEXP (note, 0))
  					  + eh_region_offset);
--- 1686,1691 ----
  	      if (REG_NOTE_KIND (note) == REG_LABEL)
  	        remove_note (new_insn, note);
! 	      else if (REG_NOTE_KIND (note) == REG_EH_REGION
! 		       && INTVAL (XEXP (note, 0)) > 0)
  	        XEXP (note, 0) = GEN_INT (INTVAL (XEXP (note, 0))
  					  + eh_region_offset);


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