+2009-08-12 Sebastian Pop <sebastian.pop@amd.com>
+
+ * graphite-clast-to-gimple.c (gloog): Add time to TV_GRAPHITE_CODE_GEN.
+ * graphite-dependences.c (graphite_legal_transform): Add time to
+ TV_GRAPHITE_DATA_DEPS.
+ (dependency_between_pbbs_p): Same.
+ * timevar.def (TV_GRAPHITE_DATA_DEPS, TV_GRAPHITE_CODE_GEN): New.
+
2009-08-12 Andrey Belevantsev <abel@ispras.ru>
PR rtl-optimization/41033
+2009-08-05 Sebastian Pop <sebastian.pop@amd.com>
+
+ * graphite-clast-to-gimple.c (gloog): Add time to TV_GRAPHITE_CODE_GEN.
+ * graphite-dependences.c (graphite_legal_transform): Add time to
+ TV_GRAPHITE_DATA_DEPS.
+ (dependency_between_pbbs_p): Same.
+ * timevar.def (TV_GRAPHITE_DATA_DEPS, TV_GRAPHITE_CODE_GEN): New.
+
+2009-08-03 Sebastian Pop <sebastian.pop@amd.com>
+
+ * Merge from mainline (r149952:150372).
+
2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
* ChangeLog.graphite: Fix indenting, white spaces and 80 columns.
Common Report Var(flag_graphite)
Enable in and out of Graphite representation
-; This option is not documented as it does not perform any useful optimization.
fgraphite-identity
Common Report Var(flag_graphite_identity) Optimization
Enable Graphite Identity transformation
-; This option is not documented as it will be removed
floop-parallelize-all
Common Report Var(flag_loop_parallelize_all) Optimization
Mark all loops as parallel
sese region = SCOP_REGION (scop);
ifsese if_region = NULL;
htab_t rename_map, newivs_index;
- cloog_prog_clast pc = scop_to_clast (scop);
+ cloog_prog_clast pc;
+
+ timevar_push (TV_GRAPHITE_CODE_GEN);
+
+ pc = scop_to_clast (scop);
if (dump_file && (dump_flags & TDF_DETAILS))
{
VEC_free (tree, heap, newivs);
cloog_clast_free (pc.stmt);
cloog_program_free (pc.prog);
+ timevar_pop (TV_GRAPHITE_CODE_GEN);
+
return true;
}
int i, j;
poly_bb_p pbb1, pbb2;
+ timevar_push (TV_GRAPHITE_DATA_DEPS);
+
for (i = 0; VEC_iterate (poly_bb_p, SCOP_BBS (scop), i, pbb1); i++)
for (j = 0; VEC_iterate (poly_bb_p, SCOP_BBS (scop), j, pbb2); j++)
if (!graphite_legal_transform_bb (pbb1, pbb2))
- return false;
+ {
+ timevar_pop (TV_GRAPHITE_DATA_DEPS);
+ return false;
+ }
+ timevar_pop (TV_GRAPHITE_DATA_DEPS);
return true;
}
int i, j;
poly_dr_p pdr1, pdr2;
+ timevar_push (TV_GRAPHITE_DATA_DEPS);
+
for (i = 0; VEC_iterate (poly_dr_p, PBB_DRS (pbb1), i, pdr1); i++)
for (j = 0; VEC_iterate (poly_dr_p, PBB_DRS (pbb2), j, pdr2); j++)
if (graphite_carried_dependence_level_k (pdr1, pdr2, level))
- return true;
+ {
+ timevar_pop (TV_GRAPHITE_DATA_DEPS);
+ return true;
+ }
+ timevar_pop (TV_GRAPHITE_DATA_DEPS);
return false;
}
DEFTIMEVAR (TV_TREE_PARALLELIZE_LOOPS, "tree parallelize loops")
DEFTIMEVAR (TV_TREE_VECTORIZATION , "tree vectorization")
DEFTIMEVAR (TV_TREE_SLP_VECTORIZATION, "tree slp vectorization")
-DEFTIMEVAR (TV_GRAPHITE_TRANSFORMS , "GRAPHITE loop transforms")
+DEFTIMEVAR (TV_GRAPHITE_TRANSFORMS , "Graphite loop transforms")
+DEFTIMEVAR (TV_GRAPHITE_DATA_DEPS , "Graphite data dep analysis")
+DEFTIMEVAR (TV_GRAPHITE_CODE_GEN , "Graphite code generation")
DEFTIMEVAR (TV_TREE_LINEAR_TRANSFORM , "tree loop linear")
DEFTIMEVAR (TV_TREE_LOOP_DISTRIBUTION, "tree loop distribution")
DEFTIMEVAR (TV_CHECK_DATA_DEPS , "tree check data dependences")
{
htab_empty (reduction_list);
+ /* If we use autopar in graphite pass, we use it's marked dependency
+ checking results. */
+ if (flag_loop_parallelize_all && !loop->can_be_parallel)
+ continue;
+
/* FIXME: Only consider innermost loops with just one exit. */
if (loop->inner || !single_dom_exit (loop))
continue;
/* FIXME: the check for vector phi nodes could be removed. */
|| loop_has_vector_phi_nodes (loop))
continue;
-
- if (/* Do not bother with loops in cold areas. */
- optimize_loop_nest_for_size_p (loop)
- /* Or loops that roll too little. */
- || expected_loop_iterations (loop) <= n_threads)
+
+ /* FIXME: Bypass this check as graphite doesn't update the
+ count and frequency correctly now. */
+ if (!flag_loop_parallelize_all
+ && (expected_loop_iterations (loop) <= n_threads
+ /* Do not bother with loops in cold areas. */
+ || optimize_loop_nest_for_size_p (loop)))
continue;
+
if (!try_get_loop_niter (loop, &niter_desc))
continue;
if (!try_create_reduction_list (loop, reduction_list))
continue;
- if (!loop_parallel_p (loop))
+ if (!flag_loop_parallelize_all && !loop_parallel_p (loop))
continue;
changed = true;