From: Petr Sumbera Date: Sat, 21 Oct 2023 11:42:11 +0000 (+0200) Subject: Fix passing floating point arguments on 64bits SPARC (libffi#778) (#802) X-Git-Tag: upstream/3.4.7~56 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=dd90749505559d38abb339f1a1cd03791a9dc484;p=platform%2Fupstream%2Flibffi.git Fix passing floating point arguments on 64bits SPARC (libffi#778) (#802) --- diff --git a/src/sparc/ffi64.c b/src/sparc/ffi64.c index 5ae43e8..7a9dc32 100644 --- a/src/sparc/ffi64.c +++ b/src/sparc/ffi64.c @@ -382,13 +382,19 @@ ffi_prep_args_v9(ffi_cif *cif, unsigned long *argp, void *rvalue, void **avalue) *argp++ = *(SINT32 *)a; break; case FFI_TYPE_UINT32: - case FFI_TYPE_FLOAT: *argp++ = *(UINT32 *)a; break; case FFI_TYPE_SINT64: case FFI_TYPE_UINT64: case FFI_TYPE_POINTER: + *argp++ = *(UINT64 *)a; + break; + case FFI_TYPE_FLOAT: + flags |= SPARC_FLAG_FP_ARGS; + *argp++ = *(UINT32 *)a; + break; case FFI_TYPE_DOUBLE: + flags |= SPARC_FLAG_FP_ARGS; *argp++ = *(UINT64 *)a; break;