summaryrefslogtreecommitdiff
path: root/gcc/stor-layout.c
diff options
context:
space:
mode:
authorechristo <echristo@138bc75d-0d04-0410-961f-82ee72b054a4>2006-06-12 06:53:33 +0000
committerechristo <echristo@138bc75d-0d04-0410-961f-82ee72b054a4>2006-06-12 06:53:33 +0000
commita6cf93fb3448a97489fe2697862241ccca5ddcdc (patch)
treec0513c3903bf29cecf7de13de3ef79ec15d809aa /gcc/stor-layout.c
parent114d15457a8335a754d75d8754a940d860351821 (diff)
downloadgcc-a6cf93fb3448a97489fe2697862241ccca5ddcdc.tar.gz
2006-06-11 Eric Christopher <echristo@apple.com>
PR middle-end/27948 * stor-layout.c (place_field): Remove check for remaining_in_alignment when aligning at the end of a run. 2006-06-11 Eric Christopher <echristo@apple.com> PR middle-end/27948 * gcc.dg/bf-ms-layout.c: Run on darwin. * gcc.dg/bf-no-ms-layout: Ditto. * gcc.dg/attr-ms_struct-2.c: New. * gcc.dg/bf-ms-layout-2.c: Ditto. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@114562 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/stor-layout.c')
-rw-r--r--gcc/stor-layout.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/gcc/stor-layout.c b/gcc/stor-layout.c
index bf67099bad0..47bc6a047a7 100644
--- a/gcc/stor-layout.c
+++ b/gcc/stor-layout.c
@@ -1070,8 +1070,7 @@ place_field (record_layout_info rli, tree field)
Note: since the beginning of the field was aligned then
of course the end will be too. No round needed. */
- if (!integer_zerop (DECL_SIZE (rli->prev_field))
- && rli->remaining_in_alignment)
+ if (!integer_zerop (DECL_SIZE (rli->prev_field)))
{
rli->bitpos
= size_binop (PLUS_EXPR, rli->bitpos,
@@ -1085,7 +1084,7 @@ place_field (record_layout_info rli, tree field)
/* Cause a new bitfield to be captured, either this time (if
currently a bitfield) or next time we see one. */
if (!DECL_BIT_FIELD_TYPE(field)
- || integer_zerop (DECL_SIZE (field)))
+ || integer_zerop (DECL_SIZE (field)))
rli->prev_field = NULL;
}
@@ -1105,9 +1104,9 @@ place_field (record_layout_info rli, tree field)
there wasn't. */
if (!DECL_BIT_FIELD_TYPE (field)
- || ( prev_saved != NULL
- ? !simple_cst_equal (TYPE_SIZE (type),
- TYPE_SIZE (TREE_TYPE (prev_saved)))
+ || (prev_saved != NULL
+ ? !simple_cst_equal (TYPE_SIZE (type),
+ TYPE_SIZE (TREE_TYPE (prev_saved)))
: !integer_zerop (DECL_SIZE (field)) ))
{
/* Never smaller than a byte for compatibility. */