Lines Matching refs:gsym
1911 // Add a static entry for the GOT entry at OFFSET. GSYM is a global
1915 add_static_reloc(unsigned int got_offset, unsigned int r_type, Symbol* gsym)
1916 { this->static_relocs_.push_back(Static_reloc(got_offset, r_type, gsym)); }
1934 // be applied by gold. GSYM is a global symbol.
1936 add_tls_gd32_with_static_reloc(unsigned int got_type, Symbol* gsym);
1955 Static_reloc(unsigned int got_offset, unsigned int r_type, Symbol* gsym)
1957 { this->u_.global.symbol = gsym; }
2267 do_plt_address_for_global(const Symbol* gsym) const
2268 { return this->plt_section()->address_for_global(gsym); }
2592 Symbol* gsym);
2667 should_apply_static_reloc(const Sized_symbol<32>* gsym,
2799 may_need_copy_reloc(Symbol* gsym)
2801 return (gsym->type() != elfcpp::STT_ARM_TFUNC
2802 && gsym->may_need_copy_reloc());
3920 const Sized_symbol<32>* gsym,
4011 Reloc_stub::Key stub_key(stub_type, gsym, object, r_sym, addend);
4049 const Sized_symbol<32>* gsym,
4089 (gsym ? gsym->name() : "(local)"));
4152 Reloc_stub::Key stub_key(stub_type, gsym, object, r_sym, addend);
7204 // be applied by gold. GSYM is a global symbol.
7210 Symbol* gsym)
7212 if (gsym->has_got_offset(got_type))
7218 gsym->set_got_offset(got_type, got_offset);
7222 gsym));
7304 const Symbol* gsym = reloc.symbol();
7305 gold_assert(gsym != NULL);
7306 if (gsym->is_forwarder())
7307 gsym = this->symbol_table_->resolve_forwards(gsym);
7312 if ((gsym->is_defined_in_discarded_section()
7313 || gsym->is_undefined())
7314 && !gsym->is_weak_undefined())
7317 gsym->name());
7321 if (!gsym->is_weak_undefined())
7324 static_cast<const Sized_symbol<32>*>(gsym);
7411 add_entry(Symbol_table* symtab, Layout* layout, Symbol* gsym);
7416 Symbol* gsym, unsigned int got_offset);
7570 Symbol* gsym)
7572 gold_assert(!gsym->has_plt_offset());
7592 if (gsym->type() == elfcpp::STT_GNU_IFUNC
7593 && gsym->can_use_relative_reloc(false))
7602 IRelative_data(symtab->get_sized_symbol<32>(gsym)));
7613 gsym->set_plt_offset(begin_offset
7626 this->add_relocation(symtab, layout, gsym, got_offset);
7672 Symbol_table* symtab, Layout* layout, Symbol* gsym, unsigned int got_offset)
7674 if (gsym->type() == elfcpp::STT_GNU_IFUNC
7675 && gsym->can_use_relative_reloc(false))
7678 rel->add_symbolless_global_addend(gsym, elfcpp::R_ARM_IRELATIVE,
7683 gsym->set_needs_dynsym_entry();
7684 this->rel_->add_global(gsym, elfcpp::R_ARM_JUMP_SLOT, this->got_plt_,
7734 Output_data_plt_arm<big_endian>::address_for_global(const Symbol* gsym) const
7737 if (gsym->type() == elfcpp::STT_GNU_IFUNC
7738 && gsym->can_use_relative_reloc(false))
7743 return this->address() + begin_offset + gsym->plt_offset();
7962 Symbol* gsym)
7964 if (gsym->has_plt_offset())
7970 this->plt_->add_entry(symtab, layout, gsym);
8676 Symbol* gsym)
8679 object->name().c_str(), r_type, gsym->demangled_name().c_str());
8738 Symbol* gsym)
8741 if (strcmp(gsym->name(), "_GLOBAL_OFFSET_TABLE_") == 0)
8760 Symbol* gsym)
8766 && strcmp(gsym->name(), "_GLOBAL_OFFSET_TABLE_") == 0)
8770 if (gsym->type() == elfcpp::STT_GNU_IFUNC
8772 target->make_plt_entry(symtab, layout, gsym);
8797 if (this->symbol_needs_plt_entry(gsym))
8799 target->make_plt_entry(symtab, layout, gsym);
8804 if (gsym->is_from_dynobj() && !parameters->options().shared())
8805 gsym->set_needs_dynsym_value();
8808 if (gsym->needs_dynamic_reloc(Scan::get_reference_flags(r_type)))
8811 && gsym->may_need_copy_reloc())
8814 data_shndx, output_section, gsym, reloc);
8818 && gsym->type() == elfcpp::STT_GNU_IFUNC
8819 && gsym->can_use_relative_reloc(false)
8820 && !gsym->is_from_dynobj()
8821 && !gsym->is_undefined()
8822 && !gsym->is_preemptible())
8831 gsym, r_type, output_section, object,
8836 && gsym->can_use_relative_reloc(false))
8839 rel_dyn->add_global_relative(gsym, elfcpp::R_ARM_RELATIVE,
8847 rel_dyn->add_global(gsym, r_type, output_section, object,
8908 if (gsym->needs_dynamic_reloc(Scan::get_reference_flags(r_type)))
8911 && target->may_need_copy_reloc(gsym))
8914 data_shndx, output_section, gsym, reloc);
8920 rel_dyn->add_global(gsym, r_type, output_section, object,
8949 if (gsym->final_value_is_known())
8954 if (gsym->is_defined()
8955 && !gsym->is_from_dynobj()
8956 && !gsym->is_preemptible())
8958 target->make_plt_entry(symtab, layout, gsym);
8968 if (gsym->final_value_is_known())
8971 if (gsym->type() == elfcpp::STT_GNU_IFUNC)
8972 got->add_global_plt(gsym, GOT_TYPE_STANDARD);
8974 got->add_global(gsym, GOT_TYPE_STANDARD);
8981 if (gsym->is_from_dynobj()
8982 || gsym->is_undefined()
8983 || gsym->is_preemptible()
8984 || (gsym->visibility() == elfcpp::STV_PROTECTED
8986 || (gsym->type() == elfcpp::STT_GNU_IFUNC
8988 got->add_global_with_rel(gsym, GOT_TYPE_STANDARD,
8996 if (gsym->type() != elfcpp::STT_GNU_IFUNC)
8997 is_new = got->add_global(gsym, GOT_TYPE_STANDARD);
9000 is_new = got->add_global_plt(gsym, GOT_TYPE_STANDARD);
9003 if (gsym->is_from_dynobj()
9005 gsym->set_needs_dynsym_value();
9009 gsym, elfcpp::R_ARM_RELATIVE, got,
9010 gsym->got_offset(GOT_TYPE_STANDARD));
9038 const bool is_final = gsym->final_value_is_known();
9051 got->add_global_pair_with_rel(gsym, GOT_TYPE_TLS_PAIR,
9056 got->add_tls_gd32_with_static_reloc(GOT_TYPE_TLS_PAIR, gsym);
9085 got->add_global_with_rel(gsym, GOT_TYPE_TLS_OFFSET,
9088 else if (!gsym->has_got_offset(GOT_TYPE_TLS_OFFSET))
9090 got->add_global(gsym, GOT_TYPE_TLS_OFFSET);
9092 gsym->got_offset(GOT_TYPE_TLS_OFFSET);
9094 elfcpp::R_ARM_TLS_TPOFF32, gsym);
9108 rel_dyn->add_global(gsym, elfcpp::R_ARM_TLS_TPOFF32,
9125 unsupported_reloc_global(object, r_type, gsym);
9345 const Sized_symbol<32>* gsym,
9362 if (gsym == NULL)
9371 bool has_dyn = gsym->needs_dynamic_reloc(ref_flags);
9373 && gsym->can_use_relative_reloc(ref_flags
9389 const Sized_symbol<32>* gsym,
9439 if (gsym != NULL)
9441 gold_assert(gsym->has_got_offset(GOT_TYPE_STANDARD));
9442 got_offset = (gsym->got_offset(GOT_TYPE_STANDARD)
9462 if (gsym != NULL)
9466 if (gsym->use_plt_offset(Scan::get_reference_flags(r_type)))
9469 symval.set_output_value(target->plt_address_for_global(gsym));
9472 else if (gsym->is_weak_undefined())
9479 else if (gsym->is_undefined() && reloc_property->uses_symbol())
9492 (((gsym->type() == elfcpp::STT_ARM_TFUNC)
9493 || (gsym->type() == elfcpp::STT_FUNC
9494 && !gsym->is_undefined()
9540 // symbol gsym if needed (AAELF 4.6.1.2 Relocation types).
9544 if (r_type == elfcpp::R_ARM_BASE_ABS && gsym == NULL)
9549 else if (gsym == NULL)
9551 else if (gsym->source() == Symbol::IN_OUTPUT_SEGMENT)
9552 sym_origin = gsym->output_segment()->vaddr();
9553 else if (gsym->source() == Symbol::IN_OUTPUT_DATA)
9554 sym_origin = gsym->output_data()->address();
9596 if (should_apply_static_reloc(gsym, r_type, false, output_section))
9601 if (should_apply_static_reloc(gsym, r_type, false, output_section))
9606 if (should_apply_static_reloc(gsym, r_type, false, output_section))
9611 if (should_apply_static_reloc(gsym, r_type, true, output_section))
9617 if (should_apply_static_reloc(gsym, r_type, true, output_section))
9624 if (should_apply_static_reloc(gsym, r_type, false, output_section))
9631 if (should_apply_static_reloc(gsym, r_type, false, output_section))
9636 if (should_apply_static_reloc(gsym, r_type, false, output_section))
9642 if (should_apply_static_reloc(gsym, r_type, false, output_section))
9685 if (should_apply_static_reloc(gsym, r_type, false, output_section))
9695 r_type, relinfo, view, gsym, object, r_sym, psymval, address,
9709 gold_assert(gsym != NULL);
9715 if (should_apply_static_reloc(gsym, r_type, false, output_section))
9740 gold_assert(gsym == NULL
9741 || gsym->has_plt_offset()
9742 || gsym->final_value_is_known()
9743 || (gsym->is_defined()
9744 && !gsym->is_from_dynobj()
9745 && !gsym->is_preemptible()));
9748 r_type, relinfo, view, gsym, object, r_sym, psymval, address,
9866 this->relocate_tls(relinfo, target, relnum, rel, r_type, gsym, psymval,
9916 const Sized_symbol<32>* gsym,
9930 const bool is_final = (gsym == NULL
9932 : gsym->final_value_is_known());
9941 if (gsym != NULL)
9943 gold_assert(gsym->has_got_offset(got_type));
9944 got_offset = gsym->got_offset(got_type) - target->got_size();
9995 if (gsym != NULL)
9997 gold_assert(gsym->has_got_offset(got_type));
9998 got_offset = gsym->got_offset(got_type);
10489 Target_arm<big_endian>::do_dynsym_value(const Symbol* gsym) const
10491 gold_assert(gsym->is_from_dynobj() && gsym->has_plt_offset());
10492 return this->plt_address_for_global(gsym);
11651 const Sized_symbol<32>* gsym,
11662 if (gsym != NULL)
11666 if (gsym->use_plt_offset(Scan::get_reference_flags(r_type)))
11669 symval.set_output_value(this->plt_address_for_global(gsym));
11673 else if (gsym->is_undefined())
11679 ((gsym->type() == elfcpp::STT_ARM_TFUNC)
11680 || (gsym->type() == elfcpp::STT_FUNC
11681 && !gsym->is_undefined()
11742 Reloc_stub::Key stub_key(stub_type, gsym, arm_relobj, r_sym, addend);
11944 const Symbol* gsym;
11945 gsym = arm_object->global_symbol(r_sym);
11946 gold_assert(gsym != NULL);
11947 if (gsym->is_forwarder())
11948 gsym = relinfo->symtab->resolve_forwards(gsym);
11950 sym = static_cast<const Sized_symbol<32>*>(gsym);
11960 symtab->get_sized_symbol<32>(gsym);
11970 if (gsym->type() == elfcpp::STT_TLS)
11972 else if (gsym->type() == elfcpp::STT_GNU_IFUNC)
11977 (gsym->is_defined_in_discarded_section()
11978 && gsym->is_undefined());