[AVR] inferior call of subprogram with pointer as argument
On AVR, the gdb view of an address is different from the machine view of the
same address. We need to use special machinery implemented by value_pointer
to take the pointer of a value.
For instance, considering the following function...
procedure Trace (Unit : T; Message : String);
... where T is an access Integer (a pointer to an integer), call to this
function currently triggers the following warnings:
(gdb) call debug.trace (me, "You")
warning: Value does not fit in 16 bits.
warning: Value does not fit in 16 bits.
Tracing message: You
It could have been worse if Trace actually tried to dereference the Unit
argument...
gdb/ChangeLog (from Tristan Gingold):
* ada-lang.c (value_pointer): New function.
(make_array_descriptor): Call value_pointer to convert addresses to
pointers.
Tested on avr and x86_64-linux.