-/* Translation of ISL AST to Gimple.
+/* Translation of isl AST to Gimple.
Copyright (C) 2014-2015 Free Software Foundation, Inc.
Contributed by Roman Gareev <gareevroman@gmail.com>.
#include "cfganal.h"
#include "value-prof.h"
#include "graphite.h"
-
#include <map>
/* We always try to use signed 128 bit types, but fall back to smaller types
checking_verify_loop_closed_ssa (true);
}
-/* IVS_PARAMS maps ISL's scattering and parameter identifiers
+/* IVS_PARAMS maps isl's scattering and parameter identifiers
to corresponding trees. */
typedef std::map<isl_id *, tree> ivs_params;
-/* Free all memory allocated for ISL's identifiers. */
+/* Free all memory allocated for isl's identifiers. */
void ivs_params_clear (ivs_params &ip)
{
: region (r), codegen_error (false)
{ }
- /* Translates an ISL AST node NODE to GCC representation in the
+ /* Translates an isl AST node NODE to GCC representation in the
context of a SESE. */
edge translate_isl_ast (loop_p context_loop, __isl_keep isl_ast_node *node,
edge next_e, ivs_params &ip);
tree nary_op_to_tree (tree type, __isl_take isl_ast_expr *expr,
ivs_params &ip);
- /* Converts an ISL AST expression E back to a GCC expression tree of
+ /* Converts an isl AST expression E back to a GCC expression tree of
type TYPE. */
tree gcc_expression_from_isl_expression (tree type,
__isl_take isl_ast_expr *,
induction variable for the new LOOP. New LOOP is attached to CFG
starting at ENTRY_EDGE. LOOP is inserted into the loop tree and
becomes the child loop of the OUTER_LOOP. NEWIVS_INDEX binds
- ISL's scattering name to the induction variable created for the
+ isl's scattering name to the induction variable created for the
loop of STMT. The new induction variable is inserted in the NEWIVS
vector and is of type TYPE. */
struct loop *graphite_create_new_loop (edge entry_edge,
tree *type,
tree *lb, tree *ub, ivs_params &ip);
- /* Creates a new if region corresponding to ISL's cond. */
+ /* Creates a new if region corresponding to isl's cond. */
edge graphite_create_new_guard (edge entry_edge,
__isl_take isl_ast_expr *if_cond,
ivs_params &ip);
void translate_pending_phi_nodes (void);
- /* Add ISL's parameter identifiers and corresponding trees to ivs_params. */
+ /* Add isl's parameter identifiers and corresponding trees to ivs_params. */
void add_parameters_to_ivs_params (scop_p scop, ivs_params &ip);
/* The region to be translated. */
sese_info_p region;
- /* This flag is set when an error occurred during the translation of ISL AST
+ /* This flag is set when an error occurred during the translation of isl AST
to Gimple. */
bool codegen_error;
return fold_build2 (MULT_EXPR, type, tree_lhs_expr, tree_rhs_expr);
case isl_ast_op_div:
- /* As ISL operates on arbitrary precision numbers, we may end up with
+ /* As isl operates on arbitrary precision numbers, we may end up with
division by 2^64 that is folded to 0. */
if (integer_zerop (tree_rhs_expr))
{
return fold_build2 (EXACT_DIV_EXPR, type, tree_lhs_expr, tree_rhs_expr);
case isl_ast_op_pdiv_q:
- /* As ISL operates on arbitrary precision numbers, we may end up with
+ /* As isl operates on arbitrary precision numbers, we may end up with
division by 2^64 that is folded to 0. */
if (integer_zerop (tree_rhs_expr))
{
return fold_build2 (TRUNC_DIV_EXPR, type, tree_lhs_expr, tree_rhs_expr);
#if HAVE_ISL_OPTIONS_SET_SCHEDULE_SERIALIZE_SCCS
- /* ISL-0.15 or later. */
+ /* isl 0.15 or later. */
case isl_ast_op_zdiv_r:
#endif
case isl_ast_op_pdiv_r:
- /* As ISL operates on arbitrary precision numbers, we may end up with
+ /* As isl operates on arbitrary precision numbers, we may end up with
division by 2^64 that is folded to 0. */
if (integer_zerop (tree_rhs_expr))
{
return fold_build2 (TRUNC_MOD_EXPR, type, tree_lhs_expr, tree_rhs_expr);
case isl_ast_op_fdiv_q:
- /* As ISL operates on arbitrary precision numbers, we may end up with
+ /* As isl operates on arbitrary precision numbers, we may end up with
division by 2^64 that is folded to 0. */
if (integer_zerop (tree_rhs_expr))
{
case isl_ast_op_pdiv_r:
case isl_ast_op_fdiv_q:
#if HAVE_ISL_OPTIONS_SET_SCHEDULE_SERIALIZE_SCCS
- /* ISL-0.15 or later. */
+ /* isl 0.15 or later. */
case isl_ast_op_zdiv_r:
#endif
case isl_ast_op_and:
return NULL_TREE;
}
-/* Converts an ISL AST expression E back to a GCC expression tree of
+/* Converts an isl AST expression E back to a GCC expression tree of
type TYPE. */
tree
induction variable for the new LOOP. New LOOP is attached to CFG
starting at ENTRY_EDGE. LOOP is inserted into the loop tree and
becomes the child loop of the OUTER_LOOP. NEWIVS_INDEX binds
- ISL's scattering name to the induction variable created for the
+ isl's scattering name to the induction variable created for the
loop of STMT. The new induction variable is inserted in the NEWIVS
vector and is of type TYPE. */
return next_e;
}
-/* Creates a new if region corresponding to ISL's cond. */
+/* Creates a new if region corresponding to isl's cond. */
edge
translate_isl_ast_to_gimple::
return last_e;
}
-/* Translates an ISL AST node NODE to GCC representation in the
+/* Translates an isl AST node NODE to GCC representation in the
context of a SESE. */
edge
return NULL;
}
- /* In case ISL did some loop peeling, like this:
+ /* In case isl did some loop peeling, like this:
S_8(0);
for (int c1 = 1; c1 <= 5; c1 += 1) {
isl_printer_free (prn);
}
-/* Add ISL's parameter identifiers and corresponding trees to ivs_params. */
+/* Add isl's parameter identifiers and corresponding trees to ivs_params. */
void
translate_isl_ast_to_gimple::add_parameters_to_ivs_params (scop_p scop,
the given SCOP. Return true if code generation succeeded.
FIXME: This is not yet a full implementation of the code generator
- with ISL ASTs. Generation of GIMPLE code has to be completed. */
+ with isl ASTs. Generation of GIMPLE code has to be completed. */
bool
graphite_regenerate_ast_isl (scop_p scop)
if (dump_file && (dump_flags & TDF_DETAILS))
{
- fprintf (dump_file, "ISL AST generated by ISL: \n");
+ fprintf (dump_file, "AST generated by isl: \n");
t.print_isl_ast_node (dump_file, root_node, scop->isl_context);
}