1 2010-01-20 Sebastian Pop <sebastian.pop@amd.com>
3 * testsuite/gcc.dg/graphite/id-17.c: New.
4 * testsuite/gcc.dg/graphite/pr41888.c: New.
5 * testsuite/gcc.dg/graphite/scop-22.c: New.
6 * testsuite/gfortran.dg/graphite/pr40982.f90: New.
8 2010-01-20 Sebastian Pop <sebastian.pop@amd.com>
10 * graphite-dependences.c: Clarify comments.
11 (build_pddr): Add an extra parameter direction.
12 (graphite_legal_transform_dr): Use build_pddr.
13 (dot_original_deps_stmt_1): Update use of build_pddr.
14 (dot_transformed_deps_stmt_1): Same.
15 (dot_original_deps): Same.
16 (dot_transformed_deps): Same.
18 * testsuite/gcc.dg/graphite/interchange-12.c: New.
19 * testsuite/gcc.dg/graphite/block-7.c: New.
21 2010-01-20 Sebastian Pop <sebastian.pop@amd.com>
23 * graphite-dependences.c (pddr_original_scattering): Renamed build_pddr.
24 (pddr_transformed_scattering): Removed.
25 (graphite_legal_transform_dr): Use build_pddr.
26 (dot_original_deps_stmt_1): Same.
27 (dot_transformed_deps_stmt_1): Same.
28 (dot_original_deps): Same.
29 (dot_transformed_deps): Same.
31 2010-01-20 Sebastian Pop <sebastian.pop@amd.com>
33 * graphite-dependences.c (lexicographically_gt_p): Add comments.
34 (build_lexicographically_gt_constraint): Same.
35 (dependence_polyhedron_1): Same.
36 (dependence_polyhedron): Same.
38 2010-01-20 Sebastian Pop <sebastian.pop@amd.com>
40 * graphite-dependences.c (build_pairwise_scheduling_equality): Removed.
41 (build_pairwise_scheduling_inequality): Renamed build_pairwise_scheduling.
42 (lexicographically_gt_p): Change type of direction to int.
43 (build_lexicographically_gt_constraint): Same.
44 (dependence_polyhedron_1): Same.
45 (dependence_polyhedron): Same.
46 (pddr_original_scattering): Use integers for direction.
47 (pddr_transformed_scattering): Same.
48 (graphite_legal_transform_dr): Same.
49 (graphite_carried_dependence_level_k): Same.
51 2010-01-20 Sebastian Pop <sebastian.pop@amd.com>
53 * graphite-dependences.c (build_pairwise_constraint): Renamed
54 ppl_build_relation. Moved...
55 (dr_equality_constraints): Use ppl_build_relation.
56 (build_pairwise_scheduling_equality): Same.
57 (build_pairwise_scheduling_inequality): Same.
58 * graphite-ppl.c (ppl_build_relation): ...here.
59 * graphite-ppl.h (ppl_build_relation): Declared.
61 2010-01-14 Sebastian Pop <sebastian.pop@amd.com>
64 * graphite-clast-to-gimple.c (gloog_error): New static variable.
65 (clast_to_gcc_expression): Do not build MULT_EXPR of POINTER_TYPE_P.
66 Set gloog_error when such an expression failed to be built.
67 (translate_clast): Early return when gloog_error is set.
68 (gloog): Clear gloog_error. When gloog_error is set, call
69 set_ifsese_condition to enable the original code. Return the status
70 of the code generation based on gloog_error.
71 * sese.c (set_ifsese_condition): New.
72 * sese.h (set_ifsese_condition): Declared.
74 * testsuite/g++.dg/graphite/pr42681.C: New.
76 2010-01-14 Sebastian Pop <sebastian.pop@amd.com>
79 * graphite-clast-to-gimple.c (gloog): Call scev_reset_htab and
81 * sese.c (rename_variables_in_operand): New.
82 (rename_variables_in_expr): New.
83 (rename_nb_iterations): New.
84 (sese_adjust_liveout_phis): Update the rename_map.
85 * sese.h (rename_nb_iterations): Declared.
86 * tree-scalar-evolution.c (scev_reset_htab): New.
87 (scev_reset): Call scev_reset_htab.
88 * tree-scalar-evolution.h (scev_reset_htab): Declared.
90 * testsuite/gfortran.dg/graphite/pr42732.f: New.
92 2010-01-08 Sebastian Pop <sebastian.pop@amd.com>
95 * graphite-clast-to-gimple.c: Fix formatting.
96 * sese.c (defined_in_loop_p): Renamed name_defined_in_loop_p.
97 (expr_defined_in_loop_p): New.
98 (add_loop_exit_phis): Also handle full expressions: remove from
99 the rename_map the expressions defined in the loop that we're closing.
101 * testsuite/gfortran.dg/graphite/pr42393-1.f90: New.
102 * testsuite/gfortran.dg/graphite/pr42393.f90: Add new flags
103 -fno-loop-block -fno-loop-interchange -fno-loop-strip-mine to also
104 make this testcase useful in the Graphite branch.
106 2010-01-08 Sebastian Pop <sebastian.pop@amd.com>
108 * graphite-scop-detection.c (exclude_component_ref): Removed.
109 (is_simple_operand): Removed.
110 (stmt_simple_for_scop_p): Remove use of is_simple_operand.
112 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
115 * sese.c (expand_scalar_variables_expr): Follow the SSA links into
116 the array indexing of ADDR_EXPRs.
118 * testsuite/gcc.dg/graphite/pr42221.c: New.
120 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
123 * graphite.c (graphite_finalize): Call scev_reset.
124 (graphite_transform_loops): Do not call scev_reset between the code
127 * testsuite/gcc.dg/graphite/pr42521.c: New.
129 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
131 * graphite-interchange.c (memory_stride_in_loop): Renamed
133 (memory_strides_in_loop): Renamed memory_strides_in_loop_1.
134 (memory_strides_in_loop): Memoize the memory strides per loop.
135 (lst_interchange_profitable_p): Do not initialize to zero the memory
137 * graphite-poly.h (struct lst): Add a field memory_strides.
138 (LST_LOOP_MEMORY_STRIDES): New.
139 (new_lst_loop): Initialize LST_LOOP_MEMORY_STRIDES to -1.
140 (free_lst): Clear LST_LOOP_MEMORY_STRIDES.
142 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
144 * graphite-interchange.c (memory_strides_in_loop_depth): Renamed
145 memory_strides_in_loop. Gather memory strides on a whole loop.
146 (pbb_interchange_profitable_p): Renamed lst_interchange_profitable_p.
147 (lst_interchange_profitable_p): Removed.
148 (lst_try_interchange_loops): Call lst_interchange_profitable_p.
150 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
152 Revert patch 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
153 * graphite-clast-to-gimple.c (try_mark_loop_parallel): New.
154 (translate_clast_for, translate_clast_guard, translate_clast, gloog):
155 Remove context_loop and level.
157 2010-01-07 Richard Guenther <rguenther@suse.de>
159 PR tree-optimization/42641
160 * sese.c (rename_map_elt_info): Use the SSA name version, do
163 2010-01-06 Sebastian Pop <sebastian.pop@amd.com>
165 * graphite-blocking.c (scop_do_block): Print "SCoP will be loop
166 blocked" only when both the strip mine and the interchange have
169 * testsuite/gcc.dg/graphite/block-2.c: Removed.
170 * testsuite/gcc.dg/graphite/block-3.c: Add scan pattern.
171 * testsuite/gcc.dg/graphite/block-4.c: Same.
172 * testsuite/gcc.dg/graphite/block-5.c: Same.
173 * testsuite/gcc.dg/graphite/block-6.c: Same.
175 2010-01-06 Sebastian Pop <sebastian.pop@amd.com>
177 * graphite-clast-to-gimple.c (save_clast_name_index): Free slot
178 before allocating a new one.
179 (copy_renames): Check that slot is not NULL.
180 (mark_bb_with_pbb): Same.
181 (compute_cloog_iv_types_1): Same.
182 * graphite-interchange.c (lst_perfect_nestify): Free the before,
183 nest, and after LSTs.
184 (lst_try_interchange_loops): Same.
186 2010-01-05 Sebastian Pop <sebastian.pop@amd.com>
189 * graphite-interchange.c (lst_try_interchange_loops): Do not return
190 the before, nest, and after LSTs.
191 (lst_try_interchange): Removed.
192 (lst_interchange_select_inner): Do not iterate over the LSTs if they
194 (lst_interchange_select_outer): Apply interchange on the outer loop
195 until there are no more changes in the inner loops.
197 2009-12-18 Sebastian Pop <sebastian.pop@amd.com>
199 Revert patch fixing PR middle-end/42221.
201 2009-12-18 Sebastian Pop <sebastian.pop@amd.com>
204 * graphite-sese-to-poly.c (follow_ssa_with_commutative_ops): Handle
207 * testsuite/gfortran.dg/graphite/pr42180.f90: Add compile flags.
209 2009-12-18 Sebastian Pop <sebastian.pop@amd.com>
212 * graphite-sese-to-poly.c (split_reduction_stmt): Do not split blocks
213 that contain only one statement.
215 * testsuite/gfortran.dg/graphite/pr42180.f90: New.
217 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
220 * testsuite/gfortran.dg/graphite/pr42393.f90: New.
222 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
225 * testsuite/gfortran.dg/graphite/pr42186.f90: New.
227 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
230 * graphite-sese-to-poly.c (translate_scalar_reduction_to_array_for_stmt):
231 Insert the reduction copy in the same block as the phi node.
232 (follow_ssa_with_commutative_ops): Handle GIMPLE_NOPs.
234 * testsuite/gcc.dg/graphite/pr42205-1.c: New.
235 * testsuite/gcc.dg/graphite/pr42205-2.c: New.
237 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
240 * sese.c (expand_scalar_variables_expr): Follow the SSA links into
241 the array indexing of ADDR_EXPRs.
243 * testsuite/gcc.dg/graphite/pr42221.c: New.
245 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
249 * graphite-interchange.c (lst_try_interchange): Do not modify OUTER
250 index. Call lst_interchange_select_inner only once.
251 (lst_interchange_select_inner): Update use of lst_try_interchange.
252 (lst_interchange_select_outer): Update.
254 2009-12-15 Sebastian Pop <sebastian.pop@amd.com>
258 * graphite-interchange.c (lst_try_interchange): Do not increment the
259 the OUTER index when there is no AFTER kernel. Do not increment the
260 OUTER index for after processing the AFTER kernel.
261 (lst_interchange_select_inner): Call lst_try_interchange only on loops.
262 (lst_interchange_select_outer): Do not pass in a pointer to the OUTER
263 index. Do not pass to lst_interchange_select_inner the OUTER index.
264 (scop_do_interchange): Update use of lst_interchange_select_outer.
266 * testsuite/gfortran.dg/graphite/graphite.exp
267 (DEFAULT_FLAGS_GRAPHITE_IDENTITY): Remove -fdump-tree-graphite-all.
268 * testsuite/gfortran.dg/graphite/interchange-1.f: Add comment. Clean
269 the graphite dump file.
270 * testsuite/gfortran.dg/graphite/interchange-2.f: Same.
271 * testsuite/gfortran.dg/graphite/pr42334-1.f: New.
273 2009-12-15 Sebastian Pop <sebastian.pop@amd.com>
277 * graphite-interchange.c (lst_perfect_nestify): Reset to NULL the LSTs
279 (lst_do_interchange_1): Renamed lst_interchange_select_inner.
280 (lst_try_interchange): Reimplemented.
281 (lst_interchange_select_inner): Same.
282 (lst_do_interchange): Renamed lst_interchange_select_outer.
284 (scop_do_interchange): Update use of lst_interchange_select_outer.
286 * testsuite/g++.dg/graphite/pr42130.C: Add -fgraphite-identity.
287 * testsuite/gcc.dg/graphite/block-0.c: Un-XFAILed.
288 * testsuite/gcc.dg/graphite/pr42211.c: New.
289 * testsuite/gfortran.dg/graphite/pr42334.f90: New.
291 2009-12-14 Sebastian Pop <sebastian.pop@amd.com>
294 * graphite-scop-detection.c (graphite_can_represent_scev): Handle more
295 carefully PLUS_EXPR, MINUS_EXPR, and MULT_EXPR.
297 * testsuite/gfortran.dg/graphite/pr42181.f90: New.
299 2009-12-12 Sebastian Pop <sebpop@gmail.com>
302 * graphite-sese-to-poly.c (rewrite_close_phi_out_of_ssa): Call
303 insert_out_of_ssa_copy_on_edge for anything else than SSA_NAMEs.
304 (detect_commutative_reduction_arg): Simplified.
305 (detect_commutative_reduction): Early return when the argument of
306 the close phi is not of an SSA_NAME.
308 * testsuite/gcc.dg/graphite/pr42284.c: New.
310 2009-12-11 Alexander Monakov <amonakov@ispras.ru>
312 * dbgcnt.def (graphite_scop): New counter.
313 * graphite.c: Include dbgcnt.h
314 (graphite_transform_loops): Use new counter to limit transformations.
316 2009-12-08 Sebastian Pop <sebpop@gmail.com>
319 * graphite-scop-detection.c (graphite_can_represent_init): Also
320 handle more complex MULT_EXPRs containing parameters by recursion
323 * testsuite/gfortran.dg/graphite/pr42285.f90: New.
325 2009-12-01 Tobias Grosser <grosser@fim.uni-passau.de>
327 * testsuite/g++.dg/graphite/pr42130.C: Fix type.
329 2009-11-29 Alexander Monakov <amonakov@gcc.gnu.org>
331 * testsuite/g++.dg/graphite/pr42130.C: Correct testcase.
333 2009-11-24 Tobias Grosser <grosser@fim.uni-passau.de>
335 * graphite-clast-to-gimple.c (try_mark_loop_parallel,
336 graphite_create_new_loop_guard, translate_clast_for): Fix comments.
338 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
341 * graphite-clast-to-gimple.c (graphite_create_new_loop_guard,
342 translate_clast_for_loop): New.
343 (translate_clast_for): Add a condition around the loop, to do not
344 execute loops with zero iterations.
345 * testsuite/g++.dg/graphite/pr42130.C: New.
346 * testsuite/gcc.dg/graphite/pr35356-2.c: Adapt.
348 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
350 * graphite-clast-to-gimple.c (try_mark_loop_parallel): New.
351 (translate_clast_for, translate_clast_guard, translate_clast, gloog):
352 Remove context_loop and level.
354 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
356 * graphite-clast-to-gimple.c (translate_clast_user,
357 translate_clast_for, translate_clast_guard): Simplify and move common
358 elements to translate_clast().
359 (translate_clast): Simplify and get common elements.
361 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
363 * graphite-clast-to-gimple.c (translate_clast_user,
364 translate_clast_for, translate_clast_guard): Split out of
367 2009-11-21 Tobias Grosser <grosser@fim.uni-passau.de>
369 * graphite-clast-to-gimple.c (clast_name_index, new_clast_name_index,
370 clast_name_to_index, save_clast_name_index, debug_clast_name_index,
371 debug_clast_name_indexes_1, debug_clast_name_indexes,
372 clast_name_index_elt_info, eq_clast_name_indexes): Moved from sese.h.
373 (clast_name_to_gcc, clast_to_gcc_expression,
374 clast_to_gcc_expression_red, gcc_type_for_clast_expr,
375 gcc_type_for_clast_eq, graphite_translate_clast_equation,
376 graphite_create_guard_cond_expr, graphite_create_new_loop,
377 translate_clast): Add params_index.
378 (initialize_cloog_names): Create parameter strings from scratch, do
379 not reference other strings.
380 (create_params_index): New.
381 (gloog): Initialize params_index.
382 * graphite-scop-detection (free_scops_1): Removed.
383 (limit_scops): Use normal free_scops.
384 * graphite-sese-to-poly.c (save_var_names): Removed.
385 (parameter_index_in_region): Do not initialize SESE_PARAM_NAMES
386 and SESE_PARAMS_INDEX.
387 * sese.c (new_sese, free_sese): Dito.
388 * sese.h (struct sese): Remove params_index, params_names.
389 (SESE_PARAMS_INDEX, SESE_PARAMS_NAMES): Removed.
391 2009-11-20 Sebastian Pop <sebastian.pop@amd.com>
393 Revert the following patch from 2009-09-14:
394 * graphite-blocking.c: Fix order of includes: tree-chrec.h, then
395 tree-scalar-evolution.h, and then tree-data-ref.h.
396 * graphite-clast-to-gimple.c: Same.
397 * graphite-dependences.c: Same.
398 * graphite-interchange.c: Same.
399 * graphite-poly.c: Same.
400 * graphite-scop-detection.c: Same.
401 * graphite-sese-to-poly.c: Same.
403 * lambda-code.c: Same.
404 * matrix-reorg.c: Same.
405 * tree-data-ref.c: Same.
406 * tree-if-conv.c: Same.
407 * tree-loop-distribu: Same.: Same.
408 * tree-loop-linear.c: Same.
409 * tree-parloops.c: Same.
410 * tree-predcom.c: Same.
411 * tree-vect-patterns.c: Same.
413 2009-11-20 Sebastian Pop <sebastian.pop@amd.com>
415 Revert patch from 2009-09-14.
416 * tree-ssa-loop.c (gate_graphite_transforms): Re-enable Graphite
417 passes at -O1 and below.
419 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
422 * testsuite/gcc.dg/graphite/pr40281.c: New.
424 * tree-scalar-evolution.c (instantiate_scev_poly): Base and stride
425 evolutions should not variate in inner loops.
427 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
430 * testsuite/gfortran.dg/graphite/pr42050.f90: New.
432 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
434 * graphite-interchange.c (memory_strides_in_loop_depth): New.
435 (pbb_interchange_profitable_p): Call memory_strides_in_loop_depth.
437 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
439 * graphite-blocking.c (scop_do_block): New.
440 * graphite-poly.c (apply_poly_transforms): Call scop_do_block.
441 * graphite-poly.h (scop_do_block): Declared.
443 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
445 * graphite-blocking.c (pbb_strip_mine_profitable_p): The parameter
446 depth is the loop nesting depth in the LST. Call psct_dynamic_dim
447 to transform depth into the time_depth before calling
448 pbb_number_of_iterations_at_time.
449 (lst_do_strip_mine): Use a scalar variable instead of recomputing
452 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
454 Reverted the patch for "scattering permutations" from 2009-10-28.
456 * graphite-poly.c (print_permutation): New.
457 (debug_permutation): New.
458 (new_poly_bb): Initialize PBB_PERMUTATION.
459 (free_poly_bb): Free PBB_PERMUTATION.
460 * graphite-poly.h (pbb_permutation_elt_p): Declared.
461 (struct pbb_permutation_elt): New.
462 (PBB_PERMUTATION_ELT_STRIDE): New.
463 (PBB_PERMUTATION_ELT_STRIDED_P): New.
464 (PBB_PERMUTATION_ELT_TIME_DIMENSION): New.
465 (new_pbb_permutation_elt): New.
466 (pbb_permutation_elt_free): New.
467 (struct poly_bb): Add field permutation.
468 (PBB_PERMUTATION): New.
469 (print_permutation): Declared.
470 (debug_permutation): Declared.
472 2009-11-04 Konrad Trifunovic <konrad.trifunovic@inria.fr>
474 * graphite-interchange.c (build_partial_difference): New.
475 (memory_stride_in_loop): Refactored the computation of
476 equality constraints into build_partial_difference function.
477 Added support for debugging stride computations.
479 2009-11-03 Sebastian Pop <sebastian.pop@amd.com>
481 * graphite-clast-to-gimple.c (gloog): Free if_region,
482 if_region->true_region, and if_region->region.
483 * sese.c (if_region_set_false_region): Free if_region->false_region.
484 (create_if_region_on_edge): Do not use GGC_NEW.
485 (move_sese_in_condition): Remove useless initialization.
487 2009-11-03 Sebastian Pop <sebastian.pop@amd.com>
489 * graphite-interchange.c (lst_perfect_nestify): Pass 3 parameters
490 for the loops created by the loop distribution. Do not modify the
492 (lst_try_interchange_loops): Same. Use a temporary LST for the
493 transformed schedule. Call lst_update_scattering before data
495 (lst_try_interchange): Pass an extra parameter INDEX.
496 (lst_do_interchange_1): New.
497 (lst_do_interchange): Call lst_do_interchange_1.
498 (scop_do_interchange): Call lst_update_scattering.
499 * graphite-poly.c (apply_poly_transforms): Do not call
500 lst_update_scattering.
501 * graphite-poly.h (lst_pred): New.
503 (lst_find_first_pbb): Return NULL when not found.
505 (lst_insert_in_sequence): Allow LST1 to be NULL.
507 (lst_substitute_3): New.
508 * gcc.dg/graphite/interchange-1.c: XFail.
509 * gcc.dg/graphite/interchange-8.c: XFail.
510 * gcc.dg/graphite/interchange-11.c: XFail.
512 2009-10-30 Sebastian Pop <sebastian.pop@amd.com>
514 * graphite-interchange.c (lst_perfectly_nested_p): New.
515 (lst_perfect_nestify): New.
516 (lst_try_interchange_loops): Call store_lst_schedule,
517 lst_perfectly_nested_p, lst_perfect_nestify and restore_lst_schedule.
518 (scop_do_interchange): Avoid redundant legality test.
519 Call lst_do_interchange on a copy of SCOP_TRANSFORMED_SCHEDULE.
520 * graphite-poly.c (apply_poly_transforms): Call lst_update_scattering.
521 * graphite-poly.h (psct_static_dim): New.
522 (lst_dewey_number_at_depth): New.
523 (lst_find_pbb): Restructured.
524 (lst_find_first_pbb): Restructured.
525 (lst_find_last_pbb): New.
526 (lst_contains_p): New.
527 (lst_contains_pbb): New.
528 (lst_create_nest): New.
529 (lst_remove_from_sequence): New.
530 (pbb_update_scattering): New.
531 (lst_update_scattering_under): New.
532 (lst_update_scattering_seq): New.
533 (lst_update_scattering): New.
534 (lst_insert_in_sequence): New.
535 (lst_distribute_lst): New.
536 (lst_remove_all_before_including_pbb): New.
537 (lst_remove_all_before_excluding_pbb): New.
539 2009-10-30 Sebastian Pop <sebastian.pop@amd.com>
541 * tree-ssa-loop-niter.c (finite_loop_p): Do not call twice
544 2009-10-30 Sebastian Pop <sebastian.pop@amd.com>
546 * graphite-poly.c (pbb_remove_duplicate_pdrs): Free collapsed.
548 2009-10-28 Konrad Trifunovic <konrad.trifunovic@gmail.com>
550 * graphite-poly.c (print_permutation): New.
551 (debug_permutation): New.
552 (new_poly_bb): Initialize PBB_PERMUTATION.
553 (free_poly_bb): Free PBB_PERMUTATION.
554 * graphite-poly.h (pbb_permutation_elt_p): Declared.
555 (struct pbb_permutation_elt): New.
556 (PBB_PERMUTATION_ELT_STRIDE): New.
557 (PBB_PERMUTATION_ELT_STRIDED_P): New.
558 (PBB_PERMUTATION_ELT_TIME_DIMENSION): New.
559 (new_pbb_permutation_elt): New.
560 (pbb_permutation_elt_free): New.
561 (struct poly_bb): Add field permutation.
562 (PBB_PERMUTATION): New.
563 (print_permutation): Declared.
564 (debug_permutation): Declared.
566 2009-10-26 Sebastian Pop <sebastian.pop@amd.com>
568 * graphite-clast-to-gimple.c (gloog): Do not call
569 sese_reset_aux_in_loops.
570 * graphite-sese-to-poly.c (build_loop_iteration_domains): Pass an
571 extra argument for domains. Do not use loop->aux.
572 (build_scop_iteration_domain): Initialize and free domains, pass it
573 to build_loop_iteration_domains and extract the information from
574 domains. Do not use loop->aux.
575 * sese.c (sese_reset_aux_in_loops): Removed.
576 * sese.h (sese_reset_aux_in_loops): Removed.
578 2009-10-26 Sebastian Pop <sebastian.pop@amd.com>
580 * graphite-clast-to-gimple.c (find_pbb_via_hash): Moved up.
581 (dependency_in_loop_p): Same.
582 (translate_clast): Do not use loop->aux. Initialize
583 loop->can_be_parallel.
584 (mark_loops_parallel): Removed.
585 * graphite-clast-to-gimple.h (mark_loops_parallel): Removed.
586 * graphite.c (free_aux_in_new_loops): Removed.
587 (graphite_finalize): Do not call free_aux_in_new_loops.
588 (graphite_transform_loops): Do not call mark_loops_parallel.
590 2009-10-26 Li Feng <nemokingdom@gmail.com>
592 * graphite-clast-to-gimple.c (get_stmtfor_depth): Removed.
593 (translate_clast): Pass an extra parameter LEVEL.
594 Call get_scattering_level.
595 * graphite-clast-to-gimple.h (get_scattering_level): New.
597 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
599 * cfgloop.c (alloc_loop): Initialize loop->single_iv.
600 * cfgloop.h (struct loop): New field single_iv.
602 * graphite-clast-to-gimple.c (pbb_to_depth_to_oldiv): Do not use
603 loop->aux anymore: use loop->single_iv.
604 (graphite_loop_normal_form): Moved...
605 (build_graphite_loop_normal_form): Removed.
606 (gloog): Do not call build_graphite_loop_normal_form.
607 (free_aux_in_new_loops): Moved...
608 (mark_loops_parallel): Restructure.
609 * graphite-clast-to-gimple.h (free_aux_in_new_loops): Do not declare.
610 * graphite-sese-to-poly.c (graphite_loop_normal_form): ...here.
611 (scop_canonicalize_loops): New.
612 (build_poly_scop): Call scop_canonicalize_loops.
613 * graphite.c (free_aux_in_new_loops): ...here.
615 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
617 * g++.dg/graphite/graphite.exp: Add the same rules as in
618 gcc.dg/graphite/graphite.exp.
620 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
622 * g++.dg/graphite/id-1.C: New.
624 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
626 * graphite-sese-to-poly.c (create_zero_dim_array): Pass an extra
628 (rewrite_close_phi_out_of_ssa): Update use of create_zero_dim_array.
629 (rewrite_phi_out_of_ssa): Same.
630 (rewrite_cross_bb_scalar_deps): Same.
631 (translate_scalar_reduction_to_array): Same.
633 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
635 * graphite-sese-to-poly.c (build_scop_drs): Disable call to
638 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
640 * graphite-sese-to-poly.c (dump_alias_graphs): New.
641 (build_scop_drs): Call dump_alias_graphs.
643 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
645 * graphite-poly.c (new_scop): Initialize SCOP_ORIGINAL_SCHEDULE,
646 SCOP_TRANSFORMED_SCHEDULE, and SCOP_SAVED_SCHEDULE.
647 (free_scop): Call free_lst on SCOP_ORIGINAL_SCHEDULE,
648 SCOP_TRANSFORMED_SCHEDULE, and SCOP_SAVED_SCHEDULE.
649 * graphite-poly.h (free_lst): New.
650 (store_lst_schedule): Free SCOP_SAVED_SCHEDULE.
651 (restore_lst_schedule): Free SCOP_TRANSFORMED_SCHEDULE.
653 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
655 * graphite-poly.h (struct scop): Add a field saved_schedule.
656 (SCOP_SAVED_SCHEDULE): New.
657 (store_lst_schedule): New.
658 (restore_lst_schedule): New.
659 (store_scattering): Call store_lst_schedule.
660 (restore_scattering): Call restore_lst_schedule.
662 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
664 * graphite-sese-to-poly.c (free_data_refs_aux): Fix formatting.
665 (pdr_add_alias_set): Same.
666 (build_poly_dr): Same.
667 (build_alias_set_optimal_p): Same.
668 (build_base_obj_set_for_drs): Same. Do not store the result of
671 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
673 * graphite-sese-to-poly.c (build_alias_set_optimal_p): Initialize
674 all_components_are_cliques to 1.
676 2009-10-20 Li Feng <nemokingdom@gmail.com>
678 * graphite-sese-to-poly.c (free_data_refs_aux): Update to free
680 (pdr_add_alias_set): Update retrieving alias_set_num.
681 (build_poly_dr): Update retrieving dr_base_object_set.
682 (partition_drs_to_sets): Remove.
683 (build_alias_set_optimal_p): New.
684 (build_alias_set_for_drs): Rename.
685 (build_scop_drs): Update.
686 * graphite-sese-to-poly.h (struct base_alias_pair): New.
687 (ALIAS_SET_INDEX): Remove.
688 (BASE_OBJECT_SET_INDEX): Remove.
690 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
692 * sese.c (get_vdef_before_sese): Handle GIMPLE_ASSIGN and GIMPLE_CALL.
694 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
696 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Do not infer
697 loop upper bounds for 1-element arrays at end of structures.
698 * tree-flow.h (array_at_struct_end_p): Declared.
699 * tree-ssa-loop-niter.c (array_at_struct_end_p): Not static anymore.
701 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
703 * g++.dg/graphite/pr41305.C: New.
705 2009-10-20 Alexander Monakov <amonakov@ispras.ru>
707 * graphite-sese-to-poly.c (build_loop_iteration_domains): Generalize
708 construction of parameter constraints from loop iteration analysis.
709 * gcc.dg/graphite/run-id-2.c: New test.
711 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
713 * graphite-interchange.c (memory_stride_in_loop): Delete p1, lma
716 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
718 * graphite-dependences.c (dependence_polyhedron_1): Remove
719 unused gdim dimensions from the DDR polyhedron.
721 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
723 * graphite-dependences.c (pddr_transformed_scattering): New.
724 (dot_original_deps_stmt_1): New.
725 (dot_transformed_deps_stmt_1): New.
726 (dot_deps_stmt_1): Call dot_original_deps_stmt_1 and
727 dot_transformed_deps_stmt_1.
728 (dot_original_deps): New.
729 (dot_transformed_deps): New.
730 (dot_deps_1): Call dot_original_deps and dot_transformed_deps.
732 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
734 * graphite-dependences.c (reduction_dr_1): Remove wrong
735 assert: reduction BBs can have multiple reduction writes
736 to memory. interchange-3.f90 is an example.
738 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
740 * gfortran.dg/graphite/interchange-3.f90: New.
742 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
744 * gcc.dg/graphite/interchange-1.c: Un-XFAILed.
746 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
748 * graphite-dependences.c (dependence_polyhedron_1): Add the
749 context to the dependence polyhedron.
751 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
753 * graphite-poly.c (pbb_remove_duplicate_pdrs): Initialize
754 PBB_PDR_DUPLICATES_REMOVED.
757 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
759 * graphite-sese-to-poly.c (find_scop_parameters): Initialize
761 (build_loop_iteration_domains): Extract bounds on parameters
762 based on the data size.
763 (build_scop_context): Do not initialize SCOP_CONTEXT;
766 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
768 * graphite-ppl.c (ppl_min_for_le_polyhedron): New.
769 * graphite-ppl.h (graphite-ppl.h): Declared.
771 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
773 * graphite-ppl.c (ppl_print_linear_expr): New.
774 (debug_ppl_linear_expr): New.
775 * graphite-ppl.h (ppl_print_linear_expr): Declared.
776 (debug_ppl_linear_expr): Declared.
778 2009-10-16 Sebastian Pop <sebastian.pop@amd.com>
780 * graphite-interchange.c: Fix comments.
781 * gcc.dg/graphite/block-1.c: Fix comments.
783 2009-10-16 Sebastian Pop <sebastian.pop@amd.com>
785 * gcc.dg/graphite/interchange-7.c: Un-XFAILed.
786 * gcc.dg/graphite/interchange-9.c: Un-XFAILed.
788 2009-10-16 Sebastian Pop <sebastian.pop@amd.com>
790 Reapply the patch from Alexander Monakov that disappeared during
791 the last merges from trunk.
793 2009-09-16 Alexander Monakov <amonakov@ispras.ru>
795 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Add bounds only
796 for ARRAY_REFs. Use array_ref_{low,up}_bound to determine bounds.
798 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
800 * graphite-interchange.c (memory_stride_in_loop): The depth
801 argument corresponds to a dynamic time dimension, so use
802 psct_dynamic_dim to refer to the transformed scattering dimension.
804 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
806 * graphite-interchange.c (memory_stride_in_loop): Fix comments.
808 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
810 * graphite-blocking.c (lst_do_strip_mine): Avoid strip mining the
812 * graphite-interchange.c (lst_do_interchange): Avoid interchanging
814 * graphite-poly.c (scop_to_lst): Fix LST sequence in an outermost
816 (print_lst): Print the root of LST in a different format.
817 * graphite-poly.h (lst_depth): Adjust to include the root of the LST.
819 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
821 * graphite-poly.c (print_scop): Fix pretty printing of a SCoP.
823 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
825 * doc/passes.texi: Document the Graphite infrastructure.
827 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
829 * graphite-sese-to-poly.c (insert_copyin): Use gsi_insert_seq_on_edge.
830 (rewrite_commutative_reductions_out_of_ssa): Call gsi_commit_edge_inserts,
831 and check the SSA representation.
833 * gfortran.dg/graphite/id-18.f90: New, reduced from PR41193.
835 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
837 * gcc.dg/graphite/pr40157.c: Use -floop-block as reported in the PR.
839 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
841 * gcc.dg/graphite/interchange-11.c: New.
843 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
845 * gcc.dg/graphite/interchange-8.c: Enable loop interchange.
847 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
849 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK):
850 Add -fno-loop-strip-mine and -fno-loop-interchange.
851 (DEFAULT_FLAGS_GRAPHITE_INTERCHANGE): Add -fno-loop-block and
852 -fno-loop-strip-mine.
853 * gfortran.dg/graphite/graphite.exp: Same.
855 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
857 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK):
858 Renamed DEFAULT_FLAGS_GRAPHITE_BLOCK.
859 (DEFAULT_CFLAGS_GRAPHITE_IDENTITY): Renamed
860 DEFAULT_FLAGS_GRAPHITE_IDENTITY.
861 (DEFAULT_CFLAGS_GRAPHITE_INTERCHANGE): Renamed
862 DEFAULT_FLAGS_GRAPHITE_INTERCHANGE.
863 (DEFAULT_CFLAGS_GRAPHITE_SCOP): Renamed
864 DEFAULT_FLAGS_GRAPHITE_SCOP.
865 (DEFAULT_CFLAGS_RUN_ID): Renamed DEFAULT_FLAGS_RUN_ID.
866 (DEFAULT_CFLAGS_GRAPHITE): Renamed DEFAULT_FLAGS_GRAPHITE.
868 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
870 * graphite-poly.c (pbb_number_of_iterations_at_time): Cleanup comments.
872 2009-10-14 Konrad Trifunovic <konrad.trifunovic@gmail.com>
873 Sebastian Pop <sebastian.pop@amd.com>
875 * graphite-interchange.c (build_linearized_memory_access): Pass an
877 (memory_stride_in_loop): Include transform scattering in the
878 access functions to be able to querry the strides in the
880 (pbb_interchange_loop_depths): Interchange the psct_dynamic_dim,
881 not the psct_iterator_dim.
883 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
885 * graphite-blocking.c (pbb_do_strip_mine): Removed.
886 (lst_do_strip_mine_loop): New.
887 (lst_do_strip_mine): New.
888 (scop_do_strip_mine): Call lst_do_strip_mine.
889 * graphite-poly.h (lst_add_loop_under_loop): New.
890 (lst_find_first_pbb): New.
892 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
894 * graphite-poly.c (loop_to_lst): Fix LST creation.
896 2009-10-14 Tobias Grosser <grosser@fim.uni-passau.de>
898 * testsuite/gcc.dg/graphite/id-15.c: (8 * 8) replaced with
899 sizeof(unsigned long) to make it run on 32bit systems.
901 2009-10-14 Tobias Grosser <grosser@fim.uni-passau.de>
903 * testsuite/gcc.dg/graphite/run-id-1.c: Use smaller matrix to not
906 2009-10-14 Ramakrishna Upadrasta <Ramakrishna.Upadrasta@inria.fr>
908 * graphite-sese-to-poly.c (write_alias_graph_to_ascii_dimacs): Fix
910 (write_alias_graph_to_ascii_dot): New.
911 (write_alias_graph_to_ascii_ecc): Ditto.
912 (partition_drs_to_sets): Add testing of optimality of current method
913 which assigns alias numbers according to DFS Comopnent number. used
914 as heuristic for the upcoming ECC algorithm.
915 (build_scop_drs): Write to file also with the ecc and dot format.
917 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
919 * gfortran.dg/graphite/interchange-1.f: XFail.
921 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
923 * graphite.c (graphite_initialize): Do not handle functions with
924 more than 100 basic blocks.
926 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
928 * graphite-blocking.c (pbb_do_strip_mine): Use
929 PARAM_LOOP_BLOCK_TILE_SIZE.
931 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
933 * graphite-poly.c (dot_lst_1): New.
935 * graphite-poly.h (dot_lst): Declared.
937 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
939 * graphite-dependences.c (dot_deps_stmt_1): New.
940 (dot_deps_stmt): New.
941 * graphite-dependences.h (dot_deps_stmt): Declared.
943 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
945 * graphite-sese-to-poly.c (rewrite_cross_bb_scalar_dependence): Do
946 not replace cross BB scalar dependences ending on PHI nodes.
947 (rewrite_cross_bb_scalar_deps): Filter out GIMPLE_PHI nodes.
949 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
951 * graphite-poly.c (apply_poly_transforms): Implement the high
952 level driver for flag_loop_block.
953 * tree-ssa-loop.c (gate_graphite_transforms): Remove call to sorry for
956 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK): Add
958 * gfortran.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK):
961 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
963 * graphite-poly.h (lst_find_pbb): New.
964 (find_lst_loop): New.
966 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
968 * graphite-poly.c (new_scop): Remove init of SCOP_DEP_GRAPH.
969 * graphite-poly.h (struct scop): Remove dep_graph field.
970 (SCOP_DEP_GRAPH): Removed.
972 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
974 * graphite-poly.h (copy_lst): Do full copy of LST.
976 2009-10-07 Sebastian Pop <sebastian.pop@amd.com>
978 * graphite-sese-to-poly.c (reduction_phi_p): Call remove_invariant_phi
979 when the loop stride is zero.
981 * gcc.dg/graphite/id-16.c: New.
983 2009-10-06 Sebastian Pop <sebastian.pop@amd.com>
985 * graphite-dependences.c (reduction_dr_1): New.
986 (reduction_dr_p): New.
987 (graphite_legal_transform_dr): Call reduction_dr_p.
988 (reduction_ddr): Renamed reduction_ddr_p.
989 * graphite-poly.h (same_pdr_p): New.
990 (number_of_write_pdrs): New.
991 * graphite-sese-to-poly.c (nb_data_writes_in_bb): New.
992 (split_reduction_stmt): Do not split reduction statements
993 when there are no writes to memory.
994 (translate_scalar_reduction_to_array_for_stmt): Insert the
995 memory reduction statement just after the scalar reduction statement.
997 * gcc.dg/graphite/interchange-10.c: Updated to differ from interchange-4.c.
999 * gcc.dg/graphite/interchange-3.c: Un-XFAIL-ed.
1000 * gcc.dg/graphite/interchange-4.c: Un-XFAIL-ed.
1002 2009-10-06 Sebastian Pop <sebastian.pop@amd.com>
1004 * graphite-interchange.c (lst_apply_interchange): New.
1005 (lst_interchange_profitable_p): New.
1006 (lst_try_interchange_loops): New.
1007 (lst_try_interchange): New.
1008 (lst_do_interchange): New.
1009 (pbb_do_interchange): Removed.
1010 (scop_do_interchange): Call lst_do_interchange.
1012 2009-10-06 Sebastian Pop <sebastian.pop@amd.com>
1014 * graphite-poly.c (print_scop): Print SCOP_ORIGINAL_SCHEDULE and
1015 SCOP_TRANSFORMED_SCHEDULE.
1020 * graphite-poly.h (lst_p): New.
1023 (LST_LOOP_FATHER): New.
1026 (scop_to_lst): Declared.
1027 (print_lst): Declared.
1028 (debug_lst): Declared.
1029 (new_lst_loop): New.
1030 (new_lst_stmt): New.
1033 (lst_dewey_number): New.
1034 (struct scop): Add original_schedule and transformed_schedule fields.
1035 (SCOP_ORIGINAL_SCHEDULE): New.
1036 (SCOP_TRANSFORMED_SCHEDULE): New.
1037 * graphite-sese-to-poly.c (build_poly_scop): Call scop_to_lst.
1039 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
1041 * graphite-dependences.c (reduction_ddr): New.
1042 (graphite_legal_transform_bb): Call reduction_ddr.
1043 * graphite-poly.c (new_poly_bb): Pass a new bool parameter.
1044 Initialize PBB_IS_REDUCTION.
1045 * graphite-poly.h (struct poly_bb): New bool field is_reduction.
1046 (PBB_IS_REDUCTION): New.
1047 (new_poly_bb): Update declaration.
1048 * graphite-scop-detection.h (build_scop_bbs): Removed.
1049 (nb_reductions_in_loop): Removed.
1050 * graphite-sese-to-poly.c (try_generate_gimple_bb): Pass a sbitmap
1051 parameter for reductions.
1052 (try_generate_gimple_bb): Update call to new_poly_bb.
1053 (build_scop_bbs_1): Same.
1054 (build_scop_bbs): Same.
1055 (gsi_for_phi_node): New.
1056 (scalar_close_phi_node_p): Remove gcc_assert.
1057 (split_reduction_stmt): New.
1058 (is_reduction_operation_p): New.
1059 (phi_contains_arg): New.
1060 (follow_ssa_with_commutative_ops): New.
1061 (detect_commutative_reduction_arg): New.
1062 (detect_commutative_reduction_assign): New.
1063 (follow_inital_value_to_phi): New.
1064 (edge_initial_value_for_loop_phi): New.
1065 (initial_value_for_loop_phi): New.
1066 (detect_commutative_reduction): New.
1067 (translate_scalar_reduction_to_array_for_stmt): New.
1068 (insert_copyout): New.
1069 (insert_copyin): New.
1070 (translate_scalar_reduction_to_array): New.
1071 (rewrite_commutative_reductions_out_of_ssa_close_phi): New.
1072 (rewrite_commutative_reductions_out_of_ssa_loop): New.
1073 (rewrite_commutative_reductions_out_of_ssa): New.
1074 (build_poly_scop): Call rewrite_commutative_reductions_out_of_ssa.
1075 * sese.h (split_region_for_bb): New.
1077 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK): Add -ffast-math.
1078 * gcc.dg/graphite/interchange-1.c: Fix format.
1079 * gcc.dg/graphite/interchange-10.c: New.
1081 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
1083 * graphite-sese-to-poly.c (insert_out_of_ssa_copy): Remove
1086 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
1088 * graphite-sese-to-poly.c (scev_analyzable_p): New.
1089 (rewrite_cross_bb_scalar_dependence): New.
1090 (rewrite_cross_bb_scalar_deps): New.
1091 (rewrite_reductions_out_of_ssa): Use bb_in_sese_p.
1092 Call rewrite_cross_bb_scalar_deps.
1094 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
1096 * graphite-sese-to-poly.c (gsi_for_ssa_name_def): Removed.
1097 (insert_out_of_ssa_copy): Directly use gsi_after_labels and
1100 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
1102 * graphite-clast-to-gimple.c (build_cloog_prog): Use pbb_index.
1103 * graphite-interchange.c (pbb_do_interchange): Same.
1104 * graphite-poly.c (print_scattering_function): Same.
1106 * graphite-poly.h (pbb_loop): New.
1107 * graphite-sese-to-poly.c (create_linear_expr_from_tree): Use pbb_loop.
1109 2009-09-27 Sebastian Pop <sebastian.pop@amd.com>
1111 * graphite-scop-detection.c (limit_scops): Do not build poly_bbs.
1113 2009-09-27 Sebastian Pop <sebastian.pop@amd.com>
1115 * graphite-sese-to-poly.c (partition_drs_to_sets): Drs is not modified,
1116 so don't pass a pointer to it.
1117 (build_alias_set_for_drs): Same.
1118 (build_base_obj_set_for_drs): Same.
1119 (build_scop_drs): Same.
1121 2009-09-26 Li Feng <nemokingdom@gmail.com>
1123 * graphite-sese-to-poly.c (build_scop_drs): Disable writing to file
1124 the alias graph of data references.
1126 2009-09-25 Li Feng <nemokingdom@gmail.com>
1128 * graphite-sese-to-poly.c (write_alias_graph_to_ascii_dimacs): New.
1129 (build_scop_drs): When debugging, write the alias graph to file,
1130 otherwise, should be disabled.
1132 2009-09-17 Sebastian Pop <sebastian.pop@amd.com>
1134 * graphite-scop-detection.c (stmt_simple_memref_p): Removed.
1135 (is_simple_operand): Remove call to stmt_simple_memref_p.
1136 (stmt_simple_for_scop_p): Update call to is_simple_operand.
1138 2009-09-17 David Edelsohn <edelsohn@gnu.org>
1140 * testsuite/gcc.dg/graphite/interchange-mvt.c: New File.
1141 * testsuite/gcc.dg/graphite/scop-dsyrk.c: New File.
1142 * testsuite/gcc.dg/graphite/scop-dsyr2k.c: New File.
1143 * testsuite/gcc.dg/graphite/scop-mvt.c: New File.
1144 * testsuite/gcc.dg/graphite/scop-sor.c: New File.
1146 2009-09-17 Li Feng <nemokingdom@gmail.com>
1149 * graphite-dependences.c (poly_drs_may_alias_p): Adjust definition.
1150 (pddr_original_scattering): Make sure 2 pdr2 in the same base object set.
1151 (graphite_carried_dependence_level_k): Ditto.
1152 * graphite-poly.c (new_poly_dr): Add init of PDR_BASE_OBJECT_SET.
1153 * graphite-poly.h (struct poly_dr): Add member dr_base_object_set.
1154 (new_poly_dr): Adjust declaration.
1155 * graphite-sese-to-poly.c (free_data_refs_aux): New.
1156 (free_gimple_bb): Added free_data_refs_aux.
1157 (build_poly_dr): Add dr_base_object_set.
1158 (partition_drs_to_sets): New.
1159 (dr_same_base_object_p): New.
1160 (build_alias_set_for_drs): New.
1161 (build_base_object_set_for_drs): New.
1162 (build_scop_drs): Add build_base_obj_set_for_drs.
1163 * graphite-sese-to-poly.h: Added #define for alias set number index and
1164 base object set index.
1165 * libgomp/testsuite/libgomp.graphite/force-parallel-6.c: Refine tests.
1166 * libgomp/testsuite/libgomp.graphite/pr4118.c: New.
1168 2009-09-16 Alexander Monakov <amonakov@ispras.ru>
1170 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Add bounds only
1171 for ARRAY_REFs. Use array_ref_{low,up}_bound to determine bounds.
1173 2009-09-14 Sebastian Pop <sebastian.pop@amd.com>
1175 * graphite-sese-to-poly.c (struct irp_data): Removed.
1176 (idx_record_params): Removed.
1177 (find_params_in_bb): Scan for parameters the access functions; don't
1178 parse the tree representation.
1180 2009-09-14 Sebastian Pop <sebastian.pop@amd.com>
1182 * tree-ssa-loop.c (gate_graphite_transforms): Disable Graphite
1183 passes at -O1 and below.
1185 2009-09-14 Sebastian Pop <sebastian.pop@amd.com>
1187 * graphite-blocking.c: Fix order of includes: tree-chrec.h, then
1188 tree-scalar-evolution.h, and then tree-data-ref.h.
1189 * graphite-clast-to-gimple.c: Same.
1190 * graphite-dependences.c: Same.
1191 * graphite-interchange.c: Same.
1192 * graphite-poly.c: Same.
1193 * graphite-scop-detection.c: Same.
1194 * graphite-sese-to-poly.c: Same.
1196 * lambda-code.c: Same.
1197 * matrix-reorg.c: Same.
1198 * tree-data-ref.c: Same.
1199 * tree-if-conv.c: Same.
1200 * tree-loop-distribu: Same.: Same.
1201 * tree-loop-linear.c: Same.
1202 * tree-parloops.c: Same.
1203 * tree-predcom.c: Same.
1204 * tree-vect-patterns.c: Same.
1206 2009-09-02 Sebastian Pop <sebastian.pop@amd.com>
1208 Partially revert the previous patch, except the following.
1209 * tree-scalar-evolution.c (instantiate_scev_not): Adapted to pass
1210 as parameters the operands of the not expression.
1212 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1214 * tree-scalar-evolution.c (instantiate_scev_assign): New.
1215 Do not call analyze_scalar_evolution on assignments.
1216 (instantiate_scev_phi): Call analyze_scalar_evolution.
1217 (instantiate_scev_name): Call instantiate_scev_assign and
1218 instantiate_scev_phi.
1219 (instantiate_scev_not): Adapted to pass as parameters the operands
1220 of the not expression.
1222 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1224 * tree-scalar-evolution.c (instantiate_scev_binary): Adapted
1225 to pass as parameters the operands of the binary expression.
1227 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1229 * tree-scalar-evolution.c (instantiate_scev_bitnot): Renamed
1230 instantiate_scev_not. Handle NEGATE_EXPR.
1231 (instantiate_scev_r): Handle NEGATE_EXPR.
1233 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1235 * tree-scalar-evolution.c (instantiate_scev_1): Renamed
1237 (instantiate_scev_r): Move code in instantiate_scev_2
1238 and instantiate_scev_1.
1240 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1242 * tree-scalar-evolution.c (instantiate_scev_3): New.
1243 (instantiate_scev_1): Move code in instantiate_scev_3.
1245 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1247 * tree-scalar-evolution.c (instantiate_scev_poly): New.
1248 (instantiate_scev_1): Move code in instantiate_scev_poly.
1250 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1252 * tree-scalar-evolution.c (instantiate_scev_bitnot): New.
1253 (instantiate_scev_1): Move code in instantiate_scev_bitnot.
1255 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1257 * tree-scalar-evolution.c (instantiate_scev_convert): New.
1258 (instantiate_scev_1): Move code in instantiate_scev_convert.
1260 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1262 * tree-scalar-evolution.c (instantiate_scev_binary): New.
1263 (instantiate_scev_1): Move code in instantiate_scev_binary.
1265 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1267 * tree-scalar-evolution.c (instantiate_scev_name): New.
1268 (instantiate_scev_1): Move code in instantiate_scev_name.
1270 2009-08-28 Sebastian Pop <sebastian.pop@amd.com>
1272 * Merge from mainline (150992:151171).
1274 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
1276 * graphite-dependences.c (graphite_legal_transform_bb): Call
1277 pbb_remove_duplicate_pdrs.
1278 * graphite-poly.c (can_collapse_pdr): Removed.
1279 (pdr_find_duplicate): Removed.
1280 (can_collapse_pdrs): New.
1281 (pbb_remove_duplicate_pdrs): New.
1282 (new_poly_dr): Do not look for duplicates.
1283 * graphite-poly.h (struct poly_bb): New field pdr_duplicates_removed.
1284 (PBB_PDR_DUPLICATES_REMOVED): New.
1285 (pbb_remove_duplicate_pdrs): Declared.
1287 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
1289 * graphite-interchange.c (pbb_interchange_profitable_p): Adjust
1290 the strides by multiplying by PDR_NB_REFS.
1291 * graphite-poly.c (can_collapse_pdr): New.
1292 (pdr_find_duplicate): New.
1293 (new_poly_dr): Call pdr_find_duplicate. Collapse duplicate PDRs.
1294 Initialize PDR_NB_REFS.
1295 * graphite-poly.h (struct poly_dr): Add field nb_refs.
1297 (new_poly_dr): Number of subscripts is a graphite_dim_t.
1299 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
1301 Revert one of the previous commits:
1302 * graphite-dependences.c (graphite_legal_transform_bb): Avoid
1303 the computation of symmetric data dependence relations.
1304 (dependency_between_pbbs_p): Same.
1306 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
1309 * graphite-poly.c (apply_poly_transforms): Remove legality test before
1312 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
1314 * graphite-dependences.c (pddr_original_scattering): Return NULL
1315 for read-read dependence relations.
1316 * graphite-poly.h (enum poly_dr_type): Fix comment.
1319 (pdr_may_write_p): New.
1321 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
1323 * graphite-poly.h (enum POLY_DR_TYPE): Renamed poly_dr_type.
1324 (struct poly_dr): Same.
1325 (new_poly_dr): Same.
1326 * graphite-poly.c (new_poly_dr): Same.
1328 2009-08-25 Konrad Trifunovic <konrad.trifunovic@gmail.com>
1329 Sebastian Pop <sebastian.pop@amd.com>
1331 * graphite-blocking.c (pbb_strip_mine_loop_depth): Renamed
1332 pbb_strip_mine_time_depth. Changed the implementation so that
1333 transformation is expressed as a transformation on
1334 time (scatttering) dimensions. Also, ensures that the 2d+1
1335 scheduling format is preserved.
1336 (pbb_strip_mine_profitable_p): Profitability is based on the
1337 iteration number of a given time (scattering) dimension,
1338 and not on a original loop depth dimension.
1339 (pbb_strip_mine): Call pbb_number_of_iterations_at_time.
1340 (pbb_do_strip_mine): Call psct_dynamic_dim.
1341 * graphite-poly.c (pbb_number_of_iterations_at_time): New.
1342 * graphite-poly.h (pbb_number_of_iterations_at_time): Declared.
1343 (pbb_nb_dynamic_scattering_transform): New.
1344 (psct_dynamic_dim): New.
1346 2009-08-25 Konrad Trifunovic <konrad.trifunovic@gmail.com>
1348 * graphite-ppl.c (ppl_max_for_le): Renamed ppl_max_for_le_pointset.
1349 * graphite-ppl.h (ppl_max_for_le): Renamed ppl_max_for_le_pointset.
1350 * graphite-poly.c (pbb_number_of_iterations): Rename ppl_max_for_le.
1351 * graphite-interchange.c (build_linearized_memory_access): Same.
1352 (memory_stride_in_loop): Same.
1354 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
1356 * graphite-dependences.c (pddr_original_scattering): New.
1357 (graphite_legal_transform_dr): Call pddr_original_scattering.
1360 * graphite-dependences.h (dot_deps): Declared.
1361 * graphite-poly.c (new_poly_dr): Initialize PDR_ID.
1362 (print_pdr): Print PDR_ID.
1363 * graphite-poly.h (struct poly_dr): Add field id.
1366 * graphite-scop-detection.c (dot_all_scops_1): Cleanup comment.
1368 2009-08-22 Sebastian Pop <sebastian.pop@amd.com>
1370 * graphite-dependences.c (graphite_carried_dependence_level_k): Do
1371 not delete the original dependence relation.
1373 2009-08-21 Sebastian Pop <sebastian.pop@amd.com>
1375 * graphite-dependences.c (graphite_legal_transform_bb): Avoid
1376 the computation of symmetric data dependence relations.
1377 (dependency_between_pbbs_p): Same.
1379 2009-08-21 Sebastian Pop <sebastian.pop@amd.com>
1381 * graphite-dependences.c (new_poly_dr_pair): Renamed new_poly_ddr.
1382 (eq_poly_dr_pair_p): Renamed eq_poly_ddr_p.
1383 (hash_poly_dr_pair_p): Renamed hash_poly_ddr_p.
1384 (free_poly_ddr): New.
1385 (pddr_is_empty): New.
1386 (dependence_polyhedron_1): Now returns a poly_ddr_p.
1387 (dependence_polyhedron): Same. Remove useless gcc_assert.
1389 (graphite_legal_transform_dr): Call pddr_is_empty and free_poly_ddr.
1390 (graphite_carried_dependence_level_k): Call pddr_is_empty.
1391 * graphite-dependences.h (enum poly_dependence_kind): New.
1392 (poly_dr_pair): Renamed poly_ddr. Added a field kind.
1393 (PDRP_SOURCE): Renamed PDDR_SOURCE.
1394 (PDRP_SINK): Renamed PDDR_SINK.
1395 (PDRP_DDP): Renamed PDDR_DDP.
1397 (free_poly_ddr): Declared.
1398 * graphite-poly.c (new_scop): Use the new hash function names.
1399 * graphite-poly.h (struct scop): Renamed field original_pdr_pairs
1400 into original_pddrs.
1401 (SCOP_ORIGINAL_PDR_PAIRS): Renamed SCOP_ORIGINAL_PDDRS.
1403 2009-08-21 Sebastian Pop <sebastian.pop@amd.com>
1405 * Merge from mainline (150764:150992).
1407 2009-08-18 Sebastian Pop <sebastian.pop@amd.com>
1409 * cfgloopmanip.c (create_empty_loop_on_edge): Generate upper
1410 bounds with LT_EXPR to make niter analysis more precise on code
1411 generated by Graphite.
1413 2009-08-18 Sebastian Pop <sebastian.pop@amd.com>
1415 * graphite-dependences.c (graphite_legal_transform_dr): Fix formatting.
1416 (graphite_legal_transform_bb): Same.
1417 (poly_drs_may_alias_p): Same.
1419 2009-08-15 Sebastian Pop <sebastian.pop@amd.com>
1422 * graphite-ppl.c (ppl_max_for_le): Correct the use of
1423 ppl_Pointset_Powerset_C_Polyhedron_maximize.
1425 2009-08-13 Sebastian Pop <sebastian.pop@amd.com>
1427 * graphite-poly.c (print_pbb): Print PBB index.
1429 2009-08-13 Sebastian Pop <sebastian.pop@amd.com>
1431 * Merge from mainline (r150672:150764).
1433 2009-08-13 Sebastian Pop <sebastian.pop@amd.com>
1435 * graphite-interchange.c (ppl_max_for_le): Moved...
1436 * graphite-poly.c (pbb_number_of_iterations): Call ppl_max_for_le.
1437 * graphite-ppl.c (ppl_max_for_le): ... here.
1438 * graphite-ppl.h (ppl_max_for_le): Declared.
1440 2009-08-12 Sebastian Pop <sebastian.pop@amd.com>
1442 * Merge from mainline (r150372:150672).
1444 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
1447 * sese.c (convert_for_phi_arg): New.
1448 (add_guard_exit_phis): Use convert_for_phi_arg.
1450 * testsuite/gfortran.dg/graphite/id-17.f: New.
1452 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
1454 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Dont add
1455 unknown subscript upper bounds.
1457 * testsuite/gcc.dg/graphite/interchange-6.c: Un-XFAIL.
1459 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
1460 Pranav Garg <pranav.garg2107@gmail.com>
1462 * graphite-interchange.c (gather_access_strides): Removed.
1463 (ppl_max_for_le): New.
1464 (build_linearized_memory_access): New.
1465 (memory_stride_in_loop): New.
1466 (pbb_interchange_profitable_p): Reimplemented.
1467 * graphite-ppl.h (ppl_new_id_map): New.
1468 (ppl_interchange): New.
1470 * testsuite/gcc.dg/graphite/interchange-6.c: XFAILed.
1472 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
1474 * graphite-interchange.c (compute_subscript): Removed.
1475 (compute_array_size_cstr): Removed.
1476 (compute_array_size_poly): Removed.
1477 (compute_array_size): Removed.
1478 (gather_access_strides_poly): Removed.
1479 (gather_access_strides): Empty.
1481 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
1483 * graphite-dependences.c (dependence_polyhedron_1): Replace
1484 pdr_nb_subscripts with PDR_NB_SUBSCRIPTS.
1485 (graphite_legal_transform_dr): Same.
1486 (graphite_carried_dependence_level_k): Same.
1487 * graphite-poly.c (new_poly_dr): Add a parameter nb_subscripts.
1488 Initialize PDR_NB_SUBSCRIPTS.
1489 (print_pdr_access_layout): Replace pdr_nb_subscripts with
1491 * graphite-poly.h (struct poly_dr): Add nb_subscripts field.
1492 (PDR_NB_SUBSCRIPTS): New.
1493 (pdr_nb_subscripts): Removed.
1494 (pdr_dim): Simplified.
1495 * graphite-sese-to-poly.c (build_poly_dr): Replace pdr_nb_subscripts
1496 with PDR_NB_SUBSCRIPTS.
1498 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
1500 * graphite-interchange.c (compute_array_size): Remove use of
1502 * graphite-poly.c (new_poly_dr): Remove argument data_container.
1503 Do not initialize PDR_DATA_CONTAINER.
1504 (print_pdr): Do not print PDR_DATA_CONTAINER.
1505 * graphite-poly.h (struct poly_dr): Remove data_container field.
1506 (PDR_DATA_CONTAINER): Removed.
1507 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Remove use of
1509 (build_poly_dr): Same.
1511 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
1513 * testsuite/gcc.dg/graphite/interchange-9.c: New.
1515 2009-08-05 Konrad Trifunovic <konrad.trifunovic@gmail.com>
1516 Sebastian Pop <sebastian.pop@amd.com>
1518 * graphite-dependences.c (graphite_legal_transform_dr): Work on a
1519 copy of the dependence polyhedron. Free the temporary objects.
1520 (graphite_carried_dependence_level_k): Free unused objects before
1523 * testsuite/gcc.dg/graphite/interchange-1.c: XFAILed.
1524 * testsuite/gcc.dg/graphite/interchange-2.c: XFAILed.
1525 * testsuite/gcc.dg/graphite/interchange-3.c: XFAILed.
1526 * testsuite/gcc.dg/graphite/interchange-4.c: XFAILed.
1527 * testsuite/gcc.dg/graphite/interchange-7.c: XFAILed.
1529 2009-08-05 Sebastian Pop <sebastian.pop@amd.com>
1531 * graphite-blocking.c (scop_do_strip_mine): Call store_scattering.
1532 Early return without analyzing the data dependences if no
1533 transform has been done. Call restore_scattering if the transform
1535 (graphite-interchange.c): Same.
1536 * graphite-poly.c (print_scattering_function): Test for PBB_TRANSFORMED.
1537 (graphite_read_transforms): Initialize PBB_TRANSFORMED.
1538 (apply_poly_transforms): Do not gcc_assert that
1539 the transform is legal.
1540 (new_poly_bb): Initialize PBB_TRANSFORMED, PBB_SAVED, and PBB_ORIGINAL.
1541 Do not initialize PBB_NB_SCATTERING_TRANSFORM, PBB_NB_LOCAL_VARIABLES,
1542 PBB_TRANSFORMED_SCATTERING, and PBB_ORIGINAL_SCATTERING.
1543 (free_poly_dr): Free PBB_TRANSFORMED, PBB_SAVED, and PBB_ORIGINAL.
1544 * graphite-poly.h (struct poly_scattering): New.
1545 (struct poly_bb): Add original, transformed, and saved fields.
1546 Remove transformed_scattering, original_scattering, nb_local_variables,
1547 and nb_scattering_transform fields.
1548 (PBB_ORIGINAL, PBB_TRANSFORMED, PBB_SAVED): New.
1549 (poly_scattering_new): New.
1550 (poly_scattering_free): New.
1551 (poly_scattering_copy): New.
1552 (store_scattering_pbb): New.
1553 (store_scattering): New.
1554 (restore_scattering_pbb): New.
1555 (restore_scattering): New.
1556 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons):
1557 Initialize PBB_TRANSFORMED and PBB_ORIGINAL.
1559 2009-08-05 Sebastian Pop <sebastian.pop@amd.com>
1561 * graphite-poly.c (print_pbb): Add parentheses in the pretty print.
1564 2009-08-05 Sebastian Pop <sebastian.pop@amd.com>
1566 * Makefile.in (graphite.o): Depends on PREDICT_H.
1567 * graphite.c: Include predict.h.
1568 (graphite_finalize): Call tree_estimate_probability.
1569 * predict.c (predict_loops): Do not call scev_initialize and
1571 (tree_estimate_probability_bb): New.
1572 (tree_estimate_probability): Do not initialize loops: move that
1573 code to the driver. Call tree_estimate_probability_bb.
1574 (tree_estimate_probability_driver): New.
1575 (pass_profile): Use tree_estimate_probability_driver.
1576 * predict.h (tree_estimate_probability): Declared.
1578 2009-08-05 Sebastian Pop <sebastian.pop@amd.com>
1580 * graphite-clast-to-gimple.c (gloog): Add time to TV_GRAPHITE_CODE_GEN.
1581 * graphite-dependences.c (graphite_legal_transform): Add time to
1582 TV_GRAPHITE_DATA_DEPS.
1583 (dependency_between_pbbs_p): Same.
1584 * timevar.def (TV_GRAPHITE_DATA_DEPS, TV_GRAPHITE_CODE_GEN): New.
1586 2009-08-03 Sebastian Pop <sebastian.pop@amd.com>
1588 * Merge from mainline (r149952:150372).
1590 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
1592 * ChangeLog.graphite: Fix indenting, white spaces and 80 columns.
1593 * graphite-blocking.c: Same.
1594 * graphite-clast-to-gimple.c: Same.
1595 * graphite-dependences.c: Same.
1596 * graphite-poly.c: Same.
1597 * graphite-poly.h: Same.
1598 * graphite-ppl.c: Same.
1599 * graphite-scop-detection.c: Same.
1600 * graphite-sese-to-poly.c: Same.
1603 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
1605 * graphite-sese-to-poly.c (loop_entry_phi_arg): New.
1606 (remove_simple_copy_phi): New.
1607 (remove_invariant_phi): New.
1608 (simple_copy_phi_p): New.
1609 (reduction_phi_p): New.
1610 (gsi_for_ssa_name_def): New.
1611 (insert_out_of_ssa_copy): New.
1612 (insert_out_of_ssa_copy_on_edge): New.
1613 (create_zero_dim_array): New.
1614 (scalar_close_phi_node_p): New.
1615 (rewrite_close_phi_out_of_ssa): New.
1616 (rewrite_phi_out_of_ssa): New.
1617 (rewrite_reductions_out_of_ssa): New.
1618 (build_poly_scop): Call rewrite_reductions_out_of_ssa.
1620 * testsuite/gcc.dg/graphite/id-11.c: New.
1621 * testsuite/gcc.dg/graphite/id-15.c: New.
1622 * testsuite/gcc.dg/graphite/interchange-1.c: Un-XFAIL.
1623 * testsuite/gcc.dg/graphite/interchange-2.c: Un-XFAIL.
1624 * testsuite/gcc.dg/graphite/interchange-3.c: Un-XFAIL.
1625 * testsuite/gcc.dg/graphite/interchange-4.c: Un-XFAIL.
1626 * testsuite/gcc.dg/graphite/interchange-7.c: Un-XFAIL.
1627 * testsuite/gcc.dg/graphite/scop-matmult.c: Un-XFAIL.
1628 * testsuite/gfortran.dg/graphite/id-13.f: New.
1629 * testsuite/gfortran.dg/graphite/id-5.f: New.
1631 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
1633 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not
1634 check that nb_reductions_in_loop is zero.
1635 * graphite-scop-detection.c (harmful_stmt_in_bb): Don't filter out
1636 reduction phi nodes.
1637 (nb_reductions_in_loop): Removed.
1638 (graphite_can_represent_loop): Do not call nb_reductions_in_loop.
1639 * graphite-sese-to-poly.c (phi_node_is_iv): Removed.
1640 (bb_contains_non_iv_scalar_phi_nodes): Removed.
1641 (scop_contains_non_iv_scalar_phi_nodes): Removed.
1642 (build_poly_scop): Do not call scop_contains_non_iv_scalar_phi_nodes.
1644 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
1646 * graphite-clast-to-gimple.c (build_cloog_prog): Do not code generate
1647 statements that have an empty iteration domain.
1648 * testsuite/gfortran.dg/graphite/id-16.f: New.
1650 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
1652 * tree-scalar-evolution.c (instantiate_scev_1): Return
1653 chrec_dont_know when the result is not above instantiate_below.
1654 * graphite-scop-detection.c (scopdet_basic_block_info): Fix formatting.
1655 * graphite-sese-to-poly.c (create_linear_expr_from_tree): Assert that
1656 the tree has a known scalar evolution.
1657 * testsuite/gfortran.dg/graphite/id-14.f: New.
1658 * testsuite/gfortran.dg/graphite/id-15.f: New.
1660 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
1662 * sese.c (rename_variables_in_stmt): Pass in an extra parameter
1664 (rename_variables): Keep inserting renames after the ones already
1667 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
1669 * graphite-sese-to-poly.c (compare_bb_depths): New.
1670 (graphite_sort_dominated_info): New.
1671 (build_scop_bbs_1): Call graphite_sort_dominated_info.
1672 (build_scop_scattering): Fix comment.
1674 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
1676 * graphite.c (graphite_finalize): Call print_loops instead of
1677 dump_function_to_file.
1678 * testsuite/gcc.dg/graphite/graphite.exp: Fix formatting.
1679 * testsuite/gcc.dg/graphite/pr35356-1.c: New. Look for the number of
1680 loops generated in the graphite output file.
1681 * testsuite/gcc.dg/graphite/pr35356-2.c: New.
1682 * testsuite/gcc.dg/graphite/pr35356-3.c: New. XFAILed for now.
1683 * testsuite/gfortran.dg/graphite/id-12.f: New.
1685 2009-07-24 Li Feng <nemokingdom@gmail.com>
1687 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-8.c:
1690 2009-07-24 Li Feng <nemokingdom@gmail.com>
1691 Tobias Grosser <grosser@fim.uni-passau.de>
1693 * graphite-sese-to-poly.c (pdr_add_alias_set): Use data reference's
1694 alias set number build alias in ACCESSES polyhedron.
1695 (build_alias_set_for_drs): New.
1696 (build_pbb_drs): Added build_alias_set_for_drs.
1697 * graphite-dependences.c (poly_drs_may_alias_p): New.
1698 (graphite_carried_dependence_level_k): Check alias information
1699 before building polyhedron.
1701 2009-07-24 Tobias Grosser <grosser@fim.uni-passau.de>
1703 * Makefile.in (lambda-code.o): Fix formatting.
1705 2009-07-24 Tobias Grosser <grosser@fim.uni-passau.de>
1707 * Merge from mainline (r149350-149952)
1709 2009-07-18 Tobias Grosser <grosser@fim.uni-passau.de>
1711 * graphite-poly.c (apply_poly_transforms): Move strip_mine
1712 before interchange to prepare for loop blocking.
1714 2009-07-18 Tobias Grosser <grosser@fim.uni-passau.de>
1716 * graphite-poly.c (apply_poly_transforms): Add checks after every
1718 * graphite-sese-to-poly.c (build_poly_scop): Remove check, as already
1719 done in apply_poly_transforms.
1721 2009-07-17 Konrad Trifunovic <konrad.trifunovic@gmail.com>
1723 * graphite-dependences.c (build_lexicographically_gt_constraint):
1724 Replace RES parameter with *RES.
1725 (dependence_polyhedron_1): Pass an address of the parameter RES
1726 instead of value of RES.
1728 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
1730 * graphite.c (graphite_finalize): Fix comment.
1731 (graphite_transform_loops): Reset scev info after code generation
1734 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
1736 * graphite.c (graphite_finalize): Call scev_reset.
1738 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
1740 * graphite-clast-to-gimple.c (compute_cloog_iv_types): Do not create
1741 GBB_CLOOG_IV_TYPES hash table twice.
1742 * graphite-sese-to-poly.c (free_gimple_bb): Call free_data_refs.
1743 (add_condition_to_domain): Clear GMP values.
1745 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
1747 * graphite-dependences.c: Fix formatting.
1748 * graphite-poly.c (free_poly_dr): Also free PDR_DATA_CONTAINER.
1749 (pbb_number_of_iterations): Free ppl_Linear_Expression.
1750 * graphite-sese-to-poly.c: Fix formatting.
1751 * graphite.c (graphite_transform_loops): Create the hash table
1752 after the early return.
1754 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
1756 * testsuite/gcc.dg/graphite/id-14.c: New.
1757 * testsuite/gcc.dg/graphite/pr40157.c: New.
1758 * testsuite/gfortran.dg/graphite/id-11.f: New.
1760 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
1762 * graphite-sese-to-poly.c (nb_pbbs_in_loops): New.
1763 (build_poly_scop): Return false when there are no pbbs within
1764 loops to avoid to pass to cloog scops with no loops.
1766 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
1768 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons): Avoid
1769 useless test "i % 2".
1770 (build_pbb_scattering_polyhedrons): Fix formatting.
1771 (build_poly_dr): Same.
1772 * graphite.c (graphite_transform_loops): Restructure.
1774 2009-07-14 Razya Ladelsky <razya@il.ibm.com>
1776 * tree-ssa-loop-manip.c (rewrite_phi_with_iv): Remove
1777 reduction_list parameter.
1778 (rewrite_all_phi_nodes_with_iv): Same.
1779 (canonicalize_loop_ivs): Same.
1780 * tree-parloops.c (struct brli): Removed.
1781 (build_reduction_list_info): Removed.
1782 (build_new_reduction): New.
1783 (analyze_reduction_list): Removed.
1784 (gather_scalar_reductions): Find reductions instead of phi
1785 nodes that can't be canonicalized.
1786 (try_create_reduction_list): Remove reduction_list parameter.
1787 (gen_parallel_loop): Same.
1788 (parallelize_loops): Remove analyze_reductions variable,
1789 initialization and free.
1790 Change reduction_list htab initialization to reduction_info
1791 elements instead of ssa names.
1792 Call try_create_reduction_list and gen_parallel_loop without
1793 analyzed_reduction argument.
1794 * graphite-clast-to-gimple (graphite_loop_normal_form): Call
1795 canonicalize_loop_ivs with one less argument.
1796 * tree-flow.h (canonicalize_loop_ivs): Remove one argument.
1798 2009-07-14 Konrad Trifunovic <konrad.trifunovic@gmail.com>
1800 * graphite-dependences.c (new_poly_dr_pair): New.
1801 (dependence_polyhedron): Renamed into dependence_polyhedron_1.
1802 (new_poly_dr_pair): New.
1803 (eq_poly_dr_pair_p): New.
1804 (hash_poly_dr_pair_p): New.
1805 * graphite-dependences.h (struct poly_dr_pair): New.
1806 (eq_poly_dr_pair_p): Declared.
1807 (hash_poly_dr_pair_p): Declared.
1808 * graphite-poly.c (new_scop): Initialize SCOP_ORIGINAL_PDR_PAIRS.
1809 (free_scop): Free SCOP_ORIGINAL_PDR_PAIRS.
1810 * graphite-poly.h (struct scop): Add original_pdr_pairs field.
1811 * Makefile.in (graphite-poly.o): Add dependence on
1812 graphite-dependences.h.
1814 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
1816 * graphite-scop-detection.c (graphite_can_represent_scev): Do not let
1817 polynomials of degree > 1 pass to Graphite.
1818 * tree-chrec.c (scev_is_linear_expression): Call
1819 evolution_function_is_affine_multivariate_p.
1820 * testsuite/gfortran.dg/graphite/id-10.f90: New.
1822 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
1824 * tree-scalar-evolution.c (compute_overall_effect_of_inner_loop):
1825 Instantiate scevs varying in outer loops.
1826 * testsuite/gfortran.dg/graphite/id-9.f: Correct testcase.
1828 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
1830 * graphite-sese-to-poly.c (build_loop_iteration_domains): Do not insert
1831 redundant constraint.
1833 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
1835 * testsuite/gcc.dg/graphite/graphite.exp: Fix comments.
1836 * testsuite/gfortran.dg/graphite/graphite.exp: Trigger actions
1837 based on the file names as in the C testsuite.
1838 * testsuite/gfortran.dg/graphite/block-1.f90: Fix patterns.
1839 * testsuite/gfortran.dg/graphite/block-2.f: Same.
1840 * testsuite/gfortran.dg/graphite/block-3.f90: Same.
1841 * testsuite/gfortran.dg/graphite/block-4.f90: Same.
1842 * testsuite/gfortran.dg/graphite/id-1.f90: Same.
1843 * testsuite/gfortran.dg/graphite/id-2.f90: Same.
1844 * testsuite/gfortran.dg/graphite/id-3.f90: Same.
1845 * testsuite/gfortran.dg/graphite/id-4.f90: Same.
1846 * testsuite/gfortran.dg/graphite/id-6.f: Same.
1847 * testsuite/gfortran.dg/graphite/id-9.f: Same.
1848 * testsuite/gfortran.dg/graphite/interchange-1.f: Same.
1849 * testsuite/gfortran.dg/graphite/interchange-2.f: Same.
1850 * testsuite/gfortran.dg/graphite/scop-1.f: Same.
1852 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
1854 * sese.c (expand_scalar_variables_call): New.
1855 (expand_scalar_variables_ssa_name): Handle calls in expander.
1857 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
1859 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-6.c:
1860 Expect to see the pattern twice.
1861 * testsuite/gcc.dg/graphite/interchange-0.c: Un-XFAIL.
1862 * testsuite/gcc.dg/graphite/interchange-5.c: Same.
1863 * testsuite/gcc.dg/graphite/interchange-6.c: Same.
1865 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
1867 * testsuite/gcc.dg/graphite/id-10.c: New.
1868 * testsuite/gcc.dg/graphite/id-12.c: New.
1869 * testsuite/gfortran.dg/graphite/id-7.f: New.
1870 * testsuite/gfortran.dg/graphite/id-8.f: New.
1872 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
1874 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Fix division by
1877 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
1879 * sese.c (rename_variables_in_stmt): Call fold_convert during renaming.
1881 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
1883 * sese.c (expand_scalar_variables_stmt): Avoid unnecessary expansion.
1885 2009-07-10 Sebastian Pop <sebastian.pop@amd.com>
1887 * graphite-sese-to-poly.c (pdr_add_memory_accesses): Fix order of
1888 building PDR subscripts.
1890 2009-07-10 Sebastian Pop <sebastian.pop@amd.com>
1892 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Fix the
1893 computation of array sizes.
1895 2009-07-10 Sebastian Pop <sebastian.pop@amd.com>
1897 * graphite-sese-to-poly.c (add_param_constraints): Disabled.
1899 2009-07-10 Tobias Grosser <grosser@fim.uni-passau.de>
1901 * graphite-dependences.c (map_into_dep_poly, map_dr_into_dep_poly,
1902 build_pairwise_constraint, dr_equality_constraints,
1903 build_pairwise_scheduling_equality,
1904 build_pairwise_scheduling_inequality, lexicographically_gt_p,
1905 build_lexicographically_gt_constraint, dependence_polyhedron,
1906 graphite_legal_transform_dr, graphite_carried_dependence_level_k):
1907 Move from NNC_Polyhedron to C_Polyhedron.
1908 * graphite-interchange.c (compute_array_size_poly,
1909 gather_access_strides): Dito.
1910 * graphite-poly.c (apply_poly_transforms, new_poly_dr, free_poly_bb,
1911 free_scop, pbb_number_of_iterations): Dito.
1912 * graphite-poly.h (struct poly_dr, pdr_nb_subscripts, struct poly_bb,
1913 pbb_dim_iter_domain, struct scop): Dito.
1914 * graphite-ppl.c (new_Constraint_System_from_Cloog_Matrix,
1915 new_Cloog_Domain_from_ppl_Polyhedron,
1916 new_Cloog_Domain_from_ppl_Pointset_Powerset, ppl_set_coef_gmp,
1917 ppl_insert_dimensions_pointset, ppl_insert_dimensions_pointset,
1918 ppl_strip_loop, ppl_strip_loop, ppl_print_polyhedron_matrix,
1919 ppl_print_powerset_matrix, debug_ppl_polyhedron_matrix,
1920 debug_ppl_powerset_matrix, ppl_read_polyhedron_matrix): Dito.
1921 * graphite-ppl.h (ppl_Pointset_Powerset_C_Polyhedron_t,
1922 new_C_Polyhedron_from_Cloog_Matrix, ppl_print_powerset_matrix,
1923 debug_ppl_powerset_matrix, ppl_insert_dimensions_pointset): Dito.
1924 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons,
1925 build_loop_iteration_domains, ppl_constraint_type_from_tree_code,
1926 add_condition_to_domain, add_condition_to_pbb, build_scop_context,
1927 build_scop_iteration_domain, build_poly_dr): Dito
1929 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1931 * testsuite/gcc.dg/graphite/graphite.exp: Added a rule to execute
1933 * testsuite/gcc.dg/graphite/run-id-1.c: New.
1935 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1937 * graphite-sese-to-poly.c (build_loop_iteration_domains): Add the
1938 positivity constraint on the symbolic number of iterations.
1940 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1942 * graphite-sese-to-poly.c (build_loop_iteration_domains): Rewrite.
1944 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1945 Tobias Grosser <grosser@fim.uni-passau.de>
1947 * graphite-clast-to-gimple.c (build_scop_context): Removed.
1948 (build_cloog_prog): Directly use SCOP_CONTEXT.
1949 * graphite-poly.c (new_scop): Initialize SCOP_CONTEXT.
1950 (free_scop): Free SCOP_CONTEXT.
1951 (print_scop_context): New.
1952 (print_scop): Call print_scop_context.
1953 (debug_scop_context): New.
1954 * graphite-poly.h (print_scop_context, debug_scop_context): Declared.
1955 (struct scop): Added field context.
1956 (SCOP_CONTEXT): New.
1957 * graphite-sese-to-poly.c (add_param_constraints): New.
1958 (build_scop_context): New.
1959 (build_poly_scop): Call build_scop_context.
1961 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1963 * graphite-clast-to-gimple.c (gmp_cst_to_tree): Moved...
1964 * graphite-ppl.c (ppl_set_inhomogeneous_gmp, ppl_set_coef_gmp): New.
1965 (ppl_set_inhomogeneous, ppl_set_coef): Moved...
1966 * graphite-ppl.h: Include double-int.h and tree.h.
1967 (ppl_set_inhomogeneous_gmp, ppl_set_coef_gmp): Declared.
1968 (ppl_set_inhomogeneous, ppl_set_coef): ...here.
1969 (gmp_cst_to_tree): ...here. Reimplemented using mpz_get_double_int.
1970 (tree_int_to_gmp, ppl_set_inhomogeneous_tree, ppl_set_coef_tree): New.
1972 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1974 * graphite-clast-to-gimple.c (clast_to_gcc_expression_red): Generate
1975 POINTER_PLUS_EXPR for pointer types.
1976 (clast_to_gcc_expression): Same.
1978 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1980 * graphite-poly.c (print_scattering_function): Early return when
1981 PBB_TRANSFORMED_SCATTERING is not initialized.
1982 (print_pbb_domain): Early return when PBB_DOMAIN is not initialized.
1984 2009-07-08 Sebastian Pop <sebastian.pop@amd.com>
1986 * tree-parloops.c (analyze_reduction_list): Remove unused variable
1989 2009-07-08 Razya Ladelsky <razya@il.ibm.com>
1991 * tree-parloops.c (analyze_reduction_list): Change return
1993 (try_create_reduction_list): Move the call to
1994 analyze_reduction_list to the beginining.
1995 Call reduction_phi with analyzed_reductions as argument
1996 instead of reduction_list.
1998 2009-07-08 Tobias Grosser <grosser@fim.uni-passau.de>
2000 * Merge from mainline (r148296:149346)
2002 2009-07-07 Sebastian Pop <sebastian.pop@amd.com>
2004 * graphite-scop-detection.c (graphite_can_represent_init): New.
2005 (graphite_can_represent_scev): Call graphite_can_represent_init:
2006 check that the initial value does not contain multiplications of
2008 (stmt_has_simple_data_refs_p): New.
2009 (stmt_simple_for_scop_p): Call stmt_simple_for_scop_p.
2010 (is_simple_operand): Fix formatting.
2011 * graphite-sese-to-poly.c (try_generate_gimple_bb): Fix formatting.
2013 2009-07-07 Sebastian Pop <sebastian.pop@amd.com>
2015 * testsuite/gcc.dg/graphite/id-13.c: New.
2016 * graphite-sese-to-poly.c (graphite_stmt_p): Do not call
2017 analyze_scalar_evolution, use scalar_evolution_in_region.
2018 (scan_tree_for_params_right_scev): Add extra assert.
2019 (parameter_index_in_region_1): Split from parameter_index_in_region.
2020 (idx_record_params): Use scalar_evolution_in_region.
2021 (find_params_in_bb): Same.
2022 (find_scop_parameters): Same.
2023 (build_loop_iteration_domains): Same.
2024 (create_linear_expr_from_tree): Same.
2025 * sese.c (scalar_evolution_in_region): New.
2026 * sese.h (scalar_evolution_in_region): Declared.
2027 (defined_in_sese_p): New.
2028 * tree-scalar-evolution.c (compute_overall_effect_of_inner_loop): Not
2030 * tree-scalar-evolution.h (compute_overall_effect_of_inner_loop):
2033 2009-07-07 Sebastian Pop <sebastian.pop@amd.com>
2035 * Makefile.in: Replace dependences on tree-chrec.h with SCEV_H.
2036 TREE_DATA_REF_H also implies SCEV_H.
2038 2009-07-07 Sebastian Pop <sebastian.pop@amd.com>
2040 * graphite-poly.c (print_scop_params): New.
2041 (print_scop): Call print_scop_params.
2042 (debug_scop_params): New.
2043 * graphite-poly.h (print_scop_params, debug_scop_params): Declared.
2045 2009-07-07 Li Feng <nemokingdom@gmail.com>
2047 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-4.c: New.
2048 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-5.c: New.
2049 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-6.c: New.
2050 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-7.c: New.
2051 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-8.c: New.
2052 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-9.c: New.
2054 2009-07-07 Li Feng <nemokingdom@gmail.com>
2056 * graphite-clast-to-gimple.c (mark_loops_parallel): Dump information
2057 for dependency checking part.
2058 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-1.c: Add
2059 tests for dependency checking.
2060 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-2.c: Ditto.
2061 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-3.c: Ditto.
2062 * testsuite/gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: Add
2063 flag -fdump-tree-graphite-all for autopar testsuites.
2065 2009-07-06 Sebastian Pop <sebastian.pop@amd.com>
2067 * Makefile.in (tree-ssa-loop-manip.o): Depends on langhooks.h.
2068 * tree-parloops.c (rewrite_phi_with_iv, rewrite_all_phi_nodes_with_iv,
2069 canonicalize_loop_ivs): Moved...
2070 * tree-ssa-loop-manip.c: ... here. Include langhooks.h.
2072 2009-07-06 Sebastian Pop <sebastian.pop@amd.com>
2074 * tree-parloops.c (try_create_reduction_list): Pass an extra
2075 argument analyzed_reductions. Call analyze_reduction_list.
2076 (gen_parallel_loop): Do not call analyze_reduction_list.
2077 (parallelize_loops): Init and finalize analyzed_reductions.
2079 2009-07-06 Li Feng <nemokingdom@gmail.com>
2081 * testsuite/gcc.dg/graphite/graphite_autopar/graphite_autopar.exp:
2082 Added flag -fno-loop-strip-mine for autopar testcase.
2084 2009-07-04 Li Feng <nemokingdom@gmail.com>
2086 * graphite-dependences.c (graphite_carried_dependence_level_k): Use
2087 transformed scattering dimension instead of unmatch orignal when
2088 calling dependence_polyhedron.
2090 2009-06-30 Sebastian Pop <sebastian.pop@amd.com>
2092 * opts.c (decode_options): Enable flag_loop_strip_mine at -O2.
2094 2009-06-30 Sebastian Pop <sebastian.pop@amd.com>
2096 * graphite-poly.c (pbb_number_of_iterations): Check for returned
2097 value 1 from ppl_Pointset_Powerset_NNC_Polyhedron_maximize.
2099 2009-06-30 Sebastian Pop <sebastian.pop@amd.com>
2101 * graphite-blocking.c (pbb_strip_mine_profitable_p): New.
2102 (pbb_do_strip_mine): Call pbb_strip_mine_profitable_p.
2103 * graphite-poly.c (pbb_number_of_iterations): New.
2104 * graphite-poly.h (pbb_number_of_iterations): Declared.
2105 (pbb_iterator_dim, pbb_parameter_dim): New.
2107 2009-06-29 Sebastian Pop <sebastian.pop@amd.com>
2109 * graphite-clast-to-gimple.c (graphite_create_new_loop): Revert the
2110 last commit on type of lower and upper bound of loops.
2112 2009-06-29 Li Feng <nemokingdom@gmail.com>
2114 * Makefile.in (graphite-clast-to-gimple.o): Added dependence on
2115 graphite-dependences.h.
2116 * graphite-clast-to-gimple.c (new_bb_pbb_def): New.
2117 (mark_bb_with_pbb): New.
2118 (get_stmtfor_depth): New.
2119 (find_pbb_via_hash): New.
2120 (dependency_in_loop_p): New.
2121 (mark_loops_parallel): New.
2122 (free_aux_in_new_loops): New.
2123 (translate_clast): Add parameter BB_PBB_MAPPING. Mark newly created
2124 bb with it's relevant pbb. Mark newly created loops. Remove mark
2125 innermost loop parallel without checking.
2126 (gloog): Add parameter BB_PBB_MAPPING.
2127 * graphite-clast-to-gimple.h (struct bb_pbb_def): New.
2128 (gloog): Change declaration.
2129 (mark_loop_parallel): Make extern.
2130 (free_aux_in_new_loops): Declare.
2131 (bb_pbb_map_hash): New.
2132 (eq_bb_pbb_map): New.
2133 * graphite.c (graphite_transform_loops): Added BB_PBB_MAPPING. Trigger
2134 auto parallelization when flag_graphite_force_parallel is set.
2135 (graphite_finalize): Added free_aux_in_new_loops.
2136 * tree-parloops.c (parallelize_loops): Only generate parallel code for
2137 the innermost loop that marked parallel. Use
2138 flag_graphite_force_parallel instead of loop->can_be_parallel.
2139 (loop_parallel_p): Move inner most checking out of function.
2141 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2143 * graphite-clast-to-gimple.c (graphite_create_new_loop): Make the
2144 type of lower and upper bound of loops signed long int.
2146 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2148 * cfgloopmanip.c (create_empty_loop_on_edge): Gimplify the loop exit
2149 expression outside the loop.
2151 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2153 * gcc.dg/graphite/interchange-8.c: New.
2155 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2157 * gcc.dg/graphite/interchange-0.c: XFailed.
2158 * gcc.dg/graphite/interchange-5.c: XFailed.
2159 * gcc.dg/graphite/interchange-6.c: XFailed.
2161 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2163 * graphite-interchange.c (compute_array_size_poly): The end of the
2164 recursion should return 1.
2166 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2168 * graphite-interchange.c (compute_array_size_cstr): Allow the
2169 subscript multiplier to be -1.
2170 (compute_array_size): Use PDR_DATA_CONTAINER and not PDR_ACCESSES.
2171 * graphite-poly.c (new_poly_dr): Takes an extra argument for the
2172 data_container. Initializes PDR_DATA_CONTAINER.
2173 (print_pdr_access_layout): New.
2174 (print_pdr): Call print_pdr_access_layout. Print PDR_DATA_CONTAINER.
2175 * graphite-poly.h (struct poly_dr): Adjust comment. Add a new field
2177 (PDR_DATA_CONTAINER): New.
2178 (new_poly_dr): Update declaration.
2179 * graphite-sese-to-poly.c (pdr_add_data_dimensions): New.
2180 (build_poly_dr): Call pdr_add_data_dimensions.
2182 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2184 * graphite-poly.h (struct poly_dr): Fix comment.
2185 * graphite-sese-to-poly.c (pdr_add_alias_set): New.
2186 (pdr_add_memory_accesses): New.
2187 (build_poly_dr): Call pdr_add_memory_accesses and pdr_add_alias_set.
2189 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2191 * graphite-poly.c (print_pdrs, debug_pdrs): New.
2192 (print_pbb): Add call to print_pdrs.
2193 * graphite-poly.h (print_pdrs, debug_pdrs): Declared.
2195 2009-06-24 Konrad Trifunovic <konrad.trifunovic@gmail.com>
2196 Li Feng <nemokingdom@gmail.com>
2198 * graphite-dependences.c (graphite_carried_dependence_level_k): New.
2199 (dependency_between_pbbs_p): New.
2200 (lexicographically_gt_p): Assure !empty_p before polyhedron
2201 intersection assign.
2202 (build_lexicographically_gt_constraint): Correct lexicographically
2204 * graphite-dependences.h: New.
2205 * Makefile.in (graphite-dependences.o): Add graphite-dependences.h.
2207 2009-06-24 Sebastian Pop <sebastian.pop@amd.com>
2209 * graphite-clast-to-gimple.c (print_clast_stmt): New.
2210 (gloog): Print to dump_file the generated clast.
2211 * graphite-clast-to-gimple.h (print_clast_stmt): Declared.
2212 * graphite-interchange.c (pbb_do_interchange): Fix dump formatting.
2214 2009-06-24 Sebastian Pop <sebastian.pop@amd.com>
2216 * graphite-poly.c (extend_scattering): Increment
2217 PBB_NB_LOCAL_VARIABLES by the number of added dimensions.
2219 2009-06-24 Sebastian Pop <sebastian.pop@amd.com>
2221 * graphite-interchange.c (compute_array_size_poly): Added exit of
2222 recursion condition. Continue iterating even after the first equality.
2223 (compute_array_size): Same.
2225 2009-06-24 Li Feng <nemokingdom@gmail.com>
2227 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-1.c: Update
2228 -fdump-tree-final_cleanup to -fdump-tree-optimized.
2229 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-2.c: Ditto.
2230 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-3.c: Ditto.
2231 * testsuite/gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: Ditto.
2233 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2235 * sese.c (expand_scalar_variables_stmt): Expand scalar variables
2236 only when the use verifies is_gimple_reg.
2238 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2240 * graphite-clast-to-gimple.c (build_cloog_prog): Fix memory corruption.
2241 Allocate scaldims after call to unify_scattering_dimensions.
2243 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2245 * graphite-clast-to-gimple.c (translate_clast): Fix memory leak.
2247 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2248 Albert Cohen <albert.cohen@inria.fr>
2250 * graphite-blocking.c (pbb_strip_mine_loop_depth): Do not use local
2251 variables for the strip mining.
2253 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2254 Pranav Garg <pranav.garg2107@gmail.com>
2256 * Makefile.in (OBJS-common): Added graphite-blocking.o.
2257 (graphite-sese-to-poly.o): Moved down to be in lexicographical order.
2258 (graphite-blocking.o): New rule.
2259 (graphite-poly.o, graphite-ppl.o): Moved to be in lexicographical order.
2260 * graphite-blocking.c: New.
2261 * graphite-poly.c (apply_poly_transforms): Call scop_do_strip_mine for
2262 flag_loop_strip_mine.
2263 (psct_scattering_dim_for_loop_depth): New.
2264 * graphite-poly.h (scop_do_strip_mine): Declared.
2265 (psct_add_local_variable): Increment PBB_NB_LOCAL_VARIABLES.
2266 * tree-ssa-loop.c (gate_graphite_transforms): Do not fail when using
2267 flag_loop_strip_mine.
2269 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2271 * graphite-poly.c (extend_scattering): Avoid initializing and freeing
2272 a GMP value and a PPL coefficient at each iteration of a loop.
2274 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2276 * graphite-dependences.c (dependence_polyhedron): Do not use
2277 pbb_nb_scattering_dims anymore. Use pbb_nb_scattering_orig and
2278 pbb_nb_scattering_transform.
2279 (graphite_legal_transform_dr): Same.
2280 * graphite-poly.c (extend_scattering): Same.
2281 (unify_scattering_dimensions): Same.
2282 (print_scattering_function): Same.
2283 (new_poly_bb): Initialize PBB_NB_SCATTERING_TRANSFORM and
2284 PBB_NB_LOCAL_VARIABLES.
2285 * graphite-poly.h (pbb_nb_scattering): Removed declaration.
2286 (struct poly_bb): Added nb_local_variables and nb_scattering_transform.
2287 (PBB_NB_LOCAL_VARIABLES, PBB_NB_SCATTERING_TRANSFORM): New.
2288 (pbb_nb_scattering_orig, pbb_nb_scattering_transform): New.
2289 (pbb_nb_scattering_dims, pbb_nb_scattering): Removed.
2290 (pbb_nb_scattering_transform): New.
2291 (pbb_nb_local_vars): Return PBB_NB_LOCAL_VARIABLES.
2292 (psco_scattering_dim): Add assert on parameters.
2293 (psct_scattering_dim): Same.
2294 (psct_scattering_dim_for_loop_depth): Declared.
2295 (psct_local_var_dim): New.
2296 (psco_iterator_dim, psco_parameter_dim): Add assert on parameters.
2297 (psct_iterator_dim, psct_parameter_dim): Same. To maintain the
2298 correct layout, call pbb_nb_local_vars.
2299 (psct_add_local_variable, psct_add_scattering_dimension): New.
2300 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons):
2301 Initialize PBB_NB_SCATTERING_TRANSFORM.
2303 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2305 * graphite-ppl.c (set_inhomogeneous): Renamed ppl_set_inhomogeneous.
2306 (set_coef): Renamed ppl_set_coef.
2307 * graphite-ppl.h (ppl_set_inhomogeneous, ppl_set_coef): Declared.
2309 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2311 * graphite-dependences.c (build_pairwise_scheduling_inequality): Don't
2312 test a boolean against 1.
2313 * graphite-interchange.c (pbb_interchange_loop_depths): Do not build
2314 a new polyhedron for the PBB_TRANSFORMED_SCATTERING.
2315 (pbb_do_interchange): Returns true when a transform has been performed.
2316 (scop_do_interchange): Same.
2317 * graphite-poly.c (apply_poly_transforms): Use the return value of
2318 scop_do_interchange.
2319 * graphite-poly.h (scop_do_interchange): Update declaration.
2321 2009-06-23 Tobias Grosser <grosser@fim.uni-passau.de>
2323 * graphite-clast-to-gimple.c (gloog): Reset loop->aux right
2325 * sese.c (sese_reset_aux_in_loops): New.
2326 * sese.h (sese_reset_aux_in_loops): New.
2328 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
2330 * graphite-sese-to-poly.c (scan_tree_for_params_int): Pass in the
2331 multiplier and multiply the constant by the multiplier.
2332 (scan_tree_for_params): Bound the multiplier to its MULT_EXPR.
2333 (build_poly_dr): Do not use the multiplier to define the subscript.
2335 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
2337 * graphite-poly.c (new_poly_dr): Pass an extra argument for the
2338 compiler's data reference. Initialize PDR_CDR.
2339 (print_pdr): Call dump_data_reference.
2340 * graphite-poly.h (struct poly_dr): Rename black_box into pbb.
2341 Add compiler_dr field.
2342 (PDR_BB): Renamed PDR_PBB.
2344 * graphite-sese-to-poly.c (build_poly_dr): Pass to new_poly_dr
2345 GCC's data reference representation.
2346 * tree-data-ref.c (debug_data_references, debug_data_reference): New.
2347 * tree-data-ref.h (debug_data_references, debug_data_reference): Decl.
2349 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
2351 * graphite-poly.c (print_scattering_function): Also print the layout.
2352 * graphite-poly.h (pbb_nb_local_vars): New.
2354 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
2356 * graphite-poly.c (print_pbb_domain): Also print the layout names.
2358 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
2360 * graphite-poly.c (print_pdr, debug_pdr): New.
2361 * graphite-poly.h (print_pdr, debug_pdr): Declared.
2362 (PDR_BASE): Removed.
2364 2009-06-18 Sebastian Pop <sebastian.pop@amd.com>
2366 * gcc/testsuite/gcc.dg/graphite/interchange-{1..7}.c: New avatars of
2369 2009-06-18 Sebastian Pop <sebastian.pop@amd.com>
2371 * graphite-interchange.c (compute_subscript): Allow also -1 in the
2372 subscript identification column.
2373 (pbb_do_interchange): Print to dump_file that some loops "will be
2374 interchanged". Rely on that chain of characters in the testcases.
2375 * gcc.dg/graphite/interchange-0.c: New.
2376 * gcc.dg/graphite/graphite.exp: Iterate over the testsuite
2377 interchange-*.c files and compile them with -floop-interchange.
2379 2009-06-18 Pranav Garg <pranav.garg2107@gmail.com>
2381 * graphite-interchange.c (interchange_profitable_p): Renamed
2382 pbb_interchange_profitable_p.
2384 2009-06-18 Sebastian Pop <sebastian.pop@amd.com>
2385 Harsha Jagasia <harsha.jagasia@amd.com>
2386 Pranav Garg <pranav.garg2107@gmail.com>
2388 * graphite-interchange.c (interchange_profitable_p): Make static.
2389 (pbb_interchange_loop_depths, pbb_do_interchange,
2390 scop_do_interchange): New.
2391 * graphite-poly.c (apply_poly_transforms): Call scop_do_interchange
2392 for flag_loop_interchange.
2393 * graphite-poly.h (scop_do_interchange): Declared.
2394 * tree-ssa-loop.c (gate_graphite_transforms): Do not fail when
2395 flag_loop_interchange is used.
2397 2009-06-18 Sebastian Pop <sebastian.pop@amd.com>
2399 * graphite-dependences.c (dependence_polyhedron): Update use of
2400 pbb_nb_scattering_dims.
2401 * graphite-poly.h (pbb_nb_scattering_dims): Do not pass SCOP.
2402 (pbb_nb_scattering): Update use of pbb_nb_scattering_dims.
2403 (psco_scattering_dim, psct_scattering_dim, psco_iterator_dim,
2404 psct_iterator_dim, psco_parameter_dim, psct_parameter_dim): New.
2406 2009-06-16 Sebastian Pop <sebastian.pop@amd.com>
2408 * graphite.c: Cleanup foo.
2410 2009-06-16 Sebastian Pop <sebastian.pop@amd.com>
2412 * Merge from mainline (r143684:148293).
2413 * Disabled libpcp until it gets fixed.
2415 2009-06-05 Sebastian Pop <sebastian.pop@amd.com>
2416 Harsha Jagasia <harsha.jagasia@amd.com>
2418 * graphite-interchange.c: New.
2419 * Makefile.in (graphite-interchange.o): New.
2420 * graphite-poly.h (interchange_profitable_p): Declared.
2421 * graphite-ppl.h (value_max): New.
2423 2009-06-04 Sebastian Pop <sebastian.pop@amd.com>
2425 * graphite-dependences.c (dependence_polyhedron): Use pdr_dim.
2426 * graphite-poly.h: Fix some comments.
2430 2009-06-04 Sebastian Pop <sebastian.pop@amd.com>
2433 (pdr_accessp_nb_subscripts): Renamed pdr_nb_subscripts.
2434 (pdr_accessp_nb_iterators): Renamed pdr_dim_iter_domain.
2435 (pdr_accessp_nb_params): Renamed pdr_nb_params.
2436 (pdr_accessp_alias_set_dim): Renamed pdr_alias_set_dim.
2437 (pdr_accessp_subscript_dim): Renamed pdr_subscript_dim.
2438 (pdr_accessp_iterator_dim): Renamed pdr_iterator_dim.
2439 (pdr_accessp_param_dim): Renamed pdr_parameter_dim.
2440 (pbb_nb_loops): Renamed pbb_dim_iter_domain.
2441 * graphite-clast-to-gimple.c: Same.
2442 * graphite-dependences.c: Same.
2443 * graphite-poly.c: Same.
2444 * graphite-sese-to-poly.c: Same.
2446 2009-06-03 Sebastian Pop <sebastian.pop@amd.com>
2448 * graphite-clast-to-gimple.c (build_iv_mapping): Insert full
2449 expressions for an IV rename, as returned by clast_to_gcc_expression.
2450 (copy_renames): Rename new_name to expr.
2451 * sese.c (debug_rename_elt): Same.
2454 (sese_adjust_liveout_phis): Call force_gimple_operand before using
2455 the information from the rename map.
2456 (rename_variables_in_stmt): Same.
2457 (add_loop_exit_phis): Rename new_name to expr.
2458 (insert_loop_close_phis): Same.
2459 (add_guard_exit_phis): Same. Call force_gimple_operand.
2460 * sese.h (struct rename_map_elt): Rename new_name to expr.
2461 (new_rename_map_elt): Same.
2463 2009-06-03 Sebastian Pop <sebastian.pop@amd.com>
2465 * graphite-clast-to-gimple.c (build_iv_mapping): Use set_rename.
2466 * sese.c (set_rename): Make it extern.
2467 * sese.h (set_rename): Declared.
2469 2009-06-03 Sebastian Pop <sebastian.pop@amd.com>
2471 * graphite-poly.c (extend_scattering): Free values.
2472 * graphite-ppl.c (new_Cloog_Domain_from_ppl_Pointset_Powerset):
2474 (ppl_print_powerset_matrix): Same.
2475 * graphite-scop-detection.c (free_scops_1): New.
2476 (limit_scops): Call free_scops_1.
2477 * graphite-sese-to-poly.c (build_scop_bbs_1): Free dom.
2478 (build_poly_dr): Free PPL coefficients.
2479 * tree-parloops.c (rewrite_all_phi_nodes_with_iv): Free bbs.
2481 2009-06-02 Sebastian Pop <sebastian.pop@amd.com>
2483 * graphite-dependences.c: New.
2484 * graphite-data-ref.c: Removed.
2485 * graphite-data-ref.h: Removed.
2486 * Makefile.in (graphite-data-ref.o): Removed.
2487 (graphite-dependences.o): Added.
2488 * graphite-clast-to-gimple.c: Remove dependence on graphite-data-ref.h.
2489 * graphite-poly.c: Same.
2490 Move the data dependence testing to graphite-dependences.c.
2492 2009-05-19 Tobias Grosser <grosser@fim.uni-passau.de>
2494 * graphite-scop-detection.c (graphite_can_represent_loop): Renamed
2495 from graphite_cannot_represent_loop. Code refactored.
2496 (scopdet_basic_block_info): Call graphite_can_represent_loop.
2498 2009-05-17 Li Feng <nemokingdom@gmail.com>
2500 * testsuite/gcc.dg/graphite/graphite_autopar/graphite_autopar.exp:
2501 Cover all the testcases (not only the filtered ones).
2503 2009-05-17 Tobias Grosser <grosser@fim.uni-passau.de>
2505 * graphite-scop-detection.c (stmt_simple_for_scop_p): Remove
2506 unnecessary check. Update comments. Move check for REAL_TYPE here.
2507 (harmful_stmt_in_bb): Remove checks for conditions. This is already
2508 done in (stmt_simple_for_scop_p).
2510 2009-05-14 Tobias Grosser <grosser@fim.uni-passau.de>
2512 * graphite.c (print_global_statistics): New.
2513 (print_graphite_scop_statistic): New.
2514 (print_graphite_statistics): New.
2515 (graphite_initialize, graphite_transform_loops): Print statistics.
2516 * graphite-scop-detection (build_scops): Print statistics.
2517 (print_graphite_scop_statistics): New.
2518 (print_graphite_statistics): New.
2520 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2522 * graphite-clast-to-gimple.c (struct clast_name_index): Removed.
2523 (debug_clast_name_index): Removed.
2524 (debug_clast_name_indexes_1): Removed.
2525 (debug_clast_name_indexes): Removed.
2526 (clast_name_index_elt_info): Removed.
2527 (eq_clast_name_indexes): Removed.
2528 (clast_name_to_index): Removed.
2529 (new_clast_name_index): Removed.
2530 (save_clast_name_index): Removed.
2531 (save_var_name): Moved...
2532 (init_sese_params_index): Removed.
2533 (clast_name_to_gcc): Remove use of name_tree.
2534 (initialize_cloog_names): Same.
2535 (gloog): Do not call init_sese_params_index.
2536 * graphite-sese-to-poly.c (save_var_name): ...here.
2537 (parameter_index_in_region): New.
2538 * sese.c (new_sese): Initialize SESE_PARAMS_NAMES.
2539 (parameter_index_in_region): Removed.
2540 (is_parameter): Remove use of name_tree.
2541 * sese.h (struct name_tree): Removed.
2542 (struct sese): Remove use of name_tree. New field params_names.
2543 (SESE_PARAMS_NAMES): New.
2544 (SESE_PARAMS): Remove duplicate.
2545 (parameter_index_in_region): Removed.
2546 (sese_nb_params): Remove use of name_tree.
2547 (struct clast_name_index): New.
2548 (new_clast_name_index): New.
2549 (clast_name_to_index): New.
2550 (save_clast_name_index): New.
2551 (debug_clast_name_index): New.
2552 (debug_clast_name_indexes_1): New.
2553 (debug_clast_name_indexes): New.
2554 (clast_name_index_elt_info): New.
2555 (eq_clast_name_indexes): New.
2557 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2559 * graphite-clast-to-gimple.c (compute_cloog_iv_types_1): Call
2560 pbb_to_depth_to_oldiv. Remove call to oldiv_for_loop.
2561 (graphite_loop_normal_form): Do not pass region. Do not
2562 initialize SESE_OLDIVS.
2563 (build_graphite_loop_normal_form): Update call to
2564 graphite_loop_normal_form.
2565 * sese.c (debug_oldivs): Removed.
2566 (new_sese): Do not initialize SESE_OLDIVS.
2567 (free_sese): Do not free SESE_OLDIVS.
2568 (oldiv_for_loop): Removed.
2569 * sese.h (struct sese): Remove old_ivs.
2570 (SESE_OLDIVS): Removed.
2571 (oldiv_for_loop): Removed.
2573 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2575 * graphite-clast-to-gimple.c (clast_name_to_gcc): Pass newivs,
2576 remove ivstack. Remove call to loop_iv_stack_get_iv_from_name,
2577 replaced by a call to newivs_to_depth_to_newiv.
2578 (clast_to_gcc_expression): Pass newivs, remove ivstack.
2579 (clast_to_gcc_expression_red): Same.
2580 (gcc_type_for_clast_expr): Same.
2581 (gcc_type_for_clast_eq): Same.
2582 (graphite_translate_clast_equation): Same.
2583 (graphite_create_guard_cond_expr): Same.
2584 (graphite_create_new_guard): Same.
2585 (graphite_create_new_loop): Same.
2586 (build_iv_mapping): Same.
2587 (translate_clast): Same.
2589 (loop_iv_stack_patch_for_consts): Removed. *
2590 sese.c (iv_stack_entry_is_constant): Removed.
2591 (iv_stack_entry_is_iv): Removed.
2592 (loop_iv_stack_push_iv): Removed.
2593 (loop_iv_stack_insert_constant): Removed.
2594 (loop_iv_stack_pop): Removed.
2595 (loop_iv_stack_get_iv): Removed.
2596 (loop_iv_stack_get_iv_from_name): Removed.
2597 (debug_loop_iv_stack): Removed.
2598 (free_loop_iv_stack): Removed.
2599 (loop_iv_stack_remove_constants): Removed. *
2600 sese.h (iv_stack_entry_kind): Removed.
2601 (iv_stack_entry_data_union): Removed.
2602 (iv_stack_entry_struct): Removed.
2603 (iv_stack_entry_p): Removed.
2604 (debug_oldivs, debug_loop_iv_stack, loop_iv_stack_insert_constant,
2605 loop_iv_stack_get_iv_from_name, loop_iv_stack_push_iv,
2606 loop_iv_stack_get_iv, loop_iv_stack_remove_constants,
2607 loop_iv_stack_pop, free_loop_iv_stack): Removed.
2608 (gbb_loop_at_index): Fix indenting.
2609 (gbb_loop_index): Removed.
2611 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2613 * graphite-clast-to-gimple.c (clast_name_to_gcc): Do not use strcmp.
2614 Call clast_name_to_index.
2616 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2618 * graphite-clast-to-gimple.c (clast_name_to_gcc): Pass region,
2619 do not pass params. Get params from SESE_PARAMS.
2620 (clast_to_gcc_expression): Same.
2621 (clast_to_gcc_expression_red): Same.
2622 (gcc_type_for_clast_eq): Same.
2623 (graphite_translate_clast_equation): Same.
2624 (graphite_create_new_loop): Same.
2625 * sese.c (rename_variables_in_stmt): Fix comment.
2627 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2629 * graphite-clast-to-gimple.c (graphite_create_new_loop): Pass
2631 Call save_clast_name_index.
2632 (translate_clast): Pass newivs_index.
2633 (gloog): Create and free newivs_index.
2635 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2637 * graphite-clast-to-gimple.c (clast_name_index): New structure.
2638 (clast_name_index_p): New type.
2639 (debug_clast_name_index): New.
2640 (debug_clast_name_indexes_1): New.
2641 (debug_clast_name_indexes): New.
2642 (clast_name_index_elt_info): New.
2643 (eq_clast_name_indexes): New.
2644 (clast_name_to_index): New.
2645 (new_clast_name_index): New.
2646 (save_clast_name_index): New.
2647 (init_sese_params_index): New.
2648 (gloog): Call init_sese_params_index.
2649 * graphite-clast-to-gimple.h (debug_clast_name_indexes): Declared.
2650 * sese.c (new_sese): Initialize SESE_PARAMS_INDEX.
2651 (free_sese): Free SESE_PARAMS_INDEX.
2652 * sese.h (struct sese): Add params_index.
2653 (SESE_PARAMS_INDEX): New.
2655 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2657 * graphite-clast-to-gimple.c (newivs_to_depth_to_newiv): New.
2658 (graphite_create_new_loop): Pass the newivs vector. Push the
2659 newly created IV to newivs.
2660 (translate_clast): Pass the newivs vector.
2661 (gloog): Create and destroy the newivs vector.
2663 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2665 * graphite-clast-to-gimple.c (pbb_to_depth_to_oldiv): New.
2666 (graphite_loop_normal_form): Initialize loop->aux with the unique
2667 IV that has been created.
2669 2009-05-13 Tobias Grosser <grosser@fim.uni-passau.de>
2671 * tree-chrec.c (evolution_function_right_is_integer_cst): Allow
2672 scev with parameters in the base part. They where forbidden
2675 2009-05-11 Li Feng <nemokingdom@gmail.com>
2677 * testsuite/gcc.dg/graphite/graphite.exp: Set different default
2678 compile options by file names.
2679 * testsuite/gcc.dg/graphite/block{0-6}.c: Remove dg-option line.
2680 * testsuite/gcc.dg/graphite/id-{1-9}.c: Ditto.
2681 * testsuite/gcc.dg/graphite/scop-{0-20}.c: Ditto.
2682 * testsuite/gcc.dg/graphite/scop-matmult.c: Ditto.
2684 2009-05-08 Li Feng <nemokingdom@gmail.com>
2686 * testsuite/gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: New.
2687 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-1.c: New.
2688 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-2.c: New.
2689 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-3.c: New.
2691 2009-05-07 Tobias Grosser <grosser@fim.uni-passau.de>
2693 * graphite-scop-detection (build_scops_1): Fix little bug introduced
2696 2009-05-07 Tobias Grosser <grosser@fim.uni-passau.de>
2698 * graphite-scop-detection.c (graphite_can_represent_scev): Only
2699 allow integer constant strides.
2700 (graphite_can_represent_expr): Depend on outermost_loop.
2701 (stmt_simple_memref_p, graphite_cannot_represent_loop,
2702 harmful_stmt_in_bb, is_simple_operand, stmt_simple_for_scop_p,
2703 build_scops_1): Same.
2704 (scopdet_basic_block_info): Same and insert layered SCoP
2706 (try_generate_gimple_bb): Cleanup.
2707 (build_scops): Enable data references.
2709 * testsuite/gcc.dg/graphite/id-5.c: New.
2710 * testsuite/gcc.dg/graphite/id-9.c: New.
2711 * tree-chrec.c (evolution_function_right_is_integer_cst): New.
2712 * tree-chrec.h (evolution_function_right_is_integer_cst): New.
2714 2009-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
2716 * sese.c (expand_scalar_variables_ssa_name): Only build expressions,
2717 that we have not yet built for this SCoP.
2719 2009-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
2721 * sese.c (expand_scalar_variables_expr): Fix expand_scalar_variables
2722 for complex numbers.
2724 2009-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
2726 * graphite-ppl.c: Fix build if cloog is not available.
2728 2009-05-04 Li Feng <nemokingdom@gmail.com>
2730 * tree-parloops.c (loop_parallel_p): Remove construction of
2731 NITER and REDUCTION_LIST.
2732 (try_get_loop_niter): New.
2733 (try_create_reduction_list): New.
2734 (parallelize_loops): Bypass the failed checkings in autopar
2735 when can_be_parallel in loop structure is set to true.
2737 2009-05-01 Tobias Grosser <grosser@fim.uni-passau.de>
2739 * testsuite/gcc.dg/graphite/id-6.c: Update testcase.
2740 * testsuite/gcc.dg/graphite/scop-3.c: Dito.
2742 2009-05-01 Tobias Grosser <grosser@fim.uni-passau.de>
2744 * graphite-scop-detection.c (stmt_simple_for_scop_p):
2745 Enable EQ_EXPR and NE_EXPR again.
2747 2009-04-30 Tobias Grosser <grosser@fim.uni-passau.de>
2749 * graphite-scop-detection.c (graphite_can_represent_scev):
2750 Add check if scev is affine multivariate.
2751 (harmful_stmt_in_bb): Check if we can represent the conditions.
2752 (scopdet_basic_block_info (basic_block bb, VEC): Pass the loop to
2754 * testsuite/gcc.dg/graphite/id-7.c: New.
2756 2009-04-30 Tobias Grosser <grosser@fim.uni-passau.de>
2758 * graphite-sese-to-poly.c (bb_contains_non_iv_scalar_phi_nodes):
2759 Check all bbs in region, not only the bbs that are represented in
2761 (build_poly_scop): Add newline.
2762 * testsuite/gcc.dg/graphite/id-8.c: New.
2764 2009-04-30 Li Feng <nemokingdom@gmail.com>
2766 * cfgloop.c (alloc_loop): Initialize can_be_parallel to false
2767 when loop initialize.
2768 * cfgloop.h (struct loop): Introduce flag can_be_parallel.
2769 * common.opt: Declare flag_graphite_force_parallel.
2770 * graphite-clast-to-gimple.c (translate_clast): Mark the innermost
2772 * graphite-poly.c (apply_poly_transforms): Introduce
2773 flag_graphite_force_parallel.
2774 * tree-ssa-loop.c (gate_graphite_transforms): ditto.
2775 * toplev.c (process_options): ditto and replace a not correctly
2778 2009-04-30 Li Feng <nemokingdom@gmail.com>
2780 * graphite-clast-to-gimple.c (loop_iv_stack_patch_for_consts):
2781 Change the call of gbb_loop_at_index and/or gbb_loop_index due
2782 to the redefinition.
2783 (compute_cloog_iv_types_1): ditto.
2784 (build_iv_mapping): ditto.
2785 * graphite-sese-to-poly.c (new_gimple_bb): Remove GBB_LOOPS related
2787 (free_gimple_bb): Removed GBB_LOOPS related free part.
2788 (build_bb_loops): Removed.
2789 * sese.h (struct gimple_bb): Removed loops.
2790 (GBB_LOOPS): Removed.
2791 (gbb_loop_at_index): Instead of using GBB_LOOPS, we use sese instead.
2792 (gbb_loop_index): ditto.
2794 2009-04-24 Tobias Grosser <grosser@fim.uni-passau.de>
2796 * graphite-scop-detection.c (graphite_can_represent_scev): Do not
2797 allow non constant strides.
2798 * testsuite/gcc.dg/graphite/scop-20.c: New.
2800 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
2802 * graphite-scop-detection.c (dot_all_scops): Fix system call
2803 return value warning.
2806 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
2808 * testsuite/gcc.dg/graphite/id-6.c: Fix pattern.
2809 * testsuite/gcc.dg/graphite/scop-3.c: Same.
2811 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
2813 * graphite-poly.c (map_into_dep_poly, map_dr_into_dep_poly,
2814 build_pairwise_constraint, dr_equality_constraints,
2815 build_pairwise_scheduling_equality,
2816 build_pairwise_scheduling_inequality, lexicographically_gt_p,
2817 build_lexicographically_gt_constraint, dependence_polyhedron,
2818 graphite_legal_transform_dr, graphite_legal_transform_bb,
2819 graphite_legal_transform): New.
2820 * graphite-poly.h (graphite_legal_transform): Declared.
2821 * graphite-sese-to-poly.c (build_poly_scop): Call to
2822 graphite_legal_transform is disabled for the moment.
2824 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
2826 * graphite-poly.h (pbb_nb_scattering_dims): New.
2827 (pbb_nb_scattering): Use it.
2829 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
2831 * graphite-ppl.c (ppl_insert_dimensions_pointset): Add
2832 Pointset_Powerset version of ppl_insert_dimensions.
2833 * graphite-ppl.h (ppl_insert_dimensions_pointset): Declared.
2835 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
2837 * graphite-ppl.c (ppl_insert_dimensions): Fix formatting.
2839 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
2841 * graphite-poly.h: Fix comment.
2843 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
2845 * graphite-sese-to-poly.c (build_poly_dr): Fix data ref multiplier.
2847 2009-04-24 Tobias Grosser <grosser@fim.uni-passau.de>
2849 * sese.c (expand_scalar_variables_stmt): Only iterate over the old
2852 2009-04-24 Tobias Grosser <grosser@fim.uni-passau.de>
2854 * graphite-sese-to-poly.c (var_used_in_not_loop_header_phi_node): New.
2855 (graphite_stmt_p): Represent bbs necessary to build the phi nodes of
2858 2009-04-20 Sebastian Pop <sebastian.pop@amd.com>
2860 * graphite-scop-detection.c (stmt_simple_for_scop_p): Do not
2861 handle EQ_EXPR and NE_EXPR.
2863 2009-04-17 Tobias Grosser <grosser@fim.uni-passau.de>
2865 * graphite-poly.h (poly_dr): Fix comment.
2867 2009-04-09 Sebastian Pop <sebastian.pop@amd.com>
2868 Tobias Grosser <grosser@fim.uni-passau.de>
2870 * graphite-poly.c (new_poly_bb): Do not initialize PBB_DOMAIN
2871 with a zero dimension polyhedron.
2872 (find_scop_parameters): Move the call to scop_set_nb_params here.
2873 (build_loop_iteration_domains): Store in loop->aux the iteration
2875 (build_scop_iteration_domain): Fix PBB_DOMAIN for bbs not surrounded
2876 by any loop in scop.
2877 (build_poly_scop): Do not call scop_set_nb_params.
2879 2009-04-09 Sebastian Pop <sebastian.pop@amd.com>
2880 Tobias Grosser <grosser@fim.uni-passau.de>
2882 * graphite-sese-to-poly.c (add_condition_to_pbb): Pass code to
2883 add_condition_to_domain not GT_EXPR.
2885 2009-04-09 Tobias Grosser <grosser@fim.uni-passau.de>
2887 * graphite-ppl.c (debug_ppl_powerset_matrix): New.
2888 * graphite-ppl.h (debug_ppl_powerset_matrix): New.
2889 * graphite-sese-to-poly.c (add_condition_to_pbb): Use
2890 upper_bound_assign to calculate unions.
2891 * testsuite/gcc.dg/graphite/id-6.c: New.
2893 2009-04-09 Tobias Grosser <grosser@fim.uni-passau.de>
2895 * graphite-scop-detection.c (canonicalize_loop_closed_ssa): Do not
2896 handle abnormal edges.
2898 2009-04-09 Tobias Grosser <grosser@fim.uni-passau.de>
2900 * graphite-poly.c (new_poly_dr, free_poly_dr): New.
2901 (free_poly_bb): Also free poly_drs.
2902 * graphite-poly.h (new_poly_dr, free_poly_dr): New.
2903 (poly_dr): Polyhedron to Pointset_Powerset.
2904 (pdr_accessp_nb_subscripts): Same.
2905 * graphite-sese-to-poly.c (build_poly_dr): Same. And actually build
2908 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
2910 * graphite-clast-to-gimple.c (initialize_cloog_names): Change cloog
2911 names into more meaningful names.
2913 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
2915 * testsuite/gfortran.dg/graphite/interchange-1.c: New.
2916 * testsuite/gfortran.dg/graphite/interchange-2.c: New.
2918 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
2920 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not build
2922 * tree-parloops.c (rewrite_phi_with_iv): New.
2923 (rewrite_all_phi_nodes_with_iv): New.
2924 (canonicalize_loop_ivs): Call them.
2926 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
2928 * graphite-sese-to-poly.c (try_generate_gimple_bb): Use
2929 graphite_find_data_references_in_stmt.
2930 * tree-data-ref.c (graphite_find_data_references_in_stmt): New.
2931 * tree-data-ref.h (graphite_find_data_references_in_stmt): Declared.
2933 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
2935 * sese.c (add_loop_exit_phis): Don't fail on non SSA_NAME renames.
2937 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
2939 * graphite-sese-to-poly.c (build_scop_bbs_1): Use bb_in_sese_p
2940 instead of bb_in_region.
2941 (flag_bb_in_region): Same. Renamed flag_bb_in_sese.
2942 (build_sese_conditions): Use flag_bb_in_sese.
2943 * sese.c (register_bb_in_sese): Removed.
2944 (new_sese): Remove initialization of SESE_REGION_BBS.
2945 (free_sese): Do not free SESE_REGION_BBS.
2946 * sese.h (struct sese): Remove field region_basic_blocks.
2947 (SESE_REGION_BBS): Removed.
2948 (bb_in_sese_p): Implement in function of bb_in_region.
2950 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
2952 * graphite-scop-detection.c (limit_scops): Deal only with single exit
2955 2009-04-08 Tobias Grosser <grosser@fim.uni-passau.de>
2957 * graphite-scop-detection.c (stmt_simple_for_scop_p): Allow NE_EXPR
2959 * graphite-sese-to-poly.c (create_linear_expr_from_tree): New.
2960 (add_condition_to_domain): New.
2961 (add_condition_to_pbb): New.
2962 (add_conditions_to_domain): Cleanup and handle of NE_EXPR and EQ_EXPR.
2963 * testsuite/gcc.dg/graphite/scop-3.c: Update number of detected SCoPs.
2965 2009-04-08 Tobias Grosser <grosser@fim.uni-passau.de>
2967 * graphite-clast-to-gimple.c (build_cloog_prog): ppl_Polyhedron ->
2968 ppl_Pointset_Powerset.
2969 * graphite-poly.c (new_poly_bb, free_poly_bb): Same.
2970 * graphite-poly.h (poly_bb): poly_bb.domain Same.
2971 (pbb_nb_loops): Same.
2972 * graphite-sese-to-poly.c (build_loop_iteration_domains,
2973 add_conditions_to_domain): Same.
2974 * graphite-ppl.c (new_Cloog_Domain_from_ppl_Pointset_Powerset): New.
2975 (ppl_print_polyhedron_matrix): ppl_Polyhedron_t ->
2976 ppl_const_Polyhedron_t.
2977 (ppl_print_powerset_matrix): New.
2978 * graphite-ppl.h (new_Cloog_Domain_from_ppl_Pointset_Powerset,
2979 ppl_print_powerset_matrix): New.
2980 (ppl_print_polyhedron_matrix): Updated.
2982 2009-04-07 Sebastian Pop <sebastian.pop@amd.com>
2984 * tree-scalar-evolution.c (analyze_scalar_evolution_1): Fix comment.
2986 2009-04-07 Sebastian Pop <sebastian.pop@amd.com>
2988 * graphite-poly.c (extend_scattering): Fix indenting. Free cstr.
2989 (print_iteration_domains, debug_iteration_domain,
2990 debug_iteration_domains): New.
2991 * graphite-poly.h (print_iteration_domains, debug_iteration_domain,
2992 debug_iteration_domains): Declared.
2993 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons): Fix
2996 2009-04-03 Tobias Grosser <grosser@fim.uni-passau.de>
2997 Sebastian Pop <sebastian.pop@amd.com>
2999 * graphite-poly.h (print_iteration_domain): New.
3000 * graphite-sese-to-poly.c (add_conditions_to_domain): Fixed bug.
3001 (build_sese_conditions_1, build_sese_conditions_after,
3002 build_sese_conditions_before): New.
3003 (build_sese_conditions): Rewritten.
3005 2009-04-03 Sebastian Pop <sebastian.pop@amd.com>
3006 Tobias Grosser <grosser@fim.uni-passau.de>
3008 Cleanup of code generation liveouts.
3009 * graphite-clast-to-gimple.c (translate_clast): Use a single
3010 rename_map instead of one per translated statement.
3011 Do not use SESE_LIVEOUT_RENAMES.
3012 (graphite_loop_normal_form): Do not use SESE_REDUCTION_LIST.
3013 (gloog): Do not use SESE_LIVEOUT_RENAMES.
3014 * graphite-scop-detection.c (harmful_stmt_in_bb): Return the close
3015 phi node of a reduction: when a loop contains a reduction used outside
3016 the loop, there should be a scalar close phi node on the exit block.
3017 * sese.c (new_sese): Do not initialize SESE_LIVEOUT,
3018 SESE_LIVEOUT_RENAMES, and SESE_REDUCTION_LIST.
3019 (free_sese): Do not free them.
3020 (sese_build_liveouts_use): Do not use them.
3021 (sese_build_liveouts_bb): Same.
3022 (sese_build_liveouts): Same.
3023 (sese_insert_phis_for_liveouts): Same.
3024 (sese_adjust_phis_for_liveouts): Same. Renamed sese_adjust_liveout_phis.
3025 (defined_in_loop_p): New.
3026 (alive_after_loop): New.
3027 (close_phi_not_yet_inserted_p): New.
3028 (struct alep, alep_p): New.
3029 (add_loop_exit_phis): Remove from the rename_map all the names defined
3030 in the code generated loop.
3031 (insert_loop_close_phis): Traverse the rename_map passed to it.
3032 Don't use SESE_LIVEOUT_RENAMES.
3033 (default_liveout_before_guard): Renamed default_before_guard.
3034 (insert_guard_phis): Do not use SESE_LIVEOUT_RENAMES.
3035 (graphite_copy_stmts_from_block): Do not directly call set_rename.
3036 (register_sese_liveout_renames): Removed.
3037 (copy_bb_and_scalar_dependences): Do not call it.
3038 * sese.h (struct sese): Removed fields: liveout, liveout_renames, and
3040 (SESE_LIVEOUT): Removed.
3041 (SESE_LIVEOUT_RENAMES): Removed.
3042 (SESE_REDUCTION_LIST): Removed.
3043 (sese_build_liveouts): Removed.
3044 (sese_adjust_phis_for_liveouts): Renamed sese_adjust_liveout_phis.
3045 (insert_loop_close_phis): Pass a htab_t instead of a sese.
3046 (insert_guard_phis): Same.
3047 (rename_map_elt): Declare a VEC of them.
3048 * tree-parloops.c (canonicalize_loop_ivs): reduction_list contains
3049 trees not pointers to trees.
3051 Rewrite in canonical close SSA form:
3052 * graphite-scop-detection.c (contains_only_close_phi_nodes): New.
3053 (limit_scops): Close the scop after the block containing the close phi
3055 (canonicalize_loop_closed_ssa): New.
3056 (canonicalize_loop_closed_ssa_form): New.
3057 (build_scops): Call canonicalize_loop_closed_ssa_form.
3059 * graphite-sese-to-poly.c: Fix typos.
3061 2009-04-03 Sebastian Pop <sebastian.pop@amd.com>
3063 * graphite-poly.c (print_scattering_function, print_pbb_domain):
3065 (dump_gbb_conditions, dump_gbb_cases, print_iteration_domain): New.
3066 (print_pbb): Add conditions.
3068 2009-04-01 Tobias Grosser <grosser@fim.uni-passau.de>
3069 Sebastian Pop <sebastian.pop@amd.com>
3071 * graphite-scop-detection.c (bb_in_sd_region): Use bb_in_region.
3072 * graphite-sese-to-poly.c (all_non_dominated_preds_marked_p): New.
3073 (build_scop_bbs_1): New.
3074 (build_scop_bbs): Rewrite.
3075 * sese.h (bb_in_region): New.
3077 2009-03-29 Tobias Grosser <grosser@fim.uni-passau.de>
3079 * graphite-poly.c (new_poly_bb, free_poly_bb): Initialize/free
3081 (print_scop): Style.
3082 * graphite-poly.h (poly_bb): Add drs vector.
3083 (PBB_DRS): Add accessor.
3084 * graphite-sese-to-poly.c (build_poly_dr): New.
3085 (build_pbb_drs, build_scop_drs): New.
3086 (build_poly_scop): call build_scop_drs (Disabled at the moment).
3088 2009-03-29 Tobias Grosser <grosser@fim.uni-passau.de>
3090 * tree-ssa-loop.c: Include forgotten toplev.h
3092 2009-03-29 Tobias Grosser <grosser@fim.uni-passau.de>
3094 * graphite-poly.c: (apply_poly_transforms): sorry -> gcc_unreachable.
3095 * testsuite/gcc.dg/graphite/pr37883.c: Remove -floop-*
3096 * testsuite/gcc.dg/graphite/pr37928.c: Same
3097 * testsuite/gcc.dg/graphite/pr38409.c: Same
3098 * testsuite/gcc.dg/graphite/pr38498.c: Same
3099 * testsuite/gcc.dg/graphite/pr38559.c: Same
3100 * testsuite/gcc.dg/graphite/pr39335.c: Same
3101 * testsuite/gcc.dg/graphite/pr39335_1.c: Same
3102 * testsuite/gfortran.dg/graphite/block-2.f: Same
3103 * tree-ssa-loop.c (gate_graphite_transforms): Always fail if called
3106 2009-03-28 Tobias Grosser <grosser@fim.uni-passau.de>
3108 * graphite-sese-to-poly.c (ref_nb_loops, build_access_matrix_with_af,
3109 build_access_matrix, build_scop_data_accesses): Remove access function
3110 building. (We get a new version soon).
3111 (build_bb_loops, scan_tree_for_params_right_scev): Update.
3112 * sese.h (nb_loops_around_loop_in_sese): Remove.
3113 (sese_loop_depth): Do not use SESE_LOOP_NEST any more.
3115 2009-03-27 Tobias Grosser <grosser@fim.uni-passau.de>
3116 Sebastian Pop <sebastian.pop@amd.com>
3118 * graphite-scop-detection.c (struct scopdet_info): Rename last
3120 (scopdet_basic_block_info, build_scops_1): Don't use
3121 CDI_POST_DOMINATORS. CDI_POST_DOMINATORS should never be used.
3123 2009-03-26 Tobias Grosser <grosser@fim.uni-passau.de>
3124 Sebastian Pop <sebastian.pop@amd.com>
3126 * graphite-clast-to-gimple.c (gloog): Call sese_build_liveouts.
3127 * sese.c (sese_build_liveouts_use): Renamed from
3128 sese_build_livein_liveouts_use. Remove liveins.
3129 (sese_build_liveouts_bb): Renamed from sese_build_livein_liveouts_bb.
3130 Call sese_build_liveouts_use.
3131 (sese_build_liveouts): Renamed from sese_build_livein_liveouts.
3132 Call sese_build_liveouts_bb.
3133 (new_sese, free_sese): Remove liveins.
3134 (sese_add_exit_phis_var): Deleted.
3135 (sese_insert_phis_for_liveouts): Call sese_add_exit_phis_edge
3137 (graphite_copy_stmts_from_block): Remove SESE_NUM_VER.
3139 * sese.h (sese): Remove num_ver and livein.
3140 (SESE_LIVEIN, SESE_LIVEIN_VER, SESE_NUM_VER): Removed.
3142 2009-03-25 Tobias Grosser <grosser@fim.uni-passau.de>
3144 * graphite-sese-to-poly.c (build_scop_scattering): Fix compile.
3146 2009-03-25 Tobias Grosser <grosser@fim.uni-passau.de>
3148 * graphite-sese-to-poly.c (compare_prefix_loops): Removed.
3149 (build_scop_scattering): Do not use compare_prefix_loops any more.
3150 (nb_common_loops): New.
3152 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
3154 * sese.c (get_new_name_from_old_name): Renamed get_rename.
3155 (register_old_and_new_names): Renamed set_rename.
3157 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
3159 * graphite-scop-detection.h (nb_reductions_in_loop): Revert removal
3160 of the decl from the previous commit.
3162 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
3164 * graphite-scop-detection.c (dot_scop): New.
3165 * graphite-scop-detection.h (dot_scop): Declared.
3167 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
3169 * graphite-sese-to-poly.c (compare_prefix_loops): Fix compare.
3171 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
3173 * cfgloopmanip.c (create_empty_loop_on_edge): Generate the loop exit
3174 condition at the end of the loop.
3175 * graphite.c (graphite_initialize, graphite_finalize): Print to
3176 dump_file the compiled function.
3177 * graphite-clast-to-gimple.c (graphite_create_new_loop): Update use
3178 of create_empty_loop_on_edge.
3179 (translate_clast): Update the code generation of loops for the new
3181 * cfgloop.h (create_empty_loop_on_edge): Update declaration.
3183 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
3185 Reverted the patch from 2009-03-19.
3187 2009-03-19 Tobias Grosser <grosser@fim.uni-passau.de>
3189 * graphite-poly.c (new_poly_bb, free_poly_bb): Initialize/free
3191 (print_scop): Style.
3192 * graphite-poly.h (poly_bb): Add drs vector.
3193 (PBB_DRS): Add accessor.
3194 * graphite-sese-to-poly.c (ref_nb_loops): Remove.
3195 (build_access_matrix_with_af, build_access_matrix,
3196 build_scop_data_accesses): Delete.
3197 (build_poly_dr): New.
3198 (build_pbb_drs, build_scop_drs): New.
3199 (build_poly_scop): call build_scop_drs.
3201 2009-03-13 Sebastian Pop <sebastian.pop@amd.com>
3203 * graphite-scop-detection.c (dot_all_scops_1): Close the table
3204 once per basic block.
3206 2009-03-13 Tobias Grosser <grosser@fim.uni-passau.de>
3208 * graphite-scop-detection.c (graphite_can_represent_scev): New.
3209 (graphite_can_represent_expr): Renamed from loop_affine_expr
3211 (stmt_simple_for_scop_p): Call graphite_can_represent_expr.
3212 (graphite_cannot_represent_loop): Add scop_entry to parameters.
3213 (scopdet_basic_block_info): Actually define entry_block.
3214 (stmt_simple_memref_p): Moved here from ...
3216 * tree-data-ref.c (stmt_simple_memref_p): here.
3217 * tree-data-ref.h (stmt_simple_memref_p): Removed.
3219 2009-03-13 Tobias Grosser <grosser@fim.uni-passau.de>
3221 * testsuite/gcc.dg/graphite/id-4.c: New.
3223 2009-03-12 Sebastian Pop <sebastian.pop@amd.com>
3225 * sese.c (expand_scalar_variables_expr): Handle tcc_comparison.
3226 (register_old_and_new_names): Update the content of the map.
3227 When there was already a rename_map_elt in the map at that
3229 (copy_bb_and_scalar_dependences): Do rename_variables after
3230 expand_scalar_variables.
3231 * graphite-clast-to-gimple.c (build_iv_mapping): Update the content
3232 of the map. When there was already a rename_map_elt in the
3233 map at that location, free it.
3234 (translate_clast): Pass the rename_map. Do not initialize and free
3235 a rename_map per stmt_user.
3236 (gloog): Initialize and free one rename_map and pass it to
3239 2009-03-12 Sebastian Pop <sebastian.pop@amd.com>
3241 * sese.c (expand_scalar_variables_stmt,
3242 expand_scalar_variables_ssa_name): Add a gimple_stmt_iterator
3244 (expand_scalar_variables_expr): Handle REALPART_EXPR and IMAGPART_EXPR.
3245 (expand_scalar_variables): Pass to expand_scalar_variables_stmt
3246 the gimple_stmt_iterator of the statement to be expanded.
3247 * graphite-scop-detection.c (is_simple_operand): Do handle
3250 2009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
3252 * graphite-scop-detection.c (is_simple_operand): Do not handle
3254 * testsuite/gcc.dg/graphite/id-2.c: New.
3256 * graphite-sese-to-poly.c (build_bb_loops,
3257 add_value_to_dim, scan_tree_for_params_right_scev,
3258 scan_tree_for_params_int, scan_tree_for_params, idx_record_params,
3259 find_params_in_bb, build_loop_iteration_domains,
3260 add_conditions_to_domain): Remove subtract.
3262 2009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
3264 * graphite-clast-to-gimple.c (loop_iv_stack_patch_for_consts,
3265 build_iv_mapping, compute_cloog_iv_types_1, build_cloog_prog):
3266 pbb_loop_at_index -> gbb_loop_at_index.
3267 * graphite-poly.c (new_poly_bb, new_scop): New accessors.
3268 (debug_loop_vec): Delete.
3269 * graphite-poly.h (poly_bb, scop): Change black_box and region to void
3270 pointer. Move LOOPS to gimple_bb_p and insert nb_params.
3271 (PBB_LOOPS): Removed.
3272 (PBB_BLACK_BOX): Insert cast.
3273 (pbb_set_black_box): New setter.
3274 (pbb_loop_at_index, pbb_loop_index): Removed.
3275 (scop_set_region, scop_set_nb_params): New.
3276 * graphite-sese-to-poly.c (new_gimple_bb, free_gimple_bb,
3277 build_scop_scattering, build_bb_loops): Add GBB_LOOPS.
3278 (build_poly_scop): Use scop_set_nb_params.
3279 * sese.h (gimple_bb): Add LOOPS.
3280 (GBB_LOOPS, gbb_loop_index, gbb_loop_at_index): New.
3282 2009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
3284 Revert previous commit.
3286 2009-03-11 Sebastian Pop <sebastian.pop@amd.com>
3288 * sese.c (expand_scalar_variables_expr): Handle tcc_comparison.
3289 (register_old_and_new_names): Update the content of the map.
3290 When there was already a rename_map_elt in the map at that
3292 (copy_bb_and_scalar_dependences): Do rename_variables after
3293 expand_scalar_variables.
3294 * graphite-clast-to-gimple.c (build_iv_mapping): Update the content
3295 of the map. When there was already a rename_map_elt in the
3296 map at that location, free it.
3297 (translate_clast): Pass the rename_map. Do not initialize and free
3298 a rename_map per stmt_user.
3299 (gloog): Initialize and free one rename_map and pass it to
3302 2009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
3304 Remove forgotten line in revert.
3306 2009-03-11 Sebastian Pop <sebastian.pop@amd.com>
3308 Revert previous commit.
3310 2009-03-10 Sebastian Pop <sebastian.pop@amd.com>
3312 * sese.c (register_old_and_new_names): Update the content
3313 of the map. When there was already a rename_map_elt in the
3314 map at that location, free it.
3315 (copy_bb_and_scalar_dependences): Do rename_variables after
3316 expand_scalar_variables.
3317 * graphite-clast-to-gimple.c (build_iv_mapping): Update the content
3318 of the map. When there was already a rename_map_elt in the
3319 map at that location, free it.
3320 (translate_clast): Pass the rename_map. Do not initialize and free
3321 a rename_map per stmt_user.
3322 (gloog): Initialize and free one rename_map and pass it to
3325 2009-03-10 Sebastian Pop <sebastian.pop@amd.com>
3327 * graphite-clast-to-gimple.c (translate_clast): context_loop
3330 2009-03-10 Tobias Grosser <grosser@fim.uni-passau.de>
3331 Sebastian Pop <sebastian.pop@amd.com>
3333 * graphite-ppl.c (ppl_insert_dimensions): Fix stupid mistake
3334 of the use of ppl_Polyhedron_map_space_dimensions.
3336 2009-03-10 Tobias Grosser <grosser@fim.uni-passau.de>
3337 Sebastian Pop <sebastian.pop@amd.com>
3339 * graphite-poly.c (unify_scattering_dimensions): Fix types.
3340 * graphite-poly.h (poly_dr_p, poly_dr, POLY_DR_TYPE, PDR_BB,
3341 PDR_TYPE, PDR_ACCESSES, pdr_accessp_nb_subscripts,
3342 pdr_accessp_nb_iterators, pdr_accessp_nb_params,
3343 pdr_accessp_alias_set_dim, pdr_accessp_subscript_dim,
3344 pdr_accessp_iterator_dim, pdr_accessp_param_dim,
3345 pbb_nb_params): New.
3346 (pbb_nb_loops, pbb_nb_scattering, scop_nb_params,
3347 nb_loops_around_pbb): Adapt return types.
3349 2009-03-09 Tobias Grosser <grosser@fim.uni-passau.de>
3351 * Makefile.in (graphite.o, graphite-sese-to-poly.o,
3352 graphite-clast-to-gimple.o, graphite-data-ref.o,
3353 graphite-scop-detection.o, graphite-poly.o): Add
3356 2009-03-05 Tobias Grosser <grosser@fim.uni-passau.de>
3358 * Makefile.in (graphite.o, graphite-sese-to-poly.o,
3359 graphite-clast-to-gimple.o, graphite-data-ref.o,
3360 graphite-scop-detection.o, graphite-poly.o): Add graphite-poly.h.
3362 2009-03-04 Tobias Grosser <grosser@fim.uni-passau.de>
3364 * testsuite/gcc.dg/graphite/pr37485.c: Remove -floop-block
3365 * testsuite/gcc.dg/graphite/pr37828.c: Same.
3366 * testsuite/gcc.dg/graphite/pr37684.c: Same.
3367 * testsuite/gcc.dg/graphite/block-0.c: Same.
3368 * testsuite/gcc.dg/graphite/block-1.c: Same.
3369 * testsuite/gcc.dg/graphite/block-2.c: Same.
3370 * testsuite/gcc.dg/graphite/block-3.c: Same.
3371 * testsuite/gcc.dg/graphite/block-4.c: Same.
3372 * testsuite/gcc.dg/graphite/block-5.c: Same.
3373 * testsuite/gcc.dg/graphite/block-6.c: Same.
3374 * testsuite/gfortran.dg/graphite/pr38083.f90: Same.
3375 * testsuite/gfortran.dg/graphite/block-1.f90: Same.
3376 * testsuite/gfortran.dg/graphite/block-3.f90: Same.
3377 * testsuite/gfortran.dg/graphite/pr37852.f90: Same.
3378 * testsuite/gfortran.dg/graphite/block-4.f90: Same.
3379 * testsuite/gfortran.dg/graphite/pr37980.f90: Same.
3380 * testsuite/gfortran.dg/graphite/pr38953.f90: Same.
3381 * testsuite/gfortran.dg/graphite/pr37857.f90: Same.
3382 * opts.c: Remove -floop-block from -O2.
3383 * graphite-poly.c: Fail if -floop-block -floop-interchange or
3384 -floop-strip-mine are used.
3386 2009-03-04 Tobias Grosser <grosser@fim.uni-passau.de>
3387 Sebastian Pop <sebastian.pop@amd.com>
3389 * graphite-clast-to-gimple.c (build_cloog_prog): Unify scattering
3391 * graphite-poly.c (pbb_compare, graphite_sort_pbbs,
3392 graphite_trans_bb_move_loop, graphite_trans_bb_strip_mine,
3393 strip_mine_profitable_p, is_interchange_valid,
3394 graphite_trans_bb_block, graphite_trans_loop_block,
3395 graphite_trans_scop_block): Temporary removed.
3396 (extend_scattering, unify_scattering_dimensions): New.
3397 (print_scattering_function, graphite_read_transforms):
3398 PBB_SCATTERING -> PBB_TRANSFORMED_SCATTERING.
3399 (graphite_generate_scattering_fns): Removed.
3400 (apply_poly_transforms): Cleanup.
3401 (free_poly_bb): Add PBB_SCATTERING -> PBB_TRANSFORMED_SCATTERING.
3402 (schedule_to_scattering): Moved.
3403 (PBB_STATIC_SCHEDULE, PBB_SCATTERING): Removed.
3404 (PBB_ORIGINAL_SCATTERING, PBB_TRANSFORMED_SCATTERING): New.
3405 (pbb_nb_scattering): New.
3406 (SCOP_ENTRY, SCOP_EXIT, SCOP_REGION_BBS, SCOP_DEP_GRAPH, SCOP_PARAMS,
3407 SCOP_LOOP_NEST, SCOP_PARAMS, SCOP_OLDIVS, SCOP_LIVEOUT_RENAMES):
3409 * graphite-ppl.c (ppl_insert_dimensions): Extended and renamed from
3411 (ppl_strip_loop): PBB_SCATTERING -> PBB_TRANSFORMED_SCATTERING.
3412 * graphite-scop-detection.c (dot_all_scops_1): PBB_SCATTERING
3413 -> PBB_TRANSFORMED_SCATTERING.
3414 * graphite-sese-to-poly.c (build_scop_bbs): Remove region.
3415 (build_pbb_scattering_polyhedron): Moved from schedule_to_scattering.
3416 (build_scop_scattering): Renamed from build_scop_canonical_schedules.
3417 (check_poly_representation): Do not return bool.
3418 (graphite_transform_loops): Reformat.
3419 * sese.h (SESE_ENTRY_BB, SESE_EXIT_BB): New.
3421 2009-03-04 Sebastian Pop <sebastian.pop@amd.com>
3423 * graphite-poly.c (print_pbb_domain, print_pbb, print_scop,
3424 debug_pbb_domain, debug_pbb, debug_scop): New.
3425 * graphite-poly.h (print_pbb_domain, print_pbb, print_scop,
3426 debug_pbb_domain, debug_pbb, debug_scop): Declared.
3428 2009-03-02 Sebastian Pop <sebastian.pop@amd.com>
3431 * tree-parloops.c (canonicalize_loop_ivs): Call fold_convert
3432 when the type precision of the induction variable should be
3433 larger than the type precision of nit.
3434 (gen_parallel_loop): Update use of canonicalize_loop_ivs.
3435 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Same.
3436 * tree-flow.h (canonicalize_loop_ivs): Update declaration.
3438 * testsuite/gcc.dg/graphite/pr39335_1.c: New.
3439 * testsuite/gcc.dg/graphite/pr39335.c: New.
3441 2009-03-02 Sebastian Pop <sebastian.pop@amd.com>
3443 * tree-parloops.c (canonicalize_loop_ivs): reduction_list contains
3444 SSA_NAMES not struct reduction_info.
3446 2009-03-02 Sebastian Pop <sebastian.pop@amd.com>
3448 * sese.c (expand_scalar_variables_expr): Handle ADDR_EXPR.
3450 2009-02-27 Sebastian Pop <sebastian.pop@amd.com>
3451 Tobias Grosser <grosser@fim.uni-passau.de>
3453 * sese.c (new_sese): Initialize SESE_REDUCTION_LIST.
3454 (free_sese): Free SESE_REDUCTION_LIST.
3455 * sese.h (struct sese): Add field reduction_list.
3456 (SESE_REDUCTION_LIST): New.
3457 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Call
3458 canonicalize_loop_ivs on SESE_REDUCTION_LIST.
3460 2009-02-27 Sebastian Pop <sebastian.pop@amd.com>
3461 Tobias Grosser <grosser@fim.uni-passau.de>
3463 * tree-flow.h (gather_scalar_reductions): Use struct loop * instead
3466 2009-02-27 Sebastian Pop <sebastian.pop@amd.com>
3467 Tobias Grosser <grosser@fim.uni-passau.de>
3469 * tree-parloops.c (struct brli, build_reduction_list_info,
3470 analyze_reduction_list, gather_scalar_reductions): New.
3471 (loop_parallel_p): Build a reduction list containing only
3472 PHI_RESULT SSA_NAMEs: call gather_scalar_reductions.
3473 (gen_parallel_loop): Call the analysis analyze_reduction_list.
3474 (parallelize_loops): Now reduction_list is a htab_t of SSA_NAMEs.
3475 * tree-flow.h (gather_scalar_reductions): Declared.
3477 2009-02-26 Sebastian Pop <sebastian.pop@amd.com>
3480 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not call
3481 number_of_iterations_exit from a gcc_assert.
3483 2009-02-25 Sebastian Pop <sebastian.pop@amd.com>
3484 Jan Sjodin <jan.sjodin@amd.com>
3486 * output.h (graphite_out_file, graphite_in_file): Declared.
3487 * toplev.c (graphite_out_file, graphite_in_file): New.
3488 (init_asm_output): Initialize graphite_in_file and graphite_out_file.
3489 * graphite-clast-to-gimple.c (build_cloog_prog): Read PBB_SCATTERING.
3490 Don't call schedule_to_scattering.
3491 * common.opt (fgraphite-write, fgraphite-read): New.
3492 * graphite-poly.c: Include output.h.
3493 (print_scattering_function, print_scattering_functions,
3494 debug_scattering_function, debug_scattering_functions,
3495 graphite_write_transforms, graphite_read_transforms,
3496 graphite_generate_scattering_fns): New.
3497 (apply_poly_transforms): Do not apply transform if flag_graphite_read.
3498 Call graphite_generate_scattering_fns, graphite_write_transforms,
3499 graphite_read_transforms.
3500 (new_poly_bb): Initialize PBB_SCATTERING.
3501 (free_poly_bb): Free PBB_SCATTERING.
3502 (schedule_to_scattering): Does not return, initialize PBB_SCATTERING.
3503 * graphite-poly.h (struct poly_bb): Add field scattering.
3504 (PBB_SCATTERING): New.
3505 (print_scattering_function, print_scattering_functions,
3506 debug_scattering_function, debug_scattering_functions): Declared.
3507 * graphite-ppl.c (cloog_matrix_to_ppl_constraint): Matrices contain
3508 GMP values, not integers!
3509 (ppl_print_polyhedron_matrix, debug_ppl_polyhedron_matrix,
3510 ppl_read_polyhedron_matrix): New.
3511 * graphite-ppl.h (ppl_print_polyhedron_matrix,
3512 debug_ppl_polyhedron_matrix,
3513 ppl_read_polyhedron_matrix): Declared.
3514 * Makefile.in (graphite-poly.o): Depends on output.h.
3516 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
3517 Tobias Grosser <grosser@fim.uni-passau.de>
3520 * graphite-scop-detection.c (stmt_simple_for_scop_p): Analyze
3521 scalar evolutions in the scop_entry->loop_father.
3523 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
3524 Tobias Grosser <grosser@fim.uni-passau.de>
3526 * graphite.h (ref_nb_loops): Remove declaration.
3527 (struct gimple_bb, gimple_bb_p, GBB_BB, GBB_DATA_REFS, GBB_CONDITIONS,
3528 GBB_CONDITION_CASES, GBB_CLOOG_IV_TYPES, gbb_loop, print_gimple_bb,
3529 debug_gbb): Moved to sese.h.
3532 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
3533 Tobias Grosser <grosser@fim.uni-passau.de>
3535 * graphite-data-ref.[ch]: Disable.
3537 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
3538 Tobias Grosser <grosser@fim.uni-passau.de>
3540 * graphite-scop-detection.c (stmt_simple_for_scop_p): Analyze
3541 scalar evolutions in the scop_entry->loop_father.
3543 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
3545 * graphite-scop-detection.c (nb_reductions_in_loop): Moved here...
3546 (graphite_cannot_represent_loop_niter): Renamed
3547 graphite_cannot_represent_loop. Call nb_reductions_in_loop.
3548 (limit_scops): build_sese_loop_nests does not return a bool.
3549 * graphite-scop-detection.h (nb_reductions_in_loop): Declared.
3550 * sese.c (nb_reductions_in_loop): ... from here.
3551 (graphite_loop_normal_form): ... from here.
3552 (sese_record_loop): Does not fail, so does not return a bool.
3553 (build_sese_loop_nests): Same.
3554 * sese.h (build_sese_loop_nests): Update declaration.
3555 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Moved here...
3556 (build_graphite_loop_normal_form): New.
3557 (gloog): Call build_graphite_loop_normal_form.
3558 * graphite-sese-to-poly.c (build_poly_scop): Don't fail on
3559 build_sese_loop_nests.
3561 * testsuite/gcc.dg/graphite/id-1.c: New.
3563 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
3564 Tobias Grosser <grosser@fim.uni-passau.de>
3566 * graphite-sese-to-poly.c (scan_tree_for_params): Remove REAL_CST.
3567 The SCoP detection fix is sufficient.
3569 2009-02-21 Sebastian Pop <sebastian.pop@amd.com>
3571 PR tree-optimization/39260
3572 * graphite-scop-detection.c (harmful_stmt_in_bb): Stop a SCoP when
3573 the basic block contains a condition with a real type.
3574 * graphite-sese-to-poly.c (scan_tree_for_params): Handle REAL_CST.
3576 * gcc.dg/graphite/pr39260.c: New.
3578 2009-02-21 Sebastian Pop <sebastian.pop@amd.com>
3580 * graphite-poly.c: Inlcude params.h.
3581 (graphite_trans_loop_block): Use PARAM_LOOP_BLOCK_TILE_SIZE for
3583 * Makefile.in (graphite-poly.o): Depend on PARAMS_H.
3584 * params.def (PARAM_LOOP_BLOCK_TILE_SIZE): Define.
3586 2009-02-20 Sebastian Pop <sebastian.pop@amd.com>
3587 Tobias Grosser <grosser@fim.uni-passau.de>
3589 * graphite-scop-detection.c (dot_all_scops_1,
3590 dot_all_scops): Moved here.
3591 * graphite-scop-detection.h (dot_all_scops): Declared here.
3592 * graphite.c (graphite_initialize, graphite_finalize): New.
3593 (graphite_transform_loops): Cleaned up.
3594 * sese.c (debug_oldivs): Moved here.
3595 * graphite-poly.c (graphite_apply_transformations): Renamed
3596 apply_poly_transforms.
3597 (debug_loop_vec): Moved here.
3598 * graphite-sese-to-poly.c (build_bb_loops, build_sese_conditions_1,
3599 scop_contains_non_iv_scalar_phi_nodes, build_sese_conditions,
3600 find_scop_parameters, build_scop_iteration_domain,
3601 add_conditions_to_constraints, build_scop_canonical_schedules,
3602 build_scop_data_accesses): Now static.
3603 (build_poly_scop, check_poly_representation): New.
3605 2009-02-20 Sebastian Pop <sebastian.pop@amd.com>
3607 * graphite.c (graphite_stmt_p, new_gimple_bb, free_gimple_bb,
3608 remove_gbbs_in_scop, free_scops, try_generate_gimple_bb,
3609 build_scop_bbs, ref_nb_loops, compare_prefix_loops,
3610 build_scop_canonical_schedules, build_bb_loops, add_value_to_dim,
3611 scan_tree_for_params_right_scev, scan_tree_for_params_int,
3612 scan_tree_for_params, struct irp_data, dx_record_params,
3613 find_params_in_bb, find_scop_parameters, gbb_from_bb,
3614 build_loop_iteration_domains, add_conditions_to_domain,
3615 phi_node_is_iv, bb_contains_non_iv_scalar_phi_nodes,
3616 scop_contains_non_iv_scalar_phi_nodes, build_sese_conditions_1,
3617 build_sese_conditions, add_conditions_to_constraints,
3618 build_scop_iteration_domain, build_access_matrix_with_af,
3619 build_access_matrix,
3620 build_scop_data_accesses): Moved to graphite-sese-to-poly.c.
3622 * graphite-sese-to-poly.c: New.
3623 * graphite-sese-to-poly.h: New.
3625 * Makefile.in: Add new rule for graphite-sese-to-poly.o.
3627 2009-02-20 Sebastian Pop <sebastian.pop@amd.com>
3629 * graphite.c: Split graphite code generation to a new file.
3630 (graphite_verify, gmp_cst_to_tree, clast_name_to_gcc,
3631 max_precision_type, clast_to_gcc_expression_red,
3632 clast_to_gcc_expression, gcc_type_for_clast_expr,
3633 gcc_type_for_clast_eq, loop_iv_stack_patch_for_consts,
3634 graphite_translate_clast_equation, graphite_create_guard_cond_expr,
3635 graphite_create_new_guard, clast_get_body_of_loop,
3636 gcc_type_for_cloog_iv, gcc_type_for_iv_of_clast_loop,
3637 graphite_create_new_loop, build_iv_mapping, copy_renames,
3638 translate_clast, find_cloog_iv_in_expr, compute_cloog_iv_types_1,
3639 compute_cloog_iv_types, free_scattering, save_var_name,
3640 initialize_cloog_names, build_scop_context, build_cloog_prog,
3641 set_cloog_options, debug_clast_stmt, scop_to_clast,
3642 print_generated_program, debug_generated_program,
3643 gloog): Moved to graphite-clast-to-gimple.c.
3645 (struct cloog_prog_clast): Moved to graphite-clast-to-gimple.h.
3647 (iv_stack_entry_is_constant, iv_stack_entry_is_iv,
3648 loop_iv_stack_push_iv, loop_iv_stack_insert_constant,
3649 loop_iv_stack_pop, loop_iv_stack_get_iv,
3650 loop_iv_stack_get_iv_from_name, debug_loop_iv_stack,
3651 free_loop_iv_stack, loop_iv_stack_remove_constants,
3652 debug_rename_elt, debug_rename_map_1, debug_rename_map,
3653 rename_map_elt_info, eq_rename_map_elts, debug_ivtype_elt,
3654 debug_ivtype_map_1, debug_ivtype_map, ivtype_map_elt_info,
3655 eq_ivtype_map_elts, sese_add_exit_phis_edge,
3656 sese_add_exit_phis_var, sese_insert_phis_for_liveouts,
3657 get_vdef_before_sese, sese_adjust_vphi,
3658 get_new_name_from_old_name, sese_adjust_phis_for_liveouts,
3659 oldiv_for_loop, rename_variables_in_stmt, is_parameter,
3660 is_iv, expand_scalar_variables_ssa_name,
3661 expand_scalar_variables_expr, expand_scalar_variables_stmt,
3662 expand_scalar_variables, rename_variables, remove_condition,
3663 get_true_edge_from_guard_bb, get_false_edge_from_guard_bb,
3664 add_loop_exit_phis, insert_loop_close_phis, struct igp,
3665 default_liveout_before_guard, add_guard_exit_phis,
3666 insert_guard_phis, register_old_and_new_names,
3667 graphite_copy_stmts_from_block, register_sese_liveout_renames,
3668 copy_bb_and_scalar_dependences, outermost_loop_in_sese,
3669 if_region_set_false_region, create_if_region_on_edge,
3670 move_sese_in_condition): Moved to sese.c.
3672 (nb_loops_around_loop_in_sese, struct ifsese, if_region_entry,
3673 if_region_exit, if_region_get_condition_block,
3674 struct rename_map_elt, new_rename_map_elt, enum iv_stack_entry_kind,
3675 union iv_stack_entry_data_union, struct iv_stack_entry_struct,
3676 iv_stack_entry_p, loop_iv_stack, struct ivtype_map_elt,
3677 ivtype_map_elt, new_ivtype_map_elt,
3678 recompute_all_dominators): Moved to sese.h.
3680 * graphite-clast-to-gimple.c: New.
3681 * graphite-clast-to-gimple.h: New.
3682 * Makefile.in: Add new rule for graphite-clast-to-gimple.o.
3683 * sese.c: Modified as said above.
3686 2009-02-20 Sebastian Pop <sebastian.pop@amd.com>
3688 * graphite.c: Split scop detection to a new file.
3689 (enum gbb_type, gbb_type, get_bb_type, struct sd_region_p, sd_region,
3690 move_sd_regions, loop_affine_expr, exclude_component_ref,
3691 is_simple_operand, stmt_simple_for_scop_p, harmful_stmt_in_bb,
3692 graphite_cannot_represent_loop_niter, struct scopdet_info,
3693 scopdet_basic_block_info, build_scops_1, bb_in_sd_region,
3694 find_single_entry_edge, find_single_exit_edge,
3695 create_single_entry_edge, sd_region_without_exit,
3696 create_single_exit_edge, unmark_exit_edges, mark_exit_edges,
3697 create_sese_edges, build_graphite_scops, limit_scops, build_scops):
3698 Moved to graphite-scop-detection.c.
3700 * graphite-scop-detection.c: New.
3701 * graphite-scop-detection.h: New.
3702 * Makefile.in: Add new rule for graphite-scop-detection.o.
3704 * sese.c: Include tree-chrec.h, tree-data-ref.h, and
3705 tree-scalar-evolution.h.
3706 (nb_reductions_in_loop, graphite_loop_normal_form, sese_record_loop,
3707 build_sese_loop_nests): Moved here from graphite.c.
3708 (param_index): Renamed parameter_index_in_region.
3710 2009-02-18 Tobias Grosser <grosser@fim.uni-passau.de>
3711 Sebastian Pop <sebastian.pop@amd.com>
3713 * gcc.dg/graphite/block-0.c: Expected to fail now.
3714 * gcc.dg/graphite/block-1.c: Same.
3715 * gcc.dg/graphite/block-5.c: Same.
3716 * gcc.dg/graphite/block-6.c: Same.
3718 2009-02-18 Tobias Grosser <grosser@fim.uni-passau.de>
3719 Sebastian Pop <sebastian.pop@amd.com>
3721 * graphite.h: Separate from graphite_bb_p the polyhedral
3722 representation in poly_bb_p and the GCC specifics in gimple_bb_p.
3723 (struct data_dependence_polyhedron, RDGE_DDP, ddp_p): Moved to
3724 graphite-data-ref.h.
3725 (struct poly_bb, PBB_SCOP, PBB_STATIC_SCHEDULE, PBB_DOMAIN,
3726 PBB_BLACK_BOX, PBB_LOOPS, pbb_nb_loops, pbb_loop_at_index,
3727 pbb_loop_index, struct scop, SCOP_BBS, SCOP_REGION, SCOP_ENTRY,
3728 SCOP_EXIT, SCOP_REGION_BBS, SCOP_DEP_GRAPH, SCOP_PARAMS,
3729 SCOP_LOOP_NEST, SCOP_PARAMS, SCOP_OLDIVS, SCOP_LIVEOUT_RENAMES,
3730 scop_nb_params): Moved to graphite-poly.h.
3731 * graphite-data-ref.c: Same.
3732 * graphite-data-ref.h: New.
3734 (pbb_compare, graphite_sort_pbbs, graphite_trans_bb_move_loop,
3735 graphite_trans_bb_strip_mine, strip_mine_profitable_p,
3736 is_interchange_valid, graphite_trans_bb_block,
3737 graphite_trans_loop_block, scop_max_loop_depth,
3738 graphite_trans_scop_block, graphite_apply_transformations,
3739 new_poly_bb, free_poly_bb, new_scop, free_scop): Moved to
3741 * graphite-poly.h: New.
3742 * graphite-poly.c: New.
3743 * Makefile.in (OBJS-common): Add graphite-poly.o.
3744 (graphite-poly.o): New rule.
3745 * tree-data-ref.h (struct data_reference): Remove unused scop field.
3748 2009-02-18 Sebastian Pop <sebastian.pop@amd.com>
3749 Tobias Grosser <grosser@fim.uni-passau.de>
3751 * graphite.c: Replace gb -> gbb.
3753 * graphite-data-ref.c: Same.
3755 2009-02-18 Sebastian Pop <sebastian.pop@amd.com>
3756 Tobias Grosser <grosser@fim.uni-passau.de>
3758 * Makefile.in (OBJS-commmon): Add sese.o.
3760 (graphite.o): Add sese.h.
3761 * graphite.c (bb_in_ss_p, loop_in_sese_p,
3762 sese_build_livein_liveouts_use, sese_build_livein_liveouts_bb,
3763 sese_build_livein_liveouts, register_bb_in_sese, new_sese, free_sese):
3765 (block_before_scop): Add missing return.
3766 (new_scop, free_scop): Remove SESE data structures.
3767 (scop_record_loop, scan_tree_for_params, find_params_in_bb,
3768 find_scop_parameters, build_loop_iteration_domains,
3769 add_conditions_to_domain, register_scop_liveout_renames,
3770 copy_bb_and_scalar_dependences): Scop -> SESE.
3772 (add_conditions_to_domain): SCoP -> SESE and remove check
3773 (scop_contains_non_iv_scalar_phi_nodes): New.
3774 (build_scop_conditions_1, build_scop_conditions): Remove check for
3775 non iv scalar phi nodes.
3776 (print_scop_statistics): New.
3777 (graphite_transform_loops): Cleanup.
3779 * graphite.h: Move to sese & cleanup.
3783 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
3784 Tobias Grosser <grosser@fim.uni-passau.de>
3786 * graphite.c (build_scop_conditions_1): Conditions are only
3787 at the end of a basic block.
3789 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
3790 Tobias Grosser <grosser@fim.uni-passau>
3792 * graphite.h (struct graphite_bb): Remove compressed_alpha_matrix
3794 (GBB_ALPHA): Removed.
3796 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
3797 Tobias Grosser <grosser@fim.uni-passau.de>
3799 * graphite-data-ref.c (graphite_test_dependence): Don't use
3800 GBB_DYNAMIC_SCHEDULE.
3801 * graphite.c (new_graphite_bb): Same.
3802 (free_graphite_bb): Same.
3803 (build_scop_dynamic_schedules): Removed.
3804 (graphite_transform_loops): Don't call it.
3805 * graphite.h (struct graphite_bb): Remove dynamic_schedule field.
3806 (GBB_DYNAMIC_SCHEDULE): Removed.
3808 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
3809 Tobias Grosser <grosser@fim.uni-passau.de>
3811 * graphite.c (schedule_to_scattering): Don't use CloogMatrix.
3812 (print_graphite_bb): Same.
3813 (build_cloog_prog): Same.
3815 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
3816 Tobias Grosser <grosser@fim.uni-passau.de>
3818 * graphite.c (build_cloog_prog): Don't use CloogMatrix.
3820 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
3821 Tobias Grosser <grosser@fim.uni-passau.de>
3823 * graphite.c (build_scop_context): Don't use CloogMatrix.
3824 * graphite-ppl.c (new_Cloog_Domain_from_ppl_Polyhedron): New.
3825 * graphite-ppl.h (new_Cloog_Domain_from_ppl_Polyhedron): Declared.
3827 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
3828 Tobias Grosser <grosser@fim.uni-passau.de>
3830 * graphite.h (struct scop): Move params, old_ivs, loops, loop_nest,
3831 liveout_renames, add_params fields...
3832 (struct sese): ... here.
3833 (SESE_PARAMS, SESE_LOOPS, SESE_LOOP_NEST, SESE_ADD_PARAMS,
3834 SESE_PARAMS, SESE_OLDIVS, SESE_LIVEOUT_RENAMES): New.
3836 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
3837 Tobias Grosser <grosser@fim.uni-passau.de>
3839 * graphite.c (print_scop): Do not print the CLooG program.
3840 (new_scop, free_scop, initialize_cloog_names, build_scop_context,
3841 build_cloog_prog, gloog): Don't use SCOP_PROG.
3842 (find_transform): Renamed scop_to_clast.
3843 (print_generated_program, debug_generated_program): New.
3844 (graphite_transform_loops): Adapt to new interface.
3845 * graphite.h (struct scop): Remove program field.
3846 (SCOP_PROG): Removed.
3847 (print_generated_program, debug_generated_program): Declared.
3849 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
3851 * graphite-data-ref.c (schedule_precedes_p, schedule_same_p): New.
3852 (statement_precedes_p): Use schedule_same_p and schedule_precedes_p.
3853 * graphite.c (gbb_compare, schedule_to_scattering, print_graphite_bb,
3854 free_graphite_bb, build_scop_canonical_schedules,
3855 graphite_trans_bb_strip_mine, graphite_trans_scop_block): Static
3856 schedules are now represented using a ppl_Linear_Expression_t.
3857 * graphite.h (struct graphite_bb): Same.
3858 * graphite-ppl.c (ppl_lexico_compare_linear_expressions): New.
3859 * graphite-ppl.h (ppl_lexico_compare_linear_expressions): Declared.
3861 2009-02-15 Sebastian Pop <sebastian.pop@amd.com>
3863 * graphite.c: Free local memory.
3864 * graphite-ppl.c: Same.
3866 2009-02-15 Sebastian Pop <sebastian.pop@amd.com>
3868 * graphite.c (const_column_index, get_first_matching_sign_row_index,
3869 get_lower_bound_row, get_upper_bound_row, copy_constraint,
3870 swap_constraint_variables, scale_constraint_variable): Removed.
3871 (graphite_trans_bb_strip_mine): Remove pong.
3872 * graphite-ppl.c: Include missing header files.
3873 (set_inhomogeneous, set_coef, shift_poly, ppl_strip_loop): New.
3874 * graphite-ppl.h (ppl_strip_loop): Declared.
3875 * Makefile.in (graphite-ppl.o): Adjust dependences.
3877 2009-02-14 Sebastian Pop <sebastian.pop@amd.com>
3879 * graphite.c (build_loop_iteration_domains): Remove ping pong.
3880 (build_scop_iteration_domain): Same.
3882 2009-02-13 Sebastian Pop <sebastian.pop@amd.com>
3884 * graphite.c (scan_tree_for_params, add_conditions_to_domain): Remove
3886 (add_value_to_dim, scan_tree_for_params_right_scev,
3887 scan_tree_for_params_int): New.
3888 * graphite-ppl.c (oppose_constraint): New.
3889 (insert_constraint_into_matrix): Implement missing cases.
3890 * graphite-ppl.h (insert_constraint_into_matrix): Declared.
3892 2009-02-13 Sebastian Pop <sebastian.pop@amd.com>
3894 * graphite.c (graphite_trans_bb_move_loop): Remove ping pong,
3895 use ppl_move_dimension.
3897 2009-02-12 Sebastian Pop <sebastian.pop@amd.com>
3899 * graphite-data-ref.c: Domains are now ppl_Polyhedra_t.
3902 * graphite-ppl.c: Same.
3903 * graphite-ppl.h: Same.
3905 2009-02-12 Sebastian Pop <sebastian.pop@amd.com>
3907 Revert last 3 commits.
3909 2009-02-10 Sebastian Pop <sebastian.pop@amd.com>
3911 * graphite.c (scan_tree_for_params, add_conditions_to_domain): Remove
3913 (add_value_to_dim, scan_tree_for_params_right_scev,
3914 scan_tree_for_params_int): New.
3915 * graphite-ppl.c (oppose_constraint): New.
3916 (insert_constraint_into_matrix): Implement missing cases.
3917 * graphite-ppl.h (insert_constraint_into_matrix): Declared.
3919 2009-02-10 Sebastian Pop <sebastian.pop@amd.com>
3921 * graphite.c (graphite_trans_bb_move_loop): Remove unused variables.
3923 2009-02-10 Sebastian Pop <sebastian.pop@amd.com>
3924 Tobias Grosser <grosser@fim.uni-passau.de>
3926 * graphite.c (graphite_trans_bb_move_loop): Remove ping pong,
3927 use ppl_move_dimension.
3928 * graphite-ppl.c (ppl_move_dimension): New.
3929 * graphite-ppl.h (ppl_move_dimension): Declared.
3931 2009-02-10 Sebastian Pop <sebastian.pop@amd.com>
3933 * graphite.c: Do not include cloog/cloog.h.
3934 (print_graphite_bb): Remove ping pong, call PPL print function.
3936 2009-02-10 Tobias Grosser <grosser@fim.uni-passau.de>
3938 * Makefile.in (OBJS-common): Add graphite-ppl.o.
3939 (graphite.o): Add dependence on graphite-ppl.h.
3940 (graphite-ppl.o): New.
3941 (graphite-data-ref.c): Ping pong between PPL data structures
3943 * graphite-ppl.c: New.
3944 * graphite-ppl.h: New.
3945 * graphite.c: Include graphite-ppl.h.
3946 (print_graphite_bb, add_conditions_to_domain, build_cloog_prog,
3947 graphite_trans_bb_move_loop, graphite_trans_bb_strip_mine):
3948 Ping pong between PPL data structures and matrices.
3949 (new_graphite_bb): Create a PPL constraint system.
3950 Call ppl_delete_Constraint_System instead of cloog_matrix_free.
3951 (build_loop_iteration_domains): Use PPL functions.
3952 * graphite.h: Include graphite-ppl.h. Fix comments.
3953 (graphite_bb): Use a ppl_Constraint_System_t instead of
3954 CloogMatrix for representing the domain.
3955 (scop): Remove static_schedule.
3956 (gbb_nb_loops): Ping pong between PPL data structures and matrices.
3958 2009-02-06 Sebastian Pop <sebastian.pop@amd.com>
3960 * graphite.c: Fix some comments.
3962 2009-02-05 Sebastian Pop <sebastian.pop@amd.com>
3965 * graphite.c (if_region_set_false_region): After moving a region
3966 in the false branch of a condition, remove the empty dummy
3968 (gloog): Remove wrong fix for PR38953.
3970 2009-02-03 Tobias Grosser <grosser@fim.uni-passau.de>
3972 * graphite.c (bb_in_sese_p, sese_build_livein_liveouts_use,
3973 sese_build_livein_liveouts_bb, sese_build_livein_liveouts,
3974 register_bb_in_sese, new_sese, free_sese): Moved.
3975 (dot_scop_1, build_scop_loop_nests, build_loop_iteration_domains,
3976 outermost_loop_in_scop, build_scop_iteration_domain,
3977 expand_scalar_variables_ssa_name, get_vdef_before_scop,
3978 limit_scops): Use bb_in_sese_p instead of bb_in_scop_p.
3979 Use loop_in_sese_p instead of loop_in_scop_p.
3980 (new_graphite_bb, new_scop, gloog): Do not initialize SCOP_BBS_B.
3981 (free_scop): Do not free SCOP_BBS_B.
3982 (nb_loops_around_loop_in_scop, nb_loops_around_gb,
3983 ref_nb_loops): Moved here...
3984 * graphite.h (ref_nb_loops): ... from here.
3985 (struct scop): Remove bbs_b bitmap.
3986 (SCOP_BBS_B, bb_in_scop_p, loop_in_scop_p): Removed.
3987 * testsuite/gcc.dg/graphite/scop-19.c: New
3989 2009-02-03 Tobias Grosser <grosser@fim.uni-passau.de>
3991 * graphite.c (scopdet_basic_block_info): Fix bug in scop
3994 2009-01-30 Tobias Grosser <grosser@fim.uni-passau.de>
3996 * graphite.c (new_loop_to_cloog_loop_str, hash_loop_to_cloog_loop,
3997 eq_loop_to_cloog_loop): Remove.
3998 (new_scop, free_scop): Remove SCOP_LOOP2CLOOG_LOOP.
3999 * graphite.h (struct scop): Remove loop2cloog_loop.
4000 (loop_domain_dim, loop_iteration_vector_dim): Remove.
4002 2009-01-30 Tobias Grosser <grosser@fim.uni-passau.de>
4004 * opts.c (decode_options): Only add graphite options to O2
4005 if we compile with graphite enabled.
4007 2009-01-26 Sebastian Pop <sebastian.pop@amd.com>
4009 * Merge from mainline (r143163:143684).
4011 2009-01-26 Sebastian Pop <sebastian.pop@amd.com>
4013 * graphite.c (debug_value): Removed.
4014 * graphite.h (debug_value): Removed.
4016 2009-01-23 Sebastian Pop <sebastian.pop@amd.com>
4018 * passes.c (init_optimization_passes): Do not call pass_copy_prop
4019 after graphite: pass_copy_prop does not maintain a proper loop closed
4020 SSA form. pass_copy_prop should be fixed.
4022 2009-01-23 Sebastian Pop <sebastian.pop@amd.com>
4024 * graphite.c (scop_adjust_phis_for_liveouts): Fix warning.
4026 2009-01-23 Sebastian Pop <sebastian.pop@amd.com>
4028 * graphite.c (graphite_verify): Add a call to verify_loop_closed_ssa.
4029 (gloog): Split the exit of the scop when the scop exit is a loop exit.
4030 (graphite_transform_loops): Only call cleanup_tree_cfg if gloog
4033 2009-01-20 Sebastian Pop <sebastian.pop@amd.com>
4035 * graphite.c (gloog): Return true when code gen succeeded.
4036 (graphite_transform_loops): Do not call cleanup_tree_cfg if
4037 the code of the function did not changed. After cleanup_tree_cfg
4038 call rewrite_into_loop_closed_ssa to maintain the loop closed ssa
4041 2009-01-19 Sebastian Pop <sebastian.pop@amd.com>
4043 * graphite.c (stmt_simple_for_scop_p): Also handle cases when
4044 gimple_call_lhs is NULL.
4046 2009-01-16 Sebastian Pop <sebastian.pop@amd.com>
4047 Tobias Grosser <tobi.grosser@amd.com>
4049 * graphite.c (graphite_trans_scop_block): Do not block single
4052 2009-01-15 Sebastian Pop <sebastian.pop@amd.com>
4053 Tobias Grosser <tobi.grosser@amd.com>
4055 * graphite.c (build_scop_canonical_schedules): Start schedules at
4058 2009-01-15 Sebastian Pop <sebastian.pop@amd.com>
4059 Tobias Grosser <tobi.grosser@amd.com>
4061 * graphite.c (compare_prefix_loops): New.
4062 (build_scop_canonical_schedules): Rewritten.
4063 (graphite_transform_loops): Move build_scop_canonical_schedules
4064 after build_scop_iteration_domain.
4066 2009-01-14 Sebastian Pop <sebastian.pop@amd.com>
4067 Tobias Grosser <tobi.grosser@amd.com>
4069 * graphite.c (add_conditions_to_domain): Add the loops to
4070 the dimension of the iteration domain. Do copy the domain
4071 only when it exists.
4072 (build_scop_conditions_1): Do not call add_conditions_to_domain.
4073 (add_conditions_to_constraints): New.
4074 (can_generate_code_stmt, can_generate_code): Removed.
4075 (gloog): Do not call can_generate_code.
4076 (graphite_transform_loops): Call add_conditions_to_constraints
4077 after building the iteration domain.
4079 2009-01-14 Sebastian Pop <sebastian.pop@amd.com>
4080 Tobias Grosser <tobi.grosser@amd.com>
4081 Jan Sjodin <jan.sjodin@amd.com>
4083 * graphite.c (scan_tree_for_params): On substractions negate
4084 all the coefficients of the term.
4085 (clast_to_gcc_expression_red): New. Handle reduction expressions
4086 of more than two operands.
4087 (clast_to_gcc_expression): Call clast_to_gcc_expression_red.
4088 (get_vdef_before_scop): Handle also the case of default definitions.
4090 2009-01-14 Sebastian Pop <sebastian.pop@amd.com>
4093 * graphite.c (get_vdef_before_scop, scop_adjust_vphi): New.
4094 (scop_adjust_phis_for_liveouts): Call scop_adjust_vphi.
4095 (gloog): Do not call cleanup_tree_cfg.
4096 (graphite_transform_loops): Call cleanup_tree_cfg after all
4097 scops have been code generated.
4099 2009-01-13 Sebastian Pop <sebastian.pop@amd.com>
4101 * passes.c (init_optimization_passes): Schedule after
4102 graphite transforms pass_copy_prop, pass_dce_loop and pass_lim.
4104 2009-01-13 Sebastian Pop <sebastian.pop@amd.com>
4106 * graphite.c (expand_scalar_variables_stmt): Do not pass loop_p.
4108 (expand_scalar_variables_ssa_name): Do not pass loop_p. Fix comment.
4109 Set the type of an expression to the type of its assign statement.
4110 (expand_scalar_variables_expr): Do not pass loop_p.
4111 Fix comment. Stop recursion on tcc_constant or tcc_declaration.
4112 (copy_bb_and_scalar_dependences): Do not pass loop_p.
4113 (translate_clast): Update call to copy_bb_and_scalar_dependences.
4115 2009-01-11 Sebastian Pop <sebastian.pop@amd.com>
4117 * graphite.c (expand_scalar_variables_ssa_name): Set the type of
4118 an expression to the gimple_expr_type of its assign statement.
4119 (expand_scalar_variables_expr): Stop recursion on tcc_constant
4122 2009-01-11 Sebastian Pop <sebastian.pop@amd.com>
4124 PR tree-optimization/38786
4125 * testsuite/gcc.dg/graphite/pr38786.c: New.
4126 * graphite.c (expand_scalar_variables_ssa_name): New, outlined from
4127 the SSA_NAME case of expand_scalar_variables_expr.
4128 (expand_scalar_variables_expr): Also gather the scalar computation
4129 used to index the memory access.
4130 (expand_scalar_variables_stmt): Pass to expand_scalar_variables_expr
4131 the gimple_stmt_iterator where it inserts new code.
4133 2009-01-10 Sebastian Pop <sebastian.pop@amd.com>
4135 * testsuite/gcc.dg/graphite/block-3.c: Fix compile error on 32bit.
4137 2009-01-10 Sebastian Pop <sebastian.pop@amd.com>
4139 * opts.c (decode_options): Enable flag_graphite_identity and
4140 flag_loop_block in -O2 and above.
4142 2009-01-08 Sebastian Pop <sebastian.pop@amd.com>
4144 * libjava/classpath/lib/gnu/java/awt/peer/gtk/GtkMouseInfoPeer.class:
4145 Fix merge problem: replace with the file from trunk.
4147 2009-01-08 Sebastian Pop <sebastian.pop@amd.com>
4149 * Merge from mainline (r141727:143163).
4151 2009-01-07 Sebastian Pop <sebastian.pop@amd.com>
4152 Jan Sjodin <jan.sjodin@amd.com>
4154 PR tree-optimization/38559
4155 * testsuite/gcc.dg/graphite/pr38559.c: New.
4157 * graphite.c (debug_value, copy_constraint,
4158 swap_constraint_variables, scale_constraint_variable, ): New.
4159 (get_lower_bound, get_upper_bound): Removed.
4160 (graphite_trans_bb_strip_mine): Clean up this code that works
4161 only for constant number of iterations. Fully copy upper and
4162 lower bound constraints, not only the constant part of them.
4163 * graphite.h (debug_value): Declared.
4165 2009-01-06 Jan Sjodin <jan.sjodin@amd.com>
4167 PR tree-optimization/38492
4168 PR tree-optimization/38498
4169 * tree-check.c (operator_is_linear, scev_is_linear_expression): New.
4170 * tree-chrec.h (scev_is_linear_expression): Declared.
4171 * graphite.c (graphite_cannot_represent_loop_niter): New.
4172 (scopdet_basic_block_info): Call graphite_cannot_represent_loop_niter.
4173 (graphite_loop_normal_form): Use gcc_assert.
4174 (scan_tree_for_params): Use CASE_CONVERT.
4175 (phi_node_is_iv, bb_contains_non_iv_scalar_phi_nodes): New.
4176 (build_scop_conditions_1): Call bb_contains_non_iv_scalar_phi_nodes.
4177 Use gcc_assert. Discard scops that contain unhandled cases.
4178 (build_scop_conditions): Return a boolean status for unhandled cases.
4179 (strip_mine_profitable_p): Print the loop number, not its depth.
4180 (is_interchange_valid): Pass the depth of the loop nest, don't
4181 recompute it wrongly.
4182 (graphite_trans_bb_block): Same.
4183 (graphite_trans_bb_block): Print tentative of loop blocking.
4184 (graphite_trans_scop_block): Do not print that the loop has been
4186 (graphite_transform_loops): Do not handle scops that contain condition
4189 * testsuite/gcc.dg/graphite/pr38500.c: Fixed warning as committed
4191 * testsuite/gcc.dg/graphite/block-0.c: Update test.
4192 * testsuite/gcc.dg/graphite/block-1.c: Same.
4193 * testsuite/gcc.dg/graphite/block-2.c: Remove xfail and test for
4195 * testsuite/gcc.dg/graphite/block-4.c: Remove test for strip mine.
4196 * testsuite/gcc.dg/graphite/block-3.c: New.
4197 * testsuite/gcc.dg/graphite/pr38498.c: New.
4199 2008-12-22 Harsha Jagasia <harsha.jagasia@amd.com>
4201 PR tree-optimization/38510
4202 * gcc.dg/graphite/pr38510.c: New.
4203 * graphite.c (recompute_all_dominators): Call mark_irreducible_loops.
4204 (translate_clast): Call recompute_all_dominators before
4206 (gloog): Call recompute_all_dominators before graphite_verify.
4208 2008-12-12 Sebastian Pop <sebastian.pop@amd.com>
4210 PR tree-optimization/38492
4211 * graphite.c (rename_map_elt, debug_rename_elt,
4212 debug_rename_map_1, debug_rename_map, new_rename_map_elt,
4213 rename_map_elt_info, eq_rename_map_elts,
4214 get_new_name_from_old_name, bb_in_sese_p): Moved around.
4215 (sese_find_uses_to_rename_use): Renamed sese_build_livein_liveouts_use.
4216 (sese_find_uses_to_rename_bb): Renamed sese_build_livein_liveouts_bb.
4217 (sese_build_livein_liveouts): New.
4218 (new_sese, free_sese): New.
4219 (new_scop): Call new_sese.
4220 (free_scop): Call free_sese.
4221 (rename_variables_from_edge, rename_phis_end_scop): Removed.
4222 (register_old_new_names): Renamed register_old_and_new_names.
4223 (register_scop_liveout_renames, add_loop_exit_phis,
4224 insert_loop_close_phis, struct igp,
4225 default_liveout_before_guard, add_guard_exit_phis,
4226 insert_guard_phis, copy_renames): New.
4227 (translate_clast): Call insert_loop_close_phis and insert_guard_phis.
4228 (sese_add_exit_phis_edge): Renamed scop_add_exit_phis_edge.
4229 (rewrite_into_sese_closed_ssa): Renamed scop_insert_phis_for_liveouts.
4230 (scop_adjust_phis_for_liveouts): New.
4231 (gloog): Call scop_adjust_phis_for_liveouts.
4233 * graphite.h (struct sese): Documented. Added fields liveout,
4235 (SESE_LIVEOUT, SESE_LIVEIN, SESE_LIVEIN_VER, SESE_NUM_VER): New.
4236 (new_sese, free_sese, sese_build_livein_liveouts): Declared.
4237 (struct scop): Added field liveout_renames.
4238 (SCOP_LIVEOUT_RENAMES): New.
4240 2008-12-11 Sebastian Pop <sebastian.pop@amd.com>
4242 PR tree-optimization/38409
4243 * gcc.dg/graphite/pr38409.c: New.
4244 * graphite.c (nb_reductions_in_loop): Use simple_iv.
4246 2008-12-11 Sebastian Pop <sebastian.pop@amd.com>
4248 * graphite.c (gcc_type_for_cloog_iv): By default return
4250 (graphite_create_new_loop): Don't fold_convert the already
4251 fold_convert-ed expression.
4253 2008-12-11 Harsha Jagasia <harsha.jagasia@amd.com>
4255 PR tree-optimization/38446
4256 * gcc.dg/graphite/pr38446.c: New.
4257 * graphite.c (register_bb_in_sese): New.
4258 (bb_in_sese_p): Check if bb belongs to sese region by explicitly
4259 looking at the bbs in the region.
4260 * graphite.h (sese): Add region_basic_blocks pointer set to
4261 structure and initialize at the time of defining new scop.
4263 2008-12-11 Tobias Grosser <grosser@fim.uni-passau.de>
4265 * graphite.c (new_graphite_bb): Initialize GBB_STATIC_SCHEDULE.
4266 (find_params_in_bb): Do not free data refs.
4267 (free_graphite_bb): Add FIXME on disabled free_data_refs.
4269 2008-12-11 Sebastian Pop <sebastian.pop@amd.com>
4271 * testsuite/gcc.dg/graphite/scop-16.c: Test only scop specific info.
4272 * testsuite/gcc.dg/graphite/scop-17.c: Same.
4273 * testsuite/gcc.dg/graphite/block-5.c: New.
4274 * testsuite/gcc.dg/graphite/block-6.c: New.
4275 * testsuite/gcc.dg/graphite/pr37485.c: Clean dump file after.
4276 * testsuite/gcc.dg/graphite/pr37684.c: Same.
4277 * testsuite/gcc.dg/graphite/block-2.c: Same.
4279 * graphite.c (struct ivtype_map_elt): New.
4280 (debug_ivtype_elt, debug_ivtype_map_1, debug_ivtype_map,
4281 new_ivtype_map_elt, ivtype_map_elt_info, eq_ivtype_map_elts,
4282 gcc_type_for_cloog_iv): New.
4283 (loop_iv_stack_patch_for_consts): Use the type of the induction
4284 variable from the original loop, except for the automatically
4285 generated loops, i.e., in the case of a strip-mined loop, in
4286 which case there is no original loop: in that case just use
4288 (new_graphite_bb): Initialize GBB_CLOOG_IV_TYPES.
4289 (free_graphite_bb): Free GBB_CLOOG_IV_TYPES.
4290 (clast_name_to_gcc): Accept params to be NULL.
4291 (clast_to_gcc_expression): Take an extra parameter for the type.
4292 Convert to that type all the expressions built by this function.
4293 (gcc_type_for_clast_expr, gcc_type_for_clast_eq): New.
4294 (graphite_translate_clast_equation): Compute the type of the
4295 clast_equation before translating its LHS and RHS.
4296 (clast_get_body_of_loop, gcc_type_for_iv_of_clast_loop): New.
4297 (graphite_create_new_loop): Compute the type of the induction
4298 variable before translating the lower and upper bounds and before
4299 creating the induction variable.
4300 (rename_variables_from_edge, rename_phis_end_scop): New.
4301 (copy_bb_and_scalar_dependences): Call rename_phis_end_scop.
4302 (sese_add_exit_phis_edge): Do not use integer_zero_node.
4303 (find_cloog_iv_in_expr, compute_cloog_iv_types_1,
4304 compute_cloog_iv_types): New.
4305 (gloog): Call compute_cloog_iv_types before starting the
4306 translation of the clast.
4308 * graphite.h (struct graphite_bb): New field cloog_iv_types.
4309 (GBB_CLOOG_IV_TYPES): New.
4310 (debug_ivtype_map): Declared.
4311 (oldiv_for_loop): New.
4313 2008-12-10 Tobias Grosser <grosser@fim.uni-passau.de>
4316 * graphite.c (new_scop): Initialize SCOP_ADD_PARAMS.
4317 (param_index): Assert if parameter is not know after parameter
4319 (find_params_in_bb): Detect params directly in GBB_CONDITIONS.
4320 (find_scop_parameters): Mark, that we have finished parameter
4322 (graphite_transform_loops): Move condition detection before parameter
4324 * graphite.h (struct scop): Add SCOP_ADD_PARAMS.
4325 * testsuite/gfortran.dg/graphite/pr38459.f90: New.
4327 2008-12-09 Tobias Grosser <grosser@fim.uni-passau.de>
4329 * graphite.c (graphite_transform_loops): Always call find_transform ()
4330 in ENABLE_CHECKING. So we test these code paths, even if we do not
4333 2008-12-09 Tobias Grosser <grosser@fim.uni-passau.de>
4335 * graphite.c (print_graphite_bb): Fix printing to file != dump_file.
4336 (print_scop): Ditto.
4338 2008-12-08 Tobias Grosser <grosser@fim.uni-passau.de>
4341 Fix testsuite/gfortran.dg/graphite/id-3.f90.
4342 * graphite.c (scopdet_basic_block_info): Fix bug that found some
4343 regions more than once.
4345 2008-12-03 Sebastian Pop <sebastian.pop@amd.com>
4347 Fix testsuite/gfortran.dg/graphite/id-4.f90.
4348 * graphite.c (scan_tree_for_params): Do not compute the multiplicand
4351 2008-12-03 Sebastian Pop <sebastian.pop@amd.com>
4353 Fix testsuite/gfortran.dg/graphite/id-1.f90.
4354 * graphite.c (gmp_cst_to_tree): Pass the type in parameter.
4355 (loop_iv_stack_patch_for_consts): Update use of gmp_cst_to_tree.
4356 (max_precision_type): New.
4357 (value_clast): Removed.
4358 (clast_to_gcc_expression): Be more careful to types of expressions.
4359 Use max_precision_type and update use of gmp_cst_to_tree.
4360 (graphite_translate_clast_equation): Use max_precision_type.
4361 (graphite_create_guard_cond_expr): Do not use integer_type_node,
4362 use the type of the condition.
4363 (graphite_create_new_loop): Do not use integer_type_node, use the
4364 max_precision_type of lb and ub.
4366 2008-12-03 Sebastian Pop <sebastian.pop@amd.com>
4368 * graphite.c (build_scops_1): Initialize open_scop.exit
4371 2008-12-02 Sebastian Pop <sebastian.pop@amd.com>
4373 * testsuite/gcc.dg/graphite/pr38084.c: New.
4374 * testsuite/gfortran.dg/graphite/id-1.f90: New.
4375 * testsuite/gfortran.dg/graphite/id-2.f90: New.
4376 * testsuite/gfortran.dg/graphite/id-3.f90: New.
4377 * testsuite/gfortran.dg/graphite/id-4.f90: New.
4378 * testsuite/gfortran.dg/graphite/pr37857.f90: New.
4380 2008-12-02 Sebastian Pop <sebastian.pop@amd.com>
4381 Jan Sjodin <jan.sjodin@amd.com>
4382 Harsha Jagasia <harsha.jagasia@amd.com>
4394 * testsuite/gcc.dg/graphite/pr38073.c: New.
4395 * testsuite/gcc.dg/graphite/pr37928.c: New.
4396 * testsuite/gcc.dg/graphite/pr37883.c: New.
4397 * testsuite/gcc.dg/graphite/pr38125.c: New.
4398 * testsuite/gfortran.dg/graphite/pr38083.f90: New.
4399 * testsuite/gfortran.dg/graphite/pr37852.f90: New.
4400 * testsuite/gfortran.dg/graphite/pr37980.f90: New.
4402 * testsuite/gcc.dg/graphite/scop-18.c: Remove reduction, test for
4403 the number of detected scops. Copy exact same test for loop
4405 * testsuite/gcc.dg/graphite/block-1.c: Fix the number of expected
4406 loops to be blocked as reductions are not handled.
4407 * testsuite/gcc.dg/graphite/block-4.c: ...here. New.
4409 * tree-phinodes.c (remove_phi_nodes): New, extracted from...
4410 * tree-cfg.c (remove_phi_nodes_and_edges_for_unreachable_block):
4412 * tree-flow.h (remove_phi_nodes, canonicalize_loop_ivs): Declared.
4413 * Makefile.in (graphite.o): Depend on value-prof.h.
4414 (graphite.o-warn): Removed -Wno-error.
4415 * tree-parloops.c (canonicalize_loop_ivs): Allow reduction_list
4416 to be a NULL pointer. Call update_stmt. Return the newly created
4417 cannonical induction variable.
4419 * graphite.h (debug_rename_map): Declared. Fix some comments.
4421 * graphite.c: Reimplement the code generation from graphite to gimple.
4422 Include value-prof.h.
4423 (loop_iv_stack_get_iv): Do not return NULL for constant substitutions.
4424 (get_old_iv_from_ssa_name): Removed.
4425 (graphite_stmt_p): New.
4426 (new_graphite_bb): Test for useful statements before building a
4427 graphite statement for the basic block.
4428 (free_graphite_bb): Do not free GBB_DATA_REFS: this is a bug
4429 in free_data_ref that calls BITMAP_FREE (DR_VOPS (dr)) without
4431 (recompute_all_dominators, graphite_verify,
4432 nb_reductions_in_loop, graphite_loop_normal_form): New.
4433 (scop_record_loop): Call graphite_loop_normal_form.
4434 (build_scop_loop_nests): Iterate over all the blocks of the
4435 function instead of relying on the incomplete information from
4436 SCOP_BBS. Return the success of the operation.
4437 (find_params_in_bb): Use the data from GBB_DATA_REFS.
4438 (add_bb_domains): Removed.
4439 (build_loop_iteration_domains): Don't call add_bb_domains.
4440 Add the iteration domain only to the basic blocks that have been
4441 translated to graphite.
4442 (build_scop_conditions_1): Add constraints only if the basic
4443 block have been translated to graphite.
4444 (build_scop_data_accesses): Completely disabled until data
4445 dependence is correctly implemented.
4446 (debug_rename_elt, debug_rename_map_1, debug_rename_map): New.
4447 (remove_all_edges_1, remove_all_edges): Removed.
4448 (get_new_name_from_old_name): New.
4449 (graphite_rename_variables_in_stmt): Renamed
4450 rename_variables_in_stmt. Call get_new_name_from_old_name.
4451 Use replace_exp and update_stmt.
4452 (is_old_iv): Renamed is_iv.
4453 (expand_scalar_variables_stmt): Extra parameter for renaming map.
4454 Use replace_exp and update_stmt.
4455 (expand_scalar_variables_expr): Same. Use the map to get the
4456 new names for the renaming of induction variables and for the
4457 renaming of variables after a basic block has been copied.
4458 (expand_scalar_variables): Same.
4459 (graphite_rename_variables): Renamed rename_variables.
4460 (move_phi_nodes): Removed.
4461 (get_false_edge_from_guard_bb): New.
4462 (build_iv_mapping): Do not insert the induction variable of a
4463 loop in the renaming iv map if the basic block does not belong
4465 (register_old_new_names, graphite_copy_stmts_from_block,
4466 copy_bb_and_scalar_dependences): New.
4467 (translate_clast): Heavily reimplemented: copy basic blocks,
4468 do not move them. Finally, in call cleanup_tree_cfg in gloog.
4469 At each translation step call graphite_verify ensuring the
4470 consistency of the SSA, loops and dominators information.
4471 (collect_virtual_phis, find_vdef_for_var_in_bb,
4472 find_vdef_for_var_1, find_vdef_for_var,
4473 patch_phis_for_virtual_defs): Removed huge hack.
4474 (mark_old_loops, remove_dead_loops, skip_phi_defs,
4475 collect_scop_exit_phi_args, patch_scop_exit_phi_args,
4476 gbb_can_be_ignored, scop_remove_ignoreable_gbbs, ): Removed.
4477 (remove_sese_region, ifsese, if_region_entry, if_region_exit,
4478 if_region_get_condition_block, if_region_set_false_region,
4479 create_if_region_on_edge, move_sese_in_condition, bb_in_sese_p,
4480 sese_find_uses_to_rename_use, sese_find_uses_to_rename_bb,
4481 sese_add_exit_phis_edge, sese_add_exit_phis_var,
4482 rewrite_into_sese_closed_ssa): New.
4483 (gloog): Remove dead code. Early return if code cannot be
4484 generated. Call cleanup_tree_cfg once the scop has been code
4486 (graphite_trans_scop_block, graphite_trans_loop_block): Do not
4487 block loops with less than two loops.
4488 (graphite_apply_transformations): Remove the call to
4489 scop_remove_ignoreable_gbbs.
4490 (limit_scops): When build_scop_loop_nests fails, continue on
4491 the next scop. Fix open_scop.entry.
4492 (graphite_transform_loops): Call recompute_all_dominators: force the
4493 recomputation of correct CDI_DOMINATORS and CDI_POST_DOMINATORS.
4494 Call initialize_original_copy_tables and free_original_copy_tables
4495 to be able to copy basic blocks during code generation.
4496 When build_scop_loop_nests fails, continue on next scop.
4497 (value_clast): New union.
4498 (clast_to_gcc_expression): Fix type cast warning.
4500 2008-11-09 Sebastian Pop <sebastian.pop@amd.com>
4502 * Merge from mainline (r140838:141727).
4504 2008-11-05 Tobias Grosser <grosser@fim.uni-passau.de>
4508 * graphite.c (scan_tree_for_params): Add POINTER_PLUS_EXPR.
4510 2008-11-05 Tobias Grosser <grosser@fim.uni-passau.de>
4514 * graphite.c (scopdet_basic_block_info): Fix loops with multiple
4515 exits and conditions.
4516 * testsuite/gcc.dg/graphite/pr37943.c: New.
4518 2008-10-23 Tobias Grosser <grosser@fim.uni-passau.de>
4521 * graphite.c (gloog): Replace EXIT_BLOCK_PTR with scop exit.
4523 2008-10-23 Tobias Grosser <grosser@fim.uni-passau.de>
4525 * doc/invoke.texi: Fix spaces.
4527 2008-10-22 Sebastian Pop <sebastian.pop@amd.com>
4529 PR tree-optimization/37891
4530 Reverted last commit.
4531 * graphite.c (create_single_entry_edge): Set
4532 EDGE_IRREDUCIBLE_LOOP and BB_IRREDUCIBLE_LOOP.
4534 2008-10-21 Sebastian Pop <sebastian.pop@amd.com>
4535 Mitul Thakkar <mitul.thakkar@amd.com>
4537 * graphite.c (create_single_entry_edge): Set
4538 EDGE_IRREDUCIBLE_LOOP and BB_IRREDUCIBLE_LOOP.
4540 2008-10-16 Tobias Grosser <grosser@fim.uni-passau.de>
4542 * doc/invoke.texi: Add -fgraphite-identity.
4543 * graphite.c (graphite_apply_transformations): Check for
4544 -fgraphite-identity.
4545 * toplev.c (process_options): Add flag_graphite_identity.
4546 * tree-ssa-loop.c: Add flag_graphite_identity.
4548 2008-10-14 Sebastian Pop <sebastian.pop@amd.com>
4550 Undo changes from 2008-10-02:
4551 * tree-ssa-loop-ivopts.c (rewrite_use_nonlinear_expr): Convert
4552 operand type when copying the operand to a variable of different type.
4553 * cfgloopmanip.c (create_empty_loop_on_edge): Write exit condition
4554 with the IV name after increment.
4556 2008-10-14 Sebastian Pop <sebastian.pop@amd.com>
4557 Harsha Jagasia <harsha.jagasia@amd.com>
4559 PR tree-optimization/37828
4560 * testsuite/gcc.dg/graphite/pr37828.c: New.
4561 * graphite.c (graphite_trans_loop_block): Do not loop block
4562 single nested loops.
4564 2008-10-09 Harsha Jagasia <harsha.jagasia@amd.com>
4565 Sebastian Pop <sebastian.pop@amd.com>
4567 * graphite.c (struct rename_map_elt, new_rename_map_elt,
4568 rename_map_elt_info, eq_rename_map_elts): New.
4569 (graphite_rename_ivs_stmt): Renamed graphite_rename_variables_in_stmt.
4570 (expand_scalar_variables_expr): Change parameters.
4571 (expand_scalar_variables_stmt): Same.
4572 (expand_scalar_variables): Same.
4573 (graphite_rename_ivs): Rename graphite_rename_variables.
4574 (build_iv_mapping): New.
4575 (translate_clast): Call build_iv_mapping.
4576 * graphite.h (gbb_p): New name.
4578 2008-10-03 Harsha Jagasia <harsha.jagasia@amd.com>
4580 PR tree-optimization/37684
4581 * gcc.dg/graphite/pr37684.c: New.
4582 * graphite.c (exclude_component_ref): New.
4583 (is_simple_operand): Call exclude_component_ref.
4585 2008-10-02 Jan Sjodin <jan.sjodin@amd.com>
4586 Harsha Jagasia <harsha.jagasia@amd.com>
4588 PR tree-optimization/37485
4589 * gcc.dg/graphite/block-2.c: New
4590 * graphite.c (gmp_cst_to_tree): Moved.
4591 (iv_stack_entry_is_constant): New.
4592 (iv_stack_entry_is_iv): New.
4593 (loop_iv_stack_push): Renamed to loop_iv_stack_push_iv.
4594 (loop_iv_stack_insert_constant): New.
4595 (loop_iv_stack_pop): Use new datatpype.
4596 (loop_iv_stack_get_iv): Same.
4597 (loop_iv_stack_get_iv_from_name): Same.
4598 (loop_iv_stack_debug): Renamed to debug_loop_iv_stack.
4599 (loop_iv_stack_patch_for_consts): New.
4600 (loop_iv_stack_remove_constants): New.
4601 (graphite_create_new_loop): Use loop_iv_stack_push_iv.
4602 (translate_clast): Call loop_iv_stack_patch_for_consts and
4603 loop_iv_stack_remove_constants.
4604 (gloog): Use new datatype. Redirect construction edge to end
4605 block to avoid accidental deletion.
4606 * graphite.h (enum iv_stack_entry_kind): New. Tag for data in
4608 (union iv_stack_entry_data): New. Data in iv stack entry.
4609 (struct iv_stack_entry): New. Datatype for iv stack entries.
4611 2008-10-02 Sebastian Pop <sebastian.pop@amd.com>
4613 * tree-ssa-loop-ivopts.c (rewrite_use_nonlinear_expr): Convert
4614 operand type when copying the operand to a variable of different type.
4616 2008-10-02 Sebastian Pop <sebastian.pop@amd.com>
4618 * cfgloopmanip.c (create_empty_loop_on_edge): Write exit condition
4619 with the IV name after increment.
4621 2008-10-02 Sebastian Pop <sebastian.pop@amd.com>
4623 * Merge from mainline (r140164:140838).
4625 2008-09-10 Konrad Trifunovic <konrad.trifunovic@inria.fr>
4627 * graphite-data-ref.c: New.
4628 * graphite.c (print_scop): Also dump the dependence graph.
4629 (bb_in_scop_p, loop_in_scop_p, nb_loops_around_gb): Moved...
4630 (new_scop): Initialize SCOP_DEP_GRAPH.
4631 (build_scop_dynamic_schedules): New.
4632 (build_access_matrix_with_af): Fixed column numbering.
4633 (graphite_transform_loops): Call build_scop_dynamic_schedules.
4634 * graphite.h: Add ifndef/define guards against multiple inclusion.
4635 (struct scop): Add dep_graph field.
4636 (SCOP_DEP_GRAPH): Defined.
4637 (ref_nb_loops): Fixed and moved to other position.
4638 (bb_in_scop_p, loop_in_scop_p, nb_loops_around_gb): ... here.
4639 (nb_loops_around_loop_in_scop): New.
4640 (graphite_dump_dependence_graph): Declared.
4641 (graphite_build_rdg_all_levels): Declared.
4642 (graphite_test_dependence): Declared.
4643 * Makefile.in (graphite-data-ref.o): New target.
4645 2008-09-09 Sebastian Pop <sebastian.pop@amd.com>
4647 * Merge from mainline (139870:140164).
4649 2008-09-01 Sebastian Pop <sebastian.pop@amd.com>
4651 * Merge from mainline (138275:139870).
4652 * testsuite/gcc.dg/graphite/scop-matmult.c: XFailed as one of
4653 the commits from trunk broke the niter detection.
4655 2008-09-01 Sebastian Pop <sebastian.pop@amd.com>
4657 * graphite.c: Add more documentation. Fix formatting.
4658 (debug_loop_vec, debug_oldivs, loop_iv_stack,
4659 loop_iv_stack_debug): Moved...
4660 (schedule_to_scattering): Move before use.
4661 (dot_all_scops): Include in "#if 0" the code for system
4664 * graphite.h: (debug_loop_vec, debug_oldivs, loop_iv_stack,
4665 loop_iv_stack_debug): ...here.
4667 2008-08-29 Jan Sjodin <jan.sjodin@amd.com>
4669 * tree-phinodes.c (make_phi_node): Extern.
4670 (add_phi_node_to_bb): New.
4671 (create_phi_node): Call add_phi_node_to_bb.
4672 * tree-ssa-loop-ivopts.c (get_phi_with_result): New.
4673 (remove_statement): Handle case where stored phi was updated
4674 and is no longer the same.
4675 * graphite.c (is_parameter): New.
4677 (expand_scalar_variables_expr): New.
4678 (expand_scalar_variables_stmt): New.
4679 (expand_scalar_variables): New.
4680 (move_phi_nodes): Create new phi instead of moving old one.
4681 (translate_clast): Call expand_scalar_variables.
4682 (find_vdef_for_var_in_bb): Also scan regular definitions.
4683 (skip_phi_defs): New.
4684 (collect_scop_exit_phi_args): New.
4685 (patch_scop_exit_phi_args): New.
4686 (gloog): Patch phis after scop.
4687 * tree-flow.h: (add_phi_node_to_bb): Declared.
4688 (make_phi_node): Declared.
4690 2008-08-26 Sebastian Pop <sebastian.pop@amd.com>
4692 * graphite.c (end_scop): Split the entry of the scop when it
4693 is the header of the loop in which the scop is ending.
4694 (build_scops_1, limit_scops): Update uses of end_scop.
4696 2008-08-26 Sebastian Pop <sebastian.pop@amd.com>
4698 * graphite.c (dot_all_scops_1): Do not fail on uninitialized
4699 SCOP_ENTRY or SCOP_EXIT.
4701 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
4703 * graphite.c (get_construction_edge): Removed.
4704 (gloog): Construction edge is the scop entry edge.
4706 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
4708 * graphite.c (can_generate_for_scop): Removed.
4709 (gloog): Do not call it.
4711 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
4713 * graphite.c (new_scop): Entry of a scop is an edge.
4714 Initialize SESE region.
4715 (free_scop): Free SESE region.
4716 (build_scops_1, scopdet_bb_info): Work on edges, not on bbs.
4717 (split_difficult_bb): New, split from end_scop.
4718 (end_scop): Exit of a scop is an edge.
4719 (build_scop_bbs): Never check CDI_POST_DOMINATORS: this info is
4720 not automatically updated and thus is always wrong.
4721 * graphite.h (struct sese): New.
4724 (struct scop): New field for a SESE region. Remove entry, exit.
4725 (SCOP_ENTRY, SCOP_EXIT): Update definitions to match same
4726 semantics as before. Moved comment around.
4728 2008-08-25 Tobias Grosser <grosser@fim.uni-passau.de>
4729 Sebastian Pop <sebastian.pop@amd.com>
4731 * graphite.c (graphite_transform_loops): Always enable gloog
4732 and find_transform when ENABLE_CHECKING.
4734 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
4736 * graphite.c (graphite_transform_loops): Move pretty printer
4737 of SCOPs before doing any transform. Remove call to print_scops
4738 and dot_all_scops_1.
4740 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
4742 * graphite.c (dump_gbb_conditions): Don't try to print NULL pointers.
4743 (print_graphite_bb): Same.
4745 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
4747 * graphite.c (dot_all_scops_1): Cleanup.
4748 (move_scops): Fix comment.
4750 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
4752 * graphite.c (build_scop_bbs): Revert commit 139355:
4754 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4755 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
4757 * graphite.c (build_scop_bbs): Factor up code.
4759 2008-08-25 Tobias Grosser <grosser@fim.uni-passau.de>
4761 * graphite.c (gloog): Update dominator info.
4763 2008-08-25 Tobias Grosser <grosser@fim.uni-passau.de>
4765 * graphite.c (remove_cond_exprs): Do not fail on empty bbs.
4767 2008-08-24 Sebastian Pop <sebastian.pop@amd.com>
4769 * graphite.c (new_graphite_bb): Remove GBB_INDEX_TO_NUM_MAP
4771 (free_graphite_bb): Remove GBB_INDEX_TO_NUM_MAP free.
4772 (translate_clast): Correct formatting.
4773 * graphite.h (struct num_map): Removed.
4774 (struct graphite_bb): Remove num_map field.
4775 (GBB_INDEX_TO_NUM_MAP): Removed.
4777 2008-08-24 Sebastian Pop <sebastian.pop@amd.com>
4779 * graphite.c (build_access_matrix_with_af): Fix comments.
4780 (build_scop_data_accesses): Same.
4782 2008-08-24 Sebastian Pop <sebastian.pop@amd.com>
4784 * graphite.c (build_scop_data_accesses): Don't construct
4785 access matrices. Add a FIXME and an assert condition that
4786 should pass when the access matrices will be needed.
4788 2008-08-24 Sebastian Pop <sebastian.pop@amd.com>
4790 * tree-data-ref.c (stmt_simple_memref_p): Don't call
4792 * graphite.c (build_graphite_bb): Renamed new_graphite_bb.
4793 Moved close by free_graphite_bb.
4794 (free_graphite_bb): Call free_data_refs. Reset bb->aux.
4795 (new_scop): Move close by free_scop.
4796 (graphite_transform_loops): Avoid linear scan to reset bb->aux.
4798 2008-08-22 Jan Sjodin <jan.sjodin@amd.com>
4800 * cfgloopmanip.c (create_empty_if_region_on_edge): New.
4801 * graphite.c (clast_to_gcc_expression): Call gmp_cst_to_tree
4802 instead of recursive call.
4803 (graphite_translate_clast_equation): New.
4804 (graphite_create_guard_cond_expr): New.
4805 (graphite_create_new_guard): New.
4806 (get_stack_index_from_iv): Removed.
4807 (graphite_rename_ivs_stmt): Use gbb_loop_index.
4808 (get_true_edge_from_guard_bb): New.
4809 (translate_clast): Handle stmt_guard in clast.
4810 (get_construction_edge): Allow construction edge detection for
4811 a scope entry with multiple predecessors if one predecessor is
4812 the immediate dominator of scope entry.
4813 (can_generate_code_stmt): Enable code generation for clast_guard.
4814 (gloog): Use correct context loop. Removed check for post dominators.
4815 * cfgloop.h (create_empty_if_region_on_edge): Declared.
4817 2008-08-21 Sebastian Pop <sebastian.pop@amd.com>
4819 * graphite.c (remove_dead_loops): Document better which
4822 2008-08-21 Sebastian Pop <sebastian.pop@amd.com>
4824 * Makefile.in: Rename POLYLIBLIBS and POLYLIBINC to PPLLIBS
4826 (graphite.o): Also depends on pointer-set.h.
4828 2008-08-21 Sebastian Pop <sebastian.pop@amd.com>
4830 * graphite.c (scop_record_loop): Fix compile warning.
4832 2008-08-21 Harsha Jagasia <harsha.jagasia@amd.com>
4833 Sebastian Pop <sebastian.pop@amd.com>
4835 * graphite.c (scop_record_loop): DECL_NAME can be NULL.
4837 2008-08-21 Sebastian Pop <sebastian.pop@amd.com>
4839 * graphite.c (build_graphite_bb): Initialize bb->aux to
4840 point to the graphite_bb_p.
4841 (graphite_bb_from_bb): Renamed gbb_from_bb; returns the
4843 (add_bb_domains): Does not use the scop parameter.
4844 (graphite_transform_loops): Clean bb->aux at the end.
4846 2008-08-20 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
4847 Sebastian Pop <sebastian.pop@amd.com>
4849 * testsuite/lib/target-supports.exp
4850 (check_effective_target_fgraphite): New.
4852 * testsuite/gcc.dg/graphite/graphite.exp: Early exit when
4853 check_effective_target_fgraphite returns false.
4854 Set dg-do-what-default to compile.
4855 (scan-graphite-dump-times): Removed.
4856 * testsuite/gfortran.dg/graphite/graphite.exp: Same.
4858 * testsuite/gcc.dg/graphite/scop-0.c: Do not use "dg-do compile".
4859 Use scan-tree-dump-times instead of scan-graphite-dump-times.
4860 * testsuite/gcc.dg/graphite/scop-1.c: Same.
4861 * testsuite/gcc.dg/graphite/scop-2.c: Same.
4862 * testsuite/gcc.dg/graphite/scop-3.c: Same.
4863 * testsuite/gcc.dg/graphite/scop-4.c: Same.
4864 * testsuite/gcc.dg/graphite/scop-5.c: Same.
4865 * testsuite/gcc.dg/graphite/scop-6.c: Same.
4866 * testsuite/gcc.dg/graphite/scop-7.c: Same.
4867 * testsuite/gcc.dg/graphite/scop-8.c: Same.
4868 * testsuite/gcc.dg/graphite/scop-9.c: Same.
4869 * testsuite/gcc.dg/graphite/scop-10.c: Same.
4870 * testsuite/gcc.dg/graphite/scop-11.c: Same.
4871 * testsuite/gcc.dg/graphite/scop-12.c: Same.
4872 * testsuite/gcc.dg/graphite/scop-13.c: Same.
4873 * testsuite/gcc.dg/graphite/scop-matmult.c: Same.
4874 * testsuite/gcc.dg/graphite/scop-14.c: Same.
4875 * testsuite/gcc.dg/graphite/scop-15.c: Same.
4876 * testsuite/gcc.dg/graphite/block-0.c: Same.
4877 * testsuite/gcc.dg/graphite/scop-16.c: Same.
4878 * testsuite/gcc.dg/graphite/block-1.c: Same.
4879 * testsuite/gcc.dg/graphite/scop-17.c: Same.
4880 * testsuite/gcc.dg/graphite/scop-18.c: Same.
4881 * testsuite/gfortran.dg/graphite/block-1.f90: Same.
4882 * testsuite/gfortran.dg/graphite/scop-1.f: Same.
4883 * testsuite/gfortran.dg/graphite/block-2.f: Same.
4885 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4887 * graphite.c: Fix some XXX comments.
4888 (build_scop_dynamic_schedules): Removed.
4890 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4892 * graphite.h (scop_max_loop_depth): Moved...
4893 * graphite.c (scop_max_loop_depth): ...here.
4894 (remove_all_edges_1): New.
4895 (remove_all_edges): Factored code.
4896 (remove_cond_exprs): Check only the last statement for
4897 a GIMPLE_COND expression.
4899 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4901 * graphite.c (scan_tree_for_params): Early return when the
4902 expression is a chrec_dont_know. Handle case NEGATE_EXPR.
4903 (find_scop_parameters): Factor out code.
4904 (graphite_trans_bb_strip_mine): Remove dead code.
4906 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4908 * graphite.c (clast_to_gcc_expression, graphite_create_new_loop,
4909 graphite_trans_bb_move_loop): Factor asserts.
4910 (gloog): Perform sanity checks only for ENABLE_CHECKING.
4911 Do not call calculate_dominance_info and estimate_bb_frequencies.
4913 2008-08-20 Jan Sjodin <jan.sjodin@amd.com>
4915 * graphite.c (create_loops_mapping, free_loops_mapping,
4916 create_loops_mapping_num, debug_loop_mapping_1,
4917 debug_loop_mapping, graphite_loops_mapping_max_loop_num,
4918 get_loop_mapping_for_num, graphite_loops_mapping_add_child,
4919 graphite_loops_mapping_add_child_num,
4920 graphite_loops_mapping_insert_child,
4921 graphite_loops_mapping_parent, get_loop_mapped_depth_for_num,
4922 get_loop_mapped_depth, split_loop_mapped_depth_for_num,
4923 loop_mapped_depth_split_loop, swap_loop_mapped_depth_for_num,
4924 create_num_from_index, get_num_from_index,
4925 swap_loop_mapped_depth): Removed.
4926 (new_scop): Do not initialize SCOP_LOOPS_MAPPING.
4927 (free_scop): Do not call free_loops_mapping.
4928 (graphite_get_new_iv_stack_index_from_old_iv): Renamed
4929 get_stack_index_from_iv. Use GBB_LOOPS instead of calling
4930 get_loop_mapped_depth.
4931 (graphite_trans_bb_move_loop): Do not update the loop mapping.
4932 (graphite_trans_bb_strip_mine): Same.
4933 * graphite.h (graphite_loops_mapping, graphite_loop_node): Removed.
4934 (struct scop): Remove field loops_mapping.
4936 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4937 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
4939 * graphite.c (scop_record_loop): Factor out one level of the
4940 condition by early return.
4941 (build_scop_loop_nests): Format following FSF coding style.
4942 (build_scop_dynamic_schedules): Factor out code.
4943 (scopdet_bb_info): Reindent. Default case should not be reachable.
4945 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4946 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
4948 * graphite.c (loop_affine_expr): Check for DECL_P or struct
4949 assignments that are not handled as simple operands for now.
4951 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4952 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
4954 * graphite.c (build_scop_bbs): Factor up code.
4956 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4957 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
4959 * graphite.c (stmt_simple_for_scop_p): Factor code out
4961 (enum gbb_type): New. Group all the GBB_* types under it.
4962 (is_loop_exit): Moved...
4963 (end_scop): Enable BB spliting.
4964 * cfgloop.c (is_loop_exit): ...here. Reimplemented.
4965 * cfgloop.h (is_loop_exit): Declared.
4967 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4969 * doc/invoke.texi: Remove strides from examples containing
4970 DO loops when the strides are equal to 1.
4972 2008-08-20 Harsha Jagasia <harsha.jagasia@amd.com>
4973 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
4975 * graphite.c (graphite_trans_scop_block): Or the result with
4976 the result from graphite_trans_loop_block.
4977 * testsuite/gcc.dg/graphite/block-1.c: New.
4978 * testsuite/gfortran.dg/graphite/block-1.f90: New.
4979 * testsuite/gfortran.dg/graphite/block-2.f: New.
4981 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4983 * graphite.c (graphite_transform_loops): Call cloog_initialize
4986 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4988 * tree-data-ref.c) (stmt_simple_memref_p): New.
4989 * tree-data-ref.h (stmt_simple_memref_p): Declared.
4990 * graphite.c (stmt_simple_memref_for_scop_p): Removed.
4991 (is_simple_operand): Call stmt_simple_memref_p.
4993 * testsuite/gcc.dg/graphite/scop-matmult.c: Updated for not
4994 using pointer arithmetic, as this is optimized by PRE and
4995 makes the code too difficult to analyze.
4997 * testsuite/gcc.dg/graphite/scop-18.c: Same.
4999 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5001 * gdbinit.in (pgg): New.
5003 2008-08-15 Tobias Grosser <grosser@fim.uni-passau.de>
5005 * graphite.c (graphite_trans_loop_block): Fix warning.
5007 2008-08-15 Tobias Grosser <grosser@fim.uni-passau.de>
5009 * graphite.c (graphite_trans_loop_block): Fix my merge error.
5011 2008-08-15 Tobias Grosser <grosser@fim.uni-passau.de>
5013 * graphite.c (graphite_trans_bb_block): Remove check for
5014 flag_loop_strip_mine, flag_loop_block, flag_loop_interchange.
5015 Check if loop blocking is profitable for every loop, before applying
5017 (graphite_apply_transformations): Call graphite_trans_bb_block only,
5018 if flag_loop_block is set.
5020 2008-08-14 Sebastian Pop <sebastian.pop@amd.com>
5022 * graphite.c: Add some more documentation for the loop
5025 2008-08-14 Sebastian Pop <sebastian.pop@amd.com>
5027 * Makefile.in (tree-data-ref.o): Remove dependence on graphite.h.
5028 * graphite.c: Format on less than 80 columns.
5031 2008-08-14 Sebastian Pop <sebastian.pop@amd.com>
5033 * cfgloopmanip.c (loopify): Use update_dominators_in_loop.
5035 2008-08-14 Sebastian Pop <sebastian.pop@amd.com>
5037 * doc/invoke.texi (floop-block, floop-strip-mine,
5038 floop-interchange): Update documentation with examples.
5040 2008-08-13 Sebastian Pop <sebastian.pop@amd.com>
5042 * cfgloopmanip.c (create_empty_loop_on_edge): Don't call
5044 * graphite.c (graphite_create_new_loop): Call add_referenced_var.
5046 2008-08-13 Sebastian Pop <sebastian.pop@amd.com>
5048 * cfgloopmanip.c (create_empty_loop_on_edge): Improve documentation.
5049 Factor gcc_asserts into a single one. Use force_gimple_operand_gsi.
5050 * tree-scalar-evolution.c: Revert useless changes.
5051 * tree-phinodes.c: Same.
5054 * tree-vectorizer.h: Same.
5055 * tree-flow.h: Same.
5057 * common.opt (fgraphite): Update documentation.
5059 2008-08-12 Harsha Jagasia <harsha.jagasia@amd.com>
5061 * doc/invoke.texi (-floop-block, -floop-strip-mine,
5062 -floop-interchange): Add more text for explaining what each of these
5064 * tree-into-ssa.c (gimple_vec): Moved to...
5065 * graphite.c: Include gimple.h.
5066 (gimple_vec): Moved to...
5067 (del_loop_to_cloog_loop): Removed.
5068 (loop_affine_expr): Do not call create_data_ref when the
5069 operand is a constant.
5070 (new_scop): Use free instead of del_loop_to_cloog_loop.
5071 * Makefile.in (graphite.o): Depend on GIMPLE_H.
5072 * gimple.h (gimple_vec): ... here.
5074 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5076 * graphite.c (scopdet_bb_info): Only allow loops with known number of
5078 (build_loop_iteration_domains): Fail, if latch executions unknown.
5080 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5082 * graphite.c (add_conditions_to_domain): New.
5083 (build_scop_conditions_1): Call add_conditions_to_domain.
5084 (set_cloog_options): Allow to disable optimizations.
5086 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5088 * graphite.c (find_params_in_bb): Look for parameters in conditions.
5089 Do not use walk_dominator_tree.
5090 (find_scop_parameters): Do not use walk_dominator_tree.
5092 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5094 * graphite.c (scan_tree_for_params) Add / Subtract inequality.
5095 (idx_record_params): Adapt.
5096 * graphite.h (scop_gimple_loop_depth): New.
5098 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5100 * graphite.c (build_scop_dynamic_schedules): Remove value_init.
5101 (scan_tree_for_params): Remove value_init.
5102 (build_scop_context): Remove value_init.
5103 (build_loop_iteration_domains): Remove value_init.
5104 (schedule_to_scattering): Remove value_init.
5105 (graphite_trans_bb_strip_mine): Remove value_init.
5107 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5109 * gcc/graphite.c (limit_scops): New.
5110 (graphite_transform_loops): Add limit SCoPs.
5111 * gcc/testsuite/gcc.dg/graphite/scop-0.c: Update number of SCoPs.
5112 * gcc/testsuite/gcc.dg/graphite/scop-1.c: Update number of SCoPs.
5113 * gcc/testsuite/gcc.dg/graphite/scop-10.c: Update number of SCoPs.
5114 * gcc/testsuite/gcc.dg/graphite/scop-11.c: Update number of SCoPs.
5115 * gcc/testsuite/gcc.dg/graphite/scop-12.c: Update number of SCoPs.
5116 * gcc/testsuite/gcc.dg/graphite/scop-13.c: Update number of SCoPs.
5117 * gcc/testsuite/gcc.dg/graphite/scop-14.c: Update number of SCoPs.
5118 * gcc/testsuite/gcc.dg/graphite/scop-15.c: Update number of SCoPs.
5119 * gcc/testsuite/gcc.dg/graphite/scop-16.c: Update number of SCoPs.
5120 Change loop numbers.
5121 * gcc/testsuite/gcc.dg/graphite/scop-17.c: Update number of SCoPs.
5122 Change loop numbers.
5123 * gcc/testsuite/gcc.dg/graphite/scop-18.c: Update number of SCoPs.
5124 * gcc/testsuite/gcc.dg/graphite/scop-2.c: Update number of SCoPs.
5125 * gcc/testsuite/gcc.dg/graphite/scop-3.c: Update number of SCoPs.
5126 * gcc/testsuite/gcc.dg/graphite/scop-4.c: Update number of SCoPs.
5127 * gcc/testsuite/gcc.dg/graphite/scop-5.c: Update number of SCoPs.
5128 * gcc/testsuite/gcc.dg/graphite/scop-6.c: Update number of SCoPs.
5129 * gcc/testsuite/gcc.dg/graphite/scop-7.c: Update number of SCoPs.
5130 * gcc/testsuite/gcc.dg/graphite/scop-8.c: Update number of SCoPs.
5131 * gcc/testsuite/gcc.dg/graphite/scop-9.c: Update number of SCoPs.
5132 * gcc/testsuite/gcc.dg/graphite/scop-matmult.c: Update number of SCoPs.
5134 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5136 * graphite.c (graphite_transform_loops): Call always find_transform.
5138 2008-08-08 Tobias Grosser <grosser@fim.uni-passau.de>
5140 * graphite.c (free_loops_mapping): New.
5141 (stmt_simple_for_scop_p): Fix typo.
5142 (stmt_simple_for_scop_p): Fix tuples functions, that
5144 (free_graphite_bb): Fix some memleaks.
5145 (free_scop): Fix some memleaks.
5146 (scopdet_bb_info): Do not forget some tmp SCoPs.
5147 (find_params_in_bb): Fix some memleaks.
5148 (clast_to_gcc_expression): Fix warning.
5150 2008-08-07 Tobias Grosser <grosser@fim.uni-passau.de>
5152 * testsuite/gcc.dg/graphite/scop-16.c: Fix for 32bit.
5153 * testsuite/gcc.dg/graphite/scop-17.c: Fix for 32bit.
5155 2008-08-04 Sebastian Pop <sebastian.pop@amd.com>
5157 * tree-ssa-loop.c (tree-ssa-loop.o): Do not include toplev.h.
5158 Move code ifdef-ed HAVE_cloog...
5159 * graphite.c: Include toplev.h.
5161 * Makefile.in (OBJS-common): Always build graphite.o.
5162 (BACKEND): Remove @GRAPHITE@.
5163 (tree-ssa-loop.o): Do not depend on TOPLEV_H.
5164 (graphite.o): Depend on TOPLEV_H.
5166 2008-08-04 Sebastian Pop <sebastian.pop@amd.com>
5168 * Makefile.in (tree-ssa-loop.o): Depend on TOPLEV_H.
5169 Remove typo left from polylib to ppl conversion.
5170 * graphite.c (graphite_transforms): Use sorry instead of fatal.
5172 2008-08-03 Sebastian Pop <sebastian.pop@amd.com>
5174 * toplev.c (process_options): Move the graphite loop optimization
5176 * tree-ssa-loop.c (graphite_transforms): ... here.
5177 When not configured with CLooG, print to dump_file that
5178 Graphite transforms were not performed.
5179 * testsuite/gcc.dg/graphite/graphite.exp (scan-graphite-dump-times):
5181 * testsuite/gcc.dg/graphite/*.c: Updated all testcases to use
5182 scan-graphite-dump-times.
5184 2008-08-03 Sebastian Pop <sebastian.pop@amd.com>
5186 * graphite.c (dot_scop, dot_all_scops): Do not call system.
5187 Do not open /tmp/scop.dot and /tmp/allscops.dot.
5189 2008-08-02 Sebastian Pop <sebastian.pop@amd.com>
5190 Jan Sjodin <jan.sjodin@amd.com>
5192 * configure: Regenerated.
5193 * omp-low.c (expand_omp_sections): Remove now unused code.
5194 * config.in (HAVE_polylib): Removed.
5195 * configure.ac (HAVE_polylib, POLYLIBLIBS, POLYLIBINC): Removed.
5196 (PPLLIBS, PPLINC): Added.
5197 * graphite.c: Replace unsigned with int wherever possible.
5198 Don't access Cloog's data structures, but use accessor functions.
5199 Clast's stmt->type is now implemented as a vtable: change the
5200 switches of stmt->type into ifs.
5201 (polylib/polylibgmp.h): Don't include.
5202 (initialize_dependence_polyhedron,
5203 initialize_data_dependence_polyhedron, is_empty_polyhedron,
5204 statement_precedes_p, test_dependence, build_rdg_all_levels,
5205 dump_dependence_graph): Removed until this code is cleaned up
5207 * Makefile.in (POLYLIBLIBS): Renamed PPLLIBS.
5208 (POLYLIBINC): Renamed PPLINC.
5210 2008-08-01 Harsha Jagasia <harsha.jagasia@amd.com>
5211 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
5212 Jan Sjodin <jan.sjodin@amd.com>
5214 Finish the merge and tuplification of graphite.
5216 2008-07-24 Sebastian Pop <sebastian.pop@amd.com>
5217 Jan Sjodin <jan.sjodin@amd.com>
5219 Partial merge from mainline (138072:138275).
5220 * graphite.c still has to be tuplified.
5222 2008-07-29 Jan Sjodin <jan.sjodin@amd.com>
5224 * graphite.c (graphite_loops_mapping_max_loop_num): New.
5225 (create_num_from_index): New.
5226 (get_num_from_index): Also pass in the graphite BB.
5227 (free_graphite_bb): Free GBB_INDEX_TO_NUM_MAP.
5228 (build_graphite_bb): Initialize GBB_INDEX_TO_NUM_MAP.
5229 (graphite_trans_bb_strip_mine): Call create_num_from_index.
5230 (is_interchange_valid): Return false when failing.
5231 * graphite.h (struct num_map): New.
5232 (struct graphite_bb): New field num_map.
5233 (GBB_LOOPS_MAPPING): Renamed GBB_INDEX_TO_NUM_MAP.
5235 2008-07-29 Tobias Grosser <grosser@fim.uni-passau.de>
5237 * graphite.c (dump_gbb_conditions): Print also conditions like
5238 "if (a)". Remove dublicated code and use print_generic_expr ().
5239 (stmt_simple_for_scop_p): Only allow conditions we can handle
5242 2008-07-25 Jan Sjodin <jan.sjodin@amd.com>
5244 * graphite.h (struct scop): Removed new_ivs field.
5245 (SCOP_NEWIVS): Deleted.
5246 * graphite.c (new_scop, free_scop, clast_name_to_gcc,
5247 clast_to_gcc_expression, graphite_create_new_loop):
5248 Removed use of new_ivs.
5250 2008-07-25 Jan Sjodin <jan.sjodin@amd.com>
5252 * graphite.c (debug_oldivs, debug_loop_vec, create_loops_mapping,
5253 create_loops_mapping_num, debug_loop_mapping_1): New.
5254 (debug_loop_mapping): Call debug_loop_mapping_1.
5255 (get_loop_mapping_for_num,
5256 graphite_loops_mapping_add_child,
5257 graphite_loops_mapping_add_child_num,
5258 graphite_loops_mapping_insert_child,
5259 graphite_loops_mapping_parent,
5260 split_loop_mapped_depth_for_num,
5261 loop_mapped_depth_split_loop): New.
5262 (increment_loop_mapped_depths): Removed.
5263 (swap_loop_mapped_depth_for_num): Reimplemented.
5264 (new_scop): Call create_loops_mapping.
5265 (scop_record_loop): Call graphite_loops_mapping_insert_child.
5266 (translate_clast): Pass the old loop father in parameter, and pass
5267 it to get_old_iv_from_ssa_name.
5268 (remove_edges_around_useless_blocks, can_generate_code_stmt,
5269 can_generate_code, can_generate_for_scop): New.
5270 (graphite_trans_bb_block): Returns false when it fails to transform.
5271 * graphite.h (graphite_loop_node, graphite_loops_mapping): New.
5273 2008-07-25 Sebastian Pop <sebastian.pop@amd.com>
5275 Reverted all the changes related to the streamization and
5277 These changes are now tracked in the streamization branch.
5279 2008-07-25 Sebastian Pop <sebastian.pop@amd.com>
5280 Jan Sjodin <jan.sjodin@amd.com>
5282 * graphite.c (gbb_compare): Correctly constify.
5283 (gbb_can_be_ignored): Indent.
5284 (graphite_trans_scop_swap_1and2): Add legality check.
5287 2008-07-25 Sebastian Pop <sebastian.pop@amd.com>
5289 Remove fallouts from "Reverted the Condate changes".
5290 * tree.h: Remove unused decl.
5291 * testsuite/gcc.dg/tree-checker: Same.
5292 * timevar.def: Remove counter.
5294 2008-07-24 Sebastian Pop <sebastian.pop@amd.com>
5296 * Merge from mainline (135673:138072).
5298 Reverted the MIRO changes (from 2008-04-05) that are now
5299 tracked in the miro branch.
5300 * tree-bounds.c: Removed.
5301 * tree-bounds.h: Removed.
5303 Reverted the Condate changes (from 2006-07-04, 2007-03-20) that
5304 are now tracked in the condate branch.
5305 * tree-check.c: Removed.
5306 * tree-match.c: Removed.
5307 * condate.y: Removed.
5309 2008-07-24 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
5311 * common.opt: New user flag -floop-block, -floop-strip-mine
5312 and -floop-interchange.
5313 * toplev.c (process_options): Enable -fgraphite pass if any one of the
5314 graphite loop optimization flags is turned on.
5315 * graphite.c (graphite_apply_transformations): Add flag_loop_block,
5316 flag_loop_strip_mine and flag_loop_interchange checks before
5318 * doc/invoke.texi: Remove -fgraphite and add -floop-block,
5319 -floop-strip-mine and -floop-interchange.
5320 * testsuite/gcc.dg/graphite/block-0.c: Add -floop-block and remove
5322 * testsuite/gcc.dg/graphite/scop-16.c: Ditto.
5323 * testsuite/gcc.dg/graphite/scop-17.c: Ditto.
5324 * testsuite/gcc.dg/graphite/scop-18.c: Ditto.
5326 2008-07-23 Jan Sjodin <jan.sjodin@amd.com>
5327 Sebastian Pop <sebastian.pop@amd.com>
5329 * cfgloopmanip.c (update_dominators_in_loop): Make it static.
5330 (create_empty_loop_on_edge): More fixes.
5331 * tree-phinodes.c (resize_phi_node): Extern.
5332 (unlink_phi_node, move_phi_node): New split from remove_phi_node.
5333 * cfghooks.c (update_dominator_information): New split from
5335 * tree-vectorizer.c (rename_variables_in_bb): Extern.
5336 * tree-dfa.c (collect_dfa_stats): Start walking the CFG on the
5337 successor of the function entry block.
5339 * graphite.c: Include pointer-set.h.
5340 (debug_loop_mapping, increment_loop_mapped_depths,
5341 get_loop_mapped_depth_for_num, get_loop_mapped_depth,
5342 set_loop_mapped_depth_for_num, set_loop_mapped_depth,
5343 swap_loop_mapped_depth_for_num, get_num_from_index,
5344 swap_loop_mapped_depth, loop_iv_stack_debug,
5345 loop_iv_stack_push, loop_iv_stack_pop, loop_iv_stack_get_iv,
5346 loop_iv_stack_get_iv_from_name, loop_iv_stack_debug,
5347 get_old_iv_from_ssa_name): New.
5348 (new_scop): Initialize SCOP_LOOPS_MAPPING.
5349 (free_scop): Free SCOP_LOOPS_MAPPING.
5350 (scop_record_loop): Record old ivs.
5351 (create_var_name): Removed.
5352 (initialize_cloog_names): Allocate double space in case strip mine
5353 applies to all loops once.
5354 (clast_name_to_gcc): Look up in the map ivstack passed in parameter.
5355 (clast_to_gcc_expression): Same. Implement more clast to gimple
5357 (graphite_create_new_loop): Pass in ivstack.
5358 (remove_all_edges): Pass in the construction_edge.
5359 (graphite_remove_iv): Removed.
5360 (graphite_rename_ivs, graphite_rename_ivs_stmt,
5361 remove_cond_exprs): Rewritten.
5362 (move_phi_nodes): New.
5363 (disconnect_virtual_phi_nodes, disconnect_cond_expr): Removed.
5364 (translate_clast): Pass in ivstack. Rewrite some cases.
5365 (set_cloog_options, debug_clast_stmt): New.
5366 (find_transform): Use set_cloog_options.
5367 (outermost_loop_layer): Removed.
5368 (get_construction_edge, collect_virtual_phis, find_vdef_for_var_in_bb,
5369 find_vdef_for_var_1, find_vdef_for_var, patch_phis_for_virtual_defs,
5370 mark_old_loops, remove_dead_loops): New.
5372 (graphite_trans_bb_move_loop): Call swap_loop_mapped_depth.
5373 (const_column_index, get_first_matching_sign_row_index,
5374 get_lower_bound_row, get_upper_bound_row, get_lower_bound,
5375 get_upper_bound): New.
5376 (graphite_trans_bb_strip_mine): Also update the iv map.
5378 * graphite.h (graphite_loops_mapping, GBB_LOOPS_MAPPING): New.
5379 (struct name_tree): Add a loop field.
5380 (struct scop): Add a graphite_loops_mapping field.
5381 (SCOP_LOOPS_MAPPING): New.
5382 (debug_clast_stmt): Declare.
5383 * lambda.h (find_induction_var_from_exit_cond): Declare.
5384 (lambda-code.c): (find_induction_var_from_exit_cond): Extern.
5385 * cfgloop.h (update_dominators_in_loop): Removed declaration.
5386 (create_empty_loop_on_edge): Updated.
5387 * tree-flow.h (remove_bb, resize_phi_node, move_phi_node,
5388 rename_variables_in_bb): Declare.
5389 * tree-cfg.c (remove_bb): Extern.
5391 * testsuite/gcc.dg/graphite/block-0.c: New.
5393 2008-07-21 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
5394 Sebastian Pop <sebastian.pop@amd.com>
5396 * graphite.c (strip_mine_profitable_p): New.
5397 (graphite_trans_bb_block): Disable strip mining if not profitable.
5399 * testsuite/gcc.dg/graphite/scop-18.c: New.
5400 * testsuite/gcc.dg/graphite/scop-17.c: Fixed.
5401 * testsuite/gcc.dg/graphite/scop-16.c: Fixed.
5403 2008-07-17 Harsha Jagasia <harsha.jagasia@amd.com>
5404 Jan Sjodin <jan.sjodin@amd.com>
5405 Sebastian Pop <sebastian.pop@amd.com>
5407 * graphite.c (is_interchange_valid): New.
5408 (graphite_trans_bb_block): Check loop nest of basic block for legality
5411 * graphite.h (gbb_inner_most_loop_index, outer_most_loop_1,
5412 outer_most_loop, gbb_outer_most_loop_index): New.
5414 * tree-loop-linear.c (perfect_loop_nest_depth): Remove static.
5415 * tree-flow.h (perfect_loop_nest_depth): Declare as extern.
5416 * testsuite/gcc.dg/graphite/scop-16.c: New.
5417 * testsuite/gcc.dg/graphite/scop-17.c: New.
5419 2008-07-11 Tobias Grosser <grosser@fim.uni-passau.de>
5421 * graphite.c (scop_remove_ignoreable_gbbs): Also update bitmap.
5422 (graphite_trans_scop_block): Ignore SCoPs without bbs.
5424 2008-07-11 Tobias Grosser <grosser@fim.uni-passau.de>
5426 * graphite.c (new_scop): Initialize SCOP_EXIT.
5427 (scopdet_info): Add.
5428 (scopdet_bb_info): Rename from is_bb_addable. Cleanup, bugfixes.
5429 (build_scops_1): Cleanup, bugfixes.
5430 (build_scops): Cleanup.
5432 * testsuite/gcc.dg/graphite/scop-matmult.c: Remove duplicated code.
5433 * testsuite/gcc.dg/graphite/scop-15.c: Add SCoP numbers.
5435 2008-07-10 Harsha Jagasia <harsha.jagasia@amd.com>
5437 * testsuite/gfortran.dg/graphite/scop-1.f: Update to reduced test case.
5439 * testsuite/gfortran.dg/graphite/graphite.exp: Use
5440 DEFAULT_GRAPHITE_FLAGS.
5442 * testsuite/gcc.dg/graphite/scop-15.c: Update to reduced test case.
5444 2008-07-10 Harsha Jagasia <harsha.jagasia@amd.com>
5446 * graphite.c (scan_tree_for_params): Do not assert any more if
5447 MULT_EXPR parameter is negative.
5449 * testsuite/gfortran.dg/graphite/scop-1.f: New.
5451 * testsuite/gfortran.dg/graphite/graphite.exp: New.
5453 * testsuite/gcc.dg/graphite/scop-15.c: New.
5455 2008-07-10 Harsha Jagasia <harsha.jagasia@amd.com>
5457 * graphite.c (is_bb_addable): Fix segfault in spec gzip and reformat.
5459 2008-07-10 Tobias Grosser <grosser@fim.uni-passau.de>
5461 * graphite.c (graphite_trans_bb_swap_loops): Rename from
5462 graphite_swap_loops.
5463 (graphite_trans_bb_move_loop): New.
5464 (graphite_trans_bb_strip_mine): Rename from graphite_strip_mine_loop.
5465 (graphite_trans_bb_block): New.
5466 (graphite_trans_loop_block): New.
5467 (graphite_trans_scop_swap_1and2): Rename from
5468 graphite_trans_swap_1and2.
5469 (graphite_trans_scop_strip): Rename from graphite_trans_strip.
5470 (graphite_trans_scop_block): New.
5471 (graphite_apply_transformations): Rename from
5472 graphite_transformations.
5474 * testsuite/gcc.dg/graphite/scop-matmult.c: New.
5476 2008-07-10 Tobias Grosser <grosser@fim.uni-passau.de>
5478 * graphite.c (gbb_compare): New.
5479 (graphite_sort_gbbs): New.
5480 (gbb_can_be_ignored): New.
5481 (scop_remove_ignoreable_gbbs): New.
5482 (graphite_transformations): Cleanup and add
5483 scop_remove_ignoreable_gbbs.
5484 * lambda.h (lambda_vector_compare): New.
5486 2008-07-09 Tobias Grosser <grosser@fim.uni-passau.de>
5488 * graphite.c (print_graphite_bb): Correct printing of static schedule.
5489 (graphite_swap_loops): int -> unsigned
5490 (graphite_strip_mine_loop): int -> unsigned, Fix SCHEDULE
5491 (graphite_transformations): New.
5492 (graphite_transform_loops): Move to graphite_transformations.
5493 * graphite.h (gbb_nb_loops): Return unsigned.
5495 2008-07-04 Tobias Grosser <grosser@fim.uni-passau.de>
5497 * graphite.c (scan_tree_for_params): Fix insertion of parameters into
5498 the domain matrix. This makes scop-0.c work again.
5500 2008-06-20 Richard Guenther <rguenther@suse.de>
5502 * graphite.h: Adjust copyright to GPLv3.
5503 * graphite.c: Likewise.
5504 (stmt_simple_memref_for_scop_p): Split out from ...
5505 (stmt_simple_for_scop_p): ... here. Fix handling of calls
5507 (get_bb_type): Optimize.
5509 (is_bb_addable): Fix memleak, replace is_pred call with
5511 (build_scops): Use current_loops.
5512 (param_index): Fix memleak.
5514 2008-06-20 Konrad Trifunovic <konrad.trifunovic@inria.fr>
5516 * graphite.c: Fix formatting.
5518 2008-06-19 Konrad Trifunovic <konrad.trifunovic@inria.fr>
5520 * graphite.c (new_scop): Memory allocation for SCOP_{NEWIVS, OLDIVS}.
5521 (free_scop): Memory deallocation for SCOP_NEWIVS, SCOP_OLDIVS.
5522 (create_var_name, save_var_name): Newly defined functions.
5523 (initialize_cloog_names): Part of the code factored out to
5525 (clast_to_gcc_expression): Now handles the case of clast_red_sum
5526 in clast_reduction statement.
5527 (graphite_create_new_loop): Now takes a new parameter
5529 (translate_clast): Now also takes the context_loop and bb_exit
5530 parameters. Rewritten the code so that it creates a gimple code
5531 inside the given context.
5532 (outermost_loop_layer, graphite_remove_iv, graphite_rename_ivs,
5533 remove_cond_expr, disconnect_cond_expr,
5534 disconnect_virtual_phi_nodes): Newly defined functions.
5535 * graphite.h (struct scop): added old_ivs vector.
5536 SCOP_OLDIVS: New macro.
5538 2008-06-19 Sebastian Pop <sebastian.pop@amd.com>
5540 * cfgloopmanip.c: Add missing function comments, fix formatting.
5542 2008-06-18 Konrad Trifunovic <konrad.trifunovic@inria.fr>
5544 * cfgloopmanip.c (update_dominators_in_loop): Defined.
5545 (create_empty_loop_on_edge): Defined.
5546 * tree-parloops.c (canonicalize_loop_ivs): Returns tree
5548 * cfgloop.h (create_empty_loop_on_edge): Declared as extern.
5549 (update_dominators_in_loop): Declared as extern
5550 * tree-flow.h (canonicalize_loop_ivs): Declared as extern.
5552 2008-06-16 Tobias Grosser <grosser@fim.uni-passau.de>
5554 * graphite.c (print_graphite_bb): Allow changing number of loops
5556 (initialize_cloog_names): Allow changing number of loops.
5557 (build_cloog_prog): Simplify.
5558 (find_transform): Enable cloog option --strides.
5559 (graphite_swap_loops): New.
5560 (graphite_strip_mine_loop): New.
5561 (graphite_trans_swap_1and2): New.
5562 (graphite_trans_strip): New.
5563 (graphite_transform_loops): Add graphite_trans_strip.
5564 * graphite.h (scop_max_loop_depth): New.
5566 2008-06-15 Tobias Grosser <grosser@fim.uni-passau.de>
5568 * graphite.c (build_scop_iteration_domain): Remove forgotten
5569 line. (Fixes compile)
5571 2008-06-15 Tobias Grosser <grosser@fim.uni-passau.de>
5573 * graphite.c (print_graphite_bb): Add output of GBB_LOOPS.
5574 (build_graphite_bb): Add GBB_LOOPS and GBB_DOMAIN and reorder.
5575 (build_bb_loops): New.
5576 (graphite_transform_loops): Add build_bb_loops.
5577 (schedule_to_scattering): Use gbb_nb_loops to support changing loop
5579 * graphite.h (graphite_bb): Add loops.
5580 (gbb_nb_loops): New.
5581 (gbb_loop_at_index): New.
5582 (gbb_loop_index): New.
5583 (nb_params_in_scop): Renamed to scop_nb_params. Updated all functions
5584 using nb_params_in_scop.
5586 2008-06-14 Tobias Grosser <grosser@fim.uni-passau.de>
5588 * graphite.c (print_graphite_bb): Adapt to minimized schedule.
5589 (build_scop_canonical_schedules): Build minimized schedule.
5590 (schedule_to_scattering): Adapt to minimized schedule.
5591 * graphite.h (graphite_bb): Add/Update descriptions.
5593 2008-06-14 Adrien Eliche <aeliche@isty.uvsq.fr>
5594 Tobias Grosser <grosser@fim.uni-passau.de>
5596 * graphite.c (print_graphite_bb): Add condition printing.
5598 (dump_gbb_conditions): New.
5599 (build_scop_conditions_1): New.
5600 (build_scop_conditions): New.
5601 * graphite.h (graphite_bb): Add conditions.
5603 2008-06-14 Tobias Grosser <grosser@fim.uni-passau.de>
5605 * graphite.c (print_graphite_bb):
5606 (free_graphite_bb): New.
5607 (free_scop): Free bbs.
5608 (get_bb_type): Free doms.
5609 (build_scop_context): Free context matrix.
5610 (build_loop_iteration_domains): Remove unused code.
5611 (build_cloog_prog): Free scattering function and blocklist.
5612 (find_transform): Free options.
5614 2008-06-13 Tobias Grosser <grosser@fim.uni-passau.de>
5616 * graphite.c (loop_body_to_cloog_stmts): Rename to add_bb_domains.
5617 Remove unnecessery cloog data structures. Make a copy of the domain
5618 (setup_cloog_loop): Rename to build_loop_iteration_domains. Remove
5619 unnecessary cloog data structures. Fix memory leaks. Remove insert
5620 into SCOP_LOOP2CLOOG_LOOP as the inserted CloogLoops will never be
5622 (build_scop_iteration_domain): Remove unnecessary cloog
5623 data structures. Fix memory leaks.
5624 (graphite_transform_loops): Disable build_scop_dynamic_schedules as it
5625 uses SCOP_LOOP2CLOOG_LOOP, that is at the moment not working.
5627 2008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
5629 * graphite.c (find_scop_params): Remove initialize_cloog_names.
5631 2008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
5633 * graphite.c (end_scop): Style fix.
5634 (schedule_to_scattering): Style and comment fix.
5636 2008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
5637 * graphite.c (print_graphite_bb): Fix definiton of
5638 schedule_to_scattering.
5639 (initialize_cloog_names): Change nb_scattdims to max loop
5641 (schedule_to_scattering): Take parameter for number of scattering
5643 (build_cloog_prog): Only build as much scattering dimensions as
5646 2008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
5648 * graphite.c (end_scop): Disable bb splitting. Fixes SIGSEGV
5649 in polyhedron/aermod.f90.
5651 2008-06-11 Tobias Grosser <grosser@fim.uni-passau.de>
5652 Dwarak Rajagopal <dwarak.rajagopal@amd.com>
5653 Harsha Jagasia <harsha.jagasia@amd.com>
5655 * graphite.c (is_bb_addable): Fix segfault.
5657 2008-06-10 Tobias Grosser <grosser@fim.uni-passau.de>
5659 * graphite.c (is_bb_addable): Fix memory leak, handling of loops
5660 with multiple exits and conditional handling in edge cases.
5661 (is_loop_exit): Fix memory leak. (Forgotten in last commit)
5663 * testsuite/gcc.dg/graphite/scop-14.c: New.
5665 2008-06-06 Tobias Grosser <grosser@fim.uni-passau.de>
5666 Adrien Eliche <aeliche@isty.uvsq.fr>
5668 * graphite.c (is_bb_addable): Add more comments and enhance
5669 readablity of the source code. Fix memory leak.
5670 (is_loop_exit): Fix memory leak.
5672 2008-06-05 Tobias Grosser <grosser@fim.uni-passau.de>
5674 * graphite.c (first_loop_in_scop): Deleted.
5675 (setup_cloog_loop): Only walk the loop chain for inner loops.
5676 (build_scop_iteration_domain): Execute setup_cloog_loop for
5677 all loops in the first layer.
5679 2008-06-05 Tobias Grosser <grosser@fim.uni-passau.de>
5681 * graphite.c (scan_tree_for_params): Change the way params are
5682 added to be indepenent of the number of loops.
5683 (setup_cloog_loop): Revert to short matrix format. Fix parameter
5685 (build_cloog_prog): Revert to short matrix format.
5687 2008-06-05 Sebastian Pop <sebastian.pop@amd.com>
5688 Dwarak Rajagopal <dwarak.rajagopal@amd.com>
5690 * tree-loop-fusion.c (fuse_loops): Fix uninitialized variable
5693 2008-06-05 Sebastian Pop <sebastian.pop@amd.com>
5695 * graphite.c (nb_data_refs_in_scop): New.
5696 (graphite_transform_loops): Print more stats: number of
5697 loops, basic blocks and data references per scop.
5699 2008-06-04 Sebastian Pop <sebastian.pop@amd.com>
5700 Jan Sjodin <jan.sjodin@amd.com>
5702 * graphite.c (loop_affine_expr, idx_record_params,
5703 find_scop_parameters, setup_cloog_loop): Use instantiate_scev
5704 instead of instantiate_parameters.
5706 2008-06-04 Tobias Grosser <grosser@fim.uni-passau.de>
5708 * graphite.c (schedule_to_scattering): Fix scattering dimensions,
5709 add support for parameters, add STATIC_SCHEDULE at the right places,
5712 2008-06-04 Tobias Grosser <grosser@fim.uni-passau.de>
5714 * graphite.c (build_scop_loop_nests): Only add the loops, that
5715 are contained completely in the SCoP.
5716 (build_cloog_prog): Disable scattering, until schedule_to_scattering
5717 and the domains are fixed.
5718 (build_scop_canonical_schedules): Add support for bbs not contained
5721 2008-06-04 Tobias Grosser <grosser@fim.uni-passau.de>
5723 * graphite.h (scop_contains_loop): Update comments to match
5724 the actual behavior.
5725 (scop_contains_loop): New.
5726 * graphite.c (schedule_to_scattering): Use scop_contains_loop.
5728 2008-06-04 Sebastian Pop <sebastian.pop@amd.com>
5730 * graphite.c (get_bb_type): On function body, i.e. loop_0,
5731 don't mark blocks as GBB_LOOP_SING_EXIT_HEADER, mark them
5734 2008-06-04 Sebastian Pop <sebastian.pop@amd.com>
5735 Tobias Grosser <grosser@fim.uni-passau.de>
5737 * graphite.c (graphite_transform_loops): Early return when
5738 there are no loops in the function.
5740 2008-05-31 Sebastian Pop <sebastian.pop@amd.com>
5741 Jan Sjodin <jan.sjodin@amd.com>
5743 * graphite.c (scan_tree_for_params, setup_cloog_loop): Compute the
5744 offset of the last loop.
5745 (setup_cloog_loop): Copy the entire outer constraint matrix.
5747 2008-05-31 Sebastian Pop <sebastian.pop@amd.com>
5748 Jan Sjodin <jan.sjodin@amd.com>
5750 * graphite.c (stmt_in_scop_p, function_parameter_p,
5751 invariant_in_scop_p): Removed.
5752 (scan_tree_for_params): Can be used with no constraint
5753 matrix for gathering parameters.
5754 (idx_record_params): Don't use idx_record_param, instead use
5755 scan_tree_for_params.
5756 (find_scop_parameters): Same.
5757 (setup_cloog_loop, build_scop_iteration_domain, build_cloog_prog):
5758 Fix the size of loop domains.
5759 (schedule_to_scattering): Exit when the outer loop is not in scop.
5760 (find_transform): Enable build_cloog_prog.
5762 2008-05-31 Sebastian Pop <sebastian.pop@amd.com>
5763 Jan Sjodin <jan.sjodin@amd.com>
5765 * graphite.c (schedule_to_scattering): Make scattering domains
5766 uniformly of the same size, as required by CLooG 0.14.0 and before.
5768 2008-05-31 Sebastian Pop <sebastian.pop@amd.com>
5769 Jan Sjodin <jan.sjodin@amd.com>
5771 * graphite.c (schedule_to_scattering): Rewrite, correct the
5772 translation of the scheduling function to scattering.
5773 (build_cloog_prog): Call schedule_to_scattering only once.
5774 * graphite.h (scop_loop_index): Do not fail for loops not
5775 in the scop: return -1.
5777 2008-05-30 Tobias Grosser <grosser@fim.uni-passau.de>
5779 * graphite.c (build_graphite_bb): Initialize GBB_DOMAIN.
5780 (loop_body_to_cloog_stmts): Export GBB_DOMAIN.
5781 (setup_cloog_loop): Export GBB_DOMAIN.
5782 (build_cloog_prog): New. Create new CLOOG_PROG, which should be
5783 able to rebuild the original control flow.
5784 * graphite.h (graphite_bb): Add domain field and access macro.
5787 2008-05-30 Sebastian Pop <sebastian.pop@amd.com>
5789 * graphite.c (debug_gbb): New.
5790 (print_scop, build_graphite_bb): Use SCOP_BBS.
5791 (build_scop_bbs): Reimplemented.
5792 (dfs_bb_in_scop_p): Removed.
5793 (build_scop_loop_nests): Reorder loops inserted in
5794 SCOP_LOOP_NEST: outer loops should come first.
5795 (build_scop_canonical_schedules): Reinitialize at zero
5796 the components of the SCOP_STATIC_SCHEDULE for the loops
5797 that have already been parsed.
5799 * graphite.h (debug_gbb): Declared.
5801 2008-05-30 Sebastian Pop <sebastian.pop@amd.com>
5802 Jan Sjodin <jan.sjodin@amd.com>
5804 * graphite.c (create_empty_loop): Renamed graphite_create_new_loop.
5805 (graphite_loop_to_gcc_loop): Removed.
5806 (remove_all_edges): New.
5807 (graphite_stmt_to_gcc_stmt): Renamed translate_clast.
5808 (gloog): Remove useless code.
5810 2008-05-29 Tobias Grosser <grosser@fim.uni-passau.de>
5812 * graphite.c (get_bb_type): Reworked. We distinguish between
5813 loops with one or multiple exits.
5814 (is_loop_exit): New.
5816 (is_bb_addable): Rework condition handling, now support for case
5817 case statements and loops with multiple exits.
5819 * testsuite/gcc.dg/graphite/scop-11.c: New.
5820 * testsuite/gcc.dg/graphite/scop-12.c: New.
5821 * testsuite/gcc.dg/graphite/scop-13.c: New.
5823 2008-05-29 Tobias Grosser <grosser@fim.uni-passau.de>
5825 * graphite.c (dot_all_scops_1): Fix some colors. Reuse colors, if
5826 we have too many colors.
5828 2008-05-22 Sandeep Maram <smaram_b04@iiita.ac.in>
5830 * doc/invoke.texi (-ftree-loop-fusion): Document.
5831 * tree-pass.h (pass_loop_fusion): Declared.
5832 * tree-loop-fusion.c: New.
5833 * timevar.def (TV_TREE_LOOP_FUSION): Declared.
5834 * tree-data-ref.c (find_data_references_in_loop): Make extern.
5835 * tree-data-ref.h (find_data_references_in_loop): Declared.
5836 * common.opt (ftree-loop-fusion): Declared.
5837 * Makefile.in (tree-loop-fusion.o): Added rule and to OBJS-common.
5839 2008-05-21 Sebastian Pop <sebastian.pop@amd.com>
5841 * graphite.c (build_access_matrix): Fix typo from the merge.
5843 2008-05-20 Sebastian Pop <sebastian.pop@amd.com>
5845 * Merge from mainline (130800:135673).
5847 2008-05-07 Sebastian Pop <sebastian.pop@amd.com>
5849 * graphite.c (end_scop): The exit of the scop is not part of the scop.
5850 Update dominators after splitting.
5852 2008-05-07 Sebastian Pop <sebastian.pop@amd.com>
5854 * graphite.c (is_bb_addable): Return the harmful statement.
5855 Factor up some code.
5856 (end_scop): New. Splits end of scope bbs on a harmful statement.
5857 (build_scops_1): Call end_scop.
5859 2008-05-07 Sebastian Pop <sebastian.pop@amd.com>
5861 * graphite.c: (succs_at_same_depth, end_scop, all_preds_visited_p,
5862 all_succs_visited_p, start_new_scop_for_each_succ, start_new_scop,
5863 add_dominators_to_open_scops, stop_last_open_scop, scop_end_loop,
5864 build_scops_1): Removed.
5865 (build_scops_2): Renamed build_scops_1.
5867 2008-05-06 Sebastian Pop <sebastian.pop@amd.com>
5869 * graphite.c: Fix formatting.
5871 2008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
5873 * graphite.c (get_bb_type): New.
5875 (build_scops_2): New.
5876 (is_bb_addable): New.
5877 (build_scops): Switch the scop detection.
5878 (build_scop_bbs): Add entry bb to scop.
5879 * graphite.h (struct scop): Update comment.
5881 2008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
5883 * graphite.c (dot_all_scops_1): Fix some incorrect colors and add
5886 2008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
5888 * testsuite/gcc.dg/graphite/scop-1.c: Update.
5889 * testsuite/gcc.dg/graphite/scop-2.c: Update.
5890 * testsuite/gcc.dg/graphite/scop-4.c: Update.
5891 * testsuite/gcc.dg/graphite/scop-5.c: Add.
5892 * testsuite/gcc.dg/graphite/scop-6.c: Add.
5894 2008-05-06 Sebastian Pop <sebastian.pop@amd.com>
5896 * testsuite/gcc.dg/graphite/scop-0.c: Add.
5897 * testsuite/gcc.dg/graphite/scop-7.c: Add.
5898 * testsuite/gcc.dg/graphite/scop-8.c: Add.
5899 * testsuite/gcc.dg/graphite/scop-9.c: Add.
5900 * testsuite/gcc.dg/graphite/scop-10.c: Add.
5902 2008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
5904 * graphite.c (scop_affine_expr): Renamed to loop_affine_expr.
5905 Check affine expressions depending on the outermost loop
5907 (stmt_simple_for_scop_p): Same.
5908 (harmfule_stmt_in_scop): Same.
5910 2008-04-28 Tobias Grosser <grosser@fim.uni-passau.de>
5912 * graphite.c (dot_all_scops): Remove incorrect difficult bb coloring,
5913 mark entry and exit, that are not part of the SCoP and update HTML
5916 2008-04-25 Sebastian Pop <sebastian.pop@amd.com>
5918 * graphite.c (basic_block_simple_for_scop_p): Renamed
5920 (save_scop, preds_at_same_depth, test_for_scop_bound): Removed.
5921 (add_dominators_to_open_scops, build_scops_1): Reimplemented.
5922 (all_preds_visited_p, all_succs_visited_p,
5923 start_new_scop_for_each_succ, start_new_scop, stop_last_open_scop,
5924 scop_end_loop): New.
5925 (build_scops): Do not use dfs_enumerate_from.
5927 * testsuite/gcc.dg/graphite/scop-{1,2,4}.c: Updated.
5929 2008-04-23 Sebastian Pop <sebastian.pop@amd.com>
5931 * graphite.c: Add comments to functions that are missing a
5933 (graphite_create_iv): Removed. Merged in graphite_loop_to_gcc_loop.
5935 2008-04-23 Sebastian Pop <sebastian.pop@amd.com>
5937 * graphite.c (nb_params_in_scop): Moved...
5938 (graphite_bb_from_bb, loop_body_to_cloog_stmts): New.
5939 (setup_cloog_loop): Call loop_body_to_cloog_stmts.
5940 (clast_to_gcc_expression): Reduce column size to less than 80.
5941 (graphite_create_iv): Return the new name of the IV.
5942 (find_transform): Set options->esp and options->cpp.
5943 (gloog): Comment out the invalidation of the old loop code.
5944 (initialize_dependence_polyhedron): Replace scop_nb_params with
5947 * graphite.h (nb_params_in_scop): ... here.
5948 (scop_nb_params): Removed.
5949 (loop_domain_dim): Return something even when the loop was not
5950 found in the hash table: avoid ICEing on all the graphite.exp
5953 2008-04-14 Konrad Trifunovic <konrad.trifunovic@inria.fr>
5955 * tree-chrec.c (for_each_scev_op): SCEV can have 3 operands.
5957 * graphite.c (build_scop_dynamic_schedules): Schedule is built
5958 according to nesting level.
5959 (find_scop_parameters): Call instantiate_parameters.
5960 (scan_tree_for_params): Extend it to handle general affine bounds.
5961 Inner loop bound can depend on outer loop induction variable.
5962 (setup_cloog_loop): tmp variable is allocated on stack. Call
5963 instantiate_parameters with respect to outermost_loop_in_scop.
5964 (loop_domain_dim, ref_nb_loops, loop_iteration_vector_dim): moved to
5966 (create_empty_loop): Function loopify should be given edge
5967 probability, instead of edge frequency. Dominance relation from
5968 switch_bb to loop_header.
5969 (clast_to_gcc_expression): Added handling of clast_reduction node.
5970 (gloog): New functionality for removing old loop.
5971 (test_dependence): Factored out from build_rdg_all_levels.
5972 (build_rdg_all_levels): Dependence testing factored out to
5973 test_dependence function.
5975 * graphite.h (struct graphite_bb): Extended with dynamic_schedule.
5976 (loop_domain_dim, ref_nb_loops, loop_iteration_vector_dim): Moved
5979 2008-04-07 Sebastian Pop <sebastian.pop@amd.com>
5981 * graphite.c (free_scop, param_index, initialize_cloog_names,
5982 nb_params_in_scop): Use name_tree map instead of just a tree
5983 for keeping track of the variable name associated to that tree.
5984 (create_empty_loop, gmp_cst_to_tree, clast_name_to_gcc,
5985 clast_to_gcc_expression, graphite_create_iv,
5986 graphite_loop_to_gcc_loop, graphite_cond_to_gcc_cond,
5987 graphite_stmt_to_gcc_stmt): New.
5988 (gloog): Call these.
5989 * graphite.h (struct name_tree): New.
5990 (struct scop): Use name_tree instead of tree for params.
5991 Store a vector of name_tree for new_ivs.
5993 (scop_nb_params): Use name_tree instead of tree.
5995 2008-04-05 Alexander Lamaison <awl03@doc.ic.ac.uk>
5996 Sebastian Pop <sebastian.pop@amd.com>
5998 * tree-bounds.c: New.
5999 * tree-bounds.h: New.
6000 * tree-pass.h: Declare pass_bounds_early and pass_bounds_late.
6001 * passes.c: Schedule pass_bounds_early, pass_bounds_late.
6002 * builtins.c (expand_builtin_alloca): Add flag_bounds as for
6006 * c-cppbuiltin.c: Same.
6010 * tree-outof-ssa.c: Same.
6012 * Makefile.in: Same.
6014 2008-03-15 Antoniu Pop <antoniu.pop@gmail.com>
6015 Sebastian Pop <sebastian.pop@amd.com>
6017 * tree-loop-distribution.c (remaining_stmts,
6018 upstream_mem_writes): Removed static variables.
6019 (copy_loop_before, create_bb_after_loop,
6020 mark_nodes_having_upstream_mem_writes, free_rdg_components,
6021 rdg_build_components, rdg_build_partitions,
6022 dump_rdg_partitions): Extern.
6023 (generate_loops_for_partition, generate_code_for_partition): Do not
6025 (already_processed_vertex_p, predecessor_has_mem_write,
6026 mark_nodes_having_upstream_mem_writes, has_upstream_mem_writes,
6027 rdg_flag_all_uses, rdg_flag_uses, rdg_flag_vertex_and_dependent,
6028 rdg_flag_loop_exits, rdg_flag_similar_memory_accesses,
6029 build_rdg_partition_for_component, rdg_build_partitions, ldist_gen):
6030 Pass remaining_stmts and upstream_mem_writes as parameters.
6031 (rdg_component): Moved...
6032 (build_rdg_partition_for_component): Do not aggregate components when
6033 flag_streamize_loops is set.
6034 (gen_sequential_loops): New.
6035 (ldist_gen): Call gen_sequential_loops.
6037 * tree-pass.h (pass_loop_streamization): Declared.
6039 * omp-low.c (expand_omp_sections): Call add_bb_to_loop on created
6040 basic blocks when loops structures exist.
6042 * builtin-types.def (BT_FN_VOID_PTR_PTR_INT): New.
6044 * tree-ssa-loop-ivopts.c (expr_invariant_in_region_p): New.
6046 * tree-parloops.c (take_address_of, eliminate_local_variables_1,
6047 eliminate_local_variables_stmt, eliminate_local_variables,
6048 separate_decls_in_loop_name, separate_decls_in_loop_stmt,
6049 separate_decls_in_loop, gen_parallel_loop): Make them work on a region
6050 of code delimited by two edges in the CFG.
6051 (separate_decls_in_loop_name): Renamed separate_decls_in_region_name.
6052 (separate_decls_in_loop_stmt): Renamed separate_decls_in_region_stmt.
6053 (separate_decls_in_loop): Renamed separate_decls_in_region. Isolate
6054 the case of parallelisation of reductions.
6055 (create_loop_fn): Extern.
6056 (create_omp_parallel_region): New.
6058 * tree-data-ref.c (dump_data_dependence_relation): Don't call
6059 dump_data_reference for printing dra and drb.
6060 (create_rdg_edge_for_ddr, create_rdg_edges_for_scalar): Initialise
6062 (build_rdg): Don't call free_dependence_relations for the moment, as
6063 we attach dependence relations on each edge of the RDG.
6066 * tree-data-ref.h (rdg_component): ...here.
6067 (struct rdg_edge): New field ddr_p relation.
6068 (RDGE_RELATION): New.
6069 (create_bb_after_loop, copy_loop_before,
6070 mark_nodes_having_upstream_mem_writes, rdg_build_components,
6071 rdg_build_partitions, dump_rdg_partitions,
6072 free_rdg_components): Declared.
6074 * omp-builtins.def (BUILT_IN_GOMP_STREAM_ALIGN_PUSH,
6075 BUILT_IN_GOMP_STREAM_ALIGN_POP): New.
6077 * tree-loop-streamization.c: New.
6079 * tree-flow.h (gather_blocks_in_sese_region, create_loop_fn,
6080 create_omp_parallel_region, expr_invariant_in_region_p): Declared.
6082 * Makefile.in (tree-loop-streamization.o): Added to OBJS-common.
6084 * tree-cfg.c (gather_blocks_in_sese_region): Extern.
6086 * passes.c: Schedule pass_loop_streamization.
6088 2008-03-08 Tobias Grosser <grosser@fmi.uni-passau.de>
6090 * graphite.c (dot_all_scops_1): Fix formatting for difficult bbs and
6093 2008-03-07 Tobias Grosser <grosser@fim.uni-passau.de>
6095 * graphite.c (dot_all_scops): Update formatting.
6096 Bbs can now be part of more than one SCoP.
6098 2008-03-04 Sebastian Pop <sebastian.pop@amd.com>
6100 * graphite.c (new_loop_to_cloog_loop_str, setup_cloog_loop): Fix
6102 (loop_domain_dim): Check for unregistered toplev SCOP loop.
6103 * graphite.h (loop_to_cloog_loop): New.
6105 2008-03-04 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6107 * graphite.c (loop_domain_dim, ref_nb_loops,
6108 loop_iteration_vector_dim): New.
6109 (build_access_matrix_with_af, build_access_matrix,
6110 initialize_dependence_polyhedron): Fixed for new matrix layout.
6111 No longer assume that all iteration domains are of the same
6114 2008-03-02 Sebastian Pop <sebastian.pop@amd.com>
6116 * tree-scalar-evolution.c (instantiate_parameters_1): An SSA_NAME
6117 defined in a loop at depth 0 is invariant.
6118 * tree-chrec.c (evolution_function_is_invariant_rec_p): Ditto.
6119 * tree-ssa-loop-ivopts.c (expr_invariant_in_loop_p): Should never
6120 be called at loop depth 0.
6122 * graphite.c (basic_block_simple_for_scop_p): Take the scop as
6124 (dot_all_scops_1): Update use of basic_block_simple_for_scop_p.
6125 (down_open_scop): Removed.
6126 (loop_in_scop_p): Redefined.
6127 (scop_affine_expr): New argument: scop.
6128 (stmt_simple_for_scop_p): New argument: scop. RETURN_EXPR is not
6129 a harmful statement ending a scop.
6130 (basic_block_simple_for_scop_p): New argument: scop.
6131 (get_loop_start): Removed.
6132 (new_scop): Initialize SCOP_LOOPS.
6133 (free_scop): Free SCOP_LOOPS.
6134 (succs_at_same_depth, preds_at_same_depth): New.
6135 (end_scop): Test the validity of a scop.
6136 (add_dominators_to_open_scops): New.
6137 (test_for_scop_bound): Call add_dominators_to_open_scops.
6138 Add cases for opening and closing multiple scops.
6139 (build_scops, build_scop_bbs): Iterate over basic blocks in
6141 (build_graphite_bb): Pass scop directly.
6142 (dfs_bb_in_scop_p): New.
6143 (scop_record_loop): Use SCOP_LOOPS for not recording the same loop
6145 (nb_loops_around_gb): Use loop_in_scop_p.
6146 (schedule_to_scattering): Disabled for the moment the code computing
6147 the "textual order for outer loop".
6149 * graphite.h (struct scop): New field loops.
6151 (scop_loop_index): Test that the given loop belongs to SCOP_LOOPS.
6153 * testsuite/gcc.dg/graphite/scop-{1,...,7}.c: Updated.
6155 2008-02-27 Antoniu Pop <antoniu.pop@gmail.com>
6156 Sebastian Pop <sebastian.pop@amd.com>
6158 * builtin-types.def (BT_FN_PTR_SIZE_UINT, BT_FN_BOOL_PTR): New.
6159 * common.opt (fstreamize-loops): New.
6160 * omp-builtins.def (BUILT_IN_GOMP_STREAM_CREATE,
6161 BUILT_IN_GOMP_STREAM_PUSH, BUILT_IN_GOMP_STREAM_HEAD,
6162 BUILT_IN_GOMP_STREAM_POP, BUILT_IN_GOMP_STREAM_EOS_P,
6163 BUILT_IN_GOMP_STREAM_SET_EOS, BUILT_IN_GOMP_STREAM_DESTROY): New.
6165 2008-02-22 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6167 * tree-data-ref.c (build_empty_rdg): New.
6168 (build_rdg): Use it.
6169 * tree-data-ref.h (build_empty_rdg): Declared.
6170 * graphite.c (free_scop): Free SCOP_LOOP2CLOOG_LOOP.
6171 (find_vertex_for_stmt): Removed.
6172 (build_rdg_all_levels): Use build_empty_rdg and rdg_vertex_for_stmt.
6174 2008-02-21 Sebastian Pop <sebastian.pop@amd.com>
6176 * tree-loop-distribution.c (generate_builtin): After cancelling the
6177 loop tree, also delete basic blocks.
6178 (rdg_flag_uses): Stop recursion when a vertex has already been
6181 2008-02-15 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6183 * graphite.c (build_scop_alpha): Removed.
6184 (graphite_transform_loops): Add a dummy call to build_all_rdg_levels
6185 and dump_dependence_graph to avoid compiler warnings.
6187 2008-02-14 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6189 * tree-data-ref.c (dr_may_alias_p, create_rdg_vertices): Extern.
6190 * tree-data-ref.h (dr_may_alias_p, create_rdg_vertices): Declared.
6191 * graphite.c (new_loop_to_cloog_loop_str, hash_loop_to_cloog_loop,
6192 eq_loop_to_cloog_loop, del_loop_to_cloog_loop): New.
6193 (new_scop, setup_cloog_loop): Initialize SCOP_LOOP2CLOOG_LOOP.
6194 (initialize_dependence_polyhedron, find_vertex_for_stmt,
6195 initialize_data_dependence_polyhedron, is_empty_polyhedron,
6196 statement_precedes_p, build_rdg_all_levels, build_scop_alpha,
6197 dump_dependence_graph): New.
6198 * graphite.h (struct graphite_bb): New field compressed_alpha_matrix.
6200 (struct scop): New field loop2cloog_loop.
6201 (SCOP_LOOP2CLOOG_LOOP, struct data_dependence_polyhedron,
6202 RDGE_DDP, ddp_p, struct loop_to_cloog_loop_str): New.
6204 2008-02-10 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6206 * graphite.c (build_graphite_bb): Fix initialization
6207 of the graphite basic block.
6209 2008-02-05 Sebastian Pop <sebastian.pop@amd.com>
6211 * graphite.c (scan_tree_for_params): Rewrite for the new layout of
6212 loop domain matrix. Pass in the number of loops contained in the
6214 (nb_loops_around_gb): Moved before setup_cloog_loop that uses it.
6215 (setup_cloog_loop): Rewrite for the new layout of loop domain matrix:
6216 loops that are not surrounding the current loop are not represented
6217 in the domain constraint matrix.
6218 (build_scop_iteration_domain): Initial domain constraint matrix
6219 contains only the eq/ineq, cst, and scop parameters columns.
6221 2008-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
6223 * graphite.c (schedule_to_scattering, nb_loops_around_gb): New.
6224 (print_graphite_bb): Print scattering.
6226 2008-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
6228 * graphite.c (initialize_cloog_names): Initialize names of
6229 scattering variables.
6231 2009-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
6233 * graphite.c (dot_all_scops_1): Disable debug output while
6236 2008-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
6238 * graphite.c (find_transform): Change cloog output language to C.
6240 2008-01-27 Sebastian Pop <sebastian.pop@amd.com>
6242 * tree-loop-distribution.c (generate_memset_zero,
6243 generate_builtin, generate_code_for_partition,
6244 rdg_flag_all_uses): New.
6245 (rdg_flag_uses): Gather in the same partition the statements defining
6246 the VUSES of the current statement.
6247 (rdg_flag_similar_stores): Renamed rdg_flag_similar_memory_accesses.
6248 Gather in the same partition not only the stores to the same memory
6249 access, but also the reads.
6250 (ldist_generate_loops): Renamed ldist_gen.
6252 2008-01-24 Sebastian Pop <sebastian.pop@amd.com>
6253 Tobias Grosser <grosser@fmi.uni-passau.de>
6255 * graphite.c (setup_cloog_loop): Chain all cloog loops with the
6256 next pointer, don't use the inner pointer.
6258 2008-01-20 Tobias Grosser <grosser@fmi.uni-passau.de>
6260 * graphite.c (dot_all_scops, dot_all_scops_1): New.
6261 (find_transform): Call dot_all_1.
6262 * graphite.h (dot_all_scops): Declared.
6264 2007-12-14 Sebastian Pop <sebastian.pop@amd.com>
6266 * tree-loop-distribution.c: Fix apsi.f ICE.
6267 (create_bb_after_loop): New.
6268 (generate_loops_for_partition): Use it.
6269 * testsuite/gfortran.dg/ldist-1.f90: New.
6271 * tree-data-ref.c (dot_rdg): Use /tmp/rdg.dot for dotty format.
6272 * graphite.c (dot_scop): Use /tmp/scop.dot for dotty format.
6274 2007-12-13 Tobias Grosser <grosser@fmi.uni-passau.de>
6276 * graphite.c (find_transform): Dump cloog program sent to cloog.
6278 2007-12-13 Tobias Grosser <grosser@fmi.uni-passau.de>
6280 * graphite.c (initialize_cloog_names): Initialize cloog
6283 2007-12-13 Tobias Grosser <grosser@fmi.uni-passau.de>
6285 * graphite.c (build_scop_context): Fix typo, for the matrix
6286 format: insert '0 >= 0' instead of '-1 >= 0'.
6288 2007-12-13 Sebastian Pop <sebastian.pop@amd.com>
6290 * Fix merge problems.
6292 2007-12-13 Sebastian Pop <sebastian.pop@amd.com>
6294 * graphite.c (setup_cloog_loop): Fix typo.
6296 2007-12-12 Sebastian Pop <sebastian.pop@amd.com>
6298 * doc/invoke.texi (-ftree-loop-distribution): Documented.
6299 * tree-loop-distribution.c: Reimplemented.
6300 * tree-pass.h (pass_loop_distribution): New.
6301 * tree-scalar-evolution.c (number_of_iterations_for_all_loops): Use
6303 * graphds.h (struct graph): New field indexes.
6304 * timevar.def (TV_TREE_LOOP_DISTRIBUTION): New.
6306 * tree-vect-analyze.c: Remove declaration of static functions when not
6308 * tree-vectorizer.c: Same.
6309 (rename_variables_in_loop): Now extern.
6310 (slpeel_tree_duplicate_loop_to_edge_cfg): Renamed
6311 tree_duplicate_loop_to_edge_cfg. Reset PENDING_STMT for edges after
6312 calling redirect_edge_and_branch_force.
6314 * tree-vectorizer.h (tree_duplicate_loop_on_edge): Declared.
6316 * tree-data-ref.c: Don't include tree-chrec.h.
6317 (debug_data_dependence_relations): New.
6318 (dump_data_dependence_relation): Call dump_data_reference on data refs
6320 (same_access_functions): Moved...
6321 (find_vertex_for_stmt): Renamed rdg_vertex_for_stmt.
6322 (dump_rdg_vertex, debug_rdg_vertex, dump_rdg_component,
6323 debug_rdg_component, dump_rdg, debug_rdg, dot_rdg_1, dot_rdg,
6324 struct rdg_vertex_info, ): New.
6325 (create_rdg_edge_for_ddr): Compute the dependence level before looking
6327 (create_rdg_vertices): Initialize the htab of graph->indexes.
6328 Initialize RDG_MEM_WRITE_STMT and RDG_MEM_READS_STMT.
6329 (stmts_from_loop): Don't save LABEL_EXPR.
6330 (hash_stmt_vertex_info, eq_stmt_vertex_info,
6331 hash_stmt_vertex_del): New.
6332 (build_rdg): Initialize rdg->indexes.
6333 (free_rdg, stores_from_loop, ref_base_address,
6334 rdg_defs_used_in_other_loops_p, have_similar_memory_accesses,
6335 have_similar_memory_accesses_1, ref_base_address_1,
6336 remove_similar_memory_refs): New.
6338 * tree-data-ref.h: Include tree-chrec.h.
6339 (debug_data_dependence_relations): Declared.
6340 (same_access_functions): ...here. Now static inline.
6341 (ddr_is_anti_dependent, ddrs_have_anti_deps,
6342 ddr_dependence_level): New.
6343 (struct rdg_vertex): New fields has_mem_write, has_mem_reads.
6344 (RDGV_HAS_MEM_WRITE, RDGV_HAS_MEM_READS, RDG_STMT, RDG_MEM_WRITE_STMT,
6345 RDG_MEM_READS_STMT): New.
6346 (dump_rdg_vertex, debug_rdg_vertex, dump_rdg_component,
6347 debug_rdg_component, dump_rdg, debug_rdg, dot_rdg,
6348 rdg_vertex_for_stmt): Declared.
6349 (struct rdg_edge): New field level.
6350 (RDGE_LEVEL, free_rdg): New.
6351 (stores_from_loop, remove_similar_memory_refs,
6352 rdg_defs_used_in_other_loops_p,
6353 have_similar_memory_accesses): Declared.
6354 (rdg_has_similar_memory_accesses): New.
6356 * lambda.h (dependence_level): New.
6357 * common.opt (ftree-loop-distribution): New.
6358 * tree-flow.h (debug_loop_ir): Renamed debug_loops.
6359 (print_loop_ir): Renamed print_loops.
6360 (debug_loop, debug_loop_num, print_loops_bb, mark_virtual_ops_in_bb,
6361 tree_duplicate_loop_to_edge_cfg, rename_variables_in_loop): Declared.
6362 * Makefile.in (TREE_DATA_REF_H): Depends on tree-chrec.h.
6363 (tree-loop-distribution.o): Added.
6364 * tree-cfg.c (mark_virtual_ops_in_region): Use mark_virtual_ops_in_bb.
6365 (mark_virtual_ops_in_bb): New.
6366 (print_loops_bb, debug_loop_num, debug_loop): New.
6367 * passes.c: Scheduled pass_loop_distribution.
6369 2007-12-12 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6371 * graphite.c (scan_tree_for_params): Correct the number of columns
6373 (nb_flat_iterator): New.
6374 (setup_cloog_loop): Initialize to 1 the first column for inequalities.
6375 (build_scop_iteration_domain): Correct the number of columns for
6378 2007-12-12 Sebastian Pop <sebastian.pop@amd.com>
6380 * Merge from mainline (129697:130800).
6382 2007-10-30 Sebastian Pop <sebastian.pop@amd.com>
6384 * graphite.c (build_graphite_bb): SCoP's basic blocks are post
6385 dominated by SCoP's exit.
6386 (graphite_transform_loops): Compute post dominators.
6388 2007-10-28 Sebastian Pop <sebastian.pop@amd.com>
6390 * Merge from mainline (127169:129697).
6392 2007-10-28 Sebastian Pop <sebastian.pop@amd.com>
6394 * graphite.c (affine_expr): Renamed scop_affine_expr. Use an extra
6395 parameter for the basic block that contains the expression. Use
6396 outermost_loop_in_scop for evolution_function_is_affine_multivariate_p.
6397 (stmt_simple_for_scop_p): Pass to scop_affine_expr the basic block of
6399 * graphite.h (gbb_loop): New.
6400 (GBB_LOOP): Removed.
6402 2007-08-03 Sebastian Pop <sebpop@gmail.com>
6404 * Makefile.in: Fix merge problem.
6406 2007-08-03 Sebastian Pop <sebpop@gmail.com>
6408 * Merge from mainline (125309:127169).
6409 * tree-loop-distribution.c: Disabled.
6411 2007-06-05 Sebastian Pop <sebpop@gmail.com>
6413 * Merge from mainline (r123693:125309).
6415 2007-05-30 Sebastian Pop <sebpop@gmail.com>
6417 * tree-loop-distribution.c (correct_modify_expr_p): Renamed
6419 (correct_modify_p, check_statements, number_of_lvalue_uses,
6420 number_of_scalar_dependences, create_edges): Use GIMPLE_MODIFY_STMT
6421 instead of MODIFY_EXPR.
6422 (update_edge_with_ddv): Don't pass index_of_edge. Initialize
6425 2007-05-24 Sebastian Pop <sebpop@gmail.com>
6427 * tree-loop-distribution.c (struct rdg): Replace arrays by
6428 VECs for edges and vertices.
6429 (RDG_NBV, RDG_NBE, RDG_VERTEX, RDG_EDGE): Removed.
6430 (RDGV_NB_PARTITIONS): New.
6431 (PRDG_NBV, PRDG_NBE): Removed.
6432 (build_scc_graph, correct_partitions_p, mark_partitions, build_prdg,
6433 dump_rdg, find_vertex_with_stmt, create_vertices, free_rdg,
6434 number_of_scalar_dependences, create_edges, build_rdg): Use VECs.
6436 2007-05-17 Georges-Andre Silber <silber@cri.ensmp.fr>
6437 Sebastian Pop <sebpop@gmail.com>
6439 * doc/invoke.texi (-ftree-loop-distribution): Document.
6440 * tree-loop-distribution.c: New file.
6441 * tree-pass.h (pass_loop_distribution): Declared.
6442 * timevar.def (TV_TREE_LOOP_DISTRIBUTION): New.
6443 * tree-data-ref.c (initialize_data_dependence_relation): Initialize
6445 * tree-data-ref.h (data_dependence_relation): Add reversed_p.
6446 (DDR_REVERSED_P): New.
6447 * common.opt (-ftree-loop-distribution): New.
6448 * tree-flow.h (distribute_loops): Declared.
6449 * Makefile.in (OBJS-common): Depend on tree-loop-distribution.o.
6450 * passes.c (init_optimization_passes): Schedule loop distribution.
6452 2007-05-12 Sebastian Pop <sebastian.pop@inria.fr>
6454 * graphite.c (print_graphite_bb): Don't call dump_data_references.
6455 (print_scop): Don't print when scop is NULL.
6456 (build_scop_context, find_transform): Don't output to stderr.
6458 2007-05-09 Sebastian Pop <sebastian.pop@inria.fr>
6460 * tree-data-ref.c: Don't include graphite.h.
6461 Comment out the code for printing data reference's scop.
6462 (build_access_matrix_with_af): Moved...
6463 * tree-data-ref.h (build_access_matrix_with_af): Removed declaration.
6464 * graphite.c (build_access_matrix_with_af): ... here. Now static.
6465 (print_graphite_bb): Print basic block's schedule.
6466 (print_scop): Don't print the schedule, call cloog's pretty printer.
6467 (bb_in_scop_p): A basic block is in a scop only if it is both
6468 dominated and postdominated by the scop's entry and exit basic blocks.
6469 (function_parameter_p): New.
6470 (invariant_in_scop_p): Use function_parameter_p.
6471 (new_scop, save_scop): New.
6472 (end_scop, test_for_scop_bound, build_scops): Use new_scop, and
6474 (scan_tree_for_params): Directly build the constraint as CloogMatrix.
6475 (loop_in_scop_p): New.
6476 (scop_record_loop): Use loop_in_scop_p.
6477 (build_scop_domain): Renamed build_scop_iteration_domain.
6478 (setup_cloog_loop, initialize_cloog_names, find_scop_parameters,
6479 nb_params_in_scop, build_scop_context, first_loop_in_scop,
6480 setup_cloog_loop, dot_scop_1, dot_scop): New.
6481 * graphite.h (GBB_LOOP, SCOP_PROG, dot_scop): New.
6482 (struct scop): Add a pointer to cloog's representation of a program.
6484 2007-04-14 Sebastian Pop <sebastian.pop@inria.fr>
6486 * doc/invoke.texi (-ftree-check-verbose): Renamed
6487 -ftree-checks-verbose.
6488 * common.opt (flag_tree_check_verbose): Renamed
6489 flag_tree_checks_verbose.
6490 * tree-check.c (tree_check_warning): Use flag_tree_checks_verbose.
6492 2007-04-14 Sebastian Pop <sebastian.pop@inria.fr>
6494 * configure: Regenerated.
6495 * config.in: Regenerated.
6496 * tree-ssa-loop.c (graphite_transforms): Execute
6497 graphite_transform_loops only when HAVE_cloog.
6498 * configure.ac (HAVE_polylib, HAVE_cloog, GRAPHITE): Defined.
6499 * graphite.c: Include polylibgmp.h and cloog.h.
6500 (graphite_transform_loops): Removed loops parameter.
6501 * tree-flow.h (graphite_transform_loops): Update declaration.
6502 * Makefile.in (POLYLIBLIBS, POLYLIBINC, CLOOGLIBS, CLOOGINC): New.
6503 (LIBS): Depend on CLOOGLIBS and on POLYLIBLIBS.
6504 (INCLUDES): Depend on POLYLIBINC and on CLOOGINC.
6505 (OBJS-common): Remove dependence on graphite.o.
6506 (BACKEND): Depend on @GRAPHITE@.
6508 2007-04-13 Sebastian Pop <sebastian.pop@inria.fr>
6510 * doc/invoke.texi (-ftree-check-verbose): Documented.
6511 * testsuite/gcc.dg/tree-checker/tree-checks-1.c: New.
6512 * testsuite/gcc.dg/tree-checker/tree-checks-2.c: New.
6513 * testsuite/gcc.dg/tree-checker/tree-checks-3.c: New.
6514 * testsuite/gcc.dg/tree-checker/tree-checks-4.c: New.
6515 * testsuite/gcc.dg/tree-checker/tree-checks.exp: New.
6516 * testsuite/gcc.dg/tree-checker/condates.crp: New.
6517 * common.opt (ftree-checks-verbose): New.
6518 * tree-check.c (tree_check_warning): Move extra stderr output
6519 under control of flag_tree_check_verbose.
6521 2007-04-12 Sebastian Pop <sebastian.pop@inria.fr>
6523 * tree-match.c: Fix comments formatting.
6524 * tree-match.h: Fix comments formatting.
6525 * tree-check.c: Fix comments formatting.
6526 (tree_check_init): Restructure.
6528 2007-04-12 Nic Volanschi <nic.volanschi@free.fr>
6530 * doc/invoke.texi (-ftree-check, -ftree-checks): Documented.
6532 2007-04-10 Sebastian Pop <sebastian.pop@inria.fr>
6534 * Merge from mainline (r120733:123693).
6536 2007-03-20 Nic Volanschi <nic.volanschi@free.fr>
6538 * condate.y: New file.
6539 * tree-match.h (struct patt_info_s): New field sign.
6540 (struct condate_s): New field msg.
6541 (normalize_condate, name_condate, add_condate): New.
6542 (conds[], condate_parse): Made extern.
6543 * tree-check.c (tree_check_warning): First arg changed to cond;
6544 warning reformatted.
6545 (tree_check_init): Reset the TREE_VISITED bit on every CFG node.
6547 (tree_check): Process trivial condates.
6548 (read_delimited_string): Removed.
6549 (print_cond): Print name and msg.
6550 (conds[]): Made extern.
6551 (parse_tree_check_file_once): Rewritten to use the parser in
6553 Processing of option --tree_check_string moved to tree_scan().
6554 * Makefile.in: Added condate.y
6556 2007-03-12 Sebastian Pop <sebastian.pop@inria.fr>
6558 * tree-pretty-print.c (dump_generic_bb_buff, lazy_dump_generic_node):
6559 Use VECs instead of varrays.
6560 * diagnostic.h (lazy_dump_generic_node): Update declaration.
6561 * Makefile.in (pretty-print.o): Depend on vec.h.
6562 * pretty-print.c: Include tree.h and vec.h.
6563 (pp_clear_state, pp_write_list_to_stream, pp_base_format,
6564 pp_base_format, pp_construct, pp_base_string, pp_lazy_mode,
6565 new_tree_chunk, pp_add_tree, pp_add_string, pp_add_char, pp_write_list,
6566 pp_free_list): Use VECs instead of varrays.
6567 * pretty-print.h: Do not include varray.h.
6568 (struct tree_chunk_s): Declaration moved before its use.
6569 (output_buffer): Rename varray field to chunks.
6570 * tree-match.c (tree_equal, chunk_1st_char, chunks_lookahead,
6571 tree_1st_char, match_chunks_pattinfo, match_tree_pattinfo,
6572 save_global_holes): Use VECs instead of varrays.
6573 * tree-match.h: Declare VECs of cfg_node, and hole_p.
6574 * tree-check.c (scan_cfg_stmts, push_node,
6575 print_matching_stmt): Removed.
6576 (tree_check_instance, push_global_holes_if_new, tree_check,
6577 execute_tree_check): Use VECs instead of varrays.
6578 (gate_tree_check): Don't execute the CFG check when basic_block_info
6581 2007-01-12 Sebastian Pop <sebastian.pop@inria.fr>
6583 * Merge from mainline (r115016:120733).
6585 2007-01-12 Sebastian Pop <sebastian.pop@inria.fr>
6587 * Merge from mainline (r117632:117661).
6589 2007-01-12 Sebastian Pop <sebastian.pop@inria.fr>
6591 * tree-dump.c (dump_option_value_in): Add TDF_DEBUG.
6592 * tree-pass.h (TDF_DEBUG, debug_p): New.
6593 * tree-scalar-evolution.c (set_scalar_evolution, get_scalar_evolution,
6594 get_scalar_evolution, add_to_evolution, set_nb_iterations_in_loop,
6595 get_loop_exit_condition, analyze_evolution_in_loop,
6596 analyze_initial_condition, analyze_scalar_evolution,
6597 instantiate_parameters, number_of_latch_executions): Use debug_p.
6598 * tree-chrec.c (chrec_apply): Use debug_p.
6599 * tree-data-ref.c: Include graphite.h.
6600 (dump_data_reference): Print also the access matrix.
6601 (analyze_array, analyze_indirect_ref, init_data_ref,
6602 analyze_offset_expr, address_analysis, object_analysis,
6603 create_data_ref, finalize_ddr_dependent,
6604 non_affine_dependence_relation, analyze_ziv_subscript,
6605 analyze_siv_subscript_cst_affine,
6606 compute_overlap_steps_for_affine_1_2, analyze_subscript_affine_affine,
6607 can_use_analyze_subscript_affine_affine, analyze_siv_subscript,
6608 analyze_miv_subscript, analyze_overlapping_iterations,
6609 build_classic_dist_vector, subscript_dependence_tester,
6610 compute_affine_dependence, analyze_all_data_dependences): Use debug_p.
6611 (build_access_matrix_with_af): No longer static.
6612 * tree-data-ref.h (scop_p): ... declaration here.
6613 (data_reference.scop): New field.
6614 (DR_SCOP, DR_ACCESS_MATRIX): New.
6615 (build_access_matrix_with_af, dr_num_subscripts): Declared.
6616 * graphite.c (print_graphite_bb): Call dump_data_references.
6617 (print_scop): Use scop_nb_loops and scop_dim_domain.
6618 (test_for_scop_bound): Use debug_p.
6619 (scan_tree_for_params): Use scop_nb_loops, scop_nb_loops and
6621 (scop_loop_index): Moved...
6622 (scop_record_loop): New.
6623 (build_scop_loop_nests): Use scop_record_loop.
6624 (build_scop_domain): Use scop_dim_domain.
6625 (build_access_matrix): Implemented.
6626 (build_scop_canonical_schedules): Use scop_nb_loops.
6627 (build_graphite_bb): Initialize GBB_SCOP.
6628 * graphite.h (scop_p): Moved...
6629 (graphite_bb.scop): New field.
6630 (graphite_bb.iteration_domain, GBB_DOMAIN, scop.nb_params,
6631 scop.nb_loops, scop.dim_domain, SCOP_NB_LOOPS, SCOP_NB_PARAMS,
6632 SCOP_DIM_DOMAIN, SCOP_STMTS): Removed.
6633 (scop_nb_params, scop_nb_loops, scop_dim_domain, gbb_dim_domain,
6634 scop_loop_index): New.
6635 * Makefile.in (tree-data-ref.o): Depends on graphite.h.
6637 2007-01-05 Sebastian Pop <sebastian.pop@inria.fr>
6639 * Merge from mainline (r117661:120450).
6641 2006-10-12 Sebastian Pop <sebastian.pop@inria.fr>
6643 * tree-scalar-evolution.c (instantiate_parameters_1): Don't stop
6644 at the first declaration outside the varying loop, instantiate as
6646 * tree-chrec.c (for_each_scev_op): New.
6647 * tree-chrec.h (for_each_scev_op): Declared.
6648 * tree-ssa-loop.c (pass_graphite_trans): Don't dump the function.
6649 * tree-data-ref.c (get_references_in_stmt,
6650 find_data_references_in_stmt): New, from trunk.
6651 (find_data_references_in_loop): Use get_references_in_stmt
6652 and find_data_references_in_loop, modified as in trunk.
6653 (build_access_matrix_with_af): New.
6654 * tree-data-ref.h (data_reference): Add a field access_matrix.
6655 (data_ref_loc): New, as in trunk.
6656 * graphite.c (print_graphite_bb, bb_in_scop_p, stmt_in_scop_p,
6657 invariant_in_scop_p, param_index, scan_tree_for_params,
6658 scop_loop_index, build_scop_loop_nests, build_scop_domain, irp_data,
6659 idx_record_param, idx_record_params, build_access_matrix,
6660 build_scop_data_accesses, build_scop_canonical_schedules,
6661 build_graphite_bb, build_scop_bbs, find_params_in_bb,
6662 build_scop_params): New.
6663 * graphite.h (graphite_bb): New.
6664 (scop): Add fields static_schedule, params, loop_nest,
6666 * lambda.h: Declare vecs of lambda_matrix.
6667 * tree-flow.h (print_loop_ir_bb): Declared.
6668 * tree-cfg.c (print_loop_ir_bb): New.
6669 (print_loop): Use print_loop_ir_bb.
6671 2006-10-12 Sebastian Pop <pop@cri.ensmp.fr>
6673 * Merge from mainline (r115016:117632).
6675 2006-10-11 Sebastian Pop <pop@cri.ensmp.fr>
6677 * graphite.c (debug_scops): Adjust definition for avoiding a bootstrap
6678 break due to a warning.
6680 2006-10-10 Sebastian Pop <pop@cri.ensmp.fr>
6682 * graphite.c (print_scops, debug_scops): New.
6683 (graphite_transform): Renamed graphite_find_transform.
6684 * graphite.h (debug_scops): Declared.
6686 2006-08-17 Sebastian Pop <pop@cri.ensmp.fr>
6688 * tree-match.c: Reformat following the GNU style.
6689 * tree-match.h: Reformat following the GNU style.
6690 * tree-pattern.h: Removed empty file.
6691 * Makefile.in: Remove references to tree-pattern.h.
6692 * tree-check.c: Reformat following the GNU style.
6693 (execute_tree_check): Move gate condition code to...
6694 (gate_tree_check): ...here. New function.
6695 (pass_check): Use the gate function.
6697 2006-07-04 Nic Volanschi <nic.volanschi@free.fr>
6699 * tree-pattern.h: New. Tree pattern matching and checking using
6701 * tree-check.c: New. Tree/CFG checking pass.
6702 * tree-match.c: New. Library for tree pattern matching.
6703 * opts.c, common.opt: Add options --ftree-check & --ftree-checks.
6704 * toplev.c, flags.h: Add globals for tree-check pass.
6705 * Makefile.in: Integrate the files in tree-check pass.
6706 * timevar.def, tree-optimize.c, tree-pass.h: Register tree-check pass.
6707 * pretty-print.c, pretty-print.h, tree-pretty-print.c, diagnostic.h:
6708 Introduce a "lazy" pretty-print mode.
6709 * tree.c, tree.h: Add tree_name.
6711 2006-07-04 Sebastian Pop <pop@cri.ensmp.fr>
6713 * doc/invoke.texi (-fgraphite): Correct typo.
6714 * tree-scalar-evolution.c (number_of_iterations_for_all_loops): Update
6715 use of print_loop_ir.
6716 * testsuite/gcc.dg/graphite/scop-1.c: New.
6717 * testsuite/gcc.dg/graphite/scop-2.c: New.
6718 * testsuite/gcc.dg/graphite/graphite.exp: New.
6719 * graphite.c: Include domwalk.h.
6720 (print_scop): Print only the entry and exit blocks.
6721 (debug_scop): No longer static.
6722 (affine_expr): Fix formating. Return also true when the expression is
6724 (stmt_simple_for_scop_p): Fix formating.
6725 (build_scops): Use domwalk.
6726 (get_loop_start, end_scop, test_for_scop_bound): New.
6727 (graphite_transform_loops): Avoid printing on stderr.
6728 * graphite.h (debug_scop): Declared.
6729 * tree-flow.h (debug_loop_ir, print_loop_ir): Update declarations.
6730 * Makefile.in (graphite.o): Depend on domwalk.h.
6731 * tree-cfg.c (print_loop, print_pred_bbs, print_succ_bbs): Remove
6732 declarations for static functions.
6733 (print_loop, print_loop_ir, debug_loop_ir): Use an extra parameter for
6734 controlling output verbosity.
6736 2006-06-26 Sebastian Pop <pop@cri.ensmp.fr>
6737 Plesco Alexandru <shurikx@gmail.com>
6739 * doc/invoke.texi (-fgraphite): Document.
6740 * tree-pass.h (pass_graphite_transforms): Declared.
6741 * timevar.def (TV_GRAPHITE_TRANSFORMS): New.
6742 * tree-ssa-loop.c (graphite_transforms, gate_graphite_transforms): New.
6743 (pass_graphite_transforms): Defined.
6744 * tree-data-ref.c (free_data_ref, data_reference): Extern.
6745 * tree-data-ref.h (free_data_ref, data_reference): Declared.
6746 * graphite.c, graphite.h: New.
6747 * common.opt (fgraphite): Declared.
6748 * tree-flow.h (graphite_transform_loops): Declared.
6749 * Makefile.in (OBJS-common): Add graphite.o.
6750 (graphite.o): New rule.
6751 * passes.c (pass_graphite_transforms): Scheduled.