ffi.c (ffi_prep_args_SYSV): Advance intarg_count when a float arguments is passed in memory.

* src/powerpc/ffi.c (ffi_prep_args_SYSV): Advance intarg_count
when a float arguments is passed in memory.
(ffi_closure_helper_SYSV): Mark general registers as used up when
a 64bit or soft-float long double argument is passed in memory.

From-SVN: r155473
This commit is contained in:
Andreas Schwab 2009-12-26 12:40:27 +00:00
parent b8f38e8917
commit 302486f4fb
2 changed files with 184 additions and 174 deletions

View File

@ -1,3 +1,10 @@
2009-12-26 Andreas Schwab <schwab@linux-m68k.org>
* src/powerpc/ffi.c (ffi_prep_args_SYSV): Advance intarg_count
when a float arguments is passed in memory.
(ffi_closure_helper_SYSV): Mark general registers as used up when
a 64bit or soft-float long double argument is passed in memory.
2009-12-25 Matthias Klose <doko@ubuntu.com>
* man/ffi_call.3: Fix #include in examples.

View File

@ -185,6 +185,7 @@ ffi_prep_args_SYSV (extended_cif *ecif, unsigned *const stack)
{
*next_arg.f = (float) double_tmp;
next_arg.u += 1;
intarg_count++;
}
else
*fpr_base.d++ = double_tmp;
@ -1149,6 +1150,7 @@ ffi_closure_helper_SYSV (ffi_closure *closure, void *rvalue,
pst++;
avalue[i] = pst;
pst += 2;
ng = 8;
}
break;
@ -1222,6 +1224,7 @@ ffi_closure_helper_SYSV (ffi_closure *closure, void *rvalue,
{
avalue[i] = pst;
pst += 4;
ng = 8;
}
break;
}