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: MI: frozen variable objects


On Fri, 2006-11-17 at 09:16 +0300, Vladimir Prus wrote:
> > If the above is right, then the low-level changes will prevent the
> > varobj layer from fetching the data, and you kinda get the result you
> > wanted. You'd just need to make sure that the data gets fetched when
> > requested explicitly and to report the not-fetched-because-sensitive
> > varobj state.
> 
> That not exactly the design we planned. The value/type level will need two
> changes:
> 
>    - Some flag on type or value to indicate it's read sensitive
>    - Some mechanism to allow presenting various target register, 
>      scattered over address space, as a single structure
> 
> At the same time, value level is not the right level to handle presentation
> of read-sensitive values or make fetch/not fetch decisions. There's just
> value_fetch_lazy function -- that fetches the raw data from the target. We
> can either:
> 
>    (1) make value_fetch_lazy do nothing for read-sensitive values,
>    and add new value_fetch_really function that will read the value anyway,
>    or
>    (2) teach the clients of value_fetch_lazy to call it only when needed

Well that's roughly what I meant. Once you get this groundwork in GDB,
all you'll have to do to get the behavior you described is to propagate
the explicitly-requested flag down to the varobj call to
value_fetch_lazy. Maybe your additional changes are necessary to handle
it gracefully. You've obviously studied this code more deeply and
recently than I did.

Fred.


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