GDB (xrefs)
|
#include "defs.h"
#include "frame.h"
#include "frame-unwind.h"
#include "gdbcore.h"
#include "symtab.h"
#include "objfiles.h"
#include "osabi.h"
#include "regcache.h"
#include "regset.h"
#include "target.h"
#include "trad-frame.h"
#include "gdb_assert.h"
#include "gdb_string.h"
#include "amd64-tdep.h"
#include "i387-tdep.h"
#include "solib-svr4.h"
#include "bsd-uthread.h"
Go to the source code of this file.
Definition at line 353 of file amd64obsd-tdep.c.
Referenced by amd64obsd_trapframe_cache().
#define AMD64OBSD_UTHREAD_RSP_OFFSET 400 |
Definition at line 256 of file amd64obsd-tdep.c.
Referenced by amd64obsd_collect_uthread(), and amd64obsd_supply_uthread().
void _initialize_amd64obsd_tdep | ( | void | ) |
Definition at line 503 of file amd64obsd-tdep.c.
References AMD64_NUM_GREGS, amd64obsd_core_init_abi(), amd64obsd_init_abi(), amd64obsd_r_reg_offset, gdb_assert, GDB_OSABI_NETBSD_AOUT, GDB_OSABI_OPENBSD_ELF, and gdbarch_register_osabi().
static void amd64obsd_collect_uthread | ( | const struct regcache * | regcache, |
int | regnum, | ||
CORE_ADDR | addr | ||
) | [static] |
Definition at line 303 of file amd64obsd-tdep.c.
References AMD64_RIP_REGNUM, AMD64_RSP_REGNUM, amd64obsd_uthread_reg_offset, AMD64OBSD_UTHREAD_RSP_OFFSET, gdbarch::byte_order, extract_unsigned_integer(), gdb_assert, gdbarch_byte_order(), get_regcache_arch(), offset, read_memory_unsigned_integer(), regcache_raw_collect(), sp, write_memory(), and write_memory_unsigned_integer().
Referenced by amd64obsd_init_abi().
static void amd64obsd_core_init_abi | ( | struct gdbarch_info | info, |
struct gdbarch * | gdbarch | ||
) | [static] |
Definition at line 490 of file amd64obsd-tdep.c.
References amd64obsd_init_abi(), amd64obsd_regset_from_core_section(), and set_gdbarch_regset_from_core_section().
Referenced by _initialize_amd64obsd_tdep().
static void amd64obsd_init_abi | ( | struct gdbarch_info | info, |
struct gdbarch * | gdbarch | ||
) | [static] |
Definition at line 457 of file amd64obsd-tdep.c.
References amd64_init_abi(), amd64obsd_collect_uthread(), amd64obsd_r_reg_offset, amd64obsd_sc_reg_offset, amd64obsd_sigcontext_addr(), amd64obsd_sigtramp_p(), amd64obsd_supply_uthread(), bsd_uthread_set_collect_uthread(), bsd_uthread_set_supply_uthread(), frame_unwind_prepend_unwinder(), gdbarch_tdep(), gdbarch_tdep::gregset_num_regs, gdbarch_tdep::gregset_reg_offset, gdbarch_tdep::jb_pc_offset, gdbarch_tdep::sc_num_regs, gdbarch_tdep::sc_reg_offset, set_solib_svr4_fetch_link_map_offsets(), gdbarch_tdep::sigcontext_addr, gdbarch_tdep::sigtramp_p, gdbarch_tdep::sizeof_gregset, and svr4_lp64_fetch_link_map_offsets().
Referenced by _initialize_amd64obsd_tdep(), and amd64obsd_core_init_abi().
static struct regset* amd64obsd_regset_from_core_section | ( | struct gdbarch * | gdbarch, |
const char * | sect_name, | ||
size_t | sect_size | ||
) | [static, read] |
Definition at line 57 of file amd64obsd-tdep.c.
References amd64obsd_supply_regset(), gdbarch_tdep(), gdbarch_tdep::gregset, I387_SIZEOF_FXSAVE, regset_alloc(), and gdbarch_tdep::sizeof_gregset.
Referenced by amd64obsd_core_init_abi().
static CORE_ADDR amd64obsd_sigcontext_addr | ( | struct frame_info * | this_frame | ) | [static] |
Definition at line 139 of file amd64obsd-tdep.c.
References AMD64_RDI_REGNUM, AMD64_RSP_REGNUM, amd64obsd_page_size, get_frame_pc(), get_frame_register_unsigned(), offset, gdbarch_tdep::pc, and ULONGEST.
Referenced by amd64obsd_init_abi().
static int amd64obsd_sigtramp_p | ( | struct frame_info * | this_frame | ) | [static] |
Definition at line 86 of file amd64obsd-tdep.c.
References amd64obsd_page_size, find_pc_partial_function(), find_pc_section(), get_frame_pc(), memcmp(), name, gdbarch_tdep::pc, and safe_frame_unwind_memory().
Referenced by amd64obsd_init_abi().
static void amd64obsd_supply_regset | ( | const struct regset * | regset, |
struct regcache * | regcache, | ||
int | regnum, | ||
const void * | regs, | ||
size_t | len | ||
) | [static] |
Definition at line 43 of file amd64obsd-tdep.c.
References amd64_supply_fxsave(), regset::arch, gdb_assert, gdbarch_tdep(), i386_supply_gregset(), I387_SIZEOF_FXSAVE, and gdbarch_tdep::sizeof_gregset.
Referenced by amd64obsd_regset_from_core_section().
static void amd64obsd_supply_uthread | ( | struct regcache * | regcache, |
int | regnum, | ||
CORE_ADDR | addr | ||
) | [static] |
Definition at line 259 of file amd64obsd-tdep.c.
References AMD64_RIP_REGNUM, AMD64_RSP_REGNUM, amd64obsd_uthread_reg_offset, AMD64OBSD_UTHREAD_RSP_OFFSET, gdbarch::byte_order, gdb_assert, gdbarch_byte_order(), get_regcache_arch(), offset, read_memory(), read_memory_unsigned_integer(), regcache_raw_supply(), sp, and store_unsigned_integer().
Referenced by amd64obsd_init_abi().
static struct trad_frame_cache* amd64obsd_trapframe_cache | ( | struct frame_info * | this_frame, |
void ** | this_cache | ||
) | [static, read] |
Definition at line 356 of file amd64obsd-tdep.c.
References AMD64_CS_REGNUM, AMD64_RSP_REGNUM, amd64obsd_tf_reg_offset, gdbarch::byte_order, find_pc_partial_function(), frame_id_build(), func, gdbarch_byte_order(), get_frame_arch(), get_frame_func(), get_frame_register_unsigned(), I386_SEL_RPL, I386_SEL_UPL, name, outer_frame_id, read_memory_unsigned_integer(), sp, trad_frame_cache_zalloc(), trad_frame_set_id(), trad_frame_set_reg_addr(), and ULONGEST.
Referenced by amd64obsd_trapframe_prev_register(), and amd64obsd_trapframe_this_id().
static struct value* amd64obsd_trapframe_prev_register | ( | struct frame_info * | this_frame, |
void ** | this_cache, | ||
int | regnum | ||
) | [static, read] |
Definition at line 413 of file amd64obsd-tdep.c.
References amd64obsd_trapframe_cache(), and trad_frame_get_register().
static int amd64obsd_trapframe_sniffer | ( | const struct frame_unwind * | self, |
struct frame_info * | this_frame, | ||
void ** | this_prologue_cache | ||
) | [static] |
Definition at line 423 of file amd64obsd-tdep.c.
References AMD64_CS_REGNUM, find_pc_partial_function(), get_frame_pc(), get_frame_register_unsigned(), I386_SEL_RPL, I386_SEL_UPL, name, and ULONGEST.
static void amd64obsd_trapframe_this_id | ( | struct frame_info * | this_frame, |
void ** | this_cache, | ||
struct frame_id * | this_id | ||
) | [static] |
Definition at line 403 of file amd64obsd-tdep.c.
References amd64obsd_trapframe_cache(), and trad_frame_get_id().
const int amd64obsd_page_size = 4096 [static] |
Definition at line 80 of file amd64obsd-tdep.c.
Referenced by amd64obsd_sigcontext_addr(), and amd64obsd_sigtramp_p().
{ 14 * 8, 13 * 8, 3 * 8, 2 * 8, 1 * 8, 0 * 8, 12 * 8, 15 * 8, 4 * 8, 5 * 8, 6 * 8, 7 * 8, 8 * 8, 9 * 8, 10 * 8, 11 * 8, 16 * 8, 17 * 8, 18 * 8, 19 * 8, 20 * 8, 21 * 8, 22 * 8, 23 * 8 }
Definition at line 168 of file amd64obsd-tdep.c.
Referenced by _initialize_amd64obsd_nat(), _initialize_amd64obsd_tdep(), and amd64obsd_init_abi().
int amd64obsd_sc_reg_offset[] [static] |
{ 14 * 8, 13 * 8, 3 * 8, 2 * 8, 1 * 8, 0 * 8, 12 * 8, 24 * 8, 4 * 8, 5 * 8, 6 * 8, 7 * 8, 8 * 8, 9 * 8, 10 * 8, 11 * 8, 21 * 8, 23 * 8, 22 * 8, 25 * 8, 18 * 8, 17 * 8, 16 * 8, 15 * 8 }
Definition at line 197 of file amd64obsd-tdep.c.
Referenced by amd64obsd_init_abi().
struct frame_unwind amd64obsd_trapframe_unwind [static] |
{ NORMAL_FRAME, default_frame_unwind_stop_reason, amd64obsd_trapframe_this_id, amd64obsd_trapframe_prev_register, NULL, amd64obsd_trapframe_sniffer }
Definition at line 443 of file amd64obsd-tdep.c.
int amd64obsd_uthread_reg_offset[] [static] |
{ 19 * 8, 16 * 8, 18 * 8, 17 * 8, 14 * 8, 13 * 8, 15 * 8, -1, 12 * 8, 11 * 8, 10 * 8, 9 * 8, 8 * 8, 7 * 8, 6 * 8, 5 * 8, 20 * 8, 4 * 8, 21 * 8, -1, 3 * 8, 2 * 8, 1 * 8, 0 * 8 }
Definition at line 226 of file amd64obsd-tdep.c.
Referenced by amd64obsd_collect_uthread(), and amd64obsd_supply_uthread().