This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: PR 19893 & array_ref bug
- From: Mark Mitchell <mark at codesourcery dot com>
- To: Steve Ellcey <sje at cup dot hp dot com>
- Cc: gdr at integrable-solutions dot net, Joe dot Buck at synopsys dot COM, gcc at gcc dot gnu dot org
- Date: Wed, 16 Mar 2005 11:53:57 -0800
- Subject: Re: PR 19893 & array_ref bug
- Organization: CodeSourcery, LLC
- References: <200503161943.LAA23972@hpsje.cup.hp.com>
Steve Ellcey wrote:
What do people think about this idea for changing the vect tests using
gcc.dg/vect/vect-56.c as an example. The arguments (pa, pb, pc) would
remain afloat type (vs. float) but the arrays would be changed from
'array of aligned floats' to an array of floats where the actual array
itself is aligned.
That makes sense to me. (Independently of whether or not we continue to
allow the brokenness currently in GCC, there is no reason to actively
make use of it.)
It seems like we are lying about the alignment of the pa, pb, pc
arguments but I don't see a way around this.
Make them array arguments, instead of pointer arguments. I'm not sure
if GCC is smart enough to still vectorize them in that case, but that's
the right way to express it. An aligned array-of-floats decays to an
aligned pointer-to-float, i.e., the pointer is known to be aligned, but
the object pointed to is just a float not an aligned float.
> If we changed GCC to pad
the array elements (in order to obey the alignment request) wouldn't we
actually break our ability to vectorize things?
Yes.
--
Mark Mitchell
CodeSourcery, LLC
mark@codesourcery.com
(916) 791-8304