DCFG
Dynamic Control Flow Graph
 All Classes Functions
Public Member Functions | List of all members
dcfg_api::DCFG_LOOP_CONTAINER Class Referenceabstract

Common interface to any structure containing loops, i.e., routines, images, and processes. More...

#include <dcfg_api.H>

Inheritance diagram for dcfg_api::DCFG_LOOP_CONTAINER:
dcfg_api::DCFG_GRAPH_BASE dcfg_api::DCFG_ROUTINE dcfg_api::DCFG_ROUTINE_CONTAINER dcfg_api::DCFG_IMAGE dcfg_api::DCFG_IMAGE_CONTAINER dcfg_api::DCFG_PROCESS

Public Member Functions

virtual UINT32 get_loop_ids (DCFG_ID_CONTAINER &node_ids) const =0
 Get the set of loop IDs.
 
virtual DCFG_LOOP_CPTR get_loop_info (DCFG_ID loop_id) const =0
 Get access to data for a loop.
 
- Public Member Functions inherited from dcfg_api::DCFG_GRAPH_BASE
virtual UINT32 get_basic_block_ids (DCFG_ID_CONTAINER &node_ids) const =0
 Get IDs of all basic blocks in the structure.
 
virtual UINT32 get_internal_edge_ids (DCFG_ID_CONTAINER &edge_ids) const =0
 Get list of internal edge IDs.
 
virtual UINT32 get_inbound_edge_ids (DCFG_ID_CONTAINER &edge_ids) const =0
 Get list of in-bound edge IDs.
 
virtual UINT32 get_outbound_edge_ids (DCFG_ID_CONTAINER &edge_ids) const =0
 Get list of out-bound edge IDs.
 
virtual UINT64 get_instr_count () const =0
 Get the total dynamic instruction count.
 
virtual UINT64 get_instr_count_for_thread (UINT32 thread_id) const =0
 Get per-thread dynamic instruction count.
 

Detailed Description

Common interface to any structure containing loops, i.e., routines, images, and processes.

Note: even though loops can be nested, a loop is not considered a DCFG_LOOP_CONTAINER. Loop nesting structure can be determined by querying the parent loop id from a DCFG_LOOP object.

Member Function Documentation

virtual UINT32 dcfg_api::DCFG_LOOP_CONTAINER::get_loop_ids ( DCFG_ID_CONTAINER node_ids) const
pure virtual

Get the set of loop IDs.

Get IDs of all loops in the structure. A loop ID is the same as the ID of the basic block at its head node.

Returns
Number of IDs that were added to node_ids.
Parameters
[out]node_idsContainer to which IDs are added. Previous contents of the container are not emptied by this call, so it should be emptied by the programmer before the call if desired. The programmer can use any implementation of DCFG_ID_CONTAINER: DCFG_ID_VECTOR, DCFG_ID_SET, etc.
virtual DCFG_LOOP_CPTR dcfg_api::DCFG_LOOP_CONTAINER::get_loop_info ( DCFG_ID  loop_id) const
pure virtual

Get access to data for a loop.

Returns
Pointer to interface object for specified loop or NULL if loop_id is invalid.
Parameters
[in]loop_idID of desired loop.

The documentation for this class was generated from the following file: