diff options
author | zippel <zippel@138bc75d-0d04-0410-961f-82ee72b054a4> | 2007-09-06 23:00:01 +0000 |
---|---|---|
committer | zippel <zippel@138bc75d-0d04-0410-961f-82ee72b054a4> | 2007-09-06 23:00:01 +0000 |
commit | 2be6167d5305821010dcb0be56891b0598cd5186 (patch) | |
tree | ccbc349cc13f7fd295ce205e7e9613249e16e037 /gcc/java/boehm.c | |
parent | 3b4a645facc06b53f3cf958867be10c1daf2d56e (diff) | |
download | gcc-2be6167d5305821010dcb0be56891b0598cd5186.tar.gz |
boehm.c (mark_reference_fields): Move misaligned pointer check
after JREFERENCE_TYPE_P test
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@128208 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/java/boehm.c')
-rw-r--r-- | gcc/java/boehm.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/gcc/java/boehm.c b/gcc/java/boehm.c index c44c6200951..5c65c8bb0cc 100644 --- a/gcc/java/boehm.c +++ b/gcc/java/boehm.c @@ -98,13 +98,6 @@ mark_reference_fields (tree field, offset = int_byte_position (field); size_bytes = int_size_in_bytes (TREE_TYPE (field)); - if (offset % (POINTER_SIZE / BITS_PER_UNIT)) - { - *all_bits_set = -1; - *pointer_after_end = 1; - break; - } - if (JREFERENCE_TYPE_P (TREE_TYPE (field)) /* An `object' of type gnu.gcj.RawData is actually non-Java data. */ @@ -118,6 +111,13 @@ mark_reference_fields (tree field, we already covered, then we are doomed. */ gcc_assert (offset > *last_view_index); + if (offset % (POINTER_SIZE / BITS_PER_UNIT)) + { + *all_bits_set = -1; + *pointer_after_end = 1; + break; + } + count = offset * BITS_PER_UNIT / POINTER_SIZE; size_words = size_bytes * BITS_PER_UNIT / POINTER_SIZE; |