From e6eac7863e2bf1a009ea863041b354bdb4af6b67 Mon Sep 17 00:00:00 2001 From: Gregory Pakosz Date: Tue, 18 Sep 2018 15:19:53 +0200 Subject: [PATCH] Prefix ALIGN_DOWN macro with FFI_ --- include/ffi_common.h | 2 +- src/frv/ffi.c | 2 +- src/metag/ffi.c | 2 +- src/moxie/ffi.c | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/include/ffi_common.h b/include/ffi_common.h index 7fb0a64e..ee9cdcb6 100644 --- a/include/ffi_common.h +++ b/include/ffi_common.h @@ -77,7 +77,7 @@ void ffi_type_test(ffi_type *a, char *file, int line); /* v cast to size_t and aligned up to a multiple of a */ #define FFI_ALIGN(v, a) (((((size_t) (v))-1) | ((a)-1))+1) /* v cast to size_t and aligned down to a multiple of a */ -#define ALIGN_DOWN(v, a) (((size_t) (v)) & -a) +#define FFI_ALIGN_DOWN(v, a) (((size_t) (v)) & -a) /* Perform machine dependent cif processing */ ffi_status ffi_prep_cif_machdep(ffi_cif *cif); diff --git a/src/frv/ffi.c b/src/frv/ffi.c index 62ae6526..ed1c65a1 100644 --- a/src/frv/ffi.c +++ b/src/frv/ffi.c @@ -107,7 +107,7 @@ void *ffi_prep_args(char *stack, extended_cif *ecif) count += z; } - return (stack + ((count > 24) ? 24 : ALIGN_DOWN(count, 8))); + return (stack + ((count > 24) ? 24 : FFI_ALIGN_DOWN(count, 8))); } /* Perform machine dependent cif processing */ diff --git a/src/metag/ffi.c b/src/metag/ffi.c index dfc1e399..3aecb0b8 100644 --- a/src/metag/ffi.c +++ b/src/metag/ffi.c @@ -61,7 +61,7 @@ unsigned int ffi_prep_args(char *stack, extended_cif *ecif) argp -= z; /* Align if necessary */ - argp = (char *) ALIGN_DOWN(ALIGN_DOWN(argp, (*p_arg)->alignment), 4); + argp = (char *) FFI_ALIGN_DOWN(FFI_ALIGN_DOWN(argp, (*p_arg)->alignment), 4); if (z < sizeof(int)) { z = sizeof(int); diff --git a/src/moxie/ffi.c b/src/moxie/ffi.c index 21144e81..16d2bb37 100644 --- a/src/moxie/ffi.c +++ b/src/moxie/ffi.c @@ -100,7 +100,7 @@ void *ffi_prep_args(char *stack, extended_cif *ecif) count += z; } - return (stack + ((count > 24) ? 24 : ALIGN_DOWN(count, 8))); + return (stack + ((count > 24) ? 24 : FFI_ALIGN_DOWN(count, 8))); } /* Perform machine dependent cif processing */