Blame SOURCES/gcc48-rh1469697-1.patch

001c85
2015-10-02  Uros Bizjak  <ubizjak@gmail.com>
001c85
001c85
        * system.h (ROUND_UP): New macro definition.
001c85
        (ROUND_DOWN): Ditto.
001c85
        * ggc-page.c (ROUND_UP): Remove local macro definition.
001c85
        (PAGE_ALIGN): Implement using ROUND_UP macro.
001c85
001c85
2013-08-24  Marc Glisse  <marc.glisse@inria.fr>
001c85
001c85
        PR other/57324
001c85
        * hwint.h (HOST_WIDE_INT_UC, HOST_WIDE_INT_1U, HOST_WIDE_INT_M1,
001c85
        HOST_WIDE_INT_M1U): New macros.
001c85
001c85
001c85
diff --git a/gcc/ggc-page.c b/gcc/ggc-page.c
001c85
index 5b18468439d..4fb41b1112b 100644
001c85
--- a/gcc/ggc-page.c
001c85
+++ b/gcc/ggc-page.c
001c85
@@ -216,10 +216,6 @@ static const size_t extra_order_size_table[] = {
001c85
 
001c85
 #define ROUND_UP_VALUE(x, f) ((f) - 1 - ((f) - 1 + (x)) % (f))
001c85
 
001c85
-/* Compute the smallest multiple of F that is >= X.  */
001c85
-
001c85
-#define ROUND_UP(x, f) (CEIL (x, f) * (f))
001c85
-
001c85
 /* Round X to next multiple of the page size */
001c85
 
001c85
 #define PAGE_ALIGN(x) (((x) + G.pagesize - 1) & ~(G.pagesize - 1))
001c85
diff --git a/gcc/hwint.h b/gcc/hwint.h
001c85
index da62fadcc9e..64b1805345d 100644
001c85
--- a/gcc/hwint.h
001c85
+++ b/gcc/hwint.h
001c85
@@ -76,7 +76,9 @@ extern char sizeof_long_long_must_be_8[sizeof(long long) == 8 ? 1 : -1];
001c85
 # endif
001c85
 #endif
001c85
 
001c85
+#define HOST_WIDE_INT_UC(X) HOST_WIDE_INT_C (X ## U)
001c85
 #define HOST_WIDE_INT_1 HOST_WIDE_INT_C(1)
001c85
+#define HOST_WIDE_INT_1U HOST_WIDE_INT_UC(1)
001c85
 
001c85
 /* This is a magic identifier which allows GCC to figure out the type
001c85
    of HOST_WIDE_INT for %wd specifier checks.  You must issue this
001c85
diff --git a/gcc/system.h b/gcc/system.h
001c85
index 41cd565538a..8230d506fc3 100644
001c85
--- a/gcc/system.h
001c85
+++ b/gcc/system.h
001c85
@@ -348,6 +348,12 @@ extern int errno;
001c85
 /* Returns the least number N such that N * Y >= X.  */
001c85
 #define CEIL(x,y) (((x) + (y) - 1) / (y))
001c85
 
001c85
+/* This macro rounds x up to the y boundary.  */
001c85
+#define ROUND_UP(x,y) (((x) + (y) - 1) & ~((y) - 1))
001c85
+
001c85
+/* This macro rounds x down to the y boundary.  */
001c85
+#define ROUND_DOWN(x,y) ((x) & ~((y) - 1))
001c85
+
001c85
 #ifdef HAVE_SYS_WAIT_H
001c85
 #include <sys/wait.h>
001c85
 #endif