[patch/rfc] default REGISTER_VIRTUAL_SIZE and REGISTER_RAW_SIZE toregister_size
Andrew Cagney
ac131313@cygnus.com
Mon May 6 17:17:00 GMT 2002
> Andrew Cagney wrote:
>
>>
>> Hello,
>>
>> For most architectures. The relationship:
>>
>> REGISTER_VIRTUAL_SIZE(N)
>> == REGISTER_RAW_SIZE(N)
>> == TYPE_LENGTH(REGISTER_VIRTUAL_TYPE(N)
>>
>> (the exception is the @$(*&@(^$*&^!@ MIPS ...).
>
>
> Surely this is also true for x87 regs?
Nope! The i386 register is 80 bits. When pushed on the stack, extra
space is reserved to make it 4 byte aligned (96 bit) but the extra two
bytes at the end don't get used.
>> Given this, the
>> attached patch changes the architecture vector so that it defaults both
>> to the register's type size.
>>
>> I think this is the logical conclusion to MichaelS's earlier patch that
>> provided defaults to each.
>>
>> Thoughts? I'll look to commit it in a week.
>
>
> If I understand it, it won't affect any target that explicitly
> sets these methods -- in which case I agree with the change.
Yes, it isn't ment to affect existing targets. Up until now you were
required to set the methods as otherwize GDB wouldn't build/run.
thanks for the comments,
Andrew
More information about the Gdb-patches
mailing list