This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[commit, 4.8/4.9, libobjc] Match branch ABI (Re: [PATCH, rs6000, 4.8/4.9] Fix alignment of non-Altivec vector struct fields)
- From: Ulrich Weigand <uweigand at de dot ibm dot com>
- To: Ulrich Weigand <uweigand at de dot ibm dot com>
- Cc: doko at ubuntu dot com (Matthias Klose), pinskia at gmail dot com, amodra at gmail dot com (Alan Modra), gcc-patches at gcc dot gnu dot org (gcc-patches at gcc dot gnu dot org), dje dot gcc at gmail dot com (dje dot gcc at gmail dot com)
- Date: Mon, 28 Jul 2014 16:50:16 +0200 (CEST)
- Subject: [commit, 4.8/4.9, libobjc] Match branch ABI (Re: [PATCH, rs6000, 4.8/4.9] Fix alignment of non-Altivec vector struct fields)
- Authentication-results: sourceware.org; auth=none
> Matthias Klose wrote:
>
> > #define rs6000_special_adjust_field_align_p(FIELD, COMPUTED) 0
> >
> > is what succeeds for me. false is not defined for ObjC. Checked in on the trunk
> > and the branches.
>
> Since we didn't backport the actual ABI change to the branches, only the warning,
> I think it would be consistent to use something like this on the branches:
>
> #define rs6000_special_adjust_field_align_p(FIELD, COMPUTED) \
> (TARGET_ALTIVEC && TREE_CODE (TREE_TYPE (FIELD)) == VECTOR_TYPE)
>
> rather than the #define ... 0 that is appropriate for mainline.
I've now checked this in to the 4.8 and 4.9 branches.
Tested on powerpc64le-linux.
Bye,
Ulrich
libobjc/
PR libobjc/61920
* encoding.c (rs6000_special_adjust_field_align_p): Use definition
that matches the 4.8/4.9 branch ABI.
Index: libobjc/encoding.c
===================================================================
--- libobjc/encoding.c (revision 213124)
+++ libobjc/encoding.c (working copy)
@@ -192,7 +192,8 @@
? MAX (MAX (COMPUTED, SPECIFIED), 64) \
: MAX (COMPUTED, SPECIFIED));})
-#define rs6000_special_adjust_field_align_p(FIELD, COMPUTED) 0
+#define rs6000_special_adjust_field_align_p(FIELD, COMPUTED) \
+ (TARGET_ALTIVEC && TREE_CODE (TREE_TYPE (FIELD)) == VECTOR_TYPE)
/* Skip a variable name, enclosed in quotes ("). */
static inline
--
Dr. Ulrich Weigand
GNU/Linux compilers and toolchain
Ulrich.Weigand@de.ibm.com