From 93dd6255c208d0fe680741183b724124455c7c19 Mon Sep 17 00:00:00 2001 From: Jim Wilson Date: Wed, 11 Apr 2001 20:19:43 +0000 Subject: [PATCH] Fix PR 2520, a problem with structure parameter passing. * config/ia64/ia64.h (FUNCTION_ARG_BOUNDARY): Return 128 if argument requires more than 64 bits of alignment. From-SVN: r41269 --- gcc/ChangeLog | 5 +++++ gcc/config/ia64/ia64.h | 10 +++++++--- 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 12198f23542..9ff706e6532 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2001-04-11 Jim Wilson + + * config/ia64/ia64.h (FUNCTION_ARG_BOUNDARY): Return 128 if argument + requires more than 64 bits of alignment. + 2001-04-11 Neil Booth * cpplib.c (do_line): Sanity check iff enable checking. diff --git a/gcc/config/ia64/ia64.h b/gcc/config/ia64/ia64.h index 8acbef13127..956abd02a32 100644 --- a/gcc/config/ia64/ia64.h +++ b/gcc/config/ia64/ia64.h @@ -1382,11 +1382,15 @@ do { \ /* If defined, a C expression that gives the alignment boundary, in bits, of an argument with the specified mode and type. */ -/* Arguments larger than 64 bits require 128 bit alignment. */ +/* Arguments with alignment larger than 8 bytes start at the next even + boundary. See ia64_function_arg. */ #define FUNCTION_ARG_BOUNDARY(MODE, TYPE) \ - (((((MODE) == BLKmode ? int_size_in_bytes (TYPE) : GET_MODE_SIZE (MODE)) \ - + UNITS_PER_WORD - 1) / UNITS_PER_WORD) > 1 ? 128 : PARM_BOUNDARY) + (((TYPE) ? (TYPE_ALIGN (TYPE) > 8 * BITS_PER_UNIT) \ + : (((((MODE) == BLKmode \ + ? int_size_in_bytes (TYPE) : GET_MODE_SIZE (MODE)) \ + + UNITS_PER_WORD - 1) / UNITS_PER_WORD) > 1)) \ + ? 128 : PARM_BOUNDARY) /* A C expression that is nonzero if REGNO is the number of a hard register in which function arguments are sometimes passed. This does *not* include -- 2.30.2