Re: [RFA][2/5] New port: Cell BE SPU (valops.c fix)

Vladimir Prus
2006-12-07T06:34:17Z

Daniel Jacobowitz wrote:

> On Wed, Dec 06, 2006 at 06:10:04PM +0100, Ulrich Weigand wrote:
>> Daniel Jacobowitz wrote:
>>
>> > Vladimir has actually been working on a similar change for a different
>> > purpose. He added a "parent value" pointer to values; bitfields then
>> > are accessed by reading the enclosing structure and extracting bits
>> > from value_contents.
>>
>> Can you point me to the patch? I didn't find it on the gdb-patches list
>> ...
>
> It hasn't been posted yet - it's not quite done.
>
>> > What do you think? Would this solve the same problem as your patch?
>>
>> Depending on the circumstances when a "child" value is generated, it
>> may solve the same problem. To solve the register value problem,
>> we would need to make sure that accessing a component of a value in
>> a register would create a "child" value, and v_t_r is always only
>> ever called on the (grand-)parent that corresponds to the value
>> originally retrieved by r_t_v.
>
> Right. The current version only did this for bitfields in memory,
> rather than fields in registers, but it shouldn't be hard to extend.
> Does that make sense, Vlad?

It does. We'd only have to use value_to_register as opposed to write_memory
when sending the value back. Plus a bunch of unexpected problems but nothing
impossible.

- Volodya