aboutsummaryrefslogtreecommitdiff
path: root/gcc/stor-layout.c
diff options
context:
space:
mode:
authorAldy Hernandez <aldyh@redhat.com>2002-06-15 09:41:13 +0000
committerAldy Hernandez <aldyh@gcc.gnu.org>2002-06-15 09:41:13 +0000
commit182e515e724e29aaa44873ea71333fd799ee3925 (patch)
tree61bbb17e58b498d6833007ffcfd18ab3fddef41d /gcc/stor-layout.c
parent2313d59405eb165d70bbdd81bb1914ab1eddd1d8 (diff)
downloadgcc-182e515e724e29aaa44873ea71333fd799ee3925.zip
gcc-182e515e724e29aaa44873ea71333fd799ee3925.tar.gz
gcc-182e515e724e29aaa44873ea71333fd799ee3925.tar.bz2
tm.texi (MEMBER_TYPE_FORCES_BLK): Document MODE argument.
2002-06-15 Aldy Hernandez <aldyh@redhat.com> * tm.texi (MEMBER_TYPE_FORCES_BLK): Document MODE argument. * stor-layout.c (compute_record_mode): Remove check for FUNCTION_ARG_REG_LITTLE_ENDIAN and VOIDmode when checking for MEMBER_TYPE_FORCES_BLK. Pass new mode field to MEMBER_TYPE_FORCES_BLK. * config/ia64/hpux.h (MEMBER_TYPE_FORCES_BLK): Same. * config/c4x/c4x.h (MEMBER_TYPE_FORCES_BLK): Same. From-SVN: r54643
Diffstat (limited to 'gcc/stor-layout.c')
-rw-r--r--gcc/stor-layout.c13
1 files changed, 2 insertions, 11 deletions
diff --git a/gcc/stor-layout.c b/gcc/stor-layout.c
index 8569ca2..753e41d 100644
--- a/gcc/stor-layout.c
+++ b/gcc/stor-layout.c
@@ -1228,16 +1228,7 @@ compute_record_mode (type)
/* With some targets, eg. c4x, it is sub-optimal
to access an aligned BLKmode structure as a scalar. */
- /* On ia64-*-hpux we need to ensure that we don't change the
- mode of a structure containing a single field or else we
- will pass it incorrectly. Since a structure with a single
- field causes mode to get set above we can't allow the
- check for mode == VOIDmode in this case. Perhaps
- MEMBER_TYPE_FORCES_BLK should be extended to include mode
- as an argument and the check could be put in there for c4x. */
-
- if ((mode == VOIDmode || FUNCTION_ARG_REG_LITTLE_ENDIAN)
- && MEMBER_TYPE_FORCES_BLK (field))
+ if (MEMBER_TYPE_FORCES_BLK (field, mode))
return;
#endif /* MEMBER_TYPE_FORCES_BLK */
}
@@ -1577,7 +1568,7 @@ layout_type (type)
TYPE_MODE (type) = BLKmode;
if (TYPE_SIZE (type) != 0
#ifdef MEMBER_TYPE_FORCES_BLK
- && ! MEMBER_TYPE_FORCES_BLK (type)
+ && ! MEMBER_TYPE_FORCES_BLK (type, VOIDmode)
#endif
/* BLKmode elements force BLKmode aggregate;
else extract/store fields may lose. */