This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: PR8554: New command to save breakpoints to a file


Pedro Alves wrote:
On Thursday 15 April 2010 18:51:55, Michael Snyder wrote:
What about watchpoints? Do we get all the context info right?

Watchpoints on globals, as right as breakpoints. Watchpoints on locals, no, you're just out of luck. I don't think there's much to do there; GDB gets rid of those on process start/exit, so users are used to those not being very "persistanteable". OTOH, it may be useful to be able to dump watchpoints on locals, and be able to load them up when you know it's okay, so never dumping those isn't that great either. So, IMO, we shouldn't worry much about those, at least, in this first patch. :-) I could add a note to the manual, perhaps.


I can't remember if we've discussed this idea before, but a simple way to handle in the future might be simply to introduce a syntax for referring to specific locals - function:::local, file:line:::local, for instance. You get a sal that maps to a block, then can find the block's symbol with that name. If the name also occurs in superblocks, you could make a policy decision as to whether to include the first found, or all found.


Stan


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]