2 #include "pips_config.h"
71 static const char any_name[] =
105 anywhere_p = anywhere_p
162 bool typed_anywhere_p =
false;
169 return typed_anywhere_p;
325 bool found_p =
false;
356 pips_debug(8,
"New abstract location entity \"%s\" found or created"
410 bool found_p =
false;
442 pips_debug(8,
"New abstract location entity \"%s\" found or created"
462 dynamic_p = dynamic_p
601 bool stub_sink_p =
false;
602 bool dummy_target_p =
false;
612 if(dummy_target_p && first ==
'_') {
614 while(
'0' <=en[l-i] && en[l-i]<=
'9') {
617 if(i>=2 && en[l-i]==
'_')
646 bool abstract_locations_p = ( 0 == strncmp(en,
ANY_MODULE_NAME,module_sep++ - en)
793 " for abstract locations.\n");
797 if(strcmp(ln1, ln2)==0)
802 if(strcmp(mn1, mn2)==0)
841 if(al1_abstract_location_p )
842 if(al2_abstract_location_p ) {
852 if(al2_abstract_location_p) {
913 "the set of all application locations" :
"bug!!!");
919 "the bottom of the abstract location lattice" :
"bug!!!");
925 "the null pointer" :
"bug!!!");
931 "the set of all locations of a module" :
"bug!!!");
937 "the set of all heap locations of a module" :
"bug!!!");
943 "the set of all stack locations of a module" :
"bug!!!");
949 "the set of all static locations of a module" :
"bug!!!");
955 "the set of all dynamic locations of a module" :
"bug!!!");
962 "the set of all heap locations of an application" :
"bug!!!");
968 "the set of all stack locations of an application" :
"bug!!!");
974 "the set of all static locations of an applciation" :
"bug!!!");
980 "the set of all dynamic locations of an application" :
"bug!!!");
992 bool conflict_p = (mal==al1) || (mal==al2);
1019 entity anywhere = type_sensitive_p?
float a2sf[2] __attribute__((aligned(16)))
USER generates a user error (i.e., non fatal) by printing the given MSG according to the FMT.
cell make_cell_reference(reference _field_)
functional make_functional(list a1, type a2)
value make_value_unknown(void)
type make_type_variable(variable _field_)
storage make_storage_rom(void)
value make_value_constant(constant _field_)
type copy_type(type p)
TYPE.
basic make_basic_overloaded(void)
type make_type_functional(functional _field_)
type make_type_void(list _field_)
reference make_reference(entity a1, list a2)
constant make_constant_int(intptr_t _field_)
type make_type_area(area _field_)
variable make_variable(basic a1, list a2, list a3)
area make_area(intptr_t a1, list a2)
bool entity_all_module_static_locations_p(entity e)
test if an entity is the a static area
bool entity_all_xxx_locations_p(entity e, string xxx)
test if an entity is the set of all memory locations in the xxx area of any module.
bool entity_null_locations_p(entity e)
test if an entity is the NULL POINTER
entity entity_null_locations()
return TOP-LEVEL:NULL_POINTER The NULL pointer should be a global variable, unique for all modules FI...
void check_abstract_locations()
For debugging the API.
bool entity_abstract_location_p(entity al)
entity entity_all_module_dynamic_locations(entity m)
return m:*DYNAMIC**ANYWHERE
entity entity_typed_anywhere_locations(type t)
entity entity_all_module_xxx_locations_typed(const char *mn, const char *xxx, type t)
entity entity_all_module_heap_locations(entity m)
return m:*HEAP**ANYWHERE
entity abstract_locations_max(entity al1, entity al2)
eturns the smallest abstract location set greater than or equalt to al1 and al2.
entity entity_all_module_heap_locations_typed(entity m, type t)
bool abstract_locations_must_conflict_p(entity al1 __attribute__((__unused__)), entity al2 __attribute__((__unused__)))
Do these two abstract locations MUST share some real memory locations ? Never ! DO NOT USE THIS FUNCT...
entity variable_to_abstract_location(entity v)
returns the smallest abstract locations containing the location of variable v.
bool entity_all_dynamic_locations_p(entity e)
test if an entity is the set of all dynamic locations
bool stub_entity_of_module_p(entity s, entity m)
entity entity_all_module_locations(entity m)
return m:ANYWHERE Set of all memory locations related to one module.
entity entity_locations_dereference(entity al __attribute__((__unused__)))
in case we need to evaluate sigma(al), i.e.
bool entity_stub_sink_p(entity e)
test if an entity is a stub sink for a formal parameter e.g.
bool cell_typed_anywhere_locations_p(cell c)
test if a cell is the bottom of the lattice
entity entity_all_stack_locations()
return ANY_MODULE:STACK
bool entity_all_locations_p(entity e)
test if an entity is the top of the lattice
entity entity_all_module_static_locations(entity m)
return m:*DYNAMIC**ANYWHERE
bool entity_all_static_locations_p(entity e)
test if an entity is the set of all static locations
bool entity_typed_anywhere_locations_p(entity e)
Test if an entity is the bottom of the lattice.
entity entity_all_module_stack_locations(entity m)
return m:*STACK**ANYWHERE
reference make_anywhere_reference(type t)
This function should be located somewhere in effect-util in or near abstract locations.
bool reference_typed_anywhere_locations_p(reference r)
test if a reference is the bottom of the lattice
entity entity_locations_max(entity al1, entity al2)
Here, entity al1 and entity al2 can be program variables.
entity entity_anywhere_locations()
entity entity_all_dynamic_locations()
return ANY_MODULE:DYNAMIC
entity entity_all_module_xxx_locations(entity m, const char *xxx)
return m:xxx*ANYWHERE* Generic set of functions for all kinds of areas
bool entity_nowhere_locations_p(entity e)
test if an entity is the bottom of the lattice
entity entity_all_xxx_locations(string xxx)
return ANY_MODULE:xxx
bool entity_all_module_locations_p(entity e)
test if an entity is the set of locations defined in a module
entity entity_all_xxx_locations_typed(string xxx, type t)
FI->AM: the predicate entity_all_xxx_locations_typed_p() is missing...
bool entity_anywhere_locations_p(entity e)
test if an entity is the bottom of the lattice
entity entity_all_locations()
eturn ANY_MODULE:ANYWHERE (the top of the lattice)
bool entity_all_module_heap_locations_p(entity e)
test if an entity is the a heap area
entity entity_all_heap_locations()
return ANY_MODULE:HEAP
cell make_anywhere_cell(type t)
entity entity_all_heap_locations_typed(type t)
bool entity_all_module_dynamic_locations_p(entity e)
test if an entity is the a dynamic area
bool abstract_locations_may_conflict_p(entity al1, entity al2)
Do these two abstract locations MAY share some real memory locations ?
entity entity_nowhere_locations()
return ANY_MODULE:NOWHERE
bool entity_all_module_stack_locations_p(entity e)
test if an entity is the a stack area
bool entity_all_stack_locations_p(entity e)
test if an entity is the set of all stack locations
bool entity_all_module_xxx_locations_p(entity e, string xxx)
test if an entity is the set of all memory locations in the xxx area of a module.
bool entity_all_heap_locations_p(entity e)
test if an entity is the set of all heap locations
bool entity_typed_nowhere_locations_p(entity e)
test if an entity is the bottom of the lattice
entity entity_all_static_locations()
return ANY_MODULE:STATIC
entity entity_typed_nowhere_locations(type t)
entity generic_entity_typed_anywhere_locations(type t)
#define NULL_POINTER_NAME
#define ANYWHERE_LOCATION
reference cell_any_reference(cell)
API for reference.
const char * local_name(const char *s)
Does not take care of block scopes and returns a pointer.
bool get_bool_property(const string)
FC 2015-07-20: yuk, moved out to prevent an include cycle dependency include "properties....
entity get_current_module_entity(void)
Get the entity of the current module.
#define NIL
The empty list (nil in Lisp)
#define pips_debug
these macros use the GNU extensions that allow variadic macros, including with an empty list.
#define pips_user_warning
#define pips_assert(what, predicate)
common macros, two flavors depending on NDEBUG
#define pips_internal_error
#define FORMAL_AREA_LOCAL_NAME
#define DYNAMIC_AREA_LOCAL_NAME
#define TOP_LEVEL_MODULE_NAME
Module containing the global variables in Fortran and C.
#define STACK_AREA_LOCAL_NAME
#define STATIC_AREA_LOCAL_NAME
#define MODULE_SEP_STRING
#define HEAP_AREA_LOCAL_NAME
string concatenate(const char *,...)
Return the concatenation of the given strings.
#define same_string_p(s1, s2)
void * gen_find_tabulated(const char *, int)
int f(int off1, int off2, int n, float r[n], float a[n], float b[n])
int f2(int off1, int off2, int w, int n, float r[n], float a[n], float b[n])
void print_type(type)
For debugging.
#define make_entity(n, t, s, i)
#define entity_variable_p(e)
An entity_variable_p(e) may hide a typedef and hence a functional type.
bool dynamic_area_p(entity aire)
bool stack_area_p(entity aire)
bool heap_area_p(entity aire)
bool formal_area_p(entity aire)
bool static_area_p(entity aire)
entity FindEntity(const char *package, const char *name)
Retrieve an entity from its package/module name and its local name.
const char * entity_local_name(entity e)
entity_local_name modified so that it does not core when used in vect_fprint, since someone thought t...
entity FindOrCreateEntity(const char *package, const char *local_name)
Problem: A functional global entity may be referenced without parenthesis or CALL keyword in a functi...
bool dummy_parameter_entity_p(entity p)
is p a dummy parameter?
bool same_entity_p(entity e1, entity e2)
predicates on entities
void register_static_entity(entity *e)
add given entity to the set of entities that must reset upon workspace deletion practically,...
entity CreateEntity(const char *package_name, const char *local_name)
BEGIN_EOLE.
const char * entity_module_name(entity e)
See comments about module_name().
bool variable_return_p(entity)
True if a variable is the pseudo-variable used to store value returned by a function:
type type_to_pointer_type(type)
allocate a new type "pt" which includes directly "t".
bool type_equal_p(type, type)
type entity_basic_concrete_type(entity)
retrieves or computes and then returns the basic concrete type of an entity
bool formal_parameter_p(entity)
string type_to_string(const type)
type.c
#define type_functional_p(x)
#define reference_variable(x)
#define entity_storage(x)
#define storage_formal(x)
#define type_undefined_p(x)
#define entity_undefined_p(x)
#define formal_function(x)
#define storage_undefined_p(x)
#define entity_domain
newgen_syntax_domain_defined
#define entity_initial(x)
int fprintf()
test sc_min : ce test s'appelle par : programme fichier1.data fichier2.data ...