int idx = s - objfile->sections;
exec_set_section_address (bfd_get_filename (objfile->obfd), idx,
- obj_section_addr (s));
+ s->addr ());
}
/* Data changed. */
static bool
sort_cmp (const struct obj_section *sect1, const obj_section *sect2)
{
- const CORE_ADDR sect1_addr = obj_section_addr (sect1);
- const CORE_ADDR sect2_addr = obj_section_addr (sect2);
+ const CORE_ADDR sect1_addr = sect1->addr ();
+ const CORE_ADDR sect2_addr = sect2->addr ();
if (sect1_addr < sect2_addr)
return true;
static struct obj_section *
preferred_obj_section (struct obj_section *a, struct obj_section *b)
{
- gdb_assert (obj_section_addr (a) == obj_section_addr (b));
+ gdb_assert (a->addr () == b->addr ());
gdb_assert ((a->objfile->separate_debug_objfile == b->objfile)
|| (b->objfile->separate_debug_objfile == a->objfile));
gdb_assert ((a->objfile->separate_debug_objfile_backlink == b->objfile)
struct obj_section *const sect2 = map[i + 1];
const struct objfile *const objfile1 = sect1->objfile;
const struct objfile *const objfile2 = sect2->objfile;
- const CORE_ADDR sect1_addr = obj_section_addr (sect1);
- const CORE_ADDR sect2_addr = obj_section_addr (sect2);
+ const CORE_ADDR sect1_addr = sect1->addr ();
+ const CORE_ADDR sect2_addr = sect2->addr ();
if (sect1_addr == sect2_addr
&& (objfile1->separate_debug_objfile == objfile2
{
struct obj_section *const sect1 = map[i];
struct obj_section *const sect2 = map[k];
- const CORE_ADDR sect1_addr = obj_section_addr (sect1);
- const CORE_ADDR sect2_addr = obj_section_addr (sect2);
- const CORE_ADDR sect1_endaddr = obj_section_endaddr (sect1);
+ const CORE_ADDR sect1_addr = sect1->addr ();
+ const CORE_ADDR sect2_addr = sect2->addr ();
+ const CORE_ADDR sect1_endaddr = sect1->endaddr ();
gdb_assert (sect1_addr <= sect2_addr);
const struct bfd_section *const bfds1 = sect1->the_bfd_section;
const struct bfd_section *const bfds2 = sect2->the_bfd_section;
- const CORE_ADDR sect2_endaddr = obj_section_endaddr (sect2);
+ const CORE_ADDR sect2_endaddr = sect2->endaddr ();
struct gdbarch *const gdbarch = objf1->arch ();
const CORE_ADDR pc = *(CORE_ADDR *) key;
const struct obj_section *section = *(const struct obj_section **) elt;
- if (pc < obj_section_addr (section))
+ if (pc < section->addr ())
return -1;
- if (pc < obj_section_endaddr (section))
+ if (pc < section->endaddr ())
return 0;
return 1;
}
if (section_is_overlay (osect) && !section_is_mapped (osect))
continue;
- if (obj_section_addr (osect) <= addr
- && addr < obj_section_endaddr (osect))
+ if (osect->addr () <= addr && addr < osect->endaddr ())
return true;
}
return false;