GDB (xrefs)
|
#include "defs.h"
#include "compile-object-load.h"
#include "compile-internal.h"
#include "command.h"
#include "objfiles.h"
#include "gdbcore.h"
#include "readline/tilde.h"
#include "bfdlink.h"
#include "gdbcmd.h"
#include "regcache.h"
#include "inferior.h"
#include "compile.h"
#include "block.h"
#include "arch-utils.h"
Go to the source code of this file.
Classes | |
struct | munmap_list |
struct | setup_sections_data |
struct | link_hash_table_cleanup_data |
Functions | |
static void | munmap_list_add (struct munmap_list **headp, CORE_ADDR addr, CORE_ADDR size) |
void | munmap_list_free (struct munmap_list *head) |
static void | munmap_listp_free_cleanup (void *headp_voidp) |
static void | setup_sections (bfd *abfd, asection *sect, void *data_voidp) |
static bfd_boolean | link_callbacks_multiple_definition (struct bfd_link_info *link_info, struct bfd_link_hash_entry *h, bfd *nbfd, asection *nsec, bfd_vma nval) |
static bfd_boolean | link_callbacks_warning (struct bfd_link_info *link_info, const char *xwarning, const char *symbol, bfd *abfd, asection *section, bfd_vma address) |
static bfd_boolean | link_callbacks_undefined_symbol (struct bfd_link_info *link_info, const char *name, bfd *abfd, asection *section, bfd_vma address, bfd_boolean is_fatal) |
static bfd_boolean | link_callbacks_reloc_overflow (struct bfd_link_info *link_info, struct bfd_link_hash_entry *entry, const char *name, const char *reloc_name, bfd_vma addend, bfd *abfd, asection *section, bfd_vma address) |
static bfd_boolean | link_callbacks_reloc_dangerous (struct bfd_link_info *link_info, const char *message, bfd *abfd, asection *section, bfd_vma address) |
static bfd_boolean | link_callbacks_unattached_reloc (struct bfd_link_info *link_info, const char *name, bfd *abfd, asection *section, bfd_vma address) |
static void | link_callbacks_einfo (const char *fmt,...) ATTRIBUTE_PRINTF(1 |
static void | link_hash_table_free (void *d) |
static void | copy_sections (bfd *abfd, asection *sect, void *data) |
static struct type * | get_out_value_type (struct symbol *func_sym, struct objfile *objfile, enum compile_i_scope_types scope) |
static struct type * | get_regs_type (struct symbol *func_sym, struct objfile *objfile) |
static void | store_regs (struct type *regs_type, CORE_ADDR regs_base) |
struct compile_module * | compile_object_load (const char *object_file, const char *source_file, enum compile_i_scope_types scope, void *scope_data) |
Variables | |
static const struct bfd_link_callbacks | link_callbacks |
struct compile_module* compile_object_load | ( | const char * | object_file, |
const char * | source_file, | ||
enum compile_i_scope_types | scope, | ||
void * | scope_data | ||
) |
Definition at line 619 of file compile-object-load.c.
References _, BMSYMBOL_VALUE_ADDRESS, builtin_type::builtin_data_ptr, builtin_type(), builtin_type::builtin_void, check_typedef(), compile_debug, COMPILE_I_PRINT_ADDRESS_SCOPE, COMPILE_I_PRINT_VALUE_SCOPE, COMPILE_I_RAW_SCOPE, COMPILE_I_SIMPLE_SCOPE, copy_sections(), discard_cleanups(), do_cleanups(), error(), fprintf_unfiltered(), compile_module::func_sym, gdb_assert, gdb_bfd_errmsg(), gdb_bfd_open(), GDB_MMAP_PROT_READ, GDB_MMAP_PROT_WRITE, gdb_stdlog, gdbarch_infcall_mmap(), get_out_value_type(), get_regs_type(), gnu_ifunc_resolve_addr, gnutarget, internal_error(), setup_sections_data::last_max_alignment, setup_sections_data::last_prot, setup_sections_data::last_section_first, setup_sections_data::last_size, lookup_global_symbol_from_objfile(), lookup_minimal_symbol(), make_cleanup(), make_cleanup_bfd_unref(), make_cleanup_free_objfile(), bound_minimal_symbol::minsym, mst_text, mst_text_gnu_ifunc, mst_unknown, MSYMBOL_TYPE, munmap_list_add(), compile_module::munmap_list_head, setup_sections_data::munmap_list_headp, munmap_listp_free_cleanup(), compile_module::objfile, objfile_name(), objfile::objfile_obstack, compile_module::out_value_addr, compile_module::out_value_type, paddress(), compile_module::regs_addr, compile_module::scope, compile_module::scope_data, setup_sections(), compile_module::source_file, store_regs(), symbol_file_add_from_bfd(), SYMBOL_TYPE, target_gdbarch(), TYPE_CODE, TYPE_CODE_FUNC, TYPE_LENGTH, TYPE_NFIELDS, TYPE_TARGET_TYPE, types_deeply_equal(), VAR_DOMAIN, warning(), xfree(), and xmalloc().
Referenced by eval_compile_command().
|
static |
Definition at line 349 of file compile-object-load.c.
References _, link_hash_table_cleanup_data::abfd, do_cleanups(), error(), gdb_assert, link_callbacks, link_hash_table_free(), link_hash_table_cleanup_data::link_next, make_cleanup(), paddress(), target_gdbarch(), target_write_memory(), xfree(), and xmalloc().
Referenced by compile_object_load().
|
static |
Definition at line 428 of file compile-object-load.c.
References _, BLOCK_FUNCTION, block_lookup_symbol(), BLOCK_SUPERBLOCK, BLOCKVECTOR_BLOCK, BLOCKVECTOR_NBLOCKS, CHECK_TYPEDEF, COMPILE_I_EXPR_PTR_TYPE, COMPILE_I_EXPR_VAL, COMPILE_I_PRINT_ADDRESS_SCOPE, error(), GLOBAL_BLOCK, blockvector::nblocks, objfile_name(), symbol::owner, STATIC_BLOCK, SYMBOL_LINKAGE_NAME, SYMBOL_TYPE, symbol::symtab, SYMTAB_BLOCKVECTOR, TYPE_CODE, TYPE_CODE_ARRAY, TYPE_CODE_FUNC, TYPE_CODE_PTR, TYPE_TARGET_TYPE, types_deeply_equal(), and VAR_DOMAIN.
Referenced by compile_object_load().
Definition at line 532 of file compile-object-load.c.
References _, check_typedef(), error(), objfile_name(), SYMBOL_TYPE, TYPE_CODE, TYPE_CODE_PTR, TYPE_CODE_STRUCT, TYPE_FIELD_TYPE, TYPE_NFIELDS, and TYPE_TARGET_TYPE.
Referenced by compile_object_load().
|
static |
Definition at line 289 of file compile-object-load.c.
References _, do_cleanups(), make_cleanup(), warning(), xfree(), and xstrvprintf().
|
static |
Definition at line 202 of file compile-object-load.c.
|
static |
Definition at line 258 of file compile-object-load.c.
|
static |
Definition at line 245 of file compile-object-load.c.
|
static |
Definition at line 272 of file compile-object-load.c.
|
static |
Definition at line 232 of file compile-object-load.c.
|
static |
Definition at line 218 of file compile-object-load.c.
|
static |
Definition at line 337 of file compile-object-load.c.
References link_hash_table_cleanup_data::abfd, and link_hash_table_cleanup_data::link_next.
Referenced by copy_sections().
|
static |
Definition at line 47 of file compile-object-load.c.
References munmap_list::addr, munmap_list::next, munmap_list::size, size, and xmalloc().
Referenced by compile_object_load(), and setup_sections().
void munmap_list_free | ( | struct munmap_list * | head | ) |
Definition at line 63 of file compile-object-load.c.
References munmap_list::addr, gdbarch_infcall_munmap(), munmap_list::next, munmap_list::size, target_gdbarch(), and xfree().
Referenced by do_module_cleanup(), and munmap_listp_free_cleanup().
|
static |
Definition at line 80 of file compile-object-load.c.
References munmap_list_free().
Referenced by compile_object_load().
|
static |
Definition at line 112 of file compile-object-load.c.
References _, compile_debug, error(), fprintf_unfiltered(), GDB_MMAP_PROT_EXEC, GDB_MMAP_PROT_READ, GDB_MMAP_PROT_WRITE, gdb_stdlog, gdbarch_infcall_mmap(), setup_sections_data::last_max_alignment, setup_sections_data::last_prot, setup_sections_data::last_section_first, setup_sections_data::last_size, max, munmap_list_add(), setup_sections_data::munmap_list_headp, paddress(), and target_gdbarch().
Referenced by compile_object_load().
Definition at line 562 of file compile-object-load.c.
References _, check_typedef(), COMPILE_I_SIMPLE_REGISTER_DUMMY, compile_register_name_demangle(), error(), get_current_frame(), get_thread_regcache(), inferior_ptid, paddress(), pulongest(), reg_offset, regnum, target_gdbarch(), target_write_memory(), TYPE_CODE, TYPE_CODE_INT, TYPE_CODE_PTR, TYPE_FIELD_BITPOS, TYPE_FIELD_BITSIZE, TYPE_FIELD_NAME, TYPE_FIELD_TYPE, TYPE_LENGTH, TYPE_NFIELDS, value_contents(), value_entirely_available(), value_from_register(), and value_optimized_out().
Referenced by compile_object_load().
|
static |
Definition at line 309 of file compile-object-load.c.
Referenced by copy_sections().