GDB (API)
Defines | Enumerations | Functions
/home/stan/gdb/src/gdb/dictionary.c File Reference
#include "defs.h"
#include <ctype.h>
#include "gdb_obstack.h"
#include "symtab.h"
#include "buildsym.h"
#include "gdb_assert.h"
#include "dictionary.h"

Go to the source code of this file.

Defines

#define DICT_VECTOR(d)   (d)->vector
#define DICT_HASHED_NBUCKETS(d)   (d)->data.hashed.nbuckets
#define DICT_HASHED_BUCKETS(d)   (d)->data.hashed.buckets
#define DICT_HASHED_BUCKET(d, i)   DICT_HASHED_BUCKETS (d) [i]
#define DICT_HASHED_EXPANDABLE_NSYMS(d)   (d)->data.hashed_expandable.nsyms
#define DICT_LINEAR_NSYMS(d)   (d)->data.linear.nsyms
#define DICT_LINEAR_SYMS(d)   (d)->data.linear.syms
#define DICT_LINEAR_SYM(d, i)   DICT_LINEAR_SYMS (d) [i]
#define DICT_LINEAR_EXPANDABLE_CAPACITY(d)   (d)->data.linear_expandable.capacity
#define DICT_EXPANDABLE_INITIAL_CAPACITY   10
#define DICT_HASHTABLE_SIZE(n)   ((n)/5 + 1)
#define DICT_ITERATOR_DICT(iter)   (iter)->dict
#define DICT_ITERATOR_INDEX(iter)   (iter)->index
#define DICT_ITERATOR_CURRENT(iter)   (iter)->current

Enumerations

enum  dict_type { DICT_HASHED, DICT_HASHED_EXPANDABLE, DICT_LINEAR, DICT_LINEAR_EXPANDABLE }

Functions

struct dictionary * dict_create_hashed (struct obstack *obstack, const struct pending *symbol_list)
struct dictionary * dict_create_hashed_expandable (void)
struct dictionary * dict_create_linear (struct obstack *obstack, const struct pending *symbol_list)
struct dictionary * dict_create_linear_expandable (void)
void dict_free (struct dictionary *dict)
void dict_add_symbol (struct dictionary *dict, struct symbol *sym)
void dict_add_pending (struct dictionary *dict, const struct pending *symbol_list)
struct symboldict_iterator_first (const struct dictionary *dict, struct dict_iterator *iterator)
struct symboldict_iterator_next (struct dict_iterator *iterator)
struct symboldict_iter_name_first (const struct dictionary *dict, const char *name, struct dict_iterator *iterator)
struct symboldict_iter_name_next (const char *name, struct dict_iterator *iterator)
struct symboldict_iter_match_first (const struct dictionary *dict, const char *name, symbol_compare_ftype *compare, struct dict_iterator *iterator)
struct symboldict_iter_match_next (const char *name, symbol_compare_ftype *compare, struct dict_iterator *iterator)
int dict_size (const struct dictionary *dict)
int dict_empty (struct dictionary *dict)

Define Documentation

Definition at line 203 of file dictionary.c.

#define DICT_HASHED_BUCKET (   d,
 
)    DICT_HASHED_BUCKETS (d) [i]

Definition at line 188 of file dictionary.c.

#define DICT_HASHED_BUCKETS (   d)    (d)->data.hashed.buckets

Definition at line 187 of file dictionary.c.

#define DICT_HASHED_EXPANDABLE_NSYMS (   d)    (d)->data.hashed_expandable.nsyms

Definition at line 190 of file dictionary.c.

#define DICT_HASHED_NBUCKETS (   d)    (d)->data.hashed.nbuckets

Definition at line 186 of file dictionary.c.

#define DICT_HASHTABLE_SIZE (   n)    ((n)/5 + 1)

Definition at line 208 of file dictionary.c.

#define DICT_ITERATOR_CURRENT (   iter)    (iter)->current

Definition at line 221 of file dictionary.c.

#define DICT_ITERATOR_DICT (   iter)    (iter)->dict

Definition at line 215 of file dictionary.c.

#define DICT_ITERATOR_INDEX (   iter)    (iter)->index

Definition at line 218 of file dictionary.c.

#define DICT_LINEAR_EXPANDABLE_CAPACITY (   d)    (d)->data.linear_expandable.capacity

Definition at line 198 of file dictionary.c.

#define DICT_LINEAR_NSYMS (   d)    (d)->data.linear.nsyms

Definition at line 194 of file dictionary.c.

#define DICT_LINEAR_SYM (   d,
 
)    DICT_LINEAR_SYMS (d) [i]

Definition at line 196 of file dictionary.c.

#define DICT_LINEAR_SYMS (   d)    (d)->data.linear.syms

Definition at line 195 of file dictionary.c.

#define DICT_VECTOR (   d)    (d)->vector

Definition at line 182 of file dictionary.c.


Enumeration Type Documentation

enum dict_type
Enumerator:
DICT_HASHED 
DICT_HASHED_EXPANDABLE 
DICT_LINEAR 
DICT_LINEAR_EXPANDABLE 

Definition at line 90 of file dictionary.c.


Function Documentation

void dict_add_pending ( struct dictionary *  dict,
const struct pending symbol_list 
)

Definition at line 505 of file dictionary.c.

void dict_add_symbol ( struct dictionary *  dict,
struct symbol sym 
)

Definition at line 496 of file dictionary.c.

struct dictionary* dict_create_hashed ( struct obstack *  obstack,
const struct pending symbol_list 
) [read]

Definition at line 357 of file dictionary.c.

struct dictionary* dict_create_hashed_expandable ( void  ) [read]

Definition at line 401 of file dictionary.c.

struct dictionary* dict_create_linear ( struct obstack *  obstack,
const struct pending symbol_list 
) [read]

Definition at line 421 of file dictionary.c.

struct dictionary* dict_create_linear_expandable ( void  ) [read]

Definition at line 466 of file dictionary.c.

int dict_empty ( struct dictionary *  dict)

Definition at line 581 of file dictionary.c.

void dict_free ( struct dictionary *  dict)

Definition at line 488 of file dictionary.c.

struct symbol* dict_iter_match_first ( const struct dictionary *  dict,
const char *  name,
symbol_compare_ftype compare,
struct dict_iterator iterator 
) [read]

Definition at line 552 of file dictionary.c.

struct symbol* dict_iter_match_next ( const char *  name,
symbol_compare_ftype compare,
struct dict_iterator iterator 
) [read]

Definition at line 561 of file dictionary.c.

struct symbol* dict_iter_name_first ( const struct dictionary *  dict,
const char *  name,
struct dict_iterator iterator 
) [read]

Definition at line 538 of file dictionary.c.

struct symbol* dict_iter_name_next ( const char *  name,
struct dict_iterator iterator 
) [read]

Definition at line 546 of file dictionary.c.

struct symbol* dict_iterator_first ( const struct dictionary *  dict,
struct dict_iterator iterator 
) [read]

Definition at line 521 of file dictionary.c.

struct symbol* dict_iterator_next ( struct dict_iterator iterator) [read]

Definition at line 531 of file dictionary.c.

int dict_size ( const struct dictionary *  dict)

Definition at line 569 of file dictionary.c.

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Defines