https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77728

--- Comment #14 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
For the base class alignment vs. alignment of base class members, I think
testcases could be e.g. like:
struct B { char a __attribute__((aligned (8))); };
struct A : public B {};

A
foo (int x, A y)
{
  return y;
}

or
struct __attribute__((aligned (8))) B { char a; };
struct A : public B {};

A
foo (int x, A y)
{
  return y;
}
and similar, though it seems g++ and clang++ agree on the passing at least in
these two testcases.  Of course, one should also try multiple inheritance, etc.
Virtual inheritance probably doesn't matter, I think those types must be passed
always by invisible reference.

Reply via email to