VIRTUTECH CONFIDENTIAL    Previous - Up - Next

symtable

Implemented By
symtable
Description
This is a collection of API calls for the symtable module, providing symbolic debugging support of the target machine.
typedef struct symtable_interface {
        attr_value_t (*eval_sym)(processor_t *cpu,
                                 const char *expr,
                                 attr_value_t *frame,
                                 const char *format);
Evaluates the symbolic expression expr in the given stack frame on the specified cpu. The result is the list (value, type) where value depends on the format, and type is a string describing the type of the result. If format is "v", then value is the value of the result as a string or integer; otherwise it is a human-readable string representation of the result. The only operators allowed in expr are casts, indirection and member selection (no arithmetic).
        attr_value_t (*stack_trace)(processor_t *cpu,
                                    int maxframes);
Does a stack trace in the current context of the specified cpu, and returns a list of stack frames (at most maxframes). Each stack frame is in turn a list of state variables, suitable for passing to eval_sym above, but has no defined structure other than that the first element is the program counter. This program counter points to the next instruction to be executed in respective frame.
        attr_value_t (*fun_args)(processor_t *cpu,
                                 attr_value_t *frame);
Given a stack frame, returns a list of the formal and actual parameters to the function where that frame is currently executing. Each element of the returned list is a list on the form (name, value).
        attr_value_t (*source_profile)(conf_object_t *symtable,
                                       conf_object_t *profile);
Find the corresponding source lines for profile values and return a list on the form ((source-file, (line, value) ...) ...).
} symtable_interface_t;

VIRTUTECH CONFIDENTIAL    Previous - Up - Next