* object.h (class Relobj): Drop options parameter from
gc_process_relocs, scan_relocs, relocate, do_gc_process_relocs, do_scan_relocs, do_relocate. Change all callers. (class Sized_relobj): Drop options parameters from do_gc_process_relocs, do_scan_relocs, do_relocate, do_relocate_sections, relocate_sections, emit_relocs_scan, emit_relocs_scan_reltype. Change all callers. (struct Relocate_info): Remove options field and all references to it. * reloc.h (class Read_relocs): Remove options constructor parameter and options_ field. Change all callers. (class Gc_process_relocs, class Scan_relocs): Likewise. (class Relocate_task): Likewise. * target-reloc.h (scan_relocs): Remove options parameter. Change all callers. (scan_relocatable_relocs): Likewise. * target.h (class Sized_target): Remove options parameter from gc_process_relocs, scan_relocs, scan_relocatable_relocs. Change all callers. * gc.h (gc_process_relocs): Remove options parameter. Change all callers. * arm.cc: Update functions to remove options parameters. * i386.cc: Likewise. * powerpc.cc: Likewise. * sparc.cc: Likewise. * x86_64.cc: Likewise. * testsuite/testfile.cc: Likewise.
This commit is contained in:
parent
8ffa366761
commit
ad0f2072a6
|
@ -1,3 +1,33 @@
|
||||||
|
2009-10-28 Ian Lance Taylor <iant@google.com>
|
||||||
|
|
||||||
|
* object.h (class Relobj): Drop options parameter from
|
||||||
|
gc_process_relocs, scan_relocs, relocate, do_gc_process_relocs,
|
||||||
|
do_scan_relocs, do_relocate. Change all callers.
|
||||||
|
(class Sized_relobj): Drop options parameters from
|
||||||
|
do_gc_process_relocs, do_scan_relocs, do_relocate,
|
||||||
|
do_relocate_sections, relocate_sections, emit_relocs_scan,
|
||||||
|
emit_relocs_scan_reltype. Change all callers.
|
||||||
|
(struct Relocate_info): Remove options field and all references to
|
||||||
|
it.
|
||||||
|
* reloc.h (class Read_relocs): Remove options constructor
|
||||||
|
parameter and options_ field. Change all callers.
|
||||||
|
(class Gc_process_relocs, class Scan_relocs): Likewise.
|
||||||
|
(class Relocate_task): Likewise.
|
||||||
|
* target-reloc.h (scan_relocs): Remove options parameter. Change
|
||||||
|
all callers.
|
||||||
|
(scan_relocatable_relocs): Likewise.
|
||||||
|
* target.h (class Sized_target): Remove options parameter from
|
||||||
|
gc_process_relocs, scan_relocs, scan_relocatable_relocs. Change
|
||||||
|
all callers.
|
||||||
|
* gc.h (gc_process_relocs): Remove options parameter. Change all
|
||||||
|
callers.
|
||||||
|
* arm.cc: Update functions to remove options parameters.
|
||||||
|
* i386.cc: Likewise.
|
||||||
|
* powerpc.cc: Likewise.
|
||||||
|
* sparc.cc: Likewise.
|
||||||
|
* x86_64.cc: Likewise.
|
||||||
|
* testsuite/testfile.cc: Likewise.
|
||||||
|
|
||||||
2009-10-28 Doug Kwan <dougkwan@google.com>
|
2009-10-28 Doug Kwan <dougkwan@google.com>
|
||||||
|
|
||||||
* arm.cc (Arm_relobj): New class definition.
|
* arm.cc (Arm_relobj): New class definition.
|
||||||
|
|
32
gold/arm.cc
32
gold/arm.cc
|
@ -1092,8 +1092,7 @@ class Target_arm : public Sized_target<32, big_endian>
|
||||||
// Process the relocations to determine unreferenced sections for
|
// Process the relocations to determine unreferenced sections for
|
||||||
// garbage collection.
|
// garbage collection.
|
||||||
void
|
void
|
||||||
gc_process_relocs(const General_options& options,
|
gc_process_relocs(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Sized_relobj<32, big_endian>* object,
|
Sized_relobj<32, big_endian>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
|
@ -1107,8 +1106,7 @@ class Target_arm : public Sized_target<32, big_endian>
|
||||||
|
|
||||||
// Scan the relocations to look for symbol adjustments.
|
// Scan the relocations to look for symbol adjustments.
|
||||||
void
|
void
|
||||||
scan_relocs(const General_options& options,
|
scan_relocs(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Sized_relobj<32, big_endian>* object,
|
Sized_relobj<32, big_endian>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
|
@ -1144,8 +1142,7 @@ class Target_arm : public Sized_target<32, big_endian>
|
||||||
|
|
||||||
// Scan the relocs during a relocatable link.
|
// Scan the relocs during a relocatable link.
|
||||||
void
|
void
|
||||||
scan_relocatable_relocs(const General_options& options,
|
scan_relocatable_relocs(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Sized_relobj<32, big_endian>* object,
|
Sized_relobj<32, big_endian>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
|
@ -1209,8 +1206,7 @@ class Target_arm : public Sized_target<32, big_endian>
|
||||||
{ }
|
{ }
|
||||||
|
|
||||||
inline void
|
inline void
|
||||||
local(const General_options& options, Symbol_table* symtab,
|
local(Symbol_table* symtab, Layout* layout, Target_arm* target,
|
||||||
Layout* layout, Target_arm* target,
|
|
||||||
Sized_relobj<32, big_endian>* object,
|
Sized_relobj<32, big_endian>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
Output_section* output_section,
|
Output_section* output_section,
|
||||||
|
@ -1218,8 +1214,7 @@ class Target_arm : public Sized_target<32, big_endian>
|
||||||
const elfcpp::Sym<32, big_endian>& lsym);
|
const elfcpp::Sym<32, big_endian>& lsym);
|
||||||
|
|
||||||
inline void
|
inline void
|
||||||
global(const General_options& options, Symbol_table* symtab,
|
global(Symbol_table* symtab, Layout* layout, Target_arm* target,
|
||||||
Layout* layout, Target_arm* target,
|
|
||||||
Sized_relobj<32, big_endian>* object,
|
Sized_relobj<32, big_endian>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
Output_section* output_section,
|
Output_section* output_section,
|
||||||
|
@ -3030,7 +3025,6 @@ Arm_relobj<big_endian>::scan_sections_for_stubs(
|
||||||
const Relobj::Output_sections& out_sections(this->output_sections());
|
const Relobj::Output_sections& out_sections(this->output_sections());
|
||||||
|
|
||||||
Relocate_info<32, big_endian> relinfo;
|
Relocate_info<32, big_endian> relinfo;
|
||||||
relinfo.options = ¶meters->options();
|
|
||||||
relinfo.symtab = symtab;
|
relinfo.symtab = symtab;
|
||||||
relinfo.layout = layout;
|
relinfo.layout = layout;
|
||||||
relinfo.object = this;
|
relinfo.object = this;
|
||||||
|
@ -3554,8 +3548,7 @@ Target_arm<big_endian>::Scan::check_non_pic(Relobj* object,
|
||||||
|
|
||||||
template<bool big_endian>
|
template<bool big_endian>
|
||||||
inline void
|
inline void
|
||||||
Target_arm<big_endian>::Scan::local(const General_options&,
|
Target_arm<big_endian>::Scan::local(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Target_arm* target,
|
Target_arm* target,
|
||||||
Sized_relobj<32, big_endian>* object,
|
Sized_relobj<32, big_endian>* object,
|
||||||
|
@ -3682,8 +3675,7 @@ Target_arm<big_endian>::Scan::unsupported_reloc_global(
|
||||||
|
|
||||||
template<bool big_endian>
|
template<bool big_endian>
|
||||||
inline void
|
inline void
|
||||||
Target_arm<big_endian>::Scan::global(const General_options&,
|
Target_arm<big_endian>::Scan::global(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Target_arm* target,
|
Target_arm* target,
|
||||||
Sized_relobj<32, big_endian>* object,
|
Sized_relobj<32, big_endian>* object,
|
||||||
|
@ -3887,8 +3879,7 @@ Target_arm<big_endian>::Scan::global(const General_options&,
|
||||||
|
|
||||||
template<bool big_endian>
|
template<bool big_endian>
|
||||||
void
|
void
|
||||||
Target_arm<big_endian>::gc_process_relocs(const General_options& options,
|
Target_arm<big_endian>::gc_process_relocs(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Sized_relobj<32, big_endian>* object,
|
Sized_relobj<32, big_endian>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
|
@ -3904,7 +3895,6 @@ Target_arm<big_endian>::gc_process_relocs(const General_options& options,
|
||||||
typedef typename Target_arm<big_endian>::Scan Scan;
|
typedef typename Target_arm<big_endian>::Scan Scan;
|
||||||
|
|
||||||
gold::gc_process_relocs<32, big_endian, Arm, elfcpp::SHT_REL, Scan>(
|
gold::gc_process_relocs<32, big_endian, Arm, elfcpp::SHT_REL, Scan>(
|
||||||
options,
|
|
||||||
symtab,
|
symtab,
|
||||||
layout,
|
layout,
|
||||||
this,
|
this,
|
||||||
|
@ -3922,8 +3912,7 @@ Target_arm<big_endian>::gc_process_relocs(const General_options& options,
|
||||||
|
|
||||||
template<bool big_endian>
|
template<bool big_endian>
|
||||||
void
|
void
|
||||||
Target_arm<big_endian>::scan_relocs(const General_options& options,
|
Target_arm<big_endian>::scan_relocs(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Sized_relobj<32, big_endian>* object,
|
Sized_relobj<32, big_endian>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
|
@ -3944,7 +3933,6 @@ Target_arm<big_endian>::scan_relocs(const General_options& options,
|
||||||
}
|
}
|
||||||
|
|
||||||
gold::scan_relocs<32, big_endian, Target_arm, elfcpp::SHT_REL, Scan>(
|
gold::scan_relocs<32, big_endian, Target_arm, elfcpp::SHT_REL, Scan>(
|
||||||
options,
|
|
||||||
symtab,
|
symtab,
|
||||||
layout,
|
layout,
|
||||||
this,
|
this,
|
||||||
|
@ -4499,7 +4487,6 @@ Target_arm<big_endian>::Relocatable_size_for_reloc::get_size_for_reloc(
|
||||||
template<bool big_endian>
|
template<bool big_endian>
|
||||||
void
|
void
|
||||||
Target_arm<big_endian>::scan_relocatable_relocs(
|
Target_arm<big_endian>::scan_relocatable_relocs(
|
||||||
const General_options& options,
|
|
||||||
Symbol_table* symtab,
|
Symbol_table* symtab,
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Sized_relobj<32, big_endian>* object,
|
Sized_relobj<32, big_endian>* object,
|
||||||
|
@ -4520,7 +4507,6 @@ Target_arm<big_endian>::scan_relocatable_relocs(
|
||||||
|
|
||||||
gold::scan_relocatable_relocs<32, big_endian, elfcpp::SHT_REL,
|
gold::scan_relocatable_relocs<32, big_endian, elfcpp::SHT_REL,
|
||||||
Scan_relocatable_relocs>(
|
Scan_relocatable_relocs>(
|
||||||
options,
|
|
||||||
symtab,
|
symtab,
|
||||||
layout,
|
layout,
|
||||||
object,
|
object,
|
||||||
|
|
|
@ -138,7 +138,6 @@ template<int size, bool big_endian, typename Target_type, int sh_type,
|
||||||
typename Scan>
|
typename Scan>
|
||||||
inline void
|
inline void
|
||||||
gc_process_relocs(
|
gc_process_relocs(
|
||||||
const General_options& ,
|
|
||||||
Symbol_table* symtab,
|
Symbol_table* symtab,
|
||||||
Layout*,
|
Layout*,
|
||||||
Target_type* ,
|
Target_type* ,
|
||||||
|
|
17
gold/gold.cc
17
gold/gold.cc
|
@ -229,7 +229,7 @@ queue_initial_tasks(const General_options& options,
|
||||||
|| parameters->options().icf_enabled())
|
|| parameters->options().icf_enabled())
|
||||||
{
|
{
|
||||||
workqueue->queue(new Task_function(new Gc_runner(options,
|
workqueue->queue(new Task_function(new Gc_runner(options,
|
||||||
input_objects,
|
input_objects,
|
||||||
symtab,
|
symtab,
|
||||||
layout,
|
layout,
|
||||||
mapfile),
|
mapfile),
|
||||||
|
@ -273,8 +273,8 @@ queue_middle_gc_tasks(const General_options& options,
|
||||||
{
|
{
|
||||||
// We can read and process the relocations in any order.
|
// We can read and process the relocations in any order.
|
||||||
blocker->add_blocker();
|
blocker->add_blocker();
|
||||||
workqueue->queue(new Read_relocs(options, symtab, layout, *p,
|
workqueue->queue(new Read_relocs(symtab, layout, *p, symtab_lock,
|
||||||
symtab_lock, blocker));
|
blocker));
|
||||||
}
|
}
|
||||||
|
|
||||||
Task_token* this_blocker = new Task_token(true);
|
Task_token* this_blocker = new Task_token(true);
|
||||||
|
@ -485,8 +485,9 @@ queue_middle_tasks(const General_options& options,
|
||||||
++p)
|
++p)
|
||||||
{
|
{
|
||||||
blocker->add_blocker();
|
blocker->add_blocker();
|
||||||
workqueue->queue(new Scan_relocs(options, symtab, layout, *p,
|
workqueue->queue(new Scan_relocs(symtab, layout, *p,
|
||||||
(*p)->get_relocs_data(),symtab_lock, blocker));
|
(*p)->get_relocs_data(),
|
||||||
|
symtab_lock, blocker));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
@ -512,8 +513,8 @@ queue_middle_tasks(const General_options& options,
|
||||||
// relocations. That task will in turn queue a task to wait
|
// relocations. That task will in turn queue a task to wait
|
||||||
// until it can write to the symbol table.
|
// until it can write to the symbol table.
|
||||||
blocker->add_blocker();
|
blocker->add_blocker();
|
||||||
workqueue->queue(new Read_relocs(options, symtab, layout, *p,
|
workqueue->queue(new Read_relocs(symtab, layout, *p, symtab_lock,
|
||||||
symtab_lock, blocker));
|
blocker));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -600,7 +601,7 @@ queue_final_tasks(const General_options& options,
|
||||||
if (input_sections_blocker != NULL)
|
if (input_sections_blocker != NULL)
|
||||||
input_sections_blocker->add_blocker();
|
input_sections_blocker->add_blocker();
|
||||||
final_blocker->add_blocker();
|
final_blocker->add_blocker();
|
||||||
workqueue->queue(new Relocate_task(options, symtab, layout, *p, of,
|
workqueue->queue(new Relocate_task(symtab, layout, *p, of,
|
||||||
input_sections_blocker,
|
input_sections_blocker,
|
||||||
output_sections_blocker,
|
output_sections_blocker,
|
||||||
final_blocker));
|
final_blocker));
|
||||||
|
|
33
gold/i386.cc
33
gold/i386.cc
|
@ -67,8 +67,7 @@ class Target_i386 : public Target_freebsd<32, false>
|
||||||
// Process the relocations to determine unreferenced sections for
|
// Process the relocations to determine unreferenced sections for
|
||||||
// garbage collection.
|
// garbage collection.
|
||||||
void
|
void
|
||||||
gc_process_relocs(const General_options& options,
|
gc_process_relocs(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Sized_relobj<32, false>* object,
|
Sized_relobj<32, false>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
|
@ -82,8 +81,7 @@ class Target_i386 : public Target_freebsd<32, false>
|
||||||
|
|
||||||
// Scan the relocations to look for symbol adjustments.
|
// Scan the relocations to look for symbol adjustments.
|
||||||
void
|
void
|
||||||
scan_relocs(const General_options& options,
|
scan_relocs(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Sized_relobj<32, false>* object,
|
Sized_relobj<32, false>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
|
@ -119,8 +117,7 @@ class Target_i386 : public Target_freebsd<32, false>
|
||||||
|
|
||||||
// Scan the relocs during a relocatable link.
|
// Scan the relocs during a relocatable link.
|
||||||
void
|
void
|
||||||
scan_relocatable_relocs(const General_options& options,
|
scan_relocatable_relocs(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Sized_relobj<32, false>* object,
|
Sized_relobj<32, false>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
|
@ -190,8 +187,7 @@ class Target_i386 : public Target_freebsd<32, false>
|
||||||
struct Scan
|
struct Scan
|
||||||
{
|
{
|
||||||
inline void
|
inline void
|
||||||
local(const General_options& options, Symbol_table* symtab,
|
local(Symbol_table* symtab, Layout* layout, Target_i386* target,
|
||||||
Layout* layout, Target_i386* target,
|
|
||||||
Sized_relobj<32, false>* object,
|
Sized_relobj<32, false>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
Output_section* output_section,
|
Output_section* output_section,
|
||||||
|
@ -199,8 +195,7 @@ class Target_i386 : public Target_freebsd<32, false>
|
||||||
const elfcpp::Sym<32, false>& lsym);
|
const elfcpp::Sym<32, false>& lsym);
|
||||||
|
|
||||||
inline void
|
inline void
|
||||||
global(const General_options& options, Symbol_table* symtab,
|
global(Symbol_table* symtab, Layout* layout, Target_i386* target,
|
||||||
Layout* layout, Target_i386* target,
|
|
||||||
Sized_relobj<32, false>* object,
|
Sized_relobj<32, false>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
Output_section* output_section,
|
Output_section* output_section,
|
||||||
|
@ -884,8 +879,7 @@ Target_i386::Scan::unsupported_reloc_local(Sized_relobj<32, false>* object,
|
||||||
// Scan a relocation for a local symbol.
|
// Scan a relocation for a local symbol.
|
||||||
|
|
||||||
inline void
|
inline void
|
||||||
Target_i386::Scan::local(const General_options&,
|
Target_i386::Scan::local(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Target_i386* target,
|
Target_i386* target,
|
||||||
Sized_relobj<32, false>* object,
|
Sized_relobj<32, false>* object,
|
||||||
|
@ -1175,8 +1169,7 @@ Target_i386::Scan::unsupported_reloc_global(Sized_relobj<32, false>* object,
|
||||||
// Scan a relocation for a global symbol.
|
// Scan a relocation for a global symbol.
|
||||||
|
|
||||||
inline void
|
inline void
|
||||||
Target_i386::Scan::global(const General_options&,
|
Target_i386::Scan::global(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Target_i386* target,
|
Target_i386* target,
|
||||||
Sized_relobj<32, false>* object,
|
Sized_relobj<32, false>* object,
|
||||||
|
@ -1492,8 +1485,7 @@ Target_i386::Scan::global(const General_options&,
|
||||||
// Process relocations for gc.
|
// Process relocations for gc.
|
||||||
|
|
||||||
void
|
void
|
||||||
Target_i386::gc_process_relocs(const General_options& options,
|
Target_i386::gc_process_relocs(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Sized_relobj<32, false>* object,
|
Sized_relobj<32, false>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
|
@ -1507,7 +1499,6 @@ Target_i386::gc_process_relocs(const General_options& options,
|
||||||
{
|
{
|
||||||
gold::gc_process_relocs<32, false, Target_i386, elfcpp::SHT_REL,
|
gold::gc_process_relocs<32, false, Target_i386, elfcpp::SHT_REL,
|
||||||
Target_i386::Scan>(
|
Target_i386::Scan>(
|
||||||
options,
|
|
||||||
symtab,
|
symtab,
|
||||||
layout,
|
layout,
|
||||||
this,
|
this,
|
||||||
|
@ -1524,8 +1515,7 @@ Target_i386::gc_process_relocs(const General_options& options,
|
||||||
// Scan relocations for a section.
|
// Scan relocations for a section.
|
||||||
|
|
||||||
void
|
void
|
||||||
Target_i386::scan_relocs(const General_options& options,
|
Target_i386::scan_relocs(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Sized_relobj<32, false>* object,
|
Sized_relobj<32, false>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
|
@ -1546,7 +1536,6 @@ Target_i386::scan_relocs(const General_options& options,
|
||||||
|
|
||||||
gold::scan_relocs<32, false, Target_i386, elfcpp::SHT_REL,
|
gold::scan_relocs<32, false, Target_i386, elfcpp::SHT_REL,
|
||||||
Target_i386::Scan>(
|
Target_i386::Scan>(
|
||||||
options,
|
|
||||||
symtab,
|
symtab,
|
||||||
layout,
|
layout,
|
||||||
this,
|
this,
|
||||||
|
@ -2537,8 +2526,7 @@ Target_i386::Relocatable_size_for_reloc::get_size_for_reloc(
|
||||||
// Scan the relocs during a relocatable link.
|
// Scan the relocs during a relocatable link.
|
||||||
|
|
||||||
void
|
void
|
||||||
Target_i386::scan_relocatable_relocs(const General_options& options,
|
Target_i386::scan_relocatable_relocs(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Sized_relobj<32, false>* object,
|
Sized_relobj<32, false>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
|
@ -2558,7 +2546,6 @@ Target_i386::scan_relocatable_relocs(const General_options& options,
|
||||||
|
|
||||||
gold::scan_relocatable_relocs<32, false, elfcpp::SHT_REL,
|
gold::scan_relocatable_relocs<32, false, elfcpp::SHT_REL,
|
||||||
Scan_relocatable_relocs>(
|
Scan_relocatable_relocs>(
|
||||||
options,
|
|
||||||
symtab,
|
symtab,
|
||||||
layout,
|
layout,
|
||||||
object,
|
object,
|
||||||
|
|
|
@ -659,15 +659,13 @@ class Relobj : public Object
|
||||||
|
|
||||||
// Process the relocs, during garbage collection only.
|
// Process the relocs, during garbage collection only.
|
||||||
void
|
void
|
||||||
gc_process_relocs(const General_options& options, Symbol_table* symtab,
|
gc_process_relocs(Symbol_table* symtab, Layout* layout, Read_relocs_data* rd)
|
||||||
Layout* layout, Read_relocs_data* rd)
|
{ return this->do_gc_process_relocs(symtab, layout, rd); }
|
||||||
{ return this->do_gc_process_relocs(options, symtab, layout, rd); }
|
|
||||||
|
|
||||||
// Scan the relocs and adjust the symbol table.
|
// Scan the relocs and adjust the symbol table.
|
||||||
void
|
void
|
||||||
scan_relocs(const General_options& options, Symbol_table* symtab,
|
scan_relocs(Symbol_table* symtab, Layout* layout, Read_relocs_data* rd)
|
||||||
Layout* layout, Read_relocs_data* rd)
|
{ return this->do_scan_relocs(symtab, layout, rd); }
|
||||||
{ return this->do_scan_relocs(options, symtab, layout, rd); }
|
|
||||||
|
|
||||||
// The number of local symbols in the input symbol table.
|
// The number of local symbols in the input symbol table.
|
||||||
virtual unsigned int
|
virtual unsigned int
|
||||||
|
@ -701,9 +699,8 @@ class Relobj : public Object
|
||||||
|
|
||||||
// Relocate the input sections and write out the local symbols.
|
// Relocate the input sections and write out the local symbols.
|
||||||
void
|
void
|
||||||
relocate(const General_options& options, const Symbol_table* symtab,
|
relocate(const Symbol_table* symtab, const Layout* layout, Output_file* of)
|
||||||
const Layout* layout, Output_file* of)
|
{ return this->do_relocate(symtab, layout, of); }
|
||||||
{ return this->do_relocate(options, symtab, layout, of); }
|
|
||||||
|
|
||||||
// Return whether an input section is being included in the link.
|
// Return whether an input section is being included in the link.
|
||||||
bool
|
bool
|
||||||
|
@ -790,13 +787,11 @@ class Relobj : public Object
|
||||||
|
|
||||||
// Process the relocs--implemented by child class.
|
// Process the relocs--implemented by child class.
|
||||||
virtual void
|
virtual void
|
||||||
do_gc_process_relocs(const General_options&, Symbol_table*, Layout*,
|
do_gc_process_relocs(Symbol_table*, Layout*, Read_relocs_data*) = 0;
|
||||||
Read_relocs_data*) = 0;
|
|
||||||
|
|
||||||
// Scan the relocs--implemented by child class.
|
// Scan the relocs--implemented by child class.
|
||||||
virtual void
|
virtual void
|
||||||
do_scan_relocs(const General_options&, Symbol_table*, Layout*,
|
do_scan_relocs(Symbol_table*, Layout*, Read_relocs_data*) = 0;
|
||||||
Read_relocs_data*) = 0;
|
|
||||||
|
|
||||||
// Return the number of local symbols--implemented by child class.
|
// Return the number of local symbols--implemented by child class.
|
||||||
virtual unsigned int
|
virtual unsigned int
|
||||||
|
@ -824,8 +819,7 @@ class Relobj : public Object
|
||||||
// Relocate the input sections and write out the local
|
// Relocate the input sections and write out the local
|
||||||
// symbols--implemented by child class.
|
// symbols--implemented by child class.
|
||||||
virtual void
|
virtual void
|
||||||
do_relocate(const General_options& options, const Symbol_table* symtab,
|
do_relocate(const Symbol_table* symtab, const Layout*, Output_file* of) = 0;
|
||||||
const Layout*, Output_file* of) = 0;
|
|
||||||
|
|
||||||
// Get the offset of a section--implemented by child class.
|
// Get the offset of a section--implemented by child class.
|
||||||
virtual uint64_t
|
virtual uint64_t
|
||||||
|
@ -1502,13 +1496,11 @@ class Sized_relobj : public Relobj
|
||||||
// Process the relocs to find list of referenced sections. Used only
|
// Process the relocs to find list of referenced sections. Used only
|
||||||
// during garbage collection.
|
// during garbage collection.
|
||||||
void
|
void
|
||||||
do_gc_process_relocs(const General_options&, Symbol_table*, Layout*,
|
do_gc_process_relocs(Symbol_table*, Layout*, Read_relocs_data*);
|
||||||
Read_relocs_data*);
|
|
||||||
|
|
||||||
// Scan the relocs and adjust the symbol table.
|
// Scan the relocs and adjust the symbol table.
|
||||||
void
|
void
|
||||||
do_scan_relocs(const General_options&, Symbol_table*, Layout*,
|
do_scan_relocs(Symbol_table*, Layout*, Read_relocs_data*);
|
||||||
Read_relocs_data*);
|
|
||||||
|
|
||||||
// Count the local symbols.
|
// Count the local symbols.
|
||||||
void
|
void
|
||||||
|
@ -1529,8 +1521,7 @@ class Sized_relobj : public Relobj
|
||||||
|
|
||||||
// Relocate the input sections and write out the local symbols.
|
// Relocate the input sections and write out the local symbols.
|
||||||
void
|
void
|
||||||
do_relocate(const General_options& options, const Symbol_table* symtab,
|
do_relocate(const Symbol_table* symtab, const Layout*, Output_file* of);
|
||||||
const Layout*, Output_file* of);
|
|
||||||
|
|
||||||
// Get the size of a section.
|
// Get the size of a section.
|
||||||
uint64_t
|
uint64_t
|
||||||
|
@ -1663,8 +1654,7 @@ class Sized_relobj : public Relobj
|
||||||
|
|
||||||
// This may be overriden by a child class.
|
// This may be overriden by a child class.
|
||||||
virtual void
|
virtual void
|
||||||
do_relocate_sections(const General_options& options,
|
do_relocate_sections(const Symbol_table* symtab, const Layout* layout,
|
||||||
const Symbol_table* symtab, const Layout* layout,
|
|
||||||
const unsigned char* pshdrs, Views* pviews);
|
const unsigned char* pshdrs, Views* pviews);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
@ -1728,22 +1718,20 @@ class Sized_relobj : public Relobj
|
||||||
|
|
||||||
// Relocate the sections in the output file.
|
// Relocate the sections in the output file.
|
||||||
void
|
void
|
||||||
relocate_sections(const General_options& options, const Symbol_table* symtab,
|
relocate_sections(const Symbol_table* symtab, const Layout* layout,
|
||||||
const Layout* layout, const unsigned char* pshdrs,
|
const unsigned char* pshdrs, Views* pviews)
|
||||||
Views* pviews)
|
{ this->do_relocate_sections(symtab, layout, pshdrs, pviews); }
|
||||||
{ this->do_relocate_sections(options, symtab, layout, pshdrs, pviews); }
|
|
||||||
|
|
||||||
// Scan the input relocations for --emit-relocs.
|
// Scan the input relocations for --emit-relocs.
|
||||||
void
|
void
|
||||||
emit_relocs_scan(const General_options&, Symbol_table*, Layout*,
|
emit_relocs_scan(Symbol_table*, Layout*, const unsigned char* plocal_syms,
|
||||||
const unsigned char* plocal_syms,
|
|
||||||
const Read_relocs_data::Relocs_list::iterator&);
|
const Read_relocs_data::Relocs_list::iterator&);
|
||||||
|
|
||||||
// Scan the input relocations for --emit-relocs, templatized on the
|
// Scan the input relocations for --emit-relocs, templatized on the
|
||||||
// type of the relocation section.
|
// type of the relocation section.
|
||||||
template<int sh_type>
|
template<int sh_type>
|
||||||
void
|
void
|
||||||
emit_relocs_scan_reltype(const General_options&, Symbol_table*, Layout*,
|
emit_relocs_scan_reltype(Symbol_table*, Layout*,
|
||||||
const unsigned char* plocal_syms,
|
const unsigned char* plocal_syms,
|
||||||
const Read_relocs_data::Relocs_list::iterator&,
|
const Read_relocs_data::Relocs_list::iterator&,
|
||||||
Relocatable_relocs*);
|
Relocatable_relocs*);
|
||||||
|
@ -2005,8 +1993,6 @@ class Input_objects
|
||||||
template<int size, bool big_endian>
|
template<int size, bool big_endian>
|
||||||
struct Relocate_info
|
struct Relocate_info
|
||||||
{
|
{
|
||||||
// Command line options.
|
|
||||||
const General_options* options;
|
|
||||||
// Symbol table.
|
// Symbol table.
|
||||||
const Symbol_table* symtab;
|
const Symbol_table* symtab;
|
||||||
// Layout.
|
// Layout.
|
||||||
|
|
|
@ -65,8 +65,7 @@ class Target_powerpc : public Sized_target<size, big_endian>
|
||||||
// Process the relocations to determine unreferenced sections for
|
// Process the relocations to determine unreferenced sections for
|
||||||
// garbage collection.
|
// garbage collection.
|
||||||
void
|
void
|
||||||
gc_process_relocs(const General_options& options,
|
gc_process_relocs(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Sized_relobj<size, big_endian>* object,
|
Sized_relobj<size, big_endian>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
|
@ -80,8 +79,7 @@ class Target_powerpc : public Sized_target<size, big_endian>
|
||||||
|
|
||||||
// Scan the relocations to look for symbol adjustments.
|
// Scan the relocations to look for symbol adjustments.
|
||||||
void
|
void
|
||||||
scan_relocs(const General_options& options,
|
scan_relocs(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Sized_relobj<size, big_endian>* object,
|
Sized_relobj<size, big_endian>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
|
@ -116,8 +114,7 @@ class Target_powerpc : public Sized_target<size, big_endian>
|
||||||
|
|
||||||
// Scan the relocs during a relocatable link.
|
// Scan the relocs during a relocatable link.
|
||||||
void
|
void
|
||||||
scan_relocatable_relocs(const General_options& options,
|
scan_relocatable_relocs(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Sized_relobj<size, big_endian>* object,
|
Sized_relobj<size, big_endian>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
|
@ -171,8 +168,7 @@ class Target_powerpc : public Sized_target<size, big_endian>
|
||||||
{ }
|
{ }
|
||||||
|
|
||||||
inline void
|
inline void
|
||||||
local(const General_options& options, Symbol_table* symtab,
|
local(Symbol_table* symtab, Layout* layout, Target_powerpc* target,
|
||||||
Layout* layout, Target_powerpc* target,
|
|
||||||
Sized_relobj<size, big_endian>* object,
|
Sized_relobj<size, big_endian>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
Output_section* output_section,
|
Output_section* output_section,
|
||||||
|
@ -180,8 +176,7 @@ class Target_powerpc : public Sized_target<size, big_endian>
|
||||||
const elfcpp::Sym<size, big_endian>& lsym);
|
const elfcpp::Sym<size, big_endian>& lsym);
|
||||||
|
|
||||||
inline void
|
inline void
|
||||||
global(const General_options& options, Symbol_table* symtab,
|
global(Symbol_table* symtab, Layout* layout, Target_powerpc* target,
|
||||||
Layout* layout, Target_powerpc* target,
|
|
||||||
Sized_relobj<size, big_endian>* object,
|
Sized_relobj<size, big_endian>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
Output_section* output_section,
|
Output_section* output_section,
|
||||||
|
@ -1113,7 +1108,6 @@ Target_powerpc<size, big_endian>::Scan::check_non_pic(Relobj* object,
|
||||||
template<int size, bool big_endian>
|
template<int size, bool big_endian>
|
||||||
inline void
|
inline void
|
||||||
Target_powerpc<size, big_endian>::Scan::local(
|
Target_powerpc<size, big_endian>::Scan::local(
|
||||||
const General_options&,
|
|
||||||
Symbol_table* symtab,
|
Symbol_table* symtab,
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Target_powerpc<size, big_endian>* target,
|
Target_powerpc<size, big_endian>* target,
|
||||||
|
@ -1248,7 +1242,6 @@ Target_powerpc<size, big_endian>::Scan::unsupported_reloc_global(
|
||||||
template<int size, bool big_endian>
|
template<int size, bool big_endian>
|
||||||
inline void
|
inline void
|
||||||
Target_powerpc<size, big_endian>::Scan::global(
|
Target_powerpc<size, big_endian>::Scan::global(
|
||||||
const General_options&,
|
|
||||||
Symbol_table* symtab,
|
Symbol_table* symtab,
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Target_powerpc<size, big_endian>* target,
|
Target_powerpc<size, big_endian>* target,
|
||||||
|
@ -1444,7 +1437,6 @@ Target_powerpc<size, big_endian>::Scan::global(
|
||||||
template<int size, bool big_endian>
|
template<int size, bool big_endian>
|
||||||
void
|
void
|
||||||
Target_powerpc<size, big_endian>::gc_process_relocs(
|
Target_powerpc<size, big_endian>::gc_process_relocs(
|
||||||
const General_options& options,
|
|
||||||
Symbol_table* symtab,
|
Symbol_table* symtab,
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Sized_relobj<size, big_endian>* object,
|
Sized_relobj<size, big_endian>* object,
|
||||||
|
@ -1461,7 +1453,6 @@ Target_powerpc<size, big_endian>::gc_process_relocs(
|
||||||
typedef typename Target_powerpc<size, big_endian>::Scan Scan;
|
typedef typename Target_powerpc<size, big_endian>::Scan Scan;
|
||||||
|
|
||||||
gold::gc_process_relocs<size, big_endian, Powerpc, elfcpp::SHT_RELA, Scan>(
|
gold::gc_process_relocs<size, big_endian, Powerpc, elfcpp::SHT_RELA, Scan>(
|
||||||
options,
|
|
||||||
symtab,
|
symtab,
|
||||||
layout,
|
layout,
|
||||||
this,
|
this,
|
||||||
|
@ -1480,7 +1471,6 @@ Target_powerpc<size, big_endian>::gc_process_relocs(
|
||||||
template<int size, bool big_endian>
|
template<int size, bool big_endian>
|
||||||
void
|
void
|
||||||
Target_powerpc<size, big_endian>::scan_relocs(
|
Target_powerpc<size, big_endian>::scan_relocs(
|
||||||
const General_options& options,
|
|
||||||
Symbol_table* symtab,
|
Symbol_table* symtab,
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Sized_relobj<size, big_endian>* object,
|
Sized_relobj<size, big_endian>* object,
|
||||||
|
@ -1523,7 +1513,6 @@ Target_powerpc<size, big_endian>::scan_relocs(
|
||||||
}
|
}
|
||||||
|
|
||||||
gold::scan_relocs<size, big_endian, Powerpc, elfcpp::SHT_RELA, Scan>(
|
gold::scan_relocs<size, big_endian, Powerpc, elfcpp::SHT_RELA, Scan>(
|
||||||
options,
|
|
||||||
symtab,
|
symtab,
|
||||||
layout,
|
layout,
|
||||||
this,
|
this,
|
||||||
|
@ -1897,7 +1886,6 @@ Target_powerpc<size, big_endian>::Relocatable_size_for_reloc::get_size_for_reloc
|
||||||
template<int size, bool big_endian>
|
template<int size, bool big_endian>
|
||||||
void
|
void
|
||||||
Target_powerpc<size, big_endian>::scan_relocatable_relocs(
|
Target_powerpc<size, big_endian>::scan_relocatable_relocs(
|
||||||
const General_options& options,
|
|
||||||
Symbol_table* symtab,
|
Symbol_table* symtab,
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Sized_relobj<size, big_endian>* object,
|
Sized_relobj<size, big_endian>* object,
|
||||||
|
@ -1918,7 +1906,6 @@ Target_powerpc<size, big_endian>::scan_relocatable_relocs(
|
||||||
|
|
||||||
gold::scan_relocatable_relocs<size, big_endian, elfcpp::SHT_RELA,
|
gold::scan_relocatable_relocs<size, big_endian, elfcpp::SHT_RELA,
|
||||||
Scan_relocatable_relocs>(
|
Scan_relocatable_relocs>(
|
||||||
options,
|
|
||||||
symtab,
|
symtab,
|
||||||
layout,
|
layout,
|
||||||
object,
|
object,
|
||||||
|
|
147
gold/reloc.cc
147
gold/reloc.cc
|
@ -72,8 +72,7 @@ Read_relocs::run(Workqueue* workqueue)
|
||||||
if (parameters->options().gc_sections()
|
if (parameters->options().gc_sections()
|
||||||
|| parameters->options().icf_enabled())
|
|| parameters->options().icf_enabled())
|
||||||
{
|
{
|
||||||
workqueue->queue_next(new Gc_process_relocs(this->options_,
|
workqueue->queue_next(new Gc_process_relocs(this->symtab_,
|
||||||
this->symtab_,
|
|
||||||
this->layout_,
|
this->layout_,
|
||||||
this->object_, rd,
|
this->object_, rd,
|
||||||
this->symtab_lock_,
|
this->symtab_lock_,
|
||||||
|
@ -81,8 +80,8 @@ Read_relocs::run(Workqueue* workqueue)
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
workqueue->queue_next(new Scan_relocs(this->options_, this->symtab_,
|
workqueue->queue_next(new Scan_relocs(this->symtab_, this->layout_,
|
||||||
this->layout_, this->object_, rd,
|
this->object_, rd,
|
||||||
this->symtab_lock_,
|
this->symtab_lock_,
|
||||||
this->blocker_));
|
this->blocker_));
|
||||||
}
|
}
|
||||||
|
@ -120,8 +119,7 @@ Gc_process_relocs::locks(Task_locker* tl)
|
||||||
void
|
void
|
||||||
Gc_process_relocs::run(Workqueue*)
|
Gc_process_relocs::run(Workqueue*)
|
||||||
{
|
{
|
||||||
this->object_->gc_process_relocs(this->options_, this->symtab_, this->layout_,
|
this->object_->gc_process_relocs(this->symtab_, this->layout_, this->rd_);
|
||||||
this->rd_);
|
|
||||||
this->object_->release();
|
this->object_->release();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -166,8 +164,7 @@ Scan_relocs::locks(Task_locker* tl)
|
||||||
void
|
void
|
||||||
Scan_relocs::run(Workqueue*)
|
Scan_relocs::run(Workqueue*)
|
||||||
{
|
{
|
||||||
this->object_->scan_relocs(this->options_, this->symtab_, this->layout_,
|
this->object_->scan_relocs(this->symtab_, this->layout_, this->rd_);
|
||||||
this->rd_);
|
|
||||||
this->object_->release();
|
this->object_->release();
|
||||||
delete this->rd_;
|
delete this->rd_;
|
||||||
this->rd_ = NULL;
|
this->rd_ = NULL;
|
||||||
|
@ -216,8 +213,7 @@ Relocate_task::locks(Task_locker* tl)
|
||||||
void
|
void
|
||||||
Relocate_task::run(Workqueue*)
|
Relocate_task::run(Workqueue*)
|
||||||
{
|
{
|
||||||
this->object_->relocate(this->options_, this->symtab_, this->layout_,
|
this->object_->relocate(this->symtab_, this->layout_, this->of_);
|
||||||
this->of_);
|
|
||||||
|
|
||||||
// This is normally the last thing we will do with an object, so
|
// This is normally the last thing we will do with an object, so
|
||||||
// uncache all views.
|
// uncache all views.
|
||||||
|
@ -360,10 +356,9 @@ Sized_relobj<size, big_endian>::do_read_relocs(Read_relocs_data* rd)
|
||||||
|
|
||||||
template<int size, bool big_endian>
|
template<int size, bool big_endian>
|
||||||
void
|
void
|
||||||
Sized_relobj<size, big_endian>::do_gc_process_relocs(const General_options& options,
|
Sized_relobj<size, big_endian>::do_gc_process_relocs(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
Layout* layout,
|
||||||
Layout* layout,
|
Read_relocs_data* rd)
|
||||||
Read_relocs_data* rd)
|
|
||||||
{
|
{
|
||||||
Sized_target<size, big_endian>* target =
|
Sized_target<size, big_endian>* target =
|
||||||
parameters->sized_target<size, big_endian>();
|
parameters->sized_target<size, big_endian>();
|
||||||
|
@ -384,7 +379,7 @@ Sized_relobj<size, big_endian>::do_gc_process_relocs(const General_options& opti
|
||||||
// only scan allocated sections. We may see a non-allocated
|
// only scan allocated sections. We may see a non-allocated
|
||||||
// section here if we are emitting relocs.
|
// section here if we are emitting relocs.
|
||||||
if (p->is_data_section_allocated)
|
if (p->is_data_section_allocated)
|
||||||
target->gc_process_relocs(options, symtab, layout, this,
|
target->gc_process_relocs(symtab, layout, this,
|
||||||
p->data_shndx, p->sh_type,
|
p->data_shndx, p->sh_type,
|
||||||
p->contents->data(), p->reloc_count,
|
p->contents->data(), p->reloc_count,
|
||||||
p->output_section,
|
p->output_section,
|
||||||
|
@ -401,8 +396,7 @@ Sized_relobj<size, big_endian>::do_gc_process_relocs(const General_options& opti
|
||||||
|
|
||||||
template<int size, bool big_endian>
|
template<int size, bool big_endian>
|
||||||
void
|
void
|
||||||
Sized_relobj<size, big_endian>::do_scan_relocs(const General_options& options,
|
Sized_relobj<size, big_endian>::do_scan_relocs(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Read_relocs_data* rd)
|
Read_relocs_data* rd)
|
||||||
{
|
{
|
||||||
|
@ -434,21 +428,21 @@ Sized_relobj<size, big_endian>::do_scan_relocs(const General_options& options,
|
||||||
// only scan allocated sections. We may see a non-allocated
|
// only scan allocated sections. We may see a non-allocated
|
||||||
// section here if we are emitting relocs.
|
// section here if we are emitting relocs.
|
||||||
if (p->is_data_section_allocated)
|
if (p->is_data_section_allocated)
|
||||||
target->scan_relocs(options, symtab, layout, this, p->data_shndx,
|
target->scan_relocs(symtab, layout, this, p->data_shndx,
|
||||||
p->sh_type, p->contents->data(),
|
p->sh_type, p->contents->data(),
|
||||||
p->reloc_count, p->output_section,
|
p->reloc_count, p->output_section,
|
||||||
p->needs_special_offset_handling,
|
p->needs_special_offset_handling,
|
||||||
this->local_symbol_count_,
|
this->local_symbol_count_,
|
||||||
local_symbols);
|
local_symbols);
|
||||||
if (parameters->options().emit_relocs())
|
if (parameters->options().emit_relocs())
|
||||||
this->emit_relocs_scan(options, symtab, layout, local_symbols, p);
|
this->emit_relocs_scan(symtab, layout, local_symbols, p);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
Relocatable_relocs* rr = this->relocatable_relocs(p->reloc_shndx);
|
Relocatable_relocs* rr = this->relocatable_relocs(p->reloc_shndx);
|
||||||
gold_assert(rr != NULL);
|
gold_assert(rr != NULL);
|
||||||
rr->set_reloc_count(p->reloc_count);
|
rr->set_reloc_count(p->reloc_count);
|
||||||
target->scan_relocatable_relocs(options, symtab, layout, this,
|
target->scan_relocatable_relocs(symtab, layout, this,
|
||||||
p->data_shndx, p->sh_type,
|
p->data_shndx, p->sh_type,
|
||||||
p->contents->data(),
|
p->contents->data(),
|
||||||
p->reloc_count,
|
p->reloc_count,
|
||||||
|
@ -510,7 +504,6 @@ class Emit_relocs_strategy
|
||||||
template<int size, bool big_endian>
|
template<int size, bool big_endian>
|
||||||
void
|
void
|
||||||
Sized_relobj<size, big_endian>::emit_relocs_scan(
|
Sized_relobj<size, big_endian>::emit_relocs_scan(
|
||||||
const General_options& options,
|
|
||||||
Symbol_table* symtab,
|
Symbol_table* symtab,
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
const unsigned char* plocal_syms,
|
const unsigned char* plocal_syms,
|
||||||
|
@ -521,14 +514,13 @@ Sized_relobj<size, big_endian>::emit_relocs_scan(
|
||||||
rr->set_reloc_count(p->reloc_count);
|
rr->set_reloc_count(p->reloc_count);
|
||||||
|
|
||||||
if (p->sh_type == elfcpp::SHT_REL)
|
if (p->sh_type == elfcpp::SHT_REL)
|
||||||
this->emit_relocs_scan_reltype<elfcpp::SHT_REL>(options, symtab, layout,
|
this->emit_relocs_scan_reltype<elfcpp::SHT_REL>(symtab, layout,
|
||||||
plocal_syms, p, rr);
|
plocal_syms, p, rr);
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
gold_assert(p->sh_type == elfcpp::SHT_RELA);
|
gold_assert(p->sh_type == elfcpp::SHT_RELA);
|
||||||
this->emit_relocs_scan_reltype<elfcpp::SHT_RELA>(options, symtab,
|
this->emit_relocs_scan_reltype<elfcpp::SHT_RELA>(symtab, layout,
|
||||||
layout, plocal_syms, p,
|
plocal_syms, p, rr);
|
||||||
rr);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -539,7 +531,6 @@ template<int size, bool big_endian>
|
||||||
template<int sh_type>
|
template<int sh_type>
|
||||||
void
|
void
|
||||||
Sized_relobj<size, big_endian>::emit_relocs_scan_reltype(
|
Sized_relobj<size, big_endian>::emit_relocs_scan_reltype(
|
||||||
const General_options& options,
|
|
||||||
Symbol_table* symtab,
|
Symbol_table* symtab,
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
const unsigned char* plocal_syms,
|
const unsigned char* plocal_syms,
|
||||||
|
@ -548,7 +539,6 @@ Sized_relobj<size, big_endian>::emit_relocs_scan_reltype(
|
||||||
{
|
{
|
||||||
scan_relocatable_relocs<size, big_endian, sh_type,
|
scan_relocatable_relocs<size, big_endian, sh_type,
|
||||||
Emit_relocs_strategy<sh_type> >(
|
Emit_relocs_strategy<sh_type> >(
|
||||||
options,
|
|
||||||
symtab,
|
symtab,
|
||||||
layout,
|
layout,
|
||||||
this,
|
this,
|
||||||
|
@ -566,8 +556,7 @@ Sized_relobj<size, big_endian>::emit_relocs_scan_reltype(
|
||||||
|
|
||||||
template<int size, bool big_endian>
|
template<int size, bool big_endian>
|
||||||
void
|
void
|
||||||
Sized_relobj<size, big_endian>::do_relocate(const General_options& options,
|
Sized_relobj<size, big_endian>::do_relocate(const Symbol_table* symtab,
|
||||||
const Symbol_table* symtab,
|
|
||||||
const Layout* layout,
|
const Layout* layout,
|
||||||
Output_file* of)
|
Output_file* of)
|
||||||
{
|
{
|
||||||
|
@ -593,7 +582,7 @@ Sized_relobj<size, big_endian>::do_relocate(const General_options& options,
|
||||||
|
|
||||||
// Apply relocations.
|
// Apply relocations.
|
||||||
|
|
||||||
this->relocate_sections(options, symtab, layout, pshdrs, &views);
|
this->relocate_sections(symtab, layout, pshdrs, &views);
|
||||||
|
|
||||||
// After we've done the relocations, we release the hash tables,
|
// After we've done the relocations, we release the hash tables,
|
||||||
// since we no longer need them.
|
// since we no longer need them.
|
||||||
|
@ -800,7 +789,6 @@ Sized_relobj<size, big_endian>::write_sections(const unsigned char* pshdrs,
|
||||||
template<int size, bool big_endian>
|
template<int size, bool big_endian>
|
||||||
void
|
void
|
||||||
Sized_relobj<size, big_endian>::do_relocate_sections(
|
Sized_relobj<size, big_endian>::do_relocate_sections(
|
||||||
const General_options& options,
|
|
||||||
const Symbol_table* symtab,
|
const Symbol_table* symtab,
|
||||||
const Layout* layout,
|
const Layout* layout,
|
||||||
const unsigned char* pshdrs,
|
const unsigned char* pshdrs,
|
||||||
|
@ -814,7 +802,6 @@ Sized_relobj<size, big_endian>::do_relocate_sections(
|
||||||
const std::vector<Address>& out_offsets(this->section_offsets_);
|
const std::vector<Address>& out_offsets(this->section_offsets_);
|
||||||
|
|
||||||
Relocate_info<size, big_endian> relinfo;
|
Relocate_info<size, big_endian> relinfo;
|
||||||
relinfo.options = &options;
|
|
||||||
relinfo.symtab = symtab;
|
relinfo.symtab = symtab;
|
||||||
relinfo.layout = layout;
|
relinfo.layout = layout;
|
||||||
relinfo.object = this;
|
relinfo.object = this;
|
||||||
|
@ -1431,8 +1418,39 @@ Sized_relobj<64, true>::do_read_relocs(Read_relocs_data* rd);
|
||||||
#ifdef HAVE_TARGET_32_LITTLE
|
#ifdef HAVE_TARGET_32_LITTLE
|
||||||
template
|
template
|
||||||
void
|
void
|
||||||
Sized_relobj<32, false>::do_gc_process_relocs(const General_options& options,
|
Sized_relobj<32, false>::do_gc_process_relocs(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
Layout* layout,
|
||||||
|
Read_relocs_data* rd);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef HAVE_TARGET_32_BIG
|
||||||
|
template
|
||||||
|
void
|
||||||
|
Sized_relobj<32, true>::do_gc_process_relocs(Symbol_table* symtab,
|
||||||
|
Layout* layout,
|
||||||
|
Read_relocs_data* rd);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef HAVE_TARGET_64_LITTLE
|
||||||
|
template
|
||||||
|
void
|
||||||
|
Sized_relobj<64, false>::do_gc_process_relocs(Symbol_table* symtab,
|
||||||
|
Layout* layout,
|
||||||
|
Read_relocs_data* rd);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef HAVE_TARGET_64_BIG
|
||||||
|
template
|
||||||
|
void
|
||||||
|
Sized_relobj<64, true>::do_gc_process_relocs(Symbol_table* symtab,
|
||||||
|
Layout* layout,
|
||||||
|
Read_relocs_data* rd);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef HAVE_TARGET_32_LITTLE
|
||||||
|
template
|
||||||
|
void
|
||||||
|
Sized_relobj<32, false>::do_scan_relocs(Symbol_table* symtab,
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Read_relocs_data* rd);
|
Read_relocs_data* rd);
|
||||||
#endif
|
#endif
|
||||||
|
@ -1440,8 +1458,7 @@ Sized_relobj<32, false>::do_gc_process_relocs(const General_options& options,
|
||||||
#ifdef HAVE_TARGET_32_BIG
|
#ifdef HAVE_TARGET_32_BIG
|
||||||
template
|
template
|
||||||
void
|
void
|
||||||
Sized_relobj<32, true>::do_gc_process_relocs(const General_options& options,
|
Sized_relobj<32, true>::do_scan_relocs(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Read_relocs_data* rd);
|
Read_relocs_data* rd);
|
||||||
#endif
|
#endif
|
||||||
|
@ -1449,8 +1466,7 @@ Sized_relobj<32, true>::do_gc_process_relocs(const General_options& options,
|
||||||
#ifdef HAVE_TARGET_64_LITTLE
|
#ifdef HAVE_TARGET_64_LITTLE
|
||||||
template
|
template
|
||||||
void
|
void
|
||||||
Sized_relobj<64, false>::do_gc_process_relocs(const General_options& options,
|
Sized_relobj<64, false>::do_scan_relocs(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Read_relocs_data* rd);
|
Read_relocs_data* rd);
|
||||||
#endif
|
#endif
|
||||||
|
@ -1458,8 +1474,7 @@ Sized_relobj<64, false>::do_gc_process_relocs(const General_options& options,
|
||||||
#ifdef HAVE_TARGET_64_BIG
|
#ifdef HAVE_TARGET_64_BIG
|
||||||
template
|
template
|
||||||
void
|
void
|
||||||
Sized_relobj<64, true>::do_gc_process_relocs(const General_options& options,
|
Sized_relobj<64, true>::do_scan_relocs(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Read_relocs_data* rd);
|
Read_relocs_data* rd);
|
||||||
#endif
|
#endif
|
||||||
|
@ -1467,44 +1482,7 @@ Sized_relobj<64, true>::do_gc_process_relocs(const General_options& options,
|
||||||
#ifdef HAVE_TARGET_32_LITTLE
|
#ifdef HAVE_TARGET_32_LITTLE
|
||||||
template
|
template
|
||||||
void
|
void
|
||||||
Sized_relobj<32, false>::do_scan_relocs(const General_options& options,
|
Sized_relobj<32, false>::do_relocate(const Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
|
||||||
Read_relocs_data* rd);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef HAVE_TARGET_32_BIG
|
|
||||||
template
|
|
||||||
void
|
|
||||||
Sized_relobj<32, true>::do_scan_relocs(const General_options& options,
|
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
|
||||||
Read_relocs_data* rd);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef HAVE_TARGET_64_LITTLE
|
|
||||||
template
|
|
||||||
void
|
|
||||||
Sized_relobj<64, false>::do_scan_relocs(const General_options& options,
|
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
|
||||||
Read_relocs_data* rd);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef HAVE_TARGET_64_BIG
|
|
||||||
template
|
|
||||||
void
|
|
||||||
Sized_relobj<64, true>::do_scan_relocs(const General_options& options,
|
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
|
||||||
Read_relocs_data* rd);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef HAVE_TARGET_32_LITTLE
|
|
||||||
template
|
|
||||||
void
|
|
||||||
Sized_relobj<32, false>::do_relocate(const General_options& options,
|
|
||||||
const Symbol_table* symtab,
|
|
||||||
const Layout* layout,
|
const Layout* layout,
|
||||||
Output_file* of);
|
Output_file* of);
|
||||||
#endif
|
#endif
|
||||||
|
@ -1512,8 +1490,7 @@ Sized_relobj<32, false>::do_relocate(const General_options& options,
|
||||||
#ifdef HAVE_TARGET_32_BIG
|
#ifdef HAVE_TARGET_32_BIG
|
||||||
template
|
template
|
||||||
void
|
void
|
||||||
Sized_relobj<32, true>::do_relocate(const General_options& options,
|
Sized_relobj<32, true>::do_relocate(const Symbol_table* symtab,
|
||||||
const Symbol_table* symtab,
|
|
||||||
const Layout* layout,
|
const Layout* layout,
|
||||||
Output_file* of);
|
Output_file* of);
|
||||||
#endif
|
#endif
|
||||||
|
@ -1521,8 +1498,7 @@ Sized_relobj<32, true>::do_relocate(const General_options& options,
|
||||||
#ifdef HAVE_TARGET_64_LITTLE
|
#ifdef HAVE_TARGET_64_LITTLE
|
||||||
template
|
template
|
||||||
void
|
void
|
||||||
Sized_relobj<64, false>::do_relocate(const General_options& options,
|
Sized_relobj<64, false>::do_relocate(const Symbol_table* symtab,
|
||||||
const Symbol_table* symtab,
|
|
||||||
const Layout* layout,
|
const Layout* layout,
|
||||||
Output_file* of);
|
Output_file* of);
|
||||||
#endif
|
#endif
|
||||||
|
@ -1530,8 +1506,7 @@ Sized_relobj<64, false>::do_relocate(const General_options& options,
|
||||||
#ifdef HAVE_TARGET_64_BIG
|
#ifdef HAVE_TARGET_64_BIG
|
||||||
template
|
template
|
||||||
void
|
void
|
||||||
Sized_relobj<64, true>::do_relocate(const General_options& options,
|
Sized_relobj<64, true>::do_relocate(const Symbol_table* symtab,
|
||||||
const Symbol_table* symtab,
|
|
||||||
const Layout* layout,
|
const Layout* layout,
|
||||||
Output_file* of);
|
Output_file* of);
|
||||||
#endif
|
#endif
|
||||||
|
@ -1540,7 +1515,6 @@ Sized_relobj<64, true>::do_relocate(const General_options& options,
|
||||||
template
|
template
|
||||||
void
|
void
|
||||||
Sized_relobj<32, false>::do_relocate_sections(
|
Sized_relobj<32, false>::do_relocate_sections(
|
||||||
const General_options& options,
|
|
||||||
const Symbol_table* symtab,
|
const Symbol_table* symtab,
|
||||||
const Layout* layout,
|
const Layout* layout,
|
||||||
const unsigned char* pshdrs,
|
const unsigned char* pshdrs,
|
||||||
|
@ -1551,7 +1525,6 @@ Sized_relobj<32, false>::do_relocate_sections(
|
||||||
template
|
template
|
||||||
void
|
void
|
||||||
Sized_relobj<32, true>::do_relocate_sections(
|
Sized_relobj<32, true>::do_relocate_sections(
|
||||||
const General_options& options,
|
|
||||||
const Symbol_table* symtab,
|
const Symbol_table* symtab,
|
||||||
const Layout* layout,
|
const Layout* layout,
|
||||||
const unsigned char* pshdrs,
|
const unsigned char* pshdrs,
|
||||||
|
@ -1562,7 +1535,6 @@ Sized_relobj<32, true>::do_relocate_sections(
|
||||||
template
|
template
|
||||||
void
|
void
|
||||||
Sized_relobj<64, false>::do_relocate_sections(
|
Sized_relobj<64, false>::do_relocate_sections(
|
||||||
const General_options& options,
|
|
||||||
const Symbol_table* symtab,
|
const Symbol_table* symtab,
|
||||||
const Layout* layout,
|
const Layout* layout,
|
||||||
const unsigned char* pshdrs,
|
const unsigned char* pshdrs,
|
||||||
|
@ -1573,7 +1545,6 @@ Sized_relobj<64, false>::do_relocate_sections(
|
||||||
template
|
template
|
||||||
void
|
void
|
||||||
Sized_relobj<64, true>::do_relocate_sections(
|
Sized_relobj<64, true>::do_relocate_sections(
|
||||||
const General_options& options,
|
|
||||||
const Symbol_table* symtab,
|
const Symbol_table* symtab,
|
||||||
const Layout* layout,
|
const Layout* layout,
|
||||||
const unsigned char* pshdrs,
|
const unsigned char* pshdrs,
|
||||||
|
|
39
gold/reloc.h
39
gold/reloc.h
|
@ -64,10 +64,9 @@ class Read_relocs : public Task
|
||||||
public:
|
public:
|
||||||
// SYMTAB_LOCK is used to lock the symbol table. BLOCKER should be
|
// SYMTAB_LOCK is used to lock the symbol table. BLOCKER should be
|
||||||
// unblocked when the Scan_relocs task completes.
|
// unblocked when the Scan_relocs task completes.
|
||||||
Read_relocs(const General_options& options, Symbol_table* symtab,
|
Read_relocs(Symbol_table* symtab, Layout* layout, Relobj* object,
|
||||||
Layout* layout, Relobj* object, Task_token* symtab_lock,
|
Task_token* symtab_lock, Task_token* blocker)
|
||||||
Task_token* blocker)
|
: symtab_(symtab), layout_(layout), object_(object),
|
||||||
: options_(options), symtab_(symtab), layout_(layout), object_(object),
|
|
||||||
symtab_lock_(symtab_lock), blocker_(blocker)
|
symtab_lock_(symtab_lock), blocker_(blocker)
|
||||||
{ }
|
{ }
|
||||||
|
|
||||||
|
@ -86,7 +85,6 @@ class Read_relocs : public Task
|
||||||
get_name() const;
|
get_name() const;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
const General_options& options_;
|
|
||||||
Symbol_table* symtab_;
|
Symbol_table* symtab_;
|
||||||
Layout* layout_;
|
Layout* layout_;
|
||||||
Relobj* object_;
|
Relobj* object_;
|
||||||
|
@ -102,11 +100,11 @@ class Gc_process_relocs : public Task
|
||||||
public:
|
public:
|
||||||
// SYMTAB_LOCK is used to lock the symbol table. BLOCKER should be
|
// SYMTAB_LOCK is used to lock the symbol table. BLOCKER should be
|
||||||
// unblocked when the task completes.
|
// unblocked when the task completes.
|
||||||
Gc_process_relocs(const General_options& options, Symbol_table* symtab,
|
Gc_process_relocs(Symbol_table* symtab, Layout* layout, Relobj* object,
|
||||||
Layout* layout, Relobj* object, Read_relocs_data* rd,
|
Read_relocs_data* rd, Task_token* symtab_lock,
|
||||||
Task_token* symtab_lock, Task_token* blocker)
|
Task_token* blocker)
|
||||||
: options_(options), symtab_(symtab), layout_(layout), object_(object),
|
: symtab_(symtab), layout_(layout), object_(object), rd_(rd),
|
||||||
rd_(rd), symtab_lock_(symtab_lock), blocker_(blocker)
|
symtab_lock_(symtab_lock), blocker_(blocker)
|
||||||
{ }
|
{ }
|
||||||
|
|
||||||
// The standard Task methods.
|
// The standard Task methods.
|
||||||
|
@ -124,7 +122,6 @@ class Gc_process_relocs : public Task
|
||||||
get_name() const;
|
get_name() const;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
const General_options& options_;
|
|
||||||
Symbol_table* symtab_;
|
Symbol_table* symtab_;
|
||||||
Layout* layout_;
|
Layout* layout_;
|
||||||
Relobj* object_;
|
Relobj* object_;
|
||||||
|
@ -141,11 +138,11 @@ class Scan_relocs : public Task
|
||||||
public:
|
public:
|
||||||
// SYMTAB_LOCK is used to lock the symbol table. BLOCKER should be
|
// SYMTAB_LOCK is used to lock the symbol table. BLOCKER should be
|
||||||
// unblocked when the task completes.
|
// unblocked when the task completes.
|
||||||
Scan_relocs(const General_options& options, Symbol_table* symtab,
|
Scan_relocs(Symbol_table* symtab, Layout* layout, Relobj* object,
|
||||||
Layout* layout, Relobj* object, Read_relocs_data* rd,
|
Read_relocs_data* rd, Task_token* symtab_lock,
|
||||||
Task_token* symtab_lock, Task_token* blocker)
|
Task_token* blocker)
|
||||||
: options_(options), symtab_(symtab), layout_(layout), object_(object),
|
: symtab_(symtab), layout_(layout), object_(object), rd_(rd),
|
||||||
rd_(rd), symtab_lock_(symtab_lock), blocker_(blocker)
|
symtab_lock_(symtab_lock), blocker_(blocker)
|
||||||
{ }
|
{ }
|
||||||
|
|
||||||
// The standard Task methods.
|
// The standard Task methods.
|
||||||
|
@ -163,7 +160,6 @@ class Scan_relocs : public Task
|
||||||
get_name() const;
|
get_name() const;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
const General_options& options_;
|
|
||||||
Symbol_table* symtab_;
|
Symbol_table* symtab_;
|
||||||
Layout* layout_;
|
Layout* layout_;
|
||||||
Relobj* object_;
|
Relobj* object_;
|
||||||
|
@ -177,12 +173,12 @@ class Scan_relocs : public Task
|
||||||
class Relocate_task : public Task
|
class Relocate_task : public Task
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
Relocate_task(const General_options& options, const Symbol_table* symtab,
|
Relocate_task(const Symbol_table* symtab, const Layout* layout,
|
||||||
const Layout* layout, Relobj* object, Output_file* of,
|
Relobj* object, Output_file* of,
|
||||||
Task_token* input_sections_blocker,
|
Task_token* input_sections_blocker,
|
||||||
Task_token* output_sections_blocker, Task_token* final_blocker)
|
Task_token* output_sections_blocker, Task_token* final_blocker)
|
||||||
: options_(options), symtab_(symtab), layout_(layout), object_(object),
|
: symtab_(symtab), layout_(layout), object_(object), of_(of),
|
||||||
of_(of), input_sections_blocker_(input_sections_blocker),
|
input_sections_blocker_(input_sections_blocker),
|
||||||
output_sections_blocker_(output_sections_blocker),
|
output_sections_blocker_(output_sections_blocker),
|
||||||
final_blocker_(final_blocker)
|
final_blocker_(final_blocker)
|
||||||
{ }
|
{ }
|
||||||
|
@ -202,7 +198,6 @@ class Relocate_task : public Task
|
||||||
get_name() const;
|
get_name() const;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
const General_options& options_;
|
|
||||||
const Symbol_table* symtab_;
|
const Symbol_table* symtab_;
|
||||||
const Layout* layout_;
|
const Layout* layout_;
|
||||||
Relobj* object_;
|
Relobj* object_;
|
||||||
|
|
|
@ -67,8 +67,7 @@ class Target_sparc : public Sized_target<size, big_endian>
|
||||||
// Process the relocations to determine unreferenced sections for
|
// Process the relocations to determine unreferenced sections for
|
||||||
// garbage collection.
|
// garbage collection.
|
||||||
void
|
void
|
||||||
gc_process_relocs(const General_options& options,
|
gc_process_relocs(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Sized_relobj<size, big_endian>* object,
|
Sized_relobj<size, big_endian>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
|
@ -82,8 +81,7 @@ class Target_sparc : public Sized_target<size, big_endian>
|
||||||
|
|
||||||
// Scan the relocations to look for symbol adjustments.
|
// Scan the relocations to look for symbol adjustments.
|
||||||
void
|
void
|
||||||
scan_relocs(const General_options& options,
|
scan_relocs(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Sized_relobj<size, big_endian>* object,
|
Sized_relobj<size, big_endian>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
|
@ -118,8 +116,7 @@ class Target_sparc : public Sized_target<size, big_endian>
|
||||||
|
|
||||||
// Scan the relocs during a relocatable link.
|
// Scan the relocs during a relocatable link.
|
||||||
void
|
void
|
||||||
scan_relocatable_relocs(const General_options& options,
|
scan_relocatable_relocs(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Sized_relobj<size, big_endian>* object,
|
Sized_relobj<size, big_endian>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
|
@ -181,8 +178,7 @@ class Target_sparc : public Sized_target<size, big_endian>
|
||||||
{ }
|
{ }
|
||||||
|
|
||||||
inline void
|
inline void
|
||||||
local(const General_options& options, Symbol_table* symtab,
|
local(Symbol_table* symtab, Layout* layout, Target_sparc* target,
|
||||||
Layout* layout, Target_sparc* target,
|
|
||||||
Sized_relobj<size, big_endian>* object,
|
Sized_relobj<size, big_endian>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
Output_section* output_section,
|
Output_section* output_section,
|
||||||
|
@ -190,8 +186,7 @@ class Target_sparc : public Sized_target<size, big_endian>
|
||||||
const elfcpp::Sym<size, big_endian>& lsym);
|
const elfcpp::Sym<size, big_endian>& lsym);
|
||||||
|
|
||||||
inline void
|
inline void
|
||||||
global(const General_options& options, Symbol_table* symtab,
|
global(Symbol_table* symtab, Layout* layout, Target_sparc* target,
|
||||||
Layout* layout, Target_sparc* target,
|
|
||||||
Sized_relobj<size, big_endian>* object,
|
Sized_relobj<size, big_endian>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
Output_section* output_section,
|
Output_section* output_section,
|
||||||
|
@ -1600,7 +1595,6 @@ Target_sparc<size, big_endian>::Scan::check_non_pic(Relobj* object, unsigned int
|
||||||
template<int size, bool big_endian>
|
template<int size, bool big_endian>
|
||||||
inline void
|
inline void
|
||||||
Target_sparc<size, big_endian>::Scan::local(
|
Target_sparc<size, big_endian>::Scan::local(
|
||||||
const General_options&,
|
|
||||||
Symbol_table* symtab,
|
Symbol_table* symtab,
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Target_sparc<size, big_endian>* target,
|
Target_sparc<size, big_endian>* target,
|
||||||
|
@ -1902,7 +1896,6 @@ Target_sparc<size, big_endian>::Scan::unsupported_reloc_global(
|
||||||
template<int size, bool big_endian>
|
template<int size, bool big_endian>
|
||||||
inline void
|
inline void
|
||||||
Target_sparc<size, big_endian>::Scan::global(
|
Target_sparc<size, big_endian>::Scan::global(
|
||||||
const General_options&,
|
|
||||||
Symbol_table* symtab,
|
Symbol_table* symtab,
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Target_sparc<size, big_endian>* target,
|
Target_sparc<size, big_endian>* target,
|
||||||
|
@ -2250,7 +2243,6 @@ Target_sparc<size, big_endian>::Scan::global(
|
||||||
template<int size, bool big_endian>
|
template<int size, bool big_endian>
|
||||||
void
|
void
|
||||||
Target_sparc<size, big_endian>::gc_process_relocs(
|
Target_sparc<size, big_endian>::gc_process_relocs(
|
||||||
const General_options& options,
|
|
||||||
Symbol_table* symtab,
|
Symbol_table* symtab,
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Sized_relobj<size, big_endian>* object,
|
Sized_relobj<size, big_endian>* object,
|
||||||
|
@ -2267,7 +2259,6 @@ Target_sparc<size, big_endian>::gc_process_relocs(
|
||||||
typedef typename Target_sparc<size, big_endian>::Scan Scan;
|
typedef typename Target_sparc<size, big_endian>::Scan Scan;
|
||||||
|
|
||||||
gold::gc_process_relocs<size, big_endian, Sparc, elfcpp::SHT_RELA, Scan>(
|
gold::gc_process_relocs<size, big_endian, Sparc, elfcpp::SHT_RELA, Scan>(
|
||||||
options,
|
|
||||||
symtab,
|
symtab,
|
||||||
layout,
|
layout,
|
||||||
this,
|
this,
|
||||||
|
@ -2286,7 +2277,6 @@ Target_sparc<size, big_endian>::gc_process_relocs(
|
||||||
template<int size, bool big_endian>
|
template<int size, bool big_endian>
|
||||||
void
|
void
|
||||||
Target_sparc<size, big_endian>::scan_relocs(
|
Target_sparc<size, big_endian>::scan_relocs(
|
||||||
const General_options& options,
|
|
||||||
Symbol_table* symtab,
|
Symbol_table* symtab,
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Sized_relobj<size, big_endian>* object,
|
Sized_relobj<size, big_endian>* object,
|
||||||
|
@ -2310,7 +2300,6 @@ Target_sparc<size, big_endian>::scan_relocs(
|
||||||
}
|
}
|
||||||
|
|
||||||
gold::scan_relocs<size, big_endian, Sparc, elfcpp::SHT_RELA, Scan>(
|
gold::scan_relocs<size, big_endian, Sparc, elfcpp::SHT_RELA, Scan>(
|
||||||
options,
|
|
||||||
symtab,
|
symtab,
|
||||||
layout,
|
layout,
|
||||||
this,
|
this,
|
||||||
|
@ -3149,7 +3138,6 @@ Target_sparc<size, big_endian>::Relocatable_size_for_reloc::get_size_for_reloc(
|
||||||
template<int size, bool big_endian>
|
template<int size, bool big_endian>
|
||||||
void
|
void
|
||||||
Target_sparc<size, big_endian>::scan_relocatable_relocs(
|
Target_sparc<size, big_endian>::scan_relocatable_relocs(
|
||||||
const General_options& options,
|
|
||||||
Symbol_table* symtab,
|
Symbol_table* symtab,
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Sized_relobj<size, big_endian>* object,
|
Sized_relobj<size, big_endian>* object,
|
||||||
|
@ -3170,7 +3158,6 @@ Target_sparc<size, big_endian>::scan_relocatable_relocs(
|
||||||
|
|
||||||
gold::scan_relocatable_relocs<size, big_endian, elfcpp::SHT_RELA,
|
gold::scan_relocatable_relocs<size, big_endian, elfcpp::SHT_RELA,
|
||||||
Scan_relocatable_relocs>(
|
Scan_relocatable_relocs>(
|
||||||
options,
|
|
||||||
symtab,
|
symtab,
|
||||||
layout,
|
layout,
|
||||||
object,
|
object,
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
// target-reloc.h -- target specific relocation support -*- C++ -*-
|
// target-reloc.h -- target specific relocation support -*- C++ -*-
|
||||||
|
|
||||||
// Copyright 2006, 2007, 2008 Free Software Foundation, Inc.
|
// Copyright 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
|
||||||
// Written by Ian Lance Taylor <iant@google.com>.
|
// Written by Ian Lance Taylor <iant@google.com>.
|
||||||
|
|
||||||
// This file is part of gold.
|
// This file is part of gold.
|
||||||
|
@ -43,7 +43,6 @@ template<int size, bool big_endian, typename Target_type, int sh_type,
|
||||||
typename Scan>
|
typename Scan>
|
||||||
inline void
|
inline void
|
||||||
scan_relocs(
|
scan_relocs(
|
||||||
const General_options& options,
|
|
||||||
Symbol_table* symtab,
|
Symbol_table* symtab,
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Target_type* target,
|
Target_type* target,
|
||||||
|
@ -104,7 +103,7 @@ scan_relocs(
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
scan.local(options, symtab, layout, target, object, data_shndx,
|
scan.local(symtab, layout, target, object, data_shndx,
|
||||||
output_section, reloc, r_type, lsym);
|
output_section, reloc, r_type, lsym);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
@ -114,7 +113,7 @@ scan_relocs(
|
||||||
if (gsym->is_forwarder())
|
if (gsym->is_forwarder())
|
||||||
gsym = symtab->resolve_forwards(gsym);
|
gsym = symtab->resolve_forwards(gsym);
|
||||||
|
|
||||||
scan.global(options, symtab, layout, target, object, data_shndx,
|
scan.global(symtab, layout, target, object, data_shndx,
|
||||||
output_section, reloc, r_type, gsym);
|
output_section, reloc, r_type, gsym);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -384,7 +383,6 @@ template<int size, bool big_endian, int sh_type,
|
||||||
typename Scan_relocatable_reloc>
|
typename Scan_relocatable_reloc>
|
||||||
void
|
void
|
||||||
scan_relocatable_relocs(
|
scan_relocatable_relocs(
|
||||||
const General_options&,
|
|
||||||
Symbol_table*,
|
Symbol_table*,
|
||||||
Layout*,
|
Layout*,
|
||||||
Sized_relobj<size, big_endian>* object,
|
Sized_relobj<size, big_endian>* object,
|
||||||
|
|
|
@ -41,7 +41,6 @@
|
||||||
namespace gold
|
namespace gold
|
||||||
{
|
{
|
||||||
|
|
||||||
class General_options;
|
|
||||||
class Object;
|
class Object;
|
||||||
class Relobj;
|
class Relobj;
|
||||||
template<int size, bool big_endian>
|
template<int size, bool big_endian>
|
||||||
|
@ -467,34 +466,32 @@ class Sized_target : public Target
|
||||||
// used to determine unreferenced garbage sections. This procedure is
|
// used to determine unreferenced garbage sections. This procedure is
|
||||||
// only called during garbage collection.
|
// only called during garbage collection.
|
||||||
virtual void
|
virtual void
|
||||||
gc_process_relocs(const General_options& options,
|
gc_process_relocs(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
Layout* layout,
|
||||||
Layout* layout,
|
Sized_relobj<size, big_endian>* object,
|
||||||
Sized_relobj<size, big_endian>* object,
|
unsigned int data_shndx,
|
||||||
unsigned int data_shndx,
|
unsigned int sh_type,
|
||||||
unsigned int sh_type,
|
const unsigned char* prelocs,
|
||||||
const unsigned char* prelocs,
|
size_t reloc_count,
|
||||||
size_t reloc_count,
|
Output_section* output_section,
|
||||||
Output_section* output_section,
|
bool needs_special_offset_handling,
|
||||||
bool needs_special_offset_handling,
|
size_t local_symbol_count,
|
||||||
size_t local_symbol_count,
|
const unsigned char* plocal_symbols) = 0;
|
||||||
const unsigned char* plocal_symbols) = 0;
|
|
||||||
|
|
||||||
// Scan the relocs for a section, and record any information
|
// Scan the relocs for a section, and record any information
|
||||||
// required for the symbol. OPTIONS is the command line options.
|
// required for the symbol. SYMTAB is the symbol table. OBJECT is
|
||||||
// SYMTAB is the symbol table. OBJECT is the object in which the
|
// the object in which the section appears. DATA_SHNDX is the
|
||||||
// section appears. DATA_SHNDX is the section index that these
|
// section index that these relocs apply to. SH_TYPE is the type of
|
||||||
// relocs apply to. SH_TYPE is the type of the relocation section,
|
// the relocation section, SHT_REL or SHT_RELA. PRELOCS points to
|
||||||
// SHT_REL or SHT_RELA. PRELOCS points to the relocation data.
|
// the relocation data. RELOC_COUNT is the number of relocs.
|
||||||
// RELOC_COUNT is the number of relocs. LOCAL_SYMBOL_COUNT is the
|
// LOCAL_SYMBOL_COUNT is the number of local symbols.
|
||||||
// number of local symbols. OUTPUT_SECTION is the output section.
|
// OUTPUT_SECTION is the output section.
|
||||||
// NEEDS_SPECIAL_OFFSET_HANDLING is true if offsets to the output
|
// NEEDS_SPECIAL_OFFSET_HANDLING is true if offsets to the output
|
||||||
// sections are not mapped as usual. PLOCAL_SYMBOLS points to the
|
// sections are not mapped as usual. PLOCAL_SYMBOLS points to the
|
||||||
// local symbol data from OBJECT. GLOBAL_SYMBOLS is the array of
|
// local symbol data from OBJECT. GLOBAL_SYMBOLS is the array of
|
||||||
// pointers to the global symbol table from OBJECT.
|
// pointers to the global symbol table from OBJECT.
|
||||||
virtual void
|
virtual void
|
||||||
scan_relocs(const General_options& options,
|
scan_relocs(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Sized_relobj<size, big_endian>* object,
|
Sized_relobj<size, big_endian>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
|
@ -533,8 +530,7 @@ class Sized_target : public Target
|
||||||
// like scan_relocs, with an additional Relocatable_relocs
|
// like scan_relocs, with an additional Relocatable_relocs
|
||||||
// parameter, used to record the disposition of the relocs.
|
// parameter, used to record the disposition of the relocs.
|
||||||
virtual void
|
virtual void
|
||||||
scan_relocatable_relocs(const General_options& options,
|
scan_relocatable_relocs(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Sized_relobj<size, big_endian>* object,
|
Sized_relobj<size, big_endian>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
|
|
|
@ -44,17 +44,15 @@ class Target_test : public Sized_target<size, big_endian>
|
||||||
{ }
|
{ }
|
||||||
|
|
||||||
void
|
void
|
||||||
gc_process_relocs(const General_options&, Symbol_table*, Layout*,
|
gc_process_relocs(Symbol_table*, Layout*, Sized_relobj<size, big_endian>*,
|
||||||
Sized_relobj<size, big_endian>*, unsigned int,
|
unsigned int, unsigned int, const unsigned char*, size_t,
|
||||||
unsigned int, const unsigned char*, size_t, Output_section*,
|
Output_section*, bool, size_t, const unsigned char*)
|
||||||
bool, size_t, const unsigned char*)
|
|
||||||
{ ERROR("call to Target_test::gc_process_relocs"); }
|
{ ERROR("call to Target_test::gc_process_relocs"); }
|
||||||
|
|
||||||
void
|
void
|
||||||
scan_relocs(const General_options&, Symbol_table*, Layout*,
|
scan_relocs(Symbol_table*, Layout*, Sized_relobj<size, big_endian>*,
|
||||||
Sized_relobj<size, big_endian>*, unsigned int,
|
unsigned int, unsigned int, const unsigned char*, size_t,
|
||||||
unsigned int, const unsigned char*, size_t, Output_section*,
|
Output_section*, bool, size_t, const unsigned char*)
|
||||||
bool, size_t, const unsigned char*)
|
|
||||||
{ ERROR("call to Target_test::scan_relocs"); }
|
{ ERROR("call to Target_test::scan_relocs"); }
|
||||||
|
|
||||||
void
|
void
|
||||||
|
@ -65,7 +63,7 @@ class Target_test : public Sized_target<size, big_endian>
|
||||||
{ ERROR("call to Target_test::relocate_section"); }
|
{ ERROR("call to Target_test::relocate_section"); }
|
||||||
|
|
||||||
void
|
void
|
||||||
scan_relocatable_relocs(const General_options&, Symbol_table*, Layout*,
|
scan_relocatable_relocs(Symbol_table*, Layout*,
|
||||||
Sized_relobj<size, big_endian>*, unsigned int,
|
Sized_relobj<size, big_endian>*, unsigned int,
|
||||||
unsigned int, const unsigned char*,
|
unsigned int, const unsigned char*,
|
||||||
size_t, Output_section*, bool, size_t,
|
size_t, Output_section*, bool, size_t,
|
||||||
|
|
|
@ -74,8 +74,7 @@ class Target_x86_64 : public Target_freebsd<64, false>
|
||||||
|
|
||||||
// Scan the relocations to look for symbol adjustments.
|
// Scan the relocations to look for symbol adjustments.
|
||||||
void
|
void
|
||||||
gc_process_relocs(const General_options& options,
|
gc_process_relocs(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Sized_relobj<64, false>* object,
|
Sized_relobj<64, false>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
|
@ -89,8 +88,7 @@ class Target_x86_64 : public Target_freebsd<64, false>
|
||||||
|
|
||||||
// Scan the relocations to look for symbol adjustments.
|
// Scan the relocations to look for symbol adjustments.
|
||||||
void
|
void
|
||||||
scan_relocs(const General_options& options,
|
scan_relocs(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Sized_relobj<64, false>* object,
|
Sized_relobj<64, false>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
|
@ -126,8 +124,7 @@ class Target_x86_64 : public Target_freebsd<64, false>
|
||||||
|
|
||||||
// Scan the relocs during a relocatable link.
|
// Scan the relocs during a relocatable link.
|
||||||
void
|
void
|
||||||
scan_relocatable_relocs(const General_options& options,
|
scan_relocatable_relocs(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Sized_relobj<64, false>* object,
|
Sized_relobj<64, false>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
|
@ -189,8 +186,7 @@ class Target_x86_64 : public Target_freebsd<64, false>
|
||||||
{ }
|
{ }
|
||||||
|
|
||||||
inline void
|
inline void
|
||||||
local(const General_options& options, Symbol_table* symtab,
|
local(Symbol_table* symtab, Layout* layout, Target_x86_64* target,
|
||||||
Layout* layout, Target_x86_64* target,
|
|
||||||
Sized_relobj<64, false>* object,
|
Sized_relobj<64, false>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
Output_section* output_section,
|
Output_section* output_section,
|
||||||
|
@ -198,8 +194,7 @@ class Target_x86_64 : public Target_freebsd<64, false>
|
||||||
const elfcpp::Sym<64, false>& lsym);
|
const elfcpp::Sym<64, false>& lsym);
|
||||||
|
|
||||||
inline void
|
inline void
|
||||||
global(const General_options& options, Symbol_table* symtab,
|
global(Symbol_table* symtab, Layout* layout, Target_x86_64* target,
|
||||||
Layout* layout, Target_x86_64* target,
|
|
||||||
Sized_relobj<64, false>* object,
|
Sized_relobj<64, false>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
Output_section* output_section,
|
Output_section* output_section,
|
||||||
|
@ -1002,8 +997,7 @@ Target_x86_64::Scan::check_non_pic(Relobj* object, unsigned int r_type)
|
||||||
// Scan a relocation for a local symbol.
|
// Scan a relocation for a local symbol.
|
||||||
|
|
||||||
inline void
|
inline void
|
||||||
Target_x86_64::Scan::local(const General_options&,
|
Target_x86_64::Scan::local(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Target_x86_64* target,
|
Target_x86_64* target,
|
||||||
Sized_relobj<64, false>* object,
|
Sized_relobj<64, false>* object,
|
||||||
|
@ -1283,8 +1277,7 @@ Target_x86_64::Scan::unsupported_reloc_global(Sized_relobj<64, false>* object,
|
||||||
// Scan a relocation for a global symbol.
|
// Scan a relocation for a global symbol.
|
||||||
|
|
||||||
inline void
|
inline void
|
||||||
Target_x86_64::Scan::global(const General_options&,
|
Target_x86_64::Scan::global(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Target_x86_64* target,
|
Target_x86_64* target,
|
||||||
Sized_relobj<64, false>* object,
|
Sized_relobj<64, false>* object,
|
||||||
|
@ -1576,8 +1569,7 @@ Target_x86_64::Scan::global(const General_options&,
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
Target_x86_64::gc_process_relocs(const General_options& options,
|
Target_x86_64::gc_process_relocs(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Sized_relobj<64, false>* object,
|
Sized_relobj<64, false>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
|
@ -1597,7 +1589,6 @@ Target_x86_64::gc_process_relocs(const General_options& options,
|
||||||
|
|
||||||
gold::gc_process_relocs<64, false, Target_x86_64, elfcpp::SHT_RELA,
|
gold::gc_process_relocs<64, false, Target_x86_64, elfcpp::SHT_RELA,
|
||||||
Target_x86_64::Scan>(
|
Target_x86_64::Scan>(
|
||||||
options,
|
|
||||||
symtab,
|
symtab,
|
||||||
layout,
|
layout,
|
||||||
this,
|
this,
|
||||||
|
@ -1614,8 +1605,7 @@ Target_x86_64::gc_process_relocs(const General_options& options,
|
||||||
// Scan relocations for a section.
|
// Scan relocations for a section.
|
||||||
|
|
||||||
void
|
void
|
||||||
Target_x86_64::scan_relocs(const General_options& options,
|
Target_x86_64::scan_relocs(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Sized_relobj<64, false>* object,
|
Sized_relobj<64, false>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
|
@ -1636,7 +1626,6 @@ Target_x86_64::scan_relocs(const General_options& options,
|
||||||
|
|
||||||
gold::scan_relocs<64, false, Target_x86_64, elfcpp::SHT_RELA,
|
gold::scan_relocs<64, false, Target_x86_64, elfcpp::SHT_RELA,
|
||||||
Target_x86_64::Scan>(
|
Target_x86_64::Scan>(
|
||||||
options,
|
|
||||||
symtab,
|
symtab,
|
||||||
layout,
|
layout,
|
||||||
this,
|
this,
|
||||||
|
@ -2526,8 +2515,7 @@ Target_x86_64::Relocatable_size_for_reloc::get_size_for_reloc(
|
||||||
// Scan the relocs during a relocatable link.
|
// Scan the relocs during a relocatable link.
|
||||||
|
|
||||||
void
|
void
|
||||||
Target_x86_64::scan_relocatable_relocs(const General_options& options,
|
Target_x86_64::scan_relocatable_relocs(Symbol_table* symtab,
|
||||||
Symbol_table* symtab,
|
|
||||||
Layout* layout,
|
Layout* layout,
|
||||||
Sized_relobj<64, false>* object,
|
Sized_relobj<64, false>* object,
|
||||||
unsigned int data_shndx,
|
unsigned int data_shndx,
|
||||||
|
@ -2547,7 +2535,6 @@ Target_x86_64::scan_relocatable_relocs(const General_options& options,
|
||||||
|
|
||||||
gold::scan_relocatable_relocs<64, false, elfcpp::SHT_RELA,
|
gold::scan_relocatable_relocs<64, false, elfcpp::SHT_RELA,
|
||||||
Scan_relocatable_relocs>(
|
Scan_relocatable_relocs>(
|
||||||
options,
|
|
||||||
symtab,
|
symtab,
|
||||||
layout,
|
layout,
|
||||||
object,
|
object,
|
||||||
|
|
Loading…
Reference in New Issue