1 2011-01-15 Sebastian Pop <sebastian.pop@amd.com>
3 * graphite-dependences.c (build_lexicographical_constraint): Stop the
4 iteration when the bag of constraints is empty.
6 2011-01-15 Sebastian Pop <sebastian.pop@amd.com>
8 * graphite-poly.c (pbb_remove_duplicate_pdrs): Make it work.
10 2011-01-15 Sebastian Pop <sebastian.pop@amd.com>
12 * graphite-interchange.c (lst_interchange_profitable_p): Takes a loop
13 nest and two loop depths as parameters.
14 (lst_try_interchange_loops): Call lst_interchange_profitable_p after
17 2011-01-15 Sebastian Pop <sebastian.pop@amd.com>
19 * graphite-dependences.c (print_pddr): Call
20 ppl_io_fprint_Pointset_Powerset_C_Polyhedron.
22 2011-01-15 Sebastian Pop <sebastian.pop@amd.com>
24 * graphite-ppl.c (debug_gmp_value): New.
25 * graphite-ppl.h (debug_gmp_value): Declared.
27 2011-01-13 Tobias Grosser <grosser@fim.uni-passau.de>
29 * doc/install.texi: Document availability of cloog-0.16
31 2011-01-05 Vladimir Kargov <kargov@gmail.com>
33 * graphite-scop-detection.c (is_valid_stmt_p): Pass the entry basic
34 block instead of region start to the instantiation.
35 (is_valid_bb_p): Add support for basic blocks with conditional
37 (find_scops_new): Recalculate dominance info before SCOP
40 2011-01-05 Vladimir Kargov <kargov@gmail.com>
42 * graphite-scop-detection.c (get_outermost_loop_in_region): New.
43 (is_valid_loop_p): Correct loop passed to stmt_has_simple_data_refs_p
45 2011-01-05 Vladimir Kargov <kargov@gmail.com>
47 * graphite-scop-detection.c (canonicalize_loop_closed_ssa): Free
48 invalid postdominance info
50 2010-12-29 Sebastian Pop <sebastian.pop@amd.com>
52 * Makefile.in (graphite-opencl-codegen.o): Update dependences.
53 (graphite-opencl-meta-clast.o): Same.
54 (graphite-opencl.o): Same.
55 (refined-regions.o): Same.
56 * graphite-opencl-codegen.c: Do not include unnecessary .h files.
57 * graphite-opencl-meta-clast.c: Same.
58 * graphite-opencl.c: Same.
59 * refined-regions.c: Same.
61 2010-12-27 Sebastian Pop <sebastian.pop@amd.com>
63 * graphite-opencl-codegen.c: Use FOR_EACH_VEC_ELT.
64 * graphite-opencl-meta-clast.c: Same.
65 * graphite-opencl.c: Same.
67 2010-12-27 Sebastian Pop <sebastian.pop@amd.com>
69 * graphite-opencl-codegen.c: Do not include sys/time.h.
70 * graphite-opencl.c: Same.
72 2010-12-27 Sebastian Pop <sebastian.pop@amd.com>
74 * graphite-opencl.c (h_context, h_cmd_queue, h_program): Moved
75 out of ifdef HAVE_cloog section.
77 2010-12-27 Sebastian Pop <sebastian.pop@amd.com>
79 * Makefile.in (graphite-opencl.o): Depends on
80 graphite-opencl-functions.def.
81 * graphite-opencl-functions.def: New.
82 * graphite-opencl.c (enum OPENCL_FUNCTIONS): Read data from
83 graphite-opencl-functions.def.
84 (opencl_function_names): Same.
85 (opencl_create_function_decl): Use the enum OPENCL_FUNCTIONS
86 as indices of opencl_function_names.
88 2010-12-27 Sebastian Pop <sebastian.pop@amd.com>
90 * graphite-opencl-codegen.c: Fix formatting.
91 * graphite-opencl-meta-clast.c: Same.
92 * graphite-opencl.c: Same.
94 2010-12-27 Sebastian Pop <sebastian.pop@amd.com>
96 * graphite-opencl-codegen.c: Fix formating problems.
97 * graphite-opencl-meta-clast.c: Same.
98 * graphite-opencl.c: Same.
99 * graphite-opencl.h: Same.
101 2010-12-27 Sebastian Pop <sebastian.pop@amd.com>
103 * graphite-opencl-codegen.c: Sort topologically static functions.
104 * graphite-opencl.c: Same.
106 2010-12-25 Sebastian Pop <sebastian.pop@amd.com>
108 * graphite-cloog-compat.h (cloog_names_nb_scattering): New.
109 (cloog_names_scattering): New.
110 * graphite-opencl-codegen.c (opencl_constant_expression_p): Use
111 clast_expr_* instead of expr_*. Call clast_name_to_str.
112 (opencl_clast_name_to_tree): Now takes a clast_name_p in parameter.
113 (opencl_get_scat_real_name): Same. Call clast_name_to_str.
114 (opencl_add_scat_as_arg): Same.
115 (opencl_print_local_vars): Call cloog_names_scattering and
116 cloog_names_nb_scattering.
117 (opencl_print_for): Do not call value_*.
118 (opencl_print_term): Same.
119 (opencl_print_expr): Use clast_expr_* instead of expr_*.
120 (opencl_print_sum): Same.
121 (opencl_print_binary): Same.
123 2010-12-25 Alexey Kravets <kayrick@ispras.ru>
125 * Makefile.in (OBJS-common): Add graphite-opencl-codegen.o,
126 graphite-opencl-meta-clast.o and graphite-opencl.o.
127 (graphite-opencl-codegen.o): New.
128 (graphite-opencl-meta-clast.o): New.
129 (graphite-opencl.o): New.
130 (GTFILES): Add graphite-opencl.c.
131 * common.opt (fgraphite-opencl): New.
132 (fgraphite-opencl-cpu): New.
133 (fgraphite-opencl-ignore-depth-heuristic): New.
134 (fgraphite-opencl-ignore-mem-heuristic): New.
135 (fgraphite-opencl-ignore-dep): New.
136 (fgraphite-opencl-ignore-types): New.
137 (fgraphite-opencl-depth-base): New.
138 (fgraphite-opencl-debug): New.
139 * graphite-opencl-codegen.c: New file.
140 * graphite-opencl-meta-clast.c: New file.
141 * graphite-opencl.c: New file.
142 * graphite-opencl.h: New file.
143 * graphite.c (graphite_transform_loops): Call graphite_opencl_init and
144 graphite_opencl_finalize.
145 * tree-ssa-loop.c (gate_graphite_transforms): Handle
146 flag_graphite_opencl.
147 * graphite-clast-to-gimple.c (gloog): Call opencl_transform_clast.
148 * dbgcnt.def (opencl_scop_cnt): New counter.
150 2010-12-25 Alexander Monakov <amonakov@ispras.ru>
152 * graphite-dependences.c (graphite_outer_subscript_bound): New.
153 (graphite_carried_dependence_level_k): Export.
154 * graphite-dependences.h (graphite_outer_subscript_bound): Declare.
155 (graphite_carried_dependence_level_k): Ditto.
157 2010-12-25 Alexey Kravets <kayrick@ispras.ru>
159 * graphite-clast-to-gimple.c (struct clast_name_index): Move
160 definition to graphite-clast-to-gimple.h.
161 (clast_name_to_index): Ditto.
162 (clast_name_index_elt_info): Ditto.
163 (eq_clast_name_indexes): Ditto.
164 (save_clast_name_index): Export.
165 (clast_name_to_gcc): Ditto.
166 (clast_to_gcc_expression): Ditto.
167 (gcc_type_for_clast_expr): Ditto.
168 (graphite_create_new_guard): Ditto.
169 (gcc_type_for_iv_of_clast_loop): Ditto.
170 (graphite_create_new_loop): Ditto.
171 (build_iv_mapping): Ditto.
172 (graphite_create_new_loop_guard): Ditto.
173 (debug_clast_name_index): New.
174 (debug_clast_name_indices): New debug function.
176 2010-12-21 Sebastian Pop <sebastian.pop@amd.com>
178 PR tree-optimization/47021
179 * graphite-sese-to-poly.c (scan_tree_for_params): Handle ADDR_EXPR.
181 2010-11-26 Sebastian Pop <sebastian.pop@amd.com>
183 * graphite-sese-to-poly.c (analyze_drs_in_stmts): Fix set but
185 (rewrite_cross_bb_scalar_deps_out_of_ssa): Same.
187 2010-11-26 Sebastian Pop <sebastian.pop@amd.com>
189 * graphite-sese-to-poly.c (analyze_drs): Removed.
190 (build_scop_drs): Do not call analyze_drs.
191 (analyze_drs_in_stmts): New.
193 (insert_out_of_ssa_copy): Call analyze_drs_in_stmts.
194 (insert_out_of_ssa_copy_on_edge): Same.
195 (rewrite_close_phi_out_of_ssa): Call insert_stmts.
196 (rewrite_phi_out_of_ssa): Same.
197 (rewrite_cross_bb_scalar_dependence): Same.
198 (split_reduction_stmt): Move data references in the new basic blocks.
199 (translate_scalar_reduction_to_array_for_stmt): Call insert_stmts.
201 2010-11-26 Sebastian Pop <sebastian.pop@amd.com>
203 * sese.c (rename_uses): Do not handle ADDR_EXPR in LHS of assignments.
205 2010-11-22 Sebastian Pop <sebastian.pop@amd.com>
208 * graphite-poly.c (new_poly_bb): Returns a poly_bb_p. Do not take
209 the reduction bool in parameter. Clear PBB_IS_REDUCTION. Set GBB_PBB.
210 * graphite-poly.h (new_poly_bb): Update declaration.
211 (gbb_from_bb): Moved here...
213 * graphite-sese-to-poly.c (var_used_in_not_loop_header_phi_node):
215 (graphite_stmt_p): Removed.
216 (try_generate_gimple_bb): Returns a gimple_bb_p. Do not pass in
217 sbitmap reductions. Always build a gimple_bb_p. Do not call
219 (build_scop_bbs_1): Do not pass in sbitmap reductions.
220 (build_scop_bbs): Same.
221 (gbb_from_bb): ... from here.
222 (add_conditions_to_constraints): Moved up.
224 (build_scop_drs): Call analyze_drs. Remove all the PBBs that do
225 not contain data references.
226 (new_pbb_from_pbb): New.
227 (insert_out_of_ssa_copy_on_edge): Call new_pbb_from_pbb after a
229 (rewrite_close_phi_out_of_ssa): Update call to
230 insert_out_of_ssa_copy_on_edge.
231 (rewrite_reductions_out_of_ssa): Now static.
232 (rewrite_cross_bb_scalar_deps_out_of_ssa): Same.
234 (split_reduction_stmt): Call split_pbb.
235 (translate_scalar_reduction_to_array): Pass in the scop, do not
236 pass in the sbitmap reductions.
237 (rewrite_commutative_reductions_out_of_ssa_close_phi): Same.
238 (rewrite_commutative_reductions_out_of_ssa_loop): Same.
239 (rewrite_commutative_reductions_out_of_ssa): Same.
240 (build_poly_scop): Call build_scop_bbs,
241 rewrite_commutative_reductions_out_of_ssa,
242 rewrite_reductions_out_of_ssa, and
243 rewrite_cross_bb_scalar_deps_out_of_ssa. Move build_scop_drs
245 * graphite-sese-to-poly.h (rewrite_commutative_reductions_out_of_ssa):
247 (rewrite_reductions_out_of_ssa): Same.
248 (rewrite_cross_bb_scalar_deps_out_of_ssa): Same.
249 (build_scop_bbs): Same.
250 * graphite.c (graphite_transform_loops): Do not initialize reductions.
251 Do not call build_scop_bbs,
252 rewrite_commutative_reductions_out_of_ssa,
253 rewrite_reductions_out_of_ssa, and
254 rewrite_cross_bb_scalar_deps_out_of_ssa.
255 * sese.h (struct gimple_bb): Add field pbb.
258 * gcc.dg/graphite/pr45297.c: New.
260 2010-11-22 Sebastian Pop <sebastian.pop@amd.com>
262 * graphite-sese-to-poly.c (handle_scalar_deps_crossing_scop_limits):
264 (rewrite_cross_bb_scalar_deps): Pass in the scop. Call
265 handle_scalar_deps_crossing_scop_limits.
266 (rewrite_cross_bb_scalar_deps_out_of_ssa): Create an empty BB
267 after the scop. Update call to rewrite_cross_bb_scalar_deps.
269 2010-11-22 Sebastian Pop <sebastian.pop@amd.com>
271 * sese.c (rename_uses): Call recompute_tree_invariant_for_addr_expr
272 when replacing a constant in an ADDR_EXPR.
274 2010-10-20 Sebastian Pop <sebastian.pop@amd.com>
276 * graphite-blocking.c (lst_do_strip_mine_loop): Extra parameter
278 (lst_do_strip_mine): Same.
279 (scop_do_strip_mine): Same.
280 * graphite-poly.c (apply_poly_transforms): Update call to
282 * graphite-poly.h (scop_do_strip_mine): Update declaration.
284 2010-09-24 Sebastian Pop <sebastian.pop@amd.com>
287 * graphite.c (graphite_initialize): Call scev_reset.
289 2010-09-23 Sebastian Pop <sebastian.pop@amd.com>
291 * sese.h (scev_analyzable_p): Return false for real or floating
292 point. Only handle INTEGRAL_TYPE_P and POINTER_TYPE_P.
294 2010-09-23 Sebastian Pop <sebastian.pop@amd.com>
297 * gfortran.dg/graphite/pr45758.f90: New.
299 2010-09-23 Sebastian Pop <sebastian.pop@amd.com>
301 * graphite-scop-detection.c (is_scop_p): Free bblist.
303 2010-09-23 Sebastian Pop <sebastian.pop@amd.com>
305 * graphite-clast-to-gimple.c (compute_bounds_for_level): Free le
307 * graphite-poly.c (pbb_number_of_iterations_at_time): Free le and
309 * graphite-sese-to-poly.c (add_upper_bounds_from_estimated_nit):
310 Do not allocate ub_expr, it is passed in initialized.
312 2010-09-21 Andreas Simbuerger <simbuerg@fim.uni-passau.de>
314 * common.opt (fgraphite-dump-cloog): New flag.
315 * doc/invoke.texi (-fgraphite-dump-cloog): Documented.
316 * graphite-clast-to-gimple.c (init_cloog_input_file): New.
317 (build_cloog_prog): Dump CLooG input file when
318 flag_graphite_dump_cloog is set.
319 * graphite-cloog-compat.h (cloog_program_dump_cloog): New.
321 2010-09-20 Sebastian Pop <sebastian.pop@amd.com>
323 Revert previous patch "New flag: -fgraphite-dump-cloog."
325 2010-09-20 Andreas Simbuerger <simbuerg@fim.uni-passau.de>
327 * common.opt (fgraphite-dump-cloog): New flag.
328 * doc/invoke.texi (-fgraphite-dump-cloog): Documented.
329 * graphite-clast-to-gimple.c (init_cloog_input_file): New.
330 (build_cloog_prog): Dump CLooG input file when
331 flag_graphite_dump_cloog is set.
333 2010-09-20 Sebastian Pop <sebastian.pop@amd.com>
335 * graphite-clast-to-gimple.c (graphite_verify): Remove call to
336 verify_dominators for CDI_POST_DOMINATORS.
337 * sese.h: Remove comment about CDI_POST_DOMINATORS.
338 (recompute_all_dominators): Remove call to free_dominance_info
339 for CDI_POST_DOMINATORS. Remove call to calculate_dominance_info
340 for CDI_POST_DOMINATORS.
342 2010-09-09 Sebastian Pop <sebastian.pop@amd.com>
344 * graphite-poly.c (pbb_number_of_iterations_at_time): Only iterate
345 over pbb_dim_iter_domain.
347 2010-09-09 Sebastian Pop <sebastian.pop@amd.com>
349 * graphite-flattening.c: Fix comments.
351 2010-09-09 Sebastian Pop <sebastian.pop@amd.com>
353 * Makefile.in (OBJS-common): Add graphite-flattening.o.
354 (graphite-flattening.o): New rule.
355 * common.opt (floop-flatten): New flag.
356 * doc/invoke.texi (-floop-flatten): Documented.
357 * graphite-flattening.c: New.
358 * graphite-poly.c (apply_poly_transforms): Call flatten_all_loops.
359 * graphite-poly.h (flatten_all_loops): Declared.
360 (lst_remove_loop_and_inline_stmts_in_loop_father): New.
361 * tree-ssa-loop.c (gate_graphite_transforms): When flag_loop_flatten
362 is set, also set flag_graphite.
364 2010-09-09 Sebastian Pop <sebastian.pop@amd.com>
366 * graphite-poly.c (cloog_checksum): New.
367 * graphite-poly.h (cloog_checksum): Declared.
369 2010-09-09 Sebastian Pop <sebastian.pop@amd.com>
371 * graphite-poly.c (pbb_number_of_iterations): Removed.
372 (pbb_number_of_iterations_at_time): Correctly compute the number
373 of iterations in the transformed loop.
374 * graphite-poly.h (pbb_number_of_iterations): Removed.
376 2010-09-09 Sebastian Pop <sebastian.pop@amd.com>
378 * graphite-poly.h (lst_update_scattering_seq): Removed.
379 (lst_update_scattering): Correctly handle outermost loop dewey
382 2010-09-09 Sebastian Pop <sebastian.pop@amd.com>
384 * graphite-blocking.c (pbb_strip_mine_profitable_p): Renamed
385 lst_strip_mine_profitable_p. Call lst_niter_for_loop.
386 * graphite-poly.h (lst_niter_for_loop): New.
388 2010-09-09 Sebastian Pop <sebastian.pop@amd.com>
390 * graphite-poly.c (apply_poly_transforms): Do not abort when the
391 transform read from disk is not legal. Call fatal_error instead.
393 2010-09-09 Sebastian Pop <sebastian.pop@amd.com>
395 * graphite-poly.c (print_pbb_body): Add missing closing parenthesis.
396 (print_scop_header): Removed. Inlined in the only call place...
397 (print_scop): ... here.
399 2010-09-09 Sebastian Pop <sebastian.pop@amd.com>
401 * graphite-poly.h (lst_dewey_number): Use FOR_EACH_VEC_ELT.
403 2010-09-02 Vladimir Kargov <kargov@gmail.com>
405 * graphite-scop-detection.c (is_valid_expr_p, is_valid_loop_p): New.
406 (is_valid_stmt_p): Add data reference and operation-specific checks.
407 (is_valid_bb_p): Change structure, add loop validity check.
408 (is_scop_p): Move the TODO list
409 (find_scops_new): New.
410 (build_scops_new): Move part of functionality to find_scops_new and
411 build_scops. Add necessary steps for successful SCoP construction.
412 (build_scops): Compute SCoP sets for both detection algorithms, choose
413 the resulting one depending on static condition.
415 2010-08-24 Sebastian Pop <sebastian.pop@amd.com>
417 * graphite-poly.c (graphite_read_scop_file): Fix uninitialize warning.
419 2010-08-24 Sebastian Pop <sebastian.pop@amd.com>
421 * graphite-dependences.c (dot_deps): Avoid set but not used warning.
422 (dot_deps_stmt): Same.
423 * graphite-poly.c (dot_lst): Same.
425 2010-08-23 Sebastian Pop <sebastian.pop@amd.com>
427 * graphite-blocking.c (scop_do_strip_mine): Do not call
428 graphite_legal_transform.
429 (scop_do_block): Same.
431 2010-08-20 Vladimir Kargov <kargov@gmail.com>
433 * graphite-scop-detection.c (graphite_can_represent_loop): Correct the
436 2010-08-20 Sebastian Pop <sebastian.pop@amd.com>
439 * gcc.dg/graphite/id-pr45230.c: New.
441 2010-08-20 Sebastian Pop <sebastian.pop@amd.com>
443 * tree-scalar-evolution.c (instantiate_array_ref): New.
444 (instantiate_scev_r): Also handle ARRAY_REFs.
446 2010-08-20 Sebastian Pop <sebastian.pop@amd.com>
448 * tree-scalar-evolution.c (chrec_contains_symbols_defined_in_loop):
449 Do not check for VAR_DECL, PARM_DECL, FUNCTION_DECL, LABEL_DECL,
450 RESULT_DECL, and FIELD_DECL. Return false for an
451 SSA_NAME_IS_DEFAULT_DEF.
452 (compute_scalar_evolution_in_loop): Do not further analyze the
453 scalar evolution when no_evolution_in_loop_p returns true.
455 2010-08-20 Sebastian Pop <sebastian.pop@amd.com>
457 * tree-chrec.h (evolution_function_is_affine_p): Do not check
458 whether CHREC_LEFT is invariant. A function is affine when
459 CHREC_RIGHT is invariant.
461 2010-08-20 Sebastian Pop <sebastian.pop@amd.com>
463 * graphite-sese-to-poly.c (reduction_phi_p): Remove check for
465 (rewrite_degenerate_phi): Same.
466 (rewrite_reductions_out_of_ssa): Add check for is_gimple_reg.
468 2010-08-18 Vladimir Kargov <kargov@gmail.com>
470 * graphite-scop-detection.c (graphite_can_represent_scev,
471 graphite_can_represent_expr, stmt_has_simple_data_refs_p,
472 graphite_can_represent_loop): Remove outermost_loop.
474 2010-08-17 Sebastian Pop <sebastian.pop@amd.com>
477 * graphite-sese-to-poly.c (rewrite_cross_bb_scalar_deps): Do not
478 handle GIMPLE_CALLs with no LHS.
480 2010-08-17 Riyadh Baghdadi <baghdadi.mr@gmail.com>
481 Sebastian Pop <sebastian.pop@amd.com>
483 * gcc.dg/graphite/graphite.exp: Add test rules for openscop read/write.
484 Call remove-build-file to clean up the generated *.graphite files.
486 2010-08-17 Riyadh Baghdadi <baghdadi.mr@gmail.com>
488 * doc/invoke.texi (debugging options): Update documentation.
489 (-floop-interchange): Same.
490 (-flopp-strip-mine): Same.
491 (-floop-block): Same.
492 (-fgraphite-read): Add documentation.
493 (-fgraphite-write): Same.
495 2010-08-17 Riyadh Baghdadi <baghdadi.mr@gmail.com>
497 * toplev.c (process_options): Disable graphite loop optimization
498 options when -fgraphite-read flag is used.
500 2010-08-17 Riyadh Baghdadi <baghdadi.mr@gmail.com>
502 * graphite-poly.c (init_graphite_out_file): New.
503 (init_graphite_in_file): New.
504 (apply_poly_transforms): Updated to enable reading and writing of
506 * toplev.c (init_asm_output): Remove graphite in/out file initialization.
508 2010-08-17 Tobias Grosser <grosser@fim.uni-passau.de>
510 * graphite-scop-detection.c (graphite_can_represent_scev): Remove
513 2010-08-12 Sebastian Pop <sebastian.pop@amd.com>
515 * graphite-clast-to-gimple.c (precision_for_value): Adjust
516 computation of precision by 1.
518 2010-08-12 Riyadh Baghdadi <baghdadi.mr@gmail.com>
520 * graphite-cloog-util.c (openscop_read_cloog_matrix): New.
521 (openscop_read_polyhedron_matrix): New.
522 * graphite-cloog-util.h (openscop_read_polyhedron_matrix): Declared.
523 (openscop_read_N_int): Same.
524 * graphite-poly.c (openscop_read_N_int): New.
525 (openscop_read_one_int): New.
526 (openscop_read_N_string): New.
527 (openscop_read_one_string): New.
528 (openscop_read_powerset_matrix): New.
529 (graphite_read_transforms): Remove.
530 (graphite_read_scatt): New.
531 (graphite_read_scop_file): New.
532 (apply_poly_transforms): Updated to call graphite_read_scop_file.
534 2010-08-11 Andreas Simbuerger <simbuerg@fim.uni-passau.de>
536 * graphite-poly.c: Change include order.
538 2010-08-11 Andreas Simbuerger <simbuerg@fim.uni-passau.de>
540 * graphite-cloog-compat.h (cloog_matrix_ncolumns): New.
541 (cloog_matrix_nrows): New.
543 2010-08-11 Riyadh Baghdadi <baghdadi.mr@gmail.com>
545 * graphite-cloog-util.c (openscop_print_cloog_matrix): Remove spaces
547 * graphite-poly.c (openscop_print_scattering_function_1): Same.
548 (print_scattering_function_1): Same.
549 (openscop_print_pbb_domain): Same.
550 (openscop_print_scop_context): Same.
551 (print_scop_context): Same.
553 2010-08-11 Riyadh Baghdadi <baghdadi.mr@gmail.com>
555 * graphite-poly.c (openscop_print_pdr_polyhedron): Fix indentation.
556 (openscop_print_pdr_polyhedron): Print pph.
558 2010-07-29 Sebastian Pop <sebastian.pop@amd.com>
560 * gcc.dg/graphite/graphite.exp: Add compile rules for vect-* files.
561 * gfortran.dg/graphite/graphite.exp: Same.
562 * gcc.dg/graphite/vect-pr43423.c: New.
564 2010-07-29 Sebastian Pop <sebastian.pop@amd.com>
566 * graphite-clast-to-gimple.c (gcc_type_for_interval): Generate in
567 priority signed types.
569 2010-07-29 Sebastian Pop <sebastian.pop@amd.com>
571 * graphite-clast-to-gimple.c (max_signed_precision_type): Remove the call
572 to lang_hooks.types.type_for_size. Call build_nonstandard_integer_type.
574 2010-07-29 Riyadh Baghdadi <baghdadi.mr@gmail.com>
576 * graphite-cloog-util.c (openscop_print_cloog_matrix): New.
577 (openscop_print_polyhedron_matrix): New.
578 * graphite-cloog-util.h (openscop_print_polyhedron_matrix): Declared.
579 * graphite-poly.c (openscop_print_pdr_polyhedron): Same.
580 (openscop_print_pdr_powerset): New.
581 (openscop_print_powerset_matrix): New.
582 (openscop_print_scattering_function_1): New.
583 (print_scattering_function): Add support for scattering names and
585 (graphite_write_transforms): Remove.
586 (apply_poly_transforms): Updated to call print_scop.
587 (print_pdr_access_layout): Updated to support OpenScop format.
589 (openscop_print_pbb_domain): New.
590 (print_pbb_body): Added a parameter to allow indicating that pbb_body is
592 (print_pbb): Updated to call the new print_pbb_body.
593 (openscop_print_scop_context): New.
594 (print_scop_header): New.
595 (print_scop): Updated to call print_scop_header.
596 * graphite-poly.h: Document OpenScop format.
598 2010-07-29 Sebastian Pop <sebastian.pop@amd.com>
600 * graphite-sese-to-poly.c (rewrite_close_phi_out_of_ssa): Add back
601 the case removed in the previous patch, when the only phi argument
602 is defined in the same loop as the phi node itself. Handle it
603 separately from the invariant case by both propagating it outside
604 the region and replacing the phi node with an assign.
606 2010-07-28 Sebastian Pop <sebastian.pop@amd.com>
608 * graphite-sese-to-poly.c (rewrite_close_phi_out_of_ssa): The only
609 constant phi nodes with one argument are is_gimple_min_invariant
610 and SSA_NAME_IS_DEFAULT_DEF.
612 * gfortran.dg/graphite/id-22.f: New.
614 2010-07-27 Andreas Simbuerger <simbuerg@fim.uni-passau.de>
616 * graphite.c (graphite_initialize): Do not initialize
617 CLooG and initialize the Parma Polyhedra Library
618 manually when using CLOOG_ORG.
619 (graphite_finalize): Do not finalize CLooG and finalize
620 the Parma Polyhedra Library manually when using CLOOG_ORG.
621 * graphite-cloog-compat.h (cloog_initialize): Hide function
622 when using CLOOG_ORG.
623 (cloog_finalize): Same.
625 2010-07-27 Andreas Simbuerger <simbuerg@fim.uni-passau.de>
627 * graphite-clast-to-gimple.c (free_scattering): Change
628 CloogDomainList/CloogDomain to CloogScatteringList/CloogScattering
630 (build_cloog_prog): Same.
631 * graphite-cloog-compat.h (cloog_domain): Removed.
632 (cloog_scattering): New.
633 (cloog_set_domain): Removed.
634 (cloog_set_scattering): New.
635 (cloog_next_domain): Removed.
636 (cloog_next_scattering): New.
637 (cloog_set_next_domain): Removed.
638 (cloog_set_next_scattering): New.
639 (CloogScatteringList): New.
640 (CloogScattering): New.
641 (cloog_scattering_free): New.
642 (new_Cloog_Scattering_from_ppl_Polyhedron): New.
643 * graphite-cloog-util.c (new_Cloog_Scattering_from_ppl_Polyhedron):
646 2010-07-27 Andreas Simbuerger <simbuerg@fim.uni-passau.de>
648 * graphite-clast-to-gimple.c (build_cloog_prog): Extend with
650 (set_cloog_options): Same.
651 (print_clast_stmt): Same.
652 (scop_to_clast): Same.
653 (print_generated_program): Same.
655 * graphite-clast-to-gimple.h: Include graphite-cloog-util.h.
656 (scop_to_clast): Extend with CloogState.
657 * graphite-cloog-util.c: Include graphite-cloog-compat.h
658 (new_Cloog_Domain_from_ppl_Polyhedron):
659 Extend with CloogState. Use cloog_domain_from_cloog_matrix (CLOOG_ORG).
660 (new_Cloog_Domain_from_ppl_Pointset_Powerset): Extend with CloogState.
661 (new_Cloog_Domain_from_ppl_Polyhedron): Same.
662 * graphite-cloog-util.h (build_cloog_prog): Same.
663 * graphite-cloog-copat.h (build_cloog_prog): New.
665 (cloog_state_malloc): New.
666 (cloog_state_free): New.
667 (cloog_loop_malloc): New.
668 (cloog_options_malloc): New.
669 (cloog_statement_alloc): New.
670 (cloog_domain_from_cloog_matrix): New.
671 (new_Cloog_Domain_from_ppl_Pointset_Powerset): New.
672 (new_Cloog_Domain_from_ppl_Polyhedron): New.
674 2010-07-27 Andreas Simbuerger <simbuerg@fim.uni-passau.de>
676 * graphite-clast-to-gimple.c (clast_name_to_gcc): Parameter
677 type of NAME now depends on used CLooG version.
678 (clast_to_gcc_expression): Replace expr_* with clast_expr_*.
679 (gcc_type_for_clast_expr): Same.
680 (print_clast_stmt): Replace pprint with clast_pprint.
681 * graphite-cloog-compat.h: Provide compatibility macros for
684 (clast_expr_term): New.
685 (clast_expr_red): New.
686 (clast_expr_bin): New.
689 2010-07-27 Andreas Simbuerger <simbuerg@fim.uni-passau.de>
691 * graphite-clast-to-gimple.c (set_cloog_options): Make CLooG options
692 compatible to newer CLooG releases (CLOOG_ORG).
693 (build_cloog_prog): Pass CloogOptions to more functions (CLOOG_ORG).
694 (scop_to_clast): Pass CloogOptions to build_cloog_prog (CLOOG_ORG).
695 * graphite-cloog-compat.h: Add compatibility macros for CLooG Legacy.
696 (build_cloog_prog) : New.
697 (cloog_program_extract_scalars): New.
698 (cloog_program_scatter): New.
700 2010-07-27 Andreas Simbuerger <simbuerg@fim.uni-passau.de>
702 * graphite-clast-to-gimple.c: Include graphite-cloog-compat.h
703 conditionally (CLOOG_ORG).
704 * graphite-cloog-compat.h: New. Include graphite-cloog-compat.h.
705 (cloog_statement_usr): New.
706 (cloog_domain): Same.
707 (cloog_set_domain): Same.
708 (cloog_next_domain): Same.
709 (cloog_set_next_domain): Same.
710 (cloog_program_nb_scattdims): Same.
711 (cloog_program_set_nb_scattdims): Same.
712 (cloog_program_names): Same.
713 (cloog_program_set_names): Same.
714 (cloog_program_set_context): Same.
715 (cloog_program_set_loop): Same.
716 (cloog_program_blocklist): Same.
717 (cloog_program_set_blocklist): Same.
718 (cloog_program_scaldims): Same.
719 (cloog_program_set_scaldims): Same.
720 (cloog_names_nb_parameters): Same.
721 (cloog_names_set_nb_parameters): Same.
722 (cloog_names_parameters): Same.
723 (cloog_names_set_parameters): Same.
724 (cloog_names_set_nb_iterators): Same.
725 (cloog_names_set_iterators): Same.
726 (cloog_names_set_nb_scattering): Same.
727 (cloog_names_set_scattering): Same.
728 (cloog_statement_set_usr): Same.
729 (cloog_loop_set_next): Same.
730 (cloog_loop_set_domain): Same.
731 (cloog_loop_set_block): Same.
732 (cloog_block_list_next): Same.
733 (cloog_block_list_set_next):
734 (cloog_block_list_set_block): Same.
736 2010-07-27 Sebastian Pop <sebastian.pop@amd.com>
738 * graphite-sese-to-poly.c (rewrite_cross_bb_scalar_deps): Returns
740 (rewrite_commutative_reductions_out_of_ssa_close_phi): Same.
741 (rewrite_commutative_reductions_out_of_ssa_loop): Same.
742 (rewrite_cross_bb_scalar_deps_out_of_ssa): Call scev_reset_htab
743 when something has been changed.
744 (rewrite_commutative_reductions_out_of_ssa): Same.
746 * gcc.dg/graphite/id-26.c: New.
748 2010-07-26 Sebastian Pop <sebastian.pop@amd.com>
750 * graphite-sese-to-poly.c (propagate_expr_outside_region): Also
751 handle the case when def is in the sese region.
752 (rewrite_close_phi_out_of_ssa): Call propagate_expr_outside_region
753 for invariant expressions.
754 (rewrite_cross_bb_phi_deps): Removed.
755 (rewrite_cross_bb_scalar_deps): Also handle GIMPLE_PHI nodes.
756 (rewrite_cross_bb_scalar_deps_out_of_ssa): Do not call
757 rewrite_cross_bb_phi_deps.
759 2010-07-26 Sebastian Pop <sebastian.pop@amd.com>
761 * graphite-sese-to-poly.c
762 (rewrite_commutative_reductions_out_of_ssa_loop): Call
763 scev_analyzable_p only on is_gimple_reg
765 * gcc.dg/graphite/id-25.c: New.
767 2010-07-22 Sebastian Pop <sebastian.pop@amd.com>
769 * graphite-sese-to-poly.c (propagate_expr_outside_region): New.
770 (rewrite_close_phi_out_of_ssa): Propagate constant values or
771 parametric expressions outside the scop region.
772 (rewrite_cross_bb_scalar_deps): Same.
773 * sese.c (rename_uses): Use NULL_TREE instead of NULL for trees.
775 * gcc.dg/graphite/run-id-5.c: New.
776 * gcc.dg/graphite/run-id-6.c: New.
777 * gfortran.dg/graphite/id-21.f: New.
779 2010-07-22 Sebastian Pop <sebastian.pop@amd.com>
781 * graphite-sese-to-poly.c (rewrite_phi_out_of_ssa): Use
782 SSA_NAME_DEF_STMT only on SSA_NAMEs.
784 * gcc.dg/graphite/id-24.c: New.
786 2010-07-22 Sebastian Pop <sebastian.pop@amd.com>
788 * tree-scalar-evolution.c (instantiate_scev_name): Do not
789 instantiate default definitions.
791 2010-07-20 Vladimir Kargov <kargov@gmail.com>
793 * graphite-scop-detection.c (is_valid_stmt_p): New.
794 (is_valid_bb_p): New.
796 2010-07-20 Vladimir Kargov <kargov@gmail.com>
797 Sebastian Pop <sebastian.pop@amd.com>
799 * cfgloop.c (is_loop_exit): Renamed loop_exits_to_bb_p.
800 (loop_exits_from_bb_p): New.
801 * cfgloop.h (is_loop_exit): Renamed loop_exits_to_bb_p.
802 (loop_exits_from_bb_p): Declared.
803 * graphite-scop-detection.c (scopdet_basic_block_info): Call
806 2010-07-20 Vladimir Kargov <kargov@gmail.com>
808 * refined-regions.c: Include tree-pass.h, cfgloop.h, gimple.h, and
810 (dot_regions_1): New.
812 * refined-regions.h (dot_regions): Declared.
813 * Makefile.in (refined-regions.o): Update dependences.
815 2010-07-20 Sebastian Pop <sebastian.pop@amd.com>
817 * graphite-sese-to-poly.c (rewrite_close_phi_out_of_ssa): Add an
818 extra parameter for the region. Call scev_analyzable_p.
819 (rewrite_reductions_out_of_ssa): Update call to
820 rewrite_close_phi_out_of_ssa.
821 (rewrite_cross_bb_phi_deps): Same.
822 (rewrite_commutative_reductions_out_of_ssa_loop): Add an extra
823 parameter for the region. Call scev_analyzable_p.
824 (rewrite_commutative_reductions_out_of_ssa): Update call to
825 rewrite_commutative_reductions_out_of_ssa_loop.
827 2010-07-20 Sebastian Pop <sebastian.pop@amd.com>
829 * gcc.dg/tree-ssa/pr20742.c: New.
831 2010-07-15 Sebastian Pop <sebastian.pop@amd.com>
833 * sese.c (rename_uses): Call unshare_expr before force_gimple_operand.
835 * gcc.dg/graphite/id-23.c: New.
837 2010-07-15 Sebastian Pop <sebastian.pop@amd.com>
839 * graphite-sese-to-poly.c (reduction_phi_p): Do not rewrite out of
840 SSA scalar phi nodes that can be scev_analyzable_p.
842 * gfortran.dg/graphite/id-20.f: Adjust testcase.
844 2010-07-15 Sebastian Pop <sebastian.pop@amd.com>
846 * graphite-sese-to-poly.c (rewrite_close_phi_out_of_ssa): Correctly
847 handle SSA_NAME_IS_DEFAULT_DEF.
849 2010-07-15 Sebastian Pop <sebastian.pop@amd.com>
851 * sese.c (rename_uses): Handl unconditionally gimple_debug statements.
853 * gcc.dg/graphite/pr42729.c: New.
855 2010-07-15 Sebastian Pop <sebastian.pop@amd.com>
857 * graphite-sese-to-poly.c (rewrite_close_phi_out_of_ssa): Special
858 case non close-phi nodes with one argument.
860 2010-07-15 Sebastian Pop <sebastian.pop@amd.com>
862 * sese.h (scev_analyzable_p): Scevs could be expressions without
863 chrecs and still be scev_analyzable_p.
865 2010-07-15 Sebastian Pop <sebastian.pop@amd.com>
867 * params.def (PARAM_SCEV_MAX_EXPR_SIZE): Bump the value to 100.
869 2010-07-15 Sebastian Pop <sebastian.pop@amd.com>
871 * cfgloop.c (alloc_loop): Remove initialization of loop->single_iv.
872 * cfgloop.h (struct loop): Remove single_iv field.
873 * graphite-sese-to-poly.c (graphite_loop_normal_form): Removed.
874 (scop_canonicalize_loops): Removed.
875 (scop_ivs_can_be_represented): Do not use loop->single_iv. Iterate
876 over all the loop phi nodes in loop->header.
877 (build_poly_scop): Remove use of scop_canonicalize_loops.
879 2010-07-15 Sebastian Pop <sebastian.pop@amd.com>
881 * graphite-sese-to-poly.c (rewrite_cross_bb_scalar_deps): Also
884 2010-07-15 Sebastian Pop <sebastian.pop@amd.com>
886 * tree-chrec.c (chrec_apply): Should only apply to the specified
887 variable. Also handle multivariate chains of recurrences that
888 satisfy evolution_function_is_affine_p. Also handle CASE_CONVERT.
890 2010-07-15 Sebastian Pop <sebastian.pop@amd.com>
892 * graphite-clast-to-gimple.c (debug_clast_name_index): Removed.
893 (debug_clast_name_indexes_1): Removed.
894 (debug_clast_name_indexes): Removed.
895 (pbb_to_depth_to_oldiv): Removed.
896 (build_iv_mapping): Replace the use of rename_map with iv_map.
897 (translate_clast_user): Remove uses of rename_map. Allocate and
899 (translate_clast_for_loop): Remove uses of rename_map.
900 (translate_clast_for): Same.
901 (translate_clast_guard): Same.
902 (translate_clast): Same.
904 * graphite-clast-to-gimple.h (debug_clast_name_indexes): Removed.
905 * graphite-sese-to-poly.c (scev_analyzable_p): Moved...
906 * sese.c (set_rename): Now static.
907 (rename_variables_in_stmt): Removed.
909 (is_parameter): Removed.
911 (expand_scalar_variables_call): Removed.
912 (expand_scalar_variables_ssa_name): Removed.
913 (expand_scalar_variables_expr): Removed.
914 (expand_scalar_variables_stmt): Removed.
915 (expand_scalar_variables): Removed.
916 (rename_variables): Removed.
917 (remove_condition): Removed.
918 (get_true_edge_from_guard_bb): Removed.
919 (get_false_edge_from_guard_bb): Removed.
920 (struct igp): Removed.
921 (default_before_guard): Removed.
922 (convert_for_phi_arg): Removed.
923 (add_guard_exit_phis): Removed.
924 (insert_guard_phis): Removed.
925 (graphite_copy_stmts_from_block): Now also uses iv_map and a
926 region. Do not copy conditions. Do not copy induction variables.
928 (copy_bb_and_scalar_dependences): Allocate a local rename_map for
929 the translated statement. Use the iv_map for the induction
931 * sese.h (copy_bb_and_scalar_dependences): Update declaration.
932 (set_rename): Removed declaration.
933 (scev_analyzable_p): ...here.
934 * tree-chrec.c (chrec_apply_map): New.
935 * tree-chrec.h (chrec_apply_map): Declared.
937 2010-07-15 Sebastian Pop <sebastian.pop@amd.com>
939 * graphite-clast-to-gimple.c (translate_clast_for_loop): Do not call
940 insert_loop_close_phis.
941 * sese.c (name_defined_in_loop_p): Removed.
942 (expr_defined_in_loop_p): Removed.
943 (alive_after_loop): Removed.
944 (close_phi_not_yet_inserted_p): Removed.
945 (struct alep): Removed.
946 (add_loop_exit_phis): Removed.
947 (insert_loop_close_phis): Removed.
949 2010-07-15 Andreas Simbuerger <simbuerg@fim.uni-passau.de>
951 * graphite-cloog-util.c (cloog_matrix_to_ppl_constraint): Fix flipped
953 * graphite-poly.c (psct_scattering_dim_for_loop_depth): Same.
955 2010-07-07 Sebastian Pop <sebastian.pop@amd.com>
957 * gfortran.dg/graphite/id-20.f: New.
959 2010-07-05 Andreas Simbuerger <simbuerg@fim.uni-passau.de>
961 * graphite-cloog-util.h: Added cloog.h.
962 * graphite-blocking.c: Removed cloog.h.
963 * graphite-dependences.c: Same.
964 * graphite-interchange.c: Same.
965 * graphite-poly.c: Same.
966 * graphite-ppl.c: Same.
967 * graphite-scop-detection.c: Same.
968 * graphite-sese-to-poly.c:
970 Removed graphite-clast-to-gimple.h.
971 (check_poly_representation): Removed (unused).
972 * graphite-sese-to-poly.h
973 (check_poly_representation): Removed (unused).
975 2010-07-05 Andreas Simbuerger <simbuerg@fim.uni-passau.de>
978 (OBJS-common): Added graphite-cloog-util.o.
979 (graphite-clast-to-gimple.o): Added graphite-cloog-util.h.
980 (graphite-cloog-util.o): New.
981 (graphite-ppl.o): Added graphite-cloog-util.h.
982 * graphite-clast-to-gimple.c:
983 Added graphite-cloog-util.h to include statements.
984 * graphite-cloog-util.c: New.
985 (new_Cloog_Matrix_from_ppl_Polyhedron): Moved from graphite-ppl.c.
986 (new_Cloog_Domain_from_ppl_Polyhedron): Same.
987 (new_Cloog_Domain_from_ppl_Pointset_Powerset): Same.
988 (new_C_Polyhedron_from_Cloog_Matrix): Same.
989 (ppl_Constrain_System_number_of_constraints): Same.
990 (new_Cloog_Matrix_from_ppl_Constraint_System): Same.
991 (oppose_constraint): Same.
992 (cloog_matrix_to_ppl_constraint): Same.
993 (new_Constraint_System_from_Cloog_Matrix): Same.
994 (insert_constraint_into_matrix): Same. Declared static.
995 * graphite-cloog-util.h: New.
996 (new_Cloog_Matrix_from_ppl_Polyhedron): Moved from graphite-ppl.h.
997 (new_Cloog_Domain_from_ppl_Polyhedron): Same.
998 (new_Cloog_Domain_from_ppl_Pointset_Powerset): Same.
999 (new_C_Polyhedron_from_Cloog_Matrix): Same.
1000 (insert_constraint_into_matrix): Same.
1002 Added graphite-cloog-util.h to include statements.
1003 (new_Cloog_Matrix_from_ppl_Polyhedron): Moved to graphite-cloog-util.c.
1004 (new_Cloog_Domain_from_ppl_Polyhedron): Same.
1005 (new_Cloog_Domain_from_ppl_Pointset_Powerset): Same.
1006 (new_C_Polyhedron_from_Cloog_Matrix): Same.
1007 (insert_constraint_into_matrix): Same.
1008 (ppl_Constrain_System_number_of_constraints): Same.
1009 (new_Cloog_Matrix_from_ppl_Constraint_System): Same.
1010 (oppose_constraint): Same.
1011 (cloog_matrix_to_ppl_constraint): Same.
1012 (new_Constraint_System_from_Cloog_Matrix): Same.
1014 (new_Cloog_Matrix_from_ppl_Polyhedron): Moved to
1015 graphite-cloog-util.h.
1016 (new_Cloog_Domain_from_ppl_Polyhedron): Same.
1017 (new_Cloog_Domain_from_ppl_Pointset_Powerset): Same.
1018 (new_C_Polyhedron_from_Cloog_Matrix): Same.
1019 (insert_constraint_into_matrix): Removed.
1021 2010-07-04 Andreas Simbuerger <simbuerg@fim.uni-passau.de>
1023 * graphite-clast-to-gimple.c
1024 (precision_for_value): Resolve value_* calls to matching mpz_* calls.
1025 (precision_for_interval): Same.
1026 (gcc_type_for_interval): Same.
1027 (compute_type_for_level): Same.
1028 * graphite-interchange.c
1029 (lst_interchange_profitable_p): Same.
1031 (psct_scattering_dim_for_loop_depth): Same.
1033 (ppl_max_for_le_pointset): Same.
1034 (ppl_min_for_le_pointset): Same.
1036 2010-06-25 Vladimir Kargov <kargov@gmail.com>
1038 * refined-regions.c (bb_index_compare): New.
1039 (get_bbs_in_region): New.
1040 (print_bbs_in_region): New.
1041 (print_refined_region): Add an argument that allows to print
1042 all basic blocks contained in regions.
1043 (debug_refined_region): Update call to print_refined_region.
1044 * refined-regions.h (print_refined_region): Update declaration.
1045 (get_bbs_in_region): Declared.
1046 * graphite-scop-detection.c (build_scops_new): Print the refined
1047 region tree into the Grahite dump file.
1049 2010-06-24 Sebastian Pop <sebastian.pop@amd.com>
1051 * graphite-sese-to-poly.c (rewrite_degenerate_phi): New.
1052 (rewrite_reductions_out_of_ssa): Call it for degenerate_phi_result.
1054 2010-06-24 Sebastian Pop <sebastian.pop@amd.com>
1056 * graphite-sese-to-poly.c (rewrite_cross_bb_phi_deps): Call
1057 rewrite_close_phi_out_of_ssa.
1059 * gcc.dg/graphite/id-22.c: New.
1061 2010-06-24 Sebastian Pop <sebastian.pop@amd.com>
1063 * graphite-sese-to-poly.c (rewrite_cross_bb_phi_deps): Remove dead code.
1065 2010-06-24 Sebastian Pop <sebastian.pop@amd.com>
1067 * graphite-clast-to-gimple.c (build_iv_mapping): Rename map with
1069 * sese.c (debug_rename_map): Same.
1072 (rename_variables_in_stmt): Same.
1073 (expand_scalar_variables_call): Same.
1074 (expand_scalar_variables_ssa_name): Same.
1075 (expand_scalar_variables_expr): Same.
1076 (expand_scalar_variables_stmt): Same.
1077 (expand_scalar_variables): Same.
1078 (rename_variables): Same.
1079 (graphite_copy_stmts_from_block): Same.
1080 (copy_bb_and_scalar_dependences): Same.
1082 2010-06-24 Sebastian Pop <sebastian.pop@amd.com>
1084 * graphite-clast-to-gimple.c (copy_renames): Removed.
1085 (translate_clast_for): Do not call copy_renames.
1086 (translate_clast_guard): Same.
1088 2010-06-23 Sebastian Pop <sebastian.pop@amd.com>
1090 * graphite-sese-to-poly.c (rewrite_reductions_out_of_ssa): Moved up.
1091 (rewrite_cross_bb_phi_deps): Split out of rewrite_cross_bb_scalar_deps.
1092 (rewrite_cross_bb_scalar_deps_out_of_ssa): Run rewrite_cross_bb_phi_deps
1093 before rewrite_cross_bb_scalar_deps.
1095 2010-06-23 Sebastian Pop <sebastian.pop@amd.com>
1097 * graphite-sese-to-poly.c (rewrite_commutative_reductions_out_of_ssa):
1098 Early return in when flag_associative_math is not set.
1100 2010-06-23 Sebastian Pop <sebastian.pop@amd.com>
1102 * gcc.dg/graphite/run-id-2.c: Call abort.
1104 2010-06-23 Sebastian Pop <sebastian.pop@amd.com>
1106 * graphite-sese-to-poly.c (rewrite_phi_out_of_ssa): Always insert out
1107 of SSA copies on edges except for loop->latch.
1109 2010-06-23 Sebastian Pop <sebastian.pop@amd.com>
1111 * graphite-sese-to-poly.c (rewrite_cross_bb_scalar_deps_out_of_ssa):
1112 Split out of rewrite_reductions_out_of_ssa.
1113 * graphite-sese-to-poly.h (rewrite_cross_bb_scalar_deps_out_of_ssa):
1115 * graphite.c (graphite_transform_loops): Call it.
1117 2010-06-23 Sebastian Pop <sebastian.pop@amd.com>
1119 * graphite.c (graphite_transform_loops): Add two more dbg_cnt calls.
1121 2010-06-15 Sebastian Pop <sebastian.pop@amd.com>
1123 * passes.c (init_optimization_passes): Add pass_graphite.
1124 Schedule a pass_copy_prop before pass_graphite_transforms.
1125 * timevar.def (TV_GRAPHITE): Declared.
1126 * tree-pass.h (pass_graphite): Declared.
1127 * tree-ssa-loop.c (pass_graphite): New.
1129 * gcc.dg/graphite/id-20.c: New.
1131 2010-06-12 Sebastian Pop <sebastian.pop@amd.com>
1133 * graphite-clast-to-gimple.c (gloog): Do not pass scops in parameter.
1134 Remove calls to rename_nb_iterations and rename_sese_parameters.
1135 * graphite-clast-to-gimple.h (gloog): Update declaration.
1136 * graphite.c (graphite_transform_loops): Update call to gloog.
1137 * sese.c (rename_variables_in_expr): Removed.
1138 (rename_nb_iterations): Removed.
1139 (rename_sese_parameters): Removed.
1140 * sese.h (rename_nb_iterations): Removed.
1141 (rename_sese_parameters): Removed.
1143 2010-06-12 Sebastian Pop <sebastian.pop@amd.com>
1145 * graphite-clast-to-gimple.c (gloog): Remove call to
1146 sese_adjust_liveout_phis.
1147 * graphite-sese-to-poly.c (scev_analyzable_p): When scev returns an
1148 SSA_NAME, allow it to be handled by rewrite_cross_bb_scalar_deps.
1149 (rewrite_cross_bb_scalar_deps): Handle GIMPLE_PHI nodes: call
1150 rewrite_phi_out_of_ssa.
1151 * sese.c (get_vdef_before_sese): Removed.
1152 (sese_adjust_vphi): Removed.
1153 (sese_adjust_liveout_phis): Removed.
1154 * sese.h (sese_adjust_liveout_phis): Removed.
1156 2010-06-12 Sebastian Pop <sebastian.pop@amd.com>
1158 * graphite-sese-to-poly.c (insert_out_of_ssa_copy): Pass an extra
1159 argument for the place after which to insert the out of SSA copy.
1160 (rewrite_close_phi_out_of_ssa): Update calls to insert_out_of_ssa_copy.
1161 (rewrite_phi_out_of_ssa): Same.
1162 (rewrite_cross_bb_scalar_deps): Same.
1163 (insert_copyout): Removed.
1164 (insert_copyin): Removed.
1165 (translate_scalar_reduction_to_array): Call insert_out_of_ssa_copy and
1166 insert_out_of_ssa_copy_on_edge instead of insert_copyout and
1169 2010-06-12 Sebastian Pop <sebastian.pop@amd.com>
1171 * graphite-sese-to-poly.c (build_scop_bbs): Not static anymore.
1172 (rewrite_reductions_out_of_ssa): Same.
1173 (rewrite_commutative_reductions_out_of_ssa): Same.
1174 (build_poly_scop): Do not call these functions.
1175 * graphite-sese-to-poly.h (build_poly_scop): Declared.
1176 (rewrite_reductions_out_of_ssa): Declared.
1177 (rewrite_commutative_reductions_out_of_ssa): Declared.
1178 * graphite.c (graphite_transform_loops): Call on every scop
1179 rewrite_commutative_reductions_out_of_ssa before calling
1180 rewrite_reductions_out_of_ssa and build_scop_bbs.
1182 2010-06-12 Sebastian Pop <sebastian.pop@amd.com>
1184 * graphite-dependences.c (dot_deps): Make system call to dotty run
1186 (dot_deps_stmt): Same.
1187 * graphite-poly.c (dot_lst): Same.
1189 2010-06-11 Sebastian Pop <sebastian.pop@amd.com>
1191 * graphite-clast-to-gimple.c (gcc_type_for_interval): Do not pass
1192 old_type in parameter.
1193 (gcc_type_for_value): Update call to gcc_type_for_interval.
1194 (compute_type_for_level_1): Renamed compute_type_for_level.
1195 Update call to gcc_type_for_interval.
1197 2010-06-09 Sebastian Pop <sebastian.pop@amd.com>
1199 * tree-scalar-evolution.c (instantiate_scev_name): Do not fail
1200 the scev analysis when the variable is not used outside the loop
1201 in a close phi node: call compute_overall_effect_of_inner_loop.
1203 2010-06-09 Sebastian Pop <sebastian.pop@amd.com>
1205 * graphite-sese-to-poly.c (single_pred_cond): Renamed
1206 single_pred_cond_non_loop_exit. Return NULL for loop exit edges.
1207 (build_sese_conditions_before): Renamed call to single_pred_cond.
1208 (build_sese_conditions_after): Same.
1210 2010-06-09 Sebastian Pop <sebastian.pop@amd.com>
1212 * graphite-poly.h: Fix comments and indentation.
1213 * graphite-sese-to-poly.c: Same.
1214 (build_sese_conditions_before): Compute stmt and gbb only when needed.
1215 * tree-chrec.c: Fix comments and indentation.
1216 (tree-ssa-loop-niter.c): Same.
1218 2010-06-08 Tobias Grosser <grosser@fim.uni-passau.de>
1220 * refined-regions.c (create_region): Only initialize the region.
1221 (find_regions_with_entry): Initialize parent relation and bbmap
1223 (build_regions_tree): Set outermost_region to region instead of
1225 (calculate_region_tree): Remove unneeded parameters.
1227 2010-06-02 Tobias Grosser <grosser@fim.uni-passau.de>
1229 * graphite-scop-detection.c (is_scop_p): New.
1230 (build_scops_new): New. A skeleton for the new scop detection.
1231 (build_scops_old): Renamed from build_scops.
1232 (build_scops): New version. Call the new and the old scop
1235 2010-05-27 Tobias Grosser <grosser@fim.uni-passau.de>
1236 Antoniu Pop <antoniu.pop@gmail.com>
1238 * Makefile.in (OBJS-common): Add refined-regions.o.
1239 (refined-regions.o): New.
1240 (graphite-scop-detection.o): Use refined-regions.h.
1241 * graphite-scop-detection.c: Include refined-regions.h
1242 (build_scops): Also build the refined region tree.
1243 * refined-regions.c: New. Adds an algorithm to detect refined
1245 (print_refined_region): New.
1246 (debug_refined_region): New.
1247 (refined_region_contains_bb_p): New.
1248 (refined_region_contains_region_p): New.
1249 (is_common_df): New.
1250 (struct find_regions_global_data): New.
1252 (typedef struct bb_bb_def): New.
1253 (new_bb_bb_def): New.
1254 (bb_bb_map_hash): New.
1255 (eq_bb_bb_map): New.
1258 (new_bb_reg_def): New.
1259 (bb_reg_map_hash): New.
1260 (eq_bb_reg_map): New.
1261 (find_new_region): New.
1262 (insert_new_reg): New.
1263 (insert_new_bb): New.
1264 (insert_shortcut): New.
1265 (get_next_postdom): New.
1266 (create_region): New.
1267 (find_regions_with_entry): New.
1268 (find_regions_adc): New.
1269 (find_regions): New.
1270 (get_topmost_parent): New.
1271 (build_regions_tree): New.
1272 (calculate_region_tree): New.
1273 (free_region_tree): New.
1274 * refined-regions.h: New.
1275 (struct refined_region): New.
1276 (calculate_region_tree): New.
1277 (free_region_tree): New.
1278 (refined_region_contains_bb_p): New.
1279 (refined_region_contains_region_p): New.
1280 (print_refined_region): New.
1281 (debug_refined_region): New.
1283 2010-05-26 Sebastian Pop <sebastian.pop@amd.com>
1285 * graphite-clast-to-gimple.c (graphite_create_new_loop_guard): Use
1288 2010-05-07 Sebastian Pop <sebastian.pop@amd.com>
1290 * graphite-clast-to-gimple.c (graphite_create_new_loop_guard): Fix
1291 type of integer_one_node for fold_build of POINTER_PLUS_EXPR.
1293 2010-05-07 Sebastian Pop <sebastian.pop@amd.com>
1295 * graphite-sese-to-poly.c (loop_entry_phi_arg): Renamed
1296 phi_arg_in_outermost_loop.
1297 (remove_simple_copy_phi): Call phi_arg_in_outermost_loop.
1298 (remove_invariant_phi): Same.
1300 2010-04-12 Andreas Simbuerger <simbuerg@fim.uni-passau.de>
1302 * graphite-blocking.c
1303 (pbb_strip_mine_profitable_p): Replace Value with mpz_t.
1304 * graphite-clast-to-gimple.c
1305 (clast_to_gcc_expression): Same.
1306 (precision_for_value): Same.
1307 (precision_for_interval): Same.
1308 (gcc_type_for_interval): Same.
1309 (graphite_create_new_guard): Same.
1310 (compute_bounds_for_level): Same.
1311 (graphite_create_new_loop_guard): Same.
1312 * graphite-interchange.c
1313 (build_linearized_memory_access): Same.
1314 (pdr_stride_in_loop): Same.
1315 (memory_strides_in_loop_1): Same.
1316 (memory_strides_in_loop): Same.
1317 (extend_scattering): Same.
1318 (psct_scattering_dim_for_loop_depth): Same.
1319 (pbb_number_of_iterations): Same.
1321 (debug_iteration_domains): Same.
1323 (new_Cloog_Domain_from_ppl_Pointset_Powerset): Same.
1324 (ppl_set_inhomogeneous_gmp): Same.
1325 (ppl_strip_loop): Same.
1326 (ppl_lexico_compare_linear_expressions): Same.
1327 (ppl_read_polyhedron_matrix): Same.
1328 (ppl_max_for_le_pointset): Same.
1330 (ppl_read_polyhedron_matrix): Same.
1331 (tree_int_to_gmp): Same.
1332 (gmp_cst_to_tree): Same.
1333 (ppl_set_inhomogeneous): Same.
1334 (ppl_set_inhomogeneous_tree): Same.
1335 (ppl_set_coef): Same.
1336 (ppl_set_coef_tree): Same.
1337 * graphite-sese-to-poly.c
1338 (build_pbb_scattering_polyhedrons): Same.
1339 (build_scop_scattering): Same.
1340 (scan_tree_for_params_right_scev): Same.
1341 (scan_tree_for_params): Same.
1342 (find_params_in_bb): Same.
1343 (find_scop_parameters): Same.
1344 (add_upper_bounds_from_estimated_nit): Same.
1345 (build_loop_iteration_domains): Same.
1346 (add_condition_to_domain): Same.
1347 (pdr_add_memory_accesses): Same.
1349 2010-04-11 Andreas Simbuerger <simbuerg@fim.uni-passau.de>
1351 * graphite-blocking.c (pbb_strip_mine_profitable_p): Resolve
1352 CLooG's value_* macros to their respective mpz_* counterparts.
1353 * graphite-clast-to-gimple.c (clast_to_gcc_expression): Same.
1354 (graphite_create_new_loop_guard): Same.
1355 * graphite-interchange.c (build_linearized_memory_access): Same.
1356 (pdr_stride_in_loop): Same.
1357 (memory_strides_in_loop_1): Same.
1358 (1st_interchange_profitable_p): Same.
1359 * graphite-poly.c (extend_scattering): Same.
1360 (psct_scattering_dim_for_loop_depth): Same.
1361 (pbb_number_of_iterations): Same.
1362 (pbb_number_of_iterations_at_time): Same.
1363 * graphite-poly.h (new_1st_loop): Same.
1364 * graphite-ppl.c (cloog_matrix_to_ppl_constraint): Same.
1365 (oppose_constraint): Same.
1366 (insert_constraint_into_matrix): Same.
1367 (ppl_set_inhomogeneous_gmp): Same.
1368 (ppl_set_coef_gmp): Same.
1369 (ppl_strip_loop): Same.
1370 (ppl_lexico_compare_linear_expressions): Same.
1371 (ppl_max_for_le_pointset): Same.
1372 (ppl_min_for_le_pointset): Same.
1373 (ppl_build_realtion): Same.
1374 * graphite-ppl.h (gmp_cst_to_tree): Same.
1375 (ppl_set_inhomogeneous): Same.
1376 (ppl_set_inhomogeneous_tree): Same.
1377 (ppl_set_coef): Same.
1378 (ppl_set_coef_tree): Same.
1379 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons): Same.
1380 (build_scop_scattering): Same.
1381 (add_value_to_dim): Same.
1382 (scan_tree_for_params_right_scev): Same.
1383 (scan_tree_for_params_int): Same.
1384 (scan_tree_for_params): Same.
1385 (find_params_in_bb): Same.
1386 (find_scop_parameters): Same.
1387 (add_upper_bounds_from_estimated_nit): Same.
1388 (build_loop_iteration_domains): Same.
1389 (create_linear_expr_from_tree): Same.
1390 (add_condition_to_domain): Same.
1391 (pdr_add_memory_accesses): Same.
1393 2010-04-05 Sebastian Pop <sebastian.pop@amd.com>
1396 * graphite-clast-to-gimple.c (max_signed_precision_type): Use
1397 lang_hooks.types.type_for_size instead of build_nonstandard_integer_type.
1398 When converting an unsigned type to signed, double its precision.
1399 (gcc_type_for_interval): Use lang_hooks.types.type_for_size.
1400 (gcc_type_for_iv_of_clast_loop): Call max_signed_precision_type.
1401 (graphite_create_new_loop_guard): When ub + 1 wraps around, use lb <= ub.
1403 2010-04-05 Sebastian Pop <sebastian.pop@amd.com>
1406 * graphite-clast-to-gimple.c (max_signed_precision_type): Use
1407 build_nonstandard_integer_type.
1408 (gcc_type_for_interval): Same.
1410 2010-04-05 Sebastian Pop <sebastian.pop@amd.com>
1413 * graphite-clast-to-gimple.c (graphite_create_new_loop_guard): Use
1414 POINTER_PLUS_EXPR for pointer types.
1416 * gcc.dg/graphite/id-19.c: New.
1418 2010-04-04 Sebastian Pop <sebastian.pop@amd.com>
1421 * Makefile.in (graphite-clast-to-gimple.o): Depends on langhooks.h.
1422 * graphite-clast-to-gimple.c: Include langhooks.h.
1423 (max_signed_precision_type): New.
1424 (max_precision_type): Takes two types as arguments.
1425 (precision_for_value): New.
1426 (precision_for_interval): New.
1427 (gcc_type_for_interval): New.
1428 (gcc_type_for_value): New.
1429 (gcc_type_for_clast_term): New.
1430 (gcc_type_for_clast_red): New.
1431 (gcc_type_for_clast_bin): New.
1432 (gcc_type_for_clast_expr): Split up into several functions.
1433 (gcc_type_for_clast_eq): Rewritten.
1434 (compute_bounds_for_level): New.
1435 (compute_type_for_level_1): New.
1436 (compute_type_for_level): New.
1437 (gcc_type_for_cloog_iv): Removed.
1438 (gcc_type_for_iv_of_clast_loop): Rewritten.
1439 (graphite_create_new_loop): Compute the lower and upper bound types
1440 with gcc_type_for_clast_expr.
1441 (graphite_create_new_loop_guard): Same.
1442 (find_cloog_iv_in_expr): Removed.
1443 (compute_cloog_iv_types_1): Removed.
1444 (compute_cloog_iv_types): Removed.
1445 (gloog): Do not call compute_cloog_iv_types.
1446 * graphite-sese-to-poly.c (new_gimple_bb): Do not initialize
1448 (free_data_refs_aux): Do not free GBB_CLOOG_IV_TYPES.
1449 * sese.h (struct gimple_bb): Removed field cloog_iv_types.
1450 (GBB_CLOOG_IV_TYPES): Removed.
1452 * gcc.dg/graphite/run-id-pr42644.c: Call abort.
1454 2010-04-02 Sebastian Pop <sebastian.pop@amd.com>
1456 Reverted this commit: as at this point the loop closed SSA form
1457 is under a canonical form respecting the single argument condition.
1458 * graphite-sese-to-poly.c (scalar_close_phi_node_p): Loop
1459 close phi nodes may have more than one argument.
1461 2010-04-01 Sebastian Pop <sebastian.pop@amd.com>
1463 * graphite-sese-to-poly.c (rewrite_close_phi_out_of_ssa): Assert that
1464 gimple_phi_num_args of the loop close SSA phi node is equal to 1.
1465 (detect_commutative_reduction): Same.
1467 2010-03-31 Sebastian Pop <sebastian.pop@amd.com>
1469 * graphite-sese-to-poly.c (scalar_close_phi_node_p): Loop
1470 close phi nodes may have more than one argument.
1472 2010-03-30 Richard Guenther <rguenther@suse.de>
1473 Zdenek Dvorak <ook@ucw.cz>
1474 Sebastian Pop <sebastian.pop@amd.com>
1477 * tree-ssa-copy.c (init_copy_prop): Handle loop close phi nodes
1478 with multiple arguments.
1479 (execute_copy_prop): Remove call to rewrite_into_loop_closed_ssa.
1481 2010-03-23 Sebastian Pop <sebastian.pop@amd.com>
1483 * graphite-dependences.c (print_pddr): Call print_pdr with an
1485 * graphite-poly.c (debug_pdr): Add an extra argument for the
1488 (print_pbb_domain): Same.
1490 (print_scop_context): Same.
1492 (print_cloog): Same.
1493 (debug_pbb_domain): Same.
1497 (debug_scop_context): Same.
1499 (debug_cloog): Same.
1500 (print_scop_params): Same.
1501 (debug_scop_params): Same.
1502 (print_iteration_domain): Same.
1503 (print_iteration_domains): Same.
1504 (debug_iteration_domain): Same.
1505 (debug_iteration_domains): Same.
1506 (print_scattering_function): Same.
1507 (print_scattering_functions): Same.
1508 (debug_scattering_function): Same.
1509 (debug_scattering_functions): Same.
1510 * graphite-poly.h (debug_pdr): Update declaration.
1512 (print_pbb_domain): Same.
1514 (print_scop_context): Same.
1516 (print_cloog): Same.
1517 (debug_pbb_domain): Same.
1521 (debug_scop_context): Same.
1523 (debug_cloog): Same.
1524 (print_scop_params): Same.
1525 (debug_scop_params): Same.
1526 (print_iteration_domain): Same.
1527 (print_iteration_domains): Same.
1528 (debug_iteration_domain): Same.
1529 (debug_iteration_domains): Same.
1530 (print_scattering_function): Same.
1531 (print_scattering_functions): Same.
1532 (debug_scattering_function): Same.
1533 (debug_scattering_functions): Same.
1535 2010-03-23 Sebastian Pop <sebastian.pop@amd.com>
1537 * graphite-poly.c (print_scattering_function_1): New.
1538 (print_scattering_function): Call it.
1539 (print_scop_params): Remove spaces at the end of lines.
1542 * graphite-poly.h (print_cloog): Declared.
1543 (debug_cloog): Declared.
1545 2010-03-23 Sebastian Pop <sebastian.pop@amd.com>
1547 * tree-ssa-copy.c: Revert this previous change:
1548 (init_copy_prop): Loop closed phi nodes cancontain more than one
1550 (execute_copy_prop): Revert the previous change: do not call
1551 rewrite_into_loop_closed_ssa.
1553 2010-03-21 Sebastian Pop <sebastian.pop@amd.com>
1554 Richard Guenther <rguenther@suse.de>
1557 * tree-ssa-copy.c (init_copy_prop): Loop closed phi nodes can
1558 contain more than one argument.
1559 (execute_copy_prop): Revert the previous change: do not call
1560 rewrite_into_loop_closed_ssa.
1562 * gcc.dg/graphite/id-pr43464.c: Remove compile warning.
1563 * gcc.dg/graphite/id-pr43464-1.c: New.
1565 2010-03-21 Sebastian Pop <sebastian.pop@amd.com>
1568 * tree-ssa-copy.c (execute_copy_prop): Call rewrite_into_loop_closed_ssa
1569 and verify_loop_closed_ssa when copy prop is executed in the LNO.
1571 * gcc.dg/graphite/id-pr43464.c: New.
1573 2010-03-16 Sebastian Pop <sebastian.pop@amd.com>
1575 * graphite-sese-to-poly.c (graphite_loop_normal_form): Add the IV bump
1577 * tree-flow.h (canonicalize_loop_ivs): Updated declaration.
1578 * tree-parloops.c (gen_parallel_loop): Add the IV bump in loop->latch.
1579 * tree-ssa-loop-manip.c (canonicalize_loop_ivs): Add a new parameter
1580 to switch between adding the IV bump in loop->latch or in loop->header.
1582 2010-03-16 Sebastian Pop <sebastian.pop@amd.com>
1584 * passes.c (init_optimization_passes): Add pass_copy_prop
1587 2010-03-16 Sebastian Pop <sebastian.pop@amd.com>
1589 * graphite-poly.c (print_scattering_function): Pretty print following
1592 (print_pbb_domain): Same.
1593 (dump_gbb_cases): Same.
1594 (dump_gbb_conditions): Same.
1597 (print_scop_params): Same.
1598 (print_scop_context): Same.
1600 (print_pbb_body): New.
1601 (lst_indent_to): New.
1602 (print_lst): Start new lines with a #.
1603 * graphite-poly.h (pbb_bb): New.
1604 (pbb_index): Use pbb_bb.
1605 * graphite-ppl.c (ppl_print_powerset_matrix): Print the number of
1607 * tree-data-ref.c (dump_data_reference): Start new lines with a #.
1609 2010-03-13 Sebastian Pop <sebastian.pop@amd.com>
1612 * gcc.dg/graphite/id-pr43351.c
1614 2010-03-13 Sebastian Pop <sebastian.pop@amd.com>
1617 * graphite-sese-to-poly.c (rewrite_close_phi_out_of_ssa): Do not
1618 call insert_out_of_ssa_copy for default definitions.
1619 * gfortran.dg/graphite/id-pr43354.f: New.
1621 2010-03-13 Sebastian Pop <sebastian.pop@amd.com>
1624 * gfortran.dg/graphite/pr43349.f: New.
1626 2010-03-11 Sebastian Pop <sebastian.pop@amd.com>
1628 * graphite-clast-to-gimple.c (my_long_long): Defined.
1629 (gcc_type_for_cloog_iv): Use it instead of long_long_integer_type_node.
1630 * graphite-sese-to-poly.c (my_long_long): Defined.
1631 (scop_ivs_can_be_represented): Use it.
1633 2010-03-10 Sebastian Pop <sebastian.pop@amd.com>
1635 * doc/invoke.texi: Fix documentation of graphite-max-nb-scop-params,
1636 graphite-max-bbs-per-function, and loop-block-tile-size.
1637 * params.def (PARAM_GRAPHITE_MAX_NB_SCOP_PARAMS): Replace "maximal"
1639 (PARAM_GRAPHITE_MAX_BBS_PER_FUNCTION): Same.
1641 2010-03-10 Sebastian Pop <sebastian.pop@amd.com>
1643 * graphite-clast-to-gimple.c (gcc_type_for_iv_of_clast_loop): Remove
1644 forward declaration.
1645 * graphite-sese-to-poly.c (reduction_phi_p): Remove FIXME comment.
1646 (add_upper_bounds_from_estimated_nit): New.
1647 (build_loop_iteration_domains): Use it.
1649 2010-03-09 Sebastian Pop <sebastian.pop@amd.com>
1651 * doc/invoke.texi (PARAM_LOOP_BLOCK_TILE_SIZE): Document.
1653 2010-03-09 Sebastian Pop <sebastian.pop@amd.com>
1656 * tree-chrec.c (evolution_function_right_is_integer_cst): CHREC_RIGHT
1657 should be an INTEGER_CST. Also handle CASE_CONVERT.
1658 * gcc.dg/graphite/pr43306.c: New.
1660 2010-03-09 Sebastian Pop <sebastian.pop@amd.com>
1662 * graphite.c (graphite_initialize): To bound the number of bbs per
1663 function, use PARAM_GRAPHITE_MAX_BBS_PER_FUNCTION.
1664 * params.def (PARAM_GRAPHITE_MAX_BBS_PER_FUNCTION): Declared.
1665 * doc/invoke.texi: Document it.
1667 2010-03-09 Sebastian Pop <sebastian.pop@amd.com>
1669 * graphite-sese-to-poly.c (build_poly_scop): Do not return bool.
1670 * graphite-sese-to-poly.h (build_poly_scop): Same.
1672 2010-03-09 Sebastian Pop <sebastian.pop@amd.com>
1674 * graphite-sese-to-poly.c (build_poly_scop): Limit scops following
1675 the number of parameters in the scop. Use as an upper bound
1676 PARAM_GRAPHITE_MAX_NB_SCOP_PARAMS.
1677 * params.def (PARAM_GRAPHITE_MAX_NB_SCOP_PARAMS): Declared.
1678 * doc/invoke.texi: Document it.
1680 2010-03-05 Sebastian Pop <sebastian.pop@amd.com>
1682 * graphite-sese-to-poly.c (add_param_constraints): Use
1683 lower_bound_in_type and upper_bound_in_type.
1685 2010-03-05 Sebastian Pop <sebastian.pop@amd.com>
1687 * graphite-sese-to-poly.c (add_param_constraints): Use sizetype
1688 instead of unsigned_type_node.
1690 2010-03-05 Sebastian Pop <sebastian.pop@amd.com>
1691 Reza Yazdani <reza.yazdani@amd.com>
1694 * graphite-sese-to-poly.c (add_param_constraints): Insert bounds
1695 on pointer type parameters.
1697 * gcc.dg/graphite/run-id-4.c: New.
1699 2010-03-05 Sebastian Pop <sebastian.pop@amd.com>
1702 * gcc.dg/graphite/run-id-3.c: New.
1704 2010-03-05 Tobias Grosser <grosser@fim.uni-passau.de>
1705 Ramakrishna Upadrasta <Ramakrishna.Upadrasta@inria.fr>
1707 * graphite-clast-to-gimple.c (clast_to_gcc_expression): Also
1708 handle conversions from pointer to integers.
1709 (gcc_type_for_cloog_iv): Choose the smalles signed integer as an
1710 induction variable, to be able to work with code generated by CLooG.
1711 * graphite-sese-to-poly.c (scop_ivs_can_be_represented): New.
1712 (build_poly_scop): Bail out if we cannot codegen a loop.
1714 2010-03-04 Tobias Grosser <grosser@fim.uni-passau.de>
1716 * graphite-clast-to-gimple.c (translate_clast): Do not short-cut
1717 code generation with gloog_error.
1719 2010-03-04 Sebastian Pop <sebastian.pop@amd.com>
1721 * sese.c (expand_scalar_variables_ssa_name): Add new argument for type.
1722 Call fold_convert on all the returned values.
1723 (expand_scalar_variables_expr): Pass to expand_scalar_variables_ssa_name
1724 the type of the resulting expression.
1726 2010-03-04 Sebastian Pop <sebastian.pop@amd.com>
1728 * graphite-ppl.c (ppl_min_for_le_polyhedron): Renamed
1729 ppl_min_for_le_pointset. Use ppl_Pointset_Powerset_C_Polyhedron_minimize.
1730 * graphite-ppl.h (ppl_min_for_le_polyhedron): Update declaration.
1732 2010-03-04 Sebastian Pop <sebastian.pop@amd.com>
1734 * graphite-dependences.c (map_into_dep_poly): Removed.
1735 (dependence_polyhedron_1): Use combine_context_id_scat.
1737 2010-03-04 Sebastian Pop <sebastian.pop@amd.com>
1739 * graphite-poly.h (struct poly_scattering): Add layout documentation.
1740 (struct poly_bb): Same.
1741 (combine_context_id_scat): New.
1743 2010-03-02 Sebastian Pop <sebastian.pop@amd.com>
1746 * sese.c (name_defined_in_loop_p): Return false for default
1749 * gcc.dg/graphite/pr42326.c: New.
1751 2010-02-23 Sebastian Pop <sebastian.pop@amd.com>
1753 * graphite-clast-to-gimple.c (find_cloog_iv_in_expr): Simplify
1754 and clean up the logic.
1756 2010-02-23 Sebastian Pop <sebastian.pop@amd.com>
1758 * graphite-sese-to-poly.c (add_param_constraints): Enabled: remove
1761 2010-02-22 Sebastian Pop <sebastian.pop@amd.com>
1764 * graphite-scop-detection.c (create_single_exit_edge): Move
1765 the call to find_single_exit_edge to....
1766 (create_sese_edges): ...here. Don't handle multiple edges
1767 exiting the function.
1768 (build_graphite_scops): Don't handle multiple edges
1769 exiting the function.
1771 * gcc.dg/graphite/pr43083.c: New.
1773 2010-02-22 Sebastian Pop <sebastian.pop@amd.com>
1776 * sese.c (get_rename): Assert that old_name is an SSA_NAME.
1777 (rename_variables_in_stmt): Continue when the use is not an SSA_NAME.
1779 * gfortran.dg/graphite/pr43097.f: New.
1781 2010-02-22 Sebastian Pop <sebastian.pop@amd.com>
1782 Manuel López-Ibáñez <manu@gcc.gnu.org>
1785 * g++.dg/graphite/pr41305.C: Add -Wno-conversion-null.
1787 2010-02-22 Sebastian Pop <sebastian.pop@amd.com>
1790 * sese.c (expand_scalar_variables_expr): Handle COMPONENT_REF.
1792 * g++.dg/graphite/pr43026.C: New.
1794 2010-02-13 Tobias Grosser <grosser@fim.uni-passau.de>
1796 * Merge from mainline (154736:156693).
1798 2010-02-11 Sebastian Pop <sebastian.pop@amd.com>
1801 * gcc.dg/graphite/pr43012.c: New.
1803 2010-02-10 Sebastian Pop <sebastian.pop@amd.com>
1805 * graphite.c (graphite_transform_loops): Re-enable dbg_cnt.
1806 2010-02-10 Sebastian Pop <sebastian.pop@amd.com>
1808 * g++.dg/graphite/pr42930.C: New.
1810 2010-02-10 Sebastian Pop <sebastian.pop@amd.com>
1813 * graphite-scop-detection.c (graphite_can_represent_scev): Call
1814 graphite_can_represent_init for MULT_EXPR.
1816 2010-02-10 Sebastian Pop <sebastian.pop@amd.com>
1820 * graphite-sese-to-poly.c (remove_phi): New.
1821 (translate_scalar_reduction_to_array): Call remove_phi.
1823 * gcc.dg/graphite/pr42530.c: New.
1824 * gcc.dg/graphite/pr42914.c: New.
1826 2010-02-10 Sebastian Pop <sebastian.pop@amd.com>
1829 * graphite-clast-to-gimple.c (gloog): Call rename_sese_parameters.
1830 * graphite-clast-to-gimple.h (gloog): Update declaration.
1831 * graphite-poly.c (new_scop): Clear POLY_SCOP_P.
1832 * graphite-poly.h (struct poly_bb): Add missing comments.
1833 (struct scop): Add poly_scop_p field.
1835 * graphite-sese-to-poly.c (build_poly_scop): Set POLY_SCOP_P.
1836 * graphite.c (graphite_transform_loops): Build the polyhedral
1837 representation for each scop before code generation.
1838 * sese.c (rename_variables_in_operand): Removed.
1839 (rename_variables_in_expr): Return the renamed expression.
1840 (rename_sese_parameters): New.
1841 * sese.h (rename_sese_parameters): Declared.
1843 * gcc.dg/graphite/pr42771.c: New.
1845 2010-02-07 Sebastian Pop <sebastian.pop@amd.com>
1847 * gcc.dg/graphite/block-0.c: Call abort for runtime test. Always
1849 * gcc.dg/graphite/block-1.c: Same.
1850 * gcc.dg/graphite/block-3.c: Same.
1851 * gcc.dg/graphite/block-4.c: Same.
1852 * gcc.dg/graphite/block-5.c: Same.
1853 * gcc.dg/graphite/block-6.c: Same.
1854 * gcc.dg/graphite/block-7.c: Same.
1855 * gcc.dg/graphite/interchange-0.c: Same.
1856 * gcc.dg/graphite/interchange-1.c: Same.
1857 * gcc.dg/graphite/interchange-10.c: Same.
1858 * gcc.dg/graphite/interchange-11.c: Same.
1859 * gcc.dg/graphite/interchange-12.c: Same.
1860 * gcc.dg/graphite/interchange-2.c: Same.
1861 * gcc.dg/graphite/interchange-3.c: Same.
1862 * gcc.dg/graphite/interchange-4.c: Same.
1863 * gcc.dg/graphite/interchange-5.c: Same.
1864 * gcc.dg/graphite/interchange-6.c: Same.
1865 * gcc.dg/graphite/interchange-7.c: Same.
1866 * gcc.dg/graphite/interchange-8.c: Same.
1867 * gcc.dg/graphite/interchange-9.c: Same.
1868 * gcc.dg/graphite/interchange-mvt.c: Same.
1870 2010-02-07 Sebastian Pop <sebastian.pop@amd.com>
1872 * gfortran.dg/graphite/id-19.f: New.
1873 * gfortran.dg/graphite/pr14741.f90: New.
1874 * gfortran.dg/graphite/pr41924.f90: New.
1875 * gfortran.dg/graphite/run-id-2.f90: New.
1877 2010-02-07 Sebastian Pop <sebastian.pop@amd.com>
1880 * graphite-dependences.c (dependence_polyhedron): Set PDDR_KIND
1881 to unknown_dependence.
1882 (graphite_legal_transform_dr): Handle the unknown_dependence.
1883 (graphite_carried_dependence_level_k): Same.
1885 2010-02-07 Sebastian Pop <sebastian.pop@amd.com>
1887 * ChangeLog.graphite: Remove testsuite/ or gcc/testsuite/.
1889 2010-02-05 Sebastian Pop <sebastian.pop@amd.com>
1890 Konrad Trifunovic <konrad.trifunovic@inria.fr>
1893 * graphite-dependences.c (build_lexicographical_constraint): Return
1894 a union of dependence polyhedra.
1895 (dependence_polyhedron_1): Adapt for build_lexicographical_constraint.
1897 * gcc.dg/graphite/block-0.c: Enable runtime check. XFAILed.
1898 * gcc.dg/graphite/block-4.c: Same.
1899 * gcc.dg/graphite/block-7.c: Same.
1900 * gcc.dg/graphite/interchange-12.c: Same.
1901 * gcc.dg/graphite/interchange-mvt.c: Same.
1902 * gfortran.dg/graphite/interchange-1.f: XFAILed.
1903 * gfortran.dg/graphite/interchange-3.f90: XFAILed.
1904 * gfortran.dg/graphite/run-id-1.f: New testcase for PR42637.
1906 2010-02-03 Sebastian Pop <sebastian.pop@amd.com>
1908 * gcc.dg/graphite/interchange-12.c: Return 0 to avoid
1909 the execution check to FAIL. This testcase is miscompiled by Graphite
1910 and the check should be re-enabled.
1911 * gcc.dg/graphite/interchange-mvt.c: Same.
1912 * gcc.dg/graphite/block-0.c: Same.
1913 * gcc.dg/graphite/block-4.c: Same.
1914 * gcc.dg/graphite/block-7.c: Same.
1916 2010-02-03 Sebastian Pop <sebastian.pop@amd.com>
1918 * gcc.dg/graphite/interchange-mvt.c: Un-XFAILed.
1919 * gcc.dg/graphite/scop-0.c: Fix spaces.
1920 * gfortran.dg/graphite/block-1.f90: Rewrite expected output.
1921 * gfortran.dg/graphite/block-2.f: Same.
1922 * gfortran.dg/graphite/block-3.f90: Same.
1923 * gfortran.dg/graphite/block-4.f90: Same.
1924 * gfortran.dg/graphite/interchange-1.f: Un-XFAILed.
1925 * gfortran.dg/graphite/interchange-3.f90: Un-XFAILed.
1927 2010-02-03 Sebastian Pop <sebastian.pop@amd.com>
1929 * graphite-dependences.c (new_poly_ddr): Initialize PDDR_KIND and
1930 PDDR_ORIGINAL_SCATTERING_P.
1931 (pddr_is_empty): Rewritten.
1932 (print_dependence_polyhedron_layout): New.
1935 (build_alias_set_powerset): Moved up.
1936 (poly_drs_may_alias_p): Moved up.
1937 (lexicographically_gt_p): Removed.
1938 (build_lexicographically_gt_constraint): Renamed
1939 build_lexicographical_constraint, reimplemented.
1940 (dependence_polyhedron_1): Simplified parameters.
1941 (dependence_polyhedron): Same. Keep along empty PDDRs
1942 to make efficient use of the cache.
1943 (reduction_dr_p): Compute the PBBs don't pass them as parameters.
1944 (graphite_legal_transform_dr): Rewritten.
1945 (graphite_legal_transform_bb): Pass fewer arguments to
1946 graphite_legal_transform_dr.
1947 (graphite_carried_dependence_level_k): Simplified implementation.
1948 (dot_original_deps_stmt_1): Call dependence_polyhedron.
1949 (dot_transformed_deps_stmt_1): Same.
1950 (dot_original_deps): Same.
1951 (dot_transformed_deps): Same.
1952 * graphite-dependences.h (struct poly_ddr): Added a new field
1953 original_scattering_p.
1954 (PDDR_ORIGINAL_SCATTERING_P): New.
1955 (print_pddr): Declared.
1956 (debug_pddr): Declared.
1957 * graphite-ppl.c: Clarify comment.
1958 * sese.h (print_gimple_bb): Removed unused declaration.
1961 2010-02-03 Sebastian Pop <sebastian.pop@amd.com>
1963 * g++.dg/graphite/graphite.exp: Rewritten.
1964 * gcc.dg/graphite/graphite.exp: Rewritten.
1965 * gfortran.dg/graphite/graphite.exp: Rewritten.
1966 * gcc.dg/graphite/block-0.c: Added runtime test.
1967 * gcc.dg/graphite/block-1.c: Same.
1968 * gcc.dg/graphite/block-3.c: Same.
1969 * gcc.dg/graphite/block-4.c: Same.
1970 * gcc.dg/graphite/block-5.c: Same.
1971 * gcc.dg/graphite/block-6.c: Same.
1972 * gcc.dg/graphite/block-7.c: Same.
1973 * gcc.dg/graphite/interchange-0.c: Same.
1974 * gcc.dg/graphite/interchange-1.c: Same.
1975 * gcc.dg/graphite/interchange-10.c: Same.
1976 * gcc.dg/graphite/interchange-11.c: Same.
1977 * gcc.dg/graphite/interchange-12.c: Same.
1978 * gcc.dg/graphite/interchange-2.c: Same.
1979 * gcc.dg/graphite/interchange-3.c: Same.
1980 * gcc.dg/graphite/interchange-4.c: Same.
1981 * gcc.dg/graphite/interchange-5.c: Same.
1982 * gcc.dg/graphite/interchange-6.c: Same.
1983 * gcc.dg/graphite/interchange-7.c: Same.
1984 * gcc.dg/graphite/interchange-8.c: Same.
1985 * gcc.dg/graphite/interchange-9.c: Same.
1986 * gcc.dg/graphite/interchange-mvt.c: Same.
1987 * gcc.dg/graphite/run-id-2.c: Remove useless dg-do run.
1989 2010-01-22 Ramakrishna Upadrasta <Ramakrishna.Upadrasta@inria.fr>
1991 * graphite-scop-detection.c (dot_all_scops): Make calls to dot run in
1994 2010-01-22 Ramakrishna Upadrasta <Ramakrishna.Upadrasta@inria.fr>
1996 * common.opt: Add -fgraphite-cloog-opts.
1997 * graphite-clast-to-gimple.c (set_cloog_options): Same.
1998 * opts.c (decode_options): Same.
2000 2010-01-20 Sebastian Pop <sebastian.pop@amd.com>
2002 * gcc.dg/graphite/id-17.c: New.
2003 * gcc.dg/graphite/pr41888.c: New.
2004 * gcc.dg/graphite/scop-22.c: New.
2005 * gfortran.dg/graphite/pr40982.f90: New.
2007 2010-01-20 Sebastian Pop <sebastian.pop@amd.com>
2009 * graphite-dependences.c: Clarify comments.
2010 (build_pddr): Add an extra parameter direction.
2011 (graphite_legal_transform_dr): Use build_pddr.
2012 (dot_original_deps_stmt_1): Update use of build_pddr.
2013 (dot_transformed_deps_stmt_1): Same.
2014 (dot_original_deps): Same.
2015 (dot_transformed_deps): Same.
2017 * gcc.dg/graphite/interchange-12.c: New.
2018 * gcc.dg/graphite/block-7.c: New.
2020 2010-01-20 Sebastian Pop <sebastian.pop@amd.com>
2022 * graphite-dependences.c (pddr_original_scattering): Renamed build_pddr.
2023 (pddr_transformed_scattering): Removed.
2024 (graphite_legal_transform_dr): Use build_pddr.
2025 (dot_original_deps_stmt_1): Same.
2026 (dot_transformed_deps_stmt_1): Same.
2027 (dot_original_deps): Same.
2028 (dot_transformed_deps): Same.
2030 2010-01-20 Sebastian Pop <sebastian.pop@amd.com>
2032 * graphite-dependences.c (lexicographically_gt_p): Add comments.
2033 (build_lexicographically_gt_constraint): Same.
2034 (dependence_polyhedron_1): Same.
2035 (dependence_polyhedron): Same.
2037 2010-01-20 Sebastian Pop <sebastian.pop@amd.com>
2039 * graphite-dependences.c (build_pairwise_scheduling_equality): Removed.
2040 (build_pairwise_scheduling_inequality): Renamed build_pairwise_scheduling.
2041 (lexicographically_gt_p): Change type of direction to int.
2042 (build_lexicographically_gt_constraint): Same.
2043 (dependence_polyhedron_1): Same.
2044 (dependence_polyhedron): Same.
2045 (pddr_original_scattering): Use integers for direction.
2046 (pddr_transformed_scattering): Same.
2047 (graphite_legal_transform_dr): Same.
2048 (graphite_carried_dependence_level_k): Same.
2050 2010-01-20 Sebastian Pop <sebastian.pop@amd.com>
2052 * graphite-dependences.c (build_pairwise_constraint): Renamed
2053 ppl_build_relation. Moved...
2054 (dr_equality_constraints): Use ppl_build_relation.
2055 (build_pairwise_scheduling_equality): Same.
2056 (build_pairwise_scheduling_inequality): Same.
2057 * graphite-ppl.c (ppl_build_relation): ...here.
2058 * graphite-ppl.h (ppl_build_relation): Declared.
2060 2010-01-14 Sebastian Pop <sebastian.pop@amd.com>
2063 * graphite-clast-to-gimple.c (gloog_error): New static variable.
2064 (clast_to_gcc_expression): Do not build MULT_EXPR of POINTER_TYPE_P.
2065 Set gloog_error when such an expression failed to be built.
2066 (translate_clast): Early return when gloog_error is set.
2067 (gloog): Clear gloog_error. When gloog_error is set, call
2068 set_ifsese_condition to enable the original code. Return the status
2069 of the code generation based on gloog_error.
2070 * sese.c (set_ifsese_condition): New.
2071 * sese.h (set_ifsese_condition): Declared.
2073 * g++.dg/graphite/pr42681.C: New.
2075 2010-01-14 Sebastian Pop <sebastian.pop@amd.com>
2078 * graphite-clast-to-gimple.c (gloog): Call scev_reset_htab and
2079 rename_nb_iterations.
2080 * sese.c (rename_variables_in_operand): New.
2081 (rename_variables_in_expr): New.
2082 (rename_nb_iterations): New.
2083 (sese_adjust_liveout_phis): Update the rename_map.
2084 * sese.h (rename_nb_iterations): Declared.
2085 * tree-scalar-evolution.c (scev_reset_htab): New.
2086 (scev_reset): Call scev_reset_htab.
2087 * tree-scalar-evolution.h (scev_reset_htab): Declared.
2089 * gfortran.dg/graphite/pr42732.f: New.
2091 2010-01-08 Sebastian Pop <sebastian.pop@amd.com>
2094 * graphite-clast-to-gimple.c: Fix formatting.
2095 * sese.c (defined_in_loop_p): Renamed name_defined_in_loop_p.
2096 (expr_defined_in_loop_p): New.
2097 (add_loop_exit_phis): Also handle full expressions: remove from
2098 the rename_map the expressions defined in the loop that we're closing.
2100 * gfortran.dg/graphite/pr42393-1.f90: New.
2101 * gfortran.dg/graphite/pr42393.f90: Add new flags
2102 -fno-loop-block -fno-loop-interchange -fno-loop-strip-mine to also
2103 make this testcase useful in the Graphite branch.
2105 2010-01-08 Sebastian Pop <sebastian.pop@amd.com>
2107 * graphite-scop-detection.c (exclude_component_ref): Removed.
2108 (is_simple_operand): Removed.
2109 (stmt_simple_for_scop_p): Remove use of is_simple_operand.
2111 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
2114 * sese.c (expand_scalar_variables_expr): Follow the SSA links into
2115 the array indexing of ADDR_EXPRs.
2117 * gcc.dg/graphite/pr42221.c: New.
2119 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
2122 * graphite.c (graphite_finalize): Call scev_reset.
2123 (graphite_transform_loops): Do not call scev_reset between the code
2124 generation of scops.
2126 * gcc.dg/graphite/pr42521.c: New.
2128 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
2130 * graphite-interchange.c (memory_stride_in_loop): Renamed
2132 (memory_strides_in_loop): Renamed memory_strides_in_loop_1.
2133 (memory_strides_in_loop): Memoize the memory strides per loop.
2134 (lst_interchange_profitable_p): Do not initialize to zero the memory
2136 * graphite-poly.h (struct lst): Add a field memory_strides.
2137 (LST_LOOP_MEMORY_STRIDES): New.
2138 (new_lst_loop): Initialize LST_LOOP_MEMORY_STRIDES to -1.
2139 (free_lst): Clear LST_LOOP_MEMORY_STRIDES.
2141 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
2143 * graphite-interchange.c (memory_strides_in_loop_depth): Renamed
2144 memory_strides_in_loop. Gather memory strides on a whole loop.
2145 (pbb_interchange_profitable_p): Renamed lst_interchange_profitable_p.
2146 (lst_interchange_profitable_p): Removed.
2147 (lst_try_interchange_loops): Call lst_interchange_profitable_p.
2149 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
2151 Revert patch 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
2152 * graphite-clast-to-gimple.c (try_mark_loop_parallel): New.
2153 (translate_clast_for, translate_clast_guard, translate_clast, gloog):
2154 Remove context_loop and level.
2156 2010-01-07 Richard Guenther <rguenther@suse.de>
2158 PR tree-optimization/42641
2159 * sese.c (rename_map_elt_info): Use the SSA name version, do
2162 2010-01-06 Sebastian Pop <sebastian.pop@amd.com>
2164 * graphite-blocking.c (scop_do_block): Print "SCoP will be loop
2165 blocked" only when both the strip mine and the interchange have
2168 * gcc.dg/graphite/block-2.c: Removed.
2169 * gcc.dg/graphite/block-3.c: Add scan pattern.
2170 * gcc.dg/graphite/block-4.c: Same.
2171 * gcc.dg/graphite/block-5.c: Same.
2172 * gcc.dg/graphite/block-6.c: Same.
2174 2010-01-06 Sebastian Pop <sebastian.pop@amd.com>
2176 * graphite-clast-to-gimple.c (save_clast_name_index): Free slot
2177 before allocating a new one.
2178 (copy_renames): Check that slot is not NULL.
2179 (mark_bb_with_pbb): Same.
2180 (compute_cloog_iv_types_1): Same.
2181 * graphite-interchange.c (lst_perfect_nestify): Free the before,
2182 nest, and after LSTs.
2183 (lst_try_interchange_loops): Same.
2185 2010-01-05 Sebastian Pop <sebastian.pop@amd.com>
2188 * graphite-interchange.c (lst_try_interchange_loops): Do not return
2189 the before, nest, and after LSTs.
2190 (lst_try_interchange): Removed.
2191 (lst_interchange_select_inner): Do not iterate over the LSTs if they
2193 (lst_interchange_select_outer): Apply interchange on the outer loop
2194 until there are no more changes in the inner loops.
2196 2009-12-18 Sebastian Pop <sebastian.pop@amd.com>
2198 Revert patch fixing PR middle-end/42221.
2200 2009-12-18 Sebastian Pop <sebastian.pop@amd.com>
2203 * graphite-sese-to-poly.c (follow_ssa_with_commutative_ops): Handle
2206 * gfortran.dg/graphite/pr42180.f90: Add compile flags.
2208 2009-12-18 Sebastian Pop <sebastian.pop@amd.com>
2211 * graphite-sese-to-poly.c (split_reduction_stmt): Do not split blocks
2212 that contain only one statement.
2214 * gfortran.dg/graphite/pr42180.f90: New.
2216 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
2219 * gfortran.dg/graphite/pr42393.f90: New.
2221 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
2224 * gfortran.dg/graphite/pr42186.f90: New.
2226 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
2229 * graphite-sese-to-poly.c (translate_scalar_reduction_to_array_for_stmt):
2230 Insert the reduction copy in the same block as the phi node.
2231 (follow_ssa_with_commutative_ops): Handle GIMPLE_NOPs.
2233 * gcc.dg/graphite/pr42205-1.c: New.
2234 * gcc.dg/graphite/pr42205-2.c: New.
2236 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
2239 * sese.c (expand_scalar_variables_expr): Follow the SSA links into
2240 the array indexing of ADDR_EXPRs.
2242 * gcc.dg/graphite/pr42221.c: New.
2244 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
2248 * graphite-interchange.c (lst_try_interchange): Do not modify OUTER
2249 index. Call lst_interchange_select_inner only once.
2250 (lst_interchange_select_inner): Update use of lst_try_interchange.
2251 (lst_interchange_select_outer): Update.
2253 2009-12-15 Sebastian Pop <sebastian.pop@amd.com>
2257 * graphite-interchange.c (lst_try_interchange): Do not increment the
2258 the OUTER index when there is no AFTER kernel. Do not increment the
2259 OUTER index for after processing the AFTER kernel.
2260 (lst_interchange_select_inner): Call lst_try_interchange only on loops.
2261 (lst_interchange_select_outer): Do not pass in a pointer to the OUTER
2262 index. Do not pass to lst_interchange_select_inner the OUTER index.
2263 (scop_do_interchange): Update use of lst_interchange_select_outer.
2265 * gfortran.dg/graphite/graphite.exp
2266 (DEFAULT_FLAGS_GRAPHITE_IDENTITY): Remove -fdump-tree-graphite-all.
2267 * gfortran.dg/graphite/interchange-1.f: Add comment. Clean
2268 the graphite dump file.
2269 * gfortran.dg/graphite/interchange-2.f: Same.
2270 * gfortran.dg/graphite/pr42334-1.f: New.
2272 2009-12-15 Sebastian Pop <sebastian.pop@amd.com>
2276 * graphite-interchange.c (lst_perfect_nestify): Reset to NULL the LSTs
2278 (lst_do_interchange_1): Renamed lst_interchange_select_inner.
2279 (lst_try_interchange): Reimplemented.
2280 (lst_interchange_select_inner): Same.
2281 (lst_do_interchange): Renamed lst_interchange_select_outer.
2283 (scop_do_interchange): Update use of lst_interchange_select_outer.
2285 * g++.dg/graphite/pr42130.C: Add -fgraphite-identity.
2286 * gcc.dg/graphite/block-0.c: Un-XFAILed.
2287 * gcc.dg/graphite/pr42211.c: New.
2288 * gfortran.dg/graphite/pr42334.f90: New.
2290 2009-12-14 Sebastian Pop <sebastian.pop@amd.com>
2293 * graphite-scop-detection.c (graphite_can_represent_scev): Handle more
2294 carefully PLUS_EXPR, MINUS_EXPR, and MULT_EXPR.
2296 * gfortran.dg/graphite/pr42181.f90: New.
2298 2009-12-12 Sebastian Pop <sebpop@gmail.com>
2301 * graphite-sese-to-poly.c (rewrite_close_phi_out_of_ssa): Call
2302 insert_out_of_ssa_copy_on_edge for anything else than SSA_NAMEs.
2303 (detect_commutative_reduction_arg): Simplified.
2304 (detect_commutative_reduction): Early return when the argument of
2305 the close phi is not of an SSA_NAME.
2307 * gcc.dg/graphite/pr42284.c: New.
2309 2009-12-11 Alexander Monakov <amonakov@ispras.ru>
2311 * dbgcnt.def (graphite_scop): New counter.
2312 * graphite.c: Include dbgcnt.h
2313 (graphite_transform_loops): Use new counter to limit transformations.
2315 2009-12-08 Sebastian Pop <sebpop@gmail.com>
2318 * graphite-scop-detection.c (graphite_can_represent_init): Also
2319 handle more complex MULT_EXPRs containing parameters by recursion
2322 * gfortran.dg/graphite/pr42285.f90: New.
2324 2009-12-01 Tobias Grosser <grosser@fim.uni-passau.de>
2326 * g++.dg/graphite/pr42130.C: Fix type.
2328 2009-11-29 Alexander Monakov <amonakov@gcc.gnu.org>
2330 * g++.dg/graphite/pr42130.C: Correct testcase.
2332 2009-11-28 Tobias Grosser <grosser@fim.uni-passau.de>
2334 * Merge from mainline (154493:154734).
2336 2009-11-28 Tobias Grosser <grosser@fim.uni-passau.de>
2338 * Merge from mainline (151362:154491).
2340 2009-11-24 Tobias Grosser <grosser@fim.uni-passau.de>
2342 * graphite-clast-to-gimple.c (try_mark_loop_parallel,
2343 graphite_create_new_loop_guard, translate_clast_for): Fix comments.
2345 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
2348 * graphite-clast-to-gimple.c (graphite_create_new_loop_guard,
2349 translate_clast_for_loop): New.
2350 (translate_clast_for): Add a condition around the loop, to do not
2351 execute loops with zero iterations.
2352 * g++.dg/graphite/pr42130.C: New.
2353 * gcc.dg/graphite/pr35356-2.c: Adapt.
2355 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
2357 * graphite-clast-to-gimple.c (try_mark_loop_parallel): New.
2358 (translate_clast_for, translate_clast_guard, translate_clast, gloog):
2359 Remove context_loop and level.
2361 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
2363 * graphite-clast-to-gimple.c (translate_clast_user,
2364 translate_clast_for, translate_clast_guard): Simplify and move common
2365 elements to translate_clast().
2366 (translate_clast): Simplify and get common elements.
2368 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
2370 * graphite-clast-to-gimple.c (translate_clast_user,
2371 translate_clast_for, translate_clast_guard): Split out of
2374 2009-11-21 Tobias Grosser <grosser@fim.uni-passau.de>
2376 * graphite-clast-to-gimple.c (clast_name_index, new_clast_name_index,
2377 clast_name_to_index, save_clast_name_index, debug_clast_name_index,
2378 debug_clast_name_indexes_1, debug_clast_name_indexes,
2379 clast_name_index_elt_info, eq_clast_name_indexes): Moved from sese.h.
2380 (clast_name_to_gcc, clast_to_gcc_expression,
2381 clast_to_gcc_expression_red, gcc_type_for_clast_expr,
2382 gcc_type_for_clast_eq, graphite_translate_clast_equation,
2383 graphite_create_guard_cond_expr, graphite_create_new_loop,
2384 translate_clast): Add params_index.
2385 (initialize_cloog_names): Create parameter strings from scratch, do
2386 not reference other strings.
2387 (create_params_index): New.
2388 (gloog): Initialize params_index.
2389 * graphite-scop-detection (free_scops_1): Removed.
2390 (limit_scops): Use normal free_scops.
2391 * graphite-sese-to-poly.c (save_var_names): Removed.
2392 (parameter_index_in_region): Do not initialize SESE_PARAM_NAMES
2393 and SESE_PARAMS_INDEX.
2394 * sese.c (new_sese, free_sese): Dito.
2395 * sese.h (struct sese): Remove params_index, params_names.
2396 (SESE_PARAMS_INDEX, SESE_PARAMS_NAMES): Removed.
2398 2009-11-20 Sebastian Pop <sebastian.pop@amd.com>
2400 Revert the following patch from 2009-09-14:
2401 * graphite-blocking.c: Fix order of includes: tree-chrec.h, then
2402 tree-scalar-evolution.h, and then tree-data-ref.h.
2403 * graphite-clast-to-gimple.c: Same.
2404 * graphite-dependences.c: Same.
2405 * graphite-interchange.c: Same.
2406 * graphite-poly.c: Same.
2407 * graphite-scop-detection.c: Same.
2408 * graphite-sese-to-poly.c: Same.
2410 * lambda-code.c: Same.
2411 * matrix-reorg.c: Same.
2412 * tree-data-ref.c: Same.
2413 * tree-if-conv.c: Same.
2414 * tree-loop-distribu: Same.: Same.
2415 * tree-loop-linear.c: Same.
2416 * tree-parloops.c: Same.
2417 * tree-predcom.c: Same.
2418 * tree-vect-patterns.c: Same.
2420 2009-11-20 Sebastian Pop <sebastian.pop@amd.com>
2422 Revert patch from 2009-09-14.
2423 * tree-ssa-loop.c (gate_graphite_transforms): Re-enable Graphite
2424 passes at -O1 and below.
2426 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
2429 * gcc.dg/graphite/pr40281.c: New.
2431 * tree-scalar-evolution.c (instantiate_scev_poly): Base and stride
2432 evolutions should not variate in inner loops.
2434 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
2437 * gfortran.dg/graphite/pr42050.f90: New.
2439 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
2441 * graphite-interchange.c (memory_strides_in_loop_depth): New.
2442 (pbb_interchange_profitable_p): Call memory_strides_in_loop_depth.
2444 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
2446 * graphite-blocking.c (scop_do_block): New.
2447 * graphite-poly.c (apply_poly_transforms): Call scop_do_block.
2448 * graphite-poly.h (scop_do_block): Declared.
2450 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
2452 * graphite-blocking.c (pbb_strip_mine_profitable_p): The parameter
2453 depth is the loop nesting depth in the LST. Call psct_dynamic_dim
2454 to transform depth into the time_depth before calling
2455 pbb_number_of_iterations_at_time.
2456 (lst_do_strip_mine): Use a scalar variable instead of recomputing
2459 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
2461 Reverted the patch for "scattering permutations" from 2009-10-28.
2463 * graphite-poly.c (print_permutation): New.
2464 (debug_permutation): New.
2465 (new_poly_bb): Initialize PBB_PERMUTATION.
2466 (free_poly_bb): Free PBB_PERMUTATION.
2467 * graphite-poly.h (pbb_permutation_elt_p): Declared.
2468 (struct pbb_permutation_elt): New.
2469 (PBB_PERMUTATION_ELT_STRIDE): New.
2470 (PBB_PERMUTATION_ELT_STRIDED_P): New.
2471 (PBB_PERMUTATION_ELT_TIME_DIMENSION): New.
2472 (new_pbb_permutation_elt): New.
2473 (pbb_permutation_elt_free): New.
2474 (struct poly_bb): Add field permutation.
2475 (PBB_PERMUTATION): New.
2476 (print_permutation): Declared.
2477 (debug_permutation): Declared.
2479 2009-11-04 Konrad Trifunovic <konrad.trifunovic@inria.fr>
2481 * graphite-interchange.c (build_partial_difference): New.
2482 (memory_stride_in_loop): Refactored the computation of
2483 equality constraints into build_partial_difference function.
2484 Added support for debugging stride computations.
2486 2009-11-03 Sebastian Pop <sebastian.pop@amd.com>
2488 * graphite-clast-to-gimple.c (gloog): Free if_region,
2489 if_region->true_region, and if_region->region.
2490 * sese.c (if_region_set_false_region): Free if_region->false_region.
2491 (create_if_region_on_edge): Do not use GGC_NEW.
2492 (move_sese_in_condition): Remove useless initialization.
2494 2009-11-03 Sebastian Pop <sebastian.pop@amd.com>
2496 * graphite-interchange.c (lst_perfect_nestify): Pass 3 parameters
2497 for the loops created by the loop distribution. Do not modify the
2499 (lst_try_interchange_loops): Same. Use a temporary LST for the
2500 transformed schedule. Call lst_update_scattering before data
2501 dependence analysis.
2502 (lst_try_interchange): Pass an extra parameter INDEX.
2503 (lst_do_interchange_1): New.
2504 (lst_do_interchange): Call lst_do_interchange_1.
2505 (scop_do_interchange): Call lst_update_scattering.
2506 * graphite-poly.c (apply_poly_transforms): Do not call
2507 lst_update_scattering.
2508 * graphite-poly.h (lst_pred): New.
2510 (lst_find_first_pbb): Return NULL when not found.
2512 (lst_insert_in_sequence): Allow LST1 to be NULL.
2514 (lst_substitute_3): New.
2515 * gcc.dg/graphite/interchange-1.c: XFail.
2516 * gcc.dg/graphite/interchange-8.c: XFail.
2517 * gcc.dg/graphite/interchange-11.c: XFail.
2519 2009-10-30 Sebastian Pop <sebastian.pop@amd.com>
2521 * graphite-interchange.c (lst_perfectly_nested_p): New.
2522 (lst_perfect_nestify): New.
2523 (lst_try_interchange_loops): Call store_lst_schedule,
2524 lst_perfectly_nested_p, lst_perfect_nestify and restore_lst_schedule.
2525 (scop_do_interchange): Avoid redundant legality test.
2526 Call lst_do_interchange on a copy of SCOP_TRANSFORMED_SCHEDULE.
2527 * graphite-poly.c (apply_poly_transforms): Call lst_update_scattering.
2528 * graphite-poly.h (psct_static_dim): New.
2529 (lst_dewey_number_at_depth): New.
2530 (lst_find_pbb): Restructured.
2531 (lst_find_first_pbb): Restructured.
2532 (lst_find_last_pbb): New.
2533 (lst_contains_p): New.
2534 (lst_contains_pbb): New.
2535 (lst_create_nest): New.
2536 (lst_remove_from_sequence): New.
2537 (pbb_update_scattering): New.
2538 (lst_update_scattering_under): New.
2539 (lst_update_scattering_seq): New.
2540 (lst_update_scattering): New.
2541 (lst_insert_in_sequence): New.
2542 (lst_distribute_lst): New.
2543 (lst_remove_all_before_including_pbb): New.
2544 (lst_remove_all_before_excluding_pbb): New.
2546 2009-10-30 Sebastian Pop <sebastian.pop@amd.com>
2548 * tree-ssa-loop-niter.c (finite_loop_p): Do not call twice
2549 get_loop_exit_edges.
2551 2009-10-30 Sebastian Pop <sebastian.pop@amd.com>
2553 * graphite-poly.c (pbb_remove_duplicate_pdrs): Free collapsed.
2555 2009-10-28 Konrad Trifunovic <konrad.trifunovic@gmail.com>
2557 * graphite-poly.c (print_permutation): New.
2558 (debug_permutation): New.
2559 (new_poly_bb): Initialize PBB_PERMUTATION.
2560 (free_poly_bb): Free PBB_PERMUTATION.
2561 * graphite-poly.h (pbb_permutation_elt_p): Declared.
2562 (struct pbb_permutation_elt): New.
2563 (PBB_PERMUTATION_ELT_STRIDE): New.
2564 (PBB_PERMUTATION_ELT_STRIDED_P): New.
2565 (PBB_PERMUTATION_ELT_TIME_DIMENSION): New.
2566 (new_pbb_permutation_elt): New.
2567 (pbb_permutation_elt_free): New.
2568 (struct poly_bb): Add field permutation.
2569 (PBB_PERMUTATION): New.
2570 (print_permutation): Declared.
2571 (debug_permutation): Declared.
2573 2009-10-26 Sebastian Pop <sebastian.pop@amd.com>
2575 * graphite-clast-to-gimple.c (gloog): Do not call
2576 sese_reset_aux_in_loops.
2577 * graphite-sese-to-poly.c (build_loop_iteration_domains): Pass an
2578 extra argument for domains. Do not use loop->aux.
2579 (build_scop_iteration_domain): Initialize and free domains, pass it
2580 to build_loop_iteration_domains and extract the information from
2581 domains. Do not use loop->aux.
2582 * sese.c (sese_reset_aux_in_loops): Removed.
2583 * sese.h (sese_reset_aux_in_loops): Removed.
2585 2009-10-26 Sebastian Pop <sebastian.pop@amd.com>
2587 * graphite-clast-to-gimple.c (find_pbb_via_hash): Moved up.
2588 (dependency_in_loop_p): Same.
2589 (translate_clast): Do not use loop->aux. Initialize
2590 loop->can_be_parallel.
2591 (mark_loops_parallel): Removed.
2592 * graphite-clast-to-gimple.h (mark_loops_parallel): Removed.
2593 * graphite.c (free_aux_in_new_loops): Removed.
2594 (graphite_finalize): Do not call free_aux_in_new_loops.
2595 (graphite_transform_loops): Do not call mark_loops_parallel.
2597 2009-10-26 Li Feng <nemokingdom@gmail.com>
2599 * graphite-clast-to-gimple.c (get_stmtfor_depth): Removed.
2600 (translate_clast): Pass an extra parameter LEVEL.
2601 Call get_scattering_level.
2602 * graphite-clast-to-gimple.h (get_scattering_level): New.
2604 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
2606 * cfgloop.c (alloc_loop): Initialize loop->single_iv.
2607 * cfgloop.h (struct loop): New field single_iv.
2609 * graphite-clast-to-gimple.c (pbb_to_depth_to_oldiv): Do not use
2610 loop->aux anymore: use loop->single_iv.
2611 (graphite_loop_normal_form): Moved...
2612 (build_graphite_loop_normal_form): Removed.
2613 (gloog): Do not call build_graphite_loop_normal_form.
2614 (free_aux_in_new_loops): Moved...
2615 (mark_loops_parallel): Restructure.
2616 * graphite-clast-to-gimple.h (free_aux_in_new_loops): Do not declare.
2617 * graphite-sese-to-poly.c (graphite_loop_normal_form): ...here.
2618 (scop_canonicalize_loops): New.
2619 (build_poly_scop): Call scop_canonicalize_loops.
2620 * graphite.c (free_aux_in_new_loops): ...here.
2622 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
2624 * g++.dg/graphite/graphite.exp: Add the same rules as in
2625 gcc.dg/graphite/graphite.exp.
2627 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
2629 * g++.dg/graphite/id-1.C: New.
2631 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
2633 * graphite-sese-to-poly.c (create_zero_dim_array): Pass an extra
2635 (rewrite_close_phi_out_of_ssa): Update use of create_zero_dim_array.
2636 (rewrite_phi_out_of_ssa): Same.
2637 (rewrite_cross_bb_scalar_deps): Same.
2638 (translate_scalar_reduction_to_array): Same.
2640 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
2642 * graphite-sese-to-poly.c (build_scop_drs): Disable call to
2645 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
2647 * graphite-sese-to-poly.c (dump_alias_graphs): New.
2648 (build_scop_drs): Call dump_alias_graphs.
2650 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
2652 * graphite-poly.c (new_scop): Initialize SCOP_ORIGINAL_SCHEDULE,
2653 SCOP_TRANSFORMED_SCHEDULE, and SCOP_SAVED_SCHEDULE.
2654 (free_scop): Call free_lst on SCOP_ORIGINAL_SCHEDULE,
2655 SCOP_TRANSFORMED_SCHEDULE, and SCOP_SAVED_SCHEDULE.
2656 * graphite-poly.h (free_lst): New.
2657 (store_lst_schedule): Free SCOP_SAVED_SCHEDULE.
2658 (restore_lst_schedule): Free SCOP_TRANSFORMED_SCHEDULE.
2660 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
2662 * graphite-poly.h (struct scop): Add a field saved_schedule.
2663 (SCOP_SAVED_SCHEDULE): New.
2664 (store_lst_schedule): New.
2665 (restore_lst_schedule): New.
2666 (store_scattering): Call store_lst_schedule.
2667 (restore_scattering): Call restore_lst_schedule.
2669 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
2671 * graphite-sese-to-poly.c (free_data_refs_aux): Fix formatting.
2672 (pdr_add_alias_set): Same.
2673 (build_poly_dr): Same.
2674 (build_alias_set_optimal_p): Same.
2675 (build_base_obj_set_for_drs): Same. Do not store the result of
2678 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
2680 * graphite-sese-to-poly.c (build_alias_set_optimal_p): Initialize
2681 all_components_are_cliques to 1.
2683 2009-10-20 Li Feng <nemokingdom@gmail.com>
2685 * graphite-sese-to-poly.c (free_data_refs_aux): Update to free
2687 (pdr_add_alias_set): Update retrieving alias_set_num.
2688 (build_poly_dr): Update retrieving dr_base_object_set.
2689 (partition_drs_to_sets): Remove.
2690 (build_alias_set_optimal_p): New.
2691 (build_alias_set_for_drs): Rename.
2692 (build_scop_drs): Update.
2693 * graphite-sese-to-poly.h (struct base_alias_pair): New.
2694 (ALIAS_SET_INDEX): Remove.
2695 (BASE_OBJECT_SET_INDEX): Remove.
2697 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
2699 * sese.c (get_vdef_before_sese): Handle GIMPLE_ASSIGN and GIMPLE_CALL.
2701 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
2703 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Do not infer
2704 loop upper bounds for 1-element arrays at end of structures.
2705 * tree-flow.h (array_at_struct_end_p): Declared.
2706 * tree-ssa-loop-niter.c (array_at_struct_end_p): Not static anymore.
2708 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
2710 * g++.dg/graphite/pr41305.C: New.
2712 2009-10-20 Alexander Monakov <amonakov@ispras.ru>
2714 * graphite-sese-to-poly.c (build_loop_iteration_domains): Generalize
2715 construction of parameter constraints from loop iteration analysis.
2716 * gcc.dg/graphite/run-id-2.c: New test.
2718 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
2720 * graphite-interchange.c (memory_stride_in_loop): Delete p1, lma
2723 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
2725 * graphite-dependences.c (dependence_polyhedron_1): Remove
2726 unused gdim dimensions from the DDR polyhedron.
2728 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
2730 * graphite-dependences.c (pddr_transformed_scattering): New.
2731 (dot_original_deps_stmt_1): New.
2732 (dot_transformed_deps_stmt_1): New.
2733 (dot_deps_stmt_1): Call dot_original_deps_stmt_1 and
2734 dot_transformed_deps_stmt_1.
2735 (dot_original_deps): New.
2736 (dot_transformed_deps): New.
2737 (dot_deps_1): Call dot_original_deps and dot_transformed_deps.
2739 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
2741 * graphite-dependences.c (reduction_dr_1): Remove wrong
2742 assert: reduction BBs can have multiple reduction writes
2743 to memory. interchange-3.f90 is an example.
2745 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
2747 * gfortran.dg/graphite/interchange-3.f90: New.
2749 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
2751 * gcc.dg/graphite/interchange-1.c: Un-XFAILed.
2753 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
2755 * graphite-dependences.c (dependence_polyhedron_1): Add the
2756 context to the dependence polyhedron.
2758 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
2760 * graphite-poly.c (pbb_remove_duplicate_pdrs): Initialize
2761 PBB_PDR_DUPLICATES_REMOVED.
2762 (new_poly_bb): Same.
2764 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
2766 * graphite-sese-to-poly.c (find_scop_parameters): Initialize
2768 (build_loop_iteration_domains): Extract bounds on parameters
2769 based on the data size.
2770 (build_scop_context): Do not initialize SCOP_CONTEXT;
2771 add new constraints.
2773 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
2775 * graphite-ppl.c (ppl_min_for_le_polyhedron): New.
2776 * graphite-ppl.h (graphite-ppl.h): Declared.
2778 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
2780 * graphite-ppl.c (ppl_print_linear_expr): New.
2781 (debug_ppl_linear_expr): New.
2782 * graphite-ppl.h (ppl_print_linear_expr): Declared.
2783 (debug_ppl_linear_expr): Declared.
2785 2009-10-16 Sebastian Pop <sebastian.pop@amd.com>
2787 * graphite-interchange.c: Fix comments.
2788 * gcc.dg/graphite/block-1.c: Fix comments.
2790 2009-10-16 Sebastian Pop <sebastian.pop@amd.com>
2792 * gcc.dg/graphite/interchange-7.c: Un-XFAILed.
2793 * gcc.dg/graphite/interchange-9.c: Un-XFAILed.
2795 2009-10-16 Sebastian Pop <sebastian.pop@amd.com>
2797 Reapply the patch from Alexander Monakov that disappeared during
2798 the last merges from trunk.
2800 2009-09-16 Alexander Monakov <amonakov@ispras.ru>
2802 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Add bounds only
2803 for ARRAY_REFs. Use array_ref_{low,up}_bound to determine bounds.
2805 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
2807 * graphite-interchange.c (memory_stride_in_loop): The depth
2808 argument corresponds to a dynamic time dimension, so use
2809 psct_dynamic_dim to refer to the transformed scattering dimension.
2811 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
2813 * graphite-interchange.c (memory_stride_in_loop): Fix comments.
2815 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
2817 * graphite-blocking.c (lst_do_strip_mine): Avoid strip mining the
2819 * graphite-interchange.c (lst_do_interchange): Avoid interchanging
2820 the root of the LST.
2821 * graphite-poly.c (scop_to_lst): Fix LST sequence in an outermost
2823 (print_lst): Print the root of LST in a different format.
2824 * graphite-poly.h (lst_depth): Adjust to include the root of the LST.
2826 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
2828 * graphite-poly.c (print_scop): Fix pretty printing of a SCoP.
2830 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
2832 * doc/passes.texi: Document the Graphite infrastructure.
2834 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
2836 * graphite-sese-to-poly.c (insert_copyin): Use gsi_insert_seq_on_edge.
2837 (rewrite_commutative_reductions_out_of_ssa): Call gsi_commit_edge_inserts,
2838 and check the SSA representation.
2840 * gfortran.dg/graphite/id-18.f90: New, reduced from PR41193.
2842 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
2844 * gcc.dg/graphite/pr40157.c: Use -floop-block as reported in the PR.
2846 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
2848 * gcc.dg/graphite/interchange-11.c: New.
2850 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
2852 * gcc.dg/graphite/interchange-8.c: Enable loop interchange.
2854 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
2856 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK):
2857 Add -fno-loop-strip-mine and -fno-loop-interchange.
2858 (DEFAULT_FLAGS_GRAPHITE_INTERCHANGE): Add -fno-loop-block and
2859 -fno-loop-strip-mine.
2860 * gfortran.dg/graphite/graphite.exp: Same.
2862 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
2864 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK):
2865 Renamed DEFAULT_FLAGS_GRAPHITE_BLOCK.
2866 (DEFAULT_CFLAGS_GRAPHITE_IDENTITY): Renamed
2867 DEFAULT_FLAGS_GRAPHITE_IDENTITY.
2868 (DEFAULT_CFLAGS_GRAPHITE_INTERCHANGE): Renamed
2869 DEFAULT_FLAGS_GRAPHITE_INTERCHANGE.
2870 (DEFAULT_CFLAGS_GRAPHITE_SCOP): Renamed
2871 DEFAULT_FLAGS_GRAPHITE_SCOP.
2872 (DEFAULT_CFLAGS_RUN_ID): Renamed DEFAULT_FLAGS_RUN_ID.
2873 (DEFAULT_CFLAGS_GRAPHITE): Renamed DEFAULT_FLAGS_GRAPHITE.
2875 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
2877 * graphite-poly.c (pbb_number_of_iterations_at_time): Cleanup comments.
2879 2009-10-14 Konrad Trifunovic <konrad.trifunovic@gmail.com>
2880 Sebastian Pop <sebastian.pop@amd.com>
2882 * graphite-interchange.c (build_linearized_memory_access): Pass an
2883 offset as parameter.
2884 (memory_stride_in_loop): Include transform scattering in the
2885 access functions to be able to querry the strides in the
2887 (pbb_interchange_loop_depths): Interchange the psct_dynamic_dim,
2888 not the psct_iterator_dim.
2890 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
2892 * graphite-blocking.c (pbb_do_strip_mine): Removed.
2893 (lst_do_strip_mine_loop): New.
2894 (lst_do_strip_mine): New.
2895 (scop_do_strip_mine): Call lst_do_strip_mine.
2896 * graphite-poly.h (lst_add_loop_under_loop): New.
2897 (lst_find_first_pbb): New.
2899 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
2901 * graphite-poly.c (loop_to_lst): Fix LST creation.
2903 2009-10-14 Tobias Grosser <grosser@fim.uni-passau.de>
2905 * gcc.dg/graphite/id-15.c: (8 * 8) replaced with
2906 sizeof(unsigned long) to make it run on 32bit systems.
2908 2009-10-14 Tobias Grosser <grosser@fim.uni-passau.de>
2910 * gcc.dg/graphite/run-id-1.c: Use smaller matrix to not
2913 2009-10-14 Ramakrishna Upadrasta <Ramakrishna.Upadrasta@inria.fr>
2915 * graphite-sese-to-poly.c (write_alias_graph_to_ascii_dimacs): Fix
2917 (write_alias_graph_to_ascii_dot): New.
2918 (write_alias_graph_to_ascii_ecc): Ditto.
2919 (partition_drs_to_sets): Add testing of optimality of current method
2920 which assigns alias numbers according to DFS Comopnent number. used
2921 as heuristic for the upcoming ECC algorithm.
2922 (build_scop_drs): Write to file also with the ecc and dot format.
2924 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
2926 * gfortran.dg/graphite/interchange-1.f: XFail.
2928 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
2930 * graphite.c (graphite_initialize): Do not handle functions with
2931 more than 100 basic blocks.
2933 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
2935 * graphite-blocking.c (pbb_do_strip_mine): Use
2936 PARAM_LOOP_BLOCK_TILE_SIZE.
2938 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
2940 * graphite-poly.c (dot_lst_1): New.
2942 * graphite-poly.h (dot_lst): Declared.
2944 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
2946 * graphite-dependences.c (dot_deps_stmt_1): New.
2947 (dot_deps_stmt): New.
2948 * graphite-dependences.h (dot_deps_stmt): Declared.
2950 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
2952 * graphite-sese-to-poly.c (rewrite_cross_bb_scalar_dependence): Do
2953 not replace cross BB scalar dependences ending on PHI nodes.
2954 (rewrite_cross_bb_scalar_deps): Filter out GIMPLE_PHI nodes.
2956 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
2958 * graphite-poly.c (apply_poly_transforms): Implement the high
2959 level driver for flag_loop_block.
2960 * opts.c (decode_options): Enable flag_loop_block at -O2.
2961 * tree-ssa-loop.c (gate_graphite_transforms): Remove call to sorry for
2964 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK): Add
2966 * gfortran.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK):
2969 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
2971 * graphite-poly.h (lst_find_pbb): New.
2972 (find_lst_loop): New.
2974 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
2976 * graphite-poly.c (new_scop): Remove init of SCOP_DEP_GRAPH.
2977 * graphite-poly.h (struct scop): Remove dep_graph field.
2978 (SCOP_DEP_GRAPH): Removed.
2980 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
2982 * graphite-poly.h (copy_lst): Do full copy of LST.
2984 2009-10-07 Sebastian Pop <sebastian.pop@amd.com>
2986 * graphite-sese-to-poly.c (reduction_phi_p): Call remove_invariant_phi
2987 when the loop stride is zero.
2989 * gcc.dg/graphite/id-16.c: New.
2991 2009-10-06 Sebastian Pop <sebastian.pop@amd.com>
2993 * graphite-dependences.c (reduction_dr_1): New.
2994 (reduction_dr_p): New.
2995 (graphite_legal_transform_dr): Call reduction_dr_p.
2996 (reduction_ddr): Renamed reduction_ddr_p.
2997 * graphite-poly.h (same_pdr_p): New.
2998 (number_of_write_pdrs): New.
2999 * graphite-sese-to-poly.c (nb_data_writes_in_bb): New.
3000 (split_reduction_stmt): Do not split reduction statements
3001 when there are no writes to memory.
3002 (translate_scalar_reduction_to_array_for_stmt): Insert the
3003 memory reduction statement just after the scalar reduction statement.
3005 * gcc.dg/graphite/interchange-10.c: Updated to differ from interchange-4.c.
3007 * gcc.dg/graphite/interchange-3.c: Un-XFAIL-ed.
3008 * gcc.dg/graphite/interchange-4.c: Un-XFAIL-ed.
3010 2009-10-06 Sebastian Pop <sebastian.pop@amd.com>
3012 * graphite-interchange.c (lst_apply_interchange): New.
3013 (lst_interchange_profitable_p): New.
3014 (lst_try_interchange_loops): New.
3015 (lst_try_interchange): New.
3016 (lst_do_interchange): New.
3017 (pbb_do_interchange): Removed.
3018 (scop_do_interchange): Call lst_do_interchange.
3020 2009-10-06 Sebastian Pop <sebastian.pop@amd.com>
3022 * graphite-poly.c (print_scop): Print SCOP_ORIGINAL_SCHEDULE and
3023 SCOP_TRANSFORMED_SCHEDULE.
3028 * graphite-poly.h (lst_p): New.
3031 (LST_LOOP_FATHER): New.
3034 (scop_to_lst): Declared.
3035 (print_lst): Declared.
3036 (debug_lst): Declared.
3037 (new_lst_loop): New.
3038 (new_lst_stmt): New.
3041 (lst_dewey_number): New.
3042 (struct scop): Add original_schedule and transformed_schedule fields.
3043 (SCOP_ORIGINAL_SCHEDULE): New.
3044 (SCOP_TRANSFORMED_SCHEDULE): New.
3045 * graphite-sese-to-poly.c (build_poly_scop): Call scop_to_lst.
3047 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
3049 * graphite-dependences.c (reduction_ddr): New.
3050 (graphite_legal_transform_bb): Call reduction_ddr.
3051 * graphite-poly.c (new_poly_bb): Pass a new bool parameter.
3052 Initialize PBB_IS_REDUCTION.
3053 * graphite-poly.h (struct poly_bb): New bool field is_reduction.
3054 (PBB_IS_REDUCTION): New.
3055 (new_poly_bb): Update declaration.
3056 * graphite-scop-detection.h (build_scop_bbs): Removed.
3057 (nb_reductions_in_loop): Removed.
3058 * graphite-sese-to-poly.c (try_generate_gimple_bb): Pass a sbitmap
3059 parameter for reductions.
3060 (try_generate_gimple_bb): Update call to new_poly_bb.
3061 (build_scop_bbs_1): Same.
3062 (build_scop_bbs): Same.
3063 (gsi_for_phi_node): New.
3064 (scalar_close_phi_node_p): Remove gcc_assert.
3065 (split_reduction_stmt): New.
3066 (is_reduction_operation_p): New.
3067 (phi_contains_arg): New.
3068 (follow_ssa_with_commutative_ops): New.
3069 (detect_commutative_reduction_arg): New.
3070 (detect_commutative_reduction_assign): New.
3071 (follow_inital_value_to_phi): New.
3072 (edge_initial_value_for_loop_phi): New.
3073 (initial_value_for_loop_phi): New.
3074 (detect_commutative_reduction): New.
3075 (translate_scalar_reduction_to_array_for_stmt): New.
3076 (insert_copyout): New.
3077 (insert_copyin): New.
3078 (translate_scalar_reduction_to_array): New.
3079 (rewrite_commutative_reductions_out_of_ssa_close_phi): New.
3080 (rewrite_commutative_reductions_out_of_ssa_loop): New.
3081 (rewrite_commutative_reductions_out_of_ssa): New.
3082 (build_poly_scop): Call rewrite_commutative_reductions_out_of_ssa.
3083 * sese.h (split_region_for_bb): New.
3085 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK): Add -ffast-math.
3086 * gcc.dg/graphite/interchange-1.c: Fix format.
3087 * gcc.dg/graphite/interchange-10.c: New.
3089 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
3091 * graphite-sese-to-poly.c (insert_out_of_ssa_copy): Remove
3094 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
3096 * graphite-sese-to-poly.c (scev_analyzable_p): New.
3097 (rewrite_cross_bb_scalar_dependence): New.
3098 (rewrite_cross_bb_scalar_deps): New.
3099 (rewrite_reductions_out_of_ssa): Use bb_in_sese_p.
3100 Call rewrite_cross_bb_scalar_deps.
3102 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
3104 * graphite-sese-to-poly.c (gsi_for_ssa_name_def): Removed.
3105 (insert_out_of_ssa_copy): Directly use gsi_after_labels and
3108 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
3110 * graphite-clast-to-gimple.c (build_cloog_prog): Use pbb_index.
3111 * graphite-interchange.c (pbb_do_interchange): Same.
3112 * graphite-poly.c (print_scattering_function): Same.
3114 * graphite-poly.h (pbb_loop): New.
3115 * graphite-sese-to-poly.c (create_linear_expr_from_tree): Use pbb_loop.
3117 2009-09-27 Sebastian Pop <sebastian.pop@amd.com>
3119 * graphite-scop-detection.c (limit_scops): Do not build poly_bbs.
3121 2009-09-27 Sebastian Pop <sebastian.pop@amd.com>
3123 * graphite-sese-to-poly.c (partition_drs_to_sets): Drs is not modified,
3124 so don't pass a pointer to it.
3125 (build_alias_set_for_drs): Same.
3126 (build_base_obj_set_for_drs): Same.
3127 (build_scop_drs): Same.
3129 2009-09-26 Li Feng <nemokingdom@gmail.com>
3131 * graphite-sese-to-poly.c (build_scop_drs): Disable writing to file
3132 the alias graph of data references.
3134 2009-09-25 Li Feng <nemokingdom@gmail.com>
3136 * graphite-sese-to-poly.c (write_alias_graph_to_ascii_dimacs): New.
3137 (build_scop_drs): When debugging, write the alias graph to file,
3138 otherwise, should be disabled.
3140 2009-09-17 Sebastian Pop <sebastian.pop@amd.com>
3142 * Merge from mainline (151310:151361).
3144 2009-09-17 Sebastian Pop <sebastian.pop@amd.com>
3146 * Merge from mainline (151171:151310).
3148 2009-09-17 Sebastian Pop <sebastian.pop@amd.com>
3150 * Merge from mainline (151171:151806).
3152 2009-09-17 Sebastian Pop <sebastian.pop@amd.com>
3154 * Revert the last commit.
3156 2009-09-17 Sebastian Pop <sebastian.pop@amd.com>
3158 * Merge from mainline (151171:151819).
3160 2009-09-17 Sebastian Pop <sebastian.pop@amd.com>
3162 * graphite-scop-detection.c (stmt_simple_memref_p): Removed.
3163 (is_simple_operand): Remove call to stmt_simple_memref_p.
3164 (stmt_simple_for_scop_p): Update call to is_simple_operand.
3166 2009-09-17 David Edelsohn <edelsohn@gnu.org>
3168 * gcc.dg/graphite/interchange-mvt.c: New File.
3169 * gcc.dg/graphite/scop-dsyrk.c: New File.
3170 * gcc.dg/graphite/scop-dsyr2k.c: New File.
3171 * gcc.dg/graphite/scop-mvt.c: New File.
3172 * gcc.dg/graphite/scop-sor.c: New File.
3174 2009-09-17 Li Feng <nemokingdom@gmail.com>
3176 * graphite-dependences.c (poly_drs_may_alias_p): Adjust definition.
3177 (pddr_original_scattering): Make sure 2 pdr2 in the same base object set.
3178 (graphite_carried_dependence_level_k): Ditto.
3179 * graphite-poly.c (new_poly_dr): Add init of PDR_BASE_OBJECT_SET.
3180 * graphite-poly.h (struct poly_dr): Add member dr_base_object_set.
3181 (new_poly_dr): Adjust declaration.
3182 * graphite-sese-to-poly.c (free_data_refs_aux): New.
3183 (free_gimple_bb): Added free_data_refs_aux.
3184 (build_poly_dr): Add dr_base_object_set.
3185 (partition_drs_to_sets): New.
3186 (dr_same_base_object_p): New.
3187 (build_alias_set_for_drs): New.
3188 (build_base_object_set_for_drs): New.
3189 (build_scop_drs): Add build_base_obj_set_for_drs.
3190 * graphite-sese-to-poly.h: Added #define for alias set number index and
3191 base object set index.
3192 * libgomp/testsuite/libgomp.graphite/force-parallel-6.c: Refine tests.
3193 * libgomp/testsuite/libgomp.graphite/pr4118.c: New.
3195 2009-09-16 Alexander Monakov <amonakov@ispras.ru>
3197 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Add bounds only
3198 for ARRAY_REFs. Use array_ref_{low,up}_bound to determine bounds.
3200 2009-09-14 Sebastian Pop <sebastian.pop@amd.com>
3202 * graphite-sese-to-poly.c (struct irp_data): Removed.
3203 (idx_record_params): Removed.
3204 (find_params_in_bb): Scan for parameters the access functions; don't
3205 parse the tree representation.
3207 2009-09-14 Sebastian Pop <sebastian.pop@amd.com>
3209 * tree-ssa-loop.c (gate_graphite_transforms): Disable Graphite
3210 passes at -O1 and below.
3212 2009-09-14 Sebastian Pop <sebastian.pop@amd.com>
3214 * graphite-blocking.c: Fix order of includes: tree-chrec.h, then
3215 tree-scalar-evolution.h, and then tree-data-ref.h.
3216 * graphite-clast-to-gimple.c: Same.
3217 * graphite-dependences.c: Same.
3218 * graphite-interchange.c: Same.
3219 * graphite-poly.c: Same.
3220 * graphite-scop-detection.c: Same.
3221 * graphite-sese-to-poly.c: Same.
3223 * lambda-code.c: Same.
3224 * matrix-reorg.c: Same.
3225 * tree-data-ref.c: Same.
3226 * tree-if-conv.c: Same.
3227 * tree-loop-distribu: Same.: Same.
3228 * tree-loop-linear.c: Same.
3229 * tree-parloops.c: Same.
3230 * tree-predcom.c: Same.
3231 * tree-vect-patterns.c: Same.
3233 2009-09-02 Sebastian Pop <sebastian.pop@amd.com>
3235 Partially revert the previous patch, except the following.
3236 * tree-scalar-evolution.c (instantiate_scev_not): Adapted to pass
3237 as parameters the operands of the not expression.
3239 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
3241 * tree-scalar-evolution.c (instantiate_scev_assign): New.
3242 Do not call analyze_scalar_evolution on assignments.
3243 (instantiate_scev_phi): Call analyze_scalar_evolution.
3244 (instantiate_scev_name): Call instantiate_scev_assign and
3245 instantiate_scev_phi.
3246 (instantiate_scev_not): Adapted to pass as parameters the operands
3247 of the not expression.
3249 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
3251 * tree-scalar-evolution.c (instantiate_scev_binary): Adapted
3252 to pass as parameters the operands of the binary expression.
3254 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
3256 * tree-scalar-evolution.c (instantiate_scev_bitnot): Renamed
3257 instantiate_scev_not. Handle NEGATE_EXPR.
3258 (instantiate_scev_r): Handle NEGATE_EXPR.
3260 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
3262 * tree-scalar-evolution.c (instantiate_scev_1): Renamed
3264 (instantiate_scev_r): Move code in instantiate_scev_2
3265 and instantiate_scev_1.
3267 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
3269 * tree-scalar-evolution.c (instantiate_scev_3): New.
3270 (instantiate_scev_1): Move code in instantiate_scev_3.
3272 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
3274 * tree-scalar-evolution.c (instantiate_scev_poly): New.
3275 (instantiate_scev_1): Move code in instantiate_scev_poly.
3277 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
3279 * tree-scalar-evolution.c (instantiate_scev_bitnot): New.
3280 (instantiate_scev_1): Move code in instantiate_scev_bitnot.
3282 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
3284 * tree-scalar-evolution.c (instantiate_scev_convert): New.
3285 (instantiate_scev_1): Move code in instantiate_scev_convert.
3287 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
3289 * tree-scalar-evolution.c (instantiate_scev_binary): New.
3290 (instantiate_scev_1): Move code in instantiate_scev_binary.
3292 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
3294 * tree-scalar-evolution.c (instantiate_scev_name): New.
3295 (instantiate_scev_1): Move code in instantiate_scev_name.
3297 2009-08-28 Sebastian Pop <sebastian.pop@amd.com>
3299 * Merge from mainline (150992:151171).
3301 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
3303 * opts.c (decode_options): Enable flag_loop_interchange at -O2.
3305 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
3307 * graphite-dependences.c (graphite_legal_transform_bb): Call
3308 pbb_remove_duplicate_pdrs.
3309 * graphite-poly.c (can_collapse_pdr): Removed.
3310 (pdr_find_duplicate): Removed.
3311 (can_collapse_pdrs): New.
3312 (pbb_remove_duplicate_pdrs): New.
3313 (new_poly_dr): Do not look for duplicates.
3314 * graphite-poly.h (struct poly_bb): New field pdr_duplicates_removed.
3315 (PBB_PDR_DUPLICATES_REMOVED): New.
3316 (pbb_remove_duplicate_pdrs): Declared.
3318 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
3320 * graphite-interchange.c (pbb_interchange_profitable_p): Adjust
3321 the strides by multiplying by PDR_NB_REFS.
3322 * graphite-poly.c (can_collapse_pdr): New.
3323 (pdr_find_duplicate): New.
3324 (new_poly_dr): Call pdr_find_duplicate. Collapse duplicate PDRs.
3325 Initialize PDR_NB_REFS.
3326 * graphite-poly.h (struct poly_dr): Add field nb_refs.
3328 (new_poly_dr): Number of subscripts is a graphite_dim_t.
3330 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
3332 Revert one of the previous commits:
3333 * graphite-dependences.c (graphite_legal_transform_bb): Avoid
3334 the computation of symmetric data dependence relations.
3335 (dependency_between_pbbs_p): Same.
3337 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
3340 * graphite-poly.c (apply_poly_transforms): Remove legality test before
3343 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
3345 * graphite-dependences.c (pddr_original_scattering): Return NULL
3346 for read-read dependence relations.
3347 * graphite-poly.h (enum poly_dr_type): Fix comment.
3350 (pdr_may_write_p): New.
3352 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
3354 * graphite-poly.h (enum POLY_DR_TYPE): Renamed poly_dr_type.
3355 (struct poly_dr): Same.
3356 (new_poly_dr): Same.
3357 * graphite-poly.c (new_poly_dr): Same.
3359 2009-08-25 Konrad Trifunovic <konrad.trifunovic@gmail.com>
3360 Sebastian Pop <sebastian.pop@amd.com>
3362 * graphite-blocking.c (pbb_strip_mine_loop_depth): Renamed
3363 pbb_strip_mine_time_depth. Changed the implementation so that
3364 transformation is expressed as a transformation on
3365 time (scatttering) dimensions. Also, ensures that the 2d+1
3366 scheduling format is preserved.
3367 (pbb_strip_mine_profitable_p): Profitability is based on the
3368 iteration number of a given time (scattering) dimension,
3369 and not on a original loop depth dimension.
3370 (pbb_strip_mine): Call pbb_number_of_iterations_at_time.
3371 (pbb_do_strip_mine): Call psct_dynamic_dim.
3372 * graphite-poly.c (pbb_number_of_iterations_at_time): New.
3373 * graphite-poly.h (pbb_number_of_iterations_at_time): Declared.
3374 (pbb_nb_dynamic_scattering_transform): New.
3375 (psct_dynamic_dim): New.
3377 2009-08-25 Konrad Trifunovic <konrad.trifunovic@gmail.com>
3379 * graphite-ppl.c (ppl_max_for_le): Renamed ppl_max_for_le_pointset.
3380 * graphite-ppl.h (ppl_max_for_le): Renamed ppl_max_for_le_pointset.
3381 * graphite-poly.c (pbb_number_of_iterations): Rename ppl_max_for_le.
3382 * graphite-interchange.c (build_linearized_memory_access): Same.
3383 (memory_stride_in_loop): Same.
3385 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
3387 * graphite-dependences.c (pddr_original_scattering): New.
3388 (graphite_legal_transform_dr): Call pddr_original_scattering.
3391 * graphite-dependences.h (dot_deps): Declared.
3392 * graphite-poly.c (new_poly_dr): Initialize PDR_ID.
3393 (print_pdr): Print PDR_ID.
3394 * graphite-poly.h (struct poly_dr): Add field id.
3397 * graphite-scop-detection.c (dot_all_scops_1): Cleanup comment.
3399 2009-08-22 Sebastian Pop <sebastian.pop@amd.com>
3401 * graphite-dependences.c (graphite_carried_dependence_level_k): Do
3402 not delete the original dependence relation.
3404 2009-08-21 Sebastian Pop <sebastian.pop@amd.com>
3406 * graphite-dependences.c (graphite_legal_transform_bb): Avoid
3407 the computation of symmetric data dependence relations.
3408 (dependency_between_pbbs_p): Same.
3410 2009-08-21 Sebastian Pop <sebastian.pop@amd.com>
3412 * graphite-dependences.c (new_poly_dr_pair): Renamed new_poly_ddr.
3413 (eq_poly_dr_pair_p): Renamed eq_poly_ddr_p.
3414 (hash_poly_dr_pair_p): Renamed hash_poly_ddr_p.
3415 (free_poly_ddr): New.
3416 (pddr_is_empty): New.
3417 (dependence_polyhedron_1): Now returns a poly_ddr_p.
3418 (dependence_polyhedron): Same. Remove useless gcc_assert.
3420 (graphite_legal_transform_dr): Call pddr_is_empty and free_poly_ddr.
3421 (graphite_carried_dependence_level_k): Call pddr_is_empty.
3422 * graphite-dependences.h (enum poly_dependence_kind): New.
3423 (poly_dr_pair): Renamed poly_ddr. Added a field kind.
3424 (PDRP_SOURCE): Renamed PDDR_SOURCE.
3425 (PDRP_SINK): Renamed PDDR_SINK.
3426 (PDRP_DDP): Renamed PDDR_DDP.
3428 (free_poly_ddr): Declared.
3429 * graphite-poly.c (new_scop): Use the new hash function names.
3430 * graphite-poly.h (struct scop): Renamed field original_pdr_pairs
3431 into original_pddrs.
3432 (SCOP_ORIGINAL_PDR_PAIRS): Renamed SCOP_ORIGINAL_PDDRS.
3434 2009-08-21 Sebastian Pop <sebastian.pop@amd.com>
3436 * Merge from mainline (150764:150992).
3438 2009-08-18 Sebastian Pop <sebastian.pop@amd.com>
3440 * cfgloopmanip.c (create_empty_loop_on_edge): Generate upper
3441 bounds with LT_EXPR to make niter analysis more precise on code
3442 generated by Graphite.
3444 2009-08-18 Sebastian Pop <sebastian.pop@amd.com>
3446 * graphite-dependences.c (graphite_legal_transform_dr): Fix formatting.
3447 (graphite_legal_transform_bb): Same.
3448 (poly_drs_may_alias_p): Same.
3450 2009-08-15 Sebastian Pop <sebastian.pop@amd.com>
3453 * graphite-ppl.c (ppl_max_for_le): Correct the use of
3454 ppl_Pointset_Powerset_C_Polyhedron_maximize.
3456 2009-08-13 Sebastian Pop <sebastian.pop@amd.com>
3458 * graphite-poly.c (print_pbb): Print PBB index.
3460 2009-08-13 Sebastian Pop <sebastian.pop@amd.com>
3462 * Merge from mainline (r150672:150764).
3464 2009-08-13 Sebastian Pop <sebastian.pop@amd.com>
3466 * graphite-interchange.c (ppl_max_for_le): Moved...
3467 * graphite-poly.c (pbb_number_of_iterations): Call ppl_max_for_le.
3468 * graphite-ppl.c (ppl_max_for_le): ... here.
3469 * graphite-ppl.h (ppl_max_for_le): Declared.
3471 2009-08-12 Sebastian Pop <sebastian.pop@amd.com>
3473 * Merge from mainline (r150372:150672).
3475 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
3478 * sese.c (convert_for_phi_arg): New.
3479 (add_guard_exit_phis): Use convert_for_phi_arg.
3481 * gfortran.dg/graphite/id-17.f: New.
3483 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
3485 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Dont add
3486 unknown subscript upper bounds.
3488 * gcc.dg/graphite/interchange-6.c: Un-XFAIL.
3490 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
3491 Pranav Garg <pranav.garg2107@gmail.com>
3493 * graphite-interchange.c (gather_access_strides): Removed.
3494 (ppl_max_for_le): New.
3495 (build_linearized_memory_access): New.
3496 (memory_stride_in_loop): New.
3497 (pbb_interchange_profitable_p): Reimplemented.
3498 * graphite-ppl.h (ppl_new_id_map): New.
3499 (ppl_interchange): New.
3501 * gcc.dg/graphite/interchange-6.c: XFAILed.
3503 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
3505 * graphite-interchange.c (compute_subscript): Removed.
3506 (compute_array_size_cstr): Removed.
3507 (compute_array_size_poly): Removed.
3508 (compute_array_size): Removed.
3509 (gather_access_strides_poly): Removed.
3510 (gather_access_strides): Empty.
3512 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
3514 * graphite-dependences.c (dependence_polyhedron_1): Replace
3515 pdr_nb_subscripts with PDR_NB_SUBSCRIPTS.
3516 (graphite_legal_transform_dr): Same.
3517 (graphite_carried_dependence_level_k): Same.
3518 * graphite-poly.c (new_poly_dr): Add a parameter nb_subscripts.
3519 Initialize PDR_NB_SUBSCRIPTS.
3520 (print_pdr_access_layout): Replace pdr_nb_subscripts with
3522 * graphite-poly.h (struct poly_dr): Add nb_subscripts field.
3523 (PDR_NB_SUBSCRIPTS): New.
3524 (pdr_nb_subscripts): Removed.
3525 (pdr_dim): Simplified.
3526 * graphite-sese-to-poly.c (build_poly_dr): Replace pdr_nb_subscripts
3527 with PDR_NB_SUBSCRIPTS.
3529 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
3531 * graphite-interchange.c (compute_array_size): Remove use of
3533 * graphite-poly.c (new_poly_dr): Remove argument data_container.
3534 Do not initialize PDR_DATA_CONTAINER.
3535 (print_pdr): Do not print PDR_DATA_CONTAINER.
3536 * graphite-poly.h (struct poly_dr): Remove data_container field.
3537 (PDR_DATA_CONTAINER): Removed.
3538 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Remove use of
3540 (build_poly_dr): Same.
3542 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
3544 * gcc.dg/graphite/interchange-9.c: New.
3546 2009-08-05 Konrad Trifunovic <konrad.trifunovic@gmail.com>
3547 Sebastian Pop <sebastian.pop@amd.com>
3549 * graphite-dependences.c (graphite_legal_transform_dr): Work on a
3550 copy of the dependence polyhedron. Free the temporary objects.
3551 (graphite_carried_dependence_level_k): Free unused objects before
3554 * gcc.dg/graphite/interchange-1.c: XFAILed.
3555 * gcc.dg/graphite/interchange-2.c: XFAILed.
3556 * gcc.dg/graphite/interchange-3.c: XFAILed.
3557 * gcc.dg/graphite/interchange-4.c: XFAILed.
3558 * gcc.dg/graphite/interchange-7.c: XFAILed.
3560 2009-08-05 Sebastian Pop <sebastian.pop@amd.com>
3562 * graphite-blocking.c (scop_do_strip_mine): Call store_scattering.
3563 Early return without analyzing the data dependences if no
3564 transform has been done. Call restore_scattering if the transform
3566 (graphite-interchange.c): Same.
3567 * graphite-poly.c (print_scattering_function): Test for PBB_TRANSFORMED.
3568 (graphite_read_transforms): Initialize PBB_TRANSFORMED.
3569 (apply_poly_transforms): Do not gcc_assert that
3570 the transform is legal.
3571 (new_poly_bb): Initialize PBB_TRANSFORMED, PBB_SAVED, and PBB_ORIGINAL.
3572 Do not initialize PBB_NB_SCATTERING_TRANSFORM, PBB_NB_LOCAL_VARIABLES,
3573 PBB_TRANSFORMED_SCATTERING, and PBB_ORIGINAL_SCATTERING.
3574 (free_poly_dr): Free PBB_TRANSFORMED, PBB_SAVED, and PBB_ORIGINAL.
3575 * graphite-poly.h (struct poly_scattering): New.
3576 (struct poly_bb): Add original, transformed, and saved fields.
3577 Remove transformed_scattering, original_scattering, nb_local_variables,
3578 and nb_scattering_transform fields.
3579 (PBB_ORIGINAL, PBB_TRANSFORMED, PBB_SAVED): New.
3580 (poly_scattering_new): New.
3581 (poly_scattering_free): New.
3582 (poly_scattering_copy): New.
3583 (store_scattering_pbb): New.
3584 (store_scattering): New.
3585 (restore_scattering_pbb): New.
3586 (restore_scattering): New.
3587 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons):
3588 Initialize PBB_TRANSFORMED and PBB_ORIGINAL.
3590 2009-08-05 Sebastian Pop <sebastian.pop@amd.com>
3592 * graphite-poly.c (print_pbb): Add parentheses in the pretty print.
3595 2009-08-05 Sebastian Pop <sebastian.pop@amd.com>
3597 * Makefile.in (graphite.o): Depends on PREDICT_H.
3598 * graphite.c: Include predict.h.
3599 (graphite_finalize): Call tree_estimate_probability.
3600 * predict.c (predict_loops): Do not call scev_initialize and
3602 (tree_estimate_probability_bb): New.
3603 (tree_estimate_probability): Do not initialize loops: move that
3604 code to the driver. Call tree_estimate_probability_bb.
3605 (tree_estimate_probability_driver): New.
3606 (pass_profile): Use tree_estimate_probability_driver.
3607 * predict.h (tree_estimate_probability): Declared.
3609 2009-08-05 Sebastian Pop <sebastian.pop@amd.com>
3611 * graphite-clast-to-gimple.c (gloog): Add time to TV_GRAPHITE_CODE_GEN.
3612 * graphite-dependences.c (graphite_legal_transform): Add time to
3613 TV_GRAPHITE_DATA_DEPS.
3614 (dependency_between_pbbs_p): Same.
3615 * timevar.def (TV_GRAPHITE_DATA_DEPS, TV_GRAPHITE_CODE_GEN): New.
3617 2009-08-03 Sebastian Pop <sebastian.pop@amd.com>
3619 * Merge from mainline (r149952:150372).
3621 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
3623 * ChangeLog.graphite: Fix indenting, white spaces and 80 columns.
3624 * graphite-blocking.c: Same.
3625 * graphite-clast-to-gimple.c: Same.
3626 * graphite-dependences.c: Same.
3627 * graphite-poly.c: Same.
3628 * graphite-poly.h: Same.
3629 * graphite-ppl.c: Same.
3630 * graphite-scop-detection.c: Same.
3631 * graphite-sese-to-poly.c: Same.
3634 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
3636 * graphite-sese-to-poly.c (loop_entry_phi_arg): New.
3637 (remove_simple_copy_phi): New.
3638 (remove_invariant_phi): New.
3639 (simple_copy_phi_p): New.
3640 (reduction_phi_p): New.
3641 (gsi_for_ssa_name_def): New.
3642 (insert_out_of_ssa_copy): New.
3643 (insert_out_of_ssa_copy_on_edge): New.
3644 (create_zero_dim_array): New.
3645 (scalar_close_phi_node_p): New.
3646 (rewrite_close_phi_out_of_ssa): New.
3647 (rewrite_phi_out_of_ssa): New.
3648 (rewrite_reductions_out_of_ssa): New.
3649 (build_poly_scop): Call rewrite_reductions_out_of_ssa.
3651 * gcc.dg/graphite/id-11.c: New.
3652 * gcc.dg/graphite/id-15.c: New.
3653 * gcc.dg/graphite/interchange-1.c: Un-XFAIL.
3654 * gcc.dg/graphite/interchange-2.c: Un-XFAIL.
3655 * gcc.dg/graphite/interchange-3.c: Un-XFAIL.
3656 * gcc.dg/graphite/interchange-4.c: Un-XFAIL.
3657 * gcc.dg/graphite/interchange-7.c: Un-XFAIL.
3658 * gcc.dg/graphite/scop-matmult.c: Un-XFAIL.
3659 * gfortran.dg/graphite/id-13.f: New.
3660 * gfortran.dg/graphite/id-5.f: New.
3662 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
3664 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not
3665 check that nb_reductions_in_loop is zero.
3666 * graphite-scop-detection.c (harmful_stmt_in_bb): Don't filter out
3667 reduction phi nodes.
3668 (nb_reductions_in_loop): Removed.
3669 (graphite_can_represent_loop): Do not call nb_reductions_in_loop.
3670 * graphite-sese-to-poly.c (phi_node_is_iv): Removed.
3671 (bb_contains_non_iv_scalar_phi_nodes): Removed.
3672 (scop_contains_non_iv_scalar_phi_nodes): Removed.
3673 (build_poly_scop): Do not call scop_contains_non_iv_scalar_phi_nodes.
3675 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
3677 * graphite-clast-to-gimple.c (build_cloog_prog): Do not code generate
3678 statements that have an empty iteration domain.
3679 * gfortran.dg/graphite/id-16.f: New.
3681 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
3683 * tree-scalar-evolution.c (instantiate_scev_1): Return
3684 chrec_dont_know when the result is not above instantiate_below.
3685 * graphite-scop-detection.c (scopdet_basic_block_info): Fix formatting.
3686 * graphite-sese-to-poly.c (create_linear_expr_from_tree): Assert that
3687 the tree has a known scalar evolution.
3688 * gfortran.dg/graphite/id-14.f: New.
3689 * gfortran.dg/graphite/id-15.f: New.
3691 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
3693 * sese.c (rename_variables_in_stmt): Pass in an extra parameter
3695 (rename_variables): Keep inserting renames after the ones already
3698 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
3700 * graphite-sese-to-poly.c (compare_bb_depths): New.
3701 (graphite_sort_dominated_info): New.
3702 (build_scop_bbs_1): Call graphite_sort_dominated_info.
3703 (build_scop_scattering): Fix comment.
3705 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
3707 * graphite.c (graphite_finalize): Call print_loops instead of
3708 dump_function_to_file.
3709 * gcc.dg/graphite/graphite.exp: Fix formatting.
3710 * gcc.dg/graphite/pr35356-1.c: New. Look for the number of
3711 loops generated in the graphite output file.
3712 * gcc.dg/graphite/pr35356-2.c: New.
3713 * gcc.dg/graphite/pr35356-3.c: New. XFAILed for now.
3714 * gfortran.dg/graphite/id-12.f: New.
3716 2009-07-24 Li Feng <nemokingdom@gmail.com>
3718 * gcc.dg/graphite/graphite_autopar/force-parallel-8.c:
3721 2009-07-24 Li Feng <nemokingdom@gmail.com>
3722 Tobias Grosser <grosser@fim.uni-passau.de>
3724 * graphite-sese-to-poly.c (pdr_add_alias_set): Use data reference's
3725 alias set number build alias in ACCESSES polyhedron.
3726 (build_alias_set_for_drs): New.
3727 (build_pbb_drs): Added build_alias_set_for_drs.
3728 * graphite-dependences.c (poly_drs_may_alias_p): New.
3729 (graphite_carried_dependence_level_k): Check alias information
3730 before building polyhedron.
3732 2009-07-24 Tobias Grosser <grosser@fim.uni-passau.de>
3734 * Makefile.in (lambda-code.o): Fix formatting.
3736 2009-07-24 Tobias Grosser <grosser@fim.uni-passau.de>
3738 * Merge from mainline (r149350-149952)
3740 2009-07-18 Tobias Grosser <grosser@fim.uni-passau.de>
3742 * graphite-poly.c (apply_poly_transforms): Move strip_mine
3743 before interchange to prepare for loop blocking.
3745 2009-07-18 Tobias Grosser <grosser@fim.uni-passau.de>
3747 * graphite-poly.c (apply_poly_transforms): Add checks after every
3749 * graphite-sese-to-poly.c (build_poly_scop): Remove check, as already
3750 done in apply_poly_transforms.
3752 2009-07-17 Konrad Trifunovic <konrad.trifunovic@gmail.com>
3754 * graphite-dependences.c (build_lexicographically_gt_constraint):
3755 Replace RES parameter with *RES.
3756 (dependence_polyhedron_1): Pass an address of the parameter RES
3757 instead of value of RES.
3759 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
3761 * graphite.c (graphite_finalize): Fix comment.
3762 (graphite_transform_loops): Reset scev info after code generation
3765 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
3767 * graphite.c (graphite_finalize): Call scev_reset.
3769 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
3771 * graphite-clast-to-gimple.c (compute_cloog_iv_types): Do not create
3772 GBB_CLOOG_IV_TYPES hash table twice.
3773 * graphite-sese-to-poly.c (free_gimple_bb): Call free_data_refs.
3774 (add_condition_to_domain): Clear GMP values.
3776 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
3778 * graphite-dependences.c: Fix formatting.
3779 * graphite-poly.c (free_poly_dr): Also free PDR_DATA_CONTAINER.
3780 (pbb_number_of_iterations): Free ppl_Linear_Expression.
3781 * graphite-sese-to-poly.c: Fix formatting.
3782 * graphite.c (graphite_transform_loops): Create the hash table
3783 after the early return.
3785 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
3787 * gcc.dg/graphite/id-14.c: New.
3788 * gcc.dg/graphite/pr40157.c: New.
3789 * gfortran.dg/graphite/id-11.f: New.
3791 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
3793 * graphite-sese-to-poly.c (nb_pbbs_in_loops): New.
3794 (build_poly_scop): Return false when there are no pbbs within
3795 loops to avoid to pass to cloog scops with no loops.
3797 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
3799 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons): Avoid
3800 useless test "i % 2".
3801 (build_pbb_scattering_polyhedrons): Fix formatting.
3802 (build_poly_dr): Same.
3803 * graphite.c (graphite_transform_loops): Restructure.
3805 2009-07-14 Razya Ladelsky <razya@il.ibm.com>
3807 * tree-ssa-loop-manip.c (rewrite_phi_with_iv): Remove
3808 reduction_list parameter.
3809 (rewrite_all_phi_nodes_with_iv): Same.
3810 (canonicalize_loop_ivs): Same.
3811 * tree-parloops.c (struct brli): Removed.
3812 (build_reduction_list_info): Removed.
3813 (build_new_reduction): New.
3814 (analyze_reduction_list): Removed.
3815 (gather_scalar_reductions): Find reductions instead of phi
3816 nodes that can't be canonicalized.
3817 (try_create_reduction_list): Remove reduction_list parameter.
3818 (gen_parallel_loop): Same.
3819 (parallelize_loops): Remove analyze_reductions variable,
3820 initialization and free.
3821 Change reduction_list htab initialization to reduction_info
3822 elements instead of ssa names.
3823 Call try_create_reduction_list and gen_parallel_loop without
3824 analyzed_reduction argument.
3825 * graphite-clast-to-gimple (graphite_loop_normal_form): Call
3826 canonicalize_loop_ivs with one less argument.
3827 * tree-flow.h (canonicalize_loop_ivs): Remove one argument.
3829 2009-07-14 Konrad Trifunovic <konrad.trifunovic@gmail.com>
3831 * graphite-dependences.c (new_poly_dr_pair): New.
3832 (dependence_polyhedron): Renamed into dependence_polyhedron_1.
3833 (new_poly_dr_pair): New.
3834 (eq_poly_dr_pair_p): New.
3835 (hash_poly_dr_pair_p): New.
3836 * graphite-dependences.h (struct poly_dr_pair): New.
3837 (eq_poly_dr_pair_p): Declared.
3838 (hash_poly_dr_pair_p): Declared.
3839 * graphite-poly.c (new_scop): Initialize SCOP_ORIGINAL_PDR_PAIRS.
3840 (free_scop): Free SCOP_ORIGINAL_PDR_PAIRS.
3841 * graphite-poly.h (struct scop): Add original_pdr_pairs field.
3842 * Makefile.in (graphite-poly.o): Add dependence on
3843 graphite-dependences.h.
3845 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
3847 * graphite-scop-detection.c (graphite_can_represent_scev): Do not let
3848 polynomials of degree > 1 pass to Graphite.
3849 * tree-chrec.c (scev_is_linear_expression): Call
3850 evolution_function_is_affine_multivariate_p.
3851 * gfortran.dg/graphite/id-10.f90: New.
3853 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
3855 * tree-scalar-evolution.c (compute_overall_effect_of_inner_loop):
3856 Instantiate scevs varying in outer loops.
3857 * gfortran.dg/graphite/id-9.f: Correct testcase.
3859 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
3861 * graphite-sese-to-poly.c (build_loop_iteration_domains): Do not insert
3862 redundant constraint.
3864 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
3866 * gcc.dg/graphite/graphite.exp: Fix comments.
3867 * gfortran.dg/graphite/graphite.exp: Trigger actions
3868 based on the file names as in the C testsuite.
3869 * gfortran.dg/graphite/block-1.f90: Fix patterns.
3870 * gfortran.dg/graphite/block-2.f: Same.
3871 * gfortran.dg/graphite/block-3.f90: Same.
3872 * gfortran.dg/graphite/block-4.f90: Same.
3873 * gfortran.dg/graphite/id-1.f90: Same.
3874 * gfortran.dg/graphite/id-2.f90: Same.
3875 * gfortran.dg/graphite/id-3.f90: Same.
3876 * gfortran.dg/graphite/id-4.f90: Same.
3877 * gfortran.dg/graphite/id-6.f: Same.
3878 * gfortran.dg/graphite/id-9.f: Same.
3879 * gfortran.dg/graphite/interchange-1.f: Same.
3880 * gfortran.dg/graphite/interchange-2.f: Same.
3881 * gfortran.dg/graphite/scop-1.f: Same.
3883 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
3885 * sese.c (expand_scalar_variables_call): New.
3886 (expand_scalar_variables_ssa_name): Handle calls in expander.
3888 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
3890 * gcc.dg/graphite/graphite_autopar/force-parallel-6.c:
3891 Expect to see the pattern twice.
3892 * gcc.dg/graphite/interchange-0.c: Un-XFAIL.
3893 * gcc.dg/graphite/interchange-5.c: Same.
3894 * gcc.dg/graphite/interchange-6.c: Same.
3896 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
3898 * gcc.dg/graphite/id-10.c: New.
3899 * gcc.dg/graphite/id-12.c: New.
3900 * gfortran.dg/graphite/id-7.f: New.
3901 * gfortran.dg/graphite/id-8.f: New.
3903 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
3905 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Fix division by
3908 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
3910 * sese.c (rename_variables_in_stmt): Call fold_convert during renaming.
3912 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
3914 * sese.c (expand_scalar_variables_stmt): Avoid unnecessary expansion.
3916 2009-07-10 Sebastian Pop <sebastian.pop@amd.com>
3918 * graphite-sese-to-poly.c (pdr_add_memory_accesses): Fix order of
3919 building PDR subscripts.
3921 2009-07-10 Sebastian Pop <sebastian.pop@amd.com>
3923 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Fix the
3924 computation of array sizes.
3926 2009-07-10 Sebastian Pop <sebastian.pop@amd.com>
3928 * graphite-sese-to-poly.c (add_param_constraints): Disabled.
3930 2009-07-10 Tobias Grosser <grosser@fim.uni-passau.de>
3932 * graphite-dependences.c (map_into_dep_poly, map_dr_into_dep_poly,
3933 build_pairwise_constraint, dr_equality_constraints,
3934 build_pairwise_scheduling_equality,
3935 build_pairwise_scheduling_inequality, lexicographically_gt_p,
3936 build_lexicographically_gt_constraint, dependence_polyhedron,
3937 graphite_legal_transform_dr, graphite_carried_dependence_level_k):
3938 Move from NNC_Polyhedron to C_Polyhedron.
3939 * graphite-interchange.c (compute_array_size_poly,
3940 gather_access_strides): Dito.
3941 * graphite-poly.c (apply_poly_transforms, new_poly_dr, free_poly_bb,
3942 free_scop, pbb_number_of_iterations): Dito.
3943 * graphite-poly.h (struct poly_dr, pdr_nb_subscripts, struct poly_bb,
3944 pbb_dim_iter_domain, struct scop): Dito.
3945 * graphite-ppl.c (new_Constraint_System_from_Cloog_Matrix,
3946 new_Cloog_Domain_from_ppl_Polyhedron,
3947 new_Cloog_Domain_from_ppl_Pointset_Powerset, ppl_set_coef_gmp,
3948 ppl_insert_dimensions_pointset, ppl_insert_dimensions_pointset,
3949 ppl_strip_loop, ppl_strip_loop, ppl_print_polyhedron_matrix,
3950 ppl_print_powerset_matrix, debug_ppl_polyhedron_matrix,
3951 debug_ppl_powerset_matrix, ppl_read_polyhedron_matrix): Dito.
3952 * graphite-ppl.h (ppl_Pointset_Powerset_C_Polyhedron_t,
3953 new_C_Polyhedron_from_Cloog_Matrix, ppl_print_powerset_matrix,
3954 debug_ppl_powerset_matrix, ppl_insert_dimensions_pointset): Dito.
3955 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons,
3956 build_loop_iteration_domains, ppl_constraint_type_from_tree_code,
3957 add_condition_to_domain, add_condition_to_pbb, build_scop_context,
3958 build_scop_iteration_domain, build_poly_dr): Dito
3960 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
3962 * gcc.dg/graphite/graphite.exp: Added a rule to execute
3964 * gcc.dg/graphite/run-id-1.c: New.
3966 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
3968 * graphite-sese-to-poly.c (build_loop_iteration_domains): Add the
3969 positivity constraint on the symbolic number of iterations.
3971 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
3973 * graphite-sese-to-poly.c (build_loop_iteration_domains): Rewrite.
3975 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
3976 Tobias Grosser <grosser@fim.uni-passau.de>
3978 * graphite-clast-to-gimple.c (build_scop_context): Removed.
3979 (build_cloog_prog): Directly use SCOP_CONTEXT.
3980 * graphite-poly.c (new_scop): Initialize SCOP_CONTEXT.
3981 (free_scop): Free SCOP_CONTEXT.
3982 (print_scop_context): New.
3983 (print_scop): Call print_scop_context.
3984 (debug_scop_context): New.
3985 * graphite-poly.h (print_scop_context, debug_scop_context): Declared.
3986 (struct scop): Added field context.
3987 (SCOP_CONTEXT): New.
3988 * graphite-sese-to-poly.c (add_param_constraints): New.
3989 (build_scop_context): New.
3990 (build_poly_scop): Call build_scop_context.
3992 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
3994 * graphite-clast-to-gimple.c (gmp_cst_to_tree): Moved...
3995 * graphite-ppl.c (ppl_set_inhomogeneous_gmp, ppl_set_coef_gmp): New.
3996 (ppl_set_inhomogeneous, ppl_set_coef): Moved...
3997 * graphite-ppl.h: Include double-int.h and tree.h.
3998 (ppl_set_inhomogeneous_gmp, ppl_set_coef_gmp): Declared.
3999 (ppl_set_inhomogeneous, ppl_set_coef): ...here.
4000 (gmp_cst_to_tree): ...here. Reimplemented using mpz_get_double_int.
4001 (tree_int_to_gmp, ppl_set_inhomogeneous_tree, ppl_set_coef_tree): New.
4003 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
4005 * graphite-clast-to-gimple.c (clast_to_gcc_expression_red): Generate
4006 POINTER_PLUS_EXPR for pointer types.
4007 (clast_to_gcc_expression): Same.
4009 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
4011 * graphite-poly.c (print_scattering_function): Early return when
4012 PBB_TRANSFORMED_SCATTERING is not initialized.
4013 (print_pbb_domain): Early return when PBB_DOMAIN is not initialized.
4015 2009-07-08 Sebastian Pop <sebastian.pop@amd.com>
4017 * tree-parloops.c (analyze_reduction_list): Remove unused variable
4020 2009-07-08 Razya Ladelsky <razya@il.ibm.com>
4022 * tree-parloops.c (analyze_reduction_list): Change return
4024 (try_create_reduction_list): Move the call to
4025 analyze_reduction_list to the beginining.
4026 Call reduction_phi with analyzed_reductions as argument
4027 instead of reduction_list.
4029 2009-07-08 Tobias Grosser <grosser@fim.uni-passau.de>
4031 * Merge from mainline (r148296:149346)
4033 2009-07-07 Sebastian Pop <sebastian.pop@amd.com>
4035 * graphite-scop-detection.c (graphite_can_represent_init): New.
4036 (graphite_can_represent_scev): Call graphite_can_represent_init:
4037 check that the initial value does not contain multiplications of
4039 (stmt_has_simple_data_refs_p): New.
4040 (stmt_simple_for_scop_p): Call stmt_simple_for_scop_p.
4041 (is_simple_operand): Fix formatting.
4042 * graphite-sese-to-poly.c (try_generate_gimple_bb): Fix formatting.
4044 2009-07-07 Sebastian Pop <sebastian.pop@amd.com>
4046 * gcc.dg/graphite/id-13.c: New.
4047 * graphite-sese-to-poly.c (graphite_stmt_p): Do not call
4048 analyze_scalar_evolution, use scalar_evolution_in_region.
4049 (scan_tree_for_params_right_scev): Add extra assert.
4050 (parameter_index_in_region_1): Split from parameter_index_in_region.
4051 (idx_record_params): Use scalar_evolution_in_region.
4052 (find_params_in_bb): Same.
4053 (find_scop_parameters): Same.
4054 (build_loop_iteration_domains): Same.
4055 (create_linear_expr_from_tree): Same.
4056 * sese.c (scalar_evolution_in_region): New.
4057 * sese.h (scalar_evolution_in_region): Declared.
4058 (defined_in_sese_p): New.
4059 * tree-scalar-evolution.c (compute_overall_effect_of_inner_loop): Not
4061 * tree-scalar-evolution.h (compute_overall_effect_of_inner_loop):
4064 2009-07-07 Sebastian Pop <sebastian.pop@amd.com>
4066 * Makefile.in: Replace dependences on tree-chrec.h with SCEV_H.
4067 TREE_DATA_REF_H also implies SCEV_H.
4069 2009-07-07 Sebastian Pop <sebastian.pop@amd.com>
4071 * graphite-poly.c (print_scop_params): New.
4072 (print_scop): Call print_scop_params.
4073 (debug_scop_params): New.
4074 * graphite-poly.h (print_scop_params, debug_scop_params): Declared.
4076 2009-07-07 Li Feng <nemokingdom@gmail.com>
4078 * gcc.dg/graphite/graphite_autopar/force-parallel-4.c: New.
4079 * gcc.dg/graphite/graphite_autopar/force-parallel-5.c: New.
4080 * gcc.dg/graphite/graphite_autopar/force-parallel-6.c: New.
4081 * gcc.dg/graphite/graphite_autopar/force-parallel-7.c: New.
4082 * gcc.dg/graphite/graphite_autopar/force-parallel-8.c: New.
4083 * gcc.dg/graphite/graphite_autopar/force-parallel-9.c: New.
4085 2009-07-07 Li Feng <nemokingdom@gmail.com>
4087 * graphite-clast-to-gimple.c (mark_loops_parallel): Dump information
4088 for dependency checking part.
4089 * gcc.dg/graphite/graphite_autopar/force-parallel-1.c: Add
4090 tests for dependency checking.
4091 * gcc.dg/graphite/graphite_autopar/force-parallel-2.c: Ditto.
4092 * gcc.dg/graphite/graphite_autopar/force-parallel-3.c: Ditto.
4093 * gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: Add
4094 flag -fdump-tree-graphite-all for autopar testsuites.
4096 2009-07-06 Sebastian Pop <sebastian.pop@amd.com>
4098 * Makefile.in (tree-ssa-loop-manip.o): Depends on langhooks.h.
4099 * tree-parloops.c (rewrite_phi_with_iv, rewrite_all_phi_nodes_with_iv,
4100 canonicalize_loop_ivs): Moved...
4101 * tree-ssa-loop-manip.c: ... here. Include langhooks.h.
4103 2009-07-06 Sebastian Pop <sebastian.pop@amd.com>
4105 * tree-parloops.c (try_create_reduction_list): Pass an extra
4106 argument analyzed_reductions. Call analyze_reduction_list.
4107 (gen_parallel_loop): Do not call analyze_reduction_list.
4108 (parallelize_loops): Init and finalize analyzed_reductions.
4110 2009-07-06 Li Feng <nemokingdom@gmail.com>
4112 * gcc.dg/graphite/graphite_autopar/graphite_autopar.exp:
4113 Added flag -fno-loop-strip-mine for autopar testcase.
4115 2009-07-04 Li Feng <nemokingdom@gmail.com>
4117 * graphite-dependences.c (graphite_carried_dependence_level_k): Use
4118 transformed scattering dimension instead of unmatch orignal when
4119 calling dependence_polyhedron.
4121 2009-06-30 Sebastian Pop <sebastian.pop@amd.com>
4123 * opts.c (decode_options): Enable flag_loop_strip_mine at -O2.
4125 2009-06-30 Sebastian Pop <sebastian.pop@amd.com>
4127 * graphite-poly.c (pbb_number_of_iterations): Check for returned
4128 value 1 from ppl_Pointset_Powerset_NNC_Polyhedron_maximize.
4130 2009-06-30 Sebastian Pop <sebastian.pop@amd.com>
4132 * graphite-blocking.c (pbb_strip_mine_profitable_p): New.
4133 (pbb_do_strip_mine): Call pbb_strip_mine_profitable_p.
4134 * graphite-poly.c (pbb_number_of_iterations): New.
4135 * graphite-poly.h (pbb_number_of_iterations): Declared.
4136 (pbb_iterator_dim, pbb_parameter_dim): New.
4138 2009-06-29 Sebastian Pop <sebastian.pop@amd.com>
4140 * graphite-clast-to-gimple.c (graphite_create_new_loop): Revert the
4141 last commit on type of lower and upper bound of loops.
4143 2009-06-29 Li Feng <nemokingdom@gmail.com>
4145 * Makefile.in (graphite-clast-to-gimple.o): Added dependence on
4146 graphite-dependences.h.
4147 * graphite-clast-to-gimple.c (new_bb_pbb_def): New.
4148 (mark_bb_with_pbb): New.
4149 (get_stmtfor_depth): New.
4150 (find_pbb_via_hash): New.
4151 (dependency_in_loop_p): New.
4152 (mark_loops_parallel): New.
4153 (free_aux_in_new_loops): New.
4154 (translate_clast): Add parameter BB_PBB_MAPPING. Mark newly created
4155 bb with it's relevant pbb. Mark newly created loops. Remove mark
4156 innermost loop parallel without checking.
4157 (gloog): Add parameter BB_PBB_MAPPING.
4158 * graphite-clast-to-gimple.h (struct bb_pbb_def): New.
4159 (gloog): Change declaration.
4160 (mark_loop_parallel): Make extern.
4161 (free_aux_in_new_loops): Declare.
4162 (bb_pbb_map_hash): New.
4163 (eq_bb_pbb_map): New.
4164 * graphite.c (graphite_transform_loops): Added BB_PBB_MAPPING. Trigger
4165 auto parallelization when flag_graphite_force_parallel is set.
4166 (graphite_finalize): Added free_aux_in_new_loops.
4167 * tree-parloops.c (parallelize_loops): Only generate parallel code for
4168 the innermost loop that marked parallel. Use
4169 flag_graphite_force_parallel instead of loop->can_be_parallel.
4170 (loop_parallel_p): Move inner most checking out of function.
4172 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
4174 * graphite-clast-to-gimple.c (graphite_create_new_loop): Make the
4175 type of lower and upper bound of loops signed long int.
4177 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
4179 * cfgloopmanip.c (create_empty_loop_on_edge): Gimplify the loop exit
4180 expression outside the loop.
4182 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
4184 * gcc.dg/graphite/interchange-8.c: New.
4186 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
4188 * gcc.dg/graphite/interchange-0.c: XFailed.
4189 * gcc.dg/graphite/interchange-5.c: XFailed.
4190 * gcc.dg/graphite/interchange-6.c: XFailed.
4192 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
4194 * graphite-interchange.c (compute_array_size_poly): The end of the
4195 recursion should return 1.
4197 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
4199 * graphite-interchange.c (compute_array_size_cstr): Allow the
4200 subscript multiplier to be -1.
4201 (compute_array_size): Use PDR_DATA_CONTAINER and not PDR_ACCESSES.
4202 * graphite-poly.c (new_poly_dr): Takes an extra argument for the
4203 data_container. Initializes PDR_DATA_CONTAINER.
4204 (print_pdr_access_layout): New.
4205 (print_pdr): Call print_pdr_access_layout. Print PDR_DATA_CONTAINER.
4206 * graphite-poly.h (struct poly_dr): Adjust comment. Add a new field
4208 (PDR_DATA_CONTAINER): New.
4209 (new_poly_dr): Update declaration.
4210 * graphite-sese-to-poly.c (pdr_add_data_dimensions): New.
4211 (build_poly_dr): Call pdr_add_data_dimensions.
4213 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
4215 * graphite-poly.h (struct poly_dr): Fix comment.
4216 * graphite-sese-to-poly.c (pdr_add_alias_set): New.
4217 (pdr_add_memory_accesses): New.
4218 (build_poly_dr): Call pdr_add_memory_accesses and pdr_add_alias_set.
4220 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
4222 * graphite-poly.c (print_pdrs, debug_pdrs): New.
4223 (print_pbb): Add call to print_pdrs.
4224 * graphite-poly.h (print_pdrs, debug_pdrs): Declared.
4226 2009-06-24 Konrad Trifunovic <konrad.trifunovic@gmail.com>
4227 Li Feng <nemokingdom@gmail.com>
4229 * graphite-dependences.c (graphite_carried_dependence_level_k): New.
4230 (dependency_between_pbbs_p): New.
4231 (lexicographically_gt_p): Assure !empty_p before polyhedron
4232 intersection assign.
4233 (build_lexicographically_gt_constraint): Correct lexicographically
4235 * graphite-dependences.h: New.
4236 * Makefile.in (graphite-dependences.o): Add graphite-dependences.h.
4238 2009-06-24 Sebastian Pop <sebastian.pop@amd.com>
4240 * graphite-clast-to-gimple.c (print_clast_stmt): New.
4241 (gloog): Print to dump_file the generated clast.
4242 * graphite-clast-to-gimple.h (print_clast_stmt): Declared.
4243 * graphite-interchange.c (pbb_do_interchange): Fix dump formatting.
4245 2009-06-24 Sebastian Pop <sebastian.pop@amd.com>
4247 * graphite-poly.c (extend_scattering): Increment
4248 PBB_NB_LOCAL_VARIABLES by the number of added dimensions.
4250 2009-06-24 Sebastian Pop <sebastian.pop@amd.com>
4252 * graphite-interchange.c (compute_array_size_poly): Added exit of
4253 recursion condition. Continue iterating even after the first equality.
4254 (compute_array_size): Same.
4256 2009-06-24 Li Feng <nemokingdom@gmail.com>
4258 * gcc.dg/graphite/graphite_autopar/force-parallel-1.c: Update
4259 -fdump-tree-final_cleanup to -fdump-tree-optimized.
4260 * gcc.dg/graphite/graphite_autopar/force-parallel-2.c: Ditto.
4261 * gcc.dg/graphite/graphite_autopar/force-parallel-3.c: Ditto.
4262 * gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: Ditto.
4264 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
4266 * sese.c (expand_scalar_variables_stmt): Expand scalar variables
4267 only when the use verifies is_gimple_reg.
4269 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
4271 * graphite-clast-to-gimple.c (build_cloog_prog): Fix memory corruption.
4272 Allocate scaldims after call to unify_scattering_dimensions.
4274 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
4276 * graphite-clast-to-gimple.c (translate_clast): Fix memory leak.
4278 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
4279 Albert Cohen <albert.cohen@inria.fr>
4281 * graphite-blocking.c (pbb_strip_mine_loop_depth): Do not use local
4282 variables for the strip mining.
4284 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
4285 Pranav Garg <pranav.garg2107@gmail.com>
4287 * Makefile.in (OBJS-common): Added graphite-blocking.o.
4288 (graphite-sese-to-poly.o): Moved down to be in lexicographical order.
4289 (graphite-blocking.o): New rule.
4290 (graphite-poly.o, graphite-ppl.o): Moved to be in lexicographical order.
4291 * graphite-blocking.c: New.
4292 * graphite-poly.c (apply_poly_transforms): Call scop_do_strip_mine for
4293 flag_loop_strip_mine.
4294 (psct_scattering_dim_for_loop_depth): New.
4295 * graphite-poly.h (scop_do_strip_mine): Declared.
4296 (psct_add_local_variable): Increment PBB_NB_LOCAL_VARIABLES.
4297 * tree-ssa-loop.c (gate_graphite_transforms): Do not fail when using
4298 flag_loop_strip_mine.
4300 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
4302 * graphite-poly.c (extend_scattering): Avoid initializing and freeing
4303 a GMP value and a PPL coefficient at each iteration of a loop.
4305 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
4307 * graphite-dependences.c (dependence_polyhedron): Do not use
4308 pbb_nb_scattering_dims anymore. Use pbb_nb_scattering_orig and
4309 pbb_nb_scattering_transform.
4310 (graphite_legal_transform_dr): Same.
4311 * graphite-poly.c (extend_scattering): Same.
4312 (unify_scattering_dimensions): Same.
4313 (print_scattering_function): Same.
4314 (new_poly_bb): Initialize PBB_NB_SCATTERING_TRANSFORM and
4315 PBB_NB_LOCAL_VARIABLES.
4316 * graphite-poly.h (pbb_nb_scattering): Removed declaration.
4317 (struct poly_bb): Added nb_local_variables and nb_scattering_transform.
4318 (PBB_NB_LOCAL_VARIABLES, PBB_NB_SCATTERING_TRANSFORM): New.
4319 (pbb_nb_scattering_orig, pbb_nb_scattering_transform): New.
4320 (pbb_nb_scattering_dims, pbb_nb_scattering): Removed.
4321 (pbb_nb_scattering_transform): New.
4322 (pbb_nb_local_vars): Return PBB_NB_LOCAL_VARIABLES.
4323 (psco_scattering_dim): Add assert on parameters.
4324 (psct_scattering_dim): Same.
4325 (psct_scattering_dim_for_loop_depth): Declared.
4326 (psct_local_var_dim): New.
4327 (psco_iterator_dim, psco_parameter_dim): Add assert on parameters.
4328 (psct_iterator_dim, psct_parameter_dim): Same. To maintain the
4329 correct layout, call pbb_nb_local_vars.
4330 (psct_add_local_variable, psct_add_scattering_dimension): New.
4331 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons):
4332 Initialize PBB_NB_SCATTERING_TRANSFORM.
4334 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
4336 * graphite-ppl.c (set_inhomogeneous): Renamed ppl_set_inhomogeneous.
4337 (set_coef): Renamed ppl_set_coef.
4338 * graphite-ppl.h (ppl_set_inhomogeneous, ppl_set_coef): Declared.
4340 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
4342 * graphite-dependences.c (build_pairwise_scheduling_inequality): Don't
4343 test a boolean against 1.
4344 * graphite-interchange.c (pbb_interchange_loop_depths): Do not build
4345 a new polyhedron for the PBB_TRANSFORMED_SCATTERING.
4346 (pbb_do_interchange): Returns true when a transform has been performed.
4347 (scop_do_interchange): Same.
4348 * graphite-poly.c (apply_poly_transforms): Use the return value of
4349 scop_do_interchange.
4350 * graphite-poly.h (scop_do_interchange): Update declaration.
4352 2009-06-23 Tobias Grosser <grosser@fim.uni-passau.de>
4354 * graphite-clast-to-gimple.c (gloog): Reset loop->aux right
4356 * sese.c (sese_reset_aux_in_loops): New.
4357 * sese.h (sese_reset_aux_in_loops): New.
4359 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
4361 * graphite-sese-to-poly.c (scan_tree_for_params_int): Pass in the
4362 multiplier and multiply the constant by the multiplier.
4363 (scan_tree_for_params): Bound the multiplier to its MULT_EXPR.
4364 (build_poly_dr): Do not use the multiplier to define the subscript.
4366 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
4368 * graphite-poly.c (new_poly_dr): Pass an extra argument for the
4369 compiler's data reference. Initialize PDR_CDR.
4370 (print_pdr): Call dump_data_reference.
4371 * graphite-poly.h (struct poly_dr): Rename black_box into pbb.
4372 Add compiler_dr field.
4373 (PDR_BB): Renamed PDR_PBB.
4375 * graphite-sese-to-poly.c (build_poly_dr): Pass to new_poly_dr
4376 GCC's data reference representation.
4377 * tree-data-ref.c (debug_data_references, debug_data_reference): New.
4378 * tree-data-ref.h (debug_data_references, debug_data_reference): Decl.
4380 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
4382 * graphite-poly.c (print_scattering_function): Also print the layout.
4383 * graphite-poly.h (pbb_nb_local_vars): New.
4385 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
4387 * graphite-poly.c (print_pbb_domain): Also print the layout names.
4389 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
4391 * graphite-poly.c (print_pdr, debug_pdr): New.
4392 * graphite-poly.h (print_pdr, debug_pdr): Declared.
4393 (PDR_BASE): Removed.
4395 2009-06-18 Sebastian Pop <sebastian.pop@amd.com>
4397 * gcc.dg/graphite/interchange-{1..7}.c: New avatars of
4400 2009-06-18 Sebastian Pop <sebastian.pop@amd.com>
4402 * graphite-interchange.c (compute_subscript): Allow also -1 in the
4403 subscript identification column.
4404 (pbb_do_interchange): Print to dump_file that some loops "will be
4405 interchanged". Rely on that chain of characters in the testcases.
4406 * gcc.dg/graphite/interchange-0.c: New.
4407 * gcc.dg/graphite/graphite.exp: Iterate over the testsuite
4408 interchange-*.c files and compile them with -floop-interchange.
4410 2009-06-18 Pranav Garg <pranav.garg2107@gmail.com>
4412 * graphite-interchange.c (interchange_profitable_p): Renamed
4413 pbb_interchange_profitable_p.
4415 2009-06-18 Sebastian Pop <sebastian.pop@amd.com>
4416 Harsha Jagasia <harsha.jagasia@amd.com>
4417 Pranav Garg <pranav.garg2107@gmail.com>
4419 * graphite-interchange.c (interchange_profitable_p): Make static.
4420 (pbb_interchange_loop_depths, pbb_do_interchange,
4421 scop_do_interchange): New.
4422 * graphite-poly.c (apply_poly_transforms): Call scop_do_interchange
4423 for flag_loop_interchange.
4424 * graphite-poly.h (scop_do_interchange): Declared.
4425 * tree-ssa-loop.c (gate_graphite_transforms): Do not fail when
4426 flag_loop_interchange is used.
4428 2009-06-18 Sebastian Pop <sebastian.pop@amd.com>
4430 * graphite-dependences.c (dependence_polyhedron): Update use of
4431 pbb_nb_scattering_dims.
4432 * graphite-poly.h (pbb_nb_scattering_dims): Do not pass SCOP.
4433 (pbb_nb_scattering): Update use of pbb_nb_scattering_dims.
4434 (psco_scattering_dim, psct_scattering_dim, psco_iterator_dim,
4435 psct_iterator_dim, psco_parameter_dim, psct_parameter_dim): New.
4437 2009-06-16 Sebastian Pop <sebastian.pop@amd.com>
4439 * graphite.c: Cleanup foo.
4441 2009-06-16 Sebastian Pop <sebastian.pop@amd.com>
4443 * Merge from mainline (r143684:148293).
4444 * Disabled libpcp until it gets fixed.
4446 2009-06-05 Sebastian Pop <sebastian.pop@amd.com>
4447 Harsha Jagasia <harsha.jagasia@amd.com>
4449 * graphite-interchange.c: New.
4450 * Makefile.in (graphite-interchange.o): New.
4451 * graphite-poly.h (interchange_profitable_p): Declared.
4452 * graphite-ppl.h (value_max): New.
4454 2009-06-04 Sebastian Pop <sebastian.pop@amd.com>
4456 * graphite-dependences.c (dependence_polyhedron): Use pdr_dim.
4457 * graphite-poly.h: Fix some comments.
4461 2009-06-04 Sebastian Pop <sebastian.pop@amd.com>
4464 (pdr_accessp_nb_subscripts): Renamed pdr_nb_subscripts.
4465 (pdr_accessp_nb_iterators): Renamed pdr_dim_iter_domain.
4466 (pdr_accessp_nb_params): Renamed pdr_nb_params.
4467 (pdr_accessp_alias_set_dim): Renamed pdr_alias_set_dim.
4468 (pdr_accessp_subscript_dim): Renamed pdr_subscript_dim.
4469 (pdr_accessp_iterator_dim): Renamed pdr_iterator_dim.
4470 (pdr_accessp_param_dim): Renamed pdr_parameter_dim.
4471 (pbb_nb_loops): Renamed pbb_dim_iter_domain.
4472 * graphite-clast-to-gimple.c: Same.
4473 * graphite-dependences.c: Same.
4474 * graphite-poly.c: Same.
4475 * graphite-sese-to-poly.c: Same.
4477 2009-06-03 Sebastian Pop <sebastian.pop@amd.com>
4479 * graphite-clast-to-gimple.c (build_iv_mapping): Insert full
4480 expressions for an IV rename, as returned by clast_to_gcc_expression.
4481 (copy_renames): Rename new_name to expr.
4482 * sese.c (debug_rename_elt): Same.
4485 (sese_adjust_liveout_phis): Call force_gimple_operand before using
4486 the information from the rename map.
4487 (rename_variables_in_stmt): Same.
4488 (add_loop_exit_phis): Rename new_name to expr.
4489 (insert_loop_close_phis): Same.
4490 (add_guard_exit_phis): Same. Call force_gimple_operand.
4491 * sese.h (struct rename_map_elt): Rename new_name to expr.
4492 (new_rename_map_elt): Same.
4494 2009-06-03 Sebastian Pop <sebastian.pop@amd.com>
4496 * graphite-clast-to-gimple.c (build_iv_mapping): Use set_rename.
4497 * sese.c (set_rename): Make it extern.
4498 * sese.h (set_rename): Declared.
4500 2009-06-03 Sebastian Pop <sebastian.pop@amd.com>
4502 * graphite-poly.c (extend_scattering): Free values.
4503 * graphite-ppl.c (new_Cloog_Domain_from_ppl_Pointset_Powerset):
4505 (ppl_print_powerset_matrix): Same.
4506 * graphite-scop-detection.c (free_scops_1): New.
4507 (limit_scops): Call free_scops_1.
4508 * graphite-sese-to-poly.c (build_scop_bbs_1): Free dom.
4509 (build_poly_dr): Free PPL coefficients.
4510 * tree-parloops.c (rewrite_all_phi_nodes_with_iv): Free bbs.
4512 2009-06-02 Sebastian Pop <sebastian.pop@amd.com>
4514 * graphite-dependences.c: New.
4515 * graphite-data-ref.c: Removed.
4516 * graphite-data-ref.h: Removed.
4517 * Makefile.in (graphite-data-ref.o): Removed.
4518 (graphite-dependences.o): Added.
4519 * graphite-clast-to-gimple.c: Remove dependence on graphite-data-ref.h.
4520 * graphite-poly.c: Same.
4521 Move the data dependence testing to graphite-dependences.c.
4523 2009-05-19 Tobias Grosser <grosser@fim.uni-passau.de>
4525 * graphite-scop-detection.c (graphite_can_represent_loop): Renamed
4526 from graphite_cannot_represent_loop. Code refactored.
4527 (scopdet_basic_block_info): Call graphite_can_represent_loop.
4529 2009-05-17 Li Feng <nemokingdom@gmail.com>
4531 * gcc.dg/graphite/graphite_autopar/graphite_autopar.exp:
4532 Cover all the testcases (not only the filtered ones).
4534 2009-05-17 Tobias Grosser <grosser@fim.uni-passau.de>
4536 * graphite-scop-detection.c (stmt_simple_for_scop_p): Remove
4537 unnecessary check. Update comments. Move check for REAL_TYPE here.
4538 (harmful_stmt_in_bb): Remove checks for conditions. This is already
4539 done in (stmt_simple_for_scop_p).
4541 2009-05-14 Tobias Grosser <grosser@fim.uni-passau.de>
4543 * graphite.c (print_global_statistics): New.
4544 (print_graphite_scop_statistic): New.
4545 (print_graphite_statistics): New.
4546 (graphite_initialize, graphite_transform_loops): Print statistics.
4547 * graphite-scop-detection (build_scops): Print statistics.
4548 (print_graphite_scop_statistics): New.
4549 (print_graphite_statistics): New.
4551 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
4553 * graphite-clast-to-gimple.c (struct clast_name_index): Removed.
4554 (debug_clast_name_index): Removed.
4555 (debug_clast_name_indexes_1): Removed.
4556 (debug_clast_name_indexes): Removed.
4557 (clast_name_index_elt_info): Removed.
4558 (eq_clast_name_indexes): Removed.
4559 (clast_name_to_index): Removed.
4560 (new_clast_name_index): Removed.
4561 (save_clast_name_index): Removed.
4562 (save_var_name): Moved...
4563 (init_sese_params_index): Removed.
4564 (clast_name_to_gcc): Remove use of name_tree.
4565 (initialize_cloog_names): Same.
4566 (gloog): Do not call init_sese_params_index.
4567 * graphite-sese-to-poly.c (save_var_name): ...here.
4568 (parameter_index_in_region): New.
4569 * sese.c (new_sese): Initialize SESE_PARAMS_NAMES.
4570 (parameter_index_in_region): Removed.
4571 (is_parameter): Remove use of name_tree.
4572 * sese.h (struct name_tree): Removed.
4573 (struct sese): Remove use of name_tree. New field params_names.
4574 (SESE_PARAMS_NAMES): New.
4575 (SESE_PARAMS): Remove duplicate.
4576 (parameter_index_in_region): Removed.
4577 (sese_nb_params): Remove use of name_tree.
4578 (struct clast_name_index): New.
4579 (new_clast_name_index): New.
4580 (clast_name_to_index): New.
4581 (save_clast_name_index): New.
4582 (debug_clast_name_index): New.
4583 (debug_clast_name_indexes_1): New.
4584 (debug_clast_name_indexes): New.
4585 (clast_name_index_elt_info): New.
4586 (eq_clast_name_indexes): New.
4588 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
4590 * graphite-clast-to-gimple.c (compute_cloog_iv_types_1): Call
4591 pbb_to_depth_to_oldiv. Remove call to oldiv_for_loop.
4592 (graphite_loop_normal_form): Do not pass region. Do not
4593 initialize SESE_OLDIVS.
4594 (build_graphite_loop_normal_form): Update call to
4595 graphite_loop_normal_form.
4596 * sese.c (debug_oldivs): Removed.
4597 (new_sese): Do not initialize SESE_OLDIVS.
4598 (free_sese): Do not free SESE_OLDIVS.
4599 (oldiv_for_loop): Removed.
4600 * sese.h (struct sese): Remove old_ivs.
4601 (SESE_OLDIVS): Removed.
4602 (oldiv_for_loop): Removed.
4604 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
4606 * graphite-clast-to-gimple.c (clast_name_to_gcc): Pass newivs,
4607 remove ivstack. Remove call to loop_iv_stack_get_iv_from_name,
4608 replaced by a call to newivs_to_depth_to_newiv.
4609 (clast_to_gcc_expression): Pass newivs, remove ivstack.
4610 (clast_to_gcc_expression_red): Same.
4611 (gcc_type_for_clast_expr): Same.
4612 (gcc_type_for_clast_eq): Same.
4613 (graphite_translate_clast_equation): Same.
4614 (graphite_create_guard_cond_expr): Same.
4615 (graphite_create_new_guard): Same.
4616 (graphite_create_new_loop): Same.
4617 (build_iv_mapping): Same.
4618 (translate_clast): Same.
4620 (loop_iv_stack_patch_for_consts): Removed. *
4621 sese.c (iv_stack_entry_is_constant): Removed.
4622 (iv_stack_entry_is_iv): Removed.
4623 (loop_iv_stack_push_iv): Removed.
4624 (loop_iv_stack_insert_constant): Removed.
4625 (loop_iv_stack_pop): Removed.
4626 (loop_iv_stack_get_iv): Removed.
4627 (loop_iv_stack_get_iv_from_name): Removed.
4628 (debug_loop_iv_stack): Removed.
4629 (free_loop_iv_stack): Removed.
4630 (loop_iv_stack_remove_constants): Removed. *
4631 sese.h (iv_stack_entry_kind): Removed.
4632 (iv_stack_entry_data_union): Removed.
4633 (iv_stack_entry_struct): Removed.
4634 (iv_stack_entry_p): Removed.
4635 (debug_oldivs, debug_loop_iv_stack, loop_iv_stack_insert_constant,
4636 loop_iv_stack_get_iv_from_name, loop_iv_stack_push_iv,
4637 loop_iv_stack_get_iv, loop_iv_stack_remove_constants,
4638 loop_iv_stack_pop, free_loop_iv_stack): Removed.
4639 (gbb_loop_at_index): Fix indenting.
4640 (gbb_loop_index): Removed.
4642 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
4644 * graphite-clast-to-gimple.c (clast_name_to_gcc): Do not use strcmp.
4645 Call clast_name_to_index.
4647 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
4649 * graphite-clast-to-gimple.c (clast_name_to_gcc): Pass region,
4650 do not pass params. Get params from SESE_PARAMS.
4651 (clast_to_gcc_expression): Same.
4652 (clast_to_gcc_expression_red): Same.
4653 (gcc_type_for_clast_eq): Same.
4654 (graphite_translate_clast_equation): Same.
4655 (graphite_create_new_loop): Same.
4656 * sese.c (rename_variables_in_stmt): Fix comment.
4658 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
4660 * graphite-clast-to-gimple.c (graphite_create_new_loop): Pass
4662 Call save_clast_name_index.
4663 (translate_clast): Pass newivs_index.
4664 (gloog): Create and free newivs_index.
4666 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
4668 * graphite-clast-to-gimple.c (clast_name_index): New structure.
4669 (clast_name_index_p): New type.
4670 (debug_clast_name_index): New.
4671 (debug_clast_name_indexes_1): New.
4672 (debug_clast_name_indexes): New.
4673 (clast_name_index_elt_info): New.
4674 (eq_clast_name_indexes): New.
4675 (clast_name_to_index): New.
4676 (new_clast_name_index): New.
4677 (save_clast_name_index): New.
4678 (init_sese_params_index): New.
4679 (gloog): Call init_sese_params_index.
4680 * graphite-clast-to-gimple.h (debug_clast_name_indexes): Declared.
4681 * sese.c (new_sese): Initialize SESE_PARAMS_INDEX.
4682 (free_sese): Free SESE_PARAMS_INDEX.
4683 * sese.h (struct sese): Add params_index.
4684 (SESE_PARAMS_INDEX): New.
4686 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
4688 * graphite-clast-to-gimple.c (newivs_to_depth_to_newiv): New.
4689 (graphite_create_new_loop): Pass the newivs vector. Push the
4690 newly created IV to newivs.
4691 (translate_clast): Pass the newivs vector.
4692 (gloog): Create and destroy the newivs vector.
4694 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
4696 * graphite-clast-to-gimple.c (pbb_to_depth_to_oldiv): New.
4697 (graphite_loop_normal_form): Initialize loop->aux with the unique
4698 IV that has been created.
4700 2009-05-13 Tobias Grosser <grosser@fim.uni-passau.de>
4702 * tree-chrec.c (evolution_function_right_is_integer_cst): Allow
4703 scev with parameters in the base part. They where forbidden
4706 2009-05-11 Li Feng <nemokingdom@gmail.com>
4708 * gcc.dg/graphite/graphite.exp: Set different default
4709 compile options by file names.
4710 * gcc.dg/graphite/block{0-6}.c: Remove dg-option line.
4711 * gcc.dg/graphite/id-{1-9}.c: Ditto.
4712 * gcc.dg/graphite/scop-{0-20}.c: Ditto.
4713 * gcc.dg/graphite/scop-matmult.c: Ditto.
4715 2009-05-08 Li Feng <nemokingdom@gmail.com>
4717 * gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: New.
4718 * gcc.dg/graphite/graphite_autopar/force-parallel-1.c: New.
4719 * gcc.dg/graphite/graphite_autopar/force-parallel-2.c: New.
4720 * gcc.dg/graphite/graphite_autopar/force-parallel-3.c: New.
4722 2009-05-07 Tobias Grosser <grosser@fim.uni-passau.de>
4724 * graphite-scop-detection (build_scops_1): Fix little bug introduced
4727 2009-05-07 Tobias Grosser <grosser@fim.uni-passau.de>
4729 * graphite-scop-detection.c (graphite_can_represent_scev): Only
4730 allow integer constant strides.
4731 (graphite_can_represent_expr): Depend on outermost_loop.
4732 (stmt_simple_memref_p, graphite_cannot_represent_loop,
4733 harmful_stmt_in_bb, is_simple_operand, stmt_simple_for_scop_p,
4734 build_scops_1): Same.
4735 (scopdet_basic_block_info): Same and insert layered SCoP
4737 (try_generate_gimple_bb): Cleanup.
4738 (build_scops): Enable data references.
4740 * gcc.dg/graphite/id-5.c: New.
4741 * gcc.dg/graphite/id-9.c: New.
4742 * tree-chrec.c (evolution_function_right_is_integer_cst): New.
4743 * tree-chrec.h (evolution_function_right_is_integer_cst): New.
4745 2009-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
4747 * sese.c (expand_scalar_variables_ssa_name): Only build expressions,
4748 that we have not yet built for this SCoP.
4750 2009-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
4752 * sese.c (expand_scalar_variables_expr): Fix expand_scalar_variables
4753 for complex numbers.
4755 2009-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
4757 * graphite-ppl.c: Fix build if cloog is not available.
4759 2009-05-04 Li Feng <nemokingdom@gmail.com>
4761 * tree-parloops.c (loop_parallel_p): Remove construction of
4762 NITER and REDUCTION_LIST.
4763 (try_get_loop_niter): New.
4764 (try_create_reduction_list): New.
4765 (parallelize_loops): Bypass the failed checkings in autopar
4766 when can_be_parallel in loop structure is set to true.
4768 2009-05-01 Tobias Grosser <grosser@fim.uni-passau.de>
4770 * gcc.dg/graphite/id-6.c: Update testcase.
4771 * gcc.dg/graphite/scop-3.c: Dito.
4773 2009-05-01 Tobias Grosser <grosser@fim.uni-passau.de>
4775 * graphite-scop-detection.c (stmt_simple_for_scop_p):
4776 Enable EQ_EXPR and NE_EXPR again.
4778 2009-04-30 Tobias Grosser <grosser@fim.uni-passau.de>
4780 * graphite-scop-detection.c (graphite_can_represent_scev):
4781 Add check if scev is affine multivariate.
4782 (harmful_stmt_in_bb): Check if we can represent the conditions.
4783 (scopdet_basic_block_info (basic_block bb, VEC): Pass the loop to
4785 * gcc.dg/graphite/id-7.c: New.
4787 2009-04-30 Tobias Grosser <grosser@fim.uni-passau.de>
4789 * graphite-sese-to-poly.c (bb_contains_non_iv_scalar_phi_nodes):
4790 Check all bbs in region, not only the bbs that are represented in
4792 (build_poly_scop): Add newline.
4793 * gcc.dg/graphite/id-8.c: New.
4795 2009-04-30 Li Feng <nemokingdom@gmail.com>
4797 * cfgloop.c (alloc_loop): Initialize can_be_parallel to false
4798 when loop initialize.
4799 * cfgloop.h (struct loop): Introduce flag can_be_parallel.
4800 * common.opt: Declare flag_graphite_force_parallel.
4801 * graphite-clast-to-gimple.c (translate_clast): Mark the innermost
4803 * graphite-poly.c (apply_poly_transforms): Introduce
4804 flag_graphite_force_parallel.
4805 * tree-ssa-loop.c (gate_graphite_transforms): ditto.
4806 * toplev.c (process_options): ditto and replace a not correctly
4809 2009-04-30 Li Feng <nemokingdom@gmail.com>
4811 * graphite-clast-to-gimple.c (loop_iv_stack_patch_for_consts):
4812 Change the call of gbb_loop_at_index and/or gbb_loop_index due
4813 to the redefinition.
4814 (compute_cloog_iv_types_1): ditto.
4815 (build_iv_mapping): ditto.
4816 * graphite-sese-to-poly.c (new_gimple_bb): Remove GBB_LOOPS related
4818 (free_gimple_bb): Removed GBB_LOOPS related free part.
4819 (build_bb_loops): Removed.
4820 * sese.h (struct gimple_bb): Removed loops.
4821 (GBB_LOOPS): Removed.
4822 (gbb_loop_at_index): Instead of using GBB_LOOPS, we use sese instead.
4823 (gbb_loop_index): ditto.
4825 2009-04-24 Tobias Grosser <grosser@fim.uni-passau.de>
4827 * graphite-scop-detection.c (graphite_can_represent_scev): Do not
4828 allow non constant strides.
4829 * gcc.dg/graphite/scop-20.c: New.
4831 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
4833 * graphite-scop-detection.c (dot_all_scops): Fix system call
4834 return value warning.
4837 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
4839 * gcc.dg/graphite/id-6.c: Fix pattern.
4840 * gcc.dg/graphite/scop-3.c: Same.
4842 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
4844 * graphite-poly.c (map_into_dep_poly, map_dr_into_dep_poly,
4845 build_pairwise_constraint, dr_equality_constraints,
4846 build_pairwise_scheduling_equality,
4847 build_pairwise_scheduling_inequality, lexicographically_gt_p,
4848 build_lexicographically_gt_constraint, dependence_polyhedron,
4849 graphite_legal_transform_dr, graphite_legal_transform_bb,
4850 graphite_legal_transform): New.
4851 * graphite-poly.h (graphite_legal_transform): Declared.
4852 * graphite-sese-to-poly.c (build_poly_scop): Call to
4853 graphite_legal_transform is disabled for the moment.
4855 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
4857 * graphite-poly.h (pbb_nb_scattering_dims): New.
4858 (pbb_nb_scattering): Use it.
4860 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
4862 * graphite-ppl.c (ppl_insert_dimensions_pointset): Add
4863 Pointset_Powerset version of ppl_insert_dimensions.
4864 * graphite-ppl.h (ppl_insert_dimensions_pointset): Declared.
4866 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
4868 * graphite-ppl.c (ppl_insert_dimensions): Fix formatting.
4870 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
4872 * graphite-poly.h: Fix comment.
4874 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
4876 * graphite-sese-to-poly.c (build_poly_dr): Fix data ref multiplier.
4878 2009-04-24 Tobias Grosser <grosser@fim.uni-passau.de>
4880 * sese.c (expand_scalar_variables_stmt): Only iterate over the old
4883 2009-04-24 Tobias Grosser <grosser@fim.uni-passau.de>
4885 * graphite-sese-to-poly.c (var_used_in_not_loop_header_phi_node): New.
4886 (graphite_stmt_p): Represent bbs necessary to build the phi nodes of
4889 2009-04-20 Sebastian Pop <sebastian.pop@amd.com>
4891 * graphite-scop-detection.c (stmt_simple_for_scop_p): Do not
4892 handle EQ_EXPR and NE_EXPR.
4894 2009-04-17 Tobias Grosser <grosser@fim.uni-passau.de>
4896 * graphite-poly.h (poly_dr): Fix comment.
4898 2009-04-09 Sebastian Pop <sebastian.pop@amd.com>
4899 Tobias Grosser <grosser@fim.uni-passau.de>
4901 * graphite-poly.c (new_poly_bb): Do not initialize PBB_DOMAIN
4902 with a zero dimension polyhedron.
4903 (find_scop_parameters): Move the call to scop_set_nb_params here.
4904 (build_loop_iteration_domains): Store in loop->aux the iteration
4906 (build_scop_iteration_domain): Fix PBB_DOMAIN for bbs not surrounded
4907 by any loop in scop.
4908 (build_poly_scop): Do not call scop_set_nb_params.
4910 2009-04-09 Sebastian Pop <sebastian.pop@amd.com>
4911 Tobias Grosser <grosser@fim.uni-passau.de>
4913 * graphite-sese-to-poly.c (add_condition_to_pbb): Pass code to
4914 add_condition_to_domain not GT_EXPR.
4916 2009-04-09 Tobias Grosser <grosser@fim.uni-passau.de>
4918 * graphite-ppl.c (debug_ppl_powerset_matrix): New.
4919 * graphite-ppl.h (debug_ppl_powerset_matrix): New.
4920 * graphite-sese-to-poly.c (add_condition_to_pbb): Use
4921 upper_bound_assign to calculate unions.
4922 * gcc.dg/graphite/id-6.c: New.
4924 2009-04-09 Tobias Grosser <grosser@fim.uni-passau.de>
4926 * graphite-scop-detection.c (canonicalize_loop_closed_ssa): Do not
4927 handle abnormal edges.
4929 2009-04-09 Tobias Grosser <grosser@fim.uni-passau.de>
4931 * graphite-poly.c (new_poly_dr, free_poly_dr): New.
4932 (free_poly_bb): Also free poly_drs.
4933 * graphite-poly.h (new_poly_dr, free_poly_dr): New.
4934 (poly_dr): Polyhedron to Pointset_Powerset.
4935 (pdr_accessp_nb_subscripts): Same.
4936 * graphite-sese-to-poly.c (build_poly_dr): Same. And actually build
4939 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
4941 * graphite-clast-to-gimple.c (initialize_cloog_names): Change cloog
4942 names into more meaningful names.
4944 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
4946 * gfortran.dg/graphite/interchange-1.c: New.
4947 * gfortran.dg/graphite/interchange-2.c: New.
4949 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
4951 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not build
4953 * tree-parloops.c (rewrite_phi_with_iv): New.
4954 (rewrite_all_phi_nodes_with_iv): New.
4955 (canonicalize_loop_ivs): Call them.
4957 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
4959 * graphite-sese-to-poly.c (try_generate_gimple_bb): Use
4960 graphite_find_data_references_in_stmt.
4961 * tree-data-ref.c (graphite_find_data_references_in_stmt): New.
4962 * tree-data-ref.h (graphite_find_data_references_in_stmt): Declared.
4964 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
4966 * sese.c (add_loop_exit_phis): Don't fail on non SSA_NAME renames.
4968 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
4970 * graphite-sese-to-poly.c (build_scop_bbs_1): Use bb_in_sese_p
4971 instead of bb_in_region.
4972 (flag_bb_in_region): Same. Renamed flag_bb_in_sese.
4973 (build_sese_conditions): Use flag_bb_in_sese.
4974 * sese.c (register_bb_in_sese): Removed.
4975 (new_sese): Remove initialization of SESE_REGION_BBS.
4976 (free_sese): Do not free SESE_REGION_BBS.
4977 * sese.h (struct sese): Remove field region_basic_blocks.
4978 (SESE_REGION_BBS): Removed.
4979 (bb_in_sese_p): Implement in function of bb_in_region.
4981 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
4983 * graphite-scop-detection.c (limit_scops): Deal only with single exit
4986 2009-04-08 Tobias Grosser <grosser@fim.uni-passau.de>
4988 * graphite-scop-detection.c (stmt_simple_for_scop_p): Allow NE_EXPR
4990 * graphite-sese-to-poly.c (create_linear_expr_from_tree): New.
4991 (add_condition_to_domain): New.
4992 (add_condition_to_pbb): New.
4993 (add_conditions_to_domain): Cleanup and handle of NE_EXPR and EQ_EXPR.
4994 * gcc.dg/graphite/scop-3.c: Update number of detected SCoPs.
4996 2009-04-08 Tobias Grosser <grosser@fim.uni-passau.de>
4998 * graphite-clast-to-gimple.c (build_cloog_prog): ppl_Polyhedron ->
4999 ppl_Pointset_Powerset.
5000 * graphite-poly.c (new_poly_bb, free_poly_bb): Same.
5001 * graphite-poly.h (poly_bb): poly_bb.domain Same.
5002 (pbb_nb_loops): Same.
5003 * graphite-sese-to-poly.c (build_loop_iteration_domains,
5004 add_conditions_to_domain): Same.
5005 * graphite-ppl.c (new_Cloog_Domain_from_ppl_Pointset_Powerset): New.
5006 (ppl_print_polyhedron_matrix): ppl_Polyhedron_t ->
5007 ppl_const_Polyhedron_t.
5008 (ppl_print_powerset_matrix): New.
5009 * graphite-ppl.h (new_Cloog_Domain_from_ppl_Pointset_Powerset,
5010 ppl_print_powerset_matrix): New.
5011 (ppl_print_polyhedron_matrix): Updated.
5013 2009-04-07 Sebastian Pop <sebastian.pop@amd.com>
5015 * tree-scalar-evolution.c (analyze_scalar_evolution_1): Fix comment.
5017 2009-04-07 Sebastian Pop <sebastian.pop@amd.com>
5019 * graphite-poly.c (extend_scattering): Fix indenting. Free cstr.
5020 (print_iteration_domains, debug_iteration_domain,
5021 debug_iteration_domains): New.
5022 * graphite-poly.h (print_iteration_domains, debug_iteration_domain,
5023 debug_iteration_domains): Declared.
5024 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons): Fix
5027 2009-04-03 Tobias Grosser <grosser@fim.uni-passau.de>
5028 Sebastian Pop <sebastian.pop@amd.com>
5030 * graphite-poly.h (print_iteration_domain): New.
5031 * graphite-sese-to-poly.c (add_conditions_to_domain): Fixed bug.
5032 (build_sese_conditions_1, build_sese_conditions_after,
5033 build_sese_conditions_before): New.
5034 (build_sese_conditions): Rewritten.
5036 2009-04-03 Sebastian Pop <sebastian.pop@amd.com>
5037 Tobias Grosser <grosser@fim.uni-passau.de>
5039 Cleanup of code generation liveouts.
5040 * graphite-clast-to-gimple.c (translate_clast): Use a single
5041 rename_map instead of one per translated statement.
5042 Do not use SESE_LIVEOUT_RENAMES.
5043 (graphite_loop_normal_form): Do not use SESE_REDUCTION_LIST.
5044 (gloog): Do not use SESE_LIVEOUT_RENAMES.
5045 * graphite-scop-detection.c (harmful_stmt_in_bb): Return the close
5046 phi node of a reduction: when a loop contains a reduction used outside
5047 the loop, there should be a scalar close phi node on the exit block.
5048 * sese.c (new_sese): Do not initialize SESE_LIVEOUT,
5049 SESE_LIVEOUT_RENAMES, and SESE_REDUCTION_LIST.
5050 (free_sese): Do not free them.
5051 (sese_build_liveouts_use): Do not use them.
5052 (sese_build_liveouts_bb): Same.
5053 (sese_build_liveouts): Same.
5054 (sese_insert_phis_for_liveouts): Same.
5055 (sese_adjust_phis_for_liveouts): Same. Renamed sese_adjust_liveout_phis.
5056 (defined_in_loop_p): New.
5057 (alive_after_loop): New.
5058 (close_phi_not_yet_inserted_p): New.
5059 (struct alep, alep_p): New.
5060 (add_loop_exit_phis): Remove from the rename_map all the names defined
5061 in the code generated loop.
5062 (insert_loop_close_phis): Traverse the rename_map passed to it.
5063 Don't use SESE_LIVEOUT_RENAMES.
5064 (default_liveout_before_guard): Renamed default_before_guard.
5065 (insert_guard_phis): Do not use SESE_LIVEOUT_RENAMES.
5066 (graphite_copy_stmts_from_block): Do not directly call set_rename.
5067 (register_sese_liveout_renames): Removed.
5068 (copy_bb_and_scalar_dependences): Do not call it.
5069 * sese.h (struct sese): Removed fields: liveout, liveout_renames, and
5071 (SESE_LIVEOUT): Removed.
5072 (SESE_LIVEOUT_RENAMES): Removed.
5073 (SESE_REDUCTION_LIST): Removed.
5074 (sese_build_liveouts): Removed.
5075 (sese_adjust_phis_for_liveouts): Renamed sese_adjust_liveout_phis.
5076 (insert_loop_close_phis): Pass a htab_t instead of a sese.
5077 (insert_guard_phis): Same.
5078 (rename_map_elt): Declare a VEC of them.
5079 * tree-parloops.c (canonicalize_loop_ivs): reduction_list contains
5080 trees not pointers to trees.
5082 Rewrite in canonical close SSA form:
5083 * graphite-scop-detection.c (contains_only_close_phi_nodes): New.
5084 (limit_scops): Close the scop after the block containing the close phi
5086 (canonicalize_loop_closed_ssa): New.
5087 (canonicalize_loop_closed_ssa_form): New.
5088 (build_scops): Call canonicalize_loop_closed_ssa_form.
5090 * graphite-sese-to-poly.c: Fix typos.
5092 2009-04-03 Sebastian Pop <sebastian.pop@amd.com>
5094 * graphite-poly.c (print_scattering_function, print_pbb_domain):
5096 (dump_gbb_conditions, dump_gbb_cases, print_iteration_domain): New.
5097 (print_pbb): Add conditions.
5099 2009-04-01 Tobias Grosser <grosser@fim.uni-passau.de>
5100 Sebastian Pop <sebastian.pop@amd.com>
5102 * graphite-scop-detection.c (bb_in_sd_region): Use bb_in_region.
5103 * graphite-sese-to-poly.c (all_non_dominated_preds_marked_p): New.
5104 (build_scop_bbs_1): New.
5105 (build_scop_bbs): Rewrite.
5106 * sese.h (bb_in_region): New.
5108 2009-03-29 Tobias Grosser <grosser@fim.uni-passau.de>
5110 * graphite-poly.c (new_poly_bb, free_poly_bb): Initialize/free
5112 (print_scop): Style.
5113 * graphite-poly.h (poly_bb): Add drs vector.
5114 (PBB_DRS): Add accessor.
5115 * graphite-sese-to-poly.c (build_poly_dr): New.
5116 (build_pbb_drs, build_scop_drs): New.
5117 (build_poly_scop): call build_scop_drs (Disabled at the moment).
5119 2009-03-29 Tobias Grosser <grosser@fim.uni-passau.de>
5121 * tree-ssa-loop.c: Include forgotten toplev.h
5123 2009-03-29 Tobias Grosser <grosser@fim.uni-passau.de>
5125 * graphite-poly.c: (apply_poly_transforms): sorry -> gcc_unreachable.
5126 * gcc.dg/graphite/pr37883.c: Remove -floop-*
5127 * gcc.dg/graphite/pr37928.c: Same
5128 * gcc.dg/graphite/pr38409.c: Same
5129 * gcc.dg/graphite/pr38498.c: Same
5130 * gcc.dg/graphite/pr38559.c: Same
5131 * gcc.dg/graphite/pr39335.c: Same
5132 * gcc.dg/graphite/pr39335_1.c: Same
5133 * gfortran.dg/graphite/block-2.f: Same
5134 * tree-ssa-loop.c (gate_graphite_transforms): Always fail if called
5137 2009-03-28 Tobias Grosser <grosser@fim.uni-passau.de>
5139 * graphite-sese-to-poly.c (ref_nb_loops, build_access_matrix_with_af,
5140 build_access_matrix, build_scop_data_accesses): Remove access function
5141 building. (We get a new version soon).
5142 (build_bb_loops, scan_tree_for_params_right_scev): Update.
5143 * sese.h (nb_loops_around_loop_in_sese): Remove.
5144 (sese_loop_depth): Do not use SESE_LOOP_NEST any more.
5146 2009-03-27 Tobias Grosser <grosser@fim.uni-passau.de>
5147 Sebastian Pop <sebastian.pop@amd.com>
5149 * graphite-scop-detection.c (struct scopdet_info): Rename last
5151 (scopdet_basic_block_info, build_scops_1): Don't use
5152 CDI_POST_DOMINATORS. CDI_POST_DOMINATORS should never be used.
5154 2009-03-26 Tobias Grosser <grosser@fim.uni-passau.de>
5155 Sebastian Pop <sebastian.pop@amd.com>
5157 * graphite-clast-to-gimple.c (gloog): Call sese_build_liveouts.
5158 * sese.c (sese_build_liveouts_use): Renamed from
5159 sese_build_livein_liveouts_use. Remove liveins.
5160 (sese_build_liveouts_bb): Renamed from sese_build_livein_liveouts_bb.
5161 Call sese_build_liveouts_use.
5162 (sese_build_liveouts): Renamed from sese_build_livein_liveouts.
5163 Call sese_build_liveouts_bb.
5164 (new_sese, free_sese): Remove liveins.
5165 (sese_add_exit_phis_var): Deleted.
5166 (sese_insert_phis_for_liveouts): Call sese_add_exit_phis_edge
5168 (graphite_copy_stmts_from_block): Remove SESE_NUM_VER.
5170 * sese.h (sese): Remove num_ver and livein.
5171 (SESE_LIVEIN, SESE_LIVEIN_VER, SESE_NUM_VER): Removed.
5173 2009-03-25 Tobias Grosser <grosser@fim.uni-passau.de>
5175 * graphite-sese-to-poly.c (build_scop_scattering): Fix compile.
5177 2009-03-25 Tobias Grosser <grosser@fim.uni-passau.de>
5179 * graphite-sese-to-poly.c (compare_prefix_loops): Removed.
5180 (build_scop_scattering): Do not use compare_prefix_loops any more.
5181 (nb_common_loops): New.
5183 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
5185 * sese.c (get_new_name_from_old_name): Renamed get_rename.
5186 (register_old_and_new_names): Renamed set_rename.
5188 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
5190 * graphite-scop-detection.h (nb_reductions_in_loop): Revert removal
5191 of the decl from the previous commit.
5193 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
5195 * graphite-scop-detection.c (dot_scop): New.
5196 * graphite-scop-detection.h (dot_scop): Declared.
5198 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
5200 * graphite-sese-to-poly.c (compare_prefix_loops): Fix compare.
5202 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
5204 * cfgloopmanip.c (create_empty_loop_on_edge): Generate the loop exit
5205 condition at the end of the loop.
5206 * graphite.c (graphite_initialize, graphite_finalize): Print to
5207 dump_file the compiled function.
5208 * graphite-clast-to-gimple.c (graphite_create_new_loop): Update use
5209 of create_empty_loop_on_edge.
5210 (translate_clast): Update the code generation of loops for the new
5212 * cfgloop.h (create_empty_loop_on_edge): Update declaration.
5214 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
5216 Reverted the patch from 2009-03-19.
5218 2009-03-19 Tobias Grosser <grosser@fim.uni-passau.de>
5220 * graphite-poly.c (new_poly_bb, free_poly_bb): Initialize/free
5222 (print_scop): Style.
5223 * graphite-poly.h (poly_bb): Add drs vector.
5224 (PBB_DRS): Add accessor.
5225 * graphite-sese-to-poly.c (ref_nb_loops): Remove.
5226 (build_access_matrix_with_af, build_access_matrix,
5227 build_scop_data_accesses): Delete.
5228 (build_poly_dr): New.
5229 (build_pbb_drs, build_scop_drs): New.
5230 (build_poly_scop): call build_scop_drs.
5232 2009-03-13 Sebastian Pop <sebastian.pop@amd.com>
5234 * graphite-scop-detection.c (dot_all_scops_1): Close the table
5235 once per basic block.
5237 2009-03-13 Tobias Grosser <grosser@fim.uni-passau.de>
5239 * graphite-scop-detection.c (graphite_can_represent_scev): New.
5240 (graphite_can_represent_expr): Renamed from loop_affine_expr
5242 (stmt_simple_for_scop_p): Call graphite_can_represent_expr.
5243 (graphite_cannot_represent_loop): Add scop_entry to parameters.
5244 (scopdet_basic_block_info): Actually define entry_block.
5245 (stmt_simple_memref_p): Moved here from ...
5247 * tree-data-ref.c (stmt_simple_memref_p): here.
5248 * tree-data-ref.h (stmt_simple_memref_p): Removed.
5250 2009-03-13 Tobias Grosser <grosser@fim.uni-passau.de>
5252 * gcc.dg/graphite/id-4.c: New.
5254 2009-03-12 Sebastian Pop <sebastian.pop@amd.com>
5256 * sese.c (expand_scalar_variables_expr): Handle tcc_comparison.
5257 (register_old_and_new_names): Update the content of the map.
5258 When there was already a rename_map_elt in the map at that
5260 (copy_bb_and_scalar_dependences): Do rename_variables after
5261 expand_scalar_variables.
5262 * graphite-clast-to-gimple.c (build_iv_mapping): Update the content
5263 of the map. When there was already a rename_map_elt in the
5264 map at that location, free it.
5265 (translate_clast): Pass the rename_map. Do not initialize and free
5266 a rename_map per stmt_user.
5267 (gloog): Initialize and free one rename_map and pass it to
5270 2009-03-12 Sebastian Pop <sebastian.pop@amd.com>
5272 * sese.c (expand_scalar_variables_stmt,
5273 expand_scalar_variables_ssa_name): Add a gimple_stmt_iterator
5275 (expand_scalar_variables_expr): Handle REALPART_EXPR and IMAGPART_EXPR.
5276 (expand_scalar_variables): Pass to expand_scalar_variables_stmt
5277 the gimple_stmt_iterator of the statement to be expanded.
5278 * graphite-scop-detection.c (is_simple_operand): Do handle
5281 2009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
5283 * graphite-scop-detection.c (is_simple_operand): Do not handle
5285 * gcc.dg/graphite/id-2.c: New.
5287 * graphite-sese-to-poly.c (build_bb_loops,
5288 add_value_to_dim, scan_tree_for_params_right_scev,
5289 scan_tree_for_params_int, scan_tree_for_params, idx_record_params,
5290 find_params_in_bb, build_loop_iteration_domains,
5291 add_conditions_to_domain): Remove subtract.
5293 2009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
5295 * graphite-clast-to-gimple.c (loop_iv_stack_patch_for_consts,
5296 build_iv_mapping, compute_cloog_iv_types_1, build_cloog_prog):
5297 pbb_loop_at_index -> gbb_loop_at_index.
5298 * graphite-poly.c (new_poly_bb, new_scop): New accessors.
5299 (debug_loop_vec): Delete.
5300 * graphite-poly.h (poly_bb, scop): Change black_box and region to void
5301 pointer. Move LOOPS to gimple_bb_p and insert nb_params.
5302 (PBB_LOOPS): Removed.
5303 (PBB_BLACK_BOX): Insert cast.
5304 (pbb_set_black_box): New setter.
5305 (pbb_loop_at_index, pbb_loop_index): Removed.
5306 (scop_set_region, scop_set_nb_params): New.
5307 * graphite-sese-to-poly.c (new_gimple_bb, free_gimple_bb,
5308 build_scop_scattering, build_bb_loops): Add GBB_LOOPS.
5309 (build_poly_scop): Use scop_set_nb_params.
5310 * sese.h (gimple_bb): Add LOOPS.
5311 (GBB_LOOPS, gbb_loop_index, gbb_loop_at_index): New.
5313 2009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
5315 Revert previous commit.
5317 2009-03-11 Sebastian Pop <sebastian.pop@amd.com>
5319 * sese.c (expand_scalar_variables_expr): Handle tcc_comparison.
5320 (register_old_and_new_names): Update the content of the map.
5321 When there was already a rename_map_elt in the map at that
5323 (copy_bb_and_scalar_dependences): Do rename_variables after
5324 expand_scalar_variables.
5325 * graphite-clast-to-gimple.c (build_iv_mapping): Update the content
5326 of the map. When there was already a rename_map_elt in the
5327 map at that location, free it.
5328 (translate_clast): Pass the rename_map. Do not initialize and free
5329 a rename_map per stmt_user.
5330 (gloog): Initialize and free one rename_map and pass it to
5333 2009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
5335 Remove forgotten line in revert.
5337 2009-03-11 Sebastian Pop <sebastian.pop@amd.com>
5339 Revert previous commit.
5341 2009-03-10 Sebastian Pop <sebastian.pop@amd.com>
5343 * sese.c (register_old_and_new_names): Update the content
5344 of the map. When there was already a rename_map_elt in the
5345 map at that location, free it.
5346 (copy_bb_and_scalar_dependences): Do rename_variables after
5347 expand_scalar_variables.
5348 * graphite-clast-to-gimple.c (build_iv_mapping): Update the content
5349 of the map. When there was already a rename_map_elt in the
5350 map at that location, free it.
5351 (translate_clast): Pass the rename_map. Do not initialize and free
5352 a rename_map per stmt_user.
5353 (gloog): Initialize and free one rename_map and pass it to
5356 2009-03-10 Sebastian Pop <sebastian.pop@amd.com>
5358 * graphite-clast-to-gimple.c (translate_clast): context_loop
5361 2009-03-10 Tobias Grosser <grosser@fim.uni-passau.de>
5362 Sebastian Pop <sebastian.pop@amd.com>
5364 * graphite-ppl.c (ppl_insert_dimensions): Fix stupid mistake
5365 of the use of ppl_Polyhedron_map_space_dimensions.
5367 2009-03-10 Tobias Grosser <grosser@fim.uni-passau.de>
5368 Sebastian Pop <sebastian.pop@amd.com>
5370 * graphite-poly.c (unify_scattering_dimensions): Fix types.
5371 * graphite-poly.h (poly_dr_p, poly_dr, POLY_DR_TYPE, PDR_BB,
5372 PDR_TYPE, PDR_ACCESSES, pdr_accessp_nb_subscripts,
5373 pdr_accessp_nb_iterators, pdr_accessp_nb_params,
5374 pdr_accessp_alias_set_dim, pdr_accessp_subscript_dim,
5375 pdr_accessp_iterator_dim, pdr_accessp_param_dim,
5376 pbb_nb_params): New.
5377 (pbb_nb_loops, pbb_nb_scattering, scop_nb_params,
5378 nb_loops_around_pbb): Adapt return types.
5380 2009-03-09 Tobias Grosser <grosser@fim.uni-passau.de>
5382 * Makefile.in (graphite.o, graphite-sese-to-poly.o,
5383 graphite-clast-to-gimple.o, graphite-data-ref.o,
5384 graphite-scop-detection.o, graphite-poly.o): Add
5387 2009-03-05 Tobias Grosser <grosser@fim.uni-passau.de>
5389 * Makefile.in (graphite.o, graphite-sese-to-poly.o,
5390 graphite-clast-to-gimple.o, graphite-data-ref.o,
5391 graphite-scop-detection.o, graphite-poly.o): Add graphite-poly.h.
5393 2009-03-04 Tobias Grosser <grosser@fim.uni-passau.de>
5395 * gcc.dg/graphite/pr37485.c: Remove -floop-block
5396 * gcc.dg/graphite/pr37828.c: Same.
5397 * gcc.dg/graphite/pr37684.c: Same.
5398 * gcc.dg/graphite/block-0.c: Same.
5399 * gcc.dg/graphite/block-1.c: Same.
5400 * gcc.dg/graphite/block-2.c: Same.
5401 * gcc.dg/graphite/block-3.c: Same.
5402 * gcc.dg/graphite/block-4.c: Same.
5403 * gcc.dg/graphite/block-5.c: Same.
5404 * gcc.dg/graphite/block-6.c: Same.
5405 * gfortran.dg/graphite/pr38083.f90: Same.
5406 * gfortran.dg/graphite/block-1.f90: Same.
5407 * gfortran.dg/graphite/block-3.f90: Same.
5408 * gfortran.dg/graphite/pr37852.f90: Same.
5409 * gfortran.dg/graphite/block-4.f90: Same.
5410 * gfortran.dg/graphite/pr37980.f90: Same.
5411 * gfortran.dg/graphite/pr38953.f90: Same.
5412 * gfortran.dg/graphite/pr37857.f90: Same.
5413 * opts.c: Remove -floop-block from -O2.
5414 * graphite-poly.c: Fail if -floop-block -floop-interchange or
5415 -floop-strip-mine are used.
5417 2009-03-04 Tobias Grosser <grosser@fim.uni-passau.de>
5418 Sebastian Pop <sebastian.pop@amd.com>
5420 * graphite-clast-to-gimple.c (build_cloog_prog): Unify scattering
5422 * graphite-poly.c (pbb_compare, graphite_sort_pbbs,
5423 graphite_trans_bb_move_loop, graphite_trans_bb_strip_mine,
5424 strip_mine_profitable_p, is_interchange_valid,
5425 graphite_trans_bb_block, graphite_trans_loop_block,
5426 graphite_trans_scop_block): Temporary removed.
5427 (extend_scattering, unify_scattering_dimensions): New.
5428 (print_scattering_function, graphite_read_transforms):
5429 PBB_SCATTERING -> PBB_TRANSFORMED_SCATTERING.
5430 (graphite_generate_scattering_fns): Removed.
5431 (apply_poly_transforms): Cleanup.
5432 (free_poly_bb): Add PBB_SCATTERING -> PBB_TRANSFORMED_SCATTERING.
5433 (schedule_to_scattering): Moved.
5434 (PBB_STATIC_SCHEDULE, PBB_SCATTERING): Removed.
5435 (PBB_ORIGINAL_SCATTERING, PBB_TRANSFORMED_SCATTERING): New.
5436 (pbb_nb_scattering): New.
5437 (SCOP_ENTRY, SCOP_EXIT, SCOP_REGION_BBS, SCOP_DEP_GRAPH, SCOP_PARAMS,
5438 SCOP_LOOP_NEST, SCOP_PARAMS, SCOP_OLDIVS, SCOP_LIVEOUT_RENAMES):
5440 * graphite-ppl.c (ppl_insert_dimensions): Extended and renamed from
5442 (ppl_strip_loop): PBB_SCATTERING -> PBB_TRANSFORMED_SCATTERING.
5443 * graphite-scop-detection.c (dot_all_scops_1): PBB_SCATTERING
5444 -> PBB_TRANSFORMED_SCATTERING.
5445 * graphite-sese-to-poly.c (build_scop_bbs): Remove region.
5446 (build_pbb_scattering_polyhedron): Moved from schedule_to_scattering.
5447 (build_scop_scattering): Renamed from build_scop_canonical_schedules.
5448 (check_poly_representation): Do not return bool.
5449 (graphite_transform_loops): Reformat.
5450 * sese.h (SESE_ENTRY_BB, SESE_EXIT_BB): New.
5452 2009-03-04 Sebastian Pop <sebastian.pop@amd.com>
5454 * graphite-poly.c (print_pbb_domain, print_pbb, print_scop,
5455 debug_pbb_domain, debug_pbb, debug_scop): New.
5456 * graphite-poly.h (print_pbb_domain, print_pbb, print_scop,
5457 debug_pbb_domain, debug_pbb, debug_scop): Declared.
5459 2009-03-02 Sebastian Pop <sebastian.pop@amd.com>
5462 * tree-parloops.c (canonicalize_loop_ivs): Call fold_convert
5463 when the type precision of the induction variable should be
5464 larger than the type precision of nit.
5465 (gen_parallel_loop): Update use of canonicalize_loop_ivs.
5466 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Same.
5467 * tree-flow.h (canonicalize_loop_ivs): Update declaration.
5469 * gcc.dg/graphite/pr39335_1.c: New.
5470 * gcc.dg/graphite/pr39335.c: New.
5472 2009-03-02 Sebastian Pop <sebastian.pop@amd.com>
5474 * tree-parloops.c (canonicalize_loop_ivs): reduction_list contains
5475 SSA_NAMES not struct reduction_info.
5477 2009-03-02 Sebastian Pop <sebastian.pop@amd.com>
5479 * sese.c (expand_scalar_variables_expr): Handle ADDR_EXPR.
5481 2009-02-27 Sebastian Pop <sebastian.pop@amd.com>
5482 Tobias Grosser <grosser@fim.uni-passau.de>
5484 * sese.c (new_sese): Initialize SESE_REDUCTION_LIST.
5485 (free_sese): Free SESE_REDUCTION_LIST.
5486 * sese.h (struct sese): Add field reduction_list.
5487 (SESE_REDUCTION_LIST): New.
5488 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Call
5489 canonicalize_loop_ivs on SESE_REDUCTION_LIST.
5491 2009-02-27 Sebastian Pop <sebastian.pop@amd.com>
5492 Tobias Grosser <grosser@fim.uni-passau.de>
5494 * tree-flow.h (gather_scalar_reductions): Use struct loop * instead
5497 2009-02-27 Sebastian Pop <sebastian.pop@amd.com>
5498 Tobias Grosser <grosser@fim.uni-passau.de>
5500 * tree-parloops.c (struct brli, build_reduction_list_info,
5501 analyze_reduction_list, gather_scalar_reductions): New.
5502 (loop_parallel_p): Build a reduction list containing only
5503 PHI_RESULT SSA_NAMEs: call gather_scalar_reductions.
5504 (gen_parallel_loop): Call the analysis analyze_reduction_list.
5505 (parallelize_loops): Now reduction_list is a htab_t of SSA_NAMEs.
5506 * tree-flow.h (gather_scalar_reductions): Declared.
5508 2009-02-26 Sebastian Pop <sebastian.pop@amd.com>
5511 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not call
5512 number_of_iterations_exit from a gcc_assert.
5514 2009-02-25 Sebastian Pop <sebastian.pop@amd.com>
5515 Jan Sjodin <jan.sjodin@amd.com>
5517 * output.h (graphite_out_file, graphite_in_file): Declared.
5518 * toplev.c (graphite_out_file, graphite_in_file): New.
5519 (init_asm_output): Initialize graphite_in_file and graphite_out_file.
5520 * graphite-clast-to-gimple.c (build_cloog_prog): Read PBB_SCATTERING.
5521 Don't call schedule_to_scattering.
5522 * common.opt (fgraphite-write, fgraphite-read): New.
5523 * graphite-poly.c: Include output.h.
5524 (print_scattering_function, print_scattering_functions,
5525 debug_scattering_function, debug_scattering_functions,
5526 graphite_write_transforms, graphite_read_transforms,
5527 graphite_generate_scattering_fns): New.
5528 (apply_poly_transforms): Do not apply transform if flag_graphite_read.
5529 Call graphite_generate_scattering_fns, graphite_write_transforms,
5530 graphite_read_transforms.
5531 (new_poly_bb): Initialize PBB_SCATTERING.
5532 (free_poly_bb): Free PBB_SCATTERING.
5533 (schedule_to_scattering): Does not return, initialize PBB_SCATTERING.
5534 * graphite-poly.h (struct poly_bb): Add field scattering.
5535 (PBB_SCATTERING): New.
5536 (print_scattering_function, print_scattering_functions,
5537 debug_scattering_function, debug_scattering_functions): Declared.
5538 * graphite-ppl.c (cloog_matrix_to_ppl_constraint): Matrices contain
5539 GMP values, not integers!
5540 (ppl_print_polyhedron_matrix, debug_ppl_polyhedron_matrix,
5541 ppl_read_polyhedron_matrix): New.
5542 * graphite-ppl.h (ppl_print_polyhedron_matrix,
5543 debug_ppl_polyhedron_matrix,
5544 ppl_read_polyhedron_matrix): Declared.
5545 * Makefile.in (graphite-poly.o): Depends on output.h.
5547 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
5548 Tobias Grosser <grosser@fim.uni-passau.de>
5551 * graphite-scop-detection.c (stmt_simple_for_scop_p): Analyze
5552 scalar evolutions in the scop_entry->loop_father.
5554 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
5555 Tobias Grosser <grosser@fim.uni-passau.de>
5557 * graphite.h (ref_nb_loops): Remove declaration.
5558 (struct gimple_bb, gimple_bb_p, GBB_BB, GBB_DATA_REFS, GBB_CONDITIONS,
5559 GBB_CONDITION_CASES, GBB_CLOOG_IV_TYPES, gbb_loop, print_gimple_bb,
5560 debug_gbb): Moved to sese.h.
5563 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
5564 Tobias Grosser <grosser@fim.uni-passau.de>
5566 * graphite-data-ref.[ch]: Disable.
5568 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
5569 Tobias Grosser <grosser@fim.uni-passau.de>
5571 * graphite-scop-detection.c (stmt_simple_for_scop_p): Analyze
5572 scalar evolutions in the scop_entry->loop_father.
5574 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
5576 * graphite-scop-detection.c (nb_reductions_in_loop): Moved here...
5577 (graphite_cannot_represent_loop_niter): Renamed
5578 graphite_cannot_represent_loop. Call nb_reductions_in_loop.
5579 (limit_scops): build_sese_loop_nests does not return a bool.
5580 * graphite-scop-detection.h (nb_reductions_in_loop): Declared.
5581 * sese.c (nb_reductions_in_loop): ... from here.
5582 (graphite_loop_normal_form): ... from here.
5583 (sese_record_loop): Does not fail, so does not return a bool.
5584 (build_sese_loop_nests): Same.
5585 * sese.h (build_sese_loop_nests): Update declaration.
5586 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Moved here...
5587 (build_graphite_loop_normal_form): New.
5588 (gloog): Call build_graphite_loop_normal_form.
5589 * graphite-sese-to-poly.c (build_poly_scop): Don't fail on
5590 build_sese_loop_nests.
5592 * gcc.dg/graphite/id-1.c: New.
5594 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
5595 Tobias Grosser <grosser@fim.uni-passau.de>
5597 * graphite-sese-to-poly.c (scan_tree_for_params): Remove REAL_CST.
5598 The SCoP detection fix is sufficient.
5600 2009-02-21 Sebastian Pop <sebastian.pop@amd.com>
5602 PR tree-optimization/39260
5603 * graphite-scop-detection.c (harmful_stmt_in_bb): Stop a SCoP when
5604 the basic block contains a condition with a real type.
5605 * graphite-sese-to-poly.c (scan_tree_for_params): Handle REAL_CST.
5607 * gcc.dg/graphite/pr39260.c: New.
5609 2009-02-21 Sebastian Pop <sebastian.pop@amd.com>
5611 * graphite-poly.c: Inlcude params.h.
5612 (graphite_trans_loop_block): Use PARAM_LOOP_BLOCK_TILE_SIZE for
5614 * Makefile.in (graphite-poly.o): Depend on PARAMS_H.
5615 * params.def (PARAM_LOOP_BLOCK_TILE_SIZE): Define.
5617 2009-02-20 Sebastian Pop <sebastian.pop@amd.com>
5618 Tobias Grosser <grosser@fim.uni-passau.de>
5620 * graphite-scop-detection.c (dot_all_scops_1,
5621 dot_all_scops): Moved here.
5622 * graphite-scop-detection.h (dot_all_scops): Declared here.
5623 * graphite.c (graphite_initialize, graphite_finalize): New.
5624 (graphite_transform_loops): Cleaned up.
5625 * sese.c (debug_oldivs): Moved here.
5626 * graphite-poly.c (graphite_apply_transformations): Renamed
5627 apply_poly_transforms.
5628 (debug_loop_vec): Moved here.
5629 * graphite-sese-to-poly.c (build_bb_loops, build_sese_conditions_1,
5630 scop_contains_non_iv_scalar_phi_nodes, build_sese_conditions,
5631 find_scop_parameters, build_scop_iteration_domain,
5632 add_conditions_to_constraints, build_scop_canonical_schedules,
5633 build_scop_data_accesses): Now static.
5634 (build_poly_scop, check_poly_representation): New.
5636 2009-02-20 Sebastian Pop <sebastian.pop@amd.com>
5638 * graphite.c (graphite_stmt_p, new_gimple_bb, free_gimple_bb,
5639 remove_gbbs_in_scop, free_scops, try_generate_gimple_bb,
5640 build_scop_bbs, ref_nb_loops, compare_prefix_loops,
5641 build_scop_canonical_schedules, build_bb_loops, add_value_to_dim,
5642 scan_tree_for_params_right_scev, scan_tree_for_params_int,
5643 scan_tree_for_params, struct irp_data, dx_record_params,
5644 find_params_in_bb, find_scop_parameters, gbb_from_bb,
5645 build_loop_iteration_domains, add_conditions_to_domain,
5646 phi_node_is_iv, bb_contains_non_iv_scalar_phi_nodes,
5647 scop_contains_non_iv_scalar_phi_nodes, build_sese_conditions_1,
5648 build_sese_conditions, add_conditions_to_constraints,
5649 build_scop_iteration_domain, build_access_matrix_with_af,
5650 build_access_matrix,
5651 build_scop_data_accesses): Moved to graphite-sese-to-poly.c.
5653 * graphite-sese-to-poly.c: New.
5654 * graphite-sese-to-poly.h: New.
5656 * Makefile.in: Add new rule for graphite-sese-to-poly.o.
5658 2009-02-20 Sebastian Pop <sebastian.pop@amd.com>
5660 * graphite.c: Split graphite code generation to a new file.
5661 (graphite_verify, gmp_cst_to_tree, clast_name_to_gcc,
5662 max_precision_type, clast_to_gcc_expression_red,
5663 clast_to_gcc_expression, gcc_type_for_clast_expr,
5664 gcc_type_for_clast_eq, loop_iv_stack_patch_for_consts,
5665 graphite_translate_clast_equation, graphite_create_guard_cond_expr,
5666 graphite_create_new_guard, clast_get_body_of_loop,
5667 gcc_type_for_cloog_iv, gcc_type_for_iv_of_clast_loop,
5668 graphite_create_new_loop, build_iv_mapping, copy_renames,
5669 translate_clast, find_cloog_iv_in_expr, compute_cloog_iv_types_1,
5670 compute_cloog_iv_types, free_scattering, save_var_name,
5671 initialize_cloog_names, build_scop_context, build_cloog_prog,
5672 set_cloog_options, debug_clast_stmt, scop_to_clast,
5673 print_generated_program, debug_generated_program,
5674 gloog): Moved to graphite-clast-to-gimple.c.
5676 (struct cloog_prog_clast): Moved to graphite-clast-to-gimple.h.
5678 (iv_stack_entry_is_constant, iv_stack_entry_is_iv,
5679 loop_iv_stack_push_iv, loop_iv_stack_insert_constant,
5680 loop_iv_stack_pop, loop_iv_stack_get_iv,
5681 loop_iv_stack_get_iv_from_name, debug_loop_iv_stack,
5682 free_loop_iv_stack, loop_iv_stack_remove_constants,
5683 debug_rename_elt, debug_rename_map_1, debug_rename_map,
5684 rename_map_elt_info, eq_rename_map_elts, debug_ivtype_elt,
5685 debug_ivtype_map_1, debug_ivtype_map, ivtype_map_elt_info,
5686 eq_ivtype_map_elts, sese_add_exit_phis_edge,
5687 sese_add_exit_phis_var, sese_insert_phis_for_liveouts,
5688 get_vdef_before_sese, sese_adjust_vphi,
5689 get_new_name_from_old_name, sese_adjust_phis_for_liveouts,
5690 oldiv_for_loop, rename_variables_in_stmt, is_parameter,
5691 is_iv, expand_scalar_variables_ssa_name,
5692 expand_scalar_variables_expr, expand_scalar_variables_stmt,
5693 expand_scalar_variables, rename_variables, remove_condition,
5694 get_true_edge_from_guard_bb, get_false_edge_from_guard_bb,
5695 add_loop_exit_phis, insert_loop_close_phis, struct igp,
5696 default_liveout_before_guard, add_guard_exit_phis,
5697 insert_guard_phis, register_old_and_new_names,
5698 graphite_copy_stmts_from_block, register_sese_liveout_renames,
5699 copy_bb_and_scalar_dependences, outermost_loop_in_sese,
5700 if_region_set_false_region, create_if_region_on_edge,
5701 move_sese_in_condition): Moved to sese.c.
5703 (nb_loops_around_loop_in_sese, struct ifsese, if_region_entry,
5704 if_region_exit, if_region_get_condition_block,
5705 struct rename_map_elt, new_rename_map_elt, enum iv_stack_entry_kind,
5706 union iv_stack_entry_data_union, struct iv_stack_entry_struct,
5707 iv_stack_entry_p, loop_iv_stack, struct ivtype_map_elt,
5708 ivtype_map_elt, new_ivtype_map_elt,
5709 recompute_all_dominators): Moved to sese.h.
5711 * graphite-clast-to-gimple.c: New.
5712 * graphite-clast-to-gimple.h: New.
5713 * Makefile.in: Add new rule for graphite-clast-to-gimple.o.
5714 * sese.c: Modified as said above.
5717 2009-02-20 Sebastian Pop <sebastian.pop@amd.com>
5719 * graphite.c: Split scop detection to a new file.
5720 (enum gbb_type, gbb_type, get_bb_type, struct sd_region_p, sd_region,
5721 move_sd_regions, loop_affine_expr, exclude_component_ref,
5722 is_simple_operand, stmt_simple_for_scop_p, harmful_stmt_in_bb,
5723 graphite_cannot_represent_loop_niter, struct scopdet_info,
5724 scopdet_basic_block_info, build_scops_1, bb_in_sd_region,
5725 find_single_entry_edge, find_single_exit_edge,
5726 create_single_entry_edge, sd_region_without_exit,
5727 create_single_exit_edge, unmark_exit_edges, mark_exit_edges,
5728 create_sese_edges, build_graphite_scops, limit_scops, build_scops):
5729 Moved to graphite-scop-detection.c.
5731 * graphite-scop-detection.c: New.
5732 * graphite-scop-detection.h: New.
5733 * Makefile.in: Add new rule for graphite-scop-detection.o.
5735 * sese.c: Include tree-chrec.h, tree-data-ref.h, and
5736 tree-scalar-evolution.h.
5737 (nb_reductions_in_loop, graphite_loop_normal_form, sese_record_loop,
5738 build_sese_loop_nests): Moved here from graphite.c.
5739 (param_index): Renamed parameter_index_in_region.
5741 2009-02-18 Tobias Grosser <grosser@fim.uni-passau.de>
5742 Sebastian Pop <sebastian.pop@amd.com>
5744 * gcc.dg/graphite/block-0.c: Expected to fail now.
5745 * gcc.dg/graphite/block-1.c: Same.
5746 * gcc.dg/graphite/block-5.c: Same.
5747 * gcc.dg/graphite/block-6.c: Same.
5749 2009-02-18 Tobias Grosser <grosser@fim.uni-passau.de>
5750 Sebastian Pop <sebastian.pop@amd.com>
5752 * graphite.h: Separate from graphite_bb_p the polyhedral
5753 representation in poly_bb_p and the GCC specifics in gimple_bb_p.
5754 (struct data_dependence_polyhedron, RDGE_DDP, ddp_p): Moved to
5755 graphite-data-ref.h.
5756 (struct poly_bb, PBB_SCOP, PBB_STATIC_SCHEDULE, PBB_DOMAIN,
5757 PBB_BLACK_BOX, PBB_LOOPS, pbb_nb_loops, pbb_loop_at_index,
5758 pbb_loop_index, struct scop, SCOP_BBS, SCOP_REGION, SCOP_ENTRY,
5759 SCOP_EXIT, SCOP_REGION_BBS, SCOP_DEP_GRAPH, SCOP_PARAMS,
5760 SCOP_LOOP_NEST, SCOP_PARAMS, SCOP_OLDIVS, SCOP_LIVEOUT_RENAMES,
5761 scop_nb_params): Moved to graphite-poly.h.
5762 * graphite-data-ref.c: Same.
5763 * graphite-data-ref.h: New.
5765 (pbb_compare, graphite_sort_pbbs, graphite_trans_bb_move_loop,
5766 graphite_trans_bb_strip_mine, strip_mine_profitable_p,
5767 is_interchange_valid, graphite_trans_bb_block,
5768 graphite_trans_loop_block, scop_max_loop_depth,
5769 graphite_trans_scop_block, graphite_apply_transformations,
5770 new_poly_bb, free_poly_bb, new_scop, free_scop): Moved to
5772 * graphite-poly.h: New.
5773 * graphite-poly.c: New.
5774 * Makefile.in (OBJS-common): Add graphite-poly.o.
5775 (graphite-poly.o): New rule.
5776 * tree-data-ref.h (struct data_reference): Remove unused scop field.
5779 2009-02-18 Sebastian Pop <sebastian.pop@amd.com>
5780 Tobias Grosser <grosser@fim.uni-passau.de>
5782 * graphite.c: Replace gb -> gbb.
5784 * graphite-data-ref.c: Same.
5786 2009-02-18 Sebastian Pop <sebastian.pop@amd.com>
5787 Tobias Grosser <grosser@fim.uni-passau.de>
5789 * Makefile.in (OBJS-commmon): Add sese.o.
5791 (graphite.o): Add sese.h.
5792 * graphite.c (bb_in_ss_p, loop_in_sese_p,
5793 sese_build_livein_liveouts_use, sese_build_livein_liveouts_bb,
5794 sese_build_livein_liveouts, register_bb_in_sese, new_sese, free_sese):
5796 (block_before_scop): Add missing return.
5797 (new_scop, free_scop): Remove SESE data structures.
5798 (scop_record_loop, scan_tree_for_params, find_params_in_bb,
5799 find_scop_parameters, build_loop_iteration_domains,
5800 add_conditions_to_domain, register_scop_liveout_renames,
5801 copy_bb_and_scalar_dependences): Scop -> SESE.
5803 (add_conditions_to_domain): SCoP -> SESE and remove check
5804 (scop_contains_non_iv_scalar_phi_nodes): New.
5805 (build_scop_conditions_1, build_scop_conditions): Remove check for
5806 non iv scalar phi nodes.
5807 (print_scop_statistics): New.
5808 (graphite_transform_loops): Cleanup.
5810 * graphite.h: Move to sese & cleanup.
5814 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
5815 Tobias Grosser <grosser@fim.uni-passau.de>
5817 * graphite.c (build_scop_conditions_1): Conditions are only
5818 at the end of a basic block.
5820 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
5821 Tobias Grosser <grosser@fim.uni-passau>
5823 * graphite.h (struct graphite_bb): Remove compressed_alpha_matrix
5825 (GBB_ALPHA): Removed.
5827 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
5828 Tobias Grosser <grosser@fim.uni-passau.de>
5830 * graphite-data-ref.c (graphite_test_dependence): Don't use
5831 GBB_DYNAMIC_SCHEDULE.
5832 * graphite.c (new_graphite_bb): Same.
5833 (free_graphite_bb): Same.
5834 (build_scop_dynamic_schedules): Removed.
5835 (graphite_transform_loops): Don't call it.
5836 * graphite.h (struct graphite_bb): Remove dynamic_schedule field.
5837 (GBB_DYNAMIC_SCHEDULE): Removed.
5839 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
5840 Tobias Grosser <grosser@fim.uni-passau.de>
5842 * graphite.c (schedule_to_scattering): Don't use CloogMatrix.
5843 (print_graphite_bb): Same.
5844 (build_cloog_prog): Same.
5846 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
5847 Tobias Grosser <grosser@fim.uni-passau.de>
5849 * graphite.c (build_cloog_prog): Don't use CloogMatrix.
5851 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
5852 Tobias Grosser <grosser@fim.uni-passau.de>
5854 * graphite.c (build_scop_context): Don't use CloogMatrix.
5855 * graphite-ppl.c (new_Cloog_Domain_from_ppl_Polyhedron): New.
5856 * graphite-ppl.h (new_Cloog_Domain_from_ppl_Polyhedron): Declared.
5858 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
5859 Tobias Grosser <grosser@fim.uni-passau.de>
5861 * graphite.h (struct scop): Move params, old_ivs, loops, loop_nest,
5862 liveout_renames, add_params fields...
5863 (struct sese): ... here.
5864 (SESE_PARAMS, SESE_LOOPS, SESE_LOOP_NEST, SESE_ADD_PARAMS,
5865 SESE_PARAMS, SESE_OLDIVS, SESE_LIVEOUT_RENAMES): New.
5867 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
5868 Tobias Grosser <grosser@fim.uni-passau.de>
5870 * graphite.c (print_scop): Do not print the CLooG program.
5871 (new_scop, free_scop, initialize_cloog_names, build_scop_context,
5872 build_cloog_prog, gloog): Don't use SCOP_PROG.
5873 (find_transform): Renamed scop_to_clast.
5874 (print_generated_program, debug_generated_program): New.
5875 (graphite_transform_loops): Adapt to new interface.
5876 * graphite.h (struct scop): Remove program field.
5877 (SCOP_PROG): Removed.
5878 (print_generated_program, debug_generated_program): Declared.
5880 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
5882 * graphite-data-ref.c (schedule_precedes_p, schedule_same_p): New.
5883 (statement_precedes_p): Use schedule_same_p and schedule_precedes_p.
5884 * graphite.c (gbb_compare, schedule_to_scattering, print_graphite_bb,
5885 free_graphite_bb, build_scop_canonical_schedules,
5886 graphite_trans_bb_strip_mine, graphite_trans_scop_block): Static
5887 schedules are now represented using a ppl_Linear_Expression_t.
5888 * graphite.h (struct graphite_bb): Same.
5889 * graphite-ppl.c (ppl_lexico_compare_linear_expressions): New.
5890 * graphite-ppl.h (ppl_lexico_compare_linear_expressions): Declared.
5892 2009-02-15 Sebastian Pop <sebastian.pop@amd.com>
5894 * graphite.c: Free local memory.
5895 * graphite-ppl.c: Same.
5897 2009-02-15 Sebastian Pop <sebastian.pop@amd.com>
5899 * graphite.c (const_column_index, get_first_matching_sign_row_index,
5900 get_lower_bound_row, get_upper_bound_row, copy_constraint,
5901 swap_constraint_variables, scale_constraint_variable): Removed.
5902 (graphite_trans_bb_strip_mine): Remove pong.
5903 * graphite-ppl.c: Include missing header files.
5904 (set_inhomogeneous, set_coef, shift_poly, ppl_strip_loop): New.
5905 * graphite-ppl.h (ppl_strip_loop): Declared.
5906 * Makefile.in (graphite-ppl.o): Adjust dependences.
5908 2009-02-14 Sebastian Pop <sebastian.pop@amd.com>
5910 * graphite.c (build_loop_iteration_domains): Remove ping pong.
5911 (build_scop_iteration_domain): Same.
5913 2009-02-13 Sebastian Pop <sebastian.pop@amd.com>
5915 * graphite.c (scan_tree_for_params, add_conditions_to_domain): Remove
5917 (add_value_to_dim, scan_tree_for_params_right_scev,
5918 scan_tree_for_params_int): New.
5919 * graphite-ppl.c (oppose_constraint): New.
5920 (insert_constraint_into_matrix): Implement missing cases.
5921 * graphite-ppl.h (insert_constraint_into_matrix): Declared.
5923 2009-02-13 Sebastian Pop <sebastian.pop@amd.com>
5925 * graphite.c (graphite_trans_bb_move_loop): Remove ping pong,
5926 use ppl_move_dimension.
5928 2009-02-12 Sebastian Pop <sebastian.pop@amd.com>
5930 * graphite-data-ref.c: Domains are now ppl_Polyhedra_t.
5933 * graphite-ppl.c: Same.
5934 * graphite-ppl.h: Same.
5936 2009-02-12 Sebastian Pop <sebastian.pop@amd.com>
5938 Revert last 3 commits.
5940 2009-02-10 Sebastian Pop <sebastian.pop@amd.com>
5942 * graphite.c (scan_tree_for_params, add_conditions_to_domain): Remove
5944 (add_value_to_dim, scan_tree_for_params_right_scev,
5945 scan_tree_for_params_int): New.
5946 * graphite-ppl.c (oppose_constraint): New.
5947 (insert_constraint_into_matrix): Implement missing cases.
5948 * graphite-ppl.h (insert_constraint_into_matrix): Declared.
5950 2009-02-10 Sebastian Pop <sebastian.pop@amd.com>
5952 * graphite.c (graphite_trans_bb_move_loop): Remove unused variables.
5954 2009-02-10 Sebastian Pop <sebastian.pop@amd.com>
5955 Tobias Grosser <grosser@fim.uni-passau.de>
5957 * graphite.c (graphite_trans_bb_move_loop): Remove ping pong,
5958 use ppl_move_dimension.
5959 * graphite-ppl.c (ppl_move_dimension): New.
5960 * graphite-ppl.h (ppl_move_dimension): Declared.
5962 2009-02-10 Sebastian Pop <sebastian.pop@amd.com>
5964 * graphite.c: Do not include cloog/cloog.h.
5965 (print_graphite_bb): Remove ping pong, call PPL print function.
5967 2009-02-10 Tobias Grosser <grosser@fim.uni-passau.de>
5969 * Makefile.in (OBJS-common): Add graphite-ppl.o.
5970 (graphite.o): Add dependence on graphite-ppl.h.
5971 (graphite-ppl.o): New.
5972 (graphite-data-ref.c): Ping pong between PPL data structures
5974 * graphite-ppl.c: New.
5975 * graphite-ppl.h: New.
5976 * graphite.c: Include graphite-ppl.h.
5977 (print_graphite_bb, add_conditions_to_domain, build_cloog_prog,
5978 graphite_trans_bb_move_loop, graphite_trans_bb_strip_mine):
5979 Ping pong between PPL data structures and matrices.
5980 (new_graphite_bb): Create a PPL constraint system.
5981 Call ppl_delete_Constraint_System instead of cloog_matrix_free.
5982 (build_loop_iteration_domains): Use PPL functions.
5983 * graphite.h: Include graphite-ppl.h. Fix comments.
5984 (graphite_bb): Use a ppl_Constraint_System_t instead of
5985 CloogMatrix for representing the domain.
5986 (scop): Remove static_schedule.
5987 (gbb_nb_loops): Ping pong between PPL data structures and matrices.
5989 2009-02-06 Sebastian Pop <sebastian.pop@amd.com>
5991 * graphite.c: Fix some comments.
5993 2009-02-05 Sebastian Pop <sebastian.pop@amd.com>
5996 * graphite.c (if_region_set_false_region): After moving a region
5997 in the false branch of a condition, remove the empty dummy
5999 (gloog): Remove wrong fix for PR38953.
6001 2009-02-03 Tobias Grosser <grosser@fim.uni-passau.de>
6003 * graphite.c (bb_in_sese_p, sese_build_livein_liveouts_use,
6004 sese_build_livein_liveouts_bb, sese_build_livein_liveouts,
6005 register_bb_in_sese, new_sese, free_sese): Moved.
6006 (dot_scop_1, build_scop_loop_nests, build_loop_iteration_domains,
6007 outermost_loop_in_scop, build_scop_iteration_domain,
6008 expand_scalar_variables_ssa_name, get_vdef_before_scop,
6009 limit_scops): Use bb_in_sese_p instead of bb_in_scop_p.
6010 Use loop_in_sese_p instead of loop_in_scop_p.
6011 (new_graphite_bb, new_scop, gloog): Do not initialize SCOP_BBS_B.
6012 (free_scop): Do not free SCOP_BBS_B.
6013 (nb_loops_around_loop_in_scop, nb_loops_around_gb,
6014 ref_nb_loops): Moved here...
6015 * graphite.h (ref_nb_loops): ... from here.
6016 (struct scop): Remove bbs_b bitmap.
6017 (SCOP_BBS_B, bb_in_scop_p, loop_in_scop_p): Removed.
6018 * gcc.dg/graphite/scop-19.c: New
6020 2009-02-03 Tobias Grosser <grosser@fim.uni-passau.de>
6022 * graphite.c (scopdet_basic_block_info): Fix bug in scop
6025 2009-01-30 Tobias Grosser <grosser@fim.uni-passau.de>
6027 * graphite.c (new_loop_to_cloog_loop_str, hash_loop_to_cloog_loop,
6028 eq_loop_to_cloog_loop): Remove.
6029 (new_scop, free_scop): Remove SCOP_LOOP2CLOOG_LOOP.
6030 * graphite.h (struct scop): Remove loop2cloog_loop.
6031 (loop_domain_dim, loop_iteration_vector_dim): Remove.
6033 2009-01-30 Tobias Grosser <grosser@fim.uni-passau.de>
6035 * opts.c (decode_options): Only add graphite options to O2
6036 if we compile with graphite enabled.
6038 2009-01-26 Sebastian Pop <sebastian.pop@amd.com>
6040 * Merge from mainline (r143163:143684).
6042 2009-01-26 Sebastian Pop <sebastian.pop@amd.com>
6044 * graphite.c (debug_value): Removed.
6045 * graphite.h (debug_value): Removed.
6047 2009-01-23 Sebastian Pop <sebastian.pop@amd.com>
6049 * passes.c (init_optimization_passes): Do not call pass_copy_prop
6050 after graphite: pass_copy_prop does not maintain a proper loop closed
6051 SSA form. pass_copy_prop should be fixed.
6053 2009-01-23 Sebastian Pop <sebastian.pop@amd.com>
6055 * graphite.c (scop_adjust_phis_for_liveouts): Fix warning.
6057 2009-01-23 Sebastian Pop <sebastian.pop@amd.com>
6059 * graphite.c (graphite_verify): Add a call to verify_loop_closed_ssa.
6060 (gloog): Split the exit of the scop when the scop exit is a loop exit.
6061 (graphite_transform_loops): Only call cleanup_tree_cfg if gloog
6064 2009-01-20 Sebastian Pop <sebastian.pop@amd.com>
6066 * graphite.c (gloog): Return true when code gen succeeded.
6067 (graphite_transform_loops): Do not call cleanup_tree_cfg if
6068 the code of the function did not changed. After cleanup_tree_cfg
6069 call rewrite_into_loop_closed_ssa to maintain the loop closed ssa
6072 2009-01-19 Sebastian Pop <sebastian.pop@amd.com>
6074 * graphite.c (stmt_simple_for_scop_p): Also handle cases when
6075 gimple_call_lhs is NULL.
6077 2009-01-16 Sebastian Pop <sebastian.pop@amd.com>
6078 Tobias Grosser <tobi.grosser@amd.com>
6080 * graphite.c (graphite_trans_scop_block): Do not block single
6083 2009-01-15 Sebastian Pop <sebastian.pop@amd.com>
6084 Tobias Grosser <tobi.grosser@amd.com>
6086 * graphite.c (build_scop_canonical_schedules): Start schedules at
6089 2009-01-15 Sebastian Pop <sebastian.pop@amd.com>
6090 Tobias Grosser <tobi.grosser@amd.com>
6092 * graphite.c (compare_prefix_loops): New.
6093 (build_scop_canonical_schedules): Rewritten.
6094 (graphite_transform_loops): Move build_scop_canonical_schedules
6095 after build_scop_iteration_domain.
6097 2009-01-14 Sebastian Pop <sebastian.pop@amd.com>
6098 Tobias Grosser <tobi.grosser@amd.com>
6100 * graphite.c (add_conditions_to_domain): Add the loops to
6101 the dimension of the iteration domain. Do copy the domain
6102 only when it exists.
6103 (build_scop_conditions_1): Do not call add_conditions_to_domain.
6104 (add_conditions_to_constraints): New.
6105 (can_generate_code_stmt, can_generate_code): Removed.
6106 (gloog): Do not call can_generate_code.
6107 (graphite_transform_loops): Call add_conditions_to_constraints
6108 after building the iteration domain.
6110 2009-01-14 Sebastian Pop <sebastian.pop@amd.com>
6111 Tobias Grosser <tobi.grosser@amd.com>
6112 Jan Sjodin <jan.sjodin@amd.com>
6114 * graphite.c (scan_tree_for_params): On substractions negate
6115 all the coefficients of the term.
6116 (clast_to_gcc_expression_red): New. Handle reduction expressions
6117 of more than two operands.
6118 (clast_to_gcc_expression): Call clast_to_gcc_expression_red.
6119 (get_vdef_before_scop): Handle also the case of default definitions.
6121 2009-01-14 Sebastian Pop <sebastian.pop@amd.com>
6124 * graphite.c (get_vdef_before_scop, scop_adjust_vphi): New.
6125 (scop_adjust_phis_for_liveouts): Call scop_adjust_vphi.
6126 (gloog): Do not call cleanup_tree_cfg.
6127 (graphite_transform_loops): Call cleanup_tree_cfg after all
6128 scops have been code generated.
6130 2009-01-13 Sebastian Pop <sebastian.pop@amd.com>
6132 * passes.c (init_optimization_passes): Schedule after
6133 graphite transforms pass_copy_prop, pass_dce_loop and pass_lim.
6135 2009-01-13 Sebastian Pop <sebastian.pop@amd.com>
6137 * graphite.c (expand_scalar_variables_stmt): Do not pass loop_p.
6139 (expand_scalar_variables_ssa_name): Do not pass loop_p. Fix comment.
6140 Set the type of an expression to the type of its assign statement.
6141 (expand_scalar_variables_expr): Do not pass loop_p.
6142 Fix comment. Stop recursion on tcc_constant or tcc_declaration.
6143 (copy_bb_and_scalar_dependences): Do not pass loop_p.
6144 (translate_clast): Update call to copy_bb_and_scalar_dependences.
6146 2009-01-11 Sebastian Pop <sebastian.pop@amd.com>
6148 * graphite.c (expand_scalar_variables_ssa_name): Set the type of
6149 an expression to the gimple_expr_type of its assign statement.
6150 (expand_scalar_variables_expr): Stop recursion on tcc_constant
6153 2009-01-11 Sebastian Pop <sebastian.pop@amd.com>
6155 PR tree-optimization/38786
6156 * gcc.dg/graphite/pr38786.c: New.
6157 * graphite.c (expand_scalar_variables_ssa_name): New, outlined from
6158 the SSA_NAME case of expand_scalar_variables_expr.
6159 (expand_scalar_variables_expr): Also gather the scalar computation
6160 used to index the memory access.
6161 (expand_scalar_variables_stmt): Pass to expand_scalar_variables_expr
6162 the gimple_stmt_iterator where it inserts new code.
6164 2009-01-10 Sebastian Pop <sebastian.pop@amd.com>
6166 * gcc.dg/graphite/block-3.c: Fix compile error on 32bit.
6168 2009-01-10 Sebastian Pop <sebastian.pop@amd.com>
6170 * opts.c (decode_options): Enable flag_graphite_identity and
6171 flag_loop_block in -O2 and above.
6173 2009-01-08 Sebastian Pop <sebastian.pop@amd.com>
6175 * libjava/classpath/lib/gnu/java/awt/peer/gtk/GtkMouseInfoPeer.class:
6176 Fix merge problem: replace with the file from trunk.
6178 2009-01-08 Sebastian Pop <sebastian.pop@amd.com>
6180 * Merge from mainline (r141727:143163).
6182 2009-01-07 Sebastian Pop <sebastian.pop@amd.com>
6183 Jan Sjodin <jan.sjodin@amd.com>
6185 PR tree-optimization/38559
6186 * gcc.dg/graphite/pr38559.c: New.
6188 * graphite.c (debug_value, copy_constraint,
6189 swap_constraint_variables, scale_constraint_variable, ): New.
6190 (get_lower_bound, get_upper_bound): Removed.
6191 (graphite_trans_bb_strip_mine): Clean up this code that works
6192 only for constant number of iterations. Fully copy upper and
6193 lower bound constraints, not only the constant part of them.
6194 * graphite.h (debug_value): Declared.
6196 2009-01-06 Jan Sjodin <jan.sjodin@amd.com>
6198 PR tree-optimization/38492
6199 PR tree-optimization/38498
6200 * tree-check.c (operator_is_linear, scev_is_linear_expression): New.
6201 * tree-chrec.h (scev_is_linear_expression): Declared.
6202 * graphite.c (graphite_cannot_represent_loop_niter): New.
6203 (scopdet_basic_block_info): Call graphite_cannot_represent_loop_niter.
6204 (graphite_loop_normal_form): Use gcc_assert.
6205 (scan_tree_for_params): Use CASE_CONVERT.
6206 (phi_node_is_iv, bb_contains_non_iv_scalar_phi_nodes): New.
6207 (build_scop_conditions_1): Call bb_contains_non_iv_scalar_phi_nodes.
6208 Use gcc_assert. Discard scops that contain unhandled cases.
6209 (build_scop_conditions): Return a boolean status for unhandled cases.
6210 (strip_mine_profitable_p): Print the loop number, not its depth.
6211 (is_interchange_valid): Pass the depth of the loop nest, don't
6212 recompute it wrongly.
6213 (graphite_trans_bb_block): Same.
6214 (graphite_trans_bb_block): Print tentative of loop blocking.
6215 (graphite_trans_scop_block): Do not print that the loop has been
6217 (graphite_transform_loops): Do not handle scops that contain condition
6220 * gcc.dg/graphite/pr38500.c: Fixed warning as committed
6222 * gcc.dg/graphite/block-0.c: Update test.
6223 * gcc.dg/graphite/block-1.c: Same.
6224 * gcc.dg/graphite/block-2.c: Remove xfail and test for
6226 * gcc.dg/graphite/block-4.c: Remove test for strip mine.
6227 * gcc.dg/graphite/block-3.c: New.
6228 * gcc.dg/graphite/pr38498.c: New.
6230 2008-12-22 Harsha Jagasia <harsha.jagasia@amd.com>
6232 PR tree-optimization/38510
6233 * gcc.dg/graphite/pr38510.c: New.
6234 * graphite.c (recompute_all_dominators): Call mark_irreducible_loops.
6235 (translate_clast): Call recompute_all_dominators before
6237 (gloog): Call recompute_all_dominators before graphite_verify.
6239 2008-12-12 Sebastian Pop <sebastian.pop@amd.com>
6241 PR tree-optimization/38492
6242 * graphite.c (rename_map_elt, debug_rename_elt,
6243 debug_rename_map_1, debug_rename_map, new_rename_map_elt,
6244 rename_map_elt_info, eq_rename_map_elts,
6245 get_new_name_from_old_name, bb_in_sese_p): Moved around.
6246 (sese_find_uses_to_rename_use): Renamed sese_build_livein_liveouts_use.
6247 (sese_find_uses_to_rename_bb): Renamed sese_build_livein_liveouts_bb.
6248 (sese_build_livein_liveouts): New.
6249 (new_sese, free_sese): New.
6250 (new_scop): Call new_sese.
6251 (free_scop): Call free_sese.
6252 (rename_variables_from_edge, rename_phis_end_scop): Removed.
6253 (register_old_new_names): Renamed register_old_and_new_names.
6254 (register_scop_liveout_renames, add_loop_exit_phis,
6255 insert_loop_close_phis, struct igp,
6256 default_liveout_before_guard, add_guard_exit_phis,
6257 insert_guard_phis, copy_renames): New.
6258 (translate_clast): Call insert_loop_close_phis and insert_guard_phis.
6259 (sese_add_exit_phis_edge): Renamed scop_add_exit_phis_edge.
6260 (rewrite_into_sese_closed_ssa): Renamed scop_insert_phis_for_liveouts.
6261 (scop_adjust_phis_for_liveouts): New.
6262 (gloog): Call scop_adjust_phis_for_liveouts.
6264 * graphite.h (struct sese): Documented. Added fields liveout,
6266 (SESE_LIVEOUT, SESE_LIVEIN, SESE_LIVEIN_VER, SESE_NUM_VER): New.
6267 (new_sese, free_sese, sese_build_livein_liveouts): Declared.
6268 (struct scop): Added field liveout_renames.
6269 (SCOP_LIVEOUT_RENAMES): New.
6271 2008-12-11 Sebastian Pop <sebastian.pop@amd.com>
6273 PR tree-optimization/38409
6274 * gcc.dg/graphite/pr38409.c: New.
6275 * graphite.c (nb_reductions_in_loop): Use simple_iv.
6277 2008-12-11 Sebastian Pop <sebastian.pop@amd.com>
6279 * graphite.c (gcc_type_for_cloog_iv): By default return
6281 (graphite_create_new_loop): Don't fold_convert the already
6282 fold_convert-ed expression.
6284 2008-12-11 Harsha Jagasia <harsha.jagasia@amd.com>
6286 PR tree-optimization/38446
6287 * gcc.dg/graphite/pr38446.c: New.
6288 * graphite.c (register_bb_in_sese): New.
6289 (bb_in_sese_p): Check if bb belongs to sese region by explicitly
6290 looking at the bbs in the region.
6291 * graphite.h (sese): Add region_basic_blocks pointer set to
6292 structure and initialize at the time of defining new scop.
6294 2008-12-11 Tobias Grosser <grosser@fim.uni-passau.de>
6296 * graphite.c (new_graphite_bb): Initialize GBB_STATIC_SCHEDULE.
6297 (find_params_in_bb): Do not free data refs.
6298 (free_graphite_bb): Add FIXME on disabled free_data_refs.
6300 2008-12-11 Sebastian Pop <sebastian.pop@amd.com>
6302 * gcc.dg/graphite/scop-16.c: Test only scop specific info.
6303 * gcc.dg/graphite/scop-17.c: Same.
6304 * gcc.dg/graphite/block-5.c: New.
6305 * gcc.dg/graphite/block-6.c: New.
6306 * gcc.dg/graphite/pr37485.c: Clean dump file after.
6307 * gcc.dg/graphite/pr37684.c: Same.
6308 * gcc.dg/graphite/block-2.c: Same.
6310 * graphite.c (struct ivtype_map_elt): New.
6311 (debug_ivtype_elt, debug_ivtype_map_1, debug_ivtype_map,
6312 new_ivtype_map_elt, ivtype_map_elt_info, eq_ivtype_map_elts,
6313 gcc_type_for_cloog_iv): New.
6314 (loop_iv_stack_patch_for_consts): Use the type of the induction
6315 variable from the original loop, except for the automatically
6316 generated loops, i.e., in the case of a strip-mined loop, in
6317 which case there is no original loop: in that case just use
6319 (new_graphite_bb): Initialize GBB_CLOOG_IV_TYPES.
6320 (free_graphite_bb): Free GBB_CLOOG_IV_TYPES.
6321 (clast_name_to_gcc): Accept params to be NULL.
6322 (clast_to_gcc_expression): Take an extra parameter for the type.
6323 Convert to that type all the expressions built by this function.
6324 (gcc_type_for_clast_expr, gcc_type_for_clast_eq): New.
6325 (graphite_translate_clast_equation): Compute the type of the
6326 clast_equation before translating its LHS and RHS.
6327 (clast_get_body_of_loop, gcc_type_for_iv_of_clast_loop): New.
6328 (graphite_create_new_loop): Compute the type of the induction
6329 variable before translating the lower and upper bounds and before
6330 creating the induction variable.
6331 (rename_variables_from_edge, rename_phis_end_scop): New.
6332 (copy_bb_and_scalar_dependences): Call rename_phis_end_scop.
6333 (sese_add_exit_phis_edge): Do not use integer_zero_node.
6334 (find_cloog_iv_in_expr, compute_cloog_iv_types_1,
6335 compute_cloog_iv_types): New.
6336 (gloog): Call compute_cloog_iv_types before starting the
6337 translation of the clast.
6339 * graphite.h (struct graphite_bb): New field cloog_iv_types.
6340 (GBB_CLOOG_IV_TYPES): New.
6341 (debug_ivtype_map): Declared.
6342 (oldiv_for_loop): New.
6344 2008-12-10 Tobias Grosser <grosser@fim.uni-passau.de>
6347 * graphite.c (new_scop): Initialize SCOP_ADD_PARAMS.
6348 (param_index): Assert if parameter is not know after parameter
6350 (find_params_in_bb): Detect params directly in GBB_CONDITIONS.
6351 (find_scop_parameters): Mark, that we have finished parameter
6353 (graphite_transform_loops): Move condition detection before parameter
6355 * graphite.h (struct scop): Add SCOP_ADD_PARAMS.
6356 * gfortran.dg/graphite/pr38459.f90: New.
6358 2008-12-09 Tobias Grosser <grosser@fim.uni-passau.de>
6360 * graphite.c (graphite_transform_loops): Always call find_transform ()
6361 in ENABLE_CHECKING. So we test these code paths, even if we do not
6364 2008-12-09 Tobias Grosser <grosser@fim.uni-passau.de>
6366 * graphite.c (print_graphite_bb): Fix printing to file != dump_file.
6367 (print_scop): Ditto.
6369 2008-12-08 Tobias Grosser <grosser@fim.uni-passau.de>
6372 Fix gfortran.dg/graphite/id-3.f90.
6373 * graphite.c (scopdet_basic_block_info): Fix bug that found some
6374 regions more than once.
6376 2008-12-03 Sebastian Pop <sebastian.pop@amd.com>
6378 Fix gfortran.dg/graphite/id-4.f90.
6379 * graphite.c (scan_tree_for_params): Do not compute the multiplicand
6382 2008-12-03 Sebastian Pop <sebastian.pop@amd.com>
6384 Fix gfortran.dg/graphite/id-1.f90.
6385 * graphite.c (gmp_cst_to_tree): Pass the type in parameter.
6386 (loop_iv_stack_patch_for_consts): Update use of gmp_cst_to_tree.
6387 (max_precision_type): New.
6388 (value_clast): Removed.
6389 (clast_to_gcc_expression): Be more careful to types of expressions.
6390 Use max_precision_type and update use of gmp_cst_to_tree.
6391 (graphite_translate_clast_equation): Use max_precision_type.
6392 (graphite_create_guard_cond_expr): Do not use integer_type_node,
6393 use the type of the condition.
6394 (graphite_create_new_loop): Do not use integer_type_node, use the
6395 max_precision_type of lb and ub.
6397 2008-12-03 Sebastian Pop <sebastian.pop@amd.com>
6399 * graphite.c (build_scops_1): Initialize open_scop.exit
6402 2008-12-02 Sebastian Pop <sebastian.pop@amd.com>
6404 * gcc.dg/graphite/pr38084.c: New.
6405 * gfortran.dg/graphite/id-1.f90: New.
6406 * gfortran.dg/graphite/id-2.f90: New.
6407 * gfortran.dg/graphite/id-3.f90: New.
6408 * gfortran.dg/graphite/id-4.f90: New.
6409 * gfortran.dg/graphite/pr37857.f90: New.
6411 2008-12-02 Sebastian Pop <sebastian.pop@amd.com>
6412 Jan Sjodin <jan.sjodin@amd.com>
6413 Harsha Jagasia <harsha.jagasia@amd.com>
6425 * gcc.dg/graphite/pr38073.c: New.
6426 * gcc.dg/graphite/pr37928.c: New.
6427 * gcc.dg/graphite/pr37883.c: New.
6428 * gcc.dg/graphite/pr38125.c: New.
6429 * gfortran.dg/graphite/pr38083.f90: New.
6430 * gfortran.dg/graphite/pr37852.f90: New.
6431 * gfortran.dg/graphite/pr37980.f90: New.
6433 * gcc.dg/graphite/scop-18.c: Remove reduction, test for
6434 the number of detected scops. Copy exact same test for loop
6436 * gcc.dg/graphite/block-1.c: Fix the number of expected
6437 loops to be blocked as reductions are not handled.
6438 * gcc.dg/graphite/block-4.c: ...here. New.
6440 * tree-phinodes.c (remove_phi_nodes): New, extracted from...
6441 * tree-cfg.c (remove_phi_nodes_and_edges_for_unreachable_block):
6443 * tree-flow.h (remove_phi_nodes, canonicalize_loop_ivs): Declared.
6444 * Makefile.in (graphite.o): Depend on value-prof.h.
6445 (graphite.o-warn): Removed -Wno-error.
6446 * tree-parloops.c (canonicalize_loop_ivs): Allow reduction_list
6447 to be a NULL pointer. Call update_stmt. Return the newly created
6448 cannonical induction variable.
6450 * graphite.h (debug_rename_map): Declared. Fix some comments.
6452 * graphite.c: Reimplement the code generation from graphite to gimple.
6453 Include value-prof.h.
6454 (loop_iv_stack_get_iv): Do not return NULL for constant substitutions.
6455 (get_old_iv_from_ssa_name): Removed.
6456 (graphite_stmt_p): New.
6457 (new_graphite_bb): Test for useful statements before building a
6458 graphite statement for the basic block.
6459 (free_graphite_bb): Do not free GBB_DATA_REFS: this is a bug
6460 in free_data_ref that calls BITMAP_FREE (DR_VOPS (dr)) without
6462 (recompute_all_dominators, graphite_verify,
6463 nb_reductions_in_loop, graphite_loop_normal_form): New.
6464 (scop_record_loop): Call graphite_loop_normal_form.
6465 (build_scop_loop_nests): Iterate over all the blocks of the
6466 function instead of relying on the incomplete information from
6467 SCOP_BBS. Return the success of the operation.
6468 (find_params_in_bb): Use the data from GBB_DATA_REFS.
6469 (add_bb_domains): Removed.
6470 (build_loop_iteration_domains): Don't call add_bb_domains.
6471 Add the iteration domain only to the basic blocks that have been
6472 translated to graphite.
6473 (build_scop_conditions_1): Add constraints only if the basic
6474 block have been translated to graphite.
6475 (build_scop_data_accesses): Completely disabled until data
6476 dependence is correctly implemented.
6477 (debug_rename_elt, debug_rename_map_1, debug_rename_map): New.
6478 (remove_all_edges_1, remove_all_edges): Removed.
6479 (get_new_name_from_old_name): New.
6480 (graphite_rename_variables_in_stmt): Renamed
6481 rename_variables_in_stmt. Call get_new_name_from_old_name.
6482 Use replace_exp and update_stmt.
6483 (is_old_iv): Renamed is_iv.
6484 (expand_scalar_variables_stmt): Extra parameter for renaming map.
6485 Use replace_exp and update_stmt.
6486 (expand_scalar_variables_expr): Same. Use the map to get the
6487 new names for the renaming of induction variables and for the
6488 renaming of variables after a basic block has been copied.
6489 (expand_scalar_variables): Same.
6490 (graphite_rename_variables): Renamed rename_variables.
6491 (move_phi_nodes): Removed.
6492 (get_false_edge_from_guard_bb): New.
6493 (build_iv_mapping): Do not insert the induction variable of a
6494 loop in the renaming iv map if the basic block does not belong
6496 (register_old_new_names, graphite_copy_stmts_from_block,
6497 copy_bb_and_scalar_dependences): New.
6498 (translate_clast): Heavily reimplemented: copy basic blocks,
6499 do not move them. Finally, in call cleanup_tree_cfg in gloog.
6500 At each translation step call graphite_verify ensuring the
6501 consistency of the SSA, loops and dominators information.
6502 (collect_virtual_phis, find_vdef_for_var_in_bb,
6503 find_vdef_for_var_1, find_vdef_for_var,
6504 patch_phis_for_virtual_defs): Removed huge hack.
6505 (mark_old_loops, remove_dead_loops, skip_phi_defs,
6506 collect_scop_exit_phi_args, patch_scop_exit_phi_args,
6507 gbb_can_be_ignored, scop_remove_ignoreable_gbbs, ): Removed.
6508 (remove_sese_region, ifsese, if_region_entry, if_region_exit,
6509 if_region_get_condition_block, if_region_set_false_region,
6510 create_if_region_on_edge, move_sese_in_condition, bb_in_sese_p,
6511 sese_find_uses_to_rename_use, sese_find_uses_to_rename_bb,
6512 sese_add_exit_phis_edge, sese_add_exit_phis_var,
6513 rewrite_into_sese_closed_ssa): New.
6514 (gloog): Remove dead code. Early return if code cannot be
6515 generated. Call cleanup_tree_cfg once the scop has been code
6517 (graphite_trans_scop_block, graphite_trans_loop_block): Do not
6518 block loops with less than two loops.
6519 (graphite_apply_transformations): Remove the call to
6520 scop_remove_ignoreable_gbbs.
6521 (limit_scops): When build_scop_loop_nests fails, continue on
6522 the next scop. Fix open_scop.entry.
6523 (graphite_transform_loops): Call recompute_all_dominators: force the
6524 recomputation of correct CDI_DOMINATORS and CDI_POST_DOMINATORS.
6525 Call initialize_original_copy_tables and free_original_copy_tables
6526 to be able to copy basic blocks during code generation.
6527 When build_scop_loop_nests fails, continue on next scop.
6528 (value_clast): New union.
6529 (clast_to_gcc_expression): Fix type cast warning.
6531 2008-11-09 Sebastian Pop <sebastian.pop@amd.com>
6533 * Merge from mainline (r140838:141727).
6535 2008-11-05 Tobias Grosser <grosser@fim.uni-passau.de>
6539 * graphite.c (scan_tree_for_params): Add POINTER_PLUS_EXPR.
6541 2008-11-05 Tobias Grosser <grosser@fim.uni-passau.de>
6545 * graphite.c (scopdet_basic_block_info): Fix loops with multiple
6546 exits and conditions.
6547 * gcc.dg/graphite/pr37943.c: New.
6549 2008-10-23 Tobias Grosser <grosser@fim.uni-passau.de>
6552 * graphite.c (gloog): Replace EXIT_BLOCK_PTR with scop exit.
6554 2008-10-23 Tobias Grosser <grosser@fim.uni-passau.de>
6556 * doc/invoke.texi: Fix spaces.
6558 2008-10-22 Sebastian Pop <sebastian.pop@amd.com>
6560 PR tree-optimization/37891
6561 Reverted last commit.
6562 * graphite.c (create_single_entry_edge): Set
6563 EDGE_IRREDUCIBLE_LOOP and BB_IRREDUCIBLE_LOOP.
6565 2008-10-21 Sebastian Pop <sebastian.pop@amd.com>
6566 Mitul Thakkar <mitul.thakkar@amd.com>
6568 * graphite.c (create_single_entry_edge): Set
6569 EDGE_IRREDUCIBLE_LOOP and BB_IRREDUCIBLE_LOOP.
6571 2008-10-16 Tobias Grosser <grosser@fim.uni-passau.de>
6573 * doc/invoke.texi: Add -fgraphite-identity.
6574 * graphite.c (graphite_apply_transformations): Check for
6575 -fgraphite-identity.
6576 * toplev.c (process_options): Add flag_graphite_identity.
6577 * tree-ssa-loop.c: Add flag_graphite_identity.
6579 2008-10-14 Sebastian Pop <sebastian.pop@amd.com>
6581 Undo changes from 2008-10-02:
6582 * tree-ssa-loop-ivopts.c (rewrite_use_nonlinear_expr): Convert
6583 operand type when copying the operand to a variable of different type.
6584 * cfgloopmanip.c (create_empty_loop_on_edge): Write exit condition
6585 with the IV name after increment.
6587 2008-10-14 Sebastian Pop <sebastian.pop@amd.com>
6588 Harsha Jagasia <harsha.jagasia@amd.com>
6590 PR tree-optimization/37828
6591 * gcc.dg/graphite/pr37828.c: New.
6592 * graphite.c (graphite_trans_loop_block): Do not loop block
6593 single nested loops.
6595 2008-10-09 Harsha Jagasia <harsha.jagasia@amd.com>
6596 Sebastian Pop <sebastian.pop@amd.com>
6598 * graphite.c (struct rename_map_elt, new_rename_map_elt,
6599 rename_map_elt_info, eq_rename_map_elts): New.
6600 (graphite_rename_ivs_stmt): Renamed graphite_rename_variables_in_stmt.
6601 (expand_scalar_variables_expr): Change parameters.
6602 (expand_scalar_variables_stmt): Same.
6603 (expand_scalar_variables): Same.
6604 (graphite_rename_ivs): Rename graphite_rename_variables.
6605 (build_iv_mapping): New.
6606 (translate_clast): Call build_iv_mapping.
6607 * graphite.h (gbb_p): New name.
6609 2008-10-03 Harsha Jagasia <harsha.jagasia@amd.com>
6611 PR tree-optimization/37684
6612 * gcc.dg/graphite/pr37684.c: New.
6613 * graphite.c (exclude_component_ref): New.
6614 (is_simple_operand): Call exclude_component_ref.
6616 2008-10-02 Jan Sjodin <jan.sjodin@amd.com>
6617 Harsha Jagasia <harsha.jagasia@amd.com>
6619 PR tree-optimization/37485
6620 * gcc.dg/graphite/block-2.c: New
6621 * graphite.c (gmp_cst_to_tree): Moved.
6622 (iv_stack_entry_is_constant): New.
6623 (iv_stack_entry_is_iv): New.
6624 (loop_iv_stack_push): Renamed to loop_iv_stack_push_iv.
6625 (loop_iv_stack_insert_constant): New.
6626 (loop_iv_stack_pop): Use new datatpype.
6627 (loop_iv_stack_get_iv): Same.
6628 (loop_iv_stack_get_iv_from_name): Same.
6629 (loop_iv_stack_debug): Renamed to debug_loop_iv_stack.
6630 (loop_iv_stack_patch_for_consts): New.
6631 (loop_iv_stack_remove_constants): New.
6632 (graphite_create_new_loop): Use loop_iv_stack_push_iv.
6633 (translate_clast): Call loop_iv_stack_patch_for_consts and
6634 loop_iv_stack_remove_constants.
6635 (gloog): Use new datatype. Redirect construction edge to end
6636 block to avoid accidental deletion.
6637 * graphite.h (enum iv_stack_entry_kind): New. Tag for data in
6639 (union iv_stack_entry_data): New. Data in iv stack entry.
6640 (struct iv_stack_entry): New. Datatype for iv stack entries.
6642 2008-10-02 Sebastian Pop <sebastian.pop@amd.com>
6644 * tree-ssa-loop-ivopts.c (rewrite_use_nonlinear_expr): Convert
6645 operand type when copying the operand to a variable of different type.
6647 2008-10-02 Sebastian Pop <sebastian.pop@amd.com>
6649 * cfgloopmanip.c (create_empty_loop_on_edge): Write exit condition
6650 with the IV name after increment.
6652 2008-10-02 Sebastian Pop <sebastian.pop@amd.com>
6654 * Merge from mainline (r140164:140838).
6656 2008-09-10 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6658 * graphite-data-ref.c: New.
6659 * graphite.c (print_scop): Also dump the dependence graph.
6660 (bb_in_scop_p, loop_in_scop_p, nb_loops_around_gb): Moved...
6661 (new_scop): Initialize SCOP_DEP_GRAPH.
6662 (build_scop_dynamic_schedules): New.
6663 (build_access_matrix_with_af): Fixed column numbering.
6664 (graphite_transform_loops): Call build_scop_dynamic_schedules.
6665 * graphite.h: Add ifndef/define guards against multiple inclusion.
6666 (struct scop): Add dep_graph field.
6667 (SCOP_DEP_GRAPH): Defined.
6668 (ref_nb_loops): Fixed and moved to other position.
6669 (bb_in_scop_p, loop_in_scop_p, nb_loops_around_gb): ... here.
6670 (nb_loops_around_loop_in_scop): New.
6671 (graphite_dump_dependence_graph): Declared.
6672 (graphite_build_rdg_all_levels): Declared.
6673 (graphite_test_dependence): Declared.
6674 * Makefile.in (graphite-data-ref.o): New target.
6676 2008-09-09 Sebastian Pop <sebastian.pop@amd.com>
6678 * Merge from mainline (139870:140164).
6680 2008-09-01 Sebastian Pop <sebastian.pop@amd.com>
6682 * Merge from mainline (138275:139870).
6683 * gcc.dg/graphite/scop-matmult.c: XFailed as one of
6684 the commits from trunk broke the niter detection.
6686 2008-09-01 Sebastian Pop <sebastian.pop@amd.com>
6688 * graphite.c: Add more documentation. Fix formatting.
6689 (debug_loop_vec, debug_oldivs, loop_iv_stack,
6690 loop_iv_stack_debug): Moved...
6691 (schedule_to_scattering): Move before use.
6692 (dot_all_scops): Include in "#if 0" the code for system
6695 * graphite.h: (debug_loop_vec, debug_oldivs, loop_iv_stack,
6696 loop_iv_stack_debug): ...here.
6698 2008-08-29 Jan Sjodin <jan.sjodin@amd.com>
6700 * tree-phinodes.c (make_phi_node): Extern.
6701 (add_phi_node_to_bb): New.
6702 (create_phi_node): Call add_phi_node_to_bb.
6703 * tree-ssa-loop-ivopts.c (get_phi_with_result): New.
6704 (remove_statement): Handle case where stored phi was updated
6705 and is no longer the same.
6706 * graphite.c (is_parameter): New.
6708 (expand_scalar_variables_expr): New.
6709 (expand_scalar_variables_stmt): New.
6710 (expand_scalar_variables): New.
6711 (move_phi_nodes): Create new phi instead of moving old one.
6712 (translate_clast): Call expand_scalar_variables.
6713 (find_vdef_for_var_in_bb): Also scan regular definitions.
6714 (skip_phi_defs): New.
6715 (collect_scop_exit_phi_args): New.
6716 (patch_scop_exit_phi_args): New.
6717 (gloog): Patch phis after scop.
6718 * tree-flow.h: (add_phi_node_to_bb): Declared.
6719 (make_phi_node): Declared.
6721 2008-08-26 Sebastian Pop <sebastian.pop@amd.com>
6723 * graphite.c (end_scop): Split the entry of the scop when it
6724 is the header of the loop in which the scop is ending.
6725 (build_scops_1, limit_scops): Update uses of end_scop.
6727 2008-08-26 Sebastian Pop <sebastian.pop@amd.com>
6729 * graphite.c (dot_all_scops_1): Do not fail on uninitialized
6730 SCOP_ENTRY or SCOP_EXIT.
6732 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
6734 * graphite.c (get_construction_edge): Removed.
6735 (gloog): Construction edge is the scop entry edge.
6737 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
6739 * graphite.c (can_generate_for_scop): Removed.
6740 (gloog): Do not call it.
6742 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
6744 * graphite.c (new_scop): Entry of a scop is an edge.
6745 Initialize SESE region.
6746 (free_scop): Free SESE region.
6747 (build_scops_1, scopdet_bb_info): Work on edges, not on bbs.
6748 (split_difficult_bb): New, split from end_scop.
6749 (end_scop): Exit of a scop is an edge.
6750 (build_scop_bbs): Never check CDI_POST_DOMINATORS: this info is
6751 not automatically updated and thus is always wrong.
6752 * graphite.h (struct sese): New.
6755 (struct scop): New field for a SESE region. Remove entry, exit.
6756 (SCOP_ENTRY, SCOP_EXIT): Update definitions to match same
6757 semantics as before. Moved comment around.
6759 2008-08-25 Tobias Grosser <grosser@fim.uni-passau.de>
6760 Sebastian Pop <sebastian.pop@amd.com>
6762 * graphite.c (graphite_transform_loops): Always enable gloog
6763 and find_transform when ENABLE_CHECKING.
6765 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
6767 * graphite.c (graphite_transform_loops): Move pretty printer
6768 of SCOPs before doing any transform. Remove call to print_scops
6769 and dot_all_scops_1.
6771 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
6773 * graphite.c (dump_gbb_conditions): Don't try to print NULL pointers.
6774 (print_graphite_bb): Same.
6776 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
6778 * graphite.c (dot_all_scops_1): Cleanup.
6779 (move_scops): Fix comment.
6781 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
6783 * graphite.c (build_scop_bbs): Revert commit 139355:
6785 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
6786 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
6788 * graphite.c (build_scop_bbs): Factor up code.
6790 2008-08-25 Tobias Grosser <grosser@fim.uni-passau.de>
6792 * graphite.c (gloog): Update dominator info.
6794 2008-08-25 Tobias Grosser <grosser@fim.uni-passau.de>
6796 * graphite.c (remove_cond_exprs): Do not fail on empty bbs.
6798 2008-08-24 Sebastian Pop <sebastian.pop@amd.com>
6800 * graphite.c (new_graphite_bb): Remove GBB_INDEX_TO_NUM_MAP
6802 (free_graphite_bb): Remove GBB_INDEX_TO_NUM_MAP free.
6803 (translate_clast): Correct formatting.
6804 * graphite.h (struct num_map): Removed.
6805 (struct graphite_bb): Remove num_map field.
6806 (GBB_INDEX_TO_NUM_MAP): Removed.
6808 2008-08-24 Sebastian Pop <sebastian.pop@amd.com>
6810 * graphite.c (build_access_matrix_with_af): Fix comments.
6811 (build_scop_data_accesses): Same.
6813 2008-08-24 Sebastian Pop <sebastian.pop@amd.com>
6815 * graphite.c (build_scop_data_accesses): Don't construct
6816 access matrices. Add a FIXME and an assert condition that
6817 should pass when the access matrices will be needed.
6819 2008-08-24 Sebastian Pop <sebastian.pop@amd.com>
6821 * tree-data-ref.c (stmt_simple_memref_p): Don't call
6823 * graphite.c (build_graphite_bb): Renamed new_graphite_bb.
6824 Moved close by free_graphite_bb.
6825 (free_graphite_bb): Call free_data_refs. Reset bb->aux.
6826 (new_scop): Move close by free_scop.
6827 (graphite_transform_loops): Avoid linear scan to reset bb->aux.
6829 2008-08-22 Jan Sjodin <jan.sjodin@amd.com>
6831 * cfgloopmanip.c (create_empty_if_region_on_edge): New.
6832 * graphite.c (clast_to_gcc_expression): Call gmp_cst_to_tree
6833 instead of recursive call.
6834 (graphite_translate_clast_equation): New.
6835 (graphite_create_guard_cond_expr): New.
6836 (graphite_create_new_guard): New.
6837 (get_stack_index_from_iv): Removed.
6838 (graphite_rename_ivs_stmt): Use gbb_loop_index.
6839 (get_true_edge_from_guard_bb): New.
6840 (translate_clast): Handle stmt_guard in clast.
6841 (get_construction_edge): Allow construction edge detection for
6842 a scope entry with multiple predecessors if one predecessor is
6843 the immediate dominator of scope entry.
6844 (can_generate_code_stmt): Enable code generation for clast_guard.
6845 (gloog): Use correct context loop. Removed check for post dominators.
6846 * cfgloop.h (create_empty_if_region_on_edge): Declared.
6848 2008-08-21 Sebastian Pop <sebastian.pop@amd.com>
6850 * graphite.c (remove_dead_loops): Document better which
6853 2008-08-21 Sebastian Pop <sebastian.pop@amd.com>
6855 * Makefile.in: Rename POLYLIBLIBS and POLYLIBINC to PPLLIBS
6857 (graphite.o): Also depends on pointer-set.h.
6859 2008-08-21 Sebastian Pop <sebastian.pop@amd.com>
6861 * graphite.c (scop_record_loop): Fix compile warning.
6863 2008-08-21 Harsha Jagasia <harsha.jagasia@amd.com>
6864 Sebastian Pop <sebastian.pop@amd.com>
6866 * graphite.c (scop_record_loop): DECL_NAME can be NULL.
6868 2008-08-21 Sebastian Pop <sebastian.pop@amd.com>
6870 * graphite.c (build_graphite_bb): Initialize bb->aux to
6871 point to the graphite_bb_p.
6872 (graphite_bb_from_bb): Renamed gbb_from_bb; returns the
6874 (add_bb_domains): Does not use the scop parameter.
6875 (graphite_transform_loops): Clean bb->aux at the end.
6877 2008-08-20 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
6878 Sebastian Pop <sebastian.pop@amd.com>
6880 * lib/target-supports.exp
6881 (check_effective_target_fgraphite): New.
6883 * gcc.dg/graphite/graphite.exp: Early exit when
6884 check_effective_target_fgraphite returns false.
6885 Set dg-do-what-default to compile.
6886 (scan-graphite-dump-times): Removed.
6887 * gfortran.dg/graphite/graphite.exp: Same.
6889 * gcc.dg/graphite/scop-0.c: Do not use "dg-do compile".
6890 Use scan-tree-dump-times instead of scan-graphite-dump-times.
6891 * gcc.dg/graphite/scop-1.c: Same.
6892 * gcc.dg/graphite/scop-2.c: Same.
6893 * gcc.dg/graphite/scop-3.c: Same.
6894 * gcc.dg/graphite/scop-4.c: Same.
6895 * gcc.dg/graphite/scop-5.c: Same.
6896 * gcc.dg/graphite/scop-6.c: Same.
6897 * gcc.dg/graphite/scop-7.c: Same.
6898 * gcc.dg/graphite/scop-8.c: Same.
6899 * gcc.dg/graphite/scop-9.c: Same.
6900 * gcc.dg/graphite/scop-10.c: Same.
6901 * gcc.dg/graphite/scop-11.c: Same.
6902 * gcc.dg/graphite/scop-12.c: Same.
6903 * gcc.dg/graphite/scop-13.c: Same.
6904 * gcc.dg/graphite/scop-matmult.c: Same.
6905 * gcc.dg/graphite/scop-14.c: Same.
6906 * gcc.dg/graphite/scop-15.c: Same.
6907 * gcc.dg/graphite/block-0.c: Same.
6908 * gcc.dg/graphite/scop-16.c: Same.
6909 * gcc.dg/graphite/block-1.c: Same.
6910 * gcc.dg/graphite/scop-17.c: Same.
6911 * gcc.dg/graphite/scop-18.c: Same.
6912 * gfortran.dg/graphite/block-1.f90: Same.
6913 * gfortran.dg/graphite/scop-1.f: Same.
6914 * gfortran.dg/graphite/block-2.f: Same.
6916 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
6918 * graphite.c: Fix some XXX comments.
6919 (build_scop_dynamic_schedules): Removed.
6921 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
6923 * graphite.h (scop_max_loop_depth): Moved...
6924 * graphite.c (scop_max_loop_depth): ...here.
6925 (remove_all_edges_1): New.
6926 (remove_all_edges): Factored code.
6927 (remove_cond_exprs): Check only the last statement for
6928 a GIMPLE_COND expression.
6930 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
6932 * graphite.c (scan_tree_for_params): Early return when the
6933 expression is a chrec_dont_know. Handle case NEGATE_EXPR.
6934 (find_scop_parameters): Factor out code.
6935 (graphite_trans_bb_strip_mine): Remove dead code.
6937 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
6939 * graphite.c (clast_to_gcc_expression, graphite_create_new_loop,
6940 graphite_trans_bb_move_loop): Factor asserts.
6941 (gloog): Perform sanity checks only for ENABLE_CHECKING.
6942 Do not call calculate_dominance_info and estimate_bb_frequencies.
6944 2008-08-20 Jan Sjodin <jan.sjodin@amd.com>
6946 * graphite.c (create_loops_mapping, free_loops_mapping,
6947 create_loops_mapping_num, debug_loop_mapping_1,
6948 debug_loop_mapping, graphite_loops_mapping_max_loop_num,
6949 get_loop_mapping_for_num, graphite_loops_mapping_add_child,
6950 graphite_loops_mapping_add_child_num,
6951 graphite_loops_mapping_insert_child,
6952 graphite_loops_mapping_parent, get_loop_mapped_depth_for_num,
6953 get_loop_mapped_depth, split_loop_mapped_depth_for_num,
6954 loop_mapped_depth_split_loop, swap_loop_mapped_depth_for_num,
6955 create_num_from_index, get_num_from_index,
6956 swap_loop_mapped_depth): Removed.
6957 (new_scop): Do not initialize SCOP_LOOPS_MAPPING.
6958 (free_scop): Do not call free_loops_mapping.
6959 (graphite_get_new_iv_stack_index_from_old_iv): Renamed
6960 get_stack_index_from_iv. Use GBB_LOOPS instead of calling
6961 get_loop_mapped_depth.
6962 (graphite_trans_bb_move_loop): Do not update the loop mapping.
6963 (graphite_trans_bb_strip_mine): Same.
6964 * graphite.h (graphite_loops_mapping, graphite_loop_node): Removed.
6965 (struct scop): Remove field loops_mapping.
6967 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
6968 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
6970 * graphite.c (scop_record_loop): Factor out one level of the
6971 condition by early return.
6972 (build_scop_loop_nests): Format following FSF coding style.
6973 (build_scop_dynamic_schedules): Factor out code.
6974 (scopdet_bb_info): Reindent. Default case should not be reachable.
6976 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
6977 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
6979 * graphite.c (loop_affine_expr): Check for DECL_P or struct
6980 assignments that are not handled as simple operands for now.
6982 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
6983 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
6985 * graphite.c (build_scop_bbs): Factor up code.
6987 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
6988 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
6990 * graphite.c (stmt_simple_for_scop_p): Factor code out
6992 (enum gbb_type): New. Group all the GBB_* types under it.
6993 (is_loop_exit): Moved...
6994 (end_scop): Enable BB spliting.
6995 * cfgloop.c (is_loop_exit): ...here. Reimplemented.
6996 * cfgloop.h (is_loop_exit): Declared.
6998 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
7000 * doc/invoke.texi: Remove strides from examples containing
7001 DO loops when the strides are equal to 1.
7003 2008-08-20 Harsha Jagasia <harsha.jagasia@amd.com>
7004 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
7006 * graphite.c (graphite_trans_scop_block): Or the result with
7007 the result from graphite_trans_loop_block.
7008 * gcc.dg/graphite/block-1.c: New.
7009 * gfortran.dg/graphite/block-1.f90: New.
7010 * gfortran.dg/graphite/block-2.f: New.
7012 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
7014 * graphite.c (graphite_transform_loops): Call cloog_initialize
7017 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
7019 * tree-data-ref.c) (stmt_simple_memref_p): New.
7020 * tree-data-ref.h (stmt_simple_memref_p): Declared.
7021 * graphite.c (stmt_simple_memref_for_scop_p): Removed.
7022 (is_simple_operand): Call stmt_simple_memref_p.
7024 * gcc.dg/graphite/scop-matmult.c: Updated for not
7025 using pointer arithmetic, as this is optimized by PRE and
7026 makes the code too difficult to analyze.
7028 * gcc.dg/graphite/scop-18.c: Same.
7030 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
7032 * gdbinit.in (pgg): New.
7034 2008-08-15 Tobias Grosser <grosser@fim.uni-passau.de>
7036 * graphite.c (graphite_trans_loop_block): Fix warning.
7038 2008-08-15 Tobias Grosser <grosser@fim.uni-passau.de>
7040 * graphite.c (graphite_trans_loop_block): Fix my merge error.
7042 2008-08-15 Tobias Grosser <grosser@fim.uni-passau.de>
7044 * graphite.c (graphite_trans_bb_block): Remove check for
7045 flag_loop_strip_mine, flag_loop_block, flag_loop_interchange.
7046 Check if loop blocking is profitable for every loop, before applying
7048 (graphite_apply_transformations): Call graphite_trans_bb_block only,
7049 if flag_loop_block is set.
7051 2008-08-14 Sebastian Pop <sebastian.pop@amd.com>
7053 * graphite.c: Add some more documentation for the loop
7056 2008-08-14 Sebastian Pop <sebastian.pop@amd.com>
7058 * Makefile.in (tree-data-ref.o): Remove dependence on graphite.h.
7059 * graphite.c: Format on less than 80 columns.
7062 2008-08-14 Sebastian Pop <sebastian.pop@amd.com>
7064 * cfgloopmanip.c (loopify): Use update_dominators_in_loop.
7066 2008-08-14 Sebastian Pop <sebastian.pop@amd.com>
7068 * doc/invoke.texi (floop-block, floop-strip-mine,
7069 floop-interchange): Update documentation with examples.
7071 2008-08-13 Sebastian Pop <sebastian.pop@amd.com>
7073 * cfgloopmanip.c (create_empty_loop_on_edge): Don't call
7075 * graphite.c (graphite_create_new_loop): Call add_referenced_var.
7077 2008-08-13 Sebastian Pop <sebastian.pop@amd.com>
7079 * cfgloopmanip.c (create_empty_loop_on_edge): Improve documentation.
7080 Factor gcc_asserts into a single one. Use force_gimple_operand_gsi.
7081 * tree-scalar-evolution.c: Revert useless changes.
7082 * tree-phinodes.c: Same.
7085 * tree-vectorizer.h: Same.
7086 * tree-flow.h: Same.
7088 * common.opt (fgraphite): Update documentation.
7090 2008-08-12 Harsha Jagasia <harsha.jagasia@amd.com>
7092 * doc/invoke.texi (-floop-block, -floop-strip-mine,
7093 -floop-interchange): Add more text for explaining what each of these
7095 * tree-into-ssa.c (gimple_vec): Moved to...
7096 * graphite.c: Include gimple.h.
7097 (gimple_vec): Moved to...
7098 (del_loop_to_cloog_loop): Removed.
7099 (loop_affine_expr): Do not call create_data_ref when the
7100 operand is a constant.
7101 (new_scop): Use free instead of del_loop_to_cloog_loop.
7102 * Makefile.in (graphite.o): Depend on GIMPLE_H.
7103 * gimple.h (gimple_vec): ... here.
7105 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
7107 * graphite.c (scopdet_bb_info): Only allow loops with known number of
7109 (build_loop_iteration_domains): Fail, if latch executions unknown.
7111 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
7113 * graphite.c (add_conditions_to_domain): New.
7114 (build_scop_conditions_1): Call add_conditions_to_domain.
7115 (set_cloog_options): Allow to disable optimizations.
7117 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
7119 * graphite.c (find_params_in_bb): Look for parameters in conditions.
7120 Do not use walk_dominator_tree.
7121 (find_scop_parameters): Do not use walk_dominator_tree.
7123 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
7125 * graphite.c (scan_tree_for_params) Add / Subtract inequality.
7126 (idx_record_params): Adapt.
7127 * graphite.h (scop_gimple_loop_depth): New.
7129 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
7131 * graphite.c (build_scop_dynamic_schedules): Remove value_init.
7132 (scan_tree_for_params): Remove value_init.
7133 (build_scop_context): Remove value_init.
7134 (build_loop_iteration_domains): Remove value_init.
7135 (schedule_to_scattering): Remove value_init.
7136 (graphite_trans_bb_strip_mine): Remove value_init.
7138 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
7140 * gcc/graphite.c (limit_scops): New.
7141 (graphite_transform_loops): Add limit SCoPs.
7142 * gcc.dg/graphite/scop-0.c: Update number of SCoPs.
7143 * gcc.dg/graphite/scop-1.c: Update number of SCoPs.
7144 * gcc.dg/graphite/scop-10.c: Update number of SCoPs.
7145 * gcc.dg/graphite/scop-11.c: Update number of SCoPs.
7146 * gcc.dg/graphite/scop-12.c: Update number of SCoPs.
7147 * gcc.dg/graphite/scop-13.c: Update number of SCoPs.
7148 * gcc.dg/graphite/scop-14.c: Update number of SCoPs.
7149 * gcc.dg/graphite/scop-15.c: Update number of SCoPs.
7150 * gcc.dg/graphite/scop-16.c: Update number of SCoPs.
7151 Change loop numbers.
7152 * gcc.dg/graphite/scop-17.c: Update number of SCoPs.
7153 Change loop numbers.
7154 * gcc.dg/graphite/scop-18.c: Update number of SCoPs.
7155 * gcc.dg/graphite/scop-2.c: Update number of SCoPs.
7156 * gcc.dg/graphite/scop-3.c: Update number of SCoPs.
7157 * gcc.dg/graphite/scop-4.c: Update number of SCoPs.
7158 * gcc.dg/graphite/scop-5.c: Update number of SCoPs.
7159 * gcc.dg/graphite/scop-6.c: Update number of SCoPs.
7160 * gcc.dg/graphite/scop-7.c: Update number of SCoPs.
7161 * gcc.dg/graphite/scop-8.c: Update number of SCoPs.
7162 * gcc.dg/graphite/scop-9.c: Update number of SCoPs.
7163 * gcc.dg/graphite/scop-matmult.c: Update number of SCoPs.
7165 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
7167 * graphite.c (graphite_transform_loops): Call always find_transform.
7169 2008-08-08 Tobias Grosser <grosser@fim.uni-passau.de>
7171 * graphite.c (free_loops_mapping): New.
7172 (stmt_simple_for_scop_p): Fix typo.
7173 (stmt_simple_for_scop_p): Fix tuples functions, that
7175 (free_graphite_bb): Fix some memleaks.
7176 (free_scop): Fix some memleaks.
7177 (scopdet_bb_info): Do not forget some tmp SCoPs.
7178 (find_params_in_bb): Fix some memleaks.
7179 (clast_to_gcc_expression): Fix warning.
7181 2008-08-07 Tobias Grosser <grosser@fim.uni-passau.de>
7183 * gcc.dg/graphite/scop-16.c: Fix for 32bit.
7184 * gcc.dg/graphite/scop-17.c: Fix for 32bit.
7186 2008-08-04 Sebastian Pop <sebastian.pop@amd.com>
7188 * tree-ssa-loop.c (tree-ssa-loop.o): Do not include toplev.h.
7189 Move code ifdef-ed HAVE_cloog...
7190 * graphite.c: Include toplev.h.
7192 * Makefile.in (OBJS-common): Always build graphite.o.
7193 (BACKEND): Remove @GRAPHITE@.
7194 (tree-ssa-loop.o): Do not depend on TOPLEV_H.
7195 (graphite.o): Depend on TOPLEV_H.
7197 2008-08-04 Sebastian Pop <sebastian.pop@amd.com>
7199 * Makefile.in (tree-ssa-loop.o): Depend on TOPLEV_H.
7200 Remove typo left from polylib to ppl conversion.
7201 * graphite.c (graphite_transforms): Use sorry instead of fatal.
7203 2008-08-03 Sebastian Pop <sebastian.pop@amd.com>
7205 * toplev.c (process_options): Move the graphite loop optimization
7207 * tree-ssa-loop.c (graphite_transforms): ... here.
7208 When not configured with CLooG, print to dump_file that
7209 Graphite transforms were not performed.
7210 * gcc.dg/graphite/graphite.exp (scan-graphite-dump-times):
7212 * gcc.dg/graphite/*.c: Updated all testcases to use
7213 scan-graphite-dump-times.
7215 2008-08-03 Sebastian Pop <sebastian.pop@amd.com>
7217 * graphite.c (dot_scop, dot_all_scops): Do not call system.
7218 Do not open /tmp/scop.dot and /tmp/allscops.dot.
7220 2008-08-02 Sebastian Pop <sebastian.pop@amd.com>
7221 Jan Sjodin <jan.sjodin@amd.com>
7223 * configure: Regenerated.
7224 * omp-low.c (expand_omp_sections): Remove now unused code.
7225 * config.in (HAVE_polylib): Removed.
7226 * configure.ac (HAVE_polylib, POLYLIBLIBS, POLYLIBINC): Removed.
7227 (PPLLIBS, PPLINC): Added.
7228 * graphite.c: Replace unsigned with int wherever possible.
7229 Don't access Cloog's data structures, but use accessor functions.
7230 Clast's stmt->type is now implemented as a vtable: change the
7231 switches of stmt->type into ifs.
7232 (polylib/polylibgmp.h): Don't include.
7233 (initialize_dependence_polyhedron,
7234 initialize_data_dependence_polyhedron, is_empty_polyhedron,
7235 statement_precedes_p, test_dependence, build_rdg_all_levels,
7236 dump_dependence_graph): Removed until this code is cleaned up
7238 * Makefile.in (POLYLIBLIBS): Renamed PPLLIBS.
7239 (POLYLIBINC): Renamed PPLINC.
7241 2008-08-01 Harsha Jagasia <harsha.jagasia@amd.com>
7242 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
7243 Jan Sjodin <jan.sjodin@amd.com>
7245 Finish the merge and tuplification of graphite.
7247 2008-07-24 Sebastian Pop <sebastian.pop@amd.com>
7248 Jan Sjodin <jan.sjodin@amd.com>
7250 Partial merge from mainline (138072:138275).
7251 * graphite.c still has to be tuplified.
7253 2008-07-29 Jan Sjodin <jan.sjodin@amd.com>
7255 * graphite.c (graphite_loops_mapping_max_loop_num): New.
7256 (create_num_from_index): New.
7257 (get_num_from_index): Also pass in the graphite BB.
7258 (free_graphite_bb): Free GBB_INDEX_TO_NUM_MAP.
7259 (build_graphite_bb): Initialize GBB_INDEX_TO_NUM_MAP.
7260 (graphite_trans_bb_strip_mine): Call create_num_from_index.
7261 (is_interchange_valid): Return false when failing.
7262 * graphite.h (struct num_map): New.
7263 (struct graphite_bb): New field num_map.
7264 (GBB_LOOPS_MAPPING): Renamed GBB_INDEX_TO_NUM_MAP.
7266 2008-07-29 Tobias Grosser <grosser@fim.uni-passau.de>
7268 * graphite.c (dump_gbb_conditions): Print also conditions like
7269 "if (a)". Remove dublicated code and use print_generic_expr ().
7270 (stmt_simple_for_scop_p): Only allow conditions we can handle
7273 2008-07-25 Jan Sjodin <jan.sjodin@amd.com>
7275 * graphite.h (struct scop): Removed new_ivs field.
7276 (SCOP_NEWIVS): Deleted.
7277 * graphite.c (new_scop, free_scop, clast_name_to_gcc,
7278 clast_to_gcc_expression, graphite_create_new_loop):
7279 Removed use of new_ivs.
7281 2008-07-25 Jan Sjodin <jan.sjodin@amd.com>
7283 * graphite.c (debug_oldivs, debug_loop_vec, create_loops_mapping,
7284 create_loops_mapping_num, debug_loop_mapping_1): New.
7285 (debug_loop_mapping): Call debug_loop_mapping_1.
7286 (get_loop_mapping_for_num,
7287 graphite_loops_mapping_add_child,
7288 graphite_loops_mapping_add_child_num,
7289 graphite_loops_mapping_insert_child,
7290 graphite_loops_mapping_parent,
7291 split_loop_mapped_depth_for_num,
7292 loop_mapped_depth_split_loop): New.
7293 (increment_loop_mapped_depths): Removed.
7294 (swap_loop_mapped_depth_for_num): Reimplemented.
7295 (new_scop): Call create_loops_mapping.
7296 (scop_record_loop): Call graphite_loops_mapping_insert_child.
7297 (translate_clast): Pass the old loop father in parameter, and pass
7298 it to get_old_iv_from_ssa_name.
7299 (remove_edges_around_useless_blocks, can_generate_code_stmt,
7300 can_generate_code, can_generate_for_scop): New.
7301 (graphite_trans_bb_block): Returns false when it fails to transform.
7302 * graphite.h (graphite_loop_node, graphite_loops_mapping): New.
7304 2008-07-25 Sebastian Pop <sebastian.pop@amd.com>
7306 Reverted all the changes related to the streamization and
7308 These changes are now tracked in the streamization branch.
7310 2008-07-25 Sebastian Pop <sebastian.pop@amd.com>
7311 Jan Sjodin <jan.sjodin@amd.com>
7313 * graphite.c (gbb_compare): Correctly constify.
7314 (gbb_can_be_ignored): Indent.
7315 (graphite_trans_scop_swap_1and2): Add legality check.
7318 2008-07-25 Sebastian Pop <sebastian.pop@amd.com>
7320 Remove fallouts from "Reverted the Condate changes".
7321 * tree.h: Remove unused decl.
7322 * gcc.dg/tree-checker: Same.
7323 * timevar.def: Remove counter.
7325 2008-07-24 Sebastian Pop <sebastian.pop@amd.com>
7327 * Merge from mainline (135673:138072).
7329 Reverted the MIRO changes (from 2008-04-05) that are now
7330 tracked in the miro branch.
7331 * tree-bounds.c: Removed.
7332 * tree-bounds.h: Removed.
7334 Reverted the Condate changes (from 2006-07-04, 2007-03-20) that
7335 are now tracked in the condate branch.
7336 * tree-check.c: Removed.
7337 * tree-match.c: Removed.
7338 * condate.y: Removed.
7340 2008-07-24 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
7342 * common.opt: New user flag -floop-block, -floop-strip-mine
7343 and -floop-interchange.
7344 * toplev.c (process_options): Enable -fgraphite pass if any one of the
7345 graphite loop optimization flags is turned on.
7346 * graphite.c (graphite_apply_transformations): Add flag_loop_block,
7347 flag_loop_strip_mine and flag_loop_interchange checks before
7349 * doc/invoke.texi: Remove -fgraphite and add -floop-block,
7350 -floop-strip-mine and -floop-interchange.
7351 * gcc.dg/graphite/block-0.c: Add -floop-block and remove
7353 * gcc.dg/graphite/scop-16.c: Ditto.
7354 * gcc.dg/graphite/scop-17.c: Ditto.
7355 * gcc.dg/graphite/scop-18.c: Ditto.
7357 2008-07-23 Jan Sjodin <jan.sjodin@amd.com>
7358 Sebastian Pop <sebastian.pop@amd.com>
7360 * cfgloopmanip.c (update_dominators_in_loop): Make it static.
7361 (create_empty_loop_on_edge): More fixes.
7362 * tree-phinodes.c (resize_phi_node): Extern.
7363 (unlink_phi_node, move_phi_node): New split from remove_phi_node.
7364 * cfghooks.c (update_dominator_information): New split from
7366 * tree-vectorizer.c (rename_variables_in_bb): Extern.
7367 * tree-dfa.c (collect_dfa_stats): Start walking the CFG on the
7368 successor of the function entry block.
7370 * graphite.c: Include pointer-set.h.
7371 (debug_loop_mapping, increment_loop_mapped_depths,
7372 get_loop_mapped_depth_for_num, get_loop_mapped_depth,
7373 set_loop_mapped_depth_for_num, set_loop_mapped_depth,
7374 swap_loop_mapped_depth_for_num, get_num_from_index,
7375 swap_loop_mapped_depth, loop_iv_stack_debug,
7376 loop_iv_stack_push, loop_iv_stack_pop, loop_iv_stack_get_iv,
7377 loop_iv_stack_get_iv_from_name, loop_iv_stack_debug,
7378 get_old_iv_from_ssa_name): New.
7379 (new_scop): Initialize SCOP_LOOPS_MAPPING.
7380 (free_scop): Free SCOP_LOOPS_MAPPING.
7381 (scop_record_loop): Record old ivs.
7382 (create_var_name): Removed.
7383 (initialize_cloog_names): Allocate double space in case strip mine
7384 applies to all loops once.
7385 (clast_name_to_gcc): Look up in the map ivstack passed in parameter.
7386 (clast_to_gcc_expression): Same. Implement more clast to gimple
7388 (graphite_create_new_loop): Pass in ivstack.
7389 (remove_all_edges): Pass in the construction_edge.
7390 (graphite_remove_iv): Removed.
7391 (graphite_rename_ivs, graphite_rename_ivs_stmt,
7392 remove_cond_exprs): Rewritten.
7393 (move_phi_nodes): New.
7394 (disconnect_virtual_phi_nodes, disconnect_cond_expr): Removed.
7395 (translate_clast): Pass in ivstack. Rewrite some cases.
7396 (set_cloog_options, debug_clast_stmt): New.
7397 (find_transform): Use set_cloog_options.
7398 (outermost_loop_layer): Removed.
7399 (get_construction_edge, collect_virtual_phis, find_vdef_for_var_in_bb,
7400 find_vdef_for_var_1, find_vdef_for_var, patch_phis_for_virtual_defs,
7401 mark_old_loops, remove_dead_loops): New.
7403 (graphite_trans_bb_move_loop): Call swap_loop_mapped_depth.
7404 (const_column_index, get_first_matching_sign_row_index,
7405 get_lower_bound_row, get_upper_bound_row, get_lower_bound,
7406 get_upper_bound): New.
7407 (graphite_trans_bb_strip_mine): Also update the iv map.
7409 * graphite.h (graphite_loops_mapping, GBB_LOOPS_MAPPING): New.
7410 (struct name_tree): Add a loop field.
7411 (struct scop): Add a graphite_loops_mapping field.
7412 (SCOP_LOOPS_MAPPING): New.
7413 (debug_clast_stmt): Declare.
7414 * lambda.h (find_induction_var_from_exit_cond): Declare.
7415 (lambda-code.c): (find_induction_var_from_exit_cond): Extern.
7416 * cfgloop.h (update_dominators_in_loop): Removed declaration.
7417 (create_empty_loop_on_edge): Updated.
7418 * tree-flow.h (remove_bb, resize_phi_node, move_phi_node,
7419 rename_variables_in_bb): Declare.
7420 * tree-cfg.c (remove_bb): Extern.
7422 * gcc.dg/graphite/block-0.c: New.
7424 2008-07-21 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
7425 Sebastian Pop <sebastian.pop@amd.com>
7427 * graphite.c (strip_mine_profitable_p): New.
7428 (graphite_trans_bb_block): Disable strip mining if not profitable.
7430 * gcc.dg/graphite/scop-18.c: New.
7431 * gcc.dg/graphite/scop-17.c: Fixed.
7432 * gcc.dg/graphite/scop-16.c: Fixed.
7434 2008-07-17 Harsha Jagasia <harsha.jagasia@amd.com>
7435 Jan Sjodin <jan.sjodin@amd.com>
7436 Sebastian Pop <sebastian.pop@amd.com>
7438 * graphite.c (is_interchange_valid): New.
7439 (graphite_trans_bb_block): Check loop nest of basic block for legality
7442 * graphite.h (gbb_inner_most_loop_index, outer_most_loop_1,
7443 outer_most_loop, gbb_outer_most_loop_index): New.
7445 * tree-loop-linear.c (perfect_loop_nest_depth): Remove static.
7446 * tree-flow.h (perfect_loop_nest_depth): Declare as extern.
7447 * gcc.dg/graphite/scop-16.c: New.
7448 * gcc.dg/graphite/scop-17.c: New.
7450 2008-07-11 Tobias Grosser <grosser@fim.uni-passau.de>
7452 * graphite.c (scop_remove_ignoreable_gbbs): Also update bitmap.
7453 (graphite_trans_scop_block): Ignore SCoPs without bbs.
7455 2008-07-11 Tobias Grosser <grosser@fim.uni-passau.de>
7457 * graphite.c (new_scop): Initialize SCOP_EXIT.
7458 (scopdet_info): Add.
7459 (scopdet_bb_info): Rename from is_bb_addable. Cleanup, bugfixes.
7460 (build_scops_1): Cleanup, bugfixes.
7461 (build_scops): Cleanup.
7463 * gcc.dg/graphite/scop-matmult.c: Remove duplicated code.
7464 * gcc.dg/graphite/scop-15.c: Add SCoP numbers.
7466 2008-07-10 Harsha Jagasia <harsha.jagasia@amd.com>
7468 * gfortran.dg/graphite/scop-1.f: Update to reduced test case.
7470 * gfortran.dg/graphite/graphite.exp: Use
7471 DEFAULT_GRAPHITE_FLAGS.
7473 * gcc.dg/graphite/scop-15.c: Update to reduced test case.
7475 2008-07-10 Harsha Jagasia <harsha.jagasia@amd.com>
7477 * graphite.c (scan_tree_for_params): Do not assert any more if
7478 MULT_EXPR parameter is negative.
7480 * gfortran.dg/graphite/scop-1.f: New.
7482 * gfortran.dg/graphite/graphite.exp: New.
7484 * gcc.dg/graphite/scop-15.c: New.
7486 2008-07-10 Harsha Jagasia <harsha.jagasia@amd.com>
7488 * graphite.c (is_bb_addable): Fix segfault in spec gzip and reformat.
7490 2008-07-10 Tobias Grosser <grosser@fim.uni-passau.de>
7492 * graphite.c (graphite_trans_bb_swap_loops): Rename from
7493 graphite_swap_loops.
7494 (graphite_trans_bb_move_loop): New.
7495 (graphite_trans_bb_strip_mine): Rename from graphite_strip_mine_loop.
7496 (graphite_trans_bb_block): New.
7497 (graphite_trans_loop_block): New.
7498 (graphite_trans_scop_swap_1and2): Rename from
7499 graphite_trans_swap_1and2.
7500 (graphite_trans_scop_strip): Rename from graphite_trans_strip.
7501 (graphite_trans_scop_block): New.
7502 (graphite_apply_transformations): Rename from
7503 graphite_transformations.
7505 * gcc.dg/graphite/scop-matmult.c: New.
7507 2008-07-10 Tobias Grosser <grosser@fim.uni-passau.de>
7509 * graphite.c (gbb_compare): New.
7510 (graphite_sort_gbbs): New.
7511 (gbb_can_be_ignored): New.
7512 (scop_remove_ignoreable_gbbs): New.
7513 (graphite_transformations): Cleanup and add
7514 scop_remove_ignoreable_gbbs.
7515 * lambda.h (lambda_vector_compare): New.
7517 2008-07-09 Tobias Grosser <grosser@fim.uni-passau.de>
7519 * graphite.c (print_graphite_bb): Correct printing of static schedule.
7520 (graphite_swap_loops): int -> unsigned
7521 (graphite_strip_mine_loop): int -> unsigned, Fix SCHEDULE
7522 (graphite_transformations): New.
7523 (graphite_transform_loops): Move to graphite_transformations.
7524 * graphite.h (gbb_nb_loops): Return unsigned.
7526 2008-07-04 Tobias Grosser <grosser@fim.uni-passau.de>
7528 * graphite.c (scan_tree_for_params): Fix insertion of parameters into
7529 the domain matrix. This makes scop-0.c work again.
7531 2008-06-20 Richard Guenther <rguenther@suse.de>
7533 * graphite.h: Adjust copyright to GPLv3.
7534 * graphite.c: Likewise.
7535 (stmt_simple_memref_for_scop_p): Split out from ...
7536 (stmt_simple_for_scop_p): ... here. Fix handling of calls
7538 (get_bb_type): Optimize.
7540 (is_bb_addable): Fix memleak, replace is_pred call with
7542 (build_scops): Use current_loops.
7543 (param_index): Fix memleak.
7545 2008-06-20 Konrad Trifunovic <konrad.trifunovic@inria.fr>
7547 * graphite.c: Fix formatting.
7549 2008-06-19 Konrad Trifunovic <konrad.trifunovic@inria.fr>
7551 * graphite.c (new_scop): Memory allocation for SCOP_{NEWIVS, OLDIVS}.
7552 (free_scop): Memory deallocation for SCOP_NEWIVS, SCOP_OLDIVS.
7553 (create_var_name, save_var_name): Newly defined functions.
7554 (initialize_cloog_names): Part of the code factored out to
7556 (clast_to_gcc_expression): Now handles the case of clast_red_sum
7557 in clast_reduction statement.
7558 (graphite_create_new_loop): Now takes a new parameter
7560 (translate_clast): Now also takes the context_loop and bb_exit
7561 parameters. Rewritten the code so that it creates a gimple code
7562 inside the given context.
7563 (outermost_loop_layer, graphite_remove_iv, graphite_rename_ivs,
7564 remove_cond_expr, disconnect_cond_expr,
7565 disconnect_virtual_phi_nodes): Newly defined functions.
7566 * graphite.h (struct scop): added old_ivs vector.
7567 SCOP_OLDIVS: New macro.
7569 2008-06-19 Sebastian Pop <sebastian.pop@amd.com>
7571 * cfgloopmanip.c: Add missing function comments, fix formatting.
7573 2008-06-18 Konrad Trifunovic <konrad.trifunovic@inria.fr>
7575 * cfgloopmanip.c (update_dominators_in_loop): Defined.
7576 (create_empty_loop_on_edge): Defined.
7577 * tree-parloops.c (canonicalize_loop_ivs): Returns tree
7579 * cfgloop.h (create_empty_loop_on_edge): Declared as extern.
7580 (update_dominators_in_loop): Declared as extern
7581 * tree-flow.h (canonicalize_loop_ivs): Declared as extern.
7583 2008-06-16 Tobias Grosser <grosser@fim.uni-passau.de>
7585 * graphite.c (print_graphite_bb): Allow changing number of loops
7587 (initialize_cloog_names): Allow changing number of loops.
7588 (build_cloog_prog): Simplify.
7589 (find_transform): Enable cloog option --strides.
7590 (graphite_swap_loops): New.
7591 (graphite_strip_mine_loop): New.
7592 (graphite_trans_swap_1and2): New.
7593 (graphite_trans_strip): New.
7594 (graphite_transform_loops): Add graphite_trans_strip.
7595 * graphite.h (scop_max_loop_depth): New.
7597 2008-06-15 Tobias Grosser <grosser@fim.uni-passau.de>
7599 * graphite.c (build_scop_iteration_domain): Remove forgotten
7600 line. (Fixes compile)
7602 2008-06-15 Tobias Grosser <grosser@fim.uni-passau.de>
7604 * graphite.c (print_graphite_bb): Add output of GBB_LOOPS.
7605 (build_graphite_bb): Add GBB_LOOPS and GBB_DOMAIN and reorder.
7606 (build_bb_loops): New.
7607 (graphite_transform_loops): Add build_bb_loops.
7608 (schedule_to_scattering): Use gbb_nb_loops to support changing loop
7610 * graphite.h (graphite_bb): Add loops.
7611 (gbb_nb_loops): New.
7612 (gbb_loop_at_index): New.
7613 (gbb_loop_index): New.
7614 (nb_params_in_scop): Renamed to scop_nb_params. Updated all functions
7615 using nb_params_in_scop.
7617 2008-06-14 Tobias Grosser <grosser@fim.uni-passau.de>
7619 * graphite.c (print_graphite_bb): Adapt to minimized schedule.
7620 (build_scop_canonical_schedules): Build minimized schedule.
7621 (schedule_to_scattering): Adapt to minimized schedule.
7622 * graphite.h (graphite_bb): Add/Update descriptions.
7624 2008-06-14 Adrien Eliche <aeliche@isty.uvsq.fr>
7625 Tobias Grosser <grosser@fim.uni-passau.de>
7627 * graphite.c (print_graphite_bb): Add condition printing.
7629 (dump_gbb_conditions): New.
7630 (build_scop_conditions_1): New.
7631 (build_scop_conditions): New.
7632 * graphite.h (graphite_bb): Add conditions.
7634 2008-06-14 Tobias Grosser <grosser@fim.uni-passau.de>
7636 * graphite.c (print_graphite_bb):
7637 (free_graphite_bb): New.
7638 (free_scop): Free bbs.
7639 (get_bb_type): Free doms.
7640 (build_scop_context): Free context matrix.
7641 (build_loop_iteration_domains): Remove unused code.
7642 (build_cloog_prog): Free scattering function and blocklist.
7643 (find_transform): Free options.
7645 2008-06-13 Tobias Grosser <grosser@fim.uni-passau.de>
7647 * graphite.c (loop_body_to_cloog_stmts): Rename to add_bb_domains.
7648 Remove unnecessery cloog data structures. Make a copy of the domain
7649 (setup_cloog_loop): Rename to build_loop_iteration_domains. Remove
7650 unnecessary cloog data structures. Fix memory leaks. Remove insert
7651 into SCOP_LOOP2CLOOG_LOOP as the inserted CloogLoops will never be
7653 (build_scop_iteration_domain): Remove unnecessary cloog
7654 data structures. Fix memory leaks.
7655 (graphite_transform_loops): Disable build_scop_dynamic_schedules as it
7656 uses SCOP_LOOP2CLOOG_LOOP, that is at the moment not working.
7658 2008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
7660 * graphite.c (find_scop_params): Remove initialize_cloog_names.
7662 2008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
7664 * graphite.c (end_scop): Style fix.
7665 (schedule_to_scattering): Style and comment fix.
7667 2008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
7668 * graphite.c (print_graphite_bb): Fix definiton of
7669 schedule_to_scattering.
7670 (initialize_cloog_names): Change nb_scattdims to max loop
7672 (schedule_to_scattering): Take parameter for number of scattering
7674 (build_cloog_prog): Only build as much scattering dimensions as
7677 2008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
7679 * graphite.c (end_scop): Disable bb splitting. Fixes SIGSEGV
7680 in polyhedron/aermod.f90.
7682 2008-06-11 Tobias Grosser <grosser@fim.uni-passau.de>
7683 Dwarak Rajagopal <dwarak.rajagopal@amd.com>
7684 Harsha Jagasia <harsha.jagasia@amd.com>
7686 * graphite.c (is_bb_addable): Fix segfault.
7688 2008-06-10 Tobias Grosser <grosser@fim.uni-passau.de>
7690 * graphite.c (is_bb_addable): Fix memory leak, handling of loops
7691 with multiple exits and conditional handling in edge cases.
7692 (is_loop_exit): Fix memory leak. (Forgotten in last commit)
7694 * gcc.dg/graphite/scop-14.c: New.
7696 2008-06-06 Tobias Grosser <grosser@fim.uni-passau.de>
7697 Adrien Eliche <aeliche@isty.uvsq.fr>
7699 * graphite.c (is_bb_addable): Add more comments and enhance
7700 readablity of the source code. Fix memory leak.
7701 (is_loop_exit): Fix memory leak.
7703 2008-06-05 Tobias Grosser <grosser@fim.uni-passau.de>
7705 * graphite.c (first_loop_in_scop): Deleted.
7706 (setup_cloog_loop): Only walk the loop chain for inner loops.
7707 (build_scop_iteration_domain): Execute setup_cloog_loop for
7708 all loops in the first layer.
7710 2008-06-05 Tobias Grosser <grosser@fim.uni-passau.de>
7712 * graphite.c (scan_tree_for_params): Change the way params are
7713 added to be indepenent of the number of loops.
7714 (setup_cloog_loop): Revert to short matrix format. Fix parameter
7716 (build_cloog_prog): Revert to short matrix format.
7718 2008-06-05 Sebastian Pop <sebastian.pop@amd.com>
7719 Dwarak Rajagopal <dwarak.rajagopal@amd.com>
7721 * tree-loop-fusion.c (fuse_loops): Fix uninitialized variable
7724 2008-06-05 Sebastian Pop <sebastian.pop@amd.com>
7726 * graphite.c (nb_data_refs_in_scop): New.
7727 (graphite_transform_loops): Print more stats: number of
7728 loops, basic blocks and data references per scop.
7730 2008-06-04 Sebastian Pop <sebastian.pop@amd.com>
7731 Jan Sjodin <jan.sjodin@amd.com>
7733 * graphite.c (loop_affine_expr, idx_record_params,
7734 find_scop_parameters, setup_cloog_loop): Use instantiate_scev
7735 instead of instantiate_parameters.
7737 2008-06-04 Tobias Grosser <grosser@fim.uni-passau.de>
7739 * graphite.c (schedule_to_scattering): Fix scattering dimensions,
7740 add support for parameters, add STATIC_SCHEDULE at the right places,
7743 2008-06-04 Tobias Grosser <grosser@fim.uni-passau.de>
7745 * graphite.c (build_scop_loop_nests): Only add the loops, that
7746 are contained completely in the SCoP.
7747 (build_cloog_prog): Disable scattering, until schedule_to_scattering
7748 and the domains are fixed.
7749 (build_scop_canonical_schedules): Add support for bbs not contained
7752 2008-06-04 Tobias Grosser <grosser@fim.uni-passau.de>
7754 * graphite.h (scop_contains_loop): Update comments to match
7755 the actual behavior.
7756 (scop_contains_loop): New.
7757 * graphite.c (schedule_to_scattering): Use scop_contains_loop.
7759 2008-06-04 Sebastian Pop <sebastian.pop@amd.com>
7761 * graphite.c (get_bb_type): On function body, i.e. loop_0,
7762 don't mark blocks as GBB_LOOP_SING_EXIT_HEADER, mark them
7765 2008-06-04 Sebastian Pop <sebastian.pop@amd.com>
7766 Tobias Grosser <grosser@fim.uni-passau.de>
7768 * graphite.c (graphite_transform_loops): Early return when
7769 there are no loops in the function.
7771 2008-05-31 Sebastian Pop <sebastian.pop@amd.com>
7772 Jan Sjodin <jan.sjodin@amd.com>
7774 * graphite.c (scan_tree_for_params, setup_cloog_loop): Compute the
7775 offset of the last loop.
7776 (setup_cloog_loop): Copy the entire outer constraint matrix.
7778 2008-05-31 Sebastian Pop <sebastian.pop@amd.com>
7779 Jan Sjodin <jan.sjodin@amd.com>
7781 * graphite.c (stmt_in_scop_p, function_parameter_p,
7782 invariant_in_scop_p): Removed.
7783 (scan_tree_for_params): Can be used with no constraint
7784 matrix for gathering parameters.
7785 (idx_record_params): Don't use idx_record_param, instead use
7786 scan_tree_for_params.
7787 (find_scop_parameters): Same.
7788 (setup_cloog_loop, build_scop_iteration_domain, build_cloog_prog):
7789 Fix the size of loop domains.
7790 (schedule_to_scattering): Exit when the outer loop is not in scop.
7791 (find_transform): Enable build_cloog_prog.
7793 2008-05-31 Sebastian Pop <sebastian.pop@amd.com>
7794 Jan Sjodin <jan.sjodin@amd.com>
7796 * graphite.c (schedule_to_scattering): Make scattering domains
7797 uniformly of the same size, as required by CLooG 0.14.0 and before.
7799 2008-05-31 Sebastian Pop <sebastian.pop@amd.com>
7800 Jan Sjodin <jan.sjodin@amd.com>
7802 * graphite.c (schedule_to_scattering): Rewrite, correct the
7803 translation of the scheduling function to scattering.
7804 (build_cloog_prog): Call schedule_to_scattering only once.
7805 * graphite.h (scop_loop_index): Do not fail for loops not
7806 in the scop: return -1.
7808 2008-05-30 Tobias Grosser <grosser@fim.uni-passau.de>
7810 * graphite.c (build_graphite_bb): Initialize GBB_DOMAIN.
7811 (loop_body_to_cloog_stmts): Export GBB_DOMAIN.
7812 (setup_cloog_loop): Export GBB_DOMAIN.
7813 (build_cloog_prog): New. Create new CLOOG_PROG, which should be
7814 able to rebuild the original control flow.
7815 * graphite.h (graphite_bb): Add domain field and access macro.
7818 2008-05-30 Sebastian Pop <sebastian.pop@amd.com>
7820 * graphite.c (debug_gbb): New.
7821 (print_scop, build_graphite_bb): Use SCOP_BBS.
7822 (build_scop_bbs): Reimplemented.
7823 (dfs_bb_in_scop_p): Removed.
7824 (build_scop_loop_nests): Reorder loops inserted in
7825 SCOP_LOOP_NEST: outer loops should come first.
7826 (build_scop_canonical_schedules): Reinitialize at zero
7827 the components of the SCOP_STATIC_SCHEDULE for the loops
7828 that have already been parsed.
7830 * graphite.h (debug_gbb): Declared.
7832 2008-05-30 Sebastian Pop <sebastian.pop@amd.com>
7833 Jan Sjodin <jan.sjodin@amd.com>
7835 * graphite.c (create_empty_loop): Renamed graphite_create_new_loop.
7836 (graphite_loop_to_gcc_loop): Removed.
7837 (remove_all_edges): New.
7838 (graphite_stmt_to_gcc_stmt): Renamed translate_clast.
7839 (gloog): Remove useless code.
7841 2008-05-29 Tobias Grosser <grosser@fim.uni-passau.de>
7843 * graphite.c (get_bb_type): Reworked. We distinguish between
7844 loops with one or multiple exits.
7845 (is_loop_exit): New.
7847 (is_bb_addable): Rework condition handling, now support for case
7848 case statements and loops with multiple exits.
7850 * gcc.dg/graphite/scop-11.c: New.
7851 * gcc.dg/graphite/scop-12.c: New.
7852 * gcc.dg/graphite/scop-13.c: New.
7854 2008-05-29 Tobias Grosser <grosser@fim.uni-passau.de>
7856 * graphite.c (dot_all_scops_1): Fix some colors. Reuse colors, if
7857 we have too many colors.
7859 2008-05-22 Sandeep Maram <smaram_b04@iiita.ac.in>
7861 * doc/invoke.texi (-ftree-loop-fusion): Document.
7862 * tree-pass.h (pass_loop_fusion): Declared.
7863 * tree-loop-fusion.c: New.
7864 * timevar.def (TV_TREE_LOOP_FUSION): Declared.
7865 * tree-data-ref.c (find_data_references_in_loop): Make extern.
7866 * tree-data-ref.h (find_data_references_in_loop): Declared.
7867 * common.opt (ftree-loop-fusion): Declared.
7868 * Makefile.in (tree-loop-fusion.o): Added rule and to OBJS-common.
7870 2008-05-21 Sebastian Pop <sebastian.pop@amd.com>
7872 * graphite.c (build_access_matrix): Fix typo from the merge.
7874 2008-05-20 Sebastian Pop <sebastian.pop@amd.com>
7876 * Merge from mainline (130800:135673).
7878 2008-05-07 Sebastian Pop <sebastian.pop@amd.com>
7880 * graphite.c (end_scop): The exit of the scop is not part of the scop.
7881 Update dominators after splitting.
7883 2008-05-07 Sebastian Pop <sebastian.pop@amd.com>
7885 * graphite.c (is_bb_addable): Return the harmful statement.
7886 Factor up some code.
7887 (end_scop): New. Splits end of scope bbs on a harmful statement.
7888 (build_scops_1): Call end_scop.
7890 2008-05-07 Sebastian Pop <sebastian.pop@amd.com>
7892 * graphite.c: (succs_at_same_depth, end_scop, all_preds_visited_p,
7893 all_succs_visited_p, start_new_scop_for_each_succ, start_new_scop,
7894 add_dominators_to_open_scops, stop_last_open_scop, scop_end_loop,
7895 build_scops_1): Removed.
7896 (build_scops_2): Renamed build_scops_1.
7898 2008-05-06 Sebastian Pop <sebastian.pop@amd.com>
7900 * graphite.c: Fix formatting.
7902 2008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
7904 * graphite.c (get_bb_type): New.
7906 (build_scops_2): New.
7907 (is_bb_addable): New.
7908 (build_scops): Switch the scop detection.
7909 (build_scop_bbs): Add entry bb to scop.
7910 * graphite.h (struct scop): Update comment.
7912 2008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
7914 * graphite.c (dot_all_scops_1): Fix some incorrect colors and add
7917 2008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
7919 * gcc.dg/graphite/scop-1.c: Update.
7920 * gcc.dg/graphite/scop-2.c: Update.
7921 * gcc.dg/graphite/scop-4.c: Update.
7922 * gcc.dg/graphite/scop-5.c: Add.
7923 * gcc.dg/graphite/scop-6.c: Add.
7925 2008-05-06 Sebastian Pop <sebastian.pop@amd.com>
7927 * gcc.dg/graphite/scop-0.c: Add.
7928 * gcc.dg/graphite/scop-7.c: Add.
7929 * gcc.dg/graphite/scop-8.c: Add.
7930 * gcc.dg/graphite/scop-9.c: Add.
7931 * gcc.dg/graphite/scop-10.c: Add.
7933 2008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
7935 * graphite.c (scop_affine_expr): Renamed to loop_affine_expr.
7936 Check affine expressions depending on the outermost loop
7938 (stmt_simple_for_scop_p): Same.
7939 (harmfule_stmt_in_scop): Same.
7941 2008-04-28 Tobias Grosser <grosser@fim.uni-passau.de>
7943 * graphite.c (dot_all_scops): Remove incorrect difficult bb coloring,
7944 mark entry and exit, that are not part of the SCoP and update HTML
7947 2008-04-25 Sebastian Pop <sebastian.pop@amd.com>
7949 * graphite.c (basic_block_simple_for_scop_p): Renamed
7951 (save_scop, preds_at_same_depth, test_for_scop_bound): Removed.
7952 (add_dominators_to_open_scops, build_scops_1): Reimplemented.
7953 (all_preds_visited_p, all_succs_visited_p,
7954 start_new_scop_for_each_succ, start_new_scop, stop_last_open_scop,
7955 scop_end_loop): New.
7956 (build_scops): Do not use dfs_enumerate_from.
7958 * gcc.dg/graphite/scop-{1,2,4}.c: Updated.
7960 2008-04-23 Sebastian Pop <sebastian.pop@amd.com>
7962 * graphite.c: Add comments to functions that are missing a
7964 (graphite_create_iv): Removed. Merged in graphite_loop_to_gcc_loop.
7966 2008-04-23 Sebastian Pop <sebastian.pop@amd.com>
7968 * graphite.c (nb_params_in_scop): Moved...
7969 (graphite_bb_from_bb, loop_body_to_cloog_stmts): New.
7970 (setup_cloog_loop): Call loop_body_to_cloog_stmts.
7971 (clast_to_gcc_expression): Reduce column size to less than 80.
7972 (graphite_create_iv): Return the new name of the IV.
7973 (find_transform): Set options->esp and options->cpp.
7974 (gloog): Comment out the invalidation of the old loop code.
7975 (initialize_dependence_polyhedron): Replace scop_nb_params with
7978 * graphite.h (nb_params_in_scop): ... here.
7979 (scop_nb_params): Removed.
7980 (loop_domain_dim): Return something even when the loop was not
7981 found in the hash table: avoid ICEing on all the graphite.exp
7984 2008-04-14 Konrad Trifunovic <konrad.trifunovic@inria.fr>
7986 * tree-chrec.c (for_each_scev_op): SCEV can have 3 operands.
7988 * graphite.c (build_scop_dynamic_schedules): Schedule is built
7989 according to nesting level.
7990 (find_scop_parameters): Call instantiate_parameters.
7991 (scan_tree_for_params): Extend it to handle general affine bounds.
7992 Inner loop bound can depend on outer loop induction variable.
7993 (setup_cloog_loop): tmp variable is allocated on stack. Call
7994 instantiate_parameters with respect to outermost_loop_in_scop.
7995 (loop_domain_dim, ref_nb_loops, loop_iteration_vector_dim): moved to
7997 (create_empty_loop): Function loopify should be given edge
7998 probability, instead of edge frequency. Dominance relation from
7999 switch_bb to loop_header.
8000 (clast_to_gcc_expression): Added handling of clast_reduction node.
8001 (gloog): New functionality for removing old loop.
8002 (test_dependence): Factored out from build_rdg_all_levels.
8003 (build_rdg_all_levels): Dependence testing factored out to
8004 test_dependence function.
8006 * graphite.h (struct graphite_bb): Extended with dynamic_schedule.
8007 (loop_domain_dim, ref_nb_loops, loop_iteration_vector_dim): Moved
8010 2008-04-07 Sebastian Pop <sebastian.pop@amd.com>
8012 * graphite.c (free_scop, param_index, initialize_cloog_names,
8013 nb_params_in_scop): Use name_tree map instead of just a tree
8014 for keeping track of the variable name associated to that tree.
8015 (create_empty_loop, gmp_cst_to_tree, clast_name_to_gcc,
8016 clast_to_gcc_expression, graphite_create_iv,
8017 graphite_loop_to_gcc_loop, graphite_cond_to_gcc_cond,
8018 graphite_stmt_to_gcc_stmt): New.
8019 (gloog): Call these.
8020 * graphite.h (struct name_tree): New.
8021 (struct scop): Use name_tree instead of tree for params.
8022 Store a vector of name_tree for new_ivs.
8024 (scop_nb_params): Use name_tree instead of tree.
8026 2008-04-05 Alexander Lamaison <awl03@doc.ic.ac.uk>
8027 Sebastian Pop <sebastian.pop@amd.com>
8029 * tree-bounds.c: New.
8030 * tree-bounds.h: New.
8031 * tree-pass.h: Declare pass_bounds_early and pass_bounds_late.
8032 * passes.c: Schedule pass_bounds_early, pass_bounds_late.
8033 * builtins.c (expand_builtin_alloca): Add flag_bounds as for
8037 * c-cppbuiltin.c: Same.
8041 * tree-outof-ssa.c: Same.
8043 * Makefile.in: Same.
8045 2008-03-15 Antoniu Pop <antoniu.pop@gmail.com>
8046 Sebastian Pop <sebastian.pop@amd.com>
8048 * tree-loop-distribution.c (remaining_stmts,
8049 upstream_mem_writes): Removed static variables.
8050 (copy_loop_before, create_bb_after_loop,
8051 mark_nodes_having_upstream_mem_writes, free_rdg_components,
8052 rdg_build_components, rdg_build_partitions,
8053 dump_rdg_partitions): Extern.
8054 (generate_loops_for_partition, generate_code_for_partition): Do not
8056 (already_processed_vertex_p, predecessor_has_mem_write,
8057 mark_nodes_having_upstream_mem_writes, has_upstream_mem_writes,
8058 rdg_flag_all_uses, rdg_flag_uses, rdg_flag_vertex_and_dependent,
8059 rdg_flag_loop_exits, rdg_flag_similar_memory_accesses,
8060 build_rdg_partition_for_component, rdg_build_partitions, ldist_gen):
8061 Pass remaining_stmts and upstream_mem_writes as parameters.
8062 (rdg_component): Moved...
8063 (build_rdg_partition_for_component): Do not aggregate components when
8064 flag_streamize_loops is set.
8065 (gen_sequential_loops): New.
8066 (ldist_gen): Call gen_sequential_loops.
8068 * tree-pass.h (pass_loop_streamization): Declared.
8070 * omp-low.c (expand_omp_sections): Call add_bb_to_loop on created
8071 basic blocks when loops structures exist.
8073 * builtin-types.def (BT_FN_VOID_PTR_PTR_INT): New.
8075 * tree-ssa-loop-ivopts.c (expr_invariant_in_region_p): New.
8077 * tree-parloops.c (take_address_of, eliminate_local_variables_1,
8078 eliminate_local_variables_stmt, eliminate_local_variables,
8079 separate_decls_in_loop_name, separate_decls_in_loop_stmt,
8080 separate_decls_in_loop, gen_parallel_loop): Make them work on a region
8081 of code delimited by two edges in the CFG.
8082 (separate_decls_in_loop_name): Renamed separate_decls_in_region_name.
8083 (separate_decls_in_loop_stmt): Renamed separate_decls_in_region_stmt.
8084 (separate_decls_in_loop): Renamed separate_decls_in_region. Isolate
8085 the case of parallelisation of reductions.
8086 (create_loop_fn): Extern.
8087 (create_omp_parallel_region): New.
8089 * tree-data-ref.c (dump_data_dependence_relation): Don't call
8090 dump_data_reference for printing dra and drb.
8091 (create_rdg_edge_for_ddr, create_rdg_edges_for_scalar): Initialise
8093 (build_rdg): Don't call free_dependence_relations for the moment, as
8094 we attach dependence relations on each edge of the RDG.
8097 * tree-data-ref.h (rdg_component): ...here.
8098 (struct rdg_edge): New field ddr_p relation.
8099 (RDGE_RELATION): New.
8100 (create_bb_after_loop, copy_loop_before,
8101 mark_nodes_having_upstream_mem_writes, rdg_build_components,
8102 rdg_build_partitions, dump_rdg_partitions,
8103 free_rdg_components): Declared.
8105 * omp-builtins.def (BUILT_IN_GOMP_STREAM_ALIGN_PUSH,
8106 BUILT_IN_GOMP_STREAM_ALIGN_POP): New.
8108 * tree-loop-streamization.c: New.
8110 * tree-flow.h (gather_blocks_in_sese_region, create_loop_fn,
8111 create_omp_parallel_region, expr_invariant_in_region_p): Declared.
8113 * Makefile.in (tree-loop-streamization.o): Added to OBJS-common.
8115 * tree-cfg.c (gather_blocks_in_sese_region): Extern.
8117 * passes.c: Schedule pass_loop_streamization.
8119 2008-03-08 Tobias Grosser <grosser@fmi.uni-passau.de>
8121 * graphite.c (dot_all_scops_1): Fix formatting for difficult bbs and
8124 2008-03-07 Tobias Grosser <grosser@fim.uni-passau.de>
8126 * graphite.c (dot_all_scops): Update formatting.
8127 Bbs can now be part of more than one SCoP.
8129 2008-03-04 Sebastian Pop <sebastian.pop@amd.com>
8131 * graphite.c (new_loop_to_cloog_loop_str, setup_cloog_loop): Fix
8133 (loop_domain_dim): Check for unregistered toplev SCOP loop.
8134 * graphite.h (loop_to_cloog_loop): New.
8136 2008-03-04 Konrad Trifunovic <konrad.trifunovic@inria.fr>
8138 * graphite.c (loop_domain_dim, ref_nb_loops,
8139 loop_iteration_vector_dim): New.
8140 (build_access_matrix_with_af, build_access_matrix,
8141 initialize_dependence_polyhedron): Fixed for new matrix layout.
8142 No longer assume that all iteration domains are of the same
8145 2008-03-02 Sebastian Pop <sebastian.pop@amd.com>
8147 * tree-scalar-evolution.c (instantiate_parameters_1): An SSA_NAME
8148 defined in a loop at depth 0 is invariant.
8149 * tree-chrec.c (evolution_function_is_invariant_rec_p): Ditto.
8150 * tree-ssa-loop-ivopts.c (expr_invariant_in_loop_p): Should never
8151 be called at loop depth 0.
8153 * graphite.c (basic_block_simple_for_scop_p): Take the scop as
8155 (dot_all_scops_1): Update use of basic_block_simple_for_scop_p.
8156 (down_open_scop): Removed.
8157 (loop_in_scop_p): Redefined.
8158 (scop_affine_expr): New argument: scop.
8159 (stmt_simple_for_scop_p): New argument: scop. RETURN_EXPR is not
8160 a harmful statement ending a scop.
8161 (basic_block_simple_for_scop_p): New argument: scop.
8162 (get_loop_start): Removed.
8163 (new_scop): Initialize SCOP_LOOPS.
8164 (free_scop): Free SCOP_LOOPS.
8165 (succs_at_same_depth, preds_at_same_depth): New.
8166 (end_scop): Test the validity of a scop.
8167 (add_dominators_to_open_scops): New.
8168 (test_for_scop_bound): Call add_dominators_to_open_scops.
8169 Add cases for opening and closing multiple scops.
8170 (build_scops, build_scop_bbs): Iterate over basic blocks in
8172 (build_graphite_bb): Pass scop directly.
8173 (dfs_bb_in_scop_p): New.
8174 (scop_record_loop): Use SCOP_LOOPS for not recording the same loop
8176 (nb_loops_around_gb): Use loop_in_scop_p.
8177 (schedule_to_scattering): Disabled for the moment the code computing
8178 the "textual order for outer loop".
8180 * graphite.h (struct scop): New field loops.
8182 (scop_loop_index): Test that the given loop belongs to SCOP_LOOPS.
8184 * gcc.dg/graphite/scop-{1,...,7}.c: Updated.
8186 2008-02-27 Antoniu Pop <antoniu.pop@gmail.com>
8187 Sebastian Pop <sebastian.pop@amd.com>
8189 * builtin-types.def (BT_FN_PTR_SIZE_UINT, BT_FN_BOOL_PTR): New.
8190 * common.opt (fstreamize-loops): New.
8191 * omp-builtins.def (BUILT_IN_GOMP_STREAM_CREATE,
8192 BUILT_IN_GOMP_STREAM_PUSH, BUILT_IN_GOMP_STREAM_HEAD,
8193 BUILT_IN_GOMP_STREAM_POP, BUILT_IN_GOMP_STREAM_EOS_P,
8194 BUILT_IN_GOMP_STREAM_SET_EOS, BUILT_IN_GOMP_STREAM_DESTROY): New.
8196 2008-02-22 Konrad Trifunovic <konrad.trifunovic@inria.fr>
8198 * tree-data-ref.c (build_empty_rdg): New.
8199 (build_rdg): Use it.
8200 * tree-data-ref.h (build_empty_rdg): Declared.
8201 * graphite.c (free_scop): Free SCOP_LOOP2CLOOG_LOOP.
8202 (find_vertex_for_stmt): Removed.
8203 (build_rdg_all_levels): Use build_empty_rdg and rdg_vertex_for_stmt.
8205 2008-02-21 Sebastian Pop <sebastian.pop@amd.com>
8207 * tree-loop-distribution.c (generate_builtin): After cancelling the
8208 loop tree, also delete basic blocks.
8209 (rdg_flag_uses): Stop recursion when a vertex has already been
8212 2008-02-15 Konrad Trifunovic <konrad.trifunovic@inria.fr>
8214 * graphite.c (build_scop_alpha): Removed.
8215 (graphite_transform_loops): Add a dummy call to build_all_rdg_levels
8216 and dump_dependence_graph to avoid compiler warnings.
8218 2008-02-14 Konrad Trifunovic <konrad.trifunovic@inria.fr>
8220 * tree-data-ref.c (dr_may_alias_p, create_rdg_vertices): Extern.
8221 * tree-data-ref.h (dr_may_alias_p, create_rdg_vertices): Declared.
8222 * graphite.c (new_loop_to_cloog_loop_str, hash_loop_to_cloog_loop,
8223 eq_loop_to_cloog_loop, del_loop_to_cloog_loop): New.
8224 (new_scop, setup_cloog_loop): Initialize SCOP_LOOP2CLOOG_LOOP.
8225 (initialize_dependence_polyhedron, find_vertex_for_stmt,
8226 initialize_data_dependence_polyhedron, is_empty_polyhedron,
8227 statement_precedes_p, build_rdg_all_levels, build_scop_alpha,
8228 dump_dependence_graph): New.
8229 * graphite.h (struct graphite_bb): New field compressed_alpha_matrix.
8231 (struct scop): New field loop2cloog_loop.
8232 (SCOP_LOOP2CLOOG_LOOP, struct data_dependence_polyhedron,
8233 RDGE_DDP, ddp_p, struct loop_to_cloog_loop_str): New.
8235 2008-02-10 Konrad Trifunovic <konrad.trifunovic@inria.fr>
8237 * graphite.c (build_graphite_bb): Fix initialization
8238 of the graphite basic block.
8240 2008-02-05 Sebastian Pop <sebastian.pop@amd.com>
8242 * graphite.c (scan_tree_for_params): Rewrite for the new layout of
8243 loop domain matrix. Pass in the number of loops contained in the
8245 (nb_loops_around_gb): Moved before setup_cloog_loop that uses it.
8246 (setup_cloog_loop): Rewrite for the new layout of loop domain matrix:
8247 loops that are not surrounding the current loop are not represented
8248 in the domain constraint matrix.
8249 (build_scop_iteration_domain): Initial domain constraint matrix
8250 contains only the eq/ineq, cst, and scop parameters columns.
8252 2008-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
8254 * graphite.c (schedule_to_scattering, nb_loops_around_gb): New.
8255 (print_graphite_bb): Print scattering.
8257 2008-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
8259 * graphite.c (initialize_cloog_names): Initialize names of
8260 scattering variables.
8262 2009-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
8264 * graphite.c (dot_all_scops_1): Disable debug output while
8267 2008-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
8269 * graphite.c (find_transform): Change cloog output language to C.
8271 2008-01-27 Sebastian Pop <sebastian.pop@amd.com>
8273 * tree-loop-distribution.c (generate_memset_zero,
8274 generate_builtin, generate_code_for_partition,
8275 rdg_flag_all_uses): New.
8276 (rdg_flag_uses): Gather in the same partition the statements defining
8277 the VUSES of the current statement.
8278 (rdg_flag_similar_stores): Renamed rdg_flag_similar_memory_accesses.
8279 Gather in the same partition not only the stores to the same memory
8280 access, but also the reads.
8281 (ldist_generate_loops): Renamed ldist_gen.
8283 2008-01-24 Sebastian Pop <sebastian.pop@amd.com>
8284 Tobias Grosser <grosser@fmi.uni-passau.de>
8286 * graphite.c (setup_cloog_loop): Chain all cloog loops with the
8287 next pointer, don't use the inner pointer.
8289 2008-01-20 Tobias Grosser <grosser@fmi.uni-passau.de>
8291 * graphite.c (dot_all_scops, dot_all_scops_1): New.
8292 (find_transform): Call dot_all_1.
8293 * graphite.h (dot_all_scops): Declared.
8295 2007-12-14 Sebastian Pop <sebastian.pop@amd.com>
8297 * tree-loop-distribution.c: Fix apsi.f ICE.
8298 (create_bb_after_loop): New.
8299 (generate_loops_for_partition): Use it.
8300 * gfortran.dg/ldist-1.f90: New.
8302 * tree-data-ref.c (dot_rdg): Use /tmp/rdg.dot for dotty format.
8303 * graphite.c (dot_scop): Use /tmp/scop.dot for dotty format.
8305 2007-12-13 Tobias Grosser <grosser@fmi.uni-passau.de>
8307 * graphite.c (find_transform): Dump cloog program sent to cloog.
8309 2007-12-13 Tobias Grosser <grosser@fmi.uni-passau.de>
8311 * graphite.c (initialize_cloog_names): Initialize cloog
8314 2007-12-13 Tobias Grosser <grosser@fmi.uni-passau.de>
8316 * graphite.c (build_scop_context): Fix typo, for the matrix
8317 format: insert '0 >= 0' instead of '-1 >= 0'.
8319 2007-12-13 Sebastian Pop <sebastian.pop@amd.com>
8321 * Fix merge problems.
8323 2007-12-13 Sebastian Pop <sebastian.pop@amd.com>
8325 * graphite.c (setup_cloog_loop): Fix typo.
8327 2007-12-12 Sebastian Pop <sebastian.pop@amd.com>
8329 * doc/invoke.texi (-ftree-loop-distribution): Documented.
8330 * tree-loop-distribution.c: Reimplemented.
8331 * tree-pass.h (pass_loop_distribution): New.
8332 * tree-scalar-evolution.c (number_of_iterations_for_all_loops): Use
8334 * graphds.h (struct graph): New field indexes.
8335 * timevar.def (TV_TREE_LOOP_DISTRIBUTION): New.
8337 * tree-vect-analyze.c: Remove declaration of static functions when not
8339 * tree-vectorizer.c: Same.
8340 (rename_variables_in_loop): Now extern.
8341 (slpeel_tree_duplicate_loop_to_edge_cfg): Renamed
8342 tree_duplicate_loop_to_edge_cfg. Reset PENDING_STMT for edges after
8343 calling redirect_edge_and_branch_force.
8345 * tree-vectorizer.h (tree_duplicate_loop_on_edge): Declared.
8347 * tree-data-ref.c: Don't include tree-chrec.h.
8348 (debug_data_dependence_relations): New.
8349 (dump_data_dependence_relation): Call dump_data_reference on data refs
8351 (same_access_functions): Moved...
8352 (find_vertex_for_stmt): Renamed rdg_vertex_for_stmt.
8353 (dump_rdg_vertex, debug_rdg_vertex, dump_rdg_component,
8354 debug_rdg_component, dump_rdg, debug_rdg, dot_rdg_1, dot_rdg,
8355 struct rdg_vertex_info, ): New.
8356 (create_rdg_edge_for_ddr): Compute the dependence level before looking
8358 (create_rdg_vertices): Initialize the htab of graph->indexes.
8359 Initialize RDG_MEM_WRITE_STMT and RDG_MEM_READS_STMT.
8360 (stmts_from_loop): Don't save LABEL_EXPR.
8361 (hash_stmt_vertex_info, eq_stmt_vertex_info,
8362 hash_stmt_vertex_del): New.
8363 (build_rdg): Initialize rdg->indexes.
8364 (free_rdg, stores_from_loop, ref_base_address,
8365 rdg_defs_used_in_other_loops_p, have_similar_memory_accesses,
8366 have_similar_memory_accesses_1, ref_base_address_1,
8367 remove_similar_memory_refs): New.
8369 * tree-data-ref.h: Include tree-chrec.h.
8370 (debug_data_dependence_relations): Declared.
8371 (same_access_functions): ...here. Now static inline.
8372 (ddr_is_anti_dependent, ddrs_have_anti_deps,
8373 ddr_dependence_level): New.
8374 (struct rdg_vertex): New fields has_mem_write, has_mem_reads.
8375 (RDGV_HAS_MEM_WRITE, RDGV_HAS_MEM_READS, RDG_STMT, RDG_MEM_WRITE_STMT,
8376 RDG_MEM_READS_STMT): New.
8377 (dump_rdg_vertex, debug_rdg_vertex, dump_rdg_component,
8378 debug_rdg_component, dump_rdg, debug_rdg, dot_rdg,
8379 rdg_vertex_for_stmt): Declared.
8380 (struct rdg_edge): New field level.
8381 (RDGE_LEVEL, free_rdg): New.
8382 (stores_from_loop, remove_similar_memory_refs,
8383 rdg_defs_used_in_other_loops_p,
8384 have_similar_memory_accesses): Declared.
8385 (rdg_has_similar_memory_accesses): New.
8387 * lambda.h (dependence_level): New.
8388 * common.opt (ftree-loop-distribution): New.
8389 * tree-flow.h (debug_loop_ir): Renamed debug_loops.
8390 (print_loop_ir): Renamed print_loops.
8391 (debug_loop, debug_loop_num, print_loops_bb, mark_virtual_ops_in_bb,
8392 tree_duplicate_loop_to_edge_cfg, rename_variables_in_loop): Declared.
8393 * Makefile.in (TREE_DATA_REF_H): Depends on tree-chrec.h.
8394 (tree-loop-distribution.o): Added.
8395 * tree-cfg.c (mark_virtual_ops_in_region): Use mark_virtual_ops_in_bb.
8396 (mark_virtual_ops_in_bb): New.
8397 (print_loops_bb, debug_loop_num, debug_loop): New.
8398 * passes.c: Scheduled pass_loop_distribution.
8400 2007-12-12 Konrad Trifunovic <konrad.trifunovic@inria.fr>
8402 * graphite.c (scan_tree_for_params): Correct the number of columns
8404 (nb_flat_iterator): New.
8405 (setup_cloog_loop): Initialize to 1 the first column for inequalities.
8406 (build_scop_iteration_domain): Correct the number of columns for
8409 2007-12-12 Sebastian Pop <sebastian.pop@amd.com>
8411 * Merge from mainline (129697:130800).
8413 2007-10-30 Sebastian Pop <sebastian.pop@amd.com>
8415 * graphite.c (build_graphite_bb): SCoP's basic blocks are post
8416 dominated by SCoP's exit.
8417 (graphite_transform_loops): Compute post dominators.
8419 2007-10-28 Sebastian Pop <sebastian.pop@amd.com>
8421 * Merge from mainline (127169:129697).
8423 2007-10-28 Sebastian Pop <sebastian.pop@amd.com>
8425 * graphite.c (affine_expr): Renamed scop_affine_expr. Use an extra
8426 parameter for the basic block that contains the expression. Use
8427 outermost_loop_in_scop for evolution_function_is_affine_multivariate_p.
8428 (stmt_simple_for_scop_p): Pass to scop_affine_expr the basic block of
8430 * graphite.h (gbb_loop): New.
8431 (GBB_LOOP): Removed.
8433 2007-08-03 Sebastian Pop <sebpop@gmail.com>
8435 * Makefile.in: Fix merge problem.
8437 2007-08-03 Sebastian Pop <sebpop@gmail.com>
8439 * Merge from mainline (125309:127169).
8440 * tree-loop-distribution.c: Disabled.
8442 2007-06-05 Sebastian Pop <sebpop@gmail.com>
8444 * Merge from mainline (r123693:125309).
8446 2007-05-30 Sebastian Pop <sebpop@gmail.com>
8448 * tree-loop-distribution.c (correct_modify_expr_p): Renamed
8450 (correct_modify_p, check_statements, number_of_lvalue_uses,
8451 number_of_scalar_dependences, create_edges): Use GIMPLE_MODIFY_STMT
8452 instead of MODIFY_EXPR.
8453 (update_edge_with_ddv): Don't pass index_of_edge. Initialize
8456 2007-05-24 Sebastian Pop <sebpop@gmail.com>
8458 * tree-loop-distribution.c (struct rdg): Replace arrays by
8459 VECs for edges and vertices.
8460 (RDG_NBV, RDG_NBE, RDG_VERTEX, RDG_EDGE): Removed.
8461 (RDGV_NB_PARTITIONS): New.
8462 (PRDG_NBV, PRDG_NBE): Removed.
8463 (build_scc_graph, correct_partitions_p, mark_partitions, build_prdg,
8464 dump_rdg, find_vertex_with_stmt, create_vertices, free_rdg,
8465 number_of_scalar_dependences, create_edges, build_rdg): Use VECs.
8467 2007-05-17 Georges-Andre Silber <silber@cri.ensmp.fr>
8468 Sebastian Pop <sebpop@gmail.com>
8470 * doc/invoke.texi (-ftree-loop-distribution): Document.
8471 * tree-loop-distribution.c: New file.
8472 * tree-pass.h (pass_loop_distribution): Declared.
8473 * timevar.def (TV_TREE_LOOP_DISTRIBUTION): New.
8474 * tree-data-ref.c (initialize_data_dependence_relation): Initialize
8476 * tree-data-ref.h (data_dependence_relation): Add reversed_p.
8477 (DDR_REVERSED_P): New.
8478 * common.opt (-ftree-loop-distribution): New.
8479 * tree-flow.h (distribute_loops): Declared.
8480 * Makefile.in (OBJS-common): Depend on tree-loop-distribution.o.
8481 * passes.c (init_optimization_passes): Schedule loop distribution.
8483 2007-05-12 Sebastian Pop <sebastian.pop@inria.fr>
8485 * graphite.c (print_graphite_bb): Don't call dump_data_references.
8486 (print_scop): Don't print when scop is NULL.
8487 (build_scop_context, find_transform): Don't output to stderr.
8489 2007-05-09 Sebastian Pop <sebastian.pop@inria.fr>
8491 * tree-data-ref.c: Don't include graphite.h.
8492 Comment out the code for printing data reference's scop.
8493 (build_access_matrix_with_af): Moved...
8494 * tree-data-ref.h (build_access_matrix_with_af): Removed declaration.
8495 * graphite.c (build_access_matrix_with_af): ... here. Now static.
8496 (print_graphite_bb): Print basic block's schedule.
8497 (print_scop): Don't print the schedule, call cloog's pretty printer.
8498 (bb_in_scop_p): A basic block is in a scop only if it is both
8499 dominated and postdominated by the scop's entry and exit basic blocks.
8500 (function_parameter_p): New.
8501 (invariant_in_scop_p): Use function_parameter_p.
8502 (new_scop, save_scop): New.
8503 (end_scop, test_for_scop_bound, build_scops): Use new_scop, and
8505 (scan_tree_for_params): Directly build the constraint as CloogMatrix.
8506 (loop_in_scop_p): New.
8507 (scop_record_loop): Use loop_in_scop_p.
8508 (build_scop_domain): Renamed build_scop_iteration_domain.
8509 (setup_cloog_loop, initialize_cloog_names, find_scop_parameters,
8510 nb_params_in_scop, build_scop_context, first_loop_in_scop,
8511 setup_cloog_loop, dot_scop_1, dot_scop): New.
8512 * graphite.h (GBB_LOOP, SCOP_PROG, dot_scop): New.
8513 (struct scop): Add a pointer to cloog's representation of a program.
8515 2007-04-14 Sebastian Pop <sebastian.pop@inria.fr>
8517 * doc/invoke.texi (-ftree-check-verbose): Renamed
8518 -ftree-checks-verbose.
8519 * common.opt (flag_tree_check_verbose): Renamed
8520 flag_tree_checks_verbose.
8521 * tree-check.c (tree_check_warning): Use flag_tree_checks_verbose.
8523 2007-04-14 Sebastian Pop <sebastian.pop@inria.fr>
8525 * configure: Regenerated.
8526 * config.in: Regenerated.
8527 * tree-ssa-loop.c (graphite_transforms): Execute
8528 graphite_transform_loops only when HAVE_cloog.
8529 * configure.ac (HAVE_polylib, HAVE_cloog, GRAPHITE): Defined.
8530 * graphite.c: Include polylibgmp.h and cloog.h.
8531 (graphite_transform_loops): Removed loops parameter.
8532 * tree-flow.h (graphite_transform_loops): Update declaration.
8533 * Makefile.in (POLYLIBLIBS, POLYLIBINC, CLOOGLIBS, CLOOGINC): New.
8534 (LIBS): Depend on CLOOGLIBS and on POLYLIBLIBS.
8535 (INCLUDES): Depend on POLYLIBINC and on CLOOGINC.
8536 (OBJS-common): Remove dependence on graphite.o.
8537 (BACKEND): Depend on @GRAPHITE@.
8539 2007-04-13 Sebastian Pop <sebastian.pop@inria.fr>
8541 * doc/invoke.texi (-ftree-check-verbose): Documented.
8542 * gcc.dg/tree-checker/tree-checks-1.c: New.
8543 * gcc.dg/tree-checker/tree-checks-2.c: New.
8544 * gcc.dg/tree-checker/tree-checks-3.c: New.
8545 * gcc.dg/tree-checker/tree-checks-4.c: New.
8546 * gcc.dg/tree-checker/tree-checks.exp: New.
8547 * gcc.dg/tree-checker/condates.crp: New.
8548 * common.opt (ftree-checks-verbose): New.
8549 * tree-check.c (tree_check_warning): Move extra stderr output
8550 under control of flag_tree_check_verbose.
8552 2007-04-12 Sebastian Pop <sebastian.pop@inria.fr>
8554 * tree-match.c: Fix comments formatting.
8555 * tree-match.h: Fix comments formatting.
8556 * tree-check.c: Fix comments formatting.
8557 (tree_check_init): Restructure.
8559 2007-04-12 Nic Volanschi <nic.volanschi@free.fr>
8561 * doc/invoke.texi (-ftree-check, -ftree-checks): Documented.
8563 2007-04-10 Sebastian Pop <sebastian.pop@inria.fr>
8565 * Merge from mainline (r120733:123693).
8567 2007-03-20 Nic Volanschi <nic.volanschi@free.fr>
8569 * condate.y: New file.
8570 * tree-match.h (struct patt_info_s): New field sign.
8571 (struct condate_s): New field msg.
8572 (normalize_condate, name_condate, add_condate): New.
8573 (conds[], condate_parse): Made extern.
8574 * tree-check.c (tree_check_warning): First arg changed to cond;
8575 warning reformatted.
8576 (tree_check_init): Reset the TREE_VISITED bit on every CFG node.
8578 (tree_check): Process trivial condates.
8579 (read_delimited_string): Removed.
8580 (print_cond): Print name and msg.
8581 (conds[]): Made extern.
8582 (parse_tree_check_file_once): Rewritten to use the parser in
8584 Processing of option --tree_check_string moved to tree_scan().
8585 * Makefile.in: Added condate.y
8587 2007-03-12 Sebastian Pop <sebastian.pop@inria.fr>
8589 * tree-pretty-print.c (dump_generic_bb_buff, lazy_dump_generic_node):
8590 Use VECs instead of varrays.
8591 * diagnostic.h (lazy_dump_generic_node): Update declaration.
8592 * Makefile.in (pretty-print.o): Depend on vec.h.
8593 * pretty-print.c: Include tree.h and vec.h.
8594 (pp_clear_state, pp_write_list_to_stream, pp_base_format,
8595 pp_base_format, pp_construct, pp_base_string, pp_lazy_mode,
8596 new_tree_chunk, pp_add_tree, pp_add_string, pp_add_char, pp_write_list,
8597 pp_free_list): Use VECs instead of varrays.
8598 * pretty-print.h: Do not include varray.h.
8599 (struct tree_chunk_s): Declaration moved before its use.
8600 (output_buffer): Rename varray field to chunks.
8601 * tree-match.c (tree_equal, chunk_1st_char, chunks_lookahead,
8602 tree_1st_char, match_chunks_pattinfo, match_tree_pattinfo,
8603 save_global_holes): Use VECs instead of varrays.
8604 * tree-match.h: Declare VECs of cfg_node, and hole_p.
8605 * tree-check.c (scan_cfg_stmts, push_node,
8606 print_matching_stmt): Removed.
8607 (tree_check_instance, push_global_holes_if_new, tree_check,
8608 execute_tree_check): Use VECs instead of varrays.
8609 (gate_tree_check): Don't execute the CFG check when basic_block_info
8612 2007-01-12 Sebastian Pop <sebastian.pop@inria.fr>
8614 * Merge from mainline (r115016:120733).
8616 2007-01-12 Sebastian Pop <sebastian.pop@inria.fr>
8618 * Merge from mainline (r117632:117661).
8620 2007-01-12 Sebastian Pop <sebastian.pop@inria.fr>
8622 * tree-dump.c (dump_option_value_in): Add TDF_DEBUG.
8623 * tree-pass.h (TDF_DEBUG, debug_p): New.
8624 * tree-scalar-evolution.c (set_scalar_evolution, get_scalar_evolution,
8625 get_scalar_evolution, add_to_evolution, set_nb_iterations_in_loop,
8626 get_loop_exit_condition, analyze_evolution_in_loop,
8627 analyze_initial_condition, analyze_scalar_evolution,
8628 instantiate_parameters, number_of_latch_executions): Use debug_p.
8629 * tree-chrec.c (chrec_apply): Use debug_p.
8630 * tree-data-ref.c: Include graphite.h.
8631 (dump_data_reference): Print also the access matrix.
8632 (analyze_array, analyze_indirect_ref, init_data_ref,
8633 analyze_offset_expr, address_analysis, object_analysis,
8634 create_data_ref, finalize_ddr_dependent,
8635 non_affine_dependence_relation, analyze_ziv_subscript,
8636 analyze_siv_subscript_cst_affine,
8637 compute_overlap_steps_for_affine_1_2, analyze_subscript_affine_affine,
8638 can_use_analyze_subscript_affine_affine, analyze_siv_subscript,
8639 analyze_miv_subscript, analyze_overlapping_iterations,
8640 build_classic_dist_vector, subscript_dependence_tester,
8641 compute_affine_dependence, analyze_all_data_dependences): Use debug_p.
8642 (build_access_matrix_with_af): No longer static.
8643 * tree-data-ref.h (scop_p): ... declaration here.
8644 (data_reference.scop): New field.
8645 (DR_SCOP, DR_ACCESS_MATRIX): New.
8646 (build_access_matrix_with_af, dr_num_subscripts): Declared.
8647 * graphite.c (print_graphite_bb): Call dump_data_references.
8648 (print_scop): Use scop_nb_loops and scop_dim_domain.
8649 (test_for_scop_bound): Use debug_p.
8650 (scan_tree_for_params): Use scop_nb_loops, scop_nb_loops and
8652 (scop_loop_index): Moved...
8653 (scop_record_loop): New.
8654 (build_scop_loop_nests): Use scop_record_loop.
8655 (build_scop_domain): Use scop_dim_domain.
8656 (build_access_matrix): Implemented.
8657 (build_scop_canonical_schedules): Use scop_nb_loops.
8658 (build_graphite_bb): Initialize GBB_SCOP.
8659 * graphite.h (scop_p): Moved...
8660 (graphite_bb.scop): New field.
8661 (graphite_bb.iteration_domain, GBB_DOMAIN, scop.nb_params,
8662 scop.nb_loops, scop.dim_domain, SCOP_NB_LOOPS, SCOP_NB_PARAMS,
8663 SCOP_DIM_DOMAIN, SCOP_STMTS): Removed.
8664 (scop_nb_params, scop_nb_loops, scop_dim_domain, gbb_dim_domain,
8665 scop_loop_index): New.
8666 * Makefile.in (tree-data-ref.o): Depends on graphite.h.
8668 2007-01-05 Sebastian Pop <sebastian.pop@inria.fr>
8670 * Merge from mainline (r117661:120450).
8672 2006-10-12 Sebastian Pop <sebastian.pop@inria.fr>
8674 * tree-scalar-evolution.c (instantiate_parameters_1): Don't stop
8675 at the first declaration outside the varying loop, instantiate as
8677 * tree-chrec.c (for_each_scev_op): New.
8678 * tree-chrec.h (for_each_scev_op): Declared.
8679 * tree-ssa-loop.c (pass_graphite_trans): Don't dump the function.
8680 * tree-data-ref.c (get_references_in_stmt,
8681 find_data_references_in_stmt): New, from trunk.
8682 (find_data_references_in_loop): Use get_references_in_stmt
8683 and find_data_references_in_loop, modified as in trunk.
8684 (build_access_matrix_with_af): New.
8685 * tree-data-ref.h (data_reference): Add a field access_matrix.
8686 (data_ref_loc): New, as in trunk.
8687 * graphite.c (print_graphite_bb, bb_in_scop_p, stmt_in_scop_p,
8688 invariant_in_scop_p, param_index, scan_tree_for_params,
8689 scop_loop_index, build_scop_loop_nests, build_scop_domain, irp_data,
8690 idx_record_param, idx_record_params, build_access_matrix,
8691 build_scop_data_accesses, build_scop_canonical_schedules,
8692 build_graphite_bb, build_scop_bbs, find_params_in_bb,
8693 build_scop_params): New.
8694 * graphite.h (graphite_bb): New.
8695 (scop): Add fields static_schedule, params, loop_nest,
8697 * lambda.h: Declare vecs of lambda_matrix.
8698 * tree-flow.h (print_loop_ir_bb): Declared.
8699 * tree-cfg.c (print_loop_ir_bb): New.
8700 (print_loop): Use print_loop_ir_bb.
8702 2006-10-12 Sebastian Pop <pop@cri.ensmp.fr>
8704 * Merge from mainline (r115016:117632).
8706 2006-10-11 Sebastian Pop <pop@cri.ensmp.fr>
8708 * graphite.c (debug_scops): Adjust definition for avoiding a bootstrap
8709 break due to a warning.
8711 2006-10-10 Sebastian Pop <pop@cri.ensmp.fr>
8713 * graphite.c (print_scops, debug_scops): New.
8714 (graphite_transform): Renamed graphite_find_transform.
8715 * graphite.h (debug_scops): Declared.
8717 2006-08-17 Sebastian Pop <pop@cri.ensmp.fr>
8719 * tree-match.c: Reformat following the GNU style.
8720 * tree-match.h: Reformat following the GNU style.
8721 * tree-pattern.h: Removed empty file.
8722 * Makefile.in: Remove references to tree-pattern.h.
8723 * tree-check.c: Reformat following the GNU style.
8724 (execute_tree_check): Move gate condition code to...
8725 (gate_tree_check): ...here. New function.
8726 (pass_check): Use the gate function.
8728 2006-07-04 Nic Volanschi <nic.volanschi@free.fr>
8730 * tree-pattern.h: New. Tree pattern matching and checking using
8732 * tree-check.c: New. Tree/CFG checking pass.
8733 * tree-match.c: New. Library for tree pattern matching.
8734 * opts.c, common.opt: Add options --ftree-check & --ftree-checks.
8735 * toplev.c, flags.h: Add globals for tree-check pass.
8736 * Makefile.in: Integrate the files in tree-check pass.
8737 * timevar.def, tree-optimize.c, tree-pass.h: Register tree-check pass.
8738 * pretty-print.c, pretty-print.h, tree-pretty-print.c, diagnostic.h:
8739 Introduce a "lazy" pretty-print mode.
8740 * tree.c, tree.h: Add tree_name.
8742 2006-07-04 Sebastian Pop <pop@cri.ensmp.fr>
8744 * doc/invoke.texi (-fgraphite): Correct typo.
8745 * tree-scalar-evolution.c (number_of_iterations_for_all_loops): Update
8746 use of print_loop_ir.
8747 * gcc.dg/graphite/scop-1.c: New.
8748 * gcc.dg/graphite/scop-2.c: New.
8749 * gcc.dg/graphite/graphite.exp: New.
8750 * graphite.c: Include domwalk.h.
8751 (print_scop): Print only the entry and exit blocks.
8752 (debug_scop): No longer static.
8753 (affine_expr): Fix formating. Return also true when the expression is
8755 (stmt_simple_for_scop_p): Fix formating.
8756 (build_scops): Use domwalk.
8757 (get_loop_start, end_scop, test_for_scop_bound): New.
8758 (graphite_transform_loops): Avoid printing on stderr.
8759 * graphite.h (debug_scop): Declared.
8760 * tree-flow.h (debug_loop_ir, print_loop_ir): Update declarations.
8761 * Makefile.in (graphite.o): Depend on domwalk.h.
8762 * tree-cfg.c (print_loop, print_pred_bbs, print_succ_bbs): Remove
8763 declarations for static functions.
8764 (print_loop, print_loop_ir, debug_loop_ir): Use an extra parameter for
8765 controlling output verbosity.
8767 2006-06-26 Sebastian Pop <pop@cri.ensmp.fr>
8768 Plesco Alexandru <shurikx@gmail.com>
8770 * doc/invoke.texi (-fgraphite): Document.
8771 * tree-pass.h (pass_graphite_transforms): Declared.
8772 * timevar.def (TV_GRAPHITE_TRANSFORMS): New.
8773 * tree-ssa-loop.c (graphite_transforms, gate_graphite_transforms): New.
8774 (pass_graphite_transforms): Defined.
8775 * tree-data-ref.c (free_data_ref, data_reference): Extern.
8776 * tree-data-ref.h (free_data_ref, data_reference): Declared.
8777 * graphite.c, graphite.h: New.
8778 * common.opt (fgraphite): Declared.
8779 * tree-flow.h (graphite_transform_loops): Declared.
8780 * Makefile.in (OBJS-common): Add graphite.o.
8781 (graphite.o): New rule.
8782 * passes.c (pass_graphite_transforms): Scheduled.