[Bug debug/14860] New: [regression] gcc -gstabs+ fails to emit stabs for fundamental types
mec dot gnu at mindspring dot com
gcc-bugzilla@gcc.gnu.org
Tue Apr 6 02:07:00 GMT 2004
Here is a test program:
char * pc;
int main ()
{
return 0;
}
Compile with gcc -gstabs+ -S.
Here are the stabs with gcc 2004-03-23 23:40:00 UTC
.stabs "char:t(0,2)=r(0,2);0;127;",128,0,0,0
.stabs "pc:G(0,16)=*(0,2)",32,0,1,0
Here are the stabs with gcc 2004-03-24 00:00:00 UTC
.stabs "pc:G(0,2)=*(0,3)=r(0,3);0;127;",32,0,1,0
The problem with the new stabs is that type (0,3) has no name.
So gdb cannot print this type:
# gdb 6.0
(gdb) ptype pc
type = <invalid type code 7> *
I narrowed the regression down to this patch:
2004-03-23 Zack Weinberg <zack@codesourcery.com>
PR 12267, 12391, 12560, 13129, 14114, 14133
This problem does not happen with -gdwarf-2.
This problem happens with gcc HEAD and gcc tree-ssa-20020619-branch. It does
not happen with gcc gcc-3_4-branch or gcc gcc-3_3-branch.
I suspect that the problem is related to the removal of first_builtin_decl and
last_builtin_decl. When I compile an empty program with the old compiler, there
are stab lines for about 20 builtin types (int, char, float, double, etc). When
I compile an empty program with the new compiler, there are no such stab lines.
--
Summary: [regression] gcc -gstabs+ fails to emit stabs for
fundamental types
Product: gcc
Version: 3.5.0
Status: UNCONFIRMED
Severity: normal
Priority: P1
Component: debug
AssignedTo: zack at codesourcery dot com
ReportedBy: mec dot gnu at mindspring dot com
CC: gcc-bugs at gcc dot gnu dot org
GCC build triplet: i686-pc-linux-gnu
GCC host triplet: i686-pc-linux-gnu
GCC target triplet: i686-pc-linux-gnu
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14860
More information about the Gcc-bugs
mailing list