struct objdump_disasm_info
{
bfd * abfd;
- asection * sec;
bfd_boolean require_sec;
arelent ** dynrelbuf;
long dynrelcount;
aux = (struct objdump_disasm_info *) inf->application_data;
abfd = aux->abfd;
- sec = aux->sec;
+ sec = inf->section;
opb = inf->octets_per_byte;
/* Perform a binary search looking for the closest symbol to the
if (display_file_offsets)
inf->fprintf_func (inf->stream, _(" (File Offset: 0x%lx)"),
- (long int)(aux->sec->filepos + (vma - aux->sec->vma)));
+ (long int) (inf->section->filepos
+ + (vma - inf->section->vma)));
return;
}
if (!skip_find)
sym = find_symbol_for_address (vma, inf, NULL);
- objdump_print_addr_with_sym (aux->abfd, aux->sec, sym, vma, inf,
+ objdump_print_addr_with_sym (aux->abfd, inf->section, sym, vma, inf,
skip_zeroes);
}
SFILE sfile;
aux = (struct objdump_disasm_info *) inf->application_data;
- section = aux->sec;
+ section = inf->section;
sfile.alloc = 120;
sfile.buffer = (char *) xmalloc (sfile.alloc);
return;
}
- paux->sec = section;
pinfo->buffer = data;
pinfo->buffer_vma = section->vma;
pinfo->buffer_length = datasize;
if (aux.dynrelbuf != NULL)
free (aux.dynrelbuf);
free (sorted_syms);
+ disassemble_free_target (&disasm_info);
}
\f
static bfd_boolean
return;
}
- eh_addr_size = bfd_arch_bits_per_address (abfd) / 8;
-
switch (bfd_get_arch (abfd))
{
- case bfd_arch_i386:
- switch (bfd_get_mach (abfd))
- {
- case bfd_mach_x86_64:
- case bfd_mach_x86_64_intel_syntax:
- case bfd_mach_x86_64_nacl:
- case bfd_mach_x64_32:
- case bfd_mach_x64_32_intel_syntax:
- case bfd_mach_x64_32_nacl:
- init_dwarf_regnames_x86_64 ();
- break;
-
- default:
- init_dwarf_regnames_i386 ();
- break;
- }
- break;
-
- case bfd_arch_iamcu:
- init_dwarf_regnames_iamcu ();
- break;
-
- case bfd_arch_aarch64:
- init_dwarf_regnames_aarch64();
- break;
-
- case bfd_arch_s390:
- init_dwarf_regnames_s390 ();
- break;
-
- case bfd_arch_riscv:
- init_dwarf_regnames_riscv ();
- break;
-
case bfd_arch_s12z:
/* S12Z has a 24 bit address space. But the only known
producer of dwarf_info encodes addresses into 32 bits. */
break;
default:
+ eh_addr_size = bfd_arch_bits_per_address (abfd) / 8;
break;
}
+ init_dwarf_regnames_by_bfd_arch_and_mach (bfd_get_arch (abfd),
+ bfd_get_mach (abfd));
+
bfd_map_over_sections (abfd, dump_dwarf_section, NULL);
}
\f