* [Bug c++/48035] Mismatch on size of class when initializing hierarchy involving virtual inheritance and empty base classes
2011-03-08 22:14 [Bug c++/48035] New: Mismatch on size of class when initializing hierarchy involving virtual inheritance and empty base classes scot4spam at yahoo dot com
@ 2011-03-08 22:43 ` pinskia at gcc dot gnu.org
2011-03-08 22:46 ` [Bug c++/48035] [4.4/4.5/4.6 Regression] " pinskia at gcc dot gnu.org
` (15 subsequent siblings)
16 siblings, 0 replies; 18+ messages in thread
From: pinskia at gcc dot gnu.org @ 2011-03-08 22:43 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48035
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Keywords| |wrong-code
--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> 2011-03-08 22:43:13 UTC ---
On x86_64 with valgrind:
==31260== Invalid write of size 8
==31260== at 0x4006E0: BadStuffHere() (t.cc:38)
==31260== by 0x400703: main (t.cc:43)
==31260== Address 0x5936058 is 0 bytes after a block of size 24 alloc'd
==31260== at 0x4C24DFA: operator new(unsigned long)
(vg_replace_malloc.c:261)
==31260== by 0x4006C6: BadStuffHere() (t.cc:38)
==31260== by 0x400703: main (t.cc:43)
^ permalink raw reply [flat|nested] 18+ messages in thread
* [Bug c++/48035] [4.4/4.5/4.6 Regression] Mismatch on size of class when initializing hierarchy involving virtual inheritance and empty base classes
2011-03-08 22:14 [Bug c++/48035] New: Mismatch on size of class when initializing hierarchy involving virtual inheritance and empty base classes scot4spam at yahoo dot com
2011-03-08 22:43 ` [Bug c++/48035] " pinskia at gcc dot gnu.org
@ 2011-03-08 22:46 ` pinskia at gcc dot gnu.org
2011-03-09 11:45 ` dodji at gcc dot gnu.org
` (14 subsequent siblings)
16 siblings, 0 replies; 18+ messages in thread
From: pinskia at gcc dot gnu.org @ 2011-03-08 22:46 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48035
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Last reconfirmed| |2011.03.08 22:45:54
Known to work| |4.3.5
Target Milestone|--- |4.4.6
Summary|Mismatch on size of class |[4.4/4.5/4.6 Regression]
|when initializing hierarchy |Mismatch on size of class
|involving virtual |when initializing hierarchy
|inheritance and empty base |involving virtual
|classes |inheritance and empty base
| |classes
Ever Confirmed|0 |1
Known to fail| |4.4.5, 4.6.0
--- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> 2011-03-08 22:45:54 UTC ---
Confirmed, there was no valgrind errors in 4.3.5.
^ permalink raw reply [flat|nested] 18+ messages in thread
* [Bug c++/48035] [4.4/4.5/4.6 Regression] Mismatch on size of class when initializing hierarchy involving virtual inheritance and empty base classes
2011-03-08 22:14 [Bug c++/48035] New: Mismatch on size of class when initializing hierarchy involving virtual inheritance and empty base classes scot4spam at yahoo dot com
2011-03-08 22:43 ` [Bug c++/48035] " pinskia at gcc dot gnu.org
2011-03-08 22:46 ` [Bug c++/48035] [4.4/4.5/4.6 Regression] " pinskia at gcc dot gnu.org
@ 2011-03-09 11:45 ` dodji at gcc dot gnu.org
2011-03-09 12:46 ` jakub at gcc dot gnu.org
` (13 subsequent siblings)
16 siblings, 0 replies; 18+ messages in thread
From: dodji at gcc dot gnu.org @ 2011-03-09 11:45 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48035
Dodji Seketeli <dodji at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |ASSIGNED
CC| |dodji at gcc dot gnu.org
^ permalink raw reply [flat|nested] 18+ messages in thread
* [Bug c++/48035] [4.4/4.5/4.6 Regression] Mismatch on size of class when initializing hierarchy involving virtual inheritance and empty base classes
2011-03-08 22:14 [Bug c++/48035] New: Mismatch on size of class when initializing hierarchy involving virtual inheritance and empty base classes scot4spam at yahoo dot com
` (2 preceding siblings ...)
2011-03-09 11:45 ` dodji at gcc dot gnu.org
@ 2011-03-09 12:46 ` jakub at gcc dot gnu.org
2011-03-09 14:04 ` jakub at gcc dot gnu.org
` (12 subsequent siblings)
16 siblings, 0 replies; 18+ messages in thread
From: jakub at gcc dot gnu.org @ 2011-03-09 12:46 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48035
--- Comment #3 from Jakub Jelinek <jakub at gcc dot gnu.org> 2011-03-09 12:46:12 UTC ---
I think this started with
http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=138355
^ permalink raw reply [flat|nested] 18+ messages in thread
* [Bug c++/48035] [4.4/4.5/4.6 Regression] Mismatch on size of class when initializing hierarchy involving virtual inheritance and empty base classes
2011-03-08 22:14 [Bug c++/48035] New: Mismatch on size of class when initializing hierarchy involving virtual inheritance and empty base classes scot4spam at yahoo dot com
` (3 preceding siblings ...)
2011-03-09 12:46 ` jakub at gcc dot gnu.org
@ 2011-03-09 14:04 ` jakub at gcc dot gnu.org
2011-03-11 14:47 ` jakub at gcc dot gnu.org
` (11 subsequent siblings)
16 siblings, 0 replies; 18+ messages in thread
From: jakub at gcc dot gnu.org @ 2011-03-09 14:04 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48035
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |jakub at gcc dot gnu.org
--- Comment #4 from Jakub Jelinek <jakub at gcc dot gnu.org> 2011-03-09 14:03:35 UTC ---
I think the problem is that build_zero_init isn't aware of the
DECL_FIELD_IS_BASE FIELD_DECLs and CLASSTYPE_AS_BASE stuff. So when
simplify_aggr_init_expr decides to call build_zero_init on the
SpecificImplementation type, while the first FIELD_DECL has size 8 and its type
also size 8, the second FIELD_DECL has size 12 (CLASSTYPE_SIZE_UNIT), its type
has size 24 and thus what build_zero_init returns on the subtype isn't directly
usable as ctor of the outer type.
^ permalink raw reply [flat|nested] 18+ messages in thread
* [Bug c++/48035] [4.4/4.5/4.6 Regression] Mismatch on size of class when initializing hierarchy involving virtual inheritance and empty base classes
2011-03-08 22:14 [Bug c++/48035] New: Mismatch on size of class when initializing hierarchy involving virtual inheritance and empty base classes scot4spam at yahoo dot com
` (4 preceding siblings ...)
2011-03-09 14:04 ` jakub at gcc dot gnu.org
@ 2011-03-11 14:47 ` jakub at gcc dot gnu.org
2011-03-11 15:44 ` jakub at gcc dot gnu.org
` (10 subsequent siblings)
16 siblings, 0 replies; 18+ messages in thread
From: jakub at gcc dot gnu.org @ 2011-03-11 14:47 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48035
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Priority|P3 |P1
^ permalink raw reply [flat|nested] 18+ messages in thread
* [Bug c++/48035] [4.4/4.5/4.6 Regression] Mismatch on size of class when initializing hierarchy involving virtual inheritance and empty base classes
2011-03-08 22:14 [Bug c++/48035] New: Mismatch on size of class when initializing hierarchy involving virtual inheritance and empty base classes scot4spam at yahoo dot com
` (5 preceding siblings ...)
2011-03-11 14:47 ` jakub at gcc dot gnu.org
@ 2011-03-11 15:44 ` jakub at gcc dot gnu.org
2011-03-11 15:47 ` [Bug c++/48035] [4.4/4.5 " jakub at gcc dot gnu.org
` (9 subsequent siblings)
16 siblings, 0 replies; 18+ messages in thread
From: jakub at gcc dot gnu.org @ 2011-03-11 15:44 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48035
--- Comment #5 from Jakub Jelinek <jakub at gcc dot gnu.org> 2011-03-11 15:43:42 UTC ---
Author: jakub
Date: Fri Mar 11 15:43:37 2011
New Revision: 170874
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=170874
Log:
PR c++/48035
* init.c (build_zero_init_1): Extracted from build_zero_init.
Add FIELD_SIZE argument, if non-NULL and field bit_position
as not smaller than that, don't add that field's initializer.
Pass DECL_SIZE as last argument to build_zero_init_1
for DECL_FIELD_IS_BASE fields.
(build_zero_init): Use build_zero_init_1.
* g++.dg/inherit/virtual8.C: New test.
Added:
trunk/gcc/testsuite/g++.dg/inherit/virtual8.C
Modified:
trunk/gcc/cp/ChangeLog
trunk/gcc/cp/init.c
trunk/gcc/testsuite/ChangeLog
^ permalink raw reply [flat|nested] 18+ messages in thread
* [Bug c++/48035] [4.4/4.5 Regression] Mismatch on size of class when initializing hierarchy involving virtual inheritance and empty base classes
2011-03-08 22:14 [Bug c++/48035] New: Mismatch on size of class when initializing hierarchy involving virtual inheritance and empty base classes scot4spam at yahoo dot com
` (6 preceding siblings ...)
2011-03-11 15:44 ` jakub at gcc dot gnu.org
@ 2011-03-11 15:47 ` jakub at gcc dot gnu.org
2011-04-10 10:49 ` rguenth at gcc dot gnu.org
` (8 subsequent siblings)
16 siblings, 0 replies; 18+ messages in thread
From: jakub at gcc dot gnu.org @ 2011-03-11 15:47 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48035
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Known to work| |4.6.0
Summary|[4.4/4.5/4.6 Regression] |[4.4/4.5 Regression]
|Mismatch on size of class |Mismatch on size of class
|when initializing hierarchy |when initializing hierarchy
|involving virtual |involving virtual
|inheritance and empty base |inheritance and empty base
|classes |classes
Known to fail|4.6.0 |
--- Comment #6 from Jakub Jelinek <jakub at gcc dot gnu.org> 2011-03-11 15:45:04 UTC ---
Fixed on the trunk so far.
^ permalink raw reply [flat|nested] 18+ messages in thread
* [Bug c++/48035] [4.4/4.5 Regression] Mismatch on size of class when initializing hierarchy involving virtual inheritance and empty base classes
2011-03-08 22:14 [Bug c++/48035] New: Mismatch on size of class when initializing hierarchy involving virtual inheritance and empty base classes scot4spam at yahoo dot com
` (7 preceding siblings ...)
2011-03-11 15:47 ` [Bug c++/48035] [4.4/4.5 " jakub at gcc dot gnu.org
@ 2011-04-10 10:49 ` rguenth at gcc dot gnu.org
2011-04-11 21:23 ` tschwinge at gcc dot gnu.org
` (7 subsequent siblings)
16 siblings, 0 replies; 18+ messages in thread
From: rguenth at gcc dot gnu.org @ 2011-04-10 10:49 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48035
Richard Guenther <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Priority|P1 |P2
AssignedTo|unassigned at gcc dot |jakub at gcc dot gnu.org
|gnu.org |
^ permalink raw reply [flat|nested] 18+ messages in thread
* [Bug c++/48035] [4.4/4.5 Regression] Mismatch on size of class when initializing hierarchy involving virtual inheritance and empty base classes
2011-03-08 22:14 [Bug c++/48035] New: Mismatch on size of class when initializing hierarchy involving virtual inheritance and empty base classes scot4spam at yahoo dot com
` (8 preceding siblings ...)
2011-04-10 10:49 ` rguenth at gcc dot gnu.org
@ 2011-04-11 21:23 ` tschwinge at gcc dot gnu.org
2011-04-16 9:58 ` jakub at gcc dot gnu.org
` (6 subsequent siblings)
16 siblings, 0 replies; 18+ messages in thread
From: tschwinge at gcc dot gnu.org @ 2011-04-11 21:23 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48035
Thomas Schwinge <tschwinge at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |tschwinge at gcc dot
| |gnu.org
--- Comment #7 from Thomas Schwinge <tschwinge at gcc dot gnu.org> 2011-04-11 21:23:27 UTC ---
FWIW, I'm confirming both the bug and the fix in a 4.5-based tree.
^ permalink raw reply [flat|nested] 18+ messages in thread
* [Bug c++/48035] [4.4/4.5 Regression] Mismatch on size of class when initializing hierarchy involving virtual inheritance and empty base classes
2011-03-08 22:14 [Bug c++/48035] New: Mismatch on size of class when initializing hierarchy involving virtual inheritance and empty base classes scot4spam at yahoo dot com
` (9 preceding siblings ...)
2011-04-11 21:23 ` tschwinge at gcc dot gnu.org
@ 2011-04-16 9:58 ` jakub at gcc dot gnu.org
2011-04-18 14:04 ` rguenth at gcc dot gnu.org
` (5 subsequent siblings)
16 siblings, 0 replies; 18+ messages in thread
From: jakub at gcc dot gnu.org @ 2011-04-16 9:58 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48035
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|4.4.6 |4.4.7
^ permalink raw reply [flat|nested] 18+ messages in thread
* [Bug c++/48035] [4.4/4.5 Regression] Mismatch on size of class when initializing hierarchy involving virtual inheritance and empty base classes
2011-03-08 22:14 [Bug c++/48035] New: Mismatch on size of class when initializing hierarchy involving virtual inheritance and empty base classes scot4spam at yahoo dot com
` (10 preceding siblings ...)
2011-04-16 9:58 ` jakub at gcc dot gnu.org
@ 2011-04-18 14:04 ` rguenth at gcc dot gnu.org
2011-04-18 14:44 ` [Bug c++/48035] [4.4 " rguenth at gcc dot gnu.org
` (4 subsequent siblings)
16 siblings, 0 replies; 18+ messages in thread
From: rguenth at gcc dot gnu.org @ 2011-04-18 14:04 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48035
--- Comment #8 from Richard Guenther <rguenth at gcc dot gnu.org> 2011-04-18 14:02:27 UTC ---
Author: rguenth
Date: Mon Apr 18 14:02:22 2011
New Revision: 172647
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=172647
Log:
2011-04-18 Richard Guenther <rguenther@suse.de>
Backported from 4.6 branch
2011-03-11 Jakub Jelinek <jakub@redhat.com>
PR c++/48035
* init.c (build_zero_init_1): Extracted from build_zero_init.
Add FIELD_SIZE argument, if non-NULL and field bit_position
as not smaller than that, don't add that field's initializer.
Pass DECL_SIZE as last argument to build_zero_init_1
for DECL_FIELD_IS_BASE fields.
(build_zero_init): Use build_zero_init_1.
* g++.dg/inherit/virtual8.C: New test.
2011-03-05 Zdenek Dvorak <ook@ucw.cz>
PR rtl-optimization/47899
* cfgloopmanip.c (fix_bb_placements): Fix first argument
to flow_loop_nested_p when moving the loop upward.
* gcc.dg/pr47899.c: New test.
2011-03-15 Richard Guenther <rguenther@suse.de>
PR middle-end/48031
* fold-const.c (fold_indirect_ref_1): Do not create new variable-sized
or variable-indexed array accesses when in gimple form.
Modified:
branches/gcc-4_5-branch/gcc/ChangeLog
branches/gcc-4_5-branch/gcc/cfgloopmanip.c
branches/gcc-4_5-branch/gcc/cp/ChangeLog
branches/gcc-4_5-branch/gcc/cp/init.c
branches/gcc-4_5-branch/gcc/fold-const.c
branches/gcc-4_5-branch/gcc/testsuite/ChangeLog
^ permalink raw reply [flat|nested] 18+ messages in thread
* [Bug c++/48035] [4.4 Regression] Mismatch on size of class when initializing hierarchy involving virtual inheritance and empty base classes
2011-03-08 22:14 [Bug c++/48035] New: Mismatch on size of class when initializing hierarchy involving virtual inheritance and empty base classes scot4spam at yahoo dot com
` (11 preceding siblings ...)
2011-04-18 14:04 ` rguenth at gcc dot gnu.org
@ 2011-04-18 14:44 ` rguenth at gcc dot gnu.org
2011-09-23 22:02 ` paolo.carlini at oracle dot com
` (3 subsequent siblings)
16 siblings, 0 replies; 18+ messages in thread
From: rguenth at gcc dot gnu.org @ 2011-04-18 14:44 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48035
--- Comment #9 from Richard Guenther <rguenth at gcc dot gnu.org> 2011-04-18 14:37:17 UTC ---
Author: rguenth
Date: Mon Apr 18 14:37:08 2011
New Revision: 172652
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=172652
Log:
2011-04-18 Richard Guenther <rguenther@suse.de>
Backported from 4.6 branch
2011-03-11 Jakub Jelinek <jakub@redhat.com>
PR c++/48035
* init.c (build_zero_init_1): Extracted from build_zero_init.
Add FIELD_SIZE argument, if non-NULL and field bit_position
as not smaller than that, don't add that field's initializer.
Pass DECL_SIZE as last argument to build_zero_init_1
for DECL_FIELD_IS_BASE fields.
(build_zero_init): Use build_zero_init_1.
* g++.dg/inherit/virtual8.C: New test.
2011-03-05 Zdenek Dvorak <ook@ucw.cz>
PR rtl-optimization/47899
* cfgloopmanip.c (fix_bb_placements): Fix first argument
to flow_loop_nested_p when moving the loop upward.
* gcc.dg/pr47899.c: New test.
2011-03-15 Richard Guenther <rguenther@suse.de>
PR middle-end/48031
* fold-const.c (fold_indirect_ref_1): Do not create new variable-sized
or variable-indexed array accesses when in gimple form.
Added:
branches/gcc-4_5-branch/gcc/testsuite/g++.dg/inherit/virtual8.C
branches/gcc-4_5-branch/gcc/testsuite/gcc.dg/pr47899.c
^ permalink raw reply [flat|nested] 18+ messages in thread
* [Bug c++/48035] [4.4 Regression] Mismatch on size of class when initializing hierarchy involving virtual inheritance and empty base classes
2011-03-08 22:14 [Bug c++/48035] New: Mismatch on size of class when initializing hierarchy involving virtual inheritance and empty base classes scot4spam at yahoo dot com
` (12 preceding siblings ...)
2011-04-18 14:44 ` [Bug c++/48035] [4.4 " rguenth at gcc dot gnu.org
@ 2011-09-23 22:02 ` paolo.carlini at oracle dot com
2011-10-05 8:11 ` sezeroz at gmail dot com
` (2 subsequent siblings)
16 siblings, 0 replies; 18+ messages in thread
From: paolo.carlini at oracle dot com @ 2011-09-23 22:02 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48035
--- Comment #10 from Paolo Carlini <paolo.carlini at oracle dot com> 2011-09-23 21:57:15 UTC ---
Jakub, shall we close this?
^ permalink raw reply [flat|nested] 18+ messages in thread
* [Bug c++/48035] [4.4 Regression] Mismatch on size of class when initializing hierarchy involving virtual inheritance and empty base classes
2011-03-08 22:14 [Bug c++/48035] New: Mismatch on size of class when initializing hierarchy involving virtual inheritance and empty base classes scot4spam at yahoo dot com
` (13 preceding siblings ...)
2011-09-23 22:02 ` paolo.carlini at oracle dot com
@ 2011-10-05 8:11 ` sezeroz at gmail dot com
2011-10-13 18:06 ` jason at gcc dot gnu.org
2011-10-13 18:07 ` jason at gcc dot gnu.org
16 siblings, 0 replies; 18+ messages in thread
From: sezeroz at gmail dot com @ 2011-10-05 8:11 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48035
Ozkan Sezer <sezeroz at gmail dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |sezeroz at gmail dot com
--- Comment #11 from Ozkan Sezer <sezeroz at gmail dot com> 2011-10-05 08:10:50 UTC ---
Will the fixes for this PR go into 4.4?
^ permalink raw reply [flat|nested] 18+ messages in thread
* [Bug c++/48035] [4.4 Regression] Mismatch on size of class when initializing hierarchy involving virtual inheritance and empty base classes
2011-03-08 22:14 [Bug c++/48035] New: Mismatch on size of class when initializing hierarchy involving virtual inheritance and empty base classes scot4spam at yahoo dot com
` (14 preceding siblings ...)
2011-10-05 8:11 ` sezeroz at gmail dot com
@ 2011-10-13 18:06 ` jason at gcc dot gnu.org
2011-10-13 18:07 ` jason at gcc dot gnu.org
16 siblings, 0 replies; 18+ messages in thread
From: jason at gcc dot gnu.org @ 2011-10-13 18:06 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48035
Jason Merrill <jason at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
Resolution| |FIXED
--- Comment #13 from Jason Merrill <jason at gcc dot gnu.org> 2011-10-13 18:05:36 UTC ---
Fixed for 4.4.7.
^ permalink raw reply [flat|nested] 18+ messages in thread
* [Bug c++/48035] [4.4 Regression] Mismatch on size of class when initializing hierarchy involving virtual inheritance and empty base classes
2011-03-08 22:14 [Bug c++/48035] New: Mismatch on size of class when initializing hierarchy involving virtual inheritance and empty base classes scot4spam at yahoo dot com
` (15 preceding siblings ...)
2011-10-13 18:06 ` jason at gcc dot gnu.org
@ 2011-10-13 18:07 ` jason at gcc dot gnu.org
16 siblings, 0 replies; 18+ messages in thread
From: jason at gcc dot gnu.org @ 2011-10-13 18:07 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48035
--- Comment #12 from Jason Merrill <jason at gcc dot gnu.org> 2011-10-13 18:03:01 UTC ---
Author: jason
Date: Thu Oct 13 18:02:53 2011
New Revision: 179937
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=179937
Log:
PR c++/48035
* init.c (build_zero_init_1): Extracted from build_zero_init.
Add FIELD_SIZE argument, if non-NULL and field bit_position
as not smaller than that, don't add that field's initializer.
Pass DECL_SIZE as last argument to build_zero_init_1
for DECL_FIELD_IS_BASE fields.
(build_zero_init): Use build_zero_init_1.
Added:
branches/gcc-4_4-branch/gcc/testsuite/g++.dg/inherit/virtual8.C
Modified:
branches/gcc-4_4-branch/gcc/cp/ChangeLog
branches/gcc-4_4-branch/gcc/cp/init.c
branches/gcc-4_4-branch/gcc/testsuite/ChangeLog
^ permalink raw reply [flat|nested] 18+ messages in thread