Andreas' 2013-02-08 change reverted some breakage for struct return
authorAlan Modra <amodra@gmail.com>
Sat, 16 Nov 2013 11:52:43 +0000 (06:52 -0500)
committerAnthony Green <green@moxielogic.com>
Sat, 16 Nov 2013 11:52:43 +0000 (06:52 -0500)
commit362851379a49ce07d3e36e82c4e5c7b6cc16a352
tree600aaac80362326f542e40d9da455a0b2d9cffaf
parent1c06515d927d9de1582438d4eb5953890e79c5c7
Andreas' 2013-02-08 change reverted some breakage for struct return
values from 2011-11-12, but in so doing reintroduced string
instructions to sysv.S that are not supported on all powerpc variants.
This patch properly copies the bounce buffer to destination in C code
rather than in asm.

I have tested this on powerpc64-linux, powerpc-linux and
powerpc-freebsd.  Well, the last on powerpc-linux by lying to
configure with

CC="gcc -m32 -msvr4-struct-return -mlong-double-64" \
CXX="g++ -m32 -msvr4-struct-return -mlong-double-64" \
/src/libffi-current/configure --build=powerpc-freebsd

and then

make && make CC="gcc -m32" CXX="g++ -m32" \
RUNTESTFLAGS=--target_board=unix/-m32/-msvr4-struct-return/-mlong-double-64\
 check
ChangeLog
src/powerpc/ffi.c
src/powerpc/ppc_closure.S
src/powerpc/sysv.S