This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Missing elements in VECTOR_CST
- From: Andrew Pinski <pinskia at physics dot uc dot edu>
- To: gcc at gcc dot gnu dot org
- Cc: aldyh at gcc dot gnu dot org
- Date: Sat, 16 Sep 2006 18:47:01 -0700
- Subject: Missing elements in VECTOR_CST
The documention on VECTOR_CST is not clear if we can have missing
elements in that the remaining elements are zero. Right we produce such
VECTOR_CST for things like:
#define vector __attribute__((vector_size(16) ))
vector int a = {1, 2};
But is that valid? We currently produce a VECTOR_CST with just two
elements instead of 4. Should we always have the same number of
elements in a VECTOR_CST as there are elements in the vector type?
This is why PR 29091 is failing currently. output_constant assumes
VECTOR_CST have the correct number of elements but the C front-end via
digest_init creates a VECTOR_CST with only 2 elements.
Thanks,
Andrew Pinski