(layout_record): Turn off PCC_BITFIELD_TYPE_MATTERS
authorRichard Stallman <rms@gnu.org>
Tue, 14 Sep 1993 12:13:39 +0000 (12:13 +0000)
committerRichard Stallman <rms@gnu.org>
Tue, 14 Sep 1993 12:13:39 +0000 (12:13 +0000)
rounding of field bitpos, if maximum_field_alignment is nonzero.

From-SVN: r5318

gcc/stor-layout.c

index fb527a3de74c4839888f2436081c8a83281c074d..5504678ff3ab8cba79c6f06bf6268dfc1ceb95da 100644 (file)
@@ -410,15 +410,14 @@ layout_record (rec)
          && TREE_TYPE (field) != error_mark_node
          && DECL_BIT_FIELD_TYPE (field)
          && !DECL_PACKED (field)
+         /* If #pragma pack is in effect, turn off this feature.  */
+         && maximum_field_alignment == 0
          && !integer_zerop (DECL_SIZE (field)))
        {
          int type_align = TYPE_ALIGN (TREE_TYPE (field));
          register tree dsize = DECL_SIZE (field);
          int field_size = TREE_INT_CST_LOW (dsize);
 
-         if (maximum_field_alignment != 0)
-           type_align = MIN (type_align, maximum_field_alignment);
-
          /* A bit field may not span the unit of alignment of its type.
             Advance to next boundary if necessary.  */
          /* ??? There is some uncertainty here as to what