25 #include "pips_config.h"
125 statement statcomputation, statcomputecomputer, statifcomputer;
130 lupdatenotcomp =
NIL,
131 lreadreftodistarray =
NIL,
156 lreadreftodistarray =
166 pips_debug(8,
"considering reference to %s\n",
172 lstatnotcomp =
gen_nconc(lstatnotcomp, lnotcomp);
174 lreadreftodistarray);
199 lstatcomp =
gen_nconc(lstatcomp, lupdatecomp);
200 lstatnotcomp =
gen_nconc(lstatnotcomp, lupdatenotcomp);
225 list *lscompp, *lsnotcompp;
231 statement statif, statco, statco2, statsndtoon, statrcvfromcomp;
277 list *lcompp, *lnotcompp;
279 statement statcompco, statcompgv, statnotcompco, statnotcompmaysend;
320 statement stathco, stathrcv, statnco, statngv;
398 (*lsp) =
NIL, (*lindsp) =
NIL;
400 pips_debug(9,
"number of dimensions of %s to compute: %d\n",
513 list *lstatp, lw, lr;
517 lnotcomp =
NIL, lnotcompr =
NIL, lnotcompw =
NIL;
536 lnotcompr =
gen_nconc(lnotcompr, lnotco);
584 lnotcompw =
gen_nconc(lnotcompw, lnotco);
598 pips_debug(6,
"%zd statements for not computer write:\n",
611 lnotcomp =
gen_nconc(lnotcompr, lnotcompw);
636 list *lscompp, *lsnotcompp;
642 statif, statcompif, statco, statcompco, statcompassign,
643 statsndtoO, statsndtoOO, statrcvfromcomp;
644 list lstat, lstatcomp, linds, lindscomp;
693 list *lhstatp, *lnstatp;
697 statement statnco, stathco, stnrcv, stnif, sthsnd;
call make_call(entity a1, list a2)
expression make_expression(syntax a1, normalized a2)
reference make_reference(entity a1, list a2)
instruction make_instruction(enum instruction_utype tag, void *val)
syntax make_syntax(enum syntax_utype tag, void *val)
static reference ref
Current stmt (an integer)
entity host_module
HPFC - Fabien Coelho, May 1993 and later...
void generate_c1_beta(statement stat, list *lhp, list *lnp)
??? this should work (but that is not the case yet), with every call with no write to distributed arr...
void generate_update_values_on_computer_and_nodes(reference ref, reference val, list *lscompp, list *lsnotcompp)
generate_update_values_on_computer_and_nodes
void generate_compute_local_indices(reference ref, list *lsp, list *lindsp)
generate_compute_local_indices
void generate_get_value_locally(reference ref, reference goal, list *lstatp)
generate_get_value_locally
void generate_update_private_value_from_host(syntax s, list *lhstatp, list *lnstatp)
generate_update_private_value_from_host
void generate_read_of_ref_for_computer(syntax s, list *lcompp, list *lnotcompp)
generate_read_of_ref_for_computer
statement st_compute_ith_local_index(entity array, int i, expression expr, syntax *sp)
the returned expression is translated into variables of the node module.
statement st_send_to_host_and_nodes(reference ref, reference val)
statement st_get_value_for_all(reference ref, reference goal)
void generate_update_values_on_nodes(reference ref, reference newref, list *lscompp, list *lsnotcompp)
generate_update_values_on_nodes
statement st_send_to_computer_if_necessary(reference ref)
void generate_read_of_ref_for_all(syntax s, list *lhp, list *lnp)
generate_read_of_ref_for_all
statement st_get_value_locally_and_send(reference ref, reference goal)
void generate_send_to_computer(reference ref, list *lstatp)
generate_send_to_computer
void generate_receive_from_computer(reference ref, list *lstatp)
void generate_c1_alpha(statement stat, list *lhp, list *lnp)
generate_c1_alpha
void generate_update_distributed_value_from_host(syntax s, list *lhstatp, list *lnstatp)
generate_update_distributed_value_from_host
statement st_receive_from(reference ref, reference goal)
if ref is replicated: goal = Receive_From_Sender()
statement st_get_value_for_computer(reference ref, reference goal)
void generate_parallel_body(statement body, list *lstatp, list lw, list lr)
statement make_block_statement(list)
Make a block statement from a list of statement.
statement instruction_to_statement(instruction)
Build a statement from a give instruction.
entity get_current_module_entity(void)
Get the entity of the current module.
instruction make_assign_instruction(expression l, expression r)
#define NIL
The empty list (nil in Lisp)
size_t gen_length(const list l)
#define CONS(_t_, _i_, _l_)
List element cell constructor (insert an element at the beginning of a list)
list gen_nconc(list cp1, list cp2)
physically concatenates CP1 and CP2 but do not duplicates the elements
#define CAR(pcons)
Get the value of the first element of a list.
void gen_free_list(list l)
free the spine of the list
#define CDR(pcons)
Get the list less its first element.
#define MAP(_map_CASTER, _map_item, _map_code, _map_list)
Apply/map an instruction block on all the elements of a list (old fashioned)
bool statement_call_p(statement)
statement make_assign_statement(expression, expression)
statement make_continue_statement(entity)
statement st_make_nice_test(expression, list, list)
list lUpdateExpr(entity module, list l)
expression UpdateExpressionForModule(entity module, expression ex)
this function creates a new expression using the mapping of old to new variables map.
statement UpdateStatementForModule(entity module, statement stat)
void AddEntityToHostAndNodeModules(entity e)
AddEntityToHostAndNodeModules.
list FindRefToDistArrayFromList(list lexpr)
FindRefToDistArrayFromList.
bool replicated_p(entity e)
replicated_p
list FindRefToDistArray(void *obj)
#define st_send_to_host_and_not_owners(val)
#define st_receive_mcast_from_host(goal)
#define st_send_to_host_and_all_nodes(val)
#define st_send_to_computer(val)
SND.
#define condition_computerp()
#define condition_ownerp()
#define st_receive_from_computer(goal)
#define condition_not_computer_in_owners()
#define condition_senderp()
#define local_index_is_different_p(array, dim)
#define st_send_to_other_owners(val)
#define st_receive_from_host(goal)
#define DEBUG_STAT(D, W, S)
#define st_receive_from_sender(goal)
#define st_send_to_owners(val)
#define st_receive_mcast_from_sender(goal)
#define st_host_send_to_all_nodes(val)
#define st_send_to_owner(val)
expression expr_compute_local_index(entity, int, expression)
new index computation formula, derived from the new declarations made for the given dimension.
entity load_new_node(entity)
statement st_compute_current_computer(reference)
Computes.
statement st_compute_current_owners(reference)
entity load_new_host(entity)
bool array_distributed_p(entity)
#define pips_debug
these macros use the GNU extensions that allow variadic macros, including with an empty list.
#define pips_assert(what, predicate)
common macros, two flavors depending on NDEBUG
#define ENTITY_ASSIGN_P(e)
#define AND_OPERATOR_NAME
FI: intrinsics are defined at a third place after bootstrap and effects! I guess the name should be d...
basic entity_basic(entity e)
return the basic associated to entity e if it's a function/variable/constant basic_undefined otherwis...
entity entity_intrinsic(const char *name)
FI: I do not understand this function name (see next one!).
expression reference_to_expression(reference r)
expression entity_to_expression(entity e)
if v is a constant, returns a constant call.
expression MakeBinaryCall(entity f, expression eg, expression ed)
Creates a call expression to a function with 2 arguments.
basic MakeBasic(int)
END_EOLE.
entity make_new_scalar_variable(entity, basic)
void AddEntityToCurrentModule(entity)
Add a variable entity to the current module declarations.
int NumberOfDimension(entity)
#define normalized_undefined
#define syntax_reference_p(x)
#define syntax_reference(x)
#define reference_variable(x)
#define EXPRESSION(x)
EXPRESSION.
#define reference_indices(x)
#define statement_instruction(x)
#define instruction_call(x)
#define call_arguments(x)
#define expression_syntax(x)
#define STATEMENT(x)
STATEMENT.
The structure used to build lists in NewGen.