This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: PATCH [FSF mainline] darwin patch to fix size problem with genericvectors


> && TARGET_ALIGN_NATURAL == 0 \
> ? rs6000_special_round_type_align (STRUCT, COMPUTED, SPECIFIED) \
> ! : (TARGET_ALTIVEC && TREE_CODE (STRUCT) == VECTOR_TYPE \
> ! && ALTIVEC_VECTOR_MODE (TYPE_MODE (STRUCT))) \

No! This is wrong, because it would not enforce the alignment when -maltivec is not used, because in that case the mode would not be a vector mode.

This would introduce another occurrence of the same bug that is fixed by my patch at http://gcc.gnu.org/ml/gcc-patches/2004-07/msg02197.html where the i386 part has gone in and the AltiVec part has not. Quoting from the thread in July:

rth> Paolo> The only way I see to fix this, is to use V4SImode again for
rth> Paolo> such vectors.
rth>
rth> Huh?  You can also look at TREE_CODE (type) == VECTOR_TYPE etc.

So you need "int_size_for_bytes (STRUCT) == 16".

Paolo


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]