]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
Fix argument passing on ppc
authorBernd Schmidt <bernds@redhat.com>
Fri, 6 Apr 2001 13:41:39 +0000 (13:41 +0000)
committerBernd Schmidt <bernds@gcc.gnu.org>
Fri, 6 Apr 2001 13:41:39 +0000 (13:41 +0000)
From-SVN: r41152

gcc/ChangeLog
gcc/function.c

index 94272ff9502a07367c08b9f78adc54df6a915fe6..b2dbfbe63eb89a27dcad263112fd08286148be1b 100644 (file)
@@ -1,5 +1,8 @@
 2001-04-06  Bernd Schmidt  <bernds@redhat.com>
 
+       2000-10-17  Franz Sirl  <Franz.Sirl-kernel@lauterbach.com>
+       * function.c (locate_and_pad_parm): Don't align stack unconditionally.
+
        Thu Oct 28 10:20:02 1999  Geoffrey Keating  <geoffk@cygnus.com>
        * config/rs6000/rs6000.md (movsf): Don't convert a SUBREG
        of the function return register into a plain REG until
index 5a7a2e2ed32e676bb7f0c403b99f2503a3ba40e7..f715eaad9f885ff14a0434922a9fbb7a2cd51650 100644 (file)
@@ -5334,7 +5334,18 @@ locate_and_pad_parm (passed_mode, type, in_regs, fndecl,
                                - offset_ptr->constant); 
     }
 #else /* !ARGS_GROW_DOWNWARD */
-  pad_to_arg_alignment (initial_offset_ptr, boundary);
+  if (!in_regs 
+#ifdef REG_PARM_STACK_SPACE
+      || REG_PARM_STACK_SPACE (fndecl) > 0
+#else
+      /* For the gcc-2_95-branch we want to make sure not to break something
+         on platforms which pass argument in registers but don't define
+         REG_PARM_STACK_SPACE. So we force the original behaviour here.  */
+      || 1
+#endif
+      )
+    pad_to_arg_alignment (initial_offset_ptr, boundary);
+
   *offset_ptr = *initial_offset_ptr;
 
 #ifdef PUSH_ROUNDING