GDB (xrefs)
Classes | Typedefs | Functions | Variables
/tmp/gdb-7.10/gdb/xml-syscall.c File Reference
#include "defs.h"
#include "gdbtypes.h"
#include "xml-support.h"
#include "xml-syscall.h"
#include "gdbarch.h"
#include "target.h"
#include "filenames.h"

Go to the source code of this file.

Classes

struct  syscall_desc
 
struct  syscalls_info
 
struct  syscall_parsing_data
 

Typedefs

typedef struct syscall_descsyscall_desc_p
 

Functions

 DEF_VEC_P (syscall_desc_p)
 
static struct syscalls_infoallocate_syscalls_info (void)
 
static void syscalls_info_free_syscalls_desc (struct syscall_desc *sd)
 
static void free_syscalls_info (void *arg)
 
static struct cleanupmake_cleanup_free_syscalls_info (struct syscalls_info *syscalls_info)
 
static void syscall_create_syscall_desc (struct syscalls_info *syscalls_info, const char *name, int number)
 
static void syscall_start_syscall (struct gdb_xml_parser *parser, const struct gdb_xml_element *element, void *user_data, VEC(gdb_xml_value_s)*attributes)
 
static struct syscalls_infosyscall_parse_xml (const char *document, xml_fetch_another fetcher, void *fetcher_baton)
 
static struct syscalls_infoxml_init_syscalls_info (const char *filename)
 
static void init_syscalls_info (struct gdbarch *gdbarch)
 
static int xml_get_syscall_number (struct gdbarch *gdbarch, const char *syscall_name)
 
static const char * xml_get_syscall_name (struct gdbarch *gdbarch, int syscall_number)
 
static const char ** xml_list_of_syscalls (struct gdbarch *gdbarch)
 
void set_xml_syscall_file_name (struct gdbarch *gdbarch, const char *name)
 
void get_syscall_by_number (struct gdbarch *gdbarch, int syscall_number, struct syscall *s)
 
void get_syscall_by_name (struct gdbarch *gdbarch, const char *syscall_name, struct syscall *s)
 
const char ** get_syscall_names (struct gdbarch *gdbarch)
 

Variables

static const struct gdb_xml_attribute syscall_attr []
 
static const struct gdb_xml_element syscalls_info_children []
 
static const struct gdb_xml_element syselements []
 

Typedef Documentation

typedef struct syscall_desc * syscall_desc_p

Function Documentation

static struct syscalls_info* allocate_syscalls_info ( void  )
static

Definition at line 118 of file xml-syscall.c.

Referenced by init_syscalls_info(), and syscall_parse_xml().

DEF_VEC_P ( syscall_desc_p  )
static void free_syscalls_info ( void *  arg)
static
void get_syscall_by_name ( struct gdbarch gdbarch,
const char *  syscall_name,
struct syscall s 
)

Definition at line 408 of file xml-syscall.c.

References init_syscalls_info(), syscall::name, syscall::number, and xml_get_syscall_number().

Referenced by VEC().

void get_syscall_by_number ( struct gdbarch gdbarch,
int  syscall_number,
struct syscall s 
)
const char** get_syscall_names ( struct gdbarch gdbarch)

Definition at line 418 of file xml-syscall.c.

References init_syscalls_info(), and xml_list_of_syscalls().

Referenced by VEC().

static void init_syscalls_info ( struct gdbarch gdbarch)
static
static struct cleanup* make_cleanup_free_syscalls_info ( struct syscalls_info syscalls_info)
static

Definition at line 151 of file xml-syscall.c.

References free_syscalls_info(), and make_cleanup().

Referenced by syscall_parse_xml().

void set_xml_syscall_file_name ( struct gdbarch gdbarch,
const char *  name 
)
static void syscall_create_syscall_desc ( struct syscalls_info syscalls_info,
const char *  name,
int  number 
)
static

Definition at line 157 of file xml-syscall.c.

References syscall_desc::name, syscall_desc::number, and VEC_safe_push.

Referenced by syscall_start_syscall().

static struct syscalls_info* syscall_parse_xml ( const char *  document,
xml_fetch_another  fetcher,
void *  fetcher_baton 
)
static
static void syscall_start_syscall ( struct gdb_xml_parser parser,
const struct gdb_xml_element element,
void *  user_data,
VEC(gdb_xml_value_s)*  attributes 
)
static
static void syscalls_info_free_syscalls_desc ( struct syscall_desc sd)
static

Definition at line 124 of file xml-syscall.c.

References syscall_desc::name, and xfree().

Referenced by free_syscalls_info().

static const char* xml_get_syscall_name ( struct gdbarch gdbarch,
int  syscall_number 
)
static
static int xml_get_syscall_number ( struct gdbarch gdbarch,
const char *  syscall_name 
)
static
static struct syscalls_info* xml_init_syscalls_info ( const char *  filename)
static
static const char** xml_list_of_syscalls ( struct gdbarch gdbarch)
static

Definition at line 367 of file xml-syscall.c.

References gdbarch_syscalls_info(), syscall_desc::name, VEC_iterate, VEC_length, and xmalloc().

Referenced by get_syscall_names().

Variable Documentation

const struct gdb_xml_attribute syscall_attr[]
static
Initial value:
= {
{ "name", GDB_XML_AF_NONE, NULL, NULL },
{ NULL, GDB_XML_AF_NONE, NULL, NULL }
}
gdb_xml_attribute_handler gdb_xml_parse_attr_ulongest

Definition at line 200 of file xml-syscall.c.

const struct gdb_xml_element syscalls_info_children[]
static
Initial value:
= {
{ "syscall", syscall_attr, NULL,
{ NULL, NULL, NULL, GDB_XML_EF_NONE, NULL, NULL }
}
static const struct gdb_xml_attribute syscall_attr[]
Definition: xml-syscall.c:200
static void syscall_start_syscall(struct gdb_xml_parser *parser, const struct gdb_xml_element *element, void *user_data, VEC(gdb_xml_value_s)*attributes)
Definition: xml-syscall.c:170

Definition at line 206 of file xml-syscall.c.

const struct gdb_xml_element syselements[]
static
Initial value:
= {
{ "syscalls_info", NULL, syscalls_info_children,
GDB_XML_EF_NONE, NULL, NULL },
{ NULL, NULL, NULL, GDB_XML_EF_NONE, NULL, NULL }
}
static const struct gdb_xml_element syscalls_info_children[]
Definition: xml-syscall.c:206

Definition at line 213 of file xml-syscall.c.