This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: PATCH: error reading variable: value has been optimized out
- From: Eli Zaretskii <eliz at gnu dot org>
- To: Andrew Burgess <aburgess at broadcom dot com>
- Cc: gdb-patches at sourceware dot org, jan dot kratochvil at redhat dot com
- Date: Sat, 01 Sep 2012 11:16:41 +0300
- Subject: Re: PATCH: error reading variable: value has been optimized out
- References: <50376F3B.1080407@broadcom.com> <20120826171840.GA21205@host2.jankratochvil.net> <504092C0.2000602@broadcom.com>
- Reply-to: Eli Zaretskii <eliz at gnu dot org>
> Date: Fri, 31 Aug 2012 11:32:32 +0100
> From: "Andrew Burgess" <aburgess@broadcom.com>
> cc: "Jan Kratochvil" <jan.kratochvil@redhat.com>
>
> On 26/08/2012 6:18 PM, Jan Kratochvil wrote:
> > I agree with the fix but it should have GDB-testsuite compatible testcase.
> > Also FYI it is only for backward compatibility with old GCCs.
>
> Included a test case (below) that covers 4 different cases, all of
> which are currently broken in different ways.
Thank you for doing this.
> [...] but as gcc is no longer creating examples like this I think we can accept the more limited solution I originally suggessted, if that's ok.
"No longer creating" since what version of GCC?
I don't think we should drop use cases just because they are only
possible on past (old) versions of GCC. GDB is not limited to debug
programs created only by latest GCC versions. I happen to still use a
very old version of GCC (because it is stable and fast, and because I
rarely need C++), and would very much like to have better debugging
abilities for optimized code than what I have now.
TIA