address_profiler break_strings_v2
API Reference Manual  /  7 Simulator-to-Simulator Interfaces  / 

branch_arc

Description

Interface for getting branch arcs out profilers. The target is some kind of profiler whose data can be meaningfully viewed as branch arcs (usually a branch profiler).

iter returns a branch arc iterator that will visit all branch arcs in the range precisely once, in order of selected address (to or from, selected with dir), other address and type. In Python, it works just like any other iterator, and returns (from, to, counter, type) tuples. Note that you may not continue to use the iterator after the underlying profiler has been modified.

branch_arc_type_t defines the branch types returned by a branch arc iterator.

Branch_Arc_Branch
Normal branch operation
Branch_Arc_Exception
Branch because an exception was encountered
Branch_Arc_Exception_Return
Branch to finish an exception handler

typedef enum {
        Branch_Arc_Branch,
        Branch_Arc_Exception,
        Branch_Arc_Exception_Return,
        Branch_Arc_Max
} branch_arc_type_t;

typedef enum {
        BR_Direction_From,
        BR_Direction_To
} branch_recorder_direction_t;

SIM_INTERFACE(branch_arc) {
        branch_arc_iter_t *(*iter)(conf_object_t *prof_obj,
                                   generic_address_t start,
                                   generic_address_t stop,
                                   branch_recorder_direction_t dir);
};

#define BRANCH_ARC_INTERFACE "branch_arc"

Execution Context
Cell Context for all methods.

address_profiler break_strings_v2