diff options
author | Jakub Jelinek <jakub@redhat.com> | 2003-04-18 14:32:36 +0200 |
---|---|---|
committer | Jakub Jelinek <jakub@gcc.gnu.org> | 2003-04-18 14:32:36 +0200 |
commit | e9b841813c04b7b9ee9d2b30d8fff494ac4aacbf (patch) | |
tree | 6d11613a6465cc0f53789e34009ab2f57cfbaf75 /libffi/include/ffi.h.in | |
parent | 9c594837086fc3e80adfa989de0a494391ff39a6 (diff) | |
download | gcc-e9b841813c04b7b9ee9d2b30d8fff494ac4aacbf.zip gcc-e9b841813c04b7b9ee9d2b30d8fff494ac4aacbf.tar.gz gcc-e9b841813c04b7b9ee9d2b30d8fff494ac4aacbf.tar.bz2 |
configure.in (powerpc64*-*-linux*): Remove.
* configure.in (powerpc64*-*-linux*): Remove.
* configure: Rebuilt.
libffi/
* include/ffi.h.in (POWERPC64): Define if 64-bit.
(enum ffi_abi): Add FFI_LINUX64 on POWERPC.
Make it the default on POWERPC64.
(FFI_TRAMPOLINE_SIZE): Define to 24 on POWERPC64.
* configure.in: Change powerpc-*-linux* into powerpc*-*-linux*.
* configure: Rebuilt.
* src/powerpc/ffi.c (hidden): Define.
(ffi_prep_args_SYSV): Renamed from
ffi_prep_args. Cast pointers to unsigned long to shut up warnings.
(NUM_GPR_ARG_REGISTERS64, NUM_FPR_ARG_REGISTERS64,
ASM_NEEDS_REGISTERS64): New.
(ffi_prep_args64): New function.
(ffi_prep_cif_machdep): Handle FFI_LINUX64 ABI.
(ffi_call): Likewise.
(ffi_prep_closure): Likewise.
(flush_icache): Surround by #ifndef POWERPC64.
(ffi_dblfl): New union type.
(ffi_closure_helper_SYSV): Use it to avoid aliasing problems.
(ffi_closure_helper_LINUX64): New function.
* src/powerpc/ppc_closure.S: Surround whole file by #ifndef
__powerpc64__.
* src/powerpc/sysv.S: Likewise.
(ffi_call_SYSV): Rename ffi_prep_args to ffi_prep_args_SYSV.
* src/powerpc/linux64.S: New file.
* src/powerpc/linux64_closure.S: New file.
* Makefile.am (EXTRA_DIST): Add src/powerpc/linux64.S and
src/powerpc/linux64_closure.S.
(TARGET_SRC_POWERPC): Likewise.
* src/ffitest.c (closure_test_fn, closure_test_fn1, closure_test_fn2,
closure_test_fn3): Fix result printing on big-endian 64-bit
machines.
(main): Print tst2_arg instead of uninitialized tst2_result.
* src/ffitest.c (main): Hide what closure pointer really points to
from the compiler.
From-SVN: r65781
Diffstat (limited to 'libffi/include/ffi.h.in')
-rw-r--r-- | libffi/include/ffi.h.in | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/libffi/include/ffi.h.in b/libffi/include/ffi.h.in index fe91ecd..c51a809 100644 --- a/libffi/include/ffi.h.in +++ b/libffi/include/ffi.h.in @@ -158,6 +158,12 @@ extern "C" { #define SIZEOF_ARG SIZEOF_VOID_P #endif +#ifdef POWERPC +#if defined (__powerpc64__) +#define POWERPC64 +#endif +#endif + #ifdef SPARC #if defined(__arch64__) || defined(__sparcv9) #define SPARC64 @@ -250,7 +256,12 @@ typedef enum ffi_abi { #ifdef POWERPC FFI_SYSV, FFI_GCC_SYSV, + FFI_LINUX64, +# ifdef POWERPC64 + FFI_DEFAULT_ABI = FFI_LINUX64, +# else FFI_DEFAULT_ABI = FFI_GCC_SYSV, +# endif #endif #ifdef POWERPC_AIX @@ -435,7 +446,11 @@ struct ffi_ia64_trampoline_struct { #elif defined(POWERPC) #define FFI_CLOSURES 1 +#ifdef POWERPC64 +#define FFI_TRAMPOLINE_SIZE 24 +#else #define FFI_TRAMPOLINE_SIZE 40 +#endif #define FFI_NATIVE_RAW_API 0 #elif defined(POWERPC_DARWIN) |