This is the mail archive of the
gdb@sources.redhat.com
mailing list for the GDB project.
mi -var-create does not clear the 'value stack' all_values.
- From: Chris Zankel <zankel at tensilica dot com>
- To: gdb at sources dot redhat dot com
- Date: Fri, 30 Jul 2004 12:17:53 -0700
- Subject: mi -var-create does not clear the 'value stack' all_values.
I noticed that the mi command -var-create does not clear the value stack
(all_values) before it returns, so any command that follows -var-create
and that allocates a new value receives a list of registers that
includes those values generated by -var-create.
This could be a problem, for example, in can_use_hardware_watchpoint
that walks through the value list looking for any value it cannot watch
(registers, for example). If -var-create created such a value
(register), any succeeding command that wants to set a watchpoint
(-break-watch) would, therefore, fail.
I have to admit, though, that I haven't been able to create such a test
case, specifically, I couln't get -var-create to create a value of the
type register. Nevertheless, it seems to me that -var-create should
clear all_values.
Any comments?
-- Chris