public inbox for gdb-prs@sourceware.org help / color / mirror / Atom feed
From: "ajax at redhat dot com" <sourceware-bugzilla@sourceware.org> To: gdb-prs@sourceware.org Subject: [Bug tui/10829] New: Confusing results printed when a subexpression is optimized out Date: Thu, 22 Oct 2009 14:52:00 -0000 [thread overview] Message-ID: <20091022145246.10829.ajax@redhat.com> (raw) [-- Warning: decoded text below may be mangled, UTF-8 assumed --] [-- Attachment #1: Type: text/plain, Size: 1158 bytes --] In the X server during request processing, where "stuff" is a struct xReq * with a member named class: (gdb) print stuff $3 = <value optimized out> (gdb) print stuff->class Cannot access memory at address 0x16 The naïve conclusion for the user is that "stuff" somehow became NULL, which is not in fact true; its value is merely being flattened to zero before computing the offset of the "class" member. The second print statement should be more along the lines of "Cannot evaluate subexpression foo". gdb version: % rpm -q gdb gdb-6.8.91.20090921-1.fc12.i686 -- Summary: Confusing results printed when a subexpression is optimized out Product: gdb Version: unknown Status: UNCONFIRMED Severity: normal Priority: P2 Component: tui AssignedTo: unassigned at sourceware dot org ReportedBy: ajax at redhat dot com CC: gdb-prs at sourceware dot org http://sourceware.org/bugzilla/show_bug.cgi?id=10829 ------- You are receiving this mail because: ------- You are on the CC list for the bug, or are watching someone who is.
next reply other threads:[~2009-10-22 14:52 UTC|newest] Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top 2009-10-22 14:52 ajax at redhat dot com [this message] 2009-10-22 15:54 ` [Bug tui/10829] " jan dot kratochvil at redhat dot com 2010-01-07 19:08 ` ajax at redhat dot com 2010-04-18 1:12 ` [Bug gdb/10829] " pedro at codesourcery dot com
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20091022145246.10829.ajax@redhat.com \ --to=sourceware-bugzilla@sourceware.org \ --cc=gdb-prs@sourceware.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).