OSDN Git Service

* expr.c (is_aligning_offset): Check if we are aligning the
authorebotcazou <ebotcazou@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 19 Feb 2004 07:52:51 +0000 (07:52 +0000)
committerebotcazou <ebotcazou@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 19 Feb 2004 07:52:51 +0000 (07:52 +0000)
expressions's address over BIGGEST_ALIGNMENT in bytes, not
in bits.

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

gcc/ChangeLog
gcc/expr.c

index eb59a5e..4f58b58 100644 (file)
@@ -1,3 +1,9 @@
+2004-02-19  Olivier Hainque  <hainque@act-europe.fr>
+
+       * expr.c (is_aligning_offset): Check if we are aligning the
+       expressions's address over BIGGEST_ALIGNMENT in bytes, not
+       in bits.
+
 2003-02-18  Matt Austern  <austern@apple.com>
 
        * gcc.c (LIBGCC_SPEC): If REAL_LIBGCC_SPEC is defined, and
index 223a36b..907d30c 100644 (file)
@@ -9088,7 +9088,8 @@ is_aligning_offset (tree offset, tree exp)
      power of 2 and which is larger than BIGGEST_ALIGNMENT.  */
   if (TREE_CODE (offset) != BIT_AND_EXPR
       || !host_integerp (TREE_OPERAND (offset, 1), 1)
-      || compare_tree_int (TREE_OPERAND (offset, 1), BIGGEST_ALIGNMENT) <= 0
+      || compare_tree_int (TREE_OPERAND (offset, 1), 
+                          BIGGEST_ALIGNMENT / BITS_PER_UNIT) <= 0
       || !exact_log2 (tree_low_cst (TREE_OPERAND (offset, 1), 1) + 1) < 0)
     return 0;