This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [patch] varobj.c c_describe_child
- From: Tom Tromey <tromey at redhat dot com>
- To: Aleksandar Ristovski <aristovski at qnx dot com>
- Cc: gdb-patches at sources dot redhat dot com
- Date: Thu, 25 Mar 2010 12:29:48 -0600
- Subject: Re: [patch] varobj.c c_describe_child
- References: <ho8h62$4ic$1@dough.gmane.org>
- Reply-to: tromey at redhat dot com
>>>>> "Aleksandar" == Aleksandar Ristovski <aristovski@qnx.com> writes:
Aleksandar> Note that with latest gdb from HEAD it doesn't crash, I
Aleksandar> believe due to recent changes in lazy allocating the values,
Aleksandar> but it still seems wrong to keep all these intermediate
Aleksandar> values generated by adjust_value_for_child_access' in
Aleksandar> 'all_values' list.
I think these values will automatically be freed the next time an MI
command is executed. The call chain is mi_cmd_execute ->
prepare_execute_command -> free_all_values.
Or is the idea to limit the transient amount of memory used?
I can't tell from the patch.
In that case, I think it would be more typical to use
value_mark and value_free_to_mark.
Tom