aboutsummaryrefslogtreecommitdiff
path: root/gold/arm.cc
diff options
context:
space:
mode:
authorDoug Kwan <dougkwan@google.com>2010-01-20 17:29:52 +0000
committerDoug Kwan <dougkwan@google.com>2010-01-20 17:29:52 +0000
commit5ac169d4b6e2d88c670298a3246fc2a5d8a94aa4 (patch)
tree02c188debc6532be6476d7de9cb86cc6309ea963 /gold/arm.cc
parenta21620630edb456511a2467466814ecffa158b2f (diff)
downloadgdb-5ac169d4b6e2d88c670298a3246fc2a5d8a94aa4.zip
gdb-5ac169d4b6e2d88c670298a3246fc2a5d8a94aa4.tar.gz
gdb-5ac169d4b6e2d88c670298a3246fc2a5d8a94aa4.tar.bz2
2010-01-20 Doug Kwan <dougkwan@google.com>
* arm.cc (Target_arm::Arm_input_section_map): Change key type from Input_section_specifier to Section_id. (Target_arm::new_arm_input_section: Adjust code for change of key type. (Target_arm::find_arm_input_section): Ditto. * gc.h (object.h): Include for Section_id nand Section_id_hash. (Section_id): Remove. (Garbage_collection::Section_id_hash): Remove. * icf.h (object.h): Include for Section_id nand Section_id_hash. (Section_id): Remove. (Icf::Section_id_hash): Remove. * object.h (Section_id, Const_section_id, Section_id_hash, Const_section_id_hash): New type definitions. * output.cc (Output_section::add_relaxed_input_section): Change to use Const_section_id instead of Input_section_specifier as key type. (Output_section::add_merge_input_section): Ditto. (Output_section::build_relaxation_map): Change to use Section_id instead of Input_section_specifier as key type. (Output_section::convert_input_sections_in_list_to_relaxed_sections): Ditto. (Output_section::convert_input_sections_to_relaxed_sections): Change to use Const_section_id instead of Input_section_specifier as key type. (Output_section::find_merge_section): Ditto. (Output_section::find_relaxed_input_section): Ditto. * output.h (Input_section_specifier): Remove class. (Output_section::Output_section_data_by_input_section_map): Change key type to Const_section_id. (Output_section::Output_relaxed_input_section_by_input_section_map): Ditto. (Output_section::Relaxation_map): Change key type to Section_id.
Diffstat (limited to 'gold/arm.cc')
-rw-r--r--gold/arm.cc13
1 files changed, 6 insertions, 7 deletions
diff --git a/gold/arm.cc b/gold/arm.cc
index 87459a5..8e3573f 100644
--- a/gold/arm.cc
+++ b/gold/arm.cc
@@ -2114,10 +2114,9 @@ class Target_arm : public Sized_target<32, big_endian>
typedef typename std::vector<Stub_table<big_endian>*> Stub_table_list;
// Map input section to Arm_input_section.
- typedef Unordered_map<Input_section_specifier,
+ typedef Unordered_map<Section_id,
Arm_input_section<big_endian>*,
- Input_section_specifier::hash,
- Input_section_specifier::equal_to>
+ Section_id_hash>
Arm_input_section_map;
// Map output addresses to relocs for Cortex-A8 erratum.
@@ -7543,7 +7542,7 @@ Target_arm<big_endian>::new_arm_input_section(
Relobj* relobj,
unsigned int shndx)
{
- Input_section_specifier iss(relobj, shndx);
+ Section_id sid(relobj, shndx);
Arm_input_section<big_endian>* arm_input_section =
new Arm_input_section<big_endian>(relobj, shndx);
@@ -7551,7 +7550,7 @@ Target_arm<big_endian>::new_arm_input_section(
// Register new Arm_input_section in map for look-up.
std::pair<typename Arm_input_section_map::iterator, bool> ins =
- this->arm_input_section_map_.insert(std::make_pair(iss, arm_input_section));
+ this->arm_input_section_map_.insert(std::make_pair(sid, arm_input_section));
// Make sure that it we have not created another Arm_input_section
// for this input section already.
@@ -7569,9 +7568,9 @@ Target_arm<big_endian>::find_arm_input_section(
Relobj* relobj,
unsigned int shndx) const
{
- Input_section_specifier iss(relobj, shndx);
+ Section_id sid(relobj, shndx);
typename Arm_input_section_map::const_iterator p =
- this->arm_input_section_map_.find(iss);
+ this->arm_input_section_map_.find(sid);
return (p != this->arm_input_section_map_.end()) ? p->second : NULL;
}