1 2010-05-26 Sebastian Pop <sebastian.pop@amd.com>
3 * graphite-clast-to-gimple.c (graphite_create_new_loop_guard): Use
6 2010-05-07 Sebastian Pop <sebastian.pop@amd.com>
8 * graphite-clast-to-gimple.c (graphite_create_new_loop_guard): Fix
9 type of integer_one_node for fold_build of POINTER_PLUS_EXPR.
11 2010-05-07 Sebastian Pop <sebastian.pop@amd.com>
13 * graphite-sese-to-poly.c (loop_entry_phi_arg): Renamed
14 phi_arg_in_outermost_loop.
15 (remove_simple_copy_phi): Call phi_arg_in_outermost_loop.
16 (remove_invariant_phi): Same.
18 2010-04-12 Andreas Simbuerger <simbuerg@fim.uni-passau.de>
21 (pbb_strip_mine_profitable_p): Replace Value with mpz_t.
22 * graphite-clast-to-gimple.c
23 (clast_to_gcc_expression): Same.
24 (precision_for_value): Same.
25 (precision_for_interval): Same.
26 (gcc_type_for_interval): Same.
27 (graphite_create_new_guard): Same.
28 (compute_bounds_for_level): Same.
29 (graphite_create_new_loop_guard): Same.
30 * graphite-interchange.c
31 (build_linearized_memory_access): Same.
32 (pdr_stride_in_loop): Same.
33 (memory_strides_in_loop_1): Same.
34 (memory_strides_in_loop): Same.
35 (extend_scattering): Same.
36 (psct_scattering_dim_for_loop_depth): Same.
37 (pbb_number_of_iterations): Same.
39 (debug_iteration_domains): Same.
41 (new_Cloog_Domain_from_ppl_Pointset_Powerset): Same.
42 (ppl_set_inhomogeneous_gmp): Same.
43 (ppl_strip_loop): Same.
44 (ppl_lexico_compare_linear_expressions): Same.
45 (ppl_read_polyhedron_matrix): Same.
46 (ppl_max_for_le_pointset): Same.
48 (ppl_read_polyhedron_matrix): Same.
49 (tree_int_to_gmp): Same.
50 (gmp_cst_to_tree): Same.
51 (ppl_set_inhomogeneous): Same.
52 (ppl_set_inhomogeneous_tree): Same.
54 (ppl_set_coef_tree): Same.
55 * graphite-sese-to-poly.c
56 (build_pbb_scattering_polyhedrons): Same.
57 (build_scop_scattering): Same.
58 (scan_tree_for_params_right_scev): Same.
59 (scan_tree_for_params): Same.
60 (find_params_in_bb): Same.
61 (find_scop_parameters): Same.
62 (add_upper_bounds_from_estimated_nit): Same.
63 (build_loop_iteration_domains): Same.
64 (add_condition_to_domain): Same.
65 (pdr_add_memory_accesses): Same.
67 2010-04-11 Andreas Simbuerger <simbuerg@fim.uni-passau.de>
69 * graphite-blocking.c (pbb_strip_mine_profitable_p): Resolve
70 CLooG's value_* macros to their respective mpz_* counterparts.
71 * graphite-clast-to-gimple.c (clast_to_gcc_expression): Same.
72 (graphite_create_new_loop_guard): Same.
73 * graphite-interchange.c (build_linearized_memory_access): Same.
74 (pdr_stride_in_loop): Same.
75 (memory_strides_in_loop_1): Same.
76 (1st_interchange_profitable_p): Same.
77 * graphite-poly.c (extend_scattering): Same.
78 (psct_scattering_dim_for_loop_depth): Same.
79 (pbb_number_of_iterations): Same.
80 (pbb_number_of_iterations_at_time): Same.
81 * graphite-poly.h (new_1st_loop): Same.
82 * graphite-ppl.c (cloog_matrix_to_ppl_constraint): Same.
83 (oppose_constraint): Same.
84 (insert_constraint_into_matrix): Same.
85 (ppl_set_inhomogeneous_gmp): Same.
86 (ppl_set_coef_gmp): Same.
87 (ppl_strip_loop): Same.
88 (ppl_lexico_compare_linear_expressions): Same.
89 (ppl_max_for_le_pointset): Same.
90 (ppl_min_for_le_pointset): Same.
91 (ppl_build_realtion): Same.
92 * graphite-ppl.h (gmp_cst_to_tree): Same.
93 (ppl_set_inhomogeneous): Same.
94 (ppl_set_inhomogeneous_tree): Same.
96 (ppl_set_coef_tree): Same.
97 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons): Same.
98 (build_scop_scattering): Same.
99 (add_value_to_dim): Same.
100 (scan_tree_for_params_right_scev): Same.
101 (scan_tree_for_params_int): Same.
102 (scan_tree_for_params): Same.
103 (find_params_in_bb): Same.
104 (find_scop_parameters): Same.
105 (add_upper_bounds_from_estimated_nit): Same.
106 (build_loop_iteration_domains): Same.
107 (create_linear_expr_from_tree): Same.
108 (add_condition_to_domain): Same.
109 (pdr_add_memory_accesses): Same.
111 2010-04-05 Sebastian Pop <sebastian.pop@amd.com>
114 * graphite-clast-to-gimple.c (max_signed_precision_type): Use
115 lang_hooks.types.type_for_size instead of build_nonstandard_integer_type.
116 When converting an unsigned type to signed, double its precision.
117 (gcc_type_for_interval): Use lang_hooks.types.type_for_size.
118 (gcc_type_for_iv_of_clast_loop): Call max_signed_precision_type.
119 (graphite_create_new_loop_guard): When ub + 1 wraps around, use lb <= ub.
121 2010-04-05 Sebastian Pop <sebastian.pop@amd.com>
124 * graphite-clast-to-gimple.c (max_signed_precision_type): Use
125 build_nonstandard_integer_type.
126 (gcc_type_for_interval): Same.
128 2010-04-05 Sebastian Pop <sebastian.pop@amd.com>
131 * graphite-clast-to-gimple.c (graphite_create_new_loop_guard): Use
132 POINTER_PLUS_EXPR for pointer types.
134 * gcc.dg/graphite/id-19.c: New.
136 2010-04-04 Sebastian Pop <sebastian.pop@amd.com>
139 * Makefile.in (graphite-clast-to-gimple.o): Depends on langhooks.h.
140 * graphite-clast-to-gimple.c: Include langhooks.h.
141 (max_signed_precision_type): New.
142 (max_precision_type): Takes two types as arguments.
143 (precision_for_value): New.
144 (precision_for_interval): New.
145 (gcc_type_for_interval): New.
146 (gcc_type_for_value): New.
147 (gcc_type_for_clast_term): New.
148 (gcc_type_for_clast_red): New.
149 (gcc_type_for_clast_bin): New.
150 (gcc_type_for_clast_expr): Split up into several functions.
151 (gcc_type_for_clast_eq): Rewritten.
152 (compute_bounds_for_level): New.
153 (compute_type_for_level_1): New.
154 (compute_type_for_level): New.
155 (gcc_type_for_cloog_iv): Removed.
156 (gcc_type_for_iv_of_clast_loop): Rewritten.
157 (graphite_create_new_loop): Compute the lower and upper bound types
158 with gcc_type_for_clast_expr.
159 (graphite_create_new_loop_guard): Same.
160 (find_cloog_iv_in_expr): Removed.
161 (compute_cloog_iv_types_1): Removed.
162 (compute_cloog_iv_types): Removed.
163 (gloog): Do not call compute_cloog_iv_types.
164 * graphite-sese-to-poly.c (new_gimple_bb): Do not initialize
166 (free_data_refs_aux): Do not free GBB_CLOOG_IV_TYPES.
167 * sese.h (struct gimple_bb): Removed field cloog_iv_types.
168 (GBB_CLOOG_IV_TYPES): Removed.
170 * gcc.dg/graphite/run-id-pr42644.c: Call abort.
172 2010-04-02 Sebastian Pop <sebastian.pop@amd.com>
174 Reverted this commit: as at this point the loop closed SSA form
175 is under a canonical form respecting the single argument condition.
176 * graphite-sese-to-poly.c (scalar_close_phi_node_p): Loop
177 close phi nodes may have more than one argument.
179 2010-04-01 Sebastian Pop <sebastian.pop@amd.com>
181 * graphite-sese-to-poly.c (rewrite_close_phi_out_of_ssa): Assert that
182 gimple_phi_num_args of the loop close SSA phi node is equal to 1.
183 (detect_commutative_reduction): Same.
185 2010-03-31 Sebastian Pop <sebastian.pop@amd.com>
187 * graphite-sese-to-poly.c (scalar_close_phi_node_p): Loop
188 close phi nodes may have more than one argument.
190 2010-03-30 Richard Guenther <rguenther@suse.de>
191 Zdenek Dvorak <ook@ucw.cz>
192 Sebastian Pop <sebastian.pop@amd.com>
195 * tree-ssa-copy.c (init_copy_prop): Handle loop close phi nodes
196 with multiple arguments.
197 (execute_copy_prop): Remove call to rewrite_into_loop_closed_ssa.
199 2010-03-23 Sebastian Pop <sebastian.pop@amd.com>
201 * graphite-dependences.c (print_pddr): Call print_pdr with an
203 * graphite-poly.c (debug_pdr): Add an extra argument for the
206 (print_pbb_domain): Same.
208 (print_scop_context): Same.
211 (debug_pbb_domain): Same.
215 (debug_scop_context): Same.
218 (print_scop_params): Same.
219 (debug_scop_params): Same.
220 (print_iteration_domain): Same.
221 (print_iteration_domains): Same.
222 (debug_iteration_domain): Same.
223 (debug_iteration_domains): Same.
224 (print_scattering_function): Same.
225 (print_scattering_functions): Same.
226 (debug_scattering_function): Same.
227 (debug_scattering_functions): Same.
228 * graphite-poly.h (debug_pdr): Update declaration.
230 (print_pbb_domain): Same.
232 (print_scop_context): Same.
235 (debug_pbb_domain): Same.
239 (debug_scop_context): Same.
242 (print_scop_params): Same.
243 (debug_scop_params): Same.
244 (print_iteration_domain): Same.
245 (print_iteration_domains): Same.
246 (debug_iteration_domain): Same.
247 (debug_iteration_domains): Same.
248 (print_scattering_function): Same.
249 (print_scattering_functions): Same.
250 (debug_scattering_function): Same.
251 (debug_scattering_functions): Same.
253 2010-03-23 Sebastian Pop <sebastian.pop@amd.com>
255 * graphite-poly.c (print_scattering_function_1): New.
256 (print_scattering_function): Call it.
257 (print_scop_params): Remove spaces at the end of lines.
260 * graphite-poly.h (print_cloog): Declared.
261 (debug_cloog): Declared.
263 2010-03-23 Sebastian Pop <sebastian.pop@amd.com>
265 * tree-ssa-copy.c: Revert this previous change:
266 (init_copy_prop): Loop closed phi nodes cancontain more than one
268 (execute_copy_prop): Revert the previous change: do not call
269 rewrite_into_loop_closed_ssa.
271 2010-03-21 Sebastian Pop <sebastian.pop@amd.com>
272 Richard Guenther <rguenther@suse.de>
275 * tree-ssa-copy.c (init_copy_prop): Loop closed phi nodes can
276 contain more than one argument.
277 (execute_copy_prop): Revert the previous change: do not call
278 rewrite_into_loop_closed_ssa.
280 * gcc.dg/graphite/id-pr43464.c: Remove compile warning.
281 * gcc.dg/graphite/id-pr43464-1.c: New.
283 2010-03-21 Sebastian Pop <sebastian.pop@amd.com>
286 * tree-ssa-copy.c (execute_copy_prop): Call rewrite_into_loop_closed_ssa
287 and verify_loop_closed_ssa when copy prop is executed in the LNO.
289 * gcc.dg/graphite/id-pr43464.c: New.
291 2010-03-16 Sebastian Pop <sebastian.pop@amd.com>
293 * graphite-sese-to-poly.c (graphite_loop_normal_form): Add the IV bump
295 * tree-flow.h (canonicalize_loop_ivs): Updated declaration.
296 * tree-parloops.c (gen_parallel_loop): Add the IV bump in loop->latch.
297 * tree-ssa-loop-manip.c (canonicalize_loop_ivs): Add a new parameter
298 to switch between adding the IV bump in loop->latch or in loop->header.
300 2010-03-16 Sebastian Pop <sebastian.pop@amd.com>
302 * passes.c (init_optimization_passes): Add pass_copy_prop
305 2010-03-16 Sebastian Pop <sebastian.pop@amd.com>
307 * graphite-poly.c (print_scattering_function): Pretty print following
310 (print_pbb_domain): Same.
311 (dump_gbb_cases): Same.
312 (dump_gbb_conditions): Same.
315 (print_scop_params): Same.
316 (print_scop_context): Same.
318 (print_pbb_body): New.
319 (lst_indent_to): New.
320 (print_lst): Start new lines with a #.
321 * graphite-poly.h (pbb_bb): New.
322 (pbb_index): Use pbb_bb.
323 * graphite-ppl.c (ppl_print_powerset_matrix): Print the number of
325 * tree-data-ref.c (dump_data_reference): Start new lines with a #.
327 2010-03-13 Sebastian Pop <sebastian.pop@amd.com>
330 * gcc.dg/graphite/id-pr43351.c
332 2010-03-13 Sebastian Pop <sebastian.pop@amd.com>
335 * graphite-sese-to-poly.c (rewrite_close_phi_out_of_ssa): Do not
336 call insert_out_of_ssa_copy for default definitions.
337 * gfortran.dg/graphite/id-pr43354.f: New.
339 2010-03-13 Sebastian Pop <sebastian.pop@amd.com>
342 * gfortran.dg/graphite/pr43349.f: New.
344 2010-03-11 Sebastian Pop <sebastian.pop@amd.com>
346 * graphite-clast-to-gimple.c (my_long_long): Defined.
347 (gcc_type_for_cloog_iv): Use it instead of long_long_integer_type_node.
348 * graphite-sese-to-poly.c (my_long_long): Defined.
349 (scop_ivs_can_be_represented): Use it.
351 2010-03-10 Sebastian Pop <sebastian.pop@amd.com>
353 * doc/invoke.texi: Fix documentation of graphite-max-nb-scop-params,
354 graphite-max-bbs-per-function, and loop-block-tile-size.
355 * params.def (PARAM_GRAPHITE_MAX_NB_SCOP_PARAMS): Replace "maximal"
357 (PARAM_GRAPHITE_MAX_BBS_PER_FUNCTION): Same.
359 2010-03-10 Sebastian Pop <sebastian.pop@amd.com>
361 * graphite-clast-to-gimple.c (gcc_type_for_iv_of_clast_loop): Remove
363 * graphite-sese-to-poly.c (reduction_phi_p): Remove FIXME comment.
364 (add_upper_bounds_from_estimated_nit): New.
365 (build_loop_iteration_domains): Use it.
367 2010-03-09 Sebastian Pop <sebastian.pop@amd.com>
369 * doc/invoke.texi (PARAM_LOOP_BLOCK_TILE_SIZE): Document.
371 2010-03-09 Sebastian Pop <sebastian.pop@amd.com>
374 * tree-chrec.c (evolution_function_right_is_integer_cst): CHREC_RIGHT
375 should be an INTEGER_CST. Also handle CASE_CONVERT.
376 * gcc.dg/graphite/pr43306.c: New.
378 2010-03-09 Sebastian Pop <sebastian.pop@amd.com>
380 * graphite.c (graphite_initialize): To bound the number of bbs per
381 function, use PARAM_GRAPHITE_MAX_BBS_PER_FUNCTION.
382 * params.def (PARAM_GRAPHITE_MAX_BBS_PER_FUNCTION): Declared.
383 * doc/invoke.texi: Document it.
385 2010-03-09 Sebastian Pop <sebastian.pop@amd.com>
387 * graphite-sese-to-poly.c (build_poly_scop): Do not return bool.
388 * graphite-sese-to-poly.h (build_poly_scop): Same.
390 2010-03-09 Sebastian Pop <sebastian.pop@amd.com>
392 * graphite-sese-to-poly.c (build_poly_scop): Limit scops following
393 the number of parameters in the scop. Use as an upper bound
394 PARAM_GRAPHITE_MAX_NB_SCOP_PARAMS.
395 * params.def (PARAM_GRAPHITE_MAX_NB_SCOP_PARAMS): Declared.
396 * doc/invoke.texi: Document it.
398 2010-03-05 Sebastian Pop <sebastian.pop@amd.com>
400 * graphite-sese-to-poly.c (add_param_constraints): Use
401 lower_bound_in_type and upper_bound_in_type.
403 2010-03-05 Sebastian Pop <sebastian.pop@amd.com>
405 * graphite-sese-to-poly.c (add_param_constraints): Use sizetype
406 instead of unsigned_type_node.
408 2010-03-05 Sebastian Pop <sebastian.pop@amd.com>
409 Reza Yazdani <reza.yazdani@amd.com>
412 * graphite-sese-to-poly.c (add_param_constraints): Insert bounds
413 on pointer type parameters.
415 * gcc.dg/graphite/run-id-4.c: New.
417 2010-03-05 Sebastian Pop <sebastian.pop@amd.com>
420 * gcc.dg/graphite/run-id-3.c: New.
422 2010-03-05 Tobias Grosser <grosser@fim.uni-passau.de>
423 Ramakrishna Upadrasta <Ramakrishna.Upadrasta@inria.fr>
425 * graphite-clast-to-gimple.c (clast_to_gcc_expression): Also
426 handle conversions from pointer to integers.
427 (gcc_type_for_cloog_iv): Choose the smalles signed integer as an
428 induction variable, to be able to work with code generated by CLooG.
429 * graphite-sese-to-poly.c (scop_ivs_can_be_represented): New.
430 (build_poly_scop): Bail out if we cannot codegen a loop.
432 2010-03-04 Tobias Grosser <grosser@fim.uni-passau.de>
434 * graphite-clast-to-gimple.c (translate_clast): Do not short-cut
435 code generation with gloog_error.
437 2010-03-04 Sebastian Pop <sebastian.pop@amd.com>
439 * sese.c (expand_scalar_variables_ssa_name): Add new argument for type.
440 Call fold_convert on all the returned values.
441 (expand_scalar_variables_expr): Pass to expand_scalar_variables_ssa_name
442 the type of the resulting expression.
444 2010-03-04 Sebastian Pop <sebastian.pop@amd.com>
446 * graphite-ppl.c (ppl_min_for_le_polyhedron): Renamed
447 ppl_min_for_le_pointset. Use ppl_Pointset_Powerset_C_Polyhedron_minimize.
448 * graphite-ppl.h (ppl_min_for_le_polyhedron): Update declaration.
450 2010-03-04 Sebastian Pop <sebastian.pop@amd.com>
452 * graphite-dependences.c (map_into_dep_poly): Removed.
453 (dependence_polyhedron_1): Use combine_context_id_scat.
455 2010-03-04 Sebastian Pop <sebastian.pop@amd.com>
457 * graphite-poly.h (struct poly_scattering): Add layout documentation.
458 (struct poly_bb): Same.
459 (combine_context_id_scat): New.
461 2010-03-02 Sebastian Pop <sebastian.pop@amd.com>
464 * sese.c (name_defined_in_loop_p): Return false for default
467 * gcc.dg/graphite/pr42326.c: New.
469 2010-02-23 Sebastian Pop <sebastian.pop@amd.com>
471 * graphite-clast-to-gimple.c (find_cloog_iv_in_expr): Simplify
472 and clean up the logic.
474 2010-02-23 Sebastian Pop <sebastian.pop@amd.com>
476 * graphite-sese-to-poly.c (add_param_constraints): Enabled: remove
479 2010-02-22 Sebastian Pop <sebastian.pop@amd.com>
482 * graphite-scop-detection.c (create_single_exit_edge): Move
483 the call to find_single_exit_edge to....
484 (create_sese_edges): ...here. Don't handle multiple edges
485 exiting the function.
486 (build_graphite_scops): Don't handle multiple edges
487 exiting the function.
489 * gcc.dg/graphite/pr43083.c: New.
491 2010-02-22 Sebastian Pop <sebastian.pop@amd.com>
494 * sese.c (get_rename): Assert that old_name is an SSA_NAME.
495 (rename_variables_in_stmt): Continue when the use is not an SSA_NAME.
497 * gfortran.dg/graphite/pr43097.f: New.
499 2010-02-22 Sebastian Pop <sebastian.pop@amd.com>
502 * graphite-scop-detection.c (create_single_exit_edge): Move
503 the call to find_single_exit_edge to....
504 (create_sese_edges): ...here. Don't handle multiple edges
505 exiting the function.
506 (build_graphite_scops): Don't handle multiple edges
507 exiting the function.
509 * gcc.dg/graphite/pr43083.c: New.
511 2010-02-22 Sebastian Pop <sebastian.pop@amd.com>
514 * sese.c (get_rename): Assert that old_name is an SSA_NAME.
515 (rename_variables_in_stmt): Continue when the use is not an SSA_NAME.
517 * gfortran.dg/graphite/pr43097.f: New.
519 2010-02-22 Sebastian Pop <sebastian.pop@amd.com>
520 Manuel López-Ibáñez <manu@gcc.gnu.org>
523 * g++.dg/graphite/pr41305.C: Add -Wno-conversion-null.
525 2010-02-22 Sebastian Pop <sebastian.pop@amd.com>
528 * sese.c (expand_scalar_variables_expr): Handle COMPONENT_REF.
530 * g++.dg/graphite/pr43026.C: New.
532 2010-02-13 Tobias Grosser <grosser@fim.uni-passau.de>
534 * Merge from mainline (154736:156693).
536 2010-02-11 Sebastian Pop <sebastian.pop@amd.com>
539 * sese.c (expand_scalar_variables_expr): Handle COMPONENT_REF.
541 * g++.dg/graphite/pr43026.C: New.
543 2010-02-13 Tobias Grosser <grosser@fim.uni-passau.de>
545 * Merge from mainline (154736:156693).
547 2010-02-11 Sebastian Pop <sebastian.pop@amd.com>
550 * gcc.dg/graphite/pr43012.c: New.
552 2010-02-10 Sebastian Pop <sebastian.pop@amd.com>
554 * graphite.c (graphite_transform_loops): Re-enable dbg_cnt.
556 2010-02-10 Sebastian Pop <sebastian.pop@amd.com>
558 * g++.dg/graphite/pr42930.C: New.
560 2010-02-10 Sebastian Pop <sebastian.pop@amd.com>
562 * graphite.c (graphite_transform_loops): Re-enable dbg_cnt.
564 2010-02-10 Sebastian Pop <sebastian.pop@amd.com>
566 * g++.dg/graphite/pr42930.C: New.
568 2010-02-10 Sebastian Pop <sebastian.pop@amd.com>
571 * graphite-scop-detection.c (graphite_can_represent_scev): Call
572 graphite_can_represent_init for MULT_EXPR.
574 2010-02-10 Sebastian Pop <sebastian.pop@amd.com>
578 * graphite-sese-to-poly.c (remove_phi): New.
579 (translate_scalar_reduction_to_array): Call remove_phi.
581 * gcc.dg/graphite/pr42530.c: New.
582 * gcc.dg/graphite/pr42914.c: New.
584 2010-02-10 Sebastian Pop <sebastian.pop@amd.com>
587 * graphite-scop-detection.c (graphite_can_represent_scev): Call
588 graphite_can_represent_init for MULT_EXPR.
590 2010-02-10 Sebastian Pop <seb@napoca>
594 * graphite-sese-to-poly.c (remove_phi): New.
595 (translate_scalar_reduction_to_array): Call remove_phi.
597 * gcc.dg/graphite/pr42530.c: New.
598 * gcc.dg/graphite/pr42914.c: New.
600 2010-02-10 Sebastian Pop <seb@napoca>
603 * graphite-clast-to-gimple.c (gloog): Call rename_sese_parameters.
604 * graphite-clast-to-gimple.h (gloog): Update declaration.
605 * graphite-poly.c (new_scop): Clear POLY_SCOP_P.
606 * graphite-poly.h (struct poly_bb): Add missing comments.
607 (struct scop): Add poly_scop_p field.
609 * graphite-sese-to-poly.c (build_poly_scop): Set POLY_SCOP_P.
610 * graphite.c (graphite_transform_loops): Build the polyhedral
611 representation for each scop before code generation.
612 * sese.c (rename_variables_in_operand): Removed.
613 (rename_variables_in_expr): Return the renamed expression.
614 (rename_sese_parameters): New.
615 * sese.h (rename_sese_parameters): Declared.
617 * gcc.dg/graphite/pr42771.c: New.
619 2010-02-07 Sebastian Pop <sebastian.pop@amd.com>
621 * gcc.dg/graphite/block-0.c: Call abort for runtime test. Always
623 * gcc.dg/graphite/block-1.c: Same.
624 * gcc.dg/graphite/block-3.c: Same.
625 * gcc.dg/graphite/block-4.c: Same.
626 * gcc.dg/graphite/block-5.c: Same.
627 * gcc.dg/graphite/block-6.c: Same.
628 * gcc.dg/graphite/block-7.c: Same.
629 * gcc.dg/graphite/interchange-0.c: Same.
630 * gcc.dg/graphite/interchange-1.c: Same.
631 * gcc.dg/graphite/interchange-10.c: Same.
632 * gcc.dg/graphite/interchange-11.c: Same.
633 * gcc.dg/graphite/interchange-12.c: Same.
634 * gcc.dg/graphite/interchange-2.c: Same.
635 * gcc.dg/graphite/interchange-3.c: Same.
636 * gcc.dg/graphite/interchange-4.c: Same.
637 * gcc.dg/graphite/interchange-5.c: Same.
638 * gcc.dg/graphite/interchange-6.c: Same.
639 * gcc.dg/graphite/interchange-7.c: Same.
640 * gcc.dg/graphite/interchange-8.c: Same.
641 * gcc.dg/graphite/interchange-9.c: Same.
642 * gcc.dg/graphite/interchange-mvt.c: Same.
644 2010-02-07 Sebastian Pop <sebastian.pop@amd.com>
646 * gfortran.dg/graphite/id-19.f: New.
647 * gfortran.dg/graphite/pr14741.f90: New.
648 * gfortran.dg/graphite/pr41924.f90: New.
649 * gfortran.dg/graphite/run-id-2.f90: New.
651 2010-02-07 Sebastian Pop <sebastian.pop@amd.com>
654 * graphite-dependences.c (dependence_polyhedron): Set PDDR_KIND
655 to unknown_dependence.
656 (graphite_legal_transform_dr): Handle the unknown_dependence.
657 (graphite_carried_dependence_level_k): Same.
659 2010-02-07 Sebastian Pop <sebastian.pop@amd.com>
661 * gcc.dg/graphite/block-0.c: Call abort for runtime test. Always
663 * gcc.dg/graphite/block-1.c: Same.
664 * gcc.dg/graphite/block-3.c: Same.
665 * gcc.dg/graphite/block-4.c: Same.
666 * gcc.dg/graphite/block-5.c: Same.
667 * gcc.dg/graphite/block-6.c: Same.
668 * gcc.dg/graphite/block-7.c: Same.
669 * gcc.dg/graphite/interchange-0.c: Same.
670 * gcc.dg/graphite/interchange-1.c: Same.
671 * gcc.dg/graphite/interchange-10.c: Same.
672 * gcc.dg/graphite/interchange-11.c: Same.
673 * gcc.dg/graphite/interchange-12.c: Same.
674 * gcc.dg/graphite/interchange-2.c: Same.
675 * gcc.dg/graphite/interchange-3.c: Same.
676 * gcc.dg/graphite/interchange-4.c: Same.
677 * gcc.dg/graphite/interchange-5.c: Same.
678 * gcc.dg/graphite/interchange-6.c: Same.
679 * gcc.dg/graphite/interchange-7.c: Same.
680 * gcc.dg/graphite/interchange-8.c: Same.
681 * gcc.dg/graphite/interchange-9.c: Same.
682 * gcc.dg/graphite/interchange-mvt.c: Same.
684 2010-02-07 Sebastian Pop <sebastian.pop@amd.com>
686 * gfortran.dg/graphite/id-19.f: New.
687 * gfortran.dg/graphite/pr14741.f90: New.
688 * gfortran.dg/graphite/pr41924.f90: New.
689 * gfortran.dg/graphite/run-id-2.f90: New.
691 2010-02-07 Sebastian Pop <sebastian.pop@amd.com>
694 * graphite-dependences.c (dependence_polyhedron): Set PDDR_KIND
695 to unknown_dependence.
696 (graphite_legal_transform_dr): Handle the unknown_dependence.
697 (graphite_carried_dependence_level_k): Same.
699 2010-02-07 Sebastian Pop <sebastian.pop@amd.com>
701 * ChangeLog.graphite: Remove testsuite/ or gcc/testsuite/.
703 2010-02-05 Sebastian Pop <sebastian.pop@amd.com>
704 Konrad Trifunovic <konrad.trifunovic@inria.fr>
707 * graphite-dependences.c (build_lexicographical_constraint): Return
708 a union of dependence polyhedra.
709 (dependence_polyhedron_1): Adapt for build_lexicographical_constraint.
711 * gcc.dg/graphite/block-0.c: Enable runtime check. XFAILed.
712 * gcc.dg/graphite/block-4.c: Same.
713 * gcc.dg/graphite/block-7.c: Same.
714 * gcc.dg/graphite/interchange-12.c: Same.
715 * gcc.dg/graphite/interchange-mvt.c: Same.
716 * gfortran.dg/graphite/interchange-1.f: XFAILed.
717 * gfortran.dg/graphite/interchange-3.f90: XFAILed.
718 * gfortran.dg/graphite/run-id-1.f: New testcase for PR42637.
720 2010-02-03 Sebastian Pop <sebastian.pop@amd.com>
722 * gcc.dg/graphite/interchange-12.c: Return 0 to avoid
723 the execution check to FAIL. This testcase is miscompiled by Graphite
724 and the check should be re-enabled.
725 * gcc.dg/graphite/interchange-mvt.c: Same.
726 * gcc.dg/graphite/block-0.c: Same.
727 * gcc.dg/graphite/block-4.c: Same.
728 * gcc.dg/graphite/block-7.c: Same.
730 2010-02-03 Sebastian Pop <sebastian.pop@amd.com>
732 * gcc.dg/graphite/interchange-mvt.c: Un-XFAILed.
733 * gcc.dg/graphite/scop-0.c: Fix spaces.
734 * gfortran.dg/graphite/block-1.f90: Rewrite expected output.
735 * gfortran.dg/graphite/block-2.f: Same.
736 * gfortran.dg/graphite/block-3.f90: Same.
737 * gfortran.dg/graphite/block-4.f90: Same.
738 * gfortran.dg/graphite/interchange-1.f: Un-XFAILed.
739 * gfortran.dg/graphite/interchange-3.f90: Un-XFAILed.
741 2010-02-03 Sebastian Pop <sebastian.pop@amd.com>
743 * graphite-dependences.c (new_poly_ddr): Initialize PDDR_KIND and
744 PDDR_ORIGINAL_SCATTERING_P.
745 (pddr_is_empty): Rewritten.
746 (print_dependence_polyhedron_layout): New.
749 (build_alias_set_powerset): Moved up.
750 (poly_drs_may_alias_p): Moved up.
751 (lexicographically_gt_p): Removed.
752 (build_lexicographically_gt_constraint): Renamed
753 build_lexicographical_constraint, reimplemented.
754 (dependence_polyhedron_1): Simplified parameters.
755 (dependence_polyhedron): Same. Keep along empty PDDRs
756 to make efficient use of the cache.
757 (reduction_dr_p): Compute the PBBs don't pass them as parameters.
758 (graphite_legal_transform_dr): Rewritten.
759 (graphite_legal_transform_bb): Pass fewer arguments to
760 graphite_legal_transform_dr.
761 (graphite_carried_dependence_level_k): Simplified implementation.
762 (dot_original_deps_stmt_1): Call dependence_polyhedron.
763 (dot_transformed_deps_stmt_1): Same.
764 (dot_original_deps): Same.
765 (dot_transformed_deps): Same.
766 * graphite-dependences.h (struct poly_ddr): Added a new field
767 original_scattering_p.
768 (PDDR_ORIGINAL_SCATTERING_P): New.
769 (print_pddr): Declared.
770 (debug_pddr): Declared.
771 * graphite-ppl.c: Clarify comment.
772 * sese.h (print_gimple_bb): Removed unused declaration.
775 2010-02-03 Sebastian Pop <sebastian.pop@amd.com>
777 * g++.dg/graphite/graphite.exp: Rewritten.
778 * gcc.dg/graphite/graphite.exp: Rewritten.
779 * gfortran.dg/graphite/graphite.exp: Rewritten.
780 * gcc.dg/graphite/block-0.c: Added runtime test.
781 * gcc.dg/graphite/block-1.c: Same.
782 * gcc.dg/graphite/block-3.c: Same.
783 * gcc.dg/graphite/block-4.c: Same.
784 * gcc.dg/graphite/block-5.c: Same.
785 * gcc.dg/graphite/block-6.c: Same.
786 * gcc.dg/graphite/block-7.c: Same.
787 * gcc.dg/graphite/interchange-0.c: Same.
788 * gcc.dg/graphite/interchange-1.c: Same.
789 * gcc.dg/graphite/interchange-10.c: Same.
790 * gcc.dg/graphite/interchange-11.c: Same.
791 * gcc.dg/graphite/interchange-12.c: Same.
792 * gcc.dg/graphite/interchange-2.c: Same.
793 * gcc.dg/graphite/interchange-3.c: Same.
794 * gcc.dg/graphite/interchange-4.c: Same.
795 * gcc.dg/graphite/interchange-5.c: Same.
796 * gcc.dg/graphite/interchange-6.c: Same.
797 * gcc.dg/graphite/interchange-7.c: Same.
798 * gcc.dg/graphite/interchange-8.c: Same.
799 * gcc.dg/graphite/interchange-9.c: Same.
800 * gcc.dg/graphite/interchange-mvt.c: Same.
801 * gcc.dg/graphite/run-id-2.c: Remove useless dg-do run.
803 2010-01-22 Ramakrishna Upadrasta <Ramakrishna.Upadrasta@inria.fr>
805 * graphite-scop-detection.c (dot_all_scops): Make calls to dot run in
808 2010-01-22 Ramakrishna Upadrasta <Ramakrishna.Upadrasta@inria.fr>
810 * common.opt: Add -fgraphite-cloog-opts.
811 * graphite-clast-to-gimple.c (set_cloog_options): Same.
812 * opts.c (decode_options): Same.
814 2010-01-20 Sebastian Pop <sebastian.pop@amd.com>
816 * gcc.dg/graphite/id-17.c: New.
817 * gcc.dg/graphite/pr41888.c: New.
818 * gcc.dg/graphite/scop-22.c: New.
819 * gfortran.dg/graphite/pr40982.f90: New.
821 2010-01-20 Sebastian Pop <sebastian.pop@amd.com>
823 * testsuite/gcc.dg/graphite/id-17.c: New.
824 * testsuite/gcc.dg/graphite/pr41888.c: New.
825 * testsuite/gcc.dg/graphite/scop-22.c: New.
826 * testsuite/gfortran.dg/graphite/pr40982.f90: New.
828 2010-01-20 Sebastian Pop <sebastian.pop@amd.com>
830 * graphite-dependences.c: Clarify comments.
831 (build_pddr): Add an extra parameter direction.
832 (graphite_legal_transform_dr): Use build_pddr.
833 (dot_original_deps_stmt_1): Update use of build_pddr.
834 (dot_transformed_deps_stmt_1): Same.
835 (dot_original_deps): Same.
836 (dot_transformed_deps): Same.
838 * gcc.dg/graphite/interchange-12.c: New.
839 * gcc.dg/graphite/block-7.c: New.
841 2010-01-20 Sebastian Pop <sebastian.pop@amd.com>
843 * graphite-dependences.c (pddr_original_scattering): Renamed build_pddr.
844 (pddr_transformed_scattering): Removed.
845 (graphite_legal_transform_dr): Use build_pddr.
846 (dot_original_deps_stmt_1): Same.
847 (dot_transformed_deps_stmt_1): Same.
848 (dot_original_deps): Same.
849 (dot_transformed_deps): Same.
851 2010-01-20 Sebastian Pop <sebastian.pop@amd.com>
853 * graphite-dependences.c (lexicographically_gt_p): Add comments.
854 (build_lexicographically_gt_constraint): Same.
855 (dependence_polyhedron_1): Same.
856 (dependence_polyhedron): Same.
858 2010-01-20 Sebastian Pop <sebastian.pop@amd.com>
860 * graphite-dependences.c (build_pairwise_scheduling_equality): Removed.
861 (build_pairwise_scheduling_inequality): Renamed build_pairwise_scheduling.
862 (lexicographically_gt_p): Change type of direction to int.
863 (build_lexicographically_gt_constraint): Same.
864 (dependence_polyhedron_1): Same.
865 (dependence_polyhedron): Same.
866 (pddr_original_scattering): Use integers for direction.
867 (pddr_transformed_scattering): Same.
868 (graphite_legal_transform_dr): Same.
869 (graphite_carried_dependence_level_k): Same.
871 2010-01-20 Sebastian Pop <sebastian.pop@amd.com>
873 * graphite-dependences.c (build_pairwise_constraint): Renamed
874 ppl_build_relation. Moved...
875 (dr_equality_constraints): Use ppl_build_relation.
876 (build_pairwise_scheduling_equality): Same.
877 (build_pairwise_scheduling_inequality): Same.
878 * graphite-ppl.c (ppl_build_relation): ...here.
879 * graphite-ppl.h (ppl_build_relation): Declared.
881 2010-01-14 Sebastian Pop <sebastian.pop@amd.com>
884 * graphite-clast-to-gimple.c (gloog_error): New static variable.
885 (clast_to_gcc_expression): Do not build MULT_EXPR of POINTER_TYPE_P.
886 Set gloog_error when such an expression failed to be built.
887 (translate_clast): Early return when gloog_error is set.
888 (gloog): Clear gloog_error. When gloog_error is set, call
889 set_ifsese_condition to enable the original code. Return the status
890 of the code generation based on gloog_error.
891 * sese.c (set_ifsese_condition): New.
892 * sese.h (set_ifsese_condition): Declared.
894 * g++.dg/graphite/pr42681.C: New.
896 2010-01-14 Sebastian Pop <sebastian.pop@amd.com>
899 * graphite-clast-to-gimple.c (gloog_error): New static variable.
900 (clast_to_gcc_expression): Do not build MULT_EXPR of POINTER_TYPE_P.
901 Set gloog_error when such an expression failed to be built.
902 (translate_clast): Early return when gloog_error is set.
903 (gloog): Clear gloog_error. When gloog_error is set, call
904 set_ifsese_condition to enable the original code. Return the status
905 of the code generation based on gloog_error.
906 * sese.c (set_ifsese_condition): New.
907 * sese.h (set_ifsese_condition): Declared.
909 * testsuite/g++.dg/graphite/pr42681.C: New.
911 2010-01-14 Sebastian Pop <sebastian.pop@amd.com>
914 * graphite-clast-to-gimple.c (gloog): Call scev_reset_htab and
915 rename_nb_iterations.
916 * sese.c (rename_variables_in_operand): New.
917 (rename_variables_in_expr): New.
918 (rename_nb_iterations): New.
919 (sese_adjust_liveout_phis): Update the rename_map.
920 * sese.h (rename_nb_iterations): Declared.
921 * tree-scalar-evolution.c (scev_reset_htab): New.
922 (scev_reset): Call scev_reset_htab.
923 * tree-scalar-evolution.h (scev_reset_htab): Declared.
925 * gfortran.dg/graphite/pr42732.f: New.
927 2010-01-08 Sebastian Pop <sebastian.pop@amd.com>
930 * graphite-clast-to-gimple.c: Fix formatting.
931 * sese.c (defined_in_loop_p): Renamed name_defined_in_loop_p.
932 (expr_defined_in_loop_p): New.
933 (add_loop_exit_phis): Also handle full expressions: remove from
934 the rename_map the expressions defined in the loop that we're closing.
936 * gfortran.dg/graphite/pr42393-1.f90: New.
937 * gfortran.dg/graphite/pr42393.f90: Add new flags
938 -fno-loop-block -fno-loop-interchange -fno-loop-strip-mine to also
939 make this testcase useful in the Graphite branch.
941 2010-01-08 Sebastian Pop <sebastian.pop@amd.com>
944 * graphite-clast-to-gimple.c: Fix formatting.
945 * sese.c (defined_in_loop_p): Renamed name_defined_in_loop_p.
946 (expr_defined_in_loop_p): New.
947 (add_loop_exit_phis): Also handle full expressions: remove from
948 the rename_map the expressions defined in the loop that we're closing.
950 * testsuite/gfortran.dg/graphite/pr42393-1.f90: New.
951 * testsuite/gfortran.dg/graphite/pr42393.f90: Add new flags
952 -fno-loop-block -fno-loop-interchange -fno-loop-strip-mine to also
953 make this testcase useful in the Graphite branch.
955 2010-01-08 Sebastian Pop <sebastian.pop@amd.com>
957 * graphite-scop-detection.c (exclude_component_ref): Removed.
958 (is_simple_operand): Removed.
959 (stmt_simple_for_scop_p): Remove use of is_simple_operand.
961 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
964 * sese.c (expand_scalar_variables_expr): Follow the SSA links into
965 the array indexing of ADDR_EXPRs.
967 * gcc.dg/graphite/pr42221.c: New.
969 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
972 * sese.c (expand_scalar_variables_expr): Follow the SSA links into
973 the array indexing of ADDR_EXPRs.
975 * testsuite/gcc.dg/graphite/pr42221.c: New.
977 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
980 * graphite.c (graphite_finalize): Call scev_reset.
981 (graphite_transform_loops): Do not call scev_reset between the code
984 * gcc.dg/graphite/pr42521.c: New.
986 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
988 * graphite-interchange.c (memory_stride_in_loop): Renamed
990 (memory_strides_in_loop): Renamed memory_strides_in_loop_1.
991 (memory_strides_in_loop): Memoize the memory strides per loop.
992 (lst_interchange_profitable_p): Do not initialize to zero the memory
994 * graphite-poly.h (struct lst): Add a field memory_strides.
995 (LST_LOOP_MEMORY_STRIDES): New.
996 (new_lst_loop): Initialize LST_LOOP_MEMORY_STRIDES to -1.
997 (free_lst): Clear LST_LOOP_MEMORY_STRIDES.
999 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
1001 * graphite-interchange.c (memory_stride_in_loop): Renamed
1003 (memory_strides_in_loop): Renamed memory_strides_in_loop_1.
1004 (memory_strides_in_loop): Memoize the memory strides per loop.
1005 (lst_interchange_profitable_p): Do not initialize to zero the memory
1007 * graphite-poly.h (struct lst): Add a field memory_strides.
1008 (LST_LOOP_MEMORY_STRIDES): New.
1009 (new_lst_loop): Initialize LST_LOOP_MEMORY_STRIDES to -1.
1010 (free_lst): Clear LST_LOOP_MEMORY_STRIDES.
1012 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
1014 * graphite-interchange.c (memory_strides_in_loop_depth): Renamed
1015 memory_strides_in_loop. Gather memory strides on a whole loop.
1016 (pbb_interchange_profitable_p): Renamed lst_interchange_profitable_p.
1017 (lst_interchange_profitable_p): Removed.
1018 (lst_try_interchange_loops): Call lst_interchange_profitable_p.
1020 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
1022 Revert patch 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
1023 * graphite-clast-to-gimple.c (try_mark_loop_parallel): New.
1024 (translate_clast_for, translate_clast_guard, translate_clast, gloog):
1025 Remove context_loop and level.
1027 2010-01-07 Richard Guenther <rguenther@suse.de>
1029 PR tree-optimization/42641
1030 * sese.c (rename_map_elt_info): Use the SSA name version, do
1033 2010-01-06 Sebastian Pop <sebastian.pop@amd.com>
1035 * graphite-blocking.c (scop_do_block): Print "SCoP will be loop
1036 blocked" only when both the strip mine and the interchange have
1039 * gcc.dg/graphite/block-2.c: Removed.
1040 * gcc.dg/graphite/block-3.c: Add scan pattern.
1041 * gcc.dg/graphite/block-4.c: Same.
1042 * gcc.dg/graphite/block-5.c: Same.
1043 * gcc.dg/graphite/block-6.c: Same.
1045 2010-01-06 Sebastian Pop <sebastian.pop@amd.com>
1047 * graphite-clast-to-gimple.c (save_clast_name_index): Free slot
1048 before allocating a new one.
1049 (copy_renames): Check that slot is not NULL.
1050 (mark_bb_with_pbb): Same.
1051 (compute_cloog_iv_types_1): Same.
1052 * graphite-interchange.c (lst_perfect_nestify): Free the before,
1053 nest, and after LSTs.
1054 (lst_try_interchange_loops): Same.
1056 2010-01-05 Sebastian Pop <sebastian.pop@amd.com>
1059 * graphite-interchange.c (lst_try_interchange_loops): Do not return
1060 the before, nest, and after LSTs.
1061 (lst_try_interchange): Removed.
1062 (lst_interchange_select_inner): Do not iterate over the LSTs if they
1064 (lst_interchange_select_outer): Apply interchange on the outer loop
1065 until there are no more changes in the inner loops.
1067 2009-12-18 Sebastian Pop <sebastian.pop@amd.com>
1069 Revert patch fixing PR middle-end/42221.
1071 2009-12-18 Sebastian Pop <sebastian.pop@amd.com>
1074 * graphite-sese-to-poly.c (follow_ssa_with_commutative_ops): Handle
1077 * gfortran.dg/graphite/pr42180.f90: Add compile flags.
1079 2009-12-18 Sebastian Pop <sebastian.pop@amd.com>
1082 * graphite-sese-to-poly.c (split_reduction_stmt): Do not split blocks
1083 that contain only one statement.
1085 * gfortran.dg/graphite/pr42180.f90: New.
1087 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
1090 * gfortran.dg/graphite/pr42393.f90: New.
1092 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
1095 * gfortran.dg/graphite/pr42186.f90: New.
1097 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
1100 * testsuite/gfortran.dg/graphite/pr42186.f90: New.
1102 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
1105 * graphite-sese-to-poly.c (translate_scalar_reduction_to_array_for_stmt):
1106 Insert the reduction copy in the same block as the phi node.
1107 (follow_ssa_with_commutative_ops): Handle GIMPLE_NOPs.
1109 * gcc.dg/graphite/pr42205-1.c: New.
1110 * gcc.dg/graphite/pr42205-2.c: New.
1112 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
1115 * sese.c (expand_scalar_variables_expr): Follow the SSA links into
1116 the array indexing of ADDR_EXPRs.
1118 * gcc.dg/graphite/pr42221.c: New.
1120 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
1124 * graphite-interchange.c (lst_try_interchange): Do not modify OUTER
1125 index. Call lst_interchange_select_inner only once.
1126 (lst_interchange_select_inner): Update use of lst_try_interchange.
1127 (lst_interchange_select_outer): Update.
1129 2009-12-15 Sebastian Pop <sebastian.pop@amd.com>
1133 * graphite-interchange.c (lst_try_interchange): Do not increment the
1134 the OUTER index when there is no AFTER kernel. Do not increment the
1135 OUTER index for after processing the AFTER kernel.
1136 (lst_interchange_select_inner): Call lst_try_interchange only on loops.
1137 (lst_interchange_select_outer): Do not pass in a pointer to the OUTER
1138 index. Do not pass to lst_interchange_select_inner the OUTER index.
1139 (scop_do_interchange): Update use of lst_interchange_select_outer.
1141 * gfortran.dg/graphite/graphite.exp
1142 (DEFAULT_FLAGS_GRAPHITE_IDENTITY): Remove -fdump-tree-graphite-all.
1143 * gfortran.dg/graphite/interchange-1.f: Add comment. Clean
1144 the graphite dump file.
1145 * gfortran.dg/graphite/interchange-2.f: Same.
1146 * gfortran.dg/graphite/pr42334-1.f: New.
1148 2009-12-15 Sebastian Pop <sebastian.pop@amd.com>
1152 * graphite-interchange.c (lst_perfect_nestify): Reset to NULL the LSTs
1154 (lst_do_interchange_1): Renamed lst_interchange_select_inner.
1155 (lst_try_interchange): Reimplemented.
1156 (lst_interchange_select_inner): Same.
1157 (lst_do_interchange): Renamed lst_interchange_select_outer.
1159 (scop_do_interchange): Update use of lst_interchange_select_outer.
1161 * g++.dg/graphite/pr42130.C: Add -fgraphite-identity.
1162 * gcc.dg/graphite/block-0.c: Un-XFAILed.
1163 * gcc.dg/graphite/pr42211.c: New.
1164 * gfortran.dg/graphite/pr42334.f90: New.
1166 2009-12-14 Sebastian Pop <sebastian.pop@amd.com>
1169 * graphite-scop-detection.c (graphite_can_represent_scev): Handle more
1170 carefully PLUS_EXPR, MINUS_EXPR, and MULT_EXPR.
1172 * gfortran.dg/graphite/pr42181.f90: New.
1174 2009-12-12 Sebastian Pop <sebpop@gmail.com>
1177 * graphite-sese-to-poly.c (rewrite_close_phi_out_of_ssa): Call
1178 insert_out_of_ssa_copy_on_edge for anything else than SSA_NAMEs.
1179 (detect_commutative_reduction_arg): Simplified.
1180 (detect_commutative_reduction): Early return when the argument of
1181 the close phi is not of an SSA_NAME.
1183 * gcc.dg/graphite/pr42284.c: New.
1185 2009-12-11 Alexander Monakov <amonakov@ispras.ru>
1187 * dbgcnt.def (graphite_scop): New counter.
1188 * graphite.c: Include dbgcnt.h
1189 (graphite_transform_loops): Use new counter to limit transformations.
1191 2009-12-08 Sebastian Pop <sebpop@gmail.com>
1194 * graphite-scop-detection.c (graphite_can_represent_init): Also
1195 handle more complex MULT_EXPRs containing parameters by recursion
1198 * gfortran.dg/graphite/pr42285.f90: New.
1200 2009-12-01 Tobias Grosser <grosser@fim.uni-passau.de>
1202 * g++.dg/graphite/pr42130.C: Fix type.
1204 2009-11-29 Alexander Monakov <amonakov@gcc.gnu.org>
1206 * g++.dg/graphite/pr42130.C: Correct testcase.
1208 2009-11-28 Tobias Grosser <grosser@fim.uni-passau.de>
1210 * Merge from mainline (154493:154734).
1212 2009-11-28 Tobias Grosser <grosser@fim.uni-passau.de>
1214 * Merge from mainline (151362:154491).
1216 2009-11-24 Tobias Grosser <grosser@fim.uni-passau.de>
1218 * graphite-clast-to-gimple.c (try_mark_loop_parallel,
1219 graphite_create_new_loop_guard, translate_clast_for): Fix comments.
1221 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
1224 * graphite-clast-to-gimple.c (graphite_create_new_loop_guard,
1225 translate_clast_for_loop): New.
1226 (translate_clast_for): Add a condition around the loop, to do not
1227 execute loops with zero iterations.
1228 * g++.dg/graphite/pr42130.C: New.
1229 * gcc.dg/graphite/pr35356-2.c: Adapt.
1231 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
1233 * graphite-clast-to-gimple.c (try_mark_loop_parallel): New.
1234 (translate_clast_for, translate_clast_guard, translate_clast, gloog):
1235 Remove context_loop and level.
1237 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
1239 * graphite-clast-to-gimple.c (translate_clast_user,
1240 translate_clast_for, translate_clast_guard): Simplify and move common
1241 elements to translate_clast().
1242 (translate_clast): Simplify and get common elements.
1244 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
1246 * graphite-clast-to-gimple.c (translate_clast_user,
1247 translate_clast_for, translate_clast_guard): Split out of
1250 2009-11-21 Tobias Grosser <grosser@fim.uni-passau.de>
1252 * graphite-clast-to-gimple.c (clast_name_index, new_clast_name_index,
1253 clast_name_to_index, save_clast_name_index, debug_clast_name_index,
1254 debug_clast_name_indexes_1, debug_clast_name_indexes,
1255 clast_name_index_elt_info, eq_clast_name_indexes): Moved from sese.h.
1256 (clast_name_to_gcc, clast_to_gcc_expression,
1257 clast_to_gcc_expression_red, gcc_type_for_clast_expr,
1258 gcc_type_for_clast_eq, graphite_translate_clast_equation,
1259 graphite_create_guard_cond_expr, graphite_create_new_loop,
1260 translate_clast): Add params_index.
1261 (initialize_cloog_names): Create parameter strings from scratch, do
1262 not reference other strings.
1263 (create_params_index): New.
1264 (gloog): Initialize params_index.
1265 * graphite-scop-detection (free_scops_1): Removed.
1266 (limit_scops): Use normal free_scops.
1267 * graphite-sese-to-poly.c (save_var_names): Removed.
1268 (parameter_index_in_region): Do not initialize SESE_PARAM_NAMES
1269 and SESE_PARAMS_INDEX.
1270 * sese.c (new_sese, free_sese): Dito.
1271 * sese.h (struct sese): Remove params_index, params_names.
1272 (SESE_PARAMS_INDEX, SESE_PARAMS_NAMES): Removed.
1274 2009-11-20 Sebastian Pop <sebastian.pop@amd.com>
1276 Revert the following patch from 2009-09-14:
1277 * graphite-blocking.c: Fix order of includes: tree-chrec.h, then
1278 tree-scalar-evolution.h, and then tree-data-ref.h.
1279 * graphite-clast-to-gimple.c: Same.
1280 * graphite-dependences.c: Same.
1281 * graphite-interchange.c: Same.
1282 * graphite-poly.c: Same.
1283 * graphite-scop-detection.c: Same.
1284 * graphite-sese-to-poly.c: Same.
1286 * lambda-code.c: Same.
1287 * matrix-reorg.c: Same.
1288 * tree-data-ref.c: Same.
1289 * tree-if-conv.c: Same.
1290 * tree-loop-distribu: Same.: Same.
1291 * tree-loop-linear.c: Same.
1292 * tree-parloops.c: Same.
1293 * tree-predcom.c: Same.
1294 * tree-vect-patterns.c: Same.
1296 2009-11-20 Sebastian Pop <sebastian.pop@amd.com>
1298 Revert patch from 2009-09-14.
1299 * tree-ssa-loop.c (gate_graphite_transforms): Re-enable Graphite
1300 passes at -O1 and below.
1302 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
1305 * gcc.dg/graphite/pr40281.c: New.
1307 * tree-scalar-evolution.c (instantiate_scev_poly): Base and stride
1308 evolutions should not variate in inner loops.
1310 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
1313 * gfortran.dg/graphite/pr42050.f90: New.
1315 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
1317 * graphite-interchange.c (memory_strides_in_loop_depth): New.
1318 (pbb_interchange_profitable_p): Call memory_strides_in_loop_depth.
1320 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
1322 * graphite-blocking.c (scop_do_block): New.
1323 * graphite-poly.c (apply_poly_transforms): Call scop_do_block.
1324 * graphite-poly.h (scop_do_block): Declared.
1326 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
1328 * graphite-blocking.c (pbb_strip_mine_profitable_p): The parameter
1329 depth is the loop nesting depth in the LST. Call psct_dynamic_dim
1330 to transform depth into the time_depth before calling
1331 pbb_number_of_iterations_at_time.
1332 (lst_do_strip_mine): Use a scalar variable instead of recomputing
1335 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
1337 Reverted the patch for "scattering permutations" from 2009-10-28.
1339 * graphite-poly.c (print_permutation): New.
1340 (debug_permutation): New.
1341 (new_poly_bb): Initialize PBB_PERMUTATION.
1342 (free_poly_bb): Free PBB_PERMUTATION.
1343 * graphite-poly.h (pbb_permutation_elt_p): Declared.
1344 (struct pbb_permutation_elt): New.
1345 (PBB_PERMUTATION_ELT_STRIDE): New.
1346 (PBB_PERMUTATION_ELT_STRIDED_P): New.
1347 (PBB_PERMUTATION_ELT_TIME_DIMENSION): New.
1348 (new_pbb_permutation_elt): New.
1349 (pbb_permutation_elt_free): New.
1350 (struct poly_bb): Add field permutation.
1351 (PBB_PERMUTATION): New.
1352 (print_permutation): Declared.
1353 (debug_permutation): Declared.
1355 2009-11-04 Konrad Trifunovic <konrad.trifunovic@inria.fr>
1357 * graphite-interchange.c (build_partial_difference): New.
1358 (memory_stride_in_loop): Refactored the computation of
1359 equality constraints into build_partial_difference function.
1360 Added support for debugging stride computations.
1362 2009-11-03 Sebastian Pop <sebastian.pop@amd.com>
1364 * graphite-clast-to-gimple.c (gloog): Free if_region,
1365 if_region->true_region, and if_region->region.
1366 * sese.c (if_region_set_false_region): Free if_region->false_region.
1367 (create_if_region_on_edge): Do not use GGC_NEW.
1368 (move_sese_in_condition): Remove useless initialization.
1370 2009-11-03 Sebastian Pop <sebastian.pop@amd.com>
1372 * graphite-interchange.c (lst_perfect_nestify): Pass 3 parameters
1373 for the loops created by the loop distribution. Do not modify the
1375 (lst_try_interchange_loops): Same. Use a temporary LST for the
1376 transformed schedule. Call lst_update_scattering before data
1377 dependence analysis.
1378 (lst_try_interchange): Pass an extra parameter INDEX.
1379 (lst_do_interchange_1): New.
1380 (lst_do_interchange): Call lst_do_interchange_1.
1381 (scop_do_interchange): Call lst_update_scattering.
1382 * graphite-poly.c (apply_poly_transforms): Do not call
1383 lst_update_scattering.
1384 * graphite-poly.h (lst_pred): New.
1386 (lst_find_first_pbb): Return NULL when not found.
1388 (lst_insert_in_sequence): Allow LST1 to be NULL.
1390 (lst_substitute_3): New.
1391 * gcc.dg/graphite/interchange-1.c: XFail.
1392 * gcc.dg/graphite/interchange-8.c: XFail.
1393 * gcc.dg/graphite/interchange-11.c: XFail.
1395 2009-10-30 Sebastian Pop <sebastian.pop@amd.com>
1397 * graphite-interchange.c (lst_perfectly_nested_p): New.
1398 (lst_perfect_nestify): New.
1399 (lst_try_interchange_loops): Call store_lst_schedule,
1400 lst_perfectly_nested_p, lst_perfect_nestify and restore_lst_schedule.
1401 (scop_do_interchange): Avoid redundant legality test.
1402 Call lst_do_interchange on a copy of SCOP_TRANSFORMED_SCHEDULE.
1403 * graphite-poly.c (apply_poly_transforms): Call lst_update_scattering.
1404 * graphite-poly.h (psct_static_dim): New.
1405 (lst_dewey_number_at_depth): New.
1406 (lst_find_pbb): Restructured.
1407 (lst_find_first_pbb): Restructured.
1408 (lst_find_last_pbb): New.
1409 (lst_contains_p): New.
1410 (lst_contains_pbb): New.
1411 (lst_create_nest): New.
1412 (lst_remove_from_sequence): New.
1413 (pbb_update_scattering): New.
1414 (lst_update_scattering_under): New.
1415 (lst_update_scattering_seq): New.
1416 (lst_update_scattering): New.
1417 (lst_insert_in_sequence): New.
1418 (lst_distribute_lst): New.
1419 (lst_remove_all_before_including_pbb): New.
1420 (lst_remove_all_before_excluding_pbb): New.
1422 2009-10-30 Sebastian Pop <sebastian.pop@amd.com>
1424 * tree-ssa-loop-niter.c (finite_loop_p): Do not call twice
1425 get_loop_exit_edges.
1427 2009-10-30 Sebastian Pop <sebastian.pop@amd.com>
1429 * graphite-poly.c (pbb_remove_duplicate_pdrs): Free collapsed.
1431 2009-10-28 Konrad Trifunovic <konrad.trifunovic@gmail.com>
1433 * graphite-poly.c (print_permutation): New.
1434 (debug_permutation): New.
1435 (new_poly_bb): Initialize PBB_PERMUTATION.
1436 (free_poly_bb): Free PBB_PERMUTATION.
1437 * graphite-poly.h (pbb_permutation_elt_p): Declared.
1438 (struct pbb_permutation_elt): New.
1439 (PBB_PERMUTATION_ELT_STRIDE): New.
1440 (PBB_PERMUTATION_ELT_STRIDED_P): New.
1441 (PBB_PERMUTATION_ELT_TIME_DIMENSION): New.
1442 (new_pbb_permutation_elt): New.
1443 (pbb_permutation_elt_free): New.
1444 (struct poly_bb): Add field permutation.
1445 (PBB_PERMUTATION): New.
1446 (print_permutation): Declared.
1447 (debug_permutation): Declared.
1449 2009-10-26 Sebastian Pop <sebastian.pop@amd.com>
1451 * graphite-clast-to-gimple.c (gloog): Do not call
1452 sese_reset_aux_in_loops.
1453 * graphite-sese-to-poly.c (build_loop_iteration_domains): Pass an
1454 extra argument for domains. Do not use loop->aux.
1455 (build_scop_iteration_domain): Initialize and free domains, pass it
1456 to build_loop_iteration_domains and extract the information from
1457 domains. Do not use loop->aux.
1458 * sese.c (sese_reset_aux_in_loops): Removed.
1459 * sese.h (sese_reset_aux_in_loops): Removed.
1461 2009-10-26 Sebastian Pop <sebastian.pop@amd.com>
1463 * graphite-clast-to-gimple.c (find_pbb_via_hash): Moved up.
1464 (dependency_in_loop_p): Same.
1465 (translate_clast): Do not use loop->aux. Initialize
1466 loop->can_be_parallel.
1467 (mark_loops_parallel): Removed.
1468 * graphite-clast-to-gimple.h (mark_loops_parallel): Removed.
1469 * graphite.c (free_aux_in_new_loops): Removed.
1470 (graphite_finalize): Do not call free_aux_in_new_loops.
1471 (graphite_transform_loops): Do not call mark_loops_parallel.
1473 2009-10-26 Li Feng <nemokingdom@gmail.com>
1475 * graphite-clast-to-gimple.c (get_stmtfor_depth): Removed.
1476 (translate_clast): Pass an extra parameter LEVEL.
1477 Call get_scattering_level.
1478 * graphite-clast-to-gimple.h (get_scattering_level): New.
1480 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
1482 * cfgloop.c (alloc_loop): Initialize loop->single_iv.
1483 * cfgloop.h (struct loop): New field single_iv.
1485 * graphite-clast-to-gimple.c (pbb_to_depth_to_oldiv): Do not use
1486 loop->aux anymore: use loop->single_iv.
1487 (graphite_loop_normal_form): Moved...
1488 (build_graphite_loop_normal_form): Removed.
1489 (gloog): Do not call build_graphite_loop_normal_form.
1490 (free_aux_in_new_loops): Moved...
1491 (mark_loops_parallel): Restructure.
1492 * graphite-clast-to-gimple.h (free_aux_in_new_loops): Do not declare.
1493 * graphite-sese-to-poly.c (graphite_loop_normal_form): ...here.
1494 (scop_canonicalize_loops): New.
1495 (build_poly_scop): Call scop_canonicalize_loops.
1496 * graphite.c (free_aux_in_new_loops): ...here.
1498 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
1500 * g++.dg/graphite/graphite.exp: Add the same rules as in
1501 gcc.dg/graphite/graphite.exp.
1503 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
1505 * g++.dg/graphite/id-1.C: New.
1507 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
1509 * graphite-sese-to-poly.c (create_zero_dim_array): Pass an extra
1511 (rewrite_close_phi_out_of_ssa): Update use of create_zero_dim_array.
1512 (rewrite_phi_out_of_ssa): Same.
1513 (rewrite_cross_bb_scalar_deps): Same.
1514 (translate_scalar_reduction_to_array): Same.
1516 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
1518 * graphite-sese-to-poly.c (build_scop_drs): Disable call to
1521 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
1523 * graphite-sese-to-poly.c (dump_alias_graphs): New.
1524 (build_scop_drs): Call dump_alias_graphs.
1526 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
1528 * graphite-poly.c (new_scop): Initialize SCOP_ORIGINAL_SCHEDULE,
1529 SCOP_TRANSFORMED_SCHEDULE, and SCOP_SAVED_SCHEDULE.
1530 (free_scop): Call free_lst on SCOP_ORIGINAL_SCHEDULE,
1531 SCOP_TRANSFORMED_SCHEDULE, and SCOP_SAVED_SCHEDULE.
1532 * graphite-poly.h (free_lst): New.
1533 (store_lst_schedule): Free SCOP_SAVED_SCHEDULE.
1534 (restore_lst_schedule): Free SCOP_TRANSFORMED_SCHEDULE.
1536 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
1538 * graphite-poly.h (struct scop): Add a field saved_schedule.
1539 (SCOP_SAVED_SCHEDULE): New.
1540 (store_lst_schedule): New.
1541 (restore_lst_schedule): New.
1542 (store_scattering): Call store_lst_schedule.
1543 (restore_scattering): Call restore_lst_schedule.
1545 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
1547 * graphite-sese-to-poly.c (free_data_refs_aux): Fix formatting.
1548 (pdr_add_alias_set): Same.
1549 (build_poly_dr): Same.
1550 (build_alias_set_optimal_p): Same.
1551 (build_base_obj_set_for_drs): Same. Do not store the result of
1554 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
1556 * graphite-sese-to-poly.c (build_alias_set_optimal_p): Initialize
1557 all_components_are_cliques to 1.
1559 2009-10-20 Li Feng <nemokingdom@gmail.com>
1561 * graphite-sese-to-poly.c (free_data_refs_aux): Update to free
1563 (pdr_add_alias_set): Update retrieving alias_set_num.
1564 (build_poly_dr): Update retrieving dr_base_object_set.
1565 (partition_drs_to_sets): Remove.
1566 (build_alias_set_optimal_p): New.
1567 (build_alias_set_for_drs): Rename.
1568 (build_scop_drs): Update.
1569 * graphite-sese-to-poly.h (struct base_alias_pair): New.
1570 (ALIAS_SET_INDEX): Remove.
1571 (BASE_OBJECT_SET_INDEX): Remove.
1573 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
1575 * sese.c (get_vdef_before_sese): Handle GIMPLE_ASSIGN and GIMPLE_CALL.
1577 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
1579 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Do not infer
1580 loop upper bounds for 1-element arrays at end of structures.
1581 * tree-flow.h (array_at_struct_end_p): Declared.
1582 * tree-ssa-loop-niter.c (array_at_struct_end_p): Not static anymore.
1584 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
1586 * g++.dg/graphite/pr41305.C: New.
1588 2009-10-20 Alexander Monakov <amonakov@ispras.ru>
1590 * graphite-sese-to-poly.c (build_loop_iteration_domains): Generalize
1591 construction of parameter constraints from loop iteration analysis.
1592 * gcc.dg/graphite/run-id-2.c: New test.
1594 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
1596 * graphite-interchange.c (memory_stride_in_loop): Delete p1, lma
1599 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
1601 * graphite-dependences.c (dependence_polyhedron_1): Remove
1602 unused gdim dimensions from the DDR polyhedron.
1604 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
1606 * graphite-dependences.c (pddr_transformed_scattering): New.
1607 (dot_original_deps_stmt_1): New.
1608 (dot_transformed_deps_stmt_1): New.
1609 (dot_deps_stmt_1): Call dot_original_deps_stmt_1 and
1610 dot_transformed_deps_stmt_1.
1611 (dot_original_deps): New.
1612 (dot_transformed_deps): New.
1613 (dot_deps_1): Call dot_original_deps and dot_transformed_deps.
1615 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
1617 * graphite-dependences.c (reduction_dr_1): Remove wrong
1618 assert: reduction BBs can have multiple reduction writes
1619 to memory. interchange-3.f90 is an example.
1621 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
1623 * gfortran.dg/graphite/interchange-3.f90: New.
1625 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
1627 * gcc.dg/graphite/interchange-1.c: Un-XFAILed.
1629 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
1631 * graphite-dependences.c (dependence_polyhedron_1): Add the
1632 context to the dependence polyhedron.
1634 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
1636 * graphite-poly.c (pbb_remove_duplicate_pdrs): Initialize
1637 PBB_PDR_DUPLICATES_REMOVED.
1638 (new_poly_bb): Same.
1640 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
1642 * graphite-sese-to-poly.c (find_scop_parameters): Initialize
1644 (build_loop_iteration_domains): Extract bounds on parameters
1645 based on the data size.
1646 (build_scop_context): Do not initialize SCOP_CONTEXT;
1647 add new constraints.
1649 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
1651 * graphite-ppl.c (ppl_min_for_le_polyhedron): New.
1652 * graphite-ppl.h (graphite-ppl.h): Declared.
1654 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
1656 * graphite-ppl.c (ppl_print_linear_expr): New.
1657 (debug_ppl_linear_expr): New.
1658 * graphite-ppl.h (ppl_print_linear_expr): Declared.
1659 (debug_ppl_linear_expr): Declared.
1661 2009-10-16 Sebastian Pop <sebastian.pop@amd.com>
1663 * graphite-interchange.c: Fix comments.
1664 * gcc.dg/graphite/block-1.c: Fix comments.
1666 2009-10-16 Sebastian Pop <sebastian.pop@amd.com>
1668 * gcc.dg/graphite/interchange-7.c: Un-XFAILed.
1669 * gcc.dg/graphite/interchange-9.c: Un-XFAILed.
1671 2009-10-16 Sebastian Pop <sebastian.pop@amd.com>
1673 Reapply the patch from Alexander Monakov that disappeared during
1674 the last merges from trunk.
1676 2009-09-16 Alexander Monakov <amonakov@ispras.ru>
1678 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Add bounds only
1679 for ARRAY_REFs. Use array_ref_{low,up}_bound to determine bounds.
1681 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
1683 * graphite-interchange.c (memory_stride_in_loop): The depth
1684 argument corresponds to a dynamic time dimension, so use
1685 psct_dynamic_dim to refer to the transformed scattering dimension.
1687 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
1689 * graphite-interchange.c (memory_stride_in_loop): Fix comments.
1691 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
1693 * graphite-blocking.c (lst_do_strip_mine): Avoid strip mining the
1695 * graphite-interchange.c (lst_do_interchange): Avoid interchanging
1696 the root of the LST.
1697 * graphite-poly.c (scop_to_lst): Fix LST sequence in an outermost
1699 (print_lst): Print the root of LST in a different format.
1700 * graphite-poly.h (lst_depth): Adjust to include the root of the LST.
1702 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
1704 * graphite-poly.c (print_scop): Fix pretty printing of a SCoP.
1706 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
1708 * doc/passes.texi: Document the Graphite infrastructure.
1710 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
1712 * graphite-sese-to-poly.c (insert_copyin): Use gsi_insert_seq_on_edge.
1713 (rewrite_commutative_reductions_out_of_ssa): Call gsi_commit_edge_inserts,
1714 and check the SSA representation.
1716 * gfortran.dg/graphite/id-18.f90: New, reduced from PR41193.
1718 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
1720 * gcc.dg/graphite/pr40157.c: Use -floop-block as reported in the PR.
1722 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
1724 * gcc.dg/graphite/interchange-11.c: New.
1726 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
1728 * gcc.dg/graphite/interchange-8.c: Enable loop interchange.
1730 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
1732 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK):
1733 Add -fno-loop-strip-mine and -fno-loop-interchange.
1734 (DEFAULT_FLAGS_GRAPHITE_INTERCHANGE): Add -fno-loop-block and
1735 -fno-loop-strip-mine.
1736 * gfortran.dg/graphite/graphite.exp: Same.
1738 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
1740 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK):
1741 Renamed DEFAULT_FLAGS_GRAPHITE_BLOCK.
1742 (DEFAULT_CFLAGS_GRAPHITE_IDENTITY): Renamed
1743 DEFAULT_FLAGS_GRAPHITE_IDENTITY.
1744 (DEFAULT_CFLAGS_GRAPHITE_INTERCHANGE): Renamed
1745 DEFAULT_FLAGS_GRAPHITE_INTERCHANGE.
1746 (DEFAULT_CFLAGS_GRAPHITE_SCOP): Renamed
1747 DEFAULT_FLAGS_GRAPHITE_SCOP.
1748 (DEFAULT_CFLAGS_RUN_ID): Renamed DEFAULT_FLAGS_RUN_ID.
1749 (DEFAULT_CFLAGS_GRAPHITE): Renamed DEFAULT_FLAGS_GRAPHITE.
1751 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
1753 * graphite-poly.c (pbb_number_of_iterations_at_time): Cleanup comments.
1755 2009-10-14 Konrad Trifunovic <konrad.trifunovic@gmail.com>
1756 Sebastian Pop <sebastian.pop@amd.com>
1758 * graphite-interchange.c (build_linearized_memory_access): Pass an
1759 offset as parameter.
1760 (memory_stride_in_loop): Include transform scattering in the
1761 access functions to be able to querry the strides in the
1763 (pbb_interchange_loop_depths): Interchange the psct_dynamic_dim,
1764 not the psct_iterator_dim.
1766 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
1768 * graphite-blocking.c (pbb_do_strip_mine): Removed.
1769 (lst_do_strip_mine_loop): New.
1770 (lst_do_strip_mine): New.
1771 (scop_do_strip_mine): Call lst_do_strip_mine.
1772 * graphite-poly.h (lst_add_loop_under_loop): New.
1773 (lst_find_first_pbb): New.
1775 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
1777 * graphite-poly.c (loop_to_lst): Fix LST creation.
1779 2009-10-14 Tobias Grosser <grosser@fim.uni-passau.de>
1781 * gcc.dg/graphite/id-15.c: (8 * 8) replaced with
1782 sizeof(unsigned long) to make it run on 32bit systems.
1784 2009-10-14 Tobias Grosser <grosser@fim.uni-passau.de>
1786 * gcc.dg/graphite/run-id-1.c: Use smaller matrix to not
1789 2009-10-14 Ramakrishna Upadrasta <Ramakrishna.Upadrasta@inria.fr>
1791 * graphite-sese-to-poly.c (write_alias_graph_to_ascii_dimacs): Fix
1793 (write_alias_graph_to_ascii_dot): New.
1794 (write_alias_graph_to_ascii_ecc): Ditto.
1795 (partition_drs_to_sets): Add testing of optimality of current method
1796 which assigns alias numbers according to DFS Comopnent number. used
1797 as heuristic for the upcoming ECC algorithm.
1798 (build_scop_drs): Write to file also with the ecc and dot format.
1800 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
1802 * gfortran.dg/graphite/interchange-1.f: XFail.
1804 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
1806 * graphite.c (graphite_initialize): Do not handle functions with
1807 more than 100 basic blocks.
1809 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
1811 * graphite-blocking.c (pbb_do_strip_mine): Use
1812 PARAM_LOOP_BLOCK_TILE_SIZE.
1814 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
1816 * graphite-poly.c (dot_lst_1): New.
1818 * graphite-poly.h (dot_lst): Declared.
1820 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
1822 * graphite-dependences.c (dot_deps_stmt_1): New.
1823 (dot_deps_stmt): New.
1824 * graphite-dependences.h (dot_deps_stmt): Declared.
1826 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
1828 * graphite-sese-to-poly.c (rewrite_cross_bb_scalar_dependence): Do
1829 not replace cross BB scalar dependences ending on PHI nodes.
1830 (rewrite_cross_bb_scalar_deps): Filter out GIMPLE_PHI nodes.
1832 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
1834 * graphite-poly.c (apply_poly_transforms): Implement the high
1835 level driver for flag_loop_block.
1836 * opts.c (decode_options): Enable flag_loop_block at -O2.
1837 * tree-ssa-loop.c (gate_graphite_transforms): Remove call to sorry for
1840 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK): Add
1842 * gfortran.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK):
1845 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
1847 * graphite-poly.h (lst_find_pbb): New.
1848 (find_lst_loop): New.
1850 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
1852 * graphite-poly.c (new_scop): Remove init of SCOP_DEP_GRAPH.
1853 * graphite-poly.h (struct scop): Remove dep_graph field.
1854 (SCOP_DEP_GRAPH): Removed.
1856 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
1858 * graphite-poly.h (copy_lst): Do full copy of LST.
1860 2009-10-07 Sebastian Pop <sebastian.pop@amd.com>
1862 * graphite-sese-to-poly.c (reduction_phi_p): Call remove_invariant_phi
1863 when the loop stride is zero.
1865 * gcc.dg/graphite/id-16.c: New.
1867 2009-10-06 Sebastian Pop <sebastian.pop@amd.com>
1869 * graphite-dependences.c (reduction_dr_1): New.
1870 (reduction_dr_p): New.
1871 (graphite_legal_transform_dr): Call reduction_dr_p.
1872 (reduction_ddr): Renamed reduction_ddr_p.
1873 * graphite-poly.h (same_pdr_p): New.
1874 (number_of_write_pdrs): New.
1875 * graphite-sese-to-poly.c (nb_data_writes_in_bb): New.
1876 (split_reduction_stmt): Do not split reduction statements
1877 when there are no writes to memory.
1878 (translate_scalar_reduction_to_array_for_stmt): Insert the
1879 memory reduction statement just after the scalar reduction statement.
1881 * gcc.dg/graphite/interchange-10.c: Updated to differ from interchange-4.c.
1883 * gcc.dg/graphite/interchange-3.c: Un-XFAIL-ed.
1884 * gcc.dg/graphite/interchange-4.c: Un-XFAIL-ed.
1886 2009-10-06 Sebastian Pop <sebastian.pop@amd.com>
1888 * graphite-interchange.c (lst_apply_interchange): New.
1889 (lst_interchange_profitable_p): New.
1890 (lst_try_interchange_loops): New.
1891 (lst_try_interchange): New.
1892 (lst_do_interchange): New.
1893 (pbb_do_interchange): Removed.
1894 (scop_do_interchange): Call lst_do_interchange.
1896 2009-10-06 Sebastian Pop <sebastian.pop@amd.com>
1898 * graphite-poly.c (print_scop): Print SCOP_ORIGINAL_SCHEDULE and
1899 SCOP_TRANSFORMED_SCHEDULE.
1904 * graphite-poly.h (lst_p): New.
1907 (LST_LOOP_FATHER): New.
1910 (scop_to_lst): Declared.
1911 (print_lst): Declared.
1912 (debug_lst): Declared.
1913 (new_lst_loop): New.
1914 (new_lst_stmt): New.
1917 (lst_dewey_number): New.
1918 (struct scop): Add original_schedule and transformed_schedule fields.
1919 (SCOP_ORIGINAL_SCHEDULE): New.
1920 (SCOP_TRANSFORMED_SCHEDULE): New.
1921 * graphite-sese-to-poly.c (build_poly_scop): Call scop_to_lst.
1923 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
1925 * graphite-dependences.c (reduction_ddr): New.
1926 (graphite_legal_transform_bb): Call reduction_ddr.
1927 * graphite-poly.c (new_poly_bb): Pass a new bool parameter.
1928 Initialize PBB_IS_REDUCTION.
1929 * graphite-poly.h (struct poly_bb): New bool field is_reduction.
1930 (PBB_IS_REDUCTION): New.
1931 (new_poly_bb): Update declaration.
1932 * graphite-scop-detection.h (build_scop_bbs): Removed.
1933 (nb_reductions_in_loop): Removed.
1934 * graphite-sese-to-poly.c (try_generate_gimple_bb): Pass a sbitmap
1935 parameter for reductions.
1936 (try_generate_gimple_bb): Update call to new_poly_bb.
1937 (build_scop_bbs_1): Same.
1938 (build_scop_bbs): Same.
1939 (gsi_for_phi_node): New.
1940 (scalar_close_phi_node_p): Remove gcc_assert.
1941 (split_reduction_stmt): New.
1942 (is_reduction_operation_p): New.
1943 (phi_contains_arg): New.
1944 (follow_ssa_with_commutative_ops): New.
1945 (detect_commutative_reduction_arg): New.
1946 (detect_commutative_reduction_assign): New.
1947 (follow_inital_value_to_phi): New.
1948 (edge_initial_value_for_loop_phi): New.
1949 (initial_value_for_loop_phi): New.
1950 (detect_commutative_reduction): New.
1951 (translate_scalar_reduction_to_array_for_stmt): New.
1952 (insert_copyout): New.
1953 (insert_copyin): New.
1954 (translate_scalar_reduction_to_array): New.
1955 (rewrite_commutative_reductions_out_of_ssa_close_phi): New.
1956 (rewrite_commutative_reductions_out_of_ssa_loop): New.
1957 (rewrite_commutative_reductions_out_of_ssa): New.
1958 (build_poly_scop): Call rewrite_commutative_reductions_out_of_ssa.
1959 * sese.h (split_region_for_bb): New.
1961 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK): Add -ffast-math.
1962 * gcc.dg/graphite/interchange-1.c: Fix format.
1963 * gcc.dg/graphite/interchange-10.c: New.
1965 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
1967 * graphite-sese-to-poly.c (insert_out_of_ssa_copy): Remove
1970 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
1972 * graphite-sese-to-poly.c (scev_analyzable_p): New.
1973 (rewrite_cross_bb_scalar_dependence): New.
1974 (rewrite_cross_bb_scalar_deps): New.
1975 (rewrite_reductions_out_of_ssa): Use bb_in_sese_p.
1976 Call rewrite_cross_bb_scalar_deps.
1978 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
1980 * graphite-sese-to-poly.c (gsi_for_ssa_name_def): Removed.
1981 (insert_out_of_ssa_copy): Directly use gsi_after_labels and
1984 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
1986 * graphite-clast-to-gimple.c (build_cloog_prog): Use pbb_index.
1987 * graphite-interchange.c (pbb_do_interchange): Same.
1988 * graphite-poly.c (print_scattering_function): Same.
1990 * graphite-poly.h (pbb_loop): New.
1991 * graphite-sese-to-poly.c (create_linear_expr_from_tree): Use pbb_loop.
1993 2009-09-27 Sebastian Pop <sebastian.pop@amd.com>
1995 * graphite-scop-detection.c (limit_scops): Do not build poly_bbs.
1997 2009-09-27 Sebastian Pop <sebastian.pop@amd.com>
1999 * graphite-sese-to-poly.c (partition_drs_to_sets): Drs is not modified,
2000 so don't pass a pointer to it.
2001 (build_alias_set_for_drs): Same.
2002 (build_base_obj_set_for_drs): Same.
2003 (build_scop_drs): Same.
2005 2009-09-26 Li Feng <nemokingdom@gmail.com>
2007 * graphite-sese-to-poly.c (build_scop_drs): Disable writing to file
2008 the alias graph of data references.
2010 2009-09-25 Li Feng <nemokingdom@gmail.com>
2012 * graphite-sese-to-poly.c (write_alias_graph_to_ascii_dimacs): New.
2013 (build_scop_drs): When debugging, write the alias graph to file,
2014 otherwise, should be disabled.
2016 2009-09-17 Sebastian Pop <sebastian.pop@amd.com>
2018 * Merge from mainline (151310:151361).
2020 2009-09-17 Sebastian Pop <sebastian.pop@amd.com>
2022 * Merge from mainline (151171:151310).
2024 2009-09-17 Sebastian Pop <sebastian.pop@amd.com>
2026 * Merge from mainline (151171:151806).
2028 2009-09-17 Sebastian Pop <sebastian.pop@amd.com>
2030 * Revert the last commit.
2032 2009-09-17 Sebastian Pop <sebastian.pop@amd.com>
2034 * Merge from mainline (151171:151819).
2036 2009-09-17 Sebastian Pop <sebastian.pop@amd.com>
2038 * graphite-scop-detection.c (stmt_simple_memref_p): Removed.
2039 (is_simple_operand): Remove call to stmt_simple_memref_p.
2040 (stmt_simple_for_scop_p): Update call to is_simple_operand.
2042 2009-09-17 David Edelsohn <edelsohn@gnu.org>
2044 * gcc.dg/graphite/interchange-mvt.c: New File.
2045 * gcc.dg/graphite/scop-dsyrk.c: New File.
2046 * gcc.dg/graphite/scop-dsyr2k.c: New File.
2047 * gcc.dg/graphite/scop-mvt.c: New File.
2048 * gcc.dg/graphite/scop-sor.c: New File.
2050 2009-09-17 Li Feng <nemokingdom@gmail.com>
2052 * graphite-dependences.c (poly_drs_may_alias_p): Adjust definition.
2053 (pddr_original_scattering): Make sure 2 pdr2 in the same base object set.
2054 (graphite_carried_dependence_level_k): Ditto.
2055 * graphite-poly.c (new_poly_dr): Add init of PDR_BASE_OBJECT_SET.
2056 * graphite-poly.h (struct poly_dr): Add member dr_base_object_set.
2057 (new_poly_dr): Adjust declaration.
2058 * graphite-sese-to-poly.c (free_data_refs_aux): New.
2059 (free_gimple_bb): Added free_data_refs_aux.
2060 (build_poly_dr): Add dr_base_object_set.
2061 (partition_drs_to_sets): New.
2062 (dr_same_base_object_p): New.
2063 (build_alias_set_for_drs): New.
2064 (build_base_object_set_for_drs): New.
2065 (build_scop_drs): Add build_base_obj_set_for_drs.
2066 * graphite-sese-to-poly.h: Added #define for alias set number index and
2067 base object set index.
2068 * libgomp/testsuite/libgomp.graphite/force-parallel-6.c: Refine tests.
2069 * libgomp/testsuite/libgomp.graphite/pr4118.c: New.
2071 2009-09-16 Alexander Monakov <amonakov@ispras.ru>
2073 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Add bounds only
2074 for ARRAY_REFs. Use array_ref_{low,up}_bound to determine bounds.
2076 2009-09-14 Sebastian Pop <sebastian.pop@amd.com>
2078 * graphite-sese-to-poly.c (struct irp_data): Removed.
2079 (idx_record_params): Removed.
2080 (find_params_in_bb): Scan for parameters the access functions; don't
2081 parse the tree representation.
2083 2009-09-14 Sebastian Pop <sebastian.pop@amd.com>
2085 * tree-ssa-loop.c (gate_graphite_transforms): Disable Graphite
2086 passes at -O1 and below.
2088 2009-09-14 Sebastian Pop <sebastian.pop@amd.com>
2090 * graphite-blocking.c: Fix order of includes: tree-chrec.h, then
2091 tree-scalar-evolution.h, and then tree-data-ref.h.
2092 * graphite-clast-to-gimple.c: Same.
2093 * graphite-dependences.c: Same.
2094 * graphite-interchange.c: Same.
2095 * graphite-poly.c: Same.
2096 * graphite-scop-detection.c: Same.
2097 * graphite-sese-to-poly.c: Same.
2099 * lambda-code.c: Same.
2100 * matrix-reorg.c: Same.
2101 * tree-data-ref.c: Same.
2102 * tree-if-conv.c: Same.
2103 * tree-loop-distribu: Same.: Same.
2104 * tree-loop-linear.c: Same.
2105 * tree-parloops.c: Same.
2106 * tree-predcom.c: Same.
2107 * tree-vect-patterns.c: Same.
2109 2009-09-02 Sebastian Pop <sebastian.pop@amd.com>
2111 Partially revert the previous patch, except the following.
2112 * tree-scalar-evolution.c (instantiate_scev_not): Adapted to pass
2113 as parameters the operands of the not expression.
2115 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
2117 * tree-scalar-evolution.c (instantiate_scev_assign): New.
2118 Do not call analyze_scalar_evolution on assignments.
2119 (instantiate_scev_phi): Call analyze_scalar_evolution.
2120 (instantiate_scev_name): Call instantiate_scev_assign and
2121 instantiate_scev_phi.
2122 (instantiate_scev_not): Adapted to pass as parameters the operands
2123 of the not expression.
2125 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
2127 * tree-scalar-evolution.c (instantiate_scev_binary): Adapted
2128 to pass as parameters the operands of the binary expression.
2130 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
2132 * tree-scalar-evolution.c (instantiate_scev_bitnot): Renamed
2133 instantiate_scev_not. Handle NEGATE_EXPR.
2134 (instantiate_scev_r): Handle NEGATE_EXPR.
2136 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
2138 * tree-scalar-evolution.c (instantiate_scev_1): Renamed
2140 (instantiate_scev_r): Move code in instantiate_scev_2
2141 and instantiate_scev_1.
2143 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
2145 * tree-scalar-evolution.c (instantiate_scev_3): New.
2146 (instantiate_scev_1): Move code in instantiate_scev_3.
2148 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
2150 * tree-scalar-evolution.c (instantiate_scev_poly): New.
2151 (instantiate_scev_1): Move code in instantiate_scev_poly.
2153 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
2155 * tree-scalar-evolution.c (instantiate_scev_bitnot): New.
2156 (instantiate_scev_1): Move code in instantiate_scev_bitnot.
2158 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
2160 * tree-scalar-evolution.c (instantiate_scev_convert): New.
2161 (instantiate_scev_1): Move code in instantiate_scev_convert.
2163 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
2165 * tree-scalar-evolution.c (instantiate_scev_binary): New.
2166 (instantiate_scev_1): Move code in instantiate_scev_binary.
2168 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
2170 * tree-scalar-evolution.c (instantiate_scev_name): New.
2171 (instantiate_scev_1): Move code in instantiate_scev_name.
2173 2009-08-28 Sebastian Pop <sebastian.pop@amd.com>
2175 * Merge from mainline (150992:151171).
2177 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
2179 * opts.c (decode_options): Enable flag_loop_interchange at -O2.
2181 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
2183 * graphite-dependences.c (graphite_legal_transform_bb): Call
2184 pbb_remove_duplicate_pdrs.
2185 * graphite-poly.c (can_collapse_pdr): Removed.
2186 (pdr_find_duplicate): Removed.
2187 (can_collapse_pdrs): New.
2188 (pbb_remove_duplicate_pdrs): New.
2189 (new_poly_dr): Do not look for duplicates.
2190 * graphite-poly.h (struct poly_bb): New field pdr_duplicates_removed.
2191 (PBB_PDR_DUPLICATES_REMOVED): New.
2192 (pbb_remove_duplicate_pdrs): Declared.
2194 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
2196 * graphite-interchange.c (pbb_interchange_profitable_p): Adjust
2197 the strides by multiplying by PDR_NB_REFS.
2198 * graphite-poly.c (can_collapse_pdr): New.
2199 (pdr_find_duplicate): New.
2200 (new_poly_dr): Call pdr_find_duplicate. Collapse duplicate PDRs.
2201 Initialize PDR_NB_REFS.
2202 * graphite-poly.h (struct poly_dr): Add field nb_refs.
2204 (new_poly_dr): Number of subscripts is a graphite_dim_t.
2206 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
2208 Revert one of the previous commits:
2209 * graphite-dependences.c (graphite_legal_transform_bb): Avoid
2210 the computation of symmetric data dependence relations.
2211 (dependency_between_pbbs_p): Same.
2213 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
2216 * graphite-poly.c (apply_poly_transforms): Remove legality test before
2219 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
2221 * graphite-dependences.c (pddr_original_scattering): Return NULL
2222 for read-read dependence relations.
2223 * graphite-poly.h (enum poly_dr_type): Fix comment.
2226 (pdr_may_write_p): New.
2228 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
2230 * graphite-poly.h (enum POLY_DR_TYPE): Renamed poly_dr_type.
2231 (struct poly_dr): Same.
2232 (new_poly_dr): Same.
2233 * graphite-poly.c (new_poly_dr): Same.
2235 2009-08-25 Konrad Trifunovic <konrad.trifunovic@gmail.com>
2236 Sebastian Pop <sebastian.pop@amd.com>
2238 * graphite-blocking.c (pbb_strip_mine_loop_depth): Renamed
2239 pbb_strip_mine_time_depth. Changed the implementation so that
2240 transformation is expressed as a transformation on
2241 time (scatttering) dimensions. Also, ensures that the 2d+1
2242 scheduling format is preserved.
2243 (pbb_strip_mine_profitable_p): Profitability is based on the
2244 iteration number of a given time (scattering) dimension,
2245 and not on a original loop depth dimension.
2246 (pbb_strip_mine): Call pbb_number_of_iterations_at_time.
2247 (pbb_do_strip_mine): Call psct_dynamic_dim.
2248 * graphite-poly.c (pbb_number_of_iterations_at_time): New.
2249 * graphite-poly.h (pbb_number_of_iterations_at_time): Declared.
2250 (pbb_nb_dynamic_scattering_transform): New.
2251 (psct_dynamic_dim): New.
2253 2009-08-25 Konrad Trifunovic <konrad.trifunovic@gmail.com>
2255 * graphite-ppl.c (ppl_max_for_le): Renamed ppl_max_for_le_pointset.
2256 * graphite-ppl.h (ppl_max_for_le): Renamed ppl_max_for_le_pointset.
2257 * graphite-poly.c (pbb_number_of_iterations): Rename ppl_max_for_le.
2258 * graphite-interchange.c (build_linearized_memory_access): Same.
2259 (memory_stride_in_loop): Same.
2261 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
2263 * graphite-dependences.c (pddr_original_scattering): New.
2264 (graphite_legal_transform_dr): Call pddr_original_scattering.
2267 * graphite-dependences.h (dot_deps): Declared.
2268 * graphite-poly.c (new_poly_dr): Initialize PDR_ID.
2269 (print_pdr): Print PDR_ID.
2270 * graphite-poly.h (struct poly_dr): Add field id.
2273 * graphite-scop-detection.c (dot_all_scops_1): Cleanup comment.
2275 2009-08-22 Sebastian Pop <sebastian.pop@amd.com>
2277 * graphite-dependences.c (graphite_carried_dependence_level_k): Do
2278 not delete the original dependence relation.
2280 2009-08-21 Sebastian Pop <sebastian.pop@amd.com>
2282 * graphite-dependences.c (graphite_legal_transform_bb): Avoid
2283 the computation of symmetric data dependence relations.
2284 (dependency_between_pbbs_p): Same.
2286 2009-08-21 Sebastian Pop <sebastian.pop@amd.com>
2288 * graphite-dependences.c (new_poly_dr_pair): Renamed new_poly_ddr.
2289 (eq_poly_dr_pair_p): Renamed eq_poly_ddr_p.
2290 (hash_poly_dr_pair_p): Renamed hash_poly_ddr_p.
2291 (free_poly_ddr): New.
2292 (pddr_is_empty): New.
2293 (dependence_polyhedron_1): Now returns a poly_ddr_p.
2294 (dependence_polyhedron): Same. Remove useless gcc_assert.
2296 (graphite_legal_transform_dr): Call pddr_is_empty and free_poly_ddr.
2297 (graphite_carried_dependence_level_k): Call pddr_is_empty.
2298 * graphite-dependences.h (enum poly_dependence_kind): New.
2299 (poly_dr_pair): Renamed poly_ddr. Added a field kind.
2300 (PDRP_SOURCE): Renamed PDDR_SOURCE.
2301 (PDRP_SINK): Renamed PDDR_SINK.
2302 (PDRP_DDP): Renamed PDDR_DDP.
2304 (free_poly_ddr): Declared.
2305 * graphite-poly.c (new_scop): Use the new hash function names.
2306 * graphite-poly.h (struct scop): Renamed field original_pdr_pairs
2307 into original_pddrs.
2308 (SCOP_ORIGINAL_PDR_PAIRS): Renamed SCOP_ORIGINAL_PDDRS.
2310 2009-08-21 Sebastian Pop <sebastian.pop@amd.com>
2312 * Merge from mainline (150764:150992).
2314 2009-08-18 Sebastian Pop <sebastian.pop@amd.com>
2316 * cfgloopmanip.c (create_empty_loop_on_edge): Generate upper
2317 bounds with LT_EXPR to make niter analysis more precise on code
2318 generated by Graphite.
2320 2009-08-18 Sebastian Pop <sebastian.pop@amd.com>
2322 * graphite-dependences.c (graphite_legal_transform_dr): Fix formatting.
2323 (graphite_legal_transform_bb): Same.
2324 (poly_drs_may_alias_p): Same.
2326 2009-08-15 Sebastian Pop <sebastian.pop@amd.com>
2329 * graphite-ppl.c (ppl_max_for_le): Correct the use of
2330 ppl_Pointset_Powerset_C_Polyhedron_maximize.
2332 2009-08-13 Sebastian Pop <sebastian.pop@amd.com>
2334 * graphite-poly.c (print_pbb): Print PBB index.
2336 2009-08-13 Sebastian Pop <sebastian.pop@amd.com>
2338 * Merge from mainline (r150672:150764).
2340 2009-08-13 Sebastian Pop <sebastian.pop@amd.com>
2342 * graphite-interchange.c (ppl_max_for_le): Moved...
2343 * graphite-poly.c (pbb_number_of_iterations): Call ppl_max_for_le.
2344 * graphite-ppl.c (ppl_max_for_le): ... here.
2345 * graphite-ppl.h (ppl_max_for_le): Declared.
2347 2009-08-12 Sebastian Pop <sebastian.pop@amd.com>
2349 * Merge from mainline (r150372:150672).
2351 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
2354 * sese.c (convert_for_phi_arg): New.
2355 (add_guard_exit_phis): Use convert_for_phi_arg.
2357 * gfortran.dg/graphite/id-17.f: New.
2359 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
2361 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Dont add
2362 unknown subscript upper bounds.
2364 * gcc.dg/graphite/interchange-6.c: Un-XFAIL.
2366 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
2367 Pranav Garg <pranav.garg2107@gmail.com>
2369 * graphite-interchange.c (gather_access_strides): Removed.
2370 (ppl_max_for_le): New.
2371 (build_linearized_memory_access): New.
2372 (memory_stride_in_loop): New.
2373 (pbb_interchange_profitable_p): Reimplemented.
2374 * graphite-ppl.h (ppl_new_id_map): New.
2375 (ppl_interchange): New.
2377 * gcc.dg/graphite/interchange-6.c: XFAILed.
2379 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
2381 * graphite-interchange.c (compute_subscript): Removed.
2382 (compute_array_size_cstr): Removed.
2383 (compute_array_size_poly): Removed.
2384 (compute_array_size): Removed.
2385 (gather_access_strides_poly): Removed.
2386 (gather_access_strides): Empty.
2388 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
2390 * graphite-dependences.c (dependence_polyhedron_1): Replace
2391 pdr_nb_subscripts with PDR_NB_SUBSCRIPTS.
2392 (graphite_legal_transform_dr): Same.
2393 (graphite_carried_dependence_level_k): Same.
2394 * graphite-poly.c (new_poly_dr): Add a parameter nb_subscripts.
2395 Initialize PDR_NB_SUBSCRIPTS.
2396 (print_pdr_access_layout): Replace pdr_nb_subscripts with
2398 * graphite-poly.h (struct poly_dr): Add nb_subscripts field.
2399 (PDR_NB_SUBSCRIPTS): New.
2400 (pdr_nb_subscripts): Removed.
2401 (pdr_dim): Simplified.
2402 * graphite-sese-to-poly.c (build_poly_dr): Replace pdr_nb_subscripts
2403 with PDR_NB_SUBSCRIPTS.
2405 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
2407 * graphite-interchange.c (compute_array_size): Remove use of
2409 * graphite-poly.c (new_poly_dr): Remove argument data_container.
2410 Do not initialize PDR_DATA_CONTAINER.
2411 (print_pdr): Do not print PDR_DATA_CONTAINER.
2412 * graphite-poly.h (struct poly_dr): Remove data_container field.
2413 (PDR_DATA_CONTAINER): Removed.
2414 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Remove use of
2416 (build_poly_dr): Same.
2418 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
2420 * gcc.dg/graphite/interchange-9.c: New.
2422 2009-08-05 Konrad Trifunovic <konrad.trifunovic@gmail.com>
2423 Sebastian Pop <sebastian.pop@amd.com>
2425 * graphite-dependences.c (graphite_legal_transform_dr): Work on a
2426 copy of the dependence polyhedron. Free the temporary objects.
2427 (graphite_carried_dependence_level_k): Free unused objects before
2430 * gcc.dg/graphite/interchange-1.c: XFAILed.
2431 * gcc.dg/graphite/interchange-2.c: XFAILed.
2432 * gcc.dg/graphite/interchange-3.c: XFAILed.
2433 * gcc.dg/graphite/interchange-4.c: XFAILed.
2434 * gcc.dg/graphite/interchange-7.c: XFAILed.
2436 2009-08-05 Sebastian Pop <sebastian.pop@amd.com>
2438 * graphite-blocking.c (scop_do_strip_mine): Call store_scattering.
2439 Early return without analyzing the data dependences if no
2440 transform has been done. Call restore_scattering if the transform
2442 (graphite-interchange.c): Same.
2443 * graphite-poly.c (print_scattering_function): Test for PBB_TRANSFORMED.
2444 (graphite_read_transforms): Initialize PBB_TRANSFORMED.
2445 (apply_poly_transforms): Do not gcc_assert that
2446 the transform is legal.
2447 (new_poly_bb): Initialize PBB_TRANSFORMED, PBB_SAVED, and PBB_ORIGINAL.
2448 Do not initialize PBB_NB_SCATTERING_TRANSFORM, PBB_NB_LOCAL_VARIABLES,
2449 PBB_TRANSFORMED_SCATTERING, and PBB_ORIGINAL_SCATTERING.
2450 (free_poly_dr): Free PBB_TRANSFORMED, PBB_SAVED, and PBB_ORIGINAL.
2451 * graphite-poly.h (struct poly_scattering): New.
2452 (struct poly_bb): Add original, transformed, and saved fields.
2453 Remove transformed_scattering, original_scattering, nb_local_variables,
2454 and nb_scattering_transform fields.
2455 (PBB_ORIGINAL, PBB_TRANSFORMED, PBB_SAVED): New.
2456 (poly_scattering_new): New.
2457 (poly_scattering_free): New.
2458 (poly_scattering_copy): New.
2459 (store_scattering_pbb): New.
2460 (store_scattering): New.
2461 (restore_scattering_pbb): New.
2462 (restore_scattering): New.
2463 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons):
2464 Initialize PBB_TRANSFORMED and PBB_ORIGINAL.
2466 2009-08-05 Sebastian Pop <sebastian.pop@amd.com>
2468 * graphite-poly.c (print_pbb): Add parentheses in the pretty print.
2471 2009-08-05 Sebastian Pop <sebastian.pop@amd.com>
2473 * Makefile.in (graphite.o): Depends on PREDICT_H.
2474 * graphite.c: Include predict.h.
2475 (graphite_finalize): Call tree_estimate_probability.
2476 * predict.c (predict_loops): Do not call scev_initialize and
2478 (tree_estimate_probability_bb): New.
2479 (tree_estimate_probability): Do not initialize loops: move that
2480 code to the driver. Call tree_estimate_probability_bb.
2481 (tree_estimate_probability_driver): New.
2482 (pass_profile): Use tree_estimate_probability_driver.
2483 * predict.h (tree_estimate_probability): Declared.
2485 2009-08-05 Sebastian Pop <sebastian.pop@amd.com>
2487 * graphite-clast-to-gimple.c (gloog): Add time to TV_GRAPHITE_CODE_GEN.
2488 * graphite-dependences.c (graphite_legal_transform): Add time to
2489 TV_GRAPHITE_DATA_DEPS.
2490 (dependency_between_pbbs_p): Same.
2491 * timevar.def (TV_GRAPHITE_DATA_DEPS, TV_GRAPHITE_CODE_GEN): New.
2493 2009-08-03 Sebastian Pop <sebastian.pop@amd.com>
2495 * Merge from mainline (r149952:150372).
2497 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
2499 * ChangeLog.graphite: Fix indenting, white spaces and 80 columns.
2500 * graphite-blocking.c: Same.
2501 * graphite-clast-to-gimple.c: Same.
2502 * graphite-dependences.c: Same.
2503 * graphite-poly.c: Same.
2504 * graphite-poly.h: Same.
2505 * graphite-ppl.c: Same.
2506 * graphite-scop-detection.c: Same.
2507 * graphite-sese-to-poly.c: Same.
2510 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
2512 * graphite-sese-to-poly.c (loop_entry_phi_arg): New.
2513 (remove_simple_copy_phi): New.
2514 (remove_invariant_phi): New.
2515 (simple_copy_phi_p): New.
2516 (reduction_phi_p): New.
2517 (gsi_for_ssa_name_def): New.
2518 (insert_out_of_ssa_copy): New.
2519 (insert_out_of_ssa_copy_on_edge): New.
2520 (create_zero_dim_array): New.
2521 (scalar_close_phi_node_p): New.
2522 (rewrite_close_phi_out_of_ssa): New.
2523 (rewrite_phi_out_of_ssa): New.
2524 (rewrite_reductions_out_of_ssa): New.
2525 (build_poly_scop): Call rewrite_reductions_out_of_ssa.
2527 * gcc.dg/graphite/id-11.c: New.
2528 * gcc.dg/graphite/id-15.c: New.
2529 * gcc.dg/graphite/interchange-1.c: Un-XFAIL.
2530 * gcc.dg/graphite/interchange-2.c: Un-XFAIL.
2531 * gcc.dg/graphite/interchange-3.c: Un-XFAIL.
2532 * gcc.dg/graphite/interchange-4.c: Un-XFAIL.
2533 * gcc.dg/graphite/interchange-7.c: Un-XFAIL.
2534 * gcc.dg/graphite/scop-matmult.c: Un-XFAIL.
2535 * gfortran.dg/graphite/id-13.f: New.
2536 * gfortran.dg/graphite/id-5.f: New.
2538 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
2540 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not
2541 check that nb_reductions_in_loop is zero.
2542 * graphite-scop-detection.c (harmful_stmt_in_bb): Don't filter out
2543 reduction phi nodes.
2544 (nb_reductions_in_loop): Removed.
2545 (graphite_can_represent_loop): Do not call nb_reductions_in_loop.
2546 * graphite-sese-to-poly.c (phi_node_is_iv): Removed.
2547 (bb_contains_non_iv_scalar_phi_nodes): Removed.
2548 (scop_contains_non_iv_scalar_phi_nodes): Removed.
2549 (build_poly_scop): Do not call scop_contains_non_iv_scalar_phi_nodes.
2551 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
2553 * graphite-clast-to-gimple.c (build_cloog_prog): Do not code generate
2554 statements that have an empty iteration domain.
2555 * gfortran.dg/graphite/id-16.f: New.
2557 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
2559 * tree-scalar-evolution.c (instantiate_scev_1): Return
2560 chrec_dont_know when the result is not above instantiate_below.
2561 * graphite-scop-detection.c (scopdet_basic_block_info): Fix formatting.
2562 * graphite-sese-to-poly.c (create_linear_expr_from_tree): Assert that
2563 the tree has a known scalar evolution.
2564 * gfortran.dg/graphite/id-14.f: New.
2565 * gfortran.dg/graphite/id-15.f: New.
2567 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
2569 * sese.c (rename_variables_in_stmt): Pass in an extra parameter
2571 (rename_variables): Keep inserting renames after the ones already
2574 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
2576 * graphite-sese-to-poly.c (compare_bb_depths): New.
2577 (graphite_sort_dominated_info): New.
2578 (build_scop_bbs_1): Call graphite_sort_dominated_info.
2579 (build_scop_scattering): Fix comment.
2581 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
2583 * graphite.c (graphite_finalize): Call print_loops instead of
2584 dump_function_to_file.
2585 * gcc.dg/graphite/graphite.exp: Fix formatting.
2586 * gcc.dg/graphite/pr35356-1.c: New. Look for the number of
2587 loops generated in the graphite output file.
2588 * gcc.dg/graphite/pr35356-2.c: New.
2589 * gcc.dg/graphite/pr35356-3.c: New. XFAILed for now.
2590 * gfortran.dg/graphite/id-12.f: New.
2592 2009-07-24 Li Feng <nemokingdom@gmail.com>
2594 * gcc.dg/graphite/graphite_autopar/force-parallel-8.c:
2597 2009-07-24 Li Feng <nemokingdom@gmail.com>
2598 Tobias Grosser <grosser@fim.uni-passau.de>
2600 * graphite-sese-to-poly.c (pdr_add_alias_set): Use data reference's
2601 alias set number build alias in ACCESSES polyhedron.
2602 (build_alias_set_for_drs): New.
2603 (build_pbb_drs): Added build_alias_set_for_drs.
2604 * graphite-dependences.c (poly_drs_may_alias_p): New.
2605 (graphite_carried_dependence_level_k): Check alias information
2606 before building polyhedron.
2608 2009-07-24 Tobias Grosser <grosser@fim.uni-passau.de>
2610 * Makefile.in (lambda-code.o): Fix formatting.
2612 2009-07-24 Tobias Grosser <grosser@fim.uni-passau.de>
2614 * Merge from mainline (r149350-149952)
2616 2009-07-18 Tobias Grosser <grosser@fim.uni-passau.de>
2618 * graphite-poly.c (apply_poly_transforms): Move strip_mine
2619 before interchange to prepare for loop blocking.
2621 2009-07-18 Tobias Grosser <grosser@fim.uni-passau.de>
2623 * graphite-poly.c (apply_poly_transforms): Add checks after every
2625 * graphite-sese-to-poly.c (build_poly_scop): Remove check, as already
2626 done in apply_poly_transforms.
2628 2009-07-17 Konrad Trifunovic <konrad.trifunovic@gmail.com>
2630 * graphite-dependences.c (build_lexicographically_gt_constraint):
2631 Replace RES parameter with *RES.
2632 (dependence_polyhedron_1): Pass an address of the parameter RES
2633 instead of value of RES.
2635 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
2637 * graphite.c (graphite_finalize): Fix comment.
2638 (graphite_transform_loops): Reset scev info after code generation
2641 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
2643 * graphite.c (graphite_finalize): Call scev_reset.
2645 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
2647 * graphite-clast-to-gimple.c (compute_cloog_iv_types): Do not create
2648 GBB_CLOOG_IV_TYPES hash table twice.
2649 * graphite-sese-to-poly.c (free_gimple_bb): Call free_data_refs.
2650 (add_condition_to_domain): Clear GMP values.
2652 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
2654 * graphite-dependences.c: Fix formatting.
2655 * graphite-poly.c (free_poly_dr): Also free PDR_DATA_CONTAINER.
2656 (pbb_number_of_iterations): Free ppl_Linear_Expression.
2657 * graphite-sese-to-poly.c: Fix formatting.
2658 * graphite.c (graphite_transform_loops): Create the hash table
2659 after the early return.
2661 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
2663 * gcc.dg/graphite/id-14.c: New.
2664 * gcc.dg/graphite/pr40157.c: New.
2665 * gfortran.dg/graphite/id-11.f: New.
2667 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
2669 * graphite-sese-to-poly.c (nb_pbbs_in_loops): New.
2670 (build_poly_scop): Return false when there are no pbbs within
2671 loops to avoid to pass to cloog scops with no loops.
2673 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
2675 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons): Avoid
2676 useless test "i % 2".
2677 (build_pbb_scattering_polyhedrons): Fix formatting.
2678 (build_poly_dr): Same.
2679 * graphite.c (graphite_transform_loops): Restructure.
2681 2009-07-14 Razya Ladelsky <razya@il.ibm.com>
2683 * tree-ssa-loop-manip.c (rewrite_phi_with_iv): Remove
2684 reduction_list parameter.
2685 (rewrite_all_phi_nodes_with_iv): Same.
2686 (canonicalize_loop_ivs): Same.
2687 * tree-parloops.c (struct brli): Removed.
2688 (build_reduction_list_info): Removed.
2689 (build_new_reduction): New.
2690 (analyze_reduction_list): Removed.
2691 (gather_scalar_reductions): Find reductions instead of phi
2692 nodes that can't be canonicalized.
2693 (try_create_reduction_list): Remove reduction_list parameter.
2694 (gen_parallel_loop): Same.
2695 (parallelize_loops): Remove analyze_reductions variable,
2696 initialization and free.
2697 Change reduction_list htab initialization to reduction_info
2698 elements instead of ssa names.
2699 Call try_create_reduction_list and gen_parallel_loop without
2700 analyzed_reduction argument.
2701 * graphite-clast-to-gimple (graphite_loop_normal_form): Call
2702 canonicalize_loop_ivs with one less argument.
2703 * tree-flow.h (canonicalize_loop_ivs): Remove one argument.
2705 2009-07-14 Konrad Trifunovic <konrad.trifunovic@gmail.com>
2707 * graphite-dependences.c (new_poly_dr_pair): New.
2708 (dependence_polyhedron): Renamed into dependence_polyhedron_1.
2709 (new_poly_dr_pair): New.
2710 (eq_poly_dr_pair_p): New.
2711 (hash_poly_dr_pair_p): New.
2712 * graphite-dependences.h (struct poly_dr_pair): New.
2713 (eq_poly_dr_pair_p): Declared.
2714 (hash_poly_dr_pair_p): Declared.
2715 * graphite-poly.c (new_scop): Initialize SCOP_ORIGINAL_PDR_PAIRS.
2716 (free_scop): Free SCOP_ORIGINAL_PDR_PAIRS.
2717 * graphite-poly.h (struct scop): Add original_pdr_pairs field.
2718 * Makefile.in (graphite-poly.o): Add dependence on
2719 graphite-dependences.h.
2721 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
2723 * graphite-scop-detection.c (graphite_can_represent_scev): Do not let
2724 polynomials of degree > 1 pass to Graphite.
2725 * tree-chrec.c (scev_is_linear_expression): Call
2726 evolution_function_is_affine_multivariate_p.
2727 * gfortran.dg/graphite/id-10.f90: New.
2729 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
2731 * tree-scalar-evolution.c (compute_overall_effect_of_inner_loop):
2732 Instantiate scevs varying in outer loops.
2733 * gfortran.dg/graphite/id-9.f: Correct testcase.
2735 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
2737 * graphite-sese-to-poly.c (build_loop_iteration_domains): Do not insert
2738 redundant constraint.
2740 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
2742 * gcc.dg/graphite/graphite.exp: Fix comments.
2743 * gfortran.dg/graphite/graphite.exp: Trigger actions
2744 based on the file names as in the C testsuite.
2745 * gfortran.dg/graphite/block-1.f90: Fix patterns.
2746 * gfortran.dg/graphite/block-2.f: Same.
2747 * gfortran.dg/graphite/block-3.f90: Same.
2748 * gfortran.dg/graphite/block-4.f90: Same.
2749 * gfortran.dg/graphite/id-1.f90: Same.
2750 * gfortran.dg/graphite/id-2.f90: Same.
2751 * gfortran.dg/graphite/id-3.f90: Same.
2752 * gfortran.dg/graphite/id-4.f90: Same.
2753 * gfortran.dg/graphite/id-6.f: Same.
2754 * gfortran.dg/graphite/id-9.f: Same.
2755 * gfortran.dg/graphite/interchange-1.f: Same.
2756 * gfortran.dg/graphite/interchange-2.f: Same.
2757 * gfortran.dg/graphite/scop-1.f: Same.
2759 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
2761 * sese.c (expand_scalar_variables_call): New.
2762 (expand_scalar_variables_ssa_name): Handle calls in expander.
2764 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
2766 * gcc.dg/graphite/graphite_autopar/force-parallel-6.c:
2767 Expect to see the pattern twice.
2768 * gcc.dg/graphite/interchange-0.c: Un-XFAIL.
2769 * gcc.dg/graphite/interchange-5.c: Same.
2770 * gcc.dg/graphite/interchange-6.c: Same.
2772 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
2774 * gcc.dg/graphite/id-10.c: New.
2775 * gcc.dg/graphite/id-12.c: New.
2776 * gfortran.dg/graphite/id-7.f: New.
2777 * gfortran.dg/graphite/id-8.f: New.
2779 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
2781 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Fix division by
2784 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
2786 * sese.c (rename_variables_in_stmt): Call fold_convert during renaming.
2788 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
2790 * sese.c (expand_scalar_variables_stmt): Avoid unnecessary expansion.
2792 2009-07-10 Sebastian Pop <sebastian.pop@amd.com>
2794 * graphite-sese-to-poly.c (pdr_add_memory_accesses): Fix order of
2795 building PDR subscripts.
2797 2009-07-10 Sebastian Pop <sebastian.pop@amd.com>
2799 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Fix the
2800 computation of array sizes.
2802 2009-07-10 Sebastian Pop <sebastian.pop@amd.com>
2804 * graphite-sese-to-poly.c (add_param_constraints): Disabled.
2806 2009-07-10 Tobias Grosser <grosser@fim.uni-passau.de>
2808 * graphite-dependences.c (map_into_dep_poly, map_dr_into_dep_poly,
2809 build_pairwise_constraint, dr_equality_constraints,
2810 build_pairwise_scheduling_equality,
2811 build_pairwise_scheduling_inequality, lexicographically_gt_p,
2812 build_lexicographically_gt_constraint, dependence_polyhedron,
2813 graphite_legal_transform_dr, graphite_carried_dependence_level_k):
2814 Move from NNC_Polyhedron to C_Polyhedron.
2815 * graphite-interchange.c (compute_array_size_poly,
2816 gather_access_strides): Dito.
2817 * graphite-poly.c (apply_poly_transforms, new_poly_dr, free_poly_bb,
2818 free_scop, pbb_number_of_iterations): Dito.
2819 * graphite-poly.h (struct poly_dr, pdr_nb_subscripts, struct poly_bb,
2820 pbb_dim_iter_domain, struct scop): Dito.
2821 * graphite-ppl.c (new_Constraint_System_from_Cloog_Matrix,
2822 new_Cloog_Domain_from_ppl_Polyhedron,
2823 new_Cloog_Domain_from_ppl_Pointset_Powerset, ppl_set_coef_gmp,
2824 ppl_insert_dimensions_pointset, ppl_insert_dimensions_pointset,
2825 ppl_strip_loop, ppl_strip_loop, ppl_print_polyhedron_matrix,
2826 ppl_print_powerset_matrix, debug_ppl_polyhedron_matrix,
2827 debug_ppl_powerset_matrix, ppl_read_polyhedron_matrix): Dito.
2828 * graphite-ppl.h (ppl_Pointset_Powerset_C_Polyhedron_t,
2829 new_C_Polyhedron_from_Cloog_Matrix, ppl_print_powerset_matrix,
2830 debug_ppl_powerset_matrix, ppl_insert_dimensions_pointset): Dito.
2831 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons,
2832 build_loop_iteration_domains, ppl_constraint_type_from_tree_code,
2833 add_condition_to_domain, add_condition_to_pbb, build_scop_context,
2834 build_scop_iteration_domain, build_poly_dr): Dito
2836 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
2838 * gcc.dg/graphite/graphite.exp: Added a rule to execute
2840 * gcc.dg/graphite/run-id-1.c: New.
2842 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
2844 * graphite-sese-to-poly.c (build_loop_iteration_domains): Add the
2845 positivity constraint on the symbolic number of iterations.
2847 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
2849 * graphite-sese-to-poly.c (build_loop_iteration_domains): Rewrite.
2851 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
2852 Tobias Grosser <grosser@fim.uni-passau.de>
2854 * graphite-clast-to-gimple.c (build_scop_context): Removed.
2855 (build_cloog_prog): Directly use SCOP_CONTEXT.
2856 * graphite-poly.c (new_scop): Initialize SCOP_CONTEXT.
2857 (free_scop): Free SCOP_CONTEXT.
2858 (print_scop_context): New.
2859 (print_scop): Call print_scop_context.
2860 (debug_scop_context): New.
2861 * graphite-poly.h (print_scop_context, debug_scop_context): Declared.
2862 (struct scop): Added field context.
2863 (SCOP_CONTEXT): New.
2864 * graphite-sese-to-poly.c (add_param_constraints): New.
2865 (build_scop_context): New.
2866 (build_poly_scop): Call build_scop_context.
2868 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
2870 * graphite-clast-to-gimple.c (gmp_cst_to_tree): Moved...
2871 * graphite-ppl.c (ppl_set_inhomogeneous_gmp, ppl_set_coef_gmp): New.
2872 (ppl_set_inhomogeneous, ppl_set_coef): Moved...
2873 * graphite-ppl.h: Include double-int.h and tree.h.
2874 (ppl_set_inhomogeneous_gmp, ppl_set_coef_gmp): Declared.
2875 (ppl_set_inhomogeneous, ppl_set_coef): ...here.
2876 (gmp_cst_to_tree): ...here. Reimplemented using mpz_get_double_int.
2877 (tree_int_to_gmp, ppl_set_inhomogeneous_tree, ppl_set_coef_tree): New.
2879 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
2881 * graphite-clast-to-gimple.c (clast_to_gcc_expression_red): Generate
2882 POINTER_PLUS_EXPR for pointer types.
2883 (clast_to_gcc_expression): Same.
2885 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
2887 * graphite-poly.c (print_scattering_function): Early return when
2888 PBB_TRANSFORMED_SCATTERING is not initialized.
2889 (print_pbb_domain): Early return when PBB_DOMAIN is not initialized.
2891 2009-07-08 Sebastian Pop <sebastian.pop@amd.com>
2893 * tree-parloops.c (analyze_reduction_list): Remove unused variable
2896 2009-07-08 Razya Ladelsky <razya@il.ibm.com>
2898 * tree-parloops.c (analyze_reduction_list): Change return
2900 (try_create_reduction_list): Move the call to
2901 analyze_reduction_list to the beginining.
2902 Call reduction_phi with analyzed_reductions as argument
2903 instead of reduction_list.
2905 2009-07-08 Tobias Grosser <grosser@fim.uni-passau.de>
2907 * Merge from mainline (r148296:149346)
2909 2009-07-07 Sebastian Pop <sebastian.pop@amd.com>
2911 * graphite-scop-detection.c (graphite_can_represent_init): New.
2912 (graphite_can_represent_scev): Call graphite_can_represent_init:
2913 check that the initial value does not contain multiplications of
2915 (stmt_has_simple_data_refs_p): New.
2916 (stmt_simple_for_scop_p): Call stmt_simple_for_scop_p.
2917 (is_simple_operand): Fix formatting.
2918 * graphite-sese-to-poly.c (try_generate_gimple_bb): Fix formatting.
2920 2009-07-07 Sebastian Pop <sebastian.pop@amd.com>
2922 * gcc.dg/graphite/id-13.c: New.
2923 * graphite-sese-to-poly.c (graphite_stmt_p): Do not call
2924 analyze_scalar_evolution, use scalar_evolution_in_region.
2925 (scan_tree_for_params_right_scev): Add extra assert.
2926 (parameter_index_in_region_1): Split from parameter_index_in_region.
2927 (idx_record_params): Use scalar_evolution_in_region.
2928 (find_params_in_bb): Same.
2929 (find_scop_parameters): Same.
2930 (build_loop_iteration_domains): Same.
2931 (create_linear_expr_from_tree): Same.
2932 * sese.c (scalar_evolution_in_region): New.
2933 * sese.h (scalar_evolution_in_region): Declared.
2934 (defined_in_sese_p): New.
2935 * tree-scalar-evolution.c (compute_overall_effect_of_inner_loop): Not
2937 * tree-scalar-evolution.h (compute_overall_effect_of_inner_loop):
2940 2009-07-07 Sebastian Pop <sebastian.pop@amd.com>
2942 * Makefile.in: Replace dependences on tree-chrec.h with SCEV_H.
2943 TREE_DATA_REF_H also implies SCEV_H.
2945 2009-07-07 Sebastian Pop <sebastian.pop@amd.com>
2947 * graphite-poly.c (print_scop_params): New.
2948 (print_scop): Call print_scop_params.
2949 (debug_scop_params): New.
2950 * graphite-poly.h (print_scop_params, debug_scop_params): Declared.
2952 2009-07-07 Li Feng <nemokingdom@gmail.com>
2954 * gcc.dg/graphite/graphite_autopar/force-parallel-4.c: New.
2955 * gcc.dg/graphite/graphite_autopar/force-parallel-5.c: New.
2956 * gcc.dg/graphite/graphite_autopar/force-parallel-6.c: New.
2957 * gcc.dg/graphite/graphite_autopar/force-parallel-7.c: New.
2958 * gcc.dg/graphite/graphite_autopar/force-parallel-8.c: New.
2959 * gcc.dg/graphite/graphite_autopar/force-parallel-9.c: New.
2961 2009-07-07 Li Feng <nemokingdom@gmail.com>
2963 * graphite-clast-to-gimple.c (mark_loops_parallel): Dump information
2964 for dependency checking part.
2965 * gcc.dg/graphite/graphite_autopar/force-parallel-1.c: Add
2966 tests for dependency checking.
2967 * gcc.dg/graphite/graphite_autopar/force-parallel-2.c: Ditto.
2968 * gcc.dg/graphite/graphite_autopar/force-parallel-3.c: Ditto.
2969 * gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: Add
2970 flag -fdump-tree-graphite-all for autopar testsuites.
2972 2009-07-06 Sebastian Pop <sebastian.pop@amd.com>
2974 * Makefile.in (tree-ssa-loop-manip.o): Depends on langhooks.h.
2975 * tree-parloops.c (rewrite_phi_with_iv, rewrite_all_phi_nodes_with_iv,
2976 canonicalize_loop_ivs): Moved...
2977 * tree-ssa-loop-manip.c: ... here. Include langhooks.h.
2979 2009-07-06 Sebastian Pop <sebastian.pop@amd.com>
2981 * tree-parloops.c (try_create_reduction_list): Pass an extra
2982 argument analyzed_reductions. Call analyze_reduction_list.
2983 (gen_parallel_loop): Do not call analyze_reduction_list.
2984 (parallelize_loops): Init and finalize analyzed_reductions.
2986 2009-07-06 Li Feng <nemokingdom@gmail.com>
2988 * gcc.dg/graphite/graphite_autopar/graphite_autopar.exp:
2989 Added flag -fno-loop-strip-mine for autopar testcase.
2991 2009-07-04 Li Feng <nemokingdom@gmail.com>
2993 * graphite-dependences.c (graphite_carried_dependence_level_k): Use
2994 transformed scattering dimension instead of unmatch orignal when
2995 calling dependence_polyhedron.
2997 2009-06-30 Sebastian Pop <sebastian.pop@amd.com>
2999 * opts.c (decode_options): Enable flag_loop_strip_mine at -O2.
3001 2009-06-30 Sebastian Pop <sebastian.pop@amd.com>
3003 * graphite-poly.c (pbb_number_of_iterations): Check for returned
3004 value 1 from ppl_Pointset_Powerset_NNC_Polyhedron_maximize.
3006 2009-06-30 Sebastian Pop <sebastian.pop@amd.com>
3008 * graphite-blocking.c (pbb_strip_mine_profitable_p): New.
3009 (pbb_do_strip_mine): Call pbb_strip_mine_profitable_p.
3010 * graphite-poly.c (pbb_number_of_iterations): New.
3011 * graphite-poly.h (pbb_number_of_iterations): Declared.
3012 (pbb_iterator_dim, pbb_parameter_dim): New.
3014 2009-06-29 Sebastian Pop <sebastian.pop@amd.com>
3016 * graphite-clast-to-gimple.c (graphite_create_new_loop): Revert the
3017 last commit on type of lower and upper bound of loops.
3019 2009-06-29 Li Feng <nemokingdom@gmail.com>
3021 * Makefile.in (graphite-clast-to-gimple.o): Added dependence on
3022 graphite-dependences.h.
3023 * graphite-clast-to-gimple.c (new_bb_pbb_def): New.
3024 (mark_bb_with_pbb): New.
3025 (get_stmtfor_depth): New.
3026 (find_pbb_via_hash): New.
3027 (dependency_in_loop_p): New.
3028 (mark_loops_parallel): New.
3029 (free_aux_in_new_loops): New.
3030 (translate_clast): Add parameter BB_PBB_MAPPING. Mark newly created
3031 bb with it's relevant pbb. Mark newly created loops. Remove mark
3032 innermost loop parallel without checking.
3033 (gloog): Add parameter BB_PBB_MAPPING.
3034 * graphite-clast-to-gimple.h (struct bb_pbb_def): New.
3035 (gloog): Change declaration.
3036 (mark_loop_parallel): Make extern.
3037 (free_aux_in_new_loops): Declare.
3038 (bb_pbb_map_hash): New.
3039 (eq_bb_pbb_map): New.
3040 * graphite.c (graphite_transform_loops): Added BB_PBB_MAPPING. Trigger
3041 auto parallelization when flag_graphite_force_parallel is set.
3042 (graphite_finalize): Added free_aux_in_new_loops.
3043 * tree-parloops.c (parallelize_loops): Only generate parallel code for
3044 the innermost loop that marked parallel. Use
3045 flag_graphite_force_parallel instead of loop->can_be_parallel.
3046 (loop_parallel_p): Move inner most checking out of function.
3048 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
3050 * graphite-clast-to-gimple.c (graphite_create_new_loop): Make the
3051 type of lower and upper bound of loops signed long int.
3053 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
3055 * cfgloopmanip.c (create_empty_loop_on_edge): Gimplify the loop exit
3056 expression outside the loop.
3058 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
3060 * gcc.dg/graphite/interchange-8.c: New.
3062 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
3064 * gcc.dg/graphite/interchange-0.c: XFailed.
3065 * gcc.dg/graphite/interchange-5.c: XFailed.
3066 * gcc.dg/graphite/interchange-6.c: XFailed.
3068 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
3070 * graphite-interchange.c (compute_array_size_poly): The end of the
3071 recursion should return 1.
3073 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
3075 * graphite-interchange.c (compute_array_size_cstr): Allow the
3076 subscript multiplier to be -1.
3077 (compute_array_size): Use PDR_DATA_CONTAINER and not PDR_ACCESSES.
3078 * graphite-poly.c (new_poly_dr): Takes an extra argument for the
3079 data_container. Initializes PDR_DATA_CONTAINER.
3080 (print_pdr_access_layout): New.
3081 (print_pdr): Call print_pdr_access_layout. Print PDR_DATA_CONTAINER.
3082 * graphite-poly.h (struct poly_dr): Adjust comment. Add a new field
3084 (PDR_DATA_CONTAINER): New.
3085 (new_poly_dr): Update declaration.
3086 * graphite-sese-to-poly.c (pdr_add_data_dimensions): New.
3087 (build_poly_dr): Call pdr_add_data_dimensions.
3089 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
3091 * graphite-poly.h (struct poly_dr): Fix comment.
3092 * graphite-sese-to-poly.c (pdr_add_alias_set): New.
3093 (pdr_add_memory_accesses): New.
3094 (build_poly_dr): Call pdr_add_memory_accesses and pdr_add_alias_set.
3096 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
3098 * graphite-poly.c (print_pdrs, debug_pdrs): New.
3099 (print_pbb): Add call to print_pdrs.
3100 * graphite-poly.h (print_pdrs, debug_pdrs): Declared.
3102 2009-06-24 Konrad Trifunovic <konrad.trifunovic@gmail.com>
3103 Li Feng <nemokingdom@gmail.com>
3105 * graphite-dependences.c (graphite_carried_dependence_level_k): New.
3106 (dependency_between_pbbs_p): New.
3107 (lexicographically_gt_p): Assure !empty_p before polyhedron
3108 intersection assign.
3109 (build_lexicographically_gt_constraint): Correct lexicographically
3111 * graphite-dependences.h: New.
3112 * Makefile.in (graphite-dependences.o): Add graphite-dependences.h.
3114 2009-06-24 Sebastian Pop <sebastian.pop@amd.com>
3116 * graphite-clast-to-gimple.c (print_clast_stmt): New.
3117 (gloog): Print to dump_file the generated clast.
3118 * graphite-clast-to-gimple.h (print_clast_stmt): Declared.
3119 * graphite-interchange.c (pbb_do_interchange): Fix dump formatting.
3121 2009-06-24 Sebastian Pop <sebastian.pop@amd.com>
3123 * graphite-poly.c (extend_scattering): Increment
3124 PBB_NB_LOCAL_VARIABLES by the number of added dimensions.
3126 2009-06-24 Sebastian Pop <sebastian.pop@amd.com>
3128 * graphite-interchange.c (compute_array_size_poly): Added exit of
3129 recursion condition. Continue iterating even after the first equality.
3130 (compute_array_size): Same.
3132 2009-06-24 Li Feng <nemokingdom@gmail.com>
3134 * gcc.dg/graphite/graphite_autopar/force-parallel-1.c: Update
3135 -fdump-tree-final_cleanup to -fdump-tree-optimized.
3136 * gcc.dg/graphite/graphite_autopar/force-parallel-2.c: Ditto.
3137 * gcc.dg/graphite/graphite_autopar/force-parallel-3.c: Ditto.
3138 * gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: Ditto.
3140 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
3142 * sese.c (expand_scalar_variables_stmt): Expand scalar variables
3143 only when the use verifies is_gimple_reg.
3145 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
3147 * graphite-clast-to-gimple.c (build_cloog_prog): Fix memory corruption.
3148 Allocate scaldims after call to unify_scattering_dimensions.
3150 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
3152 * graphite-clast-to-gimple.c (translate_clast): Fix memory leak.
3154 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
3155 Albert Cohen <albert.cohen@inria.fr>
3157 * graphite-blocking.c (pbb_strip_mine_loop_depth): Do not use local
3158 variables for the strip mining.
3160 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
3161 Pranav Garg <pranav.garg2107@gmail.com>
3163 * Makefile.in (OBJS-common): Added graphite-blocking.o.
3164 (graphite-sese-to-poly.o): Moved down to be in lexicographical order.
3165 (graphite-blocking.o): New rule.
3166 (graphite-poly.o, graphite-ppl.o): Moved to be in lexicographical order.
3167 * graphite-blocking.c: New.
3168 * graphite-poly.c (apply_poly_transforms): Call scop_do_strip_mine for
3169 flag_loop_strip_mine.
3170 (psct_scattering_dim_for_loop_depth): New.
3171 * graphite-poly.h (scop_do_strip_mine): Declared.
3172 (psct_add_local_variable): Increment PBB_NB_LOCAL_VARIABLES.
3173 * tree-ssa-loop.c (gate_graphite_transforms): Do not fail when using
3174 flag_loop_strip_mine.
3176 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
3178 * graphite-poly.c (extend_scattering): Avoid initializing and freeing
3179 a GMP value and a PPL coefficient at each iteration of a loop.
3181 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
3183 * graphite-dependences.c (dependence_polyhedron): Do not use
3184 pbb_nb_scattering_dims anymore. Use pbb_nb_scattering_orig and
3185 pbb_nb_scattering_transform.
3186 (graphite_legal_transform_dr): Same.
3187 * graphite-poly.c (extend_scattering): Same.
3188 (unify_scattering_dimensions): Same.
3189 (print_scattering_function): Same.
3190 (new_poly_bb): Initialize PBB_NB_SCATTERING_TRANSFORM and
3191 PBB_NB_LOCAL_VARIABLES.
3192 * graphite-poly.h (pbb_nb_scattering): Removed declaration.
3193 (struct poly_bb): Added nb_local_variables and nb_scattering_transform.
3194 (PBB_NB_LOCAL_VARIABLES, PBB_NB_SCATTERING_TRANSFORM): New.
3195 (pbb_nb_scattering_orig, pbb_nb_scattering_transform): New.
3196 (pbb_nb_scattering_dims, pbb_nb_scattering): Removed.
3197 (pbb_nb_scattering_transform): New.
3198 (pbb_nb_local_vars): Return PBB_NB_LOCAL_VARIABLES.
3199 (psco_scattering_dim): Add assert on parameters.
3200 (psct_scattering_dim): Same.
3201 (psct_scattering_dim_for_loop_depth): Declared.
3202 (psct_local_var_dim): New.
3203 (psco_iterator_dim, psco_parameter_dim): Add assert on parameters.
3204 (psct_iterator_dim, psct_parameter_dim): Same. To maintain the
3205 correct layout, call pbb_nb_local_vars.
3206 (psct_add_local_variable, psct_add_scattering_dimension): New.
3207 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons):
3208 Initialize PBB_NB_SCATTERING_TRANSFORM.
3210 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
3212 * graphite-ppl.c (set_inhomogeneous): Renamed ppl_set_inhomogeneous.
3213 (set_coef): Renamed ppl_set_coef.
3214 * graphite-ppl.h (ppl_set_inhomogeneous, ppl_set_coef): Declared.
3216 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
3218 * graphite-dependences.c (build_pairwise_scheduling_inequality): Don't
3219 test a boolean against 1.
3220 * graphite-interchange.c (pbb_interchange_loop_depths): Do not build
3221 a new polyhedron for the PBB_TRANSFORMED_SCATTERING.
3222 (pbb_do_interchange): Returns true when a transform has been performed.
3223 (scop_do_interchange): Same.
3224 * graphite-poly.c (apply_poly_transforms): Use the return value of
3225 scop_do_interchange.
3226 * graphite-poly.h (scop_do_interchange): Update declaration.
3228 2009-06-23 Tobias Grosser <grosser@fim.uni-passau.de>
3230 * graphite-clast-to-gimple.c (gloog): Reset loop->aux right
3232 * sese.c (sese_reset_aux_in_loops): New.
3233 * sese.h (sese_reset_aux_in_loops): New.
3235 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
3237 * graphite-sese-to-poly.c (scan_tree_for_params_int): Pass in the
3238 multiplier and multiply the constant by the multiplier.
3239 (scan_tree_for_params): Bound the multiplier to its MULT_EXPR.
3240 (build_poly_dr): Do not use the multiplier to define the subscript.
3242 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
3244 * graphite-poly.c (new_poly_dr): Pass an extra argument for the
3245 compiler's data reference. Initialize PDR_CDR.
3246 (print_pdr): Call dump_data_reference.
3247 * graphite-poly.h (struct poly_dr): Rename black_box into pbb.
3248 Add compiler_dr field.
3249 (PDR_BB): Renamed PDR_PBB.
3251 * graphite-sese-to-poly.c (build_poly_dr): Pass to new_poly_dr
3252 GCC's data reference representation.
3253 * tree-data-ref.c (debug_data_references, debug_data_reference): New.
3254 * tree-data-ref.h (debug_data_references, debug_data_reference): Decl.
3256 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
3258 * graphite-poly.c (print_scattering_function): Also print the layout.
3259 * graphite-poly.h (pbb_nb_local_vars): New.
3261 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
3263 * graphite-poly.c (print_pbb_domain): Also print the layout names.
3265 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
3267 * graphite-poly.c (print_pdr, debug_pdr): New.
3268 * graphite-poly.h (print_pdr, debug_pdr): Declared.
3269 (PDR_BASE): Removed.
3271 2009-06-18 Sebastian Pop <sebastian.pop@amd.com>
3273 * gcc.dg/graphite/interchange-{1..7}.c: New avatars of
3276 2009-06-18 Sebastian Pop <sebastian.pop@amd.com>
3278 * graphite-interchange.c (compute_subscript): Allow also -1 in the
3279 subscript identification column.
3280 (pbb_do_interchange): Print to dump_file that some loops "will be
3281 interchanged". Rely on that chain of characters in the testcases.
3282 * gcc.dg/graphite/interchange-0.c: New.
3283 * gcc.dg/graphite/graphite.exp: Iterate over the testsuite
3284 interchange-*.c files and compile them with -floop-interchange.
3286 2009-06-18 Pranav Garg <pranav.garg2107@gmail.com>
3288 * graphite-interchange.c (interchange_profitable_p): Renamed
3289 pbb_interchange_profitable_p.
3291 2009-06-18 Sebastian Pop <sebastian.pop@amd.com>
3292 Harsha Jagasia <harsha.jagasia@amd.com>
3293 Pranav Garg <pranav.garg2107@gmail.com>
3295 * graphite-interchange.c (interchange_profitable_p): Make static.
3296 (pbb_interchange_loop_depths, pbb_do_interchange,
3297 scop_do_interchange): New.
3298 * graphite-poly.c (apply_poly_transforms): Call scop_do_interchange
3299 for flag_loop_interchange.
3300 * graphite-poly.h (scop_do_interchange): Declared.
3301 * tree-ssa-loop.c (gate_graphite_transforms): Do not fail when
3302 flag_loop_interchange is used.
3304 2009-06-18 Sebastian Pop <sebastian.pop@amd.com>
3306 * graphite-dependences.c (dependence_polyhedron): Update use of
3307 pbb_nb_scattering_dims.
3308 * graphite-poly.h (pbb_nb_scattering_dims): Do not pass SCOP.
3309 (pbb_nb_scattering): Update use of pbb_nb_scattering_dims.
3310 (psco_scattering_dim, psct_scattering_dim, psco_iterator_dim,
3311 psct_iterator_dim, psco_parameter_dim, psct_parameter_dim): New.
3313 2009-06-16 Sebastian Pop <sebastian.pop@amd.com>
3315 * graphite.c: Cleanup foo.
3317 2009-06-16 Sebastian Pop <sebastian.pop@amd.com>
3319 * Merge from mainline (r143684:148293).
3320 * Disabled libpcp until it gets fixed.
3322 2009-06-05 Sebastian Pop <sebastian.pop@amd.com>
3323 Harsha Jagasia <harsha.jagasia@amd.com>
3325 * graphite-interchange.c: New.
3326 * Makefile.in (graphite-interchange.o): New.
3327 * graphite-poly.h (interchange_profitable_p): Declared.
3328 * graphite-ppl.h (value_max): New.
3330 2009-06-04 Sebastian Pop <sebastian.pop@amd.com>
3332 * graphite-dependences.c (dependence_polyhedron): Use pdr_dim.
3333 * graphite-poly.h: Fix some comments.
3337 2009-06-04 Sebastian Pop <sebastian.pop@amd.com>
3340 (pdr_accessp_nb_subscripts): Renamed pdr_nb_subscripts.
3341 (pdr_accessp_nb_iterators): Renamed pdr_dim_iter_domain.
3342 (pdr_accessp_nb_params): Renamed pdr_nb_params.
3343 (pdr_accessp_alias_set_dim): Renamed pdr_alias_set_dim.
3344 (pdr_accessp_subscript_dim): Renamed pdr_subscript_dim.
3345 (pdr_accessp_iterator_dim): Renamed pdr_iterator_dim.
3346 (pdr_accessp_param_dim): Renamed pdr_parameter_dim.
3347 (pbb_nb_loops): Renamed pbb_dim_iter_domain.
3348 * graphite-clast-to-gimple.c: Same.
3349 * graphite-dependences.c: Same.
3350 * graphite-poly.c: Same.
3351 * graphite-sese-to-poly.c: Same.
3353 2009-06-03 Sebastian Pop <sebastian.pop@amd.com>
3355 * graphite-clast-to-gimple.c (build_iv_mapping): Insert full
3356 expressions for an IV rename, as returned by clast_to_gcc_expression.
3357 (copy_renames): Rename new_name to expr.
3358 * sese.c (debug_rename_elt): Same.
3361 (sese_adjust_liveout_phis): Call force_gimple_operand before using
3362 the information from the rename map.
3363 (rename_variables_in_stmt): Same.
3364 (add_loop_exit_phis): Rename new_name to expr.
3365 (insert_loop_close_phis): Same.
3366 (add_guard_exit_phis): Same. Call force_gimple_operand.
3367 * sese.h (struct rename_map_elt): Rename new_name to expr.
3368 (new_rename_map_elt): Same.
3370 2009-06-03 Sebastian Pop <sebastian.pop@amd.com>
3372 * graphite-clast-to-gimple.c (build_iv_mapping): Use set_rename.
3373 * sese.c (set_rename): Make it extern.
3374 * sese.h (set_rename): Declared.
3376 2009-06-03 Sebastian Pop <sebastian.pop@amd.com>
3378 * graphite-poly.c (extend_scattering): Free values.
3379 * graphite-ppl.c (new_Cloog_Domain_from_ppl_Pointset_Powerset):
3381 (ppl_print_powerset_matrix): Same.
3382 * graphite-scop-detection.c (free_scops_1): New.
3383 (limit_scops): Call free_scops_1.
3384 * graphite-sese-to-poly.c (build_scop_bbs_1): Free dom.
3385 (build_poly_dr): Free PPL coefficients.
3386 * tree-parloops.c (rewrite_all_phi_nodes_with_iv): Free bbs.
3388 2009-06-02 Sebastian Pop <sebastian.pop@amd.com>
3390 * graphite-dependences.c: New.
3391 * graphite-data-ref.c: Removed.
3392 * graphite-data-ref.h: Removed.
3393 * Makefile.in (graphite-data-ref.o): Removed.
3394 (graphite-dependences.o): Added.
3395 * graphite-clast-to-gimple.c: Remove dependence on graphite-data-ref.h.
3396 * graphite-poly.c: Same.
3397 Move the data dependence testing to graphite-dependences.c.
3399 2009-05-19 Tobias Grosser <grosser@fim.uni-passau.de>
3401 * graphite-scop-detection.c (graphite_can_represent_loop): Renamed
3402 from graphite_cannot_represent_loop. Code refactored.
3403 (scopdet_basic_block_info): Call graphite_can_represent_loop.
3405 2009-05-17 Li Feng <nemokingdom@gmail.com>
3407 * gcc.dg/graphite/graphite_autopar/graphite_autopar.exp:
3408 Cover all the testcases (not only the filtered ones).
3410 2009-05-17 Tobias Grosser <grosser@fim.uni-passau.de>
3412 * graphite-scop-detection.c (stmt_simple_for_scop_p): Remove
3413 unnecessary check. Update comments. Move check for REAL_TYPE here.
3414 (harmful_stmt_in_bb): Remove checks for conditions. This is already
3415 done in (stmt_simple_for_scop_p).
3417 2009-05-14 Tobias Grosser <grosser@fim.uni-passau.de>
3419 * graphite.c (print_global_statistics): New.
3420 (print_graphite_scop_statistic): New.
3421 (print_graphite_statistics): New.
3422 (graphite_initialize, graphite_transform_loops): Print statistics.
3423 * graphite-scop-detection (build_scops): Print statistics.
3424 (print_graphite_scop_statistics): New.
3425 (print_graphite_statistics): New.
3427 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
3429 * graphite-clast-to-gimple.c (struct clast_name_index): Removed.
3430 (debug_clast_name_index): Removed.
3431 (debug_clast_name_indexes_1): Removed.
3432 (debug_clast_name_indexes): Removed.
3433 (clast_name_index_elt_info): Removed.
3434 (eq_clast_name_indexes): Removed.
3435 (clast_name_to_index): Removed.
3436 (new_clast_name_index): Removed.
3437 (save_clast_name_index): Removed.
3438 (save_var_name): Moved...
3439 (init_sese_params_index): Removed.
3440 (clast_name_to_gcc): Remove use of name_tree.
3441 (initialize_cloog_names): Same.
3442 (gloog): Do not call init_sese_params_index.
3443 * graphite-sese-to-poly.c (save_var_name): ...here.
3444 (parameter_index_in_region): New.
3445 * sese.c (new_sese): Initialize SESE_PARAMS_NAMES.
3446 (parameter_index_in_region): Removed.
3447 (is_parameter): Remove use of name_tree.
3448 * sese.h (struct name_tree): Removed.
3449 (struct sese): Remove use of name_tree. New field params_names.
3450 (SESE_PARAMS_NAMES): New.
3451 (SESE_PARAMS): Remove duplicate.
3452 (parameter_index_in_region): Removed.
3453 (sese_nb_params): Remove use of name_tree.
3454 (struct clast_name_index): New.
3455 (new_clast_name_index): New.
3456 (clast_name_to_index): New.
3457 (save_clast_name_index): New.
3458 (debug_clast_name_index): New.
3459 (debug_clast_name_indexes_1): New.
3460 (debug_clast_name_indexes): New.
3461 (clast_name_index_elt_info): New.
3462 (eq_clast_name_indexes): New.
3464 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
3466 * graphite-clast-to-gimple.c (compute_cloog_iv_types_1): Call
3467 pbb_to_depth_to_oldiv. Remove call to oldiv_for_loop.
3468 (graphite_loop_normal_form): Do not pass region. Do not
3469 initialize SESE_OLDIVS.
3470 (build_graphite_loop_normal_form): Update call to
3471 graphite_loop_normal_form.
3472 * sese.c (debug_oldivs): Removed.
3473 (new_sese): Do not initialize SESE_OLDIVS.
3474 (free_sese): Do not free SESE_OLDIVS.
3475 (oldiv_for_loop): Removed.
3476 * sese.h (struct sese): Remove old_ivs.
3477 (SESE_OLDIVS): Removed.
3478 (oldiv_for_loop): Removed.
3480 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
3482 * graphite-clast-to-gimple.c (clast_name_to_gcc): Pass newivs,
3483 remove ivstack. Remove call to loop_iv_stack_get_iv_from_name,
3484 replaced by a call to newivs_to_depth_to_newiv.
3485 (clast_to_gcc_expression): Pass newivs, remove ivstack.
3486 (clast_to_gcc_expression_red): Same.
3487 (gcc_type_for_clast_expr): Same.
3488 (gcc_type_for_clast_eq): Same.
3489 (graphite_translate_clast_equation): Same.
3490 (graphite_create_guard_cond_expr): Same.
3491 (graphite_create_new_guard): Same.
3492 (graphite_create_new_loop): Same.
3493 (build_iv_mapping): Same.
3494 (translate_clast): Same.
3496 (loop_iv_stack_patch_for_consts): Removed. *
3497 sese.c (iv_stack_entry_is_constant): Removed.
3498 (iv_stack_entry_is_iv): Removed.
3499 (loop_iv_stack_push_iv): Removed.
3500 (loop_iv_stack_insert_constant): Removed.
3501 (loop_iv_stack_pop): Removed.
3502 (loop_iv_stack_get_iv): Removed.
3503 (loop_iv_stack_get_iv_from_name): Removed.
3504 (debug_loop_iv_stack): Removed.
3505 (free_loop_iv_stack): Removed.
3506 (loop_iv_stack_remove_constants): Removed. *
3507 sese.h (iv_stack_entry_kind): Removed.
3508 (iv_stack_entry_data_union): Removed.
3509 (iv_stack_entry_struct): Removed.
3510 (iv_stack_entry_p): Removed.
3511 (debug_oldivs, debug_loop_iv_stack, loop_iv_stack_insert_constant,
3512 loop_iv_stack_get_iv_from_name, loop_iv_stack_push_iv,
3513 loop_iv_stack_get_iv, loop_iv_stack_remove_constants,
3514 loop_iv_stack_pop, free_loop_iv_stack): Removed.
3515 (gbb_loop_at_index): Fix indenting.
3516 (gbb_loop_index): Removed.
3518 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
3520 * graphite-clast-to-gimple.c (clast_name_to_gcc): Do not use strcmp.
3521 Call clast_name_to_index.
3523 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
3525 * graphite-clast-to-gimple.c (clast_name_to_gcc): Pass region,
3526 do not pass params. Get params from SESE_PARAMS.
3527 (clast_to_gcc_expression): Same.
3528 (clast_to_gcc_expression_red): Same.
3529 (gcc_type_for_clast_eq): Same.
3530 (graphite_translate_clast_equation): Same.
3531 (graphite_create_new_loop): Same.
3532 * sese.c (rename_variables_in_stmt): Fix comment.
3534 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
3536 * graphite-clast-to-gimple.c (graphite_create_new_loop): Pass
3538 Call save_clast_name_index.
3539 (translate_clast): Pass newivs_index.
3540 (gloog): Create and free newivs_index.
3542 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
3544 * graphite-clast-to-gimple.c (clast_name_index): New structure.
3545 (clast_name_index_p): New type.
3546 (debug_clast_name_index): New.
3547 (debug_clast_name_indexes_1): New.
3548 (debug_clast_name_indexes): New.
3549 (clast_name_index_elt_info): New.
3550 (eq_clast_name_indexes): New.
3551 (clast_name_to_index): New.
3552 (new_clast_name_index): New.
3553 (save_clast_name_index): New.
3554 (init_sese_params_index): New.
3555 (gloog): Call init_sese_params_index.
3556 * graphite-clast-to-gimple.h (debug_clast_name_indexes): Declared.
3557 * sese.c (new_sese): Initialize SESE_PARAMS_INDEX.
3558 (free_sese): Free SESE_PARAMS_INDEX.
3559 * sese.h (struct sese): Add params_index.
3560 (SESE_PARAMS_INDEX): New.
3562 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
3564 * graphite-clast-to-gimple.c (newivs_to_depth_to_newiv): New.
3565 (graphite_create_new_loop): Pass the newivs vector. Push the
3566 newly created IV to newivs.
3567 (translate_clast): Pass the newivs vector.
3568 (gloog): Create and destroy the newivs vector.
3570 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
3572 * graphite-clast-to-gimple.c (pbb_to_depth_to_oldiv): New.
3573 (graphite_loop_normal_form): Initialize loop->aux with the unique
3574 IV that has been created.
3576 2009-05-13 Tobias Grosser <grosser@fim.uni-passau.de>
3578 * tree-chrec.c (evolution_function_right_is_integer_cst): Allow
3579 scev with parameters in the base part. They where forbidden
3582 2009-05-11 Li Feng <nemokingdom@gmail.com>
3584 * gcc.dg/graphite/graphite.exp: Set different default
3585 compile options by file names.
3586 * gcc.dg/graphite/block{0-6}.c: Remove dg-option line.
3587 * gcc.dg/graphite/id-{1-9}.c: Ditto.
3588 * gcc.dg/graphite/scop-{0-20}.c: Ditto.
3589 * gcc.dg/graphite/scop-matmult.c: Ditto.
3591 2009-05-08 Li Feng <nemokingdom@gmail.com>
3593 * gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: New.
3594 * gcc.dg/graphite/graphite_autopar/force-parallel-1.c: New.
3595 * gcc.dg/graphite/graphite_autopar/force-parallel-2.c: New.
3596 * gcc.dg/graphite/graphite_autopar/force-parallel-3.c: New.
3598 2009-05-07 Tobias Grosser <grosser@fim.uni-passau.de>
3600 * graphite-scop-detection (build_scops_1): Fix little bug introduced
3603 2009-05-07 Tobias Grosser <grosser@fim.uni-passau.de>
3605 * graphite-scop-detection.c (graphite_can_represent_scev): Only
3606 allow integer constant strides.
3607 (graphite_can_represent_expr): Depend on outermost_loop.
3608 (stmt_simple_memref_p, graphite_cannot_represent_loop,
3609 harmful_stmt_in_bb, is_simple_operand, stmt_simple_for_scop_p,
3610 build_scops_1): Same.
3611 (scopdet_basic_block_info): Same and insert layered SCoP
3613 (try_generate_gimple_bb): Cleanup.
3614 (build_scops): Enable data references.
3616 * gcc.dg/graphite/id-5.c: New.
3617 * gcc.dg/graphite/id-9.c: New.
3618 * tree-chrec.c (evolution_function_right_is_integer_cst): New.
3619 * tree-chrec.h (evolution_function_right_is_integer_cst): New.
3621 2009-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
3623 * sese.c (expand_scalar_variables_ssa_name): Only build expressions,
3624 that we have not yet built for this SCoP.
3626 2009-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
3628 * sese.c (expand_scalar_variables_expr): Fix expand_scalar_variables
3629 for complex numbers.
3631 2009-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
3633 * graphite-ppl.c: Fix build if cloog is not available.
3635 2009-05-04 Li Feng <nemokingdom@gmail.com>
3637 * tree-parloops.c (loop_parallel_p): Remove construction of
3638 NITER and REDUCTION_LIST.
3639 (try_get_loop_niter): New.
3640 (try_create_reduction_list): New.
3641 (parallelize_loops): Bypass the failed checkings in autopar
3642 when can_be_parallel in loop structure is set to true.
3644 2009-05-01 Tobias Grosser <grosser@fim.uni-passau.de>
3646 * gcc.dg/graphite/id-6.c: Update testcase.
3647 * gcc.dg/graphite/scop-3.c: Dito.
3649 2009-05-01 Tobias Grosser <grosser@fim.uni-passau.de>
3651 * graphite-scop-detection.c (stmt_simple_for_scop_p):
3652 Enable EQ_EXPR and NE_EXPR again.
3654 2009-04-30 Tobias Grosser <grosser@fim.uni-passau.de>
3656 * graphite-scop-detection.c (graphite_can_represent_scev):
3657 Add check if scev is affine multivariate.
3658 (harmful_stmt_in_bb): Check if we can represent the conditions.
3659 (scopdet_basic_block_info (basic_block bb, VEC): Pass the loop to
3661 * gcc.dg/graphite/id-7.c: New.
3663 2009-04-30 Tobias Grosser <grosser@fim.uni-passau.de>
3665 * graphite-sese-to-poly.c (bb_contains_non_iv_scalar_phi_nodes):
3666 Check all bbs in region, not only the bbs that are represented in
3668 (build_poly_scop): Add newline.
3669 * gcc.dg/graphite/id-8.c: New.
3671 2009-04-30 Li Feng <nemokingdom@gmail.com>
3673 * cfgloop.c (alloc_loop): Initialize can_be_parallel to false
3674 when loop initialize.
3675 * cfgloop.h (struct loop): Introduce flag can_be_parallel.
3676 * common.opt: Declare flag_graphite_force_parallel.
3677 * graphite-clast-to-gimple.c (translate_clast): Mark the innermost
3679 * graphite-poly.c (apply_poly_transforms): Introduce
3680 flag_graphite_force_parallel.
3681 * tree-ssa-loop.c (gate_graphite_transforms): ditto.
3682 * toplev.c (process_options): ditto and replace a not correctly
3685 2009-04-30 Li Feng <nemokingdom@gmail.com>
3687 * graphite-clast-to-gimple.c (loop_iv_stack_patch_for_consts):
3688 Change the call of gbb_loop_at_index and/or gbb_loop_index due
3689 to the redefinition.
3690 (compute_cloog_iv_types_1): ditto.
3691 (build_iv_mapping): ditto.
3692 * graphite-sese-to-poly.c (new_gimple_bb): Remove GBB_LOOPS related
3694 (free_gimple_bb): Removed GBB_LOOPS related free part.
3695 (build_bb_loops): Removed.
3696 * sese.h (struct gimple_bb): Removed loops.
3697 (GBB_LOOPS): Removed.
3698 (gbb_loop_at_index): Instead of using GBB_LOOPS, we use sese instead.
3699 (gbb_loop_index): ditto.
3701 2009-04-24 Tobias Grosser <grosser@fim.uni-passau.de>
3703 * graphite-scop-detection.c (graphite_can_represent_scev): Do not
3704 allow non constant strides.
3705 * gcc.dg/graphite/scop-20.c: New.
3707 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
3709 * graphite-scop-detection.c (dot_all_scops): Fix system call
3710 return value warning.
3713 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
3715 * gcc.dg/graphite/id-6.c: Fix pattern.
3716 * gcc.dg/graphite/scop-3.c: Same.
3718 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
3720 * graphite-poly.c (map_into_dep_poly, map_dr_into_dep_poly,
3721 build_pairwise_constraint, dr_equality_constraints,
3722 build_pairwise_scheduling_equality,
3723 build_pairwise_scheduling_inequality, lexicographically_gt_p,
3724 build_lexicographically_gt_constraint, dependence_polyhedron,
3725 graphite_legal_transform_dr, graphite_legal_transform_bb,
3726 graphite_legal_transform): New.
3727 * graphite-poly.h (graphite_legal_transform): Declared.
3728 * graphite-sese-to-poly.c (build_poly_scop): Call to
3729 graphite_legal_transform is disabled for the moment.
3731 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
3733 * graphite-poly.h (pbb_nb_scattering_dims): New.
3734 (pbb_nb_scattering): Use it.
3736 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
3738 * graphite-ppl.c (ppl_insert_dimensions_pointset): Add
3739 Pointset_Powerset version of ppl_insert_dimensions.
3740 * graphite-ppl.h (ppl_insert_dimensions_pointset): Declared.
3742 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
3744 * graphite-ppl.c (ppl_insert_dimensions): Fix formatting.
3746 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
3748 * graphite-poly.h: Fix comment.
3750 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
3752 * graphite-sese-to-poly.c (build_poly_dr): Fix data ref multiplier.
3754 2009-04-24 Tobias Grosser <grosser@fim.uni-passau.de>
3756 * sese.c (expand_scalar_variables_stmt): Only iterate over the old
3759 2009-04-24 Tobias Grosser <grosser@fim.uni-passau.de>
3761 * graphite-sese-to-poly.c (var_used_in_not_loop_header_phi_node): New.
3762 (graphite_stmt_p): Represent bbs necessary to build the phi nodes of
3765 2009-04-20 Sebastian Pop <sebastian.pop@amd.com>
3767 * graphite-scop-detection.c (stmt_simple_for_scop_p): Do not
3768 handle EQ_EXPR and NE_EXPR.
3770 2009-04-17 Tobias Grosser <grosser@fim.uni-passau.de>
3772 * graphite-poly.h (poly_dr): Fix comment.
3774 2009-04-09 Sebastian Pop <sebastian.pop@amd.com>
3775 Tobias Grosser <grosser@fim.uni-passau.de>
3777 * graphite-poly.c (new_poly_bb): Do not initialize PBB_DOMAIN
3778 with a zero dimension polyhedron.
3779 (find_scop_parameters): Move the call to scop_set_nb_params here.
3780 (build_loop_iteration_domains): Store in loop->aux the iteration
3782 (build_scop_iteration_domain): Fix PBB_DOMAIN for bbs not surrounded
3783 by any loop in scop.
3784 (build_poly_scop): Do not call scop_set_nb_params.
3786 2009-04-09 Sebastian Pop <sebastian.pop@amd.com>
3787 Tobias Grosser <grosser@fim.uni-passau.de>
3789 * graphite-sese-to-poly.c (add_condition_to_pbb): Pass code to
3790 add_condition_to_domain not GT_EXPR.
3792 2009-04-09 Tobias Grosser <grosser@fim.uni-passau.de>
3794 * graphite-ppl.c (debug_ppl_powerset_matrix): New.
3795 * graphite-ppl.h (debug_ppl_powerset_matrix): New.
3796 * graphite-sese-to-poly.c (add_condition_to_pbb): Use
3797 upper_bound_assign to calculate unions.
3798 * gcc.dg/graphite/id-6.c: New.
3800 2009-04-09 Tobias Grosser <grosser@fim.uni-passau.de>
3802 * graphite-scop-detection.c (canonicalize_loop_closed_ssa): Do not
3803 handle abnormal edges.
3805 2009-04-09 Tobias Grosser <grosser@fim.uni-passau.de>
3807 * graphite-poly.c (new_poly_dr, free_poly_dr): New.
3808 (free_poly_bb): Also free poly_drs.
3809 * graphite-poly.h (new_poly_dr, free_poly_dr): New.
3810 (poly_dr): Polyhedron to Pointset_Powerset.
3811 (pdr_accessp_nb_subscripts): Same.
3812 * graphite-sese-to-poly.c (build_poly_dr): Same. And actually build
3815 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
3817 * graphite-clast-to-gimple.c (initialize_cloog_names): Change cloog
3818 names into more meaningful names.
3820 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
3822 * gfortran.dg/graphite/interchange-1.c: New.
3823 * gfortran.dg/graphite/interchange-2.c: New.
3825 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
3827 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not build
3829 * tree-parloops.c (rewrite_phi_with_iv): New.
3830 (rewrite_all_phi_nodes_with_iv): New.
3831 (canonicalize_loop_ivs): Call them.
3833 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
3835 * graphite-sese-to-poly.c (try_generate_gimple_bb): Use
3836 graphite_find_data_references_in_stmt.
3837 * tree-data-ref.c (graphite_find_data_references_in_stmt): New.
3838 * tree-data-ref.h (graphite_find_data_references_in_stmt): Declared.
3840 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
3842 * sese.c (add_loop_exit_phis): Don't fail on non SSA_NAME renames.
3844 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
3846 * graphite-sese-to-poly.c (build_scop_bbs_1): Use bb_in_sese_p
3847 instead of bb_in_region.
3848 (flag_bb_in_region): Same. Renamed flag_bb_in_sese.
3849 (build_sese_conditions): Use flag_bb_in_sese.
3850 * sese.c (register_bb_in_sese): Removed.
3851 (new_sese): Remove initialization of SESE_REGION_BBS.
3852 (free_sese): Do not free SESE_REGION_BBS.
3853 * sese.h (struct sese): Remove field region_basic_blocks.
3854 (SESE_REGION_BBS): Removed.
3855 (bb_in_sese_p): Implement in function of bb_in_region.
3857 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
3859 * graphite-scop-detection.c (limit_scops): Deal only with single exit
3862 2009-04-08 Tobias Grosser <grosser@fim.uni-passau.de>
3864 * graphite-scop-detection.c (stmt_simple_for_scop_p): Allow NE_EXPR
3866 * graphite-sese-to-poly.c (create_linear_expr_from_tree): New.
3867 (add_condition_to_domain): New.
3868 (add_condition_to_pbb): New.
3869 (add_conditions_to_domain): Cleanup and handle of NE_EXPR and EQ_EXPR.
3870 * gcc.dg/graphite/scop-3.c: Update number of detected SCoPs.
3872 2009-04-08 Tobias Grosser <grosser@fim.uni-passau.de>
3874 * graphite-clast-to-gimple.c (build_cloog_prog): ppl_Polyhedron ->
3875 ppl_Pointset_Powerset.
3876 * graphite-poly.c (new_poly_bb, free_poly_bb): Same.
3877 * graphite-poly.h (poly_bb): poly_bb.domain Same.
3878 (pbb_nb_loops): Same.
3879 * graphite-sese-to-poly.c (build_loop_iteration_domains,
3880 add_conditions_to_domain): Same.
3881 * graphite-ppl.c (new_Cloog_Domain_from_ppl_Pointset_Powerset): New.
3882 (ppl_print_polyhedron_matrix): ppl_Polyhedron_t ->
3883 ppl_const_Polyhedron_t.
3884 (ppl_print_powerset_matrix): New.
3885 * graphite-ppl.h (new_Cloog_Domain_from_ppl_Pointset_Powerset,
3886 ppl_print_powerset_matrix): New.
3887 (ppl_print_polyhedron_matrix): Updated.
3889 2009-04-07 Sebastian Pop <sebastian.pop@amd.com>
3891 * tree-scalar-evolution.c (analyze_scalar_evolution_1): Fix comment.
3893 2009-04-07 Sebastian Pop <sebastian.pop@amd.com>
3895 * graphite-poly.c (extend_scattering): Fix indenting. Free cstr.
3896 (print_iteration_domains, debug_iteration_domain,
3897 debug_iteration_domains): New.
3898 * graphite-poly.h (print_iteration_domains, debug_iteration_domain,
3899 debug_iteration_domains): Declared.
3900 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons): Fix
3903 2009-04-03 Tobias Grosser <grosser@fim.uni-passau.de>
3904 Sebastian Pop <sebastian.pop@amd.com>
3906 * graphite-poly.h (print_iteration_domain): New.
3907 * graphite-sese-to-poly.c (add_conditions_to_domain): Fixed bug.
3908 (build_sese_conditions_1, build_sese_conditions_after,
3909 build_sese_conditions_before): New.
3910 (build_sese_conditions): Rewritten.
3912 2009-04-03 Sebastian Pop <sebastian.pop@amd.com>
3913 Tobias Grosser <grosser@fim.uni-passau.de>
3915 Cleanup of code generation liveouts.
3916 * graphite-clast-to-gimple.c (translate_clast): Use a single
3917 rename_map instead of one per translated statement.
3918 Do not use SESE_LIVEOUT_RENAMES.
3919 (graphite_loop_normal_form): Do not use SESE_REDUCTION_LIST.
3920 (gloog): Do not use SESE_LIVEOUT_RENAMES.
3921 * graphite-scop-detection.c (harmful_stmt_in_bb): Return the close
3922 phi node of a reduction: when a loop contains a reduction used outside
3923 the loop, there should be a scalar close phi node on the exit block.
3924 * sese.c (new_sese): Do not initialize SESE_LIVEOUT,
3925 SESE_LIVEOUT_RENAMES, and SESE_REDUCTION_LIST.
3926 (free_sese): Do not free them.
3927 (sese_build_liveouts_use): Do not use them.
3928 (sese_build_liveouts_bb): Same.
3929 (sese_build_liveouts): Same.
3930 (sese_insert_phis_for_liveouts): Same.
3931 (sese_adjust_phis_for_liveouts): Same. Renamed sese_adjust_liveout_phis.
3932 (defined_in_loop_p): New.
3933 (alive_after_loop): New.
3934 (close_phi_not_yet_inserted_p): New.
3935 (struct alep, alep_p): New.
3936 (add_loop_exit_phis): Remove from the rename_map all the names defined
3937 in the code generated loop.
3938 (insert_loop_close_phis): Traverse the rename_map passed to it.
3939 Don't use SESE_LIVEOUT_RENAMES.
3940 (default_liveout_before_guard): Renamed default_before_guard.
3941 (insert_guard_phis): Do not use SESE_LIVEOUT_RENAMES.
3942 (graphite_copy_stmts_from_block): Do not directly call set_rename.
3943 (register_sese_liveout_renames): Removed.
3944 (copy_bb_and_scalar_dependences): Do not call it.
3945 * sese.h (struct sese): Removed fields: liveout, liveout_renames, and
3947 (SESE_LIVEOUT): Removed.
3948 (SESE_LIVEOUT_RENAMES): Removed.
3949 (SESE_REDUCTION_LIST): Removed.
3950 (sese_build_liveouts): Removed.
3951 (sese_adjust_phis_for_liveouts): Renamed sese_adjust_liveout_phis.
3952 (insert_loop_close_phis): Pass a htab_t instead of a sese.
3953 (insert_guard_phis): Same.
3954 (rename_map_elt): Declare a VEC of them.
3955 * tree-parloops.c (canonicalize_loop_ivs): reduction_list contains
3956 trees not pointers to trees.
3958 Rewrite in canonical close SSA form:
3959 * graphite-scop-detection.c (contains_only_close_phi_nodes): New.
3960 (limit_scops): Close the scop after the block containing the close phi
3962 (canonicalize_loop_closed_ssa): New.
3963 (canonicalize_loop_closed_ssa_form): New.
3964 (build_scops): Call canonicalize_loop_closed_ssa_form.
3966 * graphite-sese-to-poly.c: Fix typos.
3968 2009-04-03 Sebastian Pop <sebastian.pop@amd.com>
3970 * graphite-poly.c (print_scattering_function, print_pbb_domain):
3972 (dump_gbb_conditions, dump_gbb_cases, print_iteration_domain): New.
3973 (print_pbb): Add conditions.
3975 2009-04-01 Tobias Grosser <grosser@fim.uni-passau.de>
3976 Sebastian Pop <sebastian.pop@amd.com>
3978 * graphite-scop-detection.c (bb_in_sd_region): Use bb_in_region.
3979 * graphite-sese-to-poly.c (all_non_dominated_preds_marked_p): New.
3980 (build_scop_bbs_1): New.
3981 (build_scop_bbs): Rewrite.
3982 * sese.h (bb_in_region): New.
3984 2009-03-29 Tobias Grosser <grosser@fim.uni-passau.de>
3986 * graphite-poly.c (new_poly_bb, free_poly_bb): Initialize/free
3988 (print_scop): Style.
3989 * graphite-poly.h (poly_bb): Add drs vector.
3990 (PBB_DRS): Add accessor.
3991 * graphite-sese-to-poly.c (build_poly_dr): New.
3992 (build_pbb_drs, build_scop_drs): New.
3993 (build_poly_scop): call build_scop_drs (Disabled at the moment).
3995 2009-03-29 Tobias Grosser <grosser@fim.uni-passau.de>
3997 * tree-ssa-loop.c: Include forgotten toplev.h
3999 2009-03-29 Tobias Grosser <grosser@fim.uni-passau.de>
4001 * graphite-poly.c: (apply_poly_transforms): sorry -> gcc_unreachable.
4002 * gcc.dg/graphite/pr37883.c: Remove -floop-*
4003 * gcc.dg/graphite/pr37928.c: Same
4004 * gcc.dg/graphite/pr38409.c: Same
4005 * gcc.dg/graphite/pr38498.c: Same
4006 * gcc.dg/graphite/pr38559.c: Same
4007 * gcc.dg/graphite/pr39335.c: Same
4008 * gcc.dg/graphite/pr39335_1.c: Same
4009 * gfortran.dg/graphite/block-2.f: Same
4010 * tree-ssa-loop.c (gate_graphite_transforms): Always fail if called
4013 2009-03-28 Tobias Grosser <grosser@fim.uni-passau.de>
4015 * graphite-sese-to-poly.c (ref_nb_loops, build_access_matrix_with_af,
4016 build_access_matrix, build_scop_data_accesses): Remove access function
4017 building. (We get a new version soon).
4018 (build_bb_loops, scan_tree_for_params_right_scev): Update.
4019 * sese.h (nb_loops_around_loop_in_sese): Remove.
4020 (sese_loop_depth): Do not use SESE_LOOP_NEST any more.
4022 2009-03-27 Tobias Grosser <grosser@fim.uni-passau.de>
4023 Sebastian Pop <sebastian.pop@amd.com>
4025 * graphite-scop-detection.c (struct scopdet_info): Rename last
4027 (scopdet_basic_block_info, build_scops_1): Don't use
4028 CDI_POST_DOMINATORS. CDI_POST_DOMINATORS should never be used.
4030 2009-03-26 Tobias Grosser <grosser@fim.uni-passau.de>
4031 Sebastian Pop <sebastian.pop@amd.com>
4033 * graphite-clast-to-gimple.c (gloog): Call sese_build_liveouts.
4034 * sese.c (sese_build_liveouts_use): Renamed from
4035 sese_build_livein_liveouts_use. Remove liveins.
4036 (sese_build_liveouts_bb): Renamed from sese_build_livein_liveouts_bb.
4037 Call sese_build_liveouts_use.
4038 (sese_build_liveouts): Renamed from sese_build_livein_liveouts.
4039 Call sese_build_liveouts_bb.
4040 (new_sese, free_sese): Remove liveins.
4041 (sese_add_exit_phis_var): Deleted.
4042 (sese_insert_phis_for_liveouts): Call sese_add_exit_phis_edge
4044 (graphite_copy_stmts_from_block): Remove SESE_NUM_VER.
4046 * sese.h (sese): Remove num_ver and livein.
4047 (SESE_LIVEIN, SESE_LIVEIN_VER, SESE_NUM_VER): Removed.
4049 2009-03-25 Tobias Grosser <grosser@fim.uni-passau.de>
4051 * graphite-sese-to-poly.c (build_scop_scattering): Fix compile.
4053 2009-03-25 Tobias Grosser <grosser@fim.uni-passau.de>
4055 * graphite-sese-to-poly.c (compare_prefix_loops): Removed.
4056 (build_scop_scattering): Do not use compare_prefix_loops any more.
4057 (nb_common_loops): New.
4059 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
4061 * sese.c (get_new_name_from_old_name): Renamed get_rename.
4062 (register_old_and_new_names): Renamed set_rename.
4064 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
4066 * graphite-scop-detection.h (nb_reductions_in_loop): Revert removal
4067 of the decl from the previous commit.
4069 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
4071 * graphite-scop-detection.c (dot_scop): New.
4072 * graphite-scop-detection.h (dot_scop): Declared.
4074 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
4076 * graphite-sese-to-poly.c (compare_prefix_loops): Fix compare.
4078 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
4080 * cfgloopmanip.c (create_empty_loop_on_edge): Generate the loop exit
4081 condition at the end of the loop.
4082 * graphite.c (graphite_initialize, graphite_finalize): Print to
4083 dump_file the compiled function.
4084 * graphite-clast-to-gimple.c (graphite_create_new_loop): Update use
4085 of create_empty_loop_on_edge.
4086 (translate_clast): Update the code generation of loops for the new
4088 * cfgloop.h (create_empty_loop_on_edge): Update declaration.
4090 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
4092 Reverted the patch from 2009-03-19.
4094 2009-03-19 Tobias Grosser <grosser@fim.uni-passau.de>
4096 * graphite-poly.c (new_poly_bb, free_poly_bb): Initialize/free
4098 (print_scop): Style.
4099 * graphite-poly.h (poly_bb): Add drs vector.
4100 (PBB_DRS): Add accessor.
4101 * graphite-sese-to-poly.c (ref_nb_loops): Remove.
4102 (build_access_matrix_with_af, build_access_matrix,
4103 build_scop_data_accesses): Delete.
4104 (build_poly_dr): New.
4105 (build_pbb_drs, build_scop_drs): New.
4106 (build_poly_scop): call build_scop_drs.
4108 2009-03-13 Sebastian Pop <sebastian.pop@amd.com>
4110 * graphite-scop-detection.c (dot_all_scops_1): Close the table
4111 once per basic block.
4113 2009-03-13 Tobias Grosser <grosser@fim.uni-passau.de>
4115 * graphite-scop-detection.c (graphite_can_represent_scev): New.
4116 (graphite_can_represent_expr): Renamed from loop_affine_expr
4118 (stmt_simple_for_scop_p): Call graphite_can_represent_expr.
4119 (graphite_cannot_represent_loop): Add scop_entry to parameters.
4120 (scopdet_basic_block_info): Actually define entry_block.
4121 (stmt_simple_memref_p): Moved here from ...
4123 * tree-data-ref.c (stmt_simple_memref_p): here.
4124 * tree-data-ref.h (stmt_simple_memref_p): Removed.
4126 2009-03-13 Tobias Grosser <grosser@fim.uni-passau.de>
4128 * gcc.dg/graphite/id-4.c: New.
4130 2009-03-12 Sebastian Pop <sebastian.pop@amd.com>
4132 * sese.c (expand_scalar_variables_expr): Handle tcc_comparison.
4133 (register_old_and_new_names): Update the content of the map.
4134 When there was already a rename_map_elt in the map at that
4136 (copy_bb_and_scalar_dependences): Do rename_variables after
4137 expand_scalar_variables.
4138 * graphite-clast-to-gimple.c (build_iv_mapping): Update the content
4139 of the map. When there was already a rename_map_elt in the
4140 map at that location, free it.
4141 (translate_clast): Pass the rename_map. Do not initialize and free
4142 a rename_map per stmt_user.
4143 (gloog): Initialize and free one rename_map and pass it to
4146 2009-03-12 Sebastian Pop <sebastian.pop@amd.com>
4148 * sese.c (expand_scalar_variables_stmt,
4149 expand_scalar_variables_ssa_name): Add a gimple_stmt_iterator
4151 (expand_scalar_variables_expr): Handle REALPART_EXPR and IMAGPART_EXPR.
4152 (expand_scalar_variables): Pass to expand_scalar_variables_stmt
4153 the gimple_stmt_iterator of the statement to be expanded.
4154 * graphite-scop-detection.c (is_simple_operand): Do handle
4157 2009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
4159 * graphite-scop-detection.c (is_simple_operand): Do not handle
4161 * gcc.dg/graphite/id-2.c: New.
4163 * graphite-sese-to-poly.c (build_bb_loops,
4164 add_value_to_dim, scan_tree_for_params_right_scev,
4165 scan_tree_for_params_int, scan_tree_for_params, idx_record_params,
4166 find_params_in_bb, build_loop_iteration_domains,
4167 add_conditions_to_domain): Remove subtract.
4169 2009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
4171 * graphite-clast-to-gimple.c (loop_iv_stack_patch_for_consts,
4172 build_iv_mapping, compute_cloog_iv_types_1, build_cloog_prog):
4173 pbb_loop_at_index -> gbb_loop_at_index.
4174 * graphite-poly.c (new_poly_bb, new_scop): New accessors.
4175 (debug_loop_vec): Delete.
4176 * graphite-poly.h (poly_bb, scop): Change black_box and region to void
4177 pointer. Move LOOPS to gimple_bb_p and insert nb_params.
4178 (PBB_LOOPS): Removed.
4179 (PBB_BLACK_BOX): Insert cast.
4180 (pbb_set_black_box): New setter.
4181 (pbb_loop_at_index, pbb_loop_index): Removed.
4182 (scop_set_region, scop_set_nb_params): New.
4183 * graphite-sese-to-poly.c (new_gimple_bb, free_gimple_bb,
4184 build_scop_scattering, build_bb_loops): Add GBB_LOOPS.
4185 (build_poly_scop): Use scop_set_nb_params.
4186 * sese.h (gimple_bb): Add LOOPS.
4187 (GBB_LOOPS, gbb_loop_index, gbb_loop_at_index): New.
4189 2009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
4191 Revert previous commit.
4193 2009-03-11 Sebastian Pop <sebastian.pop@amd.com>
4195 * sese.c (expand_scalar_variables_expr): Handle tcc_comparison.
4196 (register_old_and_new_names): Update the content of the map.
4197 When there was already a rename_map_elt in the map at that
4199 (copy_bb_and_scalar_dependences): Do rename_variables after
4200 expand_scalar_variables.
4201 * graphite-clast-to-gimple.c (build_iv_mapping): Update the content
4202 of the map. When there was already a rename_map_elt in the
4203 map at that location, free it.
4204 (translate_clast): Pass the rename_map. Do not initialize and free
4205 a rename_map per stmt_user.
4206 (gloog): Initialize and free one rename_map and pass it to
4209 2009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
4211 Remove forgotten line in revert.
4213 2009-03-11 Sebastian Pop <sebastian.pop@amd.com>
4215 Revert previous commit.
4217 2009-03-10 Sebastian Pop <sebastian.pop@amd.com>
4219 * sese.c (register_old_and_new_names): Update the content
4220 of the map. When there was already a rename_map_elt in the
4221 map at that location, free it.
4222 (copy_bb_and_scalar_dependences): Do rename_variables after
4223 expand_scalar_variables.
4224 * graphite-clast-to-gimple.c (build_iv_mapping): Update the content
4225 of the map. When there was already a rename_map_elt in the
4226 map at that location, free it.
4227 (translate_clast): Pass the rename_map. Do not initialize and free
4228 a rename_map per stmt_user.
4229 (gloog): Initialize and free one rename_map and pass it to
4232 2009-03-10 Sebastian Pop <sebastian.pop@amd.com>
4234 * graphite-clast-to-gimple.c (translate_clast): context_loop
4237 2009-03-10 Tobias Grosser <grosser@fim.uni-passau.de>
4238 Sebastian Pop <sebastian.pop@amd.com>
4240 * graphite-ppl.c (ppl_insert_dimensions): Fix stupid mistake
4241 of the use of ppl_Polyhedron_map_space_dimensions.
4243 2009-03-10 Tobias Grosser <grosser@fim.uni-passau.de>
4244 Sebastian Pop <sebastian.pop@amd.com>
4246 * graphite-poly.c (unify_scattering_dimensions): Fix types.
4247 * graphite-poly.h (poly_dr_p, poly_dr, POLY_DR_TYPE, PDR_BB,
4248 PDR_TYPE, PDR_ACCESSES, pdr_accessp_nb_subscripts,
4249 pdr_accessp_nb_iterators, pdr_accessp_nb_params,
4250 pdr_accessp_alias_set_dim, pdr_accessp_subscript_dim,
4251 pdr_accessp_iterator_dim, pdr_accessp_param_dim,
4252 pbb_nb_params): New.
4253 (pbb_nb_loops, pbb_nb_scattering, scop_nb_params,
4254 nb_loops_around_pbb): Adapt return types.
4256 2009-03-09 Tobias Grosser <grosser@fim.uni-passau.de>
4258 * Makefile.in (graphite.o, graphite-sese-to-poly.o,
4259 graphite-clast-to-gimple.o, graphite-data-ref.o,
4260 graphite-scop-detection.o, graphite-poly.o): Add
4263 2009-03-05 Tobias Grosser <grosser@fim.uni-passau.de>
4265 * Makefile.in (graphite.o, graphite-sese-to-poly.o,
4266 graphite-clast-to-gimple.o, graphite-data-ref.o,
4267 graphite-scop-detection.o, graphite-poly.o): Add graphite-poly.h.
4269 2009-03-04 Tobias Grosser <grosser@fim.uni-passau.de>
4271 * gcc.dg/graphite/pr37485.c: Remove -floop-block
4272 * gcc.dg/graphite/pr37828.c: Same.
4273 * gcc.dg/graphite/pr37684.c: Same.
4274 * gcc.dg/graphite/block-0.c: Same.
4275 * gcc.dg/graphite/block-1.c: Same.
4276 * gcc.dg/graphite/block-2.c: Same.
4277 * gcc.dg/graphite/block-3.c: Same.
4278 * gcc.dg/graphite/block-4.c: Same.
4279 * gcc.dg/graphite/block-5.c: Same.
4280 * gcc.dg/graphite/block-6.c: Same.
4281 * gfortran.dg/graphite/pr38083.f90: Same.
4282 * gfortran.dg/graphite/block-1.f90: Same.
4283 * gfortran.dg/graphite/block-3.f90: Same.
4284 * gfortran.dg/graphite/pr37852.f90: Same.
4285 * gfortran.dg/graphite/block-4.f90: Same.
4286 * gfortran.dg/graphite/pr37980.f90: Same.
4287 * gfortran.dg/graphite/pr38953.f90: Same.
4288 * gfortran.dg/graphite/pr37857.f90: Same.
4289 * opts.c: Remove -floop-block from -O2.
4290 * graphite-poly.c: Fail if -floop-block -floop-interchange or
4291 -floop-strip-mine are used.
4293 2009-03-04 Tobias Grosser <grosser@fim.uni-passau.de>
4294 Sebastian Pop <sebastian.pop@amd.com>
4296 * graphite-clast-to-gimple.c (build_cloog_prog): Unify scattering
4298 * graphite-poly.c (pbb_compare, graphite_sort_pbbs,
4299 graphite_trans_bb_move_loop, graphite_trans_bb_strip_mine,
4300 strip_mine_profitable_p, is_interchange_valid,
4301 graphite_trans_bb_block, graphite_trans_loop_block,
4302 graphite_trans_scop_block): Temporary removed.
4303 (extend_scattering, unify_scattering_dimensions): New.
4304 (print_scattering_function, graphite_read_transforms):
4305 PBB_SCATTERING -> PBB_TRANSFORMED_SCATTERING.
4306 (graphite_generate_scattering_fns): Removed.
4307 (apply_poly_transforms): Cleanup.
4308 (free_poly_bb): Add PBB_SCATTERING -> PBB_TRANSFORMED_SCATTERING.
4309 (schedule_to_scattering): Moved.
4310 (PBB_STATIC_SCHEDULE, PBB_SCATTERING): Removed.
4311 (PBB_ORIGINAL_SCATTERING, PBB_TRANSFORMED_SCATTERING): New.
4312 (pbb_nb_scattering): New.
4313 (SCOP_ENTRY, SCOP_EXIT, SCOP_REGION_BBS, SCOP_DEP_GRAPH, SCOP_PARAMS,
4314 SCOP_LOOP_NEST, SCOP_PARAMS, SCOP_OLDIVS, SCOP_LIVEOUT_RENAMES):
4316 * graphite-ppl.c (ppl_insert_dimensions): Extended and renamed from
4318 (ppl_strip_loop): PBB_SCATTERING -> PBB_TRANSFORMED_SCATTERING.
4319 * graphite-scop-detection.c (dot_all_scops_1): PBB_SCATTERING
4320 -> PBB_TRANSFORMED_SCATTERING.
4321 * graphite-sese-to-poly.c (build_scop_bbs): Remove region.
4322 (build_pbb_scattering_polyhedron): Moved from schedule_to_scattering.
4323 (build_scop_scattering): Renamed from build_scop_canonical_schedules.
4324 (check_poly_representation): Do not return bool.
4325 (graphite_transform_loops): Reformat.
4326 * sese.h (SESE_ENTRY_BB, SESE_EXIT_BB): New.
4328 2009-03-04 Sebastian Pop <sebastian.pop@amd.com>
4330 * graphite-poly.c (print_pbb_domain, print_pbb, print_scop,
4331 debug_pbb_domain, debug_pbb, debug_scop): New.
4332 * graphite-poly.h (print_pbb_domain, print_pbb, print_scop,
4333 debug_pbb_domain, debug_pbb, debug_scop): Declared.
4335 2009-03-02 Sebastian Pop <sebastian.pop@amd.com>
4338 * tree-parloops.c (canonicalize_loop_ivs): Call fold_convert
4339 when the type precision of the induction variable should be
4340 larger than the type precision of nit.
4341 (gen_parallel_loop): Update use of canonicalize_loop_ivs.
4342 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Same.
4343 * tree-flow.h (canonicalize_loop_ivs): Update declaration.
4345 * gcc.dg/graphite/pr39335_1.c: New.
4346 * gcc.dg/graphite/pr39335.c: New.
4348 2009-03-02 Sebastian Pop <sebastian.pop@amd.com>
4350 * tree-parloops.c (canonicalize_loop_ivs): reduction_list contains
4351 SSA_NAMES not struct reduction_info.
4353 2009-03-02 Sebastian Pop <sebastian.pop@amd.com>
4355 * sese.c (expand_scalar_variables_expr): Handle ADDR_EXPR.
4357 2009-02-27 Sebastian Pop <sebastian.pop@amd.com>
4358 Tobias Grosser <grosser@fim.uni-passau.de>
4360 * sese.c (new_sese): Initialize SESE_REDUCTION_LIST.
4361 (free_sese): Free SESE_REDUCTION_LIST.
4362 * sese.h (struct sese): Add field reduction_list.
4363 (SESE_REDUCTION_LIST): New.
4364 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Call
4365 canonicalize_loop_ivs on SESE_REDUCTION_LIST.
4367 2009-02-27 Sebastian Pop <sebastian.pop@amd.com>
4368 Tobias Grosser <grosser@fim.uni-passau.de>
4370 * tree-flow.h (gather_scalar_reductions): Use struct loop * instead
4373 2009-02-27 Sebastian Pop <sebastian.pop@amd.com>
4374 Tobias Grosser <grosser@fim.uni-passau.de>
4376 * tree-parloops.c (struct brli, build_reduction_list_info,
4377 analyze_reduction_list, gather_scalar_reductions): New.
4378 (loop_parallel_p): Build a reduction list containing only
4379 PHI_RESULT SSA_NAMEs: call gather_scalar_reductions.
4380 (gen_parallel_loop): Call the analysis analyze_reduction_list.
4381 (parallelize_loops): Now reduction_list is a htab_t of SSA_NAMEs.
4382 * tree-flow.h (gather_scalar_reductions): Declared.
4384 2009-02-26 Sebastian Pop <sebastian.pop@amd.com>
4387 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not call
4388 number_of_iterations_exit from a gcc_assert.
4390 2009-02-25 Sebastian Pop <sebastian.pop@amd.com>
4391 Jan Sjodin <jan.sjodin@amd.com>
4393 * output.h (graphite_out_file, graphite_in_file): Declared.
4394 * toplev.c (graphite_out_file, graphite_in_file): New.
4395 (init_asm_output): Initialize graphite_in_file and graphite_out_file.
4396 * graphite-clast-to-gimple.c (build_cloog_prog): Read PBB_SCATTERING.
4397 Don't call schedule_to_scattering.
4398 * common.opt (fgraphite-write, fgraphite-read): New.
4399 * graphite-poly.c: Include output.h.
4400 (print_scattering_function, print_scattering_functions,
4401 debug_scattering_function, debug_scattering_functions,
4402 graphite_write_transforms, graphite_read_transforms,
4403 graphite_generate_scattering_fns): New.
4404 (apply_poly_transforms): Do not apply transform if flag_graphite_read.
4405 Call graphite_generate_scattering_fns, graphite_write_transforms,
4406 graphite_read_transforms.
4407 (new_poly_bb): Initialize PBB_SCATTERING.
4408 (free_poly_bb): Free PBB_SCATTERING.
4409 (schedule_to_scattering): Does not return, initialize PBB_SCATTERING.
4410 * graphite-poly.h (struct poly_bb): Add field scattering.
4411 (PBB_SCATTERING): New.
4412 (print_scattering_function, print_scattering_functions,
4413 debug_scattering_function, debug_scattering_functions): Declared.
4414 * graphite-ppl.c (cloog_matrix_to_ppl_constraint): Matrices contain
4415 GMP values, not integers!
4416 (ppl_print_polyhedron_matrix, debug_ppl_polyhedron_matrix,
4417 ppl_read_polyhedron_matrix): New.
4418 * graphite-ppl.h (ppl_print_polyhedron_matrix,
4419 debug_ppl_polyhedron_matrix,
4420 ppl_read_polyhedron_matrix): Declared.
4421 * Makefile.in (graphite-poly.o): Depends on output.h.
4423 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
4424 Tobias Grosser <grosser@fim.uni-passau.de>
4427 * graphite-scop-detection.c (stmt_simple_for_scop_p): Analyze
4428 scalar evolutions in the scop_entry->loop_father.
4430 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
4431 Tobias Grosser <grosser@fim.uni-passau.de>
4433 * graphite.h (ref_nb_loops): Remove declaration.
4434 (struct gimple_bb, gimple_bb_p, GBB_BB, GBB_DATA_REFS, GBB_CONDITIONS,
4435 GBB_CONDITION_CASES, GBB_CLOOG_IV_TYPES, gbb_loop, print_gimple_bb,
4436 debug_gbb): Moved to sese.h.
4439 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
4440 Tobias Grosser <grosser@fim.uni-passau.de>
4442 * graphite-data-ref.[ch]: Disable.
4444 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
4445 Tobias Grosser <grosser@fim.uni-passau.de>
4447 * graphite-scop-detection.c (stmt_simple_for_scop_p): Analyze
4448 scalar evolutions in the scop_entry->loop_father.
4450 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
4452 * graphite-scop-detection.c (nb_reductions_in_loop): Moved here...
4453 (graphite_cannot_represent_loop_niter): Renamed
4454 graphite_cannot_represent_loop. Call nb_reductions_in_loop.
4455 (limit_scops): build_sese_loop_nests does not return a bool.
4456 * graphite-scop-detection.h (nb_reductions_in_loop): Declared.
4457 * sese.c (nb_reductions_in_loop): ... from here.
4458 (graphite_loop_normal_form): ... from here.
4459 (sese_record_loop): Does not fail, so does not return a bool.
4460 (build_sese_loop_nests): Same.
4461 * sese.h (build_sese_loop_nests): Update declaration.
4462 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Moved here...
4463 (build_graphite_loop_normal_form): New.
4464 (gloog): Call build_graphite_loop_normal_form.
4465 * graphite-sese-to-poly.c (build_poly_scop): Don't fail on
4466 build_sese_loop_nests.
4468 * gcc.dg/graphite/id-1.c: New.
4470 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
4471 Tobias Grosser <grosser@fim.uni-passau.de>
4473 * graphite-sese-to-poly.c (scan_tree_for_params): Remove REAL_CST.
4474 The SCoP detection fix is sufficient.
4476 2009-02-21 Sebastian Pop <sebastian.pop@amd.com>
4478 PR tree-optimization/39260
4479 * graphite-scop-detection.c (harmful_stmt_in_bb): Stop a SCoP when
4480 the basic block contains a condition with a real type.
4481 * graphite-sese-to-poly.c (scan_tree_for_params): Handle REAL_CST.
4483 * gcc.dg/graphite/pr39260.c: New.
4485 2009-02-21 Sebastian Pop <sebastian.pop@amd.com>
4487 * graphite-poly.c: Inlcude params.h.
4488 (graphite_trans_loop_block): Use PARAM_LOOP_BLOCK_TILE_SIZE for
4490 * Makefile.in (graphite-poly.o): Depend on PARAMS_H.
4491 * params.def (PARAM_LOOP_BLOCK_TILE_SIZE): Define.
4493 2009-02-20 Sebastian Pop <sebastian.pop@amd.com>
4494 Tobias Grosser <grosser@fim.uni-passau.de>
4496 * graphite-scop-detection.c (dot_all_scops_1,
4497 dot_all_scops): Moved here.
4498 * graphite-scop-detection.h (dot_all_scops): Declared here.
4499 * graphite.c (graphite_initialize, graphite_finalize): New.
4500 (graphite_transform_loops): Cleaned up.
4501 * sese.c (debug_oldivs): Moved here.
4502 * graphite-poly.c (graphite_apply_transformations): Renamed
4503 apply_poly_transforms.
4504 (debug_loop_vec): Moved here.
4505 * graphite-sese-to-poly.c (build_bb_loops, build_sese_conditions_1,
4506 scop_contains_non_iv_scalar_phi_nodes, build_sese_conditions,
4507 find_scop_parameters, build_scop_iteration_domain,
4508 add_conditions_to_constraints, build_scop_canonical_schedules,
4509 build_scop_data_accesses): Now static.
4510 (build_poly_scop, check_poly_representation): New.
4512 2009-02-20 Sebastian Pop <sebastian.pop@amd.com>
4514 * graphite.c (graphite_stmt_p, new_gimple_bb, free_gimple_bb,
4515 remove_gbbs_in_scop, free_scops, try_generate_gimple_bb,
4516 build_scop_bbs, ref_nb_loops, compare_prefix_loops,
4517 build_scop_canonical_schedules, build_bb_loops, add_value_to_dim,
4518 scan_tree_for_params_right_scev, scan_tree_for_params_int,
4519 scan_tree_for_params, struct irp_data, dx_record_params,
4520 find_params_in_bb, find_scop_parameters, gbb_from_bb,
4521 build_loop_iteration_domains, add_conditions_to_domain,
4522 phi_node_is_iv, bb_contains_non_iv_scalar_phi_nodes,
4523 scop_contains_non_iv_scalar_phi_nodes, build_sese_conditions_1,
4524 build_sese_conditions, add_conditions_to_constraints,
4525 build_scop_iteration_domain, build_access_matrix_with_af,
4526 build_access_matrix,
4527 build_scop_data_accesses): Moved to graphite-sese-to-poly.c.
4529 * graphite-sese-to-poly.c: New.
4530 * graphite-sese-to-poly.h: New.
4532 * Makefile.in: Add new rule for graphite-sese-to-poly.o.
4534 2009-02-20 Sebastian Pop <sebastian.pop@amd.com>
4536 * graphite.c: Split graphite code generation to a new file.
4537 (graphite_verify, gmp_cst_to_tree, clast_name_to_gcc,
4538 max_precision_type, clast_to_gcc_expression_red,
4539 clast_to_gcc_expression, gcc_type_for_clast_expr,
4540 gcc_type_for_clast_eq, loop_iv_stack_patch_for_consts,
4541 graphite_translate_clast_equation, graphite_create_guard_cond_expr,
4542 graphite_create_new_guard, clast_get_body_of_loop,
4543 gcc_type_for_cloog_iv, gcc_type_for_iv_of_clast_loop,
4544 graphite_create_new_loop, build_iv_mapping, copy_renames,
4545 translate_clast, find_cloog_iv_in_expr, compute_cloog_iv_types_1,
4546 compute_cloog_iv_types, free_scattering, save_var_name,
4547 initialize_cloog_names, build_scop_context, build_cloog_prog,
4548 set_cloog_options, debug_clast_stmt, scop_to_clast,
4549 print_generated_program, debug_generated_program,
4550 gloog): Moved to graphite-clast-to-gimple.c.
4552 (struct cloog_prog_clast): Moved to graphite-clast-to-gimple.h.
4554 (iv_stack_entry_is_constant, iv_stack_entry_is_iv,
4555 loop_iv_stack_push_iv, loop_iv_stack_insert_constant,
4556 loop_iv_stack_pop, loop_iv_stack_get_iv,
4557 loop_iv_stack_get_iv_from_name, debug_loop_iv_stack,
4558 free_loop_iv_stack, loop_iv_stack_remove_constants,
4559 debug_rename_elt, debug_rename_map_1, debug_rename_map,
4560 rename_map_elt_info, eq_rename_map_elts, debug_ivtype_elt,
4561 debug_ivtype_map_1, debug_ivtype_map, ivtype_map_elt_info,
4562 eq_ivtype_map_elts, sese_add_exit_phis_edge,
4563 sese_add_exit_phis_var, sese_insert_phis_for_liveouts,
4564 get_vdef_before_sese, sese_adjust_vphi,
4565 get_new_name_from_old_name, sese_adjust_phis_for_liveouts,
4566 oldiv_for_loop, rename_variables_in_stmt, is_parameter,
4567 is_iv, expand_scalar_variables_ssa_name,
4568 expand_scalar_variables_expr, expand_scalar_variables_stmt,
4569 expand_scalar_variables, rename_variables, remove_condition,
4570 get_true_edge_from_guard_bb, get_false_edge_from_guard_bb,
4571 add_loop_exit_phis, insert_loop_close_phis, struct igp,
4572 default_liveout_before_guard, add_guard_exit_phis,
4573 insert_guard_phis, register_old_and_new_names,
4574 graphite_copy_stmts_from_block, register_sese_liveout_renames,
4575 copy_bb_and_scalar_dependences, outermost_loop_in_sese,
4576 if_region_set_false_region, create_if_region_on_edge,
4577 move_sese_in_condition): Moved to sese.c.
4579 (nb_loops_around_loop_in_sese, struct ifsese, if_region_entry,
4580 if_region_exit, if_region_get_condition_block,
4581 struct rename_map_elt, new_rename_map_elt, enum iv_stack_entry_kind,
4582 union iv_stack_entry_data_union, struct iv_stack_entry_struct,
4583 iv_stack_entry_p, loop_iv_stack, struct ivtype_map_elt,
4584 ivtype_map_elt, new_ivtype_map_elt,
4585 recompute_all_dominators): Moved to sese.h.
4587 * graphite-clast-to-gimple.c: New.
4588 * graphite-clast-to-gimple.h: New.
4589 * Makefile.in: Add new rule for graphite-clast-to-gimple.o.
4590 * sese.c: Modified as said above.
4593 2009-02-20 Sebastian Pop <sebastian.pop@amd.com>
4595 * graphite.c: Split scop detection to a new file.
4596 (enum gbb_type, gbb_type, get_bb_type, struct sd_region_p, sd_region,
4597 move_sd_regions, loop_affine_expr, exclude_component_ref,
4598 is_simple_operand, stmt_simple_for_scop_p, harmful_stmt_in_bb,
4599 graphite_cannot_represent_loop_niter, struct scopdet_info,
4600 scopdet_basic_block_info, build_scops_1, bb_in_sd_region,
4601 find_single_entry_edge, find_single_exit_edge,
4602 create_single_entry_edge, sd_region_without_exit,
4603 create_single_exit_edge, unmark_exit_edges, mark_exit_edges,
4604 create_sese_edges, build_graphite_scops, limit_scops, build_scops):
4605 Moved to graphite-scop-detection.c.
4607 * graphite-scop-detection.c: New.
4608 * graphite-scop-detection.h: New.
4609 * Makefile.in: Add new rule for graphite-scop-detection.o.
4611 * sese.c: Include tree-chrec.h, tree-data-ref.h, and
4612 tree-scalar-evolution.h.
4613 (nb_reductions_in_loop, graphite_loop_normal_form, sese_record_loop,
4614 build_sese_loop_nests): Moved here from graphite.c.
4615 (param_index): Renamed parameter_index_in_region.
4617 2009-02-18 Tobias Grosser <grosser@fim.uni-passau.de>
4618 Sebastian Pop <sebastian.pop@amd.com>
4620 * gcc.dg/graphite/block-0.c: Expected to fail now.
4621 * gcc.dg/graphite/block-1.c: Same.
4622 * gcc.dg/graphite/block-5.c: Same.
4623 * gcc.dg/graphite/block-6.c: Same.
4625 2009-02-18 Tobias Grosser <grosser@fim.uni-passau.de>
4626 Sebastian Pop <sebastian.pop@amd.com>
4628 * graphite.h: Separate from graphite_bb_p the polyhedral
4629 representation in poly_bb_p and the GCC specifics in gimple_bb_p.
4630 (struct data_dependence_polyhedron, RDGE_DDP, ddp_p): Moved to
4631 graphite-data-ref.h.
4632 (struct poly_bb, PBB_SCOP, PBB_STATIC_SCHEDULE, PBB_DOMAIN,
4633 PBB_BLACK_BOX, PBB_LOOPS, pbb_nb_loops, pbb_loop_at_index,
4634 pbb_loop_index, struct scop, SCOP_BBS, SCOP_REGION, SCOP_ENTRY,
4635 SCOP_EXIT, SCOP_REGION_BBS, SCOP_DEP_GRAPH, SCOP_PARAMS,
4636 SCOP_LOOP_NEST, SCOP_PARAMS, SCOP_OLDIVS, SCOP_LIVEOUT_RENAMES,
4637 scop_nb_params): Moved to graphite-poly.h.
4638 * graphite-data-ref.c: Same.
4639 * graphite-data-ref.h: New.
4641 (pbb_compare, graphite_sort_pbbs, graphite_trans_bb_move_loop,
4642 graphite_trans_bb_strip_mine, strip_mine_profitable_p,
4643 is_interchange_valid, graphite_trans_bb_block,
4644 graphite_trans_loop_block, scop_max_loop_depth,
4645 graphite_trans_scop_block, graphite_apply_transformations,
4646 new_poly_bb, free_poly_bb, new_scop, free_scop): Moved to
4648 * graphite-poly.h: New.
4649 * graphite-poly.c: New.
4650 * Makefile.in (OBJS-common): Add graphite-poly.o.
4651 (graphite-poly.o): New rule.
4652 * tree-data-ref.h (struct data_reference): Remove unused scop field.
4655 2009-02-18 Sebastian Pop <sebastian.pop@amd.com>
4656 Tobias Grosser <grosser@fim.uni-passau.de>
4658 * graphite.c: Replace gb -> gbb.
4660 * graphite-data-ref.c: Same.
4662 2009-02-18 Sebastian Pop <sebastian.pop@amd.com>
4663 Tobias Grosser <grosser@fim.uni-passau.de>
4665 * Makefile.in (OBJS-commmon): Add sese.o.
4667 (graphite.o): Add sese.h.
4668 * graphite.c (bb_in_ss_p, loop_in_sese_p,
4669 sese_build_livein_liveouts_use, sese_build_livein_liveouts_bb,
4670 sese_build_livein_liveouts, register_bb_in_sese, new_sese, free_sese):
4672 (block_before_scop): Add missing return.
4673 (new_scop, free_scop): Remove SESE data structures.
4674 (scop_record_loop, scan_tree_for_params, find_params_in_bb,
4675 find_scop_parameters, build_loop_iteration_domains,
4676 add_conditions_to_domain, register_scop_liveout_renames,
4677 copy_bb_and_scalar_dependences): Scop -> SESE.
4679 (add_conditions_to_domain): SCoP -> SESE and remove check
4680 (scop_contains_non_iv_scalar_phi_nodes): New.
4681 (build_scop_conditions_1, build_scop_conditions): Remove check for
4682 non iv scalar phi nodes.
4683 (print_scop_statistics): New.
4684 (graphite_transform_loops): Cleanup.
4686 * graphite.h: Move to sese & cleanup.
4690 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
4691 Tobias Grosser <grosser@fim.uni-passau.de>
4693 * graphite.c (build_scop_conditions_1): Conditions are only
4694 at the end of a basic block.
4696 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
4697 Tobias Grosser <grosser@fim.uni-passau>
4699 * graphite.h (struct graphite_bb): Remove compressed_alpha_matrix
4701 (GBB_ALPHA): Removed.
4703 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
4704 Tobias Grosser <grosser@fim.uni-passau.de>
4706 * graphite-data-ref.c (graphite_test_dependence): Don't use
4707 GBB_DYNAMIC_SCHEDULE.
4708 * graphite.c (new_graphite_bb): Same.
4709 (free_graphite_bb): Same.
4710 (build_scop_dynamic_schedules): Removed.
4711 (graphite_transform_loops): Don't call it.
4712 * graphite.h (struct graphite_bb): Remove dynamic_schedule field.
4713 (GBB_DYNAMIC_SCHEDULE): Removed.
4715 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
4716 Tobias Grosser <grosser@fim.uni-passau.de>
4718 * graphite.c (schedule_to_scattering): Don't use CloogMatrix.
4719 (print_graphite_bb): Same.
4720 (build_cloog_prog): Same.
4722 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
4723 Tobias Grosser <grosser@fim.uni-passau.de>
4725 * graphite.c (build_cloog_prog): Don't use CloogMatrix.
4727 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
4728 Tobias Grosser <grosser@fim.uni-passau.de>
4730 * graphite.c (build_scop_context): Don't use CloogMatrix.
4731 * graphite-ppl.c (new_Cloog_Domain_from_ppl_Polyhedron): New.
4732 * graphite-ppl.h (new_Cloog_Domain_from_ppl_Polyhedron): Declared.
4734 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
4735 Tobias Grosser <grosser@fim.uni-passau.de>
4737 * graphite.h (struct scop): Move params, old_ivs, loops, loop_nest,
4738 liveout_renames, add_params fields...
4739 (struct sese): ... here.
4740 (SESE_PARAMS, SESE_LOOPS, SESE_LOOP_NEST, SESE_ADD_PARAMS,
4741 SESE_PARAMS, SESE_OLDIVS, SESE_LIVEOUT_RENAMES): New.
4743 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
4744 Tobias Grosser <grosser@fim.uni-passau.de>
4746 * graphite.c (print_scop): Do not print the CLooG program.
4747 (new_scop, free_scop, initialize_cloog_names, build_scop_context,
4748 build_cloog_prog, gloog): Don't use SCOP_PROG.
4749 (find_transform): Renamed scop_to_clast.
4750 (print_generated_program, debug_generated_program): New.
4751 (graphite_transform_loops): Adapt to new interface.
4752 * graphite.h (struct scop): Remove program field.
4753 (SCOP_PROG): Removed.
4754 (print_generated_program, debug_generated_program): Declared.
4756 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
4758 * graphite-data-ref.c (schedule_precedes_p, schedule_same_p): New.
4759 (statement_precedes_p): Use schedule_same_p and schedule_precedes_p.
4760 * graphite.c (gbb_compare, schedule_to_scattering, print_graphite_bb,
4761 free_graphite_bb, build_scop_canonical_schedules,
4762 graphite_trans_bb_strip_mine, graphite_trans_scop_block): Static
4763 schedules are now represented using a ppl_Linear_Expression_t.
4764 * graphite.h (struct graphite_bb): Same.
4765 * graphite-ppl.c (ppl_lexico_compare_linear_expressions): New.
4766 * graphite-ppl.h (ppl_lexico_compare_linear_expressions): Declared.
4768 2009-02-15 Sebastian Pop <sebastian.pop@amd.com>
4770 * graphite.c: Free local memory.
4771 * graphite-ppl.c: Same.
4773 2009-02-15 Sebastian Pop <sebastian.pop@amd.com>
4775 * graphite.c (const_column_index, get_first_matching_sign_row_index,
4776 get_lower_bound_row, get_upper_bound_row, copy_constraint,
4777 swap_constraint_variables, scale_constraint_variable): Removed.
4778 (graphite_trans_bb_strip_mine): Remove pong.
4779 * graphite-ppl.c: Include missing header files.
4780 (set_inhomogeneous, set_coef, shift_poly, ppl_strip_loop): New.
4781 * graphite-ppl.h (ppl_strip_loop): Declared.
4782 * Makefile.in (graphite-ppl.o): Adjust dependences.
4784 2009-02-14 Sebastian Pop <sebastian.pop@amd.com>
4786 * graphite.c (build_loop_iteration_domains): Remove ping pong.
4787 (build_scop_iteration_domain): Same.
4789 2009-02-13 Sebastian Pop <sebastian.pop@amd.com>
4791 * graphite.c (scan_tree_for_params, add_conditions_to_domain): Remove
4793 (add_value_to_dim, scan_tree_for_params_right_scev,
4794 scan_tree_for_params_int): New.
4795 * graphite-ppl.c (oppose_constraint): New.
4796 (insert_constraint_into_matrix): Implement missing cases.
4797 * graphite-ppl.h (insert_constraint_into_matrix): Declared.
4799 2009-02-13 Sebastian Pop <sebastian.pop@amd.com>
4801 * graphite.c (graphite_trans_bb_move_loop): Remove ping pong,
4802 use ppl_move_dimension.
4804 2009-02-12 Sebastian Pop <sebastian.pop@amd.com>
4806 * graphite-data-ref.c: Domains are now ppl_Polyhedra_t.
4809 * graphite-ppl.c: Same.
4810 * graphite-ppl.h: Same.
4812 2009-02-12 Sebastian Pop <sebastian.pop@amd.com>
4814 Revert last 3 commits.
4816 2009-02-10 Sebastian Pop <sebastian.pop@amd.com>
4818 * graphite.c (scan_tree_for_params, add_conditions_to_domain): Remove
4820 (add_value_to_dim, scan_tree_for_params_right_scev,
4821 scan_tree_for_params_int): New.
4822 * graphite-ppl.c (oppose_constraint): New.
4823 (insert_constraint_into_matrix): Implement missing cases.
4824 * graphite-ppl.h (insert_constraint_into_matrix): Declared.
4826 2009-02-10 Sebastian Pop <sebastian.pop@amd.com>
4828 * graphite.c (graphite_trans_bb_move_loop): Remove unused variables.
4830 2009-02-10 Sebastian Pop <sebastian.pop@amd.com>
4831 Tobias Grosser <grosser@fim.uni-passau.de>
4833 * graphite.c (graphite_trans_bb_move_loop): Remove ping pong,
4834 use ppl_move_dimension.
4835 * graphite-ppl.c (ppl_move_dimension): New.
4836 * graphite-ppl.h (ppl_move_dimension): Declared.
4838 2009-02-10 Sebastian Pop <sebastian.pop@amd.com>
4840 * graphite.c: Do not include cloog/cloog.h.
4841 (print_graphite_bb): Remove ping pong, call PPL print function.
4843 2009-02-10 Tobias Grosser <grosser@fim.uni-passau.de>
4845 * Makefile.in (OBJS-common): Add graphite-ppl.o.
4846 (graphite.o): Add dependence on graphite-ppl.h.
4847 (graphite-ppl.o): New.
4848 (graphite-data-ref.c): Ping pong between PPL data structures
4850 * graphite-ppl.c: New.
4851 * graphite-ppl.h: New.
4852 * graphite.c: Include graphite-ppl.h.
4853 (print_graphite_bb, add_conditions_to_domain, build_cloog_prog,
4854 graphite_trans_bb_move_loop, graphite_trans_bb_strip_mine):
4855 Ping pong between PPL data structures and matrices.
4856 (new_graphite_bb): Create a PPL constraint system.
4857 Call ppl_delete_Constraint_System instead of cloog_matrix_free.
4858 (build_loop_iteration_domains): Use PPL functions.
4859 * graphite.h: Include graphite-ppl.h. Fix comments.
4860 (graphite_bb): Use a ppl_Constraint_System_t instead of
4861 CloogMatrix for representing the domain.
4862 (scop): Remove static_schedule.
4863 (gbb_nb_loops): Ping pong between PPL data structures and matrices.
4865 2009-02-06 Sebastian Pop <sebastian.pop@amd.com>
4867 * graphite.c: Fix some comments.
4869 2009-02-05 Sebastian Pop <sebastian.pop@amd.com>
4872 * graphite.c (if_region_set_false_region): After moving a region
4873 in the false branch of a condition, remove the empty dummy
4875 (gloog): Remove wrong fix for PR38953.
4877 2009-02-03 Tobias Grosser <grosser@fim.uni-passau.de>
4879 * graphite.c (bb_in_sese_p, sese_build_livein_liveouts_use,
4880 sese_build_livein_liveouts_bb, sese_build_livein_liveouts,
4881 register_bb_in_sese, new_sese, free_sese): Moved.
4882 (dot_scop_1, build_scop_loop_nests, build_loop_iteration_domains,
4883 outermost_loop_in_scop, build_scop_iteration_domain,
4884 expand_scalar_variables_ssa_name, get_vdef_before_scop,
4885 limit_scops): Use bb_in_sese_p instead of bb_in_scop_p.
4886 Use loop_in_sese_p instead of loop_in_scop_p.
4887 (new_graphite_bb, new_scop, gloog): Do not initialize SCOP_BBS_B.
4888 (free_scop): Do not free SCOP_BBS_B.
4889 (nb_loops_around_loop_in_scop, nb_loops_around_gb,
4890 ref_nb_loops): Moved here...
4891 * graphite.h (ref_nb_loops): ... from here.
4892 (struct scop): Remove bbs_b bitmap.
4893 (SCOP_BBS_B, bb_in_scop_p, loop_in_scop_p): Removed.
4894 * gcc.dg/graphite/scop-19.c: New
4896 2009-02-03 Tobias Grosser <grosser@fim.uni-passau.de>
4898 * graphite.c (scopdet_basic_block_info): Fix bug in scop
4901 2009-01-30 Tobias Grosser <grosser@fim.uni-passau.de>
4903 * graphite.c (new_loop_to_cloog_loop_str, hash_loop_to_cloog_loop,
4904 eq_loop_to_cloog_loop): Remove.
4905 (new_scop, free_scop): Remove SCOP_LOOP2CLOOG_LOOP.
4906 * graphite.h (struct scop): Remove loop2cloog_loop.
4907 (loop_domain_dim, loop_iteration_vector_dim): Remove.
4909 2009-01-30 Tobias Grosser <grosser@fim.uni-passau.de>
4911 * opts.c (decode_options): Only add graphite options to O2
4912 if we compile with graphite enabled.
4914 2009-01-26 Sebastian Pop <sebastian.pop@amd.com>
4916 * Merge from mainline (r143163:143684).
4918 2009-01-26 Sebastian Pop <sebastian.pop@amd.com>
4920 * graphite.c (debug_value): Removed.
4921 * graphite.h (debug_value): Removed.
4923 2009-01-23 Sebastian Pop <sebastian.pop@amd.com>
4925 * passes.c (init_optimization_passes): Do not call pass_copy_prop
4926 after graphite: pass_copy_prop does not maintain a proper loop closed
4927 SSA form. pass_copy_prop should be fixed.
4929 2009-01-23 Sebastian Pop <sebastian.pop@amd.com>
4931 * graphite.c (scop_adjust_phis_for_liveouts): Fix warning.
4933 2009-01-23 Sebastian Pop <sebastian.pop@amd.com>
4935 * graphite.c (graphite_verify): Add a call to verify_loop_closed_ssa.
4936 (gloog): Split the exit of the scop when the scop exit is a loop exit.
4937 (graphite_transform_loops): Only call cleanup_tree_cfg if gloog
4940 2009-01-20 Sebastian Pop <sebastian.pop@amd.com>
4942 * graphite.c (gloog): Return true when code gen succeeded.
4943 (graphite_transform_loops): Do not call cleanup_tree_cfg if
4944 the code of the function did not changed. After cleanup_tree_cfg
4945 call rewrite_into_loop_closed_ssa to maintain the loop closed ssa
4948 2009-01-19 Sebastian Pop <sebastian.pop@amd.com>
4950 * graphite.c (stmt_simple_for_scop_p): Also handle cases when
4951 gimple_call_lhs is NULL.
4953 2009-01-16 Sebastian Pop <sebastian.pop@amd.com>
4954 Tobias Grosser <tobi.grosser@amd.com>
4956 * graphite.c (graphite_trans_scop_block): Do not block single
4959 2009-01-15 Sebastian Pop <sebastian.pop@amd.com>
4960 Tobias Grosser <tobi.grosser@amd.com>
4962 * graphite.c (build_scop_canonical_schedules): Start schedules at
4965 2009-01-15 Sebastian Pop <sebastian.pop@amd.com>
4966 Tobias Grosser <tobi.grosser@amd.com>
4968 * graphite.c (compare_prefix_loops): New.
4969 (build_scop_canonical_schedules): Rewritten.
4970 (graphite_transform_loops): Move build_scop_canonical_schedules
4971 after build_scop_iteration_domain.
4973 2009-01-14 Sebastian Pop <sebastian.pop@amd.com>
4974 Tobias Grosser <tobi.grosser@amd.com>
4976 * graphite.c (add_conditions_to_domain): Add the loops to
4977 the dimension of the iteration domain. Do copy the domain
4978 only when it exists.
4979 (build_scop_conditions_1): Do not call add_conditions_to_domain.
4980 (add_conditions_to_constraints): New.
4981 (can_generate_code_stmt, can_generate_code): Removed.
4982 (gloog): Do not call can_generate_code.
4983 (graphite_transform_loops): Call add_conditions_to_constraints
4984 after building the iteration domain.
4986 2009-01-14 Sebastian Pop <sebastian.pop@amd.com>
4987 Tobias Grosser <tobi.grosser@amd.com>
4988 Jan Sjodin <jan.sjodin@amd.com>
4990 * graphite.c (scan_tree_for_params): On substractions negate
4991 all the coefficients of the term.
4992 (clast_to_gcc_expression_red): New. Handle reduction expressions
4993 of more than two operands.
4994 (clast_to_gcc_expression): Call clast_to_gcc_expression_red.
4995 (get_vdef_before_scop): Handle also the case of default definitions.
4997 2009-01-14 Sebastian Pop <sebastian.pop@amd.com>
5000 * graphite.c (get_vdef_before_scop, scop_adjust_vphi): New.
5001 (scop_adjust_phis_for_liveouts): Call scop_adjust_vphi.
5002 (gloog): Do not call cleanup_tree_cfg.
5003 (graphite_transform_loops): Call cleanup_tree_cfg after all
5004 scops have been code generated.
5006 2009-01-13 Sebastian Pop <sebastian.pop@amd.com>
5008 * passes.c (init_optimization_passes): Schedule after
5009 graphite transforms pass_copy_prop, pass_dce_loop and pass_lim.
5011 2009-01-13 Sebastian Pop <sebastian.pop@amd.com>
5013 * graphite.c (expand_scalar_variables_stmt): Do not pass loop_p.
5015 (expand_scalar_variables_ssa_name): Do not pass loop_p. Fix comment.
5016 Set the type of an expression to the type of its assign statement.
5017 (expand_scalar_variables_expr): Do not pass loop_p.
5018 Fix comment. Stop recursion on tcc_constant or tcc_declaration.
5019 (copy_bb_and_scalar_dependences): Do not pass loop_p.
5020 (translate_clast): Update call to copy_bb_and_scalar_dependences.
5022 2009-01-11 Sebastian Pop <sebastian.pop@amd.com>
5024 * graphite.c (expand_scalar_variables_ssa_name): Set the type of
5025 an expression to the gimple_expr_type of its assign statement.
5026 (expand_scalar_variables_expr): Stop recursion on tcc_constant
5029 2009-01-11 Sebastian Pop <sebastian.pop@amd.com>
5031 PR tree-optimization/38786
5032 * gcc.dg/graphite/pr38786.c: New.
5033 * graphite.c (expand_scalar_variables_ssa_name): New, outlined from
5034 the SSA_NAME case of expand_scalar_variables_expr.
5035 (expand_scalar_variables_expr): Also gather the scalar computation
5036 used to index the memory access.
5037 (expand_scalar_variables_stmt): Pass to expand_scalar_variables_expr
5038 the gimple_stmt_iterator where it inserts new code.
5040 2009-01-10 Sebastian Pop <sebastian.pop@amd.com>
5042 * gcc.dg/graphite/block-3.c: Fix compile error on 32bit.
5044 2009-01-10 Sebastian Pop <sebastian.pop@amd.com>
5046 * opts.c (decode_options): Enable flag_graphite_identity and
5047 flag_loop_block in -O2 and above.
5049 2009-01-08 Sebastian Pop <sebastian.pop@amd.com>
5051 * libjava/classpath/lib/gnu/java/awt/peer/gtk/GtkMouseInfoPeer.class:
5052 Fix merge problem: replace with the file from trunk.
5054 2009-01-08 Sebastian Pop <sebastian.pop@amd.com>
5056 * Merge from mainline (r141727:143163).
5058 2009-01-07 Sebastian Pop <sebastian.pop@amd.com>
5059 Jan Sjodin <jan.sjodin@amd.com>
5061 PR tree-optimization/38559
5062 * gcc.dg/graphite/pr38559.c: New.
5064 * graphite.c (debug_value, copy_constraint,
5065 swap_constraint_variables, scale_constraint_variable, ): New.
5066 (get_lower_bound, get_upper_bound): Removed.
5067 (graphite_trans_bb_strip_mine): Clean up this code that works
5068 only for constant number of iterations. Fully copy upper and
5069 lower bound constraints, not only the constant part of them.
5070 * graphite.h (debug_value): Declared.
5072 2009-01-06 Jan Sjodin <jan.sjodin@amd.com>
5074 PR tree-optimization/38492
5075 PR tree-optimization/38498
5076 * tree-check.c (operator_is_linear, scev_is_linear_expression): New.
5077 * tree-chrec.h (scev_is_linear_expression): Declared.
5078 * graphite.c (graphite_cannot_represent_loop_niter): New.
5079 (scopdet_basic_block_info): Call graphite_cannot_represent_loop_niter.
5080 (graphite_loop_normal_form): Use gcc_assert.
5081 (scan_tree_for_params): Use CASE_CONVERT.
5082 (phi_node_is_iv, bb_contains_non_iv_scalar_phi_nodes): New.
5083 (build_scop_conditions_1): Call bb_contains_non_iv_scalar_phi_nodes.
5084 Use gcc_assert. Discard scops that contain unhandled cases.
5085 (build_scop_conditions): Return a boolean status for unhandled cases.
5086 (strip_mine_profitable_p): Print the loop number, not its depth.
5087 (is_interchange_valid): Pass the depth of the loop nest, don't
5088 recompute it wrongly.
5089 (graphite_trans_bb_block): Same.
5090 (graphite_trans_bb_block): Print tentative of loop blocking.
5091 (graphite_trans_scop_block): Do not print that the loop has been
5093 (graphite_transform_loops): Do not handle scops that contain condition
5096 * gcc.dg/graphite/pr38500.c: Fixed warning as committed
5098 * gcc.dg/graphite/block-0.c: Update test.
5099 * gcc.dg/graphite/block-1.c: Same.
5100 * gcc.dg/graphite/block-2.c: Remove xfail and test for
5102 * gcc.dg/graphite/block-4.c: Remove test for strip mine.
5103 * gcc.dg/graphite/block-3.c: New.
5104 * gcc.dg/graphite/pr38498.c: New.
5106 2008-12-22 Harsha Jagasia <harsha.jagasia@amd.com>
5108 PR tree-optimization/38510
5109 * gcc.dg/graphite/pr38510.c: New.
5110 * graphite.c (recompute_all_dominators): Call mark_irreducible_loops.
5111 (translate_clast): Call recompute_all_dominators before
5113 (gloog): Call recompute_all_dominators before graphite_verify.
5115 2008-12-12 Sebastian Pop <sebastian.pop@amd.com>
5117 PR tree-optimization/38492
5118 * graphite.c (rename_map_elt, debug_rename_elt,
5119 debug_rename_map_1, debug_rename_map, new_rename_map_elt,
5120 rename_map_elt_info, eq_rename_map_elts,
5121 get_new_name_from_old_name, bb_in_sese_p): Moved around.
5122 (sese_find_uses_to_rename_use): Renamed sese_build_livein_liveouts_use.
5123 (sese_find_uses_to_rename_bb): Renamed sese_build_livein_liveouts_bb.
5124 (sese_build_livein_liveouts): New.
5125 (new_sese, free_sese): New.
5126 (new_scop): Call new_sese.
5127 (free_scop): Call free_sese.
5128 (rename_variables_from_edge, rename_phis_end_scop): Removed.
5129 (register_old_new_names): Renamed register_old_and_new_names.
5130 (register_scop_liveout_renames, add_loop_exit_phis,
5131 insert_loop_close_phis, struct igp,
5132 default_liveout_before_guard, add_guard_exit_phis,
5133 insert_guard_phis, copy_renames): New.
5134 (translate_clast): Call insert_loop_close_phis and insert_guard_phis.
5135 (sese_add_exit_phis_edge): Renamed scop_add_exit_phis_edge.
5136 (rewrite_into_sese_closed_ssa): Renamed scop_insert_phis_for_liveouts.
5137 (scop_adjust_phis_for_liveouts): New.
5138 (gloog): Call scop_adjust_phis_for_liveouts.
5140 * graphite.h (struct sese): Documented. Added fields liveout,
5142 (SESE_LIVEOUT, SESE_LIVEIN, SESE_LIVEIN_VER, SESE_NUM_VER): New.
5143 (new_sese, free_sese, sese_build_livein_liveouts): Declared.
5144 (struct scop): Added field liveout_renames.
5145 (SCOP_LIVEOUT_RENAMES): New.
5147 2008-12-11 Sebastian Pop <sebastian.pop@amd.com>
5149 PR tree-optimization/38409
5150 * gcc.dg/graphite/pr38409.c: New.
5151 * graphite.c (nb_reductions_in_loop): Use simple_iv.
5153 2008-12-11 Sebastian Pop <sebastian.pop@amd.com>
5155 * graphite.c (gcc_type_for_cloog_iv): By default return
5157 (graphite_create_new_loop): Don't fold_convert the already
5158 fold_convert-ed expression.
5160 2008-12-11 Harsha Jagasia <harsha.jagasia@amd.com>
5162 PR tree-optimization/38446
5163 * gcc.dg/graphite/pr38446.c: New.
5164 * graphite.c (register_bb_in_sese): New.
5165 (bb_in_sese_p): Check if bb belongs to sese region by explicitly
5166 looking at the bbs in the region.
5167 * graphite.h (sese): Add region_basic_blocks pointer set to
5168 structure and initialize at the time of defining new scop.
5170 2008-12-11 Tobias Grosser <grosser@fim.uni-passau.de>
5172 * graphite.c (new_graphite_bb): Initialize GBB_STATIC_SCHEDULE.
5173 (find_params_in_bb): Do not free data refs.
5174 (free_graphite_bb): Add FIXME on disabled free_data_refs.
5176 2008-12-11 Sebastian Pop <sebastian.pop@amd.com>
5178 * gcc.dg/graphite/scop-16.c: Test only scop specific info.
5179 * gcc.dg/graphite/scop-17.c: Same.
5180 * gcc.dg/graphite/block-5.c: New.
5181 * gcc.dg/graphite/block-6.c: New.
5182 * gcc.dg/graphite/pr37485.c: Clean dump file after.
5183 * gcc.dg/graphite/pr37684.c: Same.
5184 * gcc.dg/graphite/block-2.c: Same.
5186 * graphite.c (struct ivtype_map_elt): New.
5187 (debug_ivtype_elt, debug_ivtype_map_1, debug_ivtype_map,
5188 new_ivtype_map_elt, ivtype_map_elt_info, eq_ivtype_map_elts,
5189 gcc_type_for_cloog_iv): New.
5190 (loop_iv_stack_patch_for_consts): Use the type of the induction
5191 variable from the original loop, except for the automatically
5192 generated loops, i.e., in the case of a strip-mined loop, in
5193 which case there is no original loop: in that case just use
5195 (new_graphite_bb): Initialize GBB_CLOOG_IV_TYPES.
5196 (free_graphite_bb): Free GBB_CLOOG_IV_TYPES.
5197 (clast_name_to_gcc): Accept params to be NULL.
5198 (clast_to_gcc_expression): Take an extra parameter for the type.
5199 Convert to that type all the expressions built by this function.
5200 (gcc_type_for_clast_expr, gcc_type_for_clast_eq): New.
5201 (graphite_translate_clast_equation): Compute the type of the
5202 clast_equation before translating its LHS and RHS.
5203 (clast_get_body_of_loop, gcc_type_for_iv_of_clast_loop): New.
5204 (graphite_create_new_loop): Compute the type of the induction
5205 variable before translating the lower and upper bounds and before
5206 creating the induction variable.
5207 (rename_variables_from_edge, rename_phis_end_scop): New.
5208 (copy_bb_and_scalar_dependences): Call rename_phis_end_scop.
5209 (sese_add_exit_phis_edge): Do not use integer_zero_node.
5210 (find_cloog_iv_in_expr, compute_cloog_iv_types_1,
5211 compute_cloog_iv_types): New.
5212 (gloog): Call compute_cloog_iv_types before starting the
5213 translation of the clast.
5215 * graphite.h (struct graphite_bb): New field cloog_iv_types.
5216 (GBB_CLOOG_IV_TYPES): New.
5217 (debug_ivtype_map): Declared.
5218 (oldiv_for_loop): New.
5220 2008-12-10 Tobias Grosser <grosser@fim.uni-passau.de>
5223 * graphite.c (new_scop): Initialize SCOP_ADD_PARAMS.
5224 (param_index): Assert if parameter is not know after parameter
5226 (find_params_in_bb): Detect params directly in GBB_CONDITIONS.
5227 (find_scop_parameters): Mark, that we have finished parameter
5229 (graphite_transform_loops): Move condition detection before parameter
5231 * graphite.h (struct scop): Add SCOP_ADD_PARAMS.
5232 * gfortran.dg/graphite/pr38459.f90: New.
5234 2008-12-09 Tobias Grosser <grosser@fim.uni-passau.de>
5236 * graphite.c (graphite_transform_loops): Always call find_transform ()
5237 in ENABLE_CHECKING. So we test these code paths, even if we do not
5240 2008-12-09 Tobias Grosser <grosser@fim.uni-passau.de>
5242 * graphite.c (print_graphite_bb): Fix printing to file != dump_file.
5243 (print_scop): Ditto.
5245 2008-12-08 Tobias Grosser <grosser@fim.uni-passau.de>
5248 Fix gfortran.dg/graphite/id-3.f90.
5249 * graphite.c (scopdet_basic_block_info): Fix bug that found some
5250 regions more than once.
5252 2008-12-03 Sebastian Pop <sebastian.pop@amd.com>
5254 Fix gfortran.dg/graphite/id-4.f90.
5255 * graphite.c (scan_tree_for_params): Do not compute the multiplicand
5258 2008-12-03 Sebastian Pop <sebastian.pop@amd.com>
5260 Fix gfortran.dg/graphite/id-1.f90.
5261 * graphite.c (gmp_cst_to_tree): Pass the type in parameter.
5262 (loop_iv_stack_patch_for_consts): Update use of gmp_cst_to_tree.
5263 (max_precision_type): New.
5264 (value_clast): Removed.
5265 (clast_to_gcc_expression): Be more careful to types of expressions.
5266 Use max_precision_type and update use of gmp_cst_to_tree.
5267 (graphite_translate_clast_equation): Use max_precision_type.
5268 (graphite_create_guard_cond_expr): Do not use integer_type_node,
5269 use the type of the condition.
5270 (graphite_create_new_loop): Do not use integer_type_node, use the
5271 max_precision_type of lb and ub.
5273 2008-12-03 Sebastian Pop <sebastian.pop@amd.com>
5275 * graphite.c (build_scops_1): Initialize open_scop.exit
5278 2008-12-02 Sebastian Pop <sebastian.pop@amd.com>
5280 * gcc.dg/graphite/pr38084.c: New.
5281 * gfortran.dg/graphite/id-1.f90: New.
5282 * gfortran.dg/graphite/id-2.f90: New.
5283 * gfortran.dg/graphite/id-3.f90: New.
5284 * gfortran.dg/graphite/id-4.f90: New.
5285 * gfortran.dg/graphite/pr37857.f90: New.
5287 2008-12-02 Sebastian Pop <sebastian.pop@amd.com>
5288 Jan Sjodin <jan.sjodin@amd.com>
5289 Harsha Jagasia <harsha.jagasia@amd.com>
5301 * gcc.dg/graphite/pr38073.c: New.
5302 * gcc.dg/graphite/pr37928.c: New.
5303 * gcc.dg/graphite/pr37883.c: New.
5304 * gcc.dg/graphite/pr38125.c: New.
5305 * gfortran.dg/graphite/pr38083.f90: New.
5306 * gfortran.dg/graphite/pr37852.f90: New.
5307 * gfortran.dg/graphite/pr37980.f90: New.
5309 * gcc.dg/graphite/scop-18.c: Remove reduction, test for
5310 the number of detected scops. Copy exact same test for loop
5312 * gcc.dg/graphite/block-1.c: Fix the number of expected
5313 loops to be blocked as reductions are not handled.
5314 * gcc.dg/graphite/block-4.c: ...here. New.
5316 * tree-phinodes.c (remove_phi_nodes): New, extracted from...
5317 * tree-cfg.c (remove_phi_nodes_and_edges_for_unreachable_block):
5319 * tree-flow.h (remove_phi_nodes, canonicalize_loop_ivs): Declared.
5320 * Makefile.in (graphite.o): Depend on value-prof.h.
5321 (graphite.o-warn): Removed -Wno-error.
5322 * tree-parloops.c (canonicalize_loop_ivs): Allow reduction_list
5323 to be a NULL pointer. Call update_stmt. Return the newly created
5324 cannonical induction variable.
5326 * graphite.h (debug_rename_map): Declared. Fix some comments.
5328 * graphite.c: Reimplement the code generation from graphite to gimple.
5329 Include value-prof.h.
5330 (loop_iv_stack_get_iv): Do not return NULL for constant substitutions.
5331 (get_old_iv_from_ssa_name): Removed.
5332 (graphite_stmt_p): New.
5333 (new_graphite_bb): Test for useful statements before building a
5334 graphite statement for the basic block.
5335 (free_graphite_bb): Do not free GBB_DATA_REFS: this is a bug
5336 in free_data_ref that calls BITMAP_FREE (DR_VOPS (dr)) without
5338 (recompute_all_dominators, graphite_verify,
5339 nb_reductions_in_loop, graphite_loop_normal_form): New.
5340 (scop_record_loop): Call graphite_loop_normal_form.
5341 (build_scop_loop_nests): Iterate over all the blocks of the
5342 function instead of relying on the incomplete information from
5343 SCOP_BBS. Return the success of the operation.
5344 (find_params_in_bb): Use the data from GBB_DATA_REFS.
5345 (add_bb_domains): Removed.
5346 (build_loop_iteration_domains): Don't call add_bb_domains.
5347 Add the iteration domain only to the basic blocks that have been
5348 translated to graphite.
5349 (build_scop_conditions_1): Add constraints only if the basic
5350 block have been translated to graphite.
5351 (build_scop_data_accesses): Completely disabled until data
5352 dependence is correctly implemented.
5353 (debug_rename_elt, debug_rename_map_1, debug_rename_map): New.
5354 (remove_all_edges_1, remove_all_edges): Removed.
5355 (get_new_name_from_old_name): New.
5356 (graphite_rename_variables_in_stmt): Renamed
5357 rename_variables_in_stmt. Call get_new_name_from_old_name.
5358 Use replace_exp and update_stmt.
5359 (is_old_iv): Renamed is_iv.
5360 (expand_scalar_variables_stmt): Extra parameter for renaming map.
5361 Use replace_exp and update_stmt.
5362 (expand_scalar_variables_expr): Same. Use the map to get the
5363 new names for the renaming of induction variables and for the
5364 renaming of variables after a basic block has been copied.
5365 (expand_scalar_variables): Same.
5366 (graphite_rename_variables): Renamed rename_variables.
5367 (move_phi_nodes): Removed.
5368 (get_false_edge_from_guard_bb): New.
5369 (build_iv_mapping): Do not insert the induction variable of a
5370 loop in the renaming iv map if the basic block does not belong
5372 (register_old_new_names, graphite_copy_stmts_from_block,
5373 copy_bb_and_scalar_dependences): New.
5374 (translate_clast): Heavily reimplemented: copy basic blocks,
5375 do not move them. Finally, in call cleanup_tree_cfg in gloog.
5376 At each translation step call graphite_verify ensuring the
5377 consistency of the SSA, loops and dominators information.
5378 (collect_virtual_phis, find_vdef_for_var_in_bb,
5379 find_vdef_for_var_1, find_vdef_for_var,
5380 patch_phis_for_virtual_defs): Removed huge hack.
5381 (mark_old_loops, remove_dead_loops, skip_phi_defs,
5382 collect_scop_exit_phi_args, patch_scop_exit_phi_args,
5383 gbb_can_be_ignored, scop_remove_ignoreable_gbbs, ): Removed.
5384 (remove_sese_region, ifsese, if_region_entry, if_region_exit,
5385 if_region_get_condition_block, if_region_set_false_region,
5386 create_if_region_on_edge, move_sese_in_condition, bb_in_sese_p,
5387 sese_find_uses_to_rename_use, sese_find_uses_to_rename_bb,
5388 sese_add_exit_phis_edge, sese_add_exit_phis_var,
5389 rewrite_into_sese_closed_ssa): New.
5390 (gloog): Remove dead code. Early return if code cannot be
5391 generated. Call cleanup_tree_cfg once the scop has been code
5393 (graphite_trans_scop_block, graphite_trans_loop_block): Do not
5394 block loops with less than two loops.
5395 (graphite_apply_transformations): Remove the call to
5396 scop_remove_ignoreable_gbbs.
5397 (limit_scops): When build_scop_loop_nests fails, continue on
5398 the next scop. Fix open_scop.entry.
5399 (graphite_transform_loops): Call recompute_all_dominators: force the
5400 recomputation of correct CDI_DOMINATORS and CDI_POST_DOMINATORS.
5401 Call initialize_original_copy_tables and free_original_copy_tables
5402 to be able to copy basic blocks during code generation.
5403 When build_scop_loop_nests fails, continue on next scop.
5404 (value_clast): New union.
5405 (clast_to_gcc_expression): Fix type cast warning.
5407 2008-11-09 Sebastian Pop <sebastian.pop@amd.com>
5409 * Merge from mainline (r140838:141727).
5411 2008-11-05 Tobias Grosser <grosser@fim.uni-passau.de>
5415 * graphite.c (scan_tree_for_params): Add POINTER_PLUS_EXPR.
5417 2008-11-05 Tobias Grosser <grosser@fim.uni-passau.de>
5421 * graphite.c (scopdet_basic_block_info): Fix loops with multiple
5422 exits and conditions.
5423 * gcc.dg/graphite/pr37943.c: New.
5425 2008-10-23 Tobias Grosser <grosser@fim.uni-passau.de>
5428 * graphite.c (gloog): Replace EXIT_BLOCK_PTR with scop exit.
5430 2008-10-23 Tobias Grosser <grosser@fim.uni-passau.de>
5432 * doc/invoke.texi: Fix spaces.
5434 2008-10-22 Sebastian Pop <sebastian.pop@amd.com>
5436 PR tree-optimization/37891
5437 Reverted last commit.
5438 * graphite.c (create_single_entry_edge): Set
5439 EDGE_IRREDUCIBLE_LOOP and BB_IRREDUCIBLE_LOOP.
5441 2008-10-21 Sebastian Pop <sebastian.pop@amd.com>
5442 Mitul Thakkar <mitul.thakkar@amd.com>
5444 * graphite.c (create_single_entry_edge): Set
5445 EDGE_IRREDUCIBLE_LOOP and BB_IRREDUCIBLE_LOOP.
5447 2008-10-16 Tobias Grosser <grosser@fim.uni-passau.de>
5449 * doc/invoke.texi: Add -fgraphite-identity.
5450 * graphite.c (graphite_apply_transformations): Check for
5451 -fgraphite-identity.
5452 * toplev.c (process_options): Add flag_graphite_identity.
5453 * tree-ssa-loop.c: Add flag_graphite_identity.
5455 2008-10-14 Sebastian Pop <sebastian.pop@amd.com>
5457 Undo changes from 2008-10-02:
5458 * tree-ssa-loop-ivopts.c (rewrite_use_nonlinear_expr): Convert
5459 operand type when copying the operand to a variable of different type.
5460 * cfgloopmanip.c (create_empty_loop_on_edge): Write exit condition
5461 with the IV name after increment.
5463 2008-10-14 Sebastian Pop <sebastian.pop@amd.com>
5464 Harsha Jagasia <harsha.jagasia@amd.com>
5466 PR tree-optimization/37828
5467 * gcc.dg/graphite/pr37828.c: New.
5468 * graphite.c (graphite_trans_loop_block): Do not loop block
5469 single nested loops.
5471 2008-10-09 Harsha Jagasia <harsha.jagasia@amd.com>
5472 Sebastian Pop <sebastian.pop@amd.com>
5474 * graphite.c (struct rename_map_elt, new_rename_map_elt,
5475 rename_map_elt_info, eq_rename_map_elts): New.
5476 (graphite_rename_ivs_stmt): Renamed graphite_rename_variables_in_stmt.
5477 (expand_scalar_variables_expr): Change parameters.
5478 (expand_scalar_variables_stmt): Same.
5479 (expand_scalar_variables): Same.
5480 (graphite_rename_ivs): Rename graphite_rename_variables.
5481 (build_iv_mapping): New.
5482 (translate_clast): Call build_iv_mapping.
5483 * graphite.h (gbb_p): New name.
5485 2008-10-03 Harsha Jagasia <harsha.jagasia@amd.com>
5487 PR tree-optimization/37684
5488 * gcc.dg/graphite/pr37684.c: New.
5489 * graphite.c (exclude_component_ref): New.
5490 (is_simple_operand): Call exclude_component_ref.
5492 2008-10-02 Jan Sjodin <jan.sjodin@amd.com>
5493 Harsha Jagasia <harsha.jagasia@amd.com>
5495 PR tree-optimization/37485
5496 * gcc.dg/graphite/block-2.c: New
5497 * graphite.c (gmp_cst_to_tree): Moved.
5498 (iv_stack_entry_is_constant): New.
5499 (iv_stack_entry_is_iv): New.
5500 (loop_iv_stack_push): Renamed to loop_iv_stack_push_iv.
5501 (loop_iv_stack_insert_constant): New.
5502 (loop_iv_stack_pop): Use new datatpype.
5503 (loop_iv_stack_get_iv): Same.
5504 (loop_iv_stack_get_iv_from_name): Same.
5505 (loop_iv_stack_debug): Renamed to debug_loop_iv_stack.
5506 (loop_iv_stack_patch_for_consts): New.
5507 (loop_iv_stack_remove_constants): New.
5508 (graphite_create_new_loop): Use loop_iv_stack_push_iv.
5509 (translate_clast): Call loop_iv_stack_patch_for_consts and
5510 loop_iv_stack_remove_constants.
5511 (gloog): Use new datatype. Redirect construction edge to end
5512 block to avoid accidental deletion.
5513 * graphite.h (enum iv_stack_entry_kind): New. Tag for data in
5515 (union iv_stack_entry_data): New. Data in iv stack entry.
5516 (struct iv_stack_entry): New. Datatype for iv stack entries.
5518 2008-10-02 Sebastian Pop <sebastian.pop@amd.com>
5520 * tree-ssa-loop-ivopts.c (rewrite_use_nonlinear_expr): Convert
5521 operand type when copying the operand to a variable of different type.
5523 2008-10-02 Sebastian Pop <sebastian.pop@amd.com>
5525 * cfgloopmanip.c (create_empty_loop_on_edge): Write exit condition
5526 with the IV name after increment.
5528 2008-10-02 Sebastian Pop <sebastian.pop@amd.com>
5530 * Merge from mainline (r140164:140838).
5532 2008-09-10 Konrad Trifunovic <konrad.trifunovic@inria.fr>
5534 * graphite-data-ref.c: New.
5535 * graphite.c (print_scop): Also dump the dependence graph.
5536 (bb_in_scop_p, loop_in_scop_p, nb_loops_around_gb): Moved...
5537 (new_scop): Initialize SCOP_DEP_GRAPH.
5538 (build_scop_dynamic_schedules): New.
5539 (build_access_matrix_with_af): Fixed column numbering.
5540 (graphite_transform_loops): Call build_scop_dynamic_schedules.
5541 * graphite.h: Add ifndef/define guards against multiple inclusion.
5542 (struct scop): Add dep_graph field.
5543 (SCOP_DEP_GRAPH): Defined.
5544 (ref_nb_loops): Fixed and moved to other position.
5545 (bb_in_scop_p, loop_in_scop_p, nb_loops_around_gb): ... here.
5546 (nb_loops_around_loop_in_scop): New.
5547 (graphite_dump_dependence_graph): Declared.
5548 (graphite_build_rdg_all_levels): Declared.
5549 (graphite_test_dependence): Declared.
5550 * Makefile.in (graphite-data-ref.o): New target.
5552 2008-09-09 Sebastian Pop <sebastian.pop@amd.com>
5554 * Merge from mainline (139870:140164).
5556 2008-09-01 Sebastian Pop <sebastian.pop@amd.com>
5558 * Merge from mainline (138275:139870).
5559 * gcc.dg/graphite/scop-matmult.c: XFailed as one of
5560 the commits from trunk broke the niter detection.
5562 2008-09-01 Sebastian Pop <sebastian.pop@amd.com>
5564 * graphite.c: Add more documentation. Fix formatting.
5565 (debug_loop_vec, debug_oldivs, loop_iv_stack,
5566 loop_iv_stack_debug): Moved...
5567 (schedule_to_scattering): Move before use.
5568 (dot_all_scops): Include in "#if 0" the code for system
5571 * graphite.h: (debug_loop_vec, debug_oldivs, loop_iv_stack,
5572 loop_iv_stack_debug): ...here.
5574 2008-08-29 Jan Sjodin <jan.sjodin@amd.com>
5576 * tree-phinodes.c (make_phi_node): Extern.
5577 (add_phi_node_to_bb): New.
5578 (create_phi_node): Call add_phi_node_to_bb.
5579 * tree-ssa-loop-ivopts.c (get_phi_with_result): New.
5580 (remove_statement): Handle case where stored phi was updated
5581 and is no longer the same.
5582 * graphite.c (is_parameter): New.
5584 (expand_scalar_variables_expr): New.
5585 (expand_scalar_variables_stmt): New.
5586 (expand_scalar_variables): New.
5587 (move_phi_nodes): Create new phi instead of moving old one.
5588 (translate_clast): Call expand_scalar_variables.
5589 (find_vdef_for_var_in_bb): Also scan regular definitions.
5590 (skip_phi_defs): New.
5591 (collect_scop_exit_phi_args): New.
5592 (patch_scop_exit_phi_args): New.
5593 (gloog): Patch phis after scop.
5594 * tree-flow.h: (add_phi_node_to_bb): Declared.
5595 (make_phi_node): Declared.
5597 2008-08-26 Sebastian Pop <sebastian.pop@amd.com>
5599 * graphite.c (end_scop): Split the entry of the scop when it
5600 is the header of the loop in which the scop is ending.
5601 (build_scops_1, limit_scops): Update uses of end_scop.
5603 2008-08-26 Sebastian Pop <sebastian.pop@amd.com>
5605 * graphite.c (dot_all_scops_1): Do not fail on uninitialized
5606 SCOP_ENTRY or SCOP_EXIT.
5608 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
5610 * graphite.c (get_construction_edge): Removed.
5611 (gloog): Construction edge is the scop entry edge.
5613 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
5615 * graphite.c (can_generate_for_scop): Removed.
5616 (gloog): Do not call it.
5618 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
5620 * graphite.c (new_scop): Entry of a scop is an edge.
5621 Initialize SESE region.
5622 (free_scop): Free SESE region.
5623 (build_scops_1, scopdet_bb_info): Work on edges, not on bbs.
5624 (split_difficult_bb): New, split from end_scop.
5625 (end_scop): Exit of a scop is an edge.
5626 (build_scop_bbs): Never check CDI_POST_DOMINATORS: this info is
5627 not automatically updated and thus is always wrong.
5628 * graphite.h (struct sese): New.
5631 (struct scop): New field for a SESE region. Remove entry, exit.
5632 (SCOP_ENTRY, SCOP_EXIT): Update definitions to match same
5633 semantics as before. Moved comment around.
5635 2008-08-25 Tobias Grosser <grosser@fim.uni-passau.de>
5636 Sebastian Pop <sebastian.pop@amd.com>
5638 * graphite.c (graphite_transform_loops): Always enable gloog
5639 and find_transform when ENABLE_CHECKING.
5641 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
5643 * graphite.c (graphite_transform_loops): Move pretty printer
5644 of SCOPs before doing any transform. Remove call to print_scops
5645 and dot_all_scops_1.
5647 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
5649 * graphite.c (dump_gbb_conditions): Don't try to print NULL pointers.
5650 (print_graphite_bb): Same.
5652 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
5654 * graphite.c (dot_all_scops_1): Cleanup.
5655 (move_scops): Fix comment.
5657 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
5659 * graphite.c (build_scop_bbs): Revert commit 139355:
5661 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5662 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
5664 * graphite.c (build_scop_bbs): Factor up code.
5666 2008-08-25 Tobias Grosser <grosser@fim.uni-passau.de>
5668 * graphite.c (gloog): Update dominator info.
5670 2008-08-25 Tobias Grosser <grosser@fim.uni-passau.de>
5672 * graphite.c (remove_cond_exprs): Do not fail on empty bbs.
5674 2008-08-24 Sebastian Pop <sebastian.pop@amd.com>
5676 * graphite.c (new_graphite_bb): Remove GBB_INDEX_TO_NUM_MAP
5678 (free_graphite_bb): Remove GBB_INDEX_TO_NUM_MAP free.
5679 (translate_clast): Correct formatting.
5680 * graphite.h (struct num_map): Removed.
5681 (struct graphite_bb): Remove num_map field.
5682 (GBB_INDEX_TO_NUM_MAP): Removed.
5684 2008-08-24 Sebastian Pop <sebastian.pop@amd.com>
5686 * graphite.c (build_access_matrix_with_af): Fix comments.
5687 (build_scop_data_accesses): Same.
5689 2008-08-24 Sebastian Pop <sebastian.pop@amd.com>
5691 * graphite.c (build_scop_data_accesses): Don't construct
5692 access matrices. Add a FIXME and an assert condition that
5693 should pass when the access matrices will be needed.
5695 2008-08-24 Sebastian Pop <sebastian.pop@amd.com>
5697 * tree-data-ref.c (stmt_simple_memref_p): Don't call
5699 * graphite.c (build_graphite_bb): Renamed new_graphite_bb.
5700 Moved close by free_graphite_bb.
5701 (free_graphite_bb): Call free_data_refs. Reset bb->aux.
5702 (new_scop): Move close by free_scop.
5703 (graphite_transform_loops): Avoid linear scan to reset bb->aux.
5705 2008-08-22 Jan Sjodin <jan.sjodin@amd.com>
5707 * cfgloopmanip.c (create_empty_if_region_on_edge): New.
5708 * graphite.c (clast_to_gcc_expression): Call gmp_cst_to_tree
5709 instead of recursive call.
5710 (graphite_translate_clast_equation): New.
5711 (graphite_create_guard_cond_expr): New.
5712 (graphite_create_new_guard): New.
5713 (get_stack_index_from_iv): Removed.
5714 (graphite_rename_ivs_stmt): Use gbb_loop_index.
5715 (get_true_edge_from_guard_bb): New.
5716 (translate_clast): Handle stmt_guard in clast.
5717 (get_construction_edge): Allow construction edge detection for
5718 a scope entry with multiple predecessors if one predecessor is
5719 the immediate dominator of scope entry.
5720 (can_generate_code_stmt): Enable code generation for clast_guard.
5721 (gloog): Use correct context loop. Removed check for post dominators.
5722 * cfgloop.h (create_empty_if_region_on_edge): Declared.
5724 2008-08-21 Sebastian Pop <sebastian.pop@amd.com>
5726 * graphite.c (remove_dead_loops): Document better which
5729 2008-08-21 Sebastian Pop <sebastian.pop@amd.com>
5731 * Makefile.in: Rename POLYLIBLIBS and POLYLIBINC to PPLLIBS
5733 (graphite.o): Also depends on pointer-set.h.
5735 2008-08-21 Sebastian Pop <sebastian.pop@amd.com>
5737 * graphite.c (scop_record_loop): Fix compile warning.
5739 2008-08-21 Harsha Jagasia <harsha.jagasia@amd.com>
5740 Sebastian Pop <sebastian.pop@amd.com>
5742 * graphite.c (scop_record_loop): DECL_NAME can be NULL.
5744 2008-08-21 Sebastian Pop <sebastian.pop@amd.com>
5746 * graphite.c (build_graphite_bb): Initialize bb->aux to
5747 point to the graphite_bb_p.
5748 (graphite_bb_from_bb): Renamed gbb_from_bb; returns the
5750 (add_bb_domains): Does not use the scop parameter.
5751 (graphite_transform_loops): Clean bb->aux at the end.
5753 2008-08-20 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
5754 Sebastian Pop <sebastian.pop@amd.com>
5756 * lib/target-supports.exp
5757 (check_effective_target_fgraphite): New.
5759 * gcc.dg/graphite/graphite.exp: Early exit when
5760 check_effective_target_fgraphite returns false.
5761 Set dg-do-what-default to compile.
5762 (scan-graphite-dump-times): Removed.
5763 * gfortran.dg/graphite/graphite.exp: Same.
5765 * gcc.dg/graphite/scop-0.c: Do not use "dg-do compile".
5766 Use scan-tree-dump-times instead of scan-graphite-dump-times.
5767 * gcc.dg/graphite/scop-1.c: Same.
5768 * gcc.dg/graphite/scop-2.c: Same.
5769 * gcc.dg/graphite/scop-3.c: Same.
5770 * gcc.dg/graphite/scop-4.c: Same.
5771 * gcc.dg/graphite/scop-5.c: Same.
5772 * gcc.dg/graphite/scop-6.c: Same.
5773 * gcc.dg/graphite/scop-7.c: Same.
5774 * gcc.dg/graphite/scop-8.c: Same.
5775 * gcc.dg/graphite/scop-9.c: Same.
5776 * gcc.dg/graphite/scop-10.c: Same.
5777 * gcc.dg/graphite/scop-11.c: Same.
5778 * gcc.dg/graphite/scop-12.c: Same.
5779 * gcc.dg/graphite/scop-13.c: Same.
5780 * gcc.dg/graphite/scop-matmult.c: Same.
5781 * gcc.dg/graphite/scop-14.c: Same.
5782 * gcc.dg/graphite/scop-15.c: Same.
5783 * gcc.dg/graphite/block-0.c: Same.
5784 * gcc.dg/graphite/scop-16.c: Same.
5785 * gcc.dg/graphite/block-1.c: Same.
5786 * gcc.dg/graphite/scop-17.c: Same.
5787 * gcc.dg/graphite/scop-18.c: Same.
5788 * gfortran.dg/graphite/block-1.f90: Same.
5789 * gfortran.dg/graphite/scop-1.f: Same.
5790 * gfortran.dg/graphite/block-2.f: Same.
5792 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5794 * graphite.c: Fix some XXX comments.
5795 (build_scop_dynamic_schedules): Removed.
5797 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5799 * graphite.h (scop_max_loop_depth): Moved...
5800 * graphite.c (scop_max_loop_depth): ...here.
5801 (remove_all_edges_1): New.
5802 (remove_all_edges): Factored code.
5803 (remove_cond_exprs): Check only the last statement for
5804 a GIMPLE_COND expression.
5806 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5808 * graphite.c (scan_tree_for_params): Early return when the
5809 expression is a chrec_dont_know. Handle case NEGATE_EXPR.
5810 (find_scop_parameters): Factor out code.
5811 (graphite_trans_bb_strip_mine): Remove dead code.
5813 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5815 * graphite.c (clast_to_gcc_expression, graphite_create_new_loop,
5816 graphite_trans_bb_move_loop): Factor asserts.
5817 (gloog): Perform sanity checks only for ENABLE_CHECKING.
5818 Do not call calculate_dominance_info and estimate_bb_frequencies.
5820 2008-08-20 Jan Sjodin <jan.sjodin@amd.com>
5822 * graphite.c (create_loops_mapping, free_loops_mapping,
5823 create_loops_mapping_num, debug_loop_mapping_1,
5824 debug_loop_mapping, graphite_loops_mapping_max_loop_num,
5825 get_loop_mapping_for_num, graphite_loops_mapping_add_child,
5826 graphite_loops_mapping_add_child_num,
5827 graphite_loops_mapping_insert_child,
5828 graphite_loops_mapping_parent, get_loop_mapped_depth_for_num,
5829 get_loop_mapped_depth, split_loop_mapped_depth_for_num,
5830 loop_mapped_depth_split_loop, swap_loop_mapped_depth_for_num,
5831 create_num_from_index, get_num_from_index,
5832 swap_loop_mapped_depth): Removed.
5833 (new_scop): Do not initialize SCOP_LOOPS_MAPPING.
5834 (free_scop): Do not call free_loops_mapping.
5835 (graphite_get_new_iv_stack_index_from_old_iv): Renamed
5836 get_stack_index_from_iv. Use GBB_LOOPS instead of calling
5837 get_loop_mapped_depth.
5838 (graphite_trans_bb_move_loop): Do not update the loop mapping.
5839 (graphite_trans_bb_strip_mine): Same.
5840 * graphite.h (graphite_loops_mapping, graphite_loop_node): Removed.
5841 (struct scop): Remove field loops_mapping.
5843 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5844 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
5846 * graphite.c (scop_record_loop): Factor out one level of the
5847 condition by early return.
5848 (build_scop_loop_nests): Format following FSF coding style.
5849 (build_scop_dynamic_schedules): Factor out code.
5850 (scopdet_bb_info): Reindent. Default case should not be reachable.
5852 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5853 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
5855 * graphite.c (loop_affine_expr): Check for DECL_P or struct
5856 assignments that are not handled as simple operands for now.
5858 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5859 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
5861 * graphite.c (build_scop_bbs): Factor up code.
5863 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5864 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
5866 * graphite.c (stmt_simple_for_scop_p): Factor code out
5868 (enum gbb_type): New. Group all the GBB_* types under it.
5869 (is_loop_exit): Moved...
5870 (end_scop): Enable BB spliting.
5871 * cfgloop.c (is_loop_exit): ...here. Reimplemented.
5872 * cfgloop.h (is_loop_exit): Declared.
5874 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5876 * doc/invoke.texi: Remove strides from examples containing
5877 DO loops when the strides are equal to 1.
5879 2008-08-20 Harsha Jagasia <harsha.jagasia@amd.com>
5880 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
5882 * graphite.c (graphite_trans_scop_block): Or the result with
5883 the result from graphite_trans_loop_block.
5884 * gcc.dg/graphite/block-1.c: New.
5885 * gfortran.dg/graphite/block-1.f90: New.
5886 * gfortran.dg/graphite/block-2.f: New.
5888 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5890 * graphite.c (graphite_transform_loops): Call cloog_initialize
5893 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5895 * tree-data-ref.c) (stmt_simple_memref_p): New.
5896 * tree-data-ref.h (stmt_simple_memref_p): Declared.
5897 * graphite.c (stmt_simple_memref_for_scop_p): Removed.
5898 (is_simple_operand): Call stmt_simple_memref_p.
5900 * gcc.dg/graphite/scop-matmult.c: Updated for not
5901 using pointer arithmetic, as this is optimized by PRE and
5902 makes the code too difficult to analyze.
5904 * gcc.dg/graphite/scop-18.c: Same.
5906 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5908 * gdbinit.in (pgg): New.
5910 2008-08-15 Tobias Grosser <grosser@fim.uni-passau.de>
5912 * graphite.c (graphite_trans_loop_block): Fix warning.
5914 2008-08-15 Tobias Grosser <grosser@fim.uni-passau.de>
5916 * graphite.c (graphite_trans_loop_block): Fix my merge error.
5918 2008-08-15 Tobias Grosser <grosser@fim.uni-passau.de>
5920 * graphite.c (graphite_trans_bb_block): Remove check for
5921 flag_loop_strip_mine, flag_loop_block, flag_loop_interchange.
5922 Check if loop blocking is profitable for every loop, before applying
5924 (graphite_apply_transformations): Call graphite_trans_bb_block only,
5925 if flag_loop_block is set.
5927 2008-08-14 Sebastian Pop <sebastian.pop@amd.com>
5929 * graphite.c: Add some more documentation for the loop
5932 2008-08-14 Sebastian Pop <sebastian.pop@amd.com>
5934 * Makefile.in (tree-data-ref.o): Remove dependence on graphite.h.
5935 * graphite.c: Format on less than 80 columns.
5938 2008-08-14 Sebastian Pop <sebastian.pop@amd.com>
5940 * cfgloopmanip.c (loopify): Use update_dominators_in_loop.
5942 2008-08-14 Sebastian Pop <sebastian.pop@amd.com>
5944 * doc/invoke.texi (floop-block, floop-strip-mine,
5945 floop-interchange): Update documentation with examples.
5947 2008-08-13 Sebastian Pop <sebastian.pop@amd.com>
5949 * cfgloopmanip.c (create_empty_loop_on_edge): Don't call
5951 * graphite.c (graphite_create_new_loop): Call add_referenced_var.
5953 2008-08-13 Sebastian Pop <sebastian.pop@amd.com>
5955 * cfgloopmanip.c (create_empty_loop_on_edge): Improve documentation.
5956 Factor gcc_asserts into a single one. Use force_gimple_operand_gsi.
5957 * tree-scalar-evolution.c: Revert useless changes.
5958 * tree-phinodes.c: Same.
5961 * tree-vectorizer.h: Same.
5962 * tree-flow.h: Same.
5964 * common.opt (fgraphite): Update documentation.
5966 2008-08-12 Harsha Jagasia <harsha.jagasia@amd.com>
5968 * doc/invoke.texi (-floop-block, -floop-strip-mine,
5969 -floop-interchange): Add more text for explaining what each of these
5971 * tree-into-ssa.c (gimple_vec): Moved to...
5972 * graphite.c: Include gimple.h.
5973 (gimple_vec): Moved to...
5974 (del_loop_to_cloog_loop): Removed.
5975 (loop_affine_expr): Do not call create_data_ref when the
5976 operand is a constant.
5977 (new_scop): Use free instead of del_loop_to_cloog_loop.
5978 * Makefile.in (graphite.o): Depend on GIMPLE_H.
5979 * gimple.h (gimple_vec): ... here.
5981 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5983 * graphite.c (scopdet_bb_info): Only allow loops with known number of
5985 (build_loop_iteration_domains): Fail, if latch executions unknown.
5987 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5989 * graphite.c (add_conditions_to_domain): New.
5990 (build_scop_conditions_1): Call add_conditions_to_domain.
5991 (set_cloog_options): Allow to disable optimizations.
5993 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5995 * graphite.c (find_params_in_bb): Look for parameters in conditions.
5996 Do not use walk_dominator_tree.
5997 (find_scop_parameters): Do not use walk_dominator_tree.
5999 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
6001 * graphite.c (scan_tree_for_params) Add / Subtract inequality.
6002 (idx_record_params): Adapt.
6003 * graphite.h (scop_gimple_loop_depth): New.
6005 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
6007 * graphite.c (build_scop_dynamic_schedules): Remove value_init.
6008 (scan_tree_for_params): Remove value_init.
6009 (build_scop_context): Remove value_init.
6010 (build_loop_iteration_domains): Remove value_init.
6011 (schedule_to_scattering): Remove value_init.
6012 (graphite_trans_bb_strip_mine): Remove value_init.
6014 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
6016 * gcc/graphite.c (limit_scops): New.
6017 (graphite_transform_loops): Add limit SCoPs.
6018 * gcc.dg/graphite/scop-0.c: Update number of SCoPs.
6019 * gcc.dg/graphite/scop-1.c: Update number of SCoPs.
6020 * gcc.dg/graphite/scop-10.c: Update number of SCoPs.
6021 * gcc.dg/graphite/scop-11.c: Update number of SCoPs.
6022 * gcc.dg/graphite/scop-12.c: Update number of SCoPs.
6023 * gcc.dg/graphite/scop-13.c: Update number of SCoPs.
6024 * gcc.dg/graphite/scop-14.c: Update number of SCoPs.
6025 * gcc.dg/graphite/scop-15.c: Update number of SCoPs.
6026 * gcc.dg/graphite/scop-16.c: Update number of SCoPs.
6027 Change loop numbers.
6028 * gcc.dg/graphite/scop-17.c: Update number of SCoPs.
6029 Change loop numbers.
6030 * gcc.dg/graphite/scop-18.c: Update number of SCoPs.
6031 * gcc.dg/graphite/scop-2.c: Update number of SCoPs.
6032 * gcc.dg/graphite/scop-3.c: Update number of SCoPs.
6033 * gcc.dg/graphite/scop-4.c: Update number of SCoPs.
6034 * gcc.dg/graphite/scop-5.c: Update number of SCoPs.
6035 * gcc.dg/graphite/scop-6.c: Update number of SCoPs.
6036 * gcc.dg/graphite/scop-7.c: Update number of SCoPs.
6037 * gcc.dg/graphite/scop-8.c: Update number of SCoPs.
6038 * gcc.dg/graphite/scop-9.c: Update number of SCoPs.
6039 * gcc.dg/graphite/scop-matmult.c: Update number of SCoPs.
6041 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
6043 * graphite.c (graphite_transform_loops): Call always find_transform.
6045 2008-08-08 Tobias Grosser <grosser@fim.uni-passau.de>
6047 * graphite.c (free_loops_mapping): New.
6048 (stmt_simple_for_scop_p): Fix typo.
6049 (stmt_simple_for_scop_p): Fix tuples functions, that
6051 (free_graphite_bb): Fix some memleaks.
6052 (free_scop): Fix some memleaks.
6053 (scopdet_bb_info): Do not forget some tmp SCoPs.
6054 (find_params_in_bb): Fix some memleaks.
6055 (clast_to_gcc_expression): Fix warning.
6057 2008-08-07 Tobias Grosser <grosser@fim.uni-passau.de>
6059 * gcc.dg/graphite/scop-16.c: Fix for 32bit.
6060 * gcc.dg/graphite/scop-17.c: Fix for 32bit.
6062 2008-08-04 Sebastian Pop <sebastian.pop@amd.com>
6064 * tree-ssa-loop.c (tree-ssa-loop.o): Do not include toplev.h.
6065 Move code ifdef-ed HAVE_cloog...
6066 * graphite.c: Include toplev.h.
6068 * Makefile.in (OBJS-common): Always build graphite.o.
6069 (BACKEND): Remove @GRAPHITE@.
6070 (tree-ssa-loop.o): Do not depend on TOPLEV_H.
6071 (graphite.o): Depend on TOPLEV_H.
6073 2008-08-04 Sebastian Pop <sebastian.pop@amd.com>
6075 * Makefile.in (tree-ssa-loop.o): Depend on TOPLEV_H.
6076 Remove typo left from polylib to ppl conversion.
6077 * graphite.c (graphite_transforms): Use sorry instead of fatal.
6079 2008-08-03 Sebastian Pop <sebastian.pop@amd.com>
6081 * toplev.c (process_options): Move the graphite loop optimization
6083 * tree-ssa-loop.c (graphite_transforms): ... here.
6084 When not configured with CLooG, print to dump_file that
6085 Graphite transforms were not performed.
6086 * gcc.dg/graphite/graphite.exp (scan-graphite-dump-times):
6088 * gcc.dg/graphite/*.c: Updated all testcases to use
6089 scan-graphite-dump-times.
6091 2008-08-03 Sebastian Pop <sebastian.pop@amd.com>
6093 * graphite.c (dot_scop, dot_all_scops): Do not call system.
6094 Do not open /tmp/scop.dot and /tmp/allscops.dot.
6096 2008-08-02 Sebastian Pop <sebastian.pop@amd.com>
6097 Jan Sjodin <jan.sjodin@amd.com>
6099 * configure: Regenerated.
6100 * omp-low.c (expand_omp_sections): Remove now unused code.
6101 * config.in (HAVE_polylib): Removed.
6102 * configure.ac (HAVE_polylib, POLYLIBLIBS, POLYLIBINC): Removed.
6103 (PPLLIBS, PPLINC): Added.
6104 * graphite.c: Replace unsigned with int wherever possible.
6105 Don't access Cloog's data structures, but use accessor functions.
6106 Clast's stmt->type is now implemented as a vtable: change the
6107 switches of stmt->type into ifs.
6108 (polylib/polylibgmp.h): Don't include.
6109 (initialize_dependence_polyhedron,
6110 initialize_data_dependence_polyhedron, is_empty_polyhedron,
6111 statement_precedes_p, test_dependence, build_rdg_all_levels,
6112 dump_dependence_graph): Removed until this code is cleaned up
6114 * Makefile.in (POLYLIBLIBS): Renamed PPLLIBS.
6115 (POLYLIBINC): Renamed PPLINC.
6117 2008-08-01 Harsha Jagasia <harsha.jagasia@amd.com>
6118 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
6119 Jan Sjodin <jan.sjodin@amd.com>
6121 Finish the merge and tuplification of graphite.
6123 2008-07-24 Sebastian Pop <sebastian.pop@amd.com>
6124 Jan Sjodin <jan.sjodin@amd.com>
6126 Partial merge from mainline (138072:138275).
6127 * graphite.c still has to be tuplified.
6129 2008-07-29 Jan Sjodin <jan.sjodin@amd.com>
6131 * graphite.c (graphite_loops_mapping_max_loop_num): New.
6132 (create_num_from_index): New.
6133 (get_num_from_index): Also pass in the graphite BB.
6134 (free_graphite_bb): Free GBB_INDEX_TO_NUM_MAP.
6135 (build_graphite_bb): Initialize GBB_INDEX_TO_NUM_MAP.
6136 (graphite_trans_bb_strip_mine): Call create_num_from_index.
6137 (is_interchange_valid): Return false when failing.
6138 * graphite.h (struct num_map): New.
6139 (struct graphite_bb): New field num_map.
6140 (GBB_LOOPS_MAPPING): Renamed GBB_INDEX_TO_NUM_MAP.
6142 2008-07-29 Tobias Grosser <grosser@fim.uni-passau.de>
6144 * graphite.c (dump_gbb_conditions): Print also conditions like
6145 "if (a)". Remove dublicated code and use print_generic_expr ().
6146 (stmt_simple_for_scop_p): Only allow conditions we can handle
6149 2008-07-25 Jan Sjodin <jan.sjodin@amd.com>
6151 * graphite.h (struct scop): Removed new_ivs field.
6152 (SCOP_NEWIVS): Deleted.
6153 * graphite.c (new_scop, free_scop, clast_name_to_gcc,
6154 clast_to_gcc_expression, graphite_create_new_loop):
6155 Removed use of new_ivs.
6157 2008-07-25 Jan Sjodin <jan.sjodin@amd.com>
6159 * graphite.c (debug_oldivs, debug_loop_vec, create_loops_mapping,
6160 create_loops_mapping_num, debug_loop_mapping_1): New.
6161 (debug_loop_mapping): Call debug_loop_mapping_1.
6162 (get_loop_mapping_for_num,
6163 graphite_loops_mapping_add_child,
6164 graphite_loops_mapping_add_child_num,
6165 graphite_loops_mapping_insert_child,
6166 graphite_loops_mapping_parent,
6167 split_loop_mapped_depth_for_num,
6168 loop_mapped_depth_split_loop): New.
6169 (increment_loop_mapped_depths): Removed.
6170 (swap_loop_mapped_depth_for_num): Reimplemented.
6171 (new_scop): Call create_loops_mapping.
6172 (scop_record_loop): Call graphite_loops_mapping_insert_child.
6173 (translate_clast): Pass the old loop father in parameter, and pass
6174 it to get_old_iv_from_ssa_name.
6175 (remove_edges_around_useless_blocks, can_generate_code_stmt,
6176 can_generate_code, can_generate_for_scop): New.
6177 (graphite_trans_bb_block): Returns false when it fails to transform.
6178 * graphite.h (graphite_loop_node, graphite_loops_mapping): New.
6180 2008-07-25 Sebastian Pop <sebastian.pop@amd.com>
6182 Reverted all the changes related to the streamization and
6184 These changes are now tracked in the streamization branch.
6186 2008-07-25 Sebastian Pop <sebastian.pop@amd.com>
6187 Jan Sjodin <jan.sjodin@amd.com>
6189 * graphite.c (gbb_compare): Correctly constify.
6190 (gbb_can_be_ignored): Indent.
6191 (graphite_trans_scop_swap_1and2): Add legality check.
6194 2008-07-25 Sebastian Pop <sebastian.pop@amd.com>
6196 Remove fallouts from "Reverted the Condate changes".
6197 * tree.h: Remove unused decl.
6198 * gcc.dg/tree-checker: Same.
6199 * timevar.def: Remove counter.
6201 2008-07-24 Sebastian Pop <sebastian.pop@amd.com>
6203 * Merge from mainline (135673:138072).
6205 Reverted the MIRO changes (from 2008-04-05) that are now
6206 tracked in the miro branch.
6207 * tree-bounds.c: Removed.
6208 * tree-bounds.h: Removed.
6210 Reverted the Condate changes (from 2006-07-04, 2007-03-20) that
6211 are now tracked in the condate branch.
6212 * tree-check.c: Removed.
6213 * tree-match.c: Removed.
6214 * condate.y: Removed.
6216 2008-07-24 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
6218 * common.opt: New user flag -floop-block, -floop-strip-mine
6219 and -floop-interchange.
6220 * toplev.c (process_options): Enable -fgraphite pass if any one of the
6221 graphite loop optimization flags is turned on.
6222 * graphite.c (graphite_apply_transformations): Add flag_loop_block,
6223 flag_loop_strip_mine and flag_loop_interchange checks before
6225 * doc/invoke.texi: Remove -fgraphite and add -floop-block,
6226 -floop-strip-mine and -floop-interchange.
6227 * gcc.dg/graphite/block-0.c: Add -floop-block and remove
6229 * gcc.dg/graphite/scop-16.c: Ditto.
6230 * gcc.dg/graphite/scop-17.c: Ditto.
6231 * gcc.dg/graphite/scop-18.c: Ditto.
6233 2008-07-23 Jan Sjodin <jan.sjodin@amd.com>
6234 Sebastian Pop <sebastian.pop@amd.com>
6236 * cfgloopmanip.c (update_dominators_in_loop): Make it static.
6237 (create_empty_loop_on_edge): More fixes.
6238 * tree-phinodes.c (resize_phi_node): Extern.
6239 (unlink_phi_node, move_phi_node): New split from remove_phi_node.
6240 * cfghooks.c (update_dominator_information): New split from
6242 * tree-vectorizer.c (rename_variables_in_bb): Extern.
6243 * tree-dfa.c (collect_dfa_stats): Start walking the CFG on the
6244 successor of the function entry block.
6246 * graphite.c: Include pointer-set.h.
6247 (debug_loop_mapping, increment_loop_mapped_depths,
6248 get_loop_mapped_depth_for_num, get_loop_mapped_depth,
6249 set_loop_mapped_depth_for_num, set_loop_mapped_depth,
6250 swap_loop_mapped_depth_for_num, get_num_from_index,
6251 swap_loop_mapped_depth, loop_iv_stack_debug,
6252 loop_iv_stack_push, loop_iv_stack_pop, loop_iv_stack_get_iv,
6253 loop_iv_stack_get_iv_from_name, loop_iv_stack_debug,
6254 get_old_iv_from_ssa_name): New.
6255 (new_scop): Initialize SCOP_LOOPS_MAPPING.
6256 (free_scop): Free SCOP_LOOPS_MAPPING.
6257 (scop_record_loop): Record old ivs.
6258 (create_var_name): Removed.
6259 (initialize_cloog_names): Allocate double space in case strip mine
6260 applies to all loops once.
6261 (clast_name_to_gcc): Look up in the map ivstack passed in parameter.
6262 (clast_to_gcc_expression): Same. Implement more clast to gimple
6264 (graphite_create_new_loop): Pass in ivstack.
6265 (remove_all_edges): Pass in the construction_edge.
6266 (graphite_remove_iv): Removed.
6267 (graphite_rename_ivs, graphite_rename_ivs_stmt,
6268 remove_cond_exprs): Rewritten.
6269 (move_phi_nodes): New.
6270 (disconnect_virtual_phi_nodes, disconnect_cond_expr): Removed.
6271 (translate_clast): Pass in ivstack. Rewrite some cases.
6272 (set_cloog_options, debug_clast_stmt): New.
6273 (find_transform): Use set_cloog_options.
6274 (outermost_loop_layer): Removed.
6275 (get_construction_edge, collect_virtual_phis, find_vdef_for_var_in_bb,
6276 find_vdef_for_var_1, find_vdef_for_var, patch_phis_for_virtual_defs,
6277 mark_old_loops, remove_dead_loops): New.
6279 (graphite_trans_bb_move_loop): Call swap_loop_mapped_depth.
6280 (const_column_index, get_first_matching_sign_row_index,
6281 get_lower_bound_row, get_upper_bound_row, get_lower_bound,
6282 get_upper_bound): New.
6283 (graphite_trans_bb_strip_mine): Also update the iv map.
6285 * graphite.h (graphite_loops_mapping, GBB_LOOPS_MAPPING): New.
6286 (struct name_tree): Add a loop field.
6287 (struct scop): Add a graphite_loops_mapping field.
6288 (SCOP_LOOPS_MAPPING): New.
6289 (debug_clast_stmt): Declare.
6290 * lambda.h (find_induction_var_from_exit_cond): Declare.
6291 (lambda-code.c): (find_induction_var_from_exit_cond): Extern.
6292 * cfgloop.h (update_dominators_in_loop): Removed declaration.
6293 (create_empty_loop_on_edge): Updated.
6294 * tree-flow.h (remove_bb, resize_phi_node, move_phi_node,
6295 rename_variables_in_bb): Declare.
6296 * tree-cfg.c (remove_bb): Extern.
6298 * gcc.dg/graphite/block-0.c: New.
6300 2008-07-21 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
6301 Sebastian Pop <sebastian.pop@amd.com>
6303 * graphite.c (strip_mine_profitable_p): New.
6304 (graphite_trans_bb_block): Disable strip mining if not profitable.
6306 * gcc.dg/graphite/scop-18.c: New.
6307 * gcc.dg/graphite/scop-17.c: Fixed.
6308 * gcc.dg/graphite/scop-16.c: Fixed.
6310 2008-07-17 Harsha Jagasia <harsha.jagasia@amd.com>
6311 Jan Sjodin <jan.sjodin@amd.com>
6312 Sebastian Pop <sebastian.pop@amd.com>
6314 * graphite.c (is_interchange_valid): New.
6315 (graphite_trans_bb_block): Check loop nest of basic block for legality
6318 * graphite.h (gbb_inner_most_loop_index, outer_most_loop_1,
6319 outer_most_loop, gbb_outer_most_loop_index): New.
6321 * tree-loop-linear.c (perfect_loop_nest_depth): Remove static.
6322 * tree-flow.h (perfect_loop_nest_depth): Declare as extern.
6323 * gcc.dg/graphite/scop-16.c: New.
6324 * gcc.dg/graphite/scop-17.c: New.
6326 2008-07-11 Tobias Grosser <grosser@fim.uni-passau.de>
6328 * graphite.c (scop_remove_ignoreable_gbbs): Also update bitmap.
6329 (graphite_trans_scop_block): Ignore SCoPs without bbs.
6331 2008-07-11 Tobias Grosser <grosser@fim.uni-passau.de>
6333 * graphite.c (new_scop): Initialize SCOP_EXIT.
6334 (scopdet_info): Add.
6335 (scopdet_bb_info): Rename from is_bb_addable. Cleanup, bugfixes.
6336 (build_scops_1): Cleanup, bugfixes.
6337 (build_scops): Cleanup.
6339 * gcc.dg/graphite/scop-matmult.c: Remove duplicated code.
6340 * gcc.dg/graphite/scop-15.c: Add SCoP numbers.
6342 2008-07-10 Harsha Jagasia <harsha.jagasia@amd.com>
6344 * gfortran.dg/graphite/scop-1.f: Update to reduced test case.
6346 * gfortran.dg/graphite/graphite.exp: Use
6347 DEFAULT_GRAPHITE_FLAGS.
6349 * gcc.dg/graphite/scop-15.c: Update to reduced test case.
6351 2008-07-10 Harsha Jagasia <harsha.jagasia@amd.com>
6353 * graphite.c (scan_tree_for_params): Do not assert any more if
6354 MULT_EXPR parameter is negative.
6356 * gfortran.dg/graphite/scop-1.f: New.
6358 * gfortran.dg/graphite/graphite.exp: New.
6360 * gcc.dg/graphite/scop-15.c: New.
6362 2008-07-10 Harsha Jagasia <harsha.jagasia@amd.com>
6364 * graphite.c (is_bb_addable): Fix segfault in spec gzip and reformat.
6366 2008-07-10 Tobias Grosser <grosser@fim.uni-passau.de>
6368 * graphite.c (graphite_trans_bb_swap_loops): Rename from
6369 graphite_swap_loops.
6370 (graphite_trans_bb_move_loop): New.
6371 (graphite_trans_bb_strip_mine): Rename from graphite_strip_mine_loop.
6372 (graphite_trans_bb_block): New.
6373 (graphite_trans_loop_block): New.
6374 (graphite_trans_scop_swap_1and2): Rename from
6375 graphite_trans_swap_1and2.
6376 (graphite_trans_scop_strip): Rename from graphite_trans_strip.
6377 (graphite_trans_scop_block): New.
6378 (graphite_apply_transformations): Rename from
6379 graphite_transformations.
6381 * gcc.dg/graphite/scop-matmult.c: New.
6383 2008-07-10 Tobias Grosser <grosser@fim.uni-passau.de>
6385 * graphite.c (gbb_compare): New.
6386 (graphite_sort_gbbs): New.
6387 (gbb_can_be_ignored): New.
6388 (scop_remove_ignoreable_gbbs): New.
6389 (graphite_transformations): Cleanup and add
6390 scop_remove_ignoreable_gbbs.
6391 * lambda.h (lambda_vector_compare): New.
6393 2008-07-09 Tobias Grosser <grosser@fim.uni-passau.de>
6395 * graphite.c (print_graphite_bb): Correct printing of static schedule.
6396 (graphite_swap_loops): int -> unsigned
6397 (graphite_strip_mine_loop): int -> unsigned, Fix SCHEDULE
6398 (graphite_transformations): New.
6399 (graphite_transform_loops): Move to graphite_transformations.
6400 * graphite.h (gbb_nb_loops): Return unsigned.
6402 2008-07-04 Tobias Grosser <grosser@fim.uni-passau.de>
6404 * graphite.c (scan_tree_for_params): Fix insertion of parameters into
6405 the domain matrix. This makes scop-0.c work again.
6407 2008-06-20 Richard Guenther <rguenther@suse.de>
6409 * graphite.h: Adjust copyright to GPLv3.
6410 * graphite.c: Likewise.
6411 (stmt_simple_memref_for_scop_p): Split out from ...
6412 (stmt_simple_for_scop_p): ... here. Fix handling of calls
6414 (get_bb_type): Optimize.
6416 (is_bb_addable): Fix memleak, replace is_pred call with
6418 (build_scops): Use current_loops.
6419 (param_index): Fix memleak.
6421 2008-06-20 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6423 * graphite.c: Fix formatting.
6425 2008-06-19 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6427 * graphite.c (new_scop): Memory allocation for SCOP_{NEWIVS, OLDIVS}.
6428 (free_scop): Memory deallocation for SCOP_NEWIVS, SCOP_OLDIVS.
6429 (create_var_name, save_var_name): Newly defined functions.
6430 (initialize_cloog_names): Part of the code factored out to
6432 (clast_to_gcc_expression): Now handles the case of clast_red_sum
6433 in clast_reduction statement.
6434 (graphite_create_new_loop): Now takes a new parameter
6436 (translate_clast): Now also takes the context_loop and bb_exit
6437 parameters. Rewritten the code so that it creates a gimple code
6438 inside the given context.
6439 (outermost_loop_layer, graphite_remove_iv, graphite_rename_ivs,
6440 remove_cond_expr, disconnect_cond_expr,
6441 disconnect_virtual_phi_nodes): Newly defined functions.
6442 * graphite.h (struct scop): added old_ivs vector.
6443 SCOP_OLDIVS: New macro.
6445 2008-06-19 Sebastian Pop <sebastian.pop@amd.com>
6447 * cfgloopmanip.c: Add missing function comments, fix formatting.
6449 2008-06-18 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6451 * cfgloopmanip.c (update_dominators_in_loop): Defined.
6452 (create_empty_loop_on_edge): Defined.
6453 * tree-parloops.c (canonicalize_loop_ivs): Returns tree
6455 * cfgloop.h (create_empty_loop_on_edge): Declared as extern.
6456 (update_dominators_in_loop): Declared as extern
6457 * tree-flow.h (canonicalize_loop_ivs): Declared as extern.
6459 2008-06-16 Tobias Grosser <grosser@fim.uni-passau.de>
6461 * graphite.c (print_graphite_bb): Allow changing number of loops
6463 (initialize_cloog_names): Allow changing number of loops.
6464 (build_cloog_prog): Simplify.
6465 (find_transform): Enable cloog option --strides.
6466 (graphite_swap_loops): New.
6467 (graphite_strip_mine_loop): New.
6468 (graphite_trans_swap_1and2): New.
6469 (graphite_trans_strip): New.
6470 (graphite_transform_loops): Add graphite_trans_strip.
6471 * graphite.h (scop_max_loop_depth): New.
6473 2008-06-15 Tobias Grosser <grosser@fim.uni-passau.de>
6475 * graphite.c (build_scop_iteration_domain): Remove forgotten
6476 line. (Fixes compile)
6478 2008-06-15 Tobias Grosser <grosser@fim.uni-passau.de>
6480 * graphite.c (print_graphite_bb): Add output of GBB_LOOPS.
6481 (build_graphite_bb): Add GBB_LOOPS and GBB_DOMAIN and reorder.
6482 (build_bb_loops): New.
6483 (graphite_transform_loops): Add build_bb_loops.
6484 (schedule_to_scattering): Use gbb_nb_loops to support changing loop
6486 * graphite.h (graphite_bb): Add loops.
6487 (gbb_nb_loops): New.
6488 (gbb_loop_at_index): New.
6489 (gbb_loop_index): New.
6490 (nb_params_in_scop): Renamed to scop_nb_params. Updated all functions
6491 using nb_params_in_scop.
6493 2008-06-14 Tobias Grosser <grosser@fim.uni-passau.de>
6495 * graphite.c (print_graphite_bb): Adapt to minimized schedule.
6496 (build_scop_canonical_schedules): Build minimized schedule.
6497 (schedule_to_scattering): Adapt to minimized schedule.
6498 * graphite.h (graphite_bb): Add/Update descriptions.
6500 2008-06-14 Adrien Eliche <aeliche@isty.uvsq.fr>
6501 Tobias Grosser <grosser@fim.uni-passau.de>
6503 * graphite.c (print_graphite_bb): Add condition printing.
6505 (dump_gbb_conditions): New.
6506 (build_scop_conditions_1): New.
6507 (build_scop_conditions): New.
6508 * graphite.h (graphite_bb): Add conditions.
6510 2008-06-14 Tobias Grosser <grosser@fim.uni-passau.de>
6512 * graphite.c (print_graphite_bb):
6513 (free_graphite_bb): New.
6514 (free_scop): Free bbs.
6515 (get_bb_type): Free doms.
6516 (build_scop_context): Free context matrix.
6517 (build_loop_iteration_domains): Remove unused code.
6518 (build_cloog_prog): Free scattering function and blocklist.
6519 (find_transform): Free options.
6521 2008-06-13 Tobias Grosser <grosser@fim.uni-passau.de>
6523 * graphite.c (loop_body_to_cloog_stmts): Rename to add_bb_domains.
6524 Remove unnecessery cloog data structures. Make a copy of the domain
6525 (setup_cloog_loop): Rename to build_loop_iteration_domains. Remove
6526 unnecessary cloog data structures. Fix memory leaks. Remove insert
6527 into SCOP_LOOP2CLOOG_LOOP as the inserted CloogLoops will never be
6529 (build_scop_iteration_domain): Remove unnecessary cloog
6530 data structures. Fix memory leaks.
6531 (graphite_transform_loops): Disable build_scop_dynamic_schedules as it
6532 uses SCOP_LOOP2CLOOG_LOOP, that is at the moment not working.
6534 2008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
6536 * graphite.c (find_scop_params): Remove initialize_cloog_names.
6538 2008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
6540 * graphite.c (end_scop): Style fix.
6541 (schedule_to_scattering): Style and comment fix.
6543 2008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
6544 * graphite.c (print_graphite_bb): Fix definiton of
6545 schedule_to_scattering.
6546 (initialize_cloog_names): Change nb_scattdims to max loop
6548 (schedule_to_scattering): Take parameter for number of scattering
6550 (build_cloog_prog): Only build as much scattering dimensions as
6553 2008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
6555 * graphite.c (end_scop): Disable bb splitting. Fixes SIGSEGV
6556 in polyhedron/aermod.f90.
6558 2008-06-11 Tobias Grosser <grosser@fim.uni-passau.de>
6559 Dwarak Rajagopal <dwarak.rajagopal@amd.com>
6560 Harsha Jagasia <harsha.jagasia@amd.com>
6562 * graphite.c (is_bb_addable): Fix segfault.
6564 2008-06-10 Tobias Grosser <grosser@fim.uni-passau.de>
6566 * graphite.c (is_bb_addable): Fix memory leak, handling of loops
6567 with multiple exits and conditional handling in edge cases.
6568 (is_loop_exit): Fix memory leak. (Forgotten in last commit)
6570 * gcc.dg/graphite/scop-14.c: New.
6572 2008-06-06 Tobias Grosser <grosser@fim.uni-passau.de>
6573 Adrien Eliche <aeliche@isty.uvsq.fr>
6575 * graphite.c (is_bb_addable): Add more comments and enhance
6576 readablity of the source code. Fix memory leak.
6577 (is_loop_exit): Fix memory leak.
6579 2008-06-05 Tobias Grosser <grosser@fim.uni-passau.de>
6581 * graphite.c (first_loop_in_scop): Deleted.
6582 (setup_cloog_loop): Only walk the loop chain for inner loops.
6583 (build_scop_iteration_domain): Execute setup_cloog_loop for
6584 all loops in the first layer.
6586 2008-06-05 Tobias Grosser <grosser@fim.uni-passau.de>
6588 * graphite.c (scan_tree_for_params): Change the way params are
6589 added to be indepenent of the number of loops.
6590 (setup_cloog_loop): Revert to short matrix format. Fix parameter
6592 (build_cloog_prog): Revert to short matrix format.
6594 2008-06-05 Sebastian Pop <sebastian.pop@amd.com>
6595 Dwarak Rajagopal <dwarak.rajagopal@amd.com>
6597 * tree-loop-fusion.c (fuse_loops): Fix uninitialized variable
6600 2008-06-05 Sebastian Pop <sebastian.pop@amd.com>
6602 * graphite.c (nb_data_refs_in_scop): New.
6603 (graphite_transform_loops): Print more stats: number of
6604 loops, basic blocks and data references per scop.
6606 2008-06-04 Sebastian Pop <sebastian.pop@amd.com>
6607 Jan Sjodin <jan.sjodin@amd.com>
6609 * graphite.c (loop_affine_expr, idx_record_params,
6610 find_scop_parameters, setup_cloog_loop): Use instantiate_scev
6611 instead of instantiate_parameters.
6613 2008-06-04 Tobias Grosser <grosser@fim.uni-passau.de>
6615 * graphite.c (schedule_to_scattering): Fix scattering dimensions,
6616 add support for parameters, add STATIC_SCHEDULE at the right places,
6619 2008-06-04 Tobias Grosser <grosser@fim.uni-passau.de>
6621 * graphite.c (build_scop_loop_nests): Only add the loops, that
6622 are contained completely in the SCoP.
6623 (build_cloog_prog): Disable scattering, until schedule_to_scattering
6624 and the domains are fixed.
6625 (build_scop_canonical_schedules): Add support for bbs not contained
6628 2008-06-04 Tobias Grosser <grosser@fim.uni-passau.de>
6630 * graphite.h (scop_contains_loop): Update comments to match
6631 the actual behavior.
6632 (scop_contains_loop): New.
6633 * graphite.c (schedule_to_scattering): Use scop_contains_loop.
6635 2008-06-04 Sebastian Pop <sebastian.pop@amd.com>
6637 * graphite.c (get_bb_type): On function body, i.e. loop_0,
6638 don't mark blocks as GBB_LOOP_SING_EXIT_HEADER, mark them
6641 2008-06-04 Sebastian Pop <sebastian.pop@amd.com>
6642 Tobias Grosser <grosser@fim.uni-passau.de>
6644 * graphite.c (graphite_transform_loops): Early return when
6645 there are no loops in the function.
6647 2008-05-31 Sebastian Pop <sebastian.pop@amd.com>
6648 Jan Sjodin <jan.sjodin@amd.com>
6650 * graphite.c (scan_tree_for_params, setup_cloog_loop): Compute the
6651 offset of the last loop.
6652 (setup_cloog_loop): Copy the entire outer constraint matrix.
6654 2008-05-31 Sebastian Pop <sebastian.pop@amd.com>
6655 Jan Sjodin <jan.sjodin@amd.com>
6657 * graphite.c (stmt_in_scop_p, function_parameter_p,
6658 invariant_in_scop_p): Removed.
6659 (scan_tree_for_params): Can be used with no constraint
6660 matrix for gathering parameters.
6661 (idx_record_params): Don't use idx_record_param, instead use
6662 scan_tree_for_params.
6663 (find_scop_parameters): Same.
6664 (setup_cloog_loop, build_scop_iteration_domain, build_cloog_prog):
6665 Fix the size of loop domains.
6666 (schedule_to_scattering): Exit when the outer loop is not in scop.
6667 (find_transform): Enable build_cloog_prog.
6669 2008-05-31 Sebastian Pop <sebastian.pop@amd.com>
6670 Jan Sjodin <jan.sjodin@amd.com>
6672 * graphite.c (schedule_to_scattering): Make scattering domains
6673 uniformly of the same size, as required by CLooG 0.14.0 and before.
6675 2008-05-31 Sebastian Pop <sebastian.pop@amd.com>
6676 Jan Sjodin <jan.sjodin@amd.com>
6678 * graphite.c (schedule_to_scattering): Rewrite, correct the
6679 translation of the scheduling function to scattering.
6680 (build_cloog_prog): Call schedule_to_scattering only once.
6681 * graphite.h (scop_loop_index): Do not fail for loops not
6682 in the scop: return -1.
6684 2008-05-30 Tobias Grosser <grosser@fim.uni-passau.de>
6686 * graphite.c (build_graphite_bb): Initialize GBB_DOMAIN.
6687 (loop_body_to_cloog_stmts): Export GBB_DOMAIN.
6688 (setup_cloog_loop): Export GBB_DOMAIN.
6689 (build_cloog_prog): New. Create new CLOOG_PROG, which should be
6690 able to rebuild the original control flow.
6691 * graphite.h (graphite_bb): Add domain field and access macro.
6694 2008-05-30 Sebastian Pop <sebastian.pop@amd.com>
6696 * graphite.c (debug_gbb): New.
6697 (print_scop, build_graphite_bb): Use SCOP_BBS.
6698 (build_scop_bbs): Reimplemented.
6699 (dfs_bb_in_scop_p): Removed.
6700 (build_scop_loop_nests): Reorder loops inserted in
6701 SCOP_LOOP_NEST: outer loops should come first.
6702 (build_scop_canonical_schedules): Reinitialize at zero
6703 the components of the SCOP_STATIC_SCHEDULE for the loops
6704 that have already been parsed.
6706 * graphite.h (debug_gbb): Declared.
6708 2008-05-30 Sebastian Pop <sebastian.pop@amd.com>
6709 Jan Sjodin <jan.sjodin@amd.com>
6711 * graphite.c (create_empty_loop): Renamed graphite_create_new_loop.
6712 (graphite_loop_to_gcc_loop): Removed.
6713 (remove_all_edges): New.
6714 (graphite_stmt_to_gcc_stmt): Renamed translate_clast.
6715 (gloog): Remove useless code.
6717 2008-05-29 Tobias Grosser <grosser@fim.uni-passau.de>
6719 * graphite.c (get_bb_type): Reworked. We distinguish between
6720 loops with one or multiple exits.
6721 (is_loop_exit): New.
6723 (is_bb_addable): Rework condition handling, now support for case
6724 case statements and loops with multiple exits.
6726 * gcc.dg/graphite/scop-11.c: New.
6727 * gcc.dg/graphite/scop-12.c: New.
6728 * gcc.dg/graphite/scop-13.c: New.
6730 2008-05-29 Tobias Grosser <grosser@fim.uni-passau.de>
6732 * graphite.c (dot_all_scops_1): Fix some colors. Reuse colors, if
6733 we have too many colors.
6735 2008-05-22 Sandeep Maram <smaram_b04@iiita.ac.in>
6737 * doc/invoke.texi (-ftree-loop-fusion): Document.
6738 * tree-pass.h (pass_loop_fusion): Declared.
6739 * tree-loop-fusion.c: New.
6740 * timevar.def (TV_TREE_LOOP_FUSION): Declared.
6741 * tree-data-ref.c (find_data_references_in_loop): Make extern.
6742 * tree-data-ref.h (find_data_references_in_loop): Declared.
6743 * common.opt (ftree-loop-fusion): Declared.
6744 * Makefile.in (tree-loop-fusion.o): Added rule and to OBJS-common.
6746 2008-05-21 Sebastian Pop <sebastian.pop@amd.com>
6748 * graphite.c (build_access_matrix): Fix typo from the merge.
6750 2008-05-20 Sebastian Pop <sebastian.pop@amd.com>
6752 * Merge from mainline (130800:135673).
6754 2008-05-07 Sebastian Pop <sebastian.pop@amd.com>
6756 * graphite.c (end_scop): The exit of the scop is not part of the scop.
6757 Update dominators after splitting.
6759 2008-05-07 Sebastian Pop <sebastian.pop@amd.com>
6761 * graphite.c (is_bb_addable): Return the harmful statement.
6762 Factor up some code.
6763 (end_scop): New. Splits end of scope bbs on a harmful statement.
6764 (build_scops_1): Call end_scop.
6766 2008-05-07 Sebastian Pop <sebastian.pop@amd.com>
6768 * graphite.c: (succs_at_same_depth, end_scop, all_preds_visited_p,
6769 all_succs_visited_p, start_new_scop_for_each_succ, start_new_scop,
6770 add_dominators_to_open_scops, stop_last_open_scop, scop_end_loop,
6771 build_scops_1): Removed.
6772 (build_scops_2): Renamed build_scops_1.
6774 2008-05-06 Sebastian Pop <sebastian.pop@amd.com>
6776 * graphite.c: Fix formatting.
6778 2008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
6780 * graphite.c (get_bb_type): New.
6782 (build_scops_2): New.
6783 (is_bb_addable): New.
6784 (build_scops): Switch the scop detection.
6785 (build_scop_bbs): Add entry bb to scop.
6786 * graphite.h (struct scop): Update comment.
6788 2008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
6790 * graphite.c (dot_all_scops_1): Fix some incorrect colors and add
6793 2008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
6795 * gcc.dg/graphite/scop-1.c: Update.
6796 * gcc.dg/graphite/scop-2.c: Update.
6797 * gcc.dg/graphite/scop-4.c: Update.
6798 * gcc.dg/graphite/scop-5.c: Add.
6799 * gcc.dg/graphite/scop-6.c: Add.
6801 2008-05-06 Sebastian Pop <sebastian.pop@amd.com>
6803 * gcc.dg/graphite/scop-0.c: Add.
6804 * gcc.dg/graphite/scop-7.c: Add.
6805 * gcc.dg/graphite/scop-8.c: Add.
6806 * gcc.dg/graphite/scop-9.c: Add.
6807 * gcc.dg/graphite/scop-10.c: Add.
6809 2008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
6811 * graphite.c (scop_affine_expr): Renamed to loop_affine_expr.
6812 Check affine expressions depending on the outermost loop
6814 (stmt_simple_for_scop_p): Same.
6815 (harmfule_stmt_in_scop): Same.
6817 2008-04-28 Tobias Grosser <grosser@fim.uni-passau.de>
6819 * graphite.c (dot_all_scops): Remove incorrect difficult bb coloring,
6820 mark entry and exit, that are not part of the SCoP and update HTML
6823 2008-04-25 Sebastian Pop <sebastian.pop@amd.com>
6825 * graphite.c (basic_block_simple_for_scop_p): Renamed
6827 (save_scop, preds_at_same_depth, test_for_scop_bound): Removed.
6828 (add_dominators_to_open_scops, build_scops_1): Reimplemented.
6829 (all_preds_visited_p, all_succs_visited_p,
6830 start_new_scop_for_each_succ, start_new_scop, stop_last_open_scop,
6831 scop_end_loop): New.
6832 (build_scops): Do not use dfs_enumerate_from.
6834 * gcc.dg/graphite/scop-{1,2,4}.c: Updated.
6836 2008-04-23 Sebastian Pop <sebastian.pop@amd.com>
6838 * graphite.c: Add comments to functions that are missing a
6840 (graphite_create_iv): Removed. Merged in graphite_loop_to_gcc_loop.
6842 2008-04-23 Sebastian Pop <sebastian.pop@amd.com>
6844 * graphite.c (nb_params_in_scop): Moved...
6845 (graphite_bb_from_bb, loop_body_to_cloog_stmts): New.
6846 (setup_cloog_loop): Call loop_body_to_cloog_stmts.
6847 (clast_to_gcc_expression): Reduce column size to less than 80.
6848 (graphite_create_iv): Return the new name of the IV.
6849 (find_transform): Set options->esp and options->cpp.
6850 (gloog): Comment out the invalidation of the old loop code.
6851 (initialize_dependence_polyhedron): Replace scop_nb_params with
6854 * graphite.h (nb_params_in_scop): ... here.
6855 (scop_nb_params): Removed.
6856 (loop_domain_dim): Return something even when the loop was not
6857 found in the hash table: avoid ICEing on all the graphite.exp
6860 2008-04-14 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6862 * tree-chrec.c (for_each_scev_op): SCEV can have 3 operands.
6864 * graphite.c (build_scop_dynamic_schedules): Schedule is built
6865 according to nesting level.
6866 (find_scop_parameters): Call instantiate_parameters.
6867 (scan_tree_for_params): Extend it to handle general affine bounds.
6868 Inner loop bound can depend on outer loop induction variable.
6869 (setup_cloog_loop): tmp variable is allocated on stack. Call
6870 instantiate_parameters with respect to outermost_loop_in_scop.
6871 (loop_domain_dim, ref_nb_loops, loop_iteration_vector_dim): moved to
6873 (create_empty_loop): Function loopify should be given edge
6874 probability, instead of edge frequency. Dominance relation from
6875 switch_bb to loop_header.
6876 (clast_to_gcc_expression): Added handling of clast_reduction node.
6877 (gloog): New functionality for removing old loop.
6878 (test_dependence): Factored out from build_rdg_all_levels.
6879 (build_rdg_all_levels): Dependence testing factored out to
6880 test_dependence function.
6882 * graphite.h (struct graphite_bb): Extended with dynamic_schedule.
6883 (loop_domain_dim, ref_nb_loops, loop_iteration_vector_dim): Moved
6886 2008-04-07 Sebastian Pop <sebastian.pop@amd.com>
6888 * graphite.c (free_scop, param_index, initialize_cloog_names,
6889 nb_params_in_scop): Use name_tree map instead of just a tree
6890 for keeping track of the variable name associated to that tree.
6891 (create_empty_loop, gmp_cst_to_tree, clast_name_to_gcc,
6892 clast_to_gcc_expression, graphite_create_iv,
6893 graphite_loop_to_gcc_loop, graphite_cond_to_gcc_cond,
6894 graphite_stmt_to_gcc_stmt): New.
6895 (gloog): Call these.
6896 * graphite.h (struct name_tree): New.
6897 (struct scop): Use name_tree instead of tree for params.
6898 Store a vector of name_tree for new_ivs.
6900 (scop_nb_params): Use name_tree instead of tree.
6902 2008-04-05 Alexander Lamaison <awl03@doc.ic.ac.uk>
6903 Sebastian Pop <sebastian.pop@amd.com>
6905 * tree-bounds.c: New.
6906 * tree-bounds.h: New.
6907 * tree-pass.h: Declare pass_bounds_early and pass_bounds_late.
6908 * passes.c: Schedule pass_bounds_early, pass_bounds_late.
6909 * builtins.c (expand_builtin_alloca): Add flag_bounds as for
6913 * c-cppbuiltin.c: Same.
6917 * tree-outof-ssa.c: Same.
6919 * Makefile.in: Same.
6921 2008-03-15 Antoniu Pop <antoniu.pop@gmail.com>
6922 Sebastian Pop <sebastian.pop@amd.com>
6924 * tree-loop-distribution.c (remaining_stmts,
6925 upstream_mem_writes): Removed static variables.
6926 (copy_loop_before, create_bb_after_loop,
6927 mark_nodes_having_upstream_mem_writes, free_rdg_components,
6928 rdg_build_components, rdg_build_partitions,
6929 dump_rdg_partitions): Extern.
6930 (generate_loops_for_partition, generate_code_for_partition): Do not
6932 (already_processed_vertex_p, predecessor_has_mem_write,
6933 mark_nodes_having_upstream_mem_writes, has_upstream_mem_writes,
6934 rdg_flag_all_uses, rdg_flag_uses, rdg_flag_vertex_and_dependent,
6935 rdg_flag_loop_exits, rdg_flag_similar_memory_accesses,
6936 build_rdg_partition_for_component, rdg_build_partitions, ldist_gen):
6937 Pass remaining_stmts and upstream_mem_writes as parameters.
6938 (rdg_component): Moved...
6939 (build_rdg_partition_for_component): Do not aggregate components when
6940 flag_streamize_loops is set.
6941 (gen_sequential_loops): New.
6942 (ldist_gen): Call gen_sequential_loops.
6944 * tree-pass.h (pass_loop_streamization): Declared.
6946 * omp-low.c (expand_omp_sections): Call add_bb_to_loop on created
6947 basic blocks when loops structures exist.
6949 * builtin-types.def (BT_FN_VOID_PTR_PTR_INT): New.
6951 * tree-ssa-loop-ivopts.c (expr_invariant_in_region_p): New.
6953 * tree-parloops.c (take_address_of, eliminate_local_variables_1,
6954 eliminate_local_variables_stmt, eliminate_local_variables,
6955 separate_decls_in_loop_name, separate_decls_in_loop_stmt,
6956 separate_decls_in_loop, gen_parallel_loop): Make them work on a region
6957 of code delimited by two edges in the CFG.
6958 (separate_decls_in_loop_name): Renamed separate_decls_in_region_name.
6959 (separate_decls_in_loop_stmt): Renamed separate_decls_in_region_stmt.
6960 (separate_decls_in_loop): Renamed separate_decls_in_region. Isolate
6961 the case of parallelisation of reductions.
6962 (create_loop_fn): Extern.
6963 (create_omp_parallel_region): New.
6965 * tree-data-ref.c (dump_data_dependence_relation): Don't call
6966 dump_data_reference for printing dra and drb.
6967 (create_rdg_edge_for_ddr, create_rdg_edges_for_scalar): Initialise
6969 (build_rdg): Don't call free_dependence_relations for the moment, as
6970 we attach dependence relations on each edge of the RDG.
6973 * tree-data-ref.h (rdg_component): ...here.
6974 (struct rdg_edge): New field ddr_p relation.
6975 (RDGE_RELATION): New.
6976 (create_bb_after_loop, copy_loop_before,
6977 mark_nodes_having_upstream_mem_writes, rdg_build_components,
6978 rdg_build_partitions, dump_rdg_partitions,
6979 free_rdg_components): Declared.
6981 * omp-builtins.def (BUILT_IN_GOMP_STREAM_ALIGN_PUSH,
6982 BUILT_IN_GOMP_STREAM_ALIGN_POP): New.
6984 * tree-loop-streamization.c: New.
6986 * tree-flow.h (gather_blocks_in_sese_region, create_loop_fn,
6987 create_omp_parallel_region, expr_invariant_in_region_p): Declared.
6989 * Makefile.in (tree-loop-streamization.o): Added to OBJS-common.
6991 * tree-cfg.c (gather_blocks_in_sese_region): Extern.
6993 * passes.c: Schedule pass_loop_streamization.
6995 2008-03-08 Tobias Grosser <grosser@fmi.uni-passau.de>
6997 * graphite.c (dot_all_scops_1): Fix formatting for difficult bbs and
7000 2008-03-07 Tobias Grosser <grosser@fim.uni-passau.de>
7002 * graphite.c (dot_all_scops): Update formatting.
7003 Bbs can now be part of more than one SCoP.
7005 2008-03-04 Sebastian Pop <sebastian.pop@amd.com>
7007 * graphite.c (new_loop_to_cloog_loop_str, setup_cloog_loop): Fix
7009 (loop_domain_dim): Check for unregistered toplev SCOP loop.
7010 * graphite.h (loop_to_cloog_loop): New.
7012 2008-03-04 Konrad Trifunovic <konrad.trifunovic@inria.fr>
7014 * graphite.c (loop_domain_dim, ref_nb_loops,
7015 loop_iteration_vector_dim): New.
7016 (build_access_matrix_with_af, build_access_matrix,
7017 initialize_dependence_polyhedron): Fixed for new matrix layout.
7018 No longer assume that all iteration domains are of the same
7021 2008-03-02 Sebastian Pop <sebastian.pop@amd.com>
7023 * tree-scalar-evolution.c (instantiate_parameters_1): An SSA_NAME
7024 defined in a loop at depth 0 is invariant.
7025 * tree-chrec.c (evolution_function_is_invariant_rec_p): Ditto.
7026 * tree-ssa-loop-ivopts.c (expr_invariant_in_loop_p): Should never
7027 be called at loop depth 0.
7029 * graphite.c (basic_block_simple_for_scop_p): Take the scop as
7031 (dot_all_scops_1): Update use of basic_block_simple_for_scop_p.
7032 (down_open_scop): Removed.
7033 (loop_in_scop_p): Redefined.
7034 (scop_affine_expr): New argument: scop.
7035 (stmt_simple_for_scop_p): New argument: scop. RETURN_EXPR is not
7036 a harmful statement ending a scop.
7037 (basic_block_simple_for_scop_p): New argument: scop.
7038 (get_loop_start): Removed.
7039 (new_scop): Initialize SCOP_LOOPS.
7040 (free_scop): Free SCOP_LOOPS.
7041 (succs_at_same_depth, preds_at_same_depth): New.
7042 (end_scop): Test the validity of a scop.
7043 (add_dominators_to_open_scops): New.
7044 (test_for_scop_bound): Call add_dominators_to_open_scops.
7045 Add cases for opening and closing multiple scops.
7046 (build_scops, build_scop_bbs): Iterate over basic blocks in
7048 (build_graphite_bb): Pass scop directly.
7049 (dfs_bb_in_scop_p): New.
7050 (scop_record_loop): Use SCOP_LOOPS for not recording the same loop
7052 (nb_loops_around_gb): Use loop_in_scop_p.
7053 (schedule_to_scattering): Disabled for the moment the code computing
7054 the "textual order for outer loop".
7056 * graphite.h (struct scop): New field loops.
7058 (scop_loop_index): Test that the given loop belongs to SCOP_LOOPS.
7060 * gcc.dg/graphite/scop-{1,...,7}.c: Updated.
7062 2008-02-27 Antoniu Pop <antoniu.pop@gmail.com>
7063 Sebastian Pop <sebastian.pop@amd.com>
7065 * builtin-types.def (BT_FN_PTR_SIZE_UINT, BT_FN_BOOL_PTR): New.
7066 * common.opt (fstreamize-loops): New.
7067 * omp-builtins.def (BUILT_IN_GOMP_STREAM_CREATE,
7068 BUILT_IN_GOMP_STREAM_PUSH, BUILT_IN_GOMP_STREAM_HEAD,
7069 BUILT_IN_GOMP_STREAM_POP, BUILT_IN_GOMP_STREAM_EOS_P,
7070 BUILT_IN_GOMP_STREAM_SET_EOS, BUILT_IN_GOMP_STREAM_DESTROY): New.
7072 2008-02-22 Konrad Trifunovic <konrad.trifunovic@inria.fr>
7074 * tree-data-ref.c (build_empty_rdg): New.
7075 (build_rdg): Use it.
7076 * tree-data-ref.h (build_empty_rdg): Declared.
7077 * graphite.c (free_scop): Free SCOP_LOOP2CLOOG_LOOP.
7078 (find_vertex_for_stmt): Removed.
7079 (build_rdg_all_levels): Use build_empty_rdg and rdg_vertex_for_stmt.
7081 2008-02-21 Sebastian Pop <sebastian.pop@amd.com>
7083 * tree-loop-distribution.c (generate_builtin): After cancelling the
7084 loop tree, also delete basic blocks.
7085 (rdg_flag_uses): Stop recursion when a vertex has already been
7088 2008-02-15 Konrad Trifunovic <konrad.trifunovic@inria.fr>
7090 * graphite.c (build_scop_alpha): Removed.
7091 (graphite_transform_loops): Add a dummy call to build_all_rdg_levels
7092 and dump_dependence_graph to avoid compiler warnings.
7094 2008-02-14 Konrad Trifunovic <konrad.trifunovic@inria.fr>
7096 * tree-data-ref.c (dr_may_alias_p, create_rdg_vertices): Extern.
7097 * tree-data-ref.h (dr_may_alias_p, create_rdg_vertices): Declared.
7098 * graphite.c (new_loop_to_cloog_loop_str, hash_loop_to_cloog_loop,
7099 eq_loop_to_cloog_loop, del_loop_to_cloog_loop): New.
7100 (new_scop, setup_cloog_loop): Initialize SCOP_LOOP2CLOOG_LOOP.
7101 (initialize_dependence_polyhedron, find_vertex_for_stmt,
7102 initialize_data_dependence_polyhedron, is_empty_polyhedron,
7103 statement_precedes_p, build_rdg_all_levels, build_scop_alpha,
7104 dump_dependence_graph): New.
7105 * graphite.h (struct graphite_bb): New field compressed_alpha_matrix.
7107 (struct scop): New field loop2cloog_loop.
7108 (SCOP_LOOP2CLOOG_LOOP, struct data_dependence_polyhedron,
7109 RDGE_DDP, ddp_p, struct loop_to_cloog_loop_str): New.
7111 2008-02-10 Konrad Trifunovic <konrad.trifunovic@inria.fr>
7113 * graphite.c (build_graphite_bb): Fix initialization
7114 of the graphite basic block.
7116 2008-02-05 Sebastian Pop <sebastian.pop@amd.com>
7118 * graphite.c (scan_tree_for_params): Rewrite for the new layout of
7119 loop domain matrix. Pass in the number of loops contained in the
7121 (nb_loops_around_gb): Moved before setup_cloog_loop that uses it.
7122 (setup_cloog_loop): Rewrite for the new layout of loop domain matrix:
7123 loops that are not surrounding the current loop are not represented
7124 in the domain constraint matrix.
7125 (build_scop_iteration_domain): Initial domain constraint matrix
7126 contains only the eq/ineq, cst, and scop parameters columns.
7128 2008-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
7130 * graphite.c (schedule_to_scattering, nb_loops_around_gb): New.
7131 (print_graphite_bb): Print scattering.
7133 2008-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
7135 * graphite.c (initialize_cloog_names): Initialize names of
7136 scattering variables.
7138 2009-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
7140 * graphite.c (dot_all_scops_1): Disable debug output while
7143 2008-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
7145 * graphite.c (find_transform): Change cloog output language to C.
7147 2008-01-27 Sebastian Pop <sebastian.pop@amd.com>
7149 * tree-loop-distribution.c (generate_memset_zero,
7150 generate_builtin, generate_code_for_partition,
7151 rdg_flag_all_uses): New.
7152 (rdg_flag_uses): Gather in the same partition the statements defining
7153 the VUSES of the current statement.
7154 (rdg_flag_similar_stores): Renamed rdg_flag_similar_memory_accesses.
7155 Gather in the same partition not only the stores to the same memory
7156 access, but also the reads.
7157 (ldist_generate_loops): Renamed ldist_gen.
7159 2008-01-24 Sebastian Pop <sebastian.pop@amd.com>
7160 Tobias Grosser <grosser@fmi.uni-passau.de>
7162 * graphite.c (setup_cloog_loop): Chain all cloog loops with the
7163 next pointer, don't use the inner pointer.
7165 2008-01-20 Tobias Grosser <grosser@fmi.uni-passau.de>
7167 * graphite.c (dot_all_scops, dot_all_scops_1): New.
7168 (find_transform): Call dot_all_1.
7169 * graphite.h (dot_all_scops): Declared.
7171 2007-12-14 Sebastian Pop <sebastian.pop@amd.com>
7173 * tree-loop-distribution.c: Fix apsi.f ICE.
7174 (create_bb_after_loop): New.
7175 (generate_loops_for_partition): Use it.
7176 * gfortran.dg/ldist-1.f90: New.
7178 * tree-data-ref.c (dot_rdg): Use /tmp/rdg.dot for dotty format.
7179 * graphite.c (dot_scop): Use /tmp/scop.dot for dotty format.
7181 2007-12-13 Tobias Grosser <grosser@fmi.uni-passau.de>
7183 * graphite.c (find_transform): Dump cloog program sent to cloog.
7185 2007-12-13 Tobias Grosser <grosser@fmi.uni-passau.de>
7187 * graphite.c (initialize_cloog_names): Initialize cloog
7190 2007-12-13 Tobias Grosser <grosser@fmi.uni-passau.de>
7192 * graphite.c (build_scop_context): Fix typo, for the matrix
7193 format: insert '0 >= 0' instead of '-1 >= 0'.
7195 2007-12-13 Sebastian Pop <sebastian.pop@amd.com>
7197 * Fix merge problems.
7199 2007-12-13 Sebastian Pop <sebastian.pop@amd.com>
7201 * graphite.c (setup_cloog_loop): Fix typo.
7203 2007-12-12 Sebastian Pop <sebastian.pop@amd.com>
7205 * doc/invoke.texi (-ftree-loop-distribution): Documented.
7206 * tree-loop-distribution.c: Reimplemented.
7207 * tree-pass.h (pass_loop_distribution): New.
7208 * tree-scalar-evolution.c (number_of_iterations_for_all_loops): Use
7210 * graphds.h (struct graph): New field indexes.
7211 * timevar.def (TV_TREE_LOOP_DISTRIBUTION): New.
7213 * tree-vect-analyze.c: Remove declaration of static functions when not
7215 * tree-vectorizer.c: Same.
7216 (rename_variables_in_loop): Now extern.
7217 (slpeel_tree_duplicate_loop_to_edge_cfg): Renamed
7218 tree_duplicate_loop_to_edge_cfg. Reset PENDING_STMT for edges after
7219 calling redirect_edge_and_branch_force.
7221 * tree-vectorizer.h (tree_duplicate_loop_on_edge): Declared.
7223 * tree-data-ref.c: Don't include tree-chrec.h.
7224 (debug_data_dependence_relations): New.
7225 (dump_data_dependence_relation): Call dump_data_reference on data refs
7227 (same_access_functions): Moved...
7228 (find_vertex_for_stmt): Renamed rdg_vertex_for_stmt.
7229 (dump_rdg_vertex, debug_rdg_vertex, dump_rdg_component,
7230 debug_rdg_component, dump_rdg, debug_rdg, dot_rdg_1, dot_rdg,
7231 struct rdg_vertex_info, ): New.
7232 (create_rdg_edge_for_ddr): Compute the dependence level before looking
7234 (create_rdg_vertices): Initialize the htab of graph->indexes.
7235 Initialize RDG_MEM_WRITE_STMT and RDG_MEM_READS_STMT.
7236 (stmts_from_loop): Don't save LABEL_EXPR.
7237 (hash_stmt_vertex_info, eq_stmt_vertex_info,
7238 hash_stmt_vertex_del): New.
7239 (build_rdg): Initialize rdg->indexes.
7240 (free_rdg, stores_from_loop, ref_base_address,
7241 rdg_defs_used_in_other_loops_p, have_similar_memory_accesses,
7242 have_similar_memory_accesses_1, ref_base_address_1,
7243 remove_similar_memory_refs): New.
7245 * tree-data-ref.h: Include tree-chrec.h.
7246 (debug_data_dependence_relations): Declared.
7247 (same_access_functions): ...here. Now static inline.
7248 (ddr_is_anti_dependent, ddrs_have_anti_deps,
7249 ddr_dependence_level): New.
7250 (struct rdg_vertex): New fields has_mem_write, has_mem_reads.
7251 (RDGV_HAS_MEM_WRITE, RDGV_HAS_MEM_READS, RDG_STMT, RDG_MEM_WRITE_STMT,
7252 RDG_MEM_READS_STMT): New.
7253 (dump_rdg_vertex, debug_rdg_vertex, dump_rdg_component,
7254 debug_rdg_component, dump_rdg, debug_rdg, dot_rdg,
7255 rdg_vertex_for_stmt): Declared.
7256 (struct rdg_edge): New field level.
7257 (RDGE_LEVEL, free_rdg): New.
7258 (stores_from_loop, remove_similar_memory_refs,
7259 rdg_defs_used_in_other_loops_p,
7260 have_similar_memory_accesses): Declared.
7261 (rdg_has_similar_memory_accesses): New.
7263 * lambda.h (dependence_level): New.
7264 * common.opt (ftree-loop-distribution): New.
7265 * tree-flow.h (debug_loop_ir): Renamed debug_loops.
7266 (print_loop_ir): Renamed print_loops.
7267 (debug_loop, debug_loop_num, print_loops_bb, mark_virtual_ops_in_bb,
7268 tree_duplicate_loop_to_edge_cfg, rename_variables_in_loop): Declared.
7269 * Makefile.in (TREE_DATA_REF_H): Depends on tree-chrec.h.
7270 (tree-loop-distribution.o): Added.
7271 * tree-cfg.c (mark_virtual_ops_in_region): Use mark_virtual_ops_in_bb.
7272 (mark_virtual_ops_in_bb): New.
7273 (print_loops_bb, debug_loop_num, debug_loop): New.
7274 * passes.c: Scheduled pass_loop_distribution.
7276 2007-12-12 Konrad Trifunovic <konrad.trifunovic@inria.fr>
7278 * graphite.c (scan_tree_for_params): Correct the number of columns
7280 (nb_flat_iterator): New.
7281 (setup_cloog_loop): Initialize to 1 the first column for inequalities.
7282 (build_scop_iteration_domain): Correct the number of columns for
7285 2007-12-12 Sebastian Pop <sebastian.pop@amd.com>
7287 * Merge from mainline (129697:130800).
7289 2007-10-30 Sebastian Pop <sebastian.pop@amd.com>
7291 * graphite.c (build_graphite_bb): SCoP's basic blocks are post
7292 dominated by SCoP's exit.
7293 (graphite_transform_loops): Compute post dominators.
7295 2007-10-28 Sebastian Pop <sebastian.pop@amd.com>
7297 * Merge from mainline (127169:129697).
7299 2007-10-28 Sebastian Pop <sebastian.pop@amd.com>
7301 * graphite.c (affine_expr): Renamed scop_affine_expr. Use an extra
7302 parameter for the basic block that contains the expression. Use
7303 outermost_loop_in_scop for evolution_function_is_affine_multivariate_p.
7304 (stmt_simple_for_scop_p): Pass to scop_affine_expr the basic block of
7306 * graphite.h (gbb_loop): New.
7307 (GBB_LOOP): Removed.
7309 2007-08-03 Sebastian Pop <sebpop@gmail.com>
7311 * Makefile.in: Fix merge problem.
7313 2007-08-03 Sebastian Pop <sebpop@gmail.com>
7315 * Merge from mainline (125309:127169).
7316 * tree-loop-distribution.c: Disabled.
7318 2007-06-05 Sebastian Pop <sebpop@gmail.com>
7320 * Merge from mainline (r123693:125309).
7322 2007-05-30 Sebastian Pop <sebpop@gmail.com>
7324 * tree-loop-distribution.c (correct_modify_expr_p): Renamed
7326 (correct_modify_p, check_statements, number_of_lvalue_uses,
7327 number_of_scalar_dependences, create_edges): Use GIMPLE_MODIFY_STMT
7328 instead of MODIFY_EXPR.
7329 (update_edge_with_ddv): Don't pass index_of_edge. Initialize
7332 2007-05-24 Sebastian Pop <sebpop@gmail.com>
7334 * tree-loop-distribution.c (struct rdg): Replace arrays by
7335 VECs for edges and vertices.
7336 (RDG_NBV, RDG_NBE, RDG_VERTEX, RDG_EDGE): Removed.
7337 (RDGV_NB_PARTITIONS): New.
7338 (PRDG_NBV, PRDG_NBE): Removed.
7339 (build_scc_graph, correct_partitions_p, mark_partitions, build_prdg,
7340 dump_rdg, find_vertex_with_stmt, create_vertices, free_rdg,
7341 number_of_scalar_dependences, create_edges, build_rdg): Use VECs.
7343 2007-05-17 Georges-Andre Silber <silber@cri.ensmp.fr>
7344 Sebastian Pop <sebpop@gmail.com>
7346 * doc/invoke.texi (-ftree-loop-distribution): Document.
7347 * tree-loop-distribution.c: New file.
7348 * tree-pass.h (pass_loop_distribution): Declared.
7349 * timevar.def (TV_TREE_LOOP_DISTRIBUTION): New.
7350 * tree-data-ref.c (initialize_data_dependence_relation): Initialize
7352 * tree-data-ref.h (data_dependence_relation): Add reversed_p.
7353 (DDR_REVERSED_P): New.
7354 * common.opt (-ftree-loop-distribution): New.
7355 * tree-flow.h (distribute_loops): Declared.
7356 * Makefile.in (OBJS-common): Depend on tree-loop-distribution.o.
7357 * passes.c (init_optimization_passes): Schedule loop distribution.
7359 2007-05-12 Sebastian Pop <sebastian.pop@inria.fr>
7361 * graphite.c (print_graphite_bb): Don't call dump_data_references.
7362 (print_scop): Don't print when scop is NULL.
7363 (build_scop_context, find_transform): Don't output to stderr.
7365 2007-05-09 Sebastian Pop <sebastian.pop@inria.fr>
7367 * tree-data-ref.c: Don't include graphite.h.
7368 Comment out the code for printing data reference's scop.
7369 (build_access_matrix_with_af): Moved...
7370 * tree-data-ref.h (build_access_matrix_with_af): Removed declaration.
7371 * graphite.c (build_access_matrix_with_af): ... here. Now static.
7372 (print_graphite_bb): Print basic block's schedule.
7373 (print_scop): Don't print the schedule, call cloog's pretty printer.
7374 (bb_in_scop_p): A basic block is in a scop only if it is both
7375 dominated and postdominated by the scop's entry and exit basic blocks.
7376 (function_parameter_p): New.
7377 (invariant_in_scop_p): Use function_parameter_p.
7378 (new_scop, save_scop): New.
7379 (end_scop, test_for_scop_bound, build_scops): Use new_scop, and
7381 (scan_tree_for_params): Directly build the constraint as CloogMatrix.
7382 (loop_in_scop_p): New.
7383 (scop_record_loop): Use loop_in_scop_p.
7384 (build_scop_domain): Renamed build_scop_iteration_domain.
7385 (setup_cloog_loop, initialize_cloog_names, find_scop_parameters,
7386 nb_params_in_scop, build_scop_context, first_loop_in_scop,
7387 setup_cloog_loop, dot_scop_1, dot_scop): New.
7388 * graphite.h (GBB_LOOP, SCOP_PROG, dot_scop): New.
7389 (struct scop): Add a pointer to cloog's representation of a program.
7391 2007-04-14 Sebastian Pop <sebastian.pop@inria.fr>
7393 * doc/invoke.texi (-ftree-check-verbose): Renamed
7394 -ftree-checks-verbose.
7395 * common.opt (flag_tree_check_verbose): Renamed
7396 flag_tree_checks_verbose.
7397 * tree-check.c (tree_check_warning): Use flag_tree_checks_verbose.
7399 2007-04-14 Sebastian Pop <sebastian.pop@inria.fr>
7401 * configure: Regenerated.
7402 * config.in: Regenerated.
7403 * tree-ssa-loop.c (graphite_transforms): Execute
7404 graphite_transform_loops only when HAVE_cloog.
7405 * configure.ac (HAVE_polylib, HAVE_cloog, GRAPHITE): Defined.
7406 * graphite.c: Include polylibgmp.h and cloog.h.
7407 (graphite_transform_loops): Removed loops parameter.
7408 * tree-flow.h (graphite_transform_loops): Update declaration.
7409 * Makefile.in (POLYLIBLIBS, POLYLIBINC, CLOOGLIBS, CLOOGINC): New.
7410 (LIBS): Depend on CLOOGLIBS and on POLYLIBLIBS.
7411 (INCLUDES): Depend on POLYLIBINC and on CLOOGINC.
7412 (OBJS-common): Remove dependence on graphite.o.
7413 (BACKEND): Depend on @GRAPHITE@.
7415 2007-04-13 Sebastian Pop <sebastian.pop@inria.fr>
7417 * doc/invoke.texi (-ftree-check-verbose): Documented.
7418 * gcc.dg/tree-checker/tree-checks-1.c: New.
7419 * gcc.dg/tree-checker/tree-checks-2.c: New.
7420 * gcc.dg/tree-checker/tree-checks-3.c: New.
7421 * gcc.dg/tree-checker/tree-checks-4.c: New.
7422 * gcc.dg/tree-checker/tree-checks.exp: New.
7423 * gcc.dg/tree-checker/condates.crp: New.
7424 * common.opt (ftree-checks-verbose): New.
7425 * tree-check.c (tree_check_warning): Move extra stderr output
7426 under control of flag_tree_check_verbose.
7428 2007-04-12 Sebastian Pop <sebastian.pop@inria.fr>
7430 * tree-match.c: Fix comments formatting.
7431 * tree-match.h: Fix comments formatting.
7432 * tree-check.c: Fix comments formatting.
7433 (tree_check_init): Restructure.
7435 2007-04-12 Nic Volanschi <nic.volanschi@free.fr>
7437 * doc/invoke.texi (-ftree-check, -ftree-checks): Documented.
7439 2007-04-10 Sebastian Pop <sebastian.pop@inria.fr>
7441 * Merge from mainline (r120733:123693).
7443 2007-03-20 Nic Volanschi <nic.volanschi@free.fr>
7445 * condate.y: New file.
7446 * tree-match.h (struct patt_info_s): New field sign.
7447 (struct condate_s): New field msg.
7448 (normalize_condate, name_condate, add_condate): New.
7449 (conds[], condate_parse): Made extern.
7450 * tree-check.c (tree_check_warning): First arg changed to cond;
7451 warning reformatted.
7452 (tree_check_init): Reset the TREE_VISITED bit on every CFG node.
7454 (tree_check): Process trivial condates.
7455 (read_delimited_string): Removed.
7456 (print_cond): Print name and msg.
7457 (conds[]): Made extern.
7458 (parse_tree_check_file_once): Rewritten to use the parser in
7460 Processing of option --tree_check_string moved to tree_scan().
7461 * Makefile.in: Added condate.y
7463 2007-03-12 Sebastian Pop <sebastian.pop@inria.fr>
7465 * tree-pretty-print.c (dump_generic_bb_buff, lazy_dump_generic_node):
7466 Use VECs instead of varrays.
7467 * diagnostic.h (lazy_dump_generic_node): Update declaration.
7468 * Makefile.in (pretty-print.o): Depend on vec.h.
7469 * pretty-print.c: Include tree.h and vec.h.
7470 (pp_clear_state, pp_write_list_to_stream, pp_base_format,
7471 pp_base_format, pp_construct, pp_base_string, pp_lazy_mode,
7472 new_tree_chunk, pp_add_tree, pp_add_string, pp_add_char, pp_write_list,
7473 pp_free_list): Use VECs instead of varrays.
7474 * pretty-print.h: Do not include varray.h.
7475 (struct tree_chunk_s): Declaration moved before its use.
7476 (output_buffer): Rename varray field to chunks.
7477 * tree-match.c (tree_equal, chunk_1st_char, chunks_lookahead,
7478 tree_1st_char, match_chunks_pattinfo, match_tree_pattinfo,
7479 save_global_holes): Use VECs instead of varrays.
7480 * tree-match.h: Declare VECs of cfg_node, and hole_p.
7481 * tree-check.c (scan_cfg_stmts, push_node,
7482 print_matching_stmt): Removed.
7483 (tree_check_instance, push_global_holes_if_new, tree_check,
7484 execute_tree_check): Use VECs instead of varrays.
7485 (gate_tree_check): Don't execute the CFG check when basic_block_info
7488 2007-01-12 Sebastian Pop <sebastian.pop@inria.fr>
7490 * Merge from mainline (r115016:120733).
7492 2007-01-12 Sebastian Pop <sebastian.pop@inria.fr>
7494 * Merge from mainline (r117632:117661).
7496 2007-01-12 Sebastian Pop <sebastian.pop@inria.fr>
7498 * tree-dump.c (dump_option_value_in): Add TDF_DEBUG.
7499 * tree-pass.h (TDF_DEBUG, debug_p): New.
7500 * tree-scalar-evolution.c (set_scalar_evolution, get_scalar_evolution,
7501 get_scalar_evolution, add_to_evolution, set_nb_iterations_in_loop,
7502 get_loop_exit_condition, analyze_evolution_in_loop,
7503 analyze_initial_condition, analyze_scalar_evolution,
7504 instantiate_parameters, number_of_latch_executions): Use debug_p.
7505 * tree-chrec.c (chrec_apply): Use debug_p.
7506 * tree-data-ref.c: Include graphite.h.
7507 (dump_data_reference): Print also the access matrix.
7508 (analyze_array, analyze_indirect_ref, init_data_ref,
7509 analyze_offset_expr, address_analysis, object_analysis,
7510 create_data_ref, finalize_ddr_dependent,
7511 non_affine_dependence_relation, analyze_ziv_subscript,
7512 analyze_siv_subscript_cst_affine,
7513 compute_overlap_steps_for_affine_1_2, analyze_subscript_affine_affine,
7514 can_use_analyze_subscript_affine_affine, analyze_siv_subscript,
7515 analyze_miv_subscript, analyze_overlapping_iterations,
7516 build_classic_dist_vector, subscript_dependence_tester,
7517 compute_affine_dependence, analyze_all_data_dependences): Use debug_p.
7518 (build_access_matrix_with_af): No longer static.
7519 * tree-data-ref.h (scop_p): ... declaration here.
7520 (data_reference.scop): New field.
7521 (DR_SCOP, DR_ACCESS_MATRIX): New.
7522 (build_access_matrix_with_af, dr_num_subscripts): Declared.
7523 * graphite.c (print_graphite_bb): Call dump_data_references.
7524 (print_scop): Use scop_nb_loops and scop_dim_domain.
7525 (test_for_scop_bound): Use debug_p.
7526 (scan_tree_for_params): Use scop_nb_loops, scop_nb_loops and
7528 (scop_loop_index): Moved...
7529 (scop_record_loop): New.
7530 (build_scop_loop_nests): Use scop_record_loop.
7531 (build_scop_domain): Use scop_dim_domain.
7532 (build_access_matrix): Implemented.
7533 (build_scop_canonical_schedules): Use scop_nb_loops.
7534 (build_graphite_bb): Initialize GBB_SCOP.
7535 * graphite.h (scop_p): Moved...
7536 (graphite_bb.scop): New field.
7537 (graphite_bb.iteration_domain, GBB_DOMAIN, scop.nb_params,
7538 scop.nb_loops, scop.dim_domain, SCOP_NB_LOOPS, SCOP_NB_PARAMS,
7539 SCOP_DIM_DOMAIN, SCOP_STMTS): Removed.
7540 (scop_nb_params, scop_nb_loops, scop_dim_domain, gbb_dim_domain,
7541 scop_loop_index): New.
7542 * Makefile.in (tree-data-ref.o): Depends on graphite.h.
7544 2007-01-05 Sebastian Pop <sebastian.pop@inria.fr>
7546 * Merge from mainline (r117661:120450).
7548 2006-10-12 Sebastian Pop <sebastian.pop@inria.fr>
7550 * tree-scalar-evolution.c (instantiate_parameters_1): Don't stop
7551 at the first declaration outside the varying loop, instantiate as
7553 * tree-chrec.c (for_each_scev_op): New.
7554 * tree-chrec.h (for_each_scev_op): Declared.
7555 * tree-ssa-loop.c (pass_graphite_trans): Don't dump the function.
7556 * tree-data-ref.c (get_references_in_stmt,
7557 find_data_references_in_stmt): New, from trunk.
7558 (find_data_references_in_loop): Use get_references_in_stmt
7559 and find_data_references_in_loop, modified as in trunk.
7560 (build_access_matrix_with_af): New.
7561 * tree-data-ref.h (data_reference): Add a field access_matrix.
7562 (data_ref_loc): New, as in trunk.
7563 * graphite.c (print_graphite_bb, bb_in_scop_p, stmt_in_scop_p,
7564 invariant_in_scop_p, param_index, scan_tree_for_params,
7565 scop_loop_index, build_scop_loop_nests, build_scop_domain, irp_data,
7566 idx_record_param, idx_record_params, build_access_matrix,
7567 build_scop_data_accesses, build_scop_canonical_schedules,
7568 build_graphite_bb, build_scop_bbs, find_params_in_bb,
7569 build_scop_params): New.
7570 * graphite.h (graphite_bb): New.
7571 (scop): Add fields static_schedule, params, loop_nest,
7573 * lambda.h: Declare vecs of lambda_matrix.
7574 * tree-flow.h (print_loop_ir_bb): Declared.
7575 * tree-cfg.c (print_loop_ir_bb): New.
7576 (print_loop): Use print_loop_ir_bb.
7578 2006-10-12 Sebastian Pop <pop@cri.ensmp.fr>
7580 * Merge from mainline (r115016:117632).
7582 2006-10-11 Sebastian Pop <pop@cri.ensmp.fr>
7584 * graphite.c (debug_scops): Adjust definition for avoiding a bootstrap
7585 break due to a warning.
7587 2006-10-10 Sebastian Pop <pop@cri.ensmp.fr>
7589 * graphite.c (print_scops, debug_scops): New.
7590 (graphite_transform): Renamed graphite_find_transform.
7591 * graphite.h (debug_scops): Declared.
7593 2006-08-17 Sebastian Pop <pop@cri.ensmp.fr>
7595 * tree-match.c: Reformat following the GNU style.
7596 * tree-match.h: Reformat following the GNU style.
7597 * tree-pattern.h: Removed empty file.
7598 * Makefile.in: Remove references to tree-pattern.h.
7599 * tree-check.c: Reformat following the GNU style.
7600 (execute_tree_check): Move gate condition code to...
7601 (gate_tree_check): ...here. New function.
7602 (pass_check): Use the gate function.
7604 2006-07-04 Nic Volanschi <nic.volanschi@free.fr>
7606 * tree-pattern.h: New. Tree pattern matching and checking using
7608 * tree-check.c: New. Tree/CFG checking pass.
7609 * tree-match.c: New. Library for tree pattern matching.
7610 * opts.c, common.opt: Add options --ftree-check & --ftree-checks.
7611 * toplev.c, flags.h: Add globals for tree-check pass.
7612 * Makefile.in: Integrate the files in tree-check pass.
7613 * timevar.def, tree-optimize.c, tree-pass.h: Register tree-check pass.
7614 * pretty-print.c, pretty-print.h, tree-pretty-print.c, diagnostic.h:
7615 Introduce a "lazy" pretty-print mode.
7616 * tree.c, tree.h: Add tree_name.
7618 2006-07-04 Sebastian Pop <pop@cri.ensmp.fr>
7620 * doc/invoke.texi (-fgraphite): Correct typo.
7621 * tree-scalar-evolution.c (number_of_iterations_for_all_loops): Update
7622 use of print_loop_ir.
7623 * gcc.dg/graphite/scop-1.c: New.
7624 * gcc.dg/graphite/scop-2.c: New.
7625 * gcc.dg/graphite/graphite.exp: New.
7626 * graphite.c: Include domwalk.h.
7627 (print_scop): Print only the entry and exit blocks.
7628 (debug_scop): No longer static.
7629 (affine_expr): Fix formating. Return also true when the expression is
7631 (stmt_simple_for_scop_p): Fix formating.
7632 (build_scops): Use domwalk.
7633 (get_loop_start, end_scop, test_for_scop_bound): New.
7634 (graphite_transform_loops): Avoid printing on stderr.
7635 * graphite.h (debug_scop): Declared.
7636 * tree-flow.h (debug_loop_ir, print_loop_ir): Update declarations.
7637 * Makefile.in (graphite.o): Depend on domwalk.h.
7638 * tree-cfg.c (print_loop, print_pred_bbs, print_succ_bbs): Remove
7639 declarations for static functions.
7640 (print_loop, print_loop_ir, debug_loop_ir): Use an extra parameter for
7641 controlling output verbosity.
7643 2006-06-26 Sebastian Pop <pop@cri.ensmp.fr>
7644 Plesco Alexandru <shurikx@gmail.com>
7646 * doc/invoke.texi (-fgraphite): Document.
7647 * tree-pass.h (pass_graphite_transforms): Declared.
7648 * timevar.def (TV_GRAPHITE_TRANSFORMS): New.
7649 * tree-ssa-loop.c (graphite_transforms, gate_graphite_transforms): New.
7650 (pass_graphite_transforms): Defined.
7651 * tree-data-ref.c (free_data_ref, data_reference): Extern.
7652 * tree-data-ref.h (free_data_ref, data_reference): Declared.
7653 * graphite.c, graphite.h: New.
7654 * common.opt (fgraphite): Declared.
7655 * tree-flow.h (graphite_transform_loops): Declared.
7656 * Makefile.in (OBJS-common): Add graphite.o.
7657 (graphite.o): New rule.
7658 * passes.c (pass_graphite_transforms): Scheduled.