http://gcc.gnu.org/bugzilla/show_bug.cgi?id=61082
--- Comment #8 from David Greene <greened at obbligato dot org> --- (In reply to H.J. Lu from comment #7) > It is the matter of if the size of > > --- > struct B { }; > struct X : public B { long p; }; > --- > > is size of long or not. I don't understand. The class of concern is Y, not X. Y is (correctly) 16 bytes, as reported by sizeof(). X is 8 bytes due to EBO. According to my reading of the ABI, a 16-byte struct should be returned in (RAX, RDX).