This is the mail archive of the gdb-patches@sources.redhat.com 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: [patch/rfc] Simplify by assuming that the inferior frame wasaligned


Hello,

This simplifies inferior function call code by assuming that "struct_return" is always correct and always using it to extract the "struct return value".

The MIPS inferior function call code was invalidating "struct_addr" by doing some local alignment. Now that the MIPS has a frame_align method that problem no longer occures (I've found no other code pulling similar tricks). Consequently, I believe that the attached simplification is now safe.

It's got lots of follow through. In particular it allows the restructuring of value_being_returned and print_return_value, and the elimination of VALUE_RETURNED_FROM_STACK.

Note that the change is only one line! The rest is to alert the coder as to the status of various parts of GDB.

Baring comment, I'll look to commit this in 3-4 days,

I've checked this in. Now to shuffle value_being_returned and print_return_value.


Andrew

2003-09-27 Andrew Cagney <cagney@redhat.com>

	* infcall.c (call_function_by_hand): When STRUCT_RETURN, always
	use STRUCT_ADDR.  When not using "struct return convention", pass
	"0" to "value_being_returned".  Add FIXMEs.
	* infcmd.c (print_return_value): Pass an explicit 0/1 to
	value_being_returned.  Add comments.
	* values.c (value_being_returned): Add FIXME.
	* hppa-tdep.c (hppa_extract_struct_value_address): Add FIXME.
	(hppa_value_returned_from_stack): Add FIXME.




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