This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c++/86763] [7/8/9 Regression] Wrong code comparing member of copy of a 237 byte object with nontrivial default constructor on x86-64 arch


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

--- Comment #9 from Richard Biener <rguenth at gcc dot gnu.org> ---
The following seems to work, will test.

Index: gcc/cp/class.c
===================================================================
--- gcc/cp/class.c      (revision 263209)
+++ gcc/cp/class.c      (working copy)
@@ -6243,6 +6243,7 @@ layout_class_type (tree t, tree *virtual
                                  bitsize_int (BITS_PER_UNIT)));
       SET_TYPE_ALIGN (base_t, rli->record_align);
       TYPE_USER_ALIGN (base_t) = TYPE_USER_ALIGN (t);
+      TYPE_TYPELESS_STORAGE (base_t) = TYPE_TYPELESS_STORAGE (t);

       /* Copy the non-static data members of T. This will include its
         direct non-virtual bases & vtable.  */

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]