except.c (eh_regs): Save results of build_pointer_type to a temp as FUNCTION_VALUE...
authorAlan Modra <alan@linuxcare.com.au>
Tue, 27 Mar 2001 03:00:07 +0000 (03:00 +0000)
committerAlan Modra <amodra@gcc.gnu.org>
Tue, 27 Mar 2001 03:00:07 +0000 (12:30 +0930)
* except.c (eh_regs): Save results of build_pointer_type to a temp
as FUNCTION_VALUE macro may evaluate its args multiple times.

From-SVN: r40861

gcc/ChangeLog
gcc/except.c

index 645be42..4dbf3a1 100644 (file)
@@ -1,3 +1,8 @@
+2001-03-27  Alan Modra  <alan@linuxcare.com.au>
+
+       * except.c (eh_regs): Save results of build_pointer_type to a temp
+       as FUNCTION_VALUE macro may evaluate its args multiple times.
+
 2001-03-26  Mark Mitchell  <mark@codesourcery.com>
 
        * c-common.h (DECL_NUM_STMTS): New macro.
index 5c85468..eb80b9b 100644 (file)
@@ -2998,15 +2998,15 @@ eh_regs (pcontext, psp, pra, outgoing)
 {
   rtx rcontext, rsp, rra;
   unsigned int i;
+  tree t;
 
+  t = build_pointer_type (void_type_node);
 #ifdef FUNCTION_OUTGOING_VALUE
   if (outgoing)
-    rcontext = FUNCTION_OUTGOING_VALUE (build_pointer_type (void_type_node),
-                                       current_function_decl);
+    rcontext = FUNCTION_OUTGOING_VALUE (t, current_function_decl);
   else
 #endif
-    rcontext = FUNCTION_VALUE (build_pointer_type (void_type_node),
-                              current_function_decl);
+    rcontext = FUNCTION_VALUE (t, current_function_decl);
 
 #ifdef STATIC_CHAIN_REGNUM
   if (outgoing)