This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: variable objects and registers
On Thu, Dec 21, 2006 at 02:29:44PM +1300, Nick Roberts wrote:
> I see now that Insight has two commands:
>
> /* This implements the tcl command gdb_get_blocks
> *
> * Returns the start and end addresses for all blocks in
> * the selected frame.
> /* This implements the tcl command gdb_block_vars.
> *
> * Returns all variables valid in the specified block.
> gdb_block_vars only gets called if gdb_get_blocks finds a new block which
> then finds any variabes local to it. That way new variable objects can be
> added (and old ones deleted if a block has disappeared) while keeping
> the variable objects which are still in scope. I think we should implement
> these functions in MI (perhaps Apple already have).
Just a note: whatever approach we end up with for this problem, let's
not use start and end addresses to identify the blocks. In modern
compilers a block is not a contiguous range of PCs; they can overlap.
--
Daniel Jacobowitz
CodeSourcery