class NstRDGStat : public NstGraph

Reduced dependence graph by statement

Inheritance:


Public Fields

string petit_input_file
Petit input file
string petit_output_file
Petit result file

Public Methods

int branch(int i)
Returns the position in loop
bool built()
Returns FALSE if the creation of the graph failed.
int nb_vertices()
Returns the number of vertices stored in the graph.
NstRDGStat(NstStatement* s, int type1 = 0, int type2 = 0)
Builds a reduced dependence graph by statement
void output_vcg(ostream &s)
Output the graph and infos into vcg format
NstStatement* statement(int i)
Returns the i-th statement in the graph. The statement number can be obtained by NstStatement::tag().
NstVertexSet* vertex(int i)
Returns the i-th vertex in the graph. The vertex number can be obtained by NstVertexSet::label().

Inherited from NstGraph:

Public Fields

NstEdgeList edges
NstVertexList vertices

Public Methods

NstGraph* clone(int deep = 0)
void copy(const NstGraph& s, int deep = 0)
void exec_vcg()
int graph_cc()
NstGraphList* graph_color()
int graph_scc()
NstGraph* merge_color()
void system_vcg()
int topological_sort()

Private Methods

friend ostream& operator << (ostream&, const NstGraph&)
friend ostream& operator << (ostream& s, const NstGraphList& glist)
Prints the list of graphs.

Documentation

Reduced dependence graph by statement.

The coherence of the structure depends on NstStatement::tag(), NstVertexSet::label() and an internal array of pointers to statements and vertices. At graph creation, all pointers to statements in the code, and to vertices in the vertex list of the graph are stored in the array. NstStatement::tag() is the place of a statement in the array, NstVertexSet::label() is the place of a vertex in the array. Warning: this array remains unchanged. Therefore, the user has to remember that the array contains pieces of information that were available at graph creation. If the list of vertices is destroyed, or if statements tags or vertexset labels are changed by the user, then the coherence may be lost. Howewer, changing the order in the vertex list has no consequence.

void output_vcg(ostream &s)
Output the graph and infos into vcg format

NstRDGStat(NstStatement* s, int type1 = 0, int type2 = 0)
Builds a reduced dependence graph by statement. Each vertex is a Nst_Vertex_Set.

Parameters:
s - only dependences that involve statements surrounded by the parameter s (typically a loop, or a region) are computed and stored.
type1 - If type1 = 0, a statement is any NstStatement. Otherwise, all statements within a NstStatementNestor are considered as a single statement.
type2 - If type2 = 0, all attributes of a loop (lower, upper bounds, and step) form a single vertex, otherwise each one corresponds to a different vertex.

NstStatement* statement(int i)
Returns the i-th statement in the graph. The statement number can be obtained by NstStatement::tag().

NstVertexSet* vertex(int i)
Returns the i-th vertex in the graph. The vertex number can be obtained by NstVertexSet::label().

int branch(int i)
Returns the position in loop. If type2 was not 0 at graph creation, branch(i) returns 0 if statement(i) is not a loop, otherwise returns 0 for the lower bound, 1 for the upper bound, and 2 for the step (if any). If type 2 was 0, then this is an error to use this method.

int nb_vertices()
Returns the number of vertices stored in the graph.

bool built()
Returns FALSE if the creation of the graph failed.

string petit_input_file
Petit input file. File given to Petit to analyze the code.

string petit_output_file
Petit result file. File produced by Petit.


This class has no child classes.

alphabetic index hierarchy of classes


this page has been generated automatically by doc++

(c)opyright by Malte Zöckler, Roland Wunderling
contact: doc++@zib.de