object's symbol table. */
p = find_pc_sect_psymbol (objfile, tpst, pc, section);
if (p != NULL
- && (p->value.address == BMSYMBOL_VALUE_ADDRESS (msymbol)))
+ && (p->address (objfile) == BMSYMBOL_VALUE_ADDRESS (msymbol)))
return tpst;
/* Also accept the textlow value of a psymtab as a
symbol tables with line information but no debug
symbols (e.g. those produced by an assembler). */
if (p != NULL)
- this_addr = p->value.address;
+ this_addr = p->address (objfile);
else
this_addr = tpst->textlow;
object's symbol table. */
p = find_pc_sect_psymbol (objfile, pst, pc, section);
if (p == NULL
- || (p->value.address != BMSYMBOL_VALUE_ADDRESS (msymbol)))
+ || (p->address (objfile)
+ != BMSYMBOL_VALUE_ADDRESS (msymbol)))
goto next;
}
if (p->domain == VAR_DOMAIN
&& p->aclass == LOC_BLOCK
- && pc >= p->value.address
- && (p->value.address > best_pc
+ && pc >= p->address (objfile)
+ && (p->address (objfile) > best_pc
|| (psymtab->textlow == 0
- && best_pc == 0 && p->value.address == 0)))
+ && best_pc == 0 && p->address (objfile) == 0)))
{
if (section != NULL) /* Match on a specific section. */
{
section))
continue;
}
- best_pc = p->value.address;
+ best_pc = p->address (objfile);
best = p;
}
}
if (p->domain == VAR_DOMAIN
&& p->aclass == LOC_BLOCK
- && pc >= p->value.address
- && (p->value.address > best_pc
+ && pc >= p->address (objfile)
+ && (p->address (objfile) > best_pc
|| (psymtab->textlow == 0
- && best_pc == 0 && p->value.address == 0)))
+ && best_pc == 0 && p->address (objfile) == 0)))
{
if (section != NULL) /* Match on a specific section. */
{
section))
continue;
}
- best_pc = p->value.address;
+ best_pc = p->address (objfile);
best = p;
}
}
case LOC_STATIC:
case LOC_LABEL:
case LOC_BLOCK:
- addr = psym->value.address;
+ addr = psym->address (objfile);
break;
default:
/* Nothing else will be listed in the minsyms -- no use looking
{
fixup_psymbol_section (psym, objfile);
if (psym->section >= 0)
- psym->value.address += ANOFFSET (delta, psym->section);
+ psym->set_address (psym->unrelocated_address ()
+ + ANOFFSET (delta, psym->section));
}
for (partial_symbol *psym : objfile->static_psymbols)
{
fixup_psymbol_section (psym, objfile);
if (psym->section >= 0)
- psym->value.address += ANOFFSET (delta, psym->section);
+ psym->set_address (psym->unrelocated_address ()
+ + ANOFFSET (delta, psym->section));
}
objfile->psymbol_map.clear ();
}
static void
-print_partial_symbols (struct gdbarch *gdbarch,
+print_partial_symbols (struct gdbarch *gdbarch, struct objfile *objfile,
struct partial_symbol **p, int count, const char *what,
struct ui_file *outfile)
{
break;
}
fputs_filtered (", ", outfile);
- fputs_filtered (paddress (gdbarch, (*p)->value.address), outfile);
+ fputs_filtered (paddress (gdbarch, (*p)->unrelocated_address ()), outfile);
fprintf_filtered (outfile, "\n");
p++;
}
}
if (psymtab->n_global_syms > 0)
{
- print_partial_symbols (gdbarch,
+ print_partial_symbols (gdbarch, objfile,
&objfile->global_psymbols[psymtab->globals_offset],
psymtab->n_global_syms, "Global", outfile);
}
if (psymtab->n_static_syms > 0)
{
- print_partial_symbols (gdbarch,
+ print_partial_symbols (gdbarch, objfile,
&objfile->static_psymbols[psymtab->statics_offset],
psymtab->n_static_syms, "Static", outfile);
}
if (psym->aclass == LOC_STATIC)
{
- CORE_ADDR addr = psym->value.address;
+ CORE_ADDR addr = psym->address (objfile);
if (seen_addrs->find (addr) == seen_addrs->end ())
{
seen_addrs->insert (addr);
{
struct partial_symbol psymbol;
- psymbol.value.address = coreaddr;
+ psymbol.set_address (coreaddr);
psymbol.section = -1;
psymbol.domain = domain;
psymbol.aclass = theclass;