Lines Matching defs:abfd

1507 ppc_elf_reloc_type_lookup (bfd *abfd ATTRIBUTE_UNUSED,
1614 ppc_elf_reloc_name_lookup (bfd *abfd ATTRIBUTE_UNUSED,
1632 ppc_elf_info_to_howto (bfd *abfd ATTRIBUTE_UNUSED,
1648 abfd, ELF32_R_TYPE (dst->r_info));
1658 ppc_elf_addr16_ha_reloc (bfd *abfd ATTRIBUTE_UNUSED,
1674 if (reloc_entry->address > bfd_get_section_limit (abfd, input_section))
1694 ppc_elf_unhandled_reloc (bfd *abfd,
1706 return bfd_elf_generic_reloc (abfd, reloc_entry, symbol, data,
1774 ppc_elf_mkobject (bfd *abfd)
1776 if (abfd->tdata.any == NULL)
1779 abfd->tdata.any = bfd_zalloc (abfd, amt);
1780 if (abfd->tdata.any == NULL)
1783 return bfd_elf_mkobject (abfd);
1790 ppc_elf_object_p (bfd *abfd)
1792 if (abfd->arch_info->the_default && abfd->arch_info->bits_per_word == 64)
1794 Elf_Internal_Ehdr *i_ehdr = elf_elfheader (abfd);
1799 abfd->arch_info = abfd->arch_info->next;
1800 BFD_ASSERT (abfd->arch_info->bits_per_word == 32);
1809 ppc_elf_set_private_flags (bfd *abfd, flagword flags)
1811 BFD_ASSERT (!elf_flags_init (abfd)
1812 || elf_elfheader (abfd)->e_flags == flags);
1814 elf_elfheader (abfd)->e_flags = flags;
1815 elf_flags_init (abfd) = TRUE;
1822 ppc_elf_grok_prstatus (bfd *abfd, Elf_Internal_Note *note)
1834 elf_tdata (abfd)->core_signal = bfd_get_16 (abfd, note->descdata + 12);
1837 elf_tdata (abfd)->core_pid = bfd_get_32 (abfd, note->descdata + 24);
1847 return _bfd_elfcore_make_pseudosection (abfd, ".reg",
1852 ppc_elf_grok_psinfo (bfd *abfd, Elf_Internal_Note *note)
1860 elf_tdata (abfd)->core_program
1861 = _bfd_elfcore_strndup (abfd, note->descdata + 32, 16);
1862 elf_tdata (abfd)->core_command
1863 = _bfd_elfcore_strndup (abfd, note->descdata + 48, 80);
1871 char *command = elf_tdata (abfd)->core_command;
1882 ppc_elf_write_core_note (bfd *abfd, char *buf, int *bufsiz, int note_type, ...)
1899 return elfcore_write_note (abfd, buf, bufsiz,
1914 bfd_put_32 (abfd, pid, data + 24);
1916 bfd_put_16 (abfd, cursig, data + 12);
1921 return elfcore_write_note (abfd, buf, bufsiz,
1943 ppc_elf_section_from_shdr (bfd *abfd,
1951 if (! _bfd_elf_make_section_from_shdr (abfd, hdr, name, shindex))
1955 flags = bfd_get_section_flags (abfd, newsect);
1962 bfd_set_section_flags (abfd, newsect, flags);
1969 ppc_elf_fake_sections (bfd *abfd ATTRIBUTE_UNUSED,
1986 ppc_elf_additional_program_headers (bfd *abfd,
1992 s = bfd_get_section_by_name (abfd, ".sbss2");
1996 s = bfd_get_section_by_name (abfd, ".PPC.EMB.sbss0");
2027 ppc_elf_get_sec_type_attr (bfd *abfd ATTRIBUTE_UNUSED, asection *sec)
2044 return _bfd_elf_get_sec_type_attr (abfd, sec);
2135 ppc_elf_begin_write_processing (bfd *abfd, struct bfd_link_info *link_info)
2171 asec = bfd_get_section_by_name (abfd, APUINFO_SECTION_NAME);
2248 asec = bfd_get_section_by_name (abfd, APUINFO_SECTION_NAME);
2250 if (! bfd_set_section_size (abfd, asec, output_section_size))
2251 ibfd = abfd,
2265 ppc_elf_write_section (bfd *abfd ATTRIBUTE_UNUSED,
2277 ppc_elf_final_write_processing (bfd *abfd, bfd_boolean linker ATTRIBUTE_UNUSED)
2285 asec = bfd_get_section_by_name (abfd, APUINFO_SECTION_NAME);
2306 bfd_put_32 (abfd, sizeof APUINFO_LABEL, buffer);
2307 bfd_put_32 (abfd, num_entries * 4, buffer + 4);
2308 bfd_put_32 (abfd, 0x2, buffer + 8);
2314 bfd_put_32 (abfd, apuinfo_list_element (i), buffer + length);
2321 if (! bfd_set_section_contents (abfd, asec, buffer, (file_ptr) 0, length))
2554 ppc_elf_link_hash_table_create (bfd *abfd)
2562 if (!_bfd_elf_link_hash_table_init (&ret->elf, abfd,
2593 ppc_elf_create_got (bfd *abfd, struct bfd_link_info *info)
2599 if (!_bfd_elf_create_got_section (abfd, info))
2603 htab->got = s = bfd_get_section_by_name (abfd, ".got");
2609 htab->sgotplt = bfd_get_section_by_name (abfd, ".got.plt");
2619 if (!bfd_set_section_flags (abfd, s, flags))
2625 htab->relgot = bfd_make_section_with_flags (abfd, ".rela.got", flags);
2627 || ! bfd_set_section_alignment (abfd, htab->relgot, 2))
2638 ppc_elf_create_dynamic_sections (bfd *abfd, struct bfd_link_info *info)
2647 && !ppc_elf_create_got (abfd, info))
2650 if (!_bfd_elf_create_dynamic_sections (abfd, info))
2656 s = bfd_make_section_anyway_with_flags (abfd, ".glink", flags | SEC_CODE);
2659 || !bfd_set_section_alignment (abfd, s, 4))
2662 htab->dynbss = bfd_get_section_by_name (abfd, ".dynbss");
2663 s = bfd_make_section_with_flags (abfd, ".dynsbss",
2671 htab->relbss = bfd_get_section_by_name (abfd, ".rela.bss");
2672 s = bfd_make_section_with_flags (abfd, ".rela.sbss", flags);
2675 || ! bfd_set_section_alignment (abfd, s, 2))
2680 && !elf_vxworks_create_dynamic_sections (abfd, info, &htab->srelplt2))
2683 htab->relplt = bfd_get_section_by_name (abfd, ".rela.plt");
2684 htab->plt = s = bfd_get_section_by_name (abfd, ".plt");
2692 return bfd_set_section_flags (abfd, s, flags);
2822 ppc_elf_add_symbol_hook (bfd *abfd,
2832 && sym->st_size <= elf_gp_size (abfd)
2845 htab->elf.dynobj = abfd;
2879 ppc_elf_create_linker_section (bfd *abfd,
2892 htab->elf.dynobj = abfd;
2923 elf_create_pointer_linker_section (bfd *abfd,
2952 elf_linker_section_pointers_t **ptr = elf_local_ptr_offsets (abfd);
2957 unsigned int num_symbols = elf_tdata (abfd)->symtab_hdr.sh_info;
2961 ptr = bfd_zalloc (abfd, amt);
2966 elf_local_ptr_offsets (abfd) = ptr;
2982 linker_section_ptr = bfd_alloc (abfd, amt);
3006 update_local_sym_info (bfd *abfd,
3011 bfd_signed_vma *local_got_refcounts = elf_local_got_refcounts (abfd);
3019 local_got_refcounts = bfd_zalloc (abfd, size);
3022 elf_local_got_refcounts (abfd) = local_got_refcounts;
3032 update_plt_info (bfd *abfd, struct elf_link_hash_entry *h,
3045 ent = bfd_alloc (abfd, amt);
3072 bad_shared_reloc (bfd *abfd, enum elf_ppc_reloc_type r_type)
3076 abfd,
3086 ppc_elf_check_relocs (bfd *abfd,
3113 sec, abfd);
3123 symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
3124 sym_hashes = elf_sym_hashes (abfd);
3125 got2 = bfd_get_section_by_name (abfd, ".got2");
3155 htab->elf.dynobj = abfd;
3240 htab->elf.dynobj = abfd;
3251 if (!update_local_sym_info (abfd, symtab_hdr, r_symndx, tls_type))
3259 bad_shared_reloc (abfd, r_type);
3263 && !ppc_elf_create_linker_section (abfd, info, 0,
3266 if (!elf_create_pointer_linker_section (abfd, &htab->sdata[0],
3280 bad_shared_reloc (abfd, r_type);
3284 && !ppc_elf_create_linker_section (abfd, info, SEC_READONLY,
3287 if (!elf_create_pointer_linker_section (abfd, &htab->sdata[1],
3300 bad_shared_reloc (abfd, r_type);
3316 bad_shared_reloc (abfd, r_type);
3333 bad_shared_reloc (abfd, r_type);
3356 bad_shared_reloc (abfd, r_type);
3384 abfd,
3397 ppc_elf_tdata (abfd)->makes_plt_call = 1;
3401 if (!update_plt_info (abfd, h, got2, addend))
3424 ppc_elf_tdata (abfd)->has_rel16 = 1;
3455 htab->old_bfd = abfd;
3462 if (!bfd_elf_gc_record_vtinherit (abfd, sec, h, rel->r_offset))
3469 if (!bfd_elf_gc_record_vtentry (abfd, sec, h, rel->r_addend))
3503 s = bfd_section_from_r_symndx (abfd, &htab->sym_sec, sec,
3508 htab->old_bfd = abfd;
3526 htab->old_bfd = abfd;
3548 if (!update_plt_info (abfd, h, NULL, 0))
3604 (abfd,
3605 elf_elfheader (abfd)->e_shstrndx,
3611 && strcmp (bfd_get_section_name (abfd, sec),
3615 htab->elf.dynobj = abfd;
3650 s = bfd_section_from_r_symndx (abfd, &htab->sym_sec,
3938 ppc_elf_gc_sweep_hook (bfd *abfd,
3956 symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
3957 sym_hashes = elf_sym_hashes (abfd);
3958 local_got_refcounts = elf_local_got_refcounts (abfd);
3959 got2 = bfd_get_section_by_name (abfd, ".got2");
5271 ppc_elf_relax_section (bfd *abfd,
5308 symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
5311 internal_relocs = _bfd_elf_link_read_relocs (abfd, isec, NULL, NULL,
5317 got2 = bfd_get_section_by_name (abfd, ".got2");
5361 isymbuf = bfd_elf_get_elf_syms (abfd, symtab_hdr,
5375 tsec = bfd_section_from_elf_index (abfd, isym->st_shndx);
5387 h = elf_sym_hashes (abfd)[indx];
5460 toff = _bfd_merged_section_offset (abfd, &tsec,
5555 if (!bfd_malloc_and_get_section (abfd, isec, &contents))
5567 t0 = bfd_get_32 (abfd, hit_addr);
5570 bfd_put_32 (abfd, t0, hit_addr);
5576 t0 = bfd_get_32 (abfd, hit_addr);
5579 bfd_put_32 (abfd, t0, hit_addr);
5610 bfd_put_32 (abfd, val, dest);
5627 bfd_put_32 (abfd, stub[i], dest);
6757 || strcmp (bfd_get_section_name (abfd, sec), ".got") == 0
6758 || strcmp (bfd_get_section_name (abfd, sec), ".cgot") == 0);
6798 name = bfd_get_section_name (abfd, sec->output_section);
6826 name = bfd_get_section_name (abfd, sec->output_section);
6858 name = bfd_get_section_name (abfd, sec->output_section);
7866 ppc_elf_vxworks_get_sec_type_attr (bfd *abfd ATTRIBUTE_UNUSED, asection *sec)
7872 return _bfd_elf_get_sec_type_attr (abfd, sec);
7874 return ppc_elf_get_sec_type_attr (abfd, sec);
7880 ppc_elf_vxworks_link_hash_table_create (bfd *abfd)
7884 ret = ppc_elf_link_hash_table_create (abfd);
7900 ppc_elf_vxworks_add_symbol_hook (bfd *abfd,
7908 if (!elf_vxworks_add_symbol_hook(abfd, info, sym,namep, flagsp, secp,
7912 return ppc_elf_add_symbol_hook(abfd, info, sym,namep, flagsp, secp, valp);
7916 ppc_elf_vxworks_final_write_processing (bfd *abfd, bfd_boolean linker)
7918 ppc_elf_final_write_processing(abfd, linker);
7919 elf_vxworks_final_write_processing(abfd, linker);