arm.c (arm_return_in_memory): Treat complex types as aggregates for AAPCS ABIs.
authorJulian Brown <julian@codesourcery.com>
Wed, 5 Jan 2005 18:53:08 +0000 (18:53 +0000)
committerPaul Brook <pbrook@gcc.gnu.org>
Wed, 5 Jan 2005 18:53:08 +0000 (18:53 +0000)
2004-01-05  Julian Brown  <julian@codesourcery.com>

* config/arm/arm.c (arm_return_in_memory): Treat complex types
as aggregates for AAPCS ABIs.

From-SVN: r92963

gcc/ChangeLog
gcc/config/arm/arm.c

index 442e06d543e77c5cfb463eafab60284adc10b0b3..39da29dadc6361d372b999db448b959f27af3415 100644 (file)
@@ -1,3 +1,8 @@
+2004-01-05  Julian Brown  <julian@codesourcery.com>
+
+       * config/arm/arm.c (arm_return_in_memory): Treat complex types
+       as aggregates for AAPCS ABIs.
+
 2005-01-05  Stan Shebs  <shebs@apple.com>
 
        * unwind-dw2-fde-darwin.c (examine_objects): Use 64-bit
index 77eec301f09c58a36fcb3f2db78bfc377231143d..65820219394e56ace5e44f46accbbcab0d97b974 100644 (file)
@@ -2296,8 +2296,10 @@ arm_return_in_memory (tree type)
 {
   HOST_WIDE_INT size;
 
-  if (!AGGREGATE_TYPE_P (type))
-    /* All simple types are returned in registers.  */
+  if (!AGGREGATE_TYPE_P (type) &&
+      !(TARGET_AAPCS_BASED && TREE_CODE (type) == COMPLEX_TYPE))
+    /* All simple types are returned in registers.
+       For AAPCS, complex types are treated the same as aggregates.  */
     return 0;
 
   size = int_size_in_bytes (type);