[Bug debug/53235] [4.8 Regression] 20120504 broke -fdebug-types-section
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53235 --- Comment #14 from mrs at gcc dot gnu.org mrs at gcc dot gnu.org 2013-01-20 20:35:56 UTC --- Author: mrs Date: Sun Jan 20 20:35:48 2013 New Revision: 195326 URL: http://gcc.gnu.org/viewcvs?root=gccview=revrev=195326 Log: 2013-01-20 Jack Howarth howa...@bromo.med.uc.edu PR debug/53235 * g++.dg/debug/dwarf2/nested-4.C: XFAIL on darwin. Modified: trunk/gcc/testsuite/ChangeLog trunk/gcc/testsuite/g++.dg/debug/dwarf2/nested-4.C
[Bug debug/53235] [4.8 Regression] 20120504 broke -fdebug-types-section
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53235 --- Comment #13 from Cary Coutant ccoutant at gcc dot gnu.org 2012-09-06 03:34:27 UTC --- Author: ccoutant Date: Thu Sep 6 03:34:22 2012 New Revision: 191005 URL: http://gcc.gnu.org/viewcvs?root=gccview=revrev=191005 Log: 2012-09-05 Cary Coutant ccout...@gmail.com Backport trunk patch to fix a problem where type signature does not include the type's context. 2012-07-19 Jason Merrill ja...@redhat.com gcc/ PR debug/53235 * dwarf2out.c (get_die_parent): New. (generate_type_signature): Use it. gcc/testsuite/ * g++.dg/debug/dwarf2/nested-4.C: New. Added: branches/google/gcc-4_7/gcc/testsuite/g++.dg/debug/dwarf2/nested-4.C Modified: branches/google/gcc-4_7/gcc/ChangeLog.google-4_7 branches/google/gcc-4_7/gcc/dwarf2out.c branches/google/gcc-4_7/gcc/testsuite/ChangeLog.google-4_7
[Bug debug/53235] [4.8 Regression] 20120504 broke -fdebug-types-section
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53235 --- Comment #11 from Jason Merrill jason at gcc dot gnu.org 2012-07-19 20:02:02 UTC --- Author: jason Date: Thu Jul 19 20:01:56 2012 New Revision: 189676 URL: http://gcc.gnu.org/viewcvs?root=gccview=revrev=189676 Log: PR debug/53235 * dwarf2out.c (generate_type_signature): Handle the case of DIE being nested, rather than its declaration.. Added: trunk/gcc/testsuite/g++.dg/debug/dwarf2/nested-4.C Modified: trunk/gcc/ChangeLog trunk/gcc/dwarf2out.c
[Bug debug/53235] [4.8 Regression] 20120504 broke -fdebug-types-section
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53235 Jason Merrill jason at gcc dot gnu.org changed: What|Removed |Added Status|ASSIGNED|RESOLVED Resolution||FIXED --- Comment #12 from Jason Merrill jason at gcc dot gnu.org 2012-07-19 20:09:35 UTC --- Thanks for the testcase. Fixed.
[Bug debug/53235] [4.8 Regression] 20120504 broke -fdebug-types-section
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53235 Jason Merrill jason at gcc dot gnu.org changed: What|Removed |Added Status|UNCONFIRMED |ASSIGNED Last reconfirmed||2012-07-19 AssignedTo|unassigned at gcc dot |jason at gcc dot gnu.org |gnu.org | Ever Confirmed|0 |1
[Bug debug/53235] [4.8 Regression] 20120504 broke -fdebug-types-section
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53235 --- Comment #10 from Jan Kratochvil jan.kratochvil at redhat dot com 2012-07-17 19:09:59 UTC --- namespace E { class O {}; void f (O o) {} } namespace F { class O {}; void f (O fo) {} } E::O eo; int main () {} -gdwarf-4 -fdebug-types-section gdb ./a.out -ex 'ptype eo' FAIL: gcc (GCC) 4.7.2 20120717 (prerelease) FAIL: gcc (GCC) 4.8.0 20120717 (experimental) type = class F::O { no data fields } -gdwarf-4 -fno-debug-types-section gdb ./a.out -ex 'ptype eo' PASS: gcc (GCC) 4.7.2 20120717 (prerelease) PASS: gcc (GCC) 4.8.0 20120717 (experimental) type = class E::O { no data fields } FAIL: 1d4: Abbrev Number: 13 (DW_TAG_variable) d5 DW_AT_name: eo da DW_AT_type: 0xe8 1e8: Abbrev Number: 14 (DW_TAG_class_type) e9 DW_AT_signature : signature: 0x2ab8ef7c6fcf3265 Contents of the .debug_types section: Signature: 0x2ab8ef7c6fcf3265 125: Abbrev Number: 2 (DW_TAG_namespace) 26 DW_AT_name: F
[Bug debug/53235] [4.8 Regression] 20120504 broke -fdebug-types-section
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53235 --- Comment #9 from Jason Merrill jason at gcc dot gnu.org 2012-07-07 14:13:38 UTC --- (In reply to comment #8) -fdebug-types-section regresses static scope of types http://sourceware.org/bugzilla/show_bug.cgi?id=14148 suggests the stub DW_TAG_struct_type should not have DW_AT_declaration as we need definition of the type at its proper scope. We have had declarations at the type's proper scope and definitions at CU scope for a very long time, and moving the definition to a type unit should work similarly. But I'm currently not putting a name on the stub to save space; would giving it a DW_AT_name make a difference?
[Bug debug/53235] [4.8 Regression] 20120504 broke -fdebug-types-section
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53235 Jan Kratochvil jan.kratochvil at redhat dot com changed: What|Removed |Added CC||dje at google dot com --- Comment #8 from Jan Kratochvil jan.kratochvil at redhat dot com 2012-05-24 03:36:08 UTC --- -fdebug-types-section regresses static scope of types http://sourceware.org/bugzilla/show_bug.cgi?id=14148 suggests the stub DW_TAG_struct_type should not have DW_AT_declaration as we need definition of the type at its proper scope.
[Bug debug/53235] [4.8 Regression] 20120504 broke -fdebug-types-section
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53235 Jan Kratochvil jan.kratochvil at redhat dot com changed: What|Removed |Added Status|RESOLVED|UNCONFIRMED Resolution|FIXED | --- Comment #7 from Jan Kratochvil jan.kratochvil at redhat dot com 2012-05-19 07:59:05 UTC --- Still getting for -fdebug-types-section regression against 2012-04-25 state: Running ./gdb.cp/koenig.exp ... FAIL: gdb.cp/koenig.exp: p foo(eo) FAIL: gdb.cp/koenig.exp: p foo(eo, eo) FAIL: gdb.cp/koenig.exp: p foo(eo, eo, 1) FAIL: gdb.cp/koenig.exp: p foo(fo, eo) FAIL: gdb.cp/koenig.exp: p foo(1 ,fo, eo) FAIL: gdb.cp/koenig.exp: p foo(go, fo, eo) FAIL: gdb.cp/koenig.exp: p foo(io) FAIL: gdb.cp/koenig.exp: p foo(ix) FAIL: gdb.cp/koenig.exp: p foo(ko,1) Running ./gdb.cp/m-static.exp ... FAIL: gdb.cp/m-static.exp: print svar +FAIL: gdb.ada/array_bounds.exp: print table'first (GDB internal error) +FAIL: gdb.ada/array_bounds.exp: print table'last (GDB internal error) +FAIL: gdb.ada/arrayidx.exp: print e_one_two_three, indexes off (GDB internal error) +ERROR: Process no longer exists +FAIL: gdb.ada/packed_tagged.exp: print x +FAIL: gdb.ada/packed_tagged.exp: ptype x +FAIL: gdb.ada/variant_record_packed_array.exp: print empty +FAIL: gdb.ada/whatis_array_val.exp: print full (GDB internal error) +FAIL: gdb.ada/whatis_array_val.exp: whatis $ But for example gdb.cp/class2.exp no longer regresses.
[Bug debug/53235] [4.8 Regression] 20120504 broke -fdebug-types-section
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53235 Jason Merrill jason at gcc dot gnu.org changed: What|Removed |Added Status|UNCONFIRMED |RESOLVED Resolution||FIXED --- Comment #6 from Jason Merrill jason at gcc dot gnu.org 2012-05-14 02:12:20 UTC --- Should be fixed.
[Bug debug/53235] [4.8 Regression] 20120504 broke -fdebug-types-section
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53235 --- Comment #5 from Jason Merrill jason at gcc dot gnu.org 2012-05-13 03:37:42 UTC --- Author: jason Date: Sun May 13 03:37:38 2012 New Revision: 187435 URL: http://gcc.gnu.org/viewcvs?root=gccview=revrev=187435 Log: PR debug/53235 * dwarf2out.c (build_local_stub): Prefer DW_AT_signature for comdat types. Modified: trunk/gcc/ChangeLog trunk/gcc/dwarf2out.c
[Bug debug/53235] [4.8 Regression] 20120504 broke -fdebug-types-section
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53235 Richard Guenther rguenth at gcc dot gnu.org changed: What|Removed |Added Version|4.7.0 |4.8.0 Target Milestone|--- |4.8.0
[Bug debug/53235] [4.8 Regression] 20120504 broke -fdebug-types-section
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53235 --- Comment #1 from Jason Merrill jason at gcc dot gnu.org 2012-05-07 14:21:30 UTC --- 21e is there as a local stub so that multiple references to the same .debug_types type can use (smaller) local DIE references instead of all needing to use DW_FORM_sig8. The testcase is failing because of the change from A* to struct A*? Is that an important distinction? If so, could you handle the case of a nameless typedef specially on your end?
[Bug debug/53235] [4.8 Regression] 20120504 broke -fdebug-types-section
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53235 --- Comment #2 from Jan Kratochvil jan.kratochvil at redhat dot com 2012-05-07 14:32:59 UTC --- (In reply to comment #1) The testcase is failing because of the change from A* to struct A*? Yes. Is that an important distinction? In other cases it even crashes GDB, originally filed as: http://sourceware.org/bugzilla/show_bug.cgi?id=14060 Or I see Internal error: non-aggregate type to value_struct_elt_for_reference Function policy1::function not defined. etc. If so, could you handle the case of a nameless typedef specially on your end? Yes; I wanted to know first if this is an intended change. FYI it does not seem to be DWARF compliant: The typedef entry has a DW_AT_name attribute whose value is a null-terminated string containing the name of the typedef as it appears in the source program.
[Bug debug/53235] [4.8 Regression] 20120504 broke -fdebug-types-section
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53235 --- Comment #3 from Jason Merrill jason at gcc dot gnu.org 2012-05-07 14:47:27 UTC --- (In reply to comment #2) Yes; I wanted to know first if this is an intended change. It was. FYI it does not seem to be DWARF compliant: The typedef entry has a DW_AT_name attribute whose value is a null-terminated string containing the name of the typedef as it appears in the source program. Yes, I agree, but it seemed in informal testing that GDB didn't mind; I apologize for not running the testsuite. Would DW_TAG_structure_type DW_AT_declaration DW_AT_signature sig8 be better? I suppose strictly speaking we need a DW_AT_name there, too...I'll see about going in that direction instead.
[Bug debug/53235] [4.8 Regression] 20120504 broke -fdebug-types-section
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53235 --- Comment #4 from Jan Kratochvil jan.kratochvil at redhat dot com 2012-05-07 15:00:01 UTC --- (In reply to comment #3) Would DW_TAG_structure_type DW_AT_declaration DW_AT_signature sig8 be better? I also think GDB read_structure_type should cope with it right. I suppose strictly speaking we need a DW_AT_name there, too...I'll see about going in that direction instead. As GDB should not mind maybe we could propose DWARF extension DW_AT_specification - DW_AT_specification or DW_AT_signature in the paragraph: Structure, union and class entries containing the DW_AT_specification attribute do not need to duplicate information provided by the declaration entry referenced by the specification attribute. In particular, such entries do not need to contain an attribute for the name of the structure, class or union they represent if such information is already provided in the declaration.