Commit c57173b6 by Alan Modra Committed by Alan Modra

[RS6000] Correct powerpc sysv stack argument accounting

ppc32 starts using the stack for integer arg passing when we run out
of integer arg passing registers.  Similarly, we start using the stack
for floating point args when we run out of floating point registers.
The decision on where an integer arg goes does not depend on number of
floating point args, nor does the decision on where a floating point
arg goes depend on number of integer args.  Alignment of stack args
also simply depends on number of stack args.

This patch untangles the horrible mess we had, with intarg_count being
wrongly used to count both integer args and stack words.

	* src/powerpc/ffi_sysv.c (ffi_prep_cif_sysv_core): Count fprs,
	gprs, and stack words separately.
	(ffi_prep_args_SYSV): Similarly.

From-SVN: r228307
parent d64f8dd2
2015-10-01 Alan Modra <amodra@gmail.com>
* src/powerpc/ffi_sysv.c (ffi_prep_cif_sysv_core): Count fprs,
gprs, and stack words separately.
(ffi_prep_args_SYSV): Similarly.
2015-05-13 Michael Haubenwallner <michael.haubenwallner@ssi-schaefer.com> 2015-05-13 Michael Haubenwallner <michael.haubenwallner@ssi-schaefer.com>
* Makefile.in: Regenerated with automake-1.11.6. * Makefile.in: Regenerated with automake-1.11.6.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment