This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH] Consistent display of "<optimized out>"
- From: Pedro Alves <palves at redhat dot com>
- To: gdb-patches at sourceware dot org
- Cc: Mark Kettenis <mark dot kettenis at xs4all dot nl>, aburgess at broadcom dot com
- Date: Fri, 16 Aug 2013 21:28:39 +0100
- Subject: Re: [PATCH] Consistent display of "<optimized out>"
- References: <5200F55E dot 2050308 at broadcom dot com> <201308061318 dot r76DIMdd016369 at glazunov dot sibelius dot xs4all dot nl> <5200FECF dot 7030304 at broadcom dot com> <201308061541 dot r76FfYQN022875 at glazunov dot sibelius dot xs4all dot nl> <520142D9 dot 4030304 at redhat dot com> <5208E3C8 dot 7060107 at broadcom dot com> <5208E938 dot 3080305 at redhat dot com> <201308122001 dot r7CK1862007934 at glazunov dot sibelius dot xs4all dot nl> <520E7255 dot 7080206 at redhat dot com>
On 08/16/2013 07:41 PM, Pedro Alves wrote:
> +/* Allocate a "not saved" value for type TYPE. */
> +
> +struct value *
> +allocate_not_saved_value (struct type *type,
> + struct frame_info *frame, int regnum)
> +{
> + struct value *retval = allocate_value (type);
> +
> + set_value_optimized_out (retval, 1);
> + VALUE_LVAL (retval) = lval_register;
> + VALUE_FRAME_ID (retval) = get_frame_id (frame);
I noticed that this should be the previous frame's id, not FRAME's.
I've fixed it in the branch, and did some additional cleaning up.
--
Pedro Alves