OSDN Git Service

2008-08-05 Andrew Pinski <andrew_pinski@playstation.sony.com>
authorpinskia <pinskia@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 6 Aug 2007 03:24:19 +0000 (03:24 +0000)
committerpinskia <pinskia@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 6 Aug 2007 03:24:19 +0000 (03:24 +0000)
        PR middle-end/32988
        * tree.c (build2_stat): Instead of checking for INTEGER_TYPE, check
        for INTEGRAL_TYPE_P.

2007-08-05  Andrew Pinski  <andrew_pinski@playstation.sony.com>

        PR middle-end/32988
        * gcc.c-torture/compile/pr32988.c: New test.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@127237 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/ChangeLog
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.c-torture/compile/pr32988.c [new file with mode: 0644]
gcc/tree.c

index 3f0d97a..256381b 100644 (file)
@@ -1,3 +1,9 @@
+2008-08-05  Andrew Pinski  <andrew_pinski@playstation.sony.com>
+
+       PR middle-end/32988
+       * tree.c (build2_stat): Instead of checking for INTEGER_TYPE, check
+       for INTEGRAL_TYPE_P.
+
 2008-08-05  Paolo Bonzini  <bonzini@gnu.org>
 
         * configure.ac: Remove --enable-checking=df from default settings.
index 65dc8a7..5324d97 100644 (file)
@@ -1,5 +1,10 @@
 2007-08-05  Andrew Pinski  <andrew_pinski@playstation.sony.com>
 
+       PR middle-end/32988
+       * gcc.c-torture/compile/pr32988.c: New test.
+
+2007-08-05  Andrew Pinski  <andrew_pinski@playstation.sony.com>
+
        * gcc.dg/sms-antideps.c: Add a "return 0" to the end of main.
 
 2007-08-05  Volker Reichelt  <v.reichelt@netcologne.de>
diff --git a/gcc/testsuite/gcc.c-torture/compile/pr32988.c b/gcc/testsuite/gcc.c-torture/compile/pr32988.c
new file mode 100644 (file)
index 0000000..b62004c
--- /dev/null
@@ -0,0 +1,20 @@
+enum zone_type {
+  ZONE_DMA,
+  ZONE_NORMAL,
+  ZONE_MOVABLE,
+  MAX_NR_ZONES
+};
+static unsigned long arch_zone_lowest_possible_pfn[MAX_NR_ZONES];
+static unsigned long arch_zone_highest_possible_pfn[MAX_NR_ZONES];
+void free_area_init_nodes(unsigned long *max_zone_pfn)
+{
+  enum zone_type i;
+  for (i = 1; i < MAX_NR_ZONES; i++)
+  {
+    if (i == ZONE_MOVABLE)
+      continue;
+    unsigned long _x = max_zone_pfn[i];
+    unsigned long _y = arch_zone_lowest_possible_pfn[i];
+    arch_zone_highest_possible_pfn[i] = _x > _y ? _x : _y;
+  }
+}
index f45f71b..c836dc7 100644 (file)
@@ -3077,7 +3077,7 @@ build2_stat (enum tree_code code, tree tt, tree arg0, tree arg1 MEM_STAT_DECL)
 
   if (code == POINTER_PLUS_EXPR && arg0 && arg1 && tt)
     gcc_assert (POINTER_TYPE_P (tt) && POINTER_TYPE_P (TREE_TYPE (arg0))
-               && TREE_CODE (TREE_TYPE (arg1)) == INTEGER_TYPE
+               && INTEGRAL_TYPE_P (TREE_TYPE (arg1))
                && useless_type_conversion_p (sizetype, TREE_TYPE (arg1)));
 
   t = make_node_stat (code PASS_MEM_STAT);