]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
aix.h (AGGREGATE_PADDING_FIXED): Define.
authorDavid Edelsohn <edelsohn@gnu.org>
Fri, 18 Jul 2003 21:42:29 +0000 (21:42 +0000)
committerDavid Edelsohn <dje@gcc.gnu.org>
Fri, 18 Jul 2003 21:42:29 +0000 (17:42 -0400)
* config/rs6000/aix.h (AGGREGATE_PADDING_FIXED): Define.
(AGGREGATES_PAD_UPWARD_ALWAYS): Define.
(MUST_PASS_IN_STACK): Define.
(BLOCK_REG_PADDING): Define.

From-SVN: r69570

gcc/ChangeLog
gcc/config/rs6000/aix.h

index 0b711da0476bc26006b6f59434deb4db829685d4..066668a84f31fa34cc4f158730d9e52a0838ed72 100644 (file)
@@ -1,3 +1,10 @@
+2003-07-18  David Edelsohn  <edelsohn@gnu.org>
+
+       * config/rs6000/aix.h (AGGREGATE_PADDING_FIXED): Define.
+       (AGGREGATES_PAD_UPWARD_ALWAYS): Define.
+       (MUST_PASS_IN_STACK): Define.
+       (BLOCK_REG_PADDING): Define.
+
 2003-07-18  Richard Henderson  <rth@redhat.com>
 
        * cfgrtl.c (force_nonfallthru_and_redirect): Use tablejump_p
index ec6a350f157a24744a8f3fc91a910625fd500f55..991d2c31153da929257a8d7babb8e0d2817403b5 100644 (file)
    ? MAX (MAX ((COMPUTED), (SPECIFIED)), 64)           \
    : MAX ((COMPUTED), (SPECIFIED)))
 
+/* The AIX ABI isn't explicit on whether aggregates smaller than a
+   word/doubleword should be padded upward or downward.  One could
+   reasonably assume that they follow the normal rules for structure
+   layout treating the parameter area as any other block of memory,
+   then map the reg param area to registers, i.e., pad upward, which
+   is the way IBM Compilers for AIX behave.
+   Setting both of the following defines results in this behaviour.  */
+#define AGGREGATE_PADDING_FIXED 1
+#define AGGREGATES_PAD_UPWARD_ALWAYS 1
+
+/* We don't want anything in the reg parm area being passed on the
+   stack.  */
+#define MUST_PASS_IN_STACK(MODE, TYPE)                         \
+   ((TYPE) != 0                                                        \
+    && (TREE_CODE (TYPE_SIZE (TYPE)) != INTEGER_CST            \
+       || TREE_ADDRESSABLE (TYPE)))
+
+/* Specify padding for the last element of a block move between
+   registers and memory.  FIRST is nonzero if this is the only
+   element.  */
+#define BLOCK_REG_PADDING(MODE, TYPE, FIRST) \
+  (!(FIRST) ? upward : FUNCTION_ARG_PADDING (MODE, TYPE))
+
 /* Indicate that jump tables go in the text section.  */
 
 #define JUMP_TABLES_IN_TEXT_SECTION 1