https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96377
--- Comment #5 from rsandifo at gcc dot gnu.org <rsandifo at gcc dot gnu.org>
---
I think this is bound up with the question whether:
typedef int v4si __attribute__((vector_size(16)));
typedef short v8hi __attribute__((vector_size(16)));
struct s {
v8hi x;
v4si y;
};
void
foo (v4si i, v8hi h)
{
struct s x1 = { i, i };
struct s x2 = { h, h };
struct s x3 = { i, h };
struct s x4 = { h, i };
}
should be valid with -flax-vector-conversions. g++ and clang
think it should be, but gcc doesn't accept it.
IMO process_init_element shouldn't recurse into vector types
if the initialisation value is also a vector type. We should
treat the vector value as initialising the whole type and report
an error if they're not compatible.