* config/tc-sh.c (align_test_frag_offset_fixed_p): Handle

rs_fill frags.
This commit is contained in:
Kaz Kojima 2007-04-15 22:02:25 +00:00
parent e9043d6669
commit 0838d2ac72
2 changed files with 17 additions and 4 deletions

View File

@ -1,3 +1,8 @@
2007-04-15 Kaz Kojima <kkojima@rr.iij4u.or.jp>
* config/tc-sh.c (align_test_frag_offset_fixed_p): Handle
rs_fill frags.
2007-04-14 Steve Ellcey <sje@cup.hp.com>
* Makefile.am: Add ACLOCAL_AMFLAGS.

View File

@ -847,9 +847,13 @@ align_test_frag_offset_fixed_p (const fragS *frag1, const fragS *frag2,
/* Maybe frag2 is after frag1. */
frag = frag1;
while (frag->fr_type == rs_align_test)
while (frag->fr_type == rs_fill
|| frag->fr_type == rs_align_test)
{
off += frag->fr_fix;
if (frag->fr_type == rs_fill)
off += frag->fr_fix + frag->fr_offset * frag->fr_var;
else
off += frag->fr_fix;
frag = frag->fr_next;
if (frag == NULL)
break;
@ -863,9 +867,13 @@ align_test_frag_offset_fixed_p (const fragS *frag1, const fragS *frag2,
/* Maybe frag1 is after frag2. */
off = frag1->fr_address - frag2->fr_address;
frag = frag2;
while (frag->fr_type == rs_align_test)
while (frag->fr_type == rs_fill
|| frag->fr_type == rs_align_test)
{
off -= frag->fr_fix;
if (frag->fr_type == rs_fill)
off -= frag->fr_fix + frag->fr_offset * frag->fr_var;
else
off -= frag->fr_fix;
frag = frag->fr_next;
if (frag == NULL)
break;