This is the mail archive of the
mailing list for the GCC project.
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: doko at ubuntu dot com (Matthias Klose)
- Cc: 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 13:51:38 +0200 (CEST)
- Subject: 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.
> these are still regressions, because the new warnings trigger on these test cases:
> FAIL: objc.dg-struct-layout-encoding-1/t025_main.m execution test
> FAIL: objc.dg-struct-layout-encoding-1/t027_main.m execution test
> FAIL: objc.dg-struct-layout-encoding-1/t028_main.m execution test
> FAIL: objc.dg-struct-layout-encoding-1/t029_main.m execution test
> FAIL: objc.dg-struct-layout-encoding-1/t030_main.m execution test
> FAIL: objc.dg-struct-layout-encoding-1/t031_main.m execution test
This is strange; I'm not seeing these test FAIL. (I do see the warning in the
log, just as with the C and C++ tests, but the warning is filtered out by the
dejagnu scripts and doesn't cause failures).
However, I've been testing with the above version of the macro, not sure if
that explains the difference.
Dr. Ulrich Weigand
GNU/Linux compilers and toolchain