Blame SOURCES/gcc48-rh1469697-1.patch

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