25 #include "pips_config.h"
51 list nodes_l, su_l, df_l;
55 fprintf(fp,
"\n Array Data Flow Graph:\n");
56 fprintf(fp,
"=======================\n");
67 fprintf(fp,
"\nENTRY:\n******\n");
71 fprintf(fp,
"\nINS_%d:\n********\n", source_nb);
75 fprintf(fp,
" Execution Domain for %d:\n", source_nb);
78 else fprintf(fp,
" Execution Domain for %d: Nil\n", source_nb);
83 for( ; su_l !=
NIL; su_l =
CDR(su_l))
92 for( ; df_l !=
NIL; df_l =
CDR(df_l))
97 if(sink_nb != source_nb) {
100 fprintf(fp,
" Execution Domain for %d:\n", sink_nb);
110 #define ADFG_EXT ".adfg_file"
121 debug_on(
"PRINT_ARRAY_DFG__DEBUG_LEVEL" );
130 "/", localfilename, NULL));
169 fprintf(fp,
" quast_value_undefined\n");
194 fprintf(fp,
"quast_leafundefined\n");
243 char * (*variable_name)();
256 char signe = (char) NULL;
260 if (
value_pos_p(coeff)) signe = (debut) ?
' ' :
'+';
290 else if(is_what ==
IS_EG)
304 char * (*variable_name)();
314 char * (*variable_name)();
326 char * (*variable_name)();
357 fprintf(fp,
"\t\t Vecteur(s) de diffusion :");
363 fprintf(fp,
"\t\t Vecteur(s) de reduction :");
369 fprintf(fp,
"\t\t Vecteur(s) de shift :");
383 list nodes_l = NULL, su_l = NULL, df_l = NULL;
387 fprintf(fp,
"\n Array Data Flow Graph:\n");
388 fprintf(fp,
"=======================\n");
402 for( ; su_l !=
NIL; su_l =
CDR(su_l)){
408 for( ; df_l !=
NIL; df_l =
CDR(df_l))
427 for(aux_l = exp_l; aux_l !=
NIL; aux_l =
CDR(aux_l)) {
444 debug(9,
"adg_fprint_pred",
"begin\n");
450 debug(9,
"adg_fprint_pred",
"end\n");
510 debug(9,
"adg_fprint_predicate_list",
"begin\n");
511 for(; !
ENDP( sc_l );
POP( sc_l )) {
515 debug(9,
"adg_fprint_predicate_list",
"end\n");
void user_log(const char *format,...)
bool print_array_dfg(char *module_name) const
===========================================================================
void adg_fprint_sc_pvecteur(FILE *fp, Psysteme ps)
===========================================================================
void adg_fprint_psysteme(FILE *fp, Psysteme ps)
===========================================================================
static void adg_contrainte_fprint(FILE *fp, Pcontrainte c, int is_what, char *(*variable_name)())
===========================================================================
void adg_vecteur_fprint(FILE *fp, Pcontrainte vec, char *(*variable_name)())
===========================================================================
void adg_fprint_pred(FILE *fp, predicate pred)
===========================================================================
void fprint_dfg(FILE *fp, graph obj)
===========================================================================
void adg_fprint_list_of_exp(FILE *fp, list exp_l)
===========================================================================
void adg_fprint_dataflow(FILE *fp, int sink, dataflow df)
===========================================================================
void adg_inegalite_fprint(FILE *fp, Pcontrainte ineg, char *(*variable_name)())
===========================================================================
void adg_fprint_dfg(FILE *fp, graph obj)
===========================================================================
void adg_fprint_predicate_list(FILE *fp, list sc_l)
===========================================================================
void imprime_special_quast(FILE *fp, quast qu)
===========================================================================
void adg_egalite_fprint(FILE *fp, Pcontrainte eg, char *(*variable_name)())
===========================================================================
static int sink_stmt
Current source node.
static list trans_l
Current list of nodes.
static int source_stmt
Current sink statement.
static predicate exec_dom
Current governing predicate.
static reference ref
Current stmt (an integer)
static predicate gov_pred
Current expression.
#define value_oppose(ref)
#define value_notzero_p(val)
void const char const char const int
#define value_addto(ref, val)
void fprint_Value(FILE *, Value)
#define CONTRAINTE_UNDEFINED_P(c)
#define contrainte_vecteur(c)
passage au champ vecteur d'une contrainte "a la Newgen"
const char * module_name(const char *s)
Return the module part of an entity name.
FILE * safe_fopen(const char *filename, const char *what)
int safe_fclose(FILE *stream, const char *filename)
#define successor_vertex(x)
#define successor_arc_label(x)
struct _newgen_struct_graph_ * graph
#define vertex_vertex_label(x)
#define vertex_successors(x)
#define SUCCESSOR(x)
SUCCESSOR.
#define graph_vertices(x)
#define ENDP(l)
Test if a list is empty.
#define POP(l)
Modify a list pointer to point on the next element of the list.
#define NIL
The empty list (nil in Lisp)
#define CAR(pcons)
Get the value of the first element of a list.
#define CDR(pcons)
Get the list less its first element.
string db_get_memory_resource(const char *rname, const char *oname, bool pure)
Return the pointer to the resource, whatever it is.
#define DB_PUT_FILE_RESOURCE
Put a file resource into the current workspace database.
bool vect_check(Pvecteur cv)
bool vect_check(Pvecteur v): renvoie true si le vecteur v est coherent avec les specifications du pac...
#define pips_internal_error
int get_debug_level(void)
GET_DEBUG_LEVEL returns the current debugging level.
void debug(const int the_expected_debug_level, const char *calling_function_name, const char *a_message_format,...)
ARARGS0.
string concatenate(const char *,...)
Return the concatenation of the given strings.
int vertex_int_stmt(vertex)
===========================================================================
void fprint_psysteme(FILE *, Psysteme)
===========================================================================
void fprint_pred(FILE *, predicate)
===========================================================================
void fprint_dataflow(FILE *, int, dataflow)
===========================================================================
#define communication_shift(x)
#define conditional_true_quast(x)
#define dataflow_communication(x)
#define DATAFLOW(x)
DATAFLOW.
#define dataflow_transformation(x)
#define quast_value_undefined
#define leaf_label_statement(x)
@ is_quast_value_quast_leaf
@ is_quast_value_conditional
#define dfg_arc_label_dataflows(x)
#define conditional_false_quast(x)
#define communication_undefined
#define quast_leaf_solution(x)
#define quast_value_tag(x)
#define dataflow_governing_pred(x)
#define communication_reduction(x)
#define quast_leaf_undefined
#define leaf_label_undefined
#define dataflow_reference(x)
#define leaf_label_depth(x)
#define communication_broadcast(x)
#define quast_value_quast_leaf(x)
#define quast_leaf_leaf_label(x)
#define quast_quast_value(x)
#define dfg_vertex_label_exec_domain(x)
#define conditional_predicate(x)
#define quast_value_conditional(x)
string db_get_current_workspace_directory(void)
list words_expression(expression obj, list *ppdl)
This one is exported.
list words_reference(reference obj, list *ppdl)
graph the_dfg
The placement function.
const char * entity_local_name(entity e)
entity_local_name modified so that it does not core when used in vect_fprint, since someone thought t...
#define PREDICATE(x)
PREDICATE.
#define EXPRESSION(x)
EXPRESSION.
#define predicate_undefined
#define predicate_system(x)
struct Ssysteme * Psysteme
int fprintf()
test sc_min : ce test s'appelle par : programme fichier1.data fichier2.data ...
char * variable_name(Variable v)
polynome_ri.c
struct Scontrainte * succ
le type des coefficients dans les vecteurs: Value est defini dans le package arithmetique
The structure used to build lists in NewGen.
string words_to_string(cons *lw)
#define exp
Avoid some warnings from "gcc -Wshadow".
#define TCST
VARIABLE REPRESENTANT LE TERME CONSTANT.
#define VECTEUR_NUL
DEFINITION DU VECTEUR NUL.