aboutsummaryrefslogtreecommitdiff
path: root/libffi/ChangeLog
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2018-05-04 23:17:11 +0930
committerAlan Modra <amodra@gcc.gnu.org>2018-05-04 23:17:11 +0930
commit71d372eba9d83660d02d03e9f3d6f2872b8bd972 (patch)
tree8640270aa588400317c2731ffbea77b72b12cfe2 /libffi/ChangeLog
parentdd17274465724f65c09dc2f654d92f6ba92cd90f (diff)
downloadgcc-71d372eba9d83660d02d03e9f3d6f2872b8bd972.zip
gcc-71d372eba9d83660d02d03e9f3d6f2872b8bd972.tar.gz
gcc-71d372eba9d83660d02d03e9f3d6f2872b8bd972.tar.bz2
libffi PowerPC64 ELFv1 fp arg fixes
The ELFv1 ABI says: "Single precision floating point values are mapped to the second word in a single doubleword" and also "Floating point registers f1 through f13 are used consecutively to pass up to 13 floating point values, one member aggregates passed by value containing a floating point value, and to pass complex floating point values". libffi wasn't expecting float args in the second word, and wasn't passing one member aggregates in fp registers. This patch fixes those problems, making use of the existing ELFv2 homogeneous aggregate support since a one element fp struct is a special case of an homogeneous aggregate. I've also set a flag when returning pointers that might be used one day. This is just a tidy since the ppc64 assembly support code currently doesn't test FLAG_RETURNS_64BITS for integer types.. * src/powerpc/ffi_linux64.c (discover_homogeneous_aggregate): Compile for ELFv1 too, handling single element aggregates. (ffi_prep_cif_linux64_core): Call discover_homogeneous_aggregate for ELFv1. Set FLAG_RETURNS_64BITS for FFI_TYPE_POINTER return. (ffi_prep_args64): Call discover_homogeneous_aggregate for ELFv1, and handle single element structs containing float or double as if the element wasn't wrapped in a struct. Store floats in second word of doubleword slot when big-endian. (ffi_closure_helper_LINUX64): Similarly. From-SVN: r259934
Diffstat (limited to 'libffi/ChangeLog')
-rw-r--r--libffi/ChangeLog13
1 files changed, 13 insertions, 0 deletions
diff --git a/libffi/ChangeLog b/libffi/ChangeLog
index eaface5..837b770 100644
--- a/libffi/ChangeLog
+++ b/libffi/ChangeLog
@@ -1,3 +1,16 @@
+2018-05-04 Alan Modra <amodra@gmail.com>
+
+ Import from upstream
+ * src/powerpc/ffi_linux64.c (discover_homogeneous_aggregate):
+ Compile for ELFv1 too, handling single element aggregates.
+ (ffi_prep_cif_linux64_core): Call discover_homogeneous_aggregate
+ for ELFv1. Set FLAG_RETURNS_64BITS for FFI_TYPE_POINTER return.
+ (ffi_prep_args64): Call discover_homogeneous_aggregate for ELFv1,
+ and handle single element structs containing float or double
+ as if the element wasn't wrapped in a struct. Store floats in
+ second word of doubleword slot when big-endian.
+ (ffi_closure_helper_LINUX64): Similarly.
+
2018-04-18 David Malcolm <dmalcolm@redhat.com>
PR jit/85384