Lines Matching refs:ent

329 next_cie_fde_offset (const struct eh_cie_fde *ent,  in next_cie_fde_offset()  argument
333 while (++ent < last) in next_cie_fde_offset()
335 if (!ent->removed) in next_cie_fde_offset()
336 return ent->new_offset; in next_cie_fde_offset()
1149 struct eh_cie_fde *ent, elf_gc_mark_hook_fn gc_mark_hook, in mark_entry() argument
1153 for (cookie->rel = cookie->rels + ent->reloc_index; in mark_entry()
1155 && cookie->rel->r_offset < ent->offset + ent->size; in mark_entry()
1338 struct eh_cie_fde *ent = NULL; in offset_adjust() local
1349 ent = &sec_info->entry[mid]; in offset_adjust()
1350 if (offset < ent->offset) in offset_adjust()
1354 else if (offset >= ent[1].offset) in offset_adjust()
1360 if (!ent->removed) in offset_adjust()
1361 delta = (bfd_vma) ent->new_offset - (bfd_vma) ent->offset; in offset_adjust()
1362 else if (ent->cie && ent->u.cie.merged) in offset_adjust()
1364 struct eh_cie_fde *cie = ent->u.cie.u.merged_with; in offset_adjust()
1366 - (bfd_vma) ent->offset - sec->output_offset); in offset_adjust()
1373 delta = ((bfd_vma) next_cie_fde_offset (ent, last, sec) in offset_adjust()
1374 - (bfd_vma) ent->offset); in offset_adjust()
1379 offset -= ent->offset; in offset_adjust()
1380 if (ent->cie) in offset_adjust()
1383 = ent->add_augmentation_size + ent->u.cie.add_fde_encoding; in offset_adjust()
1385 || offset <= 9u + ent->u.cie.aug_str_len) in offset_adjust()
1388 if (offset <= 9u + ent->u.cie.aug_str_len + ent->u.cie.aug_data_len) in offset_adjust()
1394 unsigned int ptr_size, width, extra = ent->add_augmentation_size; in offset_adjust()
1399 width = get_DW_EH_PE_width (ent->fde_encoding, ptr_size); in offset_adjust()
1479 struct eh_cie_fde *ent; in _bfd_elf_discard_section_eh_frame() local
1496 for (ent = sec_info->entry; ent < sec_info->entry + sec_info->count; ++ent) in _bfd_elf_discard_section_eh_frame()
1497 if (ent->size == 4) in _bfd_elf_discard_section_eh_frame()
1500 ent->removed = sec->map_head.s != NULL; in _bfd_elf_discard_section_eh_frame()
1501 else if (!ent->cie && ent->u.fde.cie_inf != NULL) in _bfd_elf_discard_section_eh_frame()
1507 = get_DW_EH_PE_width (ent->fde_encoding, ptr_size); in _bfd_elf_discard_section_eh_frame()
1509 = read_value (abfd, sec->contents + ent->offset + 8 + width, in _bfd_elf_discard_section_eh_frame()
1510 width, get_DW_EH_PE_signed (ent->fde_encoding)); in _bfd_elf_discard_section_eh_frame()
1515 cookie->rel = cookie->rels + ent->reloc_index; in _bfd_elf_discard_section_eh_frame()
1518 && cookie->rel->r_offset == ent->offset + 8); in _bfd_elf_discard_section_eh_frame()
1519 keep = !(*reloc_symbol_deleted_p) (ent->offset + 8, cookie); in _bfd_elf_discard_section_eh_frame()
1524 && (((ent->fde_encoding & 0x70) == DW_EH_PE_absptr in _bfd_elf_discard_section_eh_frame()
1525 && ent->make_relative == 0) in _bfd_elf_discard_section_eh_frame()
1526 || (ent->fde_encoding & 0x70) == DW_EH_PE_aligned)) in _bfd_elf_discard_section_eh_frame()
1554 ent->removed = 0; in _bfd_elf_discard_section_eh_frame()
1556 ent->u.fde.cie_inf = find_merged_cie (abfd, info, sec, hdr_info, in _bfd_elf_discard_section_eh_frame()
1557 cookie, ent->u.fde.cie_inf); in _bfd_elf_discard_section_eh_frame()
1572 for (ent = sec_info->entry; ent < sec_info->entry + sec_info->count; ++ent) in _bfd_elf_discard_section_eh_frame()
1573 if (!ent->removed) in _bfd_elf_discard_section_eh_frame()
1576 if (ent->size == 4) in _bfd_elf_discard_section_eh_frame()
1578 else if (ent->cie) in _bfd_elf_discard_section_eh_frame()
1580 if (ent->u.cie.per_encoding_aligned8) in _bfd_elf_discard_section_eh_frame()
1585 eh_alignment = get_DW_EH_PE_width (ent->fde_encoding, ptr_size); in _bfd_elf_discard_section_eh_frame()
1590 ent->new_offset = offset; in _bfd_elf_discard_section_eh_frame()
1591 if (ent->new_offset != ent->offset) in _bfd_elf_discard_section_eh_frame()
1593 offset += size_of_output_cie_fde (ent); in _bfd_elf_discard_section_eh_frame()
1923 struct eh_cie_fde *ent, *last_ent; in _bfd_elf_write_section_eh_frame() local
1953 for (ent = sec_info->entry + sec_info->count; ent-- != sec_info->entry;) in _bfd_elf_write_section_eh_frame()
1954 if (!ent->removed && ent->new_offset > ent->offset) in _bfd_elf_write_section_eh_frame()
1955 memmove (contents + ent->new_offset, contents + ent->offset, ent->size); in _bfd_elf_write_section_eh_frame()
1957 for (ent = sec_info->entry; ent < sec_info->entry + sec_info->count; ++ent) in _bfd_elf_write_section_eh_frame()
1958 if (!ent->removed && ent->new_offset < ent->offset) in _bfd_elf_write_section_eh_frame()
1959 memmove (contents + ent->new_offset, contents + ent->offset, ent->size); in _bfd_elf_write_section_eh_frame()
1962 for (ent = sec_info->entry; ent < last_ent; ++ent) in _bfd_elf_write_section_eh_frame()
1967 if (ent->removed) in _bfd_elf_write_section_eh_frame()
1970 if (ent->size == 4) in _bfd_elf_write_section_eh_frame()
1973 BFD_ASSERT (ent == last_ent - 1); in _bfd_elf_write_section_eh_frame()
1977 buf = contents + ent->new_offset; in _bfd_elf_write_section_eh_frame()
1978 end = buf + ent->size; in _bfd_elf_write_section_eh_frame()
1979 new_size = next_cie_fde_offset (ent, last_ent, sec) - ent->new_offset; in _bfd_elf_write_section_eh_frame()
1985 if (new_size != ent->size) in _bfd_elf_write_section_eh_frame()
1986 memset (end, 0, new_size - ent->size); in _bfd_elf_write_section_eh_frame()
1988 if (ent->cie) in _bfd_elf_write_section_eh_frame()
1991 if (ent->make_relative in _bfd_elf_write_section_eh_frame()
1992 || ent->u.cie.make_lsda_relative in _bfd_elf_write_section_eh_frame()
1993 || ent->u.cie.per_encoding_relative) in _bfd_elf_write_section_eh_frame()
2001 action = ((ent->make_relative ? 1 : 0) in _bfd_elf_write_section_eh_frame()
2002 | (ent->u.cie.make_lsda_relative ? 2 : 0) in _bfd_elf_write_section_eh_frame()
2003 | (ent->u.cie.per_encoding_relative ? 4 : 0)); in _bfd_elf_write_section_eh_frame()
2004 extra_string = extra_augmentation_string_bytes (ent); in _bfd_elf_write_section_eh_frame()
2005 extra_data = extra_augmentation_data_bytes (ent); in _bfd_elf_write_section_eh_frame()
2032 if (ent->add_augmentation_size) in _bfd_elf_write_section_eh_frame()
2037 if (ent->u.cie.add_fde_encoding) in _bfd_elf_write_section_eh_frame()
2051 BFD_ASSERT (*buf == ent->lsda_encoding); in _bfd_elf_write_section_eh_frame()
2058 if (ent->u.cie.make_per_encoding_relative) in _bfd_elf_write_section_eh_frame()
2064 == ent->u.cie.per_encoding_relative); in _bfd_elf_write_section_eh_frame()
2075 if (ent->u.cie.make_per_encoding_relative) in _bfd_elf_write_section_eh_frame()
2081 val += (bfd_vma) ent->offset - ent->new_offset; in _bfd_elf_write_section_eh_frame()
2092 BFD_ASSERT (*buf == ent->fde_encoding); in _bfd_elf_write_section_eh_frame()
2114 cie = ent->u.fde.cie_inf; in _bfd_elf_write_section_eh_frame()
2116 value = ((ent->new_offset + sec->output_offset + 4) in _bfd_elf_write_section_eh_frame()
2122 width = get_DW_EH_PE_width (ent->fde_encoding, ptr_size); in _bfd_elf_write_section_eh_frame()
2124 get_DW_EH_PE_signed (ent->fde_encoding)); in _bfd_elf_write_section_eh_frame()
2128 switch (ent->fde_encoding & 0x70) in _bfd_elf_write_section_eh_frame()
2164 value += (bfd_vma) ent->offset - ent->new_offset; in _bfd_elf_write_section_eh_frame()
2167 + ent->offset + 8); in _bfd_elf_write_section_eh_frame()
2170 if (ent->make_relative) in _bfd_elf_write_section_eh_frame()
2173 + ent->new_offset + 8); in _bfd_elf_write_section_eh_frame()
2193 + ent->new_offset); in _bfd_elf_write_section_eh_frame()
2196 if ((ent->lsda_encoding & 0x70) == DW_EH_PE_pcrel in _bfd_elf_write_section_eh_frame()
2199 buf += ent->lsda_offset; in _bfd_elf_write_section_eh_frame()
2200 width = get_DW_EH_PE_width (ent->lsda_encoding, ptr_size); in _bfd_elf_write_section_eh_frame()
2202 get_DW_EH_PE_signed (ent->lsda_encoding)); in _bfd_elf_write_section_eh_frame()
2205 if ((ent->lsda_encoding & 0x70) == DW_EH_PE_pcrel) in _bfd_elf_write_section_eh_frame()
2206 value += (bfd_vma) ent->offset - ent->new_offset; in _bfd_elf_write_section_eh_frame()
2210 + ent->new_offset + 8 + ent->lsda_offset); in _bfd_elf_write_section_eh_frame()
2214 else if (ent->add_augmentation_size) in _bfd_elf_write_section_eh_frame()
2223 if (ent->set_loc) in _bfd_elf_write_section_eh_frame()
2229 width = get_DW_EH_PE_width (ent->fde_encoding, ptr_size); in _bfd_elf_write_section_eh_frame()
2230 new_offset = ent->new_offset + 8 in _bfd_elf_write_section_eh_frame()
2231 + extra_augmentation_string_bytes (ent) in _bfd_elf_write_section_eh_frame()
2232 + extra_augmentation_data_bytes (ent); in _bfd_elf_write_section_eh_frame()
2234 for (cnt = 1; cnt <= ent->set_loc[0]; cnt++) in _bfd_elf_write_section_eh_frame()
2236 buf = start + ent->set_loc[cnt]; in _bfd_elf_write_section_eh_frame()
2239 get_DW_EH_PE_signed (ent->fde_encoding)); in _bfd_elf_write_section_eh_frame()
2243 if ((ent->fde_encoding & 0x70) == DW_EH_PE_pcrel) in _bfd_elf_write_section_eh_frame()
2244 value += (bfd_vma) ent->offset + 8 - new_offset; in _bfd_elf_write_section_eh_frame()
2245 if (ent->make_relative) in _bfd_elf_write_section_eh_frame()
2248 + new_offset + ent->set_loc[cnt]); in _bfd_elf_write_section_eh_frame()