Bug 704494 - ../../gdb/findvar.c:417: internal-error: read_var_value: Assertion `frame' failed.
Summary: ../../gdb/findvar.c:417: internal-error: read_var_value: Assertion `frame' fa...
Keywords:
Status: CLOSED NEXTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: gdb
Version: 14
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Jan Kratochvil
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-05-13 12:02 UTC by Sam Varshavchik
Modified: 2011-05-18 20:08 UTC (History)
4 users (show)

Fixed In Version: 7.2.90.20110429-36.fc15
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2011-05-18 20:08:31 UTC
Type: ---


Attachments (Terms of Use)
Sample test program (313 bytes, text/x-c++src)
2011-05-13 12:02 UTC, Sam Varshavchik
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Sourceware 11803 0 None None None Never

Description Sam Varshavchik 2011-05-13 12:02:28 UTC
Created attachment 498756 [details]
Sample test program

Description of problem:

gdb always crashes attempting to print the contents of a C++ class instance with a static __thread member.

Version-Release number of selected component (if applicable):

gdb-7.2-51.fc14.x86_64

How reproducible:

Always

Steps to Reproduce:

Use the attached sample program.
 
Actual results:

[mrsam@monster ~]$ g++ -g -o /tmp/gdb.tst /tmp/gdb.tst.C
[mrsam@monster ~]$ gdb /tmp/gdb.tst
GNU gdb (GDB) Fedora (7.2-51.fc14)
Copyright (C) 2010 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-redhat-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from /tmp/gdb.tst...done.
(gdb) b foo
Breakpoint 1 at 0x40064c: file /tmp/gdb.C, line 25.
(gdb) run
Starting program: /tmp/gdb.tst 

Breakpoint 1, foo (yp=0x7fffffffe180) at /tmp/gdb.C:25
25		yp->v=1;   /* Set the breakpoint on this line */
Missing separate debuginfos, use: debuginfo-install glibc-2.13-1.x86_64 libgcc-4.5.1-4.fc14.x86_64 libstdc++-4.5.1-4.fc14.x86_64
(gdb) p *yp
$1 = {v = 0, static xp = warning: static field's value depends on the current frame - bad debug info?

../../gdb/findvar.c:417: internal-error: read_var_value: Assertion `frame' failed.
A problem internal to GDB has been detected,
further debugging may prove unreliable.
Quit this debugging session? (y or n) 


Expected results:

The contents of the class

Additional info:

Comment 1 Tom Tromey 2011-05-17 18:34:11 UTC
This was fixed upstream:

http://sourceware.org/bugzilla/show_bug.cgi?id=11803

The assert in question no longer exists there.

Comment 2 Jan Kratochvil 2011-05-18 20:08:31 UTC
F15 is going to be released these days, to be backported only on expliciti request, thanks.

GNU gdb (GDB) Fedora (7.2.90.20110429-36.fc15)
$1 = {v = 0, static xp = 0x7fffffffdca0}
(gdb) p &xinst
$3 = (x *) 0x7fffffffdca0


Note You need to log in before you can comment on or make changes to this bug.