public inbox for gdb-prs@sourceware.org help / color / mirror / Atom feed
* [Bug gdb/16420] New: Gdb cannot print static variables when code is compiled but not linked with -flto
@ 2014-01-09 11:23 branko.drevensek at gmail dot com
2024-01-02 12:02 ` [Bug gdb/16420] " ssbssa at sourceware dot org
` (3 more replies)
0 siblings, 4 replies; 5+ messages in thread
From: branko.drevensek at gmail dot com @ 2014-01-09 11:23 UTC (permalink / raw)
To: gdb-prs
https://sourceware.org/bugzilla/show_bug.cgi?id=16420
Bug ID: 16420
Summary: Gdb cannot print static variables when code is
compiled but not linked with -flto
Product: gdb
Version: 7.6
Status: NEW
Severity: minor
Priority: P2
Component: gdb
Assignee: unassigned at sourceware dot org
Reporter: branko.drevensek at gmail dot com
Code:
---
int main()
{
static int x = 4;
return x;
}
---
Compiled with -O0 -g3 -flto. Linked *without* -flto.
In gdb within main:
info locals
x.1586 = 4
print x
No symbol "x" in current context.
print x.1586
No symbol "x" in current context.
--
You are receiving this mail because:
You are on the CC list for the bug.
^ permalink raw reply [flat|nested] 5+ messages in thread* [Bug gdb/16420] Gdb cannot print static variables when code is compiled but not linked with -flto 2014-01-09 11:23 [Bug gdb/16420] New: Gdb cannot print static variables when code is compiled but not linked with -flto branko.drevensek at gmail dot com @ 2024-01-02 12:02 ` ssbssa at sourceware dot org 2024-03-15 9:31 ` sam at gentoo dot org ` (2 subsequent siblings) 3 siblings, 0 replies; 5+ messages in thread From: ssbssa at sourceware dot org @ 2024-01-02 12:02 UTC (permalink / raw) To: gdb-prs https://sourceware.org/bugzilla/show_bug.cgi?id=16420 Hannes Domani <ssbssa at sourceware dot org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |ssbssa at sourceware dot org --- Comment #1 from Hannes Domani <ssbssa at sourceware dot org> --- Sounds to me more like a problem on gcc side. And I can't reproduce it. -- You are receiving this mail because: You are on the CC list for the bug. ^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug gdb/16420] Gdb cannot print static variables when code is compiled but not linked with -flto 2014-01-09 11:23 [Bug gdb/16420] New: Gdb cannot print static variables when code is compiled but not linked with -flto branko.drevensek at gmail dot com 2024-01-02 12:02 ` [Bug gdb/16420] " ssbssa at sourceware dot org @ 2024-03-15 9:31 ` sam at gentoo dot org 2024-03-15 13:04 ` tromey at sourceware dot org 2025-05-15 8:48 ` sam at gentoo dot org 3 siblings, 0 replies; 5+ messages in thread From: sam at gentoo dot org @ 2024-03-15 9:31 UTC (permalink / raw) To: gdb-prs https://sourceware.org/bugzilla/show_bug.cgi?id=16420 Sam James <sam at gentoo dot org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |sam at gentoo dot org -- You are receiving this mail because: You are on the CC list for the bug. ^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug gdb/16420] Gdb cannot print static variables when code is compiled but not linked with -flto 2014-01-09 11:23 [Bug gdb/16420] New: Gdb cannot print static variables when code is compiled but not linked with -flto branko.drevensek at gmail dot com 2024-01-02 12:02 ` [Bug gdb/16420] " ssbssa at sourceware dot org 2024-03-15 9:31 ` sam at gentoo dot org @ 2024-03-15 13:04 ` tromey at sourceware dot org 2025-05-15 8:48 ` sam at gentoo dot org 3 siblings, 0 replies; 5+ messages in thread From: tromey at sourceware dot org @ 2024-03-15 13:04 UTC (permalink / raw) To: gdb-prs https://sourceware.org/bugzilla/show_bug.cgi?id=16420 Tom Tromey <tromey at sourceware dot org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Resolution|--- |OBSOLETE CC| |tromey at sourceware dot org --- Comment #2 from Tom Tromey <tromey at sourceware dot org> --- (In reply to Hannes Domani from comment #1) > Sounds to me more like a problem on gcc side. > And I can't reproduce it. Given its age & lack of reproducibility, let's close it. Branko -- if this is still an issue for you, please comment and/or reopen the bug, I guess maybe with a reproducer. Often though this sort of thing turns out to be a compiler problem, where gdb is just doing what the compiler tells it. -- You are receiving this mail because: You are on the CC list for the bug. ^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug gdb/16420] Gdb cannot print static variables when code is compiled but not linked with -flto 2014-01-09 11:23 [Bug gdb/16420] New: Gdb cannot print static variables when code is compiled but not linked with -flto branko.drevensek at gmail dot com ` (2 preceding siblings ...) 2024-03-15 13:04 ` tromey at sourceware dot org @ 2025-05-15 8:48 ` sam at gentoo dot org 3 siblings, 0 replies; 5+ messages in thread From: sam at gentoo dot org @ 2025-05-15 8:48 UTC (permalink / raw) To: gdb-prs https://sourceware.org/bugzilla/show_bug.cgi?id=16420 Sam James <sam at gentoo dot org> changed: What |Removed |Added ---------------------------------------------------------------------------- See Also| |https://sourceware.org/bugz | |illa/show_bug.cgi?id=12156 -- You are receiving this mail because: You are on the CC list for the bug. ^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2025-05-15 8:48 UTC | newest] Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2014-01-09 11:23 [Bug gdb/16420] New: Gdb cannot print static variables when code is compiled but not linked with -flto branko.drevensek at gmail dot com 2024-01-02 12:02 ` [Bug gdb/16420] " ssbssa at sourceware dot org 2024-03-15 9:31 ` sam at gentoo dot org 2024-03-15 13:04 ` tromey at sourceware dot org 2025-05-15 8:48 ` sam at gentoo dot org
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).