GDB (xrefs)
Classes | Macros | Functions | Variables
/tmp/gdb-7.10/gdb/mn10300-tdep.c File Reference
#include "defs.h"
#include "arch-utils.h"
#include "dis-asm.h"
#include "gdbtypes.h"
#include "regcache.h"
#include "gdbcore.h"
#include "value.h"
#include "frame.h"
#include "frame-unwind.h"
#include "frame-base.h"
#include "symtab.h"
#include "dwarf2-frame.h"
#include "osabi.h"
#include "infcall.h"
#include "prologue-value.h"
#include "target.h"
#include "mn10300-tdep.h"

Go to the source code of this file.

Classes

struct  mn10300_prologue
 

Macros

#define MN10300_MAX_NUM_REGS   64
 

Functions

static int mn10300_type_align (struct type *type)
 
static int mn10300_use_struct_convention (struct type *type)
 
static void mn10300_store_return_value (struct gdbarch *gdbarch, struct type *type, struct regcache *regcache, const gdb_byte *valbuf)
 
static void mn10300_extract_return_value (struct gdbarch *gdbarch, struct type *type, struct regcache *regcache, void *valbuf)
 
static enum return_value_convention mn10300_return_value (struct gdbarch *gdbarch, struct value *function, struct type *type, struct regcache *regcache, gdb_byte *readbuf, const gdb_byte *writebuf)
 
static char * register_name (int reg, char **regs, long sizeof_regs)
 
static const char * mn10300_generic_register_name (struct gdbarch *gdbarch, int reg)
 
static const char * am33_register_name (struct gdbarch *gdbarch, int reg)
 
static const char * am33_2_register_name (struct gdbarch *gdbarch, int reg)
 
static struct typemn10300_register_type (struct gdbarch *gdbarch, int reg)
 
static CORE_ADDR mn10300_read_pc (struct regcache *regcache)
 
static void mn10300_write_pc (struct regcache *regcache, CORE_ADDR val)
 
static const unsigned char * mn10300_breakpoint_from_pc (struct gdbarch *gdbarch, CORE_ADDR *bp_addr, int *bp_size)
 
static void push_reg (pv_t *regs, struct pv_area *stack, int regnum)
 
static int translate_rreg (int rreg)
 
static void check_for_saved (void *result_untyped, pv_t addr, CORE_ADDR size, pv_t value)
 
static void mn10300_analyze_prologue (struct gdbarch *gdbarch, CORE_ADDR start_pc, CORE_ADDR limit_pc, struct mn10300_prologue *result)
 
static CORE_ADDR mn10300_skip_prologue (struct gdbarch *gdbarch, CORE_ADDR pc)
 
static struct mn10300_prologuemn10300_analyze_frame_prologue (struct frame_info *this_frame, void **this_prologue_cache)
 
static CORE_ADDR mn10300_frame_base (struct frame_info *this_frame, void **this_prologue_cache)
 
static struct frame_id mn10300_dummy_id (struct gdbarch *gdbarch, struct frame_info *this_frame)
 
static void mn10300_frame_this_id (struct frame_info *this_frame, void **this_prologue_cache, struct frame_id *this_id)
 
static struct valuemn10300_frame_prev_register (struct frame_info *this_frame, void **this_prologue_cache, int regnum)
 
static CORE_ADDR mn10300_unwind_pc (struct gdbarch *gdbarch, struct frame_info *this_frame)
 
static CORE_ADDR mn10300_unwind_sp (struct gdbarch *gdbarch, struct frame_info *this_frame)
 
static void mn10300_frame_unwind_init (struct gdbarch *gdbarch)
 
static CORE_ADDR mn10300_push_dummy_call (struct gdbarch *gdbarch, struct value *target_func, struct regcache *regcache, CORE_ADDR bp_addr, int nargs, struct value **args, CORE_ADDR sp, int struct_return, CORE_ADDR struct_addr)
 
static int mn10300_dwarf2_reg_to_regnum (struct gdbarch *gdbarch, int dwarf2)
 
static struct gdbarchmn10300_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
 
static void mn10300_dump_tdep (struct gdbarch *gdbarch, struct ui_file *file)
 
void _initialize_mn10300_tdep (void)
 

Variables

static const struct frame_unwind mn10300_frame_unwind
 
initialize_file_ftype _initialize_mn10300_tdep
 

Macro Definition Documentation

#define MN10300_MAX_NUM_REGS   64

Definition at line 41 of file mn10300-tdep.c.

Referenced by mn10300_analyze_prologue().

Function Documentation

void _initialize_mn10300_tdep ( void  )

Definition at line 1485 of file mn10300-tdep.c.

References gdbarch_register(), mn10300_dump_tdep(), and mn10300_gdbarch_init().

static const char* am33_2_register_name ( struct gdbarch gdbarch,
int  reg 
)
static

Definition at line 283 of file mn10300-tdep.c.

References register_name().

Referenced by mn10300_gdbarch_init().

static const char* am33_register_name ( struct gdbarch gdbarch,
int  reg 
)
static

Definition at line 271 of file mn10300-tdep.c.

References register_name().

Referenced by mn10300_gdbarch_init().

static void check_for_saved ( void *  result_untyped,
pv_t  addr,
CORE_ADDR  size,
pv_t  value 
)
static
static struct mn10300_prologue* mn10300_analyze_frame_prologue ( struct frame_info this_frame,
void **  this_prologue_cache 
)
static
static void mn10300_analyze_prologue ( struct gdbarch gdbarch,
CORE_ADDR  start_pc,
CORE_ADDR  limit_pc,
struct mn10300_prologue result 
)
static
static const unsigned char* mn10300_breakpoint_from_pc ( struct gdbarch gdbarch,
CORE_ADDR bp_addr,
int bp_size 
)
static

