GDB (xrefs)
Macros | Functions | Variables
/tmp/gdb-7.10/gdb/spu-linux-nat.c File Reference
#include "defs.h"
#include "gdbcore.h"
#include "target.h"
#include "inferior.h"
#include "inf-child.h"
#include "inf-ptrace.h"
#include "regcache.h"
#include "symfile.h"
#include "gdb_wait.h"
#include "gdbthread.h"
#include "gdb_bfd.h"
#include <sys/ptrace.h>
#include <asm/ptrace.h>
#include <sys/types.h>
#include "spu-tdep.h"

Go to the source code of this file.

Macros

#define INSTR_SC   0x44000002
 
#define NR_spu_run   0x0116
 

Functions

static ULONGEST fetch_ppc_register (int regno)
 
static int fetch_ppc_memory_1 (int tid, ULONGEST memaddr, PTRACE_TYPE_RET *word)
 
static int store_ppc_memory_1 (int tid, ULONGEST memaddr, PTRACE_TYPE_RET word)
 
static int fetch_ppc_memory (ULONGEST memaddr, gdb_byte *myaddr, int len)
 
static int store_ppc_memory (ULONGEST memaddr, const gdb_byte *myaddr, int len)
 
static int parse_spufs_run (int *fd, ULONGEST *addr)
 
static enum target_xfer_status spu_proc_xfer_spu (const char *annex, gdb_byte *readbuf, const gdb_byte *writebuf, ULONGEST offset, ULONGEST len, ULONGEST *xfered_len)
 
static void * spu_bfd_iovec_open (struct bfd *nbfd, void *open_closure)
 
static int spu_bfd_iovec_close (struct bfd *nbfd, void *stream)
 
static file_ptr spu_bfd_iovec_pread (struct bfd *abfd, void *stream, void *buf, file_ptr nbytes, file_ptr offset)
 
static int spu_bfd_iovec_stat (struct bfd *abfd, void *stream, struct stat *sb)
 
static bfd * spu_bfd_open (ULONGEST addr)
 
static void spu_symbol_file_add_from_memory (int inferior_fd)
 
static void spu_child_post_startup_inferior (struct target_ops *self, ptid_t ptid)
 
static void spu_child_post_attach (struct target_ops *self, int pid)
 
static ptid_t spu_child_wait (struct target_ops *ops, ptid_t ptid, struct target_waitstatus *ourstatus, int options)
 
static void spu_fetch_inferior_registers (struct target_ops *ops, struct regcache *regcache, int regno)
 
static void spu_store_inferior_registers (struct target_ops *ops, struct regcache *regcache, int regno)
 
static enum target_xfer_status spu_xfer_partial (struct target_ops *ops, enum target_object object, const char *annex, gdb_byte *readbuf, const gdb_byte *writebuf, ULONGEST offset, ULONGEST len, ULONGEST *xfered_len)
 
static int spu_can_use_hw_breakpoint (struct target_ops *self, int type, int cnt, int othertype)
 
void _initialize_spu_nat (void)
 

Variables

initialize_file_ftype _initialize_spu_nat
 

Macro Definition Documentation

#define INSTR_SC   0x44000002

Definition at line 40 of file spu-linux-nat.c.

Referenced by parse_spufs_run().

#define NR_spu_run   0x0116

Definition at line 41 of file spu-linux-nat.c.

Referenced by parse_spufs_run().

Function Documentation

void _initialize_spu_nat ( void  )
static int fetch_ppc_memory ( ULONGEST  memaddr,
gdb_byte myaddr,
int  len 
)
static
static int fetch_ppc_memory_1 ( int  tid,
ULONGEST  memaddr,
PTRACE_TYPE_RET word 
)
static

Definition at line 88 of file spu-linux-nat.c.

References PT_READ_I, ptrace(), and PTRACE_TYPE_ARG3.

Referenced by fetch_ppc_memory(), and store_ppc_memory().

static ULONGEST fetch_ppc_register ( int  regno)
static
static int parse_spufs_run ( int fd,
ULONGEST addr 
)
static
static int spu_bfd_iovec_close ( struct bfd *  nbfd,
void *  stream 
)
static

Definition at line 285 of file spu-linux-nat.c.

References xfree().

Referenced by spu_bfd_open().

static void* spu_bfd_iovec_open ( struct bfd *  nbfd,
void *  open_closure 
)
static

Definition at line 279 of file spu-linux-nat.c.

Referenced by spu_bfd_open().

static file_ptr spu_bfd_iovec_pread ( struct bfd *  abfd,
void *  stream,
void *  buf,
file_ptr  nbytes,
file_ptr  offset 
)
static

Definition at line 294 of file spu-linux-nat.c.

References fetch_ppc_memory().

Referenced by spu_bfd_open().

static int spu_bfd_iovec_stat ( struct bfd *  abfd,
void *  stream,
struct stat *  sb 
)
static

Definition at line 309 of file spu-linux-nat.c.

References INT_MAX.

Referenced by spu_bfd_open().

static bfd* spu_bfd_open ( ULONGEST  addr)
static
static int spu_can_use_hw_breakpoint ( struct target_ops self,
int  type,
int  cnt,
int  othertype 
)
static

Definition at line 627 of file spu-linux-nat.c.

Referenced by _initialize_spu_nat().

static void spu_child_post_attach ( struct target_ops self,
int  pid 
)
static
static void spu_child_post_startup_inferior ( struct target_ops self,
ptid_t  ptid 
)
static
static ptid_t spu_child_wait ( struct target_ops ops,
ptid_t  ptid,
struct target_waitstatus ourstatus,
int  options 
)
static
static void spu_fetch_inferior_registers ( struct target_ops ops,
struct regcache regcache,
int  regno 
)
static
static enum target_xfer_status spu_proc_xfer_spu ( const char *  annex,
gdb_byte readbuf,
const gdb_byte writebuf,
ULONGEST  offset,
ULONGEST  len,
ULONGEST xfered_len 
)
static
static void spu_store_inferior_registers ( struct target_ops ops,
struct regcache regcache,
int  regno 
)
static
static void spu_symbol_file_add_from_memory ( int  inferior_fd)
static
static enum target_xfer_status spu_xfer_partial ( struct target_ops ops,
enum target_object  object,
const char *  annex,
gdb_byte readbuf,
const gdb_byte writebuf,
ULONGEST  offset,
ULONGEST  len,
ULONGEST xfered_len 
)
static
static int store_ppc_memory ( ULONGEST  memaddr,
const gdb_byte myaddr,
int  len 
)
static
static int store_ppc_memory_1 ( int  tid,
ULONGEST  memaddr,
PTRACE_TYPE_RET  word 
)
static

Definition at line 107 of file spu-linux-nat.c.

References PT_WRITE_D, ptrace(), and PTRACE_TYPE_ARG3.

Referenced by store_ppc_memory().

Variable Documentation

initialize_file_ftype _initialize_spu_nat