1 2011-01-17 Sebastian Pop <sebastian.pop@amd.com>
3 * graphite-dependences.c (reduction_dr_1): Allow several reductions
5 * graphite-sese-to-poly.c (split_reduction_stmt): Do not split PBBs
6 that have already been marked as PBB_IS_REDUCTION.
8 2011-01-17 Sebastian Pop <sebastian.pop@amd.com>
10 * graphite-scop-detection.c (same_close_phi_node): New.
11 (remove_duplicate_close_phi): New.
12 (make_close_phi_nodes_unique): New.
13 (canonicalize_loop_closed_ssa): Call make_close_phi_nodes_unique.
15 2011-01-17 Sebastian Pop <sebastian.pop@amd.com>
17 * graphite-dependences.c (new_poly_ddr): Call same_pdr_p.
18 * graphite-poly.h (same_pdr_p): Do not expect that the PDR_TYPE
19 of both data references to be the same.
21 2011-01-17 Sebastian Pop <sebastian.pop@amd.com>
23 * graphite-dependences.c (build_lexicographical_constraint): Remove the
25 (build_lexicographical_constraint): Adjust call to ppl_powerset_is_empty.
26 (dependence_polyhedron): Same.
27 (graphite_legal_transform_dr): Same.
28 (graphite_carried_dependence_level_k): Same.
29 * graphite-ppl.c (ppl_powerset_is_empty): Remove the nb_params parameter.
30 * graphite-ppl.h (ppl_powerset_is_empty): Adjust declaration.
32 2011-01-15 Sebastian Pop <sebastian.pop@amd.com>
34 * graphite-sese-to-poly.c
35 (translate_scalar_reduction_to_array_for_stmt): Call unshare_expr.
36 (close_phi_written_to_memory): New.
37 (translate_scalar_reduction_to_array): Call close_phi_written_to_memory
40 * gcc.dg/graphite/block-0.c: Un-XFAILed.
41 * gcc.dg/graphite/block-1.c: Un-XFAILed.
42 * gcc.dg/graphite/block-7.c: Un-XFAILed.
43 * gcc.dg/graphite/block-8.c: Un-XFAILed.
44 * gcc.dg/graphite/interchange-12.c: Un-XFAILed.
45 * gcc.dg/graphite/interchange-14.c: Un-XFAILed.
46 * gcc.dg/graphite/interchange-15.c: Un-XFAILed.
47 * gcc.dg/graphite/interchange-8.c: Un-XFAILed.
48 * gcc.dg/graphite/interchange-mvt.c: Un-XFAILed.
50 2011-01-15 Sebastian Pop <sebastian.pop@amd.com>
52 * doc/install.texi: Update the expected version number of PPL to 0.11.
53 * graphite-ppl.c (ppl_powerset_is_empty): Remove now dead code under
54 #if PPL_VERSION_MINOR < 11.
56 2011-01-15 Sebastian Pop <sebastian.pop@amd.com>
58 * graphite-dependences.c (new_poly_ddr): Inlined into
59 dependence_polyhedron.
60 (free_poly_ddr): Moved close by new_poly_ddr.
61 (dependence_polyhedron_1): Renamed dependence_polyhedron.
62 Early return NULL when ppl_powerset_is_empty returns true.
63 (dependence_polyhedron): Renamed new_poly_ddr. Call only once
64 poly_drs_may_alias_p. Avoid one call to ppl_powerset_is_empty.
65 (graphite_legal_transform_dr): Call new_poly_ddr.
66 (graphite_carried_dependence_level_k): Same.
67 (dot_original_deps_stmt_1): Renamed dot_deps_stmt_2. Use new_poly_ddr.
68 (dot_transformed_deps_stmt_1): Removed.
69 (dot_deps_stmt_1): Call dot_deps_stmt_2.
70 (dot_original_deps): Renamed dot_deps_2. Call new_poly_ddr.
71 (dot_deps_1): Call dot_deps_2.
73 2011-01-15 Sebastian Pop <sebastian.pop@amd.com>
75 * graphite-dependences.c (new_poly_dr): Call ppl_powerset_is_empty.
76 (build_lexicographical_constraint): Same.
77 (dependence_polyhedron_1): Same.
78 (graphite_legal_transform_dr): Same.
79 (graphite_carried_dependence_level_k): Same.
80 * graphite-ppl.c (ppl_powerset_is_empty): New.
81 * graphite-ppl.h (ppl_powerset_is_empty): Declared.
82 * tree-data-ref.c (dump_data_reference): Print the basic block index.
84 * gcc.dg/graphite/block-0.c: Add documentation.
85 * gcc.dg/graphite/block-4.c: Same.
86 * gcc.dg/graphite/block-7.c: Same.
87 * gcc.dg/graphite/block-8.c: New.
88 * gcc.dg/graphite/interchange-1.c: Un-XFAILed.
89 * gcc.dg/graphite/interchange-11.c: Un-XFAILed.
90 * gcc.dg/graphite/interchange-12.c: Add documentation.
91 * gcc.dg/graphite/interchange-13.c: New.
92 * gcc.dg/graphite/interchange-14.c: New.
93 * gcc.dg/graphite/interchange-15.c: New.
94 * gcc.dg/graphite/interchange-8.c: Add documentation.
95 * gcc.dg/graphite/interchange-mvt.c: Same.
97 2011-01-15 Sebastian Pop <sebastian.pop@amd.com>
99 * graphite-dependences.c (build_pairwise_scheduling): Correctly compute
100 the "a followed by b" relation and document it.
102 2011-01-15 Sebastian Pop <sebastian.pop@amd.com>
104 * graphite-dependences.c (build_lexicographical_constraint): Stop the
105 iteration when the bag of constraints is empty.
107 2011-01-15 Sebastian Pop <sebastian.pop@amd.com>
109 * graphite-poly.c (pbb_remove_duplicate_pdrs): Make it work.
111 2011-01-15 Sebastian Pop <sebastian.pop@amd.com>
113 * graphite-interchange.c (lst_interchange_profitable_p): Takes a loop
114 nest and two loop depths as parameters.
115 (lst_try_interchange_loops): Call lst_interchange_profitable_p after
118 2011-01-15 Sebastian Pop <sebastian.pop@amd.com>
120 * graphite-dependences.c (print_pddr): Call
121 ppl_io_fprint_Pointset_Powerset_C_Polyhedron.
123 2011-01-15 Sebastian Pop <sebastian.pop@amd.com>
125 * graphite-ppl.c (debug_gmp_value): New.
126 * graphite-ppl.h (debug_gmp_value): Declared.
128 2011-01-13 Tobias Grosser <grosser@fim.uni-passau.de>
130 * doc/install.texi: Document availability of cloog-0.16
132 2011-01-05 Vladimir Kargov <kargov@gmail.com>
134 * graphite-scop-detection.c (is_valid_stmt_p): Pass the entry basic
135 block instead of region start to the instantiation.
136 (is_valid_bb_p): Add support for basic blocks with conditional
138 (find_scops_new): Recalculate dominance info before SCOP
141 2011-01-05 Vladimir Kargov <kargov@gmail.com>
143 * graphite-scop-detection.c (get_outermost_loop_in_region): New.
144 (is_valid_loop_p): Correct loop passed to stmt_has_simple_data_refs_p
146 2011-01-05 Vladimir Kargov <kargov@gmail.com>
148 * graphite-scop-detection.c (canonicalize_loop_closed_ssa): Free
149 invalid postdominance info
151 2010-12-29 Sebastian Pop <sebastian.pop@amd.com>
153 * Makefile.in (graphite-opencl-codegen.o): Update dependences.
154 (graphite-opencl-meta-clast.o): Same.
155 (graphite-opencl.o): Same.
156 (refined-regions.o): Same.
157 * graphite-opencl-codegen.c: Do not include unnecessary .h files.
158 * graphite-opencl-meta-clast.c: Same.
159 * graphite-opencl.c: Same.
160 * refined-regions.c: Same.
162 2010-12-27 Sebastian Pop <sebastian.pop@amd.com>
164 * graphite-opencl-codegen.c: Use FOR_EACH_VEC_ELT.
165 * graphite-opencl-meta-clast.c: Same.
166 * graphite-opencl.c: Same.
168 2010-12-27 Sebastian Pop <sebastian.pop@amd.com>
170 * graphite-opencl-codegen.c: Do not include sys/time.h.
171 * graphite-opencl.c: Same.
173 2010-12-27 Sebastian Pop <sebastian.pop@amd.com>
175 * graphite-opencl.c (h_context, h_cmd_queue, h_program): Moved
176 out of ifdef HAVE_cloog section.
178 2010-12-27 Sebastian Pop <sebastian.pop@amd.com>
180 * Makefile.in (graphite-opencl.o): Depends on
181 graphite-opencl-functions.def.
182 * graphite-opencl-functions.def: New.
183 * graphite-opencl.c (enum OPENCL_FUNCTIONS): Read data from
184 graphite-opencl-functions.def.
185 (opencl_function_names): Same.
186 (opencl_create_function_decl): Use the enum OPENCL_FUNCTIONS
187 as indices of opencl_function_names.
189 2010-12-27 Sebastian Pop <sebastian.pop@amd.com>
191 * graphite-opencl-codegen.c: Fix formatting.
192 * graphite-opencl-meta-clast.c: Same.
193 * graphite-opencl.c: Same.
195 2010-12-27 Sebastian Pop <sebastian.pop@amd.com>
197 * graphite-opencl-codegen.c: Fix formating problems.
198 * graphite-opencl-meta-clast.c: Same.
199 * graphite-opencl.c: Same.
200 * graphite-opencl.h: Same.
202 2010-12-27 Sebastian Pop <sebastian.pop@amd.com>
204 * graphite-opencl-codegen.c: Sort topologically static functions.
205 * graphite-opencl.c: Same.
207 2010-12-25 Sebastian Pop <sebastian.pop@amd.com>
209 * graphite-cloog-compat.h (cloog_names_nb_scattering): New.
210 (cloog_names_scattering): New.
211 * graphite-opencl-codegen.c (opencl_constant_expression_p): Use
212 clast_expr_* instead of expr_*. Call clast_name_to_str.
213 (opencl_clast_name_to_tree): Now takes a clast_name_p in parameter.
214 (opencl_get_scat_real_name): Same. Call clast_name_to_str.
215 (opencl_add_scat_as_arg): Same.
216 (opencl_print_local_vars): Call cloog_names_scattering and
217 cloog_names_nb_scattering.
218 (opencl_print_for): Do not call value_*.
219 (opencl_print_term): Same.
220 (opencl_print_expr): Use clast_expr_* instead of expr_*.
221 (opencl_print_sum): Same.
222 (opencl_print_binary): Same.
224 2010-12-25 Alexey Kravets <kayrick@ispras.ru>
226 * Makefile.in (OBJS-common): Add graphite-opencl-codegen.o,
227 graphite-opencl-meta-clast.o and graphite-opencl.o.
228 (graphite-opencl-codegen.o): New.
229 (graphite-opencl-meta-clast.o): New.
230 (graphite-opencl.o): New.
231 (GTFILES): Add graphite-opencl.c.
232 * common.opt (fgraphite-opencl): New.
233 (fgraphite-opencl-cpu): New.
234 (fgraphite-opencl-ignore-depth-heuristic): New.
235 (fgraphite-opencl-ignore-mem-heuristic): New.
236 (fgraphite-opencl-ignore-dep): New.
237 (fgraphite-opencl-ignore-types): New.
238 (fgraphite-opencl-depth-base): New.
239 (fgraphite-opencl-debug): New.
240 * graphite-opencl-codegen.c: New file.
241 * graphite-opencl-meta-clast.c: New file.
242 * graphite-opencl.c: New file.
243 * graphite-opencl.h: New file.
244 * graphite.c (graphite_transform_loops): Call graphite_opencl_init and
245 graphite_opencl_finalize.
246 * tree-ssa-loop.c (gate_graphite_transforms): Handle
247 flag_graphite_opencl.
248 * graphite-clast-to-gimple.c (gloog): Call opencl_transform_clast.
249 * dbgcnt.def (opencl_scop_cnt): New counter.
251 2010-12-25 Alexander Monakov <amonakov@ispras.ru>
253 * graphite-dependences.c (graphite_outer_subscript_bound): New.
254 (graphite_carried_dependence_level_k): Export.
255 * graphite-dependences.h (graphite_outer_subscript_bound): Declare.
256 (graphite_carried_dependence_level_k): Ditto.
258 2010-12-25 Alexey Kravets <kayrick@ispras.ru>
260 * graphite-clast-to-gimple.c (struct clast_name_index): Move
261 definition to graphite-clast-to-gimple.h.
262 (clast_name_to_index): Ditto.
263 (clast_name_index_elt_info): Ditto.
264 (eq_clast_name_indexes): Ditto.
265 (save_clast_name_index): Export.
266 (clast_name_to_gcc): Ditto.
267 (clast_to_gcc_expression): Ditto.
268 (gcc_type_for_clast_expr): Ditto.
269 (graphite_create_new_guard): Ditto.
270 (gcc_type_for_iv_of_clast_loop): Ditto.
271 (graphite_create_new_loop): Ditto.
272 (build_iv_mapping): Ditto.
273 (graphite_create_new_loop_guard): Ditto.
274 (debug_clast_name_index): New.
275 (debug_clast_name_indices): New debug function.
277 2010-12-21 Sebastian Pop <sebastian.pop@amd.com>
279 PR tree-optimization/47021
280 * graphite-sese-to-poly.c (scan_tree_for_params): Handle ADDR_EXPR.
282 2010-11-26 Sebastian Pop <sebastian.pop@amd.com>
284 * graphite-sese-to-poly.c (analyze_drs_in_stmts): Fix set but
286 (rewrite_cross_bb_scalar_deps_out_of_ssa): Same.
288 2010-11-26 Sebastian Pop <sebastian.pop@amd.com>
290 * graphite-sese-to-poly.c (analyze_drs): Removed.
291 (build_scop_drs): Do not call analyze_drs.
292 (analyze_drs_in_stmts): New.
294 (insert_out_of_ssa_copy): Call analyze_drs_in_stmts.
295 (insert_out_of_ssa_copy_on_edge): Same.
296 (rewrite_close_phi_out_of_ssa): Call insert_stmts.
297 (rewrite_phi_out_of_ssa): Same.
298 (rewrite_cross_bb_scalar_dependence): Same.
299 (split_reduction_stmt): Move data references in the new basic blocks.
300 (translate_scalar_reduction_to_array_for_stmt): Call insert_stmts.
302 2010-11-26 Sebastian Pop <sebastian.pop@amd.com>
304 * sese.c (rename_uses): Do not handle ADDR_EXPR in LHS of assignments.
306 2010-11-22 Sebastian Pop <sebastian.pop@amd.com>
309 * graphite-poly.c (new_poly_bb): Returns a poly_bb_p. Do not take
310 the reduction bool in parameter. Clear PBB_IS_REDUCTION. Set GBB_PBB.
311 * graphite-poly.h (new_poly_bb): Update declaration.
312 (gbb_from_bb): Moved here...
314 * graphite-sese-to-poly.c (var_used_in_not_loop_header_phi_node):
316 (graphite_stmt_p): Removed.
317 (try_generate_gimple_bb): Returns a gimple_bb_p. Do not pass in
318 sbitmap reductions. Always build a gimple_bb_p. Do not call
320 (build_scop_bbs_1): Do not pass in sbitmap reductions.
321 (build_scop_bbs): Same.
322 (gbb_from_bb): ... from here.
323 (add_conditions_to_constraints): Moved up.
325 (build_scop_drs): Call analyze_drs. Remove all the PBBs that do
326 not contain data references.
327 (new_pbb_from_pbb): New.
328 (insert_out_of_ssa_copy_on_edge): Call new_pbb_from_pbb after a
330 (rewrite_close_phi_out_of_ssa): Update call to
331 insert_out_of_ssa_copy_on_edge.
332 (rewrite_reductions_out_of_ssa): Now static.
333 (rewrite_cross_bb_scalar_deps_out_of_ssa): Same.
335 (split_reduction_stmt): Call split_pbb.
336 (translate_scalar_reduction_to_array): Pass in the scop, do not
337 pass in the sbitmap reductions.
338 (rewrite_commutative_reductions_out_of_ssa_close_phi): Same.
339 (rewrite_commutative_reductions_out_of_ssa_loop): Same.
340 (rewrite_commutative_reductions_out_of_ssa): Same.
341 (build_poly_scop): Call build_scop_bbs,
342 rewrite_commutative_reductions_out_of_ssa,
343 rewrite_reductions_out_of_ssa, and
344 rewrite_cross_bb_scalar_deps_out_of_ssa. Move build_scop_drs
346 * graphite-sese-to-poly.h (rewrite_commutative_reductions_out_of_ssa):
348 (rewrite_reductions_out_of_ssa): Same.
349 (rewrite_cross_bb_scalar_deps_out_of_ssa): Same.
350 (build_scop_bbs): Same.
351 * graphite.c (graphite_transform_loops): Do not initialize reductions.
352 Do not call build_scop_bbs,
353 rewrite_commutative_reductions_out_of_ssa,
354 rewrite_reductions_out_of_ssa, and
355 rewrite_cross_bb_scalar_deps_out_of_ssa.
356 * sese.h (struct gimple_bb): Add field pbb.
359 * gcc.dg/graphite/pr45297.c: New.
361 2010-11-22 Sebastian Pop <sebastian.pop@amd.com>
363 * graphite-sese-to-poly.c (handle_scalar_deps_crossing_scop_limits):
365 (rewrite_cross_bb_scalar_deps): Pass in the scop. Call
366 handle_scalar_deps_crossing_scop_limits.
367 (rewrite_cross_bb_scalar_deps_out_of_ssa): Create an empty BB
368 after the scop. Update call to rewrite_cross_bb_scalar_deps.
370 2010-11-22 Sebastian Pop <sebastian.pop@amd.com>
372 * sese.c (rename_uses): Call recompute_tree_invariant_for_addr_expr
373 when replacing a constant in an ADDR_EXPR.
375 2010-10-20 Sebastian Pop <sebastian.pop@amd.com>
377 * graphite-blocking.c (lst_do_strip_mine_loop): Extra parameter
379 (lst_do_strip_mine): Same.
380 (scop_do_strip_mine): Same.
381 * graphite-poly.c (apply_poly_transforms): Update call to
383 * graphite-poly.h (scop_do_strip_mine): Update declaration.
385 2010-09-24 Sebastian Pop <sebastian.pop@amd.com>
388 * graphite.c (graphite_initialize): Call scev_reset.
390 2010-09-23 Sebastian Pop <sebastian.pop@amd.com>
392 * sese.h (scev_analyzable_p): Return false for real or floating
393 point. Only handle INTEGRAL_TYPE_P and POINTER_TYPE_P.
395 2010-09-23 Sebastian Pop <sebastian.pop@amd.com>
398 * gfortran.dg/graphite/pr45758.f90: New.
400 2010-09-23 Sebastian Pop <sebastian.pop@amd.com>
402 * graphite-scop-detection.c (is_scop_p): Free bblist.
404 2010-09-23 Sebastian Pop <sebastian.pop@amd.com>
406 * graphite-clast-to-gimple.c (compute_bounds_for_level): Free le
408 * graphite-poly.c (pbb_number_of_iterations_at_time): Free le and
410 * graphite-sese-to-poly.c (add_upper_bounds_from_estimated_nit):
411 Do not allocate ub_expr, it is passed in initialized.
413 2010-09-21 Andreas Simbuerger <simbuerg@fim.uni-passau.de>
415 * common.opt (fgraphite-dump-cloog): New flag.
416 * doc/invoke.texi (-fgraphite-dump-cloog): Documented.
417 * graphite-clast-to-gimple.c (init_cloog_input_file): New.
418 (build_cloog_prog): Dump CLooG input file when
419 flag_graphite_dump_cloog is set.
420 * graphite-cloog-compat.h (cloog_program_dump_cloog): New.
422 2010-09-20 Sebastian Pop <sebastian.pop@amd.com>
424 Revert previous patch "New flag: -fgraphite-dump-cloog."
426 2010-09-20 Andreas Simbuerger <simbuerg@fim.uni-passau.de>
428 * common.opt (fgraphite-dump-cloog): New flag.
429 * doc/invoke.texi (-fgraphite-dump-cloog): Documented.
430 * graphite-clast-to-gimple.c (init_cloog_input_file): New.
431 (build_cloog_prog): Dump CLooG input file when
432 flag_graphite_dump_cloog is set.
434 2010-09-20 Sebastian Pop <sebastian.pop@amd.com>
436 * graphite-clast-to-gimple.c (graphite_verify): Remove call to
437 verify_dominators for CDI_POST_DOMINATORS.
438 * sese.h: Remove comment about CDI_POST_DOMINATORS.
439 (recompute_all_dominators): Remove call to free_dominance_info
440 for CDI_POST_DOMINATORS. Remove call to calculate_dominance_info
441 for CDI_POST_DOMINATORS.
443 2010-09-09 Sebastian Pop <sebastian.pop@amd.com>
445 * graphite-poly.c (pbb_number_of_iterations_at_time): Only iterate
446 over pbb_dim_iter_domain.
448 2010-09-09 Sebastian Pop <sebastian.pop@amd.com>
450 * graphite-flattening.c: Fix comments.
452 2010-09-09 Sebastian Pop <sebastian.pop@amd.com>
454 * Makefile.in (OBJS-common): Add graphite-flattening.o.
455 (graphite-flattening.o): New rule.
456 * common.opt (floop-flatten): New flag.
457 * doc/invoke.texi (-floop-flatten): Documented.
458 * graphite-flattening.c: New.
459 * graphite-poly.c (apply_poly_transforms): Call flatten_all_loops.
460 * graphite-poly.h (flatten_all_loops): Declared.
461 (lst_remove_loop_and_inline_stmts_in_loop_father): New.
462 * tree-ssa-loop.c (gate_graphite_transforms): When flag_loop_flatten
463 is set, also set flag_graphite.
465 2010-09-09 Sebastian Pop <sebastian.pop@amd.com>
467 * graphite-poly.c (cloog_checksum): New.
468 * graphite-poly.h (cloog_checksum): Declared.
470 2010-09-09 Sebastian Pop <sebastian.pop@amd.com>
472 * graphite-poly.c (pbb_number_of_iterations): Removed.
473 (pbb_number_of_iterations_at_time): Correctly compute the number
474 of iterations in the transformed loop.
475 * graphite-poly.h (pbb_number_of_iterations): Removed.
477 2010-09-09 Sebastian Pop <sebastian.pop@amd.com>
479 * graphite-poly.h (lst_update_scattering_seq): Removed.
480 (lst_update_scattering): Correctly handle outermost loop dewey
483 2010-09-09 Sebastian Pop <sebastian.pop@amd.com>
485 * graphite-blocking.c (pbb_strip_mine_profitable_p): Renamed
486 lst_strip_mine_profitable_p. Call lst_niter_for_loop.
487 * graphite-poly.h (lst_niter_for_loop): New.
489 2010-09-09 Sebastian Pop <sebastian.pop@amd.com>
491 * graphite-poly.c (apply_poly_transforms): Do not abort when the
492 transform read from disk is not legal. Call fatal_error instead.
494 2010-09-09 Sebastian Pop <sebastian.pop@amd.com>
496 * graphite-poly.c (print_pbb_body): Add missing closing parenthesis.
497 (print_scop_header): Removed. Inlined in the only call place...
498 (print_scop): ... here.
500 2010-09-09 Sebastian Pop <sebastian.pop@amd.com>
502 * graphite-poly.h (lst_dewey_number): Use FOR_EACH_VEC_ELT.
504 2010-09-02 Vladimir Kargov <kargov@gmail.com>
506 * graphite-scop-detection.c (is_valid_expr_p, is_valid_loop_p): New.
507 (is_valid_stmt_p): Add data reference and operation-specific checks.
508 (is_valid_bb_p): Change structure, add loop validity check.
509 (is_scop_p): Move the TODO list
510 (find_scops_new): New.
511 (build_scops_new): Move part of functionality to find_scops_new and
512 build_scops. Add necessary steps for successful SCoP construction.
513 (build_scops): Compute SCoP sets for both detection algorithms, choose
514 the resulting one depending on static condition.
516 2010-08-24 Sebastian Pop <sebastian.pop@amd.com>
518 * graphite-poly.c (graphite_read_scop_file): Fix uninitialize warning.
520 2010-08-24 Sebastian Pop <sebastian.pop@amd.com>
522 * graphite-dependences.c (dot_deps): Avoid set but not used warning.
523 (dot_deps_stmt): Same.
524 * graphite-poly.c (dot_lst): Same.
526 2010-08-23 Sebastian Pop <sebastian.pop@amd.com>
528 * graphite-blocking.c (scop_do_strip_mine): Do not call
529 graphite_legal_transform.
530 (scop_do_block): Same.
532 2010-08-20 Vladimir Kargov <kargov@gmail.com>
534 * graphite-scop-detection.c (graphite_can_represent_loop): Correct the
537 2010-08-20 Sebastian Pop <sebastian.pop@amd.com>
540 * gcc.dg/graphite/id-pr45230.c: New.
542 2010-08-20 Sebastian Pop <sebastian.pop@amd.com>
544 * tree-scalar-evolution.c (instantiate_array_ref): New.
545 (instantiate_scev_r): Also handle ARRAY_REFs.
547 2010-08-20 Sebastian Pop <sebastian.pop@amd.com>
549 * tree-scalar-evolution.c (chrec_contains_symbols_defined_in_loop):
550 Do not check for VAR_DECL, PARM_DECL, FUNCTION_DECL, LABEL_DECL,
551 RESULT_DECL, and FIELD_DECL. Return false for an
552 SSA_NAME_IS_DEFAULT_DEF.
553 (compute_scalar_evolution_in_loop): Do not further analyze the
554 scalar evolution when no_evolution_in_loop_p returns true.
556 2010-08-20 Sebastian Pop <sebastian.pop@amd.com>
558 * tree-chrec.h (evolution_function_is_affine_p): Do not check
559 whether CHREC_LEFT is invariant. A function is affine when
560 CHREC_RIGHT is invariant.
562 2010-08-20 Sebastian Pop <sebastian.pop@amd.com>
564 * graphite-sese-to-poly.c (reduction_phi_p): Remove check for
566 (rewrite_degenerate_phi): Same.
567 (rewrite_reductions_out_of_ssa): Add check for is_gimple_reg.
569 2010-08-18 Vladimir Kargov <kargov@gmail.com>
571 * graphite-scop-detection.c (graphite_can_represent_scev,
572 graphite_can_represent_expr, stmt_has_simple_data_refs_p,
573 graphite_can_represent_loop): Remove outermost_loop.
575 2010-08-17 Sebastian Pop <sebastian.pop@amd.com>
578 * graphite-sese-to-poly.c (rewrite_cross_bb_scalar_deps): Do not
579 handle GIMPLE_CALLs with no LHS.
581 2010-08-17 Riyadh Baghdadi <baghdadi.mr@gmail.com>
582 Sebastian Pop <sebastian.pop@amd.com>
584 * gcc.dg/graphite/graphite.exp: Add test rules for openscop read/write.
585 Call remove-build-file to clean up the generated *.graphite files.
587 2010-08-17 Riyadh Baghdadi <baghdadi.mr@gmail.com>
589 * doc/invoke.texi (debugging options): Update documentation.
590 (-floop-interchange): Same.
591 (-flopp-strip-mine): Same.
592 (-floop-block): Same.
593 (-fgraphite-read): Add documentation.
594 (-fgraphite-write): Same.
596 2010-08-17 Riyadh Baghdadi <baghdadi.mr@gmail.com>
598 * toplev.c (process_options): Disable graphite loop optimization
599 options when -fgraphite-read flag is used.
601 2010-08-17 Riyadh Baghdadi <baghdadi.mr@gmail.com>
603 * graphite-poly.c (init_graphite_out_file): New.
604 (init_graphite_in_file): New.
605 (apply_poly_transforms): Updated to enable reading and writing of
607 * toplev.c (init_asm_output): Remove graphite in/out file initialization.
609 2010-08-17 Tobias Grosser <grosser@fim.uni-passau.de>
611 * graphite-scop-detection.c (graphite_can_represent_scev): Remove
614 2010-08-12 Sebastian Pop <sebastian.pop@amd.com>
616 * graphite-clast-to-gimple.c (precision_for_value): Adjust
617 computation of precision by 1.
619 2010-08-12 Riyadh Baghdadi <baghdadi.mr@gmail.com>
621 * graphite-cloog-util.c (openscop_read_cloog_matrix): New.
622 (openscop_read_polyhedron_matrix): New.
623 * graphite-cloog-util.h (openscop_read_polyhedron_matrix): Declared.
624 (openscop_read_N_int): Same.
625 * graphite-poly.c (openscop_read_N_int): New.
626 (openscop_read_one_int): New.
627 (openscop_read_N_string): New.
628 (openscop_read_one_string): New.
629 (openscop_read_powerset_matrix): New.
630 (graphite_read_transforms): Remove.
631 (graphite_read_scatt): New.
632 (graphite_read_scop_file): New.
633 (apply_poly_transforms): Updated to call graphite_read_scop_file.
635 2010-08-11 Andreas Simbuerger <simbuerg@fim.uni-passau.de>
637 * graphite-poly.c: Change include order.
639 2010-08-11 Andreas Simbuerger <simbuerg@fim.uni-passau.de>
641 * graphite-cloog-compat.h (cloog_matrix_ncolumns): New.
642 (cloog_matrix_nrows): New.
644 2010-08-11 Riyadh Baghdadi <baghdadi.mr@gmail.com>
646 * graphite-cloog-util.c (openscop_print_cloog_matrix): Remove spaces
648 * graphite-poly.c (openscop_print_scattering_function_1): Same.
649 (print_scattering_function_1): Same.
650 (openscop_print_pbb_domain): Same.
651 (openscop_print_scop_context): Same.
652 (print_scop_context): Same.
654 2010-08-11 Riyadh Baghdadi <baghdadi.mr@gmail.com>
656 * graphite-poly.c (openscop_print_pdr_polyhedron): Fix indentation.
657 (openscop_print_pdr_polyhedron): Print pph.
659 2010-07-29 Sebastian Pop <sebastian.pop@amd.com>
661 * gcc.dg/graphite/graphite.exp: Add compile rules for vect-* files.
662 * gfortran.dg/graphite/graphite.exp: Same.
663 * gcc.dg/graphite/vect-pr43423.c: New.
665 2010-07-29 Sebastian Pop <sebastian.pop@amd.com>
667 * graphite-clast-to-gimple.c (gcc_type_for_interval): Generate in
668 priority signed types.
670 2010-07-29 Sebastian Pop <sebastian.pop@amd.com>
672 * graphite-clast-to-gimple.c (max_signed_precision_type): Remove the call
673 to lang_hooks.types.type_for_size. Call build_nonstandard_integer_type.
675 2010-07-29 Riyadh Baghdadi <baghdadi.mr@gmail.com>
677 * graphite-cloog-util.c (openscop_print_cloog_matrix): New.
678 (openscop_print_polyhedron_matrix): New.
679 * graphite-cloog-util.h (openscop_print_polyhedron_matrix): Declared.
680 * graphite-poly.c (openscop_print_pdr_polyhedron): Same.
681 (openscop_print_pdr_powerset): New.
682 (openscop_print_powerset_matrix): New.
683 (openscop_print_scattering_function_1): New.
684 (print_scattering_function): Add support for scattering names and
686 (graphite_write_transforms): Remove.
687 (apply_poly_transforms): Updated to call print_scop.
688 (print_pdr_access_layout): Updated to support OpenScop format.
690 (openscop_print_pbb_domain): New.
691 (print_pbb_body): Added a parameter to allow indicating that pbb_body is
693 (print_pbb): Updated to call the new print_pbb_body.
694 (openscop_print_scop_context): New.
695 (print_scop_header): New.
696 (print_scop): Updated to call print_scop_header.
697 * graphite-poly.h: Document OpenScop format.
699 2010-07-29 Sebastian Pop <sebastian.pop@amd.com>
701 * graphite-sese-to-poly.c (rewrite_close_phi_out_of_ssa): Add back
702 the case removed in the previous patch, when the only phi argument
703 is defined in the same loop as the phi node itself. Handle it
704 separately from the invariant case by both propagating it outside
705 the region and replacing the phi node with an assign.
707 2010-07-28 Sebastian Pop <sebastian.pop@amd.com>
709 * graphite-sese-to-poly.c (rewrite_close_phi_out_of_ssa): The only
710 constant phi nodes with one argument are is_gimple_min_invariant
711 and SSA_NAME_IS_DEFAULT_DEF.
713 * gfortran.dg/graphite/id-22.f: New.
715 2010-07-27 Andreas Simbuerger <simbuerg@fim.uni-passau.de>
717 * graphite.c (graphite_initialize): Do not initialize
718 CLooG and initialize the Parma Polyhedra Library
719 manually when using CLOOG_ORG.
720 (graphite_finalize): Do not finalize CLooG and finalize
721 the Parma Polyhedra Library manually when using CLOOG_ORG.
722 * graphite-cloog-compat.h (cloog_initialize): Hide function
723 when using CLOOG_ORG.
724 (cloog_finalize): Same.
726 2010-07-27 Andreas Simbuerger <simbuerg@fim.uni-passau.de>
728 * graphite-clast-to-gimple.c (free_scattering): Change
729 CloogDomainList/CloogDomain to CloogScatteringList/CloogScattering
731 (build_cloog_prog): Same.
732 * graphite-cloog-compat.h (cloog_domain): Removed.
733 (cloog_scattering): New.
734 (cloog_set_domain): Removed.
735 (cloog_set_scattering): New.
736 (cloog_next_domain): Removed.
737 (cloog_next_scattering): New.
738 (cloog_set_next_domain): Removed.
739 (cloog_set_next_scattering): New.
740 (CloogScatteringList): New.
741 (CloogScattering): New.
742 (cloog_scattering_free): New.
743 (new_Cloog_Scattering_from_ppl_Polyhedron): New.
744 * graphite-cloog-util.c (new_Cloog_Scattering_from_ppl_Polyhedron):
747 2010-07-27 Andreas Simbuerger <simbuerg@fim.uni-passau.de>
749 * graphite-clast-to-gimple.c (build_cloog_prog): Extend with
751 (set_cloog_options): Same.
752 (print_clast_stmt): Same.
753 (scop_to_clast): Same.
754 (print_generated_program): Same.
756 * graphite-clast-to-gimple.h: Include graphite-cloog-util.h.
757 (scop_to_clast): Extend with CloogState.
758 * graphite-cloog-util.c: Include graphite-cloog-compat.h
759 (new_Cloog_Domain_from_ppl_Polyhedron):
760 Extend with CloogState. Use cloog_domain_from_cloog_matrix (CLOOG_ORG).
761 (new_Cloog_Domain_from_ppl_Pointset_Powerset): Extend with CloogState.
762 (new_Cloog_Domain_from_ppl_Polyhedron): Same.
763 * graphite-cloog-util.h (build_cloog_prog): Same.
764 * graphite-cloog-copat.h (build_cloog_prog): New.
766 (cloog_state_malloc): New.
767 (cloog_state_free): New.
768 (cloog_loop_malloc): New.
769 (cloog_options_malloc): New.
770 (cloog_statement_alloc): New.
771 (cloog_domain_from_cloog_matrix): New.
772 (new_Cloog_Domain_from_ppl_Pointset_Powerset): New.
773 (new_Cloog_Domain_from_ppl_Polyhedron): New.
775 2010-07-27 Andreas Simbuerger <simbuerg@fim.uni-passau.de>
777 * graphite-clast-to-gimple.c (clast_name_to_gcc): Parameter
778 type of NAME now depends on used CLooG version.
779 (clast_to_gcc_expression): Replace expr_* with clast_expr_*.
780 (gcc_type_for_clast_expr): Same.
781 (print_clast_stmt): Replace pprint with clast_pprint.
782 * graphite-cloog-compat.h: Provide compatibility macros for
785 (clast_expr_term): New.
786 (clast_expr_red): New.
787 (clast_expr_bin): New.
790 2010-07-27 Andreas Simbuerger <simbuerg@fim.uni-passau.de>
792 * graphite-clast-to-gimple.c (set_cloog_options): Make CLooG options
793 compatible to newer CLooG releases (CLOOG_ORG).
794 (build_cloog_prog): Pass CloogOptions to more functions (CLOOG_ORG).
795 (scop_to_clast): Pass CloogOptions to build_cloog_prog (CLOOG_ORG).
796 * graphite-cloog-compat.h: Add compatibility macros for CLooG Legacy.
797 (build_cloog_prog) : New.
798 (cloog_program_extract_scalars): New.
799 (cloog_program_scatter): New.
801 2010-07-27 Andreas Simbuerger <simbuerg@fim.uni-passau.de>
803 * graphite-clast-to-gimple.c: Include graphite-cloog-compat.h
804 conditionally (CLOOG_ORG).
805 * graphite-cloog-compat.h: New. Include graphite-cloog-compat.h.
806 (cloog_statement_usr): New.
807 (cloog_domain): Same.
808 (cloog_set_domain): Same.
809 (cloog_next_domain): Same.
810 (cloog_set_next_domain): Same.
811 (cloog_program_nb_scattdims): Same.
812 (cloog_program_set_nb_scattdims): Same.
813 (cloog_program_names): Same.
814 (cloog_program_set_names): Same.
815 (cloog_program_set_context): Same.
816 (cloog_program_set_loop): Same.
817 (cloog_program_blocklist): Same.
818 (cloog_program_set_blocklist): Same.
819 (cloog_program_scaldims): Same.
820 (cloog_program_set_scaldims): Same.
821 (cloog_names_nb_parameters): Same.
822 (cloog_names_set_nb_parameters): Same.
823 (cloog_names_parameters): Same.
824 (cloog_names_set_parameters): Same.
825 (cloog_names_set_nb_iterators): Same.
826 (cloog_names_set_iterators): Same.
827 (cloog_names_set_nb_scattering): Same.
828 (cloog_names_set_scattering): Same.
829 (cloog_statement_set_usr): Same.
830 (cloog_loop_set_next): Same.
831 (cloog_loop_set_domain): Same.
832 (cloog_loop_set_block): Same.
833 (cloog_block_list_next): Same.
834 (cloog_block_list_set_next):
835 (cloog_block_list_set_block): Same.
837 2010-07-27 Sebastian Pop <sebastian.pop@amd.com>
839 * graphite-sese-to-poly.c (rewrite_cross_bb_scalar_deps): Returns
841 (rewrite_commutative_reductions_out_of_ssa_close_phi): Same.
842 (rewrite_commutative_reductions_out_of_ssa_loop): Same.
843 (rewrite_cross_bb_scalar_deps_out_of_ssa): Call scev_reset_htab
844 when something has been changed.
845 (rewrite_commutative_reductions_out_of_ssa): Same.
847 * gcc.dg/graphite/id-26.c: New.
849 2010-07-26 Sebastian Pop <sebastian.pop@amd.com>
851 * graphite-sese-to-poly.c (propagate_expr_outside_region): Also
852 handle the case when def is in the sese region.
853 (rewrite_close_phi_out_of_ssa): Call propagate_expr_outside_region
854 for invariant expressions.
855 (rewrite_cross_bb_phi_deps): Removed.
856 (rewrite_cross_bb_scalar_deps): Also handle GIMPLE_PHI nodes.
857 (rewrite_cross_bb_scalar_deps_out_of_ssa): Do not call
858 rewrite_cross_bb_phi_deps.
860 2010-07-26 Sebastian Pop <sebastian.pop@amd.com>
862 * graphite-sese-to-poly.c
863 (rewrite_commutative_reductions_out_of_ssa_loop): Call
864 scev_analyzable_p only on is_gimple_reg
866 * gcc.dg/graphite/id-25.c: New.
868 2010-07-22 Sebastian Pop <sebastian.pop@amd.com>
870 * graphite-sese-to-poly.c (propagate_expr_outside_region): New.
871 (rewrite_close_phi_out_of_ssa): Propagate constant values or
872 parametric expressions outside the scop region.
873 (rewrite_cross_bb_scalar_deps): Same.
874 * sese.c (rename_uses): Use NULL_TREE instead of NULL for trees.
876 * gcc.dg/graphite/run-id-5.c: New.
877 * gcc.dg/graphite/run-id-6.c: New.
878 * gfortran.dg/graphite/id-21.f: New.
880 2010-07-22 Sebastian Pop <sebastian.pop@amd.com>
882 * graphite-sese-to-poly.c (rewrite_phi_out_of_ssa): Use
883 SSA_NAME_DEF_STMT only on SSA_NAMEs.
885 * gcc.dg/graphite/id-24.c: New.
887 2010-07-22 Sebastian Pop <sebastian.pop@amd.com>
889 * tree-scalar-evolution.c (instantiate_scev_name): Do not
890 instantiate default definitions.
892 2010-07-20 Vladimir Kargov <kargov@gmail.com>
894 * graphite-scop-detection.c (is_valid_stmt_p): New.
895 (is_valid_bb_p): New.
897 2010-07-20 Vladimir Kargov <kargov@gmail.com>
898 Sebastian Pop <sebastian.pop@amd.com>
900 * cfgloop.c (is_loop_exit): Renamed loop_exits_to_bb_p.
901 (loop_exits_from_bb_p): New.
902 * cfgloop.h (is_loop_exit): Renamed loop_exits_to_bb_p.
903 (loop_exits_from_bb_p): Declared.
904 * graphite-scop-detection.c (scopdet_basic_block_info): Call
907 2010-07-20 Vladimir Kargov <kargov@gmail.com>
909 * refined-regions.c: Include tree-pass.h, cfgloop.h, gimple.h, and
911 (dot_regions_1): New.
913 * refined-regions.h (dot_regions): Declared.
914 * Makefile.in (refined-regions.o): Update dependences.
916 2010-07-20 Sebastian Pop <sebastian.pop@amd.com>
918 * graphite-sese-to-poly.c (rewrite_close_phi_out_of_ssa): Add an
919 extra parameter for the region. Call scev_analyzable_p.
920 (rewrite_reductions_out_of_ssa): Update call to
921 rewrite_close_phi_out_of_ssa.
922 (rewrite_cross_bb_phi_deps): Same.
923 (rewrite_commutative_reductions_out_of_ssa_loop): Add an extra
924 parameter for the region. Call scev_analyzable_p.
925 (rewrite_commutative_reductions_out_of_ssa): Update call to
926 rewrite_commutative_reductions_out_of_ssa_loop.
928 2010-07-20 Sebastian Pop <sebastian.pop@amd.com>
930 * gcc.dg/tree-ssa/pr20742.c: New.
932 2010-07-15 Sebastian Pop <sebastian.pop@amd.com>
934 * sese.c (rename_uses): Call unshare_expr before force_gimple_operand.
936 * gcc.dg/graphite/id-23.c: New.
938 2010-07-15 Sebastian Pop <sebastian.pop@amd.com>
940 * graphite-sese-to-poly.c (reduction_phi_p): Do not rewrite out of
941 SSA scalar phi nodes that can be scev_analyzable_p.
943 * gfortran.dg/graphite/id-20.f: Adjust testcase.
945 2010-07-15 Sebastian Pop <sebastian.pop@amd.com>
947 * graphite-sese-to-poly.c (rewrite_close_phi_out_of_ssa): Correctly
948 handle SSA_NAME_IS_DEFAULT_DEF.
950 2010-07-15 Sebastian Pop <sebastian.pop@amd.com>
952 * sese.c (rename_uses): Handl unconditionally gimple_debug statements.
954 * gcc.dg/graphite/pr42729.c: New.
956 2010-07-15 Sebastian Pop <sebastian.pop@amd.com>
958 * graphite-sese-to-poly.c (rewrite_close_phi_out_of_ssa): Special
959 case non close-phi nodes with one argument.
961 2010-07-15 Sebastian Pop <sebastian.pop@amd.com>
963 * sese.h (scev_analyzable_p): Scevs could be expressions without
964 chrecs and still be scev_analyzable_p.
966 2010-07-15 Sebastian Pop <sebastian.pop@amd.com>
968 * params.def (PARAM_SCEV_MAX_EXPR_SIZE): Bump the value to 100.
970 2010-07-15 Sebastian Pop <sebastian.pop@amd.com>
972 * cfgloop.c (alloc_loop): Remove initialization of loop->single_iv.
973 * cfgloop.h (struct loop): Remove single_iv field.
974 * graphite-sese-to-poly.c (graphite_loop_normal_form): Removed.
975 (scop_canonicalize_loops): Removed.
976 (scop_ivs_can_be_represented): Do not use loop->single_iv. Iterate
977 over all the loop phi nodes in loop->header.
978 (build_poly_scop): Remove use of scop_canonicalize_loops.
980 2010-07-15 Sebastian Pop <sebastian.pop@amd.com>
982 * graphite-sese-to-poly.c (rewrite_cross_bb_scalar_deps): Also
985 2010-07-15 Sebastian Pop <sebastian.pop@amd.com>
987 * tree-chrec.c (chrec_apply): Should only apply to the specified
988 variable. Also handle multivariate chains of recurrences that
989 satisfy evolution_function_is_affine_p. Also handle CASE_CONVERT.
991 2010-07-15 Sebastian Pop <sebastian.pop@amd.com>
993 * graphite-clast-to-gimple.c (debug_clast_name_index): Removed.
994 (debug_clast_name_indexes_1): Removed.
995 (debug_clast_name_indexes): Removed.
996 (pbb_to_depth_to_oldiv): Removed.
997 (build_iv_mapping): Replace the use of rename_map with iv_map.
998 (translate_clast_user): Remove uses of rename_map. Allocate and
1000 (translate_clast_for_loop): Remove uses of rename_map.
1001 (translate_clast_for): Same.
1002 (translate_clast_guard): Same.
1003 (translate_clast): Same.
1005 * graphite-clast-to-gimple.h (debug_clast_name_indexes): Removed.
1006 * graphite-sese-to-poly.c (scev_analyzable_p): Moved...
1007 * sese.c (set_rename): Now static.
1008 (rename_variables_in_stmt): Removed.
1010 (is_parameter): Removed.
1012 (expand_scalar_variables_call): Removed.
1013 (expand_scalar_variables_ssa_name): Removed.
1014 (expand_scalar_variables_expr): Removed.
1015 (expand_scalar_variables_stmt): Removed.
1016 (expand_scalar_variables): Removed.
1017 (rename_variables): Removed.
1018 (remove_condition): Removed.
1019 (get_true_edge_from_guard_bb): Removed.
1020 (get_false_edge_from_guard_bb): Removed.
1021 (struct igp): Removed.
1022 (default_before_guard): Removed.
1023 (convert_for_phi_arg): Removed.
1024 (add_guard_exit_phis): Removed.
1025 (insert_guard_phis): Removed.
1026 (graphite_copy_stmts_from_block): Now also uses iv_map and a
1027 region. Do not copy conditions. Do not copy induction variables.
1029 (copy_bb_and_scalar_dependences): Allocate a local rename_map for
1030 the translated statement. Use the iv_map for the induction
1032 * sese.h (copy_bb_and_scalar_dependences): Update declaration.
1033 (set_rename): Removed declaration.
1034 (scev_analyzable_p): ...here.
1035 * tree-chrec.c (chrec_apply_map): New.
1036 * tree-chrec.h (chrec_apply_map): Declared.
1038 2010-07-15 Sebastian Pop <sebastian.pop@amd.com>
1040 * graphite-clast-to-gimple.c (translate_clast_for_loop): Do not call
1041 insert_loop_close_phis.
1042 * sese.c (name_defined_in_loop_p): Removed.
1043 (expr_defined_in_loop_p): Removed.
1044 (alive_after_loop): Removed.
1045 (close_phi_not_yet_inserted_p): Removed.
1046 (struct alep): Removed.
1047 (add_loop_exit_phis): Removed.
1048 (insert_loop_close_phis): Removed.
1050 2010-07-15 Andreas Simbuerger <simbuerg@fim.uni-passau.de>
1052 * graphite-cloog-util.c (cloog_matrix_to_ppl_constraint): Fix flipped
1054 * graphite-poly.c (psct_scattering_dim_for_loop_depth): Same.
1056 2010-07-07 Sebastian Pop <sebastian.pop@amd.com>
1058 * gfortran.dg/graphite/id-20.f: New.
1060 2010-07-05 Andreas Simbuerger <simbuerg@fim.uni-passau.de>
1062 * graphite-cloog-util.h: Added cloog.h.
1063 * graphite-blocking.c: Removed cloog.h.
1064 * graphite-dependences.c: Same.
1065 * graphite-interchange.c: Same.
1066 * graphite-poly.c: Same.
1067 * graphite-ppl.c: Same.
1068 * graphite-scop-detection.c: Same.
1069 * graphite-sese-to-poly.c:
1071 Removed graphite-clast-to-gimple.h.
1072 (check_poly_representation): Removed (unused).
1073 * graphite-sese-to-poly.h
1074 (check_poly_representation): Removed (unused).
1076 2010-07-05 Andreas Simbuerger <simbuerg@fim.uni-passau.de>
1079 (OBJS-common): Added graphite-cloog-util.o.
1080 (graphite-clast-to-gimple.o): Added graphite-cloog-util.h.
1081 (graphite-cloog-util.o): New.
1082 (graphite-ppl.o): Added graphite-cloog-util.h.
1083 * graphite-clast-to-gimple.c:
1084 Added graphite-cloog-util.h to include statements.
1085 * graphite-cloog-util.c: New.
1086 (new_Cloog_Matrix_from_ppl_Polyhedron): Moved from graphite-ppl.c.
1087 (new_Cloog_Domain_from_ppl_Polyhedron): Same.
1088 (new_Cloog_Domain_from_ppl_Pointset_Powerset): Same.
1089 (new_C_Polyhedron_from_Cloog_Matrix): Same.
1090 (ppl_Constrain_System_number_of_constraints): Same.
1091 (new_Cloog_Matrix_from_ppl_Constraint_System): Same.
1092 (oppose_constraint): Same.
1093 (cloog_matrix_to_ppl_constraint): Same.
1094 (new_Constraint_System_from_Cloog_Matrix): Same.
1095 (insert_constraint_into_matrix): Same. Declared static.
1096 * graphite-cloog-util.h: New.
1097 (new_Cloog_Matrix_from_ppl_Polyhedron): Moved from graphite-ppl.h.
1098 (new_Cloog_Domain_from_ppl_Polyhedron): Same.
1099 (new_Cloog_Domain_from_ppl_Pointset_Powerset): Same.
1100 (new_C_Polyhedron_from_Cloog_Matrix): Same.
1101 (insert_constraint_into_matrix): Same.
1103 Added graphite-cloog-util.h to include statements.
1104 (new_Cloog_Matrix_from_ppl_Polyhedron): Moved to graphite-cloog-util.c.
1105 (new_Cloog_Domain_from_ppl_Polyhedron): Same.
1106 (new_Cloog_Domain_from_ppl_Pointset_Powerset): Same.
1107 (new_C_Polyhedron_from_Cloog_Matrix): Same.
1108 (insert_constraint_into_matrix): Same.
1109 (ppl_Constrain_System_number_of_constraints): Same.
1110 (new_Cloog_Matrix_from_ppl_Constraint_System): Same.
1111 (oppose_constraint): Same.
1112 (cloog_matrix_to_ppl_constraint): Same.
1113 (new_Constraint_System_from_Cloog_Matrix): Same.
1115 (new_Cloog_Matrix_from_ppl_Polyhedron): Moved to
1116 graphite-cloog-util.h.
1117 (new_Cloog_Domain_from_ppl_Polyhedron): Same.
1118 (new_Cloog_Domain_from_ppl_Pointset_Powerset): Same.
1119 (new_C_Polyhedron_from_Cloog_Matrix): Same.
1120 (insert_constraint_into_matrix): Removed.
1122 2010-07-04 Andreas Simbuerger <simbuerg@fim.uni-passau.de>
1124 * graphite-clast-to-gimple.c
1125 (precision_for_value): Resolve value_* calls to matching mpz_* calls.
1126 (precision_for_interval): Same.
1127 (gcc_type_for_interval): Same.
1128 (compute_type_for_level): Same.
1129 * graphite-interchange.c
1130 (lst_interchange_profitable_p): Same.
1132 (psct_scattering_dim_for_loop_depth): Same.
1134 (ppl_max_for_le_pointset): Same.
1135 (ppl_min_for_le_pointset): Same.
1137 2010-06-25 Vladimir Kargov <kargov@gmail.com>
1139 * refined-regions.c (bb_index_compare): New.
1140 (get_bbs_in_region): New.
1141 (print_bbs_in_region): New.
1142 (print_refined_region): Add an argument that allows to print
1143 all basic blocks contained in regions.
1144 (debug_refined_region): Update call to print_refined_region.
1145 * refined-regions.h (print_refined_region): Update declaration.
1146 (get_bbs_in_region): Declared.
1147 * graphite-scop-detection.c (build_scops_new): Print the refined
1148 region tree into the Grahite dump file.
1150 2010-06-24 Sebastian Pop <sebastian.pop@amd.com>
1152 * graphite-sese-to-poly.c (rewrite_degenerate_phi): New.
1153 (rewrite_reductions_out_of_ssa): Call it for degenerate_phi_result.
1155 2010-06-24 Sebastian Pop <sebastian.pop@amd.com>
1157 * graphite-sese-to-poly.c (rewrite_cross_bb_phi_deps): Call
1158 rewrite_close_phi_out_of_ssa.
1160 * gcc.dg/graphite/id-22.c: New.
1162 2010-06-24 Sebastian Pop <sebastian.pop@amd.com>
1164 * graphite-sese-to-poly.c (rewrite_cross_bb_phi_deps): Remove dead code.
1166 2010-06-24 Sebastian Pop <sebastian.pop@amd.com>
1168 * graphite-clast-to-gimple.c (build_iv_mapping): Rename map with
1170 * sese.c (debug_rename_map): Same.
1173 (rename_variables_in_stmt): Same.
1174 (expand_scalar_variables_call): Same.
1175 (expand_scalar_variables_ssa_name): Same.
1176 (expand_scalar_variables_expr): Same.
1177 (expand_scalar_variables_stmt): Same.
1178 (expand_scalar_variables): Same.
1179 (rename_variables): Same.
1180 (graphite_copy_stmts_from_block): Same.
1181 (copy_bb_and_scalar_dependences): Same.
1183 2010-06-24 Sebastian Pop <sebastian.pop@amd.com>
1185 * graphite-clast-to-gimple.c (copy_renames): Removed.
1186 (translate_clast_for): Do not call copy_renames.
1187 (translate_clast_guard): Same.
1189 2010-06-23 Sebastian Pop <sebastian.pop@amd.com>
1191 * graphite-sese-to-poly.c (rewrite_reductions_out_of_ssa): Moved up.
1192 (rewrite_cross_bb_phi_deps): Split out of rewrite_cross_bb_scalar_deps.
1193 (rewrite_cross_bb_scalar_deps_out_of_ssa): Run rewrite_cross_bb_phi_deps
1194 before rewrite_cross_bb_scalar_deps.
1196 2010-06-23 Sebastian Pop <sebastian.pop@amd.com>
1198 * graphite-sese-to-poly.c (rewrite_commutative_reductions_out_of_ssa):
1199 Early return in when flag_associative_math is not set.
1201 2010-06-23 Sebastian Pop <sebastian.pop@amd.com>
1203 * gcc.dg/graphite/run-id-2.c: Call abort.
1205 2010-06-23 Sebastian Pop <sebastian.pop@amd.com>
1207 * graphite-sese-to-poly.c (rewrite_phi_out_of_ssa): Always insert out
1208 of SSA copies on edges except for loop->latch.
1210 2010-06-23 Sebastian Pop <sebastian.pop@amd.com>
1212 * graphite-sese-to-poly.c (rewrite_cross_bb_scalar_deps_out_of_ssa):
1213 Split out of rewrite_reductions_out_of_ssa.
1214 * graphite-sese-to-poly.h (rewrite_cross_bb_scalar_deps_out_of_ssa):
1216 * graphite.c (graphite_transform_loops): Call it.
1218 2010-06-23 Sebastian Pop <sebastian.pop@amd.com>
1220 * graphite.c (graphite_transform_loops): Add two more dbg_cnt calls.
1222 2010-06-15 Sebastian Pop <sebastian.pop@amd.com>
1224 * passes.c (init_optimization_passes): Add pass_graphite.
1225 Schedule a pass_copy_prop before pass_graphite_transforms.
1226 * timevar.def (TV_GRAPHITE): Declared.
1227 * tree-pass.h (pass_graphite): Declared.
1228 * tree-ssa-loop.c (pass_graphite): New.
1230 * gcc.dg/graphite/id-20.c: New.
1232 2010-06-12 Sebastian Pop <sebastian.pop@amd.com>
1234 * graphite-clast-to-gimple.c (gloog): Do not pass scops in parameter.
1235 Remove calls to rename_nb_iterations and rename_sese_parameters.
1236 * graphite-clast-to-gimple.h (gloog): Update declaration.
1237 * graphite.c (graphite_transform_loops): Update call to gloog.
1238 * sese.c (rename_variables_in_expr): Removed.
1239 (rename_nb_iterations): Removed.
1240 (rename_sese_parameters): Removed.
1241 * sese.h (rename_nb_iterations): Removed.
1242 (rename_sese_parameters): Removed.
1244 2010-06-12 Sebastian Pop <sebastian.pop@amd.com>
1246 * graphite-clast-to-gimple.c (gloog): Remove call to
1247 sese_adjust_liveout_phis.
1248 * graphite-sese-to-poly.c (scev_analyzable_p): When scev returns an
1249 SSA_NAME, allow it to be handled by rewrite_cross_bb_scalar_deps.
1250 (rewrite_cross_bb_scalar_deps): Handle GIMPLE_PHI nodes: call
1251 rewrite_phi_out_of_ssa.
1252 * sese.c (get_vdef_before_sese): Removed.
1253 (sese_adjust_vphi): Removed.
1254 (sese_adjust_liveout_phis): Removed.
1255 * sese.h (sese_adjust_liveout_phis): Removed.
1257 2010-06-12 Sebastian Pop <sebastian.pop@amd.com>
1259 * graphite-sese-to-poly.c (insert_out_of_ssa_copy): Pass an extra
1260 argument for the place after which to insert the out of SSA copy.
1261 (rewrite_close_phi_out_of_ssa): Update calls to insert_out_of_ssa_copy.
1262 (rewrite_phi_out_of_ssa): Same.
1263 (rewrite_cross_bb_scalar_deps): Same.
1264 (insert_copyout): Removed.
1265 (insert_copyin): Removed.
1266 (translate_scalar_reduction_to_array): Call insert_out_of_ssa_copy and
1267 insert_out_of_ssa_copy_on_edge instead of insert_copyout and
1270 2010-06-12 Sebastian Pop <sebastian.pop@amd.com>
1272 * graphite-sese-to-poly.c (build_scop_bbs): Not static anymore.
1273 (rewrite_reductions_out_of_ssa): Same.
1274 (rewrite_commutative_reductions_out_of_ssa): Same.
1275 (build_poly_scop): Do not call these functions.
1276 * graphite-sese-to-poly.h (build_poly_scop): Declared.
1277 (rewrite_reductions_out_of_ssa): Declared.
1278 (rewrite_commutative_reductions_out_of_ssa): Declared.
1279 * graphite.c (graphite_transform_loops): Call on every scop
1280 rewrite_commutative_reductions_out_of_ssa before calling
1281 rewrite_reductions_out_of_ssa and build_scop_bbs.
1283 2010-06-12 Sebastian Pop <sebastian.pop@amd.com>
1285 * graphite-dependences.c (dot_deps): Make system call to dotty run
1287 (dot_deps_stmt): Same.
1288 * graphite-poly.c (dot_lst): Same.
1290 2010-06-11 Sebastian Pop <sebastian.pop@amd.com>
1292 * graphite-clast-to-gimple.c (gcc_type_for_interval): Do not pass
1293 old_type in parameter.
1294 (gcc_type_for_value): Update call to gcc_type_for_interval.
1295 (compute_type_for_level_1): Renamed compute_type_for_level.
1296 Update call to gcc_type_for_interval.
1298 2010-06-09 Sebastian Pop <sebastian.pop@amd.com>
1300 * tree-scalar-evolution.c (instantiate_scev_name): Do not fail
1301 the scev analysis when the variable is not used outside the loop
1302 in a close phi node: call compute_overall_effect_of_inner_loop.
1304 2010-06-09 Sebastian Pop <sebastian.pop@amd.com>
1306 * graphite-sese-to-poly.c (single_pred_cond): Renamed
1307 single_pred_cond_non_loop_exit. Return NULL for loop exit edges.
1308 (build_sese_conditions_before): Renamed call to single_pred_cond.
1309 (build_sese_conditions_after): Same.
1311 2010-06-09 Sebastian Pop <sebastian.pop@amd.com>
1313 * graphite-poly.h: Fix comments and indentation.
1314 * graphite-sese-to-poly.c: Same.
1315 (build_sese_conditions_before): Compute stmt and gbb only when needed.
1316 * tree-chrec.c: Fix comments and indentation.
1317 (tree-ssa-loop-niter.c): Same.
1319 2010-06-08 Tobias Grosser <grosser@fim.uni-passau.de>
1321 * refined-regions.c (create_region): Only initialize the region.
1322 (find_regions_with_entry): Initialize parent relation and bbmap
1324 (build_regions_tree): Set outermost_region to region instead of
1326 (calculate_region_tree): Remove unneeded parameters.
1328 2010-06-02 Tobias Grosser <grosser@fim.uni-passau.de>
1330 * graphite-scop-detection.c (is_scop_p): New.
1331 (build_scops_new): New. A skeleton for the new scop detection.
1332 (build_scops_old): Renamed from build_scops.
1333 (build_scops): New version. Call the new and the old scop
1336 2010-05-27 Tobias Grosser <grosser@fim.uni-passau.de>
1337 Antoniu Pop <antoniu.pop@gmail.com>
1339 * Makefile.in (OBJS-common): Add refined-regions.o.
1340 (refined-regions.o): New.
1341 (graphite-scop-detection.o): Use refined-regions.h.
1342 * graphite-scop-detection.c: Include refined-regions.h
1343 (build_scops): Also build the refined region tree.
1344 * refined-regions.c: New. Adds an algorithm to detect refined
1346 (print_refined_region): New.
1347 (debug_refined_region): New.
1348 (refined_region_contains_bb_p): New.
1349 (refined_region_contains_region_p): New.
1350 (is_common_df): New.
1351 (struct find_regions_global_data): New.
1353 (typedef struct bb_bb_def): New.
1354 (new_bb_bb_def): New.
1355 (bb_bb_map_hash): New.
1356 (eq_bb_bb_map): New.
1359 (new_bb_reg_def): New.
1360 (bb_reg_map_hash): New.
1361 (eq_bb_reg_map): New.
1362 (find_new_region): New.
1363 (insert_new_reg): New.
1364 (insert_new_bb): New.
1365 (insert_shortcut): New.
1366 (get_next_postdom): New.
1367 (create_region): New.
1368 (find_regions_with_entry): New.
1369 (find_regions_adc): New.
1370 (find_regions): New.
1371 (get_topmost_parent): New.
1372 (build_regions_tree): New.
1373 (calculate_region_tree): New.
1374 (free_region_tree): New.
1375 * refined-regions.h: New.
1376 (struct refined_region): New.
1377 (calculate_region_tree): New.
1378 (free_region_tree): New.
1379 (refined_region_contains_bb_p): New.
1380 (refined_region_contains_region_p): New.
1381 (print_refined_region): New.
1382 (debug_refined_region): New.
1384 2010-05-26 Sebastian Pop <sebastian.pop@amd.com>
1386 * graphite-clast-to-gimple.c (graphite_create_new_loop_guard): Use
1389 2010-05-07 Sebastian Pop <sebastian.pop@amd.com>
1391 * graphite-clast-to-gimple.c (graphite_create_new_loop_guard): Fix
1392 type of integer_one_node for fold_build of POINTER_PLUS_EXPR.
1394 2010-05-07 Sebastian Pop <sebastian.pop@amd.com>
1396 * graphite-sese-to-poly.c (loop_entry_phi_arg): Renamed
1397 phi_arg_in_outermost_loop.
1398 (remove_simple_copy_phi): Call phi_arg_in_outermost_loop.
1399 (remove_invariant_phi): Same.
1401 2010-04-12 Andreas Simbuerger <simbuerg@fim.uni-passau.de>
1403 * graphite-blocking.c
1404 (pbb_strip_mine_profitable_p): Replace Value with mpz_t.
1405 * graphite-clast-to-gimple.c
1406 (clast_to_gcc_expression): Same.
1407 (precision_for_value): Same.
1408 (precision_for_interval): Same.
1409 (gcc_type_for_interval): Same.
1410 (graphite_create_new_guard): Same.
1411 (compute_bounds_for_level): Same.
1412 (graphite_create_new_loop_guard): Same.
1413 * graphite-interchange.c
1414 (build_linearized_memory_access): Same.
1415 (pdr_stride_in_loop): Same.
1416 (memory_strides_in_loop_1): Same.
1417 (memory_strides_in_loop): Same.
1418 (extend_scattering): Same.
1419 (psct_scattering_dim_for_loop_depth): Same.
1420 (pbb_number_of_iterations): Same.
1422 (debug_iteration_domains): Same.
1424 (new_Cloog_Domain_from_ppl_Pointset_Powerset): Same.
1425 (ppl_set_inhomogeneous_gmp): Same.
1426 (ppl_strip_loop): Same.
1427 (ppl_lexico_compare_linear_expressions): Same.
1428 (ppl_read_polyhedron_matrix): Same.
1429 (ppl_max_for_le_pointset): Same.
1431 (ppl_read_polyhedron_matrix): Same.
1432 (tree_int_to_gmp): Same.
1433 (gmp_cst_to_tree): Same.
1434 (ppl_set_inhomogeneous): Same.
1435 (ppl_set_inhomogeneous_tree): Same.
1436 (ppl_set_coef): Same.
1437 (ppl_set_coef_tree): Same.
1438 * graphite-sese-to-poly.c
1439 (build_pbb_scattering_polyhedrons): Same.
1440 (build_scop_scattering): Same.
1441 (scan_tree_for_params_right_scev): Same.
1442 (scan_tree_for_params): Same.
1443 (find_params_in_bb): Same.
1444 (find_scop_parameters): Same.
1445 (add_upper_bounds_from_estimated_nit): Same.
1446 (build_loop_iteration_domains): Same.
1447 (add_condition_to_domain): Same.
1448 (pdr_add_memory_accesses): Same.
1450 2010-04-11 Andreas Simbuerger <simbuerg@fim.uni-passau.de>
1452 * graphite-blocking.c (pbb_strip_mine_profitable_p): Resolve
1453 CLooG's value_* macros to their respective mpz_* counterparts.
1454 * graphite-clast-to-gimple.c (clast_to_gcc_expression): Same.
1455 (graphite_create_new_loop_guard): Same.
1456 * graphite-interchange.c (build_linearized_memory_access): Same.
1457 (pdr_stride_in_loop): Same.
1458 (memory_strides_in_loop_1): Same.
1459 (1st_interchange_profitable_p): Same.
1460 * graphite-poly.c (extend_scattering): Same.
1461 (psct_scattering_dim_for_loop_depth): Same.
1462 (pbb_number_of_iterations): Same.
1463 (pbb_number_of_iterations_at_time): Same.
1464 * graphite-poly.h (new_1st_loop): Same.
1465 * graphite-ppl.c (cloog_matrix_to_ppl_constraint): Same.
1466 (oppose_constraint): Same.
1467 (insert_constraint_into_matrix): Same.
1468 (ppl_set_inhomogeneous_gmp): Same.
1469 (ppl_set_coef_gmp): Same.
1470 (ppl_strip_loop): Same.
1471 (ppl_lexico_compare_linear_expressions): Same.
1472 (ppl_max_for_le_pointset): Same.
1473 (ppl_min_for_le_pointset): Same.
1474 (ppl_build_realtion): Same.
1475 * graphite-ppl.h (gmp_cst_to_tree): Same.
1476 (ppl_set_inhomogeneous): Same.
1477 (ppl_set_inhomogeneous_tree): Same.
1478 (ppl_set_coef): Same.
1479 (ppl_set_coef_tree): Same.
1480 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons): Same.
1481 (build_scop_scattering): Same.
1482 (add_value_to_dim): Same.
1483 (scan_tree_for_params_right_scev): Same.
1484 (scan_tree_for_params_int): Same.
1485 (scan_tree_for_params): Same.
1486 (find_params_in_bb): Same.
1487 (find_scop_parameters): Same.
1488 (add_upper_bounds_from_estimated_nit): Same.
1489 (build_loop_iteration_domains): Same.
1490 (create_linear_expr_from_tree): Same.
1491 (add_condition_to_domain): Same.
1492 (pdr_add_memory_accesses): Same.
1494 2010-04-05 Sebastian Pop <sebastian.pop@amd.com>
1497 * graphite-clast-to-gimple.c (max_signed_precision_type): Use
1498 lang_hooks.types.type_for_size instead of build_nonstandard_integer_type.
1499 When converting an unsigned type to signed, double its precision.
1500 (gcc_type_for_interval): Use lang_hooks.types.type_for_size.
1501 (gcc_type_for_iv_of_clast_loop): Call max_signed_precision_type.
1502 (graphite_create_new_loop_guard): When ub + 1 wraps around, use lb <= ub.
1504 2010-04-05 Sebastian Pop <sebastian.pop@amd.com>
1507 * graphite-clast-to-gimple.c (max_signed_precision_type): Use
1508 build_nonstandard_integer_type.
1509 (gcc_type_for_interval): Same.
1511 2010-04-05 Sebastian Pop <sebastian.pop@amd.com>
1514 * graphite-clast-to-gimple.c (graphite_create_new_loop_guard): Use
1515 POINTER_PLUS_EXPR for pointer types.
1517 * gcc.dg/graphite/id-19.c: New.
1519 2010-04-04 Sebastian Pop <sebastian.pop@amd.com>
1522 * Makefile.in (graphite-clast-to-gimple.o): Depends on langhooks.h.
1523 * graphite-clast-to-gimple.c: Include langhooks.h.
1524 (max_signed_precision_type): New.
1525 (max_precision_type): Takes two types as arguments.
1526 (precision_for_value): New.
1527 (precision_for_interval): New.
1528 (gcc_type_for_interval): New.
1529 (gcc_type_for_value): New.
1530 (gcc_type_for_clast_term): New.
1531 (gcc_type_for_clast_red): New.
1532 (gcc_type_for_clast_bin): New.
1533 (gcc_type_for_clast_expr): Split up into several functions.
1534 (gcc_type_for_clast_eq): Rewritten.
1535 (compute_bounds_for_level): New.
1536 (compute_type_for_level_1): New.
1537 (compute_type_for_level): New.
1538 (gcc_type_for_cloog_iv): Removed.
1539 (gcc_type_for_iv_of_clast_loop): Rewritten.
1540 (graphite_create_new_loop): Compute the lower and upper bound types
1541 with gcc_type_for_clast_expr.
1542 (graphite_create_new_loop_guard): Same.
1543 (find_cloog_iv_in_expr): Removed.
1544 (compute_cloog_iv_types_1): Removed.
1545 (compute_cloog_iv_types): Removed.
1546 (gloog): Do not call compute_cloog_iv_types.
1547 * graphite-sese-to-poly.c (new_gimple_bb): Do not initialize
1549 (free_data_refs_aux): Do not free GBB_CLOOG_IV_TYPES.
1550 * sese.h (struct gimple_bb): Removed field cloog_iv_types.
1551 (GBB_CLOOG_IV_TYPES): Removed.
1553 * gcc.dg/graphite/run-id-pr42644.c: Call abort.
1555 2010-04-02 Sebastian Pop <sebastian.pop@amd.com>
1557 Reverted this commit: as at this point the loop closed SSA form
1558 is under a canonical form respecting the single argument condition.
1559 * graphite-sese-to-poly.c (scalar_close_phi_node_p): Loop
1560 close phi nodes may have more than one argument.
1562 2010-04-01 Sebastian Pop <sebastian.pop@amd.com>
1564 * graphite-sese-to-poly.c (rewrite_close_phi_out_of_ssa): Assert that
1565 gimple_phi_num_args of the loop close SSA phi node is equal to 1.
1566 (detect_commutative_reduction): Same.
1568 2010-03-31 Sebastian Pop <sebastian.pop@amd.com>
1570 * graphite-sese-to-poly.c (scalar_close_phi_node_p): Loop
1571 close phi nodes may have more than one argument.
1573 2010-03-30 Richard Guenther <rguenther@suse.de>
1574 Zdenek Dvorak <ook@ucw.cz>
1575 Sebastian Pop <sebastian.pop@amd.com>
1578 * tree-ssa-copy.c (init_copy_prop): Handle loop close phi nodes
1579 with multiple arguments.
1580 (execute_copy_prop): Remove call to rewrite_into_loop_closed_ssa.
1582 2010-03-23 Sebastian Pop <sebastian.pop@amd.com>
1584 * graphite-dependences.c (print_pddr): Call print_pdr with an
1586 * graphite-poly.c (debug_pdr): Add an extra argument for the
1589 (print_pbb_domain): Same.
1591 (print_scop_context): Same.
1593 (print_cloog): Same.
1594 (debug_pbb_domain): Same.
1598 (debug_scop_context): Same.
1600 (debug_cloog): Same.
1601 (print_scop_params): Same.
1602 (debug_scop_params): Same.
1603 (print_iteration_domain): Same.
1604 (print_iteration_domains): Same.
1605 (debug_iteration_domain): Same.
1606 (debug_iteration_domains): Same.
1607 (print_scattering_function): Same.
1608 (print_scattering_functions): Same.
1609 (debug_scattering_function): Same.
1610 (debug_scattering_functions): Same.
1611 * graphite-poly.h (debug_pdr): Update declaration.
1613 (print_pbb_domain): Same.
1615 (print_scop_context): Same.
1617 (print_cloog): Same.
1618 (debug_pbb_domain): Same.
1622 (debug_scop_context): Same.
1624 (debug_cloog): Same.
1625 (print_scop_params): Same.
1626 (debug_scop_params): Same.
1627 (print_iteration_domain): Same.
1628 (print_iteration_domains): Same.
1629 (debug_iteration_domain): Same.
1630 (debug_iteration_domains): Same.
1631 (print_scattering_function): Same.
1632 (print_scattering_functions): Same.
1633 (debug_scattering_function): Same.
1634 (debug_scattering_functions): Same.
1636 2010-03-23 Sebastian Pop <sebastian.pop@amd.com>
1638 * graphite-poly.c (print_scattering_function_1): New.
1639 (print_scattering_function): Call it.
1640 (print_scop_params): Remove spaces at the end of lines.
1643 * graphite-poly.h (print_cloog): Declared.
1644 (debug_cloog): Declared.
1646 2010-03-23 Sebastian Pop <sebastian.pop@amd.com>
1648 * tree-ssa-copy.c: Revert this previous change:
1649 (init_copy_prop): Loop closed phi nodes cancontain more than one
1651 (execute_copy_prop): Revert the previous change: do not call
1652 rewrite_into_loop_closed_ssa.
1654 2010-03-21 Sebastian Pop <sebastian.pop@amd.com>
1655 Richard Guenther <rguenther@suse.de>
1658 * tree-ssa-copy.c (init_copy_prop): Loop closed phi nodes can
1659 contain more than one argument.
1660 (execute_copy_prop): Revert the previous change: do not call
1661 rewrite_into_loop_closed_ssa.
1663 * gcc.dg/graphite/id-pr43464.c: Remove compile warning.
1664 * gcc.dg/graphite/id-pr43464-1.c: New.
1666 2010-03-21 Sebastian Pop <sebastian.pop@amd.com>
1669 * tree-ssa-copy.c (execute_copy_prop): Call rewrite_into_loop_closed_ssa
1670 and verify_loop_closed_ssa when copy prop is executed in the LNO.
1672 * gcc.dg/graphite/id-pr43464.c: New.
1674 2010-03-16 Sebastian Pop <sebastian.pop@amd.com>
1676 * graphite-sese-to-poly.c (graphite_loop_normal_form): Add the IV bump
1678 * tree-flow.h (canonicalize_loop_ivs): Updated declaration.
1679 * tree-parloops.c (gen_parallel_loop): Add the IV bump in loop->latch.
1680 * tree-ssa-loop-manip.c (canonicalize_loop_ivs): Add a new parameter
1681 to switch between adding the IV bump in loop->latch or in loop->header.
1683 2010-03-16 Sebastian Pop <sebastian.pop@amd.com>
1685 * passes.c (init_optimization_passes): Add pass_copy_prop
1688 2010-03-16 Sebastian Pop <sebastian.pop@amd.com>
1690 * graphite-poly.c (print_scattering_function): Pretty print following
1693 (print_pbb_domain): Same.
1694 (dump_gbb_cases): Same.
1695 (dump_gbb_conditions): Same.
1698 (print_scop_params): Same.
1699 (print_scop_context): Same.
1701 (print_pbb_body): New.
1702 (lst_indent_to): New.
1703 (print_lst): Start new lines with a #.
1704 * graphite-poly.h (pbb_bb): New.
1705 (pbb_index): Use pbb_bb.
1706 * graphite-ppl.c (ppl_print_powerset_matrix): Print the number of
1708 * tree-data-ref.c (dump_data_reference): Start new lines with a #.
1710 2010-03-13 Sebastian Pop <sebastian.pop@amd.com>
1713 * gcc.dg/graphite/id-pr43351.c
1715 2010-03-13 Sebastian Pop <sebastian.pop@amd.com>
1718 * graphite-sese-to-poly.c (rewrite_close_phi_out_of_ssa): Do not
1719 call insert_out_of_ssa_copy for default definitions.
1720 * gfortran.dg/graphite/id-pr43354.f: New.
1722 2010-03-13 Sebastian Pop <sebastian.pop@amd.com>
1725 * gfortran.dg/graphite/pr43349.f: New.
1727 2010-03-11 Sebastian Pop <sebastian.pop@amd.com>
1729 * graphite-clast-to-gimple.c (my_long_long): Defined.
1730 (gcc_type_for_cloog_iv): Use it instead of long_long_integer_type_node.
1731 * graphite-sese-to-poly.c (my_long_long): Defined.
1732 (scop_ivs_can_be_represented): Use it.
1734 2010-03-10 Sebastian Pop <sebastian.pop@amd.com>
1736 * doc/invoke.texi: Fix documentation of graphite-max-nb-scop-params,
1737 graphite-max-bbs-per-function, and loop-block-tile-size.
1738 * params.def (PARAM_GRAPHITE_MAX_NB_SCOP_PARAMS): Replace "maximal"
1740 (PARAM_GRAPHITE_MAX_BBS_PER_FUNCTION): Same.
1742 2010-03-10 Sebastian Pop <sebastian.pop@amd.com>
1744 * graphite-clast-to-gimple.c (gcc_type_for_iv_of_clast_loop): Remove
1745 forward declaration.
1746 * graphite-sese-to-poly.c (reduction_phi_p): Remove FIXME comment.
1747 (add_upper_bounds_from_estimated_nit): New.
1748 (build_loop_iteration_domains): Use it.
1750 2010-03-09 Sebastian Pop <sebastian.pop@amd.com>
1752 * doc/invoke.texi (PARAM_LOOP_BLOCK_TILE_SIZE): Document.
1754 2010-03-09 Sebastian Pop <sebastian.pop@amd.com>
1757 * tree-chrec.c (evolution_function_right_is_integer_cst): CHREC_RIGHT
1758 should be an INTEGER_CST. Also handle CASE_CONVERT.
1759 * gcc.dg/graphite/pr43306.c: New.
1761 2010-03-09 Sebastian Pop <sebastian.pop@amd.com>
1763 * graphite.c (graphite_initialize): To bound the number of bbs per
1764 function, use PARAM_GRAPHITE_MAX_BBS_PER_FUNCTION.
1765 * params.def (PARAM_GRAPHITE_MAX_BBS_PER_FUNCTION): Declared.
1766 * doc/invoke.texi: Document it.
1768 2010-03-09 Sebastian Pop <sebastian.pop@amd.com>
1770 * graphite-sese-to-poly.c (build_poly_scop): Do not return bool.
1771 * graphite-sese-to-poly.h (build_poly_scop): Same.
1773 2010-03-09 Sebastian Pop <sebastian.pop@amd.com>
1775 * graphite-sese-to-poly.c (build_poly_scop): Limit scops following
1776 the number of parameters in the scop. Use as an upper bound
1777 PARAM_GRAPHITE_MAX_NB_SCOP_PARAMS.
1778 * params.def (PARAM_GRAPHITE_MAX_NB_SCOP_PARAMS): Declared.
1779 * doc/invoke.texi: Document it.
1781 2010-03-05 Sebastian Pop <sebastian.pop@amd.com>
1783 * graphite-sese-to-poly.c (add_param_constraints): Use
1784 lower_bound_in_type and upper_bound_in_type.
1786 2010-03-05 Sebastian Pop <sebastian.pop@amd.com>
1788 * graphite-sese-to-poly.c (add_param_constraints): Use sizetype
1789 instead of unsigned_type_node.
1791 2010-03-05 Sebastian Pop <sebastian.pop@amd.com>
1792 Reza Yazdani <reza.yazdani@amd.com>
1795 * graphite-sese-to-poly.c (add_param_constraints): Insert bounds
1796 on pointer type parameters.
1798 * gcc.dg/graphite/run-id-4.c: New.
1800 2010-03-05 Sebastian Pop <sebastian.pop@amd.com>
1803 * gcc.dg/graphite/run-id-3.c: New.
1805 2010-03-05 Tobias Grosser <grosser@fim.uni-passau.de>
1806 Ramakrishna Upadrasta <Ramakrishna.Upadrasta@inria.fr>
1808 * graphite-clast-to-gimple.c (clast_to_gcc_expression): Also
1809 handle conversions from pointer to integers.
1810 (gcc_type_for_cloog_iv): Choose the smalles signed integer as an
1811 induction variable, to be able to work with code generated by CLooG.
1812 * graphite-sese-to-poly.c (scop_ivs_can_be_represented): New.
1813 (build_poly_scop): Bail out if we cannot codegen a loop.
1815 2010-03-04 Tobias Grosser <grosser@fim.uni-passau.de>
1817 * graphite-clast-to-gimple.c (translate_clast): Do not short-cut
1818 code generation with gloog_error.
1820 2010-03-04 Sebastian Pop <sebastian.pop@amd.com>
1822 * sese.c (expand_scalar_variables_ssa_name): Add new argument for type.
1823 Call fold_convert on all the returned values.
1824 (expand_scalar_variables_expr): Pass to expand_scalar_variables_ssa_name
1825 the type of the resulting expression.
1827 2010-03-04 Sebastian Pop <sebastian.pop@amd.com>
1829 * graphite-ppl.c (ppl_min_for_le_polyhedron): Renamed
1830 ppl_min_for_le_pointset. Use ppl_Pointset_Powerset_C_Polyhedron_minimize.
1831 * graphite-ppl.h (ppl_min_for_le_polyhedron): Update declaration.
1833 2010-03-04 Sebastian Pop <sebastian.pop@amd.com>
1835 * graphite-dependences.c (map_into_dep_poly): Removed.
1836 (dependence_polyhedron_1): Use combine_context_id_scat.
1838 2010-03-04 Sebastian Pop <sebastian.pop@amd.com>
1840 * graphite-poly.h (struct poly_scattering): Add layout documentation.
1841 (struct poly_bb): Same.
1842 (combine_context_id_scat): New.
1844 2010-03-02 Sebastian Pop <sebastian.pop@amd.com>
1847 * sese.c (name_defined_in_loop_p): Return false for default
1850 * gcc.dg/graphite/pr42326.c: New.
1852 2010-02-23 Sebastian Pop <sebastian.pop@amd.com>
1854 * graphite-clast-to-gimple.c (find_cloog_iv_in_expr): Simplify
1855 and clean up the logic.
1857 2010-02-23 Sebastian Pop <sebastian.pop@amd.com>
1859 * graphite-sese-to-poly.c (add_param_constraints): Enabled: remove
1862 2010-02-22 Sebastian Pop <sebastian.pop@amd.com>
1865 * graphite-scop-detection.c (create_single_exit_edge): Move
1866 the call to find_single_exit_edge to....
1867 (create_sese_edges): ...here. Don't handle multiple edges
1868 exiting the function.
1869 (build_graphite_scops): Don't handle multiple edges
1870 exiting the function.
1872 * gcc.dg/graphite/pr43083.c: New.
1874 2010-02-22 Sebastian Pop <sebastian.pop@amd.com>
1877 * sese.c (get_rename): Assert that old_name is an SSA_NAME.
1878 (rename_variables_in_stmt): Continue when the use is not an SSA_NAME.
1880 * gfortran.dg/graphite/pr43097.f: New.
1882 2010-02-22 Sebastian Pop <sebastian.pop@amd.com>
1883 Manuel López-Ibáñez <manu@gcc.gnu.org>
1886 * g++.dg/graphite/pr41305.C: Add -Wno-conversion-null.
1888 2010-02-22 Sebastian Pop <sebastian.pop@amd.com>
1891 * sese.c (expand_scalar_variables_expr): Handle COMPONENT_REF.
1893 * g++.dg/graphite/pr43026.C: New.
1895 2010-02-13 Tobias Grosser <grosser@fim.uni-passau.de>
1897 * Merge from mainline (154736:156693).
1899 2010-02-11 Sebastian Pop <sebastian.pop@amd.com>
1902 * gcc.dg/graphite/pr43012.c: New.
1904 2010-02-10 Sebastian Pop <sebastian.pop@amd.com>
1906 * graphite.c (graphite_transform_loops): Re-enable dbg_cnt.
1907 2010-02-10 Sebastian Pop <sebastian.pop@amd.com>
1909 * g++.dg/graphite/pr42930.C: New.
1911 2010-02-10 Sebastian Pop <sebastian.pop@amd.com>
1914 * graphite-scop-detection.c (graphite_can_represent_scev): Call
1915 graphite_can_represent_init for MULT_EXPR.
1917 2010-02-10 Sebastian Pop <sebastian.pop@amd.com>
1921 * graphite-sese-to-poly.c (remove_phi): New.
1922 (translate_scalar_reduction_to_array): Call remove_phi.
1924 * gcc.dg/graphite/pr42530.c: New.
1925 * gcc.dg/graphite/pr42914.c: New.
1927 2010-02-10 Sebastian Pop <sebastian.pop@amd.com>
1930 * graphite-clast-to-gimple.c (gloog): Call rename_sese_parameters.
1931 * graphite-clast-to-gimple.h (gloog): Update declaration.
1932 * graphite-poly.c (new_scop): Clear POLY_SCOP_P.
1933 * graphite-poly.h (struct poly_bb): Add missing comments.
1934 (struct scop): Add poly_scop_p field.
1936 * graphite-sese-to-poly.c (build_poly_scop): Set POLY_SCOP_P.
1937 * graphite.c (graphite_transform_loops): Build the polyhedral
1938 representation for each scop before code generation.
1939 * sese.c (rename_variables_in_operand): Removed.
1940 (rename_variables_in_expr): Return the renamed expression.
1941 (rename_sese_parameters): New.
1942 * sese.h (rename_sese_parameters): Declared.
1944 * gcc.dg/graphite/pr42771.c: New.
1946 2010-02-07 Sebastian Pop <sebastian.pop@amd.com>
1948 * gcc.dg/graphite/block-0.c: Call abort for runtime test. Always
1950 * gcc.dg/graphite/block-1.c: Same.
1951 * gcc.dg/graphite/block-3.c: Same.
1952 * gcc.dg/graphite/block-4.c: Same.
1953 * gcc.dg/graphite/block-5.c: Same.
1954 * gcc.dg/graphite/block-6.c: Same.
1955 * gcc.dg/graphite/block-7.c: Same.
1956 * gcc.dg/graphite/interchange-0.c: Same.
1957 * gcc.dg/graphite/interchange-1.c: Same.
1958 * gcc.dg/graphite/interchange-10.c: Same.
1959 * gcc.dg/graphite/interchange-11.c: Same.
1960 * gcc.dg/graphite/interchange-12.c: Same.
1961 * gcc.dg/graphite/interchange-2.c: Same.
1962 * gcc.dg/graphite/interchange-3.c: Same.
1963 * gcc.dg/graphite/interchange-4.c: Same.
1964 * gcc.dg/graphite/interchange-5.c: Same.
1965 * gcc.dg/graphite/interchange-6.c: Same.
1966 * gcc.dg/graphite/interchange-7.c: Same.
1967 * gcc.dg/graphite/interchange-8.c: Same.
1968 * gcc.dg/graphite/interchange-9.c: Same.
1969 * gcc.dg/graphite/interchange-mvt.c: Same.
1971 2010-02-07 Sebastian Pop <sebastian.pop@amd.com>
1973 * gfortran.dg/graphite/id-19.f: New.
1974 * gfortran.dg/graphite/pr14741.f90: New.
1975 * gfortran.dg/graphite/pr41924.f90: New.
1976 * gfortran.dg/graphite/run-id-2.f90: New.
1978 2010-02-07 Sebastian Pop <sebastian.pop@amd.com>
1981 * graphite-dependences.c (dependence_polyhedron): Set PDDR_KIND
1982 to unknown_dependence.
1983 (graphite_legal_transform_dr): Handle the unknown_dependence.
1984 (graphite_carried_dependence_level_k): Same.
1986 2010-02-07 Sebastian Pop <sebastian.pop@amd.com>
1988 * ChangeLog.graphite: Remove testsuite/ or gcc/testsuite/.
1990 2010-02-05 Sebastian Pop <sebastian.pop@amd.com>
1991 Konrad Trifunovic <konrad.trifunovic@inria.fr>
1994 * graphite-dependences.c (build_lexicographical_constraint): Return
1995 a union of dependence polyhedra.
1996 (dependence_polyhedron_1): Adapt for build_lexicographical_constraint.
1998 * gcc.dg/graphite/block-0.c: Enable runtime check. XFAILed.
1999 * gcc.dg/graphite/block-4.c: Same.
2000 * gcc.dg/graphite/block-7.c: Same.
2001 * gcc.dg/graphite/interchange-12.c: Same.
2002 * gcc.dg/graphite/interchange-mvt.c: Same.
2003 * gfortran.dg/graphite/interchange-1.f: XFAILed.
2004 * gfortran.dg/graphite/interchange-3.f90: XFAILed.
2005 * gfortran.dg/graphite/run-id-1.f: New testcase for PR42637.
2007 2010-02-03 Sebastian Pop <sebastian.pop@amd.com>
2009 * gcc.dg/graphite/interchange-12.c: Return 0 to avoid
2010 the execution check to FAIL. This testcase is miscompiled by Graphite
2011 and the check should be re-enabled.
2012 * gcc.dg/graphite/interchange-mvt.c: Same.
2013 * gcc.dg/graphite/block-0.c: Same.
2014 * gcc.dg/graphite/block-4.c: Same.
2015 * gcc.dg/graphite/block-7.c: Same.
2017 2010-02-03 Sebastian Pop <sebastian.pop@amd.com>
2019 * gcc.dg/graphite/interchange-mvt.c: Un-XFAILed.
2020 * gcc.dg/graphite/scop-0.c: Fix spaces.
2021 * gfortran.dg/graphite/block-1.f90: Rewrite expected output.
2022 * gfortran.dg/graphite/block-2.f: Same.
2023 * gfortran.dg/graphite/block-3.f90: Same.
2024 * gfortran.dg/graphite/block-4.f90: Same.
2025 * gfortran.dg/graphite/interchange-1.f: Un-XFAILed.
2026 * gfortran.dg/graphite/interchange-3.f90: Un-XFAILed.
2028 2010-02-03 Sebastian Pop <sebastian.pop@amd.com>
2030 * graphite-dependences.c (new_poly_ddr): Initialize PDDR_KIND and
2031 PDDR_ORIGINAL_SCATTERING_P.
2032 (pddr_is_empty): Rewritten.
2033 (print_dependence_polyhedron_layout): New.
2036 (build_alias_set_powerset): Moved up.
2037 (poly_drs_may_alias_p): Moved up.
2038 (lexicographically_gt_p): Removed.
2039 (build_lexicographically_gt_constraint): Renamed
2040 build_lexicographical_constraint, reimplemented.
2041 (dependence_polyhedron_1): Simplified parameters.
2042 (dependence_polyhedron): Same. Keep along empty PDDRs
2043 to make efficient use of the cache.
2044 (reduction_dr_p): Compute the PBBs don't pass them as parameters.
2045 (graphite_legal_transform_dr): Rewritten.
2046 (graphite_legal_transform_bb): Pass fewer arguments to
2047 graphite_legal_transform_dr.
2048 (graphite_carried_dependence_level_k): Simplified implementation.
2049 (dot_original_deps_stmt_1): Call dependence_polyhedron.
2050 (dot_transformed_deps_stmt_1): Same.
2051 (dot_original_deps): Same.
2052 (dot_transformed_deps): Same.
2053 * graphite-dependences.h (struct poly_ddr): Added a new field
2054 original_scattering_p.
2055 (PDDR_ORIGINAL_SCATTERING_P): New.
2056 (print_pddr): Declared.
2057 (debug_pddr): Declared.
2058 * graphite-ppl.c: Clarify comment.
2059 * sese.h (print_gimple_bb): Removed unused declaration.
2062 2010-02-03 Sebastian Pop <sebastian.pop@amd.com>
2064 * g++.dg/graphite/graphite.exp: Rewritten.
2065 * gcc.dg/graphite/graphite.exp: Rewritten.
2066 * gfortran.dg/graphite/graphite.exp: Rewritten.
2067 * gcc.dg/graphite/block-0.c: Added runtime test.
2068 * gcc.dg/graphite/block-1.c: Same.
2069 * gcc.dg/graphite/block-3.c: Same.
2070 * gcc.dg/graphite/block-4.c: Same.
2071 * gcc.dg/graphite/block-5.c: Same.
2072 * gcc.dg/graphite/block-6.c: Same.
2073 * gcc.dg/graphite/block-7.c: Same.
2074 * gcc.dg/graphite/interchange-0.c: Same.
2075 * gcc.dg/graphite/interchange-1.c: Same.
2076 * gcc.dg/graphite/interchange-10.c: Same.
2077 * gcc.dg/graphite/interchange-11.c: Same.
2078 * gcc.dg/graphite/interchange-12.c: Same.
2079 * gcc.dg/graphite/interchange-2.c: Same.
2080 * gcc.dg/graphite/interchange-3.c: Same.
2081 * gcc.dg/graphite/interchange-4.c: Same.
2082 * gcc.dg/graphite/interchange-5.c: Same.
2083 * gcc.dg/graphite/interchange-6.c: Same.
2084 * gcc.dg/graphite/interchange-7.c: Same.
2085 * gcc.dg/graphite/interchange-8.c: Same.
2086 * gcc.dg/graphite/interchange-9.c: Same.
2087 * gcc.dg/graphite/interchange-mvt.c: Same.
2088 * gcc.dg/graphite/run-id-2.c: Remove useless dg-do run.
2090 2010-01-22 Ramakrishna Upadrasta <Ramakrishna.Upadrasta@inria.fr>
2092 * graphite-scop-detection.c (dot_all_scops): Make calls to dot run in
2095 2010-01-22 Ramakrishna Upadrasta <Ramakrishna.Upadrasta@inria.fr>
2097 * common.opt: Add -fgraphite-cloog-opts.
2098 * graphite-clast-to-gimple.c (set_cloog_options): Same.
2099 * opts.c (decode_options): Same.
2101 2010-01-20 Sebastian Pop <sebastian.pop@amd.com>
2103 * gcc.dg/graphite/id-17.c: New.
2104 * gcc.dg/graphite/pr41888.c: New.
2105 * gcc.dg/graphite/scop-22.c: New.
2106 * gfortran.dg/graphite/pr40982.f90: New.
2108 2010-01-20 Sebastian Pop <sebastian.pop@amd.com>
2110 * graphite-dependences.c: Clarify comments.
2111 (build_pddr): Add an extra parameter direction.
2112 (graphite_legal_transform_dr): Use build_pddr.
2113 (dot_original_deps_stmt_1): Update use of build_pddr.
2114 (dot_transformed_deps_stmt_1): Same.
2115 (dot_original_deps): Same.
2116 (dot_transformed_deps): Same.
2118 * gcc.dg/graphite/interchange-12.c: New.
2119 * gcc.dg/graphite/block-7.c: New.
2121 2010-01-20 Sebastian Pop <sebastian.pop@amd.com>
2123 * graphite-dependences.c (pddr_original_scattering): Renamed build_pddr.
2124 (pddr_transformed_scattering): Removed.
2125 (graphite_legal_transform_dr): Use build_pddr.
2126 (dot_original_deps_stmt_1): Same.
2127 (dot_transformed_deps_stmt_1): Same.
2128 (dot_original_deps): Same.
2129 (dot_transformed_deps): Same.
2131 2010-01-20 Sebastian Pop <sebastian.pop@amd.com>
2133 * graphite-dependences.c (lexicographically_gt_p): Add comments.
2134 (build_lexicographically_gt_constraint): Same.
2135 (dependence_polyhedron_1): Same.
2136 (dependence_polyhedron): Same.
2138 2010-01-20 Sebastian Pop <sebastian.pop@amd.com>
2140 * graphite-dependences.c (build_pairwise_scheduling_equality): Removed.
2141 (build_pairwise_scheduling_inequality): Renamed build_pairwise_scheduling.
2142 (lexicographically_gt_p): Change type of direction to int.
2143 (build_lexicographically_gt_constraint): Same.
2144 (dependence_polyhedron_1): Same.
2145 (dependence_polyhedron): Same.
2146 (pddr_original_scattering): Use integers for direction.
2147 (pddr_transformed_scattering): Same.
2148 (graphite_legal_transform_dr): Same.
2149 (graphite_carried_dependence_level_k): Same.
2151 2010-01-20 Sebastian Pop <sebastian.pop@amd.com>
2153 * graphite-dependences.c (build_pairwise_constraint): Renamed
2154 ppl_build_relation. Moved...
2155 (dr_equality_constraints): Use ppl_build_relation.
2156 (build_pairwise_scheduling_equality): Same.
2157 (build_pairwise_scheduling_inequality): Same.
2158 * graphite-ppl.c (ppl_build_relation): ...here.
2159 * graphite-ppl.h (ppl_build_relation): Declared.
2161 2010-01-14 Sebastian Pop <sebastian.pop@amd.com>
2164 * graphite-clast-to-gimple.c (gloog_error): New static variable.
2165 (clast_to_gcc_expression): Do not build MULT_EXPR of POINTER_TYPE_P.
2166 Set gloog_error when such an expression failed to be built.
2167 (translate_clast): Early return when gloog_error is set.
2168 (gloog): Clear gloog_error. When gloog_error is set, call
2169 set_ifsese_condition to enable the original code. Return the status
2170 of the code generation based on gloog_error.
2171 * sese.c (set_ifsese_condition): New.
2172 * sese.h (set_ifsese_condition): Declared.
2174 * g++.dg/graphite/pr42681.C: New.
2176 2010-01-14 Sebastian Pop <sebastian.pop@amd.com>
2179 * graphite-clast-to-gimple.c (gloog): Call scev_reset_htab and
2180 rename_nb_iterations.
2181 * sese.c (rename_variables_in_operand): New.
2182 (rename_variables_in_expr): New.
2183 (rename_nb_iterations): New.
2184 (sese_adjust_liveout_phis): Update the rename_map.
2185 * sese.h (rename_nb_iterations): Declared.
2186 * tree-scalar-evolution.c (scev_reset_htab): New.
2187 (scev_reset): Call scev_reset_htab.
2188 * tree-scalar-evolution.h (scev_reset_htab): Declared.
2190 * gfortran.dg/graphite/pr42732.f: New.
2192 2010-01-08 Sebastian Pop <sebastian.pop@amd.com>
2195 * graphite-clast-to-gimple.c: Fix formatting.
2196 * sese.c (defined_in_loop_p): Renamed name_defined_in_loop_p.
2197 (expr_defined_in_loop_p): New.
2198 (add_loop_exit_phis): Also handle full expressions: remove from
2199 the rename_map the expressions defined in the loop that we're closing.
2201 * gfortran.dg/graphite/pr42393-1.f90: New.
2202 * gfortran.dg/graphite/pr42393.f90: Add new flags
2203 -fno-loop-block -fno-loop-interchange -fno-loop-strip-mine to also
2204 make this testcase useful in the Graphite branch.
2206 2010-01-08 Sebastian Pop <sebastian.pop@amd.com>
2208 * graphite-scop-detection.c (exclude_component_ref): Removed.
2209 (is_simple_operand): Removed.
2210 (stmt_simple_for_scop_p): Remove use of is_simple_operand.
2212 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
2215 * sese.c (expand_scalar_variables_expr): Follow the SSA links into
2216 the array indexing of ADDR_EXPRs.
2218 * gcc.dg/graphite/pr42221.c: New.
2220 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
2223 * graphite.c (graphite_finalize): Call scev_reset.
2224 (graphite_transform_loops): Do not call scev_reset between the code
2225 generation of scops.
2227 * gcc.dg/graphite/pr42521.c: New.
2229 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
2231 * graphite-interchange.c (memory_stride_in_loop): Renamed
2233 (memory_strides_in_loop): Renamed memory_strides_in_loop_1.
2234 (memory_strides_in_loop): Memoize the memory strides per loop.
2235 (lst_interchange_profitable_p): Do not initialize to zero the memory
2237 * graphite-poly.h (struct lst): Add a field memory_strides.
2238 (LST_LOOP_MEMORY_STRIDES): New.
2239 (new_lst_loop): Initialize LST_LOOP_MEMORY_STRIDES to -1.
2240 (free_lst): Clear LST_LOOP_MEMORY_STRIDES.
2242 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
2244 * graphite-interchange.c (memory_strides_in_loop_depth): Renamed
2245 memory_strides_in_loop. Gather memory strides on a whole loop.
2246 (pbb_interchange_profitable_p): Renamed lst_interchange_profitable_p.
2247 (lst_interchange_profitable_p): Removed.
2248 (lst_try_interchange_loops): Call lst_interchange_profitable_p.
2250 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
2252 Revert patch 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
2253 * graphite-clast-to-gimple.c (try_mark_loop_parallel): New.
2254 (translate_clast_for, translate_clast_guard, translate_clast, gloog):
2255 Remove context_loop and level.
2257 2010-01-07 Richard Guenther <rguenther@suse.de>
2259 PR tree-optimization/42641
2260 * sese.c (rename_map_elt_info): Use the SSA name version, do
2263 2010-01-06 Sebastian Pop <sebastian.pop@amd.com>
2265 * graphite-blocking.c (scop_do_block): Print "SCoP will be loop
2266 blocked" only when both the strip mine and the interchange have
2269 * gcc.dg/graphite/block-2.c: Removed.
2270 * gcc.dg/graphite/block-3.c: Add scan pattern.
2271 * gcc.dg/graphite/block-4.c: Same.
2272 * gcc.dg/graphite/block-5.c: Same.
2273 * gcc.dg/graphite/block-6.c: Same.
2275 2010-01-06 Sebastian Pop <sebastian.pop@amd.com>
2277 * graphite-clast-to-gimple.c (save_clast_name_index): Free slot
2278 before allocating a new one.
2279 (copy_renames): Check that slot is not NULL.
2280 (mark_bb_with_pbb): Same.
2281 (compute_cloog_iv_types_1): Same.
2282 * graphite-interchange.c (lst_perfect_nestify): Free the before,
2283 nest, and after LSTs.
2284 (lst_try_interchange_loops): Same.
2286 2010-01-05 Sebastian Pop <sebastian.pop@amd.com>
2289 * graphite-interchange.c (lst_try_interchange_loops): Do not return
2290 the before, nest, and after LSTs.
2291 (lst_try_interchange): Removed.
2292 (lst_interchange_select_inner): Do not iterate over the LSTs if they
2294 (lst_interchange_select_outer): Apply interchange on the outer loop
2295 until there are no more changes in the inner loops.
2297 2009-12-18 Sebastian Pop <sebastian.pop@amd.com>
2299 Revert patch fixing PR middle-end/42221.
2301 2009-12-18 Sebastian Pop <sebastian.pop@amd.com>
2304 * graphite-sese-to-poly.c (follow_ssa_with_commutative_ops): Handle
2307 * gfortran.dg/graphite/pr42180.f90: Add compile flags.
2309 2009-12-18 Sebastian Pop <sebastian.pop@amd.com>
2312 * graphite-sese-to-poly.c (split_reduction_stmt): Do not split blocks
2313 that contain only one statement.
2315 * gfortran.dg/graphite/pr42180.f90: New.
2317 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
2320 * gfortran.dg/graphite/pr42393.f90: New.
2322 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
2325 * gfortran.dg/graphite/pr42186.f90: New.
2327 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
2330 * graphite-sese-to-poly.c (translate_scalar_reduction_to_array_for_stmt):
2331 Insert the reduction copy in the same block as the phi node.
2332 (follow_ssa_with_commutative_ops): Handle GIMPLE_NOPs.
2334 * gcc.dg/graphite/pr42205-1.c: New.
2335 * gcc.dg/graphite/pr42205-2.c: New.
2337 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
2340 * sese.c (expand_scalar_variables_expr): Follow the SSA links into
2341 the array indexing of ADDR_EXPRs.
2343 * gcc.dg/graphite/pr42221.c: New.
2345 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
2349 * graphite-interchange.c (lst_try_interchange): Do not modify OUTER
2350 index. Call lst_interchange_select_inner only once.
2351 (lst_interchange_select_inner): Update use of lst_try_interchange.
2352 (lst_interchange_select_outer): Update.
2354 2009-12-15 Sebastian Pop <sebastian.pop@amd.com>
2358 * graphite-interchange.c (lst_try_interchange): Do not increment the
2359 the OUTER index when there is no AFTER kernel. Do not increment the
2360 OUTER index for after processing the AFTER kernel.
2361 (lst_interchange_select_inner): Call lst_try_interchange only on loops.
2362 (lst_interchange_select_outer): Do not pass in a pointer to the OUTER
2363 index. Do not pass to lst_interchange_select_inner the OUTER index.
2364 (scop_do_interchange): Update use of lst_interchange_select_outer.
2366 * gfortran.dg/graphite/graphite.exp
2367 (DEFAULT_FLAGS_GRAPHITE_IDENTITY): Remove -fdump-tree-graphite-all.
2368 * gfortran.dg/graphite/interchange-1.f: Add comment. Clean
2369 the graphite dump file.
2370 * gfortran.dg/graphite/interchange-2.f: Same.
2371 * gfortran.dg/graphite/pr42334-1.f: New.
2373 2009-12-15 Sebastian Pop <sebastian.pop@amd.com>
2377 * graphite-interchange.c (lst_perfect_nestify): Reset to NULL the LSTs
2379 (lst_do_interchange_1): Renamed lst_interchange_select_inner.
2380 (lst_try_interchange): Reimplemented.
2381 (lst_interchange_select_inner): Same.
2382 (lst_do_interchange): Renamed lst_interchange_select_outer.
2384 (scop_do_interchange): Update use of lst_interchange_select_outer.
2386 * g++.dg/graphite/pr42130.C: Add -fgraphite-identity.
2387 * gcc.dg/graphite/block-0.c: Un-XFAILed.
2388 * gcc.dg/graphite/pr42211.c: New.
2389 * gfortran.dg/graphite/pr42334.f90: New.
2391 2009-12-14 Sebastian Pop <sebastian.pop@amd.com>
2394 * graphite-scop-detection.c (graphite_can_represent_scev): Handle more
2395 carefully PLUS_EXPR, MINUS_EXPR, and MULT_EXPR.
2397 * gfortran.dg/graphite/pr42181.f90: New.
2399 2009-12-12 Sebastian Pop <sebpop@gmail.com>
2402 * graphite-sese-to-poly.c (rewrite_close_phi_out_of_ssa): Call
2403 insert_out_of_ssa_copy_on_edge for anything else than SSA_NAMEs.
2404 (detect_commutative_reduction_arg): Simplified.
2405 (detect_commutative_reduction): Early return when the argument of
2406 the close phi is not of an SSA_NAME.
2408 * gcc.dg/graphite/pr42284.c: New.
2410 2009-12-11 Alexander Monakov <amonakov@ispras.ru>
2412 * dbgcnt.def (graphite_scop): New counter.
2413 * graphite.c: Include dbgcnt.h
2414 (graphite_transform_loops): Use new counter to limit transformations.
2416 2009-12-08 Sebastian Pop <sebpop@gmail.com>
2419 * graphite-scop-detection.c (graphite_can_represent_init): Also
2420 handle more complex MULT_EXPRs containing parameters by recursion
2423 * gfortran.dg/graphite/pr42285.f90: New.
2425 2009-12-01 Tobias Grosser <grosser@fim.uni-passau.de>
2427 * g++.dg/graphite/pr42130.C: Fix type.
2429 2009-11-29 Alexander Monakov <amonakov@gcc.gnu.org>
2431 * g++.dg/graphite/pr42130.C: Correct testcase.
2433 2009-11-28 Tobias Grosser <grosser@fim.uni-passau.de>
2435 * Merge from mainline (154493:154734).
2437 2009-11-28 Tobias Grosser <grosser@fim.uni-passau.de>
2439 * Merge from mainline (151362:154491).
2441 2009-11-24 Tobias Grosser <grosser@fim.uni-passau.de>
2443 * graphite-clast-to-gimple.c (try_mark_loop_parallel,
2444 graphite_create_new_loop_guard, translate_clast_for): Fix comments.
2446 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
2449 * graphite-clast-to-gimple.c (graphite_create_new_loop_guard,
2450 translate_clast_for_loop): New.
2451 (translate_clast_for): Add a condition around the loop, to do not
2452 execute loops with zero iterations.
2453 * g++.dg/graphite/pr42130.C: New.
2454 * gcc.dg/graphite/pr35356-2.c: Adapt.
2456 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
2458 * graphite-clast-to-gimple.c (try_mark_loop_parallel): New.
2459 (translate_clast_for, translate_clast_guard, translate_clast, gloog):
2460 Remove context_loop and level.
2462 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
2464 * graphite-clast-to-gimple.c (translate_clast_user,
2465 translate_clast_for, translate_clast_guard): Simplify and move common
2466 elements to translate_clast().
2467 (translate_clast): Simplify and get common elements.
2469 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
2471 * graphite-clast-to-gimple.c (translate_clast_user,
2472 translate_clast_for, translate_clast_guard): Split out of
2475 2009-11-21 Tobias Grosser <grosser@fim.uni-passau.de>
2477 * graphite-clast-to-gimple.c (clast_name_index, new_clast_name_index,
2478 clast_name_to_index, save_clast_name_index, debug_clast_name_index,
2479 debug_clast_name_indexes_1, debug_clast_name_indexes,
2480 clast_name_index_elt_info, eq_clast_name_indexes): Moved from sese.h.
2481 (clast_name_to_gcc, clast_to_gcc_expression,
2482 clast_to_gcc_expression_red, gcc_type_for_clast_expr,
2483 gcc_type_for_clast_eq, graphite_translate_clast_equation,
2484 graphite_create_guard_cond_expr, graphite_create_new_loop,
2485 translate_clast): Add params_index.
2486 (initialize_cloog_names): Create parameter strings from scratch, do
2487 not reference other strings.
2488 (create_params_index): New.
2489 (gloog): Initialize params_index.
2490 * graphite-scop-detection (free_scops_1): Removed.
2491 (limit_scops): Use normal free_scops.
2492 * graphite-sese-to-poly.c (save_var_names): Removed.
2493 (parameter_index_in_region): Do not initialize SESE_PARAM_NAMES
2494 and SESE_PARAMS_INDEX.
2495 * sese.c (new_sese, free_sese): Dito.
2496 * sese.h (struct sese): Remove params_index, params_names.
2497 (SESE_PARAMS_INDEX, SESE_PARAMS_NAMES): Removed.
2499 2009-11-20 Sebastian Pop <sebastian.pop@amd.com>
2501 Revert the following patch from 2009-09-14:
2502 * graphite-blocking.c: Fix order of includes: tree-chrec.h, then
2503 tree-scalar-evolution.h, and then tree-data-ref.h.
2504 * graphite-clast-to-gimple.c: Same.
2505 * graphite-dependences.c: Same.
2506 * graphite-interchange.c: Same.
2507 * graphite-poly.c: Same.
2508 * graphite-scop-detection.c: Same.
2509 * graphite-sese-to-poly.c: Same.
2511 * lambda-code.c: Same.
2512 * matrix-reorg.c: Same.
2513 * tree-data-ref.c: Same.
2514 * tree-if-conv.c: Same.
2515 * tree-loop-distribu: Same.: Same.
2516 * tree-loop-linear.c: Same.
2517 * tree-parloops.c: Same.
2518 * tree-predcom.c: Same.
2519 * tree-vect-patterns.c: Same.
2521 2009-11-20 Sebastian Pop <sebastian.pop@amd.com>
2523 Revert patch from 2009-09-14.
2524 * tree-ssa-loop.c (gate_graphite_transforms): Re-enable Graphite
2525 passes at -O1 and below.
2527 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
2530 * gcc.dg/graphite/pr40281.c: New.
2532 * tree-scalar-evolution.c (instantiate_scev_poly): Base and stride
2533 evolutions should not variate in inner loops.
2535 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
2538 * gfortran.dg/graphite/pr42050.f90: New.
2540 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
2542 * graphite-interchange.c (memory_strides_in_loop_depth): New.
2543 (pbb_interchange_profitable_p): Call memory_strides_in_loop_depth.
2545 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
2547 * graphite-blocking.c (scop_do_block): New.
2548 * graphite-poly.c (apply_poly_transforms): Call scop_do_block.
2549 * graphite-poly.h (scop_do_block): Declared.
2551 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
2553 * graphite-blocking.c (pbb_strip_mine_profitable_p): The parameter
2554 depth is the loop nesting depth in the LST. Call psct_dynamic_dim
2555 to transform depth into the time_depth before calling
2556 pbb_number_of_iterations_at_time.
2557 (lst_do_strip_mine): Use a scalar variable instead of recomputing
2560 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
2562 Reverted the patch for "scattering permutations" from 2009-10-28.
2564 * graphite-poly.c (print_permutation): New.
2565 (debug_permutation): New.
2566 (new_poly_bb): Initialize PBB_PERMUTATION.
2567 (free_poly_bb): Free PBB_PERMUTATION.
2568 * graphite-poly.h (pbb_permutation_elt_p): Declared.
2569 (struct pbb_permutation_elt): New.
2570 (PBB_PERMUTATION_ELT_STRIDE): New.
2571 (PBB_PERMUTATION_ELT_STRIDED_P): New.
2572 (PBB_PERMUTATION_ELT_TIME_DIMENSION): New.
2573 (new_pbb_permutation_elt): New.
2574 (pbb_permutation_elt_free): New.
2575 (struct poly_bb): Add field permutation.
2576 (PBB_PERMUTATION): New.
2577 (print_permutation): Declared.
2578 (debug_permutation): Declared.
2580 2009-11-04 Konrad Trifunovic <konrad.trifunovic@inria.fr>
2582 * graphite-interchange.c (build_partial_difference): New.
2583 (memory_stride_in_loop): Refactored the computation of
2584 equality constraints into build_partial_difference function.
2585 Added support for debugging stride computations.
2587 2009-11-03 Sebastian Pop <sebastian.pop@amd.com>
2589 * graphite-clast-to-gimple.c (gloog): Free if_region,
2590 if_region->true_region, and if_region->region.
2591 * sese.c (if_region_set_false_region): Free if_region->false_region.
2592 (create_if_region_on_edge): Do not use GGC_NEW.
2593 (move_sese_in_condition): Remove useless initialization.
2595 2009-11-03 Sebastian Pop <sebastian.pop@amd.com>
2597 * graphite-interchange.c (lst_perfect_nestify): Pass 3 parameters
2598 for the loops created by the loop distribution. Do not modify the
2600 (lst_try_interchange_loops): Same. Use a temporary LST for the
2601 transformed schedule. Call lst_update_scattering before data
2602 dependence analysis.
2603 (lst_try_interchange): Pass an extra parameter INDEX.
2604 (lst_do_interchange_1): New.
2605 (lst_do_interchange): Call lst_do_interchange_1.
2606 (scop_do_interchange): Call lst_update_scattering.
2607 * graphite-poly.c (apply_poly_transforms): Do not call
2608 lst_update_scattering.
2609 * graphite-poly.h (lst_pred): New.
2611 (lst_find_first_pbb): Return NULL when not found.
2613 (lst_insert_in_sequence): Allow LST1 to be NULL.
2615 (lst_substitute_3): New.
2616 * gcc.dg/graphite/interchange-1.c: XFail.
2617 * gcc.dg/graphite/interchange-8.c: XFail.
2618 * gcc.dg/graphite/interchange-11.c: XFail.
2620 2009-10-30 Sebastian Pop <sebastian.pop@amd.com>
2622 * graphite-interchange.c (lst_perfectly_nested_p): New.
2623 (lst_perfect_nestify): New.
2624 (lst_try_interchange_loops): Call store_lst_schedule,
2625 lst_perfectly_nested_p, lst_perfect_nestify and restore_lst_schedule.
2626 (scop_do_interchange): Avoid redundant legality test.
2627 Call lst_do_interchange on a copy of SCOP_TRANSFORMED_SCHEDULE.
2628 * graphite-poly.c (apply_poly_transforms): Call lst_update_scattering.
2629 * graphite-poly.h (psct_static_dim): New.
2630 (lst_dewey_number_at_depth): New.
2631 (lst_find_pbb): Restructured.
2632 (lst_find_first_pbb): Restructured.
2633 (lst_find_last_pbb): New.
2634 (lst_contains_p): New.
2635 (lst_contains_pbb): New.
2636 (lst_create_nest): New.
2637 (lst_remove_from_sequence): New.
2638 (pbb_update_scattering): New.
2639 (lst_update_scattering_under): New.
2640 (lst_update_scattering_seq): New.
2641 (lst_update_scattering): New.
2642 (lst_insert_in_sequence): New.
2643 (lst_distribute_lst): New.
2644 (lst_remove_all_before_including_pbb): New.
2645 (lst_remove_all_before_excluding_pbb): New.
2647 2009-10-30 Sebastian Pop <sebastian.pop@amd.com>
2649 * tree-ssa-loop-niter.c (finite_loop_p): Do not call twice
2650 get_loop_exit_edges.
2652 2009-10-30 Sebastian Pop <sebastian.pop@amd.com>
2654 * graphite-poly.c (pbb_remove_duplicate_pdrs): Free collapsed.
2656 2009-10-28 Konrad Trifunovic <konrad.trifunovic@gmail.com>
2658 * graphite-poly.c (print_permutation): New.
2659 (debug_permutation): New.
2660 (new_poly_bb): Initialize PBB_PERMUTATION.
2661 (free_poly_bb): Free PBB_PERMUTATION.
2662 * graphite-poly.h (pbb_permutation_elt_p): Declared.
2663 (struct pbb_permutation_elt): New.
2664 (PBB_PERMUTATION_ELT_STRIDE): New.
2665 (PBB_PERMUTATION_ELT_STRIDED_P): New.
2666 (PBB_PERMUTATION_ELT_TIME_DIMENSION): New.
2667 (new_pbb_permutation_elt): New.
2668 (pbb_permutation_elt_free): New.
2669 (struct poly_bb): Add field permutation.
2670 (PBB_PERMUTATION): New.
2671 (print_permutation): Declared.
2672 (debug_permutation): Declared.
2674 2009-10-26 Sebastian Pop <sebastian.pop@amd.com>
2676 * graphite-clast-to-gimple.c (gloog): Do not call
2677 sese_reset_aux_in_loops.
2678 * graphite-sese-to-poly.c (build_loop_iteration_domains): Pass an
2679 extra argument for domains. Do not use loop->aux.
2680 (build_scop_iteration_domain): Initialize and free domains, pass it
2681 to build_loop_iteration_domains and extract the information from
2682 domains. Do not use loop->aux.
2683 * sese.c (sese_reset_aux_in_loops): Removed.
2684 * sese.h (sese_reset_aux_in_loops): Removed.
2686 2009-10-26 Sebastian Pop <sebastian.pop@amd.com>
2688 * graphite-clast-to-gimple.c (find_pbb_via_hash): Moved up.
2689 (dependency_in_loop_p): Same.
2690 (translate_clast): Do not use loop->aux. Initialize
2691 loop->can_be_parallel.
2692 (mark_loops_parallel): Removed.
2693 * graphite-clast-to-gimple.h (mark_loops_parallel): Removed.
2694 * graphite.c (free_aux_in_new_loops): Removed.
2695 (graphite_finalize): Do not call free_aux_in_new_loops.
2696 (graphite_transform_loops): Do not call mark_loops_parallel.
2698 2009-10-26 Li Feng <nemokingdom@gmail.com>
2700 * graphite-clast-to-gimple.c (get_stmtfor_depth): Removed.
2701 (translate_clast): Pass an extra parameter LEVEL.
2702 Call get_scattering_level.
2703 * graphite-clast-to-gimple.h (get_scattering_level): New.
2705 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
2707 * cfgloop.c (alloc_loop): Initialize loop->single_iv.
2708 * cfgloop.h (struct loop): New field single_iv.
2710 * graphite-clast-to-gimple.c (pbb_to_depth_to_oldiv): Do not use
2711 loop->aux anymore: use loop->single_iv.
2712 (graphite_loop_normal_form): Moved...
2713 (build_graphite_loop_normal_form): Removed.
2714 (gloog): Do not call build_graphite_loop_normal_form.
2715 (free_aux_in_new_loops): Moved...
2716 (mark_loops_parallel): Restructure.
2717 * graphite-clast-to-gimple.h (free_aux_in_new_loops): Do not declare.
2718 * graphite-sese-to-poly.c (graphite_loop_normal_form): ...here.
2719 (scop_canonicalize_loops): New.
2720 (build_poly_scop): Call scop_canonicalize_loops.
2721 * graphite.c (free_aux_in_new_loops): ...here.
2723 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
2725 * g++.dg/graphite/graphite.exp: Add the same rules as in
2726 gcc.dg/graphite/graphite.exp.
2728 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
2730 * g++.dg/graphite/id-1.C: New.
2732 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
2734 * graphite-sese-to-poly.c (create_zero_dim_array): Pass an extra
2736 (rewrite_close_phi_out_of_ssa): Update use of create_zero_dim_array.
2737 (rewrite_phi_out_of_ssa): Same.
2738 (rewrite_cross_bb_scalar_deps): Same.
2739 (translate_scalar_reduction_to_array): Same.
2741 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
2743 * graphite-sese-to-poly.c (build_scop_drs): Disable call to
2746 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
2748 * graphite-sese-to-poly.c (dump_alias_graphs): New.
2749 (build_scop_drs): Call dump_alias_graphs.
2751 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
2753 * graphite-poly.c (new_scop): Initialize SCOP_ORIGINAL_SCHEDULE,
2754 SCOP_TRANSFORMED_SCHEDULE, and SCOP_SAVED_SCHEDULE.
2755 (free_scop): Call free_lst on SCOP_ORIGINAL_SCHEDULE,
2756 SCOP_TRANSFORMED_SCHEDULE, and SCOP_SAVED_SCHEDULE.
2757 * graphite-poly.h (free_lst): New.
2758 (store_lst_schedule): Free SCOP_SAVED_SCHEDULE.
2759 (restore_lst_schedule): Free SCOP_TRANSFORMED_SCHEDULE.
2761 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
2763 * graphite-poly.h (struct scop): Add a field saved_schedule.
2764 (SCOP_SAVED_SCHEDULE): New.
2765 (store_lst_schedule): New.
2766 (restore_lst_schedule): New.
2767 (store_scattering): Call store_lst_schedule.
2768 (restore_scattering): Call restore_lst_schedule.
2770 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
2772 * graphite-sese-to-poly.c (free_data_refs_aux): Fix formatting.
2773 (pdr_add_alias_set): Same.
2774 (build_poly_dr): Same.
2775 (build_alias_set_optimal_p): Same.
2776 (build_base_obj_set_for_drs): Same. Do not store the result of
2779 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
2781 * graphite-sese-to-poly.c (build_alias_set_optimal_p): Initialize
2782 all_components_are_cliques to 1.
2784 2009-10-20 Li Feng <nemokingdom@gmail.com>
2786 * graphite-sese-to-poly.c (free_data_refs_aux): Update to free
2788 (pdr_add_alias_set): Update retrieving alias_set_num.
2789 (build_poly_dr): Update retrieving dr_base_object_set.
2790 (partition_drs_to_sets): Remove.
2791 (build_alias_set_optimal_p): New.
2792 (build_alias_set_for_drs): Rename.
2793 (build_scop_drs): Update.
2794 * graphite-sese-to-poly.h (struct base_alias_pair): New.
2795 (ALIAS_SET_INDEX): Remove.
2796 (BASE_OBJECT_SET_INDEX): Remove.
2798 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
2800 * sese.c (get_vdef_before_sese): Handle GIMPLE_ASSIGN and GIMPLE_CALL.
2802 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
2804 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Do not infer
2805 loop upper bounds for 1-element arrays at end of structures.
2806 * tree-flow.h (array_at_struct_end_p): Declared.
2807 * tree-ssa-loop-niter.c (array_at_struct_end_p): Not static anymore.
2809 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
2811 * g++.dg/graphite/pr41305.C: New.
2813 2009-10-20 Alexander Monakov <amonakov@ispras.ru>
2815 * graphite-sese-to-poly.c (build_loop_iteration_domains): Generalize
2816 construction of parameter constraints from loop iteration analysis.
2817 * gcc.dg/graphite/run-id-2.c: New test.
2819 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
2821 * graphite-interchange.c (memory_stride_in_loop): Delete p1, lma
2824 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
2826 * graphite-dependences.c (dependence_polyhedron_1): Remove
2827 unused gdim dimensions from the DDR polyhedron.
2829 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
2831 * graphite-dependences.c (pddr_transformed_scattering): New.
2832 (dot_original_deps_stmt_1): New.
2833 (dot_transformed_deps_stmt_1): New.
2834 (dot_deps_stmt_1): Call dot_original_deps_stmt_1 and
2835 dot_transformed_deps_stmt_1.
2836 (dot_original_deps): New.
2837 (dot_transformed_deps): New.
2838 (dot_deps_1): Call dot_original_deps and dot_transformed_deps.
2840 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
2842 * graphite-dependences.c (reduction_dr_1): Remove wrong
2843 assert: reduction BBs can have multiple reduction writes
2844 to memory. interchange-3.f90 is an example.
2846 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
2848 * gfortran.dg/graphite/interchange-3.f90: New.
2850 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
2852 * gcc.dg/graphite/interchange-1.c: Un-XFAILed.
2854 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
2856 * graphite-dependences.c (dependence_polyhedron_1): Add the
2857 context to the dependence polyhedron.
2859 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
2861 * graphite-poly.c (pbb_remove_duplicate_pdrs): Initialize
2862 PBB_PDR_DUPLICATES_REMOVED.
2863 (new_poly_bb): Same.
2865 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
2867 * graphite-sese-to-poly.c (find_scop_parameters): Initialize
2869 (build_loop_iteration_domains): Extract bounds on parameters
2870 based on the data size.
2871 (build_scop_context): Do not initialize SCOP_CONTEXT;
2872 add new constraints.
2874 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
2876 * graphite-ppl.c (ppl_min_for_le_polyhedron): New.
2877 * graphite-ppl.h (graphite-ppl.h): Declared.
2879 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
2881 * graphite-ppl.c (ppl_print_linear_expr): New.
2882 (debug_ppl_linear_expr): New.
2883 * graphite-ppl.h (ppl_print_linear_expr): Declared.
2884 (debug_ppl_linear_expr): Declared.
2886 2009-10-16 Sebastian Pop <sebastian.pop@amd.com>
2888 * graphite-interchange.c: Fix comments.
2889 * gcc.dg/graphite/block-1.c: Fix comments.
2891 2009-10-16 Sebastian Pop <sebastian.pop@amd.com>
2893 * gcc.dg/graphite/interchange-7.c: Un-XFAILed.
2894 * gcc.dg/graphite/interchange-9.c: Un-XFAILed.
2896 2009-10-16 Sebastian Pop <sebastian.pop@amd.com>
2898 Reapply the patch from Alexander Monakov that disappeared during
2899 the last merges from trunk.
2901 2009-09-16 Alexander Monakov <amonakov@ispras.ru>
2903 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Add bounds only
2904 for ARRAY_REFs. Use array_ref_{low,up}_bound to determine bounds.
2906 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
2908 * graphite-interchange.c (memory_stride_in_loop): The depth
2909 argument corresponds to a dynamic time dimension, so use
2910 psct_dynamic_dim to refer to the transformed scattering dimension.
2912 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
2914 * graphite-interchange.c (memory_stride_in_loop): Fix comments.
2916 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
2918 * graphite-blocking.c (lst_do_strip_mine): Avoid strip mining the
2920 * graphite-interchange.c (lst_do_interchange): Avoid interchanging
2921 the root of the LST.
2922 * graphite-poly.c (scop_to_lst): Fix LST sequence in an outermost
2924 (print_lst): Print the root of LST in a different format.
2925 * graphite-poly.h (lst_depth): Adjust to include the root of the LST.
2927 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
2929 * graphite-poly.c (print_scop): Fix pretty printing of a SCoP.
2931 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
2933 * doc/passes.texi: Document the Graphite infrastructure.
2935 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
2937 * graphite-sese-to-poly.c (insert_copyin): Use gsi_insert_seq_on_edge.
2938 (rewrite_commutative_reductions_out_of_ssa): Call gsi_commit_edge_inserts,
2939 and check the SSA representation.
2941 * gfortran.dg/graphite/id-18.f90: New, reduced from PR41193.
2943 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
2945 * gcc.dg/graphite/pr40157.c: Use -floop-block as reported in the PR.
2947 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
2949 * gcc.dg/graphite/interchange-11.c: New.
2951 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
2953 * gcc.dg/graphite/interchange-8.c: Enable loop interchange.
2955 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
2957 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK):
2958 Add -fno-loop-strip-mine and -fno-loop-interchange.
2959 (DEFAULT_FLAGS_GRAPHITE_INTERCHANGE): Add -fno-loop-block and
2960 -fno-loop-strip-mine.
2961 * gfortran.dg/graphite/graphite.exp: Same.
2963 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
2965 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK):
2966 Renamed DEFAULT_FLAGS_GRAPHITE_BLOCK.
2967 (DEFAULT_CFLAGS_GRAPHITE_IDENTITY): Renamed
2968 DEFAULT_FLAGS_GRAPHITE_IDENTITY.
2969 (DEFAULT_CFLAGS_GRAPHITE_INTERCHANGE): Renamed
2970 DEFAULT_FLAGS_GRAPHITE_INTERCHANGE.
2971 (DEFAULT_CFLAGS_GRAPHITE_SCOP): Renamed
2972 DEFAULT_FLAGS_GRAPHITE_SCOP.
2973 (DEFAULT_CFLAGS_RUN_ID): Renamed DEFAULT_FLAGS_RUN_ID.
2974 (DEFAULT_CFLAGS_GRAPHITE): Renamed DEFAULT_FLAGS_GRAPHITE.
2976 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
2978 * graphite-poly.c (pbb_number_of_iterations_at_time): Cleanup comments.
2980 2009-10-14 Konrad Trifunovic <konrad.trifunovic@gmail.com>
2981 Sebastian Pop <sebastian.pop@amd.com>
2983 * graphite-interchange.c (build_linearized_memory_access): Pass an
2984 offset as parameter.
2985 (memory_stride_in_loop): Include transform scattering in the
2986 access functions to be able to querry the strides in the
2988 (pbb_interchange_loop_depths): Interchange the psct_dynamic_dim,
2989 not the psct_iterator_dim.
2991 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
2993 * graphite-blocking.c (pbb_do_strip_mine): Removed.
2994 (lst_do_strip_mine_loop): New.
2995 (lst_do_strip_mine): New.
2996 (scop_do_strip_mine): Call lst_do_strip_mine.
2997 * graphite-poly.h (lst_add_loop_under_loop): New.
2998 (lst_find_first_pbb): New.
3000 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
3002 * graphite-poly.c (loop_to_lst): Fix LST creation.
3004 2009-10-14 Tobias Grosser <grosser@fim.uni-passau.de>
3006 * gcc.dg/graphite/id-15.c: (8 * 8) replaced with
3007 sizeof(unsigned long) to make it run on 32bit systems.
3009 2009-10-14 Tobias Grosser <grosser@fim.uni-passau.de>
3011 * gcc.dg/graphite/run-id-1.c: Use smaller matrix to not
3014 2009-10-14 Ramakrishna Upadrasta <Ramakrishna.Upadrasta@inria.fr>
3016 * graphite-sese-to-poly.c (write_alias_graph_to_ascii_dimacs): Fix
3018 (write_alias_graph_to_ascii_dot): New.
3019 (write_alias_graph_to_ascii_ecc): Ditto.
3020 (partition_drs_to_sets): Add testing of optimality of current method
3021 which assigns alias numbers according to DFS Comopnent number. used
3022 as heuristic for the upcoming ECC algorithm.
3023 (build_scop_drs): Write to file also with the ecc and dot format.
3025 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
3027 * gfortran.dg/graphite/interchange-1.f: XFail.
3029 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
3031 * graphite.c (graphite_initialize): Do not handle functions with
3032 more than 100 basic blocks.
3034 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
3036 * graphite-blocking.c (pbb_do_strip_mine): Use
3037 PARAM_LOOP_BLOCK_TILE_SIZE.
3039 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
3041 * graphite-poly.c (dot_lst_1): New.
3043 * graphite-poly.h (dot_lst): Declared.
3045 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
3047 * graphite-dependences.c (dot_deps_stmt_1): New.
3048 (dot_deps_stmt): New.
3049 * graphite-dependences.h (dot_deps_stmt): Declared.
3051 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
3053 * graphite-sese-to-poly.c (rewrite_cross_bb_scalar_dependence): Do
3054 not replace cross BB scalar dependences ending on PHI nodes.
3055 (rewrite_cross_bb_scalar_deps): Filter out GIMPLE_PHI nodes.
3057 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
3059 * graphite-poly.c (apply_poly_transforms): Implement the high
3060 level driver for flag_loop_block.
3061 * opts.c (decode_options): Enable flag_loop_block at -O2.
3062 * tree-ssa-loop.c (gate_graphite_transforms): Remove call to sorry for
3065 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK): Add
3067 * gfortran.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK):
3070 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
3072 * graphite-poly.h (lst_find_pbb): New.
3073 (find_lst_loop): New.
3075 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
3077 * graphite-poly.c (new_scop): Remove init of SCOP_DEP_GRAPH.
3078 * graphite-poly.h (struct scop): Remove dep_graph field.
3079 (SCOP_DEP_GRAPH): Removed.
3081 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
3083 * graphite-poly.h (copy_lst): Do full copy of LST.
3085 2009-10-07 Sebastian Pop <sebastian.pop@amd.com>
3087 * graphite-sese-to-poly.c (reduction_phi_p): Call remove_invariant_phi
3088 when the loop stride is zero.
3090 * gcc.dg/graphite/id-16.c: New.
3092 2009-10-06 Sebastian Pop <sebastian.pop@amd.com>
3094 * graphite-dependences.c (reduction_dr_1): New.
3095 (reduction_dr_p): New.
3096 (graphite_legal_transform_dr): Call reduction_dr_p.
3097 (reduction_ddr): Renamed reduction_ddr_p.
3098 * graphite-poly.h (same_pdr_p): New.
3099 (number_of_write_pdrs): New.
3100 * graphite-sese-to-poly.c (nb_data_writes_in_bb): New.
3101 (split_reduction_stmt): Do not split reduction statements
3102 when there are no writes to memory.
3103 (translate_scalar_reduction_to_array_for_stmt): Insert the
3104 memory reduction statement just after the scalar reduction statement.
3106 * gcc.dg/graphite/interchange-10.c: Updated to differ from interchange-4.c.
3108 * gcc.dg/graphite/interchange-3.c: Un-XFAIL-ed.
3109 * gcc.dg/graphite/interchange-4.c: Un-XFAIL-ed.
3111 2009-10-06 Sebastian Pop <sebastian.pop@amd.com>
3113 * graphite-interchange.c (lst_apply_interchange): New.
3114 (lst_interchange_profitable_p): New.
3115 (lst_try_interchange_loops): New.
3116 (lst_try_interchange): New.
3117 (lst_do_interchange): New.
3118 (pbb_do_interchange): Removed.
3119 (scop_do_interchange): Call lst_do_interchange.
3121 2009-10-06 Sebastian Pop <sebastian.pop@amd.com>
3123 * graphite-poly.c (print_scop): Print SCOP_ORIGINAL_SCHEDULE and
3124 SCOP_TRANSFORMED_SCHEDULE.
3129 * graphite-poly.h (lst_p): New.
3132 (LST_LOOP_FATHER): New.
3135 (scop_to_lst): Declared.
3136 (print_lst): Declared.
3137 (debug_lst): Declared.
3138 (new_lst_loop): New.
3139 (new_lst_stmt): New.
3142 (lst_dewey_number): New.
3143 (struct scop): Add original_schedule and transformed_schedule fields.
3144 (SCOP_ORIGINAL_SCHEDULE): New.
3145 (SCOP_TRANSFORMED_SCHEDULE): New.
3146 * graphite-sese-to-poly.c (build_poly_scop): Call scop_to_lst.
3148 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
3150 * graphite-dependences.c (reduction_ddr): New.
3151 (graphite_legal_transform_bb): Call reduction_ddr.
3152 * graphite-poly.c (new_poly_bb): Pass a new bool parameter.
3153 Initialize PBB_IS_REDUCTION.
3154 * graphite-poly.h (struct poly_bb): New bool field is_reduction.
3155 (PBB_IS_REDUCTION): New.
3156 (new_poly_bb): Update declaration.
3157 * graphite-scop-detection.h (build_scop_bbs): Removed.
3158 (nb_reductions_in_loop): Removed.
3159 * graphite-sese-to-poly.c (try_generate_gimple_bb): Pass a sbitmap
3160 parameter for reductions.
3161 (try_generate_gimple_bb): Update call to new_poly_bb.
3162 (build_scop_bbs_1): Same.
3163 (build_scop_bbs): Same.
3164 (gsi_for_phi_node): New.
3165 (scalar_close_phi_node_p): Remove gcc_assert.
3166 (split_reduction_stmt): New.
3167 (is_reduction_operation_p): New.
3168 (phi_contains_arg): New.
3169 (follow_ssa_with_commutative_ops): New.
3170 (detect_commutative_reduction_arg): New.
3171 (detect_commutative_reduction_assign): New.
3172 (follow_inital_value_to_phi): New.
3173 (edge_initial_value_for_loop_phi): New.
3174 (initial_value_for_loop_phi): New.
3175 (detect_commutative_reduction): New.
3176 (translate_scalar_reduction_to_array_for_stmt): New.
3177 (insert_copyout): New.
3178 (insert_copyin): New.
3179 (translate_scalar_reduction_to_array): New.
3180 (rewrite_commutative_reductions_out_of_ssa_close_phi): New.
3181 (rewrite_commutative_reductions_out_of_ssa_loop): New.
3182 (rewrite_commutative_reductions_out_of_ssa): New.
3183 (build_poly_scop): Call rewrite_commutative_reductions_out_of_ssa.
3184 * sese.h (split_region_for_bb): New.
3186 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK): Add -ffast-math.
3187 * gcc.dg/graphite/interchange-1.c: Fix format.
3188 * gcc.dg/graphite/interchange-10.c: New.
3190 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
3192 * graphite-sese-to-poly.c (insert_out_of_ssa_copy): Remove
3195 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
3197 * graphite-sese-to-poly.c (scev_analyzable_p): New.
3198 (rewrite_cross_bb_scalar_dependence): New.
3199 (rewrite_cross_bb_scalar_deps): New.
3200 (rewrite_reductions_out_of_ssa): Use bb_in_sese_p.
3201 Call rewrite_cross_bb_scalar_deps.
3203 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
3205 * graphite-sese-to-poly.c (gsi_for_ssa_name_def): Removed.
3206 (insert_out_of_ssa_copy): Directly use gsi_after_labels and
3209 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
3211 * graphite-clast-to-gimple.c (build_cloog_prog): Use pbb_index.
3212 * graphite-interchange.c (pbb_do_interchange): Same.
3213 * graphite-poly.c (print_scattering_function): Same.
3215 * graphite-poly.h (pbb_loop): New.
3216 * graphite-sese-to-poly.c (create_linear_expr_from_tree): Use pbb_loop.
3218 2009-09-27 Sebastian Pop <sebastian.pop@amd.com>
3220 * graphite-scop-detection.c (limit_scops): Do not build poly_bbs.
3222 2009-09-27 Sebastian Pop <sebastian.pop@amd.com>
3224 * graphite-sese-to-poly.c (partition_drs_to_sets): Drs is not modified,
3225 so don't pass a pointer to it.
3226 (build_alias_set_for_drs): Same.
3227 (build_base_obj_set_for_drs): Same.
3228 (build_scop_drs): Same.
3230 2009-09-26 Li Feng <nemokingdom@gmail.com>
3232 * graphite-sese-to-poly.c (build_scop_drs): Disable writing to file
3233 the alias graph of data references.
3235 2009-09-25 Li Feng <nemokingdom@gmail.com>
3237 * graphite-sese-to-poly.c (write_alias_graph_to_ascii_dimacs): New.
3238 (build_scop_drs): When debugging, write the alias graph to file,
3239 otherwise, should be disabled.
3241 2009-09-17 Sebastian Pop <sebastian.pop@amd.com>
3243 * Merge from mainline (151310:151361).
3245 2009-09-17 Sebastian Pop <sebastian.pop@amd.com>
3247 * Merge from mainline (151171:151310).
3249 2009-09-17 Sebastian Pop <sebastian.pop@amd.com>
3251 * Merge from mainline (151171:151806).
3253 2009-09-17 Sebastian Pop <sebastian.pop@amd.com>
3255 * Revert the last commit.
3257 2009-09-17 Sebastian Pop <sebastian.pop@amd.com>
3259 * Merge from mainline (151171:151819).
3261 2009-09-17 Sebastian Pop <sebastian.pop@amd.com>
3263 * graphite-scop-detection.c (stmt_simple_memref_p): Removed.
3264 (is_simple_operand): Remove call to stmt_simple_memref_p.
3265 (stmt_simple_for_scop_p): Update call to is_simple_operand.
3267 2009-09-17 David Edelsohn <edelsohn@gnu.org>
3269 * gcc.dg/graphite/interchange-mvt.c: New File.
3270 * gcc.dg/graphite/scop-dsyrk.c: New File.
3271 * gcc.dg/graphite/scop-dsyr2k.c: New File.
3272 * gcc.dg/graphite/scop-mvt.c: New File.
3273 * gcc.dg/graphite/scop-sor.c: New File.
3275 2009-09-17 Li Feng <nemokingdom@gmail.com>
3277 * graphite-dependences.c (poly_drs_may_alias_p): Adjust definition.
3278 (pddr_original_scattering): Make sure 2 pdr2 in the same base object set.
3279 (graphite_carried_dependence_level_k): Ditto.
3280 * graphite-poly.c (new_poly_dr): Add init of PDR_BASE_OBJECT_SET.
3281 * graphite-poly.h (struct poly_dr): Add member dr_base_object_set.
3282 (new_poly_dr): Adjust declaration.
3283 * graphite-sese-to-poly.c (free_data_refs_aux): New.
3284 (free_gimple_bb): Added free_data_refs_aux.
3285 (build_poly_dr): Add dr_base_object_set.
3286 (partition_drs_to_sets): New.
3287 (dr_same_base_object_p): New.
3288 (build_alias_set_for_drs): New.
3289 (build_base_object_set_for_drs): New.
3290 (build_scop_drs): Add build_base_obj_set_for_drs.
3291 * graphite-sese-to-poly.h: Added #define for alias set number index and
3292 base object set index.
3293 * libgomp/testsuite/libgomp.graphite/force-parallel-6.c: Refine tests.
3294 * libgomp/testsuite/libgomp.graphite/pr4118.c: New.
3296 2009-09-16 Alexander Monakov <amonakov@ispras.ru>
3298 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Add bounds only
3299 for ARRAY_REFs. Use array_ref_{low,up}_bound to determine bounds.
3301 2009-09-14 Sebastian Pop <sebastian.pop@amd.com>
3303 * graphite-sese-to-poly.c (struct irp_data): Removed.
3304 (idx_record_params): Removed.
3305 (find_params_in_bb): Scan for parameters the access functions; don't
3306 parse the tree representation.
3308 2009-09-14 Sebastian Pop <sebastian.pop@amd.com>
3310 * tree-ssa-loop.c (gate_graphite_transforms): Disable Graphite
3311 passes at -O1 and below.
3313 2009-09-14 Sebastian Pop <sebastian.pop@amd.com>
3315 * graphite-blocking.c: Fix order of includes: tree-chrec.h, then
3316 tree-scalar-evolution.h, and then tree-data-ref.h.
3317 * graphite-clast-to-gimple.c: Same.
3318 * graphite-dependences.c: Same.
3319 * graphite-interchange.c: Same.
3320 * graphite-poly.c: Same.
3321 * graphite-scop-detection.c: Same.
3322 * graphite-sese-to-poly.c: Same.
3324 * lambda-code.c: Same.
3325 * matrix-reorg.c: Same.
3326 * tree-data-ref.c: Same.
3327 * tree-if-conv.c: Same.
3328 * tree-loop-distribu: Same.: Same.
3329 * tree-loop-linear.c: Same.
3330 * tree-parloops.c: Same.
3331 * tree-predcom.c: Same.
3332 * tree-vect-patterns.c: Same.
3334 2009-09-02 Sebastian Pop <sebastian.pop@amd.com>
3336 Partially revert the previous patch, except the following.
3337 * tree-scalar-evolution.c (instantiate_scev_not): Adapted to pass
3338 as parameters the operands of the not expression.
3340 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
3342 * tree-scalar-evolution.c (instantiate_scev_assign): New.
3343 Do not call analyze_scalar_evolution on assignments.
3344 (instantiate_scev_phi): Call analyze_scalar_evolution.
3345 (instantiate_scev_name): Call instantiate_scev_assign and
3346 instantiate_scev_phi.
3347 (instantiate_scev_not): Adapted to pass as parameters the operands
3348 of the not expression.
3350 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
3352 * tree-scalar-evolution.c (instantiate_scev_binary): Adapted
3353 to pass as parameters the operands of the binary expression.
3355 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
3357 * tree-scalar-evolution.c (instantiate_scev_bitnot): Renamed
3358 instantiate_scev_not. Handle NEGATE_EXPR.
3359 (instantiate_scev_r): Handle NEGATE_EXPR.
3361 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
3363 * tree-scalar-evolution.c (instantiate_scev_1): Renamed
3365 (instantiate_scev_r): Move code in instantiate_scev_2
3366 and instantiate_scev_1.
3368 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
3370 * tree-scalar-evolution.c (instantiate_scev_3): New.
3371 (instantiate_scev_1): Move code in instantiate_scev_3.
3373 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
3375 * tree-scalar-evolution.c (instantiate_scev_poly): New.
3376 (instantiate_scev_1): Move code in instantiate_scev_poly.
3378 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
3380 * tree-scalar-evolution.c (instantiate_scev_bitnot): New.
3381 (instantiate_scev_1): Move code in instantiate_scev_bitnot.
3383 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
3385 * tree-scalar-evolution.c (instantiate_scev_convert): New.
3386 (instantiate_scev_1): Move code in instantiate_scev_convert.
3388 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
3390 * tree-scalar-evolution.c (instantiate_scev_binary): New.
3391 (instantiate_scev_1): Move code in instantiate_scev_binary.
3393 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
3395 * tree-scalar-evolution.c (instantiate_scev_name): New.
3396 (instantiate_scev_1): Move code in instantiate_scev_name.
3398 2009-08-28 Sebastian Pop <sebastian.pop@amd.com>
3400 * Merge from mainline (150992:151171).
3402 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
3404 * opts.c (decode_options): Enable flag_loop_interchange at -O2.
3406 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
3408 * graphite-dependences.c (graphite_legal_transform_bb): Call
3409 pbb_remove_duplicate_pdrs.
3410 * graphite-poly.c (can_collapse_pdr): Removed.
3411 (pdr_find_duplicate): Removed.
3412 (can_collapse_pdrs): New.
3413 (pbb_remove_duplicate_pdrs): New.
3414 (new_poly_dr): Do not look for duplicates.
3415 * graphite-poly.h (struct poly_bb): New field pdr_duplicates_removed.
3416 (PBB_PDR_DUPLICATES_REMOVED): New.
3417 (pbb_remove_duplicate_pdrs): Declared.
3419 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
3421 * graphite-interchange.c (pbb_interchange_profitable_p): Adjust
3422 the strides by multiplying by PDR_NB_REFS.
3423 * graphite-poly.c (can_collapse_pdr): New.
3424 (pdr_find_duplicate): New.
3425 (new_poly_dr): Call pdr_find_duplicate. Collapse duplicate PDRs.
3426 Initialize PDR_NB_REFS.
3427 * graphite-poly.h (struct poly_dr): Add field nb_refs.
3429 (new_poly_dr): Number of subscripts is a graphite_dim_t.
3431 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
3433 Revert one of the previous commits:
3434 * graphite-dependences.c (graphite_legal_transform_bb): Avoid
3435 the computation of symmetric data dependence relations.
3436 (dependency_between_pbbs_p): Same.
3438 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
3441 * graphite-poly.c (apply_poly_transforms): Remove legality test before
3444 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
3446 * graphite-dependences.c (pddr_original_scattering): Return NULL
3447 for read-read dependence relations.
3448 * graphite-poly.h (enum poly_dr_type): Fix comment.
3451 (pdr_may_write_p): New.
3453 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
3455 * graphite-poly.h (enum POLY_DR_TYPE): Renamed poly_dr_type.
3456 (struct poly_dr): Same.
3457 (new_poly_dr): Same.
3458 * graphite-poly.c (new_poly_dr): Same.
3460 2009-08-25 Konrad Trifunovic <konrad.trifunovic@gmail.com>
3461 Sebastian Pop <sebastian.pop@amd.com>
3463 * graphite-blocking.c (pbb_strip_mine_loop_depth): Renamed
3464 pbb_strip_mine_time_depth. Changed the implementation so that
3465 transformation is expressed as a transformation on
3466 time (scatttering) dimensions. Also, ensures that the 2d+1
3467 scheduling format is preserved.
3468 (pbb_strip_mine_profitable_p): Profitability is based on the
3469 iteration number of a given time (scattering) dimension,
3470 and not on a original loop depth dimension.
3471 (pbb_strip_mine): Call pbb_number_of_iterations_at_time.
3472 (pbb_do_strip_mine): Call psct_dynamic_dim.
3473 * graphite-poly.c (pbb_number_of_iterations_at_time): New.
3474 * graphite-poly.h (pbb_number_of_iterations_at_time): Declared.
3475 (pbb_nb_dynamic_scattering_transform): New.
3476 (psct_dynamic_dim): New.
3478 2009-08-25 Konrad Trifunovic <konrad.trifunovic@gmail.com>
3480 * graphite-ppl.c (ppl_max_for_le): Renamed ppl_max_for_le_pointset.
3481 * graphite-ppl.h (ppl_max_for_le): Renamed ppl_max_for_le_pointset.
3482 * graphite-poly.c (pbb_number_of_iterations): Rename ppl_max_for_le.
3483 * graphite-interchange.c (build_linearized_memory_access): Same.
3484 (memory_stride_in_loop): Same.
3486 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
3488 * graphite-dependences.c (pddr_original_scattering): New.
3489 (graphite_legal_transform_dr): Call pddr_original_scattering.
3492 * graphite-dependences.h (dot_deps): Declared.
3493 * graphite-poly.c (new_poly_dr): Initialize PDR_ID.
3494 (print_pdr): Print PDR_ID.
3495 * graphite-poly.h (struct poly_dr): Add field id.
3498 * graphite-scop-detection.c (dot_all_scops_1): Cleanup comment.
3500 2009-08-22 Sebastian Pop <sebastian.pop@amd.com>
3502 * graphite-dependences.c (graphite_carried_dependence_level_k): Do
3503 not delete the original dependence relation.
3505 2009-08-21 Sebastian Pop <sebastian.pop@amd.com>
3507 * graphite-dependences.c (graphite_legal_transform_bb): Avoid
3508 the computation of symmetric data dependence relations.
3509 (dependency_between_pbbs_p): Same.
3511 2009-08-21 Sebastian Pop <sebastian.pop@amd.com>
3513 * graphite-dependences.c (new_poly_dr_pair): Renamed new_poly_ddr.
3514 (eq_poly_dr_pair_p): Renamed eq_poly_ddr_p.
3515 (hash_poly_dr_pair_p): Renamed hash_poly_ddr_p.
3516 (free_poly_ddr): New.
3517 (pddr_is_empty): New.
3518 (dependence_polyhedron_1): Now returns a poly_ddr_p.
3519 (dependence_polyhedron): Same. Remove useless gcc_assert.
3521 (graphite_legal_transform_dr): Call pddr_is_empty and free_poly_ddr.
3522 (graphite_carried_dependence_level_k): Call pddr_is_empty.
3523 * graphite-dependences.h (enum poly_dependence_kind): New.
3524 (poly_dr_pair): Renamed poly_ddr. Added a field kind.
3525 (PDRP_SOURCE): Renamed PDDR_SOURCE.
3526 (PDRP_SINK): Renamed PDDR_SINK.
3527 (PDRP_DDP): Renamed PDDR_DDP.
3529 (free_poly_ddr): Declared.
3530 * graphite-poly.c (new_scop): Use the new hash function names.
3531 * graphite-poly.h (struct scop): Renamed field original_pdr_pairs
3532 into original_pddrs.
3533 (SCOP_ORIGINAL_PDR_PAIRS): Renamed SCOP_ORIGINAL_PDDRS.
3535 2009-08-21 Sebastian Pop <sebastian.pop@amd.com>
3537 * Merge from mainline (150764:150992).
3539 2009-08-18 Sebastian Pop <sebastian.pop@amd.com>
3541 * cfgloopmanip.c (create_empty_loop_on_edge): Generate upper
3542 bounds with LT_EXPR to make niter analysis more precise on code
3543 generated by Graphite.
3545 2009-08-18 Sebastian Pop <sebastian.pop@amd.com>
3547 * graphite-dependences.c (graphite_legal_transform_dr): Fix formatting.
3548 (graphite_legal_transform_bb): Same.
3549 (poly_drs_may_alias_p): Same.
3551 2009-08-15 Sebastian Pop <sebastian.pop@amd.com>
3554 * graphite-ppl.c (ppl_max_for_le): Correct the use of
3555 ppl_Pointset_Powerset_C_Polyhedron_maximize.
3557 2009-08-13 Sebastian Pop <sebastian.pop@amd.com>
3559 * graphite-poly.c (print_pbb): Print PBB index.
3561 2009-08-13 Sebastian Pop <sebastian.pop@amd.com>
3563 * Merge from mainline (r150672:150764).
3565 2009-08-13 Sebastian Pop <sebastian.pop@amd.com>
3567 * graphite-interchange.c (ppl_max_for_le): Moved...
3568 * graphite-poly.c (pbb_number_of_iterations): Call ppl_max_for_le.
3569 * graphite-ppl.c (ppl_max_for_le): ... here.
3570 * graphite-ppl.h (ppl_max_for_le): Declared.
3572 2009-08-12 Sebastian Pop <sebastian.pop@amd.com>
3574 * Merge from mainline (r150372:150672).
3576 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
3579 * sese.c (convert_for_phi_arg): New.
3580 (add_guard_exit_phis): Use convert_for_phi_arg.
3582 * gfortran.dg/graphite/id-17.f: New.
3584 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
3586 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Dont add
3587 unknown subscript upper bounds.
3589 * gcc.dg/graphite/interchange-6.c: Un-XFAIL.
3591 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
3592 Pranav Garg <pranav.garg2107@gmail.com>
3594 * graphite-interchange.c (gather_access_strides): Removed.
3595 (ppl_max_for_le): New.
3596 (build_linearized_memory_access): New.
3597 (memory_stride_in_loop): New.
3598 (pbb_interchange_profitable_p): Reimplemented.
3599 * graphite-ppl.h (ppl_new_id_map): New.
3600 (ppl_interchange): New.
3602 * gcc.dg/graphite/interchange-6.c: XFAILed.
3604 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
3606 * graphite-interchange.c (compute_subscript): Removed.
3607 (compute_array_size_cstr): Removed.
3608 (compute_array_size_poly): Removed.
3609 (compute_array_size): Removed.
3610 (gather_access_strides_poly): Removed.
3611 (gather_access_strides): Empty.
3613 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
3615 * graphite-dependences.c (dependence_polyhedron_1): Replace
3616 pdr_nb_subscripts with PDR_NB_SUBSCRIPTS.
3617 (graphite_legal_transform_dr): Same.
3618 (graphite_carried_dependence_level_k): Same.
3619 * graphite-poly.c (new_poly_dr): Add a parameter nb_subscripts.
3620 Initialize PDR_NB_SUBSCRIPTS.
3621 (print_pdr_access_layout): Replace pdr_nb_subscripts with
3623 * graphite-poly.h (struct poly_dr): Add nb_subscripts field.
3624 (PDR_NB_SUBSCRIPTS): New.
3625 (pdr_nb_subscripts): Removed.
3626 (pdr_dim): Simplified.
3627 * graphite-sese-to-poly.c (build_poly_dr): Replace pdr_nb_subscripts
3628 with PDR_NB_SUBSCRIPTS.
3630 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
3632 * graphite-interchange.c (compute_array_size): Remove use of
3634 * graphite-poly.c (new_poly_dr): Remove argument data_container.
3635 Do not initialize PDR_DATA_CONTAINER.
3636 (print_pdr): Do not print PDR_DATA_CONTAINER.
3637 * graphite-poly.h (struct poly_dr): Remove data_container field.
3638 (PDR_DATA_CONTAINER): Removed.
3639 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Remove use of
3641 (build_poly_dr): Same.
3643 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
3645 * gcc.dg/graphite/interchange-9.c: New.
3647 2009-08-05 Konrad Trifunovic <konrad.trifunovic@gmail.com>
3648 Sebastian Pop <sebastian.pop@amd.com>
3650 * graphite-dependences.c (graphite_legal_transform_dr): Work on a
3651 copy of the dependence polyhedron. Free the temporary objects.
3652 (graphite_carried_dependence_level_k): Free unused objects before
3655 * gcc.dg/graphite/interchange-1.c: XFAILed.
3656 * gcc.dg/graphite/interchange-2.c: XFAILed.
3657 * gcc.dg/graphite/interchange-3.c: XFAILed.
3658 * gcc.dg/graphite/interchange-4.c: XFAILed.
3659 * gcc.dg/graphite/interchange-7.c: XFAILed.
3661 2009-08-05 Sebastian Pop <sebastian.pop@amd.com>
3663 * graphite-blocking.c (scop_do_strip_mine): Call store_scattering.
3664 Early return without analyzing the data dependences if no
3665 transform has been done. Call restore_scattering if the transform
3667 (graphite-interchange.c): Same.
3668 * graphite-poly.c (print_scattering_function): Test for PBB_TRANSFORMED.
3669 (graphite_read_transforms): Initialize PBB_TRANSFORMED.
3670 (apply_poly_transforms): Do not gcc_assert that
3671 the transform is legal.
3672 (new_poly_bb): Initialize PBB_TRANSFORMED, PBB_SAVED, and PBB_ORIGINAL.
3673 Do not initialize PBB_NB_SCATTERING_TRANSFORM, PBB_NB_LOCAL_VARIABLES,
3674 PBB_TRANSFORMED_SCATTERING, and PBB_ORIGINAL_SCATTERING.
3675 (free_poly_dr): Free PBB_TRANSFORMED, PBB_SAVED, and PBB_ORIGINAL.
3676 * graphite-poly.h (struct poly_scattering): New.
3677 (struct poly_bb): Add original, transformed, and saved fields.
3678 Remove transformed_scattering, original_scattering, nb_local_variables,
3679 and nb_scattering_transform fields.
3680 (PBB_ORIGINAL, PBB_TRANSFORMED, PBB_SAVED): New.
3681 (poly_scattering_new): New.
3682 (poly_scattering_free): New.
3683 (poly_scattering_copy): New.
3684 (store_scattering_pbb): New.
3685 (store_scattering): New.
3686 (restore_scattering_pbb): New.
3687 (restore_scattering): New.
3688 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons):
3689 Initialize PBB_TRANSFORMED and PBB_ORIGINAL.
3691 2009-08-05 Sebastian Pop <sebastian.pop@amd.com>
3693 * graphite-poly.c (print_pbb): Add parentheses in the pretty print.
3696 2009-08-05 Sebastian Pop <sebastian.pop@amd.com>
3698 * Makefile.in (graphite.o): Depends on PREDICT_H.
3699 * graphite.c: Include predict.h.
3700 (graphite_finalize): Call tree_estimate_probability.
3701 * predict.c (predict_loops): Do not call scev_initialize and
3703 (tree_estimate_probability_bb): New.
3704 (tree_estimate_probability): Do not initialize loops: move that
3705 code to the driver. Call tree_estimate_probability_bb.
3706 (tree_estimate_probability_driver): New.
3707 (pass_profile): Use tree_estimate_probability_driver.
3708 * predict.h (tree_estimate_probability): Declared.
3710 2009-08-05 Sebastian Pop <sebastian.pop@amd.com>
3712 * graphite-clast-to-gimple.c (gloog): Add time to TV_GRAPHITE_CODE_GEN.
3713 * graphite-dependences.c (graphite_legal_transform): Add time to
3714 TV_GRAPHITE_DATA_DEPS.
3715 (dependency_between_pbbs_p): Same.
3716 * timevar.def (TV_GRAPHITE_DATA_DEPS, TV_GRAPHITE_CODE_GEN): New.
3718 2009-08-03 Sebastian Pop <sebastian.pop@amd.com>
3720 * Merge from mainline (r149952:150372).
3722 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
3724 * ChangeLog.graphite: Fix indenting, white spaces and 80 columns.
3725 * graphite-blocking.c: Same.
3726 * graphite-clast-to-gimple.c: Same.
3727 * graphite-dependences.c: Same.
3728 * graphite-poly.c: Same.
3729 * graphite-poly.h: Same.
3730 * graphite-ppl.c: Same.
3731 * graphite-scop-detection.c: Same.
3732 * graphite-sese-to-poly.c: Same.
3735 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
3737 * graphite-sese-to-poly.c (loop_entry_phi_arg): New.
3738 (remove_simple_copy_phi): New.
3739 (remove_invariant_phi): New.
3740 (simple_copy_phi_p): New.
3741 (reduction_phi_p): New.
3742 (gsi_for_ssa_name_def): New.
3743 (insert_out_of_ssa_copy): New.
3744 (insert_out_of_ssa_copy_on_edge): New.
3745 (create_zero_dim_array): New.
3746 (scalar_close_phi_node_p): New.
3747 (rewrite_close_phi_out_of_ssa): New.
3748 (rewrite_phi_out_of_ssa): New.
3749 (rewrite_reductions_out_of_ssa): New.
3750 (build_poly_scop): Call rewrite_reductions_out_of_ssa.
3752 * gcc.dg/graphite/id-11.c: New.
3753 * gcc.dg/graphite/id-15.c: New.
3754 * gcc.dg/graphite/interchange-1.c: Un-XFAIL.
3755 * gcc.dg/graphite/interchange-2.c: Un-XFAIL.
3756 * gcc.dg/graphite/interchange-3.c: Un-XFAIL.
3757 * gcc.dg/graphite/interchange-4.c: Un-XFAIL.
3758 * gcc.dg/graphite/interchange-7.c: Un-XFAIL.
3759 * gcc.dg/graphite/scop-matmult.c: Un-XFAIL.
3760 * gfortran.dg/graphite/id-13.f: New.
3761 * gfortran.dg/graphite/id-5.f: New.
3763 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
3765 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not
3766 check that nb_reductions_in_loop is zero.
3767 * graphite-scop-detection.c (harmful_stmt_in_bb): Don't filter out
3768 reduction phi nodes.
3769 (nb_reductions_in_loop): Removed.
3770 (graphite_can_represent_loop): Do not call nb_reductions_in_loop.
3771 * graphite-sese-to-poly.c (phi_node_is_iv): Removed.
3772 (bb_contains_non_iv_scalar_phi_nodes): Removed.
3773 (scop_contains_non_iv_scalar_phi_nodes): Removed.
3774 (build_poly_scop): Do not call scop_contains_non_iv_scalar_phi_nodes.
3776 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
3778 * graphite-clast-to-gimple.c (build_cloog_prog): Do not code generate
3779 statements that have an empty iteration domain.
3780 * gfortran.dg/graphite/id-16.f: New.
3782 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
3784 * tree-scalar-evolution.c (instantiate_scev_1): Return
3785 chrec_dont_know when the result is not above instantiate_below.
3786 * graphite-scop-detection.c (scopdet_basic_block_info): Fix formatting.
3787 * graphite-sese-to-poly.c (create_linear_expr_from_tree): Assert that
3788 the tree has a known scalar evolution.
3789 * gfortran.dg/graphite/id-14.f: New.
3790 * gfortran.dg/graphite/id-15.f: New.
3792 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
3794 * sese.c (rename_variables_in_stmt): Pass in an extra parameter
3796 (rename_variables): Keep inserting renames after the ones already
3799 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
3801 * graphite-sese-to-poly.c (compare_bb_depths): New.
3802 (graphite_sort_dominated_info): New.
3803 (build_scop_bbs_1): Call graphite_sort_dominated_info.
3804 (build_scop_scattering): Fix comment.
3806 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
3808 * graphite.c (graphite_finalize): Call print_loops instead of
3809 dump_function_to_file.
3810 * gcc.dg/graphite/graphite.exp: Fix formatting.
3811 * gcc.dg/graphite/pr35356-1.c: New. Look for the number of
3812 loops generated in the graphite output file.
3813 * gcc.dg/graphite/pr35356-2.c: New.
3814 * gcc.dg/graphite/pr35356-3.c: New. XFAILed for now.
3815 * gfortran.dg/graphite/id-12.f: New.
3817 2009-07-24 Li Feng <nemokingdom@gmail.com>
3819 * gcc.dg/graphite/graphite_autopar/force-parallel-8.c:
3822 2009-07-24 Li Feng <nemokingdom@gmail.com>
3823 Tobias Grosser <grosser@fim.uni-passau.de>
3825 * graphite-sese-to-poly.c (pdr_add_alias_set): Use data reference's
3826 alias set number build alias in ACCESSES polyhedron.
3827 (build_alias_set_for_drs): New.
3828 (build_pbb_drs): Added build_alias_set_for_drs.
3829 * graphite-dependences.c (poly_drs_may_alias_p): New.
3830 (graphite_carried_dependence_level_k): Check alias information
3831 before building polyhedron.
3833 2009-07-24 Tobias Grosser <grosser@fim.uni-passau.de>
3835 * Makefile.in (lambda-code.o): Fix formatting.
3837 2009-07-24 Tobias Grosser <grosser@fim.uni-passau.de>
3839 * Merge from mainline (r149350-149952)
3841 2009-07-18 Tobias Grosser <grosser@fim.uni-passau.de>
3843 * graphite-poly.c (apply_poly_transforms): Move strip_mine
3844 before interchange to prepare for loop blocking.
3846 2009-07-18 Tobias Grosser <grosser@fim.uni-passau.de>
3848 * graphite-poly.c (apply_poly_transforms): Add checks after every
3850 * graphite-sese-to-poly.c (build_poly_scop): Remove check, as already
3851 done in apply_poly_transforms.
3853 2009-07-17 Konrad Trifunovic <konrad.trifunovic@gmail.com>
3855 * graphite-dependences.c (build_lexicographically_gt_constraint):
3856 Replace RES parameter with *RES.
3857 (dependence_polyhedron_1): Pass an address of the parameter RES
3858 instead of value of RES.
3860 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
3862 * graphite.c (graphite_finalize): Fix comment.
3863 (graphite_transform_loops): Reset scev info after code generation
3866 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
3868 * graphite.c (graphite_finalize): Call scev_reset.
3870 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
3872 * graphite-clast-to-gimple.c (compute_cloog_iv_types): Do not create
3873 GBB_CLOOG_IV_TYPES hash table twice.
3874 * graphite-sese-to-poly.c (free_gimple_bb): Call free_data_refs.
3875 (add_condition_to_domain): Clear GMP values.
3877 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
3879 * graphite-dependences.c: Fix formatting.
3880 * graphite-poly.c (free_poly_dr): Also free PDR_DATA_CONTAINER.
3881 (pbb_number_of_iterations): Free ppl_Linear_Expression.
3882 * graphite-sese-to-poly.c: Fix formatting.
3883 * graphite.c (graphite_transform_loops): Create the hash table
3884 after the early return.
3886 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
3888 * gcc.dg/graphite/id-14.c: New.
3889 * gcc.dg/graphite/pr40157.c: New.
3890 * gfortran.dg/graphite/id-11.f: New.
3892 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
3894 * graphite-sese-to-poly.c (nb_pbbs_in_loops): New.
3895 (build_poly_scop): Return false when there are no pbbs within
3896 loops to avoid to pass to cloog scops with no loops.
3898 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
3900 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons): Avoid
3901 useless test "i % 2".
3902 (build_pbb_scattering_polyhedrons): Fix formatting.
3903 (build_poly_dr): Same.
3904 * graphite.c (graphite_transform_loops): Restructure.
3906 2009-07-14 Razya Ladelsky <razya@il.ibm.com>
3908 * tree-ssa-loop-manip.c (rewrite_phi_with_iv): Remove
3909 reduction_list parameter.
3910 (rewrite_all_phi_nodes_with_iv): Same.
3911 (canonicalize_loop_ivs): Same.
3912 * tree-parloops.c (struct brli): Removed.
3913 (build_reduction_list_info): Removed.
3914 (build_new_reduction): New.
3915 (analyze_reduction_list): Removed.
3916 (gather_scalar_reductions): Find reductions instead of phi
3917 nodes that can't be canonicalized.
3918 (try_create_reduction_list): Remove reduction_list parameter.
3919 (gen_parallel_loop): Same.
3920 (parallelize_loops): Remove analyze_reductions variable,
3921 initialization and free.
3922 Change reduction_list htab initialization to reduction_info
3923 elements instead of ssa names.
3924 Call try_create_reduction_list and gen_parallel_loop without
3925 analyzed_reduction argument.
3926 * graphite-clast-to-gimple (graphite_loop_normal_form): Call
3927 canonicalize_loop_ivs with one less argument.
3928 * tree-flow.h (canonicalize_loop_ivs): Remove one argument.
3930 2009-07-14 Konrad Trifunovic <konrad.trifunovic@gmail.com>
3932 * graphite-dependences.c (new_poly_dr_pair): New.
3933 (dependence_polyhedron): Renamed into dependence_polyhedron_1.
3934 (new_poly_dr_pair): New.
3935 (eq_poly_dr_pair_p): New.
3936 (hash_poly_dr_pair_p): New.
3937 * graphite-dependences.h (struct poly_dr_pair): New.
3938 (eq_poly_dr_pair_p): Declared.
3939 (hash_poly_dr_pair_p): Declared.
3940 * graphite-poly.c (new_scop): Initialize SCOP_ORIGINAL_PDR_PAIRS.
3941 (free_scop): Free SCOP_ORIGINAL_PDR_PAIRS.
3942 * graphite-poly.h (struct scop): Add original_pdr_pairs field.
3943 * Makefile.in (graphite-poly.o): Add dependence on
3944 graphite-dependences.h.
3946 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
3948 * graphite-scop-detection.c (graphite_can_represent_scev): Do not let
3949 polynomials of degree > 1 pass to Graphite.
3950 * tree-chrec.c (scev_is_linear_expression): Call
3951 evolution_function_is_affine_multivariate_p.
3952 * gfortran.dg/graphite/id-10.f90: New.
3954 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
3956 * tree-scalar-evolution.c (compute_overall_effect_of_inner_loop):
3957 Instantiate scevs varying in outer loops.
3958 * gfortran.dg/graphite/id-9.f: Correct testcase.
3960 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
3962 * graphite-sese-to-poly.c (build_loop_iteration_domains): Do not insert
3963 redundant constraint.
3965 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
3967 * gcc.dg/graphite/graphite.exp: Fix comments.
3968 * gfortran.dg/graphite/graphite.exp: Trigger actions
3969 based on the file names as in the C testsuite.
3970 * gfortran.dg/graphite/block-1.f90: Fix patterns.
3971 * gfortran.dg/graphite/block-2.f: Same.
3972 * gfortran.dg/graphite/block-3.f90: Same.
3973 * gfortran.dg/graphite/block-4.f90: Same.
3974 * gfortran.dg/graphite/id-1.f90: Same.
3975 * gfortran.dg/graphite/id-2.f90: Same.
3976 * gfortran.dg/graphite/id-3.f90: Same.
3977 * gfortran.dg/graphite/id-4.f90: Same.
3978 * gfortran.dg/graphite/id-6.f: Same.
3979 * gfortran.dg/graphite/id-9.f: Same.
3980 * gfortran.dg/graphite/interchange-1.f: Same.
3981 * gfortran.dg/graphite/interchange-2.f: Same.
3982 * gfortran.dg/graphite/scop-1.f: Same.
3984 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
3986 * sese.c (expand_scalar_variables_call): New.
3987 (expand_scalar_variables_ssa_name): Handle calls in expander.
3989 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
3991 * gcc.dg/graphite/graphite_autopar/force-parallel-6.c:
3992 Expect to see the pattern twice.
3993 * gcc.dg/graphite/interchange-0.c: Un-XFAIL.
3994 * gcc.dg/graphite/interchange-5.c: Same.
3995 * gcc.dg/graphite/interchange-6.c: Same.
3997 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
3999 * gcc.dg/graphite/id-10.c: New.
4000 * gcc.dg/graphite/id-12.c: New.
4001 * gfortran.dg/graphite/id-7.f: New.
4002 * gfortran.dg/graphite/id-8.f: New.
4004 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
4006 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Fix division by
4009 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
4011 * sese.c (rename_variables_in_stmt): Call fold_convert during renaming.
4013 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
4015 * sese.c (expand_scalar_variables_stmt): Avoid unnecessary expansion.
4017 2009-07-10 Sebastian Pop <sebastian.pop@amd.com>
4019 * graphite-sese-to-poly.c (pdr_add_memory_accesses): Fix order of
4020 building PDR subscripts.
4022 2009-07-10 Sebastian Pop <sebastian.pop@amd.com>
4024 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Fix the
4025 computation of array sizes.
4027 2009-07-10 Sebastian Pop <sebastian.pop@amd.com>
4029 * graphite-sese-to-poly.c (add_param_constraints): Disabled.
4031 2009-07-10 Tobias Grosser <grosser@fim.uni-passau.de>
4033 * graphite-dependences.c (map_into_dep_poly, map_dr_into_dep_poly,
4034 build_pairwise_constraint, dr_equality_constraints,
4035 build_pairwise_scheduling_equality,
4036 build_pairwise_scheduling_inequality, lexicographically_gt_p,
4037 build_lexicographically_gt_constraint, dependence_polyhedron,
4038 graphite_legal_transform_dr, graphite_carried_dependence_level_k):
4039 Move from NNC_Polyhedron to C_Polyhedron.
4040 * graphite-interchange.c (compute_array_size_poly,
4041 gather_access_strides): Dito.
4042 * graphite-poly.c (apply_poly_transforms, new_poly_dr, free_poly_bb,
4043 free_scop, pbb_number_of_iterations): Dito.
4044 * graphite-poly.h (struct poly_dr, pdr_nb_subscripts, struct poly_bb,
4045 pbb_dim_iter_domain, struct scop): Dito.
4046 * graphite-ppl.c (new_Constraint_System_from_Cloog_Matrix,
4047 new_Cloog_Domain_from_ppl_Polyhedron,
4048 new_Cloog_Domain_from_ppl_Pointset_Powerset, ppl_set_coef_gmp,
4049 ppl_insert_dimensions_pointset, ppl_insert_dimensions_pointset,
4050 ppl_strip_loop, ppl_strip_loop, ppl_print_polyhedron_matrix,
4051 ppl_print_powerset_matrix, debug_ppl_polyhedron_matrix,
4052 debug_ppl_powerset_matrix, ppl_read_polyhedron_matrix): Dito.
4053 * graphite-ppl.h (ppl_Pointset_Powerset_C_Polyhedron_t,
4054 new_C_Polyhedron_from_Cloog_Matrix, ppl_print_powerset_matrix,
4055 debug_ppl_powerset_matrix, ppl_insert_dimensions_pointset): Dito.
4056 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons,
4057 build_loop_iteration_domains, ppl_constraint_type_from_tree_code,
4058 add_condition_to_domain, add_condition_to_pbb, build_scop_context,
4059 build_scop_iteration_domain, build_poly_dr): Dito
4061 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
4063 * gcc.dg/graphite/graphite.exp: Added a rule to execute
4065 * gcc.dg/graphite/run-id-1.c: New.
4067 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
4069 * graphite-sese-to-poly.c (build_loop_iteration_domains): Add the
4070 positivity constraint on the symbolic number of iterations.
4072 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
4074 * graphite-sese-to-poly.c (build_loop_iteration_domains): Rewrite.
4076 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
4077 Tobias Grosser <grosser@fim.uni-passau.de>
4079 * graphite-clast-to-gimple.c (build_scop_context): Removed.
4080 (build_cloog_prog): Directly use SCOP_CONTEXT.
4081 * graphite-poly.c (new_scop): Initialize SCOP_CONTEXT.
4082 (free_scop): Free SCOP_CONTEXT.
4083 (print_scop_context): New.
4084 (print_scop): Call print_scop_context.
4085 (debug_scop_context): New.
4086 * graphite-poly.h (print_scop_context, debug_scop_context): Declared.
4087 (struct scop): Added field context.
4088 (SCOP_CONTEXT): New.
4089 * graphite-sese-to-poly.c (add_param_constraints): New.
4090 (build_scop_context): New.
4091 (build_poly_scop): Call build_scop_context.
4093 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
4095 * graphite-clast-to-gimple.c (gmp_cst_to_tree): Moved...
4096 * graphite-ppl.c (ppl_set_inhomogeneous_gmp, ppl_set_coef_gmp): New.
4097 (ppl_set_inhomogeneous, ppl_set_coef): Moved...
4098 * graphite-ppl.h: Include double-int.h and tree.h.
4099 (ppl_set_inhomogeneous_gmp, ppl_set_coef_gmp): Declared.
4100 (ppl_set_inhomogeneous, ppl_set_coef): ...here.
4101 (gmp_cst_to_tree): ...here. Reimplemented using mpz_get_double_int.
4102 (tree_int_to_gmp, ppl_set_inhomogeneous_tree, ppl_set_coef_tree): New.
4104 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
4106 * graphite-clast-to-gimple.c (clast_to_gcc_expression_red): Generate
4107 POINTER_PLUS_EXPR for pointer types.
4108 (clast_to_gcc_expression): Same.
4110 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
4112 * graphite-poly.c (print_scattering_function): Early return when
4113 PBB_TRANSFORMED_SCATTERING is not initialized.
4114 (print_pbb_domain): Early return when PBB_DOMAIN is not initialized.
4116 2009-07-08 Sebastian Pop <sebastian.pop@amd.com>
4118 * tree-parloops.c (analyze_reduction_list): Remove unused variable
4121 2009-07-08 Razya Ladelsky <razya@il.ibm.com>
4123 * tree-parloops.c (analyze_reduction_list): Change return
4125 (try_create_reduction_list): Move the call to
4126 analyze_reduction_list to the beginining.
4127 Call reduction_phi with analyzed_reductions as argument
4128 instead of reduction_list.
4130 2009-07-08 Tobias Grosser <grosser@fim.uni-passau.de>
4132 * Merge from mainline (r148296:149346)
4134 2009-07-07 Sebastian Pop <sebastian.pop@amd.com>
4136 * graphite-scop-detection.c (graphite_can_represent_init): New.
4137 (graphite_can_represent_scev): Call graphite_can_represent_init:
4138 check that the initial value does not contain multiplications of
4140 (stmt_has_simple_data_refs_p): New.
4141 (stmt_simple_for_scop_p): Call stmt_simple_for_scop_p.
4142 (is_simple_operand): Fix formatting.
4143 * graphite-sese-to-poly.c (try_generate_gimple_bb): Fix formatting.
4145 2009-07-07 Sebastian Pop <sebastian.pop@amd.com>
4147 * gcc.dg/graphite/id-13.c: New.
4148 * graphite-sese-to-poly.c (graphite_stmt_p): Do not call
4149 analyze_scalar_evolution, use scalar_evolution_in_region.
4150 (scan_tree_for_params_right_scev): Add extra assert.
4151 (parameter_index_in_region_1): Split from parameter_index_in_region.
4152 (idx_record_params): Use scalar_evolution_in_region.
4153 (find_params_in_bb): Same.
4154 (find_scop_parameters): Same.
4155 (build_loop_iteration_domains): Same.
4156 (create_linear_expr_from_tree): Same.
4157 * sese.c (scalar_evolution_in_region): New.
4158 * sese.h (scalar_evolution_in_region): Declared.
4159 (defined_in_sese_p): New.
4160 * tree-scalar-evolution.c (compute_overall_effect_of_inner_loop): Not
4162 * tree-scalar-evolution.h (compute_overall_effect_of_inner_loop):
4165 2009-07-07 Sebastian Pop <sebastian.pop@amd.com>
4167 * Makefile.in: Replace dependences on tree-chrec.h with SCEV_H.
4168 TREE_DATA_REF_H also implies SCEV_H.
4170 2009-07-07 Sebastian Pop <sebastian.pop@amd.com>
4172 * graphite-poly.c (print_scop_params): New.
4173 (print_scop): Call print_scop_params.
4174 (debug_scop_params): New.
4175 * graphite-poly.h (print_scop_params, debug_scop_params): Declared.
4177 2009-07-07 Li Feng <nemokingdom@gmail.com>
4179 * gcc.dg/graphite/graphite_autopar/force-parallel-4.c: New.
4180 * gcc.dg/graphite/graphite_autopar/force-parallel-5.c: New.
4181 * gcc.dg/graphite/graphite_autopar/force-parallel-6.c: New.
4182 * gcc.dg/graphite/graphite_autopar/force-parallel-7.c: New.
4183 * gcc.dg/graphite/graphite_autopar/force-parallel-8.c: New.
4184 * gcc.dg/graphite/graphite_autopar/force-parallel-9.c: New.
4186 2009-07-07 Li Feng <nemokingdom@gmail.com>
4188 * graphite-clast-to-gimple.c (mark_loops_parallel): Dump information
4189 for dependency checking part.
4190 * gcc.dg/graphite/graphite_autopar/force-parallel-1.c: Add
4191 tests for dependency checking.
4192 * gcc.dg/graphite/graphite_autopar/force-parallel-2.c: Ditto.
4193 * gcc.dg/graphite/graphite_autopar/force-parallel-3.c: Ditto.
4194 * gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: Add
4195 flag -fdump-tree-graphite-all for autopar testsuites.
4197 2009-07-06 Sebastian Pop <sebastian.pop@amd.com>
4199 * Makefile.in (tree-ssa-loop-manip.o): Depends on langhooks.h.
4200 * tree-parloops.c (rewrite_phi_with_iv, rewrite_all_phi_nodes_with_iv,
4201 canonicalize_loop_ivs): Moved...
4202 * tree-ssa-loop-manip.c: ... here. Include langhooks.h.
4204 2009-07-06 Sebastian Pop <sebastian.pop@amd.com>
4206 * tree-parloops.c (try_create_reduction_list): Pass an extra
4207 argument analyzed_reductions. Call analyze_reduction_list.
4208 (gen_parallel_loop): Do not call analyze_reduction_list.
4209 (parallelize_loops): Init and finalize analyzed_reductions.
4211 2009-07-06 Li Feng <nemokingdom@gmail.com>
4213 * gcc.dg/graphite/graphite_autopar/graphite_autopar.exp:
4214 Added flag -fno-loop-strip-mine for autopar testcase.
4216 2009-07-04 Li Feng <nemokingdom@gmail.com>
4218 * graphite-dependences.c (graphite_carried_dependence_level_k): Use
4219 transformed scattering dimension instead of unmatch orignal when
4220 calling dependence_polyhedron.
4222 2009-06-30 Sebastian Pop <sebastian.pop@amd.com>
4224 * opts.c (decode_options): Enable flag_loop_strip_mine at -O2.
4226 2009-06-30 Sebastian Pop <sebastian.pop@amd.com>
4228 * graphite-poly.c (pbb_number_of_iterations): Check for returned
4229 value 1 from ppl_Pointset_Powerset_NNC_Polyhedron_maximize.
4231 2009-06-30 Sebastian Pop <sebastian.pop@amd.com>
4233 * graphite-blocking.c (pbb_strip_mine_profitable_p): New.
4234 (pbb_do_strip_mine): Call pbb_strip_mine_profitable_p.
4235 * graphite-poly.c (pbb_number_of_iterations): New.
4236 * graphite-poly.h (pbb_number_of_iterations): Declared.
4237 (pbb_iterator_dim, pbb_parameter_dim): New.
4239 2009-06-29 Sebastian Pop <sebastian.pop@amd.com>
4241 * graphite-clast-to-gimple.c (graphite_create_new_loop): Revert the
4242 last commit on type of lower and upper bound of loops.
4244 2009-06-29 Li Feng <nemokingdom@gmail.com>
4246 * Makefile.in (graphite-clast-to-gimple.o): Added dependence on
4247 graphite-dependences.h.
4248 * graphite-clast-to-gimple.c (new_bb_pbb_def): New.
4249 (mark_bb_with_pbb): New.
4250 (get_stmtfor_depth): New.
4251 (find_pbb_via_hash): New.
4252 (dependency_in_loop_p): New.
4253 (mark_loops_parallel): New.
4254 (free_aux_in_new_loops): New.
4255 (translate_clast): Add parameter BB_PBB_MAPPING. Mark newly created
4256 bb with it's relevant pbb. Mark newly created loops. Remove mark
4257 innermost loop parallel without checking.
4258 (gloog): Add parameter BB_PBB_MAPPING.
4259 * graphite-clast-to-gimple.h (struct bb_pbb_def): New.
4260 (gloog): Change declaration.
4261 (mark_loop_parallel): Make extern.
4262 (free_aux_in_new_loops): Declare.
4263 (bb_pbb_map_hash): New.
4264 (eq_bb_pbb_map): New.
4265 * graphite.c (graphite_transform_loops): Added BB_PBB_MAPPING. Trigger
4266 auto parallelization when flag_graphite_force_parallel is set.
4267 (graphite_finalize): Added free_aux_in_new_loops.
4268 * tree-parloops.c (parallelize_loops): Only generate parallel code for
4269 the innermost loop that marked parallel. Use
4270 flag_graphite_force_parallel instead of loop->can_be_parallel.
4271 (loop_parallel_p): Move inner most checking out of function.
4273 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
4275 * graphite-clast-to-gimple.c (graphite_create_new_loop): Make the
4276 type of lower and upper bound of loops signed long int.
4278 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
4280 * cfgloopmanip.c (create_empty_loop_on_edge): Gimplify the loop exit
4281 expression outside the loop.
4283 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
4285 * gcc.dg/graphite/interchange-8.c: New.
4287 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
4289 * gcc.dg/graphite/interchange-0.c: XFailed.
4290 * gcc.dg/graphite/interchange-5.c: XFailed.
4291 * gcc.dg/graphite/interchange-6.c: XFailed.
4293 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
4295 * graphite-interchange.c (compute_array_size_poly): The end of the
4296 recursion should return 1.
4298 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
4300 * graphite-interchange.c (compute_array_size_cstr): Allow the
4301 subscript multiplier to be -1.
4302 (compute_array_size): Use PDR_DATA_CONTAINER and not PDR_ACCESSES.
4303 * graphite-poly.c (new_poly_dr): Takes an extra argument for the
4304 data_container. Initializes PDR_DATA_CONTAINER.
4305 (print_pdr_access_layout): New.
4306 (print_pdr): Call print_pdr_access_layout. Print PDR_DATA_CONTAINER.
4307 * graphite-poly.h (struct poly_dr): Adjust comment. Add a new field
4309 (PDR_DATA_CONTAINER): New.
4310 (new_poly_dr): Update declaration.
4311 * graphite-sese-to-poly.c (pdr_add_data_dimensions): New.
4312 (build_poly_dr): Call pdr_add_data_dimensions.
4314 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
4316 * graphite-poly.h (struct poly_dr): Fix comment.
4317 * graphite-sese-to-poly.c (pdr_add_alias_set): New.
4318 (pdr_add_memory_accesses): New.
4319 (build_poly_dr): Call pdr_add_memory_accesses and pdr_add_alias_set.
4321 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
4323 * graphite-poly.c (print_pdrs, debug_pdrs): New.
4324 (print_pbb): Add call to print_pdrs.
4325 * graphite-poly.h (print_pdrs, debug_pdrs): Declared.
4327 2009-06-24 Konrad Trifunovic <konrad.trifunovic@gmail.com>
4328 Li Feng <nemokingdom@gmail.com>
4330 * graphite-dependences.c (graphite_carried_dependence_level_k): New.
4331 (dependency_between_pbbs_p): New.
4332 (lexicographically_gt_p): Assure !empty_p before polyhedron
4333 intersection assign.
4334 (build_lexicographically_gt_constraint): Correct lexicographically
4336 * graphite-dependences.h: New.
4337 * Makefile.in (graphite-dependences.o): Add graphite-dependences.h.
4339 2009-06-24 Sebastian Pop <sebastian.pop@amd.com>
4341 * graphite-clast-to-gimple.c (print_clast_stmt): New.
4342 (gloog): Print to dump_file the generated clast.
4343 * graphite-clast-to-gimple.h (print_clast_stmt): Declared.
4344 * graphite-interchange.c (pbb_do_interchange): Fix dump formatting.
4346 2009-06-24 Sebastian Pop <sebastian.pop@amd.com>
4348 * graphite-poly.c (extend_scattering): Increment
4349 PBB_NB_LOCAL_VARIABLES by the number of added dimensions.
4351 2009-06-24 Sebastian Pop <sebastian.pop@amd.com>
4353 * graphite-interchange.c (compute_array_size_poly): Added exit of
4354 recursion condition. Continue iterating even after the first equality.
4355 (compute_array_size): Same.
4357 2009-06-24 Li Feng <nemokingdom@gmail.com>
4359 * gcc.dg/graphite/graphite_autopar/force-parallel-1.c: Update
4360 -fdump-tree-final_cleanup to -fdump-tree-optimized.
4361 * gcc.dg/graphite/graphite_autopar/force-parallel-2.c: Ditto.
4362 * gcc.dg/graphite/graphite_autopar/force-parallel-3.c: Ditto.
4363 * gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: Ditto.
4365 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
4367 * sese.c (expand_scalar_variables_stmt): Expand scalar variables
4368 only when the use verifies is_gimple_reg.
4370 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
4372 * graphite-clast-to-gimple.c (build_cloog_prog): Fix memory corruption.
4373 Allocate scaldims after call to unify_scattering_dimensions.
4375 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
4377 * graphite-clast-to-gimple.c (translate_clast): Fix memory leak.
4379 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
4380 Albert Cohen <albert.cohen@inria.fr>
4382 * graphite-blocking.c (pbb_strip_mine_loop_depth): Do not use local
4383 variables for the strip mining.
4385 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
4386 Pranav Garg <pranav.garg2107@gmail.com>
4388 * Makefile.in (OBJS-common): Added graphite-blocking.o.
4389 (graphite-sese-to-poly.o): Moved down to be in lexicographical order.
4390 (graphite-blocking.o): New rule.
4391 (graphite-poly.o, graphite-ppl.o): Moved to be in lexicographical order.
4392 * graphite-blocking.c: New.
4393 * graphite-poly.c (apply_poly_transforms): Call scop_do_strip_mine for
4394 flag_loop_strip_mine.
4395 (psct_scattering_dim_for_loop_depth): New.
4396 * graphite-poly.h (scop_do_strip_mine): Declared.
4397 (psct_add_local_variable): Increment PBB_NB_LOCAL_VARIABLES.
4398 * tree-ssa-loop.c (gate_graphite_transforms): Do not fail when using
4399 flag_loop_strip_mine.
4401 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
4403 * graphite-poly.c (extend_scattering): Avoid initializing and freeing
4404 a GMP value and a PPL coefficient at each iteration of a loop.
4406 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
4408 * graphite-dependences.c (dependence_polyhedron): Do not use
4409 pbb_nb_scattering_dims anymore. Use pbb_nb_scattering_orig and
4410 pbb_nb_scattering_transform.
4411 (graphite_legal_transform_dr): Same.
4412 * graphite-poly.c (extend_scattering): Same.
4413 (unify_scattering_dimensions): Same.
4414 (print_scattering_function): Same.
4415 (new_poly_bb): Initialize PBB_NB_SCATTERING_TRANSFORM and
4416 PBB_NB_LOCAL_VARIABLES.
4417 * graphite-poly.h (pbb_nb_scattering): Removed declaration.
4418 (struct poly_bb): Added nb_local_variables and nb_scattering_transform.
4419 (PBB_NB_LOCAL_VARIABLES, PBB_NB_SCATTERING_TRANSFORM): New.
4420 (pbb_nb_scattering_orig, pbb_nb_scattering_transform): New.
4421 (pbb_nb_scattering_dims, pbb_nb_scattering): Removed.
4422 (pbb_nb_scattering_transform): New.
4423 (pbb_nb_local_vars): Return PBB_NB_LOCAL_VARIABLES.
4424 (psco_scattering_dim): Add assert on parameters.
4425 (psct_scattering_dim): Same.
4426 (psct_scattering_dim_for_loop_depth): Declared.
4427 (psct_local_var_dim): New.
4428 (psco_iterator_dim, psco_parameter_dim): Add assert on parameters.
4429 (psct_iterator_dim, psct_parameter_dim): Same. To maintain the
4430 correct layout, call pbb_nb_local_vars.
4431 (psct_add_local_variable, psct_add_scattering_dimension): New.
4432 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons):
4433 Initialize PBB_NB_SCATTERING_TRANSFORM.
4435 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
4437 * graphite-ppl.c (set_inhomogeneous): Renamed ppl_set_inhomogeneous.
4438 (set_coef): Renamed ppl_set_coef.
4439 * graphite-ppl.h (ppl_set_inhomogeneous, ppl_set_coef): Declared.
4441 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
4443 * graphite-dependences.c (build_pairwise_scheduling_inequality): Don't
4444 test a boolean against 1.
4445 * graphite-interchange.c (pbb_interchange_loop_depths): Do not build
4446 a new polyhedron for the PBB_TRANSFORMED_SCATTERING.
4447 (pbb_do_interchange): Returns true when a transform has been performed.
4448 (scop_do_interchange): Same.
4449 * graphite-poly.c (apply_poly_transforms): Use the return value of
4450 scop_do_interchange.
4451 * graphite-poly.h (scop_do_interchange): Update declaration.
4453 2009-06-23 Tobias Grosser <grosser@fim.uni-passau.de>
4455 * graphite-clast-to-gimple.c (gloog): Reset loop->aux right
4457 * sese.c (sese_reset_aux_in_loops): New.
4458 * sese.h (sese_reset_aux_in_loops): New.
4460 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
4462 * graphite-sese-to-poly.c (scan_tree_for_params_int): Pass in the
4463 multiplier and multiply the constant by the multiplier.
4464 (scan_tree_for_params): Bound the multiplier to its MULT_EXPR.
4465 (build_poly_dr): Do not use the multiplier to define the subscript.
4467 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
4469 * graphite-poly.c (new_poly_dr): Pass an extra argument for the
4470 compiler's data reference. Initialize PDR_CDR.
4471 (print_pdr): Call dump_data_reference.
4472 * graphite-poly.h (struct poly_dr): Rename black_box into pbb.
4473 Add compiler_dr field.
4474 (PDR_BB): Renamed PDR_PBB.
4476 * graphite-sese-to-poly.c (build_poly_dr): Pass to new_poly_dr
4477 GCC's data reference representation.
4478 * tree-data-ref.c (debug_data_references, debug_data_reference): New.
4479 * tree-data-ref.h (debug_data_references, debug_data_reference): Decl.
4481 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
4483 * graphite-poly.c (print_scattering_function): Also print the layout.
4484 * graphite-poly.h (pbb_nb_local_vars): New.
4486 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
4488 * graphite-poly.c (print_pbb_domain): Also print the layout names.
4490 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
4492 * graphite-poly.c (print_pdr, debug_pdr): New.
4493 * graphite-poly.h (print_pdr, debug_pdr): Declared.
4494 (PDR_BASE): Removed.
4496 2009-06-18 Sebastian Pop <sebastian.pop@amd.com>
4498 * gcc.dg/graphite/interchange-{1..7}.c: New avatars of
4501 2009-06-18 Sebastian Pop <sebastian.pop@amd.com>
4503 * graphite-interchange.c (compute_subscript): Allow also -1 in the
4504 subscript identification column.
4505 (pbb_do_interchange): Print to dump_file that some loops "will be
4506 interchanged". Rely on that chain of characters in the testcases.
4507 * gcc.dg/graphite/interchange-0.c: New.
4508 * gcc.dg/graphite/graphite.exp: Iterate over the testsuite
4509 interchange-*.c files and compile them with -floop-interchange.
4511 2009-06-18 Pranav Garg <pranav.garg2107@gmail.com>
4513 * graphite-interchange.c (interchange_profitable_p): Renamed
4514 pbb_interchange_profitable_p.
4516 2009-06-18 Sebastian Pop <sebastian.pop@amd.com>
4517 Harsha Jagasia <harsha.jagasia@amd.com>
4518 Pranav Garg <pranav.garg2107@gmail.com>
4520 * graphite-interchange.c (interchange_profitable_p): Make static.
4521 (pbb_interchange_loop_depths, pbb_do_interchange,
4522 scop_do_interchange): New.
4523 * graphite-poly.c (apply_poly_transforms): Call scop_do_interchange
4524 for flag_loop_interchange.
4525 * graphite-poly.h (scop_do_interchange): Declared.
4526 * tree-ssa-loop.c (gate_graphite_transforms): Do not fail when
4527 flag_loop_interchange is used.
4529 2009-06-18 Sebastian Pop <sebastian.pop@amd.com>
4531 * graphite-dependences.c (dependence_polyhedron): Update use of
4532 pbb_nb_scattering_dims.
4533 * graphite-poly.h (pbb_nb_scattering_dims): Do not pass SCOP.
4534 (pbb_nb_scattering): Update use of pbb_nb_scattering_dims.
4535 (psco_scattering_dim, psct_scattering_dim, psco_iterator_dim,
4536 psct_iterator_dim, psco_parameter_dim, psct_parameter_dim): New.
4538 2009-06-16 Sebastian Pop <sebastian.pop@amd.com>
4540 * graphite.c: Cleanup foo.
4542 2009-06-16 Sebastian Pop <sebastian.pop@amd.com>
4544 * Merge from mainline (r143684:148293).
4545 * Disabled libpcp until it gets fixed.
4547 2009-06-05 Sebastian Pop <sebastian.pop@amd.com>
4548 Harsha Jagasia <harsha.jagasia@amd.com>
4550 * graphite-interchange.c: New.
4551 * Makefile.in (graphite-interchange.o): New.
4552 * graphite-poly.h (interchange_profitable_p): Declared.
4553 * graphite-ppl.h (value_max): New.
4555 2009-06-04 Sebastian Pop <sebastian.pop@amd.com>
4557 * graphite-dependences.c (dependence_polyhedron): Use pdr_dim.
4558 * graphite-poly.h: Fix some comments.
4562 2009-06-04 Sebastian Pop <sebastian.pop@amd.com>
4565 (pdr_accessp_nb_subscripts): Renamed pdr_nb_subscripts.
4566 (pdr_accessp_nb_iterators): Renamed pdr_dim_iter_domain.
4567 (pdr_accessp_nb_params): Renamed pdr_nb_params.
4568 (pdr_accessp_alias_set_dim): Renamed pdr_alias_set_dim.
4569 (pdr_accessp_subscript_dim): Renamed pdr_subscript_dim.
4570 (pdr_accessp_iterator_dim): Renamed pdr_iterator_dim.
4571 (pdr_accessp_param_dim): Renamed pdr_parameter_dim.
4572 (pbb_nb_loops): Renamed pbb_dim_iter_domain.
4573 * graphite-clast-to-gimple.c: Same.
4574 * graphite-dependences.c: Same.
4575 * graphite-poly.c: Same.
4576 * graphite-sese-to-poly.c: Same.
4578 2009-06-03 Sebastian Pop <sebastian.pop@amd.com>
4580 * graphite-clast-to-gimple.c (build_iv_mapping): Insert full
4581 expressions for an IV rename, as returned by clast_to_gcc_expression.
4582 (copy_renames): Rename new_name to expr.
4583 * sese.c (debug_rename_elt): Same.
4586 (sese_adjust_liveout_phis): Call force_gimple_operand before using
4587 the information from the rename map.
4588 (rename_variables_in_stmt): Same.
4589 (add_loop_exit_phis): Rename new_name to expr.
4590 (insert_loop_close_phis): Same.
4591 (add_guard_exit_phis): Same. Call force_gimple_operand.
4592 * sese.h (struct rename_map_elt): Rename new_name to expr.
4593 (new_rename_map_elt): Same.
4595 2009-06-03 Sebastian Pop <sebastian.pop@amd.com>
4597 * graphite-clast-to-gimple.c (build_iv_mapping): Use set_rename.
4598 * sese.c (set_rename): Make it extern.
4599 * sese.h (set_rename): Declared.
4601 2009-06-03 Sebastian Pop <sebastian.pop@amd.com>
4603 * graphite-poly.c (extend_scattering): Free values.
4604 * graphite-ppl.c (new_Cloog_Domain_from_ppl_Pointset_Powerset):
4606 (ppl_print_powerset_matrix): Same.
4607 * graphite-scop-detection.c (free_scops_1): New.
4608 (limit_scops): Call free_scops_1.
4609 * graphite-sese-to-poly.c (build_scop_bbs_1): Free dom.
4610 (build_poly_dr): Free PPL coefficients.
4611 * tree-parloops.c (rewrite_all_phi_nodes_with_iv): Free bbs.
4613 2009-06-02 Sebastian Pop <sebastian.pop@amd.com>
4615 * graphite-dependences.c: New.
4616 * graphite-data-ref.c: Removed.
4617 * graphite-data-ref.h: Removed.
4618 * Makefile.in (graphite-data-ref.o): Removed.
4619 (graphite-dependences.o): Added.
4620 * graphite-clast-to-gimple.c: Remove dependence on graphite-data-ref.h.
4621 * graphite-poly.c: Same.
4622 Move the data dependence testing to graphite-dependences.c.
4624 2009-05-19 Tobias Grosser <grosser@fim.uni-passau.de>
4626 * graphite-scop-detection.c (graphite_can_represent_loop): Renamed
4627 from graphite_cannot_represent_loop. Code refactored.
4628 (scopdet_basic_block_info): Call graphite_can_represent_loop.
4630 2009-05-17 Li Feng <nemokingdom@gmail.com>
4632 * gcc.dg/graphite/graphite_autopar/graphite_autopar.exp:
4633 Cover all the testcases (not only the filtered ones).
4635 2009-05-17 Tobias Grosser <grosser@fim.uni-passau.de>
4637 * graphite-scop-detection.c (stmt_simple_for_scop_p): Remove
4638 unnecessary check. Update comments. Move check for REAL_TYPE here.
4639 (harmful_stmt_in_bb): Remove checks for conditions. This is already
4640 done in (stmt_simple_for_scop_p).
4642 2009-05-14 Tobias Grosser <grosser@fim.uni-passau.de>
4644 * graphite.c (print_global_statistics): New.
4645 (print_graphite_scop_statistic): New.
4646 (print_graphite_statistics): New.
4647 (graphite_initialize, graphite_transform_loops): Print statistics.
4648 * graphite-scop-detection (build_scops): Print statistics.
4649 (print_graphite_scop_statistics): New.
4650 (print_graphite_statistics): New.
4652 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
4654 * graphite-clast-to-gimple.c (struct clast_name_index): Removed.
4655 (debug_clast_name_index): Removed.
4656 (debug_clast_name_indexes_1): Removed.
4657 (debug_clast_name_indexes): Removed.
4658 (clast_name_index_elt_info): Removed.
4659 (eq_clast_name_indexes): Removed.
4660 (clast_name_to_index): Removed.
4661 (new_clast_name_index): Removed.
4662 (save_clast_name_index): Removed.
4663 (save_var_name): Moved...
4664 (init_sese_params_index): Removed.
4665 (clast_name_to_gcc): Remove use of name_tree.
4666 (initialize_cloog_names): Same.
4667 (gloog): Do not call init_sese_params_index.
4668 * graphite-sese-to-poly.c (save_var_name): ...here.
4669 (parameter_index_in_region): New.
4670 * sese.c (new_sese): Initialize SESE_PARAMS_NAMES.
4671 (parameter_index_in_region): Removed.
4672 (is_parameter): Remove use of name_tree.
4673 * sese.h (struct name_tree): Removed.
4674 (struct sese): Remove use of name_tree. New field params_names.
4675 (SESE_PARAMS_NAMES): New.
4676 (SESE_PARAMS): Remove duplicate.
4677 (parameter_index_in_region): Removed.
4678 (sese_nb_params): Remove use of name_tree.
4679 (struct clast_name_index): New.
4680 (new_clast_name_index): New.
4681 (clast_name_to_index): New.
4682 (save_clast_name_index): New.
4683 (debug_clast_name_index): New.
4684 (debug_clast_name_indexes_1): New.
4685 (debug_clast_name_indexes): New.
4686 (clast_name_index_elt_info): New.
4687 (eq_clast_name_indexes): New.
4689 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
4691 * graphite-clast-to-gimple.c (compute_cloog_iv_types_1): Call
4692 pbb_to_depth_to_oldiv. Remove call to oldiv_for_loop.
4693 (graphite_loop_normal_form): Do not pass region. Do not
4694 initialize SESE_OLDIVS.
4695 (build_graphite_loop_normal_form): Update call to
4696 graphite_loop_normal_form.
4697 * sese.c (debug_oldivs): Removed.
4698 (new_sese): Do not initialize SESE_OLDIVS.
4699 (free_sese): Do not free SESE_OLDIVS.
4700 (oldiv_for_loop): Removed.
4701 * sese.h (struct sese): Remove old_ivs.
4702 (SESE_OLDIVS): Removed.
4703 (oldiv_for_loop): Removed.
4705 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
4707 * graphite-clast-to-gimple.c (clast_name_to_gcc): Pass newivs,
4708 remove ivstack. Remove call to loop_iv_stack_get_iv_from_name,
4709 replaced by a call to newivs_to_depth_to_newiv.
4710 (clast_to_gcc_expression): Pass newivs, remove ivstack.
4711 (clast_to_gcc_expression_red): Same.
4712 (gcc_type_for_clast_expr): Same.
4713 (gcc_type_for_clast_eq): Same.
4714 (graphite_translate_clast_equation): Same.
4715 (graphite_create_guard_cond_expr): Same.
4716 (graphite_create_new_guard): Same.
4717 (graphite_create_new_loop): Same.
4718 (build_iv_mapping): Same.
4719 (translate_clast): Same.
4721 (loop_iv_stack_patch_for_consts): Removed. *
4722 sese.c (iv_stack_entry_is_constant): Removed.
4723 (iv_stack_entry_is_iv): Removed.
4724 (loop_iv_stack_push_iv): Removed.
4725 (loop_iv_stack_insert_constant): Removed.
4726 (loop_iv_stack_pop): Removed.
4727 (loop_iv_stack_get_iv): Removed.
4728 (loop_iv_stack_get_iv_from_name): Removed.
4729 (debug_loop_iv_stack): Removed.
4730 (free_loop_iv_stack): Removed.
4731 (loop_iv_stack_remove_constants): Removed. *
4732 sese.h (iv_stack_entry_kind): Removed.
4733 (iv_stack_entry_data_union): Removed.
4734 (iv_stack_entry_struct): Removed.
4735 (iv_stack_entry_p): Removed.
4736 (debug_oldivs, debug_loop_iv_stack, loop_iv_stack_insert_constant,
4737 loop_iv_stack_get_iv_from_name, loop_iv_stack_push_iv,
4738 loop_iv_stack_get_iv, loop_iv_stack_remove_constants,
4739 loop_iv_stack_pop, free_loop_iv_stack): Removed.
4740 (gbb_loop_at_index): Fix indenting.
4741 (gbb_loop_index): Removed.
4743 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
4745 * graphite-clast-to-gimple.c (clast_name_to_gcc): Do not use strcmp.
4746 Call clast_name_to_index.
4748 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
4750 * graphite-clast-to-gimple.c (clast_name_to_gcc): Pass region,
4751 do not pass params. Get params from SESE_PARAMS.
4752 (clast_to_gcc_expression): Same.
4753 (clast_to_gcc_expression_red): Same.
4754 (gcc_type_for_clast_eq): Same.
4755 (graphite_translate_clast_equation): Same.
4756 (graphite_create_new_loop): Same.
4757 * sese.c (rename_variables_in_stmt): Fix comment.
4759 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
4761 * graphite-clast-to-gimple.c (graphite_create_new_loop): Pass
4763 Call save_clast_name_index.
4764 (translate_clast): Pass newivs_index.
4765 (gloog): Create and free newivs_index.
4767 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
4769 * graphite-clast-to-gimple.c (clast_name_index): New structure.
4770 (clast_name_index_p): New type.
4771 (debug_clast_name_index): New.
4772 (debug_clast_name_indexes_1): New.
4773 (debug_clast_name_indexes): New.
4774 (clast_name_index_elt_info): New.
4775 (eq_clast_name_indexes): New.
4776 (clast_name_to_index): New.
4777 (new_clast_name_index): New.
4778 (save_clast_name_index): New.
4779 (init_sese_params_index): New.
4780 (gloog): Call init_sese_params_index.
4781 * graphite-clast-to-gimple.h (debug_clast_name_indexes): Declared.
4782 * sese.c (new_sese): Initialize SESE_PARAMS_INDEX.
4783 (free_sese): Free SESE_PARAMS_INDEX.
4784 * sese.h (struct sese): Add params_index.
4785 (SESE_PARAMS_INDEX): New.
4787 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
4789 * graphite-clast-to-gimple.c (newivs_to_depth_to_newiv): New.
4790 (graphite_create_new_loop): Pass the newivs vector. Push the
4791 newly created IV to newivs.
4792 (translate_clast): Pass the newivs vector.
4793 (gloog): Create and destroy the newivs vector.
4795 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
4797 * graphite-clast-to-gimple.c (pbb_to_depth_to_oldiv): New.
4798 (graphite_loop_normal_form): Initialize loop->aux with the unique
4799 IV that has been created.
4801 2009-05-13 Tobias Grosser <grosser@fim.uni-passau.de>
4803 * tree-chrec.c (evolution_function_right_is_integer_cst): Allow
4804 scev with parameters in the base part. They where forbidden
4807 2009-05-11 Li Feng <nemokingdom@gmail.com>
4809 * gcc.dg/graphite/graphite.exp: Set different default
4810 compile options by file names.
4811 * gcc.dg/graphite/block{0-6}.c: Remove dg-option line.
4812 * gcc.dg/graphite/id-{1-9}.c: Ditto.
4813 * gcc.dg/graphite/scop-{0-20}.c: Ditto.
4814 * gcc.dg/graphite/scop-matmult.c: Ditto.
4816 2009-05-08 Li Feng <nemokingdom@gmail.com>
4818 * gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: New.
4819 * gcc.dg/graphite/graphite_autopar/force-parallel-1.c: New.
4820 * gcc.dg/graphite/graphite_autopar/force-parallel-2.c: New.
4821 * gcc.dg/graphite/graphite_autopar/force-parallel-3.c: New.
4823 2009-05-07 Tobias Grosser <grosser@fim.uni-passau.de>
4825 * graphite-scop-detection (build_scops_1): Fix little bug introduced
4828 2009-05-07 Tobias Grosser <grosser@fim.uni-passau.de>
4830 * graphite-scop-detection.c (graphite_can_represent_scev): Only
4831 allow integer constant strides.
4832 (graphite_can_represent_expr): Depend on outermost_loop.
4833 (stmt_simple_memref_p, graphite_cannot_represent_loop,
4834 harmful_stmt_in_bb, is_simple_operand, stmt_simple_for_scop_p,
4835 build_scops_1): Same.
4836 (scopdet_basic_block_info): Same and insert layered SCoP
4838 (try_generate_gimple_bb): Cleanup.
4839 (build_scops): Enable data references.
4841 * gcc.dg/graphite/id-5.c: New.
4842 * gcc.dg/graphite/id-9.c: New.
4843 * tree-chrec.c (evolution_function_right_is_integer_cst): New.
4844 * tree-chrec.h (evolution_function_right_is_integer_cst): New.
4846 2009-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
4848 * sese.c (expand_scalar_variables_ssa_name): Only build expressions,
4849 that we have not yet built for this SCoP.
4851 2009-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
4853 * sese.c (expand_scalar_variables_expr): Fix expand_scalar_variables
4854 for complex numbers.
4856 2009-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
4858 * graphite-ppl.c: Fix build if cloog is not available.
4860 2009-05-04 Li Feng <nemokingdom@gmail.com>
4862 * tree-parloops.c (loop_parallel_p): Remove construction of
4863 NITER and REDUCTION_LIST.
4864 (try_get_loop_niter): New.
4865 (try_create_reduction_list): New.
4866 (parallelize_loops): Bypass the failed checkings in autopar
4867 when can_be_parallel in loop structure is set to true.
4869 2009-05-01 Tobias Grosser <grosser@fim.uni-passau.de>
4871 * gcc.dg/graphite/id-6.c: Update testcase.
4872 * gcc.dg/graphite/scop-3.c: Dito.
4874 2009-05-01 Tobias Grosser <grosser@fim.uni-passau.de>
4876 * graphite-scop-detection.c (stmt_simple_for_scop_p):
4877 Enable EQ_EXPR and NE_EXPR again.
4879 2009-04-30 Tobias Grosser <grosser@fim.uni-passau.de>
4881 * graphite-scop-detection.c (graphite_can_represent_scev):
4882 Add check if scev is affine multivariate.
4883 (harmful_stmt_in_bb): Check if we can represent the conditions.
4884 (scopdet_basic_block_info (basic_block bb, VEC): Pass the loop to
4886 * gcc.dg/graphite/id-7.c: New.
4888 2009-04-30 Tobias Grosser <grosser@fim.uni-passau.de>
4890 * graphite-sese-to-poly.c (bb_contains_non_iv_scalar_phi_nodes):
4891 Check all bbs in region, not only the bbs that are represented in
4893 (build_poly_scop): Add newline.
4894 * gcc.dg/graphite/id-8.c: New.
4896 2009-04-30 Li Feng <nemokingdom@gmail.com>
4898 * cfgloop.c (alloc_loop): Initialize can_be_parallel to false
4899 when loop initialize.
4900 * cfgloop.h (struct loop): Introduce flag can_be_parallel.
4901 * common.opt: Declare flag_graphite_force_parallel.
4902 * graphite-clast-to-gimple.c (translate_clast): Mark the innermost
4904 * graphite-poly.c (apply_poly_transforms): Introduce
4905 flag_graphite_force_parallel.
4906 * tree-ssa-loop.c (gate_graphite_transforms): ditto.
4907 * toplev.c (process_options): ditto and replace a not correctly
4910 2009-04-30 Li Feng <nemokingdom@gmail.com>
4912 * graphite-clast-to-gimple.c (loop_iv_stack_patch_for_consts):
4913 Change the call of gbb_loop_at_index and/or gbb_loop_index due
4914 to the redefinition.
4915 (compute_cloog_iv_types_1): ditto.
4916 (build_iv_mapping): ditto.
4917 * graphite-sese-to-poly.c (new_gimple_bb): Remove GBB_LOOPS related
4919 (free_gimple_bb): Removed GBB_LOOPS related free part.
4920 (build_bb_loops): Removed.
4921 * sese.h (struct gimple_bb): Removed loops.
4922 (GBB_LOOPS): Removed.
4923 (gbb_loop_at_index): Instead of using GBB_LOOPS, we use sese instead.
4924 (gbb_loop_index): ditto.
4926 2009-04-24 Tobias Grosser <grosser@fim.uni-passau.de>
4928 * graphite-scop-detection.c (graphite_can_represent_scev): Do not
4929 allow non constant strides.
4930 * gcc.dg/graphite/scop-20.c: New.
4932 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
4934 * graphite-scop-detection.c (dot_all_scops): Fix system call
4935 return value warning.
4938 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
4940 * gcc.dg/graphite/id-6.c: Fix pattern.
4941 * gcc.dg/graphite/scop-3.c: Same.
4943 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
4945 * graphite-poly.c (map_into_dep_poly, map_dr_into_dep_poly,
4946 build_pairwise_constraint, dr_equality_constraints,
4947 build_pairwise_scheduling_equality,
4948 build_pairwise_scheduling_inequality, lexicographically_gt_p,
4949 build_lexicographically_gt_constraint, dependence_polyhedron,
4950 graphite_legal_transform_dr, graphite_legal_transform_bb,
4951 graphite_legal_transform): New.
4952 * graphite-poly.h (graphite_legal_transform): Declared.
4953 * graphite-sese-to-poly.c (build_poly_scop): Call to
4954 graphite_legal_transform is disabled for the moment.
4956 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
4958 * graphite-poly.h (pbb_nb_scattering_dims): New.
4959 (pbb_nb_scattering): Use it.
4961 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
4963 * graphite-ppl.c (ppl_insert_dimensions_pointset): Add
4964 Pointset_Powerset version of ppl_insert_dimensions.
4965 * graphite-ppl.h (ppl_insert_dimensions_pointset): Declared.
4967 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
4969 * graphite-ppl.c (ppl_insert_dimensions): Fix formatting.
4971 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
4973 * graphite-poly.h: Fix comment.
4975 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
4977 * graphite-sese-to-poly.c (build_poly_dr): Fix data ref multiplier.
4979 2009-04-24 Tobias Grosser <grosser@fim.uni-passau.de>
4981 * sese.c (expand_scalar_variables_stmt): Only iterate over the old
4984 2009-04-24 Tobias Grosser <grosser@fim.uni-passau.de>
4986 * graphite-sese-to-poly.c (var_used_in_not_loop_header_phi_node): New.
4987 (graphite_stmt_p): Represent bbs necessary to build the phi nodes of
4990 2009-04-20 Sebastian Pop <sebastian.pop@amd.com>
4992 * graphite-scop-detection.c (stmt_simple_for_scop_p): Do not
4993 handle EQ_EXPR and NE_EXPR.
4995 2009-04-17 Tobias Grosser <grosser@fim.uni-passau.de>
4997 * graphite-poly.h (poly_dr): Fix comment.
4999 2009-04-09 Sebastian Pop <sebastian.pop@amd.com>
5000 Tobias Grosser <grosser@fim.uni-passau.de>
5002 * graphite-poly.c (new_poly_bb): Do not initialize PBB_DOMAIN
5003 with a zero dimension polyhedron.
5004 (find_scop_parameters): Move the call to scop_set_nb_params here.
5005 (build_loop_iteration_domains): Store in loop->aux the iteration
5007 (build_scop_iteration_domain): Fix PBB_DOMAIN for bbs not surrounded
5008 by any loop in scop.
5009 (build_poly_scop): Do not call scop_set_nb_params.
5011 2009-04-09 Sebastian Pop <sebastian.pop@amd.com>
5012 Tobias Grosser <grosser@fim.uni-passau.de>
5014 * graphite-sese-to-poly.c (add_condition_to_pbb): Pass code to
5015 add_condition_to_domain not GT_EXPR.
5017 2009-04-09 Tobias Grosser <grosser@fim.uni-passau.de>
5019 * graphite-ppl.c (debug_ppl_powerset_matrix): New.
5020 * graphite-ppl.h (debug_ppl_powerset_matrix): New.
5021 * graphite-sese-to-poly.c (add_condition_to_pbb): Use
5022 upper_bound_assign to calculate unions.
5023 * gcc.dg/graphite/id-6.c: New.
5025 2009-04-09 Tobias Grosser <grosser@fim.uni-passau.de>
5027 * graphite-scop-detection.c (canonicalize_loop_closed_ssa): Do not
5028 handle abnormal edges.
5030 2009-04-09 Tobias Grosser <grosser@fim.uni-passau.de>
5032 * graphite-poly.c (new_poly_dr, free_poly_dr): New.
5033 (free_poly_bb): Also free poly_drs.
5034 * graphite-poly.h (new_poly_dr, free_poly_dr): New.
5035 (poly_dr): Polyhedron to Pointset_Powerset.
5036 (pdr_accessp_nb_subscripts): Same.
5037 * graphite-sese-to-poly.c (build_poly_dr): Same. And actually build
5040 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
5042 * graphite-clast-to-gimple.c (initialize_cloog_names): Change cloog
5043 names into more meaningful names.
5045 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
5047 * gfortran.dg/graphite/interchange-1.c: New.
5048 * gfortran.dg/graphite/interchange-2.c: New.
5050 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
5052 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not build
5054 * tree-parloops.c (rewrite_phi_with_iv): New.
5055 (rewrite_all_phi_nodes_with_iv): New.
5056 (canonicalize_loop_ivs): Call them.
5058 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
5060 * graphite-sese-to-poly.c (try_generate_gimple_bb): Use
5061 graphite_find_data_references_in_stmt.
5062 * tree-data-ref.c (graphite_find_data_references_in_stmt): New.
5063 * tree-data-ref.h (graphite_find_data_references_in_stmt): Declared.
5065 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
5067 * sese.c (add_loop_exit_phis): Don't fail on non SSA_NAME renames.
5069 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
5071 * graphite-sese-to-poly.c (build_scop_bbs_1): Use bb_in_sese_p
5072 instead of bb_in_region.
5073 (flag_bb_in_region): Same. Renamed flag_bb_in_sese.
5074 (build_sese_conditions): Use flag_bb_in_sese.
5075 * sese.c (register_bb_in_sese): Removed.
5076 (new_sese): Remove initialization of SESE_REGION_BBS.
5077 (free_sese): Do not free SESE_REGION_BBS.
5078 * sese.h (struct sese): Remove field region_basic_blocks.
5079 (SESE_REGION_BBS): Removed.
5080 (bb_in_sese_p): Implement in function of bb_in_region.
5082 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
5084 * graphite-scop-detection.c (limit_scops): Deal only with single exit
5087 2009-04-08 Tobias Grosser <grosser@fim.uni-passau.de>
5089 * graphite-scop-detection.c (stmt_simple_for_scop_p): Allow NE_EXPR
5091 * graphite-sese-to-poly.c (create_linear_expr_from_tree): New.
5092 (add_condition_to_domain): New.
5093 (add_condition_to_pbb): New.
5094 (add_conditions_to_domain): Cleanup and handle of NE_EXPR and EQ_EXPR.
5095 * gcc.dg/graphite/scop-3.c: Update number of detected SCoPs.
5097 2009-04-08 Tobias Grosser <grosser@fim.uni-passau.de>
5099 * graphite-clast-to-gimple.c (build_cloog_prog): ppl_Polyhedron ->
5100 ppl_Pointset_Powerset.
5101 * graphite-poly.c (new_poly_bb, free_poly_bb): Same.
5102 * graphite-poly.h (poly_bb): poly_bb.domain Same.
5103 (pbb_nb_loops): Same.
5104 * graphite-sese-to-poly.c (build_loop_iteration_domains,
5105 add_conditions_to_domain): Same.
5106 * graphite-ppl.c (new_Cloog_Domain_from_ppl_Pointset_Powerset): New.
5107 (ppl_print_polyhedron_matrix): ppl_Polyhedron_t ->
5108 ppl_const_Polyhedron_t.
5109 (ppl_print_powerset_matrix): New.
5110 * graphite-ppl.h (new_Cloog_Domain_from_ppl_Pointset_Powerset,
5111 ppl_print_powerset_matrix): New.
5112 (ppl_print_polyhedron_matrix): Updated.
5114 2009-04-07 Sebastian Pop <sebastian.pop@amd.com>
5116 * tree-scalar-evolution.c (analyze_scalar_evolution_1): Fix comment.
5118 2009-04-07 Sebastian Pop <sebastian.pop@amd.com>
5120 * graphite-poly.c (extend_scattering): Fix indenting. Free cstr.
5121 (print_iteration_domains, debug_iteration_domain,
5122 debug_iteration_domains): New.
5123 * graphite-poly.h (print_iteration_domains, debug_iteration_domain,
5124 debug_iteration_domains): Declared.
5125 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons): Fix
5128 2009-04-03 Tobias Grosser <grosser@fim.uni-passau.de>
5129 Sebastian Pop <sebastian.pop@amd.com>
5131 * graphite-poly.h (print_iteration_domain): New.
5132 * graphite-sese-to-poly.c (add_conditions_to_domain): Fixed bug.
5133 (build_sese_conditions_1, build_sese_conditions_after,
5134 build_sese_conditions_before): New.
5135 (build_sese_conditions): Rewritten.
5137 2009-04-03 Sebastian Pop <sebastian.pop@amd.com>
5138 Tobias Grosser <grosser@fim.uni-passau.de>
5140 Cleanup of code generation liveouts.
5141 * graphite-clast-to-gimple.c (translate_clast): Use a single
5142 rename_map instead of one per translated statement.
5143 Do not use SESE_LIVEOUT_RENAMES.
5144 (graphite_loop_normal_form): Do not use SESE_REDUCTION_LIST.
5145 (gloog): Do not use SESE_LIVEOUT_RENAMES.
5146 * graphite-scop-detection.c (harmful_stmt_in_bb): Return the close
5147 phi node of a reduction: when a loop contains a reduction used outside
5148 the loop, there should be a scalar close phi node on the exit block.
5149 * sese.c (new_sese): Do not initialize SESE_LIVEOUT,
5150 SESE_LIVEOUT_RENAMES, and SESE_REDUCTION_LIST.
5151 (free_sese): Do not free them.
5152 (sese_build_liveouts_use): Do not use them.
5153 (sese_build_liveouts_bb): Same.
5154 (sese_build_liveouts): Same.
5155 (sese_insert_phis_for_liveouts): Same.
5156 (sese_adjust_phis_for_liveouts): Same. Renamed sese_adjust_liveout_phis.
5157 (defined_in_loop_p): New.
5158 (alive_after_loop): New.
5159 (close_phi_not_yet_inserted_p): New.
5160 (struct alep, alep_p): New.
5161 (add_loop_exit_phis): Remove from the rename_map all the names defined
5162 in the code generated loop.
5163 (insert_loop_close_phis): Traverse the rename_map passed to it.
5164 Don't use SESE_LIVEOUT_RENAMES.
5165 (default_liveout_before_guard): Renamed default_before_guard.
5166 (insert_guard_phis): Do not use SESE_LIVEOUT_RENAMES.
5167 (graphite_copy_stmts_from_block): Do not directly call set_rename.
5168 (register_sese_liveout_renames): Removed.
5169 (copy_bb_and_scalar_dependences): Do not call it.
5170 * sese.h (struct sese): Removed fields: liveout, liveout_renames, and
5172 (SESE_LIVEOUT): Removed.
5173 (SESE_LIVEOUT_RENAMES): Removed.
5174 (SESE_REDUCTION_LIST): Removed.
5175 (sese_build_liveouts): Removed.
5176 (sese_adjust_phis_for_liveouts): Renamed sese_adjust_liveout_phis.
5177 (insert_loop_close_phis): Pass a htab_t instead of a sese.
5178 (insert_guard_phis): Same.
5179 (rename_map_elt): Declare a VEC of them.
5180 * tree-parloops.c (canonicalize_loop_ivs): reduction_list contains
5181 trees not pointers to trees.
5183 Rewrite in canonical close SSA form:
5184 * graphite-scop-detection.c (contains_only_close_phi_nodes): New.
5185 (limit_scops): Close the scop after the block containing the close phi
5187 (canonicalize_loop_closed_ssa): New.
5188 (canonicalize_loop_closed_ssa_form): New.
5189 (build_scops): Call canonicalize_loop_closed_ssa_form.
5191 * graphite-sese-to-poly.c: Fix typos.
5193 2009-04-03 Sebastian Pop <sebastian.pop@amd.com>
5195 * graphite-poly.c (print_scattering_function, print_pbb_domain):
5197 (dump_gbb_conditions, dump_gbb_cases, print_iteration_domain): New.
5198 (print_pbb): Add conditions.
5200 2009-04-01 Tobias Grosser <grosser@fim.uni-passau.de>
5201 Sebastian Pop <sebastian.pop@amd.com>
5203 * graphite-scop-detection.c (bb_in_sd_region): Use bb_in_region.
5204 * graphite-sese-to-poly.c (all_non_dominated_preds_marked_p): New.
5205 (build_scop_bbs_1): New.
5206 (build_scop_bbs): Rewrite.
5207 * sese.h (bb_in_region): New.
5209 2009-03-29 Tobias Grosser <grosser@fim.uni-passau.de>
5211 * graphite-poly.c (new_poly_bb, free_poly_bb): Initialize/free
5213 (print_scop): Style.
5214 * graphite-poly.h (poly_bb): Add drs vector.
5215 (PBB_DRS): Add accessor.
5216 * graphite-sese-to-poly.c (build_poly_dr): New.
5217 (build_pbb_drs, build_scop_drs): New.
5218 (build_poly_scop): call build_scop_drs (Disabled at the moment).
5220 2009-03-29 Tobias Grosser <grosser@fim.uni-passau.de>
5222 * tree-ssa-loop.c: Include forgotten toplev.h
5224 2009-03-29 Tobias Grosser <grosser@fim.uni-passau.de>
5226 * graphite-poly.c: (apply_poly_transforms): sorry -> gcc_unreachable.
5227 * gcc.dg/graphite/pr37883.c: Remove -floop-*
5228 * gcc.dg/graphite/pr37928.c: Same
5229 * gcc.dg/graphite/pr38409.c: Same
5230 * gcc.dg/graphite/pr38498.c: Same
5231 * gcc.dg/graphite/pr38559.c: Same
5232 * gcc.dg/graphite/pr39335.c: Same
5233 * gcc.dg/graphite/pr39335_1.c: Same
5234 * gfortran.dg/graphite/block-2.f: Same
5235 * tree-ssa-loop.c (gate_graphite_transforms): Always fail if called
5238 2009-03-28 Tobias Grosser <grosser@fim.uni-passau.de>
5240 * graphite-sese-to-poly.c (ref_nb_loops, build_access_matrix_with_af,
5241 build_access_matrix, build_scop_data_accesses): Remove access function
5242 building. (We get a new version soon).
5243 (build_bb_loops, scan_tree_for_params_right_scev): Update.
5244 * sese.h (nb_loops_around_loop_in_sese): Remove.
5245 (sese_loop_depth): Do not use SESE_LOOP_NEST any more.
5247 2009-03-27 Tobias Grosser <grosser@fim.uni-passau.de>
5248 Sebastian Pop <sebastian.pop@amd.com>
5250 * graphite-scop-detection.c (struct scopdet_info): Rename last
5252 (scopdet_basic_block_info, build_scops_1): Don't use
5253 CDI_POST_DOMINATORS. CDI_POST_DOMINATORS should never be used.
5255 2009-03-26 Tobias Grosser <grosser@fim.uni-passau.de>
5256 Sebastian Pop <sebastian.pop@amd.com>
5258 * graphite-clast-to-gimple.c (gloog): Call sese_build_liveouts.
5259 * sese.c (sese_build_liveouts_use): Renamed from
5260 sese_build_livein_liveouts_use. Remove liveins.
5261 (sese_build_liveouts_bb): Renamed from sese_build_livein_liveouts_bb.
5262 Call sese_build_liveouts_use.
5263 (sese_build_liveouts): Renamed from sese_build_livein_liveouts.
5264 Call sese_build_liveouts_bb.
5265 (new_sese, free_sese): Remove liveins.
5266 (sese_add_exit_phis_var): Deleted.
5267 (sese_insert_phis_for_liveouts): Call sese_add_exit_phis_edge
5269 (graphite_copy_stmts_from_block): Remove SESE_NUM_VER.
5271 * sese.h (sese): Remove num_ver and livein.
5272 (SESE_LIVEIN, SESE_LIVEIN_VER, SESE_NUM_VER): Removed.
5274 2009-03-25 Tobias Grosser <grosser@fim.uni-passau.de>
5276 * graphite-sese-to-poly.c (build_scop_scattering): Fix compile.
5278 2009-03-25 Tobias Grosser <grosser@fim.uni-passau.de>
5280 * graphite-sese-to-poly.c (compare_prefix_loops): Removed.
5281 (build_scop_scattering): Do not use compare_prefix_loops any more.
5282 (nb_common_loops): New.
5284 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
5286 * sese.c (get_new_name_from_old_name): Renamed get_rename.
5287 (register_old_and_new_names): Renamed set_rename.
5289 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
5291 * graphite-scop-detection.h (nb_reductions_in_loop): Revert removal
5292 of the decl from the previous commit.
5294 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
5296 * graphite-scop-detection.c (dot_scop): New.
5297 * graphite-scop-detection.h (dot_scop): Declared.
5299 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
5301 * graphite-sese-to-poly.c (compare_prefix_loops): Fix compare.
5303 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
5305 * cfgloopmanip.c (create_empty_loop_on_edge): Generate the loop exit
5306 condition at the end of the loop.
5307 * graphite.c (graphite_initialize, graphite_finalize): Print to
5308 dump_file the compiled function.
5309 * graphite-clast-to-gimple.c (graphite_create_new_loop): Update use
5310 of create_empty_loop_on_edge.
5311 (translate_clast): Update the code generation of loops for the new
5313 * cfgloop.h (create_empty_loop_on_edge): Update declaration.
5315 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
5317 Reverted the patch from 2009-03-19.
5319 2009-03-19 Tobias Grosser <grosser@fim.uni-passau.de>
5321 * graphite-poly.c (new_poly_bb, free_poly_bb): Initialize/free
5323 (print_scop): Style.
5324 * graphite-poly.h (poly_bb): Add drs vector.
5325 (PBB_DRS): Add accessor.
5326 * graphite-sese-to-poly.c (ref_nb_loops): Remove.
5327 (build_access_matrix_with_af, build_access_matrix,
5328 build_scop_data_accesses): Delete.
5329 (build_poly_dr): New.
5330 (build_pbb_drs, build_scop_drs): New.
5331 (build_poly_scop): call build_scop_drs.
5333 2009-03-13 Sebastian Pop <sebastian.pop@amd.com>
5335 * graphite-scop-detection.c (dot_all_scops_1): Close the table
5336 once per basic block.
5338 2009-03-13 Tobias Grosser <grosser@fim.uni-passau.de>
5340 * graphite-scop-detection.c (graphite_can_represent_scev): New.
5341 (graphite_can_represent_expr): Renamed from loop_affine_expr
5343 (stmt_simple_for_scop_p): Call graphite_can_represent_expr.
5344 (graphite_cannot_represent_loop): Add scop_entry to parameters.
5345 (scopdet_basic_block_info): Actually define entry_block.
5346 (stmt_simple_memref_p): Moved here from ...
5348 * tree-data-ref.c (stmt_simple_memref_p): here.
5349 * tree-data-ref.h (stmt_simple_memref_p): Removed.
5351 2009-03-13 Tobias Grosser <grosser@fim.uni-passau.de>
5353 * gcc.dg/graphite/id-4.c: New.
5355 2009-03-12 Sebastian Pop <sebastian.pop@amd.com>
5357 * sese.c (expand_scalar_variables_expr): Handle tcc_comparison.
5358 (register_old_and_new_names): Update the content of the map.
5359 When there was already a rename_map_elt in the map at that
5361 (copy_bb_and_scalar_dependences): Do rename_variables after
5362 expand_scalar_variables.
5363 * graphite-clast-to-gimple.c (build_iv_mapping): Update the content
5364 of the map. When there was already a rename_map_elt in the
5365 map at that location, free it.
5366 (translate_clast): Pass the rename_map. Do not initialize and free
5367 a rename_map per stmt_user.
5368 (gloog): Initialize and free one rename_map and pass it to
5371 2009-03-12 Sebastian Pop <sebastian.pop@amd.com>
5373 * sese.c (expand_scalar_variables_stmt,
5374 expand_scalar_variables_ssa_name): Add a gimple_stmt_iterator
5376 (expand_scalar_variables_expr): Handle REALPART_EXPR and IMAGPART_EXPR.
5377 (expand_scalar_variables): Pass to expand_scalar_variables_stmt
5378 the gimple_stmt_iterator of the statement to be expanded.
5379 * graphite-scop-detection.c (is_simple_operand): Do handle
5382 2009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
5384 * graphite-scop-detection.c (is_simple_operand): Do not handle
5386 * gcc.dg/graphite/id-2.c: New.
5388 * graphite-sese-to-poly.c (build_bb_loops,
5389 add_value_to_dim, scan_tree_for_params_right_scev,
5390 scan_tree_for_params_int, scan_tree_for_params, idx_record_params,
5391 find_params_in_bb, build_loop_iteration_domains,
5392 add_conditions_to_domain): Remove subtract.
5394 2009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
5396 * graphite-clast-to-gimple.c (loop_iv_stack_patch_for_consts,
5397 build_iv_mapping, compute_cloog_iv_types_1, build_cloog_prog):
5398 pbb_loop_at_index -> gbb_loop_at_index.
5399 * graphite-poly.c (new_poly_bb, new_scop): New accessors.
5400 (debug_loop_vec): Delete.
5401 * graphite-poly.h (poly_bb, scop): Change black_box and region to void
5402 pointer. Move LOOPS to gimple_bb_p and insert nb_params.
5403 (PBB_LOOPS): Removed.
5404 (PBB_BLACK_BOX): Insert cast.
5405 (pbb_set_black_box): New setter.
5406 (pbb_loop_at_index, pbb_loop_index): Removed.
5407 (scop_set_region, scop_set_nb_params): New.
5408 * graphite-sese-to-poly.c (new_gimple_bb, free_gimple_bb,
5409 build_scop_scattering, build_bb_loops): Add GBB_LOOPS.
5410 (build_poly_scop): Use scop_set_nb_params.
5411 * sese.h (gimple_bb): Add LOOPS.
5412 (GBB_LOOPS, gbb_loop_index, gbb_loop_at_index): New.
5414 2009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
5416 Revert previous commit.
5418 2009-03-11 Sebastian Pop <sebastian.pop@amd.com>
5420 * sese.c (expand_scalar_variables_expr): Handle tcc_comparison.
5421 (register_old_and_new_names): Update the content of the map.
5422 When there was already a rename_map_elt in the map at that
5424 (copy_bb_and_scalar_dependences): Do rename_variables after
5425 expand_scalar_variables.
5426 * graphite-clast-to-gimple.c (build_iv_mapping): Update the content
5427 of the map. When there was already a rename_map_elt in the
5428 map at that location, free it.
5429 (translate_clast): Pass the rename_map. Do not initialize and free
5430 a rename_map per stmt_user.
5431 (gloog): Initialize and free one rename_map and pass it to
5434 2009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
5436 Remove forgotten line in revert.
5438 2009-03-11 Sebastian Pop <sebastian.pop@amd.com>
5440 Revert previous commit.
5442 2009-03-10 Sebastian Pop <sebastian.pop@amd.com>
5444 * sese.c (register_old_and_new_names): Update the content
5445 of the map. When there was already a rename_map_elt in the
5446 map at that location, free it.
5447 (copy_bb_and_scalar_dependences): Do rename_variables after
5448 expand_scalar_variables.
5449 * graphite-clast-to-gimple.c (build_iv_mapping): Update the content
5450 of the map. When there was already a rename_map_elt in the
5451 map at that location, free it.
5452 (translate_clast): Pass the rename_map. Do not initialize and free
5453 a rename_map per stmt_user.
5454 (gloog): Initialize and free one rename_map and pass it to
5457 2009-03-10 Sebastian Pop <sebastian.pop@amd.com>
5459 * graphite-clast-to-gimple.c (translate_clast): context_loop
5462 2009-03-10 Tobias Grosser <grosser@fim.uni-passau.de>
5463 Sebastian Pop <sebastian.pop@amd.com>
5465 * graphite-ppl.c (ppl_insert_dimensions): Fix stupid mistake
5466 of the use of ppl_Polyhedron_map_space_dimensions.
5468 2009-03-10 Tobias Grosser <grosser@fim.uni-passau.de>
5469 Sebastian Pop <sebastian.pop@amd.com>
5471 * graphite-poly.c (unify_scattering_dimensions): Fix types.
5472 * graphite-poly.h (poly_dr_p, poly_dr, POLY_DR_TYPE, PDR_BB,
5473 PDR_TYPE, PDR_ACCESSES, pdr_accessp_nb_subscripts,
5474 pdr_accessp_nb_iterators, pdr_accessp_nb_params,
5475 pdr_accessp_alias_set_dim, pdr_accessp_subscript_dim,
5476 pdr_accessp_iterator_dim, pdr_accessp_param_dim,
5477 pbb_nb_params): New.
5478 (pbb_nb_loops, pbb_nb_scattering, scop_nb_params,
5479 nb_loops_around_pbb): Adapt return types.
5481 2009-03-09 Tobias Grosser <grosser@fim.uni-passau.de>
5483 * Makefile.in (graphite.o, graphite-sese-to-poly.o,
5484 graphite-clast-to-gimple.o, graphite-data-ref.o,
5485 graphite-scop-detection.o, graphite-poly.o): Add
5488 2009-03-05 Tobias Grosser <grosser@fim.uni-passau.de>
5490 * Makefile.in (graphite.o, graphite-sese-to-poly.o,
5491 graphite-clast-to-gimple.o, graphite-data-ref.o,
5492 graphite-scop-detection.o, graphite-poly.o): Add graphite-poly.h.
5494 2009-03-04 Tobias Grosser <grosser@fim.uni-passau.de>
5496 * gcc.dg/graphite/pr37485.c: Remove -floop-block
5497 * gcc.dg/graphite/pr37828.c: Same.
5498 * gcc.dg/graphite/pr37684.c: Same.
5499 * gcc.dg/graphite/block-0.c: Same.
5500 * gcc.dg/graphite/block-1.c: Same.
5501 * gcc.dg/graphite/block-2.c: Same.
5502 * gcc.dg/graphite/block-3.c: Same.
5503 * gcc.dg/graphite/block-4.c: Same.
5504 * gcc.dg/graphite/block-5.c: Same.
5505 * gcc.dg/graphite/block-6.c: Same.
5506 * gfortran.dg/graphite/pr38083.f90: Same.
5507 * gfortran.dg/graphite/block-1.f90: Same.
5508 * gfortran.dg/graphite/block-3.f90: Same.
5509 * gfortran.dg/graphite/pr37852.f90: Same.
5510 * gfortran.dg/graphite/block-4.f90: Same.
5511 * gfortran.dg/graphite/pr37980.f90: Same.
5512 * gfortran.dg/graphite/pr38953.f90: Same.
5513 * gfortran.dg/graphite/pr37857.f90: Same.
5514 * opts.c: Remove -floop-block from -O2.
5515 * graphite-poly.c: Fail if -floop-block -floop-interchange or
5516 -floop-strip-mine are used.
5518 2009-03-04 Tobias Grosser <grosser@fim.uni-passau.de>
5519 Sebastian Pop <sebastian.pop@amd.com>
5521 * graphite-clast-to-gimple.c (build_cloog_prog): Unify scattering
5523 * graphite-poly.c (pbb_compare, graphite_sort_pbbs,
5524 graphite_trans_bb_move_loop, graphite_trans_bb_strip_mine,
5525 strip_mine_profitable_p, is_interchange_valid,
5526 graphite_trans_bb_block, graphite_trans_loop_block,
5527 graphite_trans_scop_block): Temporary removed.
5528 (extend_scattering, unify_scattering_dimensions): New.
5529 (print_scattering_function, graphite_read_transforms):
5530 PBB_SCATTERING -> PBB_TRANSFORMED_SCATTERING.
5531 (graphite_generate_scattering_fns): Removed.
5532 (apply_poly_transforms): Cleanup.
5533 (free_poly_bb): Add PBB_SCATTERING -> PBB_TRANSFORMED_SCATTERING.
5534 (schedule_to_scattering): Moved.
5535 (PBB_STATIC_SCHEDULE, PBB_SCATTERING): Removed.
5536 (PBB_ORIGINAL_SCATTERING, PBB_TRANSFORMED_SCATTERING): New.
5537 (pbb_nb_scattering): New.
5538 (SCOP_ENTRY, SCOP_EXIT, SCOP_REGION_BBS, SCOP_DEP_GRAPH, SCOP_PARAMS,
5539 SCOP_LOOP_NEST, SCOP_PARAMS, SCOP_OLDIVS, SCOP_LIVEOUT_RENAMES):
5541 * graphite-ppl.c (ppl_insert_dimensions): Extended and renamed from
5543 (ppl_strip_loop): PBB_SCATTERING -> PBB_TRANSFORMED_SCATTERING.
5544 * graphite-scop-detection.c (dot_all_scops_1): PBB_SCATTERING
5545 -> PBB_TRANSFORMED_SCATTERING.
5546 * graphite-sese-to-poly.c (build_scop_bbs): Remove region.
5547 (build_pbb_scattering_polyhedron): Moved from schedule_to_scattering.
5548 (build_scop_scattering): Renamed from build_scop_canonical_schedules.
5549 (check_poly_representation): Do not return bool.
5550 (graphite_transform_loops): Reformat.
5551 * sese.h (SESE_ENTRY_BB, SESE_EXIT_BB): New.
5553 2009-03-04 Sebastian Pop <sebastian.pop@amd.com>
5555 * graphite-poly.c (print_pbb_domain, print_pbb, print_scop,
5556 debug_pbb_domain, debug_pbb, debug_scop): New.
5557 * graphite-poly.h (print_pbb_domain, print_pbb, print_scop,
5558 debug_pbb_domain, debug_pbb, debug_scop): Declared.
5560 2009-03-02 Sebastian Pop <sebastian.pop@amd.com>
5563 * tree-parloops.c (canonicalize_loop_ivs): Call fold_convert
5564 when the type precision of the induction variable should be
5565 larger than the type precision of nit.
5566 (gen_parallel_loop): Update use of canonicalize_loop_ivs.
5567 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Same.
5568 * tree-flow.h (canonicalize_loop_ivs): Update declaration.
5570 * gcc.dg/graphite/pr39335_1.c: New.
5571 * gcc.dg/graphite/pr39335.c: New.
5573 2009-03-02 Sebastian Pop <sebastian.pop@amd.com>
5575 * tree-parloops.c (canonicalize_loop_ivs): reduction_list contains
5576 SSA_NAMES not struct reduction_info.
5578 2009-03-02 Sebastian Pop <sebastian.pop@amd.com>
5580 * sese.c (expand_scalar_variables_expr): Handle ADDR_EXPR.
5582 2009-02-27 Sebastian Pop <sebastian.pop@amd.com>
5583 Tobias Grosser <grosser@fim.uni-passau.de>
5585 * sese.c (new_sese): Initialize SESE_REDUCTION_LIST.
5586 (free_sese): Free SESE_REDUCTION_LIST.
5587 * sese.h (struct sese): Add field reduction_list.
5588 (SESE_REDUCTION_LIST): New.
5589 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Call
5590 canonicalize_loop_ivs on SESE_REDUCTION_LIST.
5592 2009-02-27 Sebastian Pop <sebastian.pop@amd.com>
5593 Tobias Grosser <grosser@fim.uni-passau.de>
5595 * tree-flow.h (gather_scalar_reductions): Use struct loop * instead
5598 2009-02-27 Sebastian Pop <sebastian.pop@amd.com>
5599 Tobias Grosser <grosser@fim.uni-passau.de>
5601 * tree-parloops.c (struct brli, build_reduction_list_info,
5602 analyze_reduction_list, gather_scalar_reductions): New.
5603 (loop_parallel_p): Build a reduction list containing only
5604 PHI_RESULT SSA_NAMEs: call gather_scalar_reductions.
5605 (gen_parallel_loop): Call the analysis analyze_reduction_list.
5606 (parallelize_loops): Now reduction_list is a htab_t of SSA_NAMEs.
5607 * tree-flow.h (gather_scalar_reductions): Declared.
5609 2009-02-26 Sebastian Pop <sebastian.pop@amd.com>
5612 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not call
5613 number_of_iterations_exit from a gcc_assert.
5615 2009-02-25 Sebastian Pop <sebastian.pop@amd.com>
5616 Jan Sjodin <jan.sjodin@amd.com>
5618 * output.h (graphite_out_file, graphite_in_file): Declared.
5619 * toplev.c (graphite_out_file, graphite_in_file): New.
5620 (init_asm_output): Initialize graphite_in_file and graphite_out_file.
5621 * graphite-clast-to-gimple.c (build_cloog_prog): Read PBB_SCATTERING.
5622 Don't call schedule_to_scattering.
5623 * common.opt (fgraphite-write, fgraphite-read): New.
5624 * graphite-poly.c: Include output.h.
5625 (print_scattering_function, print_scattering_functions,
5626 debug_scattering_function, debug_scattering_functions,
5627 graphite_write_transforms, graphite_read_transforms,
5628 graphite_generate_scattering_fns): New.
5629 (apply_poly_transforms): Do not apply transform if flag_graphite_read.
5630 Call graphite_generate_scattering_fns, graphite_write_transforms,
5631 graphite_read_transforms.
5632 (new_poly_bb): Initialize PBB_SCATTERING.
5633 (free_poly_bb): Free PBB_SCATTERING.
5634 (schedule_to_scattering): Does not return, initialize PBB_SCATTERING.
5635 * graphite-poly.h (struct poly_bb): Add field scattering.
5636 (PBB_SCATTERING): New.
5637 (print_scattering_function, print_scattering_functions,
5638 debug_scattering_function, debug_scattering_functions): Declared.
5639 * graphite-ppl.c (cloog_matrix_to_ppl_constraint): Matrices contain
5640 GMP values, not integers!
5641 (ppl_print_polyhedron_matrix, debug_ppl_polyhedron_matrix,
5642 ppl_read_polyhedron_matrix): New.
5643 * graphite-ppl.h (ppl_print_polyhedron_matrix,
5644 debug_ppl_polyhedron_matrix,
5645 ppl_read_polyhedron_matrix): Declared.
5646 * Makefile.in (graphite-poly.o): Depends on output.h.
5648 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
5649 Tobias Grosser <grosser@fim.uni-passau.de>
5652 * graphite-scop-detection.c (stmt_simple_for_scop_p): Analyze
5653 scalar evolutions in the scop_entry->loop_father.
5655 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
5656 Tobias Grosser <grosser@fim.uni-passau.de>
5658 * graphite.h (ref_nb_loops): Remove declaration.
5659 (struct gimple_bb, gimple_bb_p, GBB_BB, GBB_DATA_REFS, GBB_CONDITIONS,
5660 GBB_CONDITION_CASES, GBB_CLOOG_IV_TYPES, gbb_loop, print_gimple_bb,
5661 debug_gbb): Moved to sese.h.
5664 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
5665 Tobias Grosser <grosser@fim.uni-passau.de>
5667 * graphite-data-ref.[ch]: Disable.
5669 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
5670 Tobias Grosser <grosser@fim.uni-passau.de>
5672 * graphite-scop-detection.c (stmt_simple_for_scop_p): Analyze
5673 scalar evolutions in the scop_entry->loop_father.
5675 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
5677 * graphite-scop-detection.c (nb_reductions_in_loop): Moved here...
5678 (graphite_cannot_represent_loop_niter): Renamed
5679 graphite_cannot_represent_loop. Call nb_reductions_in_loop.
5680 (limit_scops): build_sese_loop_nests does not return a bool.
5681 * graphite-scop-detection.h (nb_reductions_in_loop): Declared.
5682 * sese.c (nb_reductions_in_loop): ... from here.
5683 (graphite_loop_normal_form): ... from here.
5684 (sese_record_loop): Does not fail, so does not return a bool.
5685 (build_sese_loop_nests): Same.
5686 * sese.h (build_sese_loop_nests): Update declaration.
5687 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Moved here...
5688 (build_graphite_loop_normal_form): New.
5689 (gloog): Call build_graphite_loop_normal_form.
5690 * graphite-sese-to-poly.c (build_poly_scop): Don't fail on
5691 build_sese_loop_nests.
5693 * gcc.dg/graphite/id-1.c: New.
5695 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
5696 Tobias Grosser <grosser@fim.uni-passau.de>
5698 * graphite-sese-to-poly.c (scan_tree_for_params): Remove REAL_CST.
5699 The SCoP detection fix is sufficient.
5701 2009-02-21 Sebastian Pop <sebastian.pop@amd.com>
5703 PR tree-optimization/39260
5704 * graphite-scop-detection.c (harmful_stmt_in_bb): Stop a SCoP when
5705 the basic block contains a condition with a real type.
5706 * graphite-sese-to-poly.c (scan_tree_for_params): Handle REAL_CST.
5708 * gcc.dg/graphite/pr39260.c: New.
5710 2009-02-21 Sebastian Pop <sebastian.pop@amd.com>
5712 * graphite-poly.c: Inlcude params.h.
5713 (graphite_trans_loop_block): Use PARAM_LOOP_BLOCK_TILE_SIZE for
5715 * Makefile.in (graphite-poly.o): Depend on PARAMS_H.
5716 * params.def (PARAM_LOOP_BLOCK_TILE_SIZE): Define.
5718 2009-02-20 Sebastian Pop <sebastian.pop@amd.com>
5719 Tobias Grosser <grosser@fim.uni-passau.de>
5721 * graphite-scop-detection.c (dot_all_scops_1,
5722 dot_all_scops): Moved here.
5723 * graphite-scop-detection.h (dot_all_scops): Declared here.
5724 * graphite.c (graphite_initialize, graphite_finalize): New.
5725 (graphite_transform_loops): Cleaned up.
5726 * sese.c (debug_oldivs): Moved here.
5727 * graphite-poly.c (graphite_apply_transformations): Renamed
5728 apply_poly_transforms.
5729 (debug_loop_vec): Moved here.
5730 * graphite-sese-to-poly.c (build_bb_loops, build_sese_conditions_1,
5731 scop_contains_non_iv_scalar_phi_nodes, build_sese_conditions,
5732 find_scop_parameters, build_scop_iteration_domain,
5733 add_conditions_to_constraints, build_scop_canonical_schedules,
5734 build_scop_data_accesses): Now static.
5735 (build_poly_scop, check_poly_representation): New.
5737 2009-02-20 Sebastian Pop <sebastian.pop@amd.com>
5739 * graphite.c (graphite_stmt_p, new_gimple_bb, free_gimple_bb,
5740 remove_gbbs_in_scop, free_scops, try_generate_gimple_bb,
5741 build_scop_bbs, ref_nb_loops, compare_prefix_loops,
5742 build_scop_canonical_schedules, build_bb_loops, add_value_to_dim,
5743 scan_tree_for_params_right_scev, scan_tree_for_params_int,
5744 scan_tree_for_params, struct irp_data, dx_record_params,
5745 find_params_in_bb, find_scop_parameters, gbb_from_bb,
5746 build_loop_iteration_domains, add_conditions_to_domain,
5747 phi_node_is_iv, bb_contains_non_iv_scalar_phi_nodes,
5748 scop_contains_non_iv_scalar_phi_nodes, build_sese_conditions_1,
5749 build_sese_conditions, add_conditions_to_constraints,
5750 build_scop_iteration_domain, build_access_matrix_with_af,
5751 build_access_matrix,
5752 build_scop_data_accesses): Moved to graphite-sese-to-poly.c.
5754 * graphite-sese-to-poly.c: New.
5755 * graphite-sese-to-poly.h: New.
5757 * Makefile.in: Add new rule for graphite-sese-to-poly.o.
5759 2009-02-20 Sebastian Pop <sebastian.pop@amd.com>
5761 * graphite.c: Split graphite code generation to a new file.
5762 (graphite_verify, gmp_cst_to_tree, clast_name_to_gcc,
5763 max_precision_type, clast_to_gcc_expression_red,
5764 clast_to_gcc_expression, gcc_type_for_clast_expr,
5765 gcc_type_for_clast_eq, loop_iv_stack_patch_for_consts,
5766 graphite_translate_clast_equation, graphite_create_guard_cond_expr,
5767 graphite_create_new_guard, clast_get_body_of_loop,
5768 gcc_type_for_cloog_iv, gcc_type_for_iv_of_clast_loop,
5769 graphite_create_new_loop, build_iv_mapping, copy_renames,
5770 translate_clast, find_cloog_iv_in_expr, compute_cloog_iv_types_1,
5771 compute_cloog_iv_types, free_scattering, save_var_name,
5772 initialize_cloog_names, build_scop_context, build_cloog_prog,
5773 set_cloog_options, debug_clast_stmt, scop_to_clast,
5774 print_generated_program, debug_generated_program,
5775 gloog): Moved to graphite-clast-to-gimple.c.
5777 (struct cloog_prog_clast): Moved to graphite-clast-to-gimple.h.
5779 (iv_stack_entry_is_constant, iv_stack_entry_is_iv,
5780 loop_iv_stack_push_iv, loop_iv_stack_insert_constant,
5781 loop_iv_stack_pop, loop_iv_stack_get_iv,
5782 loop_iv_stack_get_iv_from_name, debug_loop_iv_stack,
5783 free_loop_iv_stack, loop_iv_stack_remove_constants,
5784 debug_rename_elt, debug_rename_map_1, debug_rename_map,
5785 rename_map_elt_info, eq_rename_map_elts, debug_ivtype_elt,
5786 debug_ivtype_map_1, debug_ivtype_map, ivtype_map_elt_info,
5787 eq_ivtype_map_elts, sese_add_exit_phis_edge,
5788 sese_add_exit_phis_var, sese_insert_phis_for_liveouts,
5789 get_vdef_before_sese, sese_adjust_vphi,
5790 get_new_name_from_old_name, sese_adjust_phis_for_liveouts,
5791 oldiv_for_loop, rename_variables_in_stmt, is_parameter,
5792 is_iv, expand_scalar_variables_ssa_name,
5793 expand_scalar_variables_expr, expand_scalar_variables_stmt,
5794 expand_scalar_variables, rename_variables, remove_condition,
5795 get_true_edge_from_guard_bb, get_false_edge_from_guard_bb,
5796 add_loop_exit_phis, insert_loop_close_phis, struct igp,
5797 default_liveout_before_guard, add_guard_exit_phis,
5798 insert_guard_phis, register_old_and_new_names,
5799 graphite_copy_stmts_from_block, register_sese_liveout_renames,
5800 copy_bb_and_scalar_dependences, outermost_loop_in_sese,
5801 if_region_set_false_region, create_if_region_on_edge,
5802 move_sese_in_condition): Moved to sese.c.
5804 (nb_loops_around_loop_in_sese, struct ifsese, if_region_entry,
5805 if_region_exit, if_region_get_condition_block,
5806 struct rename_map_elt, new_rename_map_elt, enum iv_stack_entry_kind,
5807 union iv_stack_entry_data_union, struct iv_stack_entry_struct,
5808 iv_stack_entry_p, loop_iv_stack, struct ivtype_map_elt,
5809 ivtype_map_elt, new_ivtype_map_elt,
5810 recompute_all_dominators): Moved to sese.h.
5812 * graphite-clast-to-gimple.c: New.
5813 * graphite-clast-to-gimple.h: New.
5814 * Makefile.in: Add new rule for graphite-clast-to-gimple.o.
5815 * sese.c: Modified as said above.
5818 2009-02-20 Sebastian Pop <sebastian.pop@amd.com>
5820 * graphite.c: Split scop detection to a new file.
5821 (enum gbb_type, gbb_type, get_bb_type, struct sd_region_p, sd_region,
5822 move_sd_regions, loop_affine_expr, exclude_component_ref,
5823 is_simple_operand, stmt_simple_for_scop_p, harmful_stmt_in_bb,
5824 graphite_cannot_represent_loop_niter, struct scopdet_info,
5825 scopdet_basic_block_info, build_scops_1, bb_in_sd_region,
5826 find_single_entry_edge, find_single_exit_edge,
5827 create_single_entry_edge, sd_region_without_exit,
5828 create_single_exit_edge, unmark_exit_edges, mark_exit_edges,
5829 create_sese_edges, build_graphite_scops, limit_scops, build_scops):
5830 Moved to graphite-scop-detection.c.
5832 * graphite-scop-detection.c: New.
5833 * graphite-scop-detection.h: New.
5834 * Makefile.in: Add new rule for graphite-scop-detection.o.
5836 * sese.c: Include tree-chrec.h, tree-data-ref.h, and
5837 tree-scalar-evolution.h.
5838 (nb_reductions_in_loop, graphite_loop_normal_form, sese_record_loop,
5839 build_sese_loop_nests): Moved here from graphite.c.
5840 (param_index): Renamed parameter_index_in_region.
5842 2009-02-18 Tobias Grosser <grosser@fim.uni-passau.de>
5843 Sebastian Pop <sebastian.pop@amd.com>
5845 * gcc.dg/graphite/block-0.c: Expected to fail now.
5846 * gcc.dg/graphite/block-1.c: Same.
5847 * gcc.dg/graphite/block-5.c: Same.
5848 * gcc.dg/graphite/block-6.c: Same.
5850 2009-02-18 Tobias Grosser <grosser@fim.uni-passau.de>
5851 Sebastian Pop <sebastian.pop@amd.com>
5853 * graphite.h: Separate from graphite_bb_p the polyhedral
5854 representation in poly_bb_p and the GCC specifics in gimple_bb_p.
5855 (struct data_dependence_polyhedron, RDGE_DDP, ddp_p): Moved to
5856 graphite-data-ref.h.
5857 (struct poly_bb, PBB_SCOP, PBB_STATIC_SCHEDULE, PBB_DOMAIN,
5858 PBB_BLACK_BOX, PBB_LOOPS, pbb_nb_loops, pbb_loop_at_index,
5859 pbb_loop_index, struct scop, SCOP_BBS, SCOP_REGION, SCOP_ENTRY,
5860 SCOP_EXIT, SCOP_REGION_BBS, SCOP_DEP_GRAPH, SCOP_PARAMS,
5861 SCOP_LOOP_NEST, SCOP_PARAMS, SCOP_OLDIVS, SCOP_LIVEOUT_RENAMES,
5862 scop_nb_params): Moved to graphite-poly.h.
5863 * graphite-data-ref.c: Same.
5864 * graphite-data-ref.h: New.
5866 (pbb_compare, graphite_sort_pbbs, graphite_trans_bb_move_loop,
5867 graphite_trans_bb_strip_mine, strip_mine_profitable_p,
5868 is_interchange_valid, graphite_trans_bb_block,
5869 graphite_trans_loop_block, scop_max_loop_depth,
5870 graphite_trans_scop_block, graphite_apply_transformations,
5871 new_poly_bb, free_poly_bb, new_scop, free_scop): Moved to
5873 * graphite-poly.h: New.
5874 * graphite-poly.c: New.
5875 * Makefile.in (OBJS-common): Add graphite-poly.o.
5876 (graphite-poly.o): New rule.
5877 * tree-data-ref.h (struct data_reference): Remove unused scop field.
5880 2009-02-18 Sebastian Pop <sebastian.pop@amd.com>
5881 Tobias Grosser <grosser@fim.uni-passau.de>
5883 * graphite.c: Replace gb -> gbb.
5885 * graphite-data-ref.c: Same.
5887 2009-02-18 Sebastian Pop <sebastian.pop@amd.com>
5888 Tobias Grosser <grosser@fim.uni-passau.de>
5890 * Makefile.in (OBJS-commmon): Add sese.o.
5892 (graphite.o): Add sese.h.
5893 * graphite.c (bb_in_ss_p, loop_in_sese_p,
5894 sese_build_livein_liveouts_use, sese_build_livein_liveouts_bb,
5895 sese_build_livein_liveouts, register_bb_in_sese, new_sese, free_sese):
5897 (block_before_scop): Add missing return.
5898 (new_scop, free_scop): Remove SESE data structures.
5899 (scop_record_loop, scan_tree_for_params, find_params_in_bb,
5900 find_scop_parameters, build_loop_iteration_domains,
5901 add_conditions_to_domain, register_scop_liveout_renames,
5902 copy_bb_and_scalar_dependences): Scop -> SESE.
5904 (add_conditions_to_domain): SCoP -> SESE and remove check
5905 (scop_contains_non_iv_scalar_phi_nodes): New.
5906 (build_scop_conditions_1, build_scop_conditions): Remove check for
5907 non iv scalar phi nodes.
5908 (print_scop_statistics): New.
5909 (graphite_transform_loops): Cleanup.
5911 * graphite.h: Move to sese & cleanup.
5915 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
5916 Tobias Grosser <grosser@fim.uni-passau.de>
5918 * graphite.c (build_scop_conditions_1): Conditions are only
5919 at the end of a basic block.
5921 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
5922 Tobias Grosser <grosser@fim.uni-passau>
5924 * graphite.h (struct graphite_bb): Remove compressed_alpha_matrix
5926 (GBB_ALPHA): Removed.
5928 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
5929 Tobias Grosser <grosser@fim.uni-passau.de>
5931 * graphite-data-ref.c (graphite_test_dependence): Don't use
5932 GBB_DYNAMIC_SCHEDULE.
5933 * graphite.c (new_graphite_bb): Same.
5934 (free_graphite_bb): Same.
5935 (build_scop_dynamic_schedules): Removed.
5936 (graphite_transform_loops): Don't call it.
5937 * graphite.h (struct graphite_bb): Remove dynamic_schedule field.
5938 (GBB_DYNAMIC_SCHEDULE): Removed.
5940 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
5941 Tobias Grosser <grosser@fim.uni-passau.de>
5943 * graphite.c (schedule_to_scattering): Don't use CloogMatrix.
5944 (print_graphite_bb): Same.
5945 (build_cloog_prog): Same.
5947 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
5948 Tobias Grosser <grosser@fim.uni-passau.de>
5950 * graphite.c (build_cloog_prog): Don't use CloogMatrix.
5952 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
5953 Tobias Grosser <grosser@fim.uni-passau.de>
5955 * graphite.c (build_scop_context): Don't use CloogMatrix.
5956 * graphite-ppl.c (new_Cloog_Domain_from_ppl_Polyhedron): New.
5957 * graphite-ppl.h (new_Cloog_Domain_from_ppl_Polyhedron): Declared.
5959 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
5960 Tobias Grosser <grosser@fim.uni-passau.de>
5962 * graphite.h (struct scop): Move params, old_ivs, loops, loop_nest,
5963 liveout_renames, add_params fields...
5964 (struct sese): ... here.
5965 (SESE_PARAMS, SESE_LOOPS, SESE_LOOP_NEST, SESE_ADD_PARAMS,
5966 SESE_PARAMS, SESE_OLDIVS, SESE_LIVEOUT_RENAMES): New.
5968 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
5969 Tobias Grosser <grosser@fim.uni-passau.de>
5971 * graphite.c (print_scop): Do not print the CLooG program.
5972 (new_scop, free_scop, initialize_cloog_names, build_scop_context,
5973 build_cloog_prog, gloog): Don't use SCOP_PROG.
5974 (find_transform): Renamed scop_to_clast.
5975 (print_generated_program, debug_generated_program): New.
5976 (graphite_transform_loops): Adapt to new interface.
5977 * graphite.h (struct scop): Remove program field.
5978 (SCOP_PROG): Removed.
5979 (print_generated_program, debug_generated_program): Declared.
5981 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
5983 * graphite-data-ref.c (schedule_precedes_p, schedule_same_p): New.
5984 (statement_precedes_p): Use schedule_same_p and schedule_precedes_p.
5985 * graphite.c (gbb_compare, schedule_to_scattering, print_graphite_bb,
5986 free_graphite_bb, build_scop_canonical_schedules,
5987 graphite_trans_bb_strip_mine, graphite_trans_scop_block): Static
5988 schedules are now represented using a ppl_Linear_Expression_t.
5989 * graphite.h (struct graphite_bb): Same.
5990 * graphite-ppl.c (ppl_lexico_compare_linear_expressions): New.
5991 * graphite-ppl.h (ppl_lexico_compare_linear_expressions): Declared.
5993 2009-02-15 Sebastian Pop <sebastian.pop@amd.com>
5995 * graphite.c: Free local memory.
5996 * graphite-ppl.c: Same.
5998 2009-02-15 Sebastian Pop <sebastian.pop@amd.com>
6000 * graphite.c (const_column_index, get_first_matching_sign_row_index,
6001 get_lower_bound_row, get_upper_bound_row, copy_constraint,
6002 swap_constraint_variables, scale_constraint_variable): Removed.
6003 (graphite_trans_bb_strip_mine): Remove pong.
6004 * graphite-ppl.c: Include missing header files.
6005 (set_inhomogeneous, set_coef, shift_poly, ppl_strip_loop): New.
6006 * graphite-ppl.h (ppl_strip_loop): Declared.
6007 * Makefile.in (graphite-ppl.o): Adjust dependences.
6009 2009-02-14 Sebastian Pop <sebastian.pop@amd.com>
6011 * graphite.c (build_loop_iteration_domains): Remove ping pong.
6012 (build_scop_iteration_domain): Same.
6014 2009-02-13 Sebastian Pop <sebastian.pop@amd.com>
6016 * graphite.c (scan_tree_for_params, add_conditions_to_domain): Remove
6018 (add_value_to_dim, scan_tree_for_params_right_scev,
6019 scan_tree_for_params_int): New.
6020 * graphite-ppl.c (oppose_constraint): New.
6021 (insert_constraint_into_matrix): Implement missing cases.
6022 * graphite-ppl.h (insert_constraint_into_matrix): Declared.
6024 2009-02-13 Sebastian Pop <sebastian.pop@amd.com>
6026 * graphite.c (graphite_trans_bb_move_loop): Remove ping pong,
6027 use ppl_move_dimension.
6029 2009-02-12 Sebastian Pop <sebastian.pop@amd.com>
6031 * graphite-data-ref.c: Domains are now ppl_Polyhedra_t.
6034 * graphite-ppl.c: Same.
6035 * graphite-ppl.h: Same.
6037 2009-02-12 Sebastian Pop <sebastian.pop@amd.com>
6039 Revert last 3 commits.
6041 2009-02-10 Sebastian Pop <sebastian.pop@amd.com>
6043 * graphite.c (scan_tree_for_params, add_conditions_to_domain): Remove
6045 (add_value_to_dim, scan_tree_for_params_right_scev,
6046 scan_tree_for_params_int): New.
6047 * graphite-ppl.c (oppose_constraint): New.
6048 (insert_constraint_into_matrix): Implement missing cases.
6049 * graphite-ppl.h (insert_constraint_into_matrix): Declared.
6051 2009-02-10 Sebastian Pop <sebastian.pop@amd.com>
6053 * graphite.c (graphite_trans_bb_move_loop): Remove unused variables.
6055 2009-02-10 Sebastian Pop <sebastian.pop@amd.com>
6056 Tobias Grosser <grosser@fim.uni-passau.de>
6058 * graphite.c (graphite_trans_bb_move_loop): Remove ping pong,
6059 use ppl_move_dimension.
6060 * graphite-ppl.c (ppl_move_dimension): New.
6061 * graphite-ppl.h (ppl_move_dimension): Declared.
6063 2009-02-10 Sebastian Pop <sebastian.pop@amd.com>
6065 * graphite.c: Do not include cloog/cloog.h.
6066 (print_graphite_bb): Remove ping pong, call PPL print function.
6068 2009-02-10 Tobias Grosser <grosser@fim.uni-passau.de>
6070 * Makefile.in (OBJS-common): Add graphite-ppl.o.
6071 (graphite.o): Add dependence on graphite-ppl.h.
6072 (graphite-ppl.o): New.
6073 (graphite-data-ref.c): Ping pong between PPL data structures
6075 * graphite-ppl.c: New.
6076 * graphite-ppl.h: New.
6077 * graphite.c: Include graphite-ppl.h.
6078 (print_graphite_bb, add_conditions_to_domain, build_cloog_prog,
6079 graphite_trans_bb_move_loop, graphite_trans_bb_strip_mine):
6080 Ping pong between PPL data structures and matrices.
6081 (new_graphite_bb): Create a PPL constraint system.
6082 Call ppl_delete_Constraint_System instead of cloog_matrix_free.
6083 (build_loop_iteration_domains): Use PPL functions.
6084 * graphite.h: Include graphite-ppl.h. Fix comments.
6085 (graphite_bb): Use a ppl_Constraint_System_t instead of
6086 CloogMatrix for representing the domain.
6087 (scop): Remove static_schedule.
6088 (gbb_nb_loops): Ping pong between PPL data structures and matrices.
6090 2009-02-06 Sebastian Pop <sebastian.pop@amd.com>
6092 * graphite.c: Fix some comments.
6094 2009-02-05 Sebastian Pop <sebastian.pop@amd.com>
6097 * graphite.c (if_region_set_false_region): After moving a region
6098 in the false branch of a condition, remove the empty dummy
6100 (gloog): Remove wrong fix for PR38953.
6102 2009-02-03 Tobias Grosser <grosser@fim.uni-passau.de>
6104 * graphite.c (bb_in_sese_p, sese_build_livein_liveouts_use,
6105 sese_build_livein_liveouts_bb, sese_build_livein_liveouts,
6106 register_bb_in_sese, new_sese, free_sese): Moved.
6107 (dot_scop_1, build_scop_loop_nests, build_loop_iteration_domains,
6108 outermost_loop_in_scop, build_scop_iteration_domain,
6109 expand_scalar_variables_ssa_name, get_vdef_before_scop,
6110 limit_scops): Use bb_in_sese_p instead of bb_in_scop_p.
6111 Use loop_in_sese_p instead of loop_in_scop_p.
6112 (new_graphite_bb, new_scop, gloog): Do not initialize SCOP_BBS_B.
6113 (free_scop): Do not free SCOP_BBS_B.
6114 (nb_loops_around_loop_in_scop, nb_loops_around_gb,
6115 ref_nb_loops): Moved here...
6116 * graphite.h (ref_nb_loops): ... from here.
6117 (struct scop): Remove bbs_b bitmap.
6118 (SCOP_BBS_B, bb_in_scop_p, loop_in_scop_p): Removed.
6119 * gcc.dg/graphite/scop-19.c: New
6121 2009-02-03 Tobias Grosser <grosser@fim.uni-passau.de>
6123 * graphite.c (scopdet_basic_block_info): Fix bug in scop
6126 2009-01-30 Tobias Grosser <grosser@fim.uni-passau.de>
6128 * graphite.c (new_loop_to_cloog_loop_str, hash_loop_to_cloog_loop,
6129 eq_loop_to_cloog_loop): Remove.
6130 (new_scop, free_scop): Remove SCOP_LOOP2CLOOG_LOOP.
6131 * graphite.h (struct scop): Remove loop2cloog_loop.
6132 (loop_domain_dim, loop_iteration_vector_dim): Remove.
6134 2009-01-30 Tobias Grosser <grosser@fim.uni-passau.de>
6136 * opts.c (decode_options): Only add graphite options to O2
6137 if we compile with graphite enabled.
6139 2009-01-26 Sebastian Pop <sebastian.pop@amd.com>
6141 * Merge from mainline (r143163:143684).
6143 2009-01-26 Sebastian Pop <sebastian.pop@amd.com>
6145 * graphite.c (debug_value): Removed.
6146 * graphite.h (debug_value): Removed.
6148 2009-01-23 Sebastian Pop <sebastian.pop@amd.com>
6150 * passes.c (init_optimization_passes): Do not call pass_copy_prop
6151 after graphite: pass_copy_prop does not maintain a proper loop closed
6152 SSA form. pass_copy_prop should be fixed.
6154 2009-01-23 Sebastian Pop <sebastian.pop@amd.com>
6156 * graphite.c (scop_adjust_phis_for_liveouts): Fix warning.
6158 2009-01-23 Sebastian Pop <sebastian.pop@amd.com>
6160 * graphite.c (graphite_verify): Add a call to verify_loop_closed_ssa.
6161 (gloog): Split the exit of the scop when the scop exit is a loop exit.
6162 (graphite_transform_loops): Only call cleanup_tree_cfg if gloog
6165 2009-01-20 Sebastian Pop <sebastian.pop@amd.com>
6167 * graphite.c (gloog): Return true when code gen succeeded.
6168 (graphite_transform_loops): Do not call cleanup_tree_cfg if
6169 the code of the function did not changed. After cleanup_tree_cfg
6170 call rewrite_into_loop_closed_ssa to maintain the loop closed ssa
6173 2009-01-19 Sebastian Pop <sebastian.pop@amd.com>
6175 * graphite.c (stmt_simple_for_scop_p): Also handle cases when
6176 gimple_call_lhs is NULL.
6178 2009-01-16 Sebastian Pop <sebastian.pop@amd.com>
6179 Tobias Grosser <tobi.grosser@amd.com>
6181 * graphite.c (graphite_trans_scop_block): Do not block single
6184 2009-01-15 Sebastian Pop <sebastian.pop@amd.com>
6185 Tobias Grosser <tobi.grosser@amd.com>
6187 * graphite.c (build_scop_canonical_schedules): Start schedules at
6190 2009-01-15 Sebastian Pop <sebastian.pop@amd.com>
6191 Tobias Grosser <tobi.grosser@amd.com>
6193 * graphite.c (compare_prefix_loops): New.
6194 (build_scop_canonical_schedules): Rewritten.
6195 (graphite_transform_loops): Move build_scop_canonical_schedules
6196 after build_scop_iteration_domain.
6198 2009-01-14 Sebastian Pop <sebastian.pop@amd.com>
6199 Tobias Grosser <tobi.grosser@amd.com>
6201 * graphite.c (add_conditions_to_domain): Add the loops to
6202 the dimension of the iteration domain. Do copy the domain
6203 only when it exists.
6204 (build_scop_conditions_1): Do not call add_conditions_to_domain.
6205 (add_conditions_to_constraints): New.
6206 (can_generate_code_stmt, can_generate_code): Removed.
6207 (gloog): Do not call can_generate_code.
6208 (graphite_transform_loops): Call add_conditions_to_constraints
6209 after building the iteration domain.
6211 2009-01-14 Sebastian Pop <sebastian.pop@amd.com>
6212 Tobias Grosser <tobi.grosser@amd.com>
6213 Jan Sjodin <jan.sjodin@amd.com>
6215 * graphite.c (scan_tree_for_params): On substractions negate
6216 all the coefficients of the term.
6217 (clast_to_gcc_expression_red): New. Handle reduction expressions
6218 of more than two operands.
6219 (clast_to_gcc_expression): Call clast_to_gcc_expression_red.
6220 (get_vdef_before_scop): Handle also the case of default definitions.
6222 2009-01-14 Sebastian Pop <sebastian.pop@amd.com>
6225 * graphite.c (get_vdef_before_scop, scop_adjust_vphi): New.
6226 (scop_adjust_phis_for_liveouts): Call scop_adjust_vphi.
6227 (gloog): Do not call cleanup_tree_cfg.
6228 (graphite_transform_loops): Call cleanup_tree_cfg after all
6229 scops have been code generated.
6231 2009-01-13 Sebastian Pop <sebastian.pop@amd.com>
6233 * passes.c (init_optimization_passes): Schedule after
6234 graphite transforms pass_copy_prop, pass_dce_loop and pass_lim.
6236 2009-01-13 Sebastian Pop <sebastian.pop@amd.com>
6238 * graphite.c (expand_scalar_variables_stmt): Do not pass loop_p.
6240 (expand_scalar_variables_ssa_name): Do not pass loop_p. Fix comment.
6241 Set the type of an expression to the type of its assign statement.
6242 (expand_scalar_variables_expr): Do not pass loop_p.
6243 Fix comment. Stop recursion on tcc_constant or tcc_declaration.
6244 (copy_bb_and_scalar_dependences): Do not pass loop_p.
6245 (translate_clast): Update call to copy_bb_and_scalar_dependences.
6247 2009-01-11 Sebastian Pop <sebastian.pop@amd.com>
6249 * graphite.c (expand_scalar_variables_ssa_name): Set the type of
6250 an expression to the gimple_expr_type of its assign statement.
6251 (expand_scalar_variables_expr): Stop recursion on tcc_constant
6254 2009-01-11 Sebastian Pop <sebastian.pop@amd.com>
6256 PR tree-optimization/38786
6257 * gcc.dg/graphite/pr38786.c: New.
6258 * graphite.c (expand_scalar_variables_ssa_name): New, outlined from
6259 the SSA_NAME case of expand_scalar_variables_expr.
6260 (expand_scalar_variables_expr): Also gather the scalar computation
6261 used to index the memory access.
6262 (expand_scalar_variables_stmt): Pass to expand_scalar_variables_expr
6263 the gimple_stmt_iterator where it inserts new code.
6265 2009-01-10 Sebastian Pop <sebastian.pop@amd.com>
6267 * gcc.dg/graphite/block-3.c: Fix compile error on 32bit.
6269 2009-01-10 Sebastian Pop <sebastian.pop@amd.com>
6271 * opts.c (decode_options): Enable flag_graphite_identity and
6272 flag_loop_block in -O2 and above.
6274 2009-01-08 Sebastian Pop <sebastian.pop@amd.com>
6276 * libjava/classpath/lib/gnu/java/awt/peer/gtk/GtkMouseInfoPeer.class:
6277 Fix merge problem: replace with the file from trunk.
6279 2009-01-08 Sebastian Pop <sebastian.pop@amd.com>
6281 * Merge from mainline (r141727:143163).
6283 2009-01-07 Sebastian Pop <sebastian.pop@amd.com>
6284 Jan Sjodin <jan.sjodin@amd.com>
6286 PR tree-optimization/38559
6287 * gcc.dg/graphite/pr38559.c: New.
6289 * graphite.c (debug_value, copy_constraint,
6290 swap_constraint_variables, scale_constraint_variable, ): New.
6291 (get_lower_bound, get_upper_bound): Removed.
6292 (graphite_trans_bb_strip_mine): Clean up this code that works
6293 only for constant number of iterations. Fully copy upper and
6294 lower bound constraints, not only the constant part of them.
6295 * graphite.h (debug_value): Declared.
6297 2009-01-06 Jan Sjodin <jan.sjodin@amd.com>
6299 PR tree-optimization/38492
6300 PR tree-optimization/38498
6301 * tree-check.c (operator_is_linear, scev_is_linear_expression): New.
6302 * tree-chrec.h (scev_is_linear_expression): Declared.
6303 * graphite.c (graphite_cannot_represent_loop_niter): New.
6304 (scopdet_basic_block_info): Call graphite_cannot_represent_loop_niter.
6305 (graphite_loop_normal_form): Use gcc_assert.
6306 (scan_tree_for_params): Use CASE_CONVERT.
6307 (phi_node_is_iv, bb_contains_non_iv_scalar_phi_nodes): New.
6308 (build_scop_conditions_1): Call bb_contains_non_iv_scalar_phi_nodes.
6309 Use gcc_assert. Discard scops that contain unhandled cases.
6310 (build_scop_conditions): Return a boolean status for unhandled cases.
6311 (strip_mine_profitable_p): Print the loop number, not its depth.
6312 (is_interchange_valid): Pass the depth of the loop nest, don't
6313 recompute it wrongly.
6314 (graphite_trans_bb_block): Same.
6315 (graphite_trans_bb_block): Print tentative of loop blocking.
6316 (graphite_trans_scop_block): Do not print that the loop has been
6318 (graphite_transform_loops): Do not handle scops that contain condition
6321 * gcc.dg/graphite/pr38500.c: Fixed warning as committed
6323 * gcc.dg/graphite/block-0.c: Update test.
6324 * gcc.dg/graphite/block-1.c: Same.
6325 * gcc.dg/graphite/block-2.c: Remove xfail and test for
6327 * gcc.dg/graphite/block-4.c: Remove test for strip mine.
6328 * gcc.dg/graphite/block-3.c: New.
6329 * gcc.dg/graphite/pr38498.c: New.
6331 2008-12-22 Harsha Jagasia <harsha.jagasia@amd.com>
6333 PR tree-optimization/38510
6334 * gcc.dg/graphite/pr38510.c: New.
6335 * graphite.c (recompute_all_dominators): Call mark_irreducible_loops.
6336 (translate_clast): Call recompute_all_dominators before
6338 (gloog): Call recompute_all_dominators before graphite_verify.
6340 2008-12-12 Sebastian Pop <sebastian.pop@amd.com>
6342 PR tree-optimization/38492
6343 * graphite.c (rename_map_elt, debug_rename_elt,
6344 debug_rename_map_1, debug_rename_map, new_rename_map_elt,
6345 rename_map_elt_info, eq_rename_map_elts,
6346 get_new_name_from_old_name, bb_in_sese_p): Moved around.
6347 (sese_find_uses_to_rename_use): Renamed sese_build_livein_liveouts_use.
6348 (sese_find_uses_to_rename_bb): Renamed sese_build_livein_liveouts_bb.
6349 (sese_build_livein_liveouts): New.
6350 (new_sese, free_sese): New.
6351 (new_scop): Call new_sese.
6352 (free_scop): Call free_sese.
6353 (rename_variables_from_edge, rename_phis_end_scop): Removed.
6354 (register_old_new_names): Renamed register_old_and_new_names.
6355 (register_scop_liveout_renames, add_loop_exit_phis,
6356 insert_loop_close_phis, struct igp,
6357 default_liveout_before_guard, add_guard_exit_phis,
6358 insert_guard_phis, copy_renames): New.
6359 (translate_clast): Call insert_loop_close_phis and insert_guard_phis.
6360 (sese_add_exit_phis_edge): Renamed scop_add_exit_phis_edge.
6361 (rewrite_into_sese_closed_ssa): Renamed scop_insert_phis_for_liveouts.
6362 (scop_adjust_phis_for_liveouts): New.
6363 (gloog): Call scop_adjust_phis_for_liveouts.
6365 * graphite.h (struct sese): Documented. Added fields liveout,
6367 (SESE_LIVEOUT, SESE_LIVEIN, SESE_LIVEIN_VER, SESE_NUM_VER): New.
6368 (new_sese, free_sese, sese_build_livein_liveouts): Declared.
6369 (struct scop): Added field liveout_renames.
6370 (SCOP_LIVEOUT_RENAMES): New.
6372 2008-12-11 Sebastian Pop <sebastian.pop@amd.com>
6374 PR tree-optimization/38409
6375 * gcc.dg/graphite/pr38409.c: New.
6376 * graphite.c (nb_reductions_in_loop): Use simple_iv.
6378 2008-12-11 Sebastian Pop <sebastian.pop@amd.com>
6380 * graphite.c (gcc_type_for_cloog_iv): By default return
6382 (graphite_create_new_loop): Don't fold_convert the already
6383 fold_convert-ed expression.
6385 2008-12-11 Harsha Jagasia <harsha.jagasia@amd.com>
6387 PR tree-optimization/38446
6388 * gcc.dg/graphite/pr38446.c: New.
6389 * graphite.c (register_bb_in_sese): New.
6390 (bb_in_sese_p): Check if bb belongs to sese region by explicitly
6391 looking at the bbs in the region.
6392 * graphite.h (sese): Add region_basic_blocks pointer set to
6393 structure and initialize at the time of defining new scop.
6395 2008-12-11 Tobias Grosser <grosser@fim.uni-passau.de>
6397 * graphite.c (new_graphite_bb): Initialize GBB_STATIC_SCHEDULE.
6398 (find_params_in_bb): Do not free data refs.
6399 (free_graphite_bb): Add FIXME on disabled free_data_refs.
6401 2008-12-11 Sebastian Pop <sebastian.pop@amd.com>
6403 * gcc.dg/graphite/scop-16.c: Test only scop specific info.
6404 * gcc.dg/graphite/scop-17.c: Same.
6405 * gcc.dg/graphite/block-5.c: New.
6406 * gcc.dg/graphite/block-6.c: New.
6407 * gcc.dg/graphite/pr37485.c: Clean dump file after.
6408 * gcc.dg/graphite/pr37684.c: Same.
6409 * gcc.dg/graphite/block-2.c: Same.
6411 * graphite.c (struct ivtype_map_elt): New.
6412 (debug_ivtype_elt, debug_ivtype_map_1, debug_ivtype_map,
6413 new_ivtype_map_elt, ivtype_map_elt_info, eq_ivtype_map_elts,
6414 gcc_type_for_cloog_iv): New.
6415 (loop_iv_stack_patch_for_consts): Use the type of the induction
6416 variable from the original loop, except for the automatically
6417 generated loops, i.e., in the case of a strip-mined loop, in
6418 which case there is no original loop: in that case just use
6420 (new_graphite_bb): Initialize GBB_CLOOG_IV_TYPES.
6421 (free_graphite_bb): Free GBB_CLOOG_IV_TYPES.
6422 (clast_name_to_gcc): Accept params to be NULL.
6423 (clast_to_gcc_expression): Take an extra parameter for the type.
6424 Convert to that type all the expressions built by this function.
6425 (gcc_type_for_clast_expr, gcc_type_for_clast_eq): New.
6426 (graphite_translate_clast_equation): Compute the type of the
6427 clast_equation before translating its LHS and RHS.
6428 (clast_get_body_of_loop, gcc_type_for_iv_of_clast_loop): New.
6429 (graphite_create_new_loop): Compute the type of the induction
6430 variable before translating the lower and upper bounds and before
6431 creating the induction variable.
6432 (rename_variables_from_edge, rename_phis_end_scop): New.
6433 (copy_bb_and_scalar_dependences): Call rename_phis_end_scop.
6434 (sese_add_exit_phis_edge): Do not use integer_zero_node.
6435 (find_cloog_iv_in_expr, compute_cloog_iv_types_1,
6436 compute_cloog_iv_types): New.
6437 (gloog): Call compute_cloog_iv_types before starting the
6438 translation of the clast.
6440 * graphite.h (struct graphite_bb): New field cloog_iv_types.
6441 (GBB_CLOOG_IV_TYPES): New.
6442 (debug_ivtype_map): Declared.
6443 (oldiv_for_loop): New.
6445 2008-12-10 Tobias Grosser <grosser@fim.uni-passau.de>
6448 * graphite.c (new_scop): Initialize SCOP_ADD_PARAMS.
6449 (param_index): Assert if parameter is not know after parameter
6451 (find_params_in_bb): Detect params directly in GBB_CONDITIONS.
6452 (find_scop_parameters): Mark, that we have finished parameter
6454 (graphite_transform_loops): Move condition detection before parameter
6456 * graphite.h (struct scop): Add SCOP_ADD_PARAMS.
6457 * gfortran.dg/graphite/pr38459.f90: New.
6459 2008-12-09 Tobias Grosser <grosser@fim.uni-passau.de>
6461 * graphite.c (graphite_transform_loops): Always call find_transform ()
6462 in ENABLE_CHECKING. So we test these code paths, even if we do not
6465 2008-12-09 Tobias Grosser <grosser@fim.uni-passau.de>
6467 * graphite.c (print_graphite_bb): Fix printing to file != dump_file.
6468 (print_scop): Ditto.
6470 2008-12-08 Tobias Grosser <grosser@fim.uni-passau.de>
6473 Fix gfortran.dg/graphite/id-3.f90.
6474 * graphite.c (scopdet_basic_block_info): Fix bug that found some
6475 regions more than once.
6477 2008-12-03 Sebastian Pop <sebastian.pop@amd.com>
6479 Fix gfortran.dg/graphite/id-4.f90.
6480 * graphite.c (scan_tree_for_params): Do not compute the multiplicand
6483 2008-12-03 Sebastian Pop <sebastian.pop@amd.com>
6485 Fix gfortran.dg/graphite/id-1.f90.
6486 * graphite.c (gmp_cst_to_tree): Pass the type in parameter.
6487 (loop_iv_stack_patch_for_consts): Update use of gmp_cst_to_tree.
6488 (max_precision_type): New.
6489 (value_clast): Removed.
6490 (clast_to_gcc_expression): Be more careful to types of expressions.
6491 Use max_precision_type and update use of gmp_cst_to_tree.
6492 (graphite_translate_clast_equation): Use max_precision_type.
6493 (graphite_create_guard_cond_expr): Do not use integer_type_node,
6494 use the type of the condition.
6495 (graphite_create_new_loop): Do not use integer_type_node, use the
6496 max_precision_type of lb and ub.
6498 2008-12-03 Sebastian Pop <sebastian.pop@amd.com>
6500 * graphite.c (build_scops_1): Initialize open_scop.exit
6503 2008-12-02 Sebastian Pop <sebastian.pop@amd.com>
6505 * gcc.dg/graphite/pr38084.c: New.
6506 * gfortran.dg/graphite/id-1.f90: New.
6507 * gfortran.dg/graphite/id-2.f90: New.
6508 * gfortran.dg/graphite/id-3.f90: New.
6509 * gfortran.dg/graphite/id-4.f90: New.
6510 * gfortran.dg/graphite/pr37857.f90: New.
6512 2008-12-02 Sebastian Pop <sebastian.pop@amd.com>
6513 Jan Sjodin <jan.sjodin@amd.com>
6514 Harsha Jagasia <harsha.jagasia@amd.com>
6526 * gcc.dg/graphite/pr38073.c: New.
6527 * gcc.dg/graphite/pr37928.c: New.
6528 * gcc.dg/graphite/pr37883.c: New.
6529 * gcc.dg/graphite/pr38125.c: New.
6530 * gfortran.dg/graphite/pr38083.f90: New.
6531 * gfortran.dg/graphite/pr37852.f90: New.
6532 * gfortran.dg/graphite/pr37980.f90: New.
6534 * gcc.dg/graphite/scop-18.c: Remove reduction, test for
6535 the number of detected scops. Copy exact same test for loop
6537 * gcc.dg/graphite/block-1.c: Fix the number of expected
6538 loops to be blocked as reductions are not handled.
6539 * gcc.dg/graphite/block-4.c: ...here. New.
6541 * tree-phinodes.c (remove_phi_nodes): New, extracted from...
6542 * tree-cfg.c (remove_phi_nodes_and_edges_for_unreachable_block):
6544 * tree-flow.h (remove_phi_nodes, canonicalize_loop_ivs): Declared.
6545 * Makefile.in (graphite.o): Depend on value-prof.h.
6546 (graphite.o-warn): Removed -Wno-error.
6547 * tree-parloops.c (canonicalize_loop_ivs): Allow reduction_list
6548 to be a NULL pointer. Call update_stmt. Return the newly created
6549 cannonical induction variable.
6551 * graphite.h (debug_rename_map): Declared. Fix some comments.
6553 * graphite.c: Reimplement the code generation from graphite to gimple.
6554 Include value-prof.h.
6555 (loop_iv_stack_get_iv): Do not return NULL for constant substitutions.
6556 (get_old_iv_from_ssa_name): Removed.
6557 (graphite_stmt_p): New.
6558 (new_graphite_bb): Test for useful statements before building a
6559 graphite statement for the basic block.
6560 (free_graphite_bb): Do not free GBB_DATA_REFS: this is a bug
6561 in free_data_ref that calls BITMAP_FREE (DR_VOPS (dr)) without
6563 (recompute_all_dominators, graphite_verify,
6564 nb_reductions_in_loop, graphite_loop_normal_form): New.
6565 (scop_record_loop): Call graphite_loop_normal_form.
6566 (build_scop_loop_nests): Iterate over all the blocks of the
6567 function instead of relying on the incomplete information from
6568 SCOP_BBS. Return the success of the operation.
6569 (find_params_in_bb): Use the data from GBB_DATA_REFS.
6570 (add_bb_domains): Removed.
6571 (build_loop_iteration_domains): Don't call add_bb_domains.
6572 Add the iteration domain only to the basic blocks that have been
6573 translated to graphite.
6574 (build_scop_conditions_1): Add constraints only if the basic
6575 block have been translated to graphite.
6576 (build_scop_data_accesses): Completely disabled until data
6577 dependence is correctly implemented.
6578 (debug_rename_elt, debug_rename_map_1, debug_rename_map): New.
6579 (remove_all_edges_1, remove_all_edges): Removed.
6580 (get_new_name_from_old_name): New.
6581 (graphite_rename_variables_in_stmt): Renamed
6582 rename_variables_in_stmt. Call get_new_name_from_old_name.
6583 Use replace_exp and update_stmt.
6584 (is_old_iv): Renamed is_iv.
6585 (expand_scalar_variables_stmt): Extra parameter for renaming map.
6586 Use replace_exp and update_stmt.
6587 (expand_scalar_variables_expr): Same. Use the map to get the
6588 new names for the renaming of induction variables and for the
6589 renaming of variables after a basic block has been copied.
6590 (expand_scalar_variables): Same.
6591 (graphite_rename_variables): Renamed rename_variables.
6592 (move_phi_nodes): Removed.
6593 (get_false_edge_from_guard_bb): New.
6594 (build_iv_mapping): Do not insert the induction variable of a
6595 loop in the renaming iv map if the basic block does not belong
6597 (register_old_new_names, graphite_copy_stmts_from_block,
6598 copy_bb_and_scalar_dependences): New.
6599 (translate_clast): Heavily reimplemented: copy basic blocks,
6600 do not move them. Finally, in call cleanup_tree_cfg in gloog.
6601 At each translation step call graphite_verify ensuring the
6602 consistency of the SSA, loops and dominators information.
6603 (collect_virtual_phis, find_vdef_for_var_in_bb,
6604 find_vdef_for_var_1, find_vdef_for_var,
6605 patch_phis_for_virtual_defs): Removed huge hack.
6606 (mark_old_loops, remove_dead_loops, skip_phi_defs,
6607 collect_scop_exit_phi_args, patch_scop_exit_phi_args,
6608 gbb_can_be_ignored, scop_remove_ignoreable_gbbs, ): Removed.
6609 (remove_sese_region, ifsese, if_region_entry, if_region_exit,
6610 if_region_get_condition_block, if_region_set_false_region,
6611 create_if_region_on_edge, move_sese_in_condition, bb_in_sese_p,
6612 sese_find_uses_to_rename_use, sese_find_uses_to_rename_bb,
6613 sese_add_exit_phis_edge, sese_add_exit_phis_var,
6614 rewrite_into_sese_closed_ssa): New.
6615 (gloog): Remove dead code. Early return if code cannot be
6616 generated. Call cleanup_tree_cfg once the scop has been code
6618 (graphite_trans_scop_block, graphite_trans_loop_block): Do not
6619 block loops with less than two loops.
6620 (graphite_apply_transformations): Remove the call to
6621 scop_remove_ignoreable_gbbs.
6622 (limit_scops): When build_scop_loop_nests fails, continue on
6623 the next scop. Fix open_scop.entry.
6624 (graphite_transform_loops): Call recompute_all_dominators: force the
6625 recomputation of correct CDI_DOMINATORS and CDI_POST_DOMINATORS.
6626 Call initialize_original_copy_tables and free_original_copy_tables
6627 to be able to copy basic blocks during code generation.
6628 When build_scop_loop_nests fails, continue on next scop.
6629 (value_clast): New union.
6630 (clast_to_gcc_expression): Fix type cast warning.
6632 2008-11-09 Sebastian Pop <sebastian.pop@amd.com>
6634 * Merge from mainline (r140838:141727).
6636 2008-11-05 Tobias Grosser <grosser@fim.uni-passau.de>
6640 * graphite.c (scan_tree_for_params): Add POINTER_PLUS_EXPR.
6642 2008-11-05 Tobias Grosser <grosser@fim.uni-passau.de>
6646 * graphite.c (scopdet_basic_block_info): Fix loops with multiple
6647 exits and conditions.
6648 * gcc.dg/graphite/pr37943.c: New.
6650 2008-10-23 Tobias Grosser <grosser@fim.uni-passau.de>
6653 * graphite.c (gloog): Replace EXIT_BLOCK_PTR with scop exit.
6655 2008-10-23 Tobias Grosser <grosser@fim.uni-passau.de>
6657 * doc/invoke.texi: Fix spaces.
6659 2008-10-22 Sebastian Pop <sebastian.pop@amd.com>
6661 PR tree-optimization/37891
6662 Reverted last commit.
6663 * graphite.c (create_single_entry_edge): Set
6664 EDGE_IRREDUCIBLE_LOOP and BB_IRREDUCIBLE_LOOP.
6666 2008-10-21 Sebastian Pop <sebastian.pop@amd.com>
6667 Mitul Thakkar <mitul.thakkar@amd.com>
6669 * graphite.c (create_single_entry_edge): Set
6670 EDGE_IRREDUCIBLE_LOOP and BB_IRREDUCIBLE_LOOP.
6672 2008-10-16 Tobias Grosser <grosser@fim.uni-passau.de>
6674 * doc/invoke.texi: Add -fgraphite-identity.
6675 * graphite.c (graphite_apply_transformations): Check for
6676 -fgraphite-identity.
6677 * toplev.c (process_options): Add flag_graphite_identity.
6678 * tree-ssa-loop.c: Add flag_graphite_identity.
6680 2008-10-14 Sebastian Pop <sebastian.pop@amd.com>
6682 Undo changes from 2008-10-02:
6683 * tree-ssa-loop-ivopts.c (rewrite_use_nonlinear_expr): Convert
6684 operand type when copying the operand to a variable of different type.
6685 * cfgloopmanip.c (create_empty_loop_on_edge): Write exit condition
6686 with the IV name after increment.
6688 2008-10-14 Sebastian Pop <sebastian.pop@amd.com>
6689 Harsha Jagasia <harsha.jagasia@amd.com>
6691 PR tree-optimization/37828
6692 * gcc.dg/graphite/pr37828.c: New.
6693 * graphite.c (graphite_trans_loop_block): Do not loop block
6694 single nested loops.
6696 2008-10-09 Harsha Jagasia <harsha.jagasia@amd.com>
6697 Sebastian Pop <sebastian.pop@amd.com>
6699 * graphite.c (struct rename_map_elt, new_rename_map_elt,
6700 rename_map_elt_info, eq_rename_map_elts): New.
6701 (graphite_rename_ivs_stmt): Renamed graphite_rename_variables_in_stmt.
6702 (expand_scalar_variables_expr): Change parameters.
6703 (expand_scalar_variables_stmt): Same.
6704 (expand_scalar_variables): Same.
6705 (graphite_rename_ivs): Rename graphite_rename_variables.
6706 (build_iv_mapping): New.
6707 (translate_clast): Call build_iv_mapping.
6708 * graphite.h (gbb_p): New name.
6710 2008-10-03 Harsha Jagasia <harsha.jagasia@amd.com>
6712 PR tree-optimization/37684
6713 * gcc.dg/graphite/pr37684.c: New.
6714 * graphite.c (exclude_component_ref): New.
6715 (is_simple_operand): Call exclude_component_ref.
6717 2008-10-02 Jan Sjodin <jan.sjodin@amd.com>
6718 Harsha Jagasia <harsha.jagasia@amd.com>
6720 PR tree-optimization/37485
6721 * gcc.dg/graphite/block-2.c: New
6722 * graphite.c (gmp_cst_to_tree): Moved.
6723 (iv_stack_entry_is_constant): New.
6724 (iv_stack_entry_is_iv): New.
6725 (loop_iv_stack_push): Renamed to loop_iv_stack_push_iv.
6726 (loop_iv_stack_insert_constant): New.
6727 (loop_iv_stack_pop): Use new datatpype.
6728 (loop_iv_stack_get_iv): Same.
6729 (loop_iv_stack_get_iv_from_name): Same.
6730 (loop_iv_stack_debug): Renamed to debug_loop_iv_stack.
6731 (loop_iv_stack_patch_for_consts): New.
6732 (loop_iv_stack_remove_constants): New.
6733 (graphite_create_new_loop): Use loop_iv_stack_push_iv.
6734 (translate_clast): Call loop_iv_stack_patch_for_consts and
6735 loop_iv_stack_remove_constants.
6736 (gloog): Use new datatype. Redirect construction edge to end
6737 block to avoid accidental deletion.
6738 * graphite.h (enum iv_stack_entry_kind): New. Tag for data in
6740 (union iv_stack_entry_data): New. Data in iv stack entry.
6741 (struct iv_stack_entry): New. Datatype for iv stack entries.
6743 2008-10-02 Sebastian Pop <sebastian.pop@amd.com>
6745 * tree-ssa-loop-ivopts.c (rewrite_use_nonlinear_expr): Convert
6746 operand type when copying the operand to a variable of different type.
6748 2008-10-02 Sebastian Pop <sebastian.pop@amd.com>
6750 * cfgloopmanip.c (create_empty_loop_on_edge): Write exit condition
6751 with the IV name after increment.
6753 2008-10-02 Sebastian Pop <sebastian.pop@amd.com>
6755 * Merge from mainline (r140164:140838).
6757 2008-09-10 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6759 * graphite-data-ref.c: New.
6760 * graphite.c (print_scop): Also dump the dependence graph.
6761 (bb_in_scop_p, loop_in_scop_p, nb_loops_around_gb): Moved...
6762 (new_scop): Initialize SCOP_DEP_GRAPH.
6763 (build_scop_dynamic_schedules): New.
6764 (build_access_matrix_with_af): Fixed column numbering.
6765 (graphite_transform_loops): Call build_scop_dynamic_schedules.
6766 * graphite.h: Add ifndef/define guards against multiple inclusion.
6767 (struct scop): Add dep_graph field.
6768 (SCOP_DEP_GRAPH): Defined.
6769 (ref_nb_loops): Fixed and moved to other position.
6770 (bb_in_scop_p, loop_in_scop_p, nb_loops_around_gb): ... here.
6771 (nb_loops_around_loop_in_scop): New.
6772 (graphite_dump_dependence_graph): Declared.
6773 (graphite_build_rdg_all_levels): Declared.
6774 (graphite_test_dependence): Declared.
6775 * Makefile.in (graphite-data-ref.o): New target.
6777 2008-09-09 Sebastian Pop <sebastian.pop@amd.com>
6779 * Merge from mainline (139870:140164).
6781 2008-09-01 Sebastian Pop <sebastian.pop@amd.com>
6783 * Merge from mainline (138275:139870).
6784 * gcc.dg/graphite/scop-matmult.c: XFailed as one of
6785 the commits from trunk broke the niter detection.
6787 2008-09-01 Sebastian Pop <sebastian.pop@amd.com>
6789 * graphite.c: Add more documentation. Fix formatting.
6790 (debug_loop_vec, debug_oldivs, loop_iv_stack,
6791 loop_iv_stack_debug): Moved...
6792 (schedule_to_scattering): Move before use.
6793 (dot_all_scops): Include in "#if 0" the code for system
6796 * graphite.h: (debug_loop_vec, debug_oldivs, loop_iv_stack,
6797 loop_iv_stack_debug): ...here.
6799 2008-08-29 Jan Sjodin <jan.sjodin@amd.com>
6801 * tree-phinodes.c (make_phi_node): Extern.
6802 (add_phi_node_to_bb): New.
6803 (create_phi_node): Call add_phi_node_to_bb.
6804 * tree-ssa-loop-ivopts.c (get_phi_with_result): New.
6805 (remove_statement): Handle case where stored phi was updated
6806 and is no longer the same.
6807 * graphite.c (is_parameter): New.
6809 (expand_scalar_variables_expr): New.
6810 (expand_scalar_variables_stmt): New.
6811 (expand_scalar_variables): New.
6812 (move_phi_nodes): Create new phi instead of moving old one.
6813 (translate_clast): Call expand_scalar_variables.
6814 (find_vdef_for_var_in_bb): Also scan regular definitions.
6815 (skip_phi_defs): New.
6816 (collect_scop_exit_phi_args): New.
6817 (patch_scop_exit_phi_args): New.
6818 (gloog): Patch phis after scop.
6819 * tree-flow.h: (add_phi_node_to_bb): Declared.
6820 (make_phi_node): Declared.
6822 2008-08-26 Sebastian Pop <sebastian.pop@amd.com>
6824 * graphite.c (end_scop): Split the entry of the scop when it
6825 is the header of the loop in which the scop is ending.
6826 (build_scops_1, limit_scops): Update uses of end_scop.
6828 2008-08-26 Sebastian Pop <sebastian.pop@amd.com>
6830 * graphite.c (dot_all_scops_1): Do not fail on uninitialized
6831 SCOP_ENTRY or SCOP_EXIT.
6833 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
6835 * graphite.c (get_construction_edge): Removed.
6836 (gloog): Construction edge is the scop entry edge.
6838 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
6840 * graphite.c (can_generate_for_scop): Removed.
6841 (gloog): Do not call it.
6843 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
6845 * graphite.c (new_scop): Entry of a scop is an edge.
6846 Initialize SESE region.
6847 (free_scop): Free SESE region.
6848 (build_scops_1, scopdet_bb_info): Work on edges, not on bbs.
6849 (split_difficult_bb): New, split from end_scop.
6850 (end_scop): Exit of a scop is an edge.
6851 (build_scop_bbs): Never check CDI_POST_DOMINATORS: this info is
6852 not automatically updated and thus is always wrong.
6853 * graphite.h (struct sese): New.
6856 (struct scop): New field for a SESE region. Remove entry, exit.
6857 (SCOP_ENTRY, SCOP_EXIT): Update definitions to match same
6858 semantics as before. Moved comment around.
6860 2008-08-25 Tobias Grosser <grosser@fim.uni-passau.de>
6861 Sebastian Pop <sebastian.pop@amd.com>
6863 * graphite.c (graphite_transform_loops): Always enable gloog
6864 and find_transform when ENABLE_CHECKING.
6866 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
6868 * graphite.c (graphite_transform_loops): Move pretty printer
6869 of SCOPs before doing any transform. Remove call to print_scops
6870 and dot_all_scops_1.
6872 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
6874 * graphite.c (dump_gbb_conditions): Don't try to print NULL pointers.
6875 (print_graphite_bb): Same.
6877 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
6879 * graphite.c (dot_all_scops_1): Cleanup.
6880 (move_scops): Fix comment.
6882 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
6884 * graphite.c (build_scop_bbs): Revert commit 139355:
6886 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
6887 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
6889 * graphite.c (build_scop_bbs): Factor up code.
6891 2008-08-25 Tobias Grosser <grosser@fim.uni-passau.de>
6893 * graphite.c (gloog): Update dominator info.
6895 2008-08-25 Tobias Grosser <grosser@fim.uni-passau.de>
6897 * graphite.c (remove_cond_exprs): Do not fail on empty bbs.
6899 2008-08-24 Sebastian Pop <sebastian.pop@amd.com>
6901 * graphite.c (new_graphite_bb): Remove GBB_INDEX_TO_NUM_MAP
6903 (free_graphite_bb): Remove GBB_INDEX_TO_NUM_MAP free.
6904 (translate_clast): Correct formatting.
6905 * graphite.h (struct num_map): Removed.
6906 (struct graphite_bb): Remove num_map field.
6907 (GBB_INDEX_TO_NUM_MAP): Removed.
6909 2008-08-24 Sebastian Pop <sebastian.pop@amd.com>
6911 * graphite.c (build_access_matrix_with_af): Fix comments.
6912 (build_scop_data_accesses): Same.
6914 2008-08-24 Sebastian Pop <sebastian.pop@amd.com>
6916 * graphite.c (build_scop_data_accesses): Don't construct
6917 access matrices. Add a FIXME and an assert condition that
6918 should pass when the access matrices will be needed.
6920 2008-08-24 Sebastian Pop <sebastian.pop@amd.com>
6922 * tree-data-ref.c (stmt_simple_memref_p): Don't call
6924 * graphite.c (build_graphite_bb): Renamed new_graphite_bb.
6925 Moved close by free_graphite_bb.
6926 (free_graphite_bb): Call free_data_refs. Reset bb->aux.
6927 (new_scop): Move close by free_scop.
6928 (graphite_transform_loops): Avoid linear scan to reset bb->aux.
6930 2008-08-22 Jan Sjodin <jan.sjodin@amd.com>
6932 * cfgloopmanip.c (create_empty_if_region_on_edge): New.
6933 * graphite.c (clast_to_gcc_expression): Call gmp_cst_to_tree
6934 instead of recursive call.
6935 (graphite_translate_clast_equation): New.
6936 (graphite_create_guard_cond_expr): New.
6937 (graphite_create_new_guard): New.
6938 (get_stack_index_from_iv): Removed.
6939 (graphite_rename_ivs_stmt): Use gbb_loop_index.
6940 (get_true_edge_from_guard_bb): New.
6941 (translate_clast): Handle stmt_guard in clast.
6942 (get_construction_edge): Allow construction edge detection for
6943 a scope entry with multiple predecessors if one predecessor is
6944 the immediate dominator of scope entry.
6945 (can_generate_code_stmt): Enable code generation for clast_guard.
6946 (gloog): Use correct context loop. Removed check for post dominators.
6947 * cfgloop.h (create_empty_if_region_on_edge): Declared.
6949 2008-08-21 Sebastian Pop <sebastian.pop@amd.com>
6951 * graphite.c (remove_dead_loops): Document better which
6954 2008-08-21 Sebastian Pop <sebastian.pop@amd.com>
6956 * Makefile.in: Rename POLYLIBLIBS and POLYLIBINC to PPLLIBS
6958 (graphite.o): Also depends on pointer-set.h.
6960 2008-08-21 Sebastian Pop <sebastian.pop@amd.com>
6962 * graphite.c (scop_record_loop): Fix compile warning.
6964 2008-08-21 Harsha Jagasia <harsha.jagasia@amd.com>
6965 Sebastian Pop <sebastian.pop@amd.com>
6967 * graphite.c (scop_record_loop): DECL_NAME can be NULL.
6969 2008-08-21 Sebastian Pop <sebastian.pop@amd.com>
6971 * graphite.c (build_graphite_bb): Initialize bb->aux to
6972 point to the graphite_bb_p.
6973 (graphite_bb_from_bb): Renamed gbb_from_bb; returns the
6975 (add_bb_domains): Does not use the scop parameter.
6976 (graphite_transform_loops): Clean bb->aux at the end.
6978 2008-08-20 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
6979 Sebastian Pop <sebastian.pop@amd.com>
6981 * lib/target-supports.exp
6982 (check_effective_target_fgraphite): New.
6984 * gcc.dg/graphite/graphite.exp: Early exit when
6985 check_effective_target_fgraphite returns false.
6986 Set dg-do-what-default to compile.
6987 (scan-graphite-dump-times): Removed.
6988 * gfortran.dg/graphite/graphite.exp: Same.
6990 * gcc.dg/graphite/scop-0.c: Do not use "dg-do compile".
6991 Use scan-tree-dump-times instead of scan-graphite-dump-times.
6992 * gcc.dg/graphite/scop-1.c: Same.
6993 * gcc.dg/graphite/scop-2.c: Same.
6994 * gcc.dg/graphite/scop-3.c: Same.
6995 * gcc.dg/graphite/scop-4.c: Same.
6996 * gcc.dg/graphite/scop-5.c: Same.
6997 * gcc.dg/graphite/scop-6.c: Same.
6998 * gcc.dg/graphite/scop-7.c: Same.
6999 * gcc.dg/graphite/scop-8.c: Same.
7000 * gcc.dg/graphite/scop-9.c: Same.
7001 * gcc.dg/graphite/scop-10.c: Same.
7002 * gcc.dg/graphite/scop-11.c: Same.
7003 * gcc.dg/graphite/scop-12.c: Same.
7004 * gcc.dg/graphite/scop-13.c: Same.
7005 * gcc.dg/graphite/scop-matmult.c: Same.
7006 * gcc.dg/graphite/scop-14.c: Same.
7007 * gcc.dg/graphite/scop-15.c: Same.
7008 * gcc.dg/graphite/block-0.c: Same.
7009 * gcc.dg/graphite/scop-16.c: Same.
7010 * gcc.dg/graphite/block-1.c: Same.
7011 * gcc.dg/graphite/scop-17.c: Same.
7012 * gcc.dg/graphite/scop-18.c: Same.
7013 * gfortran.dg/graphite/block-1.f90: Same.
7014 * gfortran.dg/graphite/scop-1.f: Same.
7015 * gfortran.dg/graphite/block-2.f: Same.
7017 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
7019 * graphite.c: Fix some XXX comments.
7020 (build_scop_dynamic_schedules): Removed.
7022 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
7024 * graphite.h (scop_max_loop_depth): Moved...
7025 * graphite.c (scop_max_loop_depth): ...here.
7026 (remove_all_edges_1): New.
7027 (remove_all_edges): Factored code.
7028 (remove_cond_exprs): Check only the last statement for
7029 a GIMPLE_COND expression.
7031 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
7033 * graphite.c (scan_tree_for_params): Early return when the
7034 expression is a chrec_dont_know. Handle case NEGATE_EXPR.
7035 (find_scop_parameters): Factor out code.
7036 (graphite_trans_bb_strip_mine): Remove dead code.
7038 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
7040 * graphite.c (clast_to_gcc_expression, graphite_create_new_loop,
7041 graphite_trans_bb_move_loop): Factor asserts.
7042 (gloog): Perform sanity checks only for ENABLE_CHECKING.
7043 Do not call calculate_dominance_info and estimate_bb_frequencies.
7045 2008-08-20 Jan Sjodin <jan.sjodin@amd.com>
7047 * graphite.c (create_loops_mapping, free_loops_mapping,
7048 create_loops_mapping_num, debug_loop_mapping_1,
7049 debug_loop_mapping, graphite_loops_mapping_max_loop_num,
7050 get_loop_mapping_for_num, graphite_loops_mapping_add_child,
7051 graphite_loops_mapping_add_child_num,
7052 graphite_loops_mapping_insert_child,
7053 graphite_loops_mapping_parent, get_loop_mapped_depth_for_num,
7054 get_loop_mapped_depth, split_loop_mapped_depth_for_num,
7055 loop_mapped_depth_split_loop, swap_loop_mapped_depth_for_num,
7056 create_num_from_index, get_num_from_index,
7057 swap_loop_mapped_depth): Removed.
7058 (new_scop): Do not initialize SCOP_LOOPS_MAPPING.
7059 (free_scop): Do not call free_loops_mapping.
7060 (graphite_get_new_iv_stack_index_from_old_iv): Renamed
7061 get_stack_index_from_iv. Use GBB_LOOPS instead of calling
7062 get_loop_mapped_depth.
7063 (graphite_trans_bb_move_loop): Do not update the loop mapping.
7064 (graphite_trans_bb_strip_mine): Same.
7065 * graphite.h (graphite_loops_mapping, graphite_loop_node): Removed.
7066 (struct scop): Remove field loops_mapping.
7068 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
7069 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
7071 * graphite.c (scop_record_loop): Factor out one level of the
7072 condition by early return.
7073 (build_scop_loop_nests): Format following FSF coding style.
7074 (build_scop_dynamic_schedules): Factor out code.
7075 (scopdet_bb_info): Reindent. Default case should not be reachable.
7077 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
7078 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
7080 * graphite.c (loop_affine_expr): Check for DECL_P or struct
7081 assignments that are not handled as simple operands for now.
7083 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
7084 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
7086 * graphite.c (build_scop_bbs): Factor up code.
7088 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
7089 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
7091 * graphite.c (stmt_simple_for_scop_p): Factor code out
7093 (enum gbb_type): New. Group all the GBB_* types under it.
7094 (is_loop_exit): Moved...
7095 (end_scop): Enable BB spliting.
7096 * cfgloop.c (is_loop_exit): ...here. Reimplemented.
7097 * cfgloop.h (is_loop_exit): Declared.
7099 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
7101 * doc/invoke.texi: Remove strides from examples containing
7102 DO loops when the strides are equal to 1.
7104 2008-08-20 Harsha Jagasia <harsha.jagasia@amd.com>
7105 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
7107 * graphite.c (graphite_trans_scop_block): Or the result with
7108 the result from graphite_trans_loop_block.
7109 * gcc.dg/graphite/block-1.c: New.
7110 * gfortran.dg/graphite/block-1.f90: New.
7111 * gfortran.dg/graphite/block-2.f: New.
7113 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
7115 * graphite.c (graphite_transform_loops): Call cloog_initialize
7118 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
7120 * tree-data-ref.c) (stmt_simple_memref_p): New.
7121 * tree-data-ref.h (stmt_simple_memref_p): Declared.
7122 * graphite.c (stmt_simple_memref_for_scop_p): Removed.
7123 (is_simple_operand): Call stmt_simple_memref_p.
7125 * gcc.dg/graphite/scop-matmult.c: Updated for not
7126 using pointer arithmetic, as this is optimized by PRE and
7127 makes the code too difficult to analyze.
7129 * gcc.dg/graphite/scop-18.c: Same.
7131 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
7133 * gdbinit.in (pgg): New.
7135 2008-08-15 Tobias Grosser <grosser@fim.uni-passau.de>
7137 * graphite.c (graphite_trans_loop_block): Fix warning.
7139 2008-08-15 Tobias Grosser <grosser@fim.uni-passau.de>
7141 * graphite.c (graphite_trans_loop_block): Fix my merge error.
7143 2008-08-15 Tobias Grosser <grosser@fim.uni-passau.de>
7145 * graphite.c (graphite_trans_bb_block): Remove check for
7146 flag_loop_strip_mine, flag_loop_block, flag_loop_interchange.
7147 Check if loop blocking is profitable for every loop, before applying
7149 (graphite_apply_transformations): Call graphite_trans_bb_block only,
7150 if flag_loop_block is set.
7152 2008-08-14 Sebastian Pop <sebastian.pop@amd.com>
7154 * graphite.c: Add some more documentation for the loop
7157 2008-08-14 Sebastian Pop <sebastian.pop@amd.com>
7159 * Makefile.in (tree-data-ref.o): Remove dependence on graphite.h.
7160 * graphite.c: Format on less than 80 columns.
7163 2008-08-14 Sebastian Pop <sebastian.pop@amd.com>
7165 * cfgloopmanip.c (loopify): Use update_dominators_in_loop.
7167 2008-08-14 Sebastian Pop <sebastian.pop@amd.com>
7169 * doc/invoke.texi (floop-block, floop-strip-mine,
7170 floop-interchange): Update documentation with examples.
7172 2008-08-13 Sebastian Pop <sebastian.pop@amd.com>
7174 * cfgloopmanip.c (create_empty_loop_on_edge): Don't call
7176 * graphite.c (graphite_create_new_loop): Call add_referenced_var.
7178 2008-08-13 Sebastian Pop <sebastian.pop@amd.com>
7180 * cfgloopmanip.c (create_empty_loop_on_edge): Improve documentation.
7181 Factor gcc_asserts into a single one. Use force_gimple_operand_gsi.
7182 * tree-scalar-evolution.c: Revert useless changes.
7183 * tree-phinodes.c: Same.
7186 * tree-vectorizer.h: Same.
7187 * tree-flow.h: Same.
7189 * common.opt (fgraphite): Update documentation.
7191 2008-08-12 Harsha Jagasia <harsha.jagasia@amd.com>
7193 * doc/invoke.texi (-floop-block, -floop-strip-mine,
7194 -floop-interchange): Add more text for explaining what each of these
7196 * tree-into-ssa.c (gimple_vec): Moved to...
7197 * graphite.c: Include gimple.h.
7198 (gimple_vec): Moved to...
7199 (del_loop_to_cloog_loop): Removed.
7200 (loop_affine_expr): Do not call create_data_ref when the
7201 operand is a constant.
7202 (new_scop): Use free instead of del_loop_to_cloog_loop.
7203 * Makefile.in (graphite.o): Depend on GIMPLE_H.
7204 * gimple.h (gimple_vec): ... here.
7206 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
7208 * graphite.c (scopdet_bb_info): Only allow loops with known number of
7210 (build_loop_iteration_domains): Fail, if latch executions unknown.
7212 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
7214 * graphite.c (add_conditions_to_domain): New.
7215 (build_scop_conditions_1): Call add_conditions_to_domain.
7216 (set_cloog_options): Allow to disable optimizations.
7218 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
7220 * graphite.c (find_params_in_bb): Look for parameters in conditions.
7221 Do not use walk_dominator_tree.
7222 (find_scop_parameters): Do not use walk_dominator_tree.
7224 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
7226 * graphite.c (scan_tree_for_params) Add / Subtract inequality.
7227 (idx_record_params): Adapt.
7228 * graphite.h (scop_gimple_loop_depth): New.
7230 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
7232 * graphite.c (build_scop_dynamic_schedules): Remove value_init.
7233 (scan_tree_for_params): Remove value_init.
7234 (build_scop_context): Remove value_init.
7235 (build_loop_iteration_domains): Remove value_init.
7236 (schedule_to_scattering): Remove value_init.
7237 (graphite_trans_bb_strip_mine): Remove value_init.
7239 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
7241 * gcc/graphite.c (limit_scops): New.
7242 (graphite_transform_loops): Add limit SCoPs.
7243 * gcc.dg/graphite/scop-0.c: Update number of SCoPs.
7244 * gcc.dg/graphite/scop-1.c: Update number of SCoPs.
7245 * gcc.dg/graphite/scop-10.c: Update number of SCoPs.
7246 * gcc.dg/graphite/scop-11.c: Update number of SCoPs.
7247 * gcc.dg/graphite/scop-12.c: Update number of SCoPs.
7248 * gcc.dg/graphite/scop-13.c: Update number of SCoPs.
7249 * gcc.dg/graphite/scop-14.c: Update number of SCoPs.
7250 * gcc.dg/graphite/scop-15.c: Update number of SCoPs.
7251 * gcc.dg/graphite/scop-16.c: Update number of SCoPs.
7252 Change loop numbers.
7253 * gcc.dg/graphite/scop-17.c: Update number of SCoPs.
7254 Change loop numbers.
7255 * gcc.dg/graphite/scop-18.c: Update number of SCoPs.
7256 * gcc.dg/graphite/scop-2.c: Update number of SCoPs.
7257 * gcc.dg/graphite/scop-3.c: Update number of SCoPs.
7258 * gcc.dg/graphite/scop-4.c: Update number of SCoPs.
7259 * gcc.dg/graphite/scop-5.c: Update number of SCoPs.
7260 * gcc.dg/graphite/scop-6.c: Update number of SCoPs.
7261 * gcc.dg/graphite/scop-7.c: Update number of SCoPs.
7262 * gcc.dg/graphite/scop-8.c: Update number of SCoPs.
7263 * gcc.dg/graphite/scop-9.c: Update number of SCoPs.
7264 * gcc.dg/graphite/scop-matmult.c: Update number of SCoPs.
7266 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
7268 * graphite.c (graphite_transform_loops): Call always find_transform.
7270 2008-08-08 Tobias Grosser <grosser@fim.uni-passau.de>
7272 * graphite.c (free_loops_mapping): New.
7273 (stmt_simple_for_scop_p): Fix typo.
7274 (stmt_simple_for_scop_p): Fix tuples functions, that
7276 (free_graphite_bb): Fix some memleaks.
7277 (free_scop): Fix some memleaks.
7278 (scopdet_bb_info): Do not forget some tmp SCoPs.
7279 (find_params_in_bb): Fix some memleaks.
7280 (clast_to_gcc_expression): Fix warning.
7282 2008-08-07 Tobias Grosser <grosser@fim.uni-passau.de>
7284 * gcc.dg/graphite/scop-16.c: Fix for 32bit.
7285 * gcc.dg/graphite/scop-17.c: Fix for 32bit.
7287 2008-08-04 Sebastian Pop <sebastian.pop@amd.com>
7289 * tree-ssa-loop.c (tree-ssa-loop.o): Do not include toplev.h.
7290 Move code ifdef-ed HAVE_cloog...
7291 * graphite.c: Include toplev.h.
7293 * Makefile.in (OBJS-common): Always build graphite.o.
7294 (BACKEND): Remove @GRAPHITE@.
7295 (tree-ssa-loop.o): Do not depend on TOPLEV_H.
7296 (graphite.o): Depend on TOPLEV_H.
7298 2008-08-04 Sebastian Pop <sebastian.pop@amd.com>
7300 * Makefile.in (tree-ssa-loop.o): Depend on TOPLEV_H.
7301 Remove typo left from polylib to ppl conversion.
7302 * graphite.c (graphite_transforms): Use sorry instead of fatal.
7304 2008-08-03 Sebastian Pop <sebastian.pop@amd.com>
7306 * toplev.c (process_options): Move the graphite loop optimization
7308 * tree-ssa-loop.c (graphite_transforms): ... here.
7309 When not configured with CLooG, print to dump_file that
7310 Graphite transforms were not performed.
7311 * gcc.dg/graphite/graphite.exp (scan-graphite-dump-times):
7313 * gcc.dg/graphite/*.c: Updated all testcases to use
7314 scan-graphite-dump-times.
7316 2008-08-03 Sebastian Pop <sebastian.pop@amd.com>
7318 * graphite.c (dot_scop, dot_all_scops): Do not call system.
7319 Do not open /tmp/scop.dot and /tmp/allscops.dot.
7321 2008-08-02 Sebastian Pop <sebastian.pop@amd.com>
7322 Jan Sjodin <jan.sjodin@amd.com>
7324 * configure: Regenerated.
7325 * omp-low.c (expand_omp_sections): Remove now unused code.
7326 * config.in (HAVE_polylib): Removed.
7327 * configure.ac (HAVE_polylib, POLYLIBLIBS, POLYLIBINC): Removed.
7328 (PPLLIBS, PPLINC): Added.
7329 * graphite.c: Replace unsigned with int wherever possible.
7330 Don't access Cloog's data structures, but use accessor functions.
7331 Clast's stmt->type is now implemented as a vtable: change the
7332 switches of stmt->type into ifs.
7333 (polylib/polylibgmp.h): Don't include.
7334 (initialize_dependence_polyhedron,
7335 initialize_data_dependence_polyhedron, is_empty_polyhedron,
7336 statement_precedes_p, test_dependence, build_rdg_all_levels,
7337 dump_dependence_graph): Removed until this code is cleaned up
7339 * Makefile.in (POLYLIBLIBS): Renamed PPLLIBS.
7340 (POLYLIBINC): Renamed PPLINC.
7342 2008-08-01 Harsha Jagasia <harsha.jagasia@amd.com>
7343 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
7344 Jan Sjodin <jan.sjodin@amd.com>
7346 Finish the merge and tuplification of graphite.
7348 2008-07-24 Sebastian Pop <sebastian.pop@amd.com>
7349 Jan Sjodin <jan.sjodin@amd.com>
7351 Partial merge from mainline (138072:138275).
7352 * graphite.c still has to be tuplified.
7354 2008-07-29 Jan Sjodin <jan.sjodin@amd.com>
7356 * graphite.c (graphite_loops_mapping_max_loop_num): New.
7357 (create_num_from_index): New.
7358 (get_num_from_index): Also pass in the graphite BB.
7359 (free_graphite_bb): Free GBB_INDEX_TO_NUM_MAP.
7360 (build_graphite_bb): Initialize GBB_INDEX_TO_NUM_MAP.
7361 (graphite_trans_bb_strip_mine): Call create_num_from_index.
7362 (is_interchange_valid): Return false when failing.
7363 * graphite.h (struct num_map): New.
7364 (struct graphite_bb): New field num_map.
7365 (GBB_LOOPS_MAPPING): Renamed GBB_INDEX_TO_NUM_MAP.
7367 2008-07-29 Tobias Grosser <grosser@fim.uni-passau.de>
7369 * graphite.c (dump_gbb_conditions): Print also conditions like
7370 "if (a)". Remove dublicated code and use print_generic_expr ().
7371 (stmt_simple_for_scop_p): Only allow conditions we can handle
7374 2008-07-25 Jan Sjodin <jan.sjodin@amd.com>
7376 * graphite.h (struct scop): Removed new_ivs field.
7377 (SCOP_NEWIVS): Deleted.
7378 * graphite.c (new_scop, free_scop, clast_name_to_gcc,
7379 clast_to_gcc_expression, graphite_create_new_loop):
7380 Removed use of new_ivs.
7382 2008-07-25 Jan Sjodin <jan.sjodin@amd.com>
7384 * graphite.c (debug_oldivs, debug_loop_vec, create_loops_mapping,
7385 create_loops_mapping_num, debug_loop_mapping_1): New.
7386 (debug_loop_mapping): Call debug_loop_mapping_1.
7387 (get_loop_mapping_for_num,
7388 graphite_loops_mapping_add_child,
7389 graphite_loops_mapping_add_child_num,
7390 graphite_loops_mapping_insert_child,
7391 graphite_loops_mapping_parent,
7392 split_loop_mapped_depth_for_num,
7393 loop_mapped_depth_split_loop): New.
7394 (increment_loop_mapped_depths): Removed.
7395 (swap_loop_mapped_depth_for_num): Reimplemented.
7396 (new_scop): Call create_loops_mapping.
7397 (scop_record_loop): Call graphite_loops_mapping_insert_child.
7398 (translate_clast): Pass the old loop father in parameter, and pass
7399 it to get_old_iv_from_ssa_name.
7400 (remove_edges_around_useless_blocks, can_generate_code_stmt,
7401 can_generate_code, can_generate_for_scop): New.
7402 (graphite_trans_bb_block): Returns false when it fails to transform.
7403 * graphite.h (graphite_loop_node, graphite_loops_mapping): New.
7405 2008-07-25 Sebastian Pop <sebastian.pop@amd.com>
7407 Reverted all the changes related to the streamization and
7409 These changes are now tracked in the streamization branch.
7411 2008-07-25 Sebastian Pop <sebastian.pop@amd.com>
7412 Jan Sjodin <jan.sjodin@amd.com>
7414 * graphite.c (gbb_compare): Correctly constify.
7415 (gbb_can_be_ignored): Indent.
7416 (graphite_trans_scop_swap_1and2): Add legality check.
7419 2008-07-25 Sebastian Pop <sebastian.pop@amd.com>
7421 Remove fallouts from "Reverted the Condate changes".
7422 * tree.h: Remove unused decl.
7423 * gcc.dg/tree-checker: Same.
7424 * timevar.def: Remove counter.
7426 2008-07-24 Sebastian Pop <sebastian.pop@amd.com>
7428 * Merge from mainline (135673:138072).
7430 Reverted the MIRO changes (from 2008-04-05) that are now
7431 tracked in the miro branch.
7432 * tree-bounds.c: Removed.
7433 * tree-bounds.h: Removed.
7435 Reverted the Condate changes (from 2006-07-04, 2007-03-20) that
7436 are now tracked in the condate branch.
7437 * tree-check.c: Removed.
7438 * tree-match.c: Removed.
7439 * condate.y: Removed.
7441 2008-07-24 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
7443 * common.opt: New user flag -floop-block, -floop-strip-mine
7444 and -floop-interchange.
7445 * toplev.c (process_options): Enable -fgraphite pass if any one of the
7446 graphite loop optimization flags is turned on.
7447 * graphite.c (graphite_apply_transformations): Add flag_loop_block,
7448 flag_loop_strip_mine and flag_loop_interchange checks before
7450 * doc/invoke.texi: Remove -fgraphite and add -floop-block,
7451 -floop-strip-mine and -floop-interchange.
7452 * gcc.dg/graphite/block-0.c: Add -floop-block and remove
7454 * gcc.dg/graphite/scop-16.c: Ditto.
7455 * gcc.dg/graphite/scop-17.c: Ditto.
7456 * gcc.dg/graphite/scop-18.c: Ditto.
7458 2008-07-23 Jan Sjodin <jan.sjodin@amd.com>
7459 Sebastian Pop <sebastian.pop@amd.com>
7461 * cfgloopmanip.c (update_dominators_in_loop): Make it static.
7462 (create_empty_loop_on_edge): More fixes.
7463 * tree-phinodes.c (resize_phi_node): Extern.
7464 (unlink_phi_node, move_phi_node): New split from remove_phi_node.
7465 * cfghooks.c (update_dominator_information): New split from
7467 * tree-vectorizer.c (rename_variables_in_bb): Extern.
7468 * tree-dfa.c (collect_dfa_stats): Start walking the CFG on the
7469 successor of the function entry block.
7471 * graphite.c: Include pointer-set.h.
7472 (debug_loop_mapping, increment_loop_mapped_depths,
7473 get_loop_mapped_depth_for_num, get_loop_mapped_depth,
7474 set_loop_mapped_depth_for_num, set_loop_mapped_depth,
7475 swap_loop_mapped_depth_for_num, get_num_from_index,
7476 swap_loop_mapped_depth, loop_iv_stack_debug,
7477 loop_iv_stack_push, loop_iv_stack_pop, loop_iv_stack_get_iv,
7478 loop_iv_stack_get_iv_from_name, loop_iv_stack_debug,
7479 get_old_iv_from_ssa_name): New.
7480 (new_scop): Initialize SCOP_LOOPS_MAPPING.
7481 (free_scop): Free SCOP_LOOPS_MAPPING.
7482 (scop_record_loop): Record old ivs.
7483 (create_var_name): Removed.
7484 (initialize_cloog_names): Allocate double space in case strip mine
7485 applies to all loops once.
7486 (clast_name_to_gcc): Look up in the map ivstack passed in parameter.
7487 (clast_to_gcc_expression): Same. Implement more clast to gimple
7489 (graphite_create_new_loop): Pass in ivstack.
7490 (remove_all_edges): Pass in the construction_edge.
7491 (graphite_remove_iv): Removed.
7492 (graphite_rename_ivs, graphite_rename_ivs_stmt,
7493 remove_cond_exprs): Rewritten.
7494 (move_phi_nodes): New.
7495 (disconnect_virtual_phi_nodes, disconnect_cond_expr): Removed.
7496 (translate_clast): Pass in ivstack. Rewrite some cases.
7497 (set_cloog_options, debug_clast_stmt): New.
7498 (find_transform): Use set_cloog_options.
7499 (outermost_loop_layer): Removed.
7500 (get_construction_edge, collect_virtual_phis, find_vdef_for_var_in_bb,
7501 find_vdef_for_var_1, find_vdef_for_var, patch_phis_for_virtual_defs,
7502 mark_old_loops, remove_dead_loops): New.
7504 (graphite_trans_bb_move_loop): Call swap_loop_mapped_depth.
7505 (const_column_index, get_first_matching_sign_row_index,
7506 get_lower_bound_row, get_upper_bound_row, get_lower_bound,
7507 get_upper_bound): New.
7508 (graphite_trans_bb_strip_mine): Also update the iv map.
7510 * graphite.h (graphite_loops_mapping, GBB_LOOPS_MAPPING): New.
7511 (struct name_tree): Add a loop field.
7512 (struct scop): Add a graphite_loops_mapping field.
7513 (SCOP_LOOPS_MAPPING): New.
7514 (debug_clast_stmt): Declare.
7515 * lambda.h (find_induction_var_from_exit_cond): Declare.
7516 (lambda-code.c): (find_induction_var_from_exit_cond): Extern.
7517 * cfgloop.h (update_dominators_in_loop): Removed declaration.
7518 (create_empty_loop_on_edge): Updated.
7519 * tree-flow.h (remove_bb, resize_phi_node, move_phi_node,
7520 rename_variables_in_bb): Declare.
7521 * tree-cfg.c (remove_bb): Extern.
7523 * gcc.dg/graphite/block-0.c: New.
7525 2008-07-21 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
7526 Sebastian Pop <sebastian.pop@amd.com>
7528 * graphite.c (strip_mine_profitable_p): New.
7529 (graphite_trans_bb_block): Disable strip mining if not profitable.
7531 * gcc.dg/graphite/scop-18.c: New.
7532 * gcc.dg/graphite/scop-17.c: Fixed.
7533 * gcc.dg/graphite/scop-16.c: Fixed.
7535 2008-07-17 Harsha Jagasia <harsha.jagasia@amd.com>
7536 Jan Sjodin <jan.sjodin@amd.com>
7537 Sebastian Pop <sebastian.pop@amd.com>
7539 * graphite.c (is_interchange_valid): New.
7540 (graphite_trans_bb_block): Check loop nest of basic block for legality
7543 * graphite.h (gbb_inner_most_loop_index, outer_most_loop_1,
7544 outer_most_loop, gbb_outer_most_loop_index): New.
7546 * tree-loop-linear.c (perfect_loop_nest_depth): Remove static.
7547 * tree-flow.h (perfect_loop_nest_depth): Declare as extern.
7548 * gcc.dg/graphite/scop-16.c: New.
7549 * gcc.dg/graphite/scop-17.c: New.
7551 2008-07-11 Tobias Grosser <grosser@fim.uni-passau.de>
7553 * graphite.c (scop_remove_ignoreable_gbbs): Also update bitmap.
7554 (graphite_trans_scop_block): Ignore SCoPs without bbs.
7556 2008-07-11 Tobias Grosser <grosser@fim.uni-passau.de>
7558 * graphite.c (new_scop): Initialize SCOP_EXIT.
7559 (scopdet_info): Add.
7560 (scopdet_bb_info): Rename from is_bb_addable. Cleanup, bugfixes.
7561 (build_scops_1): Cleanup, bugfixes.
7562 (build_scops): Cleanup.
7564 * gcc.dg/graphite/scop-matmult.c: Remove duplicated code.
7565 * gcc.dg/graphite/scop-15.c: Add SCoP numbers.
7567 2008-07-10 Harsha Jagasia <harsha.jagasia@amd.com>
7569 * gfortran.dg/graphite/scop-1.f: Update to reduced test case.
7571 * gfortran.dg/graphite/graphite.exp: Use
7572 DEFAULT_GRAPHITE_FLAGS.
7574 * gcc.dg/graphite/scop-15.c: Update to reduced test case.
7576 2008-07-10 Harsha Jagasia <harsha.jagasia@amd.com>
7578 * graphite.c (scan_tree_for_params): Do not assert any more if
7579 MULT_EXPR parameter is negative.
7581 * gfortran.dg/graphite/scop-1.f: New.
7583 * gfortran.dg/graphite/graphite.exp: New.
7585 * gcc.dg/graphite/scop-15.c: New.
7587 2008-07-10 Harsha Jagasia <harsha.jagasia@amd.com>
7589 * graphite.c (is_bb_addable): Fix segfault in spec gzip and reformat.
7591 2008-07-10 Tobias Grosser <grosser@fim.uni-passau.de>
7593 * graphite.c (graphite_trans_bb_swap_loops): Rename from
7594 graphite_swap_loops.
7595 (graphite_trans_bb_move_loop): New.
7596 (graphite_trans_bb_strip_mine): Rename from graphite_strip_mine_loop.
7597 (graphite_trans_bb_block): New.
7598 (graphite_trans_loop_block): New.
7599 (graphite_trans_scop_swap_1and2): Rename from
7600 graphite_trans_swap_1and2.
7601 (graphite_trans_scop_strip): Rename from graphite_trans_strip.
7602 (graphite_trans_scop_block): New.
7603 (graphite_apply_transformations): Rename from
7604 graphite_transformations.
7606 * gcc.dg/graphite/scop-matmult.c: New.
7608 2008-07-10 Tobias Grosser <grosser@fim.uni-passau.de>
7610 * graphite.c (gbb_compare): New.
7611 (graphite_sort_gbbs): New.
7612 (gbb_can_be_ignored): New.
7613 (scop_remove_ignoreable_gbbs): New.
7614 (graphite_transformations): Cleanup and add
7615 scop_remove_ignoreable_gbbs.
7616 * lambda.h (lambda_vector_compare): New.
7618 2008-07-09 Tobias Grosser <grosser@fim.uni-passau.de>
7620 * graphite.c (print_graphite_bb): Correct printing of static schedule.
7621 (graphite_swap_loops): int -> unsigned
7622 (graphite_strip_mine_loop): int -> unsigned, Fix SCHEDULE
7623 (graphite_transformations): New.
7624 (graphite_transform_loops): Move to graphite_transformations.
7625 * graphite.h (gbb_nb_loops): Return unsigned.
7627 2008-07-04 Tobias Grosser <grosser@fim.uni-passau.de>
7629 * graphite.c (scan_tree_for_params): Fix insertion of parameters into
7630 the domain matrix. This makes scop-0.c work again.
7632 2008-06-20 Richard Guenther <rguenther@suse.de>
7634 * graphite.h: Adjust copyright to GPLv3.
7635 * graphite.c: Likewise.
7636 (stmt_simple_memref_for_scop_p): Split out from ...
7637 (stmt_simple_for_scop_p): ... here. Fix handling of calls
7639 (get_bb_type): Optimize.
7641 (is_bb_addable): Fix memleak, replace is_pred call with
7643 (build_scops): Use current_loops.
7644 (param_index): Fix memleak.
7646 2008-06-20 Konrad Trifunovic <konrad.trifunovic@inria.fr>
7648 * graphite.c: Fix formatting.
7650 2008-06-19 Konrad Trifunovic <konrad.trifunovic@inria.fr>
7652 * graphite.c (new_scop): Memory allocation for SCOP_{NEWIVS, OLDIVS}.
7653 (free_scop): Memory deallocation for SCOP_NEWIVS, SCOP_OLDIVS.
7654 (create_var_name, save_var_name): Newly defined functions.
7655 (initialize_cloog_names): Part of the code factored out to
7657 (clast_to_gcc_expression): Now handles the case of clast_red_sum
7658 in clast_reduction statement.
7659 (graphite_create_new_loop): Now takes a new parameter
7661 (translate_clast): Now also takes the context_loop and bb_exit
7662 parameters. Rewritten the code so that it creates a gimple code
7663 inside the given context.
7664 (outermost_loop_layer, graphite_remove_iv, graphite_rename_ivs,
7665 remove_cond_expr, disconnect_cond_expr,
7666 disconnect_virtual_phi_nodes): Newly defined functions.
7667 * graphite.h (struct scop): added old_ivs vector.
7668 SCOP_OLDIVS: New macro.
7670 2008-06-19 Sebastian Pop <sebastian.pop@amd.com>
7672 * cfgloopmanip.c: Add missing function comments, fix formatting.
7674 2008-06-18 Konrad Trifunovic <konrad.trifunovic@inria.fr>
7676 * cfgloopmanip.c (update_dominators_in_loop): Defined.
7677 (create_empty_loop_on_edge): Defined.
7678 * tree-parloops.c (canonicalize_loop_ivs): Returns tree
7680 * cfgloop.h (create_empty_loop_on_edge): Declared as extern.
7681 (update_dominators_in_loop): Declared as extern
7682 * tree-flow.h (canonicalize_loop_ivs): Declared as extern.
7684 2008-06-16 Tobias Grosser <grosser@fim.uni-passau.de>
7686 * graphite.c (print_graphite_bb): Allow changing number of loops
7688 (initialize_cloog_names): Allow changing number of loops.
7689 (build_cloog_prog): Simplify.
7690 (find_transform): Enable cloog option --strides.
7691 (graphite_swap_loops): New.
7692 (graphite_strip_mine_loop): New.
7693 (graphite_trans_swap_1and2): New.
7694 (graphite_trans_strip): New.
7695 (graphite_transform_loops): Add graphite_trans_strip.
7696 * graphite.h (scop_max_loop_depth): New.
7698 2008-06-15 Tobias Grosser <grosser@fim.uni-passau.de>
7700 * graphite.c (build_scop_iteration_domain): Remove forgotten
7701 line. (Fixes compile)
7703 2008-06-15 Tobias Grosser <grosser@fim.uni-passau.de>
7705 * graphite.c (print_graphite_bb): Add output of GBB_LOOPS.
7706 (build_graphite_bb): Add GBB_LOOPS and GBB_DOMAIN and reorder.
7707 (build_bb_loops): New.
7708 (graphite_transform_loops): Add build_bb_loops.
7709 (schedule_to_scattering): Use gbb_nb_loops to support changing loop
7711 * graphite.h (graphite_bb): Add loops.
7712 (gbb_nb_loops): New.
7713 (gbb_loop_at_index): New.
7714 (gbb_loop_index): New.
7715 (nb_params_in_scop): Renamed to scop_nb_params. Updated all functions
7716 using nb_params_in_scop.
7718 2008-06-14 Tobias Grosser <grosser@fim.uni-passau.de>
7720 * graphite.c (print_graphite_bb): Adapt to minimized schedule.
7721 (build_scop_canonical_schedules): Build minimized schedule.
7722 (schedule_to_scattering): Adapt to minimized schedule.
7723 * graphite.h (graphite_bb): Add/Update descriptions.
7725 2008-06-14 Adrien Eliche <aeliche@isty.uvsq.fr>
7726 Tobias Grosser <grosser@fim.uni-passau.de>
7728 * graphite.c (print_graphite_bb): Add condition printing.
7730 (dump_gbb_conditions): New.
7731 (build_scop_conditions_1): New.
7732 (build_scop_conditions): New.
7733 * graphite.h (graphite_bb): Add conditions.
7735 2008-06-14 Tobias Grosser <grosser@fim.uni-passau.de>
7737 * graphite.c (print_graphite_bb):
7738 (free_graphite_bb): New.
7739 (free_scop): Free bbs.
7740 (get_bb_type): Free doms.
7741 (build_scop_context): Free context matrix.
7742 (build_loop_iteration_domains): Remove unused code.
7743 (build_cloog_prog): Free scattering function and blocklist.
7744 (find_transform): Free options.
7746 2008-06-13 Tobias Grosser <grosser@fim.uni-passau.de>
7748 * graphite.c (loop_body_to_cloog_stmts): Rename to add_bb_domains.
7749 Remove unnecessery cloog data structures. Make a copy of the domain
7750 (setup_cloog_loop): Rename to build_loop_iteration_domains. Remove
7751 unnecessary cloog data structures. Fix memory leaks. Remove insert
7752 into SCOP_LOOP2CLOOG_LOOP as the inserted CloogLoops will never be
7754 (build_scop_iteration_domain): Remove unnecessary cloog
7755 data structures. Fix memory leaks.
7756 (graphite_transform_loops): Disable build_scop_dynamic_schedules as it
7757 uses SCOP_LOOP2CLOOG_LOOP, that is at the moment not working.
7759 2008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
7761 * graphite.c (find_scop_params): Remove initialize_cloog_names.
7763 2008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
7765 * graphite.c (end_scop): Style fix.
7766 (schedule_to_scattering): Style and comment fix.
7768 2008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
7769 * graphite.c (print_graphite_bb): Fix definiton of
7770 schedule_to_scattering.
7771 (initialize_cloog_names): Change nb_scattdims to max loop
7773 (schedule_to_scattering): Take parameter for number of scattering
7775 (build_cloog_prog): Only build as much scattering dimensions as
7778 2008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
7780 * graphite.c (end_scop): Disable bb splitting. Fixes SIGSEGV
7781 in polyhedron/aermod.f90.
7783 2008-06-11 Tobias Grosser <grosser@fim.uni-passau.de>
7784 Dwarak Rajagopal <dwarak.rajagopal@amd.com>
7785 Harsha Jagasia <harsha.jagasia@amd.com>
7787 * graphite.c (is_bb_addable): Fix segfault.
7789 2008-06-10 Tobias Grosser <grosser@fim.uni-passau.de>
7791 * graphite.c (is_bb_addable): Fix memory leak, handling of loops
7792 with multiple exits and conditional handling in edge cases.
7793 (is_loop_exit): Fix memory leak. (Forgotten in last commit)
7795 * gcc.dg/graphite/scop-14.c: New.
7797 2008-06-06 Tobias Grosser <grosser@fim.uni-passau.de>
7798 Adrien Eliche <aeliche@isty.uvsq.fr>
7800 * graphite.c (is_bb_addable): Add more comments and enhance
7801 readablity of the source code. Fix memory leak.
7802 (is_loop_exit): Fix memory leak.
7804 2008-06-05 Tobias Grosser <grosser@fim.uni-passau.de>
7806 * graphite.c (first_loop_in_scop): Deleted.
7807 (setup_cloog_loop): Only walk the loop chain for inner loops.
7808 (build_scop_iteration_domain): Execute setup_cloog_loop for
7809 all loops in the first layer.
7811 2008-06-05 Tobias Grosser <grosser@fim.uni-passau.de>
7813 * graphite.c (scan_tree_for_params): Change the way params are
7814 added to be indepenent of the number of loops.
7815 (setup_cloog_loop): Revert to short matrix format. Fix parameter
7817 (build_cloog_prog): Revert to short matrix format.
7819 2008-06-05 Sebastian Pop <sebastian.pop@amd.com>
7820 Dwarak Rajagopal <dwarak.rajagopal@amd.com>
7822 * tree-loop-fusion.c (fuse_loops): Fix uninitialized variable
7825 2008-06-05 Sebastian Pop <sebastian.pop@amd.com>
7827 * graphite.c (nb_data_refs_in_scop): New.
7828 (graphite_transform_loops): Print more stats: number of
7829 loops, basic blocks and data references per scop.
7831 2008-06-04 Sebastian Pop <sebastian.pop@amd.com>
7832 Jan Sjodin <jan.sjodin@amd.com>
7834 * graphite.c (loop_affine_expr, idx_record_params,
7835 find_scop_parameters, setup_cloog_loop): Use instantiate_scev
7836 instead of instantiate_parameters.
7838 2008-06-04 Tobias Grosser <grosser@fim.uni-passau.de>
7840 * graphite.c (schedule_to_scattering): Fix scattering dimensions,
7841 add support for parameters, add STATIC_SCHEDULE at the right places,
7844 2008-06-04 Tobias Grosser <grosser@fim.uni-passau.de>
7846 * graphite.c (build_scop_loop_nests): Only add the loops, that
7847 are contained completely in the SCoP.
7848 (build_cloog_prog): Disable scattering, until schedule_to_scattering
7849 and the domains are fixed.
7850 (build_scop_canonical_schedules): Add support for bbs not contained
7853 2008-06-04 Tobias Grosser <grosser@fim.uni-passau.de>
7855 * graphite.h (scop_contains_loop): Update comments to match
7856 the actual behavior.
7857 (scop_contains_loop): New.
7858 * graphite.c (schedule_to_scattering): Use scop_contains_loop.
7860 2008-06-04 Sebastian Pop <sebastian.pop@amd.com>
7862 * graphite.c (get_bb_type): On function body, i.e. loop_0,
7863 don't mark blocks as GBB_LOOP_SING_EXIT_HEADER, mark them
7866 2008-06-04 Sebastian Pop <sebastian.pop@amd.com>
7867 Tobias Grosser <grosser@fim.uni-passau.de>
7869 * graphite.c (graphite_transform_loops): Early return when
7870 there are no loops in the function.
7872 2008-05-31 Sebastian Pop <sebastian.pop@amd.com>
7873 Jan Sjodin <jan.sjodin@amd.com>
7875 * graphite.c (scan_tree_for_params, setup_cloog_loop): Compute the
7876 offset of the last loop.
7877 (setup_cloog_loop): Copy the entire outer constraint matrix.
7879 2008-05-31 Sebastian Pop <sebastian.pop@amd.com>
7880 Jan Sjodin <jan.sjodin@amd.com>
7882 * graphite.c (stmt_in_scop_p, function_parameter_p,
7883 invariant_in_scop_p): Removed.
7884 (scan_tree_for_params): Can be used with no constraint
7885 matrix for gathering parameters.
7886 (idx_record_params): Don't use idx_record_param, instead use
7887 scan_tree_for_params.
7888 (find_scop_parameters): Same.
7889 (setup_cloog_loop, build_scop_iteration_domain, build_cloog_prog):
7890 Fix the size of loop domains.
7891 (schedule_to_scattering): Exit when the outer loop is not in scop.
7892 (find_transform): Enable build_cloog_prog.
7894 2008-05-31 Sebastian Pop <sebastian.pop@amd.com>
7895 Jan Sjodin <jan.sjodin@amd.com>
7897 * graphite.c (schedule_to_scattering): Make scattering domains
7898 uniformly of the same size, as required by CLooG 0.14.0 and before.
7900 2008-05-31 Sebastian Pop <sebastian.pop@amd.com>
7901 Jan Sjodin <jan.sjodin@amd.com>
7903 * graphite.c (schedule_to_scattering): Rewrite, correct the
7904 translation of the scheduling function to scattering.
7905 (build_cloog_prog): Call schedule_to_scattering only once.
7906 * graphite.h (scop_loop_index): Do not fail for loops not
7907 in the scop: return -1.
7909 2008-05-30 Tobias Grosser <grosser@fim.uni-passau.de>
7911 * graphite.c (build_graphite_bb): Initialize GBB_DOMAIN.
7912 (loop_body_to_cloog_stmts): Export GBB_DOMAIN.
7913 (setup_cloog_loop): Export GBB_DOMAIN.
7914 (build_cloog_prog): New. Create new CLOOG_PROG, which should be
7915 able to rebuild the original control flow.
7916 * graphite.h (graphite_bb): Add domain field and access macro.
7919 2008-05-30 Sebastian Pop <sebastian.pop@amd.com>
7921 * graphite.c (debug_gbb): New.
7922 (print_scop, build_graphite_bb): Use SCOP_BBS.
7923 (build_scop_bbs): Reimplemented.
7924 (dfs_bb_in_scop_p): Removed.
7925 (build_scop_loop_nests): Reorder loops inserted in
7926 SCOP_LOOP_NEST: outer loops should come first.
7927 (build_scop_canonical_schedules): Reinitialize at zero
7928 the components of the SCOP_STATIC_SCHEDULE for the loops
7929 that have already been parsed.
7931 * graphite.h (debug_gbb): Declared.
7933 2008-05-30 Sebastian Pop <sebastian.pop@amd.com>
7934 Jan Sjodin <jan.sjodin@amd.com>
7936 * graphite.c (create_empty_loop): Renamed graphite_create_new_loop.
7937 (graphite_loop_to_gcc_loop): Removed.
7938 (remove_all_edges): New.
7939 (graphite_stmt_to_gcc_stmt): Renamed translate_clast.
7940 (gloog): Remove useless code.
7942 2008-05-29 Tobias Grosser <grosser@fim.uni-passau.de>
7944 * graphite.c (get_bb_type): Reworked. We distinguish between
7945 loops with one or multiple exits.
7946 (is_loop_exit): New.
7948 (is_bb_addable): Rework condition handling, now support for case
7949 case statements and loops with multiple exits.
7951 * gcc.dg/graphite/scop-11.c: New.
7952 * gcc.dg/graphite/scop-12.c: New.
7953 * gcc.dg/graphite/scop-13.c: New.
7955 2008-05-29 Tobias Grosser <grosser@fim.uni-passau.de>
7957 * graphite.c (dot_all_scops_1): Fix some colors. Reuse colors, if
7958 we have too many colors.
7960 2008-05-22 Sandeep Maram <smaram_b04@iiita.ac.in>
7962 * doc/invoke.texi (-ftree-loop-fusion): Document.
7963 * tree-pass.h (pass_loop_fusion): Declared.
7964 * tree-loop-fusion.c: New.
7965 * timevar.def (TV_TREE_LOOP_FUSION): Declared.
7966 * tree-data-ref.c (find_data_references_in_loop): Make extern.
7967 * tree-data-ref.h (find_data_references_in_loop): Declared.
7968 * common.opt (ftree-loop-fusion): Declared.
7969 * Makefile.in (tree-loop-fusion.o): Added rule and to OBJS-common.
7971 2008-05-21 Sebastian Pop <sebastian.pop@amd.com>
7973 * graphite.c (build_access_matrix): Fix typo from the merge.
7975 2008-05-20 Sebastian Pop <sebastian.pop@amd.com>
7977 * Merge from mainline (130800:135673).
7979 2008-05-07 Sebastian Pop <sebastian.pop@amd.com>
7981 * graphite.c (end_scop): The exit of the scop is not part of the scop.
7982 Update dominators after splitting.
7984 2008-05-07 Sebastian Pop <sebastian.pop@amd.com>
7986 * graphite.c (is_bb_addable): Return the harmful statement.
7987 Factor up some code.
7988 (end_scop): New. Splits end of scope bbs on a harmful statement.
7989 (build_scops_1): Call end_scop.
7991 2008-05-07 Sebastian Pop <sebastian.pop@amd.com>
7993 * graphite.c: (succs_at_same_depth, end_scop, all_preds_visited_p,
7994 all_succs_visited_p, start_new_scop_for_each_succ, start_new_scop,
7995 add_dominators_to_open_scops, stop_last_open_scop, scop_end_loop,
7996 build_scops_1): Removed.
7997 (build_scops_2): Renamed build_scops_1.
7999 2008-05-06 Sebastian Pop <sebastian.pop@amd.com>
8001 * graphite.c: Fix formatting.
8003 2008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
8005 * graphite.c (get_bb_type): New.
8007 (build_scops_2): New.
8008 (is_bb_addable): New.
8009 (build_scops): Switch the scop detection.
8010 (build_scop_bbs): Add entry bb to scop.
8011 * graphite.h (struct scop): Update comment.
8013 2008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
8015 * graphite.c (dot_all_scops_1): Fix some incorrect colors and add
8018 2008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
8020 * gcc.dg/graphite/scop-1.c: Update.
8021 * gcc.dg/graphite/scop-2.c: Update.
8022 * gcc.dg/graphite/scop-4.c: Update.
8023 * gcc.dg/graphite/scop-5.c: Add.
8024 * gcc.dg/graphite/scop-6.c: Add.
8026 2008-05-06 Sebastian Pop <sebastian.pop@amd.com>
8028 * gcc.dg/graphite/scop-0.c: Add.
8029 * gcc.dg/graphite/scop-7.c: Add.
8030 * gcc.dg/graphite/scop-8.c: Add.
8031 * gcc.dg/graphite/scop-9.c: Add.
8032 * gcc.dg/graphite/scop-10.c: Add.
8034 2008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
8036 * graphite.c (scop_affine_expr): Renamed to loop_affine_expr.
8037 Check affine expressions depending on the outermost loop
8039 (stmt_simple_for_scop_p): Same.
8040 (harmfule_stmt_in_scop): Same.
8042 2008-04-28 Tobias Grosser <grosser@fim.uni-passau.de>
8044 * graphite.c (dot_all_scops): Remove incorrect difficult bb coloring,
8045 mark entry and exit, that are not part of the SCoP and update HTML
8048 2008-04-25 Sebastian Pop <sebastian.pop@amd.com>
8050 * graphite.c (basic_block_simple_for_scop_p): Renamed
8052 (save_scop, preds_at_same_depth, test_for_scop_bound): Removed.
8053 (add_dominators_to_open_scops, build_scops_1): Reimplemented.
8054 (all_preds_visited_p, all_succs_visited_p,
8055 start_new_scop_for_each_succ, start_new_scop, stop_last_open_scop,
8056 scop_end_loop): New.
8057 (build_scops): Do not use dfs_enumerate_from.
8059 * gcc.dg/graphite/scop-{1,2,4}.c: Updated.
8061 2008-04-23 Sebastian Pop <sebastian.pop@amd.com>
8063 * graphite.c: Add comments to functions that are missing a
8065 (graphite_create_iv): Removed. Merged in graphite_loop_to_gcc_loop.
8067 2008-04-23 Sebastian Pop <sebastian.pop@amd.com>
8069 * graphite.c (nb_params_in_scop): Moved...
8070 (graphite_bb_from_bb, loop_body_to_cloog_stmts): New.
8071 (setup_cloog_loop): Call loop_body_to_cloog_stmts.
8072 (clast_to_gcc_expression): Reduce column size to less than 80.
8073 (graphite_create_iv): Return the new name of the IV.
8074 (find_transform): Set options->esp and options->cpp.
8075 (gloog): Comment out the invalidation of the old loop code.
8076 (initialize_dependence_polyhedron): Replace scop_nb_params with
8079 * graphite.h (nb_params_in_scop): ... here.
8080 (scop_nb_params): Removed.
8081 (loop_domain_dim): Return something even when the loop was not
8082 found in the hash table: avoid ICEing on all the graphite.exp
8085 2008-04-14 Konrad Trifunovic <konrad.trifunovic@inria.fr>
8087 * tree-chrec.c (for_each_scev_op): SCEV can have 3 operands.
8089 * graphite.c (build_scop_dynamic_schedules): Schedule is built
8090 according to nesting level.
8091 (find_scop_parameters): Call instantiate_parameters.
8092 (scan_tree_for_params): Extend it to handle general affine bounds.
8093 Inner loop bound can depend on outer loop induction variable.
8094 (setup_cloog_loop): tmp variable is allocated on stack. Call
8095 instantiate_parameters with respect to outermost_loop_in_scop.
8096 (loop_domain_dim, ref_nb_loops, loop_iteration_vector_dim): moved to
8098 (create_empty_loop): Function loopify should be given edge
8099 probability, instead of edge frequency. Dominance relation from
8100 switch_bb to loop_header.
8101 (clast_to_gcc_expression): Added handling of clast_reduction node.
8102 (gloog): New functionality for removing old loop.
8103 (test_dependence): Factored out from build_rdg_all_levels.
8104 (build_rdg_all_levels): Dependence testing factored out to
8105 test_dependence function.
8107 * graphite.h (struct graphite_bb): Extended with dynamic_schedule.
8108 (loop_domain_dim, ref_nb_loops, loop_iteration_vector_dim): Moved
8111 2008-04-07 Sebastian Pop <sebastian.pop@amd.com>
8113 * graphite.c (free_scop, param_index, initialize_cloog_names,
8114 nb_params_in_scop): Use name_tree map instead of just a tree
8115 for keeping track of the variable name associated to that tree.
8116 (create_empty_loop, gmp_cst_to_tree, clast_name_to_gcc,
8117 clast_to_gcc_expression, graphite_create_iv,
8118 graphite_loop_to_gcc_loop, graphite_cond_to_gcc_cond,
8119 graphite_stmt_to_gcc_stmt): New.
8120 (gloog): Call these.
8121 * graphite.h (struct name_tree): New.
8122 (struct scop): Use name_tree instead of tree for params.
8123 Store a vector of name_tree for new_ivs.
8125 (scop_nb_params): Use name_tree instead of tree.
8127 2008-04-05 Alexander Lamaison <awl03@doc.ic.ac.uk>
8128 Sebastian Pop <sebastian.pop@amd.com>
8130 * tree-bounds.c: New.
8131 * tree-bounds.h: New.
8132 * tree-pass.h: Declare pass_bounds_early and pass_bounds_late.
8133 * passes.c: Schedule pass_bounds_early, pass_bounds_late.
8134 * builtins.c (expand_builtin_alloca): Add flag_bounds as for
8138 * c-cppbuiltin.c: Same.
8142 * tree-outof-ssa.c: Same.
8144 * Makefile.in: Same.
8146 2008-03-15 Antoniu Pop <antoniu.pop@gmail.com>
8147 Sebastian Pop <sebastian.pop@amd.com>
8149 * tree-loop-distribution.c (remaining_stmts,
8150 upstream_mem_writes): Removed static variables.
8151 (copy_loop_before, create_bb_after_loop,
8152 mark_nodes_having_upstream_mem_writes, free_rdg_components,
8153 rdg_build_components, rdg_build_partitions,
8154 dump_rdg_partitions): Extern.
8155 (generate_loops_for_partition, generate_code_for_partition): Do not
8157 (already_processed_vertex_p, predecessor_has_mem_write,
8158 mark_nodes_having_upstream_mem_writes, has_upstream_mem_writes,
8159 rdg_flag_all_uses, rdg_flag_uses, rdg_flag_vertex_and_dependent,
8160 rdg_flag_loop_exits, rdg_flag_similar_memory_accesses,
8161 build_rdg_partition_for_component, rdg_build_partitions, ldist_gen):
8162 Pass remaining_stmts and upstream_mem_writes as parameters.
8163 (rdg_component): Moved...
8164 (build_rdg_partition_for_component): Do not aggregate components when
8165 flag_streamize_loops is set.
8166 (gen_sequential_loops): New.
8167 (ldist_gen): Call gen_sequential_loops.
8169 * tree-pass.h (pass_loop_streamization): Declared.
8171 * omp-low.c (expand_omp_sections): Call add_bb_to_loop on created
8172 basic blocks when loops structures exist.
8174 * builtin-types.def (BT_FN_VOID_PTR_PTR_INT): New.
8176 * tree-ssa-loop-ivopts.c (expr_invariant_in_region_p): New.
8178 * tree-parloops.c (take_address_of, eliminate_local_variables_1,
8179 eliminate_local_variables_stmt, eliminate_local_variables,
8180 separate_decls_in_loop_name, separate_decls_in_loop_stmt,
8181 separate_decls_in_loop, gen_parallel_loop): Make them work on a region
8182 of code delimited by two edges in the CFG.
8183 (separate_decls_in_loop_name): Renamed separate_decls_in_region_name.
8184 (separate_decls_in_loop_stmt): Renamed separate_decls_in_region_stmt.
8185 (separate_decls_in_loop): Renamed separate_decls_in_region. Isolate
8186 the case of parallelisation of reductions.
8187 (create_loop_fn): Extern.
8188 (create_omp_parallel_region): New.
8190 * tree-data-ref.c (dump_data_dependence_relation): Don't call
8191 dump_data_reference for printing dra and drb.
8192 (create_rdg_edge_for_ddr, create_rdg_edges_for_scalar): Initialise
8194 (build_rdg): Don't call free_dependence_relations for the moment, as
8195 we attach dependence relations on each edge of the RDG.
8198 * tree-data-ref.h (rdg_component): ...here.
8199 (struct rdg_edge): New field ddr_p relation.
8200 (RDGE_RELATION): New.
8201 (create_bb_after_loop, copy_loop_before,
8202 mark_nodes_having_upstream_mem_writes, rdg_build_components,
8203 rdg_build_partitions, dump_rdg_partitions,
8204 free_rdg_components): Declared.
8206 * omp-builtins.def (BUILT_IN_GOMP_STREAM_ALIGN_PUSH,
8207 BUILT_IN_GOMP_STREAM_ALIGN_POP): New.
8209 * tree-loop-streamization.c: New.
8211 * tree-flow.h (gather_blocks_in_sese_region, create_loop_fn,
8212 create_omp_parallel_region, expr_invariant_in_region_p): Declared.
8214 * Makefile.in (tree-loop-streamization.o): Added to OBJS-common.
8216 * tree-cfg.c (gather_blocks_in_sese_region): Extern.
8218 * passes.c: Schedule pass_loop_streamization.
8220 2008-03-08 Tobias Grosser <grosser@fmi.uni-passau.de>
8222 * graphite.c (dot_all_scops_1): Fix formatting for difficult bbs and
8225 2008-03-07 Tobias Grosser <grosser@fim.uni-passau.de>
8227 * graphite.c (dot_all_scops): Update formatting.
8228 Bbs can now be part of more than one SCoP.
8230 2008-03-04 Sebastian Pop <sebastian.pop@amd.com>
8232 * graphite.c (new_loop_to_cloog_loop_str, setup_cloog_loop): Fix
8234 (loop_domain_dim): Check for unregistered toplev SCOP loop.
8235 * graphite.h (loop_to_cloog_loop): New.
8237 2008-03-04 Konrad Trifunovic <konrad.trifunovic@inria.fr>
8239 * graphite.c (loop_domain_dim, ref_nb_loops,
8240 loop_iteration_vector_dim): New.
8241 (build_access_matrix_with_af, build_access_matrix,
8242 initialize_dependence_polyhedron): Fixed for new matrix layout.
8243 No longer assume that all iteration domains are of the same
8246 2008-03-02 Sebastian Pop <sebastian.pop@amd.com>
8248 * tree-scalar-evolution.c (instantiate_parameters_1): An SSA_NAME
8249 defined in a loop at depth 0 is invariant.
8250 * tree-chrec.c (evolution_function_is_invariant_rec_p): Ditto.
8251 * tree-ssa-loop-ivopts.c (expr_invariant_in_loop_p): Should never
8252 be called at loop depth 0.
8254 * graphite.c (basic_block_simple_for_scop_p): Take the scop as
8256 (dot_all_scops_1): Update use of basic_block_simple_for_scop_p.
8257 (down_open_scop): Removed.
8258 (loop_in_scop_p): Redefined.
8259 (scop_affine_expr): New argument: scop.
8260 (stmt_simple_for_scop_p): New argument: scop. RETURN_EXPR is not
8261 a harmful statement ending a scop.
8262 (basic_block_simple_for_scop_p): New argument: scop.
8263 (get_loop_start): Removed.
8264 (new_scop): Initialize SCOP_LOOPS.
8265 (free_scop): Free SCOP_LOOPS.
8266 (succs_at_same_depth, preds_at_same_depth): New.
8267 (end_scop): Test the validity of a scop.
8268 (add_dominators_to_open_scops): New.
8269 (test_for_scop_bound): Call add_dominators_to_open_scops.
8270 Add cases for opening and closing multiple scops.
8271 (build_scops, build_scop_bbs): Iterate over basic blocks in
8273 (build_graphite_bb): Pass scop directly.
8274 (dfs_bb_in_scop_p): New.
8275 (scop_record_loop): Use SCOP_LOOPS for not recording the same loop
8277 (nb_loops_around_gb): Use loop_in_scop_p.
8278 (schedule_to_scattering): Disabled for the moment the code computing
8279 the "textual order for outer loop".
8281 * graphite.h (struct scop): New field loops.
8283 (scop_loop_index): Test that the given loop belongs to SCOP_LOOPS.
8285 * gcc.dg/graphite/scop-{1,...,7}.c: Updated.
8287 2008-02-27 Antoniu Pop <antoniu.pop@gmail.com>
8288 Sebastian Pop <sebastian.pop@amd.com>
8290 * builtin-types.def (BT_FN_PTR_SIZE_UINT, BT_FN_BOOL_PTR): New.
8291 * common.opt (fstreamize-loops): New.
8292 * omp-builtins.def (BUILT_IN_GOMP_STREAM_CREATE,
8293 BUILT_IN_GOMP_STREAM_PUSH, BUILT_IN_GOMP_STREAM_HEAD,
8294 BUILT_IN_GOMP_STREAM_POP, BUILT_IN_GOMP_STREAM_EOS_P,
8295 BUILT_IN_GOMP_STREAM_SET_EOS, BUILT_IN_GOMP_STREAM_DESTROY): New.
8297 2008-02-22 Konrad Trifunovic <konrad.trifunovic@inria.fr>
8299 * tree-data-ref.c (build_empty_rdg): New.
8300 (build_rdg): Use it.
8301 * tree-data-ref.h (build_empty_rdg): Declared.
8302 * graphite.c (free_scop): Free SCOP_LOOP2CLOOG_LOOP.
8303 (find_vertex_for_stmt): Removed.
8304 (build_rdg_all_levels): Use build_empty_rdg and rdg_vertex_for_stmt.
8306 2008-02-21 Sebastian Pop <sebastian.pop@amd.com>
8308 * tree-loop-distribution.c (generate_builtin): After cancelling the
8309 loop tree, also delete basic blocks.
8310 (rdg_flag_uses): Stop recursion when a vertex has already been
8313 2008-02-15 Konrad Trifunovic <konrad.trifunovic@inria.fr>
8315 * graphite.c (build_scop_alpha): Removed.
8316 (graphite_transform_loops): Add a dummy call to build_all_rdg_levels
8317 and dump_dependence_graph to avoid compiler warnings.
8319 2008-02-14 Konrad Trifunovic <konrad.trifunovic@inria.fr>
8321 * tree-data-ref.c (dr_may_alias_p, create_rdg_vertices): Extern.
8322 * tree-data-ref.h (dr_may_alias_p, create_rdg_vertices): Declared.
8323 * graphite.c (new_loop_to_cloog_loop_str, hash_loop_to_cloog_loop,
8324 eq_loop_to_cloog_loop, del_loop_to_cloog_loop): New.
8325 (new_scop, setup_cloog_loop): Initialize SCOP_LOOP2CLOOG_LOOP.
8326 (initialize_dependence_polyhedron, find_vertex_for_stmt,
8327 initialize_data_dependence_polyhedron, is_empty_polyhedron,
8328 statement_precedes_p, build_rdg_all_levels, build_scop_alpha,
8329 dump_dependence_graph): New.
8330 * graphite.h (struct graphite_bb): New field compressed_alpha_matrix.
8332 (struct scop): New field loop2cloog_loop.
8333 (SCOP_LOOP2CLOOG_LOOP, struct data_dependence_polyhedron,
8334 RDGE_DDP, ddp_p, struct loop_to_cloog_loop_str): New.
8336 2008-02-10 Konrad Trifunovic <konrad.trifunovic@inria.fr>
8338 * graphite.c (build_graphite_bb): Fix initialization
8339 of the graphite basic block.
8341 2008-02-05 Sebastian Pop <sebastian.pop@amd.com>
8343 * graphite.c (scan_tree_for_params): Rewrite for the new layout of
8344 loop domain matrix. Pass in the number of loops contained in the
8346 (nb_loops_around_gb): Moved before setup_cloog_loop that uses it.
8347 (setup_cloog_loop): Rewrite for the new layout of loop domain matrix:
8348 loops that are not surrounding the current loop are not represented
8349 in the domain constraint matrix.
8350 (build_scop_iteration_domain): Initial domain constraint matrix
8351 contains only the eq/ineq, cst, and scop parameters columns.
8353 2008-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
8355 * graphite.c (schedule_to_scattering, nb_loops_around_gb): New.
8356 (print_graphite_bb): Print scattering.
8358 2008-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
8360 * graphite.c (initialize_cloog_names): Initialize names of
8361 scattering variables.
8363 2009-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
8365 * graphite.c (dot_all_scops_1): Disable debug output while
8368 2008-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
8370 * graphite.c (find_transform): Change cloog output language to C.
8372 2008-01-27 Sebastian Pop <sebastian.pop@amd.com>
8374 * tree-loop-distribution.c (generate_memset_zero,
8375 generate_builtin, generate_code_for_partition,
8376 rdg_flag_all_uses): New.
8377 (rdg_flag_uses): Gather in the same partition the statements defining
8378 the VUSES of the current statement.
8379 (rdg_flag_similar_stores): Renamed rdg_flag_similar_memory_accesses.
8380 Gather in the same partition not only the stores to the same memory
8381 access, but also the reads.
8382 (ldist_generate_loops): Renamed ldist_gen.
8384 2008-01-24 Sebastian Pop <sebastian.pop@amd.com>
8385 Tobias Grosser <grosser@fmi.uni-passau.de>
8387 * graphite.c (setup_cloog_loop): Chain all cloog loops with the
8388 next pointer, don't use the inner pointer.
8390 2008-01-20 Tobias Grosser <grosser@fmi.uni-passau.de>
8392 * graphite.c (dot_all_scops, dot_all_scops_1): New.
8393 (find_transform): Call dot_all_1.
8394 * graphite.h (dot_all_scops): Declared.
8396 2007-12-14 Sebastian Pop <sebastian.pop@amd.com>
8398 * tree-loop-distribution.c: Fix apsi.f ICE.
8399 (create_bb_after_loop): New.
8400 (generate_loops_for_partition): Use it.
8401 * gfortran.dg/ldist-1.f90: New.
8403 * tree-data-ref.c (dot_rdg): Use /tmp/rdg.dot for dotty format.
8404 * graphite.c (dot_scop): Use /tmp/scop.dot for dotty format.
8406 2007-12-13 Tobias Grosser <grosser@fmi.uni-passau.de>
8408 * graphite.c (find_transform): Dump cloog program sent to cloog.
8410 2007-12-13 Tobias Grosser <grosser@fmi.uni-passau.de>
8412 * graphite.c (initialize_cloog_names): Initialize cloog
8415 2007-12-13 Tobias Grosser <grosser@fmi.uni-passau.de>
8417 * graphite.c (build_scop_context): Fix typo, for the matrix
8418 format: insert '0 >= 0' instead of '-1 >= 0'.
8420 2007-12-13 Sebastian Pop <sebastian.pop@amd.com>
8422 * Fix merge problems.
8424 2007-12-13 Sebastian Pop <sebastian.pop@amd.com>
8426 * graphite.c (setup_cloog_loop): Fix typo.
8428 2007-12-12 Sebastian Pop <sebastian.pop@amd.com>
8430 * doc/invoke.texi (-ftree-loop-distribution): Documented.
8431 * tree-loop-distribution.c: Reimplemented.
8432 * tree-pass.h (pass_loop_distribution): New.
8433 * tree-scalar-evolution.c (number_of_iterations_for_all_loops): Use
8435 * graphds.h (struct graph): New field indexes.
8436 * timevar.def (TV_TREE_LOOP_DISTRIBUTION): New.
8438 * tree-vect-analyze.c: Remove declaration of static functions when not
8440 * tree-vectorizer.c: Same.
8441 (rename_variables_in_loop): Now extern.
8442 (slpeel_tree_duplicate_loop_to_edge_cfg): Renamed
8443 tree_duplicate_loop_to_edge_cfg. Reset PENDING_STMT for edges after
8444 calling redirect_edge_and_branch_force.
8446 * tree-vectorizer.h (tree_duplicate_loop_on_edge): Declared.
8448 * tree-data-ref.c: Don't include tree-chrec.h.
8449 (debug_data_dependence_relations): New.
8450 (dump_data_dependence_relation): Call dump_data_reference on data refs
8452 (same_access_functions): Moved...
8453 (find_vertex_for_stmt): Renamed rdg_vertex_for_stmt.
8454 (dump_rdg_vertex, debug_rdg_vertex, dump_rdg_component,
8455 debug_rdg_component, dump_rdg, debug_rdg, dot_rdg_1, dot_rdg,
8456 struct rdg_vertex_info, ): New.
8457 (create_rdg_edge_for_ddr): Compute the dependence level before looking
8459 (create_rdg_vertices): Initialize the htab of graph->indexes.
8460 Initialize RDG_MEM_WRITE_STMT and RDG_MEM_READS_STMT.
8461 (stmts_from_loop): Don't save LABEL_EXPR.
8462 (hash_stmt_vertex_info, eq_stmt_vertex_info,
8463 hash_stmt_vertex_del): New.
8464 (build_rdg): Initialize rdg->indexes.
8465 (free_rdg, stores_from_loop, ref_base_address,
8466 rdg_defs_used_in_other_loops_p, have_similar_memory_accesses,
8467 have_similar_memory_accesses_1, ref_base_address_1,
8468 remove_similar_memory_refs): New.
8470 * tree-data-ref.h: Include tree-chrec.h.
8471 (debug_data_dependence_relations): Declared.
8472 (same_access_functions): ...here. Now static inline.
8473 (ddr_is_anti_dependent, ddrs_have_anti_deps,
8474 ddr_dependence_level): New.
8475 (struct rdg_vertex): New fields has_mem_write, has_mem_reads.
8476 (RDGV_HAS_MEM_WRITE, RDGV_HAS_MEM_READS, RDG_STMT, RDG_MEM_WRITE_STMT,
8477 RDG_MEM_READS_STMT): New.
8478 (dump_rdg_vertex, debug_rdg_vertex, dump_rdg_component,
8479 debug_rdg_component, dump_rdg, debug_rdg, dot_rdg,
8480 rdg_vertex_for_stmt): Declared.
8481 (struct rdg_edge): New field level.
8482 (RDGE_LEVEL, free_rdg): New.
8483 (stores_from_loop, remove_similar_memory_refs,
8484 rdg_defs_used_in_other_loops_p,
8485 have_similar_memory_accesses): Declared.
8486 (rdg_has_similar_memory_accesses): New.
8488 * lambda.h (dependence_level): New.
8489 * common.opt (ftree-loop-distribution): New.
8490 * tree-flow.h (debug_loop_ir): Renamed debug_loops.
8491 (print_loop_ir): Renamed print_loops.
8492 (debug_loop, debug_loop_num, print_loops_bb, mark_virtual_ops_in_bb,
8493 tree_duplicate_loop_to_edge_cfg, rename_variables_in_loop): Declared.
8494 * Makefile.in (TREE_DATA_REF_H): Depends on tree-chrec.h.
8495 (tree-loop-distribution.o): Added.
8496 * tree-cfg.c (mark_virtual_ops_in_region): Use mark_virtual_ops_in_bb.
8497 (mark_virtual_ops_in_bb): New.
8498 (print_loops_bb, debug_loop_num, debug_loop): New.
8499 * passes.c: Scheduled pass_loop_distribution.
8501 2007-12-12 Konrad Trifunovic <konrad.trifunovic@inria.fr>
8503 * graphite.c (scan_tree_for_params): Correct the number of columns
8505 (nb_flat_iterator): New.
8506 (setup_cloog_loop): Initialize to 1 the first column for inequalities.
8507 (build_scop_iteration_domain): Correct the number of columns for
8510 2007-12-12 Sebastian Pop <sebastian.pop@amd.com>
8512 * Merge from mainline (129697:130800).
8514 2007-10-30 Sebastian Pop <sebastian.pop@amd.com>
8516 * graphite.c (build_graphite_bb): SCoP's basic blocks are post
8517 dominated by SCoP's exit.
8518 (graphite_transform_loops): Compute post dominators.
8520 2007-10-28 Sebastian Pop <sebastian.pop@amd.com>
8522 * Merge from mainline (127169:129697).
8524 2007-10-28 Sebastian Pop <sebastian.pop@amd.com>
8526 * graphite.c (affine_expr): Renamed scop_affine_expr. Use an extra
8527 parameter for the basic block that contains the expression. Use
8528 outermost_loop_in_scop for evolution_function_is_affine_multivariate_p.
8529 (stmt_simple_for_scop_p): Pass to scop_affine_expr the basic block of
8531 * graphite.h (gbb_loop): New.
8532 (GBB_LOOP): Removed.
8534 2007-08-03 Sebastian Pop <sebpop@gmail.com>
8536 * Makefile.in: Fix merge problem.
8538 2007-08-03 Sebastian Pop <sebpop@gmail.com>
8540 * Merge from mainline (125309:127169).
8541 * tree-loop-distribution.c: Disabled.
8543 2007-06-05 Sebastian Pop <sebpop@gmail.com>
8545 * Merge from mainline (r123693:125309).
8547 2007-05-30 Sebastian Pop <sebpop@gmail.com>
8549 * tree-loop-distribution.c (correct_modify_expr_p): Renamed
8551 (correct_modify_p, check_statements, number_of_lvalue_uses,
8552 number_of_scalar_dependences, create_edges): Use GIMPLE_MODIFY_STMT
8553 instead of MODIFY_EXPR.
8554 (update_edge_with_ddv): Don't pass index_of_edge. Initialize
8557 2007-05-24 Sebastian Pop <sebpop@gmail.com>
8559 * tree-loop-distribution.c (struct rdg): Replace arrays by
8560 VECs for edges and vertices.
8561 (RDG_NBV, RDG_NBE, RDG_VERTEX, RDG_EDGE): Removed.
8562 (RDGV_NB_PARTITIONS): New.
8563 (PRDG_NBV, PRDG_NBE): Removed.
8564 (build_scc_graph, correct_partitions_p, mark_partitions, build_prdg,
8565 dump_rdg, find_vertex_with_stmt, create_vertices, free_rdg,
8566 number_of_scalar_dependences, create_edges, build_rdg): Use VECs.
8568 2007-05-17 Georges-Andre Silber <silber@cri.ensmp.fr>
8569 Sebastian Pop <sebpop@gmail.com>
8571 * doc/invoke.texi (-ftree-loop-distribution): Document.
8572 * tree-loop-distribution.c: New file.
8573 * tree-pass.h (pass_loop_distribution): Declared.
8574 * timevar.def (TV_TREE_LOOP_DISTRIBUTION): New.
8575 * tree-data-ref.c (initialize_data_dependence_relation): Initialize
8577 * tree-data-ref.h (data_dependence_relation): Add reversed_p.
8578 (DDR_REVERSED_P): New.
8579 * common.opt (-ftree-loop-distribution): New.
8580 * tree-flow.h (distribute_loops): Declared.
8581 * Makefile.in (OBJS-common): Depend on tree-loop-distribution.o.
8582 * passes.c (init_optimization_passes): Schedule loop distribution.
8584 2007-05-12 Sebastian Pop <sebastian.pop@inria.fr>
8586 * graphite.c (print_graphite_bb): Don't call dump_data_references.
8587 (print_scop): Don't print when scop is NULL.
8588 (build_scop_context, find_transform): Don't output to stderr.
8590 2007-05-09 Sebastian Pop <sebastian.pop@inria.fr>
8592 * tree-data-ref.c: Don't include graphite.h.
8593 Comment out the code for printing data reference's scop.
8594 (build_access_matrix_with_af): Moved...
8595 * tree-data-ref.h (build_access_matrix_with_af): Removed declaration.
8596 * graphite.c (build_access_matrix_with_af): ... here. Now static.
8597 (print_graphite_bb): Print basic block's schedule.
8598 (print_scop): Don't print the schedule, call cloog's pretty printer.
8599 (bb_in_scop_p): A basic block is in a scop only if it is both
8600 dominated and postdominated by the scop's entry and exit basic blocks.
8601 (function_parameter_p): New.
8602 (invariant_in_scop_p): Use function_parameter_p.
8603 (new_scop, save_scop): New.
8604 (end_scop, test_for_scop_bound, build_scops): Use new_scop, and
8606 (scan_tree_for_params): Directly build the constraint as CloogMatrix.
8607 (loop_in_scop_p): New.
8608 (scop_record_loop): Use loop_in_scop_p.
8609 (build_scop_domain): Renamed build_scop_iteration_domain.
8610 (setup_cloog_loop, initialize_cloog_names, find_scop_parameters,
8611 nb_params_in_scop, build_scop_context, first_loop_in_scop,
8612 setup_cloog_loop, dot_scop_1, dot_scop): New.
8613 * graphite.h (GBB_LOOP, SCOP_PROG, dot_scop): New.
8614 (struct scop): Add a pointer to cloog's representation of a program.
8616 2007-04-14 Sebastian Pop <sebastian.pop@inria.fr>
8618 * doc/invoke.texi (-ftree-check-verbose): Renamed
8619 -ftree-checks-verbose.
8620 * common.opt (flag_tree_check_verbose): Renamed
8621 flag_tree_checks_verbose.
8622 * tree-check.c (tree_check_warning): Use flag_tree_checks_verbose.
8624 2007-04-14 Sebastian Pop <sebastian.pop@inria.fr>
8626 * configure: Regenerated.
8627 * config.in: Regenerated.
8628 * tree-ssa-loop.c (graphite_transforms): Execute
8629 graphite_transform_loops only when HAVE_cloog.
8630 * configure.ac (HAVE_polylib, HAVE_cloog, GRAPHITE): Defined.
8631 * graphite.c: Include polylibgmp.h and cloog.h.
8632 (graphite_transform_loops): Removed loops parameter.
8633 * tree-flow.h (graphite_transform_loops): Update declaration.
8634 * Makefile.in (POLYLIBLIBS, POLYLIBINC, CLOOGLIBS, CLOOGINC): New.
8635 (LIBS): Depend on CLOOGLIBS and on POLYLIBLIBS.
8636 (INCLUDES): Depend on POLYLIBINC and on CLOOGINC.
8637 (OBJS-common): Remove dependence on graphite.o.
8638 (BACKEND): Depend on @GRAPHITE@.
8640 2007-04-13 Sebastian Pop <sebastian.pop@inria.fr>
8642 * doc/invoke.texi (-ftree-check-verbose): Documented.
8643 * gcc.dg/tree-checker/tree-checks-1.c: New.
8644 * gcc.dg/tree-checker/tree-checks-2.c: New.
8645 * gcc.dg/tree-checker/tree-checks-3.c: New.
8646 * gcc.dg/tree-checker/tree-checks-4.c: New.
8647 * gcc.dg/tree-checker/tree-checks.exp: New.
8648 * gcc.dg/tree-checker/condates.crp: New.
8649 * common.opt (ftree-checks-verbose): New.
8650 * tree-check.c (tree_check_warning): Move extra stderr output
8651 under control of flag_tree_check_verbose.
8653 2007-04-12 Sebastian Pop <sebastian.pop@inria.fr>
8655 * tree-match.c: Fix comments formatting.
8656 * tree-match.h: Fix comments formatting.
8657 * tree-check.c: Fix comments formatting.
8658 (tree_check_init): Restructure.
8660 2007-04-12 Nic Volanschi <nic.volanschi@free.fr>
8662 * doc/invoke.texi (-ftree-check, -ftree-checks): Documented.
8664 2007-04-10 Sebastian Pop <sebastian.pop@inria.fr>
8666 * Merge from mainline (r120733:123693).
8668 2007-03-20 Nic Volanschi <nic.volanschi@free.fr>
8670 * condate.y: New file.
8671 * tree-match.h (struct patt_info_s): New field sign.
8672 (struct condate_s): New field msg.
8673 (normalize_condate, name_condate, add_condate): New.
8674 (conds[], condate_parse): Made extern.
8675 * tree-check.c (tree_check_warning): First arg changed to cond;
8676 warning reformatted.
8677 (tree_check_init): Reset the TREE_VISITED bit on every CFG node.
8679 (tree_check): Process trivial condates.
8680 (read_delimited_string): Removed.
8681 (print_cond): Print name and msg.
8682 (conds[]): Made extern.
8683 (parse_tree_check_file_once): Rewritten to use the parser in
8685 Processing of option --tree_check_string moved to tree_scan().
8686 * Makefile.in: Added condate.y
8688 2007-03-12 Sebastian Pop <sebastian.pop@inria.fr>
8690 * tree-pretty-print.c (dump_generic_bb_buff, lazy_dump_generic_node):
8691 Use VECs instead of varrays.
8692 * diagnostic.h (lazy_dump_generic_node): Update declaration.
8693 * Makefile.in (pretty-print.o): Depend on vec.h.
8694 * pretty-print.c: Include tree.h and vec.h.
8695 (pp_clear_state, pp_write_list_to_stream, pp_base_format,
8696 pp_base_format, pp_construct, pp_base_string, pp_lazy_mode,
8697 new_tree_chunk, pp_add_tree, pp_add_string, pp_add_char, pp_write_list,
8698 pp_free_list): Use VECs instead of varrays.
8699 * pretty-print.h: Do not include varray.h.
8700 (struct tree_chunk_s): Declaration moved before its use.
8701 (output_buffer): Rename varray field to chunks.
8702 * tree-match.c (tree_equal, chunk_1st_char, chunks_lookahead,
8703 tree_1st_char, match_chunks_pattinfo, match_tree_pattinfo,
8704 save_global_holes): Use VECs instead of varrays.
8705 * tree-match.h: Declare VECs of cfg_node, and hole_p.
8706 * tree-check.c (scan_cfg_stmts, push_node,
8707 print_matching_stmt): Removed.
8708 (tree_check_instance, push_global_holes_if_new, tree_check,
8709 execute_tree_check): Use VECs instead of varrays.
8710 (gate_tree_check): Don't execute the CFG check when basic_block_info
8713 2007-01-12 Sebastian Pop <sebastian.pop@inria.fr>
8715 * Merge from mainline (r115016:120733).
8717 2007-01-12 Sebastian Pop <sebastian.pop@inria.fr>
8719 * Merge from mainline (r117632:117661).
8721 2007-01-12 Sebastian Pop <sebastian.pop@inria.fr>
8723 * tree-dump.c (dump_option_value_in): Add TDF_DEBUG.
8724 * tree-pass.h (TDF_DEBUG, debug_p): New.
8725 * tree-scalar-evolution.c (set_scalar_evolution, get_scalar_evolution,
8726 get_scalar_evolution, add_to_evolution, set_nb_iterations_in_loop,
8727 get_loop_exit_condition, analyze_evolution_in_loop,
8728 analyze_initial_condition, analyze_scalar_evolution,
8729 instantiate_parameters, number_of_latch_executions): Use debug_p.
8730 * tree-chrec.c (chrec_apply): Use debug_p.
8731 * tree-data-ref.c: Include graphite.h.
8732 (dump_data_reference): Print also the access matrix.
8733 (analyze_array, analyze_indirect_ref, init_data_ref,
8734 analyze_offset_expr, address_analysis, object_analysis,
8735 create_data_ref, finalize_ddr_dependent,
8736 non_affine_dependence_relation, analyze_ziv_subscript,
8737 analyze_siv_subscript_cst_affine,
8738 compute_overlap_steps_for_affine_1_2, analyze_subscript_affine_affine,
8739 can_use_analyze_subscript_affine_affine, analyze_siv_subscript,
8740 analyze_miv_subscript, analyze_overlapping_iterations,
8741 build_classic_dist_vector, subscript_dependence_tester,
8742 compute_affine_dependence, analyze_all_data_dependences): Use debug_p.
8743 (build_access_matrix_with_af): No longer static.
8744 * tree-data-ref.h (scop_p): ... declaration here.
8745 (data_reference.scop): New field.
8746 (DR_SCOP, DR_ACCESS_MATRIX): New.
8747 (build_access_matrix_with_af, dr_num_subscripts): Declared.
8748 * graphite.c (print_graphite_bb): Call dump_data_references.
8749 (print_scop): Use scop_nb_loops and scop_dim_domain.
8750 (test_for_scop_bound): Use debug_p.
8751 (scan_tree_for_params): Use scop_nb_loops, scop_nb_loops and
8753 (scop_loop_index): Moved...
8754 (scop_record_loop): New.
8755 (build_scop_loop_nests): Use scop_record_loop.
8756 (build_scop_domain): Use scop_dim_domain.
8757 (build_access_matrix): Implemented.
8758 (build_scop_canonical_schedules): Use scop_nb_loops.
8759 (build_graphite_bb): Initialize GBB_SCOP.
8760 * graphite.h (scop_p): Moved...
8761 (graphite_bb.scop): New field.
8762 (graphite_bb.iteration_domain, GBB_DOMAIN, scop.nb_params,
8763 scop.nb_loops, scop.dim_domain, SCOP_NB_LOOPS, SCOP_NB_PARAMS,
8764 SCOP_DIM_DOMAIN, SCOP_STMTS): Removed.
8765 (scop_nb_params, scop_nb_loops, scop_dim_domain, gbb_dim_domain,
8766 scop_loop_index): New.
8767 * Makefile.in (tree-data-ref.o): Depends on graphite.h.
8769 2007-01-05 Sebastian Pop <sebastian.pop@inria.fr>
8771 * Merge from mainline (r117661:120450).
8773 2006-10-12 Sebastian Pop <sebastian.pop@inria.fr>
8775 * tree-scalar-evolution.c (instantiate_parameters_1): Don't stop
8776 at the first declaration outside the varying loop, instantiate as
8778 * tree-chrec.c (for_each_scev_op): New.
8779 * tree-chrec.h (for_each_scev_op): Declared.
8780 * tree-ssa-loop.c (pass_graphite_trans): Don't dump the function.
8781 * tree-data-ref.c (get_references_in_stmt,
8782 find_data_references_in_stmt): New, from trunk.
8783 (find_data_references_in_loop): Use get_references_in_stmt
8784 and find_data_references_in_loop, modified as in trunk.
8785 (build_access_matrix_with_af): New.
8786 * tree-data-ref.h (data_reference): Add a field access_matrix.
8787 (data_ref_loc): New, as in trunk.
8788 * graphite.c (print_graphite_bb, bb_in_scop_p, stmt_in_scop_p,
8789 invariant_in_scop_p, param_index, scan_tree_for_params,
8790 scop_loop_index, build_scop_loop_nests, build_scop_domain, irp_data,
8791 idx_record_param, idx_record_params, build_access_matrix,
8792 build_scop_data_accesses, build_scop_canonical_schedules,
8793 build_graphite_bb, build_scop_bbs, find_params_in_bb,
8794 build_scop_params): New.
8795 * graphite.h (graphite_bb): New.
8796 (scop): Add fields static_schedule, params, loop_nest,
8798 * lambda.h: Declare vecs of lambda_matrix.
8799 * tree-flow.h (print_loop_ir_bb): Declared.
8800 * tree-cfg.c (print_loop_ir_bb): New.
8801 (print_loop): Use print_loop_ir_bb.
8803 2006-10-12 Sebastian Pop <pop@cri.ensmp.fr>
8805 * Merge from mainline (r115016:117632).
8807 2006-10-11 Sebastian Pop <pop@cri.ensmp.fr>
8809 * graphite.c (debug_scops): Adjust definition for avoiding a bootstrap
8810 break due to a warning.
8812 2006-10-10 Sebastian Pop <pop@cri.ensmp.fr>
8814 * graphite.c (print_scops, debug_scops): New.
8815 (graphite_transform): Renamed graphite_find_transform.
8816 * graphite.h (debug_scops): Declared.
8818 2006-08-17 Sebastian Pop <pop@cri.ensmp.fr>
8820 * tree-match.c: Reformat following the GNU style.
8821 * tree-match.h: Reformat following the GNU style.
8822 * tree-pattern.h: Removed empty file.
8823 * Makefile.in: Remove references to tree-pattern.h.
8824 * tree-check.c: Reformat following the GNU style.
8825 (execute_tree_check): Move gate condition code to...
8826 (gate_tree_check): ...here. New function.
8827 (pass_check): Use the gate function.
8829 2006-07-04 Nic Volanschi <nic.volanschi@free.fr>
8831 * tree-pattern.h: New. Tree pattern matching and checking using
8833 * tree-check.c: New. Tree/CFG checking pass.
8834 * tree-match.c: New. Library for tree pattern matching.
8835 * opts.c, common.opt: Add options --ftree-check & --ftree-checks.
8836 * toplev.c, flags.h: Add globals for tree-check pass.
8837 * Makefile.in: Integrate the files in tree-check pass.
8838 * timevar.def, tree-optimize.c, tree-pass.h: Register tree-check pass.
8839 * pretty-print.c, pretty-print.h, tree-pretty-print.c, diagnostic.h:
8840 Introduce a "lazy" pretty-print mode.
8841 * tree.c, tree.h: Add tree_name.
8843 2006-07-04 Sebastian Pop <pop@cri.ensmp.fr>
8845 * doc/invoke.texi (-fgraphite): Correct typo.
8846 * tree-scalar-evolution.c (number_of_iterations_for_all_loops): Update
8847 use of print_loop_ir.
8848 * gcc.dg/graphite/scop-1.c: New.
8849 * gcc.dg/graphite/scop-2.c: New.
8850 * gcc.dg/graphite/graphite.exp: New.
8851 * graphite.c: Include domwalk.h.
8852 (print_scop): Print only the entry and exit blocks.
8853 (debug_scop): No longer static.
8854 (affine_expr): Fix formating. Return also true when the expression is
8856 (stmt_simple_for_scop_p): Fix formating.
8857 (build_scops): Use domwalk.
8858 (get_loop_start, end_scop, test_for_scop_bound): New.
8859 (graphite_transform_loops): Avoid printing on stderr.
8860 * graphite.h (debug_scop): Declared.
8861 * tree-flow.h (debug_loop_ir, print_loop_ir): Update declarations.
8862 * Makefile.in (graphite.o): Depend on domwalk.h.
8863 * tree-cfg.c (print_loop, print_pred_bbs, print_succ_bbs): Remove
8864 declarations for static functions.
8865 (print_loop, print_loop_ir, debug_loop_ir): Use an extra parameter for
8866 controlling output verbosity.
8868 2006-06-26 Sebastian Pop <pop@cri.ensmp.fr>
8869 Plesco Alexandru <shurikx@gmail.com>
8871 * doc/invoke.texi (-fgraphite): Document.
8872 * tree-pass.h (pass_graphite_transforms): Declared.
8873 * timevar.def (TV_GRAPHITE_TRANSFORMS): New.
8874 * tree-ssa-loop.c (graphite_transforms, gate_graphite_transforms): New.
8875 (pass_graphite_transforms): Defined.
8876 * tree-data-ref.c (free_data_ref, data_reference): Extern.
8877 * tree-data-ref.h (free_data_ref, data_reference): Declared.
8878 * graphite.c, graphite.h: New.
8879 * common.opt (fgraphite): Declared.
8880 * tree-flow.h (graphite_transform_loops): Declared.
8881 * Makefile.in (OBJS-common): Add graphite.o.
8882 (graphite.o): New rule.
8883 * passes.c (pass_graphite_transforms): Scheduled.