summaryrefslogtreecommitdiff
path: root/libffi/src
diff options
context:
space:
mode:
authoraph <aph@138bc75d-0d04-0410-961f-82ee72b054a4>2004-08-10 14:24:00 +0000
committeraph <aph@138bc75d-0d04-0410-961f-82ee72b054a4>2004-08-10 14:24:00 +0000
commitbb2d2363d217f41dbe419a7d34acaac943d2cbfe (patch)
tree683db4895b4506521633380a196c0c50fe3e5e38 /libffi/src
parenta5646c18d0b5e2c61a85798e386c1650cc610fab (diff)
downloadgcc-bb2d2363d217f41dbe419a7d34acaac943d2cbfe.tar.gz
2004-08-10 Andrew Haley <aph@redhat.com>
* src/x86/ffi64.c (ffi_prep_args ): 8-align all stack arguments. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@85753 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libffi/src')
-rw-r--r--libffi/src/x86/ffi64.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/libffi/src/x86/ffi64.c b/libffi/src/x86/ffi64.c
index 343ee925fde..653d45c243a 100644
--- a/libffi/src/x86/ffi64.c
+++ b/libffi/src/x86/ffi64.c
@@ -341,6 +341,8 @@ ffi_prep_args (stackLayout *stack, extended_cif *ecif)
{
/* Pass this argument in memory. */
argp = (void *)ALIGN(argp, (*p_arg)->alignment);
+ /* Stack arguments are *always* at least 8 byte aligned. */
+ argp = (void *)ALIGN(argp, 8);
memcpy (argp, *p_argv, (*p_arg)->size);
argp += (*p_arg)->size;
}