Prefix ALIGN_DOWN macro with FFI_
authorGregory Pakosz <gregory.pakosz@gmail.com>
Tue, 18 Sep 2018 13:19:53 +0000 (15:19 +0200)
committerGregory Pakosz <gregory.pakosz@gmail.com>
Tue, 18 Sep 2018 13:19:53 +0000 (15:19 +0200)
include/ffi_common.h
src/frv/ffi.c
src/metag/ffi.c
src/moxie/ffi.c

index 7fb0a64e9296a2e9989e557ec1ce10d6ec5f990c..ee9cdcb6b153f659c17c1c70719969231d1d24f7 100644 (file)
@@ -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);
index 62ae65263d824c3a071f468fc1128fed7ab9e0f2..ed1c65a1a362b09a8b60af72d0230c04d9afa4eb 100644 (file)
@@ -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 */
index dfc1e399bd77b11e64022210b3fa225174aece31..3aecb0b8115631efdacea339e75a43c3da5b855b 100644 (file)
@@ -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);
index 21144e819d304543a9c78efaa9ddb79dc3af069c..16d2bb37c8eaa19bec89b15cbbcc8ca061050f51 100644 (file)
@@ -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 */