PIPS
|
#include "arithmetique.h"
Go to the source code of this file.
Data Structures | |
struct | Svecteur |
le type des coefficients dans les vecteurs: Value est defini dans le package arithmetique More... | |
Macros | |
#define | VECTEUR 1006 /**constante associee a un vecteur */ |
Warning! Do not modify this file that is automatically generated! More... | |
#define | VARIABLE_UNDEFINED ((Variable) 0) |
#define | VARIABLE_UNDEFINED_P(v) ((v)==VARIABLE_UNDEFINED) |
#define | VARIABLE_DEFINED_P(v) ((v)!=VARIABLE_UNDEFINED) |
#define | VECTEUR_NUL ((Pvecteur) 0) |
DEFINITION DU VECTEUR NUL. More... | |
#define | VECTEUR_NUL_P(v) ((v)==VECTEUR_NUL) |
#define | VECTEUR_UNDEFINED ((Pvecteur) 0) |
#define | VECTEUR_UNDEFINED_P(v) ((v)==VECTEUR_UNDEFINED) |
#define | PlinX Pvecteur |
definition de la valeur de type PlinX==Pvecteur qui correspond a un vecteur indefini parce que l'expression correspondante n'est pas lineaire (Malik Imadache, Jean Goubault ?) More... | |
#define | NONEXPLIN ((PlinX)-1) |
#define | print_vect(s) vect_fprint(stdout,(s)) |
MACROS SUR LES VECTEURS. More... | |
#define | var_of(varval) ((varval)->var) |
#define | val_of(varval) ((varval)->val) |
#define | vecteur_var(v) ((v)->var) |
#define | vecteur_val(v) ((v)->val) |
#define | vecteur_succ(v) ((v)->succ) |
#define | TCST ((Variable) 0) |
VARIABLE REPRESENTANT LE TERME CONSTANT. More... | |
#define | term_cst(varval) ((varval)->var == TCST) |
#define | BASE_NULLE VECTEUR_NUL |
MACROS SUR LES BASES. More... | |
#define | BASE_NULLE_P(b) ((b)==VECTEUR_NUL) |
#define | BASE_UNDEFINED ((Pbase) 0) |
#define | BASE_UNDEFINED_P(b) ((b)==BASE_UNDEFINED) |
#define | base_dimension(b) vect_size((Pvecteur)(b)) |
#define | base_add_dimension(b, v) vect_chg_coeff((Pvecteur *)(b),(v),VALUE_ONE) |
#define | base_rm(b) (vect_rm((Pvecteur)(b)), (b)=BASE_NULLE) |
#define | BASE_FOREACH(v, b) |
#define | OFL_CTRL 2 /**overflows are treated in the called procedure */ |
I do thing that overflows are managed in a very poor manner. More... | |
#define | FWD_OFL_CTRL 1 /**overflows are treated by the calling procedure */ |
#define | NO_OFL_CTRL 0 /**overflows are not trapped at all (dangerous !) */ |
Typedefs | |
typedef void * | Variable |
arithmetique is a requirement for vecteur, but I do not want to inforce it in all pips files... More... | |
typedef char *(* | get_variable_name_t) (Variable) |
typedef struct Svecteur | Svecteur |
le type des coefficients dans les vecteurs: Value est defini dans le package arithmetique More... | |
typedef struct Svecteur * | Pvecteur |
typedef struct Svecteur | Sbase |
STRUCTURE D'UNE BASE. More... | |
typedef struct Svecteur * | Pbase |
typedef struct linear_hashtable_st * | linear_hashtable_pt |
Functions | |
Pvecteur | vect_dup (Pvecteur) |
end of vecteur-local.h More... | |
void | vect_rm (Pvecteur) |
void vect_rm(Pvecteur v): desallocation des couples de v; More... | |
Pvecteur | vect_new (Variable, Value) |
Pvecteur vect_new(Variable var,Value coeff): allocation d'un vecteur colineaire au vecteur de base var et de coefficient coeff (i.e. More... | |
void | dbg_vect_rm (Pvecteur, char *) |
Pvecteur | vect_make (Pvecteur, Variable, Value,...) |
Pvecteur vect_make(v, [var, val,]* 0, val) Pvecteur v; // may be NULL, use assigne anyway Variable var; Value val;. More... | |
Pvecteur | vect_make_dense (Pbase, Value,...) |
Allocate a new vector v whose coefficient are given by the list of values ad whose dimension is given by b. More... | |
Pvecteur | vect_make_1D (Value, Variable, Value) |
Generate a sparse vector a x + b TCST. More... | |
Pbase | vect_copy (Pvecteur) |
direct duplication. More... | |
Pbase | base_dup (Pbase) |
Pbase base_dup(Pbase b) Note: this function changes the value of the pointer. More... | |
Pbase | base_copy (Pbase) |
Direct duplication. More... | |
Pvecteur | vect_add (Pvecteur, Pvecteur) |
binaires.c More... | |
Pvecteur | vect_substract (Pvecteur, Pvecteur) |
Pvecteur vect_substract(Pvecteur v1, Pvecteur v2): allocation d'un vecteur v dont la valeur est la difference des deux vecteurs v1 et v2. More... | |
Pvecteur | vect_substitute_dimension (Pvecteur, Variable, Pvecteur) |
Pvecteur vect_substitute_dimension(Pvecteur v, Variable i, Pvecteur s) More... | |
Pvecteur | vect_cl_ofl_ctrl (Pvecteur, Value, Pvecteur, int) |
Pvecteur vect_cl_ofl_ctrl(Pvecteur v, Value lambda, Pvecteur u, int ofl_ctrl): etape d'acculumulation dans une combinaison lineaire; aucun sharing entre v et u n'est cree (allocation implicite) Le controle de l'overflow est effectue et traite par le retour du contexte correspondant au dernier CATCH(overflow_error) effectue. More... | |
Pvecteur | vect_cl_ofl (Pvecteur, Value, Pvecteur) |
Pvecteur | vect_cl (Pvecteur, Value, Pvecteur) |
Pvecteur | vect_cl2_ofl_ctrl (Value, Pvecteur, Value, Pvecteur, int) |
Pvecteur vect_cl2_ofl(Value x1, Pvecteur v1, Value x2, Pvecteur v2): allocation d'un vecteur v dont la valeur est la combinaison lineaire des deux vecteurs v1 et v2 avec les coefficients respectifs x1 et x2 Le controle de l'overflow est effectue par vect_cl_ofl et traite par le retour du contexte correspondant au dernier CATCH(overflow_error) effectue. More... | |
Pvecteur | vect_cl2_ofl (Value, Pvecteur, Value, Pvecteur) |
Pvecteur | vect_cl2 (Value, Pvecteur, Value, Pvecteur) |
Pvecteur | vect_subst (Variable, Pvecteur, Pvecteur) |
Pvecteur vect_subst(Variable v, Pvecteur v1, Pvecteur v2): calcul d'un vecteur v3 tel que l'intersection des hyperplans definis par v1 et v2 soit egale a l'intersection des hyperplans definis par v1 et v3, et que v appartiennent a l'hyperplan defini par v3. More... | |
Pvecteur | vect_read (Pbase *) |
io.c More... | |
void | vect_fprint (FILE *, Pvecteur, get_variable_name_t) |
void vect_fprint(FILE * f, Pvecteur v, char * (*variable_name)()): impression d'un vecteur creux v sur le fichier f; le nom de chaque coordonnee est donne par la fonction variable_name() More... | |
void | vect_fprint_as_dense (FILE *, Pvecteur, Pbase) |
void vect_fprint_as_dense(FILE * f, Pvecteur v, Pbase b): More... | |
void | vect_fprint_as_monome (FILE *, Pvecteur, Pbase, get_variable_name_t, char *) |
void vect_fprint_as_monome(FILE * f, Pvecteur v, Pbase b, char * (*variable_name)(), char *mult_symbol): impression d'un vecteur creux considere comme un monome sans coefficient. More... | |
char * | vect_sprint_as_monome (Pvecteur, Pbase, get_variable_name_t, char *) |
char *vect_sprint_as_monome(Pvecteur v, Pbase b, char * (*variable_name)(), char *mult_symbol): Retourne dans une chaine le Pvecteur considere comme un monome sans coefficient. More... | |
void | vect_dump (Pvecteur) |
void vect_dump(Pvecteur v): print sparse vector v on stderr. More... | |
void | vect_print (Pvecteur, get_variable_name_t) |
void vect_print(Pvecteur v, char * (*variable_name)()): impression d'un vecteur creux v sur stdout; le nom de chaque coordonnee est donne par la fonction variable_name(); voir vect_fprint() More... | |
void | vect_fdump (FILE *, Pvecteur) |
void vect_fdump(FILE * f, Pvecteur v): impression d'un vecteur creux par vect_fprint() avec passage de la fonction variable_debug_name() More... | |
void | base_fprint (FILE *, Pbase, get_variable_name_t) |
void base_fprint(FILE * f, Pbase b, char * (*variable_name)()): impression d'une base sur le fichier f; le nom de chaque coordonnee est donne par la fonction variable_name() More... | |
int | vect_size (Pvecteur) |
reductions.c More... | |
int | vect_dimension (Pvecteur) |
int vect_dimension(Pvecteur v): calcul du nombre de composantes non nulles et non constantes d'un vecteur More... | |
Value | vect_prod_scal (Pvecteur, Pvecteur) |
Value vect_prod_scal(v1,v2): produit scalaire de v1 et de v2. More... | |
Value | vect_pgcd_all (Pvecteur) |
Value vect_pgcd(Pvecteur v): calcul du pgcd de tous les coefficients non nul d'un vecteur v. More... | |
Value | vect_pgcd_except (Pvecteur, Variable) |
Value vect_pgcd_except(Pvecteur v, Variable var): calcul du pgcd de tous les coefficients non nul d'un vecteur v, sauf le coefficient correspondant a la variable var. More... | |
Value | vect_max0 (Pvecteur) |
Value vect_max0(Pvecteur v): recherche du coefficient maximum d'un vecteur v; ce coefficient est toujours au moins egal a 0 car on ne dispose pas d'une base pour verifier que TOUS les coefficients sont negatifs. More... | |
Value | vect_min0 (Pvecteur) |
Value vect_min0(Pvecteur v): recherche du coefficient minimum d'un vecteur v; ce coefficient est toujours au moins egal a 0 car on ne dispose pas d'une base pour verifier que TOUS les coefficients sont negatifs. More... | |
Value | vect_min (Pvecteur) |
Value vect_min(Pvecteur v): recherche du coefficient non nul minimum d'un vecteur v; aborte sur le vecteur 0 puisqu'il faudrait renvoyer plus l'infini. More... | |
Value | vect_max (Pvecteur) |
Value vect_max(Pvecteur v): recherche du coefficient non nul maximum d'un vecteur v; aborte sur le vecteur 0 puisqu'il faudrait renvoyer plus l'infini. More... | |
Value | vect_sum (Pvecteur) |
Value vect_sum(Pvecteur v): somme des coefficients d'un vecteur (i.e. More... | |
bool | vect_equal (Pvecteur, Pvecteur) |
bool vect_equal(Pvecteur v1, Pvecteur v2): test a egalite de deux vecteurs More... | |
bool | vect_equal_except (Pvecteur, Pvecteur, Variable) |
bool vect_equal_except(Pvecteur v1, Pvecteur v2, Variable var): test a egalite des projections selon la coordonnees var de deux vecteurs -> Soit e un vecteur de base quelconque: -> -> -> -> return <v1 . More... | |
bool | vect_oppos (Pvecteur, Pvecteur) |
bool vect_oppos(Pvecteur v1, Pvecteur v2): test de l'opposition de deux vecteurs More... | |
bool | vect_opposite_except (Pvecteur, Pvecteur, Variable) |
bool vect_opposite_except(Pvecteur v1, Pvecteur v2, Variable var): test a egalite des projections selon la coordonnees var de deux vecteurs -> Soit e un vecteur de base quelconque: -> -> -> -> return <v1 . More... | |
int | vect_proport (Pvecteur, Pvecteur) |
int vect_proport(Pvecteur v1, Pvecteur v2): test de la colinearite de deux vecteurs et de leur direction. More... | |
bool | vect_colin_base (Pvecteur, Variable) |
bool vect_colin_base(Pvecteur vec, Variable var): renvoie true si --> --> vec = k var More... | |
bool | vect_check (Pvecteur) |
bool vect_check(Pvecteur v): renvoie true si le vecteur v est coherent avec les specifications du package; aucun des coefficients effectivement conserves en memoire ne doit etre nul (la cellule aurait du etre liberee) et aucune dimension (i.e. More... | |
bool | vect_consistent_p (Pvecteur) |
To ease retrieval of vect_check() More... | |
bool | vect_larger_coef_p (Pvecteur, Value) |
void | vect_normalize (Pvecteur) |
unaires.c More... | |
void | vect_add_elem (Pvecteur *, Variable, Value) |
void vect_add_elem(Pvecteur * pvect, Variable var, Value val): addition d'un vecteur colineaire au vecteur de base var au vecteur vect More... | |
void | vect_erase_var (Pvecteur *, Variable) |
void vect_erase_var(Pvecteur * ppv, Variable v): projection du vecteur *ppv selon la direction v (i.e. More... | |
void | vect_chg_coeff (Pvecteur *, Variable, Value) |
void vect_chg_coeff(Pvecteur *ppv, Variable var, Value val): mise de la coordonnee var du vecteur *ppv a la valeur val More... | |
void | vect_chg_var (Pvecteur *, Variable, Variable) |
void vect_chg_var(Pvecteur *ppv, Variable v_old, Variable v_new) replace the variable v_old by v_new More... | |
Variable | vect_one_coeff_if_any (Pvecteur) |
Pvecteur | vect_del_var (Pvecteur, Variable) |
Pvecteur vect_del_var(Pvecteur v_in, Variable var): allocation d'un nouveau vecteur egal a la projection de v_in selon la direction var (i.e. More... | |
Value | vect_coeff (Variable, Pvecteur) |
Variable vect_coeff(Variable var, Pvecteur vect): coefficient de coordonnee var du vecteur vect —> Soit evar le vecteur de base de nom var: More... | |
Value | vect_coeff_sum (Pvecteur) |
Value vect_coeff_sum(Pvecteur vect): coefficient sum de tout les val de ce vecteur (devrait etre dans reduction? FC) More... | |
Pvecteur | vect_sign (Pvecteur) |
Pvecteur vect_sign(Pvecteur v): application de l'operation signe au vecteur v. More... | |
void | vect_sort_in_place (Pvecteur *, int(*)(Pvecteur *, Pvecteur *)) |
Pvecteur | vect_sort (Pvecteur, int(*)(Pvecteur *, Pvecteur *)) |
int | vect_compare (Pvecteur *, Pvecteur *) |
for qsort, returns: More... | |
void | Pvecteur_separate_on_sign (Pvecteur, Pvecteur *, Pvecteur *) |
void Pvecteur_separate_on_sign(v, pvpos, pvneg) Pvecteur v, *pvpos, *pvneg; More... | |
bool | vect_common_variables_p (Pvecteur, Pvecteur) |
bool vect_common_variables_p(Pvecteur v1, v2) BA 19/05/94 input : two vectors. More... | |
bool | vect_contains_variable_p (Pvecteur, Variable) |
bool vect_contains_variable_p(Pvecteur v, Variable var) BA 19/05/94 input : a vector and a variable output : true if var appears as a component of v, false otherwise. More... | |
int | vect_lexicographic_compare (Pvecteur, Pvecteur, int(*)(Pvecteur *, Pvecteur *)) |
qsort() is not safe if the comparison function is not antisymmetric. More... | |
int | vect_lexicographic_compare2 (Pvecteur, Pvecteur, int(*)(Pvecteur *, Pvecteur *)) |
Version for inequalities. More... | |
int | vect_lexicographic_unsafe_compare (Pvecteur, Pvecteur, int(*)(Pvecteur *, Pvecteur *)) |
int | vect_lexicographic_unsafe_compare2 (Pvecteur, Pvecteur, int(*)(Pvecteur *, Pvecteur *)) |
int | vect_lexicographic_unsafe_compare_generic (Pvecteur, Pvecteur, int(*)(Pvecteur *, Pvecteur *), bool) |
Pbase | vect_add_variable (Pbase, Variable) |
base.c More... | |
Pbase | base_add_variable (Pbase, Variable) |
Pbase base_add_variable(Pbase b, Variable v): add variable v as a new dimension to basis b at the end of the base list; if variable v is already in basis b, do nothing; this is not clean but convenient to avoid a test;. More... | |
Pbase | make_base_from_vect (Pvecteur) |
Pbase | base_remove_variable (Pbase, Variable) |
Pbase base_remove_variable(b, v): remove basis vector relative to v from b; abort if v is not in b;. More... | |
bool | base_contains_variable_p (Pbase, Variable) |
bool base_contains_variable_p(Pbase b, Variable v): returns true if variable v is one of b's elements; More... | |
Variable | base_find_variable (Pbase, Variable) |
Variable base_find_variable(Pbase b, Variable v): returns variable v if variable v is one of b's elements (returns a pointer to the copy of v that's pointed to by basis b); else returns VARIABLE_UNDEFINED. More... | |
Variable | base_find_variable_name (Pbase, Variable, char *(*)(Variable)) |
int | base_find_variable_rank (Pbase, Variable, char *(*)(Variable)) |
Pbase | base_reversal (Pbase) |
Pbase base_reversal(Pbase b_in): produces a basis b_out, having the same basis vectors as b_in, but in reverse order. More... | |
Pvecteur | vect_rename (Pvecteur, Pbase, char *(*)(Variable)) |
Pvecteur | vect_rename_variables (Pvecteur, bool(*)(Variable), Variable(*)(Variable)) |
Pvecteur vect_rename_variables(v, renamed_p, new_variable) Pvecteur v; bool (*renamed_p)(Variable); Variable (*new_variable)(Variable);. More... | |
Pvecteur | vect_translate (Pvecteur, Pbase, char *(*)(Variable)) |
bool | vect_in_basis_p (Pvecteur, Pbase) |
Pvecteur vect_in_basis_p(Pvecteur v, Pbase b): check that all coordinates in v are in b, i.e. More... | |
Pvecteur | vect_variable_rename (Pvecteur, Variable, Variable) |
Pvecteur vect_variable_rename(Pvecteur v, Variable v_old, Variable v_new): rename the potential coordinate v_old in v as v_new. More... | |
void | base_append (Pbase *, Pbase) |
appends b2 to b1. More... | |
Pbase | base_union (Pbase, Pbase) |
Pbase base_union(Pbase b1, Pbase b2): compute a new basis containing all elements of b1 and all elements of b2, in an unkown order. More... | |
Pbase | base_intersection (Pbase, Pbase) |
Return variables/dimensions present in bases b1 and b2. More... | |
int | rank_of_variable (Pbase, Variable) |
this function returns the rank of the variable var in the base 0 encodes TCST, but I do not know why, TCST may be in base, sometimes -1 encodes an error More... | |
Variable | variable_of_rank (Pbase, int) |
Variable variable_of_rank(): this function returns the variable of rank "rank". More... | |
int | search_higher_rank (Pvecteur, Pbase) |
int search_higher_rank(): this fonction returns the rank of the variable of higher rank in the vecteur More... | |
Variable | search_var_of_higher_rank (Pvecteur, Pbase, Variable) |
this function returns the variable of higher rank, after the variable var, in the vecteur pvect More... | |
Pvecteur | search_i_element (Pbase, int) |
Pvecteur search_i_element(): recherche du i-ieme couple (var,val) dans la Pbase b. More... | |
Pbase | base_normalize (Pbase) |
bool | base_normalized_p (Pbase) |
Pbase | base_difference (Pbase, Pbase) |
Pbase base_difference(Pbase b1, Pbase b2): allocate b; b = b1 - b2 – with the set meaning return b;. More... | |
bool | base_included_p (Pbase, Pbase) |
Pbase base_included_p(Pbase b1, Pbase b2): include_p = b1 is included in b2 – with the set meaning return b;. More... | |
bool | bases_strictly_equal_p (Pbase, Pbase) |
Make sure that each dimension of b1 is the same dimension in b2. More... | |
void | vect_error (char *, char *,...) |
error.c More... | |
Pvecteur | vect_chain (Pvecteur, Variable, Value) |
private.c More... | |
Pvecteur | vect_elem (Pvecteur, Variable) |
PRIVATE: introduit du sharing; never used... More... | |
Pvecteur | vect_extract (Pvecteur, Variable) |
UNUSED - NOT TESTED. More... | |
Variable | vect_first_var (Pvecteur) |
PRIVATE: marquage du couple var_val comme visite par remplacement de var par -var dans le couple (OBSOLETE) More... | |
Pvecteur | vect_reversal (Pvecteur) |
Pvecteur vect_reversal(Pvecteur vect_in); produces the reversal vector of the vect_in. More... | |
Pvecteur | vect_div (Pvecteur, Value) |
scalaires.c More... | |
Pvecteur | vect_clean (Pvecteur) |
Pvecteur vect_clean(Pvecteur v): elimination de tous les couples dont le coefficient vaut 0 dans le vecteur v et renvoie de v. More... | |
Pvecteur | vect_multiply (Pvecteur, Value) |
Pvecteur vect_multiply(Pvecteur v, Value x): multiplication du vecteur v par le scalaire x, si x est different de 0. More... | |
void | vect_chg_sgn (Pvecteur) |
void vect_chg_sgn(Pvecteur v): multiplie v par -1 More... | |
bool | variable_equal (Variable, Variable) |
variable.c More... | |
char * | variable_default_name (Variable) |
char * variable_default_name(Variable v): returns the name of variable v More... | |
char * | variable_dump_name (Variable) |
variable_dump_name() returns an unambiguous name for variable v, based on the pointer used to really identify variables in the vecteur package; the name starts with the letter X and contains the hexadecimal representation of v More... | |
void | init_variable_debug_name (char *(*)(Variable)) |
void | reset_variable_debug_name (void) |
Variable | variable_make (char *) |
Variable variable_make(char * name): defines a new variable of a given name. More... | |
void | linear_hashtable_dump (linear_hashtable_pt) |
hashpointer.c More... | |
bool | linear_hashtable_coherent_p (linear_hashtable_pt) |
check hashtable coherency More... | |
linear_hashtable_pt | linear_hashtable_make (void) |
constructor. More... | |
void | linear_hashtable_free (linear_hashtable_pt) |
destructor More... | |
void | linear_hashtable_put (linear_hashtable_pt, void *, void *) |
void | linear_hashtable_put_once (linear_hashtable_pt, void *, void *) |
bool | linear_hashtable_isin (linear_hashtable_pt, void *) |
bool | linear_hashtable_remove (linear_hashtable_pt, void *) |
void * | linear_hashtable_get (linear_hashtable_pt, void *) |
int | linear_hashtable_nitems (linear_hashtable_pt) |
Variables | |
char *(* | variable_debug_name )(Variable) |
Debug support: pointer to the function used by debug print outs. More... | |
#define base_add_dimension | ( | b, | |
v | |||
) | vect_chg_coeff((Pvecteur *)(b),(v),VALUE_ONE) |
#define BASE_FOREACH | ( | v, | |
b | |||
) |
#define BASE_NULLE VECTEUR_NUL |
#define BASE_NULLE_P | ( | b | ) | ((b)==VECTEUR_NUL) |
#define base_rm | ( | b | ) | (vect_rm((Pvecteur)(b)), (b)=BASE_NULLE) |
#define BASE_UNDEFINED_P | ( | b | ) | ((b)==BASE_UNDEFINED) |
#define FWD_OFL_CTRL 1 /**overflows are treated by the calling procedure */ |
#define NO_OFL_CTRL 0 /**overflows are not trapped at all (dangerous !) */ |
#define OFL_CTRL 2 /**overflows are treated in the called procedure */ |
I do thing that overflows are managed in a very poor manner.
FC. It should be all or not, as provided by any os that would raise integer overflows. Thus we should have thought of a sofware mecanism compatible with such a hardware and os approach. maybe by defining a mult_Value macro to check explicitely for overflows if needed, and defined to a simple product if not. functions would have an additional argument for returning a conservative answer in case of overflow. Maybe some global variable could count the number of overflow that occured so that some caller could check whether sg got wrong and thus could warn about the result and this fact. then we would have either the library compiled for these soft checks or for none, but without any difference or explicite requirements from the user of these functions.
instead of that, we have the two versions at the same time with explicite control required from the user. I heard that for some functions this is not used... thus allowing good performance (each time some result is false someone tracks down the not checked function and checks overflow explicitely, thus it is not a very good approach). moreover the most costly functions (simplexe, chernikova) are also those in which the exceptions occurs thus they are all checked. the the impact on performances is definitely low. as far as software engineering is concerned, the current solution adds low level switch for calling different versions (controled or not) of pieces of code... this will have to be removed if some good os is to host this software... OVERFLOW CONTROL some OVERFLOW CONTROL is allowed
#define PlinX Pvecteur |
#define print_vect | ( | s | ) | vect_fprint(stdout,(s)) |
#define TCST ((Variable) 0) |
#define VARIABLE_DEFINED_P | ( | v | ) | ((v)!=VARIABLE_UNDEFINED) |
#define VARIABLE_UNDEFINED_P | ( | v | ) | ((v)==VARIABLE_UNDEFINED) |
#define VECTEUR 1006 /**constante associee a un vecteur */ |
Warning! Do not modify this file that is automatically generated!
Modify src/Libs/vecteur/vecteur-local.h instead, to add your own modifications. header file built by cproto vecteur-local.h package sur les vecteurs creux et les bases
Malik Imadache, Corinne Ancourt, Neil Butler, Francois Irigoin, Remi Triolet
Modifications:
trop creux a mon avis. il faudrait une liste de petits tableaux ? FC.
#define VECTEUR_NUL ((Pvecteur) 0) |
#define VECTEUR_NUL_P | ( | v | ) | ((v)==VECTEUR_NUL) |
#define VECTEUR_UNDEFINED_P | ( | v | ) | ((v)==VECTEUR_UNDEFINED) |
typedef struct linear_hashtable_st* linear_hashtable_pt |
STRUCTURE D'UNE BASE.
Une base est definie par son vecteur diagonal
Les tests d'appartenance sont effectues par comparaison des pointeurs et non par des strcmp.
Rien ne contraint les coefficients a valoir 1 et le package plint mais meme certains coefficients a 0, ce qui devrait revenir a faire disparaitre la variable (i.e. la coordonnee) correspondante de la base.
le type des coefficients dans les vecteurs: Value est defini dans le package arithmetique
STRUCTURE D'UN VECTEUR
Un vecteur est defini par une suite de couples Variable (i.e. element de la base) et Valeur (valeur du coefficient correspondant). Les coordonnees nulles ne sont pas representees et n'existe qu'implicitement par rapport a une base (hypothetique) definie via la package "variable".
En consequence, le vecteur nul est (malencontreusement) represente par NULL. Cela gene toutes les procedures succeptibles de retourner une valeur vecteur nul par effet de bord. Il faut alors passer en argument un POINTEUR vers un Pvecteur. En general, nous avons prefere retourner explicitement le vecteur calcule, a la maniere de ce qui est fait dans string.h
Il n'existe pas non plus de VECTEUR_UNDEFINED, puisque sa valeur devrait logiquement etre NULL.
typedef void* Variable |
Pbase base_add_variable(Pbase b, Variable v): add variable v as a new dimension to basis b at the end of the base list; if variable v is already in basis b, do nothing; this is not clean but convenient to avoid a test;.
Note that basis b contains a pointer towards variable v and not a copy of it. So some sharing is introduced.
A routine to check variable equality, variable_equal(), is used.
var | ar |
Definition at line 88 of file base.c.
References b1, VALUE_ONE, variable_equal(), vect_new(), VECTEUR_NUL_P, and vecteur_var.
Referenced by add_constraint_on_x(), base_intersection(), build_and_test_dependence_context(), copy_write_statement_with_cumulated_regions(), generic_minmax_to_transformer(), include_parameters_in_sc(), local_tile_constraints(), main(), make_base_from_vect(), make_base_phi_variables(), new_system_with_only_live_variable(), region_to_com_nest(), region_to_loop_nest(), sc_safe_append(), TestDependence(), transformer_add_loop_index_incrementation(), transformer_add_sign_information(), transformer_add_value_update(), transformer_add_variable_update(), transformer_derivative_fix_point(), transformer_list_generic_transitive_closure(), and vect_change_base().
appends b2 to b1.
modifies b1. b2 is not modified.
pb1 | b1 |
b2 | 2 |
Definition at line 384 of file base.c.
References b2, base_copy(), BASE_NULLE_P, linear_hashtable_free(), linear_hashtable_isin(), linear_hashtable_make(), linear_hashtable_put_once(), seen, Svecteur::succ, TCST, VALUE_ONE, var_of, and vect_chain().
Referenced by sc_append().
bool base_contains_variable_p(Pbase b, Variable v): returns true if variable v is one of b's elements;
Based on variable_equal()
Definition at line 136 of file base.c.
References variable_equal(), VECTEUR_NUL_P, and vecteur_var.
Referenced by add_bounding_box_constraints(), add_type_information(), base_difference(), base_intersection(), base_remove_variable(), build_transfer_equations(), cell_reference_sc_exact_projection_along_variable(), fortran_user_call_to_transformer(), include_trans_on_LC_in_ref(), my_system_remove_variables(), new_ident(), new_system_with_only_live_variable(), partial_eval_reference(), precondition_intra_to_inter(), region_exact_projection_along_parameters(), region_exact_projection_along_variable(), safe_transformer_projection(), sc_minmax_of_variable2(), sc_multiply_constant_terms(), sc_projection_ofl_along_list_of_variables(), separate_variables(), separate_variables_2(), simplify_dimension(), simplify_predicate(), sub_basis_p(), system_contains_var(), transform_in_ineq(), transformer_add_value_update(), transformer_add_variable_update(), transformer_argument_general_consistency_p(), transformer_arguments_projection(), transformer_combine(), transformer_convex_hulls(), transformer_filter(), transformer_projection_with_redundancy_elimination_and_check(), transformer_range(), transformer_to_1D_lattice(), transformer_to_domain(), transformer_value_substitutable_p(), transformer_value_substitute(), translate_global_value(), translate_to_module_frame(), vect_in_basis_p(), and vect_read().
Direct duplication.
The initial Pbase is assumed to be valid. Absolutely the same with base_dup, but base_up is the only function that maintains the old order. So recopy here for use with copy version including vect_copy, contrainte_copy, contraintes_copy, sc_copy (DN,24/6/02) Does not change the parameter. Did have a look at all copy version (DN,1/7/2002)
Definition at line 300 of file alloc.c.
References abort, BASE_NULLE, fprintf(), MALLOC, Svecteur::succ, val_of, VALUE_ONE, var_of, and VECTEUR.
Referenced by base_append(), base_union(), build_integer_sc_nredund(), new_system_with_only_live_variable(), region_sc_projection_along_variables_ofl_ctrl(), regions_must_convex_hull(), sc_base_dup(), sc_copy(), sc_fm_project_variables(), sc_init_with_sc(), sc_of_constrs(), sc_projection_concat_proj_on_variables(), sc_safe_build_sc_nredund_1pass(), sc_safe_build_sc_nredund_2pass(), sc_safe_elim_redund(), sc_strong_normalize2(), sc_strong_normalize_and_check_feasibility2(), and sg_of_rays().
Pbase base_difference(Pbase b1, Pbase b2): allocate b; b = b1 - b2 – with the set meaning return b;.
b1 | 1 |
b2 | 2 |
Definition at line 621 of file base.c.
References b1, b2, base_contains_variable_p(), BASE_NULLE, BASE_NULLE_P, BASE_UNDEFINED, Svecteur::succ, vect_add_variable(), and vecteur_var.
Referenced by algorithm_row_echelon_generic(), build_transfer_equations(), get_other_constraints(), sc_consistent_p(), and set_sort_context().
Pbase base_dup(Pbase b) Note: this function changes the value of the pointer.
Use base_copy instead. Should become a link, not a function. For the moment, it's a function, because of the sc.h cannot be updated without installation, due to decision of integration of Janus or not? DN 12/5/03
return base_copy(b);
Definition at line 268 of file alloc.c.
References abort, BASE_NULLE, fprintf(), MALLOC, Svecteur::succ, val_of, VALUE_ONE, var_of, and VECTEUR.
Referenced by add_var_sup(), build_image_base(), build_sc_nredund_1pass_ofl_ctrl(), dependence_cone_positive(), dual_pivot(), loop_nest_to_wp65_code(), main(), movement_computation(), pip_solve(), pip_solve_min_with_big(), plint(), plreal(), primal(), primal_positive(), region_sc_minimal(), region_sc_projection_ofl_along_parameter(), regions_must_convex_hull(), sc_enveloppe_chernikova_ofl_ctrl(), sc_faisabilite_optim(), sc_projection_optim_along_vecteur_ofl(), sg_dup(), sort_psysteme(), syst_smith(), TestDependence(), transformer_convex_hulls(), transformer_derivative_fix_point(), transformer_equality_fix_point(), transformer_normalize(), transformer_projection_with_redundancy_elimination_and_check(), update_basis(), and var_ecart_sup().
Variable base_find_variable(Pbase b, Variable v): returns variable v if variable v is one of b's elements (returns a pointer to the copy of v that's pointed to by basis b); else returns VARIABLE_UNDEFINED.
Based on variable_equal()
Definition at line 155 of file base.c.
References variable_equal(), VARIABLE_UNDEFINED, VECTEUR_NUL_P, and vecteur_var.
Referenced by matrice_index_sys(), rec_ident(), and vect_read().
void base_fprint | ( | FILE * | f, |
Pbase | b, | ||
get_variable_name_t | variable_name | ||
) |
void base_fprint(FILE * f, Pbase b, char * (*variable_name)()): impression d'une base sur le fichier f; le nom de chaque coordonnee est donne par la fonction variable_name()
Par exemple, la base b -> -> -> -> b == ( i j k ) est imprime sous la forme i j k LF ou les symboles i, j et k sont obtenus via la fonction pointee par variable_name()
Le base vide est represente par base vide LF
Note: attention au linefeed final il n'existe pas de fonction relisant une base sous cette forme
variable_name | ariable_name |
Definition at line 342 of file io.c.
References f(), fprintf(), Svecteur::succ, Svecteur::var, variable_name(), and VECTEUR_NUL_P.
Referenced by build_transfer_equations(), create_tile_basis(), hyperplane(), loop_nest_to_wp65_code(), print_dependence_cone(), print_loopnest_dependence_cone(), sc_default_dump(), sc_default_dump_to_files(), sc_dump(), sc_fprint_for_sc_fscan(), and sc_image_computation().
Pbase base_included_p(Pbase b1, Pbase b2): include_p = b1 is included in b2 – with the set meaning return b;.
b1 | 1 |
b2 | 2 |
Definition at line 640 of file base.c.
References b1, b2, linear_hashtable_free(), linear_hashtable_isin(), linear_hashtable_make(), linear_hashtable_put_once(), seen, Svecteur::succ, TCST, and var_of.
Referenced by sc_weak_consistent_p().
Return variables/dimensions present in bases b1 and b2.
Order is not preserved.
b1 | 1 |
b2 | 2 |
Definition at line 473 of file base.c.
References b1, b2, base_add_variable(), base_contains_variable_p(), BASE_NULLE, BASE_NULLE_P, BASE_UNDEFINED_P, vecteur_succ, and vecteur_var.
Referenced by sc_projection_optim_along_vecteur_ofl().
Definition at line 594 of file base.c.
References BASE_NULLE_P, Svecteur::succ, VALUE_ONE, and vecteur_val.
Referenced by pip_solve(), pip_solve_min_with_big(), set_sort_context(), and vars_read_and_written().
Definition at line 604 of file base.c.
References BASE_NULLE_P, Svecteur::succ, value_one_p, vect_check(), and vecteur_val.
Referenced by sc_consistent_p(), and sc_weak_consistent_p().
Pbase base_remove_variable(b, v): remove basis vector relative to v from b; abort if v is not in b;.
Definition at line 122 of file base.c.
References assert, base_contains_variable_p(), and vect_erase_var().
Referenced by main(), sc_base_remove_variable(), transformer_derivative_fix_point(), and transformer_list_generic_transitive_closure().
Pbase base_reversal(Pbase b_in): produces a basis b_out, having the same basis vectors as b_in, but in reverse order.
Basis b_in is not touched.
Example: b_in = { e1, e2, e3 } -> b_out = { e3, e2, e1}
b_in | _in |
Definition at line 221 of file base.c.
References vect_add_elem(), VECTEUR_NUL, VECTEUR_NUL_P, vecteur_val, and vecteur_var.
Referenced by adg_sc_dup(), algorithm_row_echelon_generic(), build_image_base(), code_generation(), compute_iteration_domain(), create_tile_basis(), derive_new_basis(), list_to_base(), loop_nest_to_wp65_code(), matrices_to_loop_sc(), matrices_to_sc(), parallel_tiling(), sc_projection_concat_proj_on_variables(), set_sort_context(), and tiling_transformation().
Pbase base_union(Pbase b1, Pbase b2): compute a new basis containing all elements of b1 and all elements of b2, in an unkown order.
b := b1 u b2; return b;
Bases b1 and b2 are not modified. Basis vectors are compared for equality using variable_equal()
Modifications:
b1 | 1 |
b2 | 2 |
Definition at line 428 of file base.c.
References b1, b2, base_copy(), BASE_NULLE, BASE_NULLE_P, linear_hashtable_free(), linear_hashtable_isin(), linear_hashtable_make(), linear_hashtable_put_once(), seen, Svecteur::succ, TCST, VALUE_ONE, var_of, and vect_chain().
Referenced by actual_convex_union(), elementary_convex_union(), gcd_and_constant_dependence_test(), is_inferior_monome(), matrices_to_constraints_with_sym_cst(), matrices_to_contraintes_with_sym_cst(), pip_solve(), pip_solve_min_with_big(), polynome_used_var(), regions_must_convex_hull(), sc_constraint_add(), sc_cute_convex_hull(), sc_elim_redund_with_first_ofl_ctrl(), sg_union(), simplify_float_constraint_system(), sl_fprint_tab(), transformer_add_loop_index_initialization(), transformer_convex_hulls(), and transformer_list_generic_transitive_closure().
Make sure that each dimension of b1 is the same dimension in b2.
b1 | 1 |
b2 | 2 |
Definition at line 660 of file base.c.
References b1, b2, base_dimension, s1, and variable_of_rank().
Referenced by sc_union().
void dbg_vect_rm | ( | Pvecteur | , |
char * | |||
) |
void init_variable_debug_name | ( | char * | *)(Variable | ) |
bool linear_hashtable_coherent_p | ( | linear_hashtable_pt | h | ) |
check hashtable coherency
coherent size/nitems.
check number of item stored.
check key index
Definition at line 128 of file hashpointer.c.
References linear_hashtable_st::contents, EMPTIED_CHUNK, FREE_CHUNK, paire::key, key_location(), linear_hashtable_st::nitems, linear_hashtable_st::size, and uintptr_t.
void linear_hashtable_dump | ( | linear_hashtable_pt | h | ) |
Definition at line 122 of file hashpointer.c.
References linear_hashtable_print().
void linear_hashtable_free | ( | linear_hashtable_pt | h | ) |
destructor
Definition at line 189 of file hashpointer.c.
References linear_hashtable_st::contents, debug_assert_coherent, and free().
Referenced by base_append(), base_included_p(), base_union(), fortran_data_to_prec_for_variables(), sc_to_minimal_basis(), transitive_closure_from_two_bases(), and vect_check().
void* linear_hashtable_get | ( | linear_hashtable_pt | h, |
void * | k | ||
) |
Definition at line 293 of file hashpointer.c.
References linear_hashtable_st::contents, FREE_CHUNK, paire::key, key_location(), and paire::val.
bool linear_hashtable_isin | ( | linear_hashtable_pt | h, |
void * | k | ||
) |
Definition at line 273 of file hashpointer.c.
References linear_hashtable_st::contents, paire::key, and key_location().
Referenced by base_append(), base_included_p(), base_to_set(), base_union(), contains_variables(), fortran_data_to_prec_for_variables(), sc_to_minimal_basis(), and vect_check().
linear_hashtable_pt linear_hashtable_make | ( | void | ) |
constructor.
returns a newly allocated hashtable.
check malloc
check malloc
Definition at line 165 of file hashpointer.c.
References assert, linear_hashtable_st::contents, debug_assert_coherent, FREE_CHUNK, HASHTABLE_INITIAL_SIZE, paire::key, malloc(), linear_hashtable_st::nitems, linear_hashtable_st::size, and paire::val.
Referenced by base_append(), base_included_p(), base_union(), fortran_data_to_prec_for_variables(), sc_to_minimal_basis(), transitive_closure_from_two_bases(), and vect_check().
int linear_hashtable_nitems | ( | linear_hashtable_pt | h | ) |
Definition at line 299 of file hashpointer.c.
References linear_hashtable_st::nitems.
void linear_hashtable_put | ( | linear_hashtable_pt | h, |
void * | k, | ||
void * | v | ||
) |
Definition at line 263 of file hashpointer.c.
References linear_hashtable_internal_put().
Referenced by base_to_set(), and vect_check().
void linear_hashtable_put_once | ( | linear_hashtable_pt | h, |
void * | k, | ||
void * | v | ||
) |
Definition at line 268 of file hashpointer.c.
References linear_hashtable_internal_put().
Referenced by base_append(), base_included_p(), base_union(), fortran_data_to_prec_for_variables(), and sc_to_minimal_basis().
bool linear_hashtable_remove | ( | linear_hashtable_pt | h, |
void * | k | ||
) |
Definition at line 278 of file hashpointer.c.
References linear_hashtable_st::contents, EMPTIED_CHUNK, FREE_CHUNK, paire::key, key_location(), linear_hashtable_st::nitems, and paire::val.
pv | v |
Definition at line 109 of file base.c.
References base_add_variable(), Svecteur::succ, TCST, Svecteur::var, and VECTEUR_NUL_P.
Referenced by efficient_sc_check_inequality_feasibility(), sc_normalize2(), and transformer_add_loop_index_initialization().
void Pvecteur_separate_on_sign(v, pvpos, pvneg) Pvecteur v, *pvpos, *pvneg;
IN: v
OUT: pvpos, pvneg
this function builds 2 vectors composed of the positive and negative parts of the initial vector v which is not modified.
(c) FC 16/05/94
pvpos | vpos |
pvneg | vneg |
Definition at line 369 of file unaires.c.
References Svecteur::succ, val_of, value_neg_p, value_uminus, var_of, vect_add_elem(), and VECTEUR_NUL.
Referenced by Pcontrainte_to_expression_list().
this function returns the rank of the variable var in the base 0 encodes TCST, but I do not know why, TCST may be in base, sometimes -1 encodes an error
not found
base | ase |
var | ar |
Definition at line 497 of file base.c.
References base, rank, Svecteur::succ, TCST, VECTEUR_NUL_P, and vecteur_var.
Referenced by bound_generation(), build_transfer_matrix(), compare_variables_in_base(), constraint_distribution(), constraint_integer_combination(), contrainte_extract(), reference_conversion_computation(), reference_conversion_expression(), reference_translation(), sc_elim_triang_integer_redund_constraint_p(), sc_integer_projection_information(), sc_normalize2(), search_higher_rank(), search_var_of_higher_rank(), and transformer_to_1D_lattice().
void reset_variable_debug_name | ( | void | ) |
Definition at line 121 of file variable.c.
References variable_debug_name, and variable_dump_name().
int search_higher_rank(): this fonction returns the rank of the variable of higher rank in the vecteur
vect | ect |
base | ase |
Definition at line 541 of file base.c.
References base, rank_of_variable(), Svecteur::succ, VECTEUR_NUL_P, and vecteur_var.
Referenced by bound_distribution(), build_integer_sc_nredund(), constraint_distribution(), contrainte_extract(), egalite_distribution(), elim_redund_sc_with_sc(), lower_bound_generation(), sc_integer_projection_information(), test_bound_generation(), and upper_bound_generation().
this function returns the variable of higher rank, after the variable var, in the vecteur pvect
pvect | vect |
base | ase |
var | ar |
Definition at line 561 of file base.c.
References base, rank_of_variable(), Svecteur::succ, TCST, VECTEUR_NUL_P, and vecteur_var.
char* variable_default_name | ( | Variable | v | ) |
char * variable_default_name(Variable v): returns the name of variable v
Type variable is assumed here to be char *
Definition at line 81 of file variable.c.
Referenced by add_var_sup(), eq_in_ineq(), main(), primal(), primal_pivot(), primal_positive(), rec_ident(), sc_variable_name_init(), show_nredund(), test_file(), and var_ecart_sup().
char* variable_dump_name | ( | Variable | v | ) |
variable_dump_name() returns an unambiguous name for variable v, based on the pointer used to really identify variables in the vecteur package; the name starts with the letter X and contains the hexadecimal representation of v
Bugs:
Room for X0x1234567812345678\0 for example on 64 bit address architecture since Variable is a pointer to something:
Definition at line 96 of file variable.c.
References buffer.
Referenced by fprint_message(), main(), mk_rn(), reset_variable_debug_name(), sg_dump(), and sg_without_line().
variable.c
variable.c
Francois Irigoin
Notes:
Modifications: INTLIBRARY bool variable_equal(Variable v1, Variable v2): returns true if variables v1 and v2 have the same VALUE
Type Variable is assumed here to be char *
Modifications:
v1 | 1 |
v2 | 2 |
Definition at line 62 of file variable.c.
Referenced by base_add_variable(), base_contains_variable_p(), base_find_variable(), sc_base_add_variable(), vect_add_variable(), and vect_contains_variable_p().
Variable variable_make | ( | char * | name | ) |
Variable variable_make(char * name): defines a new variable of a given name.
name | ame |
Definition at line 129 of file variable.c.
References strdup().
Referenced by creat_new_var(), and vect_read().
Variable variable_of_rank(): this function returns the variable of rank "rank".
base | ase |
rank | ank |
Definition at line 520 of file base.c.
References base, rank, Svecteur::succ, TCST, VECTEUR_NUL_P, and vecteur_var.
Referenced by bases_strictly_equal_p().
binaires.c
binaires.c
INTLIBRARY Pvecteur vect_add(Pvecteur v1, Pvecteur v2): allocation d'un vecteur v dont la valeur est la somme des deux vecteurs v1 et v2
->
allocate v; -> -> -> v := v1 + v2; -> return v;
RT: j'ai besoin d'un vect_add a effet de bord pour la normalisation d'expression lineaire. idem pour vect_substract, vect_mult, ...
v1 | 1 |
v2 | 2 |
Definition at line 53 of file binaires.c.
References Svecteur::succ, val_of, var_of, vect_add_elem(), and vect_dup().
Referenced by adg_dataflowgraph(), adg_max_of_leaves(), align_check(), analyze_expression(), array_indices_communication(), bounds_equal_p(), broadcast_of_dataflow(), build_list_of_min(), build_sc_machine(), build_third_comb(), c_convex_effects_on_actual_parameter_forward_translation(), contrainte_parallele(), count_eq_occ(), dj_system_complement(), do_gather_all_expressions_perms(), eq_in_ineq(), expression_equal_in_context_p(), expression_less_than_in_context(), find_implicit_equation(), find_pattern(), generate_one_message(), include_trans_on_LC_in_ref(), invariant_vector_p(), loop_index_domaine_to_contrainte(), loop_nest_to_wp65_code(), make_datum_movement(), make_dual(), make_lin_op_exp(), make_load_blocks(), make_movements_loop_body_wp65(), make_store_blocks(), matrices_to_loop_sc(), matrix_to_system(), MergeLinExprs(), monome_monome_mult(), my_vect_var_subst(), normalize_intrinsic(), NormalizeIntrinsic(), one_message_guards_and_neighbour(), pa_path_to_few_disjunct_ofl_ctrl(), parallel_tiling(), sc_elim_double_constraints(), sc_transform_ineg_in_eg(), simplify_constraint_with_bounding_box(), simplify_dimension(), simplify_float_constraint(), simplify_predicate(), system_new_var_subst(), tiling_transformation(), update_basis(), vect_change_base(), and vect_var_subst().
void vect_add_elem(Pvecteur * pvect, Variable var, Value val): addition d'un vecteur colineaire au vecteur de base var au vecteur vect
--—> --—> —> *pvect := *pvect + val evar
pvect | vect |
var | ar |
val | al |
Definition at line 72 of file unaires.c.
References Svecteur::succ, val_of, value_addto, value_zero_p, var_of, vect_chain(), and vect_erase_var().
Referenced by add_affine_bound_conditions(), add_declaration_list_information(), add_elem_to_list_of_Pvecteur(), add_equivalence_equality(), add_fin_mat(), add_loop_index_exit_value(), add_loop_skip_condition(), add_var_sup(), adg_list_to_vect(), affine_to_transformer(), array_indices_communication(), base_reversal(), bitwise_xor_to_transformer(), bounds_equal_p(), build_image_base(), build_sc_machine(), cell_reference_sc_exact_projection_along_variable(), check_range_wrt_precondition(), complex_bound_computation(), compute_x_and_y_bounds(), constraints_to_loop_bound(), contrainte_reverse(), converti_psysmin_psysmax(), cout_nul(), dependence_cone_positive(), dependence_system_add_lci_and_di(), do_solve_hardware_constraints_on_nb_proc(), ecrit_coeff1(), eval_var(), expression_flt(), expression_less_than_in_context(), expression_multiply_sizeof_to_transformer(), find_motif(), find_pattern(), fonct_max_all(), fonct_max_d(), fonct_min_all(), fonct_min_d(), fonct_read(), formal_and_actual_parameters_association(), free_guards(), full_linearization(), gcd_and_constant_dependence_test(), generic_abs_to_transformer(), generic_equality_to_transformer(), generic_minmax_to_transformer(), hpfc_compute_lid(), iabs_to_transformer(), integer_divide_to_transformer(), integer_left_shift_to_transformer(), integer_minmax_to_transformer(), integer_multiply_to_transformer(), integer_power_to_transformer(), integer_right_shift_to_transformer(), invariant_vector_p(), list_to_base(), local_tile_constraints(), logical_binary_function_to_transformer(), logical_binary_operation_to_transformer(), logical_constant_to_transformer(), logical_unary_operation_to_transformer(), loop_bound_evaluation_to_transformer(), loop_bounds_to_tile_bounds(), loop_index_domaine_to_contrainte(), loop_regions_normalize(), lower_bound_generation(), make_base_of_nest(), make_constraint_expression(), make_context_of_loop(), make_datum_movement(), make_loop_indice_equation(), make_movements_loop_body_wp65(), make_scanning_over_one_tile(), make_tile_constraints(), my_system_remove_variables(), my_vect_substract(), new_constraint_for_coefficient_reduction_with_bounding_box(), partial_linearization(), pivoter_pas(), plint_degen(), polynome_roots(), polynome_sscanf(), polynome_to_vecteur(), Pvecteur_separate_on_sign(), reduce_loop_bound(), region_exact_projection_along_parameters(), region_exact_projection_along_variable(), relation_to_transformer(), remove_temporal_variables_from_system(), sc_add_di(), sc_add_dsi(), sc_bounded_normalization(), sc_find_equalities(), sc_minmax_of_variable_optim(), sc_multiply_constant_terms(), sc_of_constrs(), sc_proj_optim_on_di_ofl(), sc_projection_ofl_along_list_of_variables(), scanning_base_to_vect(), set_dimensions_of_local_variable_family(), simple_addition_to_transformer(), simplify_constraint_with_bounding_box(), simplify_float_constraint(), simplify_minmax_contrainte(), small_positive_slope_reduce_coefficients_with_bounding_box(), sys_int_redond(), test_bound_generation(), tile_change_of_basis(), tile_hyperplane_constraints(), tile_membership(), tile_membership_constraints(), transformer_add_3d_affine_constraint(), transformer_add_condition_information_updown(), transformer_add_equality(), transformer_add_equality_with_affine_term(), transformer_add_equality_with_integer_constant(), transformer_add_identity(), transformer_add_inequality(), transformer_add_inequality_with_affine_term(), transformer_add_inequality_with_integer_constraint(), transformer_add_integer_relation_information(), transformer_add_loop_index_initialization(), transformer_add_sign_information(), transformer_convex_hulls(), transformer_equality_fix_point(), transformer_logical_inequalities_add(), translate_global_value(), translate_to_module_frame(), update_lower_and_upper_bounds(), update_lower_or_upper_bound(), var_ecart_sup(), variables_in_declaration_list(), vars_read_and_written(), vect_add(), vect_cl_ofl_ctrl(), vect_gen_read(), vect_make(), vect_make_1D(), vect_make_dense(), vect_make_line(), vect_printout_order(), vect_reversal(), vect_substract(), vecteur_of_zvec(), vvs_to_sc(), xml_Chain_Graph(), xml_GlobalVariables(), xml_LocalVariables(), xml_Loops(), xml_Pattern_Paving(), xml_TaskParameters(), and xml_tiling().
Francois Irigoin
The function variable_name should be inlined as much as possible to improve performances. It has to be used to be generic over the "Variable" type. For instance, variables represented by a character string cannot be decided equal by a simple pointer comparison.
Modifications: INTLIBRARY Pbase vect_add_variable(Pbase b, Variable v): add variable v as a new dimension to basis b; if variable v is already in basis b, do nothing; this is not clean but convenient to avoid a test;
Note that basis b contains a pointer towards variable v and not a copy of it. So some sharing is introduced.
A routine to check variable equality, variable_equal(), is used.
Definition at line 61 of file base.c.
References b1, base_add_dimension, variable_equal(), VECTEUR_NUL, VECTEUR_NUL_P, and vecteur_var.
Referenced by add_var_sup(), args_to_transformer(), base_difference(), build_sc_machine(), build_sc_with_several_uniform_ref(), create_tile_basis(), equations_to_bases(), filter_transformer(), loop_bounds_to_tile_bounds(), loop_index_domaine_to_contrainte(), MakeDibaseinorder(), module_to_wp65_modules(), new_ident(), sc_add_new_variable_name(), set_dimensions_of_local_variable_family(), transformer_add_modified_variable(), transformer_add_modified_variable_entity(), transformer_add_variable_incrementation(), var_ecart_sup(), and vect_read().
INTLIBRARY PRIVATE: introduit du sharing, ne garantit pas l'unicite de chaque composante
Pvecteur vect_chain(Pvecteur v_in, Variable var, Value coeff): ajout d'un vecteur colineaire au vecteur de base var et de coefficient coeff au vecteur v_in; si la composante var de v_in etait nulle:
si <v_in . evar> == 0 alors -—> allocate v_out; -—> —> --> v_out = v_in + coeff var; —> destroy v_in; sinon chaos!
v_in ne doit plus etre utilise ulterieurement; l'utilisation standard est donc: v = vect_chain(v,var,coeff);
Pour preserver la coherence des vecteurs, l'utilisateur doit appeler vect_add_elem(v,var,coeff) qui teste l'existence d'un coefficient var nul dans v avant de creer un nouveau couple (var,coeff)
On pourrait preferer le passage d'un Pvecteur * comme premier argument et un return void.
very expensive for EDF... FC/CA 06/07/2000. useless?
assert(vect_coeff(var, v_in)==0);
v_in | _in |
var | ar |
coeff | oeff |
Definition at line 69 of file private.c.
References Svecteur::succ, and vect_new().
Referenced by base_append(), base_union(), sc_to_minimal_basis(), vect_add_elem(), vect_chg_coeff(), and vect_dup().
bool vect_check(Pvecteur v): renvoie true si le vecteur v est coherent avec les specifications du package; aucun des coefficients effectivement conserves en memoire ne doit etre nul (la cellule aurait du etre liberee) et aucune dimension (i.e.
variable) ne peut apparaitre deux fois.
Ces conditions ne sont pas verifiees par Corinne dans ses routines du package "sommet".
new version to test linear_hashtable. better for large vectors, but much worse for small ones I guess. FC.
Especially for the NULL vector. FI.
cv | v |
Definition at line 529 of file reductions.c.
References linear_hashtable_free(), linear_hashtable_isin(), linear_hashtable_make(), linear_hashtable_put(), seen, Svecteur::succ, val_of, value_notzero_p, and var_of.
Referenced by adg_contrainte_fprint(), base_normalized_p(), contrainte_fprint(), contrainte_sprint_format(), contrainte_text_format(), monome_check(), pu_contrainte_fprint(), and vect_consistent_p().
void vect_chg_coeff(Pvecteur *ppv, Variable var, Value val): mise de la coordonnee var du vecteur *ppv a la valeur val
—> —> —> —> —> —> *ppv = *ppv - <*ppv . evar> evar + val evar
on n'a pas trouve de composante var
ppv | pv |
var | ar |
val | al |
Definition at line 143 of file unaires.c.
References Svecteur::succ, Svecteur::val, Svecteur::var, vect_chain(), and vect_erase_var().
Referenced by build_sc_with_several_uniform_ref(), complex_bound_computation(), contrainte_normalize(), cout_nul(), eval_var(), find_eg(), find_vbase(), free_guards(), get_exp_schedule(), gomory_trait_eq(), loop_nest_to_offset(), loop_nest_to_tile(), loop_nest_to_wp65_code(), lower_bound_generation(), mat_sys_conv(), matrice_index_sys(), matrices_to_constraints(), matrices_to_constraints_with_sym_cst(), matrices_to_contraintes_with_sym_cst(), matrices_to_loop_sc(), matrices_to_sc(), movement_computation(), my_contrainte_normalize(), my_matrices_to_constraints_with_sym_cst(), my_matrices_to_constraints_with_sym_cst_2(), oter_lvbase(), pivoter_pas(), plint_degen(), print_call_precondition(), pu_matrices_to_contraintes(), sc_consistent_p(), sc_image_computation(), sc_weak_consistent_p(), test_bound_generation(), transformer_add_variable_incrementation(), transformer_convex_hulls(), update_basis(), update_coefficient_signs_in_vector(), upper_bound_generation(), var_pivotd(), var_pivots(), var_posit(), vect_subst(), xml_Chain_Graph(), and xml_Compute_and_Need().
void vect_chg_sgn | ( | Pvecteur | v | ) |
void vect_chg_sgn(Pvecteur v): multiplie v par -1
-> -> v := - v
Definition at line 151 of file scalaires.c.
References val_of, and value_oppose.
Referenced by __attribute__(), add_affine_bound_conditions(), adg_get_conjonctions(), adg_max_of_leaves(), build_sc_with_several_uniform_ref(), calculate_delay(), change_base_in_sc(), check_positive_dependence(), complex_bound_computation(), constraint_to_bound(), constraints_to_loop_bound(), contrainte_chg_sgn(), contrainte_to_text_2(), create_farkas_poly(), creer_ineg(), dj_simple_inegs_to_eg(), dj_system_complement(), eq_in_ineq(), find_pattern(), get_bounds_expression(), get_exp_schedule(), gomory_trait_eq(), heuristique_3(), loop_executed_approximation(), loop_index_domaine_to_contrainte(), make_constraint_expression(), make_dual(), make_vvs_from_sc(), monome_monome_div(), my_substitute_var_with_vec(), negate_expression(), normalize_intrinsic(), NormalizeIntrinsic(), outliner_smart_references_computation(), pa_path_to_few_disjunct_ofl_ctrl(), print_loopnest_dependence_cone(), Pvecteur_to_assign_statement(), ray_oppose(), sc_of_constrs(), sc_supress_same_constraints(), sc_transform_eg_in_ineg(), separate_variables(), simplify_minmax_contrainte(), substitute_var_with_vec(), sys_int_redond(), test_bound_generation(), tile_hyperplane_constraints(), tile_membership_constraints(), transform_in_ineq(), translate_to_module_frame(), upper_bound_generation(), vect_cl_ofl_ctrl(), vect_div(), vect_multiply(), and xml_Region_Range().
void vect_chg_var(Pvecteur *ppv, Variable v_old, Variable v_new) replace the variable v_old by v_new
ppv | pv |
v_old | _old |
v_new | _new |
Definition at line 168 of file unaires.c.
References Svecteur::succ, and Svecteur::var.
Referenced by gcd_and_constant_dependence_test(), poly_chg_var(), polynome_chg_var(), polynome_roots(), and sc_chg_var().
lambda | ambda |
Definition at line 181 of file binaires.c.
References NO_OFL_CTRL, and vect_cl_ofl_ctrl().
Referenced by add_loop_index_exit_value(), constraints_eliminate_constant_terms(), and vect_substitute_dimension().
x1 | 1 |
v1 | 1 |
x2 | 2 |
v2 | 2 |
Definition at line 247 of file binaires.c.
References NO_OFL_CTRL, and vect_cl2_ofl_ctrl().
Referenced by find_pattern(), lower_bound_generation(), upper_bound_generation(), and vect_subst().
x1 | 1 |
v1 | 1 |
x2 | 2 |
v2 | 2 |
Definition at line 238 of file binaires.c.
References FWD_OFL_CTRL, and vect_cl2_ofl_ctrl().
Pvecteur vect_cl2_ofl(Value x1, Pvecteur v1, Value x2, Pvecteur v2): allocation d'un vecteur v dont la valeur est la combinaison lineaire des deux vecteurs v1 et v2 avec les coefficients respectifs x1 et x2 Le controle de l'overflow est effectue par vect_cl_ofl et traite par le retour du contexte correspondant au dernier CATCH(overflow_error) effectue.
-> allocate v; -> -> -> v := x1 v1 + x2 v2; -> return v;
le bout de l'horreur sur ces vecteurs creux dont les composantes ne sont pas triees; Malik a essaye d'eviter les allocations inutiles en "marquant" les coefficients de v2 qui ont ete vus lors du parcours des coefficients non-nuls de v1; puis il ajoute a ce premier resultat la partie de x2 v2 qui n'a pas encore ete prise en compte parce que le coefficient correspondant dans v1 etait nul;
la variable de nom 0 est traitee a part car la procedure de marquage (multiplication par -1) ne la marque pas
Une autre solution, presque aussi efficace, consisterait a allouer et calculer x1 v1 puis a y ajouter x2 v2 a coups de vect_add_elem; on n'a pas de procedure faisant simultanement l'allocation et la multiplication par un scalaire; on n'a pas de procedure faisant l'addition sans allocation (accumulation);
Francois Irigoin, 2 juin 1989
x1 | 1 |
v1 | 1 |
x2 | 2 |
v2 | 2 |
ofl_ctrl | fl_ctrl |
Definition at line 204 of file binaires.c.
References vect_cl_ofl_ctrl().
Referenced by compose_vvs(), contrainte_subst_ofl_ctrl(), elim_var_with_eg(), inegalite_comb_ofl_ctrl(), my_substitute_var_with_vec(), plc_elim_var_with_eg(), plc_make_vvs_with_vector(), sc_to_vvs(), substitute_var_with_vec(), valuer(), vect_cl2(), vect_cl2_ofl(), and vvs_on_vvs().
lambda | ambda |
Definition at line 173 of file binaires.c.
References FWD_OFL_CTRL, and vect_cl_ofl_ctrl().
Pvecteur vect_cl_ofl_ctrl(Pvecteur v, Value lambda, Pvecteur u, int ofl_ctrl): etape d'acculumulation dans une combinaison lineaire; aucun sharing entre v et u n'est cree (allocation implicite) Le controle de l'overflow est effectue et traite par le retour du contexte correspondant au dernier CATCH(overflow_error) effectue.
-> -> -> v := v + lambda u; -> return v;
Modifications:
ancienne version for( ;u!=NULL;u=u->succ) v = vect_chain(v,var_of(u),lambda*val_of(u));
== 1
== -1
bof, FC
lambda | ambda |
ofl_ctrl | fl_ctrl |
Definition at line 128 of file binaires.c.
References NO_OFL_CTRL, Svecteur::succ, val_of, value_mone_p, value_mult, value_notone_p, value_one_p, value_protected_mult, value_uminus, VALUE_ZERO, var_of, vect_add_elem(), vect_chg_sgn(), vect_dup(), vect_multiply(), and x.
Referenced by calculate_delay(), converti_psysmin_psysmax(), loop_regions_normalize(), put_source_ind(), vect_cl(), vect_cl2_ofl_ctrl(), vect_cl_ofl(), and vvs_on_vecteur().
Pvecteur vect_clean(Pvecteur v): elimination de tous les couples dont le coefficient vaut 0 dans le vecteur v et renvoie de v.
Ne devrait JAMAIS etre utilise en dehors de la bibliotheque vecteur. Ne sert qu'a corriger le resultat de vect_div quand la division entiere fait apparaitre un 0. Dans ces cas, vect_div n'est pas lineaire.
Definition at line 80 of file scalaires.c.
References FREE, Svecteur::succ, Svecteur::val, and VECTEUR.
Referenced by contrainte_normalize(), gomory_trait_eq(), my_contrainte_normalize(), var_posit(), and vect_div().
Variable vect_coeff(Variable var, Pvecteur vect): coefficient de coordonnee var du vecteur vect —> Soit evar le vecteur de base de nom var:
---> --->
return <vect . evar>; (i.e. return vect[var])
var | ar |
vect | ect |
Definition at line 228 of file unaires.c.
References assert, Svecteur::succ, val_of, VALUE_ZERO, and var_of.
Referenced by add_bounding_box_constraints(), add_declaration_list_information(), add_reference_information(), add_var_sup(), affine_expression_of_loop_index_p(), aligned_p(), alignment_p(), array_access_to_array_ranges(), array_indices_communication(), array_overflow(), atomize_one_message(), bound_distribution(), bound_redund_with_sc_p(), bounds_equal_p(), build_integer_sc_nredund(), build_list_of_min(), build_sc_machine(), build_third_comb(), calculate_delay(), call_rwt(), change_base_in_sc(), check_coefficient_reduction(), combiner_ofl_with_test(), compare_the_constraints(), complex_bound_computation(), compose_vvs(), compute_receive_content(), compute_receive_domain(), compute_x_and_y_bounds(), const_negative(), constraint_distribution(), constraint_integer_combination(), constraint_to_bound(), constraint_without_vars(), constraints_eliminate_constant_terms(), constraints_for_bounds(), constraints_to_loop_bound(), constraints_to_matrices(), constraints_with_sym_cst_to_matrices(), constrs_of_sc(), contrainte_dup_extract(), contrainte_eval(), contrainte_normalize(), contrainte_parallele(), contrainte_subst_ofl_ctrl(), contrainte_to_matrix_ligne(), contrainte_var_min_coeff(), contraintes_to_expression(), contraintes_with_sym_cst_to_matrices(), convert_bound_expression(), convex_in_effect_loop_range_fix(), cost_of_constant_operations(), cst_vector_p(), dj_variable_substitution_with_eqs_ofl_ctrl(), do_group_statement_constant(), ecrit_ligne(), eligible_for_coefficient_reduction_with_bounding_box_p(), elim_var_with_eg(), eq_diff_const(), eq_sum_const(), eq_var_nophi_min_coeff(), eq_var_phi(), eval(), eval_2D_vecteur(), eval_var(), expression_and_precondition_to_integer_interval(), expression_integer_constant_p(), expression_to_int(), find_eg(), find_first_integer_point_in_between(), find_motif(), find_pattern(), find_vbase(), free_guards(), gcd_and_constant_dependence_test(), generate_one_message(), get_bounds_expression(), get_const_diff(), get_const_off(), gomory_eq(), gomory_trait_eq(), hpfc_broadcast_buffers(), hpfc_compute_lid(), hpfc_integer_constant_expression_p(), HpfcExpressionToInt(), include_trans_on_LC_in_ref(), inegalite_comb_ofl_ctrl(), initialize_offsets(), intersection(), is_good_direction_p(), is_inferior_monome(), Lbound(), legal_point_p(), ligne_pivot(), lignes_entrant(), loop_bounds_to_tile_bounds(), loop_flt(), loop_index_in_several_indices(), loop_regions_normalize(), loop_sc_to_matrices(), lower_bound_generation(), make_bounds(), make_constraint_expression(), make_loop_indice_equation(), make_vvs_from_sc(), message_larger_p(), message_manageable_p(), monome_sprint(), my_constraints_with_sym_cst_to_matrices(), my_contrainte_normalize(), my_substitute_var_with_vec(), my_vect_var_subst(), new_constraint_for_coefficient_reduction_with_bounding_box(), new_ecrit_ligne(), one_message_guards_and_neighbour(), one_receive_message(), outliner_smart_references_computation(), partial_broadcast_coefficients(), phi_free_contraints_to_expressions(), pivoter(), pivoter_pas(), plc_elim_var_with_eg(), plc_make_dim(), plc_make_vvs_with_vector(), plint(), plint_pas(), polynome_contains_var(), polynome_degree(), polynome_factorize(), polynome_roots(), polynome_var_subst(), print_call_precondition(), print_cone_vecteur(), print_vect_in_vertice_val(), pu_contraintes_to_matrices(), Pvecteur_to_assign_statement(), pvecteur_to_polynome(), region_projection_along_index_safe_p(), region_range_nul_p(), sc_add_di(), sc_add_dsi(), sc_bounded_normalization(), sc_constrains_variable_p(), sc_elim_double_constraints(), sc_elim_triang_integer_redund_constraint_p(), sc_elim_var(), sc_eliminate_constant_terms(), sc_find_equalities(), sc_integer_projection_information(), sc_minmax_of_variable(), sc_minmax_of_variable_optim(), sc_normalize2(), sc_safe_elim_db_constraints(), sc_simplex_feasibility_ofl_ctrl_fixprec(), sc_to_iproblem(), sc_to_matrices(), sc_variable_rename(), separate_variables(), set_dimensions_of_local_variable_family(), sg_fprint_as_ddv(), shift_expression_of_loop_index_p(), signed_integer_constant_expression_value(), simple_indices_p(), simplify_constraint_with_bounding_box(), simplify_dimension(), simplify_minmax_contrainte(), simplify_predicate(), small_positive_slope_reduce_coefficients_with_bounding_box(), small_slope_and_first_quadrant_p(), sol_entiere(), sol_finale(), sol_positive(), sol_positive_simpl(), sort_tile_indices(), st_one_message(), stmt_bdt_directions(), substitute_var_with_vec(), supported_ref_p(), sys_mat_conv(), sys_matrice_index(), system_new_var_subst(), test_borne(), test_bound_generation(), tile_change_of_basis(), tile_hyperplane_constraints(), tile_membership_constraints(), transform_in_ineq(), transformer_affect_linear_p(), translate_to_module_frame(), Ubound(), update_coefficient_signs_in_vector(), update_indices_for_local_computation(), update_lower_and_upper_bounds(), update_lower_or_upper_bound(), upper_bound_generation(), var_in_lcontrainte_p(), var_pivotd(), var_pivots(), var_with_unity_coeff_p(), vars_in_vect_p(), vect_const_p(), vect_equal(), vect_equal_except(), vect_fprint_as_dense(), vect_in_p(), vect_oppos(), vect_opposite_except(), vect_prod_scal(), vect_product(), vect_proport(), vect_sprint_as_monome(), vect_subst(), vect_substitute_dimension(), vect_var_subst(), vvs_on_vecteur(), vvs_on_vvs(), which_array_dimension(), xml_Chain_Graph(), xml_Compute_and_Need(), xml_ConstOffset(), xml_GlobalVariables(), xml_LocalVariables(), xml_LoopOffset(), xml_Pattern_Paving(), xml_Region_Range(), xml_TaskParameter(), xml_tiling(), and zmat_set_row().
Value vect_coeff_sum(Pvecteur vect): coefficient sum de tout les val de ce vecteur (devrait etre dans reduction? FC)
return Value Lei Zhou Mar.25, 91
vect | ect |
Definition at line 246 of file unaires.c.
References assert, Svecteur::succ, TCST, val_of, value_addto, value_notzero_p, VALUE_ZERO, Svecteur::var, and vecteur_val.
Referenced by is_inferior_monome().
bool vect_colin_base(Pvecteur vec, Variable var): renvoie true si --> --> vec = k var
false sinon
Attention: le vecteur nul est colineaire a tous les vecteurs de base
vec | ec |
var | ar |
Definition at line 508 of file reductions.c.
References var_of.
bool vect_common_variables_p(Pvecteur v1, v2) BA 19/05/94 input : two vectors.
output : true if they have at least one common variable, false otherwise. modifies : nothing.
v1 | 1 |
v2 | 2 |
Definition at line 397 of file unaires.c.
References Svecteur::succ, vect_contains_variable_p(), VECTEUR_NUL_P, and vecteur_var.
Referenced by elementary_convex_union(), and sc_restricted_to_variables_transitive_closure().
for qsort, returns:
pv1 | v1 |
pv2 | v2 |
Definition at line 352 of file unaires.c.
References var_of.
Referenced by find_vbase(), MaxBoundary(), MinBoundary(), polynome_sort(), var_pivotd(), and var_pivots().
To ease retrieval of vect_check()
Definition at line 557 of file reductions.c.
References vect_check().
bool vect_contains_variable_p(Pvecteur v, Variable var) BA 19/05/94 input : a vector and a variable output : true if var appears as a component of v, false otherwise.
modifies : nothing
var | ar |
Definition at line 415 of file unaires.c.
References variable_equal(), VECTEUR_NUL_P, and vecteur_var.
Referenced by DivExists(), translate_to_module_frame(), vect_common_variables_p(), and vect_same_variables_p().
direct duplication.
vect_dup() and vect_reversal() do the same thing : duplicate the vector with the reversal order. vect_copy duplicate the vector with the same order. in use of sc_copy. (DN,24/6/02) Does not change parameter b (DN,28/06/02)
Definition at line 240 of file alloc.c.
References abort, fprintf(), MALLOC, Svecteur::succ, val_of, var_of, VECTEUR, and VECTEUR_NUL.
Referenced by add_type_information(), c_convex_effects_on_actual_parameter_forward_translation(), check_positive_dependence(), contrainte_copy(), contrainte_parallele(), find_motif(), find_pattern(), main(), make_bound_expression(), print_call_precondition(), print_loopnest_dependence_cone(), sc_copy(), sc_elim_double_constraints(), sc_minmax_of_variable(), sc_projection_concat_proj_on_variables(), small_positive_slope_reduce_coefficients_with_bounding_box(), vect_gen_copy_tree(), xml_GlobalVariables(), and xml_LocalVariables().
Pvecteur vect_del_var(Pvecteur v_in, Variable var): allocation d'un nouveau vecteur egal a la projection de v_in selon la direction var (i.e.
le coefficient de la coordonnee var est mis a 0)
Soit evar le vecteur de base correspondant a var:
---->
allocate v_out;
-—> —> -—> —> —> v_out := v_in - <v_out . evar> evar
---->
return v_out;
v_in | _in |
var | ar |
Definition at line 206 of file unaires.c.
References vect_dup(), and vect_erase_var().
Referenced by affine_expression_of_loop_index_p(), array_access_to_array_ranges(), build_list_of_min(), constraint_to_bound(), constraints_to_loop_bound(), contraintes_to_expression(), do_group_statement_constant(), get_bounds_expression(), hpfc_integer_constant_expression_p(), make_vvs_from_sc(), monome_del_var(), outliner_smart_references_computation(), polynome_roots(), shift_expression_of_loop_index_p(), the_index_of_vect(), and translate_to_module_frame().
int vect_dimension(Pvecteur v): calcul du nombre de composantes non nulles et non constantes d'un vecteur
sum abs(sgn(v[i])) i
Definition at line 64 of file reductions.c.
References Svecteur::succ, and term_cst.
Referenced by choose_pattern(), find_pattern(), print_call_precondition(), sc_minmax_of_variable2(), sc_strong_normalize_and_check_feasibility2(), and xml_Pattern_Paving().
-> -> v := v / x; -> -> Si x vaut 0, la procedure aborte meme si v == 0 -> Attention, si x ne divise pas le pgcd des coefficients de v, la valeur retournee n'est pas colineaire a la valeur initiale
Definition at line 52 of file scalaires.c.
References Svecteur::succ, val_of, value_mone_p, value_one_p, value_pdivision, value_zero_p, vect_chg_sgn(), vect_clean(), vect_error(), and x.
Referenced by analyze_expression(), calculate_delay(), contrainte_normalize(), make_array_bounds(), make_rational_exp(), my_contrainte_normalize(), sc_find_equalities(), sommet_normalize(), and vect_normalize().
void vect_dump | ( | Pvecteur | v | ) |
void vect_dump(Pvecteur v): print sparse vector v on stderr.
By default, each dimension/variable is represented by an X followed by its hexadeximal address.
Intended for debug purposes. Its behavior depends on the setting of pointer variable_debug_name by init_variable_debug_name(). Different names can be returned for each variable, more useful than a pointer value.
Definition at line 304 of file io.c.
References variable_debug_name, and vect_fprint().
Referenced by affine_to_transformer(), check_coefficient_reduction(), compute_x_and_y_bounds(), find_first_integer_point_in_between(), make_loop_indice_equation(), new_constraint_for_coefficient_reduction_with_bounding_box(), sc_bounded_normalization(), sc_consistent_p(), sc_projection_optim_along_vecteur_ofl(), simple_affine_to_transformer(), simplify_constraint_with_bounding_box(), and Tiling_buffer_allocation().
end of vecteur-local.h
cproto-generated files alloc.c
end of vecteur-local.h
allocate v_out; v_out := v_in;
v_in | _in |
Definition at line 51 of file alloc.c.
References Svecteur::succ, val_of, var_of, and vect_chain().
Referenced by __attribute__(), add_affine_bound_conditions(), adg_sc_dup(), affine_to_transformer(), array_indices_communication(), block_to_complexity(), bounds_equal_p(), broadcast_of_dataflow(), build_list_of_min(), build_sc_machine(), build_sc_with_several_uniform_ref(), build_third_comb(), calculate_delay(), change_base_in_sc(), check_range_wrt_precondition(), complex_bound_computation(), constraint_to_bound(), contrainte_dup(), CopyAccVec(), create_farkas_poly(), dependence_system_add_lci_and_di(), dj_simple_inegs_to_eg(), dj_system_complement(), dup_list_of_Pvecteur(), dup_vv(), elim_var_with_eg(), eq_in_ineq(), expression_to_affine(), final_statement_to_complexity_evaluation(), find_eg(), find_pattern(), formal_and_actual_parameters_association(), free_guards(), fusion_buffer(), gcd_and_constant_dependence_test(), get_bounds_expression(), gomory_trait_eq(), include_trans_on_LC_in_ref(), integer_divide_to_transformer(), integer_power_to_transformer(), integer_right_shift_to_transformer(), loop_executed_approximation(), loop_index_domaine_to_contrainte(), loop_nest_to_wp65_code(), lower_bound_generation(), make_constraint_expression(), make_context_of_loop(), make_datum_movement(), make_dual(), make_load_blocks(), make_movements_loop_body_wp65(), make_reindex(), make_store_blocks(), matrices_to_loop_sc(), matrices_to_sc(), matrix_to_system(), MaxBoundary(), MinBoundary(), monome_dup(), monome_monome_div(), monome_monome_mult(), movement_computation(), my_vect_substract(), negate_expression(), normalize_intrinsic(), pa_path_to_few_disjunct_ofl_ctrl(), parallel_tiling(), Pcontrainte_separate_on_vars(), pivoter_pas(), plc_elim_var_with_eg(), plint_degen(), Pvecteur_to_assign_statement(), ray_dte_dup(), sc_dup1(), sc_find_equalities(), sc_image_computation(), sc_lexicographic_sort(), sc_projection_optim_along_vecteur_ofl(), sc_supress_same_constraints(), sc_to_tableau(), separate_variables(), set_dimensions_of_local_variable_family(), simple_affine_to_transformer(), simplify_deducable_variables(), simplify_dimension(), simplify_minmax_contrainte(), simplify_predicate(), sommet_dup(), substitute_and_create(), tile_hyperplane_constraints(), tile_membership_constraints(), Tiling_buffer_allocation(), tiling_transformation(), transformer_add_integer_relation_information(), transformer_add_loop_index_initialization(), transformer_equalities_add(), transformer_pattern_fix_point(), translate_global_values(), update_basis(), upper_bound_generation(), vect_add(), vect_add_first(), vect_change_base(), vect_cl_ofl_ctrl(), vect_del_var(), vect_extract(), vect_sort(), vect_substract(), xml_Compute_and_Need(), xml_Pattern_Paving(), and xml_Region_Range().
PRIVATE: introduit du sharing; never used...
Pvecteur vect_elem(Pvecteur vect, Variable var): retourne la valeur du pointeur vers le couple correspondant a la variable var dans le vecteur vect, s'il existe ou NULL sinon.
vect | ect |
var | ar |
Definition at line 91 of file private.c.
References var_of.
bool vect_equal(Pvecteur v1, Pvecteur v2): test a egalite de deux vecteurs
-> ->
return v1 == v2 ;
Note: le test n'est pas optimal puisque v2 est parcouru et compare a v1 meme si ces coefficients ont ete deja ete compare lors du parcours de v1; mais cela evite le "marquage" des coefficients vus;
shorter version, FC 28/09/94
v1 must be preserved for the second loop: use v
now v2 may be lost: use v2
v1 | 1 |
v2 | 2 |
Definition at line 278 of file reductions.c.
References Svecteur::succ, val_of, value_eq, var_of, and vect_coeff().
Referenced by adg_quast_leaf_solution_equal_p(), adg_suppress_2nd_in_1st_ps(), call_rwt(), contrainte_equal(), contrainte_in_liste(), dte_in_sg_p(), egaliste_rd(), egalite_equal(), egalite_in_liste(), exp_equals_p(), free_guards(), monome_colin(), monome_equal(), polynome_constant_p(), polynome_TCST(), ray_in_sg_p(), rd_in_liste(), same_expression_p(), semantics_is_inferior_pvarval(), som_in_liste(), sommet_egal(), sommet_in_sg_p(), suppress_sc_in_sc(), and vect_lexicographic_unsafe_compare_generic().
bool vect_equal_except(Pvecteur v1, Pvecteur v2, Variable var): test a egalite des projections selon la coordonnees var de deux vecteurs -> Soit e un vecteur de base quelconque: -> -> -> -> return <v1 .
e> == <v2 . e>; e!=var
v1 | 1 |
v2 | 2 |
var | ar |
Definition at line 319 of file reductions.c.
References Svecteur::succ, val_of, value_eq, var_of, and vect_coeff().
Referenced by eq_smg(), and sc_elim_double_constraints().
void vect_erase_var(Pvecteur * ppv, Variable v): projection du vecteur *ppv selon la direction v (i.e.
mise a zero de la coordonnee v du vecteur pointe par ppv)
Soit ev le vecteur de base correspondant a v:
—> —> —> -> -> *ppv := *ppv - <*ppv . ev> ev
Note: cette routine ne fait pas l'hypothese que chaque coordonnee n'apparait qu'une fois; on pourrait l'accelerer en forcant pvcour a NULL des que la coordonnee est trouvee.
A-t-on trouve la composante v?
Si oui, est-il possible de la dechainer?
elle n'est pas en tete de liste
Elle est en tete de liste; il faut modifier ppv
Non, on passe a la composante suivante...
ppv | pv |
Definition at line 106 of file unaires.c.
References FREE, Svecteur::succ, Svecteur::var, and VECTEUR.
Referenced by algorithm_row_echelon_generic(), base_remove_variable(), build_third_comb(), change_base_in_sc(), compose_vvs(), constraints_to_loop_bound(), find_motif(), find_pattern(), free_guards(), include_trans_on_LC_in_ref(), is_inferior_monome(), make_constraint_expression(), movement_computation(), my_substitute_var_with_vec(), my_vect_var_subst(), new_system_with_only_live_variable(), pip_solve(), pip_solve_min_with_big(), Pvecteur_to_assign_statement(), sc_find_equalities(), sc_fm_project_variables(), sc_force_variable_to_zero(), simplify_minmax_contrainte(), system_new_var_subst(), the_index_of_vect(), transform_in_ineq(), update_basis(), vect_add_elem(), vect_add_first(), vect_change_base(), vect_chg_coeff(), vect_del_var(), vect_printout_order(), vect_var_subst(), vvs_on_vecteur(), vvs_on_vvs(), xml_Boxes(), and xml_Region_Range().
void vect_error | ( | char * | name, |
char * | fmt, | ||
... | |||
) |
error.c
error.c
INTLIBRARY void vect_error(va_dcl va_list): should be called to terminate execution and to core dump when data structures are corrupted or when an undefined operation is requested (zero divide for instance). VECT_ERROR should be called as:
VECT_ERROR(function_name, format, expression-list)
where function_name is a string containing the name of the function calling VECT_ERROR, and where format and expression-list are passed as arguments to vprintf. VECT_ERROR terminates execution with abort. ARARGS0
print name of function causing error
print out remainder of message
create a core file for debug
name | ame |
fmt | mt |
Definition at line 50 of file error.c.
References abort, and fprintf().
Referenced by vect_div(), vect_max(), vect_min(), and vect_proport().
UNUSED - NOT TESTED.
Pvecteur vect_extract(Pvecteur pvec, Variable var): fonction qui extrait le couple (variable,coefficient) du vecteur et renvoie l'adresse d'un nouveau vecteur vers ce couple. On a donc un effet de bord sur pvec (qui est impossible a assurer dans tous les cas) et un retour de valeur
—> —> —> --> --> pvec := pvec - <pvec . var> var; -—> allocate pvec1; -—> —> --> --> return(pvec1 := <pvec . var> var);
Notes:
le couple interessant se trouve en tete
Sinon, c'est le vecteur 0
pvec | vec |
var | ar |
Definition at line 126 of file private.c.
References Svecteur::succ, var_of, and vect_dup().
void vect_fdump | ( | FILE * | f, |
Pvecteur | v | ||
) |
void vect_fdump(FILE * f, Pvecteur v): impression d'un vecteur creux par vect_fprint() avec passage de la fonction variable_debug_name()
Definition at line 320 of file io.c.
References f(), variable_debug_name, and vect_fprint().
PRIVATE: marquage du couple var_val comme visite par remplacement de var par -var dans le couple (OBSOLETE)
Value vect_coeff_m(Variable var, Pvecteur vect)
static Value vect_coeff_m(var,vect) Variable var; Pvecteur vect; { for (; vect != NULL ; vect = vect->succ) if (var_of(vect) == var) { marquer(vect); return(val_of(vect)); } return(0); } PRIVATE Pvecteur vect_tri_old(Pvecteur pvec): allocation d'un vecteur prenant une valeur egale a celle de pvec mais dont les couples (variable,valeur) sont tries dans "l'ordre croissant" des vecteurs de base (i.e. des variables) Variable vect_first_var(Pvecteur pvec) retourne la premiere variable (au sens CAR) du vecteur pvec routine sale mais qui permet d'iterer sur les variables formant un vecteur ou une base. 20/06/90 PB
pvec | vec |
Definition at line 227 of file private.c.
Referenced by is_inferior_monome(), and pvecteur_to_polynome().
void vect_fprint | ( | FILE * | f, |
Pvecteur | v, | ||
get_variable_name_t | variable_name | ||
) |
void vect_fprint(FILE * f, Pvecteur v, char * (*variable_name)()): impression d'un vecteur creux v sur le fichier f; le nom de chaque coordonnee est donne par la fonction variable_name()
Par exemple, le vecteur v -> -> -> -> v == 2 i - 3 j + k est imprime sous la forme 2 * i - 3 * j + k LF ou les symboles i, j et k sont obtenus via la fonction pointee par variable_name()
Le vecteur nul est represente par vecteur nul LF
Note: attention au linefeed final il n'existe pas de fonction relisant des vecteurs sous cette forme (pour le moment...)
Modifications:
variable_name | ariable_name |
Definition at line 124 of file io.c.
References f(), fprint_Value(), fprintf(), Svecteur::succ, TCST, Svecteur::val, Svecteur::var, and variable_name().
Referenced by add_loop_skip_condition(), chose_variable_to_project_for_feasability(), compute_iteration_domain(), create_tile_basis(), dbg_ray_dte_rm(), dj_variable_substitution_with_eqs_ofl_ctrl(), eval_var(), find_iteration_domain(), fprint_message(), invariant_vector_p(), loop_iteration_domaine_to_sc(), loop_nest_to_wp65_code(), module_to_wp65_modules(), movement_computation(), new_system_with_only_live_variable(), pa_path_to_few_disjunct_ofl_ctrl(), parallel_tiling(), pvecteur_to_polynome(), ray_dte_fprint(), reduce_coefficients_with_bounding_box(), reg_v_debug(), sc_elim_redund_with_first_ofl_ctrl(), small_positive_slope_reduce_coefficients_with_bounding_box(), sommet_fprint(), tiling_transformation(), transformer_pattern_fix_point(), vect_debug(), vect_dump(), vect_fdump(), and vect_print().
void vect_fprint_as_dense(FILE * f, Pvecteur v, Pbase b):
Par exemple, le vecteur v -> -> -> -> v == 2 i - 3 j + k est imprime sous la forme ( 2 -3 1) dans la base (i j k)
No constant term TCST is expected.
I do not know what should be done for constant terms...
Definition at line 159 of file io.c.
References abort, f(), fprint_Value(), Svecteur::succ, VARIABLE_DEFINED_P, vect_coeff(), vect_in_basis_p(), VECTEUR_NUL_P, and vecteur_var.
Referenced by ray_dte_fprint_as_dense(), and sommet_fprint_as_dense().
void vect_fprint_as_monome | ( | FILE * | f, |
Pvecteur | v, | ||
Pbase | b, | ||
get_variable_name_t | variable_name, | ||
char * | mult_symbol | ||
) |
void vect_fprint_as_monome(FILE * f, Pvecteur v, Pbase b, char * (*variable_name)(), char *mult_symbol): impression d'un vecteur creux considere comme un monome sans coefficient.
Par ex.: le vecteur 2 * i - 3 * j + k est ecrit: "i^2 * j^(-3) * k". Le nom de chaque variable est donne par la fonction variable_name(). L'ordre dans lequel sont ecrites les inconnues du monome est fixe par la base b. Le symbole "multiplication" est passe dans (char *) mult_symbol: " * ", ".", "x", "", ... le vecteur de base special TCST n'est pas affiche: seulement son coefficient. Pas de
a la fin de l'affichage.
variable_name | ariable_name |
mult_symbol | ult_symbol |
Definition at line 201 of file io.c.
References f(), fprintf(), free(), variable_name(), and vect_sprint_as_monome().
Referenced by prv().
Pvecteur vect_in_basis_p(Pvecteur v, Pbase b): check that all coordinates in v are in b, i.e.
vector v is a membre of the space generated by b
Bugs:
I do not know what should be done for constant terms...
Definition at line 342 of file base.c.
References abort, base_contains_variable_p(), Svecteur::succ, VARIABLE_DEFINED_P, VECTEUR_NUL_P, and vecteur_var.
Referenced by algorithm_row_echelon_generic(), gcd_and_constant_dependence_test(), legal_point_p(), print_cone_vecteur(), and vect_fprint_as_dense().
v | vecteur being scanned |
val | maximum absolute value allowed, or 0 to ignore |
val | al |
Definition at line 564 of file reductions.c.
References linear_assert, Svecteur::succ, val_of, value_gt, value_lt, value_posz_p, value_uminus, value_zero_p, and var_of.
Referenced by contrainte_remove_large_coef().
qsort() is not safe if the comparison function is not antisymmetric.
It wanders out of the array to be sorted. It's a pain to debug. Let's play safe. Version for equations
v1 | 1 |
v2 | 2 |
Definition at line 433 of file unaires.c.
References assert, and vect_lexicographic_unsafe_compare().
Referenced by equation_lexicographic_compare(), and sc_lexicographic_sort().
int vect_lexicographic_compare2 | ( | Pvecteur | v1, |
Pvecteur | v2, | ||
int(*)(Pvecteur *, Pvecteur *) | compare | ||
) |
Version for inequalities.
v1 | 1 |
v2 | 2 |
Definition at line 449 of file unaires.c.
References assert, and vect_lexicographic_unsafe_compare2().
Referenced by inequality_lexicographic_compare().
int vect_lexicographic_unsafe_compare | ( | Pvecteur | v1, |
Pvecteur | v2, | ||
int(*)(Pvecteur *, Pvecteur *) | compare | ||
) |
v1 | 1 |
v2 | 2 |
Definition at line 464 of file unaires.c.
References vect_lexicographic_unsafe_compare_generic().
Referenced by vect_lexicographic_compare().
int vect_lexicographic_unsafe_compare2 | ( | Pvecteur | v1, |
Pvecteur | v2, | ||
int(*)(Pvecteur *, Pvecteur *) | compare | ||
) |
v1 | 1 |
v2 | 2 |
Definition at line 474 of file unaires.c.
References vect_lexicographic_unsafe_compare_generic().
Referenced by vect_lexicographic_compare2().
int vect_lexicographic_unsafe_compare_generic | ( | Pvecteur | , |
Pvecteur | , | ||
int(*)(Pvecteur *, Pvecteur *) | , | ||
bool | |||
) |
Pvecteur vect_make(v, [var, val,]* 0, val) Pvecteur v; // may be NULL, use assigne anyway Variable var; Value val;.
Builds a vector from the list of arguments, by successive additions. ends when a 0 Variable (that is TCST!) is encountered.
Because of the var val order, this function cannot be called directly with a va_list, but (va_list, 0) should be used, since the val argument is expected, read and used anyway.
CAUTION: the initial vector is modified by the process!
var | ar |
val | al |
Definition at line 165 of file alloc.c.
References vect_add_elem().
Referenced by add_type_information(), align_check(), buffer_acces(), call_rwt(), compute_entity_to_declaration_constraints(), compute_x_and_y_bounds(), convex_in_effect_loop_range_fix(), fortran_data_to_prec_for_variables(), fortran_user_function_call_to_transformer(), fusion(), fusion_buffer(), generate_system_for_equal_variables(), generate_work_sharing_system(), Hierarchical_tiling(), hpfc_compute_align_constraints(), hpfc_compute_distribute_constraints(), hpfc_compute_entity_to_new_declaration(), hpfc_compute_unicity_constraints(), interlaced_basic_workchunk_regions_p(), loop_basic_workchunk_to_workchunk(), make_loop_indice_equation(), processor_loop(), sc_image_computation(), sc_minmax_of_variables(), small_positive_slope_reduce_coefficients_with_bounding_box(), Tiling2_buffer(), Tiling_buffer_allocation(), transformer_derivative_constraints(), transformer_derivative_fix_point(), and transformer_list_generic_transitive_closure().
Generate a sparse vector a x + b TCST.
Definition at line 226 of file alloc.c.
References TCST, vect_add_elem(), vect_new(), and x.
Referenced by contrainte_make_1D().
Allocate a new vector v whose coefficient are given by the list of values ad whose dimension is given by b.
The number of constant values passed as argument is supposed to be equal to the dimension of b.
Note: 0 is a normal value. I see no way to mark the last argument.
FI: I add this function to check under gdb that a given point belongs to a constraint system. The manual verification is tedious and error prone. This is done for debugging in Linear/C3 Library the linked_regions bug.
handle first argument - the first element of a basis has rank 1
get others
val | al |
Definition at line 198 of file alloc.c.
References base_dimension, int, variable_of_rank(), vect_add_elem(), and VECTEUR_NUL.
Referenced by build_sc_nredund_2pass_ofl_ctrl().
Value vect_max(Pvecteur v): recherche du coefficient non nul maximum d'un vecteur v; aborte sur le vecteur 0 puisqu'il faudrait renvoyer plus l'infini.
max v[i] i v[i]!=0
Note: changement de semantique puisque 0 etait renvoye auparavant pour le vecteur 0
Modifications:
Definition at line 240 of file reductions.c.
References max, val_of, value_max, VALUE_NAN, and vect_error().
Value vect_max0(Pvecteur v): recherche du coefficient maximum d'un vecteur v; ce coefficient est toujours au moins egal a 0 car on ne dispose pas d'une base pour verifier que TOUS les coefficients sont negatifs.
Note: on evite le probleme du vecteur de dimension 0 dont le max vaut moins l'infini
Definition at line 164 of file reductions.c.
References max, val_of, value_max, and VALUE_ZERO.
Value vect_min(Pvecteur v): recherche du coefficient non nul minimum d'un vecteur v; aborte sur le vecteur 0 puisqu'il faudrait renvoyer plus l'infini.
min v[i] i v[i]!=0
Note: changement de semantique puisque 0 etait renvoye auparavant pour le vecteur 0
just to avoid a gcc warning
Definition at line 208 of file reductions.c.
References min, val_of, value_min, VALUE_NAN, and vect_error().
Value vect_min0(Pvecteur v): recherche du coefficient minimum d'un vecteur v; ce coefficient est toujours au moins egal a 0 car on ne dispose pas d'une base pour verifier que TOUS les coefficients sont negatifs.
Note: on evite le probleme du vecteur de dimension 0 dont le min vaut moins l'infini
Definition at line 186 of file reductions.c.
References min, val_of, value_min, and VALUE_ZERO.
Pvecteur vect_multiply(Pvecteur v, Value x): multiplication du vecteur v par le scalaire x, si x est different de 0.
-> -> v := x v;
Ancien nom: vect_mult() Ancien profil: void vect_mult(); ne permettait pas de renvoyer un vecteur nul en cas de multiplication par zero d'un vecteur non nul
Definition at line 123 of file scalaires.c.
References Svecteur::succ, val_of, value_mone_p, value_one_p, value_product, value_zero_p, vect_chg_sgn(), vect_rm(), VECTEUR_NUL, and x.
Referenced by analyze_expression(), array_indices_communication(), bounds_equal_p(), build_convex_constraints_from_vertices(), build_list_of_min(), build_sc_machine(), build_third_comb(), constraints_eliminate_constant_terms(), contrainte_parallele(), eq_in_ineq(), expression_equal_in_context_p(), find_intermediate_constraints(), find_intermediate_constraints_recursively(), full_linearization(), generic_minmax_to_transformer(), include_trans_in_sc(), include_trans_on_LC_in_ref(), integer_divide_to_transformer(), integer_minmax_to_transformer(), integer_power_to_transformer(), integer_right_shift_to_transformer(), loop_bound_evaluation_to_transformer(), make_bound_expression(), make_context_of_loop(), my_vect_var_subst(), normalize_intrinsic(), NormalizeIntrinsic(), partial_linearization(), pivoter(), prepare_reindexing(), sc_lexicographic_sort(), sc_oppose(), sc_to_tableau(), simplify_dimension(), simplify_predicate(), small_positive_slope_reduce_coefficients_with_bounding_box(), system_new_var_subst(), transformer_add_condition_information_updown(), valuer(), vect_change_base(), vect_cl_ofl_ctrl(), vect_product(), and vect_var_subst().
Pvecteur vect_new(Variable var,Value coeff): allocation d'un vecteur colineaire au vecteur de base var et de coefficient coeff (i.e.
creation d'un nouveau vecteur ne comportant qu'un seul couple (var,coeff))
-->
coeff var
Pourrait etre remplace par un vect_chain(NULL,,)
Modifications:
fprintf(stderr, "%10.3f MB", (sbrk(0) - etext)/(double)(1 << 20)); // not portable
xit(-1);
var | ar |
coeff | oeff |
Definition at line 110 of file alloc.c.
References abort, fprintf(), MALLOC, Svecteur::succ, val_of, var_of, and VECTEUR.
Referenced by add_elem_to_list_of_Pvecteur(), add_equivalence_equality(), add_loop_index_exit_value(), add_type_information(), add_x_list(), adg_dataflowgraph(), adg_dataflowgraph_with_extremities(), adg_get_predicate_of_loops(), adg_max_of_leaves(), affine_to_transformer(), ajout_dte(), align_check(), apply_farkas(), array_indices_communication(), array_scalar_access_to_bank_communication(), base_add_variable(), base_complete(), binary_to_normalized(), bitwise_xor_to_transformer(), broadcast_of_dataflow(), build_esv_list(), build_image_base(), build_sc_machine(), build_third_comb(), c_convex_effects_on_actual_parameter_forward_translation(), calculate_delay(), comp_exec_domain(), completer_base(), config_vecteur(), converti_psysmin_psysmax(), cout_nul(), create_farkas_poly(), dependence_cone_positive(), dj_system_complement(), do_solve_hardware_constraints_on_nb_proc(), do_terapix_warmup_patching(), elim_var_with_eg(), entity_list_to_base(), expression_equal_in_context_p(), expression_flt(), expression_less_than_in_context(), expression_multiply_sizeof_to_transformer(), find_implicit_equation(), find_vbase(), fonct_max(), fonct_max_all(), fonct_max_d(), fonct_min(), fonct_min_all(), fonct_min_d(), fonct_read(), generate_one_message(), generate_work_sharing_system(), generic_abs_to_transformer(), generic_equality_to_transformer(), generic_minmax_to_transformer(), hpfc_compute_distribute_constraints(), hpfc_compute_entity_to_new_declaration(), iabs_to_transformer(), include_parameters_in_sc(), integer_left_shift_to_transformer(), integer_minmax_to_transformer(), integer_multiply_to_transformer(), integer_power_to_transformer(), local_tile_constraints(), logical_binary_function_to_transformer(), logical_binary_operation_to_transformer(), logical_constant_to_transformer(), logical_unary_operation_to_transformer(), loop_basic_workchunk_to_workchunk(), loop_bound_evaluation_to_transformer(), loop_bounds_to_tile_bounds(), loop_index_domaine_to_contrainte(), loop_regions_normalize(), lvbase_add(), make_datum_movement(), make_dual(), make_load_blocks(), make_monome(), make_movement_scalar_wp65(), make_movements_loop_body_wp65(), make_store_blocks(), mat_sys_conv(), matrices_to_constraints(), matrices_to_constraints_with_sym_cst(), matrices_to_contraintes_with_sym_cst(), matrices_to_loop_sc(), matrices_to_sc(), matrix_to_system(), mk_rn(), monome_del_var(), monome_monome_div(), monome_monome_mult(), movement_computation(), my_matrices_to_constraints_with_sym_cst(), my_matrices_to_constraints_with_sym_cst_2(), my_substitute_var_with_vec(), normalize_constant(), normalize_reference(), NormalizeCall(), NormalizeConstant(), NormalizeReference(), old_prototype_factorize(), one_message_guards_and_neighbour(), one_receive_message(), pa_path_to_few_disjunct_ofl_ctrl(), plc_elim_var_with_eg(), plc_make_vvs_with_vector(), plint_degen(), polynome_constant_p(), polynome_roots(), polynome_TCST(), prepare_reindexing(), prototype_factorize(), pu_matrices_to_contraintes(), put_source_ind(), re_do_it(), reference_conversion_computation(), relation_to_transformer(), remove_variables_if_possible(), sc_base_add_variable(), sc_empty(), sc_find_equalities(), sc_image_computation(), sc_multiply_constant_terms(), sc_to_vvs(), simple_addition_to_transformer(), simple_affine_to_transformer(), simplify_float_constraint(), sort_tile_indices(), substitute_var_with_vec(), top_down_abc_dimension(), transformer_add_3d_affine_constraint(), transformer_add_condition_information_updown(), transformer_add_equality(), transformer_add_equality_with_affine_term(), transformer_add_equality_with_integer_constant(), transformer_add_identity(), transformer_add_inequality(), transformer_add_inequality_with_affine_term(), transformer_add_inequality_with_integer_constraint(), transformer_add_sign_information(), transformer_convex_hulls(), transformer_logical_inequalities_add(), translate_global_value(), valuer(), var_pivotd(), var_pivots(), var_posit(), variables_in_declaration_list(), vect_chain(), vect_make_1D(), vect_make_line(), vect_read(), vecteur_mult(), vecteur_of_zvec(), xml_Chain_Graph(), xml_LocalVariables(), and xml_Pattern_Paving().
void vect_normalize | ( | Pvecteur | v | ) |
unaires.c
unaires.c
-> -> -> -> si v == 0 alors v := 0; sinon pgcd = PGCD v[i]; i -> -> v := v / pgcd
Le pgcd est toujours positif.
Ancien nom: vect_norm()
Definition at line 59 of file unaires.c.
References value_notone_p, value_notzero_p, vect_div(), and vect_pgcd_all().
Referenced by bounds_equal_p(), build_third_comb(), compute_x_and_y_bounds(), include_trans_on_LC_in_ref(), make_rational_exp(), my_sc_normalize(), norm_eq(), ray_dte_normalize(), sc_add_normalize_eq(), sc_add_normalize_ineq(), sc_elim_double_constraints(), sc_elim_redund(), sc_elim_redund_with_first_ofl_ctrl(), sc_gcd_normalize(), sc_normalize(), simplify_relational_expression(), system_new_var_subst(), and vect_make_line().
Definition at line 182 of file unaires.c.
References Svecteur::succ, Svecteur::val, value_mone_p, value_one_p, and Svecteur::var.
bool vect_oppos(Pvecteur v1, Pvecteur v2): test de l'opposition de deux vecteurs
-> -> ->
return v1 + v2 == 0 ;
v1 | 1 |
v2 | 2 |
Definition at line 360 of file reductions.c.
References Svecteur::succ, val_of, value_eq, value_uminus, var_of, and vect_coeff().
Referenced by contrainte_oppos(), egalite_equal(), egalite_in_liste(), and free_guards().
bool vect_opposite_except(Pvecteur v1, Pvecteur v2, Variable var): test a egalite des projections selon la coordonnees var de deux vecteurs -> Soit e un vecteur de base quelconque: -> -> -> -> return <v1 .
e> == - <v2 . e>; e!=var
v1 | 1 |
v2 | 2 |
var | ar |
Definition at line 399 of file reductions.c.
References Svecteur::succ, val_of, value_eq, value_uminus, var_of, and vect_coeff().
Referenced by find_motif(), and inequalities_opposite_p().
Value vect_pgcd(Pvecteur v): calcul du pgcd de tous les coefficients non nul d'un vecteur v.
return PGCD v[i] i v[i]!=0
Renvoie 1 pour le vecteur nul (ca devrait etre +infinity)
Definition at line 108 of file reductions.c.
References pgcd, val_of, value_abs, value_notone_p, and VALUE_ONE.
Referenced by analyze_expression(), calculate_delay(), gomory_trait_eq(), make_array_bounds(), make_rational_exp(), sc_find_equalities(), sommet_normalize(), and vect_normalize().
Value vect_pgcd_except(Pvecteur v, Variable var): calcul du pgcd de tous les coefficients non nul d'un vecteur v, sauf le coefficient correspondant a la variable var.
return PGCD v[i] i!=var v[i]!=0
Renvoie 1 pour le vecteur nul (ca devrait etre +infinity)
skip var's coeff if it comes first
var | ar |
Definition at line 130 of file reductions.c.
References pgcd, Svecteur::succ, val_of, value_abs, value_notone_p, VALUE_ONE, and var_of.
Referenced by contrainte_normalize(), and my_contrainte_normalize().
void vect_print | ( | Pvecteur | v, |
get_variable_name_t | variable_name | ||
) |
void vect_print(Pvecteur v, char * (*variable_name)()): impression d'un vecteur creux v sur stdout; le nom de chaque coordonnee est donne par la fonction variable_name(); voir vect_fprint()
variable_name | ariable_name |
Definition at line 312 of file io.c.
References variable_name(), and vect_fprint().
Value vect_prod_scal(v1,v2): produit scalaire de v1 et de v2.
sum v1[i] * v2[i] i
v1 | 1 |
v2 | 2 |
Definition at line 82 of file reductions.c.
References val_of, value_addto, value_product, VALUE_ZERO, var_of, and vect_coeff().
int vect_proport(Pvecteur v1, Pvecteur v2): test de la colinearite de deux vecteurs et de leur direction.
return 1 si les deux vecteurs sont colineaires et dans la meme direction c2 v1 == c1 v1, c1*c2 > 0 c'est le cas si v1 ou v2 vaut le vecteur nul -1 si les deux vecteurs sont colineaires et dans des directions opposees c2 v1 == c1 v1, c1*c2 < 0 0 s'ils ne sont pas colineaires
-> -> ->
Note: aborte pour v1 == v2 == 0 parce qu'il est impossible de decider entre le retour de 1 et de -1
Modifications:
v1 | 1 |
v2 | 2 |
Definition at line 455 of file reductions.c.
References Svecteur::succ, val_of, value_eq, value_mult, value_pos_p, value_product, var_of, vect_coeff(), and vect_error().
io.c
io.c
Pvecteur vect_read(Pbase * b): lecture interactive d'un vecteur sur stdin; la base b est modifiee de maniere a ce que chaque composante y figure bien;
La representation d'un vecteur dont la troisieme composante vaut 2, la dixieme 6 et les autres 0 peut etre: 3 2 1 10 6 0 ou x3 2 1 x10 6 0 Le 1 veut dire qu'il faut continuer les lectures, le zero, qu'il faut arreter
Ce format est malheureusement incompatible avec celui de vect_fprint()
Definition at line 65 of file io.c.
References assert, base_contains_variable_p(), base_find_variable(), buffer, printf(), scan_Value(), Svecteur::succ, variable_make(), vect_add_variable(), vect_new(), and VECTEUR_NUL.
Pvecteur vect_rename_variables | ( | Pvecteur | v, |
bool(*)(Variable) | renamed_p, | ||
Variable(*)(Variable) | new_variable | ||
) |
Pvecteur vect_rename_variables(v, renamed_p, new_variable) Pvecteur v; bool (*renamed_p)(Variable); Variable (*new_variable)(Variable);.
what: driven renaming of variables in v. how: scans the vector, decides and replaces. input: Pvecteur v, decision and replacement functions. output: v is returned (the same) side effects:
initial vector is kept
ar!=TCST &&
Definition at line 281 of file base.c.
References new_variable, Svecteur::succ, and var_of.
Referenced by sc_rename_variables(), and vect_variables_to_values().
Pvecteur vect_reversal(Pvecteur vect_in); produces the reversal vector of the vect_in.
vect_in is not killed.
12/09/91, YY
vect_in | ect_in |
Definition at line 237 of file private.c.
References Svecteur::succ, vect_add_elem(), VECTEUR_NUL, VECTEUR_NUL_P, vecteur_val, and vecteur_var.
Referenced by adg_list_to_vect(), contrainte_reversal(), vect_add_first(), vect_gen_read(), and xml_LoopOffset().
void vect_rm | ( | Pvecteur | v | ) |
void vect_rm(Pvecteur v): desallocation des couples de v;
Attention! La procedure appelante doit penser a modifier la valeur de v apres l'appel pour ne pas pointer dans le vide: vect_rm(v); v = NULL;
Il vaudrait mieux que vect_rm retourne NULL et qu'on puisse ecrire: v = vect_rm(v); ou que vect_rm prenne un Pvecteur * en argument: vect_rm(&v);
Definition at line 78 of file alloc.c.
References free(), and Svecteur::succ.
Referenced by add_affine_bound_conditions(), add_reference_information(), add_type_information(), affine_expression_of_loop_index_p(), affine_to_transformer(), append_eg(), bounds_equal_p(), build_and_test_dependence_context(), build_convex_constraints_from_vertices(), build_image_base(), c_convex_effects_on_actual_parameter_forward_translation(), cell_reference_sc_exact_projection_along_variable(), check_positive_dependence(), constraints_keep_invariants_only(), constraints_to_loop_bound(), contrainte_free(), contrainte_parallele(), contrainte_reversal(), contrainte_subst_ofl_ctrl(), cout_nul(), dependence_system_add_lci_and_di(), dj_system_complement(), do_group_statement_constant(), do_solve_hardware_constraints_on_volume(), do_terapix_warmup_patching(), dual(), dual_positive(), elim_var_with_eg(), eq_in_ineq(), eq_set_vect_nul(), erase_trivial_ineg(), expression_equal_in_context_p(), expression_flt(), expression_less_than_in_context(), find_eg(), find_motif(), find_pattern(), find_vbase(), free_vector_list(), FreeNormalized(), gcd_and_constant_dependence_test(), hpfc_integer_constant_expression_p(), invariant_vector_p(), is_inferior_monome(), lvbase_ote_no_ligne(), make_bound_expression(), make_vecteur_expression(), monome_monome_mult(), monome_rm(), my_substitute_var_with_vec(), my_system_remove_variables(), outliner_smart_references_computation(), pa_path_to_few_disjunct_ofl_ctrl(), Pcontrainte_to_expression_list(), plc_elim_var_with_eg(), plint(), plint_degen(), plreal(), polynome_constant_p(), polynome_TCST(), polynome_used_var(), primal(), primal_positive(), print_call_precondition(), print_loopnest_dependence_cone(), Pvecteur_to_assign_statement(), ray_dte_rm(), region_exact_projection_along_parameters(), region_exact_projection_along_variable(), remove_variables_if_possible(), sc_bounded_normalization(), sc_concatenate(), sc_elim_db_constraints(), sc_elim_double_constraints(), sc_elim_redund_with_first_ofl_ctrl(), sc_find_equalities(), sc_free1(), sc_kill_db_eg(), sc_lexicographic_sort(), sc_minmax_of_variable(), sc_minmax_of_variable_optim(), sc_proj_optim_on_di_ofl(), sc_projection_ofl_along_list_of_variables(), sc_projection_optim_along_vecteur_ofl(), sc_rm(), sc_safe_elim_db_constraints(), sc_safe_kill_db_eg(), sc_simplex_feasibility_ofl_ctrl_fixprec(), sc_substitute_dimension(), sc_supress_parallel_redund_constraints(), sc_supress_same_constraints(), sc_transform_ineg_in_eg(), shift_expression_of_loop_index_p(), simple_affine_to_transformer(), simplify_constraint_with_bounding_box(), simplify_float_constraint(), simplify_float_constraint_system(), sl_fprint_tab(), sommet_rm(), sommets_rm(), substitute_and_create(), substitute_var_with_vec(), top_down_abc_dimension(), transformer_add_integer_relation_information(), transformer_projection_with_redundancy_elimination_and_check(), translate_to_module_frame(), try_reorder_expression_call(), uniform_dependence_p(), valuer(), var_pivotd(), var_pivots(), vect_gen_free(), vect_multiply(), vect_product(), vect_subst(), xml_Chain_Graph(), xml_Compute_and_Need(), xml_GlobalVariables(), and xml_LocalVariables().
Pvecteur vect_sign(Pvecteur v): application de l'operation signe au vecteur v.
-> -> v := signe(v ); -> return v ;
Definition at line 269 of file unaires.c.
References int_to_value, Svecteur::succ, val_of, and value_sign.
reductions.c
reductions.c
INTLIBRARY int vect_size(Pvecteur v): calcul du nombre de composantes non nulles d'un vecteur
sum abs(sgn(v[i])) i
Definition at line 47 of file reductions.c.
Referenced by actual_convex_union(), add_elem_to_list_of_Pvecteur(), affine_expression_of_loop_index_p(), algorithm_row_echelon_generic(), alignment_p(), args_to_transformer(), bound_generation(), build_sc_with_several_uniform_ref(), check_tiling_legality(), choose_pattern(), chose_variable_to_project_for_feasability(), constant_constraint_check(), constraint_distribution(), constraints_sort_info(), constraints_sort_with_compare(), constraints_with_sym_cst_to_matrices(), contrainte_normalize(), contrainte_parallele(), contrainte_simple_equality(), dependence_cone_positive(), do_group_statement_constant(), eligible_for_coefficient_reduction_with_bounding_box_p(), EvalNormalized(), expression_and_precondition_to_integer_interval(), expression_integer_constant_p(), find_motif(), find_pattern(), gcd_and_constant_dependence_test(), hpfc_integer_constant_expression_p(), HpfcExpressionToInt(), look_for_the_best_counter(), loop_nest_to_tile(), loop_nest_to_wp65_code(), main(), make_constraint_expression(), make_loop_indice_equation(), make_reindex(), matrices_to_loop_sc(), movement_computation(), my_constraints_with_sym_cst_to_matrices(), normalized_constant_p(), parallel_tiling(), pip_solve(), pip_solve_min_with_big(), polynome_roots(), print_call_precondition(), region_range_nul_p(), sc_append(), sc_bounded_normalization(), sc_build_triang_elim_redund(), sc_creer_base(), sc_cute_convex_hull(), sc_dup1(), sc_elim_db_constraints(), sc_elim_double_constraints(), sc_elim_redund_with_first_ofl_ctrl(), sc_empty_p(), sc_gen_read(), sc_image_computation(), sc_kill_db_eg(), sc_normalize2(), sc_projection_concat_proj_on_variables(), sc_restricted_to_variables_transitive_closure(), sc_safe_append(), sc_safe_elim_db_constraints(), sc_safe_kill_db_eg(), sc_to_tableau(), sc_triang_elim_redund(), set_dimensions_of_local_variables(), shift_expression_of_loop_index_p(), simple_indices_p(), simplify_constraint_with_bounding_box(), simplify_float_constraint(), single_var_vecteur_p(), sl_fprint_tab(), small_slope_and_first_quadrant_p(), sort_unknowns(), the_index_of_vect(), transformer_add_value_update(), transformer_add_variable_incrementation(), transformer_add_variable_update(), transformer_derivative_fix_point(), transformer_filter(), transformer_list_generic_transitive_closure(), transformer_normalize(), transformer_projection_with_redundancy_elimination_and_check(), try_reorder_expression_call(), uniform_dependence_p(), vect_const_p(), vect_lexicographic_unsafe_compare_generic(), vect_simple_definition_p(), vect_sort_in_place(), and xml_LoopOffset().
char* vect_sprint_as_monome | ( | Pvecteur | v, |
Pbase | b, | ||
get_variable_name_t | variable_name, | ||
char * | mult_symbol | ||
) |
char *vect_sprint_as_monome(Pvecteur v, Pbase b, char * (*variable_name)(), char *mult_symbol): Retourne dans une chaine le Pvecteur considere comme un monome sans coefficient.
(voir ci-dessus)
si la base est vide: affiche comme ca vient
si la base n'est pas vide, affiche selon l'ordre qu'elle definit
exp < 0
inutile pour les polynomes
(un peu tard:-)
variable_name | ariable_name |
mult_symbol | ult_symbol |
Definition at line 217 of file io.c.
References assert, exp, sprint_Value(), strdup(), Svecteur::succ, Svecteur::val, value_one_p, value_pos_p, Svecteur::var, variable_name(), vect_coeff(), and VECTEUR_NUL_P.
Referenced by monome_sprint(), and vect_fprint_as_monome().
Pvecteur vect_subst(Variable v, Pvecteur v1, Pvecteur v2): calcul d'un vecteur v3 tel que l'intersection des hyperplans definis par v1 et v2 soit egale a l'intersection des hyperplans definis par v1 et v3, et que v appartiennent a l'hyperplan defini par v3.
v3 est defini a une constante multiplicative pret et ses coefficients ne sont donc pas necessairement normalises, mais on s'arrange pour multiplier v2 par une constante positive ce qui est utile si v2 represente une inegalite (cf. package contrainte).
-> -> -> -> -> -> -> -> -> -> -> { U / V1 . u = 0 & v2 . u = 0 } = { u / v1 . u = 0 & v3 . u = 0 }
-> -> v3 . v = 0
Si v2 remplit la condition v2 . v = 0, on prend v3 = v2.
Il faut comme precondition a l'appel que v1 . v != 0
Le vecteur v1 est preserve. Le vecteur v2 est detruit. v3 est alloue.
Cette routine peut servir a eliminer une variable entre deux egalites ou inegalites. C'est pourquoi v2 est detruit. Il est destine a etre remplace par v3. Voir contrainte_subst().
ATTENTION: je ne comprends pas a quoi sert le vect_chg_coeff(). F.I. Les commentaires precedent sont donc partiellement (?) faux!!!
cv_v1 = coeff de v dans v1
cv_v2 = coeff de v dans v2
v2 est solution; i.e., substitution non faite: var absente
v1 | 1 |
v2 | 2 |
Definition at line 286 of file binaires.c.
References value_uminus, VALUE_ZERO, vect_chg_coeff(), vect_cl2(), vect_coeff(), and vect_rm().
Pvecteur vect_substitute_dimension(Pvecteur v, Variable i, Pvecteur s)
Vector v is updated to be equal to M v, where M is the identity matrix except for its ith column that is replaced by s. In other words, the resulting v is v + v_i s - v_i e_i = v + v_i (s - e_i), where e_i is the ith base vector.
Because the transformation is applied to a constraint system, it is better to update s once, and not a this low-level. So this compute v + v_i s.
Vector s is preserved.
Definition at line 99 of file binaires.c.
References vect_cl(), and vect_coeff().
Referenced by contrainte_substitute_dimension().
Pvecteur vect_substract(Pvecteur v1, Pvecteur v2): allocation d'un vecteur v dont la valeur est la difference des deux vecteurs v1 et v2.
->
allocate v; -> -> -> v := v1 - v2; -> return v;
v1 | 1 |
v2 | 2 |
Definition at line 75 of file binaires.c.
References Svecteur::succ, val_of, value_uminus, var_of, vect_add_elem(), and vect_dup().
Referenced by add_declaration_list_information(), add_loop_index_exit_value(), add_loop_skip_condition(), add_reference_information(), adg_dataflowgraph(), adg_dataflowgraph_with_extremities(), adg_get_predicate_of_loops(), adg_max_of_leaves(), affine_to_transformer(), analyze_expression(), build_contraction_matrices(), build_sc_with_several_uniform_ref(), c_convex_effects_on_actual_parameter_forward_translation(), calculate_delay(), check_range_wrt_precondition(), comp_exec_domain(), count_eq_occ(), expression_equal_in_context_p(), expression_flt(), expression_less_than_in_context(), free_guards(), gcd_and_constant_dependence_test(), include_trans_on_LC_in_ref(), loop_executed_approximation(), make_array_bounds(), make_lin_op_exp(), monome_monome_div(), my_matrices_to_constraints_with_sym_cst(), normalize_intrinsic(), NormalizeIntrinsic(), pip_solve(), pip_solve_min_with_big(), sc_elim_double_constraints(), simple_affine_to_transformer(), simplify_dimension(), simplify_predicate(), simplify_relational_expression(), subarray_shift_assignment_p(), top_down_abc_dimension(), transformer_add_integer_relation_information(), trivial_expression_p(), try_reorder_expression_call(), and uniform_dependence_p().
Value vect_sum(Pvecteur v): somme des coefficients d'un vecteur (i.e.
produit scalaire avec le vecteur 1)
sum v[i] i
Definition at line 261 of file reductions.c.
References Svecteur::succ, sum(), val_of, value_addto, and VALUE_ZERO.
Referenced by do_computation_intensity(), polynome_max_degree(), and polynomial_to_numerical().
Pvecteur vect_variable_rename(Pvecteur v, Variable v_old, Variable v_new): rename the potential coordinate v_old in v as v_new.
v_old | _old |
v_new | _new |
Definition at line 366 of file base.c.
References Svecteur::succ, VECTEUR_NUL_P, and vecteur_var.
Referenced by affine_to_transformer(), contrainte_variable_rename(), sc_variable_rename(), upwards_vect_rename(), and variables_to_new_values().
Debug support: pointer to the function used by debug print outs.
It can be set to point to other packages' own definition of Value. For instance, entity_local_name() for Linear/C3 Library.
For unit tests within linear, it should be set to point to variable_default_name()
Definition at line 114 of file variable.c.
Referenced by compute_x_and_y_bounds(), dbg_ray_dte_rm(), dbg_sommet_rm(), egalite_dump(), egalites_dump(), inegalite_dump(), inegalites_dump(), init_variable_debug_name(), new_constraint_for_coefficient_reduction_with_bounding_box(), ray_dte_dump(), reduce_coefficients_with_bounding_box(), reset_variable_debug_name(), sc_bounded_normalization(), sc_dump(), small_positive_slope_reduce_coefficients_with_bounding_box(), sommet_dump(), tpips_main(), vect_dump(), and vect_fdump().