This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH:MI] Return a subset of a variable object's children
- From: Daniel Jacobowitz <drow at false dot org>
- To: Nick Roberts <nickrob at snap dot net dot nz>
- Cc: Marc Khouzam <marc dot khouzam at ericsson dot com>, gdb-patches at sourceware dot org
- Date: Thu, 1 May 2008 16:40:59 -0400
- Subject: Re: [PATCH:MI] Return a subset of a variable object's children
- References: <18452.24568.655617.907458@kahikatea.snap.net.nz> <6D19CA8D71C89C43A057926FE0D4ADAA042910A5@ecamlmw720.eamcs.ericsson.se> <18455.41299.899430.615138@kahikatea.snap.net.nz>
Still reading the rest of the thread, but...
On Wed, Apr 30, 2008 at 10:29:39AM +1200, Nick Roberts wrote:
> > but only actually create the children that have been requested by the user.
> > I'm not sure how much efficiency there is by allocating the memory before
> > hand? Also, is there no way to grow the vector by more than a single point
> > at a time?
>
> Like resize with STL vectors? I'm not aware of one.
VEC_reserve and VEC_quick_push. There's no clean way to memset
the new elements but this will cut down on allocation anyway.
--
Daniel Jacobowitz
CodeSourcery