Definition at line 327 of file mn10300-tdep.c.

Referenced by mn10300_gdbarch_init().

static struct frame_id mn10300_dummy_id ( struct gdbarch gdbarch,
struct frame_info this_frame 
)
static
static void mn10300_dump_tdep ( struct gdbarch gdbarch,
struct ui_file file 
)
static

Definition at line 1474 of file mn10300-tdep.c.

References gdbarch_tdep::am33_mode, fprintf_unfiltered(), and gdbarch_tdep().

Referenced by _initialize_mn10300_tdep().

static int mn10300_dwarf2_reg_to_regnum ( struct gdbarch gdbarch,
int  dwarf2 
)
static
static void mn10300_extract_return_value ( struct gdbarch gdbarch,
struct type type,
struct regcache regcache,
void *  valbuf 
)
static
static CORE_ADDR mn10300_frame_base ( struct frame_info this_frame,
void **  this_prologue_cache 
)
static
static struct value* mn10300_frame_prev_register ( struct frame_info this_frame,
void **  this_prologue_cache,
int  regnum 
)
static
static void mn10300_frame_this_id ( struct frame_info this_frame,
void **  this_prologue_cache,
struct frame_id this_id 
)
static

Definition at line 1137 of file mn10300-tdep.c.

References frame_id_build(), get_frame_func(), and mn10300_frame_base().

static void mn10300_frame_unwind_init ( struct gdbarch gdbarch)
static
static struct gdbarch* mn10300_gdbarch_init ( struct gdbarch_info  info,
struct gdbarch_list arches 
)
static
static const char* mn10300_generic_register_name ( struct gdbarch gdbarch,
int  reg 
)
static

Definition at line 258 of file mn10300-tdep.c.

References register_name().

Referenced by mn10300_gdbarch_init().

static CORE_ADDR mn10300_push_dummy_call ( struct gdbarch gdbarch,
struct value target_func,
struct regcache regcache,
CORE_ADDR  bp_addr,
int  nargs,
struct value **  args,
CORE_ADDR  sp,
int  struct_return,
CORE_ADDR  struct_addr 
)
static
static CORE_ADDR mn10300_read_pc ( struct regcache regcache)
static

Definition at line 306 of file mn10300-tdep.c.

References E_PC_REGNUM, and regcache_cooked_read_unsigned().

Referenced by mn10300_gdbarch_init().

static struct type* mn10300_register_type ( struct gdbarch gdbarch,
int  reg 
)
static

Definition at line 300 of file mn10300-tdep.c.

References builtin_type::builtin_int, and builtin_type().

Referenced by mn10300_gdbarch_init().

static enum return_value_convention mn10300_return_value ( struct gdbarch gdbarch,
struct value function,
struct type type,
struct regcache regcache,
gdb_byte readbuf,
const gdb_byte writebuf 
)
static
static CORE_ADDR mn10300_skip_prologue ( struct gdbarch gdbarch,
CORE_ADDR  pc 
)
static
static void mn10300_store_return_value ( struct gdbarch gdbarch,
struct type type,
struct regcache regcache,
const gdb_byte valbuf 
)
static
static int mn10300_type_align ( struct type type)
static
static CORE_ADDR mn10300_unwind_pc ( struct gdbarch gdbarch,
struct frame_info this_frame 
)
static

Definition at line 1181 of file mn10300-tdep.c.

References E_PC_REGNUM, and frame_unwind_register_unsigned().

Referenced by mn10300_frame_unwind_init().

static CORE_ADDR mn10300_unwind_sp ( struct gdbarch gdbarch,
struct frame_info this_frame 
)
static
static int mn10300_use_struct_convention ( struct type type)
static
static void mn10300_write_pc ( struct regcache regcache,
CORE_ADDR  val 
)
static

Definition at line 314 of file mn10300-tdep.c.

References E_PC_REGNUM, and regcache_cooked_write_unsigned().

Referenced by mn10300_gdbarch_init().

static void push_reg ( pv_t regs,
struct pv_area stack,
int  regnum 
)
static

Definition at line 338 of file mn10300-tdep.c.

References E_SP_REGNUM, pv_add_constant(), and pv_area_store().

Referenced by mn10300_analyze_prologue().

static char* register_name ( int  reg,
char **  regs,
long  sizeof_regs 
)
static
static int translate_rreg ( int  rreg)
static

Definition at line 348 of file mn10300-tdep.c.

References E_A0_REGNUM, E_D0_REGNUM, and E_E0_REGNUM.

Referenced by mn10300_analyze_prologue().

Variable Documentation

initialize_file_ftype _initialize_mn10300_tdep
const struct frame_unwind mn10300_frame_unwind
static
Initial value:
= {
NULL,
}
static void mn10300_frame_this_id(struct frame_info *this_frame, void **this_prologue_cache, struct frame_id *this_id)
int default_frame_sniffer(const struct frame_unwind *self, struct frame_info *this_frame, void **this_prologue_cache)
Definition: frame-unwind.c:170
static struct value * mn10300_frame_prev_register(struct frame_info *this_frame, void **this_prologue_cache, int regnum)
enum unwind_stop_reason default_frame_unwind_stop_reason(struct frame_info *this_frame, void **this_cache)
Definition: frame-unwind.c:180

Definition at line 1171 of file mn10300-tdep.c.