This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
fix bug for Xtensa in bfd
- From: Bob Wilson <bwilson at tensilica dot com>
- To: binutils at sources dot redhat dot com
- Date: Tue, 28 Aug 2007 11:45:02 -0700
- Subject: fix bug for Xtensa in bfd
I've committed this patch from David Heine to fix a bug in bfd for linker
relaxation. I'm going to put it on the 2.18 branch, too.
2007-08-28 David Heine <dlheine@tensilica.com>
* elf32-xtensa.c (compute_ebb_actions): Update removed_bytes when
narrowing instructions.
Index: elf32-xtensa.c
===================================================================
RCS file: /cvs/src/src/bfd/elf32-xtensa.c,v
retrieving revision 1.93
diff -u -p -r1.93 elf32-xtensa.c
--- elf32-xtensa.c 18 Jul 2007 21:06:06 -0000 1.93
+++ elf32-xtensa.c 28 Aug 2007 18:21:47 -0000
@@ -6926,6 +6926,8 @@ compute_ebb_actions (ebb_constraint *ebb
bad_alignment = FALSE;
break;
}
+ if (new_action->do_action)
+ removed_bytes += new_action->removed_bytes;
}
if (!bad_alignment)
{