30 #include "pips_config.h"
42 #include "resources.h"
110 list registered_entities =
NIL;
112 for( ; !
ENDP(stmts) ;
POP(stmts) ) {
121 registered_entities =
CONS(
entity,
e,registered_entities);
136 registered_entities =
CONS(
entity,
e,registered_entities);
183 debug_on(
"GENERATE_STARPU_PRAGMA_DEBUG_LEVEL");
dimension make_dimension(expression a1, expression a2, list a3)
callees compute_callees(const statement stat)
Recompute the callees of a module statement.
struct _newgen_struct_statement_ * statement
void reset_proper_rw_effects(void)
void set_proper_rw_effects(statement_effects)
void set_cumulated_rw_effects(statement_effects)
list load_cumulated_rw_effects_list(statement)
void reset_cumulated_rw_effects(void)
const char * module_name(const char *s)
Return the module part of an entity name.
#define gen_context_recurse(start, ctxt, domain_number, flt, rwt)
#define gen_recurse(start, domain_number, flt, rwt)
static char start[1024]
The name of the variable from which to start counting domain numbers.
void reset_current_module_entity(void)
Reset the current module entity.
void reset_current_module_statement(void)
Reset the current module statement.
statement set_current_module_statement(statement)
Set the current module statement.
statement get_current_module_statement(void)
Get the current module statement.
entity set_current_module_entity(entity)
static.c
entity get_current_module_entity(void)
Get the entity of the current module.
void gen_null2(__attribute__((unused)) void *u1, __attribute__((unused)) void *u2)
idem with 2 args, to please overpeaky compiler checks
bool gen_true2(__attribute__((unused)) gen_chunk *u1, __attribute__((unused)) void *u2)
void gen_null(__attribute__((unused)) void *unused)
Ignore the argument.
bool gen_true(__attribute__((unused)) gen_chunk *unused)
Return true and ignore the argument.
#define ENDP(l)
Test if a list is empty.
#define POP(l)
Modify a list pointer to point on the next element of the list.
#define NIL
The empty list (nil in Lisp)
#define CONS(_t_, _i_, _l_)
List element cell constructor (insert an element at the beginning of a list)
#define CAR(pcons)
Get the value of the first element of a list.
#define FOREACH(_fe_CASTER, _fe_item, _fe_list)
Apply/map an instruction block on all the elements of a list.
#define CDR(pcons)
Get the list less its first element.
string db_get_memory_resource(const char *rname, const char *oname, bool pure)
Return the pointer to the resource, whatever it is.
#define DB_PUT_MEMORY_RESOURCE(res_name, own_name, res_val)
conform to old interface.
bool return_statement_p(statement)
Test if a statement is a C or Fortran "return".
void insert_statement(statement, statement, bool)
This is the normal entry point.
statement make_plain_continue_statement(void)
Make a simple continue statement to be used as a NOP or ";" in C.
bool declaration_statement_p(statement)
Had to be optimized according to Beatrice Creusillet.
#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
list gen_filter_tabulated(bool(*)(gen_chunk *), int)
returns the list of entities with this caracteristics.
bool module_reorder(statement body)
Reorder a module and recompute order to statement if any.
#define ENTITY_ADDRESS_OF_P(e)
const char * entity_user_name(entity e)
Since entity_local_name may contain PIPS special characters such as prefixes (label,...
bool entity_array_p(entity e)
Is e a variable with an array type?
entity local_name_to_top_level_entity(const char *n)
This function try to find a top-level entity from a local name.
bool entity_main_module_p(entity e)
bool top_level_entity_p(entity e)
Check if the scope of entity e is global.
expression entity_to_expression(entity e)
if v is a constant, returns a constant call.
bool unbounded_dimension_p(dimension dim)
bool unbounded_dimension_p(dim) input : a dimension of an array entity.
entity expression_to_entity(expression e)
just returns the entity of an expression, or entity_undefined
void add_pragma_str_to_statement(statement st, const char *s, bool copy_flag)
Add a string as a pragma to a statement.
entity make_integer_constant_entity(_int)
entity make_integer_constant_entity(int c) make entity for integer constant c
struct _newgen_struct_pragma_ * pragma
#define reference_variable(x)
#define statement_domain
newgen_sizeofexpression_domain_defined
#define call_domain
newgen_callees_domain_defined
#define EXPRESSION(x)
EXPRESSION.
#define reference_domain
newgen_range_domain_defined
#define sequence_statements(x)
#define reference_indices(x)
#define variable_dimensions(x)
#define statement_declarations(x)
#define call_arguments(x)
#define sequence_domain
newgen_reference_domain_defined
#define type_variable_p(x)
#define entity_domain
newgen_syntax_domain_defined
#define STATEMENT(x)
STATEMENT.
bool add_shutdown_pragma_to_return(statement s)
bool generate_starpu_pragma(char *module_name)
static void scalar_to_array(reference r, entity e)
bool address_of_entity_p(call c, struct context_address_of_entity *context)
bool array_bounded_p(entity e)
static bool address_of_variable_is_taken(void *start, entity e)
static statement get_statement_pragma_init()
static statement get_statement_pragma_register(entity e, bool address_of)
static bool add_pragma_to_sequence(sequence seq)
static statement get_statement_pragma_shutdown()
The structure used to build lists in NewGen.