Commit Message

Hi,
this patch moves the graphite code to the documented cloog library
interface and removes the use of old/deprecated interfaces. It ensures
that graphite will also compile flawless with future cloog.org versions.
* graphite-clast-to-gimple.c (new_clast_name_index): Store a copy
of the string, no just a reference.
(clast_name_index): Add a new field, that specifies if we need to
free the
name.
(free_clast_name_index): If necessary, free the name string.
(clast_name_index_elt_info): Calculate the hash based on the string
content,
not the memory location it is stored in.
(clast_name_to_level): Specify that we do not need to free the name.
(clast_name_to_index): Dito.
(clast_name_to_lb_ub): Dito.
(eq_clast_name_indexes): Compare the strings, not their base pointers.
(free_scattering): Removed.
(initialize_cloog_names): Renamed to add_names_to_union_domain().
(add_names_to_union_domain): Changed to work on a union_domain,
instead of a
CloogNames structure.
(build_cloog_prog): Removed.
(build_cloog_union_domain): New.
(generate_cloog_input): New.
(scop_to_clast): Use CloogInput instead of CloogProgram.
(print_generated_program): Adapt to new scop_to_clast() and do not
print the CloogProgram any more.
(create_params_index): Removed, functionality integrated in
add_names_to_union_domain().
(gloog): Adapt to new scop_to_clast().
* graphite-clast-to-gimple.h (scop_to_clast): Remove.
This patch depends on my previous patches [1], that remove supports for
cloog-ppl (which does not implement the new interface).
Bootstrapped and 'make check RUNTESTFLAGS=graphite.exp' tested on Linux
amd64. OK to commit, after support for cloog-ppl was removed?
Cheers
Tobi
[1] http://gcc.gnu.org/ml/gcc-patches/2011-07/msg01892.html

Comments

Hi Tobi,
The patch looks good modulo some formatting changes:
+ free(c->free_name);
+ int length = strlen(e->name);
[...]
Please follow the GNU style: there should be a space between the
function name and the open parenthesis.
- dom = new_Cloog_Domain_from_ppl_Pointset_Powerset (PBB_DOMAIN (pbb),
+ domain = new_Cloog_Domain_from_ppl_Pointset_Powerset (PBB_DOMAIN (pbb),
scop_nb_params (scop),
cloog_state);
You would still need proper indentation on the last two lines.
+ /* Dump a .cloog input file, if requested. This feature is only
+ * enabled in the Graphite branch. */
Please remove the * from the beginning of the new line in this comment.
Ok with these changes and after the other patches are committed.
Thanks,
Sebastian