# HG changeset patch # User cslag # Date 1450563875 -3600 # Node ID e5cdf4b4d813cc43536eda1d0b58559e96cfb71a # Parent b8f16ad80e347d9224b16d02f55771384ea8cb7a - armhf callback fix for calls with >= 64byte of floating point params where d7 is filled before all args are pushed diff -r b8f16ad80e34 -r e5cdf4b4d813 doc/manual/callconvs/callconv_arm32.tex --- a/doc/manual/callconvs/callconv_arm32.tex Sat Dec 19 16:19:15 2015 +0100 +++ b/doc/manual/callconvs/callconv_arm32.tex Sat Dec 19 23:24:35 2015 +0100 @@ -337,6 +337,7 @@ \item first four non-floating-point words are passed using r0-r3 \item first 16 single-precision, or 8 double-precision arguments are passed via s0-s15 or d0-d7, respectively (note that since s and d registers are aliased, already used ones are skipped) \item subsequent parameters are pushed onto the stack (in right to left order, such that the stack pointer points to the first of the remaining parameters) +\item note that as soon as d7 is used, subsequent single precision floating point parameters are also pushed onto the stack, even if there are still free S* registers \item if the callee takes the address of one of the parameters and uses it to address other parameters (e.g. varargs) it has to copy - in its prolog - the first four words to a reserved stack area adjacent to the other parameters on the stack @@@?check spilling of float args, also \item parameters \textless=\ 32 bits are passed as 32 bit words \item structures and unions are passed by value, with the first four words of the parameters in r0-r3 @@@?check doc diff -r b8f16ad80e34 -r e5cdf4b4d813 dyncallback/dyncall_args_arm32_arm.c --- a/dyncallback/dyncall_args_arm32_arm.c Sat Dec 19 16:19:15 2015 +0100 +++ b/dyncallback/dyncall_args_arm32_arm.c Sat Dec 19 23:24:35 2015 +0100 @@ -94,6 +94,7 @@ args->freg_count = args->dreg_count; return d.d; } + args->freg_count = 16; /* float registers all filled up - stop filling gaps for single precision, also */ #endif arm_align_64(args); d.l[0] = *(DClong*)arm_word(args);