* hppa-tdep.c (hppa_push_arguments): Correct handling of 5-7 byte
authorAndrew Cagney <cagney@redhat.com>
Sun, 13 Jan 2002 15:48:56 +0000 (15:48 +0000)
committerAndrew Cagney <cagney@redhat.com>
Sun, 13 Jan 2002 15:48:56 +0000 (15:48 +0000)
structures passed in registers.

gdb/ChangeLog
gdb/hppa-tdep.c

index 1d8f0b48f3a7f34cdc21b083c675da28b4187fe0..a99c997e32d3c655480becf9eb38d45038e3faca 100644 (file)
@@ -1,3 +1,9 @@
+2002-01-13  Andrew Cagney  <ac131313@redhat.com>
+
+       From Jeff law:
+       * hppa-tdep.c (hppa_push_arguments): Correct handling of 5-7 byte
+       structures passed in registers.
+
 2002-01-13  Eli Zaretskii  <eliz@is.elta.co.il>
 
        * go32-nat.c (save_npx) [__DJGPP_MINOR__ < 3]: Remove extraneous
index af72d8c4f743e45c1b0f98f9336bba154797c20a..973f778f9fe8f2820d56b06d7941f8ee607a4a4f 100644 (file)
@@ -1815,7 +1815,8 @@ hppa_push_arguments (int nargs, struct value **args, CORE_ADDR sp,
         target.  */
       bytes_reserved = (lengths[i] + REGISTER_SIZE - 1) & -REGISTER_SIZE;
 
-      offset[i] = cum_bytes_reserved + lengths[i];
+      offset[i] = (cum_bytes_reserved
+                  + (lengths[i] > 4 ? bytes_reserved : lengths[i]));
 
       /* If the argument is a double word argument, then it needs to be
         double word aligned.  */