mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-06-22 02:50:08 +08:00
* elf-m10300.c (mn10300_elf_relax_delete_bytes): Do not look for align
relocs when there are no relocs attached to the section.
This commit is contained in:
@ -1,3 +1,8 @@
|
|||||||
|
2007-10-31 Nick Clifton <nickc@redhat.com>
|
||||||
|
|
||||||
|
* elf-m10300.c (mn10300_elf_relax_delete_bytes): Do not look for
|
||||||
|
align relocs when there are no relocs attached to the section.
|
||||||
|
|
||||||
2007-10-31 Alan Modra <amodra@bigpond.net.au>
|
2007-10-31 Alan Modra <amodra@bigpond.net.au>
|
||||||
|
|
||||||
* elf-bfd.h (bfd_elf_match_symbols_in_sections): Don't declare.
|
* elf-bfd.h (bfd_elf_match_symbols_in_sections): Don't declare.
|
||||||
|
@ -1847,6 +1847,8 @@ mn10300_elf_relax_delete_bytes (bfd *abfd,
|
|||||||
irel = elf_section_data (sec)->relocs;
|
irel = elf_section_data (sec)->relocs;
|
||||||
irelend = irel + sec->reloc_count;
|
irelend = irel + sec->reloc_count;
|
||||||
|
|
||||||
|
if (sec->reloc_count > 0)
|
||||||
|
{
|
||||||
/* If there is an align reloc at the end of the section ignore it.
|
/* If there is an align reloc at the end of the section ignore it.
|
||||||
GAS creates these relocs for reasons of its own, and they just
|
GAS creates these relocs for reasons of its own, and they just
|
||||||
serve to keep the section artifically inflated. */
|
serve to keep the section artifically inflated. */
|
||||||
@ -1865,6 +1867,7 @@ mn10300_elf_relax_delete_bytes (bfd *abfd,
|
|||||||
toaddr = irel->r_offset;
|
toaddr = irel->r_offset;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/* Actually delete the bytes. */
|
/* Actually delete the bytes. */
|
||||||
memmove (contents + addr, contents + addr + count,
|
memmove (contents + addr, contents + addr + count,
|
||||||
|
Reference in New Issue
Block a user