matrix.h File Reference

#include <stdio.h>
#include <clan/macros.h>
#include <scoplib/matrix.h>
#include <scoplib/vector.h>
#include <clan/vector.h>
Include dependency graph for matrix.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

void clan_matrix_tag_array (scoplib_matrix_p, int)
scoplib_matrix_p clan_matrix_scheduling (int *, int)
void clan_matrix_compact (scoplib_matrix_p, int, int)

Function Documentation

void clan_matrix_compact ( scoplib_matrix_p  matrix,
int  nb_iterators,
int  nb_parameters 
)

clan_matrix_compact function: This function compacts a matrix such that it uses the right number of columns (during construction we used CLAN_MAX_DEPTH and CLAN_MAX_PARAMETERS to define matrix and vector sizes). It modifies directly the matrix provided as parameter.

Parameters:
matrix The matrix to compact.
nb_iterators The true number of iterators for this matrix.
nb_parameters The true number of parameters in the SCoP.
  • 02/05/2008: first version.
  • 24/05/2008: nice bug fixed (p_Init_size was not copied, segfaulting later).

References CLAN_MAX_DEPTH.

Referenced by clan_statement_compact().

scoplib_matrix_p clan_matrix_scheduling ( int *  rank,
int  depth 
)

clan_matrix_scheduling function: this function builds the scheduling matrix for the clan_statement_t structures thanks to the parser current state of parser_scheduling (rank) and parser_depth (depth). The "rank" vector gives the "position" of the statement for every loop depth (see Feautrier's demonstration of existence of a schedule for any SCoP or CLooG's manual for original scattering function to understand if necessary). This function just "expands" this vector to a (2*n+1)-dimensional schedule for a statement at depth n and returns it.

Parameters:
rank The position of the statement at every loop depth.
depth The depth of the statement.
  • 01/05/2008: First version.

References CLAN_MAX_DEPTH, and CLAN_MAX_PARAMETERS.

Referenced by yyparse().

void clan_matrix_tag_array ( scoplib_matrix_p  matrix,
int  array 
)

clan_matrix_tag_array function: this function tags a matrix to explicit it is describing the array index of a given array. This means using SCoP representation that the very first element of the very first row will be the array number instead of zero. It updates directly the matrix provided as parameter.

Parameters:
matrix The matrix to tag.
array The array number.
  • 02/05/2008: first version.

Referenced by yyparse().


Generated on Mon Jan 11 21:20:38 2010 for Clan by  doxygen 1.6.1