diff options
Diffstat (limited to 'binutils-2.25/gold')
-rw-r--r-- | binutils-2.25/gold/aarch64.cc | 2 | ||||
-rw-r--r-- | binutils-2.25/gold/arm.cc | 35 | ||||
-rw-r--r-- | binutils-2.25/gold/dirsearch.cc | 8 | ||||
-rw-r--r-- | binutils-2.25/gold/dwarf_reader.cc | 2 |
4 files changed, 2 insertions, 45 deletions
diff --git a/binutils-2.25/gold/aarch64.cc b/binutils-2.25/gold/aarch64.cc index 176c5cb..aa540f0 100644 --- a/binutils-2.25/gold/aarch64.cc +++ b/binutils-2.25/gold/aarch64.cc @@ -2025,7 +2025,7 @@ AArch64_relobj<size, big_endian>::try_fix_erratum_843419_optimized( if (-(1 << 20) <= adr_imm && adr_imm < (1 << 20)) { // Convert 'adrp' into 'adr'. - Insntype adr_insn = adrp_insn & ((1 << 31) - 1); + Insntype adr_insn = adrp_insn & ((1u << 31) - 1); adr_insn = Insn_utilities:: aarch64_adr_encode_imm(adr_insn, adr_imm); elfcpp::Swap<32, big_endian>::writeval(adrp_view, adr_insn); diff --git a/binutils-2.25/gold/arm.cc b/binutils-2.25/gold/arm.cc index 94149d6..4879acb 100644 --- a/binutils-2.25/gold/arm.cc +++ b/binutils-2.25/gold/arm.cc @@ -4497,41 +4497,6 @@ Stub::do_fixed_endian_write(unsigned char* view, section_size_type view_size) gold_assert(static_cast<section_size_type>(pov - view) == view_size); } -// Reloc_stub::Key methods. - -// Dump a Key as a string for debugging. - -std::string -Reloc_stub::Key::name() const -{ - if (this->r_sym_ == invalid_index) - { - // Global symbol key name - // <stub-type>:<symbol name>:<addend>. - const std::string sym_name = this->u_.symbol->name(); - // We need to print two hex number and two colons. So just add 100 bytes - // to the symbol name size. - size_t len = sym_name.size() + 100; - char* buffer = new char[len]; - int c = snprintf(buffer, len, "%d:%s:%x", this->stub_type_, - sym_name.c_str(), this->addend_); - gold_assert(c > 0 && c < static_cast<int>(len)); - delete[] buffer; - return std::string(buffer); - } - else - { - // local symbol key name - // <stub-type>:<object>:<r_sym>:<addend>. - const size_t len = 200; - char buffer[len]; - int c = snprintf(buffer, len, "%d:%p:%u:%x", this->stub_type_, - this->u_.relobj, this->r_sym_, this->addend_); - gold_assert(c > 0 && c < static_cast<int>(len)); - return std::string(buffer); - } -} - // Reloc_stub methods. // Determine the type of stub needed, if any, for a relocation of R_TYPE at diff --git a/binutils-2.25/gold/dirsearch.cc b/binutils-2.25/gold/dirsearch.cc index e9e2fa1..bf25fe6 100644 --- a/binutils-2.25/gold/dirsearch.cc +++ b/binutils-2.25/gold/dirsearch.cc @@ -122,14 +122,6 @@ class Dir_caches Cache_hash caches_; }; -Dir_caches::~Dir_caches() -{ - for (Cache_hash::iterator p = this->caches_.begin(); - p != this->caches_.end(); - ++p) - delete p->second; -} - void Dir_caches::add(const char* dirname) { diff --git a/binutils-2.25/gold/dwarf_reader.cc b/binutils-2.25/gold/dwarf_reader.cc index f5ca7cd..dd5635c 100644 --- a/binutils-2.25/gold/dwarf_reader.cc +++ b/binutils-2.25/gold/dwarf_reader.cc @@ -1961,7 +1961,7 @@ Sized_dwarf_line_info<size, big_endian>::read_header_tables_v5( } gold_debug(DEBUG_LOCATION, "File %3d: %s", static_cast<int>(file_list.size()), path); - file_list.push_back(std::make_pair<int, std::string>(dirindex, path)); + file_list.push_back(std::make_pair<int, std::string>(int(dirindex), path)); } delete[] types; |