2000-11-15 Kazu Hirata <kazu@hxi.com>
* coff-rs6000.c: Fix formatting. * coff-sh.c: Likewise. * coff-sparc.c: Likewise. * coff-tic30.c: Likewise. * coff-tic54x.c: Likewise. * coff-tic80.c: Likewise. * coff-w65.c: Likewise. * coff-we32k.c: Likewise. * coff-z8k.c: Likewise.
This commit is contained in:
parent
d34802440c
commit
cbfe05c4c6
10 changed files with 96 additions and 121 deletions
|
@ -3,6 +3,14 @@
|
||||||
* coff-arm.c: Fix formatting.
|
* coff-arm.c: Fix formatting.
|
||||||
* coff-ppc.c: Likewise.
|
* coff-ppc.c: Likewise.
|
||||||
* coff-rs6000.c: Likewise.
|
* coff-rs6000.c: Likewise.
|
||||||
|
* coff-sh.c: Likewise.
|
||||||
|
* coff-sparc.c: Likewise.
|
||||||
|
* coff-tic30.c: Likewise.
|
||||||
|
* coff-tic54x.c: Likewise.
|
||||||
|
* coff-tic80.c: Likewise.
|
||||||
|
* coff-w65.c: Likewise.
|
||||||
|
* coff-we32k.c: Likewise.
|
||||||
|
* coff-z8k.c: Likewise.
|
||||||
|
|
||||||
2000-11-15 Richard Henderson <rth@redhat.com>
|
2000-11-15 Richard Henderson <rth@redhat.com>
|
||||||
|
|
||||||
|
|
|
@ -1542,7 +1542,6 @@ normalize_filename (abfd)
|
||||||
|
|
||||||
/* Write out an XCOFF armap. */
|
/* Write out an XCOFF armap. */
|
||||||
|
|
||||||
/*ARGSUSED*/
|
|
||||||
static boolean
|
static boolean
|
||||||
xcoff_write_armap_old (abfd, elength, map, orl_count, stridx)
|
xcoff_write_armap_old (abfd, elength, map, orl_count, stridx)
|
||||||
bfd *abfd;
|
bfd *abfd;
|
||||||
|
@ -1741,7 +1740,6 @@ xcoff_write_one_armap_big (abfd, map, orl_count, orl_ccount, stridx, bits64,
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
/*ARGSUSED*/
|
|
||||||
static boolean
|
static boolean
|
||||||
xcoff_write_armap_big (abfd, elength, map, orl_count, stridx)
|
xcoff_write_armap_big (abfd, elength, map, orl_count, stridx)
|
||||||
bfd *abfd;
|
bfd *abfd;
|
||||||
|
@ -1801,7 +1799,6 @@ xcoff_write_armap_big (abfd, elength, map, orl_count, stridx)
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
/*ARGSUSED*/
|
|
||||||
boolean
|
boolean
|
||||||
_bfd_xcoff_write_armap (abfd, elength, map, orl_count, stridx)
|
_bfd_xcoff_write_armap (abfd, elength, map, orl_count, stridx)
|
||||||
bfd *abfd;
|
bfd *abfd;
|
||||||
|
@ -2345,7 +2342,6 @@ _bfd_xcoff_write_archive_contents (abfd)
|
||||||
/* We can't use the usual coff_sizeof_headers routine, because AIX
|
/* We can't use the usual coff_sizeof_headers routine, because AIX
|
||||||
always uses an a.out header. */
|
always uses an a.out header. */
|
||||||
|
|
||||||
/*ARGSUSED*/
|
|
||||||
int
|
int
|
||||||
_bfd_xcoff_sizeof_headers (abfd, reloc)
|
_bfd_xcoff_sizeof_headers (abfd, reloc)
|
||||||
bfd *abfd;
|
bfd *abfd;
|
||||||
|
@ -2361,5 +2357,3 @@ _bfd_xcoff_sizeof_headers (abfd, reloc)
|
||||||
size += abfd->section_count * SCNHSZ;
|
size += abfd->section_count * SCNHSZ;
|
||||||
return size;
|
return size;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -86,7 +86,6 @@ coff_tic30_select_reloc (howto)
|
||||||
|
|
||||||
#define SELECT_RELOC(x,howto) x.r_type = coff_tic30_select_reloc(howto)
|
#define SELECT_RELOC(x,howto) x.r_type = coff_tic30_select_reloc(howto)
|
||||||
|
|
||||||
|
|
||||||
#define BADMAG(x) TIC30BADMAG(x)
|
#define BADMAG(x) TIC30BADMAG(x)
|
||||||
#define TIC30 1 /* Customize coffcode.h */
|
#define TIC30 1 /* Customize coffcode.h */
|
||||||
#define __A_MAGIC_SET__
|
#define __A_MAGIC_SET__
|
||||||
|
@ -134,7 +133,6 @@ rtype2howto (internal, dst)
|
||||||
#define CALC_ADDEND(abfd, symbol, ext_reloc, cache_ptr) \
|
#define CALC_ADDEND(abfd, symbol, ext_reloc, cache_ptr) \
|
||||||
cache_ptr->addend = ext_reloc.r_offset;
|
cache_ptr->addend = ext_reloc.r_offset;
|
||||||
|
|
||||||
|
|
||||||
#define RELOC_PROCESSING(relent,reloc,symbols,abfd,section) \
|
#define RELOC_PROCESSING(relent,reloc,symbols,abfd,section) \
|
||||||
reloc_processing(relent, reloc, symbols, abfd, section)
|
reloc_processing(relent, reloc, symbols, abfd, section)
|
||||||
|
|
||||||
|
|
|
@ -87,7 +87,6 @@ bfd_ticoff_set_section_load_page (sect, page)
|
||||||
sect->lma = (sect->lma & ADDR_MASK) | PG_TO_FLAG(page);
|
sect->lma = (sect->lma & ADDR_MASK) | PG_TO_FLAG(page);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
int
|
int
|
||||||
bfd_ticoff_get_section_load_page (sect)
|
bfd_ticoff_get_section_load_page (sect)
|
||||||
asection *sect;
|
asection *sect;
|
||||||
|
@ -491,7 +490,6 @@ static CONST bfd_coff_backend_data ticoff1_swap_table =
|
||||||
coff_link_output_has_begun, coff_final_link_postscript
|
coff_link_output_has_begun, coff_final_link_postscript
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
/* TI COFF v0, DOS tools (little-endian headers) */
|
/* TI COFF v0, DOS tools (little-endian headers) */
|
||||||
const bfd_target tic54x_coff0_vec =
|
const bfd_target tic54x_coff0_vec =
|
||||||
{
|
{
|
||||||
|
|
|
@ -42,7 +42,6 @@ static reloc_howto_type howto_table[] =
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
/* Turn a howto into a reloc number */
|
/* Turn a howto into a reloc number */
|
||||||
|
|
||||||
#define SELECT_RELOC(x,howto) \
|
#define SELECT_RELOC(x,howto) \
|
||||||
|
@ -52,7 +51,6 @@ static reloc_howto_type howto_table[] =
|
||||||
#define W65 1 /* Customize coffcode.h */
|
#define W65 1 /* Customize coffcode.h */
|
||||||
#define __A_MAGIC_SET__
|
#define __A_MAGIC_SET__
|
||||||
|
|
||||||
|
|
||||||
/* Code to swap in the reloc */
|
/* Code to swap in the reloc */
|
||||||
#define SWAP_IN_RELOC_OFFSET bfd_h_get_32
|
#define SWAP_IN_RELOC_OFFSET bfd_h_get_32
|
||||||
#define SWAP_OUT_RELOC_OFFSET bfd_h_put_32
|
#define SWAP_OUT_RELOC_OFFSET bfd_h_put_32
|
||||||
|
@ -60,7 +58,6 @@ static reloc_howto_type howto_table[] =
|
||||||
dst->r_stuff[0] = 'S'; \
|
dst->r_stuff[0] = 'S'; \
|
||||||
dst->r_stuff[1] = 'C';
|
dst->r_stuff[1] = 'C';
|
||||||
|
|
||||||
|
|
||||||
static int
|
static int
|
||||||
select_reloc (howto)
|
select_reloc (howto)
|
||||||
reloc_howto_type *howto;
|
reloc_howto_type *howto;
|
||||||
|
@ -81,14 +78,11 @@ rtype2howto (internal, dst)
|
||||||
|
|
||||||
#define RTYPE2HOWTO(internal, relocentry) rtype2howto(internal,relocentry)
|
#define RTYPE2HOWTO(internal, relocentry) rtype2howto(internal,relocentry)
|
||||||
|
|
||||||
|
|
||||||
/* Perform any necessary magic to the addend in a reloc entry */
|
/* Perform any necessary magic to the addend in a reloc entry */
|
||||||
|
|
||||||
|
|
||||||
#define CALC_ADDEND(abfd, symbol, ext_reloc, cache_ptr) \
|
#define CALC_ADDEND(abfd, symbol, ext_reloc, cache_ptr) \
|
||||||
cache_ptr->addend = ext_reloc.r_offset;
|
cache_ptr->addend = ext_reloc.r_offset;
|
||||||
|
|
||||||
|
|
||||||
#define RELOC_PROCESSING(relent,reloc,symbols,abfd,section) \
|
#define RELOC_PROCESSING(relent,reloc,symbols,abfd,section) \
|
||||||
reloc_processing(relent, reloc, symbols, abfd, section)
|
reloc_processing(relent, reloc, symbols, abfd, section)
|
||||||
|
|
||||||
|
@ -112,15 +106,12 @@ reloc_processing (relent, reloc, symbols, abfd, section)
|
||||||
relent->sym_ptr_ptr = (asymbol **)&(bfd_abs_symbol);
|
relent->sym_ptr_ptr = (asymbol **)&(bfd_abs_symbol);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
relent->addend = reloc->r_offset;
|
relent->addend = reloc->r_offset;
|
||||||
|
|
||||||
relent->address -= section->vma;
|
relent->address -= section->vma;
|
||||||
/* relent->section = 0;*/
|
/* relent->section = 0;*/
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
static int
|
static int
|
||||||
h8300_reloc16_estimate(abfd, input_section, reloc, shrink, link_info)
|
h8300_reloc16_estimate(abfd, input_section, reloc, shrink, link_info)
|
||||||
bfd *abfd;
|
bfd *abfd;
|
||||||
|
@ -142,7 +133,6 @@ h8300_reloc16_estimate(abfd, input_section, reloc, shrink, link_info)
|
||||||
|
|
||||||
bfd_vma address = reloc->address - shrink;
|
bfd_vma address = reloc->address - shrink;
|
||||||
|
|
||||||
|
|
||||||
switch (reloc->howto->type)
|
switch (reloc->howto->type)
|
||||||
{
|
{
|
||||||
case R_MOV16B2:
|
case R_MOV16B2:
|
||||||
|
@ -208,7 +198,6 @@ h8300_reloc16_estimate(abfd, input_section, reloc, shrink, link_info)
|
||||||
|
|
||||||
gap = value - (dot - shrink);
|
gap = value - (dot - shrink);
|
||||||
|
|
||||||
|
|
||||||
if (-120 < (long)gap && (long)gap < 120 )
|
if (-120 < (long)gap && (long)gap < 120 )
|
||||||
{
|
{
|
||||||
|
|
||||||
|
@ -224,11 +213,9 @@ h8300_reloc16_estimate(abfd, input_section, reloc, shrink, link_info)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
return shrink;
|
return shrink;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/* First phase of a relaxing link */
|
/* First phase of a relaxing link */
|
||||||
|
|
||||||
/* Reloc types
|
/* Reloc types
|
||||||
|
@ -362,7 +349,6 @@ h8300_reloc16_extra_cases (abfd, link_info, link_order, reloc, data, src_ptr,
|
||||||
+ dst_address
|
+ dst_address
|
||||||
+ link_order->u.indirect.section->output_section->vma;
|
+ link_order->u.indirect.section->output_section->vma;
|
||||||
|
|
||||||
|
|
||||||
/* This wraps within the page, so ignore the relativeness, look at the
|
/* This wraps within the page, so ignore the relativeness, look at the
|
||||||
high part */
|
high part */
|
||||||
if ((gap & 0xf0000) != (dot & 0xf0000)) {
|
if ((gap & 0xf0000) != (dot & 0xf0000)) {
|
||||||
|
@ -394,7 +380,6 @@ h8300_reloc16_extra_cases (abfd, link_info, link_order, reloc, data, src_ptr,
|
||||||
|
|
||||||
#include "coffcode.h"
|
#include "coffcode.h"
|
||||||
|
|
||||||
|
|
||||||
#undef coff_bfd_get_relocated_section_contents
|
#undef coff_bfd_get_relocated_section_contents
|
||||||
#undef coff_bfd_relax_section
|
#undef coff_bfd_relax_section
|
||||||
#define coff_bfd_get_relocated_section_contents \
|
#define coff_bfd_get_relocated_section_contents \
|
||||||
|
|
|
@ -63,13 +63,10 @@ coff_z8k_select_reloc (howto)
|
||||||
|
|
||||||
#define SELECT_RELOC(x,howto) x.r_type = coff_z8k_select_reloc(howto)
|
#define SELECT_RELOC(x,howto) x.r_type = coff_z8k_select_reloc(howto)
|
||||||
|
|
||||||
|
|
||||||
#define BADMAG(x) Z8KBADMAG(x)
|
#define BADMAG(x) Z8KBADMAG(x)
|
||||||
#define Z8K 1 /* Customize coffcode.h */
|
#define Z8K 1 /* Customize coffcode.h */
|
||||||
#define __A_MAGIC_SET__
|
#define __A_MAGIC_SET__
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/* Code to swap in the reloc */
|
/* Code to swap in the reloc */
|
||||||
#define SWAP_IN_RELOC_OFFSET bfd_h_get_32
|
#define SWAP_IN_RELOC_OFFSET bfd_h_get_32
|
||||||
#define SWAP_OUT_RELOC_OFFSET bfd_h_put_32
|
#define SWAP_OUT_RELOC_OFFSET bfd_h_put_32
|
||||||
|
@ -110,14 +107,11 @@ rtype2howto (internal, dst)
|
||||||
|
|
||||||
#define RTYPE2HOWTO(internal, relocentry) rtype2howto(internal,relocentry)
|
#define RTYPE2HOWTO(internal, relocentry) rtype2howto(internal,relocentry)
|
||||||
|
|
||||||
|
|
||||||
/* Perform any necessary magic to the addend in a reloc entry */
|
/* Perform any necessary magic to the addend in a reloc entry */
|
||||||
|
|
||||||
|
|
||||||
#define CALC_ADDEND(abfd, symbol, ext_reloc, cache_ptr) \
|
#define CALC_ADDEND(abfd, symbol, ext_reloc, cache_ptr) \
|
||||||
cache_ptr->addend = ext_reloc.r_offset;
|
cache_ptr->addend = ext_reloc.r_offset;
|
||||||
|
|
||||||
|
|
||||||
#define RELOC_PROCESSING(relent,reloc,symbols,abfd,section) \
|
#define RELOC_PROCESSING(relent,reloc,symbols,abfd,section) \
|
||||||
reloc_processing(relent, reloc, symbols, abfd, section)
|
reloc_processing(relent, reloc, symbols, abfd, section)
|
||||||
|
|
||||||
|
@ -141,7 +135,6 @@ reloc_processing (relent, reloc, symbols, abfd, section)
|
||||||
relent->sym_ptr_ptr = bfd_abs_section_ptr->symbol_ptr_ptr;
|
relent->sym_ptr_ptr = bfd_abs_section_ptr->symbol_ptr_ptr;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
relent->addend = reloc->r_offset;
|
relent->addend = reloc->r_offset;
|
||||||
relent->address -= section->vma;
|
relent->address -= section->vma;
|
||||||
}
|
}
|
||||||
|
@ -230,7 +223,6 @@ extra_case (in_abfd, link_info, link_order, reloc, data, src_ptr, dst_ptr)
|
||||||
|
|
||||||
#include "coffcode.h"
|
#include "coffcode.h"
|
||||||
|
|
||||||
|
|
||||||
#undef coff_bfd_get_relocated_section_contents
|
#undef coff_bfd_get_relocated_section_contents
|
||||||
#undef coff_bfd_relax_section
|
#undef coff_bfd_relax_section
|
||||||
#define coff_bfd_get_relocated_section_contents \
|
#define coff_bfd_get_relocated_section_contents \
|
||||||
|
|
Loading…
Add table
Reference in a new issue