PIPS
loop.c File Reference
#include <stdio.h>
#include "linear.h"
#include "genC.h"
#include "misc.h"
#include "properties.h"
#include "ri.h"
#include "ri-util.h"
#include "text-util.h"
#include "prettyprint.h"
+ Include dependency graph for loop.c:

Go to the source code of this file.

Functions

void printf_loop (loop lp)
 ======================================================================= More...
 
void print_loops_list (entity mod, list sl)
 

Function Documentation

◆ print_loops_list()

void print_loops_list ( entity  mod,
list  sl 
)
Parameters
modod
sll

Definition at line 79 of file loop.c.

80 {
81  FOREACH(LOOP, l, sl) {
82  list pdl = NIL;
83  text t = text_loop(mod, entity_name(loop_label(l)), 2, l, 0, &pdl, true);
84  gen_free_list(pdl);
85  print_text(stderr,t);
86  }
87 }
#define NIL
The empty list (nil in Lisp)
Definition: newgen_list.h:47
void gen_free_list(list l)
free the spine of the list
Definition: list.c:327
#define FOREACH(_fe_CASTER, _fe_item, _fe_list)
Apply/map an instruction block on all the elements of a list.
Definition: newgen_list.h:179
text text_loop(entity module, const char *label, int margin, loop obj, int n, list *ppdl, bool is_recursive_p)
exported for conversion/look_for_nested_loops.c
Definition: misc.c:3264
#define LOOP(x)
LOOP.
Definition: ri.h:1606
#define entity_name(x)
Definition: ri.h:2790
#define loop_label(x)
Definition: ri.h:1646
The structure used to build lists in NewGen.
Definition: newgen_list.h:41
void print_text(FILE *fd, text t)
Definition: print.c:195

References entity_name, FOREACH, gen_free_list(), LOOP, loop_label, NIL, print_text(), and text_loop().

+ Here is the call graph for this function:

◆ printf_loop()

void printf_loop ( loop  lp)

=======================================================================

loop.c

void fprint_loop(fp, lp): print a loop.

AC 94/06/07 copied from reindexing/reindexing_utils.c for debugging

Parameters
lpp

Definition at line 48 of file loop.c.

48  {
49  FILE *fp = stdout;
50 
51  fprintf(fp,"\nLoop index information:");
53 
54  fprintf(fp,"\nDomaine (lower, upper, inc):");
57  fprintf(fp,", ");
60  fprintf(fp,", ");
63 
64  fprintf(fp,"\nLabel:");
66 
67  fprintf(fp,"\nExecution Type");
69  fprintf(fp, " ->sequentiel");
70  else
71  fprintf(fp, " ->parallele");
72 
73  fprintf(fp, "\nLocals: ");
75 
76  fprintf(fp,"\n");
77 }
#define CONS(_t_, _i_, _l_)
List element cell constructor (insert an element at the beginning of a list)
Definition: newgen_list.h:150
void fprint_entity_list(FILE *fp, list l)
void fprint_entity_list(FILE *fp,list l): prints a list of entities on file fp.
Definition: entity.c:3188
void fprint_list_of_exp(FILE *fp, list exp_l)
void fprint_list_of_exp(FILE *fp, list exp_l): prints in the file "fp" the list of expression "exp_l"...
Definition: expression.c:229
#define loop_execution(x)
Definition: ri.h:1648
#define range_upper(x)
Definition: ri.h:2290
#define ENTITY(x)
ENTITY.
Definition: ri.h:2755
#define range_increment(x)
Definition: ri.h:2292
#define EXPRESSION(x)
EXPRESSION.
Definition: ri.h:1217
#define execution_sequential_p(x)
Definition: ri.h:1208
#define loop_locals(x)
Definition: ri.h:1650
#define range_lower(x)
Definition: ri.h:2288
#define loop_range(x)
Definition: ri.h:1642
#define loop_index(x)
Definition: ri.h:1640
int fprintf()
test sc_min : ce test s'appelle par : programme fichier1.data fichier2.data ...

References CONS, ENTITY, execution_sequential_p, EXPRESSION, fprint_entity_list(), fprint_list_of_exp(), fprintf(), loop_execution, loop_index, loop_label, loop_locals, loop_range, NIL, range_increment, range_lower, and range_upper.

Referenced by loop_replace_variable().

+ Here is the call graph for this function:
+ Here is the caller graph for this function: