PIPS
|
#include "genC.h"
#include "linear.h"
#include "ri.h"
#include "effects.h"
#include "resources.h"
#include "misc.h"
#include "ri-util.h"
#include "prettyprint.h"
#include "effects-util.h"
#include "pipsdbm.h"
#include "effects-generic.h"
#include "sac.h"
#include "ray_dte.h"
#include "sommet.h"
#include "sg.h"
#include "polyedre.h"
#include "ricedg.h"
#include "control.h"
#include "effects-simple.h"
#include "effects-convex.h"
Go to the source code of this file.
Functions | |
static void | daCheckCallReplace (call c, reference ref) |
static void | checkReplaceReference (expression e, reference ref) |
static void | daCallReplaceReference (call c, reference ref, expression next) |
static void | daExpressionReplaceReference (list e, reference ref, expression next) |
static list | addStatementToSequence (statement stat, list seq, list *start) |
static bool | expr_has_write_eff_ref_p (reference ref, expression expr) |
static bool | stat_has_write_eff_ref_p (reference ref, statement stat) |
static bool | add_const_expr_p (statement stat) |
static bool | stats_has_rw_conf_p (statement si, statement sj, reference refi, reference refj) |
static list | da_process_list (list seq, bool repOnlyInIndex, bool(*stat_to_process)(statement)) |
static void | da_simple_statements_pass (statement s) |
static void | da_simple_statements (statement s) |
static bool | da_simple_sequence_filter (statement s) |
bool | deatomizer (char *mod_name) |
deatomizer.c More... | |
Variables | |
static int | gInIndex = 0 |
static bool | gRepOnlyInIndex = 0 |
static bool | gReplaceAllowed = false |
static bool | gRepDone = false |
static graph | dep_graph |
Definition at line 288 of file deatomizer.c.
References call_arguments, call_constant_p, call_function, CAR, CDR, constant_int_p, ENTITY_ASSIGN_P, entity_initial, ENTITY_MINUS_P, ENTITY_PLUS_P, exp, EXPRESSION, expression_constant_p(), expression_syntax, instruction_call, instruction_call_p, is_syntax_call, is_syntax_reference, NIL, pips_assert, statement_instruction, syntax_call, syntax_tag, and value_constant.
Referenced by da_simple_statements_pass().
Definition at line 226 of file deatomizer.c.
References CDR, CONS, NIL, start, and STATEMENT.
Referenced by da_process_list().
|
static |
replace if equal to ref
Definition at line 67 of file deatomizer.c.
References daCheckCallReplace(), EXPRESSION, expression_syntax, FOREACH, gInIndex, gReplaceAllowed, gRepOnlyInIndex, is_syntax_call, is_syntax_range, is_syntax_reference, NIL, pips_internal_error, range_increment, range_lower, range_upper, ref, reference_equal_p(), reference_indices, syntax_call, syntax_range, syntax_reference, and syntax_tag.
Referenced by daCheckCallReplace().
|
static |
Definition at line 381 of file deatomizer.c.
References addStatementToSequence(), call_arguments, call_function, CAR, CDR, daCallReplaceReference(), daCheckCallReplace(), daExpressionReplaceReference(), ENTITY_ASSIGN_P, expr_has_write_eff_ref_p(), EXPRESSION, expression_reference(), expression_syntax, fprintf(), free_statement(), gen_length(), gInIndex, gReplaceAllowed, gRepOnlyInIndex, hash_del(), hash_get(), HASH_MAP, hash_pointer, hash_put(), hash_table_free(), hash_table_make(), HASH_UNDEFINED_VALUE, ifdebug, instruction_call, instruction_call_p, is_syntax_reference, NIL, pips_assert, pips_debug, print_statement(), printf(), reference_equal_p(), reference_indices, reference_variable, same_entity_p(), stat_has_write_eff_ref_p(), STATEMENT, statement_instruction, stats_has_rw_conf_p(), syntax_reference, and syntax_tag.
Referenced by da_simple_statements_pass().
Do not recurse through simple calls, for better performance
Definition at line 698 of file deatomizer.c.
References instruction_call_p, and statement_instruction.
Referenced by deatomizer().
|
static |
Definition at line 676 of file deatomizer.c.
References da_simple_statements_pass(), gRepDone, and pips_user_warning.
Referenced by deatomizer().
|
static |
not much we can do with a single statement, or with "complex" statements (ie, with tests/loops/...)
Definition at line 653 of file deatomizer.c.
References add_const_expr_p(), da_process_list(), gen_free_list(), instruction_sequence, instruction_sequence_p, sequence_statements, and statement_instruction.
Referenced by da_simple_statements().
|
static |
nothing to replace
I'd rather assume, nothing to replace for symbolic constants
We assume that it is legal to replace arguments (because it should have been verified with the effects that the index is not WRITTEN).
Definition at line 189 of file deatomizer.c.
References abort, call_arguments, call_function, daExpressionReplaceReference(), entity_initial, f(), is_value_code, is_value_constant, is_value_intrinsic, is_value_symbolic, is_value_unknown, MAPL, pips_internal_error, ref, and value_tag.
Referenced by da_process_list(), and daExpressionReplaceReference().
nothing to replace
I'd rather assume, nothing to replace for symbolic constants
We assume that it is legal to replace arguments (because it should have been verified with the effects that the index is not WRITTEN).
Definition at line 107 of file deatomizer.c.
References abort, call_arguments, call_function, checkReplaceReference(), entity_initial, EXPRESSION, f(), FOREACH, is_value_code, is_value_constant, is_value_intrinsic, is_value_symbolic, is_value_unknown, pips_internal_error, ref, and value_tag.
Referenced by checkReplaceReference(), and da_process_list().
|
static |
replace if equal to ref
Definition at line 145 of file deatomizer.c.
References CAR, copy_syntax(), daCallReplaceReference(), exp, EXPRESSION, expression_normalized, expression_syntax, free_normalized(), gRepDone, is_syntax_call, is_syntax_range, is_syntax_reference, MAPL, NIL, NORMALIZE_EXPRESSION, normalized_undefined, pips_internal_error, ref, reference_equal_p(), reference_indices, syntax_call, syntax_reference, and syntax_tag.
Referenced by da_process_list(), and daCallReplaceReference().
bool deatomizer | ( | char * | mod_name | ) |
get the resources
Now do the job
Reorder the module, because new statements have been added
update/release resources
mod_name | od_name |
Definition at line 726 of file deatomizer.c.
References da_simple_sequence_filter(), da_simple_statements(), db_get_memory_resource(), DB_PUT_MEMORY_RESOURCE, debug_off, debug_on, dep_graph, gen_recurse, hash_dont_warn_on_redefinition(), hash_warn_on_redefinition(), module_name_to_entity(), module_reorder(), pips_assert, reset_current_module_entity(), reset_current_module_statement(), reset_ordering_to_statement(), reset_proper_rw_effects(), set_current_module_entity(), set_current_module_statement(), set_ordering_to_statement(), set_proper_rw_effects(), statement_consistent_p(), and statement_domain.
|
static |
Definition at line 244 of file deatomizer.c.
References action_write_p, EFFECT, effect_action, effect_entity(), expression_to_proper_effects(), f(), FOREACH, gen_free_list(), ref, reference_variable, and same_entity_p().
Referenced by da_process_list().
Definition at line 270 of file deatomizer.c.
References action_write_p, EFFECT, effect_action, effect_entity(), f(), FOREACH, load_proper_rw_effects_list(), ref, reference_variable, and same_entity_p().
Referenced by da_process_list().
|
static |
Definition at line 344 of file deatomizer.c.
References CONFLICT, conflict_sink, conflict_source, dep_graph, dg_arc_label_conflicts, effect_read_p, effect_write_p, FOREACH, gen_length(), graph_vertices, reference_equal_p(), reference_indices, s1, SUCCESSOR, successor_arc_label, successor_vertex, VERTEX, vertex_successors, and vertex_to_statement().
Referenced by da_process_list().
|
static |
Definition at line 65 of file deatomizer.c.
Referenced by deatomizer(), quick_privatize_graph(), and stats_has_rw_conf_p().
|
static |
Definition at line 59 of file deatomizer.c.
Referenced by checkReplaceReference(), and da_process_list().
Definition at line 63 of file deatomizer.c.
Referenced by da_simple_statements(), and daExpressionReplaceReference().
Definition at line 61 of file deatomizer.c.
Referenced by checkReplaceReference(), and da_process_list().
|
static |
Definition at line 60 of file deatomizer.c.
Referenced by checkReplaceReference(), and da_process_list().