Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/netbsd-1-6]: src/gnu/dist/toolchain/gcc/config/arm Pull up revision 1.9 ...



details:   https://anonhg.NetBSD.org/src/rev/f2a756d279db
branches:  netbsd-1-6
changeset: 529052:f2a756d279db
user:      lukem <lukem%NetBSD.org@localhost>
date:      Wed Aug 28 22:04:34 2002 +0000

description:
Pull up revision 1.9 (requested by thorpej in ticket #743):
* Rename ARM_FLAG_ATPCS_STACK_ALIGN to ARM_FLAG_ATPCS.
* Rename TARGET_ATPCS_STACK_ALIGN to TARGET_ATPCS.
* Move APTCS aggregate return rules to arm_return_in_memory(), conditional
  on TARGET_ATPCS, and make it also return true for variable-sized aggregates.

diffstat:

 gnu/dist/toolchain/gcc/config/arm/arm.c |  16 ++++++++++++++--
 1 files changed, 14 insertions(+), 2 deletions(-)

diffs (38 lines):

diff -r 65adcbd5d087 -r f2a756d279db gnu/dist/toolchain/gcc/config/arm/arm.c
--- a/gnu/dist/toolchain/gcc/config/arm/arm.c   Wed Aug 28 09:42:57 2002 +0000
+++ b/gnu/dist/toolchain/gcc/config/arm/arm.c   Wed Aug 28 22:04:34 2002 +0000
@@ -1343,12 +1343,24 @@
 arm_return_in_memory (type)
      tree type;
 {
+  HOST_WIDE_INT size;
+
   if (! AGGREGATE_TYPE_P (type))
     {
       /* All simple types are returned in registers. */
       return 0;
     }
-  else if (int_size_in_bytes (type) > 4)
+
+  size = int_size_in_bytes (type);
+
+  if (TARGET_ATPCS)
+    {
+      /* ATPCS returns aggregate types in memory only if they are
+        larger than a word (or are variable size).  */
+      return (size < 0 || size > 4);
+    }
+
+  if (size < 0 || size > 4)
     {
       /* All structures/unions bigger than one word are returned in memory. */
       return 1;
@@ -5855,7 +5867,7 @@
   int volatile_func = (optimize > 0
                       && TREE_THIS_VOLATILE (current_function_decl));
 
-  if (! TARGET_ATPCS_STACK_ALIGN)
+  if (! TARGET_ATPCS)
     return base_size;
 
   /* We know that SP will be word aligned on entry, and we must



Home | Main Index | Thread Index | Old Index