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]

ia64 eh, part 1


Starting as much as I can with independant buglets...

My new implementation of sjlj exceptions always uses a pseudo
for the DECL_RESULT of a function, which uncovered c++ test
failures wrt named return values.


r~


        * function.c (expand_function_start): Set DECL_REGISTER on
        a pseudo used for DECL_RESULT.

Index: function.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/function.c,v
retrieving revision 1.258
diff -c -p -d -r1.258 function.c
*** function.c	2001/03/22 18:48:29	1.258
--- function.c	2001/03/28 03:25:45
*************** expand_function_start (subr, parms_have_
*** 6387,6396 ****
  #endif
  
        SET_DECL_RTL (DECL_RESULT (subr), gen_reg_rtx (mode));
      }
    else
-     /* Scalar, returned in a register.  */
      {
        SET_DECL_RTL (DECL_RESULT (subr),
  		    hard_function_value (TREE_TYPE (DECL_RESULT (subr)), 
  					 subr, 1));
--- 6374,6386 ----
  #endif
  
        SET_DECL_RTL (DECL_RESULT (subr), gen_reg_rtx (mode));
+       /* Needed because we may need to move this to memory
+ 	 in case it's a named return value whose address is taken.  */
+       DECL_REGISTER (DECL_RESULT (subr)) = 1;
      }
    else
      {
+       /* Scalar, returned in a register.  */
        SET_DECL_RTL (DECL_RESULT (subr),
  		    hard_function_value (TREE_TYPE (DECL_RESULT (subr)), 
  					 subr, 1));


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