GDB (xrefs)
|
#include "defs.h"
#include "arch-utils.h"
#include "bfdlink.h"
#include "symtab.h"
#include "gdbtypes.h"
#include "gdbcore.h"
#include "frame.h"
#include "target.h"
#include "value.h"
#include "symfile.h"
#include "objfiles.h"
#include "source.h"
#include "gdbcmd.h"
#include "breakpoint.h"
#include "language.h"
#include "complaints.h"
#include "demangle.h"
#include "inferior.h"
#include "regcache.h"
#include "filenames.h"
#include "gdb-stabs.h"
#include "gdb_obstack.h"
#include "completer.h"
#include "bcache.h"
#include "hashtab.h"
#include "readline/readline.h"
#include "block.h"
#include "observer.h"
#include "exec.h"
#include "parser-defs.h"
#include "varobj.h"
#include "elf-bfd.h"
#include "solib.h"
#include "remote.h"
#include "stack.h"
#include "gdb_bfd.h"
#include "cli/cli-utils.h"
#include <sys/types.h>
#include <fcntl.h>
#include <sys/stat.h>
#include <ctype.h>
#include <time.h>
#include <sys/time.h>
#include "psymtab.h"
Go to the source code of this file.
Classes | |
struct | registered_sym_fns |
struct | place_section_arg |
struct | load_section_data |
struct | load_progress_data |
struct | load_progress_section_data |
struct | filename_language |
Macros | |
#define | DEBUG_SUBDIRECTORY ".debug" |
Typedefs | |
typedef struct objfile * | objfilep |
Enumerations | |
enum | ovly_index { VMA, SIZE, LMA, MAPPED } |
Variables | |
int(* | deprecated_ui_load_progress_hook )(const char *section, unsigned long num) |
void(* | deprecated_show_load_progress )(const char *section, unsigned long section_sent, unsigned long section_size, unsigned long total_sent, unsigned long total_size) |
void(* | deprecated_pre_add_symbol_hook )(const char *) |
void(* | deprecated_post_add_symbol_hook )(void) |
int | readnow_symbol_files |
static const char * | print_symbol_loading = print_symbol_loading_full |
int | auto_solib_add = 1 |
int | currently_reading_symtab = 0 |
char * | debug_file_directory = NULL |
static int | validate_download = 0 |
static filename_language * | filename_language_table |
static int | fl_table_size |
static int | fl_table_next |
static char * | ext_args |
enum overlay_debugging_state | overlay_debugging = ovly_off |
int | overlay_cache_invalid = 0 |
static struct cmd_list_element * | overlaylist |
static unsigned(* | cache_ovly_table )[4] = 0 |
static unsigned | cache_novlys = 0 |
static CORE_ADDR | cache_ovly_table_base = 0 |
#define DEBUG_SUBDIRECTORY ".debug" |
Definition at line 1446 of file symfile.c.
Referenced by _initialize_symfile(), and find_separate_debug_file().
enum ovly_index |
void _initialize_symfile | ( | void | ) |
Definition at line 3954 of file symfile.c.
References _, add_cmd(), add_com_alias(), add_info(), add_prefix_cmd(), add_setshow_enum_cmd(), add_setshow_optional_filename_cmd(), add_setshow_string_noescape_cmd(), add_symbol_file_command(), class_alias, class_files, class_support, cmdlist, debug_file_directory, DEBUG_SUBDIRECTORY, ext_args, info_ext_lang_command(), init_filename_language_table(), list_overlays_command(), load_command(), map_overlay_command(), no_class, observer_attach_free_objfile(), overlay_auto_command(), overlay_command(), overlay_load_command(), overlay_manual_command(), overlay_off_command(), print_symbol_loading, remove_symbol_file_command(), set_cmd_completer(), set_ext_lang_command(), setlist, setprintlist, show_debug_file_directory(), show_ext_args(), showlist, showprintlist, symbol_file_command(), symfile_free_objfile(), and unmap_overlay_command().
void add_compunit_symtab_to_objfile | ( | struct compunit_symtab * | cu | ) |
Definition at line 2985 of file symfile.c.
References objfile::compunit_symtabs, compunit_symtab::next, and compunit_symtab::objfile.
Referenced by end_symtab_with_blockvector(), finalize_symtab(), get_java_class_symtab(), and new_symtab().
|
static |
Definition at line 2732 of file symfile.c.
References filename_language::ext, fl_table_next, fl_table_size, filename_language::lang, and xrealloc().
Referenced by init_filename_language_table(), and set_ext_lang_command().
|
static |
Definition at line 1907 of file symfile.c.
Referenced by generic_load().
|
static |
Definition at line 2232 of file symfile.c.
References _, add_target_sections_of_objfile(), other_sections::addr, alloc_section_addr_info(), do_cleanups(), dont_repeat(), error(), flags, gdb_buildargv(), get_current_arch(), make_cleanup(), make_cleanup_freeargv(), name, other_sections::name, null_cleanup(), section_addr_info::num_sections, OBJF_READNOW, OBJF_SHARED, OBJF_USERLOADED, section_addr_info::other, paddress(), parse_and_eval_address(), printf_unfiltered(), query(), reinit_frame_cache(), symbol_file_add(), SYMFILE_VERBOSE, xfree(), xmalloc(), and xrealloc().
Referenced by _initialize_symfile().
Definition at line 1800 of file symfile.c.
References VEC_safe_push.
Referenced by _initialize_coffread(), _initialize_dbxread(), _initialize_elfread(), _initialize_machoread(), _initialize_mipsread(), and _initialize_xcoffread().
void addr_info_make_relative | ( | struct section_addr_info * | addrs, |
bfd * | abfd | ||
) |
Definition at line 573 of file symfile.c.
References _, other_sections::addr, addr_section_name(), addrs_section_sort(), build_section_addr_info_from_bfd(), do_cleanups(), find_lowest_section(), gdb_assert, make_cleanup(), make_cleanup_free_section_addr_info(), other_sections::name, section_addr_info::num_sections, section_addr_info::other, other_sections::sectindex, warning(), xfree(), and xzalloc().
Referenced by objfile_relocate(), and syms_from_objfile_1().
Definition at line 521 of file symfile.c.
Referenced by addr_info_make_relative(), and addrs_section_compar().
Definition at line 535 of file symfile.c.
References addr_section_name(), other_sections::name, and other_sections::sectindex.
Referenced by addrs_section_sort().
|
static |
Definition at line 552 of file symfile.c.
References addrs_section_compar(), section_addr_info::num_sections, section_addr_info::other, qsort, and xmalloc().
Referenced by addr_info_make_relative().
struct section_addr_info* alloc_section_addr_info | ( | size_t | num_sections | ) |
Definition at line 249 of file symfile.c.
References size, and xmalloc().
Referenced by add_symbol_file_command(), build_section_addr_info_from_bfd(), build_section_addr_info_from_section_table(), jit_bfd_try_read_symtab(), symbol_file_add_from_memory(), and syms_from_objfile_1().
struct compunit_symtab* allocate_compunit_symtab | ( | struct objfile * | objfile, |
const char * | name | ||
) |
Definition at line 2954 of file symfile.c.
References COMPUNIT_DEBUGFORMAT, fprintf_unfiltered(), gdb_stdlog, host_address_to_string(), compunit_symtab::name, compunit_symtab::objfile, objfile::objfile_obstack, OBSTACK_ZALLOC, and symtab_create_debug.
Referenced by finalize_symtab(), get_java_class_symtab(), new_symtab(), and start_symtab().
struct symtab* allocate_symtab | ( | struct compunit_symtab * | cust, |
const char * | filename | ||
) |
Definition at line 2898 of file symfile.c.
References bcache(), symtab::compunit_symtab, deduce_language_from_filename(), symtab::filename, objfile_per_bfd_storage::filename_cache, compunit_symtab::filetabs, fprintf_unfiltered(), symtab::fullname, gdb_stdlog, host_address_to_string(), symtab::language, compunit_symtab::last_filetab, symtab::next, compunit_symtab::objfile, objfile_name(), objfile::objfile_obstack, OBSTACK_ZALLOC, objfile::per_bfd, symtab_create_debug, and xfree().
Referenced by dwarf_decode_lines(), end_symtab_with_blockvector(), finalize_symtab(), get_java_class_symtab(), new_symtab(), and setup_type_unit_groups().
|
static |
Definition at line 298 of file symfile.c.
References other_sections::addr, alloc_section_addr_info(), gdb_bfd_section_index(), other_sections::name, section_addr_info::num_sections, section_addr_info::other, and other_sections::sectindex.
Referenced by addr_info_make_relative(), and build_section_addr_info_from_objfile().
struct section_addr_info* build_section_addr_info_from_objfile | ( | const struct objfile * | objfile | ) |
Definition at line 322 of file symfile.c.
References other_sections::addr, build_section_addr_info_from_bfd(), section_addr_info::num_sections, objfile::obfd, section_offsets::offsets, section_addr_info::other, other_sections::sectindex, and objfile::section_offsets.
Referenced by objfile_relocate(), and symbol_file_add_separate().
struct section_addr_info* build_section_addr_info_from_section_table | ( | const struct target_section * | start, |
const struct target_section * | end | ||
) |
Definition at line 266 of file symfile.c.
References other_sections::addr, target_section::addr, alloc_section_addr_info(), gdb_bfd_section_index(), other_sections::name, section_addr_info::num_sections, section_addr_info::other, other_sections::sectindex, and target_section::the_bfd_section.
Referenced by solib_read_symbols().
|
static |
Definition at line 2048 of file symfile.c.
References memory_write_request::baton, memory_write_request::data, VEC(), VEC_free, VEC_iterate, and xfree().
Referenced by generic_load().
void clear_symtab_users | ( | int | add_flags | ) |
Definition at line 2996 of file symfile.c.
References breakpoint_re_set(), clear_current_source_symtab_and_line(), clear_displays(), clear_last_displayed_sal(), clear_pc_function_cache(), expression_context_block, innermost_block, observer_notify_new_objfile(), SYMFILE_DEFER_BP_RESET, and varobj_invalidate().
Referenced by clear_symtab_users_cleanup(), do_module_cleanup(), finish_new_objfile(), free_all_objfiles(), m32r_load(), m32r_upload_command(), remove_symbol_file_command(), and reread_symbols().
|
static |
Definition at line 3026 of file symfile.c.
References clear_symtab_users().
Referenced by reread_symbols(), and syms_from_objfile_1().
|
static |
Definition at line 201 of file symfile.c.
References currently_reading_symtab, and gdb_assert.
Referenced by increment_reading_symtab().
Definition at line 2880 of file symfile.c.
References fl_table_next, filename_language::lang, and language_unknown.
Referenced by allocate_symtab(), parse_partial_symbols(), patch_subfile_names(), read_dbx_symtab(), scan_xcoff_symtab(), start_psymtab(), start_subfile(), and xcoff_start_psymtab().
DEF_VEC_O | ( | registered_sym_fns | ) |
DEF_VEC_P | ( | objfilep | ) |
void default_symfile_offsets | ( | struct objfile * | objfile, |
const struct section_addr_info * | addrs | ||
) |
Definition at line 722 of file symfile.c.
References exec_set_section_address(), gdb_bfd_count_sections(), init_objfile_sect_indices(), place_section_arg::lowest, objfile::num_sections, objfile::obfd, objfile::objfile_obstack, place_section_arg::offsets, section_offsets::offsets, place_section(), relative_addr_info_to_section_offsets(), objfile::section_offsets, and SIZEOF_N_SECTION_OFFSETS.
Referenced by xcoff_symfile_offsets().
bfd_byte* default_symfile_relocate | ( | struct objfile * | objfile, |
asection * | sectp, | ||
bfd_byte * | buf | ||
) |
Definition at line 3740 of file symfile.c.
References symfile_dummy_outputs().
struct symfile_segment_data* default_symfile_segments | ( | bfd * | abfd | ) |
Definition at line 812 of file symfile.c.
References symfile_segment_data::num_segments, symfile_segment_data::segment_bases, symfile_segment_data::segment_info, and symfile_segment_data::segment_sizes.
void expand_symtabs_matching | ( | expand_symtabs_file_matcher_ftype * | file_matcher, |
expand_symtabs_symbol_matcher_ftype * | symbol_matcher, | ||
expand_symtabs_exp_notify_ftype * | expansion_notify, | ||
enum search_domain | kind, | ||
void * | data | ||
) |
Definition at line 3917 of file symfile.c.
References ALL_OBJFILES, quick_symbol_functions::expand_symtabs_matching, sym_fns::qf, and objfile::sf.
Referenced by ada_add_global_exceptions(), default_make_symbol_completion_list_break_on_1(), search_symbols(), and VEC().
void find_lowest_section | ( | bfd * | abfd, |
asection * | sect, | ||
void * | obj | ||
) |
Definition at line 228 of file symfile.c.
Referenced by addr_info_make_relative().
struct obj_section* find_pc_mapped_section | ( | CORE_ADDR | pc | ) |
Definition at line 3314 of file symfile.c.
References ALL_OBJSECTIONS, overlay_debugging, pc_in_mapped_range(), and section_is_mapped().
Referenced by backtrace_command_1(), block_for_pc(), blockvector_for_pc(), find_pc_compunit_symtab(), find_pc_function(), and find_pc_section().
struct obj_section* find_pc_overlay | ( | CORE_ADDR | pc | ) |
Definition at line 3287 of file symfile.c.
References ALL_OBJSECTIONS, overlay_debugging, pc_in_mapped_range(), pc_in_unmapped_range(), section_is_mapped(), and section_is_overlay().
Referenced by arm_linux_copy_svc(), build_address_symbolic(), call_function_by_hand_dummy(), convert_linespec_to_sals(), create_internal_breakpoint(), elf_gnu_ifunc_resolver_stop(), find_pc_line(), find_pc_partial_function_gnu_ifunc(), handle_step_into_function(), insert_hp_step_resume_breakpoint_at_frame(), insert_single_step_breakpoint(), insert_step_resume_breakpoint_at_caller(), memory_xfer_partial_1(), parse_probes(), process_event_stop_test(), and set_momentary_breakpoint_at_pc().
|
static |
Definition at line 1457 of file symfile.c.
References debug_file_directory, DEBUG_SUBDIRECTORY, do_cleanups(), gdb_sysroot, make_cleanup_free_char_ptr_vec(), separate_debug_file_exists(), VEC(), VEC_iterate, xfree(), and xmalloc().
Referenced by find_separate_debug_file_by_debuglink().
char* find_separate_debug_file_by_debuglink | ( | struct objfile * | objfile | ) |
Definition at line 1566 of file symfile.c.
References do_cleanups(), find_separate_debug_file(), make_cleanup(), objfile::obfd, objfile_name(), terminate_after_last_dir_separator(), and xfree().
Referenced by coff_symfile_read(), and elf_symfile_read().
Definition at line 1813 of file symfile.c.
References _, error(), registered_sym_fns::sym_flavour, registered_sym_fns::sym_fns, and VEC_iterate.
Referenced by get_symfile_segment_data(), reread_symbols(), and syms_from_objfile_1().
Definition at line 1103 of file symfile.c.
References breakpoint_re_set(), clear_complaints(), clear_symtab_users(), symfile_complaints, SYMFILE_DEFER_BP_RESET, SYMFILE_MAINLINE, symfile_objfile, and SYMFILE_VERBOSE.
Referenced by symbol_file_add_with_addrs().
void free_section_addr_info | ( | struct section_addr_info * | sap | ) |
Definition at line 343 of file symfile.c.
References other_sections::name, section_addr_info::num_sections, section_addr_info::other, and xfree().
Referenced by do_free_section_addr_info(), and solib_read_symbols().
void free_symfile_segment_data | ( | struct symfile_segment_data * | data | ) |
Definition at line 3794 of file symfile.c.
References symfile_segment_data::segment_bases, symfile_segment_data::segment_info, symfile_segment_data::segment_sizes, and xfree().
Referenced by get_offsets(), solib_target_relocate_section_addresses(), and symfile_find_segment_sections().
Remote targets may wish to use this as their load function.
Definition at line 2064 of file symfile.c.
References _, add_section_size_callback(), breakpoint_re_set(), clear_memory_write_data(), current_uiout, load_progress_data::data_count, do_cleanups(), error(), error_no_arg(), flash_discard, gdb_bfd_open(), gdb_buildargv(), gdb_stdout, gdbarch_addr_bits_remove(), get_current_regcache(), gnutarget, load_section_data::load_offset, load_progress(), load_section_callback(), make_cleanup(), make_cleanup_bfd_unref(), make_cleanup_freeargv(), null_cleanup(), paddress(), perror_with_name(), print_transfer_performance(), load_section_data::progress_data, regcache_write_pc(), strtoulst(), target_gdbarch(), target_write_memory_blocks(), load_progress_data::total_size, ui_out_field_fmt(), ui_out_text(), load_progress_data::write_count, and xfree().
Referenced by m32r_load_gen(), and remote_load().
Definition at line 1783 of file symfile.c.
References objfile::obfd.
Referenced by parse_partial_symbols(), and record_minimal_symbol().
struct symfile_segment_data* get_symfile_segment_data | ( | bfd * | abfd | ) |
Definition at line 3783 of file symfile.c.
References find_sym_fns(), and sym_fns::sym_segments.
Referenced by get_offsets(), solib_target_relocate_section_addresses(), and symfile_find_segment_sections().
struct cleanup* increment_reading_symtab | ( | void | ) |
Definition at line 211 of file symfile.c.
References currently_reading_symtab, decrement_reading_symtab(), gdb_assert, and make_cleanup().
Referenced by dw2_instantiate_symtab(), and psymtab_to_symtab().
|
static |
Definition at line 2817 of file symfile.c.
References _, fl_table_next, language_str(), and printf_filtered().
Referenced by _initialize_symfile().
|
static |
Definition at line 906 of file symfile.c.
References ALL_OBJFILE_OSECTIONS, current_target, objfile_per_bfd_storage::ei, entry_info::entry_point, entry_info::entry_point_p, gdb_bfd_section_index(), gdbarch_addr_bits_remove(), gdbarch_convert_from_func_ptr_addr(), get_objfile_arch(), entry_info::initialized, objfile::obfd, objfile::per_bfd, SECT_OFF_TEXT, obj_section::the_bfd_section, and entry_info::the_bfd_section_index.
Referenced by reread_symbols(), and syms_from_objfile().
|
static |
Definition at line 2830 of file symfile.c.
References add_filename_language(), fl_table_next, fl_table_size, language_ada, language_asm, language_c, language_cplus, language_d, language_fortran, language_java, language_objc, language_pascal, and xmalloc().
Referenced by _initialize_symfile().
|
static |
Definition at line 355 of file symfile.c.
References ANOFFSET, objfile::num_sections, objfile::obfd, objfile::sect_index_bss, objfile::sect_index_data, objfile::sect_index_rodata, objfile::sect_index_text, objfile::section_offsets, and symfile_find_segment_sections().
Referenced by default_symfile_offsets().
|
static |
Definition at line 3331 of file symfile.c.
References _, ALL_OBJSECTIONS, fputs_filtered(), gdb_stdout, get_objfile_arch(), name, objfile::obfd, overlay_debugging, paddress(), printf_filtered(), puts_filtered(), section_is_mapped(), size, and obj_section::the_bfd_section.
Referenced by _initialize_symfile().
|
static |
Definition at line 1836 of file symfile.c.
References cleanup::arg, do_cleanups(), dont_repeat(), get_exec_file(), make_cleanup(), null_cleanup(), overlay_cache_invalid, reopen_exec_file(), reread_symbols(), target_load(), xfree(), and xmalloc().
Referenced by _initialize_symfile().
|
static |
Definition at line 1944 of file symfile.c.
References _, load_progress_section_data::buffer, check(), check_quit_flag(), load_progress_section_data::cumulative, current_uiout, load_progress_data::data_count, deprecated_show_load_progress, deprecated_ui_load_progress_hook, do_cleanups(), error(), hex_string(), load_progress_section_data::lma, make_cleanup(), paddress(), load_progress_section_data::section_name, load_progress_section_data::section_sent, load_progress_section_data::section_size, target_gdbarch(), target_read_memory(), load_progress_data::total_size, ui_out_message(), validate_download, load_progress_data::write_count, xfree(), and xmalloc().
Referenced by generic_load().
|
static |
Definition at line 2008 of file symfile.c.
References memory_write_request::baton, memory_write_request::begin, load_progress_section_data::buffer, load_progress_section_data::cumulative, memory_write_request::data, memory_write_request::end, load_progress_section_data::lma, load_section_data::load_offset, load_section_data::progress_data, load_progress_section_data::section_name, load_progress_section_data::section_size, size, VEC_safe_push, xcalloc(), and xmalloc().
Referenced by generic_load().
|
static |
Definition at line 3371 of file symfile.c.
References _, ALL_OBJSECTIONS, error(), info_verbose, objfile::obfd, overlay_debugging, obj_section::ovly_mapped, printf_unfiltered(), section_is_overlay(), sections_overlap(), and obj_section::the_bfd_section.
Referenced by _initialize_symfile().
void map_symbol_filenames | ( | symbol_filename_ftype * | fun, |
void * | data, | ||
int | need_fullname | ||
) |
Definition at line 3940 of file symfile.c.
References ALL_OBJFILES, quick_symbol_functions::map_symbol_filenames, sym_fns::qf, and objfile::sf.
Referenced by mi_cmd_file_list_exec_source_files(), and sources_info().
|
static |
Definition at line 3446 of file symfile.c.
References _, enable_overlay_breakpoints(), info_verbose, overlay_debugging, ovly_auto, and printf_unfiltered().
Referenced by _initialize_symfile().
|
static |
Definition at line 3498 of file symfile.c.
References all_commands, gdb_stdout, help_list(), and printf_unfiltered().
Referenced by _initialize_symfile().
|
static |
Definition at line 3109 of file symfile.c.
References ALL_OBJSECTIONS, obj_section::ovly_mapped, and section_is_overlay().
Referenced by section_is_mapped().
|
static |
Definition at line 3481 of file symfile.c.
References _, error(), gdbarch_overlay_update(), gdbarch_overlay_update_p(), and get_current_arch().
Referenced by _initialize_symfile().
|
static |
Definition at line 3459 of file symfile.c.
References _, disable_overlay_breakpoints(), info_verbose, overlay_debugging, ovly_on, and printf_unfiltered().
Referenced by _initialize_symfile().
CORE_ADDR overlay_mapped_address | ( | CORE_ADDR | pc, |
struct obj_section * | section | ||
) |
Definition at line 3238 of file symfile.c.
References objfile::obfd, obj_section::objfile, pc_in_unmapped_range(), section_is_overlay(), and obj_section::the_bfd_section.
Referenced by build_address_symbolic(), find_pc_line(), find_pc_partial_function_gnu_ifunc(), memory_xfer_partial_1(), skip_prologue_sal(), and sym_info().
|
static |
Definition at line 3472 of file symfile.c.
References _, disable_overlay_breakpoints(), info_verbose, overlay_debugging, ovly_off, and printf_unfiltered().
Referenced by _initialize_symfile().
CORE_ADDR overlay_unmapped_address | ( | CORE_ADDR | pc, |
struct obj_section * | section | ||
) |
Definition at line 3219 of file symfile.c.
References objfile::obfd, obj_section::objfile, pc_in_mapped_range(), section_is_overlay(), and obj_section::the_bfd_section.
Referenced by address_info(), find_pc_partial_function_gnu_ifunc(), insert_bp_location(), skip_prologue_sal(), and symbol_overlayed_address().
CORE_ADDR pc_in_mapped_range | ( | CORE_ADDR | pc, |
struct obj_section * | section | ||
) |
Definition at line 3188 of file symfile.c.
References obj_section_addr, obj_section_endaddr, and section_is_overlay().
Referenced by find_pc_mapped_section(), find_pc_overlay(), and overlay_unmapped_address().
CORE_ADDR pc_in_unmapped_range | ( | CORE_ADDR | pc, |
struct obj_section * | section | ||
) |
Definition at line 3165 of file symfile.c.
References objfile::obfd, obj_section_offset, obj_section::objfile, offset, section_is_overlay(), size, and obj_section::the_bfd_section.
Referenced by build_address_symbolic(), find_pc_line(), find_pc_overlay(), find_pc_partial_function_gnu_ifunc(), memory_xfer_partial_1(), overlay_mapped_address(), and sym_info().
|
static |
Definition at line 425 of file symfile.c.
References gdb_bfd_section_index(), place_section_arg::lowest, place_section_arg::offsets, and section_offsets::offsets.
Referenced by default_symfile_offsets().
Definition at line 180 of file symfile.c.
References info_verbose, and print_symbol_loading.
Referenced by reload_shared_libraries_1(), solib_add(), and symbol_file_add_with_addrs().
void print_transfer_performance | ( | struct ui_file * | stream, |
unsigned long | data_count, | ||
unsigned long | write_count, | ||
const struct timeval * | start_time, | ||
const struct timeval * | end_time | ||
) |
Definition at line 2173 of file symfile.c.
References current_uiout, rate, ui_out_field_fmt(), ui_out_is_mi_like_p(), and ui_out_text().
Referenced by generic_load(), load_srec(), m32r_load(), and m32r_upload_command().
Definition at line 873 of file symfile.c.
References do_cleanups(), find_separate_debug_file_in_section(), make_cleanup_bfd_unref(), objfile_per_bfd_storage::minsyms_read, objfile_has_partial_symbols(), objfile::original_name, objfile::per_bfd, require_partial_symbols(), objfile::separate_debug_objfile, objfile::separate_debug_objfile_backlink, objfile::sf, sym_fns::sym_read, symbol_file_add_separate(), and SYMFILE_NO_READ.
Referenced by reread_symbols(), and syms_from_objfile_1().
|
static |
Definition at line 3563 of file symfile.c.
References extract_unsigned_integer(), len, and read_memory().
Referenced by simple_overlay_update_1(), and simple_read_overlay_table().
void relative_addr_info_to_section_offsets | ( | struct section_offsets * | section_offsets, |
int | num_sections, | ||
const struct section_addr_info * | addrs | ||
) |
Definition at line 490 of file symfile.c.
References other_sections::addr, section_addr_info::num_sections, section_offsets::offsets, section_addr_info::other, other_sections::sectindex, and SIZEOF_N_SECTION_OFFSETS.
Referenced by default_symfile_offsets(), and objfile_relocate().
|
static |
Definition at line 2387 of file symfile.c.
References _, ALL_OBJFILES, clear_symtab_users(), current_program_space, do_cleanups(), dont_repeat(), error(), objfile::flags, free_objfile(), gdb_buildargv(), get_current_arch(), is_addr_in_objfile(), make_cleanup(), null_cleanup(), OBJF_SHARED, OBJF_USERLOADED, objfile_name(), parse_and_eval_address(), objfile::pspace, query(), and xfree().
Referenced by _initialize_symfile().
void reread_symbols | ( | void | ) |
Definition at line 2467 of file symfile.c.
References _, all_cleanups(), build_objfile_section_table(), clear_complaints(), clear_symtab_users(), clear_symtab_users_cleanup(), objfile::compunit_symtabs, discard_cleanups(), do_cleanups(), error(), exec_bfd, exec_file_attach(), find_sym_fns(), objfile::flags, free_objfile_separate_debug(), objfile::free_psymtabs, gdb_bfd_open(), gdb_bfd_unref(), objfile::global_psymbols, gnutarget, init_entry_point_info(), psymbol_allocation_list::list, make_cleanup(), make_cleanup_bfd_unref(), make_cleanup_free_objfile(), objfile::mtime, objfile::next, objfile::num_sections, objfile::obfd, object_files, OBJF_PSYMTABS_READ, objfile_has_symbols(), objfile_name(), objfile::objfile_obstack, objfile_set_sym_fns(), objfiles_changed(), observer_notify_executable_changed(), observer_notify_new_objfile(), section_offsets::offsets, objfile::original_name, preserve_values(), printf_unfiltered(), psymbol_bcache_free(), psymbol_bcache_init(), objfile::psymbol_cache, objfile::psymtabs, objfile::psymtabs_addrmap, read_symbols(), reinit_frame_cache(), objfile::section_offsets, objfile::sections, objfile::separate_debug_objfile_backlink, set_objfile_per_bfd(), objfile::sf, SIZEOF_N_SECTION_OFFSETS, objfile::static_psymbols, sym_fns::sym_finish, sym_fns::sym_init, sym_fns::sym_new_init, symfile_complaints, symfile_objfile, objfile::template_symbols, terminate_minimal_symbol_table(), VEC(), VEC_cleanup, VEC_iterate, VEC_safe_push, wrap_here(), and xfree().
Referenced by attach_command_post_wait(), load_command(), remote_open_1(), and run_command_1().
int section_is_mapped | ( | struct obj_section * | osect | ) |
Definition at line 3129 of file symfile.c.
References gdbarch_overlay_update(), gdbarch_overlay_update_p(), get_objfile_arch(), obj_section::objfile, overlay_cache_invalid, overlay_debugging, overlay_invalidate_all(), ovly_auto, obj_section::ovly_mapped, ovly_off, ovly_on, and section_is_overlay().
Referenced by bkpt_breakpoint_hit(), bp_location_inserted_here_p(), breakpoint_here_p(), find_pc_mapped_section(), find_pc_overlay(), insert_bp_location(), is_addr_in_objfile(), jump_command(), list_overlays_command(), remove_breakpoint_1(), skip_prologue_sal(), sym_info(), and symbol_overlayed_address().
int section_is_overlay | ( | struct obj_section * | section | ) |
Definition at line 3089 of file symfile.c.
References objfile::obfd, obj_section::objfile, overlay_debugging, and obj_section::the_bfd_section.
Referenced by address_info(), bkpt_breakpoint_hit(), bp_location_inserted_here_p(), breakpoint_here_p(), clear_command(), find_pc_overlay(), insert_bp_location(), is_addr_in_objfile(), jump_command(), map_overlay_command(), overlay_invalidate_all(), overlay_mapped_address(), overlay_unmapped_address(), pc_in_mapped_range(), pc_in_unmapped_range(), remove_breakpoint_1(), section_is_mapped(), simple_overlay_update(), skip_prologue_sal(), spu_overlay_update(), sym_info(), and symbol_overlayed_address().
|
static |
Definition at line 3204 of file symfile.c.
References obj_section_addr, and obj_section_endaddr.
Referenced by map_overlay_command().
|
static |
Definition at line 1353 of file symfile.c.
References _, gdb_bfd_crc(), gdb_bfd_open(), gdb_bfd_unref(), gnutarget, objfile::obfd, objfile_name(), and warning().
Referenced by find_separate_debug_file().
|
static |
Definition at line 2759 of file symfile.c.
References _, add_filename_language(), error(), filename_language::ext, ext_args, fl_table_next, filename_language::lang, language_enum(), skip_spaces(), and xfree().
Referenced by _initialize_symfile().
void set_initial_language | ( | void | ) |
Definition at line 1692 of file symfile.c.
References current_language, expected_language, language_c, language_unknown, lookup_symbol(), main_language(), main_name(), name, set_language(), SYMBOL_LANGUAGE, and VAR_DOMAIN.
Referenced by follow_exec(), set_language_command(), and symbol_file_add_main_1().
|
static |
Definition at line 1436 of file symfile.c.
References _, and fprintf_filtered().
Referenced by _initialize_symfile().
|
static |
Definition at line 2749 of file symfile.c.
References _, and fprintf_filtered().
Referenced by _initialize_symfile().
|
static |
Definition at line 3550 of file symfile.c.
References cache_novlys, cache_ovly_table, cache_ovly_table_base, and xfree().
Referenced by simple_read_overlay_table().
void simple_overlay_update | ( | struct obj_section * | osect | ) |
Definition at line 3671 of file symfile.c.
References _, ALL_OBJSECTIONS, BMSYMBOL_VALUE_ADDRESS, cache_novlys, cache_ovly_table, cache_ovly_table_base, error(), LMA, lookup_minimal_symbol(), MAPPED, bound_minimal_symbol::minsym, objfile::obfd, obj_section::objfile, obj_section::ovly_mapped, section_is_overlay(), simple_overlay_update_1(), simple_read_overlay_table(), size, obj_section::the_bfd_section, and VMA.
Referenced by ft32_gdbarch_init(), m32r_gdbarch_init(), and moxie_gdbarch_init().
|
static |
Definition at line 3631 of file symfile.c.
References gdbarch::byte_order, cache_novlys, cache_ovly_table, cache_ovly_table_base, gdbarch_byte_order(), gdbarch_long_bit(), get_objfile_arch(), LMA, MAPPED, objfile::obfd, obj_section::objfile, obj_section::ovly_mapped, read_target_long_array(), size, TARGET_CHAR_BIT, obj_section::the_bfd_section, and VMA.
Referenced by simple_overlay_update().
|
static |
Definition at line 3579 of file symfile.c.
References _, BMSYMBOL_VALUE_ADDRESS, gdbarch::byte_order, cache_novlys, cache_ovly_table, cache_ovly_table_base, error(), gdbarch_byte_order(), gdbarch_long_bit(), get_objfile_arch(), lookup_bound_minimal_symbol(), lookup_minimal_symbol(), bound_minimal_symbol::minsym, bound_minimal_symbol::objfile, read_memory_integer(), read_target_long_array(), simple_free_overlay_table(), TARGET_CHAR_BIT, and xmalloc().
Referenced by simple_overlay_update().
struct objfile* symbol_file_add | ( | const char * | name, |
int | add_flags, | ||
struct section_addr_info * | addrs, | ||
int | flags | ||
) |
Definition at line 1288 of file symfile.c.
References do_cleanups(), make_cleanup_bfd_unref(), symbol_file_add_from_bfd(), and symfile_bfd_open().
Referenced by add_symbol_file_command(), follow_exec(), and symbol_file_add_main_1().
struct objfile* symbol_file_add_from_bfd | ( | bfd * | abfd, |
const char * | name, | ||
int | add_flags, | ||
struct section_addr_info * | addrs, | ||
int | flags, | ||
struct objfile * | parent | ||
) |
Definition at line 1276 of file symfile.c.
References symbol_file_add_with_addrs().
Referenced by compile_object_load(), jit_bfd_try_read_symtab(), macho_add_oso_symfile(), solib_read_symbols(), spu_symbol_file_add_from_memory(), symbol_file_add(), and symbol_file_add_from_memory().
Definition at line 1309 of file symfile.c.
References symbol_file_add_main_1().
Referenced by add_inferior_command(), captured_main(), clone_program_space(), exec_file_locate_attach(), and open_symbol_file_object().
Definition at line 1315 of file symfile.c.
References current_inferior(), reinit_frame_cache(), set_initial_language(), symbol_file_add(), inferior::symfile_flags, SYMFILE_MAINLINE, SYMFILE_NO_READ, and SYMFILE_VERBOSE.
Referenced by symbol_file_add_main(), and symbol_file_command().
void symbol_file_add_separate | ( | bfd * | bfd, |
const char * | name, | ||
int | symfile_flags, | ||
struct objfile * | objfile | ||
) |
Definition at line 1249 of file symfile.c.
References build_section_addr_info_from_objfile(), do_cleanups(), objfile::flags, make_cleanup_free_section_addr_info(), new_objfile(), OBJF_READNOW, OBJF_REORDERED, OBJF_SHARED, OBJF_USERLOADED, and symbol_file_add_with_addrs().
Referenced by coff_symfile_read(), elf_symfile_read(), macho_symfile_read(), objfpy_add_separate_debug_file(), and read_symbols().
|
static |
Definition at line 1145 of file symfile.c.
References _, add_separate_debug_objfile(), allocate_objfile(), deprecated_post_add_symbol_hook, deprecated_pre_add_symbol_hook, error(), quick_symbol_functions::expand_all_symtabs, finish_new_objfile(), gdb_flush(), gdb_stdout, have_full_symbols(), have_partial_symbols(), name, OBJF_MAINLINE, OBJF_READNOW, objfile_has_symbols(), observer_notify_new_objfile(), print_symbol_loading_p(), printf_unfiltered(), sym_fns::qf, query(), readnow_symbol_files, objfile::sf, SYMFILE_MAINLINE, SYMFILE_NO_READ, SYMFILE_VERBOSE, syms_from_objfile(), and wrap_here().
Referenced by symbol_file_add_from_bfd(), and symbol_file_add_separate().
void symbol_file_clear | ( | int | from_tty | ) |
Definition at line 1331 of file symfile.c.
References _, error(), free_all_objfiles(), gdb_assert, have_full_symbols(), have_partial_symbols(), no_shared_libraries(), objfile_name(), printf_unfiltered(), query(), and symfile_objfile.
Referenced by symbol_file_command().
void symbol_file_command | ( | char * | args, |
int | from_tty | ||
) |
Definition at line 1642 of file symfile.c.
References _, do_cleanups(), dont_repeat(), error(), flags, gdb_buildargv(), make_cleanup_freeargv(), name, OBJF_READNOW, OBJF_USERLOADED, symbol_file_add_main_1(), and symbol_file_clear().
Referenced by _initialize_symfile(), and file_command().
CORE_ADDR symbol_overlayed_address | ( | CORE_ADDR | address, |
struct obj_section * | section | ||
) |
Definition at line 3257 of file symfile.c.
References overlay_debugging, overlay_unmapped_address(), section_is_mapped(), and section_is_overlay().
Referenced by default_read_var_value(), and write_exp_msymbol().
bfd* symfile_bfd_open | ( | const char * | name | ) |
Definition at line 1721 of file symfile.c.
References _, do_cleanups(), error(), gdb_bfd_has_target_filename(), gdb_bfd_open(), gnutarget, is_target_filename(), make_cleanup(), make_cleanup_bfd_unref(), null_cleanup(), O_BINARY, openp(), OPF_RETURN_REALPATH, OPF_TRY_CWD_FIRST, perror_with_name(), and xfree().
Referenced by coff_symfile_read(), elf_symfile_read(), objfpy_add_separate_debug_file(), and symbol_file_add().
|
static |
Definition at line 3731 of file symfile.c.
Referenced by default_symfile_relocate().
|
static |
Definition at line 3860 of file symfile.c.
References free_symfile_segment_data(), get_symfile_segment_data(), symfile_segment_data::num_segments, objfile::obfd, objfile::sect_index_bss, objfile::sect_index_data, objfile::sect_index_rodata, objfile::sect_index_text, and symfile_segment_data::segment_info.
Referenced by init_objfile_sect_indices().
|
static |
Definition at line 3905 of file symfile.c.
References remove_target_sections().
Referenced by _initialize_symfile().
int symfile_map_offsets_to_segments | ( | bfd * | abfd, |
const struct symfile_segment_data * | data, | ||
struct section_offsets * | offsets, | ||
int | num_segment_bases, | ||
const CORE_ADDR * | segment_bases | ||
) |
Definition at line 3818 of file symfile.c.
References gdb_assert, symfile_segment_data::num_segments, section_offsets::offsets, symfile_segment_data::segment_bases, and symfile_segment_data::segment_info.
Referenced by get_offsets(), and solib_target_relocate_section_addresses().
bfd_byte* symfile_relocate_debug_section | ( | struct objfile * | objfile, |
asection * | sectp, | ||
bfd_byte * | buf | ||
) |
Definition at line 3774 of file symfile.c.
References gdb_assert, bound_minimal_symbol::objfile, objfile::sf, and sym_fns::sym_relocate.
Referenced by dbx_read_symtab(), dwarf2_read_section(), and elfstab_build_psymtabs().
|
static |
Definition at line 1090 of file symfile.c.
References init_entry_point_info(), and syms_from_objfile_1().
Referenced by symbol_file_add_with_addrs().
|
static |
Definition at line 1000 of file symfile.c.
References addr_info_make_relative(), alloc_section_addr_info(), clear_complaints(), clear_symtab_users_cleanup(), discard_cleanups(), find_sym_fns(), free_objfile(), gdb_assert, gdb_bfd_count_sections(), make_cleanup(), make_cleanup_free_objfile(), section_addr_info::num_sections, objfile::num_sections, objfile::obfd, objfile::objfile_obstack, objfile_set_sym_fns(), read_symbols(), objfile::section_offsets, objfile::sf, size, SIZEOF_N_SECTION_OFFSETS, sym_fns::sym_init, sym_fns::sym_new_init, sym_fns::sym_offsets, symfile_complaints, SYMFILE_MAINLINE, symfile_objfile, SYMFILE_VERBOSE, and xfree().
Referenced by syms_from_objfile().
|
static |
Definition at line 1548 of file symfile.c.
Referenced by find_separate_debug_file_by_debuglink().
|
static |
Definition at line 3416 of file symfile.c.
References _, ALL_OBJSECTIONS, error(), objfile::obfd, overlay_debugging, obj_section::ovly_mapped, and obj_section::the_bfd_section.
Referenced by _initialize_symfile().
|
static |
Definition at line 142 of file symfile.c.
Referenced by clear_memory_write_data(), find_separate_debug_file(), and reread_symbols().
int auto_solib_add = 1 |
Definition at line 168 of file symfile.c.
Referenced by _initialize_solib(), enable_break(), handle_solib_event(), post_create_inferior(), reload_shared_libraries(), reload_shared_libraries_1(), remote_start_remote(), and svr4_fetch_objfile_link_map().
|
static |
Definition at line 3540 of file symfile.c.
Referenced by simple_free_overlay_table(), simple_overlay_update(), simple_overlay_update_1(), and simple_read_overlay_table().
|
static |
Definition at line 3539 of file symfile.c.
Referenced by simple_free_overlay_table(), simple_overlay_update(), simple_overlay_update_1(), and simple_read_overlay_table().
|
static |
Definition at line 3541 of file symfile.c.
Referenced by simple_free_overlay_table(), simple_overlay_update(), simple_overlay_update_1(), and simple_read_overlay_table().
int currently_reading_symtab = 0 |
Definition at line 198 of file symfile.c.
Referenced by check_typedef(), decrement_reading_symtab(), and increment_reading_symtab().
char* debug_file_directory = NULL |
Search path for separate debug files.
Definition at line 1434 of file symfile.c.
Referenced by _initialize_symfile(), build_id_to_debug_bfd(), captured_main(), find_separate_debug_file(), open_dwo_file(), open_dwp_file(), try_open_dwop_file(), and VEC().
void(* deprecated_post_add_symbol_hook) (void) |
Definition at line 77 of file symfile.c.
Referenced by symbol_file_add_with_addrs().
void(* deprecated_pre_add_symbol_hook) (const char *) |
Definition at line 76 of file symfile.c.
Referenced by symbol_file_add_with_addrs().
void(* deprecated_show_load_progress) (const char *section, unsigned long section_sent, unsigned long section_size, unsigned long total_sent, unsigned long total_size) |
Definition at line 71 of file symfile.c.
Referenced by load_progress(), and mi_interpreter_resume().
Definition at line 69 of file symfile.c.
Referenced by load_progress(), load_srec(), mips_load_srec(), and pmon_load_fast().
|
static |
Definition at line 2747 of file symfile.c.
Referenced by _initialize_symfile(), and set_ext_lang_command().
|
static |
|
static |
Definition at line 2729 of file symfile.c.
Referenced by add_filename_language(), deduce_language_from_filename(), info_ext_lang_command(), init_filename_language_table(), and set_ext_lang_command().
|
static |
Definition at line 2729 of file symfile.c.
Referenced by add_filename_language(), and init_filename_language_table().
int overlay_cache_invalid = 0 |
Definition at line 3082 of file symfile.c.
Referenced by fetch_inferior_event(), infrun_thread_stop_requested_callback(), load_command(), prepare_for_detach(), section_is_mapped(), and wait_for_inferior().
enum overlay_debugging_state overlay_debugging = ovly_off |
Definition at line 3081 of file symfile.c.
Referenced by agent_command_1(), bkpt_breakpoint_hit(), bp_location_inserted_here_p(), breakpoint_has_pc(), breakpoint_here_p(), build_address_symbolic(), create_overlay_event_breakpoint(), default_read_var_value(), find_pc_mapped_section(), find_pc_overlay(), find_pc_sect_psymtab(), insert_bp_location(), insert_section_p(), list_overlays_command(), maint_agent_printf_command(), map_overlay_command(), memory_xfer_partial_1(), overlay_auto_command(), overlay_manual_command(), overlay_off_command(), remove_breakpoint_1(), section_is_mapped(), section_is_overlay(), symbol_overlayed_address(), unmap_overlay_command(), update_global_location_list(), and write_exp_msymbol().
|
static |
|
static |
Definition at line 156 of file symfile.c.
Referenced by _initialize_symfile(), and print_symbol_loading_p().
int readnow_symbol_files |
Definition at line 82 of file symfile.c.
Referenced by captured_main(), and symbol_file_add_with_addrs().
|
static |
Definition at line 1902 of file symfile.c.
Referenced by load_progress().