This is the mail archive of the
gdb-prs@sourceware.org
mailing list for the GDB project.
[Bug symtab/14148] New: -fdebug-types-section regresses ststic scopeof types
- From: "jan.kratochvil at redhat dot com" <sourceware-bugzilla at sourceware dot org>
- To: gdb-prs at sourceware dot org
- Date: Wed, 23 May 2012 21:12:55 +0000
- Subject: [Bug symtab/14148] New: -fdebug-types-section regresses ststic scopeof types
- Auto-submitted: auto-generated
http://sourceware.org/bugzilla/show_bug.cgi?id=14148
Bug #: 14148
Summary: -fdebug-types-section regresses ststic scope of types
Product: gdb
Version: HEAD
Status: NEW
Severity: normal
Priority: P2
Component: symtab
AssignedTo: unassigned@sourceware.org
ReportedBy: jan.kratochvil@redhat.com
Classification: Unclassified
FAILing new testcase for -fdebug-types-section [Re: [RFC - Python scripting]
New methods Symtab.global_block and Symtab.static_block (docs included)]
http://sourceware.org/ml/gdb-patches/2012-05/msg00132.html
PASS:
C="gcc -fno-debug-types-section -g -c -x c -";echo 'struct s { int i; }; extern
void f (void); int main (void) { struct s a; f (); return 0; }'|$C -o 36.o;echo
'struct s { int j; }; void f (void) { struct s b; }'|$C -o 36b.o;gcc -o 36 36.o
36b.o;./gdb -readnow ./36 -ex start -ex 'ptype struct s' -ex step -ex 'ptype
struct s' -ex c -ex q 2>/dev/null|grep -w int
int i;
int j;
FAIL:
C="gcc -fdebug-types-section -g -c -x c -";echo 'struct s { int i; }; extern
void f (void); int main (void) { struct s a; f (); return 0; }'|$C -o 36.o;echo
'struct s { int j; }; void f (void) { struct s b; }'|$C -o 36b.o;gcc -o 36 36.o
36b.o;./gdb -readnow ./36 -ex start -ex 'ptype struct s' -ex step -ex 'ptype
struct s' -ex c -ex q 2>/dev/null|grep -w int
int j;
int j;
In a different more readable form:
==> 36.c <==
struct s { int i; };
extern void f (void);
int main (void) {
struct s a;
f ();
return 0;
}
==> 36b.c <==
struct s { int j; };
void f (void) {
struct s b;
}
$ gcc -fdebug-types-section -o 36 36.c 36b.c -Wall -g
$ ./gdb -readnow ./36
(gdb) start
(gdb) ptype struct s
type = struct s {
int j;
}
(gdb) ptype a
type = struct s {
int i;
}
(gdb) whatis a
type = struct s
That is with -fdebug-types-section GDB no longer provides STATIC_BLOCK scope
for DW_TAG_type_unit types.
--
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.