1 2010-04-04 Sebastian Pop <sebastian.pop@amd.com>
4 * graphite-clast-to-gimple.c (graphite_create_new_loop_guard): Use
5 POINTER_PLUS_EXPR for pointer types.
7 * gcc.dg/graphite/id-19.c: New.
9 2010-04-04 Sebastian Pop <sebastian.pop@amd.com>
12 * Makefile.in (graphite-clast-to-gimple.o): Depends on langhooks.h.
13 * graphite-clast-to-gimple.c: Include langhooks.h.
14 (max_signed_precision_type): New.
15 (max_precision_type): Takes two types as arguments.
16 (precision_for_value): New.
17 (precision_for_interval): New.
18 (gcc_type_for_interval): New.
19 (gcc_type_for_value): New.
20 (gcc_type_for_clast_term): New.
21 (gcc_type_for_clast_red): New.
22 (gcc_type_for_clast_bin): New.
23 (gcc_type_for_clast_expr): Split up into several functions.
24 (gcc_type_for_clast_eq): Rewritten.
25 (compute_bounds_for_level): New.
26 (compute_type_for_level_1): New.
27 (compute_type_for_level): New.
28 (gcc_type_for_cloog_iv): Removed.
29 (gcc_type_for_iv_of_clast_loop): Rewritten.
30 (graphite_create_new_loop): Compute the lower and upper bound types
31 with gcc_type_for_clast_expr.
32 (graphite_create_new_loop_guard): Same.
33 (find_cloog_iv_in_expr): Removed.
34 (compute_cloog_iv_types_1): Removed.
35 (compute_cloog_iv_types): Removed.
36 (gloog): Do not call compute_cloog_iv_types.
37 * graphite-sese-to-poly.c (new_gimple_bb): Do not initialize
39 (free_data_refs_aux): Do not free GBB_CLOOG_IV_TYPES.
40 * sese.h (struct gimple_bb): Removed field cloog_iv_types.
41 (GBB_CLOOG_IV_TYPES): Removed.
43 * gcc.dg/graphite/run-id-pr42644.c: Call abort.
45 2010-04-02 Sebastian Pop <sebastian.pop@amd.com>
47 Reverted this commit: as at this point the loop closed SSA form
48 is under a canonical form respecting the single argument condition.
49 * graphite-sese-to-poly.c (scalar_close_phi_node_p): Loop
50 close phi nodes may have more than one argument.
52 2010-04-01 Sebastian Pop <sebastian.pop@amd.com>
54 * graphite-sese-to-poly.c (rewrite_close_phi_out_of_ssa): Assert that
55 gimple_phi_num_args of the loop close SSA phi node is equal to 1.
56 (detect_commutative_reduction): Same.
58 2010-03-31 Sebastian Pop <sebastian.pop@amd.com>
60 * graphite-sese-to-poly.c (scalar_close_phi_node_p): Loop
61 close phi nodes may have more than one argument.
63 2010-03-30 Richard Guenther <rguenther@suse.de>
64 Zdenek Dvorak <ook@ucw.cz>
65 Sebastian Pop <sebastian.pop@amd.com>
68 * tree-ssa-copy.c (init_copy_prop): Handle loop close phi nodes
69 with multiple arguments.
70 (execute_copy_prop): Remove call to rewrite_into_loop_closed_ssa.
72 2010-03-23 Sebastian Pop <sebastian.pop@amd.com>
74 * graphite-dependences.c (print_pddr): Call print_pdr with an
76 * graphite-poly.c (debug_pdr): Add an extra argument for the
79 (print_pbb_domain): Same.
81 (print_scop_context): Same.
84 (debug_pbb_domain): Same.
88 (debug_scop_context): Same.
91 (print_scop_params): Same.
92 (debug_scop_params): Same.
93 (print_iteration_domain): Same.
94 (print_iteration_domains): Same.
95 (debug_iteration_domain): Same.
96 (debug_iteration_domains): Same.
97 (print_scattering_function): Same.
98 (print_scattering_functions): Same.
99 (debug_scattering_function): Same.
100 (debug_scattering_functions): Same.
101 * graphite-poly.h (debug_pdr): Update declaration.
103 (print_pbb_domain): Same.
105 (print_scop_context): Same.
108 (debug_pbb_domain): Same.
112 (debug_scop_context): Same.
115 (print_scop_params): Same.
116 (debug_scop_params): Same.
117 (print_iteration_domain): Same.
118 (print_iteration_domains): Same.
119 (debug_iteration_domain): Same.
120 (debug_iteration_domains): Same.
121 (print_scattering_function): Same.
122 (print_scattering_functions): Same.
123 (debug_scattering_function): Same.
124 (debug_scattering_functions): Same.
126 2010-03-23 Sebastian Pop <sebastian.pop@amd.com>
128 * graphite-poly.c (print_scattering_function_1): New.
129 (print_scattering_function): Call it.
130 (print_scop_params): Remove spaces at the end of lines.
133 * graphite-poly.h (print_cloog): Declared.
134 (debug_cloog): Declared.
136 2010-03-23 Sebastian Pop <sebastian.pop@amd.com>
138 * tree-ssa-copy.c: Revert this previous change:
139 (init_copy_prop): Loop closed phi nodes cancontain more than one
141 (execute_copy_prop): Revert the previous change: do not call
142 rewrite_into_loop_closed_ssa.
144 2010-03-21 Sebastian Pop <sebastian.pop@amd.com>
145 Richard Guenther <rguenther@suse.de>
148 * tree-ssa-copy.c (init_copy_prop): Loop closed phi nodes can
149 contain more than one argument.
150 (execute_copy_prop): Revert the previous change: do not call
151 rewrite_into_loop_closed_ssa.
153 * gcc.dg/graphite/id-pr43464.c: Remove compile warning.
154 * gcc.dg/graphite/id-pr43464-1.c: New.
156 2010-03-21 Sebastian Pop <sebastian.pop@amd.com>
159 * tree-ssa-copy.c (execute_copy_prop): Call rewrite_into_loop_closed_ssa
160 and verify_loop_closed_ssa when copy prop is executed in the LNO.
162 * gcc.dg/graphite/id-pr43464.c: New.
164 2010-03-16 Sebastian Pop <sebastian.pop@amd.com>
166 * graphite-sese-to-poly.c (graphite_loop_normal_form): Add the IV bump
168 * tree-flow.h (canonicalize_loop_ivs): Updated declaration.
169 * tree-parloops.c (gen_parallel_loop): Add the IV bump in loop->latch.
170 * tree-ssa-loop-manip.c (canonicalize_loop_ivs): Add a new parameter
171 to switch between adding the IV bump in loop->latch or in loop->header.
173 2010-03-16 Sebastian Pop <sebastian.pop@amd.com>
175 * passes.c (init_optimization_passes): Add pass_copy_prop
178 2010-03-16 Sebastian Pop <sebastian.pop@amd.com>
180 * graphite-poly.c (print_scattering_function): Pretty print following
183 (print_pbb_domain): Same.
184 (dump_gbb_cases): Same.
185 (dump_gbb_conditions): Same.
188 (print_scop_params): Same.
189 (print_scop_context): Same.
191 (print_pbb_body): New.
192 (lst_indent_to): New.
193 (print_lst): Start new lines with a #.
194 * graphite-poly.h (pbb_bb): New.
195 (pbb_index): Use pbb_bb.
196 * graphite-ppl.c (ppl_print_powerset_matrix): Print the number of
198 * tree-data-ref.c (dump_data_reference): Start new lines with a #.
200 2010-03-13 Sebastian Pop <sebastian.pop@amd.com>
203 * gcc.dg/graphite/id-pr43351.c
205 2010-03-13 Sebastian Pop <sebastian.pop@amd.com>
208 * graphite-sese-to-poly.c (rewrite_close_phi_out_of_ssa): Do not
209 call insert_out_of_ssa_copy for default definitions.
210 * gfortran.dg/graphite/id-pr43354.f: New.
212 2010-03-13 Sebastian Pop <sebastian.pop@amd.com>
215 * gfortran.dg/graphite/pr43349.f: New.
217 2010-03-11 Sebastian Pop <sebastian.pop@amd.com>
219 * graphite-clast-to-gimple.c (my_long_long): Defined.
220 (gcc_type_for_cloog_iv): Use it instead of long_long_integer_type_node.
221 * graphite-sese-to-poly.c (my_long_long): Defined.
222 (scop_ivs_can_be_represented): Use it.
224 2010-03-10 Sebastian Pop <sebastian.pop@amd.com>
226 * doc/invoke.texi: Fix documentation of graphite-max-nb-scop-params,
227 graphite-max-bbs-per-function, and loop-block-tile-size.
228 * params.def (PARAM_GRAPHITE_MAX_NB_SCOP_PARAMS): Replace "maximal"
230 (PARAM_GRAPHITE_MAX_BBS_PER_FUNCTION): Same.
232 2010-03-10 Sebastian Pop <sebastian.pop@amd.com>
234 * graphite-clast-to-gimple.c (gcc_type_for_iv_of_clast_loop): Remove
236 * graphite-sese-to-poly.c (reduction_phi_p): Remove FIXME comment.
237 (add_upper_bounds_from_estimated_nit): New.
238 (build_loop_iteration_domains): Use it.
240 2010-03-09 Sebastian Pop <sebastian.pop@amd.com>
242 * doc/invoke.texi (PARAM_LOOP_BLOCK_TILE_SIZE): Document.
244 2010-03-09 Sebastian Pop <sebastian.pop@amd.com>
247 * tree-chrec.c (evolution_function_right_is_integer_cst): CHREC_RIGHT
248 should be an INTEGER_CST. Also handle CASE_CONVERT.
249 * gcc.dg/graphite/pr43306.c: New.
251 2010-03-09 Sebastian Pop <sebastian.pop@amd.com>
253 * graphite.c (graphite_initialize): To bound the number of bbs per
254 function, use PARAM_GRAPHITE_MAX_BBS_PER_FUNCTION.
255 * params.def (PARAM_GRAPHITE_MAX_BBS_PER_FUNCTION): Declared.
256 * doc/invoke.texi: Document it.
258 2010-03-09 Sebastian Pop <sebastian.pop@amd.com>
260 * graphite-sese-to-poly.c (build_poly_scop): Do not return bool.
261 * graphite-sese-to-poly.h (build_poly_scop): Same.
263 2010-03-09 Sebastian Pop <sebastian.pop@amd.com>
265 * graphite-sese-to-poly.c (build_poly_scop): Limit scops following
266 the number of parameters in the scop. Use as an upper bound
267 PARAM_GRAPHITE_MAX_NB_SCOP_PARAMS.
268 * params.def (PARAM_GRAPHITE_MAX_NB_SCOP_PARAMS): Declared.
269 * doc/invoke.texi: Document it.
271 2010-03-05 Sebastian Pop <sebastian.pop@amd.com>
273 * graphite-sese-to-poly.c (add_param_constraints): Use
274 lower_bound_in_type and upper_bound_in_type.
276 2010-03-05 Sebastian Pop <sebastian.pop@amd.com>
278 * graphite-sese-to-poly.c (add_param_constraints): Use sizetype
279 instead of unsigned_type_node.
281 2010-03-05 Sebastian Pop <sebastian.pop@amd.com>
282 Reza Yazdani <reza.yazdani@amd.com>
285 * graphite-sese-to-poly.c (add_param_constraints): Insert bounds
286 on pointer type parameters.
288 * gcc.dg/graphite/run-id-4.c: New.
290 2010-03-05 Sebastian Pop <sebastian.pop@amd.com>
293 * gcc.dg/graphite/run-id-3.c: New.
295 2010-03-05 Tobias Grosser <grosser@fim.uni-passau.de>
296 Ramakrishna Upadrasta <Ramakrishna.Upadrasta@inria.fr>
298 * graphite-clast-to-gimple.c (clast_to_gcc_expression): Also
299 handle conversions from pointer to integers.
300 (gcc_type_for_cloog_iv): Choose the smalles signed integer as an
301 induction variable, to be able to work with code generated by CLooG.
302 * graphite-sese-to-poly.c (scop_ivs_can_be_represented): New.
303 (build_poly_scop): Bail out if we cannot codegen a loop.
305 2010-03-04 Tobias Grosser <grosser@fim.uni-passau.de>
307 * graphite-clast-to-gimple.c (translate_clast): Do not short-cut
308 code generation with gloog_error.
310 2010-03-04 Sebastian Pop <sebastian.pop@amd.com>
312 * sese.c (expand_scalar_variables_ssa_name): Add new argument for type.
313 Call fold_convert on all the returned values.
314 (expand_scalar_variables_expr): Pass to expand_scalar_variables_ssa_name
315 the type of the resulting expression.
317 2010-03-04 Sebastian Pop <sebastian.pop@amd.com>
319 * graphite-ppl.c (ppl_min_for_le_polyhedron): Renamed
320 ppl_min_for_le_pointset. Use ppl_Pointset_Powerset_C_Polyhedron_minimize.
321 * graphite-ppl.h (ppl_min_for_le_polyhedron): Update declaration.
323 2010-03-04 Sebastian Pop <sebastian.pop@amd.com>
325 * graphite-dependences.c (map_into_dep_poly): Removed.
326 (dependence_polyhedron_1): Use combine_context_id_scat.
328 2010-03-04 Sebastian Pop <sebastian.pop@amd.com>
330 * graphite-poly.h (struct poly_scattering): Add layout documentation.
331 (struct poly_bb): Same.
332 (combine_context_id_scat): New.
334 2010-03-02 Sebastian Pop <sebastian.pop@amd.com>
337 * sese.c (name_defined_in_loop_p): Return false for default
340 * gcc.dg/graphite/pr42326.c: New.
342 2010-02-23 Sebastian Pop <sebastian.pop@amd.com>
344 * graphite-clast-to-gimple.c (find_cloog_iv_in_expr): Simplify
345 and clean up the logic.
347 2010-02-23 Sebastian Pop <sebastian.pop@amd.com>
349 * graphite-sese-to-poly.c (add_param_constraints): Enabled: remove
352 2010-02-22 Sebastian Pop <sebastian.pop@amd.com>
355 * graphite-scop-detection.c (create_single_exit_edge): Move
356 the call to find_single_exit_edge to....
357 (create_sese_edges): ...here. Don't handle multiple edges
358 exiting the function.
359 (build_graphite_scops): Don't handle multiple edges
360 exiting the function.
362 * gcc.dg/graphite/pr43083.c: New.
364 2010-02-22 Sebastian Pop <sebastian.pop@amd.com>
367 * sese.c (get_rename): Assert that old_name is an SSA_NAME.
368 (rename_variables_in_stmt): Continue when the use is not an SSA_NAME.
370 * gfortran.dg/graphite/pr43097.f: New.
372 2010-02-22 Sebastian Pop <sebastian.pop@amd.com>
375 * graphite-scop-detection.c (create_single_exit_edge): Move
376 the call to find_single_exit_edge to....
377 (create_sese_edges): ...here. Don't handle multiple edges
378 exiting the function.
379 (build_graphite_scops): Don't handle multiple edges
380 exiting the function.
382 * gcc.dg/graphite/pr43083.c: New.
384 2010-02-22 Sebastian Pop <sebastian.pop@amd.com>
387 * sese.c (get_rename): Assert that old_name is an SSA_NAME.
388 (rename_variables_in_stmt): Continue when the use is not an SSA_NAME.
390 * gfortran.dg/graphite/pr43097.f: New.
392 2010-02-22 Sebastian Pop <sebastian.pop@amd.com>
393 Manuel López-Ibáñez <manu@gcc.gnu.org>
396 * g++.dg/graphite/pr41305.C: Add -Wno-conversion-null.
398 2010-02-22 Sebastian Pop <sebastian.pop@amd.com>
401 * sese.c (expand_scalar_variables_expr): Handle COMPONENT_REF.
403 * g++.dg/graphite/pr43026.C: New.
405 2010-02-13 Tobias Grosser <grosser@fim.uni-passau.de>
407 * Merge from mainline (154736:156693).
409 2010-02-11 Sebastian Pop <sebastian.pop@amd.com>
412 * sese.c (expand_scalar_variables_expr): Handle COMPONENT_REF.
414 * g++.dg/graphite/pr43026.C: New.
416 2010-02-13 Tobias Grosser <grosser@fim.uni-passau.de>
418 * Merge from mainline (154736:156693).
420 2010-02-11 Sebastian Pop <sebastian.pop@amd.com>
423 * gcc.dg/graphite/pr43012.c: New.
425 2010-02-10 Sebastian Pop <sebastian.pop@amd.com>
427 * graphite.c (graphite_transform_loops): Re-enable dbg_cnt.
429 2010-02-10 Sebastian Pop <sebastian.pop@amd.com>
431 * g++.dg/graphite/pr42930.C: New.
433 2010-02-10 Sebastian Pop <sebastian.pop@amd.com>
435 * graphite.c (graphite_transform_loops): Re-enable dbg_cnt.
437 2010-02-10 Sebastian Pop <sebastian.pop@amd.com>
439 * g++.dg/graphite/pr42930.C: New.
441 2010-02-10 Sebastian Pop <sebastian.pop@amd.com>
444 * graphite-scop-detection.c (graphite_can_represent_scev): Call
445 graphite_can_represent_init for MULT_EXPR.
447 2010-02-10 Sebastian Pop <sebastian.pop@amd.com>
451 * graphite-sese-to-poly.c (remove_phi): New.
452 (translate_scalar_reduction_to_array): Call remove_phi.
454 * gcc.dg/graphite/pr42530.c: New.
455 * gcc.dg/graphite/pr42914.c: New.
457 2010-02-10 Sebastian Pop <sebastian.pop@amd.com>
460 * graphite-scop-detection.c (graphite_can_represent_scev): Call
461 graphite_can_represent_init for MULT_EXPR.
463 2010-02-10 Sebastian Pop <seb@napoca>
467 * graphite-sese-to-poly.c (remove_phi): New.
468 (translate_scalar_reduction_to_array): Call remove_phi.
470 * gcc.dg/graphite/pr42530.c: New.
471 * gcc.dg/graphite/pr42914.c: New.
473 2010-02-10 Sebastian Pop <seb@napoca>
476 * graphite-clast-to-gimple.c (gloog): Call rename_sese_parameters.
477 * graphite-clast-to-gimple.h (gloog): Update declaration.
478 * graphite-poly.c (new_scop): Clear POLY_SCOP_P.
479 * graphite-poly.h (struct poly_bb): Add missing comments.
480 (struct scop): Add poly_scop_p field.
482 * graphite-sese-to-poly.c (build_poly_scop): Set POLY_SCOP_P.
483 * graphite.c (graphite_transform_loops): Build the polyhedral
484 representation for each scop before code generation.
485 * sese.c (rename_variables_in_operand): Removed.
486 (rename_variables_in_expr): Return the renamed expression.
487 (rename_sese_parameters): New.
488 * sese.h (rename_sese_parameters): Declared.
490 * gcc.dg/graphite/pr42771.c: New.
492 2010-02-07 Sebastian Pop <sebastian.pop@amd.com>
494 * gcc.dg/graphite/block-0.c: Call abort for runtime test. Always
496 * gcc.dg/graphite/block-1.c: Same.
497 * gcc.dg/graphite/block-3.c: Same.
498 * gcc.dg/graphite/block-4.c: Same.
499 * gcc.dg/graphite/block-5.c: Same.
500 * gcc.dg/graphite/block-6.c: Same.
501 * gcc.dg/graphite/block-7.c: Same.
502 * gcc.dg/graphite/interchange-0.c: Same.
503 * gcc.dg/graphite/interchange-1.c: Same.
504 * gcc.dg/graphite/interchange-10.c: Same.
505 * gcc.dg/graphite/interchange-11.c: Same.
506 * gcc.dg/graphite/interchange-12.c: Same.
507 * gcc.dg/graphite/interchange-2.c: Same.
508 * gcc.dg/graphite/interchange-3.c: Same.
509 * gcc.dg/graphite/interchange-4.c: Same.
510 * gcc.dg/graphite/interchange-5.c: Same.
511 * gcc.dg/graphite/interchange-6.c: Same.
512 * gcc.dg/graphite/interchange-7.c: Same.
513 * gcc.dg/graphite/interchange-8.c: Same.
514 * gcc.dg/graphite/interchange-9.c: Same.
515 * gcc.dg/graphite/interchange-mvt.c: Same.
517 2010-02-07 Sebastian Pop <sebastian.pop@amd.com>
519 * gfortran.dg/graphite/id-19.f: New.
520 * gfortran.dg/graphite/pr14741.f90: New.
521 * gfortran.dg/graphite/pr41924.f90: New.
522 * gfortran.dg/graphite/run-id-2.f90: New.
524 2010-02-07 Sebastian Pop <sebastian.pop@amd.com>
527 * graphite-dependences.c (dependence_polyhedron): Set PDDR_KIND
528 to unknown_dependence.
529 (graphite_legal_transform_dr): Handle the unknown_dependence.
530 (graphite_carried_dependence_level_k): Same.
532 2010-02-07 Sebastian Pop <sebastian.pop@amd.com>
534 * gcc.dg/graphite/block-0.c: Call abort for runtime test. Always
536 * gcc.dg/graphite/block-1.c: Same.
537 * gcc.dg/graphite/block-3.c: Same.
538 * gcc.dg/graphite/block-4.c: Same.
539 * gcc.dg/graphite/block-5.c: Same.
540 * gcc.dg/graphite/block-6.c: Same.
541 * gcc.dg/graphite/block-7.c: Same.
542 * gcc.dg/graphite/interchange-0.c: Same.
543 * gcc.dg/graphite/interchange-1.c: Same.
544 * gcc.dg/graphite/interchange-10.c: Same.
545 * gcc.dg/graphite/interchange-11.c: Same.
546 * gcc.dg/graphite/interchange-12.c: Same.
547 * gcc.dg/graphite/interchange-2.c: Same.
548 * gcc.dg/graphite/interchange-3.c: Same.
549 * gcc.dg/graphite/interchange-4.c: Same.
550 * gcc.dg/graphite/interchange-5.c: Same.
551 * gcc.dg/graphite/interchange-6.c: Same.
552 * gcc.dg/graphite/interchange-7.c: Same.
553 * gcc.dg/graphite/interchange-8.c: Same.
554 * gcc.dg/graphite/interchange-9.c: Same.
555 * gcc.dg/graphite/interchange-mvt.c: Same.
557 2010-02-07 Sebastian Pop <sebastian.pop@amd.com>
559 * gfortran.dg/graphite/id-19.f: New.
560 * gfortran.dg/graphite/pr14741.f90: New.
561 * gfortran.dg/graphite/pr41924.f90: New.
562 * gfortran.dg/graphite/run-id-2.f90: New.
564 2010-02-07 Sebastian Pop <sebastian.pop@amd.com>
567 * graphite-dependences.c (dependence_polyhedron): Set PDDR_KIND
568 to unknown_dependence.
569 (graphite_legal_transform_dr): Handle the unknown_dependence.
570 (graphite_carried_dependence_level_k): Same.
572 2010-02-07 Sebastian Pop <sebastian.pop@amd.com>
574 * ChangeLog.graphite: Remove testsuite/ or gcc/testsuite/.
576 2010-02-05 Sebastian Pop <sebastian.pop@amd.com>
577 Konrad Trifunovic <konrad.trifunovic@inria.fr>
580 * graphite-dependences.c (build_lexicographical_constraint): Return
581 a union of dependence polyhedra.
582 (dependence_polyhedron_1): Adapt for build_lexicographical_constraint.
584 * gcc.dg/graphite/block-0.c: Enable runtime check. XFAILed.
585 * gcc.dg/graphite/block-4.c: Same.
586 * gcc.dg/graphite/block-7.c: Same.
587 * gcc.dg/graphite/interchange-12.c: Same.
588 * gcc.dg/graphite/interchange-mvt.c: Same.
589 * gfortran.dg/graphite/interchange-1.f: XFAILed.
590 * gfortran.dg/graphite/interchange-3.f90: XFAILed.
591 * gfortran.dg/graphite/run-id-1.f: New testcase for PR42637.
593 2010-02-03 Sebastian Pop <sebastian.pop@amd.com>
595 * gcc.dg/graphite/interchange-12.c: Return 0 to avoid
596 the execution check to FAIL. This testcase is miscompiled by Graphite
597 and the check should be re-enabled.
598 * gcc.dg/graphite/interchange-mvt.c: Same.
599 * gcc.dg/graphite/block-0.c: Same.
600 * gcc.dg/graphite/block-4.c: Same.
601 * gcc.dg/graphite/block-7.c: Same.
603 2010-02-03 Sebastian Pop <sebastian.pop@amd.com>
605 * gcc.dg/graphite/interchange-mvt.c: Un-XFAILed.
606 * gcc.dg/graphite/scop-0.c: Fix spaces.
607 * gfortran.dg/graphite/block-1.f90: Rewrite expected output.
608 * gfortran.dg/graphite/block-2.f: Same.
609 * gfortran.dg/graphite/block-3.f90: Same.
610 * gfortran.dg/graphite/block-4.f90: Same.
611 * gfortran.dg/graphite/interchange-1.f: Un-XFAILed.
612 * gfortran.dg/graphite/interchange-3.f90: Un-XFAILed.
614 2010-02-03 Sebastian Pop <sebastian.pop@amd.com>
616 * graphite-dependences.c (new_poly_ddr): Initialize PDDR_KIND and
617 PDDR_ORIGINAL_SCATTERING_P.
618 (pddr_is_empty): Rewritten.
619 (print_dependence_polyhedron_layout): New.
622 (build_alias_set_powerset): Moved up.
623 (poly_drs_may_alias_p): Moved up.
624 (lexicographically_gt_p): Removed.
625 (build_lexicographically_gt_constraint): Renamed
626 build_lexicographical_constraint, reimplemented.
627 (dependence_polyhedron_1): Simplified parameters.
628 (dependence_polyhedron): Same. Keep along empty PDDRs
629 to make efficient use of the cache.
630 (reduction_dr_p): Compute the PBBs don't pass them as parameters.
631 (graphite_legal_transform_dr): Rewritten.
632 (graphite_legal_transform_bb): Pass fewer arguments to
633 graphite_legal_transform_dr.
634 (graphite_carried_dependence_level_k): Simplified implementation.
635 (dot_original_deps_stmt_1): Call dependence_polyhedron.
636 (dot_transformed_deps_stmt_1): Same.
637 (dot_original_deps): Same.
638 (dot_transformed_deps): Same.
639 * graphite-dependences.h (struct poly_ddr): Added a new field
640 original_scattering_p.
641 (PDDR_ORIGINAL_SCATTERING_P): New.
642 (print_pddr): Declared.
643 (debug_pddr): Declared.
644 * graphite-ppl.c: Clarify comment.
645 * sese.h (print_gimple_bb): Removed unused declaration.
648 2010-02-03 Sebastian Pop <sebastian.pop@amd.com>
650 * g++.dg/graphite/graphite.exp: Rewritten.
651 * gcc.dg/graphite/graphite.exp: Rewritten.
652 * gfortran.dg/graphite/graphite.exp: Rewritten.
653 * gcc.dg/graphite/block-0.c: Added runtime test.
654 * gcc.dg/graphite/block-1.c: Same.
655 * gcc.dg/graphite/block-3.c: Same.
656 * gcc.dg/graphite/block-4.c: Same.
657 * gcc.dg/graphite/block-5.c: Same.
658 * gcc.dg/graphite/block-6.c: Same.
659 * gcc.dg/graphite/block-7.c: Same.
660 * gcc.dg/graphite/interchange-0.c: Same.
661 * gcc.dg/graphite/interchange-1.c: Same.
662 * gcc.dg/graphite/interchange-10.c: Same.
663 * gcc.dg/graphite/interchange-11.c: Same.
664 * gcc.dg/graphite/interchange-12.c: Same.
665 * gcc.dg/graphite/interchange-2.c: Same.
666 * gcc.dg/graphite/interchange-3.c: Same.
667 * gcc.dg/graphite/interchange-4.c: Same.
668 * gcc.dg/graphite/interchange-5.c: Same.
669 * gcc.dg/graphite/interchange-6.c: Same.
670 * gcc.dg/graphite/interchange-7.c: Same.
671 * gcc.dg/graphite/interchange-8.c: Same.
672 * gcc.dg/graphite/interchange-9.c: Same.
673 * gcc.dg/graphite/interchange-mvt.c: Same.
674 * gcc.dg/graphite/run-id-2.c: Remove useless dg-do run.
676 2010-01-22 Ramakrishna Upadrasta <Ramakrishna.Upadrasta@inria.fr>
678 * graphite-scop-detection.c (dot_all_scops): Make calls to dot run in
681 2010-01-22 Ramakrishna Upadrasta <Ramakrishna.Upadrasta@inria.fr>
683 * common.opt: Add -fgraphite-cloog-opts.
684 * graphite-clast-to-gimple.c (set_cloog_options): Same.
685 * opts.c (decode_options): Same.
687 2010-01-20 Sebastian Pop <sebastian.pop@amd.com>
689 * gcc.dg/graphite/id-17.c: New.
690 * gcc.dg/graphite/pr41888.c: New.
691 * gcc.dg/graphite/scop-22.c: New.
692 * gfortran.dg/graphite/pr40982.f90: New.
694 2010-01-20 Sebastian Pop <sebastian.pop@amd.com>
696 * testsuite/gcc.dg/graphite/id-17.c: New.
697 * testsuite/gcc.dg/graphite/pr41888.c: New.
698 * testsuite/gcc.dg/graphite/scop-22.c: New.
699 * testsuite/gfortran.dg/graphite/pr40982.f90: New.
701 2010-01-20 Sebastian Pop <sebastian.pop@amd.com>
703 * graphite-dependences.c: Clarify comments.
704 (build_pddr): Add an extra parameter direction.
705 (graphite_legal_transform_dr): Use build_pddr.
706 (dot_original_deps_stmt_1): Update use of build_pddr.
707 (dot_transformed_deps_stmt_1): Same.
708 (dot_original_deps): Same.
709 (dot_transformed_deps): Same.
711 * gcc.dg/graphite/interchange-12.c: New.
712 * gcc.dg/graphite/block-7.c: New.
714 2010-01-20 Sebastian Pop <sebastian.pop@amd.com>
716 * graphite-dependences.c (pddr_original_scattering): Renamed build_pddr.
717 (pddr_transformed_scattering): Removed.
718 (graphite_legal_transform_dr): Use build_pddr.
719 (dot_original_deps_stmt_1): Same.
720 (dot_transformed_deps_stmt_1): Same.
721 (dot_original_deps): Same.
722 (dot_transformed_deps): Same.
724 2010-01-20 Sebastian Pop <sebastian.pop@amd.com>
726 * graphite-dependences.c (lexicographically_gt_p): Add comments.
727 (build_lexicographically_gt_constraint): Same.
728 (dependence_polyhedron_1): Same.
729 (dependence_polyhedron): Same.
731 2010-01-20 Sebastian Pop <sebastian.pop@amd.com>
733 * graphite-dependences.c (build_pairwise_scheduling_equality): Removed.
734 (build_pairwise_scheduling_inequality): Renamed build_pairwise_scheduling.
735 (lexicographically_gt_p): Change type of direction to int.
736 (build_lexicographically_gt_constraint): Same.
737 (dependence_polyhedron_1): Same.
738 (dependence_polyhedron): Same.
739 (pddr_original_scattering): Use integers for direction.
740 (pddr_transformed_scattering): Same.
741 (graphite_legal_transform_dr): Same.
742 (graphite_carried_dependence_level_k): Same.
744 2010-01-20 Sebastian Pop <sebastian.pop@amd.com>
746 * graphite-dependences.c (build_pairwise_constraint): Renamed
747 ppl_build_relation. Moved...
748 (dr_equality_constraints): Use ppl_build_relation.
749 (build_pairwise_scheduling_equality): Same.
750 (build_pairwise_scheduling_inequality): Same.
751 * graphite-ppl.c (ppl_build_relation): ...here.
752 * graphite-ppl.h (ppl_build_relation): Declared.
754 2010-01-14 Sebastian Pop <sebastian.pop@amd.com>
757 * graphite-clast-to-gimple.c (gloog_error): New static variable.
758 (clast_to_gcc_expression): Do not build MULT_EXPR of POINTER_TYPE_P.
759 Set gloog_error when such an expression failed to be built.
760 (translate_clast): Early return when gloog_error is set.
761 (gloog): Clear gloog_error. When gloog_error is set, call
762 set_ifsese_condition to enable the original code. Return the status
763 of the code generation based on gloog_error.
764 * sese.c (set_ifsese_condition): New.
765 * sese.h (set_ifsese_condition): Declared.
767 * g++.dg/graphite/pr42681.C: New.
769 2010-01-14 Sebastian Pop <sebastian.pop@amd.com>
772 * graphite-clast-to-gimple.c (gloog_error): New static variable.
773 (clast_to_gcc_expression): Do not build MULT_EXPR of POINTER_TYPE_P.
774 Set gloog_error when such an expression failed to be built.
775 (translate_clast): Early return when gloog_error is set.
776 (gloog): Clear gloog_error. When gloog_error is set, call
777 set_ifsese_condition to enable the original code. Return the status
778 of the code generation based on gloog_error.
779 * sese.c (set_ifsese_condition): New.
780 * sese.h (set_ifsese_condition): Declared.
782 * testsuite/g++.dg/graphite/pr42681.C: New.
784 2010-01-14 Sebastian Pop <sebastian.pop@amd.com>
787 * graphite-clast-to-gimple.c (gloog): Call scev_reset_htab and
788 rename_nb_iterations.
789 * sese.c (rename_variables_in_operand): New.
790 (rename_variables_in_expr): New.
791 (rename_nb_iterations): New.
792 (sese_adjust_liveout_phis): Update the rename_map.
793 * sese.h (rename_nb_iterations): Declared.
794 * tree-scalar-evolution.c (scev_reset_htab): New.
795 (scev_reset): Call scev_reset_htab.
796 * tree-scalar-evolution.h (scev_reset_htab): Declared.
798 * gfortran.dg/graphite/pr42732.f: New.
800 2010-01-08 Sebastian Pop <sebastian.pop@amd.com>
803 * graphite-clast-to-gimple.c: Fix formatting.
804 * sese.c (defined_in_loop_p): Renamed name_defined_in_loop_p.
805 (expr_defined_in_loop_p): New.
806 (add_loop_exit_phis): Also handle full expressions: remove from
807 the rename_map the expressions defined in the loop that we're closing.
809 * gfortran.dg/graphite/pr42393-1.f90: New.
810 * gfortran.dg/graphite/pr42393.f90: Add new flags
811 -fno-loop-block -fno-loop-interchange -fno-loop-strip-mine to also
812 make this testcase useful in the Graphite branch.
814 2010-01-08 Sebastian Pop <sebastian.pop@amd.com>
817 * graphite-clast-to-gimple.c: Fix formatting.
818 * sese.c (defined_in_loop_p): Renamed name_defined_in_loop_p.
819 (expr_defined_in_loop_p): New.
820 (add_loop_exit_phis): Also handle full expressions: remove from
821 the rename_map the expressions defined in the loop that we're closing.
823 * testsuite/gfortran.dg/graphite/pr42393-1.f90: New.
824 * testsuite/gfortran.dg/graphite/pr42393.f90: Add new flags
825 -fno-loop-block -fno-loop-interchange -fno-loop-strip-mine to also
826 make this testcase useful in the Graphite branch.
828 2010-01-08 Sebastian Pop <sebastian.pop@amd.com>
830 * graphite-scop-detection.c (exclude_component_ref): Removed.
831 (is_simple_operand): Removed.
832 (stmt_simple_for_scop_p): Remove use of is_simple_operand.
834 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
837 * sese.c (expand_scalar_variables_expr): Follow the SSA links into
838 the array indexing of ADDR_EXPRs.
840 * gcc.dg/graphite/pr42221.c: New.
842 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
845 * sese.c (expand_scalar_variables_expr): Follow the SSA links into
846 the array indexing of ADDR_EXPRs.
848 * testsuite/gcc.dg/graphite/pr42221.c: New.
850 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
853 * graphite.c (graphite_finalize): Call scev_reset.
854 (graphite_transform_loops): Do not call scev_reset between the code
857 * gcc.dg/graphite/pr42521.c: New.
859 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
861 * graphite-interchange.c (memory_stride_in_loop): Renamed
863 (memory_strides_in_loop): Renamed memory_strides_in_loop_1.
864 (memory_strides_in_loop): Memoize the memory strides per loop.
865 (lst_interchange_profitable_p): Do not initialize to zero the memory
867 * graphite-poly.h (struct lst): Add a field memory_strides.
868 (LST_LOOP_MEMORY_STRIDES): New.
869 (new_lst_loop): Initialize LST_LOOP_MEMORY_STRIDES to -1.
870 (free_lst): Clear LST_LOOP_MEMORY_STRIDES.
872 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
874 * graphite-interchange.c (memory_stride_in_loop): Renamed
876 (memory_strides_in_loop): Renamed memory_strides_in_loop_1.
877 (memory_strides_in_loop): Memoize the memory strides per loop.
878 (lst_interchange_profitable_p): Do not initialize to zero the memory
880 * graphite-poly.h (struct lst): Add a field memory_strides.
881 (LST_LOOP_MEMORY_STRIDES): New.
882 (new_lst_loop): Initialize LST_LOOP_MEMORY_STRIDES to -1.
883 (free_lst): Clear LST_LOOP_MEMORY_STRIDES.
885 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
887 * graphite-interchange.c (memory_strides_in_loop_depth): Renamed
888 memory_strides_in_loop. Gather memory strides on a whole loop.
889 (pbb_interchange_profitable_p): Renamed lst_interchange_profitable_p.
890 (lst_interchange_profitable_p): Removed.
891 (lst_try_interchange_loops): Call lst_interchange_profitable_p.
893 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
895 Revert patch 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
896 * graphite-clast-to-gimple.c (try_mark_loop_parallel): New.
897 (translate_clast_for, translate_clast_guard, translate_clast, gloog):
898 Remove context_loop and level.
900 2010-01-07 Richard Guenther <rguenther@suse.de>
902 PR tree-optimization/42641
903 * sese.c (rename_map_elt_info): Use the SSA name version, do
906 2010-01-06 Sebastian Pop <sebastian.pop@amd.com>
908 * graphite-blocking.c (scop_do_block): Print "SCoP will be loop
909 blocked" only when both the strip mine and the interchange have
912 * gcc.dg/graphite/block-2.c: Removed.
913 * gcc.dg/graphite/block-3.c: Add scan pattern.
914 * gcc.dg/graphite/block-4.c: Same.
915 * gcc.dg/graphite/block-5.c: Same.
916 * gcc.dg/graphite/block-6.c: Same.
918 2010-01-06 Sebastian Pop <sebastian.pop@amd.com>
920 * graphite-clast-to-gimple.c (save_clast_name_index): Free slot
921 before allocating a new one.
922 (copy_renames): Check that slot is not NULL.
923 (mark_bb_with_pbb): Same.
924 (compute_cloog_iv_types_1): Same.
925 * graphite-interchange.c (lst_perfect_nestify): Free the before,
926 nest, and after LSTs.
927 (lst_try_interchange_loops): Same.
929 2010-01-05 Sebastian Pop <sebastian.pop@amd.com>
932 * graphite-interchange.c (lst_try_interchange_loops): Do not return
933 the before, nest, and after LSTs.
934 (lst_try_interchange): Removed.
935 (lst_interchange_select_inner): Do not iterate over the LSTs if they
937 (lst_interchange_select_outer): Apply interchange on the outer loop
938 until there are no more changes in the inner loops.
940 2009-12-18 Sebastian Pop <sebastian.pop@amd.com>
942 Revert patch fixing PR middle-end/42221.
944 2009-12-18 Sebastian Pop <sebastian.pop@amd.com>
947 * graphite-sese-to-poly.c (follow_ssa_with_commutative_ops): Handle
950 * gfortran.dg/graphite/pr42180.f90: Add compile flags.
952 2009-12-18 Sebastian Pop <sebastian.pop@amd.com>
955 * graphite-sese-to-poly.c (split_reduction_stmt): Do not split blocks
956 that contain only one statement.
958 * gfortran.dg/graphite/pr42180.f90: New.
960 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
963 * gfortran.dg/graphite/pr42393.f90: New.
965 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
968 * gfortran.dg/graphite/pr42186.f90: New.
970 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
973 * testsuite/gfortran.dg/graphite/pr42186.f90: New.
975 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
978 * graphite-sese-to-poly.c (translate_scalar_reduction_to_array_for_stmt):
979 Insert the reduction copy in the same block as the phi node.
980 (follow_ssa_with_commutative_ops): Handle GIMPLE_NOPs.
982 * gcc.dg/graphite/pr42205-1.c: New.
983 * gcc.dg/graphite/pr42205-2.c: New.
985 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
988 * sese.c (expand_scalar_variables_expr): Follow the SSA links into
989 the array indexing of ADDR_EXPRs.
991 * gcc.dg/graphite/pr42221.c: New.
993 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
997 * graphite-interchange.c (lst_try_interchange): Do not modify OUTER
998 index. Call lst_interchange_select_inner only once.
999 (lst_interchange_select_inner): Update use of lst_try_interchange.
1000 (lst_interchange_select_outer): Update.
1002 2009-12-15 Sebastian Pop <sebastian.pop@amd.com>
1006 * graphite-interchange.c (lst_try_interchange): Do not increment the
1007 the OUTER index when there is no AFTER kernel. Do not increment the
1008 OUTER index for after processing the AFTER kernel.
1009 (lst_interchange_select_inner): Call lst_try_interchange only on loops.
1010 (lst_interchange_select_outer): Do not pass in a pointer to the OUTER
1011 index. Do not pass to lst_interchange_select_inner the OUTER index.
1012 (scop_do_interchange): Update use of lst_interchange_select_outer.
1014 * gfortran.dg/graphite/graphite.exp
1015 (DEFAULT_FLAGS_GRAPHITE_IDENTITY): Remove -fdump-tree-graphite-all.
1016 * gfortran.dg/graphite/interchange-1.f: Add comment. Clean
1017 the graphite dump file.
1018 * gfortran.dg/graphite/interchange-2.f: Same.
1019 * gfortran.dg/graphite/pr42334-1.f: New.
1021 2009-12-15 Sebastian Pop <sebastian.pop@amd.com>
1025 * graphite-interchange.c (lst_perfect_nestify): Reset to NULL the LSTs
1027 (lst_do_interchange_1): Renamed lst_interchange_select_inner.
1028 (lst_try_interchange): Reimplemented.
1029 (lst_interchange_select_inner): Same.
1030 (lst_do_interchange): Renamed lst_interchange_select_outer.
1032 (scop_do_interchange): Update use of lst_interchange_select_outer.
1034 * g++.dg/graphite/pr42130.C: Add -fgraphite-identity.
1035 * gcc.dg/graphite/block-0.c: Un-XFAILed.
1036 * gcc.dg/graphite/pr42211.c: New.
1037 * gfortran.dg/graphite/pr42334.f90: New.
1039 2009-12-14 Sebastian Pop <sebastian.pop@amd.com>
1042 * graphite-scop-detection.c (graphite_can_represent_scev): Handle more
1043 carefully PLUS_EXPR, MINUS_EXPR, and MULT_EXPR.
1045 * gfortran.dg/graphite/pr42181.f90: New.
1047 2009-12-12 Sebastian Pop <sebpop@gmail.com>
1050 * graphite-sese-to-poly.c (rewrite_close_phi_out_of_ssa): Call
1051 insert_out_of_ssa_copy_on_edge for anything else than SSA_NAMEs.
1052 (detect_commutative_reduction_arg): Simplified.
1053 (detect_commutative_reduction): Early return when the argument of
1054 the close phi is not of an SSA_NAME.
1056 * gcc.dg/graphite/pr42284.c: New.
1058 2009-12-11 Alexander Monakov <amonakov@ispras.ru>
1060 * dbgcnt.def (graphite_scop): New counter.
1061 * graphite.c: Include dbgcnt.h
1062 (graphite_transform_loops): Use new counter to limit transformations.
1064 2009-12-08 Sebastian Pop <sebpop@gmail.com>
1067 * graphite-scop-detection.c (graphite_can_represent_init): Also
1068 handle more complex MULT_EXPRs containing parameters by recursion
1071 * gfortran.dg/graphite/pr42285.f90: New.
1073 2009-12-01 Tobias Grosser <grosser@fim.uni-passau.de>
1075 * g++.dg/graphite/pr42130.C: Fix type.
1077 2009-11-29 Alexander Monakov <amonakov@gcc.gnu.org>
1079 * g++.dg/graphite/pr42130.C: Correct testcase.
1081 2009-11-28 Tobias Grosser <grosser@fim.uni-passau.de>
1083 * Merge from mainline (154493:154734).
1085 2009-11-28 Tobias Grosser <grosser@fim.uni-passau.de>
1087 * Merge from mainline (151362:154491).
1089 2009-11-24 Tobias Grosser <grosser@fim.uni-passau.de>
1091 * graphite-clast-to-gimple.c (try_mark_loop_parallel,
1092 graphite_create_new_loop_guard, translate_clast_for): Fix comments.
1094 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
1097 * graphite-clast-to-gimple.c (graphite_create_new_loop_guard,
1098 translate_clast_for_loop): New.
1099 (translate_clast_for): Add a condition around the loop, to do not
1100 execute loops with zero iterations.
1101 * g++.dg/graphite/pr42130.C: New.
1102 * gcc.dg/graphite/pr35356-2.c: Adapt.
1104 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
1106 * graphite-clast-to-gimple.c (try_mark_loop_parallel): New.
1107 (translate_clast_for, translate_clast_guard, translate_clast, gloog):
1108 Remove context_loop and level.
1110 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
1112 * graphite-clast-to-gimple.c (translate_clast_user,
1113 translate_clast_for, translate_clast_guard): Simplify and move common
1114 elements to translate_clast().
1115 (translate_clast): Simplify and get common elements.
1117 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
1119 * graphite-clast-to-gimple.c (translate_clast_user,
1120 translate_clast_for, translate_clast_guard): Split out of
1123 2009-11-21 Tobias Grosser <grosser@fim.uni-passau.de>
1125 * graphite-clast-to-gimple.c (clast_name_index, new_clast_name_index,
1126 clast_name_to_index, save_clast_name_index, debug_clast_name_index,
1127 debug_clast_name_indexes_1, debug_clast_name_indexes,
1128 clast_name_index_elt_info, eq_clast_name_indexes): Moved from sese.h.
1129 (clast_name_to_gcc, clast_to_gcc_expression,
1130 clast_to_gcc_expression_red, gcc_type_for_clast_expr,
1131 gcc_type_for_clast_eq, graphite_translate_clast_equation,
1132 graphite_create_guard_cond_expr, graphite_create_new_loop,
1133 translate_clast): Add params_index.
1134 (initialize_cloog_names): Create parameter strings from scratch, do
1135 not reference other strings.
1136 (create_params_index): New.
1137 (gloog): Initialize params_index.
1138 * graphite-scop-detection (free_scops_1): Removed.
1139 (limit_scops): Use normal free_scops.
1140 * graphite-sese-to-poly.c (save_var_names): Removed.
1141 (parameter_index_in_region): Do not initialize SESE_PARAM_NAMES
1142 and SESE_PARAMS_INDEX.
1143 * sese.c (new_sese, free_sese): Dito.
1144 * sese.h (struct sese): Remove params_index, params_names.
1145 (SESE_PARAMS_INDEX, SESE_PARAMS_NAMES): Removed.
1147 2009-11-20 Sebastian Pop <sebastian.pop@amd.com>
1149 Revert the following patch from 2009-09-14:
1150 * graphite-blocking.c: Fix order of includes: tree-chrec.h, then
1151 tree-scalar-evolution.h, and then tree-data-ref.h.
1152 * graphite-clast-to-gimple.c: Same.
1153 * graphite-dependences.c: Same.
1154 * graphite-interchange.c: Same.
1155 * graphite-poly.c: Same.
1156 * graphite-scop-detection.c: Same.
1157 * graphite-sese-to-poly.c: Same.
1159 * lambda-code.c: Same.
1160 * matrix-reorg.c: Same.
1161 * tree-data-ref.c: Same.
1162 * tree-if-conv.c: Same.
1163 * tree-loop-distribu: Same.: Same.
1164 * tree-loop-linear.c: Same.
1165 * tree-parloops.c: Same.
1166 * tree-predcom.c: Same.
1167 * tree-vect-patterns.c: Same.
1169 2009-11-20 Sebastian Pop <sebastian.pop@amd.com>
1171 Revert patch from 2009-09-14.
1172 * tree-ssa-loop.c (gate_graphite_transforms): Re-enable Graphite
1173 passes at -O1 and below.
1175 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
1178 * gcc.dg/graphite/pr40281.c: New.
1180 * tree-scalar-evolution.c (instantiate_scev_poly): Base and stride
1181 evolutions should not variate in inner loops.
1183 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
1186 * gfortran.dg/graphite/pr42050.f90: New.
1188 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
1190 * graphite-interchange.c (memory_strides_in_loop_depth): New.
1191 (pbb_interchange_profitable_p): Call memory_strides_in_loop_depth.
1193 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
1195 * graphite-blocking.c (scop_do_block): New.
1196 * graphite-poly.c (apply_poly_transforms): Call scop_do_block.
1197 * graphite-poly.h (scop_do_block): Declared.
1199 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
1201 * graphite-blocking.c (pbb_strip_mine_profitable_p): The parameter
1202 depth is the loop nesting depth in the LST. Call psct_dynamic_dim
1203 to transform depth into the time_depth before calling
1204 pbb_number_of_iterations_at_time.
1205 (lst_do_strip_mine): Use a scalar variable instead of recomputing
1208 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
1210 Reverted the patch for "scattering permutations" from 2009-10-28.
1212 * graphite-poly.c (print_permutation): New.
1213 (debug_permutation): New.
1214 (new_poly_bb): Initialize PBB_PERMUTATION.
1215 (free_poly_bb): Free PBB_PERMUTATION.
1216 * graphite-poly.h (pbb_permutation_elt_p): Declared.
1217 (struct pbb_permutation_elt): New.
1218 (PBB_PERMUTATION_ELT_STRIDE): New.
1219 (PBB_PERMUTATION_ELT_STRIDED_P): New.
1220 (PBB_PERMUTATION_ELT_TIME_DIMENSION): New.
1221 (new_pbb_permutation_elt): New.
1222 (pbb_permutation_elt_free): New.
1223 (struct poly_bb): Add field permutation.
1224 (PBB_PERMUTATION): New.
1225 (print_permutation): Declared.
1226 (debug_permutation): Declared.
1228 2009-11-04 Konrad Trifunovic <konrad.trifunovic@inria.fr>
1230 * graphite-interchange.c (build_partial_difference): New.
1231 (memory_stride_in_loop): Refactored the computation of
1232 equality constraints into build_partial_difference function.
1233 Added support for debugging stride computations.
1235 2009-11-03 Sebastian Pop <sebastian.pop@amd.com>
1237 * graphite-clast-to-gimple.c (gloog): Free if_region,
1238 if_region->true_region, and if_region->region.
1239 * sese.c (if_region_set_false_region): Free if_region->false_region.
1240 (create_if_region_on_edge): Do not use GGC_NEW.
1241 (move_sese_in_condition): Remove useless initialization.
1243 2009-11-03 Sebastian Pop <sebastian.pop@amd.com>
1245 * graphite-interchange.c (lst_perfect_nestify): Pass 3 parameters
1246 for the loops created by the loop distribution. Do not modify the
1248 (lst_try_interchange_loops): Same. Use a temporary LST for the
1249 transformed schedule. Call lst_update_scattering before data
1250 dependence analysis.
1251 (lst_try_interchange): Pass an extra parameter INDEX.
1252 (lst_do_interchange_1): New.
1253 (lst_do_interchange): Call lst_do_interchange_1.
1254 (scop_do_interchange): Call lst_update_scattering.
1255 * graphite-poly.c (apply_poly_transforms): Do not call
1256 lst_update_scattering.
1257 * graphite-poly.h (lst_pred): New.
1259 (lst_find_first_pbb): Return NULL when not found.
1261 (lst_insert_in_sequence): Allow LST1 to be NULL.
1263 (lst_substitute_3): New.
1264 * gcc.dg/graphite/interchange-1.c: XFail.
1265 * gcc.dg/graphite/interchange-8.c: XFail.
1266 * gcc.dg/graphite/interchange-11.c: XFail.
1268 2009-10-30 Sebastian Pop <sebastian.pop@amd.com>
1270 * graphite-interchange.c (lst_perfectly_nested_p): New.
1271 (lst_perfect_nestify): New.
1272 (lst_try_interchange_loops): Call store_lst_schedule,
1273 lst_perfectly_nested_p, lst_perfect_nestify and restore_lst_schedule.
1274 (scop_do_interchange): Avoid redundant legality test.
1275 Call lst_do_interchange on a copy of SCOP_TRANSFORMED_SCHEDULE.
1276 * graphite-poly.c (apply_poly_transforms): Call lst_update_scattering.
1277 * graphite-poly.h (psct_static_dim): New.
1278 (lst_dewey_number_at_depth): New.
1279 (lst_find_pbb): Restructured.
1280 (lst_find_first_pbb): Restructured.
1281 (lst_find_last_pbb): New.
1282 (lst_contains_p): New.
1283 (lst_contains_pbb): New.
1284 (lst_create_nest): New.
1285 (lst_remove_from_sequence): New.
1286 (pbb_update_scattering): New.
1287 (lst_update_scattering_under): New.
1288 (lst_update_scattering_seq): New.
1289 (lst_update_scattering): New.
1290 (lst_insert_in_sequence): New.
1291 (lst_distribute_lst): New.
1292 (lst_remove_all_before_including_pbb): New.
1293 (lst_remove_all_before_excluding_pbb): New.
1295 2009-10-30 Sebastian Pop <sebastian.pop@amd.com>
1297 * tree-ssa-loop-niter.c (finite_loop_p): Do not call twice
1298 get_loop_exit_edges.
1300 2009-10-30 Sebastian Pop <sebastian.pop@amd.com>
1302 * graphite-poly.c (pbb_remove_duplicate_pdrs): Free collapsed.
1304 2009-10-28 Konrad Trifunovic <konrad.trifunovic@gmail.com>
1306 * graphite-poly.c (print_permutation): New.
1307 (debug_permutation): New.
1308 (new_poly_bb): Initialize PBB_PERMUTATION.
1309 (free_poly_bb): Free PBB_PERMUTATION.
1310 * graphite-poly.h (pbb_permutation_elt_p): Declared.
1311 (struct pbb_permutation_elt): New.
1312 (PBB_PERMUTATION_ELT_STRIDE): New.
1313 (PBB_PERMUTATION_ELT_STRIDED_P): New.
1314 (PBB_PERMUTATION_ELT_TIME_DIMENSION): New.
1315 (new_pbb_permutation_elt): New.
1316 (pbb_permutation_elt_free): New.
1317 (struct poly_bb): Add field permutation.
1318 (PBB_PERMUTATION): New.
1319 (print_permutation): Declared.
1320 (debug_permutation): Declared.
1322 2009-10-26 Sebastian Pop <sebastian.pop@amd.com>
1324 * graphite-clast-to-gimple.c (gloog): Do not call
1325 sese_reset_aux_in_loops.
1326 * graphite-sese-to-poly.c (build_loop_iteration_domains): Pass an
1327 extra argument for domains. Do not use loop->aux.
1328 (build_scop_iteration_domain): Initialize and free domains, pass it
1329 to build_loop_iteration_domains and extract the information from
1330 domains. Do not use loop->aux.
1331 * sese.c (sese_reset_aux_in_loops): Removed.
1332 * sese.h (sese_reset_aux_in_loops): Removed.
1334 2009-10-26 Sebastian Pop <sebastian.pop@amd.com>
1336 * graphite-clast-to-gimple.c (find_pbb_via_hash): Moved up.
1337 (dependency_in_loop_p): Same.
1338 (translate_clast): Do not use loop->aux. Initialize
1339 loop->can_be_parallel.
1340 (mark_loops_parallel): Removed.
1341 * graphite-clast-to-gimple.h (mark_loops_parallel): Removed.
1342 * graphite.c (free_aux_in_new_loops): Removed.
1343 (graphite_finalize): Do not call free_aux_in_new_loops.
1344 (graphite_transform_loops): Do not call mark_loops_parallel.
1346 2009-10-26 Li Feng <nemokingdom@gmail.com>
1348 * graphite-clast-to-gimple.c (get_stmtfor_depth): Removed.
1349 (translate_clast): Pass an extra parameter LEVEL.
1350 Call get_scattering_level.
1351 * graphite-clast-to-gimple.h (get_scattering_level): New.
1353 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
1355 * cfgloop.c (alloc_loop): Initialize loop->single_iv.
1356 * cfgloop.h (struct loop): New field single_iv.
1358 * graphite-clast-to-gimple.c (pbb_to_depth_to_oldiv): Do not use
1359 loop->aux anymore: use loop->single_iv.
1360 (graphite_loop_normal_form): Moved...
1361 (build_graphite_loop_normal_form): Removed.
1362 (gloog): Do not call build_graphite_loop_normal_form.
1363 (free_aux_in_new_loops): Moved...
1364 (mark_loops_parallel): Restructure.
1365 * graphite-clast-to-gimple.h (free_aux_in_new_loops): Do not declare.
1366 * graphite-sese-to-poly.c (graphite_loop_normal_form): ...here.
1367 (scop_canonicalize_loops): New.
1368 (build_poly_scop): Call scop_canonicalize_loops.
1369 * graphite.c (free_aux_in_new_loops): ...here.
1371 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
1373 * g++.dg/graphite/graphite.exp: Add the same rules as in
1374 gcc.dg/graphite/graphite.exp.
1376 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
1378 * g++.dg/graphite/id-1.C: New.
1380 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
1382 * graphite-sese-to-poly.c (create_zero_dim_array): Pass an extra
1384 (rewrite_close_phi_out_of_ssa): Update use of create_zero_dim_array.
1385 (rewrite_phi_out_of_ssa): Same.
1386 (rewrite_cross_bb_scalar_deps): Same.
1387 (translate_scalar_reduction_to_array): Same.
1389 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
1391 * graphite-sese-to-poly.c (build_scop_drs): Disable call to
1394 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
1396 * graphite-sese-to-poly.c (dump_alias_graphs): New.
1397 (build_scop_drs): Call dump_alias_graphs.
1399 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
1401 * graphite-poly.c (new_scop): Initialize SCOP_ORIGINAL_SCHEDULE,
1402 SCOP_TRANSFORMED_SCHEDULE, and SCOP_SAVED_SCHEDULE.
1403 (free_scop): Call free_lst on SCOP_ORIGINAL_SCHEDULE,
1404 SCOP_TRANSFORMED_SCHEDULE, and SCOP_SAVED_SCHEDULE.
1405 * graphite-poly.h (free_lst): New.
1406 (store_lst_schedule): Free SCOP_SAVED_SCHEDULE.
1407 (restore_lst_schedule): Free SCOP_TRANSFORMED_SCHEDULE.
1409 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
1411 * graphite-poly.h (struct scop): Add a field saved_schedule.
1412 (SCOP_SAVED_SCHEDULE): New.
1413 (store_lst_schedule): New.
1414 (restore_lst_schedule): New.
1415 (store_scattering): Call store_lst_schedule.
1416 (restore_scattering): Call restore_lst_schedule.
1418 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
1420 * graphite-sese-to-poly.c (free_data_refs_aux): Fix formatting.
1421 (pdr_add_alias_set): Same.
1422 (build_poly_dr): Same.
1423 (build_alias_set_optimal_p): Same.
1424 (build_base_obj_set_for_drs): Same. Do not store the result of
1427 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
1429 * graphite-sese-to-poly.c (build_alias_set_optimal_p): Initialize
1430 all_components_are_cliques to 1.
1432 2009-10-20 Li Feng <nemokingdom@gmail.com>
1434 * graphite-sese-to-poly.c (free_data_refs_aux): Update to free
1436 (pdr_add_alias_set): Update retrieving alias_set_num.
1437 (build_poly_dr): Update retrieving dr_base_object_set.
1438 (partition_drs_to_sets): Remove.
1439 (build_alias_set_optimal_p): New.
1440 (build_alias_set_for_drs): Rename.
1441 (build_scop_drs): Update.
1442 * graphite-sese-to-poly.h (struct base_alias_pair): New.
1443 (ALIAS_SET_INDEX): Remove.
1444 (BASE_OBJECT_SET_INDEX): Remove.
1446 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
1448 * sese.c (get_vdef_before_sese): Handle GIMPLE_ASSIGN and GIMPLE_CALL.
1450 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
1452 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Do not infer
1453 loop upper bounds for 1-element arrays at end of structures.
1454 * tree-flow.h (array_at_struct_end_p): Declared.
1455 * tree-ssa-loop-niter.c (array_at_struct_end_p): Not static anymore.
1457 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
1459 * g++.dg/graphite/pr41305.C: New.
1461 2009-10-20 Alexander Monakov <amonakov@ispras.ru>
1463 * graphite-sese-to-poly.c (build_loop_iteration_domains): Generalize
1464 construction of parameter constraints from loop iteration analysis.
1465 * gcc.dg/graphite/run-id-2.c: New test.
1467 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
1469 * graphite-interchange.c (memory_stride_in_loop): Delete p1, lma
1472 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
1474 * graphite-dependences.c (dependence_polyhedron_1): Remove
1475 unused gdim dimensions from the DDR polyhedron.
1477 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
1479 * graphite-dependences.c (pddr_transformed_scattering): New.
1480 (dot_original_deps_stmt_1): New.
1481 (dot_transformed_deps_stmt_1): New.
1482 (dot_deps_stmt_1): Call dot_original_deps_stmt_1 and
1483 dot_transformed_deps_stmt_1.
1484 (dot_original_deps): New.
1485 (dot_transformed_deps): New.
1486 (dot_deps_1): Call dot_original_deps and dot_transformed_deps.
1488 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
1490 * graphite-dependences.c (reduction_dr_1): Remove wrong
1491 assert: reduction BBs can have multiple reduction writes
1492 to memory. interchange-3.f90 is an example.
1494 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
1496 * gfortran.dg/graphite/interchange-3.f90: New.
1498 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
1500 * gcc.dg/graphite/interchange-1.c: Un-XFAILed.
1502 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
1504 * graphite-dependences.c (dependence_polyhedron_1): Add the
1505 context to the dependence polyhedron.
1507 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
1509 * graphite-poly.c (pbb_remove_duplicate_pdrs): Initialize
1510 PBB_PDR_DUPLICATES_REMOVED.
1511 (new_poly_bb): Same.
1513 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
1515 * graphite-sese-to-poly.c (find_scop_parameters): Initialize
1517 (build_loop_iteration_domains): Extract bounds on parameters
1518 based on the data size.
1519 (build_scop_context): Do not initialize SCOP_CONTEXT;
1520 add new constraints.
1522 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
1524 * graphite-ppl.c (ppl_min_for_le_polyhedron): New.
1525 * graphite-ppl.h (graphite-ppl.h): Declared.
1527 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
1529 * graphite-ppl.c (ppl_print_linear_expr): New.
1530 (debug_ppl_linear_expr): New.
1531 * graphite-ppl.h (ppl_print_linear_expr): Declared.
1532 (debug_ppl_linear_expr): Declared.
1534 2009-10-16 Sebastian Pop <sebastian.pop@amd.com>
1536 * graphite-interchange.c: Fix comments.
1537 * gcc.dg/graphite/block-1.c: Fix comments.
1539 2009-10-16 Sebastian Pop <sebastian.pop@amd.com>
1541 * gcc.dg/graphite/interchange-7.c: Un-XFAILed.
1542 * gcc.dg/graphite/interchange-9.c: Un-XFAILed.
1544 2009-10-16 Sebastian Pop <sebastian.pop@amd.com>
1546 Reapply the patch from Alexander Monakov that disappeared during
1547 the last merges from trunk.
1549 2009-09-16 Alexander Monakov <amonakov@ispras.ru>
1551 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Add bounds only
1552 for ARRAY_REFs. Use array_ref_{low,up}_bound to determine bounds.
1554 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
1556 * graphite-interchange.c (memory_stride_in_loop): The depth
1557 argument corresponds to a dynamic time dimension, so use
1558 psct_dynamic_dim to refer to the transformed scattering dimension.
1560 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
1562 * graphite-interchange.c (memory_stride_in_loop): Fix comments.
1564 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
1566 * graphite-blocking.c (lst_do_strip_mine): Avoid strip mining the
1568 * graphite-interchange.c (lst_do_interchange): Avoid interchanging
1569 the root of the LST.
1570 * graphite-poly.c (scop_to_lst): Fix LST sequence in an outermost
1572 (print_lst): Print the root of LST in a different format.
1573 * graphite-poly.h (lst_depth): Adjust to include the root of the LST.
1575 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
1577 * graphite-poly.c (print_scop): Fix pretty printing of a SCoP.
1579 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
1581 * doc/passes.texi: Document the Graphite infrastructure.
1583 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
1585 * graphite-sese-to-poly.c (insert_copyin): Use gsi_insert_seq_on_edge.
1586 (rewrite_commutative_reductions_out_of_ssa): Call gsi_commit_edge_inserts,
1587 and check the SSA representation.
1589 * gfortran.dg/graphite/id-18.f90: New, reduced from PR41193.
1591 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
1593 * gcc.dg/graphite/pr40157.c: Use -floop-block as reported in the PR.
1595 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
1597 * gcc.dg/graphite/interchange-11.c: New.
1599 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
1601 * gcc.dg/graphite/interchange-8.c: Enable loop interchange.
1603 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
1605 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK):
1606 Add -fno-loop-strip-mine and -fno-loop-interchange.
1607 (DEFAULT_FLAGS_GRAPHITE_INTERCHANGE): Add -fno-loop-block and
1608 -fno-loop-strip-mine.
1609 * gfortran.dg/graphite/graphite.exp: Same.
1611 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
1613 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK):
1614 Renamed DEFAULT_FLAGS_GRAPHITE_BLOCK.
1615 (DEFAULT_CFLAGS_GRAPHITE_IDENTITY): Renamed
1616 DEFAULT_FLAGS_GRAPHITE_IDENTITY.
1617 (DEFAULT_CFLAGS_GRAPHITE_INTERCHANGE): Renamed
1618 DEFAULT_FLAGS_GRAPHITE_INTERCHANGE.
1619 (DEFAULT_CFLAGS_GRAPHITE_SCOP): Renamed
1620 DEFAULT_FLAGS_GRAPHITE_SCOP.
1621 (DEFAULT_CFLAGS_RUN_ID): Renamed DEFAULT_FLAGS_RUN_ID.
1622 (DEFAULT_CFLAGS_GRAPHITE): Renamed DEFAULT_FLAGS_GRAPHITE.
1624 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
1626 * graphite-poly.c (pbb_number_of_iterations_at_time): Cleanup comments.
1628 2009-10-14 Konrad Trifunovic <konrad.trifunovic@gmail.com>
1629 Sebastian Pop <sebastian.pop@amd.com>
1631 * graphite-interchange.c (build_linearized_memory_access): Pass an
1632 offset as parameter.
1633 (memory_stride_in_loop): Include transform scattering in the
1634 access functions to be able to querry the strides in the
1636 (pbb_interchange_loop_depths): Interchange the psct_dynamic_dim,
1637 not the psct_iterator_dim.
1639 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
1641 * graphite-blocking.c (pbb_do_strip_mine): Removed.
1642 (lst_do_strip_mine_loop): New.
1643 (lst_do_strip_mine): New.
1644 (scop_do_strip_mine): Call lst_do_strip_mine.
1645 * graphite-poly.h (lst_add_loop_under_loop): New.
1646 (lst_find_first_pbb): New.
1648 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
1650 * graphite-poly.c (loop_to_lst): Fix LST creation.
1652 2009-10-14 Tobias Grosser <grosser@fim.uni-passau.de>
1654 * gcc.dg/graphite/id-15.c: (8 * 8) replaced with
1655 sizeof(unsigned long) to make it run on 32bit systems.
1657 2009-10-14 Tobias Grosser <grosser@fim.uni-passau.de>
1659 * gcc.dg/graphite/run-id-1.c: Use smaller matrix to not
1662 2009-10-14 Ramakrishna Upadrasta <Ramakrishna.Upadrasta@inria.fr>
1664 * graphite-sese-to-poly.c (write_alias_graph_to_ascii_dimacs): Fix
1666 (write_alias_graph_to_ascii_dot): New.
1667 (write_alias_graph_to_ascii_ecc): Ditto.
1668 (partition_drs_to_sets): Add testing of optimality of current method
1669 which assigns alias numbers according to DFS Comopnent number. used
1670 as heuristic for the upcoming ECC algorithm.
1671 (build_scop_drs): Write to file also with the ecc and dot format.
1673 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
1675 * gfortran.dg/graphite/interchange-1.f: XFail.
1677 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
1679 * graphite.c (graphite_initialize): Do not handle functions with
1680 more than 100 basic blocks.
1682 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
1684 * graphite-blocking.c (pbb_do_strip_mine): Use
1685 PARAM_LOOP_BLOCK_TILE_SIZE.
1687 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
1689 * graphite-poly.c (dot_lst_1): New.
1691 * graphite-poly.h (dot_lst): Declared.
1693 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
1695 * graphite-dependences.c (dot_deps_stmt_1): New.
1696 (dot_deps_stmt): New.
1697 * graphite-dependences.h (dot_deps_stmt): Declared.
1699 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
1701 * graphite-sese-to-poly.c (rewrite_cross_bb_scalar_dependence): Do
1702 not replace cross BB scalar dependences ending on PHI nodes.
1703 (rewrite_cross_bb_scalar_deps): Filter out GIMPLE_PHI nodes.
1705 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
1707 * graphite-poly.c (apply_poly_transforms): Implement the high
1708 level driver for flag_loop_block.
1709 * opts.c (decode_options): Enable flag_loop_block at -O2.
1710 * tree-ssa-loop.c (gate_graphite_transforms): Remove call to sorry for
1713 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK): Add
1715 * gfortran.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK):
1718 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
1720 * graphite-poly.h (lst_find_pbb): New.
1721 (find_lst_loop): New.
1723 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
1725 * graphite-poly.c (new_scop): Remove init of SCOP_DEP_GRAPH.
1726 * graphite-poly.h (struct scop): Remove dep_graph field.
1727 (SCOP_DEP_GRAPH): Removed.
1729 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
1731 * graphite-poly.h (copy_lst): Do full copy of LST.
1733 2009-10-07 Sebastian Pop <sebastian.pop@amd.com>
1735 * graphite-sese-to-poly.c (reduction_phi_p): Call remove_invariant_phi
1736 when the loop stride is zero.
1738 * gcc.dg/graphite/id-16.c: New.
1740 2009-10-06 Sebastian Pop <sebastian.pop@amd.com>
1742 * graphite-dependences.c (reduction_dr_1): New.
1743 (reduction_dr_p): New.
1744 (graphite_legal_transform_dr): Call reduction_dr_p.
1745 (reduction_ddr): Renamed reduction_ddr_p.
1746 * graphite-poly.h (same_pdr_p): New.
1747 (number_of_write_pdrs): New.
1748 * graphite-sese-to-poly.c (nb_data_writes_in_bb): New.
1749 (split_reduction_stmt): Do not split reduction statements
1750 when there are no writes to memory.
1751 (translate_scalar_reduction_to_array_for_stmt): Insert the
1752 memory reduction statement just after the scalar reduction statement.
1754 * gcc.dg/graphite/interchange-10.c: Updated to differ from interchange-4.c.
1756 * gcc.dg/graphite/interchange-3.c: Un-XFAIL-ed.
1757 * gcc.dg/graphite/interchange-4.c: Un-XFAIL-ed.
1759 2009-10-06 Sebastian Pop <sebastian.pop@amd.com>
1761 * graphite-interchange.c (lst_apply_interchange): New.
1762 (lst_interchange_profitable_p): New.
1763 (lst_try_interchange_loops): New.
1764 (lst_try_interchange): New.
1765 (lst_do_interchange): New.
1766 (pbb_do_interchange): Removed.
1767 (scop_do_interchange): Call lst_do_interchange.
1769 2009-10-06 Sebastian Pop <sebastian.pop@amd.com>
1771 * graphite-poly.c (print_scop): Print SCOP_ORIGINAL_SCHEDULE and
1772 SCOP_TRANSFORMED_SCHEDULE.
1777 * graphite-poly.h (lst_p): New.
1780 (LST_LOOP_FATHER): New.
1783 (scop_to_lst): Declared.
1784 (print_lst): Declared.
1785 (debug_lst): Declared.
1786 (new_lst_loop): New.
1787 (new_lst_stmt): New.
1790 (lst_dewey_number): New.
1791 (struct scop): Add original_schedule and transformed_schedule fields.
1792 (SCOP_ORIGINAL_SCHEDULE): New.
1793 (SCOP_TRANSFORMED_SCHEDULE): New.
1794 * graphite-sese-to-poly.c (build_poly_scop): Call scop_to_lst.
1796 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
1798 * graphite-dependences.c (reduction_ddr): New.
1799 (graphite_legal_transform_bb): Call reduction_ddr.
1800 * graphite-poly.c (new_poly_bb): Pass a new bool parameter.
1801 Initialize PBB_IS_REDUCTION.
1802 * graphite-poly.h (struct poly_bb): New bool field is_reduction.
1803 (PBB_IS_REDUCTION): New.
1804 (new_poly_bb): Update declaration.
1805 * graphite-scop-detection.h (build_scop_bbs): Removed.
1806 (nb_reductions_in_loop): Removed.
1807 * graphite-sese-to-poly.c (try_generate_gimple_bb): Pass a sbitmap
1808 parameter for reductions.
1809 (try_generate_gimple_bb): Update call to new_poly_bb.
1810 (build_scop_bbs_1): Same.
1811 (build_scop_bbs): Same.
1812 (gsi_for_phi_node): New.
1813 (scalar_close_phi_node_p): Remove gcc_assert.
1814 (split_reduction_stmt): New.
1815 (is_reduction_operation_p): New.
1816 (phi_contains_arg): New.
1817 (follow_ssa_with_commutative_ops): New.
1818 (detect_commutative_reduction_arg): New.
1819 (detect_commutative_reduction_assign): New.
1820 (follow_inital_value_to_phi): New.
1821 (edge_initial_value_for_loop_phi): New.
1822 (initial_value_for_loop_phi): New.
1823 (detect_commutative_reduction): New.
1824 (translate_scalar_reduction_to_array_for_stmt): New.
1825 (insert_copyout): New.
1826 (insert_copyin): New.
1827 (translate_scalar_reduction_to_array): New.
1828 (rewrite_commutative_reductions_out_of_ssa_close_phi): New.
1829 (rewrite_commutative_reductions_out_of_ssa_loop): New.
1830 (rewrite_commutative_reductions_out_of_ssa): New.
1831 (build_poly_scop): Call rewrite_commutative_reductions_out_of_ssa.
1832 * sese.h (split_region_for_bb): New.
1834 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK): Add -ffast-math.
1835 * gcc.dg/graphite/interchange-1.c: Fix format.
1836 * gcc.dg/graphite/interchange-10.c: New.
1838 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
1840 * graphite-sese-to-poly.c (insert_out_of_ssa_copy): Remove
1843 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
1845 * graphite-sese-to-poly.c (scev_analyzable_p): New.
1846 (rewrite_cross_bb_scalar_dependence): New.
1847 (rewrite_cross_bb_scalar_deps): New.
1848 (rewrite_reductions_out_of_ssa): Use bb_in_sese_p.
1849 Call rewrite_cross_bb_scalar_deps.
1851 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
1853 * graphite-sese-to-poly.c (gsi_for_ssa_name_def): Removed.
1854 (insert_out_of_ssa_copy): Directly use gsi_after_labels and
1857 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
1859 * graphite-clast-to-gimple.c (build_cloog_prog): Use pbb_index.
1860 * graphite-interchange.c (pbb_do_interchange): Same.
1861 * graphite-poly.c (print_scattering_function): Same.
1863 * graphite-poly.h (pbb_loop): New.
1864 * graphite-sese-to-poly.c (create_linear_expr_from_tree): Use pbb_loop.
1866 2009-09-27 Sebastian Pop <sebastian.pop@amd.com>
1868 * graphite-scop-detection.c (limit_scops): Do not build poly_bbs.
1870 2009-09-27 Sebastian Pop <sebastian.pop@amd.com>
1872 * graphite-sese-to-poly.c (partition_drs_to_sets): Drs is not modified,
1873 so don't pass a pointer to it.
1874 (build_alias_set_for_drs): Same.
1875 (build_base_obj_set_for_drs): Same.
1876 (build_scop_drs): Same.
1878 2009-09-26 Li Feng <nemokingdom@gmail.com>
1880 * graphite-sese-to-poly.c (build_scop_drs): Disable writing to file
1881 the alias graph of data references.
1883 2009-09-25 Li Feng <nemokingdom@gmail.com>
1885 * graphite-sese-to-poly.c (write_alias_graph_to_ascii_dimacs): New.
1886 (build_scop_drs): When debugging, write the alias graph to file,
1887 otherwise, should be disabled.
1889 2009-09-17 Sebastian Pop <sebastian.pop@amd.com>
1891 * Merge from mainline (151310:151361).
1893 2009-09-17 Sebastian Pop <sebastian.pop@amd.com>
1895 * Merge from mainline (151171:151310).
1897 2009-09-17 Sebastian Pop <sebastian.pop@amd.com>
1899 * Merge from mainline (151171:151806).
1901 2009-09-17 Sebastian Pop <sebastian.pop@amd.com>
1903 * Revert the last commit.
1905 2009-09-17 Sebastian Pop <sebastian.pop@amd.com>
1907 * Merge from mainline (151171:151819).
1909 2009-09-17 Sebastian Pop <sebastian.pop@amd.com>
1911 * graphite-scop-detection.c (stmt_simple_memref_p): Removed.
1912 (is_simple_operand): Remove call to stmt_simple_memref_p.
1913 (stmt_simple_for_scop_p): Update call to is_simple_operand.
1915 2009-09-17 David Edelsohn <edelsohn@gnu.org>
1917 * gcc.dg/graphite/interchange-mvt.c: New File.
1918 * gcc.dg/graphite/scop-dsyrk.c: New File.
1919 * gcc.dg/graphite/scop-dsyr2k.c: New File.
1920 * gcc.dg/graphite/scop-mvt.c: New File.
1921 * gcc.dg/graphite/scop-sor.c: New File.
1923 2009-09-17 Li Feng <nemokingdom@gmail.com>
1925 * graphite-dependences.c (poly_drs_may_alias_p): Adjust definition.
1926 (pddr_original_scattering): Make sure 2 pdr2 in the same base object set.
1927 (graphite_carried_dependence_level_k): Ditto.
1928 * graphite-poly.c (new_poly_dr): Add init of PDR_BASE_OBJECT_SET.
1929 * graphite-poly.h (struct poly_dr): Add member dr_base_object_set.
1930 (new_poly_dr): Adjust declaration.
1931 * graphite-sese-to-poly.c (free_data_refs_aux): New.
1932 (free_gimple_bb): Added free_data_refs_aux.
1933 (build_poly_dr): Add dr_base_object_set.
1934 (partition_drs_to_sets): New.
1935 (dr_same_base_object_p): New.
1936 (build_alias_set_for_drs): New.
1937 (build_base_object_set_for_drs): New.
1938 (build_scop_drs): Add build_base_obj_set_for_drs.
1939 * graphite-sese-to-poly.h: Added #define for alias set number index and
1940 base object set index.
1941 * libgomp/testsuite/libgomp.graphite/force-parallel-6.c: Refine tests.
1942 * libgomp/testsuite/libgomp.graphite/pr4118.c: New.
1944 2009-09-16 Alexander Monakov <amonakov@ispras.ru>
1946 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Add bounds only
1947 for ARRAY_REFs. Use array_ref_{low,up}_bound to determine bounds.
1949 2009-09-14 Sebastian Pop <sebastian.pop@amd.com>
1951 * graphite-sese-to-poly.c (struct irp_data): Removed.
1952 (idx_record_params): Removed.
1953 (find_params_in_bb): Scan for parameters the access functions; don't
1954 parse the tree representation.
1956 2009-09-14 Sebastian Pop <sebastian.pop@amd.com>
1958 * tree-ssa-loop.c (gate_graphite_transforms): Disable Graphite
1959 passes at -O1 and below.
1961 2009-09-14 Sebastian Pop <sebastian.pop@amd.com>
1963 * graphite-blocking.c: Fix order of includes: tree-chrec.h, then
1964 tree-scalar-evolution.h, and then tree-data-ref.h.
1965 * graphite-clast-to-gimple.c: Same.
1966 * graphite-dependences.c: Same.
1967 * graphite-interchange.c: Same.
1968 * graphite-poly.c: Same.
1969 * graphite-scop-detection.c: Same.
1970 * graphite-sese-to-poly.c: Same.
1972 * lambda-code.c: Same.
1973 * matrix-reorg.c: Same.
1974 * tree-data-ref.c: Same.
1975 * tree-if-conv.c: Same.
1976 * tree-loop-distribu: Same.: Same.
1977 * tree-loop-linear.c: Same.
1978 * tree-parloops.c: Same.
1979 * tree-predcom.c: Same.
1980 * tree-vect-patterns.c: Same.
1982 2009-09-02 Sebastian Pop <sebastian.pop@amd.com>
1984 Partially revert the previous patch, except the following.
1985 * tree-scalar-evolution.c (instantiate_scev_not): Adapted to pass
1986 as parameters the operands of the not expression.
1988 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1990 * tree-scalar-evolution.c (instantiate_scev_assign): New.
1991 Do not call analyze_scalar_evolution on assignments.
1992 (instantiate_scev_phi): Call analyze_scalar_evolution.
1993 (instantiate_scev_name): Call instantiate_scev_assign and
1994 instantiate_scev_phi.
1995 (instantiate_scev_not): Adapted to pass as parameters the operands
1996 of the not expression.
1998 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
2000 * tree-scalar-evolution.c (instantiate_scev_binary): Adapted
2001 to pass as parameters the operands of the binary expression.
2003 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
2005 * tree-scalar-evolution.c (instantiate_scev_bitnot): Renamed
2006 instantiate_scev_not. Handle NEGATE_EXPR.
2007 (instantiate_scev_r): Handle NEGATE_EXPR.
2009 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
2011 * tree-scalar-evolution.c (instantiate_scev_1): Renamed
2013 (instantiate_scev_r): Move code in instantiate_scev_2
2014 and instantiate_scev_1.
2016 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
2018 * tree-scalar-evolution.c (instantiate_scev_3): New.
2019 (instantiate_scev_1): Move code in instantiate_scev_3.
2021 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
2023 * tree-scalar-evolution.c (instantiate_scev_poly): New.
2024 (instantiate_scev_1): Move code in instantiate_scev_poly.
2026 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
2028 * tree-scalar-evolution.c (instantiate_scev_bitnot): New.
2029 (instantiate_scev_1): Move code in instantiate_scev_bitnot.
2031 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
2033 * tree-scalar-evolution.c (instantiate_scev_convert): New.
2034 (instantiate_scev_1): Move code in instantiate_scev_convert.
2036 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
2038 * tree-scalar-evolution.c (instantiate_scev_binary): New.
2039 (instantiate_scev_1): Move code in instantiate_scev_binary.
2041 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
2043 * tree-scalar-evolution.c (instantiate_scev_name): New.
2044 (instantiate_scev_1): Move code in instantiate_scev_name.
2046 2009-08-28 Sebastian Pop <sebastian.pop@amd.com>
2048 * Merge from mainline (150992:151171).
2050 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
2052 * opts.c (decode_options): Enable flag_loop_interchange at -O2.
2054 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
2056 * graphite-dependences.c (graphite_legal_transform_bb): Call
2057 pbb_remove_duplicate_pdrs.
2058 * graphite-poly.c (can_collapse_pdr): Removed.
2059 (pdr_find_duplicate): Removed.
2060 (can_collapse_pdrs): New.
2061 (pbb_remove_duplicate_pdrs): New.
2062 (new_poly_dr): Do not look for duplicates.
2063 * graphite-poly.h (struct poly_bb): New field pdr_duplicates_removed.
2064 (PBB_PDR_DUPLICATES_REMOVED): New.
2065 (pbb_remove_duplicate_pdrs): Declared.
2067 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
2069 * graphite-interchange.c (pbb_interchange_profitable_p): Adjust
2070 the strides by multiplying by PDR_NB_REFS.
2071 * graphite-poly.c (can_collapse_pdr): New.
2072 (pdr_find_duplicate): New.
2073 (new_poly_dr): Call pdr_find_duplicate. Collapse duplicate PDRs.
2074 Initialize PDR_NB_REFS.
2075 * graphite-poly.h (struct poly_dr): Add field nb_refs.
2077 (new_poly_dr): Number of subscripts is a graphite_dim_t.
2079 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
2081 Revert one of the previous commits:
2082 * graphite-dependences.c (graphite_legal_transform_bb): Avoid
2083 the computation of symmetric data dependence relations.
2084 (dependency_between_pbbs_p): Same.
2086 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
2089 * graphite-poly.c (apply_poly_transforms): Remove legality test before
2092 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
2094 * graphite-dependences.c (pddr_original_scattering): Return NULL
2095 for read-read dependence relations.
2096 * graphite-poly.h (enum poly_dr_type): Fix comment.
2099 (pdr_may_write_p): New.
2101 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
2103 * graphite-poly.h (enum POLY_DR_TYPE): Renamed poly_dr_type.
2104 (struct poly_dr): Same.
2105 (new_poly_dr): Same.
2106 * graphite-poly.c (new_poly_dr): Same.
2108 2009-08-25 Konrad Trifunovic <konrad.trifunovic@gmail.com>
2109 Sebastian Pop <sebastian.pop@amd.com>
2111 * graphite-blocking.c (pbb_strip_mine_loop_depth): Renamed
2112 pbb_strip_mine_time_depth. Changed the implementation so that
2113 transformation is expressed as a transformation on
2114 time (scatttering) dimensions. Also, ensures that the 2d+1
2115 scheduling format is preserved.
2116 (pbb_strip_mine_profitable_p): Profitability is based on the
2117 iteration number of a given time (scattering) dimension,
2118 and not on a original loop depth dimension.
2119 (pbb_strip_mine): Call pbb_number_of_iterations_at_time.
2120 (pbb_do_strip_mine): Call psct_dynamic_dim.
2121 * graphite-poly.c (pbb_number_of_iterations_at_time): New.
2122 * graphite-poly.h (pbb_number_of_iterations_at_time): Declared.
2123 (pbb_nb_dynamic_scattering_transform): New.
2124 (psct_dynamic_dim): New.
2126 2009-08-25 Konrad Trifunovic <konrad.trifunovic@gmail.com>
2128 * graphite-ppl.c (ppl_max_for_le): Renamed ppl_max_for_le_pointset.
2129 * graphite-ppl.h (ppl_max_for_le): Renamed ppl_max_for_le_pointset.
2130 * graphite-poly.c (pbb_number_of_iterations): Rename ppl_max_for_le.
2131 * graphite-interchange.c (build_linearized_memory_access): Same.
2132 (memory_stride_in_loop): Same.
2134 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
2136 * graphite-dependences.c (pddr_original_scattering): New.
2137 (graphite_legal_transform_dr): Call pddr_original_scattering.
2140 * graphite-dependences.h (dot_deps): Declared.
2141 * graphite-poly.c (new_poly_dr): Initialize PDR_ID.
2142 (print_pdr): Print PDR_ID.
2143 * graphite-poly.h (struct poly_dr): Add field id.
2146 * graphite-scop-detection.c (dot_all_scops_1): Cleanup comment.
2148 2009-08-22 Sebastian Pop <sebastian.pop@amd.com>
2150 * graphite-dependences.c (graphite_carried_dependence_level_k): Do
2151 not delete the original dependence relation.
2153 2009-08-21 Sebastian Pop <sebastian.pop@amd.com>
2155 * graphite-dependences.c (graphite_legal_transform_bb): Avoid
2156 the computation of symmetric data dependence relations.
2157 (dependency_between_pbbs_p): Same.
2159 2009-08-21 Sebastian Pop <sebastian.pop@amd.com>
2161 * graphite-dependences.c (new_poly_dr_pair): Renamed new_poly_ddr.
2162 (eq_poly_dr_pair_p): Renamed eq_poly_ddr_p.
2163 (hash_poly_dr_pair_p): Renamed hash_poly_ddr_p.
2164 (free_poly_ddr): New.
2165 (pddr_is_empty): New.
2166 (dependence_polyhedron_1): Now returns a poly_ddr_p.
2167 (dependence_polyhedron): Same. Remove useless gcc_assert.
2169 (graphite_legal_transform_dr): Call pddr_is_empty and free_poly_ddr.
2170 (graphite_carried_dependence_level_k): Call pddr_is_empty.
2171 * graphite-dependences.h (enum poly_dependence_kind): New.
2172 (poly_dr_pair): Renamed poly_ddr. Added a field kind.
2173 (PDRP_SOURCE): Renamed PDDR_SOURCE.
2174 (PDRP_SINK): Renamed PDDR_SINK.
2175 (PDRP_DDP): Renamed PDDR_DDP.
2177 (free_poly_ddr): Declared.
2178 * graphite-poly.c (new_scop): Use the new hash function names.
2179 * graphite-poly.h (struct scop): Renamed field original_pdr_pairs
2180 into original_pddrs.
2181 (SCOP_ORIGINAL_PDR_PAIRS): Renamed SCOP_ORIGINAL_PDDRS.
2183 2009-08-21 Sebastian Pop <sebastian.pop@amd.com>
2185 * Merge from mainline (150764:150992).
2187 2009-08-18 Sebastian Pop <sebastian.pop@amd.com>
2189 * cfgloopmanip.c (create_empty_loop_on_edge): Generate upper
2190 bounds with LT_EXPR to make niter analysis more precise on code
2191 generated by Graphite.
2193 2009-08-18 Sebastian Pop <sebastian.pop@amd.com>
2195 * graphite-dependences.c (graphite_legal_transform_dr): Fix formatting.
2196 (graphite_legal_transform_bb): Same.
2197 (poly_drs_may_alias_p): Same.
2199 2009-08-15 Sebastian Pop <sebastian.pop@amd.com>
2202 * graphite-ppl.c (ppl_max_for_le): Correct the use of
2203 ppl_Pointset_Powerset_C_Polyhedron_maximize.
2205 2009-08-13 Sebastian Pop <sebastian.pop@amd.com>
2207 * graphite-poly.c (print_pbb): Print PBB index.
2209 2009-08-13 Sebastian Pop <sebastian.pop@amd.com>
2211 * Merge from mainline (r150672:150764).
2213 2009-08-13 Sebastian Pop <sebastian.pop@amd.com>
2215 * graphite-interchange.c (ppl_max_for_le): Moved...
2216 * graphite-poly.c (pbb_number_of_iterations): Call ppl_max_for_le.
2217 * graphite-ppl.c (ppl_max_for_le): ... here.
2218 * graphite-ppl.h (ppl_max_for_le): Declared.
2220 2009-08-12 Sebastian Pop <sebastian.pop@amd.com>
2222 * Merge from mainline (r150372:150672).
2224 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
2227 * sese.c (convert_for_phi_arg): New.
2228 (add_guard_exit_phis): Use convert_for_phi_arg.
2230 * gfortran.dg/graphite/id-17.f: New.
2232 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
2234 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Dont add
2235 unknown subscript upper bounds.
2237 * gcc.dg/graphite/interchange-6.c: Un-XFAIL.
2239 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
2240 Pranav Garg <pranav.garg2107@gmail.com>
2242 * graphite-interchange.c (gather_access_strides): Removed.
2243 (ppl_max_for_le): New.
2244 (build_linearized_memory_access): New.
2245 (memory_stride_in_loop): New.
2246 (pbb_interchange_profitable_p): Reimplemented.
2247 * graphite-ppl.h (ppl_new_id_map): New.
2248 (ppl_interchange): New.
2250 * gcc.dg/graphite/interchange-6.c: XFAILed.
2252 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
2254 * graphite-interchange.c (compute_subscript): Removed.
2255 (compute_array_size_cstr): Removed.
2256 (compute_array_size_poly): Removed.
2257 (compute_array_size): Removed.
2258 (gather_access_strides_poly): Removed.
2259 (gather_access_strides): Empty.
2261 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
2263 * graphite-dependences.c (dependence_polyhedron_1): Replace
2264 pdr_nb_subscripts with PDR_NB_SUBSCRIPTS.
2265 (graphite_legal_transform_dr): Same.
2266 (graphite_carried_dependence_level_k): Same.
2267 * graphite-poly.c (new_poly_dr): Add a parameter nb_subscripts.
2268 Initialize PDR_NB_SUBSCRIPTS.
2269 (print_pdr_access_layout): Replace pdr_nb_subscripts with
2271 * graphite-poly.h (struct poly_dr): Add nb_subscripts field.
2272 (PDR_NB_SUBSCRIPTS): New.
2273 (pdr_nb_subscripts): Removed.
2274 (pdr_dim): Simplified.
2275 * graphite-sese-to-poly.c (build_poly_dr): Replace pdr_nb_subscripts
2276 with PDR_NB_SUBSCRIPTS.
2278 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
2280 * graphite-interchange.c (compute_array_size): Remove use of
2282 * graphite-poly.c (new_poly_dr): Remove argument data_container.
2283 Do not initialize PDR_DATA_CONTAINER.
2284 (print_pdr): Do not print PDR_DATA_CONTAINER.
2285 * graphite-poly.h (struct poly_dr): Remove data_container field.
2286 (PDR_DATA_CONTAINER): Removed.
2287 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Remove use of
2289 (build_poly_dr): Same.
2291 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
2293 * gcc.dg/graphite/interchange-9.c: New.
2295 2009-08-05 Konrad Trifunovic <konrad.trifunovic@gmail.com>
2296 Sebastian Pop <sebastian.pop@amd.com>
2298 * graphite-dependences.c (graphite_legal_transform_dr): Work on a
2299 copy of the dependence polyhedron. Free the temporary objects.
2300 (graphite_carried_dependence_level_k): Free unused objects before
2303 * gcc.dg/graphite/interchange-1.c: XFAILed.
2304 * gcc.dg/graphite/interchange-2.c: XFAILed.
2305 * gcc.dg/graphite/interchange-3.c: XFAILed.
2306 * gcc.dg/graphite/interchange-4.c: XFAILed.
2307 * gcc.dg/graphite/interchange-7.c: XFAILed.
2309 2009-08-05 Sebastian Pop <sebastian.pop@amd.com>
2311 * graphite-blocking.c (scop_do_strip_mine): Call store_scattering.
2312 Early return without analyzing the data dependences if no
2313 transform has been done. Call restore_scattering if the transform
2315 (graphite-interchange.c): Same.
2316 * graphite-poly.c (print_scattering_function): Test for PBB_TRANSFORMED.
2317 (graphite_read_transforms): Initialize PBB_TRANSFORMED.
2318 (apply_poly_transforms): Do not gcc_assert that
2319 the transform is legal.
2320 (new_poly_bb): Initialize PBB_TRANSFORMED, PBB_SAVED, and PBB_ORIGINAL.
2321 Do not initialize PBB_NB_SCATTERING_TRANSFORM, PBB_NB_LOCAL_VARIABLES,
2322 PBB_TRANSFORMED_SCATTERING, and PBB_ORIGINAL_SCATTERING.
2323 (free_poly_dr): Free PBB_TRANSFORMED, PBB_SAVED, and PBB_ORIGINAL.
2324 * graphite-poly.h (struct poly_scattering): New.
2325 (struct poly_bb): Add original, transformed, and saved fields.
2326 Remove transformed_scattering, original_scattering, nb_local_variables,
2327 and nb_scattering_transform fields.
2328 (PBB_ORIGINAL, PBB_TRANSFORMED, PBB_SAVED): New.
2329 (poly_scattering_new): New.
2330 (poly_scattering_free): New.
2331 (poly_scattering_copy): New.
2332 (store_scattering_pbb): New.
2333 (store_scattering): New.
2334 (restore_scattering_pbb): New.
2335 (restore_scattering): New.
2336 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons):
2337 Initialize PBB_TRANSFORMED and PBB_ORIGINAL.
2339 2009-08-05 Sebastian Pop <sebastian.pop@amd.com>
2341 * graphite-poly.c (print_pbb): Add parentheses in the pretty print.
2344 2009-08-05 Sebastian Pop <sebastian.pop@amd.com>
2346 * Makefile.in (graphite.o): Depends on PREDICT_H.
2347 * graphite.c: Include predict.h.
2348 (graphite_finalize): Call tree_estimate_probability.
2349 * predict.c (predict_loops): Do not call scev_initialize and
2351 (tree_estimate_probability_bb): New.
2352 (tree_estimate_probability): Do not initialize loops: move that
2353 code to the driver. Call tree_estimate_probability_bb.
2354 (tree_estimate_probability_driver): New.
2355 (pass_profile): Use tree_estimate_probability_driver.
2356 * predict.h (tree_estimate_probability): Declared.
2358 2009-08-05 Sebastian Pop <sebastian.pop@amd.com>
2360 * graphite-clast-to-gimple.c (gloog): Add time to TV_GRAPHITE_CODE_GEN.
2361 * graphite-dependences.c (graphite_legal_transform): Add time to
2362 TV_GRAPHITE_DATA_DEPS.
2363 (dependency_between_pbbs_p): Same.
2364 * timevar.def (TV_GRAPHITE_DATA_DEPS, TV_GRAPHITE_CODE_GEN): New.
2366 2009-08-03 Sebastian Pop <sebastian.pop@amd.com>
2368 * Merge from mainline (r149952:150372).
2370 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
2372 * ChangeLog.graphite: Fix indenting, white spaces and 80 columns.
2373 * graphite-blocking.c: Same.
2374 * graphite-clast-to-gimple.c: Same.
2375 * graphite-dependences.c: Same.
2376 * graphite-poly.c: Same.
2377 * graphite-poly.h: Same.
2378 * graphite-ppl.c: Same.
2379 * graphite-scop-detection.c: Same.
2380 * graphite-sese-to-poly.c: Same.
2383 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
2385 * graphite-sese-to-poly.c (loop_entry_phi_arg): New.
2386 (remove_simple_copy_phi): New.
2387 (remove_invariant_phi): New.
2388 (simple_copy_phi_p): New.
2389 (reduction_phi_p): New.
2390 (gsi_for_ssa_name_def): New.
2391 (insert_out_of_ssa_copy): New.
2392 (insert_out_of_ssa_copy_on_edge): New.
2393 (create_zero_dim_array): New.
2394 (scalar_close_phi_node_p): New.
2395 (rewrite_close_phi_out_of_ssa): New.
2396 (rewrite_phi_out_of_ssa): New.
2397 (rewrite_reductions_out_of_ssa): New.
2398 (build_poly_scop): Call rewrite_reductions_out_of_ssa.
2400 * gcc.dg/graphite/id-11.c: New.
2401 * gcc.dg/graphite/id-15.c: New.
2402 * gcc.dg/graphite/interchange-1.c: Un-XFAIL.
2403 * gcc.dg/graphite/interchange-2.c: Un-XFAIL.
2404 * gcc.dg/graphite/interchange-3.c: Un-XFAIL.
2405 * gcc.dg/graphite/interchange-4.c: Un-XFAIL.
2406 * gcc.dg/graphite/interchange-7.c: Un-XFAIL.
2407 * gcc.dg/graphite/scop-matmult.c: Un-XFAIL.
2408 * gfortran.dg/graphite/id-13.f: New.
2409 * gfortran.dg/graphite/id-5.f: New.
2411 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
2413 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not
2414 check that nb_reductions_in_loop is zero.
2415 * graphite-scop-detection.c (harmful_stmt_in_bb): Don't filter out
2416 reduction phi nodes.
2417 (nb_reductions_in_loop): Removed.
2418 (graphite_can_represent_loop): Do not call nb_reductions_in_loop.
2419 * graphite-sese-to-poly.c (phi_node_is_iv): Removed.
2420 (bb_contains_non_iv_scalar_phi_nodes): Removed.
2421 (scop_contains_non_iv_scalar_phi_nodes): Removed.
2422 (build_poly_scop): Do not call scop_contains_non_iv_scalar_phi_nodes.
2424 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
2426 * graphite-clast-to-gimple.c (build_cloog_prog): Do not code generate
2427 statements that have an empty iteration domain.
2428 * gfortran.dg/graphite/id-16.f: New.
2430 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
2432 * tree-scalar-evolution.c (instantiate_scev_1): Return
2433 chrec_dont_know when the result is not above instantiate_below.
2434 * graphite-scop-detection.c (scopdet_basic_block_info): Fix formatting.
2435 * graphite-sese-to-poly.c (create_linear_expr_from_tree): Assert that
2436 the tree has a known scalar evolution.
2437 * gfortran.dg/graphite/id-14.f: New.
2438 * gfortran.dg/graphite/id-15.f: New.
2440 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
2442 * sese.c (rename_variables_in_stmt): Pass in an extra parameter
2444 (rename_variables): Keep inserting renames after the ones already
2447 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
2449 * graphite-sese-to-poly.c (compare_bb_depths): New.
2450 (graphite_sort_dominated_info): New.
2451 (build_scop_bbs_1): Call graphite_sort_dominated_info.
2452 (build_scop_scattering): Fix comment.
2454 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
2456 * graphite.c (graphite_finalize): Call print_loops instead of
2457 dump_function_to_file.
2458 * gcc.dg/graphite/graphite.exp: Fix formatting.
2459 * gcc.dg/graphite/pr35356-1.c: New. Look for the number of
2460 loops generated in the graphite output file.
2461 * gcc.dg/graphite/pr35356-2.c: New.
2462 * gcc.dg/graphite/pr35356-3.c: New. XFAILed for now.
2463 * gfortran.dg/graphite/id-12.f: New.
2465 2009-07-24 Li Feng <nemokingdom@gmail.com>
2467 * gcc.dg/graphite/graphite_autopar/force-parallel-8.c:
2470 2009-07-24 Li Feng <nemokingdom@gmail.com>
2471 Tobias Grosser <grosser@fim.uni-passau.de>
2473 * graphite-sese-to-poly.c (pdr_add_alias_set): Use data reference's
2474 alias set number build alias in ACCESSES polyhedron.
2475 (build_alias_set_for_drs): New.
2476 (build_pbb_drs): Added build_alias_set_for_drs.
2477 * graphite-dependences.c (poly_drs_may_alias_p): New.
2478 (graphite_carried_dependence_level_k): Check alias information
2479 before building polyhedron.
2481 2009-07-24 Tobias Grosser <grosser@fim.uni-passau.de>
2483 * Makefile.in (lambda-code.o): Fix formatting.
2485 2009-07-24 Tobias Grosser <grosser@fim.uni-passau.de>
2487 * Merge from mainline (r149350-149952)
2489 2009-07-18 Tobias Grosser <grosser@fim.uni-passau.de>
2491 * graphite-poly.c (apply_poly_transforms): Move strip_mine
2492 before interchange to prepare for loop blocking.
2494 2009-07-18 Tobias Grosser <grosser@fim.uni-passau.de>
2496 * graphite-poly.c (apply_poly_transforms): Add checks after every
2498 * graphite-sese-to-poly.c (build_poly_scop): Remove check, as already
2499 done in apply_poly_transforms.
2501 2009-07-17 Konrad Trifunovic <konrad.trifunovic@gmail.com>
2503 * graphite-dependences.c (build_lexicographically_gt_constraint):
2504 Replace RES parameter with *RES.
2505 (dependence_polyhedron_1): Pass an address of the parameter RES
2506 instead of value of RES.
2508 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
2510 * graphite.c (graphite_finalize): Fix comment.
2511 (graphite_transform_loops): Reset scev info after code generation
2514 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
2516 * graphite.c (graphite_finalize): Call scev_reset.
2518 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
2520 * graphite-clast-to-gimple.c (compute_cloog_iv_types): Do not create
2521 GBB_CLOOG_IV_TYPES hash table twice.
2522 * graphite-sese-to-poly.c (free_gimple_bb): Call free_data_refs.
2523 (add_condition_to_domain): Clear GMP values.
2525 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
2527 * graphite-dependences.c: Fix formatting.
2528 * graphite-poly.c (free_poly_dr): Also free PDR_DATA_CONTAINER.
2529 (pbb_number_of_iterations): Free ppl_Linear_Expression.
2530 * graphite-sese-to-poly.c: Fix formatting.
2531 * graphite.c (graphite_transform_loops): Create the hash table
2532 after the early return.
2534 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
2536 * gcc.dg/graphite/id-14.c: New.
2537 * gcc.dg/graphite/pr40157.c: New.
2538 * gfortran.dg/graphite/id-11.f: New.
2540 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
2542 * graphite-sese-to-poly.c (nb_pbbs_in_loops): New.
2543 (build_poly_scop): Return false when there are no pbbs within
2544 loops to avoid to pass to cloog scops with no loops.
2546 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
2548 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons): Avoid
2549 useless test "i % 2".
2550 (build_pbb_scattering_polyhedrons): Fix formatting.
2551 (build_poly_dr): Same.
2552 * graphite.c (graphite_transform_loops): Restructure.
2554 2009-07-14 Razya Ladelsky <razya@il.ibm.com>
2556 * tree-ssa-loop-manip.c (rewrite_phi_with_iv): Remove
2557 reduction_list parameter.
2558 (rewrite_all_phi_nodes_with_iv): Same.
2559 (canonicalize_loop_ivs): Same.
2560 * tree-parloops.c (struct brli): Removed.
2561 (build_reduction_list_info): Removed.
2562 (build_new_reduction): New.
2563 (analyze_reduction_list): Removed.
2564 (gather_scalar_reductions): Find reductions instead of phi
2565 nodes that can't be canonicalized.
2566 (try_create_reduction_list): Remove reduction_list parameter.
2567 (gen_parallel_loop): Same.
2568 (parallelize_loops): Remove analyze_reductions variable,
2569 initialization and free.
2570 Change reduction_list htab initialization to reduction_info
2571 elements instead of ssa names.
2572 Call try_create_reduction_list and gen_parallel_loop without
2573 analyzed_reduction argument.
2574 * graphite-clast-to-gimple (graphite_loop_normal_form): Call
2575 canonicalize_loop_ivs with one less argument.
2576 * tree-flow.h (canonicalize_loop_ivs): Remove one argument.
2578 2009-07-14 Konrad Trifunovic <konrad.trifunovic@gmail.com>
2580 * graphite-dependences.c (new_poly_dr_pair): New.
2581 (dependence_polyhedron): Renamed into dependence_polyhedron_1.
2582 (new_poly_dr_pair): New.
2583 (eq_poly_dr_pair_p): New.
2584 (hash_poly_dr_pair_p): New.
2585 * graphite-dependences.h (struct poly_dr_pair): New.
2586 (eq_poly_dr_pair_p): Declared.
2587 (hash_poly_dr_pair_p): Declared.
2588 * graphite-poly.c (new_scop): Initialize SCOP_ORIGINAL_PDR_PAIRS.
2589 (free_scop): Free SCOP_ORIGINAL_PDR_PAIRS.
2590 * graphite-poly.h (struct scop): Add original_pdr_pairs field.
2591 * Makefile.in (graphite-poly.o): Add dependence on
2592 graphite-dependences.h.
2594 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
2596 * graphite-scop-detection.c (graphite_can_represent_scev): Do not let
2597 polynomials of degree > 1 pass to Graphite.
2598 * tree-chrec.c (scev_is_linear_expression): Call
2599 evolution_function_is_affine_multivariate_p.
2600 * gfortran.dg/graphite/id-10.f90: New.
2602 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
2604 * tree-scalar-evolution.c (compute_overall_effect_of_inner_loop):
2605 Instantiate scevs varying in outer loops.
2606 * gfortran.dg/graphite/id-9.f: Correct testcase.
2608 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
2610 * graphite-sese-to-poly.c (build_loop_iteration_domains): Do not insert
2611 redundant constraint.
2613 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
2615 * gcc.dg/graphite/graphite.exp: Fix comments.
2616 * gfortran.dg/graphite/graphite.exp: Trigger actions
2617 based on the file names as in the C testsuite.
2618 * gfortran.dg/graphite/block-1.f90: Fix patterns.
2619 * gfortran.dg/graphite/block-2.f: Same.
2620 * gfortran.dg/graphite/block-3.f90: Same.
2621 * gfortran.dg/graphite/block-4.f90: Same.
2622 * gfortran.dg/graphite/id-1.f90: Same.
2623 * gfortran.dg/graphite/id-2.f90: Same.
2624 * gfortran.dg/graphite/id-3.f90: Same.
2625 * gfortran.dg/graphite/id-4.f90: Same.
2626 * gfortran.dg/graphite/id-6.f: Same.
2627 * gfortran.dg/graphite/id-9.f: Same.
2628 * gfortran.dg/graphite/interchange-1.f: Same.
2629 * gfortran.dg/graphite/interchange-2.f: Same.
2630 * gfortran.dg/graphite/scop-1.f: Same.
2632 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
2634 * sese.c (expand_scalar_variables_call): New.
2635 (expand_scalar_variables_ssa_name): Handle calls in expander.
2637 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
2639 * gcc.dg/graphite/graphite_autopar/force-parallel-6.c:
2640 Expect to see the pattern twice.
2641 * gcc.dg/graphite/interchange-0.c: Un-XFAIL.
2642 * gcc.dg/graphite/interchange-5.c: Same.
2643 * gcc.dg/graphite/interchange-6.c: Same.
2645 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
2647 * gcc.dg/graphite/id-10.c: New.
2648 * gcc.dg/graphite/id-12.c: New.
2649 * gfortran.dg/graphite/id-7.f: New.
2650 * gfortran.dg/graphite/id-8.f: New.
2652 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
2654 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Fix division by
2657 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
2659 * sese.c (rename_variables_in_stmt): Call fold_convert during renaming.
2661 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
2663 * sese.c (expand_scalar_variables_stmt): Avoid unnecessary expansion.
2665 2009-07-10 Sebastian Pop <sebastian.pop@amd.com>
2667 * graphite-sese-to-poly.c (pdr_add_memory_accesses): Fix order of
2668 building PDR subscripts.
2670 2009-07-10 Sebastian Pop <sebastian.pop@amd.com>
2672 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Fix the
2673 computation of array sizes.
2675 2009-07-10 Sebastian Pop <sebastian.pop@amd.com>
2677 * graphite-sese-to-poly.c (add_param_constraints): Disabled.
2679 2009-07-10 Tobias Grosser <grosser@fim.uni-passau.de>
2681 * graphite-dependences.c (map_into_dep_poly, map_dr_into_dep_poly,
2682 build_pairwise_constraint, dr_equality_constraints,
2683 build_pairwise_scheduling_equality,
2684 build_pairwise_scheduling_inequality, lexicographically_gt_p,
2685 build_lexicographically_gt_constraint, dependence_polyhedron,
2686 graphite_legal_transform_dr, graphite_carried_dependence_level_k):
2687 Move from NNC_Polyhedron to C_Polyhedron.
2688 * graphite-interchange.c (compute_array_size_poly,
2689 gather_access_strides): Dito.
2690 * graphite-poly.c (apply_poly_transforms, new_poly_dr, free_poly_bb,
2691 free_scop, pbb_number_of_iterations): Dito.
2692 * graphite-poly.h (struct poly_dr, pdr_nb_subscripts, struct poly_bb,
2693 pbb_dim_iter_domain, struct scop): Dito.
2694 * graphite-ppl.c (new_Constraint_System_from_Cloog_Matrix,
2695 new_Cloog_Domain_from_ppl_Polyhedron,
2696 new_Cloog_Domain_from_ppl_Pointset_Powerset, ppl_set_coef_gmp,
2697 ppl_insert_dimensions_pointset, ppl_insert_dimensions_pointset,
2698 ppl_strip_loop, ppl_strip_loop, ppl_print_polyhedron_matrix,
2699 ppl_print_powerset_matrix, debug_ppl_polyhedron_matrix,
2700 debug_ppl_powerset_matrix, ppl_read_polyhedron_matrix): Dito.
2701 * graphite-ppl.h (ppl_Pointset_Powerset_C_Polyhedron_t,
2702 new_C_Polyhedron_from_Cloog_Matrix, ppl_print_powerset_matrix,
2703 debug_ppl_powerset_matrix, ppl_insert_dimensions_pointset): Dito.
2704 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons,
2705 build_loop_iteration_domains, ppl_constraint_type_from_tree_code,
2706 add_condition_to_domain, add_condition_to_pbb, build_scop_context,
2707 build_scop_iteration_domain, build_poly_dr): Dito
2709 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
2711 * gcc.dg/graphite/graphite.exp: Added a rule to execute
2713 * gcc.dg/graphite/run-id-1.c: New.
2715 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
2717 * graphite-sese-to-poly.c (build_loop_iteration_domains): Add the
2718 positivity constraint on the symbolic number of iterations.
2720 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
2722 * graphite-sese-to-poly.c (build_loop_iteration_domains): Rewrite.
2724 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
2725 Tobias Grosser <grosser@fim.uni-passau.de>
2727 * graphite-clast-to-gimple.c (build_scop_context): Removed.
2728 (build_cloog_prog): Directly use SCOP_CONTEXT.
2729 * graphite-poly.c (new_scop): Initialize SCOP_CONTEXT.
2730 (free_scop): Free SCOP_CONTEXT.
2731 (print_scop_context): New.
2732 (print_scop): Call print_scop_context.
2733 (debug_scop_context): New.
2734 * graphite-poly.h (print_scop_context, debug_scop_context): Declared.
2735 (struct scop): Added field context.
2736 (SCOP_CONTEXT): New.
2737 * graphite-sese-to-poly.c (add_param_constraints): New.
2738 (build_scop_context): New.
2739 (build_poly_scop): Call build_scop_context.
2741 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
2743 * graphite-clast-to-gimple.c (gmp_cst_to_tree): Moved...
2744 * graphite-ppl.c (ppl_set_inhomogeneous_gmp, ppl_set_coef_gmp): New.
2745 (ppl_set_inhomogeneous, ppl_set_coef): Moved...
2746 * graphite-ppl.h: Include double-int.h and tree.h.
2747 (ppl_set_inhomogeneous_gmp, ppl_set_coef_gmp): Declared.
2748 (ppl_set_inhomogeneous, ppl_set_coef): ...here.
2749 (gmp_cst_to_tree): ...here. Reimplemented using mpz_get_double_int.
2750 (tree_int_to_gmp, ppl_set_inhomogeneous_tree, ppl_set_coef_tree): New.
2752 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
2754 * graphite-clast-to-gimple.c (clast_to_gcc_expression_red): Generate
2755 POINTER_PLUS_EXPR for pointer types.
2756 (clast_to_gcc_expression): Same.
2758 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
2760 * graphite-poly.c (print_scattering_function): Early return when
2761 PBB_TRANSFORMED_SCATTERING is not initialized.
2762 (print_pbb_domain): Early return when PBB_DOMAIN is not initialized.
2764 2009-07-08 Sebastian Pop <sebastian.pop@amd.com>
2766 * tree-parloops.c (analyze_reduction_list): Remove unused variable
2769 2009-07-08 Razya Ladelsky <razya@il.ibm.com>
2771 * tree-parloops.c (analyze_reduction_list): Change return
2773 (try_create_reduction_list): Move the call to
2774 analyze_reduction_list to the beginining.
2775 Call reduction_phi with analyzed_reductions as argument
2776 instead of reduction_list.
2778 2009-07-08 Tobias Grosser <grosser@fim.uni-passau.de>
2780 * Merge from mainline (r148296:149346)
2782 2009-07-07 Sebastian Pop <sebastian.pop@amd.com>
2784 * graphite-scop-detection.c (graphite_can_represent_init): New.
2785 (graphite_can_represent_scev): Call graphite_can_represent_init:
2786 check that the initial value does not contain multiplications of
2788 (stmt_has_simple_data_refs_p): New.
2789 (stmt_simple_for_scop_p): Call stmt_simple_for_scop_p.
2790 (is_simple_operand): Fix formatting.
2791 * graphite-sese-to-poly.c (try_generate_gimple_bb): Fix formatting.
2793 2009-07-07 Sebastian Pop <sebastian.pop@amd.com>
2795 * gcc.dg/graphite/id-13.c: New.
2796 * graphite-sese-to-poly.c (graphite_stmt_p): Do not call
2797 analyze_scalar_evolution, use scalar_evolution_in_region.
2798 (scan_tree_for_params_right_scev): Add extra assert.
2799 (parameter_index_in_region_1): Split from parameter_index_in_region.
2800 (idx_record_params): Use scalar_evolution_in_region.
2801 (find_params_in_bb): Same.
2802 (find_scop_parameters): Same.
2803 (build_loop_iteration_domains): Same.
2804 (create_linear_expr_from_tree): Same.
2805 * sese.c (scalar_evolution_in_region): New.
2806 * sese.h (scalar_evolution_in_region): Declared.
2807 (defined_in_sese_p): New.
2808 * tree-scalar-evolution.c (compute_overall_effect_of_inner_loop): Not
2810 * tree-scalar-evolution.h (compute_overall_effect_of_inner_loop):
2813 2009-07-07 Sebastian Pop <sebastian.pop@amd.com>
2815 * Makefile.in: Replace dependences on tree-chrec.h with SCEV_H.
2816 TREE_DATA_REF_H also implies SCEV_H.
2818 2009-07-07 Sebastian Pop <sebastian.pop@amd.com>
2820 * graphite-poly.c (print_scop_params): New.
2821 (print_scop): Call print_scop_params.
2822 (debug_scop_params): New.
2823 * graphite-poly.h (print_scop_params, debug_scop_params): Declared.
2825 2009-07-07 Li Feng <nemokingdom@gmail.com>
2827 * gcc.dg/graphite/graphite_autopar/force-parallel-4.c: New.
2828 * gcc.dg/graphite/graphite_autopar/force-parallel-5.c: New.
2829 * gcc.dg/graphite/graphite_autopar/force-parallel-6.c: New.
2830 * gcc.dg/graphite/graphite_autopar/force-parallel-7.c: New.
2831 * gcc.dg/graphite/graphite_autopar/force-parallel-8.c: New.
2832 * gcc.dg/graphite/graphite_autopar/force-parallel-9.c: New.
2834 2009-07-07 Li Feng <nemokingdom@gmail.com>
2836 * graphite-clast-to-gimple.c (mark_loops_parallel): Dump information
2837 for dependency checking part.
2838 * gcc.dg/graphite/graphite_autopar/force-parallel-1.c: Add
2839 tests for dependency checking.
2840 * gcc.dg/graphite/graphite_autopar/force-parallel-2.c: Ditto.
2841 * gcc.dg/graphite/graphite_autopar/force-parallel-3.c: Ditto.
2842 * gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: Add
2843 flag -fdump-tree-graphite-all for autopar testsuites.
2845 2009-07-06 Sebastian Pop <sebastian.pop@amd.com>
2847 * Makefile.in (tree-ssa-loop-manip.o): Depends on langhooks.h.
2848 * tree-parloops.c (rewrite_phi_with_iv, rewrite_all_phi_nodes_with_iv,
2849 canonicalize_loop_ivs): Moved...
2850 * tree-ssa-loop-manip.c: ... here. Include langhooks.h.
2852 2009-07-06 Sebastian Pop <sebastian.pop@amd.com>
2854 * tree-parloops.c (try_create_reduction_list): Pass an extra
2855 argument analyzed_reductions. Call analyze_reduction_list.
2856 (gen_parallel_loop): Do not call analyze_reduction_list.
2857 (parallelize_loops): Init and finalize analyzed_reductions.
2859 2009-07-06 Li Feng <nemokingdom@gmail.com>
2861 * gcc.dg/graphite/graphite_autopar/graphite_autopar.exp:
2862 Added flag -fno-loop-strip-mine for autopar testcase.
2864 2009-07-04 Li Feng <nemokingdom@gmail.com>
2866 * graphite-dependences.c (graphite_carried_dependence_level_k): Use
2867 transformed scattering dimension instead of unmatch orignal when
2868 calling dependence_polyhedron.
2870 2009-06-30 Sebastian Pop <sebastian.pop@amd.com>
2872 * opts.c (decode_options): Enable flag_loop_strip_mine at -O2.
2874 2009-06-30 Sebastian Pop <sebastian.pop@amd.com>
2876 * graphite-poly.c (pbb_number_of_iterations): Check for returned
2877 value 1 from ppl_Pointset_Powerset_NNC_Polyhedron_maximize.
2879 2009-06-30 Sebastian Pop <sebastian.pop@amd.com>
2881 * graphite-blocking.c (pbb_strip_mine_profitable_p): New.
2882 (pbb_do_strip_mine): Call pbb_strip_mine_profitable_p.
2883 * graphite-poly.c (pbb_number_of_iterations): New.
2884 * graphite-poly.h (pbb_number_of_iterations): Declared.
2885 (pbb_iterator_dim, pbb_parameter_dim): New.
2887 2009-06-29 Sebastian Pop <sebastian.pop@amd.com>
2889 * graphite-clast-to-gimple.c (graphite_create_new_loop): Revert the
2890 last commit on type of lower and upper bound of loops.
2892 2009-06-29 Li Feng <nemokingdom@gmail.com>
2894 * Makefile.in (graphite-clast-to-gimple.o): Added dependence on
2895 graphite-dependences.h.
2896 * graphite-clast-to-gimple.c (new_bb_pbb_def): New.
2897 (mark_bb_with_pbb): New.
2898 (get_stmtfor_depth): New.
2899 (find_pbb_via_hash): New.
2900 (dependency_in_loop_p): New.
2901 (mark_loops_parallel): New.
2902 (free_aux_in_new_loops): New.
2903 (translate_clast): Add parameter BB_PBB_MAPPING. Mark newly created
2904 bb with it's relevant pbb. Mark newly created loops. Remove mark
2905 innermost loop parallel without checking.
2906 (gloog): Add parameter BB_PBB_MAPPING.
2907 * graphite-clast-to-gimple.h (struct bb_pbb_def): New.
2908 (gloog): Change declaration.
2909 (mark_loop_parallel): Make extern.
2910 (free_aux_in_new_loops): Declare.
2911 (bb_pbb_map_hash): New.
2912 (eq_bb_pbb_map): New.
2913 * graphite.c (graphite_transform_loops): Added BB_PBB_MAPPING. Trigger
2914 auto parallelization when flag_graphite_force_parallel is set.
2915 (graphite_finalize): Added free_aux_in_new_loops.
2916 * tree-parloops.c (parallelize_loops): Only generate parallel code for
2917 the innermost loop that marked parallel. Use
2918 flag_graphite_force_parallel instead of loop->can_be_parallel.
2919 (loop_parallel_p): Move inner most checking out of function.
2921 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2923 * graphite-clast-to-gimple.c (graphite_create_new_loop): Make the
2924 type of lower and upper bound of loops signed long int.
2926 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2928 * cfgloopmanip.c (create_empty_loop_on_edge): Gimplify the loop exit
2929 expression outside the loop.
2931 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2933 * gcc.dg/graphite/interchange-8.c: New.
2935 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2937 * gcc.dg/graphite/interchange-0.c: XFailed.
2938 * gcc.dg/graphite/interchange-5.c: XFailed.
2939 * gcc.dg/graphite/interchange-6.c: XFailed.
2941 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2943 * graphite-interchange.c (compute_array_size_poly): The end of the
2944 recursion should return 1.
2946 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2948 * graphite-interchange.c (compute_array_size_cstr): Allow the
2949 subscript multiplier to be -1.
2950 (compute_array_size): Use PDR_DATA_CONTAINER and not PDR_ACCESSES.
2951 * graphite-poly.c (new_poly_dr): Takes an extra argument for the
2952 data_container. Initializes PDR_DATA_CONTAINER.
2953 (print_pdr_access_layout): New.
2954 (print_pdr): Call print_pdr_access_layout. Print PDR_DATA_CONTAINER.
2955 * graphite-poly.h (struct poly_dr): Adjust comment. Add a new field
2957 (PDR_DATA_CONTAINER): New.
2958 (new_poly_dr): Update declaration.
2959 * graphite-sese-to-poly.c (pdr_add_data_dimensions): New.
2960 (build_poly_dr): Call pdr_add_data_dimensions.
2962 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2964 * graphite-poly.h (struct poly_dr): Fix comment.
2965 * graphite-sese-to-poly.c (pdr_add_alias_set): New.
2966 (pdr_add_memory_accesses): New.
2967 (build_poly_dr): Call pdr_add_memory_accesses and pdr_add_alias_set.
2969 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2971 * graphite-poly.c (print_pdrs, debug_pdrs): New.
2972 (print_pbb): Add call to print_pdrs.
2973 * graphite-poly.h (print_pdrs, debug_pdrs): Declared.
2975 2009-06-24 Konrad Trifunovic <konrad.trifunovic@gmail.com>
2976 Li Feng <nemokingdom@gmail.com>
2978 * graphite-dependences.c (graphite_carried_dependence_level_k): New.
2979 (dependency_between_pbbs_p): New.
2980 (lexicographically_gt_p): Assure !empty_p before polyhedron
2981 intersection assign.
2982 (build_lexicographically_gt_constraint): Correct lexicographically
2984 * graphite-dependences.h: New.
2985 * Makefile.in (graphite-dependences.o): Add graphite-dependences.h.
2987 2009-06-24 Sebastian Pop <sebastian.pop@amd.com>
2989 * graphite-clast-to-gimple.c (print_clast_stmt): New.
2990 (gloog): Print to dump_file the generated clast.
2991 * graphite-clast-to-gimple.h (print_clast_stmt): Declared.
2992 * graphite-interchange.c (pbb_do_interchange): Fix dump formatting.
2994 2009-06-24 Sebastian Pop <sebastian.pop@amd.com>
2996 * graphite-poly.c (extend_scattering): Increment
2997 PBB_NB_LOCAL_VARIABLES by the number of added dimensions.
2999 2009-06-24 Sebastian Pop <sebastian.pop@amd.com>
3001 * graphite-interchange.c (compute_array_size_poly): Added exit of
3002 recursion condition. Continue iterating even after the first equality.
3003 (compute_array_size): Same.
3005 2009-06-24 Li Feng <nemokingdom@gmail.com>
3007 * gcc.dg/graphite/graphite_autopar/force-parallel-1.c: Update
3008 -fdump-tree-final_cleanup to -fdump-tree-optimized.
3009 * gcc.dg/graphite/graphite_autopar/force-parallel-2.c: Ditto.
3010 * gcc.dg/graphite/graphite_autopar/force-parallel-3.c: Ditto.
3011 * gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: Ditto.
3013 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
3015 * sese.c (expand_scalar_variables_stmt): Expand scalar variables
3016 only when the use verifies is_gimple_reg.
3018 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
3020 * graphite-clast-to-gimple.c (build_cloog_prog): Fix memory corruption.
3021 Allocate scaldims after call to unify_scattering_dimensions.
3023 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
3025 * graphite-clast-to-gimple.c (translate_clast): Fix memory leak.
3027 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
3028 Albert Cohen <albert.cohen@inria.fr>
3030 * graphite-blocking.c (pbb_strip_mine_loop_depth): Do not use local
3031 variables for the strip mining.
3033 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
3034 Pranav Garg <pranav.garg2107@gmail.com>
3036 * Makefile.in (OBJS-common): Added graphite-blocking.o.
3037 (graphite-sese-to-poly.o): Moved down to be in lexicographical order.
3038 (graphite-blocking.o): New rule.
3039 (graphite-poly.o, graphite-ppl.o): Moved to be in lexicographical order.
3040 * graphite-blocking.c: New.
3041 * graphite-poly.c (apply_poly_transforms): Call scop_do_strip_mine for
3042 flag_loop_strip_mine.
3043 (psct_scattering_dim_for_loop_depth): New.
3044 * graphite-poly.h (scop_do_strip_mine): Declared.
3045 (psct_add_local_variable): Increment PBB_NB_LOCAL_VARIABLES.
3046 * tree-ssa-loop.c (gate_graphite_transforms): Do not fail when using
3047 flag_loop_strip_mine.
3049 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
3051 * graphite-poly.c (extend_scattering): Avoid initializing and freeing
3052 a GMP value and a PPL coefficient at each iteration of a loop.
3054 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
3056 * graphite-dependences.c (dependence_polyhedron): Do not use
3057 pbb_nb_scattering_dims anymore. Use pbb_nb_scattering_orig and
3058 pbb_nb_scattering_transform.
3059 (graphite_legal_transform_dr): Same.
3060 * graphite-poly.c (extend_scattering): Same.
3061 (unify_scattering_dimensions): Same.
3062 (print_scattering_function): Same.
3063 (new_poly_bb): Initialize PBB_NB_SCATTERING_TRANSFORM and
3064 PBB_NB_LOCAL_VARIABLES.
3065 * graphite-poly.h (pbb_nb_scattering): Removed declaration.
3066 (struct poly_bb): Added nb_local_variables and nb_scattering_transform.
3067 (PBB_NB_LOCAL_VARIABLES, PBB_NB_SCATTERING_TRANSFORM): New.
3068 (pbb_nb_scattering_orig, pbb_nb_scattering_transform): New.
3069 (pbb_nb_scattering_dims, pbb_nb_scattering): Removed.
3070 (pbb_nb_scattering_transform): New.
3071 (pbb_nb_local_vars): Return PBB_NB_LOCAL_VARIABLES.
3072 (psco_scattering_dim): Add assert on parameters.
3073 (psct_scattering_dim): Same.
3074 (psct_scattering_dim_for_loop_depth): Declared.
3075 (psct_local_var_dim): New.
3076 (psco_iterator_dim, psco_parameter_dim): Add assert on parameters.
3077 (psct_iterator_dim, psct_parameter_dim): Same. To maintain the
3078 correct layout, call pbb_nb_local_vars.
3079 (psct_add_local_variable, psct_add_scattering_dimension): New.
3080 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons):
3081 Initialize PBB_NB_SCATTERING_TRANSFORM.
3083 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
3085 * graphite-ppl.c (set_inhomogeneous): Renamed ppl_set_inhomogeneous.
3086 (set_coef): Renamed ppl_set_coef.
3087 * graphite-ppl.h (ppl_set_inhomogeneous, ppl_set_coef): Declared.
3089 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
3091 * graphite-dependences.c (build_pairwise_scheduling_inequality): Don't
3092 test a boolean against 1.
3093 * graphite-interchange.c (pbb_interchange_loop_depths): Do not build
3094 a new polyhedron for the PBB_TRANSFORMED_SCATTERING.
3095 (pbb_do_interchange): Returns true when a transform has been performed.
3096 (scop_do_interchange): Same.
3097 * graphite-poly.c (apply_poly_transforms): Use the return value of
3098 scop_do_interchange.
3099 * graphite-poly.h (scop_do_interchange): Update declaration.
3101 2009-06-23 Tobias Grosser <grosser@fim.uni-passau.de>
3103 * graphite-clast-to-gimple.c (gloog): Reset loop->aux right
3105 * sese.c (sese_reset_aux_in_loops): New.
3106 * sese.h (sese_reset_aux_in_loops): New.
3108 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
3110 * graphite-sese-to-poly.c (scan_tree_for_params_int): Pass in the
3111 multiplier and multiply the constant by the multiplier.
3112 (scan_tree_for_params): Bound the multiplier to its MULT_EXPR.
3113 (build_poly_dr): Do not use the multiplier to define the subscript.
3115 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
3117 * graphite-poly.c (new_poly_dr): Pass an extra argument for the
3118 compiler's data reference. Initialize PDR_CDR.
3119 (print_pdr): Call dump_data_reference.
3120 * graphite-poly.h (struct poly_dr): Rename black_box into pbb.
3121 Add compiler_dr field.
3122 (PDR_BB): Renamed PDR_PBB.
3124 * graphite-sese-to-poly.c (build_poly_dr): Pass to new_poly_dr
3125 GCC's data reference representation.
3126 * tree-data-ref.c (debug_data_references, debug_data_reference): New.
3127 * tree-data-ref.h (debug_data_references, debug_data_reference): Decl.
3129 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
3131 * graphite-poly.c (print_scattering_function): Also print the layout.
3132 * graphite-poly.h (pbb_nb_local_vars): New.
3134 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
3136 * graphite-poly.c (print_pbb_domain): Also print the layout names.
3138 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
3140 * graphite-poly.c (print_pdr, debug_pdr): New.
3141 * graphite-poly.h (print_pdr, debug_pdr): Declared.
3142 (PDR_BASE): Removed.
3144 2009-06-18 Sebastian Pop <sebastian.pop@amd.com>
3146 * gcc.dg/graphite/interchange-{1..7}.c: New avatars of
3149 2009-06-18 Sebastian Pop <sebastian.pop@amd.com>
3151 * graphite-interchange.c (compute_subscript): Allow also -1 in the
3152 subscript identification column.
3153 (pbb_do_interchange): Print to dump_file that some loops "will be
3154 interchanged". Rely on that chain of characters in the testcases.
3155 * gcc.dg/graphite/interchange-0.c: New.
3156 * gcc.dg/graphite/graphite.exp: Iterate over the testsuite
3157 interchange-*.c files and compile them with -floop-interchange.
3159 2009-06-18 Pranav Garg <pranav.garg2107@gmail.com>
3161 * graphite-interchange.c (interchange_profitable_p): Renamed
3162 pbb_interchange_profitable_p.
3164 2009-06-18 Sebastian Pop <sebastian.pop@amd.com>
3165 Harsha Jagasia <harsha.jagasia@amd.com>
3166 Pranav Garg <pranav.garg2107@gmail.com>
3168 * graphite-interchange.c (interchange_profitable_p): Make static.
3169 (pbb_interchange_loop_depths, pbb_do_interchange,
3170 scop_do_interchange): New.
3171 * graphite-poly.c (apply_poly_transforms): Call scop_do_interchange
3172 for flag_loop_interchange.
3173 * graphite-poly.h (scop_do_interchange): Declared.
3174 * tree-ssa-loop.c (gate_graphite_transforms): Do not fail when
3175 flag_loop_interchange is used.
3177 2009-06-18 Sebastian Pop <sebastian.pop@amd.com>
3179 * graphite-dependences.c (dependence_polyhedron): Update use of
3180 pbb_nb_scattering_dims.
3181 * graphite-poly.h (pbb_nb_scattering_dims): Do not pass SCOP.
3182 (pbb_nb_scattering): Update use of pbb_nb_scattering_dims.
3183 (psco_scattering_dim, psct_scattering_dim, psco_iterator_dim,
3184 psct_iterator_dim, psco_parameter_dim, psct_parameter_dim): New.
3186 2009-06-16 Sebastian Pop <sebastian.pop@amd.com>
3188 * graphite.c: Cleanup foo.
3190 2009-06-16 Sebastian Pop <sebastian.pop@amd.com>
3192 * Merge from mainline (r143684:148293).
3193 * Disabled libpcp until it gets fixed.
3195 2009-06-05 Sebastian Pop <sebastian.pop@amd.com>
3196 Harsha Jagasia <harsha.jagasia@amd.com>
3198 * graphite-interchange.c: New.
3199 * Makefile.in (graphite-interchange.o): New.
3200 * graphite-poly.h (interchange_profitable_p): Declared.
3201 * graphite-ppl.h (value_max): New.
3203 2009-06-04 Sebastian Pop <sebastian.pop@amd.com>
3205 * graphite-dependences.c (dependence_polyhedron): Use pdr_dim.
3206 * graphite-poly.h: Fix some comments.
3210 2009-06-04 Sebastian Pop <sebastian.pop@amd.com>
3213 (pdr_accessp_nb_subscripts): Renamed pdr_nb_subscripts.
3214 (pdr_accessp_nb_iterators): Renamed pdr_dim_iter_domain.
3215 (pdr_accessp_nb_params): Renamed pdr_nb_params.
3216 (pdr_accessp_alias_set_dim): Renamed pdr_alias_set_dim.
3217 (pdr_accessp_subscript_dim): Renamed pdr_subscript_dim.
3218 (pdr_accessp_iterator_dim): Renamed pdr_iterator_dim.
3219 (pdr_accessp_param_dim): Renamed pdr_parameter_dim.
3220 (pbb_nb_loops): Renamed pbb_dim_iter_domain.
3221 * graphite-clast-to-gimple.c: Same.
3222 * graphite-dependences.c: Same.
3223 * graphite-poly.c: Same.
3224 * graphite-sese-to-poly.c: Same.
3226 2009-06-03 Sebastian Pop <sebastian.pop@amd.com>
3228 * graphite-clast-to-gimple.c (build_iv_mapping): Insert full
3229 expressions for an IV rename, as returned by clast_to_gcc_expression.
3230 (copy_renames): Rename new_name to expr.
3231 * sese.c (debug_rename_elt): Same.
3234 (sese_adjust_liveout_phis): Call force_gimple_operand before using
3235 the information from the rename map.
3236 (rename_variables_in_stmt): Same.
3237 (add_loop_exit_phis): Rename new_name to expr.
3238 (insert_loop_close_phis): Same.
3239 (add_guard_exit_phis): Same. Call force_gimple_operand.
3240 * sese.h (struct rename_map_elt): Rename new_name to expr.
3241 (new_rename_map_elt): Same.
3243 2009-06-03 Sebastian Pop <sebastian.pop@amd.com>
3245 * graphite-clast-to-gimple.c (build_iv_mapping): Use set_rename.
3246 * sese.c (set_rename): Make it extern.
3247 * sese.h (set_rename): Declared.
3249 2009-06-03 Sebastian Pop <sebastian.pop@amd.com>
3251 * graphite-poly.c (extend_scattering): Free values.
3252 * graphite-ppl.c (new_Cloog_Domain_from_ppl_Pointset_Powerset):
3254 (ppl_print_powerset_matrix): Same.
3255 * graphite-scop-detection.c (free_scops_1): New.
3256 (limit_scops): Call free_scops_1.
3257 * graphite-sese-to-poly.c (build_scop_bbs_1): Free dom.
3258 (build_poly_dr): Free PPL coefficients.
3259 * tree-parloops.c (rewrite_all_phi_nodes_with_iv): Free bbs.
3261 2009-06-02 Sebastian Pop <sebastian.pop@amd.com>
3263 * graphite-dependences.c: New.
3264 * graphite-data-ref.c: Removed.
3265 * graphite-data-ref.h: Removed.
3266 * Makefile.in (graphite-data-ref.o): Removed.
3267 (graphite-dependences.o): Added.
3268 * graphite-clast-to-gimple.c: Remove dependence on graphite-data-ref.h.
3269 * graphite-poly.c: Same.
3270 Move the data dependence testing to graphite-dependences.c.
3272 2009-05-19 Tobias Grosser <grosser@fim.uni-passau.de>
3274 * graphite-scop-detection.c (graphite_can_represent_loop): Renamed
3275 from graphite_cannot_represent_loop. Code refactored.
3276 (scopdet_basic_block_info): Call graphite_can_represent_loop.
3278 2009-05-17 Li Feng <nemokingdom@gmail.com>
3280 * gcc.dg/graphite/graphite_autopar/graphite_autopar.exp:
3281 Cover all the testcases (not only the filtered ones).
3283 2009-05-17 Tobias Grosser <grosser@fim.uni-passau.de>
3285 * graphite-scop-detection.c (stmt_simple_for_scop_p): Remove
3286 unnecessary check. Update comments. Move check for REAL_TYPE here.
3287 (harmful_stmt_in_bb): Remove checks for conditions. This is already
3288 done in (stmt_simple_for_scop_p).
3290 2009-05-14 Tobias Grosser <grosser@fim.uni-passau.de>
3292 * graphite.c (print_global_statistics): New.
3293 (print_graphite_scop_statistic): New.
3294 (print_graphite_statistics): New.
3295 (graphite_initialize, graphite_transform_loops): Print statistics.
3296 * graphite-scop-detection (build_scops): Print statistics.
3297 (print_graphite_scop_statistics): New.
3298 (print_graphite_statistics): New.
3300 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
3302 * graphite-clast-to-gimple.c (struct clast_name_index): Removed.
3303 (debug_clast_name_index): Removed.
3304 (debug_clast_name_indexes_1): Removed.
3305 (debug_clast_name_indexes): Removed.
3306 (clast_name_index_elt_info): Removed.
3307 (eq_clast_name_indexes): Removed.
3308 (clast_name_to_index): Removed.
3309 (new_clast_name_index): Removed.
3310 (save_clast_name_index): Removed.
3311 (save_var_name): Moved...
3312 (init_sese_params_index): Removed.
3313 (clast_name_to_gcc): Remove use of name_tree.
3314 (initialize_cloog_names): Same.
3315 (gloog): Do not call init_sese_params_index.
3316 * graphite-sese-to-poly.c (save_var_name): ...here.
3317 (parameter_index_in_region): New.
3318 * sese.c (new_sese): Initialize SESE_PARAMS_NAMES.
3319 (parameter_index_in_region): Removed.
3320 (is_parameter): Remove use of name_tree.
3321 * sese.h (struct name_tree): Removed.
3322 (struct sese): Remove use of name_tree. New field params_names.
3323 (SESE_PARAMS_NAMES): New.
3324 (SESE_PARAMS): Remove duplicate.
3325 (parameter_index_in_region): Removed.
3326 (sese_nb_params): Remove use of name_tree.
3327 (struct clast_name_index): New.
3328 (new_clast_name_index): New.
3329 (clast_name_to_index): New.
3330 (save_clast_name_index): New.
3331 (debug_clast_name_index): New.
3332 (debug_clast_name_indexes_1): New.
3333 (debug_clast_name_indexes): New.
3334 (clast_name_index_elt_info): New.
3335 (eq_clast_name_indexes): New.
3337 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
3339 * graphite-clast-to-gimple.c (compute_cloog_iv_types_1): Call
3340 pbb_to_depth_to_oldiv. Remove call to oldiv_for_loop.
3341 (graphite_loop_normal_form): Do not pass region. Do not
3342 initialize SESE_OLDIVS.
3343 (build_graphite_loop_normal_form): Update call to
3344 graphite_loop_normal_form.
3345 * sese.c (debug_oldivs): Removed.
3346 (new_sese): Do not initialize SESE_OLDIVS.
3347 (free_sese): Do not free SESE_OLDIVS.
3348 (oldiv_for_loop): Removed.
3349 * sese.h (struct sese): Remove old_ivs.
3350 (SESE_OLDIVS): Removed.
3351 (oldiv_for_loop): Removed.
3353 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
3355 * graphite-clast-to-gimple.c (clast_name_to_gcc): Pass newivs,
3356 remove ivstack. Remove call to loop_iv_stack_get_iv_from_name,
3357 replaced by a call to newivs_to_depth_to_newiv.
3358 (clast_to_gcc_expression): Pass newivs, remove ivstack.
3359 (clast_to_gcc_expression_red): Same.
3360 (gcc_type_for_clast_expr): Same.
3361 (gcc_type_for_clast_eq): Same.
3362 (graphite_translate_clast_equation): Same.
3363 (graphite_create_guard_cond_expr): Same.
3364 (graphite_create_new_guard): Same.
3365 (graphite_create_new_loop): Same.
3366 (build_iv_mapping): Same.
3367 (translate_clast): Same.
3369 (loop_iv_stack_patch_for_consts): Removed. *
3370 sese.c (iv_stack_entry_is_constant): Removed.
3371 (iv_stack_entry_is_iv): Removed.
3372 (loop_iv_stack_push_iv): Removed.
3373 (loop_iv_stack_insert_constant): Removed.
3374 (loop_iv_stack_pop): Removed.
3375 (loop_iv_stack_get_iv): Removed.
3376 (loop_iv_stack_get_iv_from_name): Removed.
3377 (debug_loop_iv_stack): Removed.
3378 (free_loop_iv_stack): Removed.
3379 (loop_iv_stack_remove_constants): Removed. *
3380 sese.h (iv_stack_entry_kind): Removed.
3381 (iv_stack_entry_data_union): Removed.
3382 (iv_stack_entry_struct): Removed.
3383 (iv_stack_entry_p): Removed.
3384 (debug_oldivs, debug_loop_iv_stack, loop_iv_stack_insert_constant,
3385 loop_iv_stack_get_iv_from_name, loop_iv_stack_push_iv,
3386 loop_iv_stack_get_iv, loop_iv_stack_remove_constants,
3387 loop_iv_stack_pop, free_loop_iv_stack): Removed.
3388 (gbb_loop_at_index): Fix indenting.
3389 (gbb_loop_index): Removed.
3391 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
3393 * graphite-clast-to-gimple.c (clast_name_to_gcc): Do not use strcmp.
3394 Call clast_name_to_index.
3396 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
3398 * graphite-clast-to-gimple.c (clast_name_to_gcc): Pass region,
3399 do not pass params. Get params from SESE_PARAMS.
3400 (clast_to_gcc_expression): Same.
3401 (clast_to_gcc_expression_red): Same.
3402 (gcc_type_for_clast_eq): Same.
3403 (graphite_translate_clast_equation): Same.
3404 (graphite_create_new_loop): Same.
3405 * sese.c (rename_variables_in_stmt): Fix comment.
3407 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
3409 * graphite-clast-to-gimple.c (graphite_create_new_loop): Pass
3411 Call save_clast_name_index.
3412 (translate_clast): Pass newivs_index.
3413 (gloog): Create and free newivs_index.
3415 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
3417 * graphite-clast-to-gimple.c (clast_name_index): New structure.
3418 (clast_name_index_p): New type.
3419 (debug_clast_name_index): New.
3420 (debug_clast_name_indexes_1): New.
3421 (debug_clast_name_indexes): New.
3422 (clast_name_index_elt_info): New.
3423 (eq_clast_name_indexes): New.
3424 (clast_name_to_index): New.
3425 (new_clast_name_index): New.
3426 (save_clast_name_index): New.
3427 (init_sese_params_index): New.
3428 (gloog): Call init_sese_params_index.
3429 * graphite-clast-to-gimple.h (debug_clast_name_indexes): Declared.
3430 * sese.c (new_sese): Initialize SESE_PARAMS_INDEX.
3431 (free_sese): Free SESE_PARAMS_INDEX.
3432 * sese.h (struct sese): Add params_index.
3433 (SESE_PARAMS_INDEX): New.
3435 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
3437 * graphite-clast-to-gimple.c (newivs_to_depth_to_newiv): New.
3438 (graphite_create_new_loop): Pass the newivs vector. Push the
3439 newly created IV to newivs.
3440 (translate_clast): Pass the newivs vector.
3441 (gloog): Create and destroy the newivs vector.
3443 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
3445 * graphite-clast-to-gimple.c (pbb_to_depth_to_oldiv): New.
3446 (graphite_loop_normal_form): Initialize loop->aux with the unique
3447 IV that has been created.
3449 2009-05-13 Tobias Grosser <grosser@fim.uni-passau.de>
3451 * tree-chrec.c (evolution_function_right_is_integer_cst): Allow
3452 scev with parameters in the base part. They where forbidden
3455 2009-05-11 Li Feng <nemokingdom@gmail.com>
3457 * gcc.dg/graphite/graphite.exp: Set different default
3458 compile options by file names.
3459 * gcc.dg/graphite/block{0-6}.c: Remove dg-option line.
3460 * gcc.dg/graphite/id-{1-9}.c: Ditto.
3461 * gcc.dg/graphite/scop-{0-20}.c: Ditto.
3462 * gcc.dg/graphite/scop-matmult.c: Ditto.
3464 2009-05-08 Li Feng <nemokingdom@gmail.com>
3466 * gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: New.
3467 * gcc.dg/graphite/graphite_autopar/force-parallel-1.c: New.
3468 * gcc.dg/graphite/graphite_autopar/force-parallel-2.c: New.
3469 * gcc.dg/graphite/graphite_autopar/force-parallel-3.c: New.
3471 2009-05-07 Tobias Grosser <grosser@fim.uni-passau.de>
3473 * graphite-scop-detection (build_scops_1): Fix little bug introduced
3476 2009-05-07 Tobias Grosser <grosser@fim.uni-passau.de>
3478 * graphite-scop-detection.c (graphite_can_represent_scev): Only
3479 allow integer constant strides.
3480 (graphite_can_represent_expr): Depend on outermost_loop.
3481 (stmt_simple_memref_p, graphite_cannot_represent_loop,
3482 harmful_stmt_in_bb, is_simple_operand, stmt_simple_for_scop_p,
3483 build_scops_1): Same.
3484 (scopdet_basic_block_info): Same and insert layered SCoP
3486 (try_generate_gimple_bb): Cleanup.
3487 (build_scops): Enable data references.
3489 * gcc.dg/graphite/id-5.c: New.
3490 * gcc.dg/graphite/id-9.c: New.
3491 * tree-chrec.c (evolution_function_right_is_integer_cst): New.
3492 * tree-chrec.h (evolution_function_right_is_integer_cst): New.
3494 2009-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
3496 * sese.c (expand_scalar_variables_ssa_name): Only build expressions,
3497 that we have not yet built for this SCoP.
3499 2009-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
3501 * sese.c (expand_scalar_variables_expr): Fix expand_scalar_variables
3502 for complex numbers.
3504 2009-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
3506 * graphite-ppl.c: Fix build if cloog is not available.
3508 2009-05-04 Li Feng <nemokingdom@gmail.com>
3510 * tree-parloops.c (loop_parallel_p): Remove construction of
3511 NITER and REDUCTION_LIST.
3512 (try_get_loop_niter): New.
3513 (try_create_reduction_list): New.
3514 (parallelize_loops): Bypass the failed checkings in autopar
3515 when can_be_parallel in loop structure is set to true.
3517 2009-05-01 Tobias Grosser <grosser@fim.uni-passau.de>
3519 * gcc.dg/graphite/id-6.c: Update testcase.
3520 * gcc.dg/graphite/scop-3.c: Dito.
3522 2009-05-01 Tobias Grosser <grosser@fim.uni-passau.de>
3524 * graphite-scop-detection.c (stmt_simple_for_scop_p):
3525 Enable EQ_EXPR and NE_EXPR again.
3527 2009-04-30 Tobias Grosser <grosser@fim.uni-passau.de>
3529 * graphite-scop-detection.c (graphite_can_represent_scev):
3530 Add check if scev is affine multivariate.
3531 (harmful_stmt_in_bb): Check if we can represent the conditions.
3532 (scopdet_basic_block_info (basic_block bb, VEC): Pass the loop to
3534 * gcc.dg/graphite/id-7.c: New.
3536 2009-04-30 Tobias Grosser <grosser@fim.uni-passau.de>
3538 * graphite-sese-to-poly.c (bb_contains_non_iv_scalar_phi_nodes):
3539 Check all bbs in region, not only the bbs that are represented in
3541 (build_poly_scop): Add newline.
3542 * gcc.dg/graphite/id-8.c: New.
3544 2009-04-30 Li Feng <nemokingdom@gmail.com>
3546 * cfgloop.c (alloc_loop): Initialize can_be_parallel to false
3547 when loop initialize.
3548 * cfgloop.h (struct loop): Introduce flag can_be_parallel.
3549 * common.opt: Declare flag_graphite_force_parallel.
3550 * graphite-clast-to-gimple.c (translate_clast): Mark the innermost
3552 * graphite-poly.c (apply_poly_transforms): Introduce
3553 flag_graphite_force_parallel.
3554 * tree-ssa-loop.c (gate_graphite_transforms): ditto.
3555 * toplev.c (process_options): ditto and replace a not correctly
3558 2009-04-30 Li Feng <nemokingdom@gmail.com>
3560 * graphite-clast-to-gimple.c (loop_iv_stack_patch_for_consts):
3561 Change the call of gbb_loop_at_index and/or gbb_loop_index due
3562 to the redefinition.
3563 (compute_cloog_iv_types_1): ditto.
3564 (build_iv_mapping): ditto.
3565 * graphite-sese-to-poly.c (new_gimple_bb): Remove GBB_LOOPS related
3567 (free_gimple_bb): Removed GBB_LOOPS related free part.
3568 (build_bb_loops): Removed.
3569 * sese.h (struct gimple_bb): Removed loops.
3570 (GBB_LOOPS): Removed.
3571 (gbb_loop_at_index): Instead of using GBB_LOOPS, we use sese instead.
3572 (gbb_loop_index): ditto.
3574 2009-04-24 Tobias Grosser <grosser@fim.uni-passau.de>
3576 * graphite-scop-detection.c (graphite_can_represent_scev): Do not
3577 allow non constant strides.
3578 * gcc.dg/graphite/scop-20.c: New.
3580 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
3582 * graphite-scop-detection.c (dot_all_scops): Fix system call
3583 return value warning.
3586 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
3588 * gcc.dg/graphite/id-6.c: Fix pattern.
3589 * gcc.dg/graphite/scop-3.c: Same.
3591 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
3593 * graphite-poly.c (map_into_dep_poly, map_dr_into_dep_poly,
3594 build_pairwise_constraint, dr_equality_constraints,
3595 build_pairwise_scheduling_equality,
3596 build_pairwise_scheduling_inequality, lexicographically_gt_p,
3597 build_lexicographically_gt_constraint, dependence_polyhedron,
3598 graphite_legal_transform_dr, graphite_legal_transform_bb,
3599 graphite_legal_transform): New.
3600 * graphite-poly.h (graphite_legal_transform): Declared.
3601 * graphite-sese-to-poly.c (build_poly_scop): Call to
3602 graphite_legal_transform is disabled for the moment.
3604 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
3606 * graphite-poly.h (pbb_nb_scattering_dims): New.
3607 (pbb_nb_scattering): Use it.
3609 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
3611 * graphite-ppl.c (ppl_insert_dimensions_pointset): Add
3612 Pointset_Powerset version of ppl_insert_dimensions.
3613 * graphite-ppl.h (ppl_insert_dimensions_pointset): Declared.
3615 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
3617 * graphite-ppl.c (ppl_insert_dimensions): Fix formatting.
3619 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
3621 * graphite-poly.h: Fix comment.
3623 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
3625 * graphite-sese-to-poly.c (build_poly_dr): Fix data ref multiplier.
3627 2009-04-24 Tobias Grosser <grosser@fim.uni-passau.de>
3629 * sese.c (expand_scalar_variables_stmt): Only iterate over the old
3632 2009-04-24 Tobias Grosser <grosser@fim.uni-passau.de>
3634 * graphite-sese-to-poly.c (var_used_in_not_loop_header_phi_node): New.
3635 (graphite_stmt_p): Represent bbs necessary to build the phi nodes of
3638 2009-04-20 Sebastian Pop <sebastian.pop@amd.com>
3640 * graphite-scop-detection.c (stmt_simple_for_scop_p): Do not
3641 handle EQ_EXPR and NE_EXPR.
3643 2009-04-17 Tobias Grosser <grosser@fim.uni-passau.de>
3645 * graphite-poly.h (poly_dr): Fix comment.
3647 2009-04-09 Sebastian Pop <sebastian.pop@amd.com>
3648 Tobias Grosser <grosser@fim.uni-passau.de>
3650 * graphite-poly.c (new_poly_bb): Do not initialize PBB_DOMAIN
3651 with a zero dimension polyhedron.
3652 (find_scop_parameters): Move the call to scop_set_nb_params here.
3653 (build_loop_iteration_domains): Store in loop->aux the iteration
3655 (build_scop_iteration_domain): Fix PBB_DOMAIN for bbs not surrounded
3656 by any loop in scop.
3657 (build_poly_scop): Do not call scop_set_nb_params.
3659 2009-04-09 Sebastian Pop <sebastian.pop@amd.com>
3660 Tobias Grosser <grosser@fim.uni-passau.de>
3662 * graphite-sese-to-poly.c (add_condition_to_pbb): Pass code to
3663 add_condition_to_domain not GT_EXPR.
3665 2009-04-09 Tobias Grosser <grosser@fim.uni-passau.de>
3667 * graphite-ppl.c (debug_ppl_powerset_matrix): New.
3668 * graphite-ppl.h (debug_ppl_powerset_matrix): New.
3669 * graphite-sese-to-poly.c (add_condition_to_pbb): Use
3670 upper_bound_assign to calculate unions.
3671 * gcc.dg/graphite/id-6.c: New.
3673 2009-04-09 Tobias Grosser <grosser@fim.uni-passau.de>
3675 * graphite-scop-detection.c (canonicalize_loop_closed_ssa): Do not
3676 handle abnormal edges.
3678 2009-04-09 Tobias Grosser <grosser@fim.uni-passau.de>
3680 * graphite-poly.c (new_poly_dr, free_poly_dr): New.
3681 (free_poly_bb): Also free poly_drs.
3682 * graphite-poly.h (new_poly_dr, free_poly_dr): New.
3683 (poly_dr): Polyhedron to Pointset_Powerset.
3684 (pdr_accessp_nb_subscripts): Same.
3685 * graphite-sese-to-poly.c (build_poly_dr): Same. And actually build
3688 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
3690 * graphite-clast-to-gimple.c (initialize_cloog_names): Change cloog
3691 names into more meaningful names.
3693 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
3695 * gfortran.dg/graphite/interchange-1.c: New.
3696 * gfortran.dg/graphite/interchange-2.c: New.
3698 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
3700 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not build
3702 * tree-parloops.c (rewrite_phi_with_iv): New.
3703 (rewrite_all_phi_nodes_with_iv): New.
3704 (canonicalize_loop_ivs): Call them.
3706 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
3708 * graphite-sese-to-poly.c (try_generate_gimple_bb): Use
3709 graphite_find_data_references_in_stmt.
3710 * tree-data-ref.c (graphite_find_data_references_in_stmt): New.
3711 * tree-data-ref.h (graphite_find_data_references_in_stmt): Declared.
3713 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
3715 * sese.c (add_loop_exit_phis): Don't fail on non SSA_NAME renames.
3717 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
3719 * graphite-sese-to-poly.c (build_scop_bbs_1): Use bb_in_sese_p
3720 instead of bb_in_region.
3721 (flag_bb_in_region): Same. Renamed flag_bb_in_sese.
3722 (build_sese_conditions): Use flag_bb_in_sese.
3723 * sese.c (register_bb_in_sese): Removed.
3724 (new_sese): Remove initialization of SESE_REGION_BBS.
3725 (free_sese): Do not free SESE_REGION_BBS.
3726 * sese.h (struct sese): Remove field region_basic_blocks.
3727 (SESE_REGION_BBS): Removed.
3728 (bb_in_sese_p): Implement in function of bb_in_region.
3730 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
3732 * graphite-scop-detection.c (limit_scops): Deal only with single exit
3735 2009-04-08 Tobias Grosser <grosser@fim.uni-passau.de>
3737 * graphite-scop-detection.c (stmt_simple_for_scop_p): Allow NE_EXPR
3739 * graphite-sese-to-poly.c (create_linear_expr_from_tree): New.
3740 (add_condition_to_domain): New.
3741 (add_condition_to_pbb): New.
3742 (add_conditions_to_domain): Cleanup and handle of NE_EXPR and EQ_EXPR.
3743 * gcc.dg/graphite/scop-3.c: Update number of detected SCoPs.
3745 2009-04-08 Tobias Grosser <grosser@fim.uni-passau.de>
3747 * graphite-clast-to-gimple.c (build_cloog_prog): ppl_Polyhedron ->
3748 ppl_Pointset_Powerset.
3749 * graphite-poly.c (new_poly_bb, free_poly_bb): Same.
3750 * graphite-poly.h (poly_bb): poly_bb.domain Same.
3751 (pbb_nb_loops): Same.
3752 * graphite-sese-to-poly.c (build_loop_iteration_domains,
3753 add_conditions_to_domain): Same.
3754 * graphite-ppl.c (new_Cloog_Domain_from_ppl_Pointset_Powerset): New.
3755 (ppl_print_polyhedron_matrix): ppl_Polyhedron_t ->
3756 ppl_const_Polyhedron_t.
3757 (ppl_print_powerset_matrix): New.
3758 * graphite-ppl.h (new_Cloog_Domain_from_ppl_Pointset_Powerset,
3759 ppl_print_powerset_matrix): New.
3760 (ppl_print_polyhedron_matrix): Updated.
3762 2009-04-07 Sebastian Pop <sebastian.pop@amd.com>
3764 * tree-scalar-evolution.c (analyze_scalar_evolution_1): Fix comment.
3766 2009-04-07 Sebastian Pop <sebastian.pop@amd.com>
3768 * graphite-poly.c (extend_scattering): Fix indenting. Free cstr.
3769 (print_iteration_domains, debug_iteration_domain,
3770 debug_iteration_domains): New.
3771 * graphite-poly.h (print_iteration_domains, debug_iteration_domain,
3772 debug_iteration_domains): Declared.
3773 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons): Fix
3776 2009-04-03 Tobias Grosser <grosser@fim.uni-passau.de>
3777 Sebastian Pop <sebastian.pop@amd.com>
3779 * graphite-poly.h (print_iteration_domain): New.
3780 * graphite-sese-to-poly.c (add_conditions_to_domain): Fixed bug.
3781 (build_sese_conditions_1, build_sese_conditions_after,
3782 build_sese_conditions_before): New.
3783 (build_sese_conditions): Rewritten.
3785 2009-04-03 Sebastian Pop <sebastian.pop@amd.com>
3786 Tobias Grosser <grosser@fim.uni-passau.de>
3788 Cleanup of code generation liveouts.
3789 * graphite-clast-to-gimple.c (translate_clast): Use a single
3790 rename_map instead of one per translated statement.
3791 Do not use SESE_LIVEOUT_RENAMES.
3792 (graphite_loop_normal_form): Do not use SESE_REDUCTION_LIST.
3793 (gloog): Do not use SESE_LIVEOUT_RENAMES.
3794 * graphite-scop-detection.c (harmful_stmt_in_bb): Return the close
3795 phi node of a reduction: when a loop contains a reduction used outside
3796 the loop, there should be a scalar close phi node on the exit block.
3797 * sese.c (new_sese): Do not initialize SESE_LIVEOUT,
3798 SESE_LIVEOUT_RENAMES, and SESE_REDUCTION_LIST.
3799 (free_sese): Do not free them.
3800 (sese_build_liveouts_use): Do not use them.
3801 (sese_build_liveouts_bb): Same.
3802 (sese_build_liveouts): Same.
3803 (sese_insert_phis_for_liveouts): Same.
3804 (sese_adjust_phis_for_liveouts): Same. Renamed sese_adjust_liveout_phis.
3805 (defined_in_loop_p): New.
3806 (alive_after_loop): New.
3807 (close_phi_not_yet_inserted_p): New.
3808 (struct alep, alep_p): New.
3809 (add_loop_exit_phis): Remove from the rename_map all the names defined
3810 in the code generated loop.
3811 (insert_loop_close_phis): Traverse the rename_map passed to it.
3812 Don't use SESE_LIVEOUT_RENAMES.
3813 (default_liveout_before_guard): Renamed default_before_guard.
3814 (insert_guard_phis): Do not use SESE_LIVEOUT_RENAMES.
3815 (graphite_copy_stmts_from_block): Do not directly call set_rename.
3816 (register_sese_liveout_renames): Removed.
3817 (copy_bb_and_scalar_dependences): Do not call it.
3818 * sese.h (struct sese): Removed fields: liveout, liveout_renames, and
3820 (SESE_LIVEOUT): Removed.
3821 (SESE_LIVEOUT_RENAMES): Removed.
3822 (SESE_REDUCTION_LIST): Removed.
3823 (sese_build_liveouts): Removed.
3824 (sese_adjust_phis_for_liveouts): Renamed sese_adjust_liveout_phis.
3825 (insert_loop_close_phis): Pass a htab_t instead of a sese.
3826 (insert_guard_phis): Same.
3827 (rename_map_elt): Declare a VEC of them.
3828 * tree-parloops.c (canonicalize_loop_ivs): reduction_list contains
3829 trees not pointers to trees.
3831 Rewrite in canonical close SSA form:
3832 * graphite-scop-detection.c (contains_only_close_phi_nodes): New.
3833 (limit_scops): Close the scop after the block containing the close phi
3835 (canonicalize_loop_closed_ssa): New.
3836 (canonicalize_loop_closed_ssa_form): New.
3837 (build_scops): Call canonicalize_loop_closed_ssa_form.
3839 * graphite-sese-to-poly.c: Fix typos.
3841 2009-04-03 Sebastian Pop <sebastian.pop@amd.com>
3843 * graphite-poly.c (print_scattering_function, print_pbb_domain):
3845 (dump_gbb_conditions, dump_gbb_cases, print_iteration_domain): New.
3846 (print_pbb): Add conditions.
3848 2009-04-01 Tobias Grosser <grosser@fim.uni-passau.de>
3849 Sebastian Pop <sebastian.pop@amd.com>
3851 * graphite-scop-detection.c (bb_in_sd_region): Use bb_in_region.
3852 * graphite-sese-to-poly.c (all_non_dominated_preds_marked_p): New.
3853 (build_scop_bbs_1): New.
3854 (build_scop_bbs): Rewrite.
3855 * sese.h (bb_in_region): New.
3857 2009-03-29 Tobias Grosser <grosser@fim.uni-passau.de>
3859 * graphite-poly.c (new_poly_bb, free_poly_bb): Initialize/free
3861 (print_scop): Style.
3862 * graphite-poly.h (poly_bb): Add drs vector.
3863 (PBB_DRS): Add accessor.
3864 * graphite-sese-to-poly.c (build_poly_dr): New.
3865 (build_pbb_drs, build_scop_drs): New.
3866 (build_poly_scop): call build_scop_drs (Disabled at the moment).
3868 2009-03-29 Tobias Grosser <grosser@fim.uni-passau.de>
3870 * tree-ssa-loop.c: Include forgotten toplev.h
3872 2009-03-29 Tobias Grosser <grosser@fim.uni-passau.de>
3874 * graphite-poly.c: (apply_poly_transforms): sorry -> gcc_unreachable.
3875 * gcc.dg/graphite/pr37883.c: Remove -floop-*
3876 * gcc.dg/graphite/pr37928.c: Same
3877 * gcc.dg/graphite/pr38409.c: Same
3878 * gcc.dg/graphite/pr38498.c: Same
3879 * gcc.dg/graphite/pr38559.c: Same
3880 * gcc.dg/graphite/pr39335.c: Same
3881 * gcc.dg/graphite/pr39335_1.c: Same
3882 * gfortran.dg/graphite/block-2.f: Same
3883 * tree-ssa-loop.c (gate_graphite_transforms): Always fail if called
3886 2009-03-28 Tobias Grosser <grosser@fim.uni-passau.de>
3888 * graphite-sese-to-poly.c (ref_nb_loops, build_access_matrix_with_af,
3889 build_access_matrix, build_scop_data_accesses): Remove access function
3890 building. (We get a new version soon).
3891 (build_bb_loops, scan_tree_for_params_right_scev): Update.
3892 * sese.h (nb_loops_around_loop_in_sese): Remove.
3893 (sese_loop_depth): Do not use SESE_LOOP_NEST any more.
3895 2009-03-27 Tobias Grosser <grosser@fim.uni-passau.de>
3896 Sebastian Pop <sebastian.pop@amd.com>
3898 * graphite-scop-detection.c (struct scopdet_info): Rename last
3900 (scopdet_basic_block_info, build_scops_1): Don't use
3901 CDI_POST_DOMINATORS. CDI_POST_DOMINATORS should never be used.
3903 2009-03-26 Tobias Grosser <grosser@fim.uni-passau.de>
3904 Sebastian Pop <sebastian.pop@amd.com>
3906 * graphite-clast-to-gimple.c (gloog): Call sese_build_liveouts.
3907 * sese.c (sese_build_liveouts_use): Renamed from
3908 sese_build_livein_liveouts_use. Remove liveins.
3909 (sese_build_liveouts_bb): Renamed from sese_build_livein_liveouts_bb.
3910 Call sese_build_liveouts_use.
3911 (sese_build_liveouts): Renamed from sese_build_livein_liveouts.
3912 Call sese_build_liveouts_bb.
3913 (new_sese, free_sese): Remove liveins.
3914 (sese_add_exit_phis_var): Deleted.
3915 (sese_insert_phis_for_liveouts): Call sese_add_exit_phis_edge
3917 (graphite_copy_stmts_from_block): Remove SESE_NUM_VER.
3919 * sese.h (sese): Remove num_ver and livein.
3920 (SESE_LIVEIN, SESE_LIVEIN_VER, SESE_NUM_VER): Removed.
3922 2009-03-25 Tobias Grosser <grosser@fim.uni-passau.de>
3924 * graphite-sese-to-poly.c (build_scop_scattering): Fix compile.
3926 2009-03-25 Tobias Grosser <grosser@fim.uni-passau.de>
3928 * graphite-sese-to-poly.c (compare_prefix_loops): Removed.
3929 (build_scop_scattering): Do not use compare_prefix_loops any more.
3930 (nb_common_loops): New.
3932 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
3934 * sese.c (get_new_name_from_old_name): Renamed get_rename.
3935 (register_old_and_new_names): Renamed set_rename.
3937 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
3939 * graphite-scop-detection.h (nb_reductions_in_loop): Revert removal
3940 of the decl from the previous commit.
3942 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
3944 * graphite-scop-detection.c (dot_scop): New.
3945 * graphite-scop-detection.h (dot_scop): Declared.
3947 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
3949 * graphite-sese-to-poly.c (compare_prefix_loops): Fix compare.
3951 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
3953 * cfgloopmanip.c (create_empty_loop_on_edge): Generate the loop exit
3954 condition at the end of the loop.
3955 * graphite.c (graphite_initialize, graphite_finalize): Print to
3956 dump_file the compiled function.
3957 * graphite-clast-to-gimple.c (graphite_create_new_loop): Update use
3958 of create_empty_loop_on_edge.
3959 (translate_clast): Update the code generation of loops for the new
3961 * cfgloop.h (create_empty_loop_on_edge): Update declaration.
3963 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
3965 Reverted the patch from 2009-03-19.
3967 2009-03-19 Tobias Grosser <grosser@fim.uni-passau.de>
3969 * graphite-poly.c (new_poly_bb, free_poly_bb): Initialize/free
3971 (print_scop): Style.
3972 * graphite-poly.h (poly_bb): Add drs vector.
3973 (PBB_DRS): Add accessor.
3974 * graphite-sese-to-poly.c (ref_nb_loops): Remove.
3975 (build_access_matrix_with_af, build_access_matrix,
3976 build_scop_data_accesses): Delete.
3977 (build_poly_dr): New.
3978 (build_pbb_drs, build_scop_drs): New.
3979 (build_poly_scop): call build_scop_drs.
3981 2009-03-13 Sebastian Pop <sebastian.pop@amd.com>
3983 * graphite-scop-detection.c (dot_all_scops_1): Close the table
3984 once per basic block.
3986 2009-03-13 Tobias Grosser <grosser@fim.uni-passau.de>
3988 * graphite-scop-detection.c (graphite_can_represent_scev): New.
3989 (graphite_can_represent_expr): Renamed from loop_affine_expr
3991 (stmt_simple_for_scop_p): Call graphite_can_represent_expr.
3992 (graphite_cannot_represent_loop): Add scop_entry to parameters.
3993 (scopdet_basic_block_info): Actually define entry_block.
3994 (stmt_simple_memref_p): Moved here from ...
3996 * tree-data-ref.c (stmt_simple_memref_p): here.
3997 * tree-data-ref.h (stmt_simple_memref_p): Removed.
3999 2009-03-13 Tobias Grosser <grosser@fim.uni-passau.de>
4001 * gcc.dg/graphite/id-4.c: New.
4003 2009-03-12 Sebastian Pop <sebastian.pop@amd.com>
4005 * sese.c (expand_scalar_variables_expr): Handle tcc_comparison.
4006 (register_old_and_new_names): Update the content of the map.
4007 When there was already a rename_map_elt in the map at that
4009 (copy_bb_and_scalar_dependences): Do rename_variables after
4010 expand_scalar_variables.
4011 * graphite-clast-to-gimple.c (build_iv_mapping): Update the content
4012 of the map. When there was already a rename_map_elt in the
4013 map at that location, free it.
4014 (translate_clast): Pass the rename_map. Do not initialize and free
4015 a rename_map per stmt_user.
4016 (gloog): Initialize and free one rename_map and pass it to
4019 2009-03-12 Sebastian Pop <sebastian.pop@amd.com>
4021 * sese.c (expand_scalar_variables_stmt,
4022 expand_scalar_variables_ssa_name): Add a gimple_stmt_iterator
4024 (expand_scalar_variables_expr): Handle REALPART_EXPR and IMAGPART_EXPR.
4025 (expand_scalar_variables): Pass to expand_scalar_variables_stmt
4026 the gimple_stmt_iterator of the statement to be expanded.
4027 * graphite-scop-detection.c (is_simple_operand): Do handle
4030 2009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
4032 * graphite-scop-detection.c (is_simple_operand): Do not handle
4034 * gcc.dg/graphite/id-2.c: New.
4036 * graphite-sese-to-poly.c (build_bb_loops,
4037 add_value_to_dim, scan_tree_for_params_right_scev,
4038 scan_tree_for_params_int, scan_tree_for_params, idx_record_params,
4039 find_params_in_bb, build_loop_iteration_domains,
4040 add_conditions_to_domain): Remove subtract.
4042 2009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
4044 * graphite-clast-to-gimple.c (loop_iv_stack_patch_for_consts,
4045 build_iv_mapping, compute_cloog_iv_types_1, build_cloog_prog):
4046 pbb_loop_at_index -> gbb_loop_at_index.
4047 * graphite-poly.c (new_poly_bb, new_scop): New accessors.
4048 (debug_loop_vec): Delete.
4049 * graphite-poly.h (poly_bb, scop): Change black_box and region to void
4050 pointer. Move LOOPS to gimple_bb_p and insert nb_params.
4051 (PBB_LOOPS): Removed.
4052 (PBB_BLACK_BOX): Insert cast.
4053 (pbb_set_black_box): New setter.
4054 (pbb_loop_at_index, pbb_loop_index): Removed.
4055 (scop_set_region, scop_set_nb_params): New.
4056 * graphite-sese-to-poly.c (new_gimple_bb, free_gimple_bb,
4057 build_scop_scattering, build_bb_loops): Add GBB_LOOPS.
4058 (build_poly_scop): Use scop_set_nb_params.
4059 * sese.h (gimple_bb): Add LOOPS.
4060 (GBB_LOOPS, gbb_loop_index, gbb_loop_at_index): New.
4062 2009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
4064 Revert previous commit.
4066 2009-03-11 Sebastian Pop <sebastian.pop@amd.com>
4068 * sese.c (expand_scalar_variables_expr): Handle tcc_comparison.
4069 (register_old_and_new_names): Update the content of the map.
4070 When there was already a rename_map_elt in the map at that
4072 (copy_bb_and_scalar_dependences): Do rename_variables after
4073 expand_scalar_variables.
4074 * graphite-clast-to-gimple.c (build_iv_mapping): Update the content
4075 of the map. When there was already a rename_map_elt in the
4076 map at that location, free it.
4077 (translate_clast): Pass the rename_map. Do not initialize and free
4078 a rename_map per stmt_user.
4079 (gloog): Initialize and free one rename_map and pass it to
4082 2009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
4084 Remove forgotten line in revert.
4086 2009-03-11 Sebastian Pop <sebastian.pop@amd.com>
4088 Revert previous commit.
4090 2009-03-10 Sebastian Pop <sebastian.pop@amd.com>
4092 * sese.c (register_old_and_new_names): Update the content
4093 of the map. When there was already a rename_map_elt in the
4094 map at that location, free it.
4095 (copy_bb_and_scalar_dependences): Do rename_variables after
4096 expand_scalar_variables.
4097 * graphite-clast-to-gimple.c (build_iv_mapping): Update the content
4098 of the map. When there was already a rename_map_elt in the
4099 map at that location, free it.
4100 (translate_clast): Pass the rename_map. Do not initialize and free
4101 a rename_map per stmt_user.
4102 (gloog): Initialize and free one rename_map and pass it to
4105 2009-03-10 Sebastian Pop <sebastian.pop@amd.com>
4107 * graphite-clast-to-gimple.c (translate_clast): context_loop
4110 2009-03-10 Tobias Grosser <grosser@fim.uni-passau.de>
4111 Sebastian Pop <sebastian.pop@amd.com>
4113 * graphite-ppl.c (ppl_insert_dimensions): Fix stupid mistake
4114 of the use of ppl_Polyhedron_map_space_dimensions.
4116 2009-03-10 Tobias Grosser <grosser@fim.uni-passau.de>
4117 Sebastian Pop <sebastian.pop@amd.com>
4119 * graphite-poly.c (unify_scattering_dimensions): Fix types.
4120 * graphite-poly.h (poly_dr_p, poly_dr, POLY_DR_TYPE, PDR_BB,
4121 PDR_TYPE, PDR_ACCESSES, pdr_accessp_nb_subscripts,
4122 pdr_accessp_nb_iterators, pdr_accessp_nb_params,
4123 pdr_accessp_alias_set_dim, pdr_accessp_subscript_dim,
4124 pdr_accessp_iterator_dim, pdr_accessp_param_dim,
4125 pbb_nb_params): New.
4126 (pbb_nb_loops, pbb_nb_scattering, scop_nb_params,
4127 nb_loops_around_pbb): Adapt return types.
4129 2009-03-09 Tobias Grosser <grosser@fim.uni-passau.de>
4131 * Makefile.in (graphite.o, graphite-sese-to-poly.o,
4132 graphite-clast-to-gimple.o, graphite-data-ref.o,
4133 graphite-scop-detection.o, graphite-poly.o): Add
4136 2009-03-05 Tobias Grosser <grosser@fim.uni-passau.de>
4138 * Makefile.in (graphite.o, graphite-sese-to-poly.o,
4139 graphite-clast-to-gimple.o, graphite-data-ref.o,
4140 graphite-scop-detection.o, graphite-poly.o): Add graphite-poly.h.
4142 2009-03-04 Tobias Grosser <grosser@fim.uni-passau.de>
4144 * gcc.dg/graphite/pr37485.c: Remove -floop-block
4145 * gcc.dg/graphite/pr37828.c: Same.
4146 * gcc.dg/graphite/pr37684.c: Same.
4147 * gcc.dg/graphite/block-0.c: Same.
4148 * gcc.dg/graphite/block-1.c: Same.
4149 * gcc.dg/graphite/block-2.c: Same.
4150 * gcc.dg/graphite/block-3.c: Same.
4151 * gcc.dg/graphite/block-4.c: Same.
4152 * gcc.dg/graphite/block-5.c: Same.
4153 * gcc.dg/graphite/block-6.c: Same.
4154 * gfortran.dg/graphite/pr38083.f90: Same.
4155 * gfortran.dg/graphite/block-1.f90: Same.
4156 * gfortran.dg/graphite/block-3.f90: Same.
4157 * gfortran.dg/graphite/pr37852.f90: Same.
4158 * gfortran.dg/graphite/block-4.f90: Same.
4159 * gfortran.dg/graphite/pr37980.f90: Same.
4160 * gfortran.dg/graphite/pr38953.f90: Same.
4161 * gfortran.dg/graphite/pr37857.f90: Same.
4162 * opts.c: Remove -floop-block from -O2.
4163 * graphite-poly.c: Fail if -floop-block -floop-interchange or
4164 -floop-strip-mine are used.
4166 2009-03-04 Tobias Grosser <grosser@fim.uni-passau.de>
4167 Sebastian Pop <sebastian.pop@amd.com>
4169 * graphite-clast-to-gimple.c (build_cloog_prog): Unify scattering
4171 * graphite-poly.c (pbb_compare, graphite_sort_pbbs,
4172 graphite_trans_bb_move_loop, graphite_trans_bb_strip_mine,
4173 strip_mine_profitable_p, is_interchange_valid,
4174 graphite_trans_bb_block, graphite_trans_loop_block,
4175 graphite_trans_scop_block): Temporary removed.
4176 (extend_scattering, unify_scattering_dimensions): New.
4177 (print_scattering_function, graphite_read_transforms):
4178 PBB_SCATTERING -> PBB_TRANSFORMED_SCATTERING.
4179 (graphite_generate_scattering_fns): Removed.
4180 (apply_poly_transforms): Cleanup.
4181 (free_poly_bb): Add PBB_SCATTERING -> PBB_TRANSFORMED_SCATTERING.
4182 (schedule_to_scattering): Moved.
4183 (PBB_STATIC_SCHEDULE, PBB_SCATTERING): Removed.
4184 (PBB_ORIGINAL_SCATTERING, PBB_TRANSFORMED_SCATTERING): New.
4185 (pbb_nb_scattering): New.
4186 (SCOP_ENTRY, SCOP_EXIT, SCOP_REGION_BBS, SCOP_DEP_GRAPH, SCOP_PARAMS,
4187 SCOP_LOOP_NEST, SCOP_PARAMS, SCOP_OLDIVS, SCOP_LIVEOUT_RENAMES):
4189 * graphite-ppl.c (ppl_insert_dimensions): Extended and renamed from
4191 (ppl_strip_loop): PBB_SCATTERING -> PBB_TRANSFORMED_SCATTERING.
4192 * graphite-scop-detection.c (dot_all_scops_1): PBB_SCATTERING
4193 -> PBB_TRANSFORMED_SCATTERING.
4194 * graphite-sese-to-poly.c (build_scop_bbs): Remove region.
4195 (build_pbb_scattering_polyhedron): Moved from schedule_to_scattering.
4196 (build_scop_scattering): Renamed from build_scop_canonical_schedules.
4197 (check_poly_representation): Do not return bool.
4198 (graphite_transform_loops): Reformat.
4199 * sese.h (SESE_ENTRY_BB, SESE_EXIT_BB): New.
4201 2009-03-04 Sebastian Pop <sebastian.pop@amd.com>
4203 * graphite-poly.c (print_pbb_domain, print_pbb, print_scop,
4204 debug_pbb_domain, debug_pbb, debug_scop): New.
4205 * graphite-poly.h (print_pbb_domain, print_pbb, print_scop,
4206 debug_pbb_domain, debug_pbb, debug_scop): Declared.
4208 2009-03-02 Sebastian Pop <sebastian.pop@amd.com>
4211 * tree-parloops.c (canonicalize_loop_ivs): Call fold_convert
4212 when the type precision of the induction variable should be
4213 larger than the type precision of nit.
4214 (gen_parallel_loop): Update use of canonicalize_loop_ivs.
4215 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Same.
4216 * tree-flow.h (canonicalize_loop_ivs): Update declaration.
4218 * gcc.dg/graphite/pr39335_1.c: New.
4219 * gcc.dg/graphite/pr39335.c: New.
4221 2009-03-02 Sebastian Pop <sebastian.pop@amd.com>
4223 * tree-parloops.c (canonicalize_loop_ivs): reduction_list contains
4224 SSA_NAMES not struct reduction_info.
4226 2009-03-02 Sebastian Pop <sebastian.pop@amd.com>
4228 * sese.c (expand_scalar_variables_expr): Handle ADDR_EXPR.
4230 2009-02-27 Sebastian Pop <sebastian.pop@amd.com>
4231 Tobias Grosser <grosser@fim.uni-passau.de>
4233 * sese.c (new_sese): Initialize SESE_REDUCTION_LIST.
4234 (free_sese): Free SESE_REDUCTION_LIST.
4235 * sese.h (struct sese): Add field reduction_list.
4236 (SESE_REDUCTION_LIST): New.
4237 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Call
4238 canonicalize_loop_ivs on SESE_REDUCTION_LIST.
4240 2009-02-27 Sebastian Pop <sebastian.pop@amd.com>
4241 Tobias Grosser <grosser@fim.uni-passau.de>
4243 * tree-flow.h (gather_scalar_reductions): Use struct loop * instead
4246 2009-02-27 Sebastian Pop <sebastian.pop@amd.com>
4247 Tobias Grosser <grosser@fim.uni-passau.de>
4249 * tree-parloops.c (struct brli, build_reduction_list_info,
4250 analyze_reduction_list, gather_scalar_reductions): New.
4251 (loop_parallel_p): Build a reduction list containing only
4252 PHI_RESULT SSA_NAMEs: call gather_scalar_reductions.
4253 (gen_parallel_loop): Call the analysis analyze_reduction_list.
4254 (parallelize_loops): Now reduction_list is a htab_t of SSA_NAMEs.
4255 * tree-flow.h (gather_scalar_reductions): Declared.
4257 2009-02-26 Sebastian Pop <sebastian.pop@amd.com>
4260 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not call
4261 number_of_iterations_exit from a gcc_assert.
4263 2009-02-25 Sebastian Pop <sebastian.pop@amd.com>
4264 Jan Sjodin <jan.sjodin@amd.com>
4266 * output.h (graphite_out_file, graphite_in_file): Declared.
4267 * toplev.c (graphite_out_file, graphite_in_file): New.
4268 (init_asm_output): Initialize graphite_in_file and graphite_out_file.
4269 * graphite-clast-to-gimple.c (build_cloog_prog): Read PBB_SCATTERING.
4270 Don't call schedule_to_scattering.
4271 * common.opt (fgraphite-write, fgraphite-read): New.
4272 * graphite-poly.c: Include output.h.
4273 (print_scattering_function, print_scattering_functions,
4274 debug_scattering_function, debug_scattering_functions,
4275 graphite_write_transforms, graphite_read_transforms,
4276 graphite_generate_scattering_fns): New.
4277 (apply_poly_transforms): Do not apply transform if flag_graphite_read.
4278 Call graphite_generate_scattering_fns, graphite_write_transforms,
4279 graphite_read_transforms.
4280 (new_poly_bb): Initialize PBB_SCATTERING.
4281 (free_poly_bb): Free PBB_SCATTERING.
4282 (schedule_to_scattering): Does not return, initialize PBB_SCATTERING.
4283 * graphite-poly.h (struct poly_bb): Add field scattering.
4284 (PBB_SCATTERING): New.
4285 (print_scattering_function, print_scattering_functions,
4286 debug_scattering_function, debug_scattering_functions): Declared.
4287 * graphite-ppl.c (cloog_matrix_to_ppl_constraint): Matrices contain
4288 GMP values, not integers!
4289 (ppl_print_polyhedron_matrix, debug_ppl_polyhedron_matrix,
4290 ppl_read_polyhedron_matrix): New.
4291 * graphite-ppl.h (ppl_print_polyhedron_matrix,
4292 debug_ppl_polyhedron_matrix,
4293 ppl_read_polyhedron_matrix): Declared.
4294 * Makefile.in (graphite-poly.o): Depends on output.h.
4296 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
4297 Tobias Grosser <grosser@fim.uni-passau.de>
4300 * graphite-scop-detection.c (stmt_simple_for_scop_p): Analyze
4301 scalar evolutions in the scop_entry->loop_father.
4303 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
4304 Tobias Grosser <grosser@fim.uni-passau.de>
4306 * graphite.h (ref_nb_loops): Remove declaration.
4307 (struct gimple_bb, gimple_bb_p, GBB_BB, GBB_DATA_REFS, GBB_CONDITIONS,
4308 GBB_CONDITION_CASES, GBB_CLOOG_IV_TYPES, gbb_loop, print_gimple_bb,
4309 debug_gbb): Moved to sese.h.
4312 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
4313 Tobias Grosser <grosser@fim.uni-passau.de>
4315 * graphite-data-ref.[ch]: Disable.
4317 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
4318 Tobias Grosser <grosser@fim.uni-passau.de>
4320 * graphite-scop-detection.c (stmt_simple_for_scop_p): Analyze
4321 scalar evolutions in the scop_entry->loop_father.
4323 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
4325 * graphite-scop-detection.c (nb_reductions_in_loop): Moved here...
4326 (graphite_cannot_represent_loop_niter): Renamed
4327 graphite_cannot_represent_loop. Call nb_reductions_in_loop.
4328 (limit_scops): build_sese_loop_nests does not return a bool.
4329 * graphite-scop-detection.h (nb_reductions_in_loop): Declared.
4330 * sese.c (nb_reductions_in_loop): ... from here.
4331 (graphite_loop_normal_form): ... from here.
4332 (sese_record_loop): Does not fail, so does not return a bool.
4333 (build_sese_loop_nests): Same.
4334 * sese.h (build_sese_loop_nests): Update declaration.
4335 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Moved here...
4336 (build_graphite_loop_normal_form): New.
4337 (gloog): Call build_graphite_loop_normal_form.
4338 * graphite-sese-to-poly.c (build_poly_scop): Don't fail on
4339 build_sese_loop_nests.
4341 * gcc.dg/graphite/id-1.c: New.
4343 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
4344 Tobias Grosser <grosser@fim.uni-passau.de>
4346 * graphite-sese-to-poly.c (scan_tree_for_params): Remove REAL_CST.
4347 The SCoP detection fix is sufficient.
4349 2009-02-21 Sebastian Pop <sebastian.pop@amd.com>
4351 PR tree-optimization/39260
4352 * graphite-scop-detection.c (harmful_stmt_in_bb): Stop a SCoP when
4353 the basic block contains a condition with a real type.
4354 * graphite-sese-to-poly.c (scan_tree_for_params): Handle REAL_CST.
4356 * gcc.dg/graphite/pr39260.c: New.
4358 2009-02-21 Sebastian Pop <sebastian.pop@amd.com>
4360 * graphite-poly.c: Inlcude params.h.
4361 (graphite_trans_loop_block): Use PARAM_LOOP_BLOCK_TILE_SIZE for
4363 * Makefile.in (graphite-poly.o): Depend on PARAMS_H.
4364 * params.def (PARAM_LOOP_BLOCK_TILE_SIZE): Define.
4366 2009-02-20 Sebastian Pop <sebastian.pop@amd.com>
4367 Tobias Grosser <grosser@fim.uni-passau.de>
4369 * graphite-scop-detection.c (dot_all_scops_1,
4370 dot_all_scops): Moved here.
4371 * graphite-scop-detection.h (dot_all_scops): Declared here.
4372 * graphite.c (graphite_initialize, graphite_finalize): New.
4373 (graphite_transform_loops): Cleaned up.
4374 * sese.c (debug_oldivs): Moved here.
4375 * graphite-poly.c (graphite_apply_transformations): Renamed
4376 apply_poly_transforms.
4377 (debug_loop_vec): Moved here.
4378 * graphite-sese-to-poly.c (build_bb_loops, build_sese_conditions_1,
4379 scop_contains_non_iv_scalar_phi_nodes, build_sese_conditions,
4380 find_scop_parameters, build_scop_iteration_domain,
4381 add_conditions_to_constraints, build_scop_canonical_schedules,
4382 build_scop_data_accesses): Now static.
4383 (build_poly_scop, check_poly_representation): New.
4385 2009-02-20 Sebastian Pop <sebastian.pop@amd.com>
4387 * graphite.c (graphite_stmt_p, new_gimple_bb, free_gimple_bb,
4388 remove_gbbs_in_scop, free_scops, try_generate_gimple_bb,
4389 build_scop_bbs, ref_nb_loops, compare_prefix_loops,
4390 build_scop_canonical_schedules, build_bb_loops, add_value_to_dim,
4391 scan_tree_for_params_right_scev, scan_tree_for_params_int,
4392 scan_tree_for_params, struct irp_data, dx_record_params,
4393 find_params_in_bb, find_scop_parameters, gbb_from_bb,
4394 build_loop_iteration_domains, add_conditions_to_domain,
4395 phi_node_is_iv, bb_contains_non_iv_scalar_phi_nodes,
4396 scop_contains_non_iv_scalar_phi_nodes, build_sese_conditions_1,
4397 build_sese_conditions, add_conditions_to_constraints,
4398 build_scop_iteration_domain, build_access_matrix_with_af,
4399 build_access_matrix,
4400 build_scop_data_accesses): Moved to graphite-sese-to-poly.c.
4402 * graphite-sese-to-poly.c: New.
4403 * graphite-sese-to-poly.h: New.
4405 * Makefile.in: Add new rule for graphite-sese-to-poly.o.
4407 2009-02-20 Sebastian Pop <sebastian.pop@amd.com>
4409 * graphite.c: Split graphite code generation to a new file.
4410 (graphite_verify, gmp_cst_to_tree, clast_name_to_gcc,
4411 max_precision_type, clast_to_gcc_expression_red,
4412 clast_to_gcc_expression, gcc_type_for_clast_expr,
4413 gcc_type_for_clast_eq, loop_iv_stack_patch_for_consts,
4414 graphite_translate_clast_equation, graphite_create_guard_cond_expr,
4415 graphite_create_new_guard, clast_get_body_of_loop,
4416 gcc_type_for_cloog_iv, gcc_type_for_iv_of_clast_loop,
4417 graphite_create_new_loop, build_iv_mapping, copy_renames,
4418 translate_clast, find_cloog_iv_in_expr, compute_cloog_iv_types_1,
4419 compute_cloog_iv_types, free_scattering, save_var_name,
4420 initialize_cloog_names, build_scop_context, build_cloog_prog,
4421 set_cloog_options, debug_clast_stmt, scop_to_clast,
4422 print_generated_program, debug_generated_program,
4423 gloog): Moved to graphite-clast-to-gimple.c.
4425 (struct cloog_prog_clast): Moved to graphite-clast-to-gimple.h.
4427 (iv_stack_entry_is_constant, iv_stack_entry_is_iv,
4428 loop_iv_stack_push_iv, loop_iv_stack_insert_constant,
4429 loop_iv_stack_pop, loop_iv_stack_get_iv,
4430 loop_iv_stack_get_iv_from_name, debug_loop_iv_stack,
4431 free_loop_iv_stack, loop_iv_stack_remove_constants,
4432 debug_rename_elt, debug_rename_map_1, debug_rename_map,
4433 rename_map_elt_info, eq_rename_map_elts, debug_ivtype_elt,
4434 debug_ivtype_map_1, debug_ivtype_map, ivtype_map_elt_info,
4435 eq_ivtype_map_elts, sese_add_exit_phis_edge,
4436 sese_add_exit_phis_var, sese_insert_phis_for_liveouts,
4437 get_vdef_before_sese, sese_adjust_vphi,
4438 get_new_name_from_old_name, sese_adjust_phis_for_liveouts,
4439 oldiv_for_loop, rename_variables_in_stmt, is_parameter,
4440 is_iv, expand_scalar_variables_ssa_name,
4441 expand_scalar_variables_expr, expand_scalar_variables_stmt,
4442 expand_scalar_variables, rename_variables, remove_condition,
4443 get_true_edge_from_guard_bb, get_false_edge_from_guard_bb,
4444 add_loop_exit_phis, insert_loop_close_phis, struct igp,
4445 default_liveout_before_guard, add_guard_exit_phis,
4446 insert_guard_phis, register_old_and_new_names,
4447 graphite_copy_stmts_from_block, register_sese_liveout_renames,
4448 copy_bb_and_scalar_dependences, outermost_loop_in_sese,
4449 if_region_set_false_region, create_if_region_on_edge,
4450 move_sese_in_condition): Moved to sese.c.
4452 (nb_loops_around_loop_in_sese, struct ifsese, if_region_entry,
4453 if_region_exit, if_region_get_condition_block,
4454 struct rename_map_elt, new_rename_map_elt, enum iv_stack_entry_kind,
4455 union iv_stack_entry_data_union, struct iv_stack_entry_struct,
4456 iv_stack_entry_p, loop_iv_stack, struct ivtype_map_elt,
4457 ivtype_map_elt, new_ivtype_map_elt,
4458 recompute_all_dominators): Moved to sese.h.
4460 * graphite-clast-to-gimple.c: New.
4461 * graphite-clast-to-gimple.h: New.
4462 * Makefile.in: Add new rule for graphite-clast-to-gimple.o.
4463 * sese.c: Modified as said above.
4466 2009-02-20 Sebastian Pop <sebastian.pop@amd.com>
4468 * graphite.c: Split scop detection to a new file.
4469 (enum gbb_type, gbb_type, get_bb_type, struct sd_region_p, sd_region,
4470 move_sd_regions, loop_affine_expr, exclude_component_ref,
4471 is_simple_operand, stmt_simple_for_scop_p, harmful_stmt_in_bb,
4472 graphite_cannot_represent_loop_niter, struct scopdet_info,
4473 scopdet_basic_block_info, build_scops_1, bb_in_sd_region,
4474 find_single_entry_edge, find_single_exit_edge,
4475 create_single_entry_edge, sd_region_without_exit,
4476 create_single_exit_edge, unmark_exit_edges, mark_exit_edges,
4477 create_sese_edges, build_graphite_scops, limit_scops, build_scops):
4478 Moved to graphite-scop-detection.c.
4480 * graphite-scop-detection.c: New.
4481 * graphite-scop-detection.h: New.
4482 * Makefile.in: Add new rule for graphite-scop-detection.o.
4484 * sese.c: Include tree-chrec.h, tree-data-ref.h, and
4485 tree-scalar-evolution.h.
4486 (nb_reductions_in_loop, graphite_loop_normal_form, sese_record_loop,
4487 build_sese_loop_nests): Moved here from graphite.c.
4488 (param_index): Renamed parameter_index_in_region.
4490 2009-02-18 Tobias Grosser <grosser@fim.uni-passau.de>
4491 Sebastian Pop <sebastian.pop@amd.com>
4493 * gcc.dg/graphite/block-0.c: Expected to fail now.
4494 * gcc.dg/graphite/block-1.c: Same.
4495 * gcc.dg/graphite/block-5.c: Same.
4496 * gcc.dg/graphite/block-6.c: Same.
4498 2009-02-18 Tobias Grosser <grosser@fim.uni-passau.de>
4499 Sebastian Pop <sebastian.pop@amd.com>
4501 * graphite.h: Separate from graphite_bb_p the polyhedral
4502 representation in poly_bb_p and the GCC specifics in gimple_bb_p.
4503 (struct data_dependence_polyhedron, RDGE_DDP, ddp_p): Moved to
4504 graphite-data-ref.h.
4505 (struct poly_bb, PBB_SCOP, PBB_STATIC_SCHEDULE, PBB_DOMAIN,
4506 PBB_BLACK_BOX, PBB_LOOPS, pbb_nb_loops, pbb_loop_at_index,
4507 pbb_loop_index, struct scop, SCOP_BBS, SCOP_REGION, SCOP_ENTRY,
4508 SCOP_EXIT, SCOP_REGION_BBS, SCOP_DEP_GRAPH, SCOP_PARAMS,
4509 SCOP_LOOP_NEST, SCOP_PARAMS, SCOP_OLDIVS, SCOP_LIVEOUT_RENAMES,
4510 scop_nb_params): Moved to graphite-poly.h.
4511 * graphite-data-ref.c: Same.
4512 * graphite-data-ref.h: New.
4514 (pbb_compare, graphite_sort_pbbs, graphite_trans_bb_move_loop,
4515 graphite_trans_bb_strip_mine, strip_mine_profitable_p,
4516 is_interchange_valid, graphite_trans_bb_block,
4517 graphite_trans_loop_block, scop_max_loop_depth,
4518 graphite_trans_scop_block, graphite_apply_transformations,
4519 new_poly_bb, free_poly_bb, new_scop, free_scop): Moved to
4521 * graphite-poly.h: New.
4522 * graphite-poly.c: New.
4523 * Makefile.in (OBJS-common): Add graphite-poly.o.
4524 (graphite-poly.o): New rule.
4525 * tree-data-ref.h (struct data_reference): Remove unused scop field.
4528 2009-02-18 Sebastian Pop <sebastian.pop@amd.com>
4529 Tobias Grosser <grosser@fim.uni-passau.de>
4531 * graphite.c: Replace gb -> gbb.
4533 * graphite-data-ref.c: Same.
4535 2009-02-18 Sebastian Pop <sebastian.pop@amd.com>
4536 Tobias Grosser <grosser@fim.uni-passau.de>
4538 * Makefile.in (OBJS-commmon): Add sese.o.
4540 (graphite.o): Add sese.h.
4541 * graphite.c (bb_in_ss_p, loop_in_sese_p,
4542 sese_build_livein_liveouts_use, sese_build_livein_liveouts_bb,
4543 sese_build_livein_liveouts, register_bb_in_sese, new_sese, free_sese):
4545 (block_before_scop): Add missing return.
4546 (new_scop, free_scop): Remove SESE data structures.
4547 (scop_record_loop, scan_tree_for_params, find_params_in_bb,
4548 find_scop_parameters, build_loop_iteration_domains,
4549 add_conditions_to_domain, register_scop_liveout_renames,
4550 copy_bb_and_scalar_dependences): Scop -> SESE.
4552 (add_conditions_to_domain): SCoP -> SESE and remove check
4553 (scop_contains_non_iv_scalar_phi_nodes): New.
4554 (build_scop_conditions_1, build_scop_conditions): Remove check for
4555 non iv scalar phi nodes.
4556 (print_scop_statistics): New.
4557 (graphite_transform_loops): Cleanup.
4559 * graphite.h: Move to sese & cleanup.
4563 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
4564 Tobias Grosser <grosser@fim.uni-passau.de>
4566 * graphite.c (build_scop_conditions_1): Conditions are only
4567 at the end of a basic block.
4569 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
4570 Tobias Grosser <grosser@fim.uni-passau>
4572 * graphite.h (struct graphite_bb): Remove compressed_alpha_matrix
4574 (GBB_ALPHA): Removed.
4576 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
4577 Tobias Grosser <grosser@fim.uni-passau.de>
4579 * graphite-data-ref.c (graphite_test_dependence): Don't use
4580 GBB_DYNAMIC_SCHEDULE.
4581 * graphite.c (new_graphite_bb): Same.
4582 (free_graphite_bb): Same.
4583 (build_scop_dynamic_schedules): Removed.
4584 (graphite_transform_loops): Don't call it.
4585 * graphite.h (struct graphite_bb): Remove dynamic_schedule field.
4586 (GBB_DYNAMIC_SCHEDULE): Removed.
4588 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
4589 Tobias Grosser <grosser@fim.uni-passau.de>
4591 * graphite.c (schedule_to_scattering): Don't use CloogMatrix.
4592 (print_graphite_bb): Same.
4593 (build_cloog_prog): Same.
4595 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
4596 Tobias Grosser <grosser@fim.uni-passau.de>
4598 * graphite.c (build_cloog_prog): Don't use CloogMatrix.
4600 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
4601 Tobias Grosser <grosser@fim.uni-passau.de>
4603 * graphite.c (build_scop_context): Don't use CloogMatrix.
4604 * graphite-ppl.c (new_Cloog_Domain_from_ppl_Polyhedron): New.
4605 * graphite-ppl.h (new_Cloog_Domain_from_ppl_Polyhedron): Declared.
4607 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
4608 Tobias Grosser <grosser@fim.uni-passau.de>
4610 * graphite.h (struct scop): Move params, old_ivs, loops, loop_nest,
4611 liveout_renames, add_params fields...
4612 (struct sese): ... here.
4613 (SESE_PARAMS, SESE_LOOPS, SESE_LOOP_NEST, SESE_ADD_PARAMS,
4614 SESE_PARAMS, SESE_OLDIVS, SESE_LIVEOUT_RENAMES): New.
4616 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
4617 Tobias Grosser <grosser@fim.uni-passau.de>
4619 * graphite.c (print_scop): Do not print the CLooG program.
4620 (new_scop, free_scop, initialize_cloog_names, build_scop_context,
4621 build_cloog_prog, gloog): Don't use SCOP_PROG.
4622 (find_transform): Renamed scop_to_clast.
4623 (print_generated_program, debug_generated_program): New.
4624 (graphite_transform_loops): Adapt to new interface.
4625 * graphite.h (struct scop): Remove program field.
4626 (SCOP_PROG): Removed.
4627 (print_generated_program, debug_generated_program): Declared.
4629 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
4631 * graphite-data-ref.c (schedule_precedes_p, schedule_same_p): New.
4632 (statement_precedes_p): Use schedule_same_p and schedule_precedes_p.
4633 * graphite.c (gbb_compare, schedule_to_scattering, print_graphite_bb,
4634 free_graphite_bb, build_scop_canonical_schedules,
4635 graphite_trans_bb_strip_mine, graphite_trans_scop_block): Static
4636 schedules are now represented using a ppl_Linear_Expression_t.
4637 * graphite.h (struct graphite_bb): Same.
4638 * graphite-ppl.c (ppl_lexico_compare_linear_expressions): New.
4639 * graphite-ppl.h (ppl_lexico_compare_linear_expressions): Declared.
4641 2009-02-15 Sebastian Pop <sebastian.pop@amd.com>
4643 * graphite.c: Free local memory.
4644 * graphite-ppl.c: Same.
4646 2009-02-15 Sebastian Pop <sebastian.pop@amd.com>
4648 * graphite.c (const_column_index, get_first_matching_sign_row_index,
4649 get_lower_bound_row, get_upper_bound_row, copy_constraint,
4650 swap_constraint_variables, scale_constraint_variable): Removed.
4651 (graphite_trans_bb_strip_mine): Remove pong.
4652 * graphite-ppl.c: Include missing header files.
4653 (set_inhomogeneous, set_coef, shift_poly, ppl_strip_loop): New.
4654 * graphite-ppl.h (ppl_strip_loop): Declared.
4655 * Makefile.in (graphite-ppl.o): Adjust dependences.
4657 2009-02-14 Sebastian Pop <sebastian.pop@amd.com>
4659 * graphite.c (build_loop_iteration_domains): Remove ping pong.
4660 (build_scop_iteration_domain): Same.
4662 2009-02-13 Sebastian Pop <sebastian.pop@amd.com>
4664 * graphite.c (scan_tree_for_params, add_conditions_to_domain): Remove
4666 (add_value_to_dim, scan_tree_for_params_right_scev,
4667 scan_tree_for_params_int): New.
4668 * graphite-ppl.c (oppose_constraint): New.
4669 (insert_constraint_into_matrix): Implement missing cases.
4670 * graphite-ppl.h (insert_constraint_into_matrix): Declared.
4672 2009-02-13 Sebastian Pop <sebastian.pop@amd.com>
4674 * graphite.c (graphite_trans_bb_move_loop): Remove ping pong,
4675 use ppl_move_dimension.
4677 2009-02-12 Sebastian Pop <sebastian.pop@amd.com>
4679 * graphite-data-ref.c: Domains are now ppl_Polyhedra_t.
4682 * graphite-ppl.c: Same.
4683 * graphite-ppl.h: Same.
4685 2009-02-12 Sebastian Pop <sebastian.pop@amd.com>
4687 Revert last 3 commits.
4689 2009-02-10 Sebastian Pop <sebastian.pop@amd.com>
4691 * graphite.c (scan_tree_for_params, add_conditions_to_domain): Remove
4693 (add_value_to_dim, scan_tree_for_params_right_scev,
4694 scan_tree_for_params_int): New.
4695 * graphite-ppl.c (oppose_constraint): New.
4696 (insert_constraint_into_matrix): Implement missing cases.
4697 * graphite-ppl.h (insert_constraint_into_matrix): Declared.
4699 2009-02-10 Sebastian Pop <sebastian.pop@amd.com>
4701 * graphite.c (graphite_trans_bb_move_loop): Remove unused variables.
4703 2009-02-10 Sebastian Pop <sebastian.pop@amd.com>
4704 Tobias Grosser <grosser@fim.uni-passau.de>
4706 * graphite.c (graphite_trans_bb_move_loop): Remove ping pong,
4707 use ppl_move_dimension.
4708 * graphite-ppl.c (ppl_move_dimension): New.
4709 * graphite-ppl.h (ppl_move_dimension): Declared.
4711 2009-02-10 Sebastian Pop <sebastian.pop@amd.com>
4713 * graphite.c: Do not include cloog/cloog.h.
4714 (print_graphite_bb): Remove ping pong, call PPL print function.
4716 2009-02-10 Tobias Grosser <grosser@fim.uni-passau.de>
4718 * Makefile.in (OBJS-common): Add graphite-ppl.o.
4719 (graphite.o): Add dependence on graphite-ppl.h.
4720 (graphite-ppl.o): New.
4721 (graphite-data-ref.c): Ping pong between PPL data structures
4723 * graphite-ppl.c: New.
4724 * graphite-ppl.h: New.
4725 * graphite.c: Include graphite-ppl.h.
4726 (print_graphite_bb, add_conditions_to_domain, build_cloog_prog,
4727 graphite_trans_bb_move_loop, graphite_trans_bb_strip_mine):
4728 Ping pong between PPL data structures and matrices.
4729 (new_graphite_bb): Create a PPL constraint system.
4730 Call ppl_delete_Constraint_System instead of cloog_matrix_free.
4731 (build_loop_iteration_domains): Use PPL functions.
4732 * graphite.h: Include graphite-ppl.h. Fix comments.
4733 (graphite_bb): Use a ppl_Constraint_System_t instead of
4734 CloogMatrix for representing the domain.
4735 (scop): Remove static_schedule.
4736 (gbb_nb_loops): Ping pong between PPL data structures and matrices.
4738 2009-02-06 Sebastian Pop <sebastian.pop@amd.com>
4740 * graphite.c: Fix some comments.
4742 2009-02-05 Sebastian Pop <sebastian.pop@amd.com>
4745 * graphite.c (if_region_set_false_region): After moving a region
4746 in the false branch of a condition, remove the empty dummy
4748 (gloog): Remove wrong fix for PR38953.
4750 2009-02-03 Tobias Grosser <grosser@fim.uni-passau.de>
4752 * graphite.c (bb_in_sese_p, sese_build_livein_liveouts_use,
4753 sese_build_livein_liveouts_bb, sese_build_livein_liveouts,
4754 register_bb_in_sese, new_sese, free_sese): Moved.
4755 (dot_scop_1, build_scop_loop_nests, build_loop_iteration_domains,
4756 outermost_loop_in_scop, build_scop_iteration_domain,
4757 expand_scalar_variables_ssa_name, get_vdef_before_scop,
4758 limit_scops): Use bb_in_sese_p instead of bb_in_scop_p.
4759 Use loop_in_sese_p instead of loop_in_scop_p.
4760 (new_graphite_bb, new_scop, gloog): Do not initialize SCOP_BBS_B.
4761 (free_scop): Do not free SCOP_BBS_B.
4762 (nb_loops_around_loop_in_scop, nb_loops_around_gb,
4763 ref_nb_loops): Moved here...
4764 * graphite.h (ref_nb_loops): ... from here.
4765 (struct scop): Remove bbs_b bitmap.
4766 (SCOP_BBS_B, bb_in_scop_p, loop_in_scop_p): Removed.
4767 * gcc.dg/graphite/scop-19.c: New
4769 2009-02-03 Tobias Grosser <grosser@fim.uni-passau.de>
4771 * graphite.c (scopdet_basic_block_info): Fix bug in scop
4774 2009-01-30 Tobias Grosser <grosser@fim.uni-passau.de>
4776 * graphite.c (new_loop_to_cloog_loop_str, hash_loop_to_cloog_loop,
4777 eq_loop_to_cloog_loop): Remove.
4778 (new_scop, free_scop): Remove SCOP_LOOP2CLOOG_LOOP.
4779 * graphite.h (struct scop): Remove loop2cloog_loop.
4780 (loop_domain_dim, loop_iteration_vector_dim): Remove.
4782 2009-01-30 Tobias Grosser <grosser@fim.uni-passau.de>
4784 * opts.c (decode_options): Only add graphite options to O2
4785 if we compile with graphite enabled.
4787 2009-01-26 Sebastian Pop <sebastian.pop@amd.com>
4789 * Merge from mainline (r143163:143684).
4791 2009-01-26 Sebastian Pop <sebastian.pop@amd.com>
4793 * graphite.c (debug_value): Removed.
4794 * graphite.h (debug_value): Removed.
4796 2009-01-23 Sebastian Pop <sebastian.pop@amd.com>
4798 * passes.c (init_optimization_passes): Do not call pass_copy_prop
4799 after graphite: pass_copy_prop does not maintain a proper loop closed
4800 SSA form. pass_copy_prop should be fixed.
4802 2009-01-23 Sebastian Pop <sebastian.pop@amd.com>
4804 * graphite.c (scop_adjust_phis_for_liveouts): Fix warning.
4806 2009-01-23 Sebastian Pop <sebastian.pop@amd.com>
4808 * graphite.c (graphite_verify): Add a call to verify_loop_closed_ssa.
4809 (gloog): Split the exit of the scop when the scop exit is a loop exit.
4810 (graphite_transform_loops): Only call cleanup_tree_cfg if gloog
4813 2009-01-20 Sebastian Pop <sebastian.pop@amd.com>
4815 * graphite.c (gloog): Return true when code gen succeeded.
4816 (graphite_transform_loops): Do not call cleanup_tree_cfg if
4817 the code of the function did not changed. After cleanup_tree_cfg
4818 call rewrite_into_loop_closed_ssa to maintain the loop closed ssa
4821 2009-01-19 Sebastian Pop <sebastian.pop@amd.com>
4823 * graphite.c (stmt_simple_for_scop_p): Also handle cases when
4824 gimple_call_lhs is NULL.
4826 2009-01-16 Sebastian Pop <sebastian.pop@amd.com>
4827 Tobias Grosser <tobi.grosser@amd.com>
4829 * graphite.c (graphite_trans_scop_block): Do not block single
4832 2009-01-15 Sebastian Pop <sebastian.pop@amd.com>
4833 Tobias Grosser <tobi.grosser@amd.com>
4835 * graphite.c (build_scop_canonical_schedules): Start schedules at
4838 2009-01-15 Sebastian Pop <sebastian.pop@amd.com>
4839 Tobias Grosser <tobi.grosser@amd.com>
4841 * graphite.c (compare_prefix_loops): New.
4842 (build_scop_canonical_schedules): Rewritten.
4843 (graphite_transform_loops): Move build_scop_canonical_schedules
4844 after build_scop_iteration_domain.
4846 2009-01-14 Sebastian Pop <sebastian.pop@amd.com>
4847 Tobias Grosser <tobi.grosser@amd.com>
4849 * graphite.c (add_conditions_to_domain): Add the loops to
4850 the dimension of the iteration domain. Do copy the domain
4851 only when it exists.
4852 (build_scop_conditions_1): Do not call add_conditions_to_domain.
4853 (add_conditions_to_constraints): New.
4854 (can_generate_code_stmt, can_generate_code): Removed.
4855 (gloog): Do not call can_generate_code.
4856 (graphite_transform_loops): Call add_conditions_to_constraints
4857 after building the iteration domain.
4859 2009-01-14 Sebastian Pop <sebastian.pop@amd.com>
4860 Tobias Grosser <tobi.grosser@amd.com>
4861 Jan Sjodin <jan.sjodin@amd.com>
4863 * graphite.c (scan_tree_for_params): On substractions negate
4864 all the coefficients of the term.
4865 (clast_to_gcc_expression_red): New. Handle reduction expressions
4866 of more than two operands.
4867 (clast_to_gcc_expression): Call clast_to_gcc_expression_red.
4868 (get_vdef_before_scop): Handle also the case of default definitions.
4870 2009-01-14 Sebastian Pop <sebastian.pop@amd.com>
4873 * graphite.c (get_vdef_before_scop, scop_adjust_vphi): New.
4874 (scop_adjust_phis_for_liveouts): Call scop_adjust_vphi.
4875 (gloog): Do not call cleanup_tree_cfg.
4876 (graphite_transform_loops): Call cleanup_tree_cfg after all
4877 scops have been code generated.
4879 2009-01-13 Sebastian Pop <sebastian.pop@amd.com>
4881 * passes.c (init_optimization_passes): Schedule after
4882 graphite transforms pass_copy_prop, pass_dce_loop and pass_lim.
4884 2009-01-13 Sebastian Pop <sebastian.pop@amd.com>
4886 * graphite.c (expand_scalar_variables_stmt): Do not pass loop_p.
4888 (expand_scalar_variables_ssa_name): Do not pass loop_p. Fix comment.
4889 Set the type of an expression to the type of its assign statement.
4890 (expand_scalar_variables_expr): Do not pass loop_p.
4891 Fix comment. Stop recursion on tcc_constant or tcc_declaration.
4892 (copy_bb_and_scalar_dependences): Do not pass loop_p.
4893 (translate_clast): Update call to copy_bb_and_scalar_dependences.
4895 2009-01-11 Sebastian Pop <sebastian.pop@amd.com>
4897 * graphite.c (expand_scalar_variables_ssa_name): Set the type of
4898 an expression to the gimple_expr_type of its assign statement.
4899 (expand_scalar_variables_expr): Stop recursion on tcc_constant
4902 2009-01-11 Sebastian Pop <sebastian.pop@amd.com>
4904 PR tree-optimization/38786
4905 * gcc.dg/graphite/pr38786.c: New.
4906 * graphite.c (expand_scalar_variables_ssa_name): New, outlined from
4907 the SSA_NAME case of expand_scalar_variables_expr.
4908 (expand_scalar_variables_expr): Also gather the scalar computation
4909 used to index the memory access.
4910 (expand_scalar_variables_stmt): Pass to expand_scalar_variables_expr
4911 the gimple_stmt_iterator where it inserts new code.
4913 2009-01-10 Sebastian Pop <sebastian.pop@amd.com>
4915 * gcc.dg/graphite/block-3.c: Fix compile error on 32bit.
4917 2009-01-10 Sebastian Pop <sebastian.pop@amd.com>
4919 * opts.c (decode_options): Enable flag_graphite_identity and
4920 flag_loop_block in -O2 and above.
4922 2009-01-08 Sebastian Pop <sebastian.pop@amd.com>
4924 * libjava/classpath/lib/gnu/java/awt/peer/gtk/GtkMouseInfoPeer.class:
4925 Fix merge problem: replace with the file from trunk.
4927 2009-01-08 Sebastian Pop <sebastian.pop@amd.com>
4929 * Merge from mainline (r141727:143163).
4931 2009-01-07 Sebastian Pop <sebastian.pop@amd.com>
4932 Jan Sjodin <jan.sjodin@amd.com>
4934 PR tree-optimization/38559
4935 * gcc.dg/graphite/pr38559.c: New.
4937 * graphite.c (debug_value, copy_constraint,
4938 swap_constraint_variables, scale_constraint_variable, ): New.
4939 (get_lower_bound, get_upper_bound): Removed.
4940 (graphite_trans_bb_strip_mine): Clean up this code that works
4941 only for constant number of iterations. Fully copy upper and
4942 lower bound constraints, not only the constant part of them.
4943 * graphite.h (debug_value): Declared.
4945 2009-01-06 Jan Sjodin <jan.sjodin@amd.com>
4947 PR tree-optimization/38492
4948 PR tree-optimization/38498
4949 * tree-check.c (operator_is_linear, scev_is_linear_expression): New.
4950 * tree-chrec.h (scev_is_linear_expression): Declared.
4951 * graphite.c (graphite_cannot_represent_loop_niter): New.
4952 (scopdet_basic_block_info): Call graphite_cannot_represent_loop_niter.
4953 (graphite_loop_normal_form): Use gcc_assert.
4954 (scan_tree_for_params): Use CASE_CONVERT.
4955 (phi_node_is_iv, bb_contains_non_iv_scalar_phi_nodes): New.
4956 (build_scop_conditions_1): Call bb_contains_non_iv_scalar_phi_nodes.
4957 Use gcc_assert. Discard scops that contain unhandled cases.
4958 (build_scop_conditions): Return a boolean status for unhandled cases.
4959 (strip_mine_profitable_p): Print the loop number, not its depth.
4960 (is_interchange_valid): Pass the depth of the loop nest, don't
4961 recompute it wrongly.
4962 (graphite_trans_bb_block): Same.
4963 (graphite_trans_bb_block): Print tentative of loop blocking.
4964 (graphite_trans_scop_block): Do not print that the loop has been
4966 (graphite_transform_loops): Do not handle scops that contain condition
4969 * gcc.dg/graphite/pr38500.c: Fixed warning as committed
4971 * gcc.dg/graphite/block-0.c: Update test.
4972 * gcc.dg/graphite/block-1.c: Same.
4973 * gcc.dg/graphite/block-2.c: Remove xfail and test for
4975 * gcc.dg/graphite/block-4.c: Remove test for strip mine.
4976 * gcc.dg/graphite/block-3.c: New.
4977 * gcc.dg/graphite/pr38498.c: New.
4979 2008-12-22 Harsha Jagasia <harsha.jagasia@amd.com>
4981 PR tree-optimization/38510
4982 * gcc.dg/graphite/pr38510.c: New.
4983 * graphite.c (recompute_all_dominators): Call mark_irreducible_loops.
4984 (translate_clast): Call recompute_all_dominators before
4986 (gloog): Call recompute_all_dominators before graphite_verify.
4988 2008-12-12 Sebastian Pop <sebastian.pop@amd.com>
4990 PR tree-optimization/38492
4991 * graphite.c (rename_map_elt, debug_rename_elt,
4992 debug_rename_map_1, debug_rename_map, new_rename_map_elt,
4993 rename_map_elt_info, eq_rename_map_elts,
4994 get_new_name_from_old_name, bb_in_sese_p): Moved around.
4995 (sese_find_uses_to_rename_use): Renamed sese_build_livein_liveouts_use.
4996 (sese_find_uses_to_rename_bb): Renamed sese_build_livein_liveouts_bb.
4997 (sese_build_livein_liveouts): New.
4998 (new_sese, free_sese): New.
4999 (new_scop): Call new_sese.
5000 (free_scop): Call free_sese.
5001 (rename_variables_from_edge, rename_phis_end_scop): Removed.
5002 (register_old_new_names): Renamed register_old_and_new_names.
5003 (register_scop_liveout_renames, add_loop_exit_phis,
5004 insert_loop_close_phis, struct igp,
5005 default_liveout_before_guard, add_guard_exit_phis,
5006 insert_guard_phis, copy_renames): New.
5007 (translate_clast): Call insert_loop_close_phis and insert_guard_phis.
5008 (sese_add_exit_phis_edge): Renamed scop_add_exit_phis_edge.
5009 (rewrite_into_sese_closed_ssa): Renamed scop_insert_phis_for_liveouts.
5010 (scop_adjust_phis_for_liveouts): New.
5011 (gloog): Call scop_adjust_phis_for_liveouts.
5013 * graphite.h (struct sese): Documented. Added fields liveout,
5015 (SESE_LIVEOUT, SESE_LIVEIN, SESE_LIVEIN_VER, SESE_NUM_VER): New.
5016 (new_sese, free_sese, sese_build_livein_liveouts): Declared.
5017 (struct scop): Added field liveout_renames.
5018 (SCOP_LIVEOUT_RENAMES): New.
5020 2008-12-11 Sebastian Pop <sebastian.pop@amd.com>
5022 PR tree-optimization/38409
5023 * gcc.dg/graphite/pr38409.c: New.
5024 * graphite.c (nb_reductions_in_loop): Use simple_iv.
5026 2008-12-11 Sebastian Pop <sebastian.pop@amd.com>
5028 * graphite.c (gcc_type_for_cloog_iv): By default return
5030 (graphite_create_new_loop): Don't fold_convert the already
5031 fold_convert-ed expression.
5033 2008-12-11 Harsha Jagasia <harsha.jagasia@amd.com>
5035 PR tree-optimization/38446
5036 * gcc.dg/graphite/pr38446.c: New.
5037 * graphite.c (register_bb_in_sese): New.
5038 (bb_in_sese_p): Check if bb belongs to sese region by explicitly
5039 looking at the bbs in the region.
5040 * graphite.h (sese): Add region_basic_blocks pointer set to
5041 structure and initialize at the time of defining new scop.
5043 2008-12-11 Tobias Grosser <grosser@fim.uni-passau.de>
5045 * graphite.c (new_graphite_bb): Initialize GBB_STATIC_SCHEDULE.
5046 (find_params_in_bb): Do not free data refs.
5047 (free_graphite_bb): Add FIXME on disabled free_data_refs.
5049 2008-12-11 Sebastian Pop <sebastian.pop@amd.com>
5051 * gcc.dg/graphite/scop-16.c: Test only scop specific info.
5052 * gcc.dg/graphite/scop-17.c: Same.
5053 * gcc.dg/graphite/block-5.c: New.
5054 * gcc.dg/graphite/block-6.c: New.
5055 * gcc.dg/graphite/pr37485.c: Clean dump file after.
5056 * gcc.dg/graphite/pr37684.c: Same.
5057 * gcc.dg/graphite/block-2.c: Same.
5059 * graphite.c (struct ivtype_map_elt): New.
5060 (debug_ivtype_elt, debug_ivtype_map_1, debug_ivtype_map,
5061 new_ivtype_map_elt, ivtype_map_elt_info, eq_ivtype_map_elts,
5062 gcc_type_for_cloog_iv): New.
5063 (loop_iv_stack_patch_for_consts): Use the type of the induction
5064 variable from the original loop, except for the automatically
5065 generated loops, i.e., in the case of a strip-mined loop, in
5066 which case there is no original loop: in that case just use
5068 (new_graphite_bb): Initialize GBB_CLOOG_IV_TYPES.
5069 (free_graphite_bb): Free GBB_CLOOG_IV_TYPES.
5070 (clast_name_to_gcc): Accept params to be NULL.
5071 (clast_to_gcc_expression): Take an extra parameter for the type.
5072 Convert to that type all the expressions built by this function.
5073 (gcc_type_for_clast_expr, gcc_type_for_clast_eq): New.
5074 (graphite_translate_clast_equation): Compute the type of the
5075 clast_equation before translating its LHS and RHS.
5076 (clast_get_body_of_loop, gcc_type_for_iv_of_clast_loop): New.
5077 (graphite_create_new_loop): Compute the type of the induction
5078 variable before translating the lower and upper bounds and before
5079 creating the induction variable.
5080 (rename_variables_from_edge, rename_phis_end_scop): New.
5081 (copy_bb_and_scalar_dependences): Call rename_phis_end_scop.
5082 (sese_add_exit_phis_edge): Do not use integer_zero_node.
5083 (find_cloog_iv_in_expr, compute_cloog_iv_types_1,
5084 compute_cloog_iv_types): New.
5085 (gloog): Call compute_cloog_iv_types before starting the
5086 translation of the clast.
5088 * graphite.h (struct graphite_bb): New field cloog_iv_types.
5089 (GBB_CLOOG_IV_TYPES): New.
5090 (debug_ivtype_map): Declared.
5091 (oldiv_for_loop): New.
5093 2008-12-10 Tobias Grosser <grosser@fim.uni-passau.de>
5096 * graphite.c (new_scop): Initialize SCOP_ADD_PARAMS.
5097 (param_index): Assert if parameter is not know after parameter
5099 (find_params_in_bb): Detect params directly in GBB_CONDITIONS.
5100 (find_scop_parameters): Mark, that we have finished parameter
5102 (graphite_transform_loops): Move condition detection before parameter
5104 * graphite.h (struct scop): Add SCOP_ADD_PARAMS.
5105 * gfortran.dg/graphite/pr38459.f90: New.
5107 2008-12-09 Tobias Grosser <grosser@fim.uni-passau.de>
5109 * graphite.c (graphite_transform_loops): Always call find_transform ()
5110 in ENABLE_CHECKING. So we test these code paths, even if we do not
5113 2008-12-09 Tobias Grosser <grosser@fim.uni-passau.de>
5115 * graphite.c (print_graphite_bb): Fix printing to file != dump_file.
5116 (print_scop): Ditto.
5118 2008-12-08 Tobias Grosser <grosser@fim.uni-passau.de>
5121 Fix gfortran.dg/graphite/id-3.f90.
5122 * graphite.c (scopdet_basic_block_info): Fix bug that found some
5123 regions more than once.
5125 2008-12-03 Sebastian Pop <sebastian.pop@amd.com>
5127 Fix gfortran.dg/graphite/id-4.f90.
5128 * graphite.c (scan_tree_for_params): Do not compute the multiplicand
5131 2008-12-03 Sebastian Pop <sebastian.pop@amd.com>
5133 Fix gfortran.dg/graphite/id-1.f90.
5134 * graphite.c (gmp_cst_to_tree): Pass the type in parameter.
5135 (loop_iv_stack_patch_for_consts): Update use of gmp_cst_to_tree.
5136 (max_precision_type): New.
5137 (value_clast): Removed.
5138 (clast_to_gcc_expression): Be more careful to types of expressions.
5139 Use max_precision_type and update use of gmp_cst_to_tree.
5140 (graphite_translate_clast_equation): Use max_precision_type.
5141 (graphite_create_guard_cond_expr): Do not use integer_type_node,
5142 use the type of the condition.
5143 (graphite_create_new_loop): Do not use integer_type_node, use the
5144 max_precision_type of lb and ub.
5146 2008-12-03 Sebastian Pop <sebastian.pop@amd.com>
5148 * graphite.c (build_scops_1): Initialize open_scop.exit
5151 2008-12-02 Sebastian Pop <sebastian.pop@amd.com>
5153 * gcc.dg/graphite/pr38084.c: New.
5154 * gfortran.dg/graphite/id-1.f90: New.
5155 * gfortran.dg/graphite/id-2.f90: New.
5156 * gfortran.dg/graphite/id-3.f90: New.
5157 * gfortran.dg/graphite/id-4.f90: New.
5158 * gfortran.dg/graphite/pr37857.f90: New.
5160 2008-12-02 Sebastian Pop <sebastian.pop@amd.com>
5161 Jan Sjodin <jan.sjodin@amd.com>
5162 Harsha Jagasia <harsha.jagasia@amd.com>
5174 * gcc.dg/graphite/pr38073.c: New.
5175 * gcc.dg/graphite/pr37928.c: New.
5176 * gcc.dg/graphite/pr37883.c: New.
5177 * gcc.dg/graphite/pr38125.c: New.
5178 * gfortran.dg/graphite/pr38083.f90: New.
5179 * gfortran.dg/graphite/pr37852.f90: New.
5180 * gfortran.dg/graphite/pr37980.f90: New.
5182 * gcc.dg/graphite/scop-18.c: Remove reduction, test for
5183 the number of detected scops. Copy exact same test for loop
5185 * gcc.dg/graphite/block-1.c: Fix the number of expected
5186 loops to be blocked as reductions are not handled.
5187 * gcc.dg/graphite/block-4.c: ...here. New.
5189 * tree-phinodes.c (remove_phi_nodes): New, extracted from...
5190 * tree-cfg.c (remove_phi_nodes_and_edges_for_unreachable_block):
5192 * tree-flow.h (remove_phi_nodes, canonicalize_loop_ivs): Declared.
5193 * Makefile.in (graphite.o): Depend on value-prof.h.
5194 (graphite.o-warn): Removed -Wno-error.
5195 * tree-parloops.c (canonicalize_loop_ivs): Allow reduction_list
5196 to be a NULL pointer. Call update_stmt. Return the newly created
5197 cannonical induction variable.
5199 * graphite.h (debug_rename_map): Declared. Fix some comments.
5201 * graphite.c: Reimplement the code generation from graphite to gimple.
5202 Include value-prof.h.
5203 (loop_iv_stack_get_iv): Do not return NULL for constant substitutions.
5204 (get_old_iv_from_ssa_name): Removed.
5205 (graphite_stmt_p): New.
5206 (new_graphite_bb): Test for useful statements before building a
5207 graphite statement for the basic block.
5208 (free_graphite_bb): Do not free GBB_DATA_REFS: this is a bug
5209 in free_data_ref that calls BITMAP_FREE (DR_VOPS (dr)) without
5211 (recompute_all_dominators, graphite_verify,
5212 nb_reductions_in_loop, graphite_loop_normal_form): New.
5213 (scop_record_loop): Call graphite_loop_normal_form.
5214 (build_scop_loop_nests): Iterate over all the blocks of the
5215 function instead of relying on the incomplete information from
5216 SCOP_BBS. Return the success of the operation.
5217 (find_params_in_bb): Use the data from GBB_DATA_REFS.
5218 (add_bb_domains): Removed.
5219 (build_loop_iteration_domains): Don't call add_bb_domains.
5220 Add the iteration domain only to the basic blocks that have been
5221 translated to graphite.
5222 (build_scop_conditions_1): Add constraints only if the basic
5223 block have been translated to graphite.
5224 (build_scop_data_accesses): Completely disabled until data
5225 dependence is correctly implemented.
5226 (debug_rename_elt, debug_rename_map_1, debug_rename_map): New.
5227 (remove_all_edges_1, remove_all_edges): Removed.
5228 (get_new_name_from_old_name): New.
5229 (graphite_rename_variables_in_stmt): Renamed
5230 rename_variables_in_stmt. Call get_new_name_from_old_name.
5231 Use replace_exp and update_stmt.
5232 (is_old_iv): Renamed is_iv.
5233 (expand_scalar_variables_stmt): Extra parameter for renaming map.
5234 Use replace_exp and update_stmt.
5235 (expand_scalar_variables_expr): Same. Use the map to get the
5236 new names for the renaming of induction variables and for the
5237 renaming of variables after a basic block has been copied.
5238 (expand_scalar_variables): Same.
5239 (graphite_rename_variables): Renamed rename_variables.
5240 (move_phi_nodes): Removed.
5241 (get_false_edge_from_guard_bb): New.
5242 (build_iv_mapping): Do not insert the induction variable of a
5243 loop in the renaming iv map if the basic block does not belong
5245 (register_old_new_names, graphite_copy_stmts_from_block,
5246 copy_bb_and_scalar_dependences): New.
5247 (translate_clast): Heavily reimplemented: copy basic blocks,
5248 do not move them. Finally, in call cleanup_tree_cfg in gloog.
5249 At each translation step call graphite_verify ensuring the
5250 consistency of the SSA, loops and dominators information.
5251 (collect_virtual_phis, find_vdef_for_var_in_bb,
5252 find_vdef_for_var_1, find_vdef_for_var,
5253 patch_phis_for_virtual_defs): Removed huge hack.
5254 (mark_old_loops, remove_dead_loops, skip_phi_defs,
5255 collect_scop_exit_phi_args, patch_scop_exit_phi_args,
5256 gbb_can_be_ignored, scop_remove_ignoreable_gbbs, ): Removed.
5257 (remove_sese_region, ifsese, if_region_entry, if_region_exit,
5258 if_region_get_condition_block, if_region_set_false_region,
5259 create_if_region_on_edge, move_sese_in_condition, bb_in_sese_p,
5260 sese_find_uses_to_rename_use, sese_find_uses_to_rename_bb,
5261 sese_add_exit_phis_edge, sese_add_exit_phis_var,
5262 rewrite_into_sese_closed_ssa): New.
5263 (gloog): Remove dead code. Early return if code cannot be
5264 generated. Call cleanup_tree_cfg once the scop has been code
5266 (graphite_trans_scop_block, graphite_trans_loop_block): Do not
5267 block loops with less than two loops.
5268 (graphite_apply_transformations): Remove the call to
5269 scop_remove_ignoreable_gbbs.
5270 (limit_scops): When build_scop_loop_nests fails, continue on
5271 the next scop. Fix open_scop.entry.
5272 (graphite_transform_loops): Call recompute_all_dominators: force the
5273 recomputation of correct CDI_DOMINATORS and CDI_POST_DOMINATORS.
5274 Call initialize_original_copy_tables and free_original_copy_tables
5275 to be able to copy basic blocks during code generation.
5276 When build_scop_loop_nests fails, continue on next scop.
5277 (value_clast): New union.
5278 (clast_to_gcc_expression): Fix type cast warning.
5280 2008-11-09 Sebastian Pop <sebastian.pop@amd.com>
5282 * Merge from mainline (r140838:141727).
5284 2008-11-05 Tobias Grosser <grosser@fim.uni-passau.de>
5288 * graphite.c (scan_tree_for_params): Add POINTER_PLUS_EXPR.
5290 2008-11-05 Tobias Grosser <grosser@fim.uni-passau.de>
5294 * graphite.c (scopdet_basic_block_info): Fix loops with multiple
5295 exits and conditions.
5296 * gcc.dg/graphite/pr37943.c: New.
5298 2008-10-23 Tobias Grosser <grosser@fim.uni-passau.de>
5301 * graphite.c (gloog): Replace EXIT_BLOCK_PTR with scop exit.
5303 2008-10-23 Tobias Grosser <grosser@fim.uni-passau.de>
5305 * doc/invoke.texi: Fix spaces.
5307 2008-10-22 Sebastian Pop <sebastian.pop@amd.com>
5309 PR tree-optimization/37891
5310 Reverted last commit.
5311 * graphite.c (create_single_entry_edge): Set
5312 EDGE_IRREDUCIBLE_LOOP and BB_IRREDUCIBLE_LOOP.
5314 2008-10-21 Sebastian Pop <sebastian.pop@amd.com>
5315 Mitul Thakkar <mitul.thakkar@amd.com>
5317 * graphite.c (create_single_entry_edge): Set
5318 EDGE_IRREDUCIBLE_LOOP and BB_IRREDUCIBLE_LOOP.
5320 2008-10-16 Tobias Grosser <grosser@fim.uni-passau.de>
5322 * doc/invoke.texi: Add -fgraphite-identity.
5323 * graphite.c (graphite_apply_transformations): Check for
5324 -fgraphite-identity.
5325 * toplev.c (process_options): Add flag_graphite_identity.
5326 * tree-ssa-loop.c: Add flag_graphite_identity.
5328 2008-10-14 Sebastian Pop <sebastian.pop@amd.com>
5330 Undo changes from 2008-10-02:
5331 * tree-ssa-loop-ivopts.c (rewrite_use_nonlinear_expr): Convert
5332 operand type when copying the operand to a variable of different type.
5333 * cfgloopmanip.c (create_empty_loop_on_edge): Write exit condition
5334 with the IV name after increment.
5336 2008-10-14 Sebastian Pop <sebastian.pop@amd.com>
5337 Harsha Jagasia <harsha.jagasia@amd.com>
5339 PR tree-optimization/37828
5340 * gcc.dg/graphite/pr37828.c: New.
5341 * graphite.c (graphite_trans_loop_block): Do not loop block
5342 single nested loops.
5344 2008-10-09 Harsha Jagasia <harsha.jagasia@amd.com>
5345 Sebastian Pop <sebastian.pop@amd.com>
5347 * graphite.c (struct rename_map_elt, new_rename_map_elt,
5348 rename_map_elt_info, eq_rename_map_elts): New.
5349 (graphite_rename_ivs_stmt): Renamed graphite_rename_variables_in_stmt.
5350 (expand_scalar_variables_expr): Change parameters.
5351 (expand_scalar_variables_stmt): Same.
5352 (expand_scalar_variables): Same.
5353 (graphite_rename_ivs): Rename graphite_rename_variables.
5354 (build_iv_mapping): New.
5355 (translate_clast): Call build_iv_mapping.
5356 * graphite.h (gbb_p): New name.
5358 2008-10-03 Harsha Jagasia <harsha.jagasia@amd.com>
5360 PR tree-optimization/37684
5361 * gcc.dg/graphite/pr37684.c: New.
5362 * graphite.c (exclude_component_ref): New.
5363 (is_simple_operand): Call exclude_component_ref.
5365 2008-10-02 Jan Sjodin <jan.sjodin@amd.com>
5366 Harsha Jagasia <harsha.jagasia@amd.com>
5368 PR tree-optimization/37485
5369 * gcc.dg/graphite/block-2.c: New
5370 * graphite.c (gmp_cst_to_tree): Moved.
5371 (iv_stack_entry_is_constant): New.
5372 (iv_stack_entry_is_iv): New.
5373 (loop_iv_stack_push): Renamed to loop_iv_stack_push_iv.
5374 (loop_iv_stack_insert_constant): New.
5375 (loop_iv_stack_pop): Use new datatpype.
5376 (loop_iv_stack_get_iv): Same.
5377 (loop_iv_stack_get_iv_from_name): Same.
5378 (loop_iv_stack_debug): Renamed to debug_loop_iv_stack.
5379 (loop_iv_stack_patch_for_consts): New.
5380 (loop_iv_stack_remove_constants): New.
5381 (graphite_create_new_loop): Use loop_iv_stack_push_iv.
5382 (translate_clast): Call loop_iv_stack_patch_for_consts and
5383 loop_iv_stack_remove_constants.
5384 (gloog): Use new datatype. Redirect construction edge to end
5385 block to avoid accidental deletion.
5386 * graphite.h (enum iv_stack_entry_kind): New. Tag for data in
5388 (union iv_stack_entry_data): New. Data in iv stack entry.
5389 (struct iv_stack_entry): New. Datatype for iv stack entries.
5391 2008-10-02 Sebastian Pop <sebastian.pop@amd.com>
5393 * tree-ssa-loop-ivopts.c (rewrite_use_nonlinear_expr): Convert
5394 operand type when copying the operand to a variable of different type.
5396 2008-10-02 Sebastian Pop <sebastian.pop@amd.com>
5398 * cfgloopmanip.c (create_empty_loop_on_edge): Write exit condition
5399 with the IV name after increment.
5401 2008-10-02 Sebastian Pop <sebastian.pop@amd.com>
5403 * Merge from mainline (r140164:140838).
5405 2008-09-10 Konrad Trifunovic <konrad.trifunovic@inria.fr>
5407 * graphite-data-ref.c: New.
5408 * graphite.c (print_scop): Also dump the dependence graph.
5409 (bb_in_scop_p, loop_in_scop_p, nb_loops_around_gb): Moved...
5410 (new_scop): Initialize SCOP_DEP_GRAPH.
5411 (build_scop_dynamic_schedules): New.
5412 (build_access_matrix_with_af): Fixed column numbering.
5413 (graphite_transform_loops): Call build_scop_dynamic_schedules.
5414 * graphite.h: Add ifndef/define guards against multiple inclusion.
5415 (struct scop): Add dep_graph field.
5416 (SCOP_DEP_GRAPH): Defined.
5417 (ref_nb_loops): Fixed and moved to other position.
5418 (bb_in_scop_p, loop_in_scop_p, nb_loops_around_gb): ... here.
5419 (nb_loops_around_loop_in_scop): New.
5420 (graphite_dump_dependence_graph): Declared.
5421 (graphite_build_rdg_all_levels): Declared.
5422 (graphite_test_dependence): Declared.
5423 * Makefile.in (graphite-data-ref.o): New target.
5425 2008-09-09 Sebastian Pop <sebastian.pop@amd.com>
5427 * Merge from mainline (139870:140164).
5429 2008-09-01 Sebastian Pop <sebastian.pop@amd.com>
5431 * Merge from mainline (138275:139870).
5432 * gcc.dg/graphite/scop-matmult.c: XFailed as one of
5433 the commits from trunk broke the niter detection.
5435 2008-09-01 Sebastian Pop <sebastian.pop@amd.com>
5437 * graphite.c: Add more documentation. Fix formatting.
5438 (debug_loop_vec, debug_oldivs, loop_iv_stack,
5439 loop_iv_stack_debug): Moved...
5440 (schedule_to_scattering): Move before use.
5441 (dot_all_scops): Include in "#if 0" the code for system
5444 * graphite.h: (debug_loop_vec, debug_oldivs, loop_iv_stack,
5445 loop_iv_stack_debug): ...here.
5447 2008-08-29 Jan Sjodin <jan.sjodin@amd.com>
5449 * tree-phinodes.c (make_phi_node): Extern.
5450 (add_phi_node_to_bb): New.
5451 (create_phi_node): Call add_phi_node_to_bb.
5452 * tree-ssa-loop-ivopts.c (get_phi_with_result): New.
5453 (remove_statement): Handle case where stored phi was updated
5454 and is no longer the same.
5455 * graphite.c (is_parameter): New.
5457 (expand_scalar_variables_expr): New.
5458 (expand_scalar_variables_stmt): New.
5459 (expand_scalar_variables): New.
5460 (move_phi_nodes): Create new phi instead of moving old one.
5461 (translate_clast): Call expand_scalar_variables.
5462 (find_vdef_for_var_in_bb): Also scan regular definitions.
5463 (skip_phi_defs): New.
5464 (collect_scop_exit_phi_args): New.
5465 (patch_scop_exit_phi_args): New.
5466 (gloog): Patch phis after scop.
5467 * tree-flow.h: (add_phi_node_to_bb): Declared.
5468 (make_phi_node): Declared.
5470 2008-08-26 Sebastian Pop <sebastian.pop@amd.com>
5472 * graphite.c (end_scop): Split the entry of the scop when it
5473 is the header of the loop in which the scop is ending.
5474 (build_scops_1, limit_scops): Update uses of end_scop.
5476 2008-08-26 Sebastian Pop <sebastian.pop@amd.com>
5478 * graphite.c (dot_all_scops_1): Do not fail on uninitialized
5479 SCOP_ENTRY or SCOP_EXIT.
5481 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
5483 * graphite.c (get_construction_edge): Removed.
5484 (gloog): Construction edge is the scop entry edge.
5486 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
5488 * graphite.c (can_generate_for_scop): Removed.
5489 (gloog): Do not call it.
5491 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
5493 * graphite.c (new_scop): Entry of a scop is an edge.
5494 Initialize SESE region.
5495 (free_scop): Free SESE region.
5496 (build_scops_1, scopdet_bb_info): Work on edges, not on bbs.
5497 (split_difficult_bb): New, split from end_scop.
5498 (end_scop): Exit of a scop is an edge.
5499 (build_scop_bbs): Never check CDI_POST_DOMINATORS: this info is
5500 not automatically updated and thus is always wrong.
5501 * graphite.h (struct sese): New.
5504 (struct scop): New field for a SESE region. Remove entry, exit.
5505 (SCOP_ENTRY, SCOP_EXIT): Update definitions to match same
5506 semantics as before. Moved comment around.
5508 2008-08-25 Tobias Grosser <grosser@fim.uni-passau.de>
5509 Sebastian Pop <sebastian.pop@amd.com>
5511 * graphite.c (graphite_transform_loops): Always enable gloog
5512 and find_transform when ENABLE_CHECKING.
5514 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
5516 * graphite.c (graphite_transform_loops): Move pretty printer
5517 of SCOPs before doing any transform. Remove call to print_scops
5518 and dot_all_scops_1.
5520 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
5522 * graphite.c (dump_gbb_conditions): Don't try to print NULL pointers.
5523 (print_graphite_bb): Same.
5525 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
5527 * graphite.c (dot_all_scops_1): Cleanup.
5528 (move_scops): Fix comment.
5530 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
5532 * graphite.c (build_scop_bbs): Revert commit 139355:
5534 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5535 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
5537 * graphite.c (build_scop_bbs): Factor up code.
5539 2008-08-25 Tobias Grosser <grosser@fim.uni-passau.de>
5541 * graphite.c (gloog): Update dominator info.
5543 2008-08-25 Tobias Grosser <grosser@fim.uni-passau.de>
5545 * graphite.c (remove_cond_exprs): Do not fail on empty bbs.
5547 2008-08-24 Sebastian Pop <sebastian.pop@amd.com>
5549 * graphite.c (new_graphite_bb): Remove GBB_INDEX_TO_NUM_MAP
5551 (free_graphite_bb): Remove GBB_INDEX_TO_NUM_MAP free.
5552 (translate_clast): Correct formatting.
5553 * graphite.h (struct num_map): Removed.
5554 (struct graphite_bb): Remove num_map field.
5555 (GBB_INDEX_TO_NUM_MAP): Removed.
5557 2008-08-24 Sebastian Pop <sebastian.pop@amd.com>
5559 * graphite.c (build_access_matrix_with_af): Fix comments.
5560 (build_scop_data_accesses): Same.
5562 2008-08-24 Sebastian Pop <sebastian.pop@amd.com>
5564 * graphite.c (build_scop_data_accesses): Don't construct
5565 access matrices. Add a FIXME and an assert condition that
5566 should pass when the access matrices will be needed.
5568 2008-08-24 Sebastian Pop <sebastian.pop@amd.com>
5570 * tree-data-ref.c (stmt_simple_memref_p): Don't call
5572 * graphite.c (build_graphite_bb): Renamed new_graphite_bb.
5573 Moved close by free_graphite_bb.
5574 (free_graphite_bb): Call free_data_refs. Reset bb->aux.
5575 (new_scop): Move close by free_scop.
5576 (graphite_transform_loops): Avoid linear scan to reset bb->aux.
5578 2008-08-22 Jan Sjodin <jan.sjodin@amd.com>
5580 * cfgloopmanip.c (create_empty_if_region_on_edge): New.
5581 * graphite.c (clast_to_gcc_expression): Call gmp_cst_to_tree
5582 instead of recursive call.
5583 (graphite_translate_clast_equation): New.
5584 (graphite_create_guard_cond_expr): New.
5585 (graphite_create_new_guard): New.
5586 (get_stack_index_from_iv): Removed.
5587 (graphite_rename_ivs_stmt): Use gbb_loop_index.
5588 (get_true_edge_from_guard_bb): New.
5589 (translate_clast): Handle stmt_guard in clast.
5590 (get_construction_edge): Allow construction edge detection for
5591 a scope entry with multiple predecessors if one predecessor is
5592 the immediate dominator of scope entry.
5593 (can_generate_code_stmt): Enable code generation for clast_guard.
5594 (gloog): Use correct context loop. Removed check for post dominators.
5595 * cfgloop.h (create_empty_if_region_on_edge): Declared.
5597 2008-08-21 Sebastian Pop <sebastian.pop@amd.com>
5599 * graphite.c (remove_dead_loops): Document better which
5602 2008-08-21 Sebastian Pop <sebastian.pop@amd.com>
5604 * Makefile.in: Rename POLYLIBLIBS and POLYLIBINC to PPLLIBS
5606 (graphite.o): Also depends on pointer-set.h.
5608 2008-08-21 Sebastian Pop <sebastian.pop@amd.com>
5610 * graphite.c (scop_record_loop): Fix compile warning.
5612 2008-08-21 Harsha Jagasia <harsha.jagasia@amd.com>
5613 Sebastian Pop <sebastian.pop@amd.com>
5615 * graphite.c (scop_record_loop): DECL_NAME can be NULL.
5617 2008-08-21 Sebastian Pop <sebastian.pop@amd.com>
5619 * graphite.c (build_graphite_bb): Initialize bb->aux to
5620 point to the graphite_bb_p.
5621 (graphite_bb_from_bb): Renamed gbb_from_bb; returns the
5623 (add_bb_domains): Does not use the scop parameter.
5624 (graphite_transform_loops): Clean bb->aux at the end.
5626 2008-08-20 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
5627 Sebastian Pop <sebastian.pop@amd.com>
5629 * lib/target-supports.exp
5630 (check_effective_target_fgraphite): New.
5632 * gcc.dg/graphite/graphite.exp: Early exit when
5633 check_effective_target_fgraphite returns false.
5634 Set dg-do-what-default to compile.
5635 (scan-graphite-dump-times): Removed.
5636 * gfortran.dg/graphite/graphite.exp: Same.
5638 * gcc.dg/graphite/scop-0.c: Do not use "dg-do compile".
5639 Use scan-tree-dump-times instead of scan-graphite-dump-times.
5640 * gcc.dg/graphite/scop-1.c: Same.
5641 * gcc.dg/graphite/scop-2.c: Same.
5642 * gcc.dg/graphite/scop-3.c: Same.
5643 * gcc.dg/graphite/scop-4.c: Same.
5644 * gcc.dg/graphite/scop-5.c: Same.
5645 * gcc.dg/graphite/scop-6.c: Same.
5646 * gcc.dg/graphite/scop-7.c: Same.
5647 * gcc.dg/graphite/scop-8.c: Same.
5648 * gcc.dg/graphite/scop-9.c: Same.
5649 * gcc.dg/graphite/scop-10.c: Same.
5650 * gcc.dg/graphite/scop-11.c: Same.
5651 * gcc.dg/graphite/scop-12.c: Same.
5652 * gcc.dg/graphite/scop-13.c: Same.
5653 * gcc.dg/graphite/scop-matmult.c: Same.
5654 * gcc.dg/graphite/scop-14.c: Same.
5655 * gcc.dg/graphite/scop-15.c: Same.
5656 * gcc.dg/graphite/block-0.c: Same.
5657 * gcc.dg/graphite/scop-16.c: Same.
5658 * gcc.dg/graphite/block-1.c: Same.
5659 * gcc.dg/graphite/scop-17.c: Same.
5660 * gcc.dg/graphite/scop-18.c: Same.
5661 * gfortran.dg/graphite/block-1.f90: Same.
5662 * gfortran.dg/graphite/scop-1.f: Same.
5663 * gfortran.dg/graphite/block-2.f: Same.
5665 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5667 * graphite.c: Fix some XXX comments.
5668 (build_scop_dynamic_schedules): Removed.
5670 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5672 * graphite.h (scop_max_loop_depth): Moved...
5673 * graphite.c (scop_max_loop_depth): ...here.
5674 (remove_all_edges_1): New.
5675 (remove_all_edges): Factored code.
5676 (remove_cond_exprs): Check only the last statement for
5677 a GIMPLE_COND expression.
5679 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5681 * graphite.c (scan_tree_for_params): Early return when the
5682 expression is a chrec_dont_know. Handle case NEGATE_EXPR.
5683 (find_scop_parameters): Factor out code.
5684 (graphite_trans_bb_strip_mine): Remove dead code.
5686 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5688 * graphite.c (clast_to_gcc_expression, graphite_create_new_loop,
5689 graphite_trans_bb_move_loop): Factor asserts.
5690 (gloog): Perform sanity checks only for ENABLE_CHECKING.
5691 Do not call calculate_dominance_info and estimate_bb_frequencies.
5693 2008-08-20 Jan Sjodin <jan.sjodin@amd.com>
5695 * graphite.c (create_loops_mapping, free_loops_mapping,
5696 create_loops_mapping_num, debug_loop_mapping_1,
5697 debug_loop_mapping, graphite_loops_mapping_max_loop_num,
5698 get_loop_mapping_for_num, graphite_loops_mapping_add_child,
5699 graphite_loops_mapping_add_child_num,
5700 graphite_loops_mapping_insert_child,
5701 graphite_loops_mapping_parent, get_loop_mapped_depth_for_num,
5702 get_loop_mapped_depth, split_loop_mapped_depth_for_num,
5703 loop_mapped_depth_split_loop, swap_loop_mapped_depth_for_num,
5704 create_num_from_index, get_num_from_index,
5705 swap_loop_mapped_depth): Removed.
5706 (new_scop): Do not initialize SCOP_LOOPS_MAPPING.
5707 (free_scop): Do not call free_loops_mapping.
5708 (graphite_get_new_iv_stack_index_from_old_iv): Renamed
5709 get_stack_index_from_iv. Use GBB_LOOPS instead of calling
5710 get_loop_mapped_depth.
5711 (graphite_trans_bb_move_loop): Do not update the loop mapping.
5712 (graphite_trans_bb_strip_mine): Same.
5713 * graphite.h (graphite_loops_mapping, graphite_loop_node): Removed.
5714 (struct scop): Remove field loops_mapping.
5716 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5717 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
5719 * graphite.c (scop_record_loop): Factor out one level of the
5720 condition by early return.
5721 (build_scop_loop_nests): Format following FSF coding style.
5722 (build_scop_dynamic_schedules): Factor out code.
5723 (scopdet_bb_info): Reindent. Default case should not be reachable.
5725 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5726 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
5728 * graphite.c (loop_affine_expr): Check for DECL_P or struct
5729 assignments that are not handled as simple operands for now.
5731 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5732 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
5734 * graphite.c (build_scop_bbs): Factor up code.
5736 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5737 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
5739 * graphite.c (stmt_simple_for_scop_p): Factor code out
5741 (enum gbb_type): New. Group all the GBB_* types under it.
5742 (is_loop_exit): Moved...
5743 (end_scop): Enable BB spliting.
5744 * cfgloop.c (is_loop_exit): ...here. Reimplemented.
5745 * cfgloop.h (is_loop_exit): Declared.
5747 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5749 * doc/invoke.texi: Remove strides from examples containing
5750 DO loops when the strides are equal to 1.
5752 2008-08-20 Harsha Jagasia <harsha.jagasia@amd.com>
5753 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
5755 * graphite.c (graphite_trans_scop_block): Or the result with
5756 the result from graphite_trans_loop_block.
5757 * gcc.dg/graphite/block-1.c: New.
5758 * gfortran.dg/graphite/block-1.f90: New.
5759 * gfortran.dg/graphite/block-2.f: New.
5761 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5763 * graphite.c (graphite_transform_loops): Call cloog_initialize
5766 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5768 * tree-data-ref.c) (stmt_simple_memref_p): New.
5769 * tree-data-ref.h (stmt_simple_memref_p): Declared.
5770 * graphite.c (stmt_simple_memref_for_scop_p): Removed.
5771 (is_simple_operand): Call stmt_simple_memref_p.
5773 * gcc.dg/graphite/scop-matmult.c: Updated for not
5774 using pointer arithmetic, as this is optimized by PRE and
5775 makes the code too difficult to analyze.
5777 * gcc.dg/graphite/scop-18.c: Same.
5779 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5781 * gdbinit.in (pgg): New.
5783 2008-08-15 Tobias Grosser <grosser@fim.uni-passau.de>
5785 * graphite.c (graphite_trans_loop_block): Fix warning.
5787 2008-08-15 Tobias Grosser <grosser@fim.uni-passau.de>
5789 * graphite.c (graphite_trans_loop_block): Fix my merge error.
5791 2008-08-15 Tobias Grosser <grosser@fim.uni-passau.de>
5793 * graphite.c (graphite_trans_bb_block): Remove check for
5794 flag_loop_strip_mine, flag_loop_block, flag_loop_interchange.
5795 Check if loop blocking is profitable for every loop, before applying
5797 (graphite_apply_transformations): Call graphite_trans_bb_block only,
5798 if flag_loop_block is set.
5800 2008-08-14 Sebastian Pop <sebastian.pop@amd.com>
5802 * graphite.c: Add some more documentation for the loop
5805 2008-08-14 Sebastian Pop <sebastian.pop@amd.com>
5807 * Makefile.in (tree-data-ref.o): Remove dependence on graphite.h.
5808 * graphite.c: Format on less than 80 columns.
5811 2008-08-14 Sebastian Pop <sebastian.pop@amd.com>
5813 * cfgloopmanip.c (loopify): Use update_dominators_in_loop.
5815 2008-08-14 Sebastian Pop <sebastian.pop@amd.com>
5817 * doc/invoke.texi (floop-block, floop-strip-mine,
5818 floop-interchange): Update documentation with examples.
5820 2008-08-13 Sebastian Pop <sebastian.pop@amd.com>
5822 * cfgloopmanip.c (create_empty_loop_on_edge): Don't call
5824 * graphite.c (graphite_create_new_loop): Call add_referenced_var.
5826 2008-08-13 Sebastian Pop <sebastian.pop@amd.com>
5828 * cfgloopmanip.c (create_empty_loop_on_edge): Improve documentation.
5829 Factor gcc_asserts into a single one. Use force_gimple_operand_gsi.
5830 * tree-scalar-evolution.c: Revert useless changes.
5831 * tree-phinodes.c: Same.
5834 * tree-vectorizer.h: Same.
5835 * tree-flow.h: Same.
5837 * common.opt (fgraphite): Update documentation.
5839 2008-08-12 Harsha Jagasia <harsha.jagasia@amd.com>
5841 * doc/invoke.texi (-floop-block, -floop-strip-mine,
5842 -floop-interchange): Add more text for explaining what each of these
5844 * tree-into-ssa.c (gimple_vec): Moved to...
5845 * graphite.c: Include gimple.h.
5846 (gimple_vec): Moved to...
5847 (del_loop_to_cloog_loop): Removed.
5848 (loop_affine_expr): Do not call create_data_ref when the
5849 operand is a constant.
5850 (new_scop): Use free instead of del_loop_to_cloog_loop.
5851 * Makefile.in (graphite.o): Depend on GIMPLE_H.
5852 * gimple.h (gimple_vec): ... here.
5854 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5856 * graphite.c (scopdet_bb_info): Only allow loops with known number of
5858 (build_loop_iteration_domains): Fail, if latch executions unknown.
5860 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5862 * graphite.c (add_conditions_to_domain): New.
5863 (build_scop_conditions_1): Call add_conditions_to_domain.
5864 (set_cloog_options): Allow to disable optimizations.
5866 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5868 * graphite.c (find_params_in_bb): Look for parameters in conditions.
5869 Do not use walk_dominator_tree.
5870 (find_scop_parameters): Do not use walk_dominator_tree.
5872 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5874 * graphite.c (scan_tree_for_params) Add / Subtract inequality.
5875 (idx_record_params): Adapt.
5876 * graphite.h (scop_gimple_loop_depth): New.
5878 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5880 * graphite.c (build_scop_dynamic_schedules): Remove value_init.
5881 (scan_tree_for_params): Remove value_init.
5882 (build_scop_context): Remove value_init.
5883 (build_loop_iteration_domains): Remove value_init.
5884 (schedule_to_scattering): Remove value_init.
5885 (graphite_trans_bb_strip_mine): Remove value_init.
5887 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5889 * gcc/graphite.c (limit_scops): New.
5890 (graphite_transform_loops): Add limit SCoPs.
5891 * gcc.dg/graphite/scop-0.c: Update number of SCoPs.
5892 * gcc.dg/graphite/scop-1.c: Update number of SCoPs.
5893 * gcc.dg/graphite/scop-10.c: Update number of SCoPs.
5894 * gcc.dg/graphite/scop-11.c: Update number of SCoPs.
5895 * gcc.dg/graphite/scop-12.c: Update number of SCoPs.
5896 * gcc.dg/graphite/scop-13.c: Update number of SCoPs.
5897 * gcc.dg/graphite/scop-14.c: Update number of SCoPs.
5898 * gcc.dg/graphite/scop-15.c: Update number of SCoPs.
5899 * gcc.dg/graphite/scop-16.c: Update number of SCoPs.
5900 Change loop numbers.
5901 * gcc.dg/graphite/scop-17.c: Update number of SCoPs.
5902 Change loop numbers.
5903 * gcc.dg/graphite/scop-18.c: Update number of SCoPs.
5904 * gcc.dg/graphite/scop-2.c: Update number of SCoPs.
5905 * gcc.dg/graphite/scop-3.c: Update number of SCoPs.
5906 * gcc.dg/graphite/scop-4.c: Update number of SCoPs.
5907 * gcc.dg/graphite/scop-5.c: Update number of SCoPs.
5908 * gcc.dg/graphite/scop-6.c: Update number of SCoPs.
5909 * gcc.dg/graphite/scop-7.c: Update number of SCoPs.
5910 * gcc.dg/graphite/scop-8.c: Update number of SCoPs.
5911 * gcc.dg/graphite/scop-9.c: Update number of SCoPs.
5912 * gcc.dg/graphite/scop-matmult.c: Update number of SCoPs.
5914 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5916 * graphite.c (graphite_transform_loops): Call always find_transform.
5918 2008-08-08 Tobias Grosser <grosser@fim.uni-passau.de>
5920 * graphite.c (free_loops_mapping): New.
5921 (stmt_simple_for_scop_p): Fix typo.
5922 (stmt_simple_for_scop_p): Fix tuples functions, that
5924 (free_graphite_bb): Fix some memleaks.
5925 (free_scop): Fix some memleaks.
5926 (scopdet_bb_info): Do not forget some tmp SCoPs.
5927 (find_params_in_bb): Fix some memleaks.
5928 (clast_to_gcc_expression): Fix warning.
5930 2008-08-07 Tobias Grosser <grosser@fim.uni-passau.de>
5932 * gcc.dg/graphite/scop-16.c: Fix for 32bit.
5933 * gcc.dg/graphite/scop-17.c: Fix for 32bit.
5935 2008-08-04 Sebastian Pop <sebastian.pop@amd.com>
5937 * tree-ssa-loop.c (tree-ssa-loop.o): Do not include toplev.h.
5938 Move code ifdef-ed HAVE_cloog...
5939 * graphite.c: Include toplev.h.
5941 * Makefile.in (OBJS-common): Always build graphite.o.
5942 (BACKEND): Remove @GRAPHITE@.
5943 (tree-ssa-loop.o): Do not depend on TOPLEV_H.
5944 (graphite.o): Depend on TOPLEV_H.
5946 2008-08-04 Sebastian Pop <sebastian.pop@amd.com>
5948 * Makefile.in (tree-ssa-loop.o): Depend on TOPLEV_H.
5949 Remove typo left from polylib to ppl conversion.
5950 * graphite.c (graphite_transforms): Use sorry instead of fatal.
5952 2008-08-03 Sebastian Pop <sebastian.pop@amd.com>
5954 * toplev.c (process_options): Move the graphite loop optimization
5956 * tree-ssa-loop.c (graphite_transforms): ... here.
5957 When not configured with CLooG, print to dump_file that
5958 Graphite transforms were not performed.
5959 * gcc.dg/graphite/graphite.exp (scan-graphite-dump-times):
5961 * gcc.dg/graphite/*.c: Updated all testcases to use
5962 scan-graphite-dump-times.
5964 2008-08-03 Sebastian Pop <sebastian.pop@amd.com>
5966 * graphite.c (dot_scop, dot_all_scops): Do not call system.
5967 Do not open /tmp/scop.dot and /tmp/allscops.dot.
5969 2008-08-02 Sebastian Pop <sebastian.pop@amd.com>
5970 Jan Sjodin <jan.sjodin@amd.com>
5972 * configure: Regenerated.
5973 * omp-low.c (expand_omp_sections): Remove now unused code.
5974 * config.in (HAVE_polylib): Removed.
5975 * configure.ac (HAVE_polylib, POLYLIBLIBS, POLYLIBINC): Removed.
5976 (PPLLIBS, PPLINC): Added.
5977 * graphite.c: Replace unsigned with int wherever possible.
5978 Don't access Cloog's data structures, but use accessor functions.
5979 Clast's stmt->type is now implemented as a vtable: change the
5980 switches of stmt->type into ifs.
5981 (polylib/polylibgmp.h): Don't include.
5982 (initialize_dependence_polyhedron,
5983 initialize_data_dependence_polyhedron, is_empty_polyhedron,
5984 statement_precedes_p, test_dependence, build_rdg_all_levels,
5985 dump_dependence_graph): Removed until this code is cleaned up
5987 * Makefile.in (POLYLIBLIBS): Renamed PPLLIBS.
5988 (POLYLIBINC): Renamed PPLINC.
5990 2008-08-01 Harsha Jagasia <harsha.jagasia@amd.com>
5991 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
5992 Jan Sjodin <jan.sjodin@amd.com>
5994 Finish the merge and tuplification of graphite.
5996 2008-07-24 Sebastian Pop <sebastian.pop@amd.com>
5997 Jan Sjodin <jan.sjodin@amd.com>
5999 Partial merge from mainline (138072:138275).
6000 * graphite.c still has to be tuplified.
6002 2008-07-29 Jan Sjodin <jan.sjodin@amd.com>
6004 * graphite.c (graphite_loops_mapping_max_loop_num): New.
6005 (create_num_from_index): New.
6006 (get_num_from_index): Also pass in the graphite BB.
6007 (free_graphite_bb): Free GBB_INDEX_TO_NUM_MAP.
6008 (build_graphite_bb): Initialize GBB_INDEX_TO_NUM_MAP.
6009 (graphite_trans_bb_strip_mine): Call create_num_from_index.
6010 (is_interchange_valid): Return false when failing.
6011 * graphite.h (struct num_map): New.
6012 (struct graphite_bb): New field num_map.
6013 (GBB_LOOPS_MAPPING): Renamed GBB_INDEX_TO_NUM_MAP.
6015 2008-07-29 Tobias Grosser <grosser@fim.uni-passau.de>
6017 * graphite.c (dump_gbb_conditions): Print also conditions like
6018 "if (a)". Remove dublicated code and use print_generic_expr ().
6019 (stmt_simple_for_scop_p): Only allow conditions we can handle
6022 2008-07-25 Jan Sjodin <jan.sjodin@amd.com>
6024 * graphite.h (struct scop): Removed new_ivs field.
6025 (SCOP_NEWIVS): Deleted.
6026 * graphite.c (new_scop, free_scop, clast_name_to_gcc,
6027 clast_to_gcc_expression, graphite_create_new_loop):
6028 Removed use of new_ivs.
6030 2008-07-25 Jan Sjodin <jan.sjodin@amd.com>
6032 * graphite.c (debug_oldivs, debug_loop_vec, create_loops_mapping,
6033 create_loops_mapping_num, debug_loop_mapping_1): New.
6034 (debug_loop_mapping): Call debug_loop_mapping_1.
6035 (get_loop_mapping_for_num,
6036 graphite_loops_mapping_add_child,
6037 graphite_loops_mapping_add_child_num,
6038 graphite_loops_mapping_insert_child,
6039 graphite_loops_mapping_parent,
6040 split_loop_mapped_depth_for_num,
6041 loop_mapped_depth_split_loop): New.
6042 (increment_loop_mapped_depths): Removed.
6043 (swap_loop_mapped_depth_for_num): Reimplemented.
6044 (new_scop): Call create_loops_mapping.
6045 (scop_record_loop): Call graphite_loops_mapping_insert_child.
6046 (translate_clast): Pass the old loop father in parameter, and pass
6047 it to get_old_iv_from_ssa_name.
6048 (remove_edges_around_useless_blocks, can_generate_code_stmt,
6049 can_generate_code, can_generate_for_scop): New.
6050 (graphite_trans_bb_block): Returns false when it fails to transform.
6051 * graphite.h (graphite_loop_node, graphite_loops_mapping): New.
6053 2008-07-25 Sebastian Pop <sebastian.pop@amd.com>
6055 Reverted all the changes related to the streamization and
6057 These changes are now tracked in the streamization branch.
6059 2008-07-25 Sebastian Pop <sebastian.pop@amd.com>
6060 Jan Sjodin <jan.sjodin@amd.com>
6062 * graphite.c (gbb_compare): Correctly constify.
6063 (gbb_can_be_ignored): Indent.
6064 (graphite_trans_scop_swap_1and2): Add legality check.
6067 2008-07-25 Sebastian Pop <sebastian.pop@amd.com>
6069 Remove fallouts from "Reverted the Condate changes".
6070 * tree.h: Remove unused decl.
6071 * gcc.dg/tree-checker: Same.
6072 * timevar.def: Remove counter.
6074 2008-07-24 Sebastian Pop <sebastian.pop@amd.com>
6076 * Merge from mainline (135673:138072).
6078 Reverted the MIRO changes (from 2008-04-05) that are now
6079 tracked in the miro branch.
6080 * tree-bounds.c: Removed.
6081 * tree-bounds.h: Removed.
6083 Reverted the Condate changes (from 2006-07-04, 2007-03-20) that
6084 are now tracked in the condate branch.
6085 * tree-check.c: Removed.
6086 * tree-match.c: Removed.
6087 * condate.y: Removed.
6089 2008-07-24 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
6091 * common.opt: New user flag -floop-block, -floop-strip-mine
6092 and -floop-interchange.
6093 * toplev.c (process_options): Enable -fgraphite pass if any one of the
6094 graphite loop optimization flags is turned on.
6095 * graphite.c (graphite_apply_transformations): Add flag_loop_block,
6096 flag_loop_strip_mine and flag_loop_interchange checks before
6098 * doc/invoke.texi: Remove -fgraphite and add -floop-block,
6099 -floop-strip-mine and -floop-interchange.
6100 * gcc.dg/graphite/block-0.c: Add -floop-block and remove
6102 * gcc.dg/graphite/scop-16.c: Ditto.
6103 * gcc.dg/graphite/scop-17.c: Ditto.
6104 * gcc.dg/graphite/scop-18.c: Ditto.
6106 2008-07-23 Jan Sjodin <jan.sjodin@amd.com>
6107 Sebastian Pop <sebastian.pop@amd.com>
6109 * cfgloopmanip.c (update_dominators_in_loop): Make it static.
6110 (create_empty_loop_on_edge): More fixes.
6111 * tree-phinodes.c (resize_phi_node): Extern.
6112 (unlink_phi_node, move_phi_node): New split from remove_phi_node.
6113 * cfghooks.c (update_dominator_information): New split from
6115 * tree-vectorizer.c (rename_variables_in_bb): Extern.
6116 * tree-dfa.c (collect_dfa_stats): Start walking the CFG on the
6117 successor of the function entry block.
6119 * graphite.c: Include pointer-set.h.
6120 (debug_loop_mapping, increment_loop_mapped_depths,
6121 get_loop_mapped_depth_for_num, get_loop_mapped_depth,
6122 set_loop_mapped_depth_for_num, set_loop_mapped_depth,
6123 swap_loop_mapped_depth_for_num, get_num_from_index,
6124 swap_loop_mapped_depth, loop_iv_stack_debug,
6125 loop_iv_stack_push, loop_iv_stack_pop, loop_iv_stack_get_iv,
6126 loop_iv_stack_get_iv_from_name, loop_iv_stack_debug,
6127 get_old_iv_from_ssa_name): New.
6128 (new_scop): Initialize SCOP_LOOPS_MAPPING.
6129 (free_scop): Free SCOP_LOOPS_MAPPING.
6130 (scop_record_loop): Record old ivs.
6131 (create_var_name): Removed.
6132 (initialize_cloog_names): Allocate double space in case strip mine
6133 applies to all loops once.
6134 (clast_name_to_gcc): Look up in the map ivstack passed in parameter.
6135 (clast_to_gcc_expression): Same. Implement more clast to gimple
6137 (graphite_create_new_loop): Pass in ivstack.
6138 (remove_all_edges): Pass in the construction_edge.
6139 (graphite_remove_iv): Removed.
6140 (graphite_rename_ivs, graphite_rename_ivs_stmt,
6141 remove_cond_exprs): Rewritten.
6142 (move_phi_nodes): New.
6143 (disconnect_virtual_phi_nodes, disconnect_cond_expr): Removed.
6144 (translate_clast): Pass in ivstack. Rewrite some cases.
6145 (set_cloog_options, debug_clast_stmt): New.
6146 (find_transform): Use set_cloog_options.
6147 (outermost_loop_layer): Removed.
6148 (get_construction_edge, collect_virtual_phis, find_vdef_for_var_in_bb,
6149 find_vdef_for_var_1, find_vdef_for_var, patch_phis_for_virtual_defs,
6150 mark_old_loops, remove_dead_loops): New.
6152 (graphite_trans_bb_move_loop): Call swap_loop_mapped_depth.
6153 (const_column_index, get_first_matching_sign_row_index,
6154 get_lower_bound_row, get_upper_bound_row, get_lower_bound,
6155 get_upper_bound): New.
6156 (graphite_trans_bb_strip_mine): Also update the iv map.
6158 * graphite.h (graphite_loops_mapping, GBB_LOOPS_MAPPING): New.
6159 (struct name_tree): Add a loop field.
6160 (struct scop): Add a graphite_loops_mapping field.
6161 (SCOP_LOOPS_MAPPING): New.
6162 (debug_clast_stmt): Declare.
6163 * lambda.h (find_induction_var_from_exit_cond): Declare.
6164 (lambda-code.c): (find_induction_var_from_exit_cond): Extern.
6165 * cfgloop.h (update_dominators_in_loop): Removed declaration.
6166 (create_empty_loop_on_edge): Updated.
6167 * tree-flow.h (remove_bb, resize_phi_node, move_phi_node,
6168 rename_variables_in_bb): Declare.
6169 * tree-cfg.c (remove_bb): Extern.
6171 * gcc.dg/graphite/block-0.c: New.
6173 2008-07-21 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
6174 Sebastian Pop <sebastian.pop@amd.com>
6176 * graphite.c (strip_mine_profitable_p): New.
6177 (graphite_trans_bb_block): Disable strip mining if not profitable.
6179 * gcc.dg/graphite/scop-18.c: New.
6180 * gcc.dg/graphite/scop-17.c: Fixed.
6181 * gcc.dg/graphite/scop-16.c: Fixed.
6183 2008-07-17 Harsha Jagasia <harsha.jagasia@amd.com>
6184 Jan Sjodin <jan.sjodin@amd.com>
6185 Sebastian Pop <sebastian.pop@amd.com>
6187 * graphite.c (is_interchange_valid): New.
6188 (graphite_trans_bb_block): Check loop nest of basic block for legality
6191 * graphite.h (gbb_inner_most_loop_index, outer_most_loop_1,
6192 outer_most_loop, gbb_outer_most_loop_index): New.
6194 * tree-loop-linear.c (perfect_loop_nest_depth): Remove static.
6195 * tree-flow.h (perfect_loop_nest_depth): Declare as extern.
6196 * gcc.dg/graphite/scop-16.c: New.
6197 * gcc.dg/graphite/scop-17.c: New.
6199 2008-07-11 Tobias Grosser <grosser@fim.uni-passau.de>
6201 * graphite.c (scop_remove_ignoreable_gbbs): Also update bitmap.
6202 (graphite_trans_scop_block): Ignore SCoPs without bbs.
6204 2008-07-11 Tobias Grosser <grosser@fim.uni-passau.de>
6206 * graphite.c (new_scop): Initialize SCOP_EXIT.
6207 (scopdet_info): Add.
6208 (scopdet_bb_info): Rename from is_bb_addable. Cleanup, bugfixes.
6209 (build_scops_1): Cleanup, bugfixes.
6210 (build_scops): Cleanup.
6212 * gcc.dg/graphite/scop-matmult.c: Remove duplicated code.
6213 * gcc.dg/graphite/scop-15.c: Add SCoP numbers.
6215 2008-07-10 Harsha Jagasia <harsha.jagasia@amd.com>
6217 * gfortran.dg/graphite/scop-1.f: Update to reduced test case.
6219 * gfortran.dg/graphite/graphite.exp: Use
6220 DEFAULT_GRAPHITE_FLAGS.
6222 * gcc.dg/graphite/scop-15.c: Update to reduced test case.
6224 2008-07-10 Harsha Jagasia <harsha.jagasia@amd.com>
6226 * graphite.c (scan_tree_for_params): Do not assert any more if
6227 MULT_EXPR parameter is negative.
6229 * gfortran.dg/graphite/scop-1.f: New.
6231 * gfortran.dg/graphite/graphite.exp: New.
6233 * gcc.dg/graphite/scop-15.c: New.
6235 2008-07-10 Harsha Jagasia <harsha.jagasia@amd.com>
6237 * graphite.c (is_bb_addable): Fix segfault in spec gzip and reformat.
6239 2008-07-10 Tobias Grosser <grosser@fim.uni-passau.de>
6241 * graphite.c (graphite_trans_bb_swap_loops): Rename from
6242 graphite_swap_loops.
6243 (graphite_trans_bb_move_loop): New.
6244 (graphite_trans_bb_strip_mine): Rename from graphite_strip_mine_loop.
6245 (graphite_trans_bb_block): New.
6246 (graphite_trans_loop_block): New.
6247 (graphite_trans_scop_swap_1and2): Rename from
6248 graphite_trans_swap_1and2.
6249 (graphite_trans_scop_strip): Rename from graphite_trans_strip.
6250 (graphite_trans_scop_block): New.
6251 (graphite_apply_transformations): Rename from
6252 graphite_transformations.
6254 * gcc.dg/graphite/scop-matmult.c: New.
6256 2008-07-10 Tobias Grosser <grosser@fim.uni-passau.de>
6258 * graphite.c (gbb_compare): New.
6259 (graphite_sort_gbbs): New.
6260 (gbb_can_be_ignored): New.
6261 (scop_remove_ignoreable_gbbs): New.
6262 (graphite_transformations): Cleanup and add
6263 scop_remove_ignoreable_gbbs.
6264 * lambda.h (lambda_vector_compare): New.
6266 2008-07-09 Tobias Grosser <grosser@fim.uni-passau.de>
6268 * graphite.c (print_graphite_bb): Correct printing of static schedule.
6269 (graphite_swap_loops): int -> unsigned
6270 (graphite_strip_mine_loop): int -> unsigned, Fix SCHEDULE
6271 (graphite_transformations): New.
6272 (graphite_transform_loops): Move to graphite_transformations.
6273 * graphite.h (gbb_nb_loops): Return unsigned.
6275 2008-07-04 Tobias Grosser <grosser@fim.uni-passau.de>
6277 * graphite.c (scan_tree_for_params): Fix insertion of parameters into
6278 the domain matrix. This makes scop-0.c work again.
6280 2008-06-20 Richard Guenther <rguenther@suse.de>
6282 * graphite.h: Adjust copyright to GPLv3.
6283 * graphite.c: Likewise.
6284 (stmt_simple_memref_for_scop_p): Split out from ...
6285 (stmt_simple_for_scop_p): ... here. Fix handling of calls
6287 (get_bb_type): Optimize.
6289 (is_bb_addable): Fix memleak, replace is_pred call with
6291 (build_scops): Use current_loops.
6292 (param_index): Fix memleak.
6294 2008-06-20 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6296 * graphite.c: Fix formatting.
6298 2008-06-19 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6300 * graphite.c (new_scop): Memory allocation for SCOP_{NEWIVS, OLDIVS}.
6301 (free_scop): Memory deallocation for SCOP_NEWIVS, SCOP_OLDIVS.
6302 (create_var_name, save_var_name): Newly defined functions.
6303 (initialize_cloog_names): Part of the code factored out to
6305 (clast_to_gcc_expression): Now handles the case of clast_red_sum
6306 in clast_reduction statement.
6307 (graphite_create_new_loop): Now takes a new parameter
6309 (translate_clast): Now also takes the context_loop and bb_exit
6310 parameters. Rewritten the code so that it creates a gimple code
6311 inside the given context.
6312 (outermost_loop_layer, graphite_remove_iv, graphite_rename_ivs,
6313 remove_cond_expr, disconnect_cond_expr,
6314 disconnect_virtual_phi_nodes): Newly defined functions.
6315 * graphite.h (struct scop): added old_ivs vector.
6316 SCOP_OLDIVS: New macro.
6318 2008-06-19 Sebastian Pop <sebastian.pop@amd.com>
6320 * cfgloopmanip.c: Add missing function comments, fix formatting.
6322 2008-06-18 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6324 * cfgloopmanip.c (update_dominators_in_loop): Defined.
6325 (create_empty_loop_on_edge): Defined.
6326 * tree-parloops.c (canonicalize_loop_ivs): Returns tree
6328 * cfgloop.h (create_empty_loop_on_edge): Declared as extern.
6329 (update_dominators_in_loop): Declared as extern
6330 * tree-flow.h (canonicalize_loop_ivs): Declared as extern.
6332 2008-06-16 Tobias Grosser <grosser@fim.uni-passau.de>
6334 * graphite.c (print_graphite_bb): Allow changing number of loops
6336 (initialize_cloog_names): Allow changing number of loops.
6337 (build_cloog_prog): Simplify.
6338 (find_transform): Enable cloog option --strides.
6339 (graphite_swap_loops): New.
6340 (graphite_strip_mine_loop): New.
6341 (graphite_trans_swap_1and2): New.
6342 (graphite_trans_strip): New.
6343 (graphite_transform_loops): Add graphite_trans_strip.
6344 * graphite.h (scop_max_loop_depth): New.
6346 2008-06-15 Tobias Grosser <grosser@fim.uni-passau.de>
6348 * graphite.c (build_scop_iteration_domain): Remove forgotten
6349 line. (Fixes compile)
6351 2008-06-15 Tobias Grosser <grosser@fim.uni-passau.de>
6353 * graphite.c (print_graphite_bb): Add output of GBB_LOOPS.
6354 (build_graphite_bb): Add GBB_LOOPS and GBB_DOMAIN and reorder.
6355 (build_bb_loops): New.
6356 (graphite_transform_loops): Add build_bb_loops.
6357 (schedule_to_scattering): Use gbb_nb_loops to support changing loop
6359 * graphite.h (graphite_bb): Add loops.
6360 (gbb_nb_loops): New.
6361 (gbb_loop_at_index): New.
6362 (gbb_loop_index): New.
6363 (nb_params_in_scop): Renamed to scop_nb_params. Updated all functions
6364 using nb_params_in_scop.
6366 2008-06-14 Tobias Grosser <grosser@fim.uni-passau.de>
6368 * graphite.c (print_graphite_bb): Adapt to minimized schedule.
6369 (build_scop_canonical_schedules): Build minimized schedule.
6370 (schedule_to_scattering): Adapt to minimized schedule.
6371 * graphite.h (graphite_bb): Add/Update descriptions.
6373 2008-06-14 Adrien Eliche <aeliche@isty.uvsq.fr>
6374 Tobias Grosser <grosser@fim.uni-passau.de>
6376 * graphite.c (print_graphite_bb): Add condition printing.
6378 (dump_gbb_conditions): New.
6379 (build_scop_conditions_1): New.
6380 (build_scop_conditions): New.
6381 * graphite.h (graphite_bb): Add conditions.
6383 2008-06-14 Tobias Grosser <grosser@fim.uni-passau.de>
6385 * graphite.c (print_graphite_bb):
6386 (free_graphite_bb): New.
6387 (free_scop): Free bbs.
6388 (get_bb_type): Free doms.
6389 (build_scop_context): Free context matrix.
6390 (build_loop_iteration_domains): Remove unused code.
6391 (build_cloog_prog): Free scattering function and blocklist.
6392 (find_transform): Free options.
6394 2008-06-13 Tobias Grosser <grosser@fim.uni-passau.de>
6396 * graphite.c (loop_body_to_cloog_stmts): Rename to add_bb_domains.
6397 Remove unnecessery cloog data structures. Make a copy of the domain
6398 (setup_cloog_loop): Rename to build_loop_iteration_domains. Remove
6399 unnecessary cloog data structures. Fix memory leaks. Remove insert
6400 into SCOP_LOOP2CLOOG_LOOP as the inserted CloogLoops will never be
6402 (build_scop_iteration_domain): Remove unnecessary cloog
6403 data structures. Fix memory leaks.
6404 (graphite_transform_loops): Disable build_scop_dynamic_schedules as it
6405 uses SCOP_LOOP2CLOOG_LOOP, that is at the moment not working.
6407 2008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
6409 * graphite.c (find_scop_params): Remove initialize_cloog_names.
6411 2008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
6413 * graphite.c (end_scop): Style fix.
6414 (schedule_to_scattering): Style and comment fix.
6416 2008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
6417 * graphite.c (print_graphite_bb): Fix definiton of
6418 schedule_to_scattering.
6419 (initialize_cloog_names): Change nb_scattdims to max loop
6421 (schedule_to_scattering): Take parameter for number of scattering
6423 (build_cloog_prog): Only build as much scattering dimensions as
6426 2008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
6428 * graphite.c (end_scop): Disable bb splitting. Fixes SIGSEGV
6429 in polyhedron/aermod.f90.
6431 2008-06-11 Tobias Grosser <grosser@fim.uni-passau.de>
6432 Dwarak Rajagopal <dwarak.rajagopal@amd.com>
6433 Harsha Jagasia <harsha.jagasia@amd.com>
6435 * graphite.c (is_bb_addable): Fix segfault.
6437 2008-06-10 Tobias Grosser <grosser@fim.uni-passau.de>
6439 * graphite.c (is_bb_addable): Fix memory leak, handling of loops
6440 with multiple exits and conditional handling in edge cases.
6441 (is_loop_exit): Fix memory leak. (Forgotten in last commit)
6443 * gcc.dg/graphite/scop-14.c: New.
6445 2008-06-06 Tobias Grosser <grosser@fim.uni-passau.de>
6446 Adrien Eliche <aeliche@isty.uvsq.fr>
6448 * graphite.c (is_bb_addable): Add more comments and enhance
6449 readablity of the source code. Fix memory leak.
6450 (is_loop_exit): Fix memory leak.
6452 2008-06-05 Tobias Grosser <grosser@fim.uni-passau.de>
6454 * graphite.c (first_loop_in_scop): Deleted.
6455 (setup_cloog_loop): Only walk the loop chain for inner loops.
6456 (build_scop_iteration_domain): Execute setup_cloog_loop for
6457 all loops in the first layer.
6459 2008-06-05 Tobias Grosser <grosser@fim.uni-passau.de>
6461 * graphite.c (scan_tree_for_params): Change the way params are
6462 added to be indepenent of the number of loops.
6463 (setup_cloog_loop): Revert to short matrix format. Fix parameter
6465 (build_cloog_prog): Revert to short matrix format.
6467 2008-06-05 Sebastian Pop <sebastian.pop@amd.com>
6468 Dwarak Rajagopal <dwarak.rajagopal@amd.com>
6470 * tree-loop-fusion.c (fuse_loops): Fix uninitialized variable
6473 2008-06-05 Sebastian Pop <sebastian.pop@amd.com>
6475 * graphite.c (nb_data_refs_in_scop): New.
6476 (graphite_transform_loops): Print more stats: number of
6477 loops, basic blocks and data references per scop.
6479 2008-06-04 Sebastian Pop <sebastian.pop@amd.com>
6480 Jan Sjodin <jan.sjodin@amd.com>
6482 * graphite.c (loop_affine_expr, idx_record_params,
6483 find_scop_parameters, setup_cloog_loop): Use instantiate_scev
6484 instead of instantiate_parameters.
6486 2008-06-04 Tobias Grosser <grosser@fim.uni-passau.de>
6488 * graphite.c (schedule_to_scattering): Fix scattering dimensions,
6489 add support for parameters, add STATIC_SCHEDULE at the right places,
6492 2008-06-04 Tobias Grosser <grosser@fim.uni-passau.de>
6494 * graphite.c (build_scop_loop_nests): Only add the loops, that
6495 are contained completely in the SCoP.
6496 (build_cloog_prog): Disable scattering, until schedule_to_scattering
6497 and the domains are fixed.
6498 (build_scop_canonical_schedules): Add support for bbs not contained
6501 2008-06-04 Tobias Grosser <grosser@fim.uni-passau.de>
6503 * graphite.h (scop_contains_loop): Update comments to match
6504 the actual behavior.
6505 (scop_contains_loop): New.
6506 * graphite.c (schedule_to_scattering): Use scop_contains_loop.
6508 2008-06-04 Sebastian Pop <sebastian.pop@amd.com>
6510 * graphite.c (get_bb_type): On function body, i.e. loop_0,
6511 don't mark blocks as GBB_LOOP_SING_EXIT_HEADER, mark them
6514 2008-06-04 Sebastian Pop <sebastian.pop@amd.com>
6515 Tobias Grosser <grosser@fim.uni-passau.de>
6517 * graphite.c (graphite_transform_loops): Early return when
6518 there are no loops in the function.
6520 2008-05-31 Sebastian Pop <sebastian.pop@amd.com>
6521 Jan Sjodin <jan.sjodin@amd.com>
6523 * graphite.c (scan_tree_for_params, setup_cloog_loop): Compute the
6524 offset of the last loop.
6525 (setup_cloog_loop): Copy the entire outer constraint matrix.
6527 2008-05-31 Sebastian Pop <sebastian.pop@amd.com>
6528 Jan Sjodin <jan.sjodin@amd.com>
6530 * graphite.c (stmt_in_scop_p, function_parameter_p,
6531 invariant_in_scop_p): Removed.
6532 (scan_tree_for_params): Can be used with no constraint
6533 matrix for gathering parameters.
6534 (idx_record_params): Don't use idx_record_param, instead use
6535 scan_tree_for_params.
6536 (find_scop_parameters): Same.
6537 (setup_cloog_loop, build_scop_iteration_domain, build_cloog_prog):
6538 Fix the size of loop domains.
6539 (schedule_to_scattering): Exit when the outer loop is not in scop.
6540 (find_transform): Enable build_cloog_prog.
6542 2008-05-31 Sebastian Pop <sebastian.pop@amd.com>
6543 Jan Sjodin <jan.sjodin@amd.com>
6545 * graphite.c (schedule_to_scattering): Make scattering domains
6546 uniformly of the same size, as required by CLooG 0.14.0 and before.
6548 2008-05-31 Sebastian Pop <sebastian.pop@amd.com>
6549 Jan Sjodin <jan.sjodin@amd.com>
6551 * graphite.c (schedule_to_scattering): Rewrite, correct the
6552 translation of the scheduling function to scattering.
6553 (build_cloog_prog): Call schedule_to_scattering only once.
6554 * graphite.h (scop_loop_index): Do not fail for loops not
6555 in the scop: return -1.
6557 2008-05-30 Tobias Grosser <grosser@fim.uni-passau.de>
6559 * graphite.c (build_graphite_bb): Initialize GBB_DOMAIN.
6560 (loop_body_to_cloog_stmts): Export GBB_DOMAIN.
6561 (setup_cloog_loop): Export GBB_DOMAIN.
6562 (build_cloog_prog): New. Create new CLOOG_PROG, which should be
6563 able to rebuild the original control flow.
6564 * graphite.h (graphite_bb): Add domain field and access macro.
6567 2008-05-30 Sebastian Pop <sebastian.pop@amd.com>
6569 * graphite.c (debug_gbb): New.
6570 (print_scop, build_graphite_bb): Use SCOP_BBS.
6571 (build_scop_bbs): Reimplemented.
6572 (dfs_bb_in_scop_p): Removed.
6573 (build_scop_loop_nests): Reorder loops inserted in
6574 SCOP_LOOP_NEST: outer loops should come first.
6575 (build_scop_canonical_schedules): Reinitialize at zero
6576 the components of the SCOP_STATIC_SCHEDULE for the loops
6577 that have already been parsed.
6579 * graphite.h (debug_gbb): Declared.
6581 2008-05-30 Sebastian Pop <sebastian.pop@amd.com>
6582 Jan Sjodin <jan.sjodin@amd.com>
6584 * graphite.c (create_empty_loop): Renamed graphite_create_new_loop.
6585 (graphite_loop_to_gcc_loop): Removed.
6586 (remove_all_edges): New.
6587 (graphite_stmt_to_gcc_stmt): Renamed translate_clast.
6588 (gloog): Remove useless code.
6590 2008-05-29 Tobias Grosser <grosser@fim.uni-passau.de>
6592 * graphite.c (get_bb_type): Reworked. We distinguish between
6593 loops with one or multiple exits.
6594 (is_loop_exit): New.
6596 (is_bb_addable): Rework condition handling, now support for case
6597 case statements and loops with multiple exits.
6599 * gcc.dg/graphite/scop-11.c: New.
6600 * gcc.dg/graphite/scop-12.c: New.
6601 * gcc.dg/graphite/scop-13.c: New.
6603 2008-05-29 Tobias Grosser <grosser@fim.uni-passau.de>
6605 * graphite.c (dot_all_scops_1): Fix some colors. Reuse colors, if
6606 we have too many colors.
6608 2008-05-22 Sandeep Maram <smaram_b04@iiita.ac.in>
6610 * doc/invoke.texi (-ftree-loop-fusion): Document.
6611 * tree-pass.h (pass_loop_fusion): Declared.
6612 * tree-loop-fusion.c: New.
6613 * timevar.def (TV_TREE_LOOP_FUSION): Declared.
6614 * tree-data-ref.c (find_data_references_in_loop): Make extern.
6615 * tree-data-ref.h (find_data_references_in_loop): Declared.
6616 * common.opt (ftree-loop-fusion): Declared.
6617 * Makefile.in (tree-loop-fusion.o): Added rule and to OBJS-common.
6619 2008-05-21 Sebastian Pop <sebastian.pop@amd.com>
6621 * graphite.c (build_access_matrix): Fix typo from the merge.
6623 2008-05-20 Sebastian Pop <sebastian.pop@amd.com>
6625 * Merge from mainline (130800:135673).
6627 2008-05-07 Sebastian Pop <sebastian.pop@amd.com>
6629 * graphite.c (end_scop): The exit of the scop is not part of the scop.
6630 Update dominators after splitting.
6632 2008-05-07 Sebastian Pop <sebastian.pop@amd.com>
6634 * graphite.c (is_bb_addable): Return the harmful statement.
6635 Factor up some code.
6636 (end_scop): New. Splits end of scope bbs on a harmful statement.
6637 (build_scops_1): Call end_scop.
6639 2008-05-07 Sebastian Pop <sebastian.pop@amd.com>
6641 * graphite.c: (succs_at_same_depth, end_scop, all_preds_visited_p,
6642 all_succs_visited_p, start_new_scop_for_each_succ, start_new_scop,
6643 add_dominators_to_open_scops, stop_last_open_scop, scop_end_loop,
6644 build_scops_1): Removed.
6645 (build_scops_2): Renamed build_scops_1.
6647 2008-05-06 Sebastian Pop <sebastian.pop@amd.com>
6649 * graphite.c: Fix formatting.
6651 2008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
6653 * graphite.c (get_bb_type): New.
6655 (build_scops_2): New.
6656 (is_bb_addable): New.
6657 (build_scops): Switch the scop detection.
6658 (build_scop_bbs): Add entry bb to scop.
6659 * graphite.h (struct scop): Update comment.
6661 2008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
6663 * graphite.c (dot_all_scops_1): Fix some incorrect colors and add
6666 2008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
6668 * gcc.dg/graphite/scop-1.c: Update.
6669 * gcc.dg/graphite/scop-2.c: Update.
6670 * gcc.dg/graphite/scop-4.c: Update.
6671 * gcc.dg/graphite/scop-5.c: Add.
6672 * gcc.dg/graphite/scop-6.c: Add.
6674 2008-05-06 Sebastian Pop <sebastian.pop@amd.com>
6676 * gcc.dg/graphite/scop-0.c: Add.
6677 * gcc.dg/graphite/scop-7.c: Add.
6678 * gcc.dg/graphite/scop-8.c: Add.
6679 * gcc.dg/graphite/scop-9.c: Add.
6680 * gcc.dg/graphite/scop-10.c: Add.
6682 2008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
6684 * graphite.c (scop_affine_expr): Renamed to loop_affine_expr.
6685 Check affine expressions depending on the outermost loop
6687 (stmt_simple_for_scop_p): Same.
6688 (harmfule_stmt_in_scop): Same.
6690 2008-04-28 Tobias Grosser <grosser@fim.uni-passau.de>
6692 * graphite.c (dot_all_scops): Remove incorrect difficult bb coloring,
6693 mark entry and exit, that are not part of the SCoP and update HTML
6696 2008-04-25 Sebastian Pop <sebastian.pop@amd.com>
6698 * graphite.c (basic_block_simple_for_scop_p): Renamed
6700 (save_scop, preds_at_same_depth, test_for_scop_bound): Removed.
6701 (add_dominators_to_open_scops, build_scops_1): Reimplemented.
6702 (all_preds_visited_p, all_succs_visited_p,
6703 start_new_scop_for_each_succ, start_new_scop, stop_last_open_scop,
6704 scop_end_loop): New.
6705 (build_scops): Do not use dfs_enumerate_from.
6707 * gcc.dg/graphite/scop-{1,2,4}.c: Updated.
6709 2008-04-23 Sebastian Pop <sebastian.pop@amd.com>
6711 * graphite.c: Add comments to functions that are missing a
6713 (graphite_create_iv): Removed. Merged in graphite_loop_to_gcc_loop.
6715 2008-04-23 Sebastian Pop <sebastian.pop@amd.com>
6717 * graphite.c (nb_params_in_scop): Moved...
6718 (graphite_bb_from_bb, loop_body_to_cloog_stmts): New.
6719 (setup_cloog_loop): Call loop_body_to_cloog_stmts.
6720 (clast_to_gcc_expression): Reduce column size to less than 80.
6721 (graphite_create_iv): Return the new name of the IV.
6722 (find_transform): Set options->esp and options->cpp.
6723 (gloog): Comment out the invalidation of the old loop code.
6724 (initialize_dependence_polyhedron): Replace scop_nb_params with
6727 * graphite.h (nb_params_in_scop): ... here.
6728 (scop_nb_params): Removed.
6729 (loop_domain_dim): Return something even when the loop was not
6730 found in the hash table: avoid ICEing on all the graphite.exp
6733 2008-04-14 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6735 * tree-chrec.c (for_each_scev_op): SCEV can have 3 operands.
6737 * graphite.c (build_scop_dynamic_schedules): Schedule is built
6738 according to nesting level.
6739 (find_scop_parameters): Call instantiate_parameters.
6740 (scan_tree_for_params): Extend it to handle general affine bounds.
6741 Inner loop bound can depend on outer loop induction variable.
6742 (setup_cloog_loop): tmp variable is allocated on stack. Call
6743 instantiate_parameters with respect to outermost_loop_in_scop.
6744 (loop_domain_dim, ref_nb_loops, loop_iteration_vector_dim): moved to
6746 (create_empty_loop): Function loopify should be given edge
6747 probability, instead of edge frequency. Dominance relation from
6748 switch_bb to loop_header.
6749 (clast_to_gcc_expression): Added handling of clast_reduction node.
6750 (gloog): New functionality for removing old loop.
6751 (test_dependence): Factored out from build_rdg_all_levels.
6752 (build_rdg_all_levels): Dependence testing factored out to
6753 test_dependence function.
6755 * graphite.h (struct graphite_bb): Extended with dynamic_schedule.
6756 (loop_domain_dim, ref_nb_loops, loop_iteration_vector_dim): Moved
6759 2008-04-07 Sebastian Pop <sebastian.pop@amd.com>
6761 * graphite.c (free_scop, param_index, initialize_cloog_names,
6762 nb_params_in_scop): Use name_tree map instead of just a tree
6763 for keeping track of the variable name associated to that tree.
6764 (create_empty_loop, gmp_cst_to_tree, clast_name_to_gcc,
6765 clast_to_gcc_expression, graphite_create_iv,
6766 graphite_loop_to_gcc_loop, graphite_cond_to_gcc_cond,
6767 graphite_stmt_to_gcc_stmt): New.
6768 (gloog): Call these.
6769 * graphite.h (struct name_tree): New.
6770 (struct scop): Use name_tree instead of tree for params.
6771 Store a vector of name_tree for new_ivs.
6773 (scop_nb_params): Use name_tree instead of tree.
6775 2008-04-05 Alexander Lamaison <awl03@doc.ic.ac.uk>
6776 Sebastian Pop <sebastian.pop@amd.com>
6778 * tree-bounds.c: New.
6779 * tree-bounds.h: New.
6780 * tree-pass.h: Declare pass_bounds_early and pass_bounds_late.
6781 * passes.c: Schedule pass_bounds_early, pass_bounds_late.
6782 * builtins.c (expand_builtin_alloca): Add flag_bounds as for
6786 * c-cppbuiltin.c: Same.
6790 * tree-outof-ssa.c: Same.
6792 * Makefile.in: Same.
6794 2008-03-15 Antoniu Pop <antoniu.pop@gmail.com>
6795 Sebastian Pop <sebastian.pop@amd.com>
6797 * tree-loop-distribution.c (remaining_stmts,
6798 upstream_mem_writes): Removed static variables.
6799 (copy_loop_before, create_bb_after_loop,
6800 mark_nodes_having_upstream_mem_writes, free_rdg_components,
6801 rdg_build_components, rdg_build_partitions,
6802 dump_rdg_partitions): Extern.
6803 (generate_loops_for_partition, generate_code_for_partition): Do not
6805 (already_processed_vertex_p, predecessor_has_mem_write,
6806 mark_nodes_having_upstream_mem_writes, has_upstream_mem_writes,
6807 rdg_flag_all_uses, rdg_flag_uses, rdg_flag_vertex_and_dependent,
6808 rdg_flag_loop_exits, rdg_flag_similar_memory_accesses,
6809 build_rdg_partition_for_component, rdg_build_partitions, ldist_gen):
6810 Pass remaining_stmts and upstream_mem_writes as parameters.
6811 (rdg_component): Moved...
6812 (build_rdg_partition_for_component): Do not aggregate components when
6813 flag_streamize_loops is set.
6814 (gen_sequential_loops): New.
6815 (ldist_gen): Call gen_sequential_loops.
6817 * tree-pass.h (pass_loop_streamization): Declared.
6819 * omp-low.c (expand_omp_sections): Call add_bb_to_loop on created
6820 basic blocks when loops structures exist.
6822 * builtin-types.def (BT_FN_VOID_PTR_PTR_INT): New.
6824 * tree-ssa-loop-ivopts.c (expr_invariant_in_region_p): New.
6826 * tree-parloops.c (take_address_of, eliminate_local_variables_1,
6827 eliminate_local_variables_stmt, eliminate_local_variables,
6828 separate_decls_in_loop_name, separate_decls_in_loop_stmt,
6829 separate_decls_in_loop, gen_parallel_loop): Make them work on a region
6830 of code delimited by two edges in the CFG.
6831 (separate_decls_in_loop_name): Renamed separate_decls_in_region_name.
6832 (separate_decls_in_loop_stmt): Renamed separate_decls_in_region_stmt.
6833 (separate_decls_in_loop): Renamed separate_decls_in_region. Isolate
6834 the case of parallelisation of reductions.
6835 (create_loop_fn): Extern.
6836 (create_omp_parallel_region): New.
6838 * tree-data-ref.c (dump_data_dependence_relation): Don't call
6839 dump_data_reference for printing dra and drb.
6840 (create_rdg_edge_for_ddr, create_rdg_edges_for_scalar): Initialise
6842 (build_rdg): Don't call free_dependence_relations for the moment, as
6843 we attach dependence relations on each edge of the RDG.
6846 * tree-data-ref.h (rdg_component): ...here.
6847 (struct rdg_edge): New field ddr_p relation.
6848 (RDGE_RELATION): New.
6849 (create_bb_after_loop, copy_loop_before,
6850 mark_nodes_having_upstream_mem_writes, rdg_build_components,
6851 rdg_build_partitions, dump_rdg_partitions,
6852 free_rdg_components): Declared.
6854 * omp-builtins.def (BUILT_IN_GOMP_STREAM_ALIGN_PUSH,
6855 BUILT_IN_GOMP_STREAM_ALIGN_POP): New.
6857 * tree-loop-streamization.c: New.
6859 * tree-flow.h (gather_blocks_in_sese_region, create_loop_fn,
6860 create_omp_parallel_region, expr_invariant_in_region_p): Declared.
6862 * Makefile.in (tree-loop-streamization.o): Added to OBJS-common.
6864 * tree-cfg.c (gather_blocks_in_sese_region): Extern.
6866 * passes.c: Schedule pass_loop_streamization.
6868 2008-03-08 Tobias Grosser <grosser@fmi.uni-passau.de>
6870 * graphite.c (dot_all_scops_1): Fix formatting for difficult bbs and
6873 2008-03-07 Tobias Grosser <grosser@fim.uni-passau.de>
6875 * graphite.c (dot_all_scops): Update formatting.
6876 Bbs can now be part of more than one SCoP.
6878 2008-03-04 Sebastian Pop <sebastian.pop@amd.com>
6880 * graphite.c (new_loop_to_cloog_loop_str, setup_cloog_loop): Fix
6882 (loop_domain_dim): Check for unregistered toplev SCOP loop.
6883 * graphite.h (loop_to_cloog_loop): New.
6885 2008-03-04 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6887 * graphite.c (loop_domain_dim, ref_nb_loops,
6888 loop_iteration_vector_dim): New.
6889 (build_access_matrix_with_af, build_access_matrix,
6890 initialize_dependence_polyhedron): Fixed for new matrix layout.
6891 No longer assume that all iteration domains are of the same
6894 2008-03-02 Sebastian Pop <sebastian.pop@amd.com>
6896 * tree-scalar-evolution.c (instantiate_parameters_1): An SSA_NAME
6897 defined in a loop at depth 0 is invariant.
6898 * tree-chrec.c (evolution_function_is_invariant_rec_p): Ditto.
6899 * tree-ssa-loop-ivopts.c (expr_invariant_in_loop_p): Should never
6900 be called at loop depth 0.
6902 * graphite.c (basic_block_simple_for_scop_p): Take the scop as
6904 (dot_all_scops_1): Update use of basic_block_simple_for_scop_p.
6905 (down_open_scop): Removed.
6906 (loop_in_scop_p): Redefined.
6907 (scop_affine_expr): New argument: scop.
6908 (stmt_simple_for_scop_p): New argument: scop. RETURN_EXPR is not
6909 a harmful statement ending a scop.
6910 (basic_block_simple_for_scop_p): New argument: scop.
6911 (get_loop_start): Removed.
6912 (new_scop): Initialize SCOP_LOOPS.
6913 (free_scop): Free SCOP_LOOPS.
6914 (succs_at_same_depth, preds_at_same_depth): New.
6915 (end_scop): Test the validity of a scop.
6916 (add_dominators_to_open_scops): New.
6917 (test_for_scop_bound): Call add_dominators_to_open_scops.
6918 Add cases for opening and closing multiple scops.
6919 (build_scops, build_scop_bbs): Iterate over basic blocks in
6921 (build_graphite_bb): Pass scop directly.
6922 (dfs_bb_in_scop_p): New.
6923 (scop_record_loop): Use SCOP_LOOPS for not recording the same loop
6925 (nb_loops_around_gb): Use loop_in_scop_p.
6926 (schedule_to_scattering): Disabled for the moment the code computing
6927 the "textual order for outer loop".
6929 * graphite.h (struct scop): New field loops.
6931 (scop_loop_index): Test that the given loop belongs to SCOP_LOOPS.
6933 * gcc.dg/graphite/scop-{1,...,7}.c: Updated.
6935 2008-02-27 Antoniu Pop <antoniu.pop@gmail.com>
6936 Sebastian Pop <sebastian.pop@amd.com>
6938 * builtin-types.def (BT_FN_PTR_SIZE_UINT, BT_FN_BOOL_PTR): New.
6939 * common.opt (fstreamize-loops): New.
6940 * omp-builtins.def (BUILT_IN_GOMP_STREAM_CREATE,
6941 BUILT_IN_GOMP_STREAM_PUSH, BUILT_IN_GOMP_STREAM_HEAD,
6942 BUILT_IN_GOMP_STREAM_POP, BUILT_IN_GOMP_STREAM_EOS_P,
6943 BUILT_IN_GOMP_STREAM_SET_EOS, BUILT_IN_GOMP_STREAM_DESTROY): New.
6945 2008-02-22 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6947 * tree-data-ref.c (build_empty_rdg): New.
6948 (build_rdg): Use it.
6949 * tree-data-ref.h (build_empty_rdg): Declared.
6950 * graphite.c (free_scop): Free SCOP_LOOP2CLOOG_LOOP.
6951 (find_vertex_for_stmt): Removed.
6952 (build_rdg_all_levels): Use build_empty_rdg and rdg_vertex_for_stmt.
6954 2008-02-21 Sebastian Pop <sebastian.pop@amd.com>
6956 * tree-loop-distribution.c (generate_builtin): After cancelling the
6957 loop tree, also delete basic blocks.
6958 (rdg_flag_uses): Stop recursion when a vertex has already been
6961 2008-02-15 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6963 * graphite.c (build_scop_alpha): Removed.
6964 (graphite_transform_loops): Add a dummy call to build_all_rdg_levels
6965 and dump_dependence_graph to avoid compiler warnings.
6967 2008-02-14 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6969 * tree-data-ref.c (dr_may_alias_p, create_rdg_vertices): Extern.
6970 * tree-data-ref.h (dr_may_alias_p, create_rdg_vertices): Declared.
6971 * graphite.c (new_loop_to_cloog_loop_str, hash_loop_to_cloog_loop,
6972 eq_loop_to_cloog_loop, del_loop_to_cloog_loop): New.
6973 (new_scop, setup_cloog_loop): Initialize SCOP_LOOP2CLOOG_LOOP.
6974 (initialize_dependence_polyhedron, find_vertex_for_stmt,
6975 initialize_data_dependence_polyhedron, is_empty_polyhedron,
6976 statement_precedes_p, build_rdg_all_levels, build_scop_alpha,
6977 dump_dependence_graph): New.
6978 * graphite.h (struct graphite_bb): New field compressed_alpha_matrix.
6980 (struct scop): New field loop2cloog_loop.
6981 (SCOP_LOOP2CLOOG_LOOP, struct data_dependence_polyhedron,
6982 RDGE_DDP, ddp_p, struct loop_to_cloog_loop_str): New.
6984 2008-02-10 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6986 * graphite.c (build_graphite_bb): Fix initialization
6987 of the graphite basic block.
6989 2008-02-05 Sebastian Pop <sebastian.pop@amd.com>
6991 * graphite.c (scan_tree_for_params): Rewrite for the new layout of
6992 loop domain matrix. Pass in the number of loops contained in the
6994 (nb_loops_around_gb): Moved before setup_cloog_loop that uses it.
6995 (setup_cloog_loop): Rewrite for the new layout of loop domain matrix:
6996 loops that are not surrounding the current loop are not represented
6997 in the domain constraint matrix.
6998 (build_scop_iteration_domain): Initial domain constraint matrix
6999 contains only the eq/ineq, cst, and scop parameters columns.
7001 2008-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
7003 * graphite.c (schedule_to_scattering, nb_loops_around_gb): New.
7004 (print_graphite_bb): Print scattering.
7006 2008-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
7008 * graphite.c (initialize_cloog_names): Initialize names of
7009 scattering variables.
7011 2009-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
7013 * graphite.c (dot_all_scops_1): Disable debug output while
7016 2008-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
7018 * graphite.c (find_transform): Change cloog output language to C.
7020 2008-01-27 Sebastian Pop <sebastian.pop@amd.com>
7022 * tree-loop-distribution.c (generate_memset_zero,
7023 generate_builtin, generate_code_for_partition,
7024 rdg_flag_all_uses): New.
7025 (rdg_flag_uses): Gather in the same partition the statements defining
7026 the VUSES of the current statement.
7027 (rdg_flag_similar_stores): Renamed rdg_flag_similar_memory_accesses.
7028 Gather in the same partition not only the stores to the same memory
7029 access, but also the reads.
7030 (ldist_generate_loops): Renamed ldist_gen.
7032 2008-01-24 Sebastian Pop <sebastian.pop@amd.com>
7033 Tobias Grosser <grosser@fmi.uni-passau.de>
7035 * graphite.c (setup_cloog_loop): Chain all cloog loops with the
7036 next pointer, don't use the inner pointer.
7038 2008-01-20 Tobias Grosser <grosser@fmi.uni-passau.de>
7040 * graphite.c (dot_all_scops, dot_all_scops_1): New.
7041 (find_transform): Call dot_all_1.
7042 * graphite.h (dot_all_scops): Declared.
7044 2007-12-14 Sebastian Pop <sebastian.pop@amd.com>
7046 * tree-loop-distribution.c: Fix apsi.f ICE.
7047 (create_bb_after_loop): New.
7048 (generate_loops_for_partition): Use it.
7049 * gfortran.dg/ldist-1.f90: New.
7051 * tree-data-ref.c (dot_rdg): Use /tmp/rdg.dot for dotty format.
7052 * graphite.c (dot_scop): Use /tmp/scop.dot for dotty format.
7054 2007-12-13 Tobias Grosser <grosser@fmi.uni-passau.de>
7056 * graphite.c (find_transform): Dump cloog program sent to cloog.
7058 2007-12-13 Tobias Grosser <grosser@fmi.uni-passau.de>
7060 * graphite.c (initialize_cloog_names): Initialize cloog
7063 2007-12-13 Tobias Grosser <grosser@fmi.uni-passau.de>
7065 * graphite.c (build_scop_context): Fix typo, for the matrix
7066 format: insert '0 >= 0' instead of '-1 >= 0'.
7068 2007-12-13 Sebastian Pop <sebastian.pop@amd.com>
7070 * Fix merge problems.
7072 2007-12-13 Sebastian Pop <sebastian.pop@amd.com>
7074 * graphite.c (setup_cloog_loop): Fix typo.
7076 2007-12-12 Sebastian Pop <sebastian.pop@amd.com>
7078 * doc/invoke.texi (-ftree-loop-distribution): Documented.
7079 * tree-loop-distribution.c: Reimplemented.
7080 * tree-pass.h (pass_loop_distribution): New.
7081 * tree-scalar-evolution.c (number_of_iterations_for_all_loops): Use
7083 * graphds.h (struct graph): New field indexes.
7084 * timevar.def (TV_TREE_LOOP_DISTRIBUTION): New.
7086 * tree-vect-analyze.c: Remove declaration of static functions when not
7088 * tree-vectorizer.c: Same.
7089 (rename_variables_in_loop): Now extern.
7090 (slpeel_tree_duplicate_loop_to_edge_cfg): Renamed
7091 tree_duplicate_loop_to_edge_cfg. Reset PENDING_STMT for edges after
7092 calling redirect_edge_and_branch_force.
7094 * tree-vectorizer.h (tree_duplicate_loop_on_edge): Declared.
7096 * tree-data-ref.c: Don't include tree-chrec.h.
7097 (debug_data_dependence_relations): New.
7098 (dump_data_dependence_relation): Call dump_data_reference on data refs
7100 (same_access_functions): Moved...
7101 (find_vertex_for_stmt): Renamed rdg_vertex_for_stmt.
7102 (dump_rdg_vertex, debug_rdg_vertex, dump_rdg_component,
7103 debug_rdg_component, dump_rdg, debug_rdg, dot_rdg_1, dot_rdg,
7104 struct rdg_vertex_info, ): New.
7105 (create_rdg_edge_for_ddr): Compute the dependence level before looking
7107 (create_rdg_vertices): Initialize the htab of graph->indexes.
7108 Initialize RDG_MEM_WRITE_STMT and RDG_MEM_READS_STMT.
7109 (stmts_from_loop): Don't save LABEL_EXPR.
7110 (hash_stmt_vertex_info, eq_stmt_vertex_info,
7111 hash_stmt_vertex_del): New.
7112 (build_rdg): Initialize rdg->indexes.
7113 (free_rdg, stores_from_loop, ref_base_address,
7114 rdg_defs_used_in_other_loops_p, have_similar_memory_accesses,
7115 have_similar_memory_accesses_1, ref_base_address_1,
7116 remove_similar_memory_refs): New.
7118 * tree-data-ref.h: Include tree-chrec.h.
7119 (debug_data_dependence_relations): Declared.
7120 (same_access_functions): ...here. Now static inline.
7121 (ddr_is_anti_dependent, ddrs_have_anti_deps,
7122 ddr_dependence_level): New.
7123 (struct rdg_vertex): New fields has_mem_write, has_mem_reads.
7124 (RDGV_HAS_MEM_WRITE, RDGV_HAS_MEM_READS, RDG_STMT, RDG_MEM_WRITE_STMT,
7125 RDG_MEM_READS_STMT): New.
7126 (dump_rdg_vertex, debug_rdg_vertex, dump_rdg_component,
7127 debug_rdg_component, dump_rdg, debug_rdg, dot_rdg,
7128 rdg_vertex_for_stmt): Declared.
7129 (struct rdg_edge): New field level.
7130 (RDGE_LEVEL, free_rdg): New.
7131 (stores_from_loop, remove_similar_memory_refs,
7132 rdg_defs_used_in_other_loops_p,
7133 have_similar_memory_accesses): Declared.
7134 (rdg_has_similar_memory_accesses): New.
7136 * lambda.h (dependence_level): New.
7137 * common.opt (ftree-loop-distribution): New.
7138 * tree-flow.h (debug_loop_ir): Renamed debug_loops.
7139 (print_loop_ir): Renamed print_loops.
7140 (debug_loop, debug_loop_num, print_loops_bb, mark_virtual_ops_in_bb,
7141 tree_duplicate_loop_to_edge_cfg, rename_variables_in_loop): Declared.
7142 * Makefile.in (TREE_DATA_REF_H): Depends on tree-chrec.h.
7143 (tree-loop-distribution.o): Added.
7144 * tree-cfg.c (mark_virtual_ops_in_region): Use mark_virtual_ops_in_bb.
7145 (mark_virtual_ops_in_bb): New.
7146 (print_loops_bb, debug_loop_num, debug_loop): New.
7147 * passes.c: Scheduled pass_loop_distribution.
7149 2007-12-12 Konrad Trifunovic <konrad.trifunovic@inria.fr>
7151 * graphite.c (scan_tree_for_params): Correct the number of columns
7153 (nb_flat_iterator): New.
7154 (setup_cloog_loop): Initialize to 1 the first column for inequalities.
7155 (build_scop_iteration_domain): Correct the number of columns for
7158 2007-12-12 Sebastian Pop <sebastian.pop@amd.com>
7160 * Merge from mainline (129697:130800).
7162 2007-10-30 Sebastian Pop <sebastian.pop@amd.com>
7164 * graphite.c (build_graphite_bb): SCoP's basic blocks are post
7165 dominated by SCoP's exit.
7166 (graphite_transform_loops): Compute post dominators.
7168 2007-10-28 Sebastian Pop <sebastian.pop@amd.com>
7170 * Merge from mainline (127169:129697).
7172 2007-10-28 Sebastian Pop <sebastian.pop@amd.com>
7174 * graphite.c (affine_expr): Renamed scop_affine_expr. Use an extra
7175 parameter for the basic block that contains the expression. Use
7176 outermost_loop_in_scop for evolution_function_is_affine_multivariate_p.
7177 (stmt_simple_for_scop_p): Pass to scop_affine_expr the basic block of
7179 * graphite.h (gbb_loop): New.
7180 (GBB_LOOP): Removed.
7182 2007-08-03 Sebastian Pop <sebpop@gmail.com>
7184 * Makefile.in: Fix merge problem.
7186 2007-08-03 Sebastian Pop <sebpop@gmail.com>
7188 * Merge from mainline (125309:127169).
7189 * tree-loop-distribution.c: Disabled.
7191 2007-06-05 Sebastian Pop <sebpop@gmail.com>
7193 * Merge from mainline (r123693:125309).
7195 2007-05-30 Sebastian Pop <sebpop@gmail.com>
7197 * tree-loop-distribution.c (correct_modify_expr_p): Renamed
7199 (correct_modify_p, check_statements, number_of_lvalue_uses,
7200 number_of_scalar_dependences, create_edges): Use GIMPLE_MODIFY_STMT
7201 instead of MODIFY_EXPR.
7202 (update_edge_with_ddv): Don't pass index_of_edge. Initialize
7205 2007-05-24 Sebastian Pop <sebpop@gmail.com>
7207 * tree-loop-distribution.c (struct rdg): Replace arrays by
7208 VECs for edges and vertices.
7209 (RDG_NBV, RDG_NBE, RDG_VERTEX, RDG_EDGE): Removed.
7210 (RDGV_NB_PARTITIONS): New.
7211 (PRDG_NBV, PRDG_NBE): Removed.
7212 (build_scc_graph, correct_partitions_p, mark_partitions, build_prdg,
7213 dump_rdg, find_vertex_with_stmt, create_vertices, free_rdg,
7214 number_of_scalar_dependences, create_edges, build_rdg): Use VECs.
7216 2007-05-17 Georges-Andre Silber <silber@cri.ensmp.fr>
7217 Sebastian Pop <sebpop@gmail.com>
7219 * doc/invoke.texi (-ftree-loop-distribution): Document.
7220 * tree-loop-distribution.c: New file.
7221 * tree-pass.h (pass_loop_distribution): Declared.
7222 * timevar.def (TV_TREE_LOOP_DISTRIBUTION): New.
7223 * tree-data-ref.c (initialize_data_dependence_relation): Initialize
7225 * tree-data-ref.h (data_dependence_relation): Add reversed_p.
7226 (DDR_REVERSED_P): New.
7227 * common.opt (-ftree-loop-distribution): New.
7228 * tree-flow.h (distribute_loops): Declared.
7229 * Makefile.in (OBJS-common): Depend on tree-loop-distribution.o.
7230 * passes.c (init_optimization_passes): Schedule loop distribution.
7232 2007-05-12 Sebastian Pop <sebastian.pop@inria.fr>
7234 * graphite.c (print_graphite_bb): Don't call dump_data_references.
7235 (print_scop): Don't print when scop is NULL.
7236 (build_scop_context, find_transform): Don't output to stderr.
7238 2007-05-09 Sebastian Pop <sebastian.pop@inria.fr>
7240 * tree-data-ref.c: Don't include graphite.h.
7241 Comment out the code for printing data reference's scop.
7242 (build_access_matrix_with_af): Moved...
7243 * tree-data-ref.h (build_access_matrix_with_af): Removed declaration.
7244 * graphite.c (build_access_matrix_with_af): ... here. Now static.
7245 (print_graphite_bb): Print basic block's schedule.
7246 (print_scop): Don't print the schedule, call cloog's pretty printer.
7247 (bb_in_scop_p): A basic block is in a scop only if it is both
7248 dominated and postdominated by the scop's entry and exit basic blocks.
7249 (function_parameter_p): New.
7250 (invariant_in_scop_p): Use function_parameter_p.
7251 (new_scop, save_scop): New.
7252 (end_scop, test_for_scop_bound, build_scops): Use new_scop, and
7254 (scan_tree_for_params): Directly build the constraint as CloogMatrix.
7255 (loop_in_scop_p): New.
7256 (scop_record_loop): Use loop_in_scop_p.
7257 (build_scop_domain): Renamed build_scop_iteration_domain.
7258 (setup_cloog_loop, initialize_cloog_names, find_scop_parameters,
7259 nb_params_in_scop, build_scop_context, first_loop_in_scop,
7260 setup_cloog_loop, dot_scop_1, dot_scop): New.
7261 * graphite.h (GBB_LOOP, SCOP_PROG, dot_scop): New.
7262 (struct scop): Add a pointer to cloog's representation of a program.
7264 2007-04-14 Sebastian Pop <sebastian.pop@inria.fr>
7266 * doc/invoke.texi (-ftree-check-verbose): Renamed
7267 -ftree-checks-verbose.
7268 * common.opt (flag_tree_check_verbose): Renamed
7269 flag_tree_checks_verbose.
7270 * tree-check.c (tree_check_warning): Use flag_tree_checks_verbose.
7272 2007-04-14 Sebastian Pop <sebastian.pop@inria.fr>
7274 * configure: Regenerated.
7275 * config.in: Regenerated.
7276 * tree-ssa-loop.c (graphite_transforms): Execute
7277 graphite_transform_loops only when HAVE_cloog.
7278 * configure.ac (HAVE_polylib, HAVE_cloog, GRAPHITE): Defined.
7279 * graphite.c: Include polylibgmp.h and cloog.h.
7280 (graphite_transform_loops): Removed loops parameter.
7281 * tree-flow.h (graphite_transform_loops): Update declaration.
7282 * Makefile.in (POLYLIBLIBS, POLYLIBINC, CLOOGLIBS, CLOOGINC): New.
7283 (LIBS): Depend on CLOOGLIBS and on POLYLIBLIBS.
7284 (INCLUDES): Depend on POLYLIBINC and on CLOOGINC.
7285 (OBJS-common): Remove dependence on graphite.o.
7286 (BACKEND): Depend on @GRAPHITE@.
7288 2007-04-13 Sebastian Pop <sebastian.pop@inria.fr>
7290 * doc/invoke.texi (-ftree-check-verbose): Documented.
7291 * gcc.dg/tree-checker/tree-checks-1.c: New.
7292 * gcc.dg/tree-checker/tree-checks-2.c: New.
7293 * gcc.dg/tree-checker/tree-checks-3.c: New.
7294 * gcc.dg/tree-checker/tree-checks-4.c: New.
7295 * gcc.dg/tree-checker/tree-checks.exp: New.
7296 * gcc.dg/tree-checker/condates.crp: New.
7297 * common.opt (ftree-checks-verbose): New.
7298 * tree-check.c (tree_check_warning): Move extra stderr output
7299 under control of flag_tree_check_verbose.
7301 2007-04-12 Sebastian Pop <sebastian.pop@inria.fr>
7303 * tree-match.c: Fix comments formatting.
7304 * tree-match.h: Fix comments formatting.
7305 * tree-check.c: Fix comments formatting.
7306 (tree_check_init): Restructure.
7308 2007-04-12 Nic Volanschi <nic.volanschi@free.fr>
7310 * doc/invoke.texi (-ftree-check, -ftree-checks): Documented.
7312 2007-04-10 Sebastian Pop <sebastian.pop@inria.fr>
7314 * Merge from mainline (r120733:123693).
7316 2007-03-20 Nic Volanschi <nic.volanschi@free.fr>
7318 * condate.y: New file.
7319 * tree-match.h (struct patt_info_s): New field sign.
7320 (struct condate_s): New field msg.
7321 (normalize_condate, name_condate, add_condate): New.
7322 (conds[], condate_parse): Made extern.
7323 * tree-check.c (tree_check_warning): First arg changed to cond;
7324 warning reformatted.
7325 (tree_check_init): Reset the TREE_VISITED bit on every CFG node.
7327 (tree_check): Process trivial condates.
7328 (read_delimited_string): Removed.
7329 (print_cond): Print name and msg.
7330 (conds[]): Made extern.
7331 (parse_tree_check_file_once): Rewritten to use the parser in
7333 Processing of option --tree_check_string moved to tree_scan().
7334 * Makefile.in: Added condate.y
7336 2007-03-12 Sebastian Pop <sebastian.pop@inria.fr>
7338 * tree-pretty-print.c (dump_generic_bb_buff, lazy_dump_generic_node):
7339 Use VECs instead of varrays.
7340 * diagnostic.h (lazy_dump_generic_node): Update declaration.
7341 * Makefile.in (pretty-print.o): Depend on vec.h.
7342 * pretty-print.c: Include tree.h and vec.h.
7343 (pp_clear_state, pp_write_list_to_stream, pp_base_format,
7344 pp_base_format, pp_construct, pp_base_string, pp_lazy_mode,
7345 new_tree_chunk, pp_add_tree, pp_add_string, pp_add_char, pp_write_list,
7346 pp_free_list): Use VECs instead of varrays.
7347 * pretty-print.h: Do not include varray.h.
7348 (struct tree_chunk_s): Declaration moved before its use.
7349 (output_buffer): Rename varray field to chunks.
7350 * tree-match.c (tree_equal, chunk_1st_char, chunks_lookahead,
7351 tree_1st_char, match_chunks_pattinfo, match_tree_pattinfo,
7352 save_global_holes): Use VECs instead of varrays.
7353 * tree-match.h: Declare VECs of cfg_node, and hole_p.
7354 * tree-check.c (scan_cfg_stmts, push_node,
7355 print_matching_stmt): Removed.
7356 (tree_check_instance, push_global_holes_if_new, tree_check,
7357 execute_tree_check): Use VECs instead of varrays.
7358 (gate_tree_check): Don't execute the CFG check when basic_block_info
7361 2007-01-12 Sebastian Pop <sebastian.pop@inria.fr>
7363 * Merge from mainline (r115016:120733).
7365 2007-01-12 Sebastian Pop <sebastian.pop@inria.fr>
7367 * Merge from mainline (r117632:117661).
7369 2007-01-12 Sebastian Pop <sebastian.pop@inria.fr>
7371 * tree-dump.c (dump_option_value_in): Add TDF_DEBUG.
7372 * tree-pass.h (TDF_DEBUG, debug_p): New.
7373 * tree-scalar-evolution.c (set_scalar_evolution, get_scalar_evolution,
7374 get_scalar_evolution, add_to_evolution, set_nb_iterations_in_loop,
7375 get_loop_exit_condition, analyze_evolution_in_loop,
7376 analyze_initial_condition, analyze_scalar_evolution,
7377 instantiate_parameters, number_of_latch_executions): Use debug_p.
7378 * tree-chrec.c (chrec_apply): Use debug_p.
7379 * tree-data-ref.c: Include graphite.h.
7380 (dump_data_reference): Print also the access matrix.
7381 (analyze_array, analyze_indirect_ref, init_data_ref,
7382 analyze_offset_expr, address_analysis, object_analysis,
7383 create_data_ref, finalize_ddr_dependent,
7384 non_affine_dependence_relation, analyze_ziv_subscript,
7385 analyze_siv_subscript_cst_affine,
7386 compute_overlap_steps_for_affine_1_2, analyze_subscript_affine_affine,
7387 can_use_analyze_subscript_affine_affine, analyze_siv_subscript,
7388 analyze_miv_subscript, analyze_overlapping_iterations,
7389 build_classic_dist_vector, subscript_dependence_tester,
7390 compute_affine_dependence, analyze_all_data_dependences): Use debug_p.
7391 (build_access_matrix_with_af): No longer static.
7392 * tree-data-ref.h (scop_p): ... declaration here.
7393 (data_reference.scop): New field.
7394 (DR_SCOP, DR_ACCESS_MATRIX): New.
7395 (build_access_matrix_with_af, dr_num_subscripts): Declared.
7396 * graphite.c (print_graphite_bb): Call dump_data_references.
7397 (print_scop): Use scop_nb_loops and scop_dim_domain.
7398 (test_for_scop_bound): Use debug_p.
7399 (scan_tree_for_params): Use scop_nb_loops, scop_nb_loops and
7401 (scop_loop_index): Moved...
7402 (scop_record_loop): New.
7403 (build_scop_loop_nests): Use scop_record_loop.
7404 (build_scop_domain): Use scop_dim_domain.
7405 (build_access_matrix): Implemented.
7406 (build_scop_canonical_schedules): Use scop_nb_loops.
7407 (build_graphite_bb): Initialize GBB_SCOP.
7408 * graphite.h (scop_p): Moved...
7409 (graphite_bb.scop): New field.
7410 (graphite_bb.iteration_domain, GBB_DOMAIN, scop.nb_params,
7411 scop.nb_loops, scop.dim_domain, SCOP_NB_LOOPS, SCOP_NB_PARAMS,
7412 SCOP_DIM_DOMAIN, SCOP_STMTS): Removed.
7413 (scop_nb_params, scop_nb_loops, scop_dim_domain, gbb_dim_domain,
7414 scop_loop_index): New.
7415 * Makefile.in (tree-data-ref.o): Depends on graphite.h.
7417 2007-01-05 Sebastian Pop <sebastian.pop@inria.fr>
7419 * Merge from mainline (r117661:120450).
7421 2006-10-12 Sebastian Pop <sebastian.pop@inria.fr>
7423 * tree-scalar-evolution.c (instantiate_parameters_1): Don't stop
7424 at the first declaration outside the varying loop, instantiate as
7426 * tree-chrec.c (for_each_scev_op): New.
7427 * tree-chrec.h (for_each_scev_op): Declared.
7428 * tree-ssa-loop.c (pass_graphite_trans): Don't dump the function.
7429 * tree-data-ref.c (get_references_in_stmt,
7430 find_data_references_in_stmt): New, from trunk.
7431 (find_data_references_in_loop): Use get_references_in_stmt
7432 and find_data_references_in_loop, modified as in trunk.
7433 (build_access_matrix_with_af): New.
7434 * tree-data-ref.h (data_reference): Add a field access_matrix.
7435 (data_ref_loc): New, as in trunk.
7436 * graphite.c (print_graphite_bb, bb_in_scop_p, stmt_in_scop_p,
7437 invariant_in_scop_p, param_index, scan_tree_for_params,
7438 scop_loop_index, build_scop_loop_nests, build_scop_domain, irp_data,
7439 idx_record_param, idx_record_params, build_access_matrix,
7440 build_scop_data_accesses, build_scop_canonical_schedules,
7441 build_graphite_bb, build_scop_bbs, find_params_in_bb,
7442 build_scop_params): New.
7443 * graphite.h (graphite_bb): New.
7444 (scop): Add fields static_schedule, params, loop_nest,
7446 * lambda.h: Declare vecs of lambda_matrix.
7447 * tree-flow.h (print_loop_ir_bb): Declared.
7448 * tree-cfg.c (print_loop_ir_bb): New.
7449 (print_loop): Use print_loop_ir_bb.
7451 2006-10-12 Sebastian Pop <pop@cri.ensmp.fr>
7453 * Merge from mainline (r115016:117632).
7455 2006-10-11 Sebastian Pop <pop@cri.ensmp.fr>
7457 * graphite.c (debug_scops): Adjust definition for avoiding a bootstrap
7458 break due to a warning.
7460 2006-10-10 Sebastian Pop <pop@cri.ensmp.fr>
7462 * graphite.c (print_scops, debug_scops): New.
7463 (graphite_transform): Renamed graphite_find_transform.
7464 * graphite.h (debug_scops): Declared.
7466 2006-08-17 Sebastian Pop <pop@cri.ensmp.fr>
7468 * tree-match.c: Reformat following the GNU style.
7469 * tree-match.h: Reformat following the GNU style.
7470 * tree-pattern.h: Removed empty file.
7471 * Makefile.in: Remove references to tree-pattern.h.
7472 * tree-check.c: Reformat following the GNU style.
7473 (execute_tree_check): Move gate condition code to...
7474 (gate_tree_check): ...here. New function.
7475 (pass_check): Use the gate function.
7477 2006-07-04 Nic Volanschi <nic.volanschi@free.fr>
7479 * tree-pattern.h: New. Tree pattern matching and checking using
7481 * tree-check.c: New. Tree/CFG checking pass.
7482 * tree-match.c: New. Library for tree pattern matching.
7483 * opts.c, common.opt: Add options --ftree-check & --ftree-checks.
7484 * toplev.c, flags.h: Add globals for tree-check pass.
7485 * Makefile.in: Integrate the files in tree-check pass.
7486 * timevar.def, tree-optimize.c, tree-pass.h: Register tree-check pass.
7487 * pretty-print.c, pretty-print.h, tree-pretty-print.c, diagnostic.h:
7488 Introduce a "lazy" pretty-print mode.
7489 * tree.c, tree.h: Add tree_name.
7491 2006-07-04 Sebastian Pop <pop@cri.ensmp.fr>
7493 * doc/invoke.texi (-fgraphite): Correct typo.
7494 * tree-scalar-evolution.c (number_of_iterations_for_all_loops): Update
7495 use of print_loop_ir.
7496 * gcc.dg/graphite/scop-1.c: New.
7497 * gcc.dg/graphite/scop-2.c: New.
7498 * gcc.dg/graphite/graphite.exp: New.
7499 * graphite.c: Include domwalk.h.
7500 (print_scop): Print only the entry and exit blocks.
7501 (debug_scop): No longer static.
7502 (affine_expr): Fix formating. Return also true when the expression is
7504 (stmt_simple_for_scop_p): Fix formating.
7505 (build_scops): Use domwalk.
7506 (get_loop_start, end_scop, test_for_scop_bound): New.
7507 (graphite_transform_loops): Avoid printing on stderr.
7508 * graphite.h (debug_scop): Declared.
7509 * tree-flow.h (debug_loop_ir, print_loop_ir): Update declarations.
7510 * Makefile.in (graphite.o): Depend on domwalk.h.
7511 * tree-cfg.c (print_loop, print_pred_bbs, print_succ_bbs): Remove
7512 declarations for static functions.
7513 (print_loop, print_loop_ir, debug_loop_ir): Use an extra parameter for
7514 controlling output verbosity.
7516 2006-06-26 Sebastian Pop <pop@cri.ensmp.fr>
7517 Plesco Alexandru <shurikx@gmail.com>
7519 * doc/invoke.texi (-fgraphite): Document.
7520 * tree-pass.h (pass_graphite_transforms): Declared.
7521 * timevar.def (TV_GRAPHITE_TRANSFORMS): New.
7522 * tree-ssa-loop.c (graphite_transforms, gate_graphite_transforms): New.
7523 (pass_graphite_transforms): Defined.
7524 * tree-data-ref.c (free_data_ref, data_reference): Extern.
7525 * tree-data-ref.h (free_data_ref, data_reference): Declared.
7526 * graphite.c, graphite.h: New.
7527 * common.opt (fgraphite): Declared.
7528 * tree-flow.h (graphite_transform_loops): Declared.
7529 * Makefile.in (OBJS-common): Add graphite.o.
7530 (graphite.o): New rule.
7531 * passes.c (pass_graphite_transforms): Scheduled.