[PATCH] Allow 'NULL' to i387_supply_fsave et. al.

Mark Kettenis kettenis@chello.nl
Sat Oct 12 10:59:00 GMT 2002


Klee Dienes <klee@apple.com> writes:

> The following patch allows one to pass 'NULL' to i387_supply_fsave, 
> i387_supply_fxsave, and i387_supply_register, to mean "no register data 
> is available".  This is convenient for clients of i387-tdep.c that may 
> have gotten a "no register data available" response from the OS while 
> trying to fetch information, and causes the i387_supply_* functions to 
> have the same behavior as supply_register.

Makes sense to me, but perhaps you should take a look at
i386-linux-nat.c:dummy_sse_values().  On Linux, if the SSE registers
aren't available, they're filled with some non-zero dummy values.  I
think we should try to be consistent about this across platforms, so
perhaps calling i387_supply_fxsave() with NULL should do something
similar.

> 2002-10-05  Klee Dienes  <kdienes@apple.com>
> 
>          * i387-tdep.c (i387_supply_register): When called with NULL as a
>          buffer, mark the register as not provided (to mirror the 
> behavior
>          of supply_register).
>          (i387_supply_fxsave): Ditto.
>          (i387_supply_fsave): Ditto (inherits the behavior from 
> i387_supply_register).

Assuming your origional ChangeLog entry doesn't have these glaring
formatting problems, please go ahead and check this in.

Mark



More information about the Gdb-patches mailing list