Commit Graph

45 Commits

Author SHA1 Message Date
Alan Modra
362851379a 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
2013-11-16 06:52:43 -05:00
Alan Modra
1c06515d92 The powerpc64 ABIs align structs passed by value, a fact ignored by
gcc for quite some time.  Since gcc now does the correct alignment,
libffi needs to follow suit.  This ought to be made selectable via
a new abi value, and the #ifdefs removed from ffi.c along with many
other #ifdefs present there and in assembly.  I'll do that with a
followup patch sometime.

This is a revised version of
https://sourceware.org/ml/libffi-discuss/2013/msg00162.html
2013-11-16 06:41:36 -05:00
Alan Modra
a97cf1fae5 This patch prepares for ELFv2, where sizes of these areas change. It
also makes some minor changes to improve code efficiency.
2013-11-16 06:40:13 -05:00
Alan Modra
164283f4ac The powerpc64 support opted to pass floating point values both in the
fpr area and the parameter save area, necessary when the backend
doesn't know if a function argument corresponds to the ellipsis
arguments of a variadic function.  This patch adds powerpc support for
variadic functions, and changes the code to only pass fp in the ABI
mandated area.  ELFv2 needs this change since the parameter save area
may not exist there.

This also fixes two faulty tests that used a non-variadic function
cast to call a variadic function, and spuriously reasoned that this is
somehow necessary for static functions..
2013-11-16 06:38:55 -05:00
Anthony Green
128cd1d2f3 Fix spelling errors 2013-10-08 06:45:51 -04:00
Anthony Green
d3d099b40c little-endian ppc64 support 2013-07-02 16:11:38 -04:00
Anthony Green
4acf0056f5 Build fix for soft-float power targets 2013-03-16 08:18:45 -04:00
Anthony Green
70b11b47ee Fix small struct passing on ppc 2013-02-08 16:12:19 -05:00
Anthony Green
8bd15d139a Fix many.c testcase for ppc 2013-02-08 13:56:37 -05:00
Anthony Green
05fbe1faed xlc compiler support 2013-01-11 16:54:40 -05:00
rofl0r
f6b58d2bdc fix build on ppc when long double == double 2012-11-22 16:26:21 +01:00
Anthony Green
dfadfb1985 Rebase for ppc64 fix 2012-10-31 06:46:41 -04:00
Anthony Green
853cc722a1 Fix typo for darwin targets 2012-04-10 06:33:33 -04:00
Anthony Green
65f40c35a2 Repair ppc build regression. 2012-04-03 07:35:59 -04:00
Anthony Green
bd78c9c331 More cygwin fixes 2012-03-21 08:09:30 -04:00
Anthony Green
84d3253f86 Rebase post GCC merge 2012-03-19 23:07:35 -04:00
Anthony Green
8360bf1cd0 Ensure that users don't include ffitarget.h directly 2012-02-23 07:01:13 -05:00
Anthony Green
ea14ae85e8 clean up 2011-11-12 16:36:59 -05:00
Anthony Green
52891f8a93 Add powerpc soft float support 2011-11-12 16:35:55 -05:00
Anthony Green
af18df2bc2 Remove use of ppc string instructions 2011-11-12 15:52:08 -05:00
Anthony Green
3d56106b07 Rebase 2011-11-12 07:20:24 -05:00
Anthony Green
2d3fb36420 Fix darwin EH 2011-03-30 16:54:42 -04:00
Anthony Green
18dd85d6cb rc8. fix last patch. 2011-02-25 16:23:04 -05:00
Anthony Green
74ee6ea8b4 rc7. More AIX fixes. 2011-02-25 15:52:14 -05:00
Anthony Green
2541679dbd Fix ppc32 bug 2011-02-25 15:09:13 -05:00
Anthony Green
1fbf9dc44f Fix bad_abi test. rc5. 2011-02-13 08:06:39 -05:00
Anthony Green
6972a4ffda Fix xlc build on AIX 2011-02-11 07:32:51 -05:00
Anthony Green
19ce713188 grammar fix 2011-02-08 10:34:23 -05:00
Anthony Green
0e5843995f Refresh from GCC 2011-02-08 07:52:40 -05:00
Anthony Green
2db72615b5 Rebase 2010-11-21 10:50:56 -05:00
Anthony Green
5feacad4a5 define generic symbols carefully 2010-08-05 08:30:04 -04:00
Anthony Green
3f5b1375ab rebase 2010-07-12 14:39:18 -04:00
Anthony Green
9dc9a293f3 Rebase to latest GCC sources 2010-04-13 10:33:52 -04:00
Anthony Green
f2c2a4fce9 Remove warnings and add OS/2 support 2010-04-13 10:19:28 -04:00
Anthony Green
7b7a42f221 Rebase from GCC 2010-01-12 09:14:14 -05:00
Anthony Green
c3042afaf3 Reset quilt patches post 3.0.9 merge with GCC 2010-01-01 08:08:02 -05:00
Anthony Green
2e7e03d014 Final updates before 3.0.9 2009-12-31 07:43:22 -05:00
Anthony Green
aea706c528 really 3.0.9rc12 2009-12-29 10:09:31 -05:00
Anthony Green
0cfe60e9d1 3.0.9rc12 2009-12-29 10:06:04 -05:00
Anthony Green
9458d88f67 Rebase from GCC 2009-12-26 07:02:27 -05:00
Anthony Green
6a34124175 Add Andreas Schwab's powerpc fix 2009-12-26 06:51:33 -05:00
Anthony Green
da11bece0f Release 3.0.9rc5 2009-12-24 05:34:46 -05:00
Anthony Green
115ab36fce Update missing changes for 3.0.9r4. 2009-12-24 00:22:00 -05:00
Anthony Green
cd98813de5 From Jens Rehsack. Fix for 64-bit AIX. 2009-10-05 00:25:29 -04:00
Anthony Green
c6dddbd02b Initial commit 2009-10-04 08:11:33 -04:00