Fix to depressed-stack-pointer calls

Richard Kenner kenner@vlsi1.ultra.nyu.edu
Sat Dec 15 15:03:00 GMT 2001


This feature is used only by Ada, and only when enabled.  This change
avoids an ICE on x86 compiling the Ada library.

Sat Dec 15 17:53:03 2001  Richard Kenner  <kenner@vlsi1.ultra.nyu.edu>

	* calls.c (emit_call_1): If ECF_SP_DEPRESSED, pretend have adjusted
	for rounded_stack_size.

*** calls.c	2001/12/11 23:02:46	1.213
--- calls.c	2001/12/15 22:56:42
*************** emit_call_1 (funexp, fndecl, funtype, st
*** 647,653 ****
  	 stack pointer will be changed.  */
  
!       if (rounded_stack_size != 0 && ! (ecf_flags & ECF_SP_DEPRESSED))
  	{
! 	  if (flag_defer_pop && inhibit_defer_pop == 0
  	      && ! (ecf_flags & (ECF_CONST | ECF_PURE)))
  	    pending_stack_adjust += rounded_stack_size;
--- 647,656 ----
  	 stack pointer will be changed.  */
  
!       if (rounded_stack_size != 0)
  	{
! 	  if (ecf_flags & ECF_SP_DEPRESSED)
! 	    /* Just pretend we did the pop.  */
! 	    stack_pointer_delta -= rounded_stack_size;
! 	  else if (flag_defer_pop && inhibit_defer_pop == 0
  	      && ! (ecf_flags & (ECF_CONST | ECF_PURE)))
  	    pending_stack_adjust += rounded_stack_size;



More information about the Gcc-patches mailing list