OSDN Git Service

Add pass_copy_prop after Graphite.
[pf3gnuchains/gcc-fork.git] / gcc / ChangeLog.graphite
1 2010-03-16  Sebastian Pop  <sebastian.pop@amd.com>
2
3         * passes.c (init_optimization_passes): Add pass_copy_prop
4         after Graphite.
5
6 2010-03-16  Sebastian Pop  <sebastian.pop@amd.com>
7
8         * graphite-poly.c (print_scattering_function): Pretty print following
9         the scoplib format.
10         (print_pdr): Same.
11         (print_pbb_domain): Same.
12         (dump_gbb_cases): Same.
13         (dump_gbb_conditions): Same.
14         (print_pdrs): Same.
15         (print_pbb): Same.
16         (print_scop_params): Same.
17         (print_scop_context): Same.
18         (print_scop): Same.
19         (print_pbb_body): New.
20         (lst_indent_to): New.
21         (print_lst): Start new lines with a #.
22         * graphite-poly.h (pbb_bb): New.
23         (pbb_index): Use pbb_bb.
24         * graphite-ppl.c (ppl_print_powerset_matrix): Print the number of
25         disjuncts.
26         * tree-data-ref.c (dump_data_reference): Start new lines with a #.
27
28 2010-03-13  Sebastian Pop  <sebastian.pop@amd.com>
29
30         PR middle-end/43351
31         * gcc.dg/graphite/id-pr43351.c
32
33 2010-03-13  Sebastian Pop  <sebastian.pop@amd.com>
34
35         PR middle-end/43354
36         * graphite-sese-to-poly.c (rewrite_close_phi_out_of_ssa): Do not
37         call insert_out_of_ssa_copy for default definitions.
38         * gfortran.dg/graphite/id-pr43354.f: New.
39
40 2010-03-13  Sebastian Pop  <sebastian.pop@amd.com>
41
42         PR middle-end/43349
43         * gfortran.dg/graphite/pr43349.f: New.
44
45 2010-03-11  Sebastian Pop  <sebastian.pop@amd.com>
46
47         * graphite-clast-to-gimple.c (my_long_long): Defined.
48         (gcc_type_for_cloog_iv): Use it instead of long_long_integer_type_node.
49         * graphite-sese-to-poly.c (my_long_long): Defined.
50         (scop_ivs_can_be_represented): Use it.
51
52 2010-03-10  Sebastian Pop  <sebastian.pop@amd.com>
53
54         * doc/invoke.texi: Fix documentation of graphite-max-nb-scop-params,
55         graphite-max-bbs-per-function, and loop-block-tile-size.
56         * params.def (PARAM_GRAPHITE_MAX_NB_SCOP_PARAMS): Replace "maximal"
57         with "maximum".
58         (PARAM_GRAPHITE_MAX_BBS_PER_FUNCTION): Same.
59
60 2010-03-10  Sebastian Pop  <sebastian.pop@amd.com>
61
62         * graphite-clast-to-gimple.c (gcc_type_for_iv_of_clast_loop): Remove
63         forward declaration.
64         * graphite-sese-to-poly.c (reduction_phi_p): Remove FIXME comment.
65         (add_upper_bounds_from_estimated_nit): New.
66         (build_loop_iteration_domains): Use it.
67
68 2010-03-09  Sebastian Pop  <sebastian.pop@amd.com>
69
70         * doc/invoke.texi (PARAM_LOOP_BLOCK_TILE_SIZE): Document.
71
72 2010-03-09  Sebastian Pop  <sebastian.pop@amd.com>
73
74         PR middle-end/43306
75         * tree-chrec.c (evolution_function_right_is_integer_cst): CHREC_RIGHT
76         should be an INTEGER_CST.  Also handle CASE_CONVERT.
77         * gcc.dg/graphite/pr43306.c: New.
78
79 2010-03-09  Sebastian Pop  <sebastian.pop@amd.com>
80
81         * graphite.c (graphite_initialize): To bound the number of bbs per
82         function, use PARAM_GRAPHITE_MAX_BBS_PER_FUNCTION.
83         * params.def (PARAM_GRAPHITE_MAX_BBS_PER_FUNCTION): Declared.
84         * doc/invoke.texi: Document it.
85
86 2010-03-09  Sebastian Pop  <sebastian.pop@amd.com>
87
88         * graphite-sese-to-poly.c (build_poly_scop): Do not return bool.
89         * graphite-sese-to-poly.h (build_poly_scop): Same.
90
91 2010-03-09  Sebastian Pop  <sebastian.pop@amd.com>
92
93         * graphite-sese-to-poly.c (build_poly_scop): Limit scops following
94         the number of parameters in the scop.  Use as an upper bound
95         PARAM_GRAPHITE_MAX_NB_SCOP_PARAMS.
96         * params.def (PARAM_GRAPHITE_MAX_NB_SCOP_PARAMS): Declared.
97         * doc/invoke.texi: Document it.
98
99 2010-03-05  Sebastian Pop  <sebastian.pop@amd.com>
100
101         * graphite-sese-to-poly.c (add_param_constraints): Use
102         lower_bound_in_type and upper_bound_in_type.
103
104 2010-03-05  Sebastian Pop  <sebastian.pop@amd.com>
105
106         * graphite-sese-to-poly.c (add_param_constraints): Use sizetype
107         instead of unsigned_type_node.
108
109 2010-03-05  Sebastian Pop  <sebastian.pop@amd.com>
110             Reza Yazdani  <reza.yazdani@amd.com>
111
112         PR middle-end/43065
113         * graphite-sese-to-poly.c (add_param_constraints): Insert bounds
114         on pointer type parameters.
115
116         * gcc.dg/graphite/run-id-4.c: New.
117
118 2010-03-05  Sebastian Pop  <sebastian.pop@amd.com>
119
120         PR middle-end/43065
121         * gcc.dg/graphite/run-id-3.c: New.
122
123 2010-03-05  Tobias Grosser  <grosser@fim.uni-passau.de>
124             Ramakrishna Upadrasta <Ramakrishna.Upadrasta@inria.fr>
125
126         * graphite-clast-to-gimple.c (clast_to_gcc_expression): Also
127         handle conversions from pointer to integers.
128         (gcc_type_for_cloog_iv): Choose the smalles signed integer as an
129         induction variable, to be able to work with code generated by CLooG.
130         * graphite-sese-to-poly.c (scop_ivs_can_be_represented): New.
131         (build_poly_scop): Bail out if we cannot codegen a loop.
132
133 2010-03-04  Tobias Grosser  <grosser@fim.uni-passau.de>
134
135         * graphite-clast-to-gimple.c (translate_clast): Do not short-cut
136         code generation with gloog_error.
137
138 2010-03-04  Sebastian Pop  <sebastian.pop@amd.com>
139
140         * sese.c (expand_scalar_variables_ssa_name): Add new argument for type.
141         Call fold_convert on all the returned values.
142         (expand_scalar_variables_expr): Pass to expand_scalar_variables_ssa_name
143         the type of the resulting expression.
144
145 2010-03-04  Sebastian Pop  <sebastian.pop@amd.com>
146
147         * graphite-ppl.c (ppl_min_for_le_polyhedron): Renamed
148         ppl_min_for_le_pointset.  Use ppl_Pointset_Powerset_C_Polyhedron_minimize.
149         * graphite-ppl.h (ppl_min_for_le_polyhedron): Update declaration.
150
151 2010-03-04  Sebastian Pop  <sebastian.pop@amd.com>
152
153         * graphite-dependences.c (map_into_dep_poly): Removed.
154         (dependence_polyhedron_1): Use combine_context_id_scat.
155
156 2010-03-04  Sebastian Pop  <sebastian.pop@amd.com>
157
158         * graphite-poly.h (struct poly_scattering): Add layout documentation.
159         (struct poly_bb): Same.
160         (combine_context_id_scat): New.
161
162 2010-03-02  Sebastian Pop  <sebastian.pop@amd.com>
163
164         PR middle-end/42326
165         * sese.c (name_defined_in_loop_p): Return false for default
166         definitions.
167
168         * gcc.dg/graphite/pr42326.c: New.
169
170 2010-02-23  Sebastian Pop  <sebastian.pop@amd.com>
171
172         * graphite-clast-to-gimple.c (find_cloog_iv_in_expr): Simplify
173         and clean up the logic.
174
175 2010-02-23  Sebastian Pop  <sebastian.pop@amd.com>
176
177         * graphite-sese-to-poly.c (add_param_constraints): Enabled: remove
178         early return.
179
180 2010-02-22  Sebastian Pop  <sebastian.pop@amd.com>
181
182         PR middle-end/43083
183         * graphite-scop-detection.c (create_single_exit_edge): Move
184         the call to find_single_exit_edge to....
185         (create_sese_edges): ...here.  Don't handle multiple edges
186         exiting the function.
187         (build_graphite_scops): Don't handle multiple edges
188         exiting the function.
189
190         * gcc.dg/graphite/pr43083.c: New.
191
192 2010-02-22  Sebastian Pop  <sebastian.pop@amd.com>
193
194         PR middle-end/43097
195         * sese.c (get_rename): Assert that old_name is an SSA_NAME.
196         (rename_variables_in_stmt): Continue when the use is not an SSA_NAME.
197
198         * gfortran.dg/graphite/pr43097.f: New.
199
200 2010-02-22  Sebastian Pop  <sebastian.pop@amd.com>
201             Manuel López-Ibáñez  <manu@gcc.gnu.org>
202
203         PR middle-end/43140
204         * g++.dg/graphite/pr41305.C: Add -Wno-conversion-null.
205
206 2010-02-22  Sebastian Pop  <sebastian.pop@amd.com>
207
208         PR middle-end/43026
209         * sese.c (expand_scalar_variables_expr): Handle COMPONENT_REF.
210
211         * g++.dg/graphite/pr43026.C: New.
212
213 2010-02-13  Tobias Grosser  <grosser@fim.uni-passau.de>
214
215         * Merge from mainline (154736:156693).
216
217 2010-02-11  Sebastian Pop  <sebastian.pop@amd.com>
218
219         PR middle-end/43012
220         * gcc.dg/graphite/pr43012.c: New.
221
222 2010-02-10  Sebastian Pop  <sebastian.pop@amd.com>
223
224         * graphite.c (graphite_transform_loops): Re-enable dbg_cnt.
225 2010-02-10  Sebastian Pop  <sebastian.pop@amd.com>
226
227         * g++.dg/graphite/pr42930.C: New.
228
229 2010-02-10  Sebastian Pop  <sebastian.pop@amd.com>
230
231         PR middle-end/42930
232         * graphite-scop-detection.c (graphite_can_represent_scev): Call
233         graphite_can_represent_init for MULT_EXPR.
234
235 2010-02-10  Sebastian Pop  <sebastian.pop@amd.com>
236
237         PR middle-end/42914
238         PR middle-end/42530
239         * graphite-sese-to-poly.c (remove_phi): New.
240         (translate_scalar_reduction_to_array): Call remove_phi.
241
242         * gcc.dg/graphite/pr42530.c: New.
243         * gcc.dg/graphite/pr42914.c: New.
244
245 2010-02-10  Sebastian Pop  <sebastian.pop@amd.com>
246
247         PR middle-end/42771
248         * graphite-clast-to-gimple.c (gloog): Call rename_sese_parameters.
249         * graphite-clast-to-gimple.h (gloog): Update declaration.
250         * graphite-poly.c (new_scop): Clear POLY_SCOP_P.
251         * graphite-poly.h (struct poly_bb): Add missing comments.
252         (struct scop): Add poly_scop_p field.
253         (POLY_SCOP_P): New.
254         * graphite-sese-to-poly.c (build_poly_scop): Set POLY_SCOP_P.
255         * graphite.c (graphite_transform_loops): Build the polyhedral
256         representation for each scop before code generation.
257         * sese.c (rename_variables_in_operand): Removed.
258         (rename_variables_in_expr): Return the renamed expression.
259         (rename_sese_parameters): New.
260         * sese.h (rename_sese_parameters): Declared.
261
262         * gcc.dg/graphite/pr42771.c: New.
263
264 2010-02-07  Sebastian Pop  <sebastian.pop@amd.com>
265
266         * gcc.dg/graphite/block-0.c: Call abort for runtime test.  Always
267         return 0 from main.
268         * gcc.dg/graphite/block-1.c: Same.
269         * gcc.dg/graphite/block-3.c: Same.
270         * gcc.dg/graphite/block-4.c: Same.
271         * gcc.dg/graphite/block-5.c: Same.
272         * gcc.dg/graphite/block-6.c: Same.
273         * gcc.dg/graphite/block-7.c: Same.
274         * gcc.dg/graphite/interchange-0.c: Same.
275         * gcc.dg/graphite/interchange-1.c: Same.
276         * gcc.dg/graphite/interchange-10.c: Same.
277         * gcc.dg/graphite/interchange-11.c: Same.
278         * gcc.dg/graphite/interchange-12.c: Same.
279         * gcc.dg/graphite/interchange-2.c: Same.
280         * gcc.dg/graphite/interchange-3.c: Same.
281         * gcc.dg/graphite/interchange-4.c: Same.
282         * gcc.dg/graphite/interchange-5.c: Same.
283         * gcc.dg/graphite/interchange-6.c: Same.
284         * gcc.dg/graphite/interchange-7.c: Same.
285         * gcc.dg/graphite/interchange-8.c: Same.
286         * gcc.dg/graphite/interchange-9.c: Same.
287         * gcc.dg/graphite/interchange-mvt.c: Same.
288
289 2010-02-07  Sebastian Pop  <sebastian.pop@amd.com>
290
291         * gfortran.dg/graphite/id-19.f: New.
292         * gfortran.dg/graphite/pr14741.f90: New.
293         * gfortran.dg/graphite/pr41924.f90: New.
294         * gfortran.dg/graphite/run-id-2.f90: New.
295
296 2010-02-07  Sebastian Pop  <sebastian.pop@amd.com>
297
298         PR middle-end/42988
299         * graphite-dependences.c (dependence_polyhedron): Set PDDR_KIND
300         to unknown_dependence.
301         (graphite_legal_transform_dr): Handle the unknown_dependence.
302         (graphite_carried_dependence_level_k): Same.
303
304 2010-02-07  Sebastian Pop  <sebastian.pop@amd.com>
305
306         * ChangeLog.graphite: Remove testsuite/ or gcc/testsuite/.
307
308 2010-02-05  Sebastian Pop  <sebastian.pop@amd.com>
309             Konrad Trifunovic  <konrad.trifunovic@inria.fr>
310
311         PR middle-end/42637
312         * graphite-dependences.c (build_lexicographical_constraint): Return
313         a union of dependence polyhedra.
314         (dependence_polyhedron_1): Adapt for build_lexicographical_constraint.
315
316         * gcc.dg/graphite/block-0.c: Enable runtime check.  XFAILed.
317         * gcc.dg/graphite/block-4.c: Same.
318         * gcc.dg/graphite/block-7.c: Same.
319         * gcc.dg/graphite/interchange-12.c: Same.
320         * gcc.dg/graphite/interchange-mvt.c: Same.
321         * gfortran.dg/graphite/interchange-1.f: XFAILed.
322         * gfortran.dg/graphite/interchange-3.f90: XFAILed.
323         * gfortran.dg/graphite/run-id-1.f: New testcase for PR42637.
324
325 2010-02-03  Sebastian Pop  <sebastian.pop@amd.com>
326
327         * gcc.dg/graphite/interchange-12.c: Return 0 to avoid
328         the execution check to FAIL.  This testcase is miscompiled by Graphite
329         and the check should be re-enabled.
330         * gcc.dg/graphite/interchange-mvt.c: Same.
331         * gcc.dg/graphite/block-0.c: Same.
332         * gcc.dg/graphite/block-4.c: Same.
333         * gcc.dg/graphite/block-7.c: Same.
334
335 2010-02-03  Sebastian Pop  <sebastian.pop@amd.com>
336
337         * gcc.dg/graphite/interchange-mvt.c: Un-XFAILed.
338         * gcc.dg/graphite/scop-0.c: Fix spaces.
339         * gfortran.dg/graphite/block-1.f90: Rewrite expected output.
340         * gfortran.dg/graphite/block-2.f: Same.
341         * gfortran.dg/graphite/block-3.f90: Same.
342         * gfortran.dg/graphite/block-4.f90: Same.
343         * gfortran.dg/graphite/interchange-1.f: Un-XFAILed.
344         * gfortran.dg/graphite/interchange-3.f90: Un-XFAILed.
345
346 2010-02-03  Sebastian Pop  <sebastian.pop@amd.com>
347
348         * graphite-dependences.c (new_poly_ddr): Initialize PDDR_KIND and
349         PDDR_ORIGINAL_SCATTERING_P.
350         (pddr_is_empty): Rewritten.
351         (print_dependence_polyhedron_layout): New.
352         (print_pddr): New.
353         (debug_pddr): New.
354         (build_alias_set_powerset): Moved up.
355         (poly_drs_may_alias_p): Moved up.
356         (lexicographically_gt_p): Removed.
357         (build_lexicographically_gt_constraint): Renamed
358         build_lexicographical_constraint, reimplemented.
359         (dependence_polyhedron_1): Simplified parameters.
360         (dependence_polyhedron): Same.  Keep along empty PDDRs
361         to make efficient use of the cache.
362         (reduction_dr_p): Compute the PBBs don't pass them as parameters.
363         (graphite_legal_transform_dr): Rewritten.
364         (graphite_legal_transform_bb): Pass fewer arguments to
365         graphite_legal_transform_dr.
366         (graphite_carried_dependence_level_k): Simplified implementation.
367         (dot_original_deps_stmt_1): Call dependence_polyhedron.
368         (dot_transformed_deps_stmt_1): Same.
369         (dot_original_deps): Same.
370         (dot_transformed_deps): Same.
371         * graphite-dependences.h (struct poly_ddr): Added a new field
372         original_scattering_p.
373         (PDDR_ORIGINAL_SCATTERING_P): New.
374         (print_pddr): Declared.
375         (debug_pddr): Declared.
376         * graphite-ppl.c: Clarify comment.
377         * sese.h (print_gimple_bb): Removed unused declaration.
378         (debug_gbb): Same.
379
380 2010-02-03  Sebastian Pop  <sebastian.pop@amd.com>
381
382         * g++.dg/graphite/graphite.exp: Rewritten.
383         * gcc.dg/graphite/graphite.exp: Rewritten.
384         * gfortran.dg/graphite/graphite.exp: Rewritten.
385         * gcc.dg/graphite/block-0.c: Added runtime test.
386         * gcc.dg/graphite/block-1.c: Same.
387         * gcc.dg/graphite/block-3.c: Same.
388         * gcc.dg/graphite/block-4.c: Same.
389         * gcc.dg/graphite/block-5.c: Same.
390         * gcc.dg/graphite/block-6.c: Same.
391         * gcc.dg/graphite/block-7.c: Same.
392         * gcc.dg/graphite/interchange-0.c: Same.
393         * gcc.dg/graphite/interchange-1.c: Same.
394         * gcc.dg/graphite/interchange-10.c: Same.
395         * gcc.dg/graphite/interchange-11.c: Same.
396         * gcc.dg/graphite/interchange-12.c: Same.
397         * gcc.dg/graphite/interchange-2.c: Same.
398         * gcc.dg/graphite/interchange-3.c: Same.
399         * gcc.dg/graphite/interchange-4.c: Same.
400         * gcc.dg/graphite/interchange-5.c: Same.
401         * gcc.dg/graphite/interchange-6.c: Same.
402         * gcc.dg/graphite/interchange-7.c: Same.
403         * gcc.dg/graphite/interchange-8.c: Same.
404         * gcc.dg/graphite/interchange-9.c: Same.
405         * gcc.dg/graphite/interchange-mvt.c: Same.
406         * gcc.dg/graphite/run-id-2.c: Remove useless dg-do run.
407
408 2010-01-22  Ramakrishna Upadrasta <Ramakrishna.Upadrasta@inria.fr>
409
410         * graphite-scop-detection.c (dot_all_scops): Make calls to dot run in
411           background.
412
413 2010-01-22  Ramakrishna Upadrasta <Ramakrishna.Upadrasta@inria.fr>
414
415         * common.opt: Add -fgraphite-cloog-opts.
416         * graphite-clast-to-gimple.c (set_cloog_options): Same.
417         * opts.c (decode_options): Same.
418
419 2010-01-20  Sebastian Pop  <sebastian.pop@amd.com>
420
421         * gcc.dg/graphite/id-17.c: New.
422         * gcc.dg/graphite/pr41888.c: New.
423         * gcc.dg/graphite/scop-22.c: New.
424         * gfortran.dg/graphite/pr40982.f90: New.
425
426 2010-01-20  Sebastian Pop  <sebastian.pop@amd.com>
427
428         * graphite-dependences.c: Clarify comments.
429         (build_pddr): Add an extra parameter direction.
430         (graphite_legal_transform_dr): Use build_pddr.
431         (dot_original_deps_stmt_1): Update use of build_pddr.
432         (dot_transformed_deps_stmt_1): Same.
433         (dot_original_deps): Same.
434         (dot_transformed_deps): Same.
435
436         * gcc.dg/graphite/interchange-12.c: New.
437         * gcc.dg/graphite/block-7.c: New.
438
439 2010-01-20  Sebastian Pop  <sebastian.pop@amd.com>
440
441         * graphite-dependences.c (pddr_original_scattering): Renamed build_pddr.
442         (pddr_transformed_scattering): Removed.
443         (graphite_legal_transform_dr): Use build_pddr.
444         (dot_original_deps_stmt_1): Same.
445         (dot_transformed_deps_stmt_1): Same.
446         (dot_original_deps): Same.
447         (dot_transformed_deps): Same.
448
449 2010-01-20  Sebastian Pop  <sebastian.pop@amd.com>
450
451         * graphite-dependences.c (lexicographically_gt_p): Add comments.
452         (build_lexicographically_gt_constraint): Same.
453         (dependence_polyhedron_1): Same.
454         (dependence_polyhedron): Same.
455
456 2010-01-20  Sebastian Pop  <sebastian.pop@amd.com>
457
458         * graphite-dependences.c (build_pairwise_scheduling_equality): Removed.
459         (build_pairwise_scheduling_inequality): Renamed build_pairwise_scheduling.
460         (lexicographically_gt_p): Change type of direction to int.
461         (build_lexicographically_gt_constraint): Same.
462         (dependence_polyhedron_1): Same.
463         (dependence_polyhedron): Same.
464         (pddr_original_scattering): Use integers for direction.
465         (pddr_transformed_scattering): Same.
466         (graphite_legal_transform_dr): Same.
467         (graphite_carried_dependence_level_k): Same.
468
469 2010-01-20  Sebastian Pop  <sebastian.pop@amd.com>
470
471         * graphite-dependences.c (build_pairwise_constraint): Renamed
472         ppl_build_relation.  Moved...
473         (dr_equality_constraints): Use ppl_build_relation.
474         (build_pairwise_scheduling_equality): Same.
475         (build_pairwise_scheduling_inequality): Same.
476         * graphite-ppl.c (ppl_build_relation): ...here.
477         * graphite-ppl.h (ppl_build_relation): Declared.
478
479 2010-01-14  Sebastian Pop  <sebastian.pop@amd.com>
480
481         PR middle-end/42681
482         * graphite-clast-to-gimple.c (gloog_error): New static variable.
483         (clast_to_gcc_expression): Do not build MULT_EXPR of POINTER_TYPE_P.
484         Set gloog_error when such an expression failed to be built.
485         (translate_clast): Early return when gloog_error is set.
486         (gloog): Clear gloog_error.  When gloog_error is set, call
487         set_ifsese_condition to enable the original code.  Return the status
488         of the code generation based on gloog_error.
489         * sese.c (set_ifsese_condition): New.
490         * sese.h (set_ifsese_condition): Declared.
491
492         * g++.dg/graphite/pr42681.C: New.
493
494 2010-01-14  Sebastian Pop  <sebastian.pop@amd.com>
495
496         PR middle-end/42732
497         * graphite-clast-to-gimple.c (gloog): Call scev_reset_htab and
498         rename_nb_iterations.
499         * sese.c (rename_variables_in_operand): New.
500         (rename_variables_in_expr): New.
501         (rename_nb_iterations): New.
502         (sese_adjust_liveout_phis): Update the rename_map.
503         * sese.h (rename_nb_iterations): Declared.
504         * tree-scalar-evolution.c (scev_reset_htab): New.
505         (scev_reset): Call scev_reset_htab.
506         * tree-scalar-evolution.h (scev_reset_htab): Declared.
507
508         * gfortran.dg/graphite/pr42732.f: New.
509
510 2010-01-08  Sebastian Pop  <sebastian.pop@amd.com>
511
512         PR middle-end/42393
513         * graphite-clast-to-gimple.c: Fix formatting.
514         * sese.c (defined_in_loop_p): Renamed name_defined_in_loop_p.
515         (expr_defined_in_loop_p): New.
516         (add_loop_exit_phis): Also handle full expressions: remove from
517         the rename_map the expressions defined in the loop that we're closing.
518
519         * gfortran.dg/graphite/pr42393-1.f90: New.
520         * gfortran.dg/graphite/pr42393.f90: Add new flags
521         -fno-loop-block -fno-loop-interchange -fno-loop-strip-mine to also
522         make this testcase useful in the Graphite branch.
523
524 2010-01-08  Sebastian Pop  <sebastian.pop@amd.com>
525
526         * graphite-scop-detection.c (exclude_component_ref): Removed.
527         (is_simple_operand): Removed.
528         (stmt_simple_for_scop_p): Remove use of is_simple_operand.
529
530 2010-01-07  Sebastian Pop  <sebastian.pop@amd.com>
531
532         PR middle-end/42221
533         * sese.c (expand_scalar_variables_expr): Follow the SSA links into
534         the array indexing of ADDR_EXPRs.
535
536         * gcc.dg/graphite/pr42221.c: New.
537
538 2010-01-07  Sebastian Pop  <sebastian.pop@amd.com>
539
540         PR middle-end/42521
541         * graphite.c (graphite_finalize): Call scev_reset.
542         (graphite_transform_loops): Do not call scev_reset between the code
543         generation of scops.
544
545         * gcc.dg/graphite/pr42521.c: New.
546
547 2010-01-07  Sebastian Pop  <sebastian.pop@amd.com>
548
549         * graphite-interchange.c (memory_stride_in_loop): Renamed
550         pdr_stride_in_loop.
551         (memory_strides_in_loop): Renamed memory_strides_in_loop_1.
552         (memory_strides_in_loop): Memoize the memory strides per loop.
553         (lst_interchange_profitable_p): Do not initialize to zero the memory
554         strides.
555         * graphite-poly.h (struct lst): Add a field memory_strides.
556         (LST_LOOP_MEMORY_STRIDES): New.
557         (new_lst_loop): Initialize LST_LOOP_MEMORY_STRIDES to -1.
558         (free_lst): Clear LST_LOOP_MEMORY_STRIDES.
559
560 2010-01-07  Sebastian Pop  <sebastian.pop@amd.com>
561
562         * graphite-interchange.c (memory_strides_in_loop_depth): Renamed
563         memory_strides_in_loop.  Gather memory strides on a whole loop.
564         (pbb_interchange_profitable_p): Renamed lst_interchange_profitable_p.
565         (lst_interchange_profitable_p): Removed.
566         (lst_try_interchange_loops): Call lst_interchange_profitable_p.
567
568 2010-01-07  Sebastian Pop  <sebastian.pop@amd.com>
569
570         Revert patch 2009-11-23  Tobias Grosser  <grosser@fim.uni-passau.de>
571         * graphite-clast-to-gimple.c (try_mark_loop_parallel): New.
572         (translate_clast_for, translate_clast_guard, translate_clast, gloog):
573         Remove context_loop and level.
574
575 2010-01-07  Richard Guenther  <rguenther@suse.de>
576
577         PR tree-optimization/42641
578         * sese.c (rename_map_elt_info): Use the SSA name version, do
579         not hash pointers.
580
581 2010-01-06  Sebastian Pop  <sebastian.pop@amd.com>
582
583         * graphite-blocking.c (scop_do_block): Print "SCoP will be loop
584         blocked" only when both the strip mine and the interchange have
585         been applied.
586
587         * gcc.dg/graphite/block-2.c: Removed.
588         * gcc.dg/graphite/block-3.c: Add scan pattern.
589         * gcc.dg/graphite/block-4.c: Same.
590         * gcc.dg/graphite/block-5.c: Same.
591         * gcc.dg/graphite/block-6.c: Same.
592
593 2010-01-06  Sebastian Pop  <sebastian.pop@amd.com>
594
595         * graphite-clast-to-gimple.c (save_clast_name_index): Free slot
596         before allocating a new one.
597         (copy_renames): Check that slot is not NULL.
598         (mark_bb_with_pbb): Same.
599         (compute_cloog_iv_types_1): Same.
600         * graphite-interchange.c (lst_perfect_nestify): Free the before,
601         nest, and after LSTs.
602         (lst_try_interchange_loops): Same.
603
604 2010-01-05  Sebastian Pop  <sebastian.pop@amd.com>
605
606         PR middle-end/42178
607         * graphite-interchange.c (lst_try_interchange_loops): Do not return
608         the before, nest, and after LSTs.
609         (lst_try_interchange): Removed.
610         (lst_interchange_select_inner): Do not iterate over the LSTs if they
611         were modified.
612         (lst_interchange_select_outer): Apply interchange on the outer loop
613         until there are no more changes in the inner loops.
614
615 2009-12-18  Sebastian Pop  <sebastian.pop@amd.com>
616
617         Revert patch fixing PR middle-end/42221.
618
619 2009-12-18  Sebastian Pop  <sebastian.pop@amd.com>
620
621         PR middle-end/42180
622         * graphite-sese-to-poly.c (follow_ssa_with_commutative_ops): Handle
623         GIMPLE_CALL.
624
625         * gfortran.dg/graphite/pr42180.f90: Add compile flags.
626
627 2009-12-18  Sebastian Pop  <sebastian.pop@amd.com>
628
629         PR middle-end/42180
630         * graphite-sese-to-poly.c (split_reduction_stmt): Do not split blocks
631         that contain only one statement.
632
633         * gfortran.dg/graphite/pr42180.f90: New.
634
635 2009-12-17  Sebastian Pop  <sebastian.pop@amd.com>
636
637         PR middle-end/42393
638         * gfortran.dg/graphite/pr42393.f90: New.
639
640 2009-12-17  Sebastian Pop  <sebastian.pop@amd.com>
641
642         PR middle-end/42186
643         * gfortran.dg/graphite/pr42186.f90: New.
644
645 2009-12-17  Sebastian Pop  <sebastian.pop@amd.com>
646
647         PR middle-end/42205
648         * graphite-sese-to-poly.c (translate_scalar_reduction_to_array_for_stmt):
649         Insert the reduction copy in the same block as the phi node.
650         (follow_ssa_with_commutative_ops): Handle GIMPLE_NOPs.
651
652         * gcc.dg/graphite/pr42205-1.c: New.
653         * gcc.dg/graphite/pr42205-2.c: New.
654
655 2009-12-17  Sebastian Pop  <sebastian.pop@amd.com>
656
657         PR middle-end/42221
658         * sese.c (expand_scalar_variables_expr): Follow the SSA links into
659         the array indexing of ADDR_EXPRs.
660
661         * gcc.dg/graphite/pr42221.c: New.
662
663 2009-12-17  Sebastian Pop  <sebastian.pop@amd.com>
664
665         PR middle-end/42178
666         PR middle-end/42334
667         * graphite-interchange.c (lst_try_interchange): Do not modify OUTER
668         index.  Call lst_interchange_select_inner only once.
669         (lst_interchange_select_inner): Update use of lst_try_interchange.
670         (lst_interchange_select_outer): Update.
671
672 2009-12-15  Sebastian Pop  <sebastian.pop@amd.com>
673
674         PR middle-end/42178
675         PR middle-end/42334
676         * graphite-interchange.c (lst_try_interchange): Do not increment the
677         the OUTER index when there is no AFTER kernel.  Do not increment the
678         OUTER index for after processing the AFTER kernel.
679         (lst_interchange_select_inner): Call lst_try_interchange only on loops.
680         (lst_interchange_select_outer): Do not pass in a pointer to the OUTER
681         index.  Do not pass to lst_interchange_select_inner the OUTER index.
682         (scop_do_interchange): Update use of lst_interchange_select_outer.
683
684         * gfortran.dg/graphite/graphite.exp
685         (DEFAULT_FLAGS_GRAPHITE_IDENTITY): Remove -fdump-tree-graphite-all.
686         * gfortran.dg/graphite/interchange-1.f: Add comment.  Clean
687         the graphite dump file.
688         * gfortran.dg/graphite/interchange-2.f: Same.
689         * gfortran.dg/graphite/pr42334-1.f: New.
690
691 2009-12-15  Sebastian Pop  <sebastian.pop@amd.com>
692
693         PR middle-end/42178
694         PR middle-end/42334
695         * graphite-interchange.c (lst_perfect_nestify): Reset to NULL the LSTs
696         that are empty.
697         (lst_do_interchange_1): Renamed lst_interchange_select_inner.
698         (lst_try_interchange): Reimplemented.
699         (lst_interchange_select_inner): Same.
700         (lst_do_interchange): Renamed lst_interchange_select_outer.
701         Reimplemented.
702         (scop_do_interchange): Update use of lst_interchange_select_outer.
703
704         * g++.dg/graphite/pr42130.C: Add -fgraphite-identity.
705         * gcc.dg/graphite/block-0.c: Un-XFAILed.
706         * gcc.dg/graphite/pr42211.c: New.
707         * gfortran.dg/graphite/pr42334.f90: New.
708
709 2009-12-14  Sebastian Pop  <sebastian.pop@amd.com>
710
711         PR middle-end/42181
712         * graphite-scop-detection.c (graphite_can_represent_scev): Handle more
713         carefully PLUS_EXPR, MINUS_EXPR, and MULT_EXPR.
714
715         * gfortran.dg/graphite/pr42181.f90: New.
716
717 2009-12-12  Sebastian Pop  <sebpop@gmail.com>
718
719         PR middle-end/42284
720         * graphite-sese-to-poly.c (rewrite_close_phi_out_of_ssa): Call
721         insert_out_of_ssa_copy_on_edge for anything else than SSA_NAMEs.
722         (detect_commutative_reduction_arg): Simplified.
723         (detect_commutative_reduction): Early return when the argument of
724         the close phi is not of an SSA_NAME.
725
726         * gcc.dg/graphite/pr42284.c: New.
727
728 2009-12-11  Alexander Monakov  <amonakov@ispras.ru>
729
730         * dbgcnt.def (graphite_scop): New counter.
731         * graphite.c: Include dbgcnt.h
732         (graphite_transform_loops): Use new counter to limit transformations.
733
734 2009-12-08  Sebastian Pop  <sebpop@gmail.com>
735
736         PR middle-end/42285
737         * graphite-scop-detection.c (graphite_can_represent_init): Also
738         handle more complex MULT_EXPRs containing parameters by recursion
739         on the structure.
740
741         * gfortran.dg/graphite/pr42285.f90: New.
742
743 2009-12-01  Tobias Grosser  <grosser@fim.uni-passau.de>
744
745         * g++.dg/graphite/pr42130.C: Fix type.
746
747 2009-11-29  Alexander Monakov <amonakov@gcc.gnu.org>
748
749         * g++.dg/graphite/pr42130.C: Correct testcase.
750
751 2009-11-28 Tobias Grosser  <grosser@fim.uni-passau.de>
752
753         * Merge from mainline (154493:154734).
754
755 2009-11-28 Tobias Grosser  <grosser@fim.uni-passau.de>
756
757         * Merge from mainline (151362:154491).
758
759 2009-11-24  Tobias Grosser  <grosser@fim.uni-passau.de>
760
761         * graphite-clast-to-gimple.c (try_mark_loop_parallel,
762         graphite_create_new_loop_guard, translate_clast_for): Fix comments.
763
764 2009-11-23  Tobias Grosser  <grosser@fim.uni-passau.de>
765
766         PR middle-end/42130
767         * graphite-clast-to-gimple.c (graphite_create_new_loop_guard,
768         translate_clast_for_loop): New.
769         (translate_clast_for): Add a condition around the loop, to do not
770         execute loops with zero iterations.
771         * g++.dg/graphite/pr42130.C: New.
772         * gcc.dg/graphite/pr35356-2.c: Adapt.
773
774 2009-11-23  Tobias Grosser  <grosser@fim.uni-passau.de>
775
776         * graphite-clast-to-gimple.c (try_mark_loop_parallel): New.
777         (translate_clast_for, translate_clast_guard, translate_clast, gloog):
778         Remove context_loop and level.
779
780 2009-11-23  Tobias Grosser  <grosser@fim.uni-passau.de>
781
782         * graphite-clast-to-gimple.c (translate_clast_user,
783         translate_clast_for, translate_clast_guard): Simplify and move common
784         elements to translate_clast().
785         (translate_clast): Simplify and get common elements.
786
787 2009-11-23  Tobias Grosser  <grosser@fim.uni-passau.de>
788
789         * graphite-clast-to-gimple.c (translate_clast_user,
790         translate_clast_for, translate_clast_guard): Split out of
791         translate_clast.
792
793 2009-11-21  Tobias Grosser  <grosser@fim.uni-passau.de>
794
795         * graphite-clast-to-gimple.c (clast_name_index, new_clast_name_index,
796         clast_name_to_index, save_clast_name_index, debug_clast_name_index,
797         debug_clast_name_indexes_1, debug_clast_name_indexes,
798         clast_name_index_elt_info, eq_clast_name_indexes): Moved from sese.h.
799         (clast_name_to_gcc, clast_to_gcc_expression,
800         clast_to_gcc_expression_red, gcc_type_for_clast_expr,
801         gcc_type_for_clast_eq, graphite_translate_clast_equation,
802         graphite_create_guard_cond_expr, graphite_create_new_loop,
803         translate_clast): Add params_index.
804         (initialize_cloog_names): Create parameter strings from scratch, do
805         not reference other strings.
806         (create_params_index): New.
807         (gloog): Initialize params_index.
808         * graphite-scop-detection (free_scops_1): Removed.
809         (limit_scops): Use normal free_scops.
810         * graphite-sese-to-poly.c (save_var_names): Removed.
811         (parameter_index_in_region): Do not initialize SESE_PARAM_NAMES
812         and SESE_PARAMS_INDEX.
813         * sese.c (new_sese, free_sese): Dito.
814         * sese.h (struct sese): Remove params_index, params_names.
815         (SESE_PARAMS_INDEX, SESE_PARAMS_NAMES): Removed.
816
817 2009-11-20  Sebastian Pop  <sebastian.pop@amd.com>
818
819         Revert the following patch from 2009-09-14:
820         * graphite-blocking.c: Fix order of includes: tree-chrec.h, then
821         tree-scalar-evolution.h, and then tree-data-ref.h.
822         * graphite-clast-to-gimple.c: Same.
823         * graphite-dependences.c: Same.
824         * graphite-interchange.c: Same.
825         * graphite-poly.c: Same.
826         * graphite-scop-detection.c: Same.
827         * graphite-sese-to-poly.c: Same.
828         * graphite.c: Same.
829         * lambda-code.c: Same.
830         * matrix-reorg.c: Same.
831         * tree-data-ref.c: Same.
832         * tree-if-conv.c: Same.
833         * tree-loop-distribu: Same.: Same.
834         * tree-loop-linear.c: Same.
835         * tree-parloops.c: Same.
836         * tree-predcom.c: Same.
837         * tree-vect-patterns.c: Same.
838
839 2009-11-20  Sebastian Pop  <sebastian.pop@amd.com>
840
841         Revert patch from 2009-09-14.
842         * tree-ssa-loop.c (gate_graphite_transforms): Re-enable Graphite
843         passes at -O1 and below.
844
845 2009-11-18  Sebastian Pop  <sebastian.pop@amd.com>
846
847         PR middle-end/40281
848         * gcc.dg/graphite/pr40281.c: New.
849
850         * tree-scalar-evolution.c (instantiate_scev_poly): Base and stride
851         evolutions should not variate in inner loops.
852
853 2009-11-18  Sebastian Pop  <sebastian.pop@amd.com>
854
855         PR middle-end/42050
856         * gfortran.dg/graphite/pr42050.f90: New.
857
858 2009-11-18  Sebastian Pop  <sebastian.pop@amd.com>
859
860         * graphite-interchange.c (memory_strides_in_loop_depth): New.
861         (pbb_interchange_profitable_p): Call memory_strides_in_loop_depth.
862
863 2009-11-18  Sebastian Pop  <sebastian.pop@amd.com>
864
865         * graphite-blocking.c (scop_do_block): New.
866         * graphite-poly.c (apply_poly_transforms): Call scop_do_block.
867         * graphite-poly.h (scop_do_block): Declared.
868
869 2009-11-18  Sebastian Pop  <sebastian.pop@amd.com>
870
871         * graphite-blocking.c (pbb_strip_mine_profitable_p): The parameter
872         depth is the loop nesting depth in the LST.  Call psct_dynamic_dim
873         to transform depth into the time_depth before calling
874         pbb_number_of_iterations_at_time.
875         (lst_do_strip_mine): Use a scalar variable instead of recomputing
876         lst_depth.
877
878 2009-11-18  Sebastian Pop  <sebastian.pop@amd.com>
879
880         Reverted the patch for "scattering permutations" from 2009-10-28.
881
882         * graphite-poly.c (print_permutation): New.
883         (debug_permutation): New.
884         (new_poly_bb): Initialize PBB_PERMUTATION.
885         (free_poly_bb): Free PBB_PERMUTATION.
886         * graphite-poly.h (pbb_permutation_elt_p): Declared.
887         (struct pbb_permutation_elt): New.
888         (PBB_PERMUTATION_ELT_STRIDE): New.
889         (PBB_PERMUTATION_ELT_STRIDED_P): New.
890         (PBB_PERMUTATION_ELT_TIME_DIMENSION): New.
891         (new_pbb_permutation_elt): New.
892         (pbb_permutation_elt_free): New.
893         (struct poly_bb): Add field permutation.
894         (PBB_PERMUTATION): New.
895         (print_permutation): Declared.
896         (debug_permutation): Declared.
897
898 2009-11-04  Konrad Trifunovic  <konrad.trifunovic@inria.fr>
899
900         * graphite-interchange.c (build_partial_difference): New.
901         (memory_stride_in_loop): Refactored the computation of
902         equality constraints into build_partial_difference function.
903         Added support for debugging stride computations.
904
905 2009-11-03  Sebastian Pop  <sebastian.pop@amd.com>
906
907         * graphite-clast-to-gimple.c (gloog): Free if_region,
908         if_region->true_region, and if_region->region.
909         * sese.c (if_region_set_false_region): Free if_region->false_region.
910         (create_if_region_on_edge): Do not use GGC_NEW.
911         (move_sese_in_condition): Remove useless initialization.
912
913 2009-11-03  Sebastian Pop  <sebastian.pop@amd.com>
914
915         * graphite-interchange.c (lst_perfect_nestify): Pass 3 parameters
916         for the loops created by the loop distribution.  Do not modify the
917         input LSTs.
918         (lst_try_interchange_loops): Same.  Use a temporary LST for the
919         transformed schedule.  Call lst_update_scattering before data
920         dependence analysis.
921         (lst_try_interchange): Pass an extra parameter INDEX.
922         (lst_do_interchange_1): New.
923         (lst_do_interchange): Call lst_do_interchange_1.
924         (scop_do_interchange): Call lst_update_scattering.
925         * graphite-poly.c (apply_poly_transforms): Do not call
926         lst_update_scattering.
927         * graphite-poly.h (lst_pred): New.
928         (lst_succ): New.
929         (lst_find_first_pbb): Return NULL when not found.
930         (lst_empty_p): New.
931         (lst_insert_in_sequence): Allow LST1 to be NULL.
932         (lst_replace): New.
933         (lst_substitute_3): New.
934         * gcc.dg/graphite/interchange-1.c: XFail.
935         * gcc.dg/graphite/interchange-8.c: XFail.
936         * gcc.dg/graphite/interchange-11.c: XFail.
937
938 2009-10-30  Sebastian Pop  <sebastian.pop@amd.com>
939
940         * graphite-interchange.c (lst_perfectly_nested_p): New.
941         (lst_perfect_nestify): New.
942         (lst_try_interchange_loops): Call store_lst_schedule,
943         lst_perfectly_nested_p, lst_perfect_nestify and restore_lst_schedule.
944         (scop_do_interchange): Avoid redundant legality test.
945         Call lst_do_interchange on a copy of SCOP_TRANSFORMED_SCHEDULE.
946         * graphite-poly.c (apply_poly_transforms): Call lst_update_scattering.
947         * graphite-poly.h (psct_static_dim): New.
948         (lst_dewey_number_at_depth): New.
949         (lst_find_pbb): Restructured.
950         (lst_find_first_pbb): Restructured.
951         (lst_find_last_pbb): New.
952         (lst_contains_p): New.
953         (lst_contains_pbb): New.
954         (lst_create_nest): New.
955         (lst_remove_from_sequence): New.
956         (pbb_update_scattering): New.
957         (lst_update_scattering_under): New.
958         (lst_update_scattering_seq): New.
959         (lst_update_scattering): New.
960         (lst_insert_in_sequence): New.
961         (lst_distribute_lst): New.
962         (lst_remove_all_before_including_pbb): New.
963         (lst_remove_all_before_excluding_pbb): New.
964
965 2009-10-30  Sebastian Pop  <sebastian.pop@amd.com>
966
967         * tree-ssa-loop-niter.c (finite_loop_p): Do not call twice
968         get_loop_exit_edges.
969
970 2009-10-30  Sebastian Pop  <sebastian.pop@amd.com>
971
972         * graphite-poly.c (pbb_remove_duplicate_pdrs): Free collapsed.
973
974 2009-10-28  Konrad Trifunovic  <konrad.trifunovic@gmail.com>
975
976         * graphite-poly.c (print_permutation): New.
977         (debug_permutation): New.
978         (new_poly_bb): Initialize PBB_PERMUTATION.
979         (free_poly_bb): Free PBB_PERMUTATION.
980         * graphite-poly.h (pbb_permutation_elt_p): Declared.
981         (struct pbb_permutation_elt): New.
982         (PBB_PERMUTATION_ELT_STRIDE): New.
983         (PBB_PERMUTATION_ELT_STRIDED_P): New.
984         (PBB_PERMUTATION_ELT_TIME_DIMENSION): New.
985         (new_pbb_permutation_elt): New.
986         (pbb_permutation_elt_free): New.
987         (struct poly_bb): Add field permutation.
988         (PBB_PERMUTATION): New.
989         (print_permutation): Declared.
990         (debug_permutation): Declared.
991
992 2009-10-26  Sebastian Pop  <sebastian.pop@amd.com>
993
994         * graphite-clast-to-gimple.c (gloog): Do not call
995         sese_reset_aux_in_loops.
996         * graphite-sese-to-poly.c (build_loop_iteration_domains): Pass an
997         extra argument for domains.  Do not use loop->aux.
998         (build_scop_iteration_domain): Initialize and free domains, pass it
999         to build_loop_iteration_domains and extract the information from
1000         domains.  Do not use loop->aux.
1001         * sese.c (sese_reset_aux_in_loops): Removed.
1002         * sese.h (sese_reset_aux_in_loops): Removed.
1003
1004 2009-10-26  Sebastian Pop  <sebastian.pop@amd.com>
1005
1006         * graphite-clast-to-gimple.c (find_pbb_via_hash): Moved up.
1007         (dependency_in_loop_p): Same.
1008         (translate_clast): Do not use loop->aux.  Initialize
1009         loop->can_be_parallel.
1010         (mark_loops_parallel): Removed.
1011         * graphite-clast-to-gimple.h (mark_loops_parallel): Removed.
1012         * graphite.c (free_aux_in_new_loops): Removed.
1013         (graphite_finalize): Do not call free_aux_in_new_loops.
1014         (graphite_transform_loops): Do not call mark_loops_parallel.
1015
1016 2009-10-26  Li Feng  <nemokingdom@gmail.com>
1017
1018         * graphite-clast-to-gimple.c (get_stmtfor_depth): Removed.
1019         (translate_clast): Pass an extra parameter LEVEL.
1020         Call get_scattering_level.
1021         * graphite-clast-to-gimple.h (get_scattering_level): New.
1022
1023 2009-10-22  Sebastian Pop  <sebastian.pop@amd.com>
1024
1025         * cfgloop.c (alloc_loop): Initialize loop->single_iv.
1026         * cfgloop.h (struct loop): New field single_iv.
1027
1028         * graphite-clast-to-gimple.c (pbb_to_depth_to_oldiv): Do not use
1029         loop->aux anymore: use loop->single_iv.
1030         (graphite_loop_normal_form): Moved...
1031         (build_graphite_loop_normal_form): Removed.
1032         (gloog): Do not call build_graphite_loop_normal_form.
1033         (free_aux_in_new_loops): Moved...
1034         (mark_loops_parallel): Restructure.
1035         * graphite-clast-to-gimple.h (free_aux_in_new_loops): Do not declare.
1036         * graphite-sese-to-poly.c (graphite_loop_normal_form): ...here.
1037         (scop_canonicalize_loops): New.
1038         (build_poly_scop): Call scop_canonicalize_loops.
1039         * graphite.c (free_aux_in_new_loops): ...here.
1040
1041 2009-10-22  Sebastian Pop  <sebastian.pop@amd.com>
1042
1043         * g++.dg/graphite/graphite.exp: Add the same rules as in
1044         gcc.dg/graphite/graphite.exp.
1045
1046 2009-10-22  Sebastian Pop  <sebastian.pop@amd.com>
1047
1048         * g++.dg/graphite/id-1.C: New.
1049
1050 2009-10-22  Sebastian Pop  <sebastian.pop@amd.com>
1051
1052         * graphite-sese-to-poly.c (create_zero_dim_array): Pass an extra
1053         argument base_name.
1054         (rewrite_close_phi_out_of_ssa): Update use of create_zero_dim_array.
1055         (rewrite_phi_out_of_ssa): Same.
1056         (rewrite_cross_bb_scalar_deps): Same.
1057         (translate_scalar_reduction_to_array): Same.
1058
1059 2009-10-22  Sebastian Pop  <sebastian.pop@amd.com>
1060
1061         * graphite-sese-to-poly.c (build_scop_drs): Disable call to
1062         dump_alias_graphs.
1063
1064 2009-10-22  Sebastian Pop  <sebastian.pop@amd.com>
1065
1066         * graphite-sese-to-poly.c (dump_alias_graphs): New.
1067         (build_scop_drs): Call dump_alias_graphs.
1068
1069 2009-10-22  Sebastian Pop  <sebastian.pop@amd.com>
1070
1071         * graphite-poly.c (new_scop): Initialize SCOP_ORIGINAL_SCHEDULE,
1072         SCOP_TRANSFORMED_SCHEDULE, and SCOP_SAVED_SCHEDULE.
1073         (free_scop): Call free_lst on SCOP_ORIGINAL_SCHEDULE,
1074         SCOP_TRANSFORMED_SCHEDULE, and SCOP_SAVED_SCHEDULE.
1075         * graphite-poly.h (free_lst): New.
1076         (store_lst_schedule): Free SCOP_SAVED_SCHEDULE.
1077         (restore_lst_schedule): Free SCOP_TRANSFORMED_SCHEDULE.
1078
1079 2009-10-22  Sebastian Pop  <sebastian.pop@amd.com>
1080
1081         * graphite-poly.h (struct scop): Add a field saved_schedule.
1082         (SCOP_SAVED_SCHEDULE): New.
1083         (store_lst_schedule): New.
1084         (restore_lst_schedule): New.
1085         (store_scattering): Call store_lst_schedule.
1086         (restore_scattering): Call restore_lst_schedule.
1087
1088 2009-10-20  Sebastian Pop  <sebastian.pop@amd.com>
1089
1090         * graphite-sese-to-poly.c (free_data_refs_aux): Fix formatting.
1091         (pdr_add_alias_set): Same.
1092         (build_poly_dr): Same.
1093         (build_alias_set_optimal_p): Same.
1094         (build_base_obj_set_for_drs): Same.  Do not store the result of
1095         graphds_dfs.
1096
1097 2009-10-20  Sebastian Pop  <sebastian.pop@amd.com>
1098
1099         * graphite-sese-to-poly.c (build_alias_set_optimal_p): Initialize
1100         all_components_are_cliques to 1.
1101
1102 2009-10-20  Li Feng  <nemokingdom@gmail.com>
1103
1104         * graphite-sese-to-poly.c (free_data_refs_aux): Update to free
1105         the new structure.
1106         (pdr_add_alias_set): Update retrieving alias_set_num.
1107         (build_poly_dr): Update retrieving dr_base_object_set.
1108         (partition_drs_to_sets): Remove.
1109         (build_alias_set_optimal_p): New.
1110         (build_alias_set_for_drs): Rename.
1111         (build_scop_drs): Update.
1112         * graphite-sese-to-poly.h (struct base_alias_pair): New.
1113         (ALIAS_SET_INDEX): Remove.
1114         (BASE_OBJECT_SET_INDEX): Remove.
1115
1116 2009-10-20  Sebastian Pop  <sebastian.pop@amd.com>
1117
1118         * sese.c (get_vdef_before_sese): Handle GIMPLE_ASSIGN and GIMPLE_CALL.
1119
1120 2009-10-20  Sebastian Pop  <sebastian.pop@amd.com>
1121
1122         * graphite-sese-to-poly.c (pdr_add_data_dimensions): Do not infer
1123         loop upper bounds for 1-element arrays at end of structures.
1124         * tree-flow.h (array_at_struct_end_p): Declared.
1125         * tree-ssa-loop-niter.c (array_at_struct_end_p): Not static anymore.
1126
1127 2009-10-20  Sebastian Pop  <sebastian.pop@amd.com>
1128
1129         * g++.dg/graphite/pr41305.C: New.
1130
1131 2009-10-20  Alexander Monakov  <amonakov@ispras.ru>
1132
1133         * graphite-sese-to-poly.c (build_loop_iteration_domains): Generalize
1134         construction of parameter constraints from loop iteration analysis.
1135         * gcc.dg/graphite/run-id-2.c: New test.
1136
1137 2009-10-17  Sebastian Pop  <sebastian.pop@amd.com>
1138
1139         * graphite-interchange.c (memory_stride_in_loop): Delete p1, lma
1140         and new_cstr.
1141
1142 2009-10-17  Sebastian Pop  <sebastian.pop@amd.com>
1143
1144         * graphite-dependences.c (dependence_polyhedron_1): Remove
1145         unused gdim dimensions from the DDR polyhedron.
1146
1147 2009-10-17  Sebastian Pop  <sebastian.pop@amd.com>
1148
1149         * graphite-dependences.c (pddr_transformed_scattering): New.
1150         (dot_original_deps_stmt_1): New.
1151         (dot_transformed_deps_stmt_1): New.
1152         (dot_deps_stmt_1): Call dot_original_deps_stmt_1 and
1153         dot_transformed_deps_stmt_1.
1154         (dot_original_deps): New.
1155         (dot_transformed_deps): New.
1156         (dot_deps_1): Call dot_original_deps and dot_transformed_deps.
1157
1158 2009-10-17  Sebastian Pop  <sebastian.pop@amd.com>
1159
1160         * graphite-dependences.c (reduction_dr_1): Remove wrong
1161         assert: reduction BBs can have multiple reduction writes
1162         to memory.  interchange-3.f90 is an example.
1163
1164 2009-10-17  Sebastian Pop  <sebastian.pop@amd.com>
1165
1166         * gfortran.dg/graphite/interchange-3.f90: New.
1167
1168 2009-10-17  Sebastian Pop  <sebastian.pop@amd.com>
1169
1170         * gcc.dg/graphite/interchange-1.c: Un-XFAILed.
1171
1172 2009-10-17  Sebastian Pop  <sebastian.pop@amd.com>
1173
1174         * graphite-dependences.c (dependence_polyhedron_1): Add the
1175         context to the dependence polyhedron.
1176
1177 2009-10-17  Sebastian Pop  <sebastian.pop@amd.com>
1178
1179         * graphite-poly.c (pbb_remove_duplicate_pdrs): Initialize
1180         PBB_PDR_DUPLICATES_REMOVED.
1181         (new_poly_bb): Same.
1182
1183 2009-10-17  Sebastian Pop  <sebastian.pop@amd.com>
1184
1185         * graphite-sese-to-poly.c (find_scop_parameters): Initialize
1186         SCOP_CONTEXT.
1187         (build_loop_iteration_domains): Extract bounds on parameters
1188         based on the data size.
1189         (build_scop_context): Do not initialize SCOP_CONTEXT;
1190         add new constraints.
1191
1192 2009-10-17  Sebastian Pop  <sebastian.pop@amd.com>
1193
1194         * graphite-ppl.c (ppl_min_for_le_polyhedron): New.
1195         * graphite-ppl.h (graphite-ppl.h): Declared.
1196
1197 2009-10-17  Sebastian Pop  <sebastian.pop@amd.com>
1198
1199         * graphite-ppl.c (ppl_print_linear_expr): New.
1200         (debug_ppl_linear_expr): New.
1201         * graphite-ppl.h (ppl_print_linear_expr): Declared.
1202         (debug_ppl_linear_expr): Declared.
1203
1204 2009-10-16  Sebastian Pop  <sebastian.pop@amd.com>
1205
1206         * graphite-interchange.c: Fix comments.
1207         * gcc.dg/graphite/block-1.c: Fix comments.
1208
1209 2009-10-16  Sebastian Pop  <sebastian.pop@amd.com>
1210
1211         * gcc.dg/graphite/interchange-7.c: Un-XFAILed.
1212         * gcc.dg/graphite/interchange-9.c: Un-XFAILed.
1213
1214 2009-10-16  Sebastian Pop  <sebastian.pop@amd.com>
1215
1216         Reapply the patch from Alexander Monakov that disappeared during
1217         the last merges from trunk.
1218
1219         2009-09-16  Alexander Monakov  <amonakov@ispras.ru>
1220
1221         * graphite-sese-to-poly.c (pdr_add_data_dimensions): Add bounds only
1222         for ARRAY_REFs.  Use array_ref_{low,up}_bound to determine bounds.
1223
1224 2009-10-15  Sebastian Pop  <sebastian.pop@amd.com>
1225
1226         * graphite-interchange.c (memory_stride_in_loop): The depth
1227         argument corresponds to a dynamic time dimension, so use
1228         psct_dynamic_dim to refer to the transformed scattering dimension.
1229
1230 2009-10-15  Sebastian Pop  <sebastian.pop@amd.com>
1231
1232         * graphite-interchange.c (memory_stride_in_loop): Fix comments.
1233
1234 2009-10-15  Sebastian Pop  <sebastian.pop@amd.com>
1235
1236         * graphite-blocking.c (lst_do_strip_mine): Avoid strip mining the
1237         root of the LST.
1238         * graphite-interchange.c (lst_do_interchange): Avoid interchanging
1239         the root of the LST.
1240         * graphite-poly.c (scop_to_lst): Fix LST sequence in an outermost
1241         fake loop.
1242         (print_lst): Print the root of LST in a different format.
1243         * graphite-poly.h (lst_depth): Adjust to include the root of the LST.
1244
1245 2009-10-15  Sebastian Pop  <sebastian.pop@amd.com>
1246
1247         * graphite-poly.c (print_scop): Fix pretty printing of a SCoP.
1248
1249 2009-10-15  Sebastian Pop  <sebastian.pop@amd.com>
1250
1251         * doc/passes.texi: Document the Graphite infrastructure.
1252
1253 2009-10-15  Sebastian Pop  <sebastian.pop@amd.com>
1254
1255         * graphite-sese-to-poly.c (insert_copyin): Use gsi_insert_seq_on_edge.
1256         (rewrite_commutative_reductions_out_of_ssa): Call gsi_commit_edge_inserts,
1257         and check the SSA representation.
1258
1259         * gfortran.dg/graphite/id-18.f90: New, reduced from PR41193.
1260
1261 2009-10-15  Sebastian Pop  <sebastian.pop@amd.com>
1262
1263         * gcc.dg/graphite/pr40157.c: Use -floop-block as reported in the PR.
1264
1265 2009-10-14  Sebastian Pop  <sebastian.pop@amd.com>
1266
1267         * gcc.dg/graphite/interchange-11.c: New.
1268
1269 2009-10-14  Sebastian Pop  <sebastian.pop@amd.com>
1270
1271         * gcc.dg/graphite/interchange-8.c: Enable loop interchange.
1272
1273 2009-10-14  Sebastian Pop  <sebastian.pop@amd.com>
1274
1275         * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK):
1276         Add -fno-loop-strip-mine and -fno-loop-interchange.
1277         (DEFAULT_FLAGS_GRAPHITE_INTERCHANGE): Add -fno-loop-block and
1278         -fno-loop-strip-mine.
1279         * gfortran.dg/graphite/graphite.exp: Same.
1280
1281 2009-10-14  Sebastian Pop  <sebastian.pop@amd.com>
1282
1283         * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK):
1284         Renamed DEFAULT_FLAGS_GRAPHITE_BLOCK.
1285         (DEFAULT_CFLAGS_GRAPHITE_IDENTITY): Renamed
1286         DEFAULT_FLAGS_GRAPHITE_IDENTITY.
1287         (DEFAULT_CFLAGS_GRAPHITE_INTERCHANGE): Renamed
1288         DEFAULT_FLAGS_GRAPHITE_INTERCHANGE.
1289         (DEFAULT_CFLAGS_GRAPHITE_SCOP): Renamed
1290         DEFAULT_FLAGS_GRAPHITE_SCOP.
1291         (DEFAULT_CFLAGS_RUN_ID): Renamed DEFAULT_FLAGS_RUN_ID.
1292         (DEFAULT_CFLAGS_GRAPHITE): Renamed DEFAULT_FLAGS_GRAPHITE.
1293
1294 2009-10-14  Sebastian Pop  <sebastian.pop@amd.com>
1295
1296         * graphite-poly.c (pbb_number_of_iterations_at_time): Cleanup comments.
1297
1298 2009-10-14  Konrad Trifunovic  <konrad.trifunovic@gmail.com>
1299             Sebastian Pop  <sebastian.pop@amd.com>
1300
1301         * graphite-interchange.c (build_linearized_memory_access): Pass an
1302         offset as parameter.
1303         (memory_stride_in_loop): Include transform scattering in the
1304         access functions to be able to querry the strides in the
1305         transformed loops.
1306         (pbb_interchange_loop_depths): Interchange the psct_dynamic_dim,
1307         not the psct_iterator_dim.
1308
1309 2009-10-14  Sebastian Pop  <sebastian.pop@amd.com>
1310
1311         * graphite-blocking.c (pbb_do_strip_mine): Removed.
1312         (lst_do_strip_mine_loop): New.
1313         (lst_do_strip_mine): New.
1314         (scop_do_strip_mine): Call lst_do_strip_mine.
1315         * graphite-poly.h (lst_add_loop_under_loop): New.
1316         (lst_find_first_pbb): New.
1317
1318 2009-10-14  Sebastian Pop  <sebastian.pop@amd.com>
1319
1320         * graphite-poly.c (loop_to_lst): Fix LST creation.
1321
1322 2009-10-14  Tobias Grosser  <grosser@fim.uni-passau.de>
1323
1324         * gcc.dg/graphite/id-15.c: (8 * 8) replaced with
1325         sizeof(unsigned long) to make it run on 32bit systems.
1326
1327 2009-10-14  Tobias Grosser  <grosser@fim.uni-passau.de>
1328
1329         * gcc.dg/graphite/run-id-1.c: Use smaller matrix to not
1330         SEGFAULT on 32bit.
1331
1332 2009-10-14  Ramakrishna Upadrasta <Ramakrishna.Upadrasta@inria.fr>
1333
1334         * graphite-sese-to-poly.c (write_alias_graph_to_ascii_dimacs): Fix
1335         Comment.
1336         (write_alias_graph_to_ascii_dot): New.
1337         (write_alias_graph_to_ascii_ecc): Ditto.
1338         (partition_drs_to_sets): Add testing of optimality of current method
1339         which assigns alias numbers according to DFS Comopnent number.  used
1340         as heuristic for the upcoming ECC algorithm.
1341         (build_scop_drs): Write to file also with the ecc and dot format.
1342
1343 2009-10-13  Sebastian Pop  <sebastian.pop@amd.com>
1344
1345         * gfortran.dg/graphite/interchange-1.f: XFail.
1346
1347 2009-10-13  Sebastian Pop  <sebastian.pop@amd.com>
1348
1349         * graphite.c (graphite_initialize): Do not handle functions with
1350         more than 100 basic blocks.
1351
1352 2009-10-13  Sebastian Pop  <sebastian.pop@amd.com>
1353
1354         * graphite-blocking.c (pbb_do_strip_mine): Use
1355         PARAM_LOOP_BLOCK_TILE_SIZE.
1356
1357 2009-10-13  Sebastian Pop  <sebastian.pop@amd.com>
1358
1359         * graphite-poly.c (dot_lst_1): New.
1360         (dot_lst): New.
1361         * graphite-poly.h (dot_lst): Declared.
1362
1363 2009-10-13  Sebastian Pop  <sebastian.pop@amd.com>
1364
1365         * graphite-dependences.c (dot_deps_stmt_1): New.
1366         (dot_deps_stmt): New.
1367         * graphite-dependences.h (dot_deps_stmt): Declared.
1368
1369 2009-10-09  Sebastian Pop  <sebastian.pop@amd.com>
1370
1371         * graphite-sese-to-poly.c (rewrite_cross_bb_scalar_dependence): Do
1372         not replace cross BB scalar dependences ending on PHI nodes.
1373         (rewrite_cross_bb_scalar_deps): Filter out GIMPLE_PHI nodes.
1374
1375 2009-10-09  Sebastian Pop  <sebastian.pop@amd.com>
1376
1377         * graphite-poly.c (apply_poly_transforms): Implement the high
1378         level driver for flag_loop_block.
1379         * opts.c (decode_options): Enable flag_loop_block at -O2.
1380         * tree-ssa-loop.c (gate_graphite_transforms): Remove call to sorry for
1381         flag_loop_block.
1382
1383         * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK): Add
1384         -floop-block.
1385         * gfortran.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK):
1386         Add -floop-block.
1387
1388 2009-10-09  Sebastian Pop  <sebastian.pop@amd.com>
1389
1390         * graphite-poly.h (lst_find_pbb): New.
1391         (find_lst_loop): New.
1392
1393 2009-10-09  Sebastian Pop  <sebastian.pop@amd.com>
1394
1395         * graphite-poly.c (new_scop): Remove init of SCOP_DEP_GRAPH.
1396         * graphite-poly.h (struct scop): Remove dep_graph field.
1397         (SCOP_DEP_GRAPH): Removed.
1398
1399 2009-10-09  Sebastian Pop  <sebastian.pop@amd.com>
1400
1401         * graphite-poly.h (copy_lst): Do full copy of LST.
1402
1403 2009-10-07  Sebastian Pop  <sebastian.pop@amd.com>
1404
1405         * graphite-sese-to-poly.c (reduction_phi_p): Call remove_invariant_phi
1406         when the loop stride is zero.
1407
1408         * gcc.dg/graphite/id-16.c: New.
1409
1410 2009-10-06  Sebastian Pop  <sebastian.pop@amd.com>
1411
1412         * graphite-dependences.c (reduction_dr_1): New.
1413         (reduction_dr_p): New.
1414         (graphite_legal_transform_dr): Call reduction_dr_p.
1415         (reduction_ddr): Renamed reduction_ddr_p.
1416         * graphite-poly.h (same_pdr_p): New.
1417         (number_of_write_pdrs): New.
1418         * graphite-sese-to-poly.c (nb_data_writes_in_bb): New.
1419         (split_reduction_stmt): Do not split reduction statements
1420         when there are no writes to memory.
1421         (translate_scalar_reduction_to_array_for_stmt): Insert the
1422         memory reduction statement just after the scalar reduction statement.
1423
1424         * gcc.dg/graphite/interchange-10.c: Updated to differ from interchange-4.c.
1425         Un-XFAIL-ed.
1426         * gcc.dg/graphite/interchange-3.c: Un-XFAIL-ed.
1427         * gcc.dg/graphite/interchange-4.c: Un-XFAIL-ed.
1428
1429 2009-10-06  Sebastian Pop  <sebastian.pop@amd.com>
1430
1431         * graphite-interchange.c (lst_apply_interchange): New.
1432         (lst_interchange_profitable_p): New.
1433         (lst_try_interchange_loops): New.
1434         (lst_try_interchange): New.
1435         (lst_do_interchange): New.
1436         (pbb_do_interchange): Removed.
1437         (scop_do_interchange): Call lst_do_interchange.
1438
1439 2009-10-06  Sebastian Pop  <sebastian.pop@amd.com>
1440
1441         * graphite-poly.c (print_scop): Print SCOP_ORIGINAL_SCHEDULE and
1442         SCOP_TRANSFORMED_SCHEDULE.
1443         (loop_to_lst): New.
1444         (scop_to_lst): New.
1445         (print_lst): New.
1446         (debug_lst): New.
1447         * graphite-poly.h (lst_p): New.
1448         (struct lst): New.
1449         (LST_LOOP_P): New.
1450         (LST_LOOP_FATHER): New.
1451         (LST_PBB): New.
1452         (LST_SEQ): New.
1453         (scop_to_lst): Declared.
1454         (print_lst): Declared.
1455         (debug_lst): Declared.
1456         (new_lst_loop): New.
1457         (new_lst_stmt): New.
1458         (copy_lst): New.
1459         (lst_depth): New.
1460         (lst_dewey_number): New.
1461         (struct scop): Add original_schedule and transformed_schedule fields.
1462         (SCOP_ORIGINAL_SCHEDULE): New.
1463         (SCOP_TRANSFORMED_SCHEDULE): New.
1464         * graphite-sese-to-poly.c (build_poly_scop): Call scop_to_lst.
1465
1466 2009-10-05  Sebastian Pop  <sebastian.pop@amd.com>
1467
1468         * graphite-dependences.c (reduction_ddr): New.
1469         (graphite_legal_transform_bb): Call reduction_ddr.
1470         * graphite-poly.c (new_poly_bb): Pass a new bool parameter.
1471         Initialize PBB_IS_REDUCTION.
1472         * graphite-poly.h (struct poly_bb): New bool field is_reduction.
1473         (PBB_IS_REDUCTION): New.
1474         (new_poly_bb): Update declaration.
1475         * graphite-scop-detection.h (build_scop_bbs): Removed.
1476         (nb_reductions_in_loop): Removed.
1477         * graphite-sese-to-poly.c (try_generate_gimple_bb): Pass a sbitmap
1478         parameter for reductions.
1479         (try_generate_gimple_bb): Update call to new_poly_bb.
1480         (build_scop_bbs_1): Same.
1481         (build_scop_bbs): Same.
1482         (gsi_for_phi_node): New.
1483         (scalar_close_phi_node_p): Remove gcc_assert.
1484         (split_reduction_stmt): New.
1485         (is_reduction_operation_p): New.
1486         (phi_contains_arg): New.
1487         (follow_ssa_with_commutative_ops): New.
1488         (detect_commutative_reduction_arg): New.
1489         (detect_commutative_reduction_assign): New.
1490         (follow_inital_value_to_phi): New.
1491         (edge_initial_value_for_loop_phi): New.
1492         (initial_value_for_loop_phi): New.
1493         (detect_commutative_reduction): New.
1494         (translate_scalar_reduction_to_array_for_stmt): New.
1495         (insert_copyout): New.
1496         (insert_copyin): New.
1497         (translate_scalar_reduction_to_array): New.
1498         (rewrite_commutative_reductions_out_of_ssa_close_phi): New.
1499         (rewrite_commutative_reductions_out_of_ssa_loop): New.
1500         (rewrite_commutative_reductions_out_of_ssa): New.
1501         (build_poly_scop): Call rewrite_commutative_reductions_out_of_ssa.
1502         * sese.h (split_region_for_bb): New.
1503
1504         * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK): Add -ffast-math.
1505         * gcc.dg/graphite/interchange-1.c: Fix format.
1506         * gcc.dg/graphite/interchange-10.c: New.
1507
1508 2009-10-05  Sebastian Pop  <sebastian.pop@amd.com>
1509
1510         * graphite-sese-to-poly.c (insert_out_of_ssa_copy): Remove
1511         buggy assert.
1512
1513 2009-10-05  Sebastian Pop  <sebastian.pop@amd.com>
1514
1515         * graphite-sese-to-poly.c (scev_analyzable_p): New.
1516         (rewrite_cross_bb_scalar_dependence): New.
1517         (rewrite_cross_bb_scalar_deps): New.
1518         (rewrite_reductions_out_of_ssa): Use bb_in_sese_p.
1519         Call rewrite_cross_bb_scalar_deps.
1520
1521 2009-10-05  Sebastian Pop  <sebastian.pop@amd.com>
1522
1523         * graphite-sese-to-poly.c (gsi_for_ssa_name_def): Removed.
1524         (insert_out_of_ssa_copy): Directly use gsi_after_labels and
1525         gsi_for_stmt.
1526
1527 2009-10-05  Sebastian Pop  <sebastian.pop@amd.com>
1528
1529         * graphite-clast-to-gimple.c (build_cloog_prog): Use pbb_index.
1530         * graphite-interchange.c (pbb_do_interchange): Same.
1531         * graphite-poly.c (print_scattering_function): Same.
1532         (debug_pdrs): Same.
1533         * graphite-poly.h (pbb_loop): New.
1534         * graphite-sese-to-poly.c (create_linear_expr_from_tree): Use pbb_loop.
1535
1536 2009-09-27  Sebastian Pop  <sebastian.pop@amd.com>
1537
1538         * graphite-scop-detection.c (limit_scops): Do not build poly_bbs.
1539
1540 2009-09-27  Sebastian Pop  <sebastian.pop@amd.com>
1541
1542         * graphite-sese-to-poly.c (partition_drs_to_sets): Drs is not modified,
1543         so don't pass a pointer to it.
1544         (build_alias_set_for_drs): Same.
1545         (build_base_obj_set_for_drs): Same.
1546         (build_scop_drs): Same.
1547
1548 2009-09-26  Li Feng  <nemokingdom@gmail.com>
1549
1550         * graphite-sese-to-poly.c (build_scop_drs): Disable writing to file
1551         the alias graph of data references.
1552
1553 2009-09-25  Li Feng  <nemokingdom@gmail.com>
1554
1555         * graphite-sese-to-poly.c (write_alias_graph_to_ascii_dimacs): New.
1556         (build_scop_drs): When debugging, write the alias graph to file,
1557         otherwise, should be disabled.
1558
1559 2009-09-17  Sebastian Pop  <sebastian.pop@amd.com>
1560
1561         * Merge from mainline (151310:151361).
1562
1563 2009-09-17  Sebastian Pop  <sebastian.pop@amd.com>
1564
1565         * Merge from mainline (151171:151310).
1566
1567 2009-09-17  Sebastian Pop  <sebastian.pop@amd.com>
1568
1569         * Merge from mainline (151171:151806).
1570
1571 2009-09-17  Sebastian Pop  <sebastian.pop@amd.com>
1572
1573         * Revert the last commit.
1574
1575 2009-09-17  Sebastian Pop  <sebastian.pop@amd.com>
1576
1577         * Merge from mainline (151171:151819).
1578
1579 2009-09-17  Sebastian Pop  <sebastian.pop@amd.com>
1580
1581         * graphite-scop-detection.c (stmt_simple_memref_p): Removed.
1582         (is_simple_operand): Remove call to stmt_simple_memref_p.
1583         (stmt_simple_for_scop_p): Update call to is_simple_operand.
1584
1585 2009-09-17  David Edelsohn  <edelsohn@gnu.org>
1586
1587         * gcc.dg/graphite/interchange-mvt.c: New File.
1588         * gcc.dg/graphite/scop-dsyrk.c: New File.
1589         * gcc.dg/graphite/scop-dsyr2k.c: New File.
1590         * gcc.dg/graphite/scop-mvt.c: New File.
1591         * gcc.dg/graphite/scop-sor.c: New File.
1592
1593 2009-09-17 Li Feng  <nemokingdom@gmail.com>
1594
1595         * graphite-dependences.c (poly_drs_may_alias_p): Adjust definition.
1596         (pddr_original_scattering): Make sure 2 pdr2 in the same base object set.
1597         (graphite_carried_dependence_level_k): Ditto.
1598         * graphite-poly.c (new_poly_dr): Add init of PDR_BASE_OBJECT_SET.
1599         * graphite-poly.h (struct poly_dr): Add member dr_base_object_set.
1600         (new_poly_dr): Adjust declaration.
1601         * graphite-sese-to-poly.c (free_data_refs_aux): New.
1602         (free_gimple_bb): Added free_data_refs_aux.
1603         (build_poly_dr): Add dr_base_object_set.
1604         (partition_drs_to_sets): New.
1605         (dr_same_base_object_p): New.
1606         (build_alias_set_for_drs): New.
1607         (build_base_object_set_for_drs): New.
1608         (build_scop_drs): Add build_base_obj_set_for_drs.
1609         * graphite-sese-to-poly.h: Added #define for alias set number index and
1610         base object set index.
1611         * libgomp/testsuite/libgomp.graphite/force-parallel-6.c: Refine tests.
1612         * libgomp/testsuite/libgomp.graphite/pr4118.c: New.
1613
1614 2009-09-16  Alexander Monakov  <amonakov@ispras.ru>
1615
1616         * graphite-sese-to-poly.c (pdr_add_data_dimensions): Add bounds only
1617         for ARRAY_REFs.  Use array_ref_{low,up}_bound to determine bounds.
1618
1619 2009-09-14  Sebastian Pop  <sebastian.pop@amd.com>
1620
1621         * graphite-sese-to-poly.c (struct irp_data): Removed.
1622         (idx_record_params): Removed.
1623         (find_params_in_bb): Scan for parameters the access functions; don't
1624         parse the tree representation.
1625
1626 2009-09-14  Sebastian Pop  <sebastian.pop@amd.com>
1627
1628         * tree-ssa-loop.c (gate_graphite_transforms): Disable Graphite
1629         passes at -O1 and below.
1630
1631 2009-09-14  Sebastian Pop  <sebastian.pop@amd.com>
1632
1633         * graphite-blocking.c: Fix order of includes: tree-chrec.h, then
1634         tree-scalar-evolution.h, and then tree-data-ref.h.
1635         * graphite-clast-to-gimple.c: Same.
1636         * graphite-dependences.c: Same.
1637         * graphite-interchange.c: Same.
1638         * graphite-poly.c: Same.
1639         * graphite-scop-detection.c: Same.
1640         * graphite-sese-to-poly.c: Same.
1641         * graphite.c: Same.
1642         * lambda-code.c: Same.
1643         * matrix-reorg.c: Same.
1644         * tree-data-ref.c: Same.
1645         * tree-if-conv.c: Same.
1646         * tree-loop-distribu: Same.: Same.
1647         * tree-loop-linear.c: Same.
1648         * tree-parloops.c: Same.
1649         * tree-predcom.c: Same.
1650         * tree-vect-patterns.c: Same.
1651
1652 2009-09-02  Sebastian Pop  <sebastian.pop@amd.com>
1653
1654         Partially revert the previous patch, except the following.
1655         * tree-scalar-evolution.c (instantiate_scev_not): Adapted to pass
1656         as parameters the operands of the not expression.
1657
1658 2009-09-01  Sebastian Pop  <sebastian.pop@amd.com>
1659
1660         * tree-scalar-evolution.c (instantiate_scev_assign): New.
1661         Do not call analyze_scalar_evolution on assignments.
1662         (instantiate_scev_phi): Call analyze_scalar_evolution.
1663         (instantiate_scev_name): Call instantiate_scev_assign and
1664         instantiate_scev_phi.
1665         (instantiate_scev_not): Adapted to pass as parameters the operands
1666         of the not expression.
1667
1668 2009-09-01  Sebastian Pop  <sebastian.pop@amd.com>
1669
1670         * tree-scalar-evolution.c (instantiate_scev_binary): Adapted
1671         to pass as parameters the operands of the binary expression.
1672
1673 2009-09-01  Sebastian Pop  <sebastian.pop@amd.com>
1674
1675         * tree-scalar-evolution.c (instantiate_scev_bitnot): Renamed
1676         instantiate_scev_not.  Handle NEGATE_EXPR.
1677         (instantiate_scev_r): Handle NEGATE_EXPR.
1678
1679 2009-09-01  Sebastian Pop  <sebastian.pop@amd.com>
1680
1681         * tree-scalar-evolution.c (instantiate_scev_1): Renamed
1682         instantiate_scev_r.
1683         (instantiate_scev_r): Move code in instantiate_scev_2
1684         and instantiate_scev_1.
1685
1686 2009-09-01  Sebastian Pop  <sebastian.pop@amd.com>
1687
1688         * tree-scalar-evolution.c (instantiate_scev_3): New.
1689         (instantiate_scev_1): Move code in instantiate_scev_3.
1690
1691 2009-09-01  Sebastian Pop  <sebastian.pop@amd.com>
1692
1693         * tree-scalar-evolution.c (instantiate_scev_poly): New.
1694         (instantiate_scev_1): Move code in instantiate_scev_poly.
1695
1696 2009-09-01  Sebastian Pop  <sebastian.pop@amd.com>
1697
1698         * tree-scalar-evolution.c (instantiate_scev_bitnot): New.
1699         (instantiate_scev_1): Move code in instantiate_scev_bitnot.
1700
1701 2009-09-01  Sebastian Pop  <sebastian.pop@amd.com>
1702
1703         * tree-scalar-evolution.c (instantiate_scev_convert): New.
1704         (instantiate_scev_1): Move code in instantiate_scev_convert.
1705
1706 2009-09-01  Sebastian Pop  <sebastian.pop@amd.com>
1707
1708         * tree-scalar-evolution.c (instantiate_scev_binary): New.
1709         (instantiate_scev_1): Move code in instantiate_scev_binary.
1710
1711 2009-09-01  Sebastian Pop  <sebastian.pop@amd.com>
1712
1713         * tree-scalar-evolution.c (instantiate_scev_name): New.
1714         (instantiate_scev_1): Move code in instantiate_scev_name.
1715
1716 2009-08-28  Sebastian Pop  <sebastian.pop@amd.com>
1717
1718         * Merge from mainline (150992:151171).
1719
1720 2009-08-25  Sebastian Pop  <sebastian.pop@amd.com>
1721
1722         * opts.c (decode_options): Enable flag_loop_interchange at -O2.
1723
1724 2009-08-25  Sebastian Pop  <sebastian.pop@amd.com>
1725
1726         * graphite-dependences.c (graphite_legal_transform_bb): Call
1727         pbb_remove_duplicate_pdrs.
1728         * graphite-poly.c (can_collapse_pdr): Removed.
1729         (pdr_find_duplicate): Removed.
1730         (can_collapse_pdrs): New.
1731         (pbb_remove_duplicate_pdrs): New.
1732         (new_poly_dr): Do not look for duplicates.
1733         * graphite-poly.h (struct poly_bb): New field pdr_duplicates_removed.
1734         (PBB_PDR_DUPLICATES_REMOVED): New.
1735         (pbb_remove_duplicate_pdrs): Declared.
1736
1737 2009-08-25  Sebastian Pop  <sebastian.pop@amd.com>
1738
1739         * graphite-interchange.c (pbb_interchange_profitable_p): Adjust
1740         the strides by multiplying by PDR_NB_REFS.
1741         * graphite-poly.c (can_collapse_pdr): New.
1742         (pdr_find_duplicate): New.
1743         (new_poly_dr): Call pdr_find_duplicate.  Collapse duplicate PDRs.
1744         Initialize PDR_NB_REFS.
1745         * graphite-poly.h (struct poly_dr): Add field nb_refs.
1746         (PDR_NB_REFS): New.
1747         (new_poly_dr): Number of subscripts is a graphite_dim_t.
1748
1749 2009-08-25  Sebastian Pop  <sebastian.pop@amd.com>
1750
1751         Revert one of the previous commits:
1752         * graphite-dependences.c (graphite_legal_transform_bb): Avoid
1753         the computation of symmetric data dependence relations.
1754         (dependency_between_pbbs_p): Same.
1755
1756 2009-08-25  Sebastian Pop  <sebastian.pop@amd.com>
1757
1758         PR middle-end/40965
1759         * graphite-poly.c (apply_poly_transforms): Remove legality test before
1760         any transform.
1761
1762 2009-08-25  Sebastian Pop  <sebastian.pop@amd.com>
1763
1764         * graphite-dependences.c (pddr_original_scattering): Return NULL
1765         for read-read dependence relations.
1766         * graphite-poly.h (enum poly_dr_type): Fix comment.
1767         (pdr_read_p): New.
1768         (pdr_write_p): New.
1769         (pdr_may_write_p): New.
1770
1771 2009-08-25  Sebastian Pop  <sebastian.pop@amd.com>
1772
1773         * graphite-poly.h (enum POLY_DR_TYPE): Renamed poly_dr_type.
1774         (struct poly_dr): Same.
1775         (new_poly_dr): Same.
1776         * graphite-poly.c (new_poly_dr): Same.
1777
1778 2009-08-25  Konrad Trifunovic  <konrad.trifunovic@gmail.com>
1779             Sebastian Pop  <sebastian.pop@amd.com>
1780
1781         * graphite-blocking.c (pbb_strip_mine_loop_depth): Renamed
1782         pbb_strip_mine_time_depth.  Changed the implementation so that
1783         transformation is expressed as a transformation on
1784         time (scatttering) dimensions.  Also, ensures that the 2d+1
1785         scheduling format is preserved.
1786         (pbb_strip_mine_profitable_p): Profitability is based on the
1787         iteration number of a given time (scattering) dimension,
1788         and not on a original loop depth dimension.
1789         (pbb_strip_mine): Call pbb_number_of_iterations_at_time.
1790         (pbb_do_strip_mine): Call psct_dynamic_dim.
1791         * graphite-poly.c (pbb_number_of_iterations_at_time): New.
1792         * graphite-poly.h (pbb_number_of_iterations_at_time): Declared.
1793         (pbb_nb_dynamic_scattering_transform): New.
1794         (psct_dynamic_dim): New.
1795
1796 2009-08-25  Konrad Trifunovic  <konrad.trifunovic@gmail.com>
1797
1798         * graphite-ppl.c (ppl_max_for_le): Renamed ppl_max_for_le_pointset.
1799         * graphite-ppl.h (ppl_max_for_le): Renamed ppl_max_for_le_pointset.
1800         * graphite-poly.c (pbb_number_of_iterations): Rename ppl_max_for_le.
1801         * graphite-interchange.c (build_linearized_memory_access): Same.
1802         (memory_stride_in_loop): Same.
1803
1804 2009-08-25  Sebastian Pop  <sebastian.pop@amd.com>
1805
1806         * graphite-dependences.c (pddr_original_scattering): New.
1807         (graphite_legal_transform_dr): Call pddr_original_scattering.
1808         (dot_deps_1): New.
1809         (dot_deps): New.
1810         * graphite-dependences.h (dot_deps): Declared.
1811         * graphite-poly.c (new_poly_dr): Initialize PDR_ID.
1812         (print_pdr): Print PDR_ID.
1813         * graphite-poly.h (struct poly_dr): Add field id.
1814         (PDR_ID): New.
1815         (pbb_index): New.
1816         * graphite-scop-detection.c (dot_all_scops_1): Cleanup comment.
1817
1818 2009-08-22  Sebastian Pop  <sebastian.pop@amd.com>
1819
1820         * graphite-dependences.c (graphite_carried_dependence_level_k): Do
1821         not delete the original dependence relation.
1822
1823 2009-08-21  Sebastian Pop  <sebastian.pop@amd.com>
1824
1825         * graphite-dependences.c (graphite_legal_transform_bb): Avoid
1826         the computation of symmetric data dependence relations.
1827         (dependency_between_pbbs_p): Same.
1828
1829 2009-08-21  Sebastian Pop  <sebastian.pop@amd.com>
1830
1831         * graphite-dependences.c (new_poly_dr_pair): Renamed new_poly_ddr.
1832         (eq_poly_dr_pair_p): Renamed eq_poly_ddr_p.
1833         (hash_poly_dr_pair_p): Renamed hash_poly_ddr_p.
1834         (free_poly_ddr): New.
1835         (pddr_is_empty): New.
1836         (dependence_polyhedron_1): Now returns a poly_ddr_p.
1837         (dependence_polyhedron): Same.  Remove useless gcc_assert.
1838         Remove fprintfs.
1839         (graphite_legal_transform_dr): Call pddr_is_empty and free_poly_ddr.
1840         (graphite_carried_dependence_level_k): Call pddr_is_empty.
1841         * graphite-dependences.h (enum poly_dependence_kind): New.
1842         (poly_dr_pair): Renamed poly_ddr.  Added a field kind.
1843         (PDRP_SOURCE): Renamed PDDR_SOURCE.
1844         (PDRP_SINK): Renamed PDDR_SINK.
1845         (PDRP_DDP): Renamed PDDR_DDP.
1846         (PDDR_KIND): New.
1847         (free_poly_ddr): Declared.
1848         * graphite-poly.c (new_scop): Use the new hash function names.
1849         * graphite-poly.h (struct scop): Renamed field original_pdr_pairs
1850         into original_pddrs.
1851         (SCOP_ORIGINAL_PDR_PAIRS): Renamed SCOP_ORIGINAL_PDDRS.
1852
1853 2009-08-21  Sebastian Pop  <sebastian.pop@amd.com>
1854
1855         * Merge from mainline (150764:150992).
1856
1857 2009-08-18  Sebastian Pop  <sebastian.pop@amd.com>
1858
1859         * cfgloopmanip.c (create_empty_loop_on_edge): Generate upper
1860         bounds with LT_EXPR to make niter analysis more precise on code
1861         generated by Graphite.
1862
1863 2009-08-18  Sebastian Pop  <sebastian.pop@amd.com>
1864
1865         * graphite-dependences.c (graphite_legal_transform_dr): Fix formatting.
1866         (graphite_legal_transform_bb): Same.
1867         (poly_drs_may_alias_p): Same.
1868
1869 2009-08-15  Sebastian Pop  <sebastian.pop@amd.com>
1870
1871         PR middle-end/40981
1872         * graphite-ppl.c (ppl_max_for_le): Correct the use of
1873         ppl_Pointset_Powerset_C_Polyhedron_maximize.
1874
1875 2009-08-13  Sebastian Pop  <sebastian.pop@amd.com>
1876
1877         * graphite-poly.c (print_pbb): Print PBB index.
1878
1879 2009-08-13  Sebastian Pop  <sebastian.pop@amd.com>
1880
1881         * Merge from mainline (r150672:150764).
1882
1883 2009-08-13  Sebastian Pop  <sebastian.pop@amd.com>
1884
1885         * graphite-interchange.c (ppl_max_for_le): Moved...
1886         * graphite-poly.c (pbb_number_of_iterations): Call ppl_max_for_le.
1887         * graphite-ppl.c (ppl_max_for_le): ... here.
1888         * graphite-ppl.h (ppl_max_for_le): Declared.
1889
1890 2009-08-12  Sebastian Pop  <sebastian.pop@amd.com>
1891
1892         * Merge from mainline (r150372:150672).
1893
1894 2009-08-11  Sebastian Pop  <sebastian.pop@amd.com>
1895
1896         PR middle-end/40980
1897         * sese.c (convert_for_phi_arg): New.
1898         (add_guard_exit_phis): Use convert_for_phi_arg.
1899
1900         * gfortran.dg/graphite/id-17.f: New.
1901
1902 2009-08-11  Sebastian Pop  <sebastian.pop@amd.com>
1903
1904         * graphite-sese-to-poly.c (pdr_add_data_dimensions): Dont add
1905         unknown subscript upper bounds.
1906
1907         * gcc.dg/graphite/interchange-6.c: Un-XFAIL.
1908
1909 2009-08-11  Sebastian Pop  <sebastian.pop@amd.com>
1910             Pranav Garg  <pranav.garg2107@gmail.com>
1911
1912         * graphite-interchange.c (gather_access_strides): Removed.
1913         (ppl_max_for_le): New.
1914         (build_linearized_memory_access): New.
1915         (memory_stride_in_loop): New.
1916         (pbb_interchange_profitable_p): Reimplemented.
1917         * graphite-ppl.h (ppl_new_id_map): New.
1918         (ppl_interchange): New.
1919
1920         * gcc.dg/graphite/interchange-6.c: XFAILed.
1921
1922 2009-08-11  Sebastian Pop  <sebastian.pop@amd.com>
1923
1924         * graphite-interchange.c (compute_subscript): Removed.
1925         (compute_array_size_cstr): Removed.
1926         (compute_array_size_poly): Removed.
1927         (compute_array_size): Removed.
1928         (gather_access_strides_poly): Removed.
1929         (gather_access_strides): Empty.
1930
1931 2009-08-11  Sebastian Pop  <sebastian.pop@amd.com>
1932
1933         * graphite-dependences.c (dependence_polyhedron_1): Replace
1934         pdr_nb_subscripts with PDR_NB_SUBSCRIPTS.
1935         (graphite_legal_transform_dr): Same.
1936         (graphite_carried_dependence_level_k): Same.
1937         * graphite-poly.c (new_poly_dr): Add a parameter nb_subscripts.
1938         Initialize PDR_NB_SUBSCRIPTS.
1939         (print_pdr_access_layout): Replace pdr_nb_subscripts with
1940         PDR_NB_SUBSCRIPTS.
1941         * graphite-poly.h (struct poly_dr): Add nb_subscripts field.
1942         (PDR_NB_SUBSCRIPTS): New.
1943         (pdr_nb_subscripts): Removed.
1944         (pdr_dim): Simplified.
1945         * graphite-sese-to-poly.c (build_poly_dr): Replace pdr_nb_subscripts
1946         with PDR_NB_SUBSCRIPTS.
1947
1948 2009-08-11  Sebastian Pop  <sebastian.pop@amd.com>
1949
1950         * graphite-interchange.c (compute_array_size): Remove use of
1951         PDR_DATA_CONTAINER.
1952         * graphite-poly.c (new_poly_dr): Remove argument data_container.
1953         Do not initialize PDR_DATA_CONTAINER.
1954         (print_pdr): Do not print PDR_DATA_CONTAINER.
1955         * graphite-poly.h (struct poly_dr): Remove data_container field.
1956         (PDR_DATA_CONTAINER): Removed.
1957         * graphite-sese-to-poly.c (pdr_add_data_dimensions): Remove use of
1958         PDR_DATA_CONTAINER.
1959         (build_poly_dr): Same.
1960
1961 2009-08-11  Sebastian Pop  <sebastian.pop@amd.com>
1962
1963         * gcc.dg/graphite/interchange-9.c: New.
1964
1965 2009-08-05  Konrad Trifunovic  <konrad.trifunovic@gmail.com>
1966             Sebastian Pop  <sebastian.pop@amd.com>
1967
1968         * graphite-dependences.c (graphite_legal_transform_dr): Work on a
1969         copy of the dependence polyhedron.  Free the temporary objects.
1970         (graphite_carried_dependence_level_k): Free unused objects before
1971         returning.
1972
1973         * gcc.dg/graphite/interchange-1.c: XFAILed.
1974         * gcc.dg/graphite/interchange-2.c: XFAILed.
1975         * gcc.dg/graphite/interchange-3.c: XFAILed.
1976         * gcc.dg/graphite/interchange-4.c: XFAILed.
1977         * gcc.dg/graphite/interchange-7.c: XFAILed.
1978
1979 2009-08-05  Sebastian Pop  <sebastian.pop@amd.com>
1980
1981         * graphite-blocking.c (scop_do_strip_mine): Call store_scattering.
1982         Early return without analyzing the data dependences if no
1983         transform has been done.  Call restore_scattering if the transform
1984         is not legal.
1985         (graphite-interchange.c): Same.
1986         * graphite-poly.c (print_scattering_function): Test for PBB_TRANSFORMED.
1987         (graphite_read_transforms): Initialize PBB_TRANSFORMED.
1988         (apply_poly_transforms): Do not gcc_assert that
1989         the transform is legal.
1990         (new_poly_bb): Initialize PBB_TRANSFORMED, PBB_SAVED, and PBB_ORIGINAL.
1991         Do not initialize PBB_NB_SCATTERING_TRANSFORM, PBB_NB_LOCAL_VARIABLES,
1992         PBB_TRANSFORMED_SCATTERING, and PBB_ORIGINAL_SCATTERING.
1993         (free_poly_dr): Free PBB_TRANSFORMED, PBB_SAVED, and PBB_ORIGINAL.
1994         * graphite-poly.h (struct poly_scattering): New.
1995         (struct poly_bb): Add original, transformed, and saved fields.
1996         Remove transformed_scattering, original_scattering, nb_local_variables,
1997         and nb_scattering_transform fields.
1998         (PBB_ORIGINAL, PBB_TRANSFORMED, PBB_SAVED): New.
1999         (poly_scattering_new): New.
2000         (poly_scattering_free): New.
2001         (poly_scattering_copy): New.
2002         (store_scattering_pbb): New.
2003         (store_scattering): New.
2004         (restore_scattering_pbb): New.
2005         (restore_scattering): New.
2006         * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons):
2007         Initialize PBB_TRANSFORMED and PBB_ORIGINAL.
2008
2009 2009-08-05  Sebastian Pop  <sebastian.pop@amd.com>
2010
2011         * graphite-poly.c (print_pbb): Add parentheses in the pretty print.
2012         (print_scop): Same.
2013
2014 2009-08-05  Sebastian Pop  <sebastian.pop@amd.com>
2015
2016         * Makefile.in (graphite.o): Depends on PREDICT_H.
2017         * graphite.c: Include predict.h.
2018         (graphite_finalize): Call tree_estimate_probability.
2019         * predict.c (predict_loops): Do not call scev_initialize and
2020         scev_finalize.
2021         (tree_estimate_probability_bb): New.
2022         (tree_estimate_probability): Do not initialize loops: move that
2023         code to the driver.  Call tree_estimate_probability_bb.
2024         (tree_estimate_probability_driver): New.
2025         (pass_profile): Use tree_estimate_probability_driver.
2026         * predict.h (tree_estimate_probability): Declared.
2027
2028 2009-08-05  Sebastian Pop  <sebastian.pop@amd.com>
2029
2030         * graphite-clast-to-gimple.c (gloog): Add time to TV_GRAPHITE_CODE_GEN.
2031         * graphite-dependences.c (graphite_legal_transform): Add time to
2032         TV_GRAPHITE_DATA_DEPS.
2033         (dependency_between_pbbs_p): Same.
2034         * timevar.def (TV_GRAPHITE_DATA_DEPS, TV_GRAPHITE_CODE_GEN): New.
2035
2036 2009-08-03  Sebastian Pop  <sebastian.pop@amd.com>
2037
2038         * Merge from mainline (r149952:150372).
2039
2040 2009-07-28  Sebastian Pop  <sebastian.pop@amd.com>
2041
2042         * ChangeLog.graphite: Fix indenting, white spaces and 80 columns.
2043         * graphite-blocking.c: Same.
2044         * graphite-clast-to-gimple.c: Same.
2045         * graphite-dependences.c: Same.
2046         * graphite-poly.c: Same.
2047         * graphite-poly.h: Same.
2048         * graphite-ppl.c: Same.
2049         * graphite-scop-detection.c: Same.
2050         * graphite-sese-to-poly.c: Same.
2051         * graphite.c: Same.
2052
2053 2009-07-28  Sebastian Pop  <sebastian.pop@amd.com>
2054
2055         * graphite-sese-to-poly.c (loop_entry_phi_arg): New.
2056         (remove_simple_copy_phi): New.
2057         (remove_invariant_phi): New.
2058         (simple_copy_phi_p): New.
2059         (reduction_phi_p): New.
2060         (gsi_for_ssa_name_def): New.
2061         (insert_out_of_ssa_copy): New.
2062         (insert_out_of_ssa_copy_on_edge): New.
2063         (create_zero_dim_array): New.
2064         (scalar_close_phi_node_p): New.
2065         (rewrite_close_phi_out_of_ssa): New.
2066         (rewrite_phi_out_of_ssa): New.
2067         (rewrite_reductions_out_of_ssa): New.
2068         (build_poly_scop): Call rewrite_reductions_out_of_ssa.
2069
2070         * gcc.dg/graphite/id-11.c: New.
2071         * gcc.dg/graphite/id-15.c: New.
2072         * gcc.dg/graphite/interchange-1.c: Un-XFAIL.
2073         * gcc.dg/graphite/interchange-2.c: Un-XFAIL.
2074         * gcc.dg/graphite/interchange-3.c: Un-XFAIL.
2075         * gcc.dg/graphite/interchange-4.c: Un-XFAIL.
2076         * gcc.dg/graphite/interchange-7.c: Un-XFAIL.
2077         * gcc.dg/graphite/scop-matmult.c: Un-XFAIL.
2078         * gfortran.dg/graphite/id-13.f: New.
2079         * gfortran.dg/graphite/id-5.f: New.
2080
2081 2009-07-28  Sebastian Pop  <sebastian.pop@amd.com>
2082
2083         * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not
2084         check that nb_reductions_in_loop is zero.
2085         * graphite-scop-detection.c (harmful_stmt_in_bb): Don't filter out
2086         reduction phi nodes.
2087         (nb_reductions_in_loop): Removed.
2088         (graphite_can_represent_loop): Do not call nb_reductions_in_loop.
2089         * graphite-sese-to-poly.c (phi_node_is_iv): Removed.
2090         (bb_contains_non_iv_scalar_phi_nodes): Removed.
2091         (scop_contains_non_iv_scalar_phi_nodes): Removed.
2092         (build_poly_scop): Do not call scop_contains_non_iv_scalar_phi_nodes.
2093
2094 2009-07-28  Sebastian Pop  <sebastian.pop@amd.com>
2095
2096         * graphite-clast-to-gimple.c (build_cloog_prog): Do not code generate
2097         statements that have an empty iteration domain.
2098         * gfortran.dg/graphite/id-16.f: New.
2099
2100 2009-07-28  Sebastian Pop  <sebastian.pop@amd.com>
2101
2102         * tree-scalar-evolution.c (instantiate_scev_1): Return
2103         chrec_dont_know when the result is not above instantiate_below.
2104         * graphite-scop-detection.c (scopdet_basic_block_info): Fix formatting.
2105         * graphite-sese-to-poly.c (create_linear_expr_from_tree): Assert that
2106         the tree has a known scalar evolution.
2107         * gfortran.dg/graphite/id-14.f: New.
2108         * gfortran.dg/graphite/id-15.f: New.
2109
2110 2009-07-28  Sebastian Pop  <sebastian.pop@amd.com>
2111
2112         * sese.c (rename_variables_in_stmt): Pass in an extra parameter
2113         insert_gsi.
2114         (rename_variables): Keep inserting renames after the ones already
2115         inserted.
2116
2117 2009-07-28  Sebastian Pop  <sebastian.pop@amd.com>
2118
2119         * graphite-sese-to-poly.c (compare_bb_depths): New.
2120         (graphite_sort_dominated_info): New.
2121         (build_scop_bbs_1): Call graphite_sort_dominated_info.
2122         (build_scop_scattering): Fix comment.
2123
2124 2009-07-28  Sebastian Pop  <sebastian.pop@amd.com>
2125
2126         * graphite.c (graphite_finalize): Call print_loops instead of
2127         dump_function_to_file.
2128         * gcc.dg/graphite/graphite.exp: Fix formatting.
2129         * gcc.dg/graphite/pr35356-1.c: New.  Look for the number of
2130         loops generated in the graphite output file.
2131         * gcc.dg/graphite/pr35356-2.c: New.
2132         * gcc.dg/graphite/pr35356-3.c: New.  XFAILed for now.
2133         * gfortran.dg/graphite/id-12.f: New.
2134
2135 2009-07-24  Li Feng  <nemokingdom@gmail.com>
2136
2137         * gcc.dg/graphite/graphite_autopar/force-parallel-8.c:
2138         Remove 2 XFAIL.
2139
2140 2009-07-24  Li Feng  <nemokingdom@gmail.com>
2141             Tobias Grosser  <grosser@fim.uni-passau.de>
2142
2143         * graphite-sese-to-poly.c (pdr_add_alias_set): Use data reference's
2144         alias set number build alias in ACCESSES polyhedron.
2145         (build_alias_set_for_drs): New.
2146         (build_pbb_drs): Added build_alias_set_for_drs.
2147         * graphite-dependences.c (poly_drs_may_alias_p): New.
2148         (graphite_carried_dependence_level_k): Check alias information
2149         before building polyhedron.
2150
2151 2009-07-24  Tobias Grosser  <grosser@fim.uni-passau.de>
2152
2153         * Makefile.in (lambda-code.o): Fix formatting.
2154
2155 2009-07-24  Tobias Grosser  <grosser@fim.uni-passau.de>
2156
2157         * Merge from mainline (r149350-149952)
2158
2159 2009-07-18  Tobias Grosser  <grosser@fim.uni-passau.de>
2160
2161         * graphite-poly.c (apply_poly_transforms): Move strip_mine
2162         before interchange to prepare for loop blocking.
2163
2164 2009-07-18  Tobias Grosser  <grosser@fim.uni-passau.de>
2165
2166         * graphite-poly.c (apply_poly_transforms): Add checks after every
2167         transformation.
2168         * graphite-sese-to-poly.c (build_poly_scop): Remove check, as already
2169         done in apply_poly_transforms.
2170
2171 2009-07-17  Konrad Trifunovic  <konrad.trifunovic@gmail.com>
2172
2173         * graphite-dependences.c (build_lexicographically_gt_constraint):
2174         Replace RES parameter with *RES.
2175         (dependence_polyhedron_1): Pass an address of the parameter RES
2176         instead of value of RES.
2177
2178 2009-07-16  Sebastian Pop  <sebastian.pop@amd.com>
2179
2180         * graphite.c (graphite_finalize): Fix comment.
2181         (graphite_transform_loops): Reset scev info after code generation
2182         of each scop.
2183
2184 2009-07-16  Sebastian Pop  <sebastian.pop@amd.com>
2185
2186         * graphite.c (graphite_finalize): Call scev_reset.
2187
2188 2009-07-16  Sebastian Pop  <sebastian.pop@amd.com>
2189
2190         * graphite-clast-to-gimple.c (compute_cloog_iv_types): Do not create
2191         GBB_CLOOG_IV_TYPES hash table twice.
2192         * graphite-sese-to-poly.c (free_gimple_bb): Call free_data_refs.
2193         (add_condition_to_domain): Clear GMP values.
2194
2195 2009-07-16  Sebastian Pop  <sebastian.pop@amd.com>
2196
2197         * graphite-dependences.c: Fix formatting.
2198         * graphite-poly.c (free_poly_dr): Also free PDR_DATA_CONTAINER.
2199         (pbb_number_of_iterations): Free ppl_Linear_Expression.
2200         * graphite-sese-to-poly.c: Fix formatting.
2201         * graphite.c (graphite_transform_loops): Create the hash table
2202         after the early return.
2203
2204 2009-07-16  Sebastian Pop  <sebastian.pop@amd.com>
2205
2206         * gcc.dg/graphite/id-14.c: New.
2207         * gcc.dg/graphite/pr40157.c: New.
2208         * gfortran.dg/graphite/id-11.f: New.
2209
2210 2009-07-16  Sebastian Pop  <sebastian.pop@amd.com>
2211
2212         * graphite-sese-to-poly.c (nb_pbbs_in_loops): New.
2213         (build_poly_scop): Return false when there are no pbbs within
2214         loops to avoid to pass to cloog scops with no loops.
2215
2216 2009-07-16  Sebastian Pop  <sebastian.pop@amd.com>
2217
2218         * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons): Avoid
2219         useless test "i % 2".
2220         (build_pbb_scattering_polyhedrons): Fix formatting.
2221         (build_poly_dr): Same.
2222         * graphite.c (graphite_transform_loops): Restructure.
2223
2224 2009-07-14  Razya Ladelsky  <razya@il.ibm.com>
2225
2226         * tree-ssa-loop-manip.c (rewrite_phi_with_iv): Remove
2227         reduction_list parameter.
2228         (rewrite_all_phi_nodes_with_iv): Same.
2229         (canonicalize_loop_ivs): Same.
2230         * tree-parloops.c (struct brli): Removed.
2231         (build_reduction_list_info): Removed.
2232         (build_new_reduction): New.
2233         (analyze_reduction_list): Removed.
2234         (gather_scalar_reductions): Find reductions instead of phi
2235         nodes that can't be canonicalized.
2236         (try_create_reduction_list): Remove reduction_list parameter.
2237         (gen_parallel_loop): Same.
2238         (parallelize_loops): Remove analyze_reductions variable,
2239         initialization and free.
2240         Change reduction_list htab initialization to reduction_info
2241         elements instead of ssa names.
2242         Call try_create_reduction_list and gen_parallel_loop without
2243         analyzed_reduction argument.
2244         * graphite-clast-to-gimple (graphite_loop_normal_form): Call
2245         canonicalize_loop_ivs with one less argument.
2246         * tree-flow.h (canonicalize_loop_ivs): Remove one argument.
2247
2248 2009-07-14  Konrad Trifunovic <konrad.trifunovic@gmail.com>
2249
2250         * graphite-dependences.c (new_poly_dr_pair): New.
2251         (dependence_polyhedron): Renamed into dependence_polyhedron_1.
2252         (new_poly_dr_pair): New.
2253         (eq_poly_dr_pair_p): New.
2254         (hash_poly_dr_pair_p): New.
2255         * graphite-dependences.h (struct poly_dr_pair): New.
2256         (eq_poly_dr_pair_p): Declared.
2257         (hash_poly_dr_pair_p): Declared.
2258         * graphite-poly.c (new_scop): Initialize SCOP_ORIGINAL_PDR_PAIRS.
2259         (free_scop): Free SCOP_ORIGINAL_PDR_PAIRS.
2260         * graphite-poly.h (struct scop): Add original_pdr_pairs field.
2261         * Makefile.in (graphite-poly.o): Add dependence on
2262         graphite-dependences.h.
2263
2264 2009-07-14  Sebastian Pop  <sebastian.pop@amd.com>
2265
2266         * graphite-scop-detection.c (graphite_can_represent_scev): Do not let
2267         polynomials of degree > 1 pass to Graphite.
2268         * tree-chrec.c (scev_is_linear_expression): Call
2269         evolution_function_is_affine_multivariate_p.
2270         * gfortran.dg/graphite/id-10.f90: New.
2271
2272 2009-07-14  Sebastian Pop  <sebastian.pop@amd.com>
2273
2274         * tree-scalar-evolution.c (compute_overall_effect_of_inner_loop):
2275         Instantiate scevs varying in outer loops.
2276         * gfortran.dg/graphite/id-9.f: Correct testcase.
2277
2278 2009-07-14  Sebastian Pop  <sebastian.pop@amd.com>
2279
2280         * graphite-sese-to-poly.c (build_loop_iteration_domains): Do not insert
2281         redundant constraint.
2282
2283 2009-07-14  Sebastian Pop  <sebastian.pop@amd.com>
2284
2285         * gcc.dg/graphite/graphite.exp: Fix comments.
2286         * gfortran.dg/graphite/graphite.exp: Trigger actions
2287         based on the file names as in the C testsuite.
2288         * gfortran.dg/graphite/block-1.f90: Fix patterns.
2289         * gfortran.dg/graphite/block-2.f: Same.
2290         * gfortran.dg/graphite/block-3.f90: Same.
2291         * gfortran.dg/graphite/block-4.f90: Same.
2292         * gfortran.dg/graphite/id-1.f90: Same.
2293         * gfortran.dg/graphite/id-2.f90: Same.
2294         * gfortran.dg/graphite/id-3.f90: Same.
2295         * gfortran.dg/graphite/id-4.f90: Same.
2296         * gfortran.dg/graphite/id-6.f: Same.
2297         * gfortran.dg/graphite/id-9.f: Same.
2298         * gfortran.dg/graphite/interchange-1.f: Same.
2299         * gfortran.dg/graphite/interchange-2.f: Same.
2300         * gfortran.dg/graphite/scop-1.f: Same.
2301
2302 2009-07-14  Sebastian Pop  <sebastian.pop@amd.com>
2303
2304         * sese.c (expand_scalar_variables_call): New.
2305         (expand_scalar_variables_ssa_name): Handle calls in expander.
2306
2307 2009-07-13  Sebastian Pop  <sebastian.pop@amd.com>
2308
2309         * gcc.dg/graphite/graphite_autopar/force-parallel-6.c:
2310         Expect to see the pattern twice.
2311         * gcc.dg/graphite/interchange-0.c: Un-XFAIL.
2312         * gcc.dg/graphite/interchange-5.c: Same.
2313         * gcc.dg/graphite/interchange-6.c: Same.
2314
2315 2009-07-13  Sebastian Pop  <sebastian.pop@amd.com>
2316
2317         * gcc.dg/graphite/id-10.c: New.
2318         * gcc.dg/graphite/id-12.c: New.
2319         * gfortran.dg/graphite/id-7.f: New.
2320         * gfortran.dg/graphite/id-8.f: New.
2321
2322 2009-07-13  Sebastian Pop  <sebastian.pop@amd.com>
2323
2324         * graphite-sese-to-poly.c (pdr_add_data_dimensions): Fix division by
2325         zero.
2326
2327 2009-07-13  Sebastian Pop  <sebastian.pop@amd.com>
2328
2329         * sese.c (rename_variables_in_stmt): Call fold_convert during renaming.
2330
2331 2009-07-13  Sebastian Pop  <sebastian.pop@amd.com>
2332
2333         * sese.c (expand_scalar_variables_stmt): Avoid unnecessary expansion.
2334
2335 2009-07-10  Sebastian Pop  <sebastian.pop@amd.com>
2336
2337         * graphite-sese-to-poly.c (pdr_add_memory_accesses): Fix order of
2338         building PDR subscripts.
2339
2340 2009-07-10  Sebastian Pop  <sebastian.pop@amd.com>
2341
2342         * graphite-sese-to-poly.c (pdr_add_data_dimensions): Fix the
2343         computation of array sizes.
2344
2345 2009-07-10  Sebastian Pop  <sebastian.pop@amd.com>
2346
2347         * graphite-sese-to-poly.c (add_param_constraints): Disabled.
2348
2349 2009-07-10  Tobias Grosser  <grosser@fim.uni-passau.de>
2350
2351         * graphite-dependences.c (map_into_dep_poly, map_dr_into_dep_poly,
2352         build_pairwise_constraint, dr_equality_constraints,
2353         build_pairwise_scheduling_equality,
2354         build_pairwise_scheduling_inequality, lexicographically_gt_p,
2355         build_lexicographically_gt_constraint, dependence_polyhedron,
2356         graphite_legal_transform_dr, graphite_carried_dependence_level_k):
2357         Move from NNC_Polyhedron to C_Polyhedron.
2358         * graphite-interchange.c (compute_array_size_poly,
2359         gather_access_strides): Dito.
2360         * graphite-poly.c (apply_poly_transforms, new_poly_dr, free_poly_bb,
2361         free_scop, pbb_number_of_iterations): Dito.
2362         * graphite-poly.h (struct poly_dr, pdr_nb_subscripts, struct poly_bb,
2363         pbb_dim_iter_domain, struct scop): Dito.
2364         * graphite-ppl.c (new_Constraint_System_from_Cloog_Matrix,
2365         new_Cloog_Domain_from_ppl_Polyhedron,
2366         new_Cloog_Domain_from_ppl_Pointset_Powerset, ppl_set_coef_gmp,
2367         ppl_insert_dimensions_pointset, ppl_insert_dimensions_pointset,
2368         ppl_strip_loop, ppl_strip_loop, ppl_print_polyhedron_matrix,
2369         ppl_print_powerset_matrix, debug_ppl_polyhedron_matrix,
2370         debug_ppl_powerset_matrix, ppl_read_polyhedron_matrix): Dito.
2371         * graphite-ppl.h (ppl_Pointset_Powerset_C_Polyhedron_t,
2372         new_C_Polyhedron_from_Cloog_Matrix, ppl_print_powerset_matrix,
2373         debug_ppl_powerset_matrix, ppl_insert_dimensions_pointset): Dito.
2374         * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons,
2375         build_loop_iteration_domains, ppl_constraint_type_from_tree_code,
2376         add_condition_to_domain, add_condition_to_pbb, build_scop_context,
2377         build_scop_iteration_domain, build_poly_dr): Dito
2378
2379 2009-07-09  Sebastian Pop  <sebastian.pop@amd.com>
2380
2381         * gcc.dg/graphite/graphite.exp: Added a rule to execute
2382         run-id-*.c files.
2383         * gcc.dg/graphite/run-id-1.c: New.
2384
2385 2009-07-09  Sebastian Pop  <sebastian.pop@amd.com>
2386
2387         * graphite-sese-to-poly.c (build_loop_iteration_domains): Add the
2388         positivity constraint on the symbolic number of iterations.
2389
2390 2009-07-09  Sebastian Pop  <sebastian.pop@amd.com>
2391
2392         * graphite-sese-to-poly.c (build_loop_iteration_domains): Rewrite.
2393
2394 2009-07-09  Sebastian Pop  <sebastian.pop@amd.com>
2395             Tobias Grosser  <grosser@fim.uni-passau.de>
2396
2397         * graphite-clast-to-gimple.c (build_scop_context): Removed.
2398         (build_cloog_prog): Directly use SCOP_CONTEXT.
2399         * graphite-poly.c (new_scop): Initialize SCOP_CONTEXT.
2400         (free_scop): Free SCOP_CONTEXT.
2401         (print_scop_context): New.
2402         (print_scop): Call print_scop_context.
2403         (debug_scop_context): New.
2404         * graphite-poly.h (print_scop_context, debug_scop_context): Declared.
2405         (struct scop): Added field context.
2406         (SCOP_CONTEXT): New.
2407         * graphite-sese-to-poly.c (add_param_constraints): New.
2408         (build_scop_context): New.
2409         (build_poly_scop): Call build_scop_context.
2410
2411 2009-07-09  Sebastian Pop  <sebastian.pop@amd.com>
2412
2413         * graphite-clast-to-gimple.c (gmp_cst_to_tree): Moved...
2414         * graphite-ppl.c (ppl_set_inhomogeneous_gmp, ppl_set_coef_gmp): New.
2415         (ppl_set_inhomogeneous, ppl_set_coef): Moved...
2416         * graphite-ppl.h: Include double-int.h and tree.h.
2417         (ppl_set_inhomogeneous_gmp, ppl_set_coef_gmp): Declared.
2418         (ppl_set_inhomogeneous, ppl_set_coef): ...here.
2419         (gmp_cst_to_tree): ...here.  Reimplemented using mpz_get_double_int.
2420         (tree_int_to_gmp, ppl_set_inhomogeneous_tree, ppl_set_coef_tree): New.
2421
2422 2009-07-09  Sebastian Pop  <sebastian.pop@amd.com>
2423
2424         * graphite-clast-to-gimple.c (clast_to_gcc_expression_red): Generate
2425         POINTER_PLUS_EXPR for pointer types.
2426         (clast_to_gcc_expression): Same.
2427
2428 2009-07-09  Sebastian Pop  <sebastian.pop@amd.com>
2429
2430         * graphite-poly.c (print_scattering_function): Early return when
2431         PBB_TRANSFORMED_SCATTERING is not initialized.
2432         (print_pbb_domain): Early return when PBB_DOMAIN is not initialized.
2433
2434 2009-07-08  Sebastian Pop  <sebastian.pop@amd.com>
2435
2436         * tree-parloops.c (analyze_reduction_list): Remove unused variable
2437         to fix bootstrap.
2438
2439 2009-07-08  Razya Ladelsky  <razya@il.ibm.com>
2440
2441         * tree-parloops.c (analyze_reduction_list): Change return
2442         value to void.
2443         (try_create_reduction_list): Move the call to
2444         analyze_reduction_list to the beginining.
2445         Call reduction_phi with analyzed_reductions as argument
2446         instead of reduction_list.
2447
2448 2009-07-08  Tobias Grosser  <grosser@fim.uni-passau.de>
2449
2450         *  Merge from mainline (r148296:149346)
2451
2452 2009-07-07  Sebastian Pop  <sebastian.pop@amd.com>
2453
2454         * graphite-scop-detection.c (graphite_can_represent_init): New.
2455         (graphite_can_represent_scev): Call graphite_can_represent_init:
2456         check that the initial value does not contain multiplications of
2457         parameters.
2458         (stmt_has_simple_data_refs_p): New.
2459         (stmt_simple_for_scop_p): Call stmt_simple_for_scop_p.
2460         (is_simple_operand): Fix formatting.
2461         * graphite-sese-to-poly.c (try_generate_gimple_bb): Fix formatting.
2462
2463 2009-07-07  Sebastian Pop  <sebastian.pop@amd.com>
2464
2465         * gcc.dg/graphite/id-13.c: New.
2466         * graphite-sese-to-poly.c (graphite_stmt_p): Do not call
2467         analyze_scalar_evolution, use scalar_evolution_in_region.
2468         (scan_tree_for_params_right_scev): Add extra assert.
2469         (parameter_index_in_region_1): Split from parameter_index_in_region.
2470         (idx_record_params): Use scalar_evolution_in_region.
2471         (find_params_in_bb): Same.
2472         (find_scop_parameters): Same.
2473         (build_loop_iteration_domains): Same.
2474         (create_linear_expr_from_tree): Same.
2475         * sese.c (scalar_evolution_in_region): New.
2476         * sese.h (scalar_evolution_in_region): Declared.
2477         (defined_in_sese_p): New.
2478         * tree-scalar-evolution.c (compute_overall_effect_of_inner_loop): Not
2479         static anymore.
2480         * tree-scalar-evolution.h (compute_overall_effect_of_inner_loop):
2481         Declared.
2482
2483 2009-07-07  Sebastian Pop  <sebastian.pop@amd.com>
2484
2485         * Makefile.in: Replace dependences on tree-chrec.h with SCEV_H.
2486         TREE_DATA_REF_H also implies SCEV_H.
2487
2488 2009-07-07  Sebastian Pop  <sebastian.pop@amd.com>
2489
2490         * graphite-poly.c (print_scop_params): New.
2491         (print_scop): Call print_scop_params.
2492         (debug_scop_params): New.
2493         * graphite-poly.h (print_scop_params, debug_scop_params): Declared.
2494
2495 2009-07-07  Li Feng  <nemokingdom@gmail.com>
2496
2497         * gcc.dg/graphite/graphite_autopar/force-parallel-4.c: New.
2498         * gcc.dg/graphite/graphite_autopar/force-parallel-5.c: New.
2499         * gcc.dg/graphite/graphite_autopar/force-parallel-6.c: New.
2500         * gcc.dg/graphite/graphite_autopar/force-parallel-7.c: New.
2501         * gcc.dg/graphite/graphite_autopar/force-parallel-8.c: New.
2502         * gcc.dg/graphite/graphite_autopar/force-parallel-9.c: New.
2503
2504 2009-07-07  Li Feng  <nemokingdom@gmail.com>
2505
2506         * graphite-clast-to-gimple.c (mark_loops_parallel): Dump information
2507         for dependency checking part.
2508         * gcc.dg/graphite/graphite_autopar/force-parallel-1.c: Add
2509         tests for dependency checking.
2510         * gcc.dg/graphite/graphite_autopar/force-parallel-2.c: Ditto.
2511         * gcc.dg/graphite/graphite_autopar/force-parallel-3.c: Ditto.
2512         * gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: Add
2513         flag -fdump-tree-graphite-all for autopar testsuites.
2514
2515 2009-07-06  Sebastian Pop  <sebastian.pop@amd.com>
2516
2517         * Makefile.in (tree-ssa-loop-manip.o): Depends on langhooks.h.
2518         * tree-parloops.c (rewrite_phi_with_iv, rewrite_all_phi_nodes_with_iv,
2519         canonicalize_loop_ivs): Moved...
2520         * tree-ssa-loop-manip.c: ... here.  Include langhooks.h.
2521
2522 2009-07-06  Sebastian Pop  <sebastian.pop@amd.com>
2523
2524         * tree-parloops.c (try_create_reduction_list): Pass an extra
2525         argument analyzed_reductions.  Call analyze_reduction_list.
2526         (gen_parallel_loop): Do not call analyze_reduction_list.
2527         (parallelize_loops): Init and finalize analyzed_reductions.
2528
2529 2009-07-06  Li Feng  <nemokingdom@gmail.com>
2530
2531         * gcc.dg/graphite/graphite_autopar/graphite_autopar.exp:
2532         Added flag -fno-loop-strip-mine for autopar testcase.
2533
2534 2009-07-04  Li Feng  <nemokingdom@gmail.com>
2535
2536         * graphite-dependences.c (graphite_carried_dependence_level_k): Use
2537         transformed scattering dimension instead of unmatch orignal when
2538         calling dependence_polyhedron.
2539
2540 2009-06-30  Sebastian Pop  <sebastian.pop@amd.com>
2541
2542         * opts.c (decode_options): Enable flag_loop_strip_mine at -O2.
2543
2544 2009-06-30  Sebastian Pop  <sebastian.pop@amd.com>
2545
2546         * graphite-poly.c (pbb_number_of_iterations): Check for returned
2547         value 1 from ppl_Pointset_Powerset_NNC_Polyhedron_maximize.
2548
2549 2009-06-30  Sebastian Pop  <sebastian.pop@amd.com>
2550
2551         * graphite-blocking.c (pbb_strip_mine_profitable_p): New.
2552         (pbb_do_strip_mine): Call pbb_strip_mine_profitable_p.
2553         * graphite-poly.c (pbb_number_of_iterations): New.
2554         * graphite-poly.h (pbb_number_of_iterations): Declared.
2555         (pbb_iterator_dim, pbb_parameter_dim): New.
2556
2557 2009-06-29  Sebastian Pop  <sebastian.pop@amd.com>
2558
2559         * graphite-clast-to-gimple.c (graphite_create_new_loop): Revert the
2560         last commit on type of lower and upper bound of loops.
2561
2562 2009-06-29  Li Feng  <nemokingdom@gmail.com>
2563
2564         * Makefile.in (graphite-clast-to-gimple.o): Added dependence on
2565         graphite-dependences.h.
2566         * graphite-clast-to-gimple.c (new_bb_pbb_def): New.
2567         (mark_bb_with_pbb): New.
2568         (get_stmtfor_depth): New.
2569         (find_pbb_via_hash): New.
2570         (dependency_in_loop_p): New.
2571         (mark_loops_parallel): New.
2572         (free_aux_in_new_loops): New.
2573         (translate_clast): Add parameter BB_PBB_MAPPING.  Mark newly created
2574         bb with it's relevant pbb. Mark newly created loops.  Remove mark
2575         innermost loop parallel without checking.
2576         (gloog): Add parameter BB_PBB_MAPPING.
2577         * graphite-clast-to-gimple.h (struct bb_pbb_def): New.
2578         (gloog): Change declaration.
2579         (mark_loop_parallel): Make extern.
2580         (free_aux_in_new_loops): Declare.
2581         (bb_pbb_map_hash): New.
2582         (eq_bb_pbb_map): New.
2583         * graphite.c (graphite_transform_loops): Added BB_PBB_MAPPING. Trigger
2584         auto parallelization when flag_graphite_force_parallel is set.
2585         (graphite_finalize): Added free_aux_in_new_loops.
2586         * tree-parloops.c (parallelize_loops): Only generate parallel code for
2587         the innermost loop that marked parallel.  Use
2588         flag_graphite_force_parallel instead of loop->can_be_parallel.
2589         (loop_parallel_p): Move inner most checking out of function.
2590
2591 2009-06-26  Sebastian Pop  <sebastian.pop@amd.com>
2592
2593         * graphite-clast-to-gimple.c (graphite_create_new_loop): Make the
2594         type of lower and upper bound of loops signed long int.
2595
2596 2009-06-26  Sebastian Pop  <sebastian.pop@amd.com>
2597
2598         * cfgloopmanip.c (create_empty_loop_on_edge): Gimplify the loop exit
2599         expression outside the loop.
2600
2601 2009-06-26  Sebastian Pop  <sebastian.pop@amd.com>
2602
2603         * gcc.dg/graphite/interchange-8.c: New.
2604
2605 2009-06-26  Sebastian Pop  <sebastian.pop@amd.com>
2606
2607         * gcc.dg/graphite/interchange-0.c: XFailed.
2608         * gcc.dg/graphite/interchange-5.c: XFailed.
2609         * gcc.dg/graphite/interchange-6.c: XFailed.
2610
2611 2009-06-26  Sebastian Pop  <sebastian.pop@amd.com>
2612
2613         * graphite-interchange.c (compute_array_size_poly): The end of the
2614         recursion should return 1.
2615
2616 2009-06-26  Sebastian Pop  <sebastian.pop@amd.com>
2617
2618         * graphite-interchange.c (compute_array_size_cstr): Allow the
2619         subscript multiplier to be -1.
2620         (compute_array_size): Use PDR_DATA_CONTAINER and not PDR_ACCESSES.
2621         * graphite-poly.c (new_poly_dr): Takes an extra argument for the
2622         data_container.  Initializes PDR_DATA_CONTAINER.
2623         (print_pdr_access_layout): New.
2624         (print_pdr): Call print_pdr_access_layout.  Print PDR_DATA_CONTAINER.
2625         * graphite-poly.h (struct poly_dr): Adjust comment.  Add a new field
2626         data_container.
2627         (PDR_DATA_CONTAINER): New.
2628         (new_poly_dr): Update declaration.
2629         * graphite-sese-to-poly.c (pdr_add_data_dimensions): New.
2630         (build_poly_dr): Call pdr_add_data_dimensions.
2631
2632 2009-06-26  Sebastian Pop  <sebastian.pop@amd.com>
2633
2634         * graphite-poly.h (struct poly_dr): Fix comment.
2635         * graphite-sese-to-poly.c (pdr_add_alias_set): New.
2636         (pdr_add_memory_accesses): New.
2637         (build_poly_dr): Call pdr_add_memory_accesses and pdr_add_alias_set.
2638
2639 2009-06-26  Sebastian Pop  <sebastian.pop@amd.com>
2640
2641         * graphite-poly.c (print_pdrs, debug_pdrs): New.
2642         (print_pbb): Add call to print_pdrs.
2643         * graphite-poly.h (print_pdrs, debug_pdrs): Declared.
2644
2645 2009-06-24  Konrad Trifunovic <konrad.trifunovic@gmail.com>
2646             Li Feng <nemokingdom@gmail.com>
2647
2648         * graphite-dependences.c (graphite_carried_dependence_level_k): New.
2649         (dependency_between_pbbs_p): New.
2650         (lexicographically_gt_p): Assure !empty_p before polyhedron
2651         intersection assign.
2652         (build_lexicographically_gt_constraint): Correct lexicographically
2653         judging.
2654         * graphite-dependences.h: New.
2655         * Makefile.in (graphite-dependences.o): Add graphite-dependences.h.
2656
2657 2009-06-24  Sebastian Pop  <sebastian.pop@amd.com>
2658
2659         * graphite-clast-to-gimple.c (print_clast_stmt): New.
2660         (gloog): Print to dump_file the generated clast.
2661         * graphite-clast-to-gimple.h (print_clast_stmt): Declared.
2662         * graphite-interchange.c (pbb_do_interchange): Fix dump formatting.
2663
2664 2009-06-24  Sebastian Pop  <sebastian.pop@amd.com>
2665
2666         * graphite-poly.c (extend_scattering): Increment
2667         PBB_NB_LOCAL_VARIABLES by the number of added dimensions.
2668
2669 2009-06-24  Sebastian Pop  <sebastian.pop@amd.com>
2670
2671         * graphite-interchange.c (compute_array_size_poly): Added exit of
2672         recursion condition.  Continue iterating even after the first equality.
2673         (compute_array_size): Same.
2674
2675 2009-06-24  Li Feng  <nemokingdom@gmail.com>
2676
2677         * gcc.dg/graphite/graphite_autopar/force-parallel-1.c: Update
2678         -fdump-tree-final_cleanup to -fdump-tree-optimized.
2679         * gcc.dg/graphite/graphite_autopar/force-parallel-2.c: Ditto.
2680         * gcc.dg/graphite/graphite_autopar/force-parallel-3.c: Ditto.
2681         * gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: Ditto.
2682
2683 2009-06-23  Sebastian Pop  <sebastian.pop@amd.com>
2684
2685         * sese.c (expand_scalar_variables_stmt): Expand scalar variables
2686         only when the use verifies is_gimple_reg.
2687
2688 2009-06-23  Sebastian Pop  <sebastian.pop@amd.com>
2689
2690         * graphite-clast-to-gimple.c (build_cloog_prog): Fix memory corruption.
2691         Allocate scaldims after call to unify_scattering_dimensions.
2692
2693 2009-06-23  Sebastian Pop  <sebastian.pop@amd.com>
2694
2695         * graphite-clast-to-gimple.c (translate_clast): Fix memory leak.
2696
2697 2009-06-23  Sebastian Pop  <sebastian.pop@amd.com>
2698             Albert Cohen  <albert.cohen@inria.fr>
2699
2700         * graphite-blocking.c (pbb_strip_mine_loop_depth): Do not use local
2701         variables for the strip mining.
2702
2703 2009-06-23  Sebastian Pop  <sebastian.pop@amd.com>
2704             Pranav Garg  <pranav.garg2107@gmail.com>
2705
2706         * Makefile.in (OBJS-common): Added graphite-blocking.o.
2707         (graphite-sese-to-poly.o): Moved down to be in lexicographical order.
2708         (graphite-blocking.o): New rule.
2709         (graphite-poly.o, graphite-ppl.o): Moved to be in lexicographical order.
2710         * graphite-blocking.c: New.
2711         * graphite-poly.c (apply_poly_transforms): Call scop_do_strip_mine for
2712         flag_loop_strip_mine.
2713         (psct_scattering_dim_for_loop_depth): New.
2714         * graphite-poly.h (scop_do_strip_mine): Declared.
2715         (psct_add_local_variable): Increment PBB_NB_LOCAL_VARIABLES.
2716         * tree-ssa-loop.c (gate_graphite_transforms): Do not fail when using
2717         flag_loop_strip_mine.
2718
2719 2009-06-23  Sebastian Pop  <sebastian.pop@amd.com>
2720
2721         * graphite-poly.c (extend_scattering): Avoid initializing and freeing
2722         a GMP value and a PPL coefficient at each iteration of a loop.
2723
2724 2009-06-23  Sebastian Pop  <sebastian.pop@amd.com>
2725
2726         * graphite-dependences.c (dependence_polyhedron): Do not use
2727         pbb_nb_scattering_dims anymore.  Use pbb_nb_scattering_orig and
2728         pbb_nb_scattering_transform.
2729         (graphite_legal_transform_dr): Same.
2730         * graphite-poly.c (extend_scattering): Same.
2731         (unify_scattering_dimensions): Same.
2732         (print_scattering_function): Same.
2733         (new_poly_bb): Initialize PBB_NB_SCATTERING_TRANSFORM and
2734         PBB_NB_LOCAL_VARIABLES.
2735         * graphite-poly.h (pbb_nb_scattering): Removed declaration.
2736         (struct poly_bb): Added nb_local_variables and nb_scattering_transform.
2737         (PBB_NB_LOCAL_VARIABLES, PBB_NB_SCATTERING_TRANSFORM): New.
2738         (pbb_nb_scattering_orig, pbb_nb_scattering_transform): New.
2739         (pbb_nb_scattering_dims, pbb_nb_scattering): Removed.
2740         (pbb_nb_scattering_transform): New.
2741         (pbb_nb_local_vars): Return PBB_NB_LOCAL_VARIABLES.
2742         (psco_scattering_dim): Add assert on parameters.
2743         (psct_scattering_dim): Same.
2744         (psct_scattering_dim_for_loop_depth): Declared.
2745         (psct_local_var_dim): New.
2746         (psco_iterator_dim, psco_parameter_dim): Add assert on parameters.
2747         (psct_iterator_dim, psct_parameter_dim): Same.  To maintain the
2748         correct layout, call pbb_nb_local_vars.
2749         (psct_add_local_variable, psct_add_scattering_dimension): New.
2750         * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons):
2751         Initialize PBB_NB_SCATTERING_TRANSFORM.
2752
2753 2009-06-23  Sebastian Pop  <sebastian.pop@amd.com>
2754
2755         * graphite-ppl.c (set_inhomogeneous): Renamed ppl_set_inhomogeneous.
2756         (set_coef): Renamed ppl_set_coef.
2757         * graphite-ppl.h (ppl_set_inhomogeneous, ppl_set_coef): Declared.
2758
2759 2009-06-23  Sebastian Pop  <sebastian.pop@amd.com>
2760
2761         * graphite-dependences.c (build_pairwise_scheduling_inequality): Don't
2762         test a boolean against 1.
2763         * graphite-interchange.c (pbb_interchange_loop_depths): Do not build
2764         a new polyhedron for the PBB_TRANSFORMED_SCATTERING.
2765         (pbb_do_interchange): Returns true when a transform has been performed.
2766         (scop_do_interchange): Same.
2767         * graphite-poly.c (apply_poly_transforms): Use the return value of
2768         scop_do_interchange.
2769         * graphite-poly.h (scop_do_interchange): Update declaration.
2770
2771 2009-06-23  Tobias Grosser  <grosser@fim.uni-passau.de>
2772
2773         * graphite-clast-to-gimple.c (gloog): Reset loop->aux right
2774         after last use.
2775         * sese.c (sese_reset_aux_in_loops): New.
2776         * sese.h (sese_reset_aux_in_loops): New.
2777
2778 2009-06-19  Sebastian Pop  <sebastian.pop@amd.com>
2779
2780         * graphite-sese-to-poly.c (scan_tree_for_params_int): Pass in the
2781         multiplier and multiply the constant by the multiplier.
2782         (scan_tree_for_params): Bound the multiplier to its MULT_EXPR.
2783         (build_poly_dr): Do not use the multiplier to define the subscript.
2784
2785 2009-06-19  Sebastian Pop  <sebastian.pop@amd.com>
2786
2787         * graphite-poly.c (new_poly_dr): Pass an extra argument for the
2788         compiler's data reference.  Initialize PDR_CDR.
2789         (print_pdr): Call dump_data_reference.
2790         * graphite-poly.h (struct poly_dr): Rename black_box into pbb.
2791         Add compiler_dr field.
2792         (PDR_BB): Renamed PDR_PBB.
2793         (PDR_CDR): New.
2794         * graphite-sese-to-poly.c (build_poly_dr): Pass to new_poly_dr
2795         GCC's data reference representation.
2796         * tree-data-ref.c (debug_data_references, debug_data_reference): New.
2797         * tree-data-ref.h (debug_data_references, debug_data_reference): Decl.
2798
2799 2009-06-19  Sebastian Pop  <sebastian.pop@amd.com>
2800
2801         * graphite-poly.c (print_scattering_function): Also print the layout.
2802         * graphite-poly.h (pbb_nb_local_vars): New.
2803
2804 2009-06-19  Sebastian Pop  <sebastian.pop@amd.com>
2805
2806         * graphite-poly.c (print_pbb_domain): Also print the layout names.
2807
2808 2009-06-19  Sebastian Pop  <sebastian.pop@amd.com>
2809
2810         * graphite-poly.c (print_pdr, debug_pdr): New.
2811         * graphite-poly.h (print_pdr, debug_pdr): Declared.
2812         (PDR_BASE): Removed.
2813
2814 2009-06-18  Sebastian Pop  <sebastian.pop@amd.com>
2815
2816         * gcc.dg/graphite/interchange-{1..7}.c: New avatars of
2817         ltrans-{1..6,8}.c.
2818
2819 2009-06-18  Sebastian Pop  <sebastian.pop@amd.com>
2820
2821         * graphite-interchange.c (compute_subscript): Allow also -1 in the
2822         subscript identification column.
2823         (pbb_do_interchange): Print to dump_file that some loops "will be
2824         interchanged".  Rely on that chain of characters in the testcases.
2825         * gcc.dg/graphite/interchange-0.c: New.
2826         * gcc.dg/graphite/graphite.exp: Iterate over the testsuite
2827         interchange-*.c files and compile them with -floop-interchange.
2828
2829 2009-06-18  Pranav Garg  <pranav.garg2107@gmail.com>
2830
2831         * graphite-interchange.c (interchange_profitable_p): Renamed
2832         pbb_interchange_profitable_p.
2833
2834 2009-06-18  Sebastian Pop  <sebastian.pop@amd.com>
2835             Harsha Jagasia  <harsha.jagasia@amd.com>
2836             Pranav Garg  <pranav.garg2107@gmail.com>
2837
2838         * graphite-interchange.c (interchange_profitable_p): Make static.
2839         (pbb_interchange_loop_depths, pbb_do_interchange,
2840         scop_do_interchange): New.
2841         * graphite-poly.c (apply_poly_transforms): Call scop_do_interchange
2842         for flag_loop_interchange.
2843         * graphite-poly.h (scop_do_interchange): Declared.
2844         * tree-ssa-loop.c (gate_graphite_transforms): Do not fail when
2845         flag_loop_interchange is used.
2846
2847 2009-06-18  Sebastian Pop  <sebastian.pop@amd.com>
2848
2849         * graphite-dependences.c (dependence_polyhedron): Update use of
2850         pbb_nb_scattering_dims.
2851         * graphite-poly.h (pbb_nb_scattering_dims): Do not pass SCOP.
2852         (pbb_nb_scattering): Update use of pbb_nb_scattering_dims.
2853         (psco_scattering_dim, psct_scattering_dim, psco_iterator_dim,
2854         psct_iterator_dim, psco_parameter_dim, psct_parameter_dim): New.
2855
2856 2009-06-16  Sebastian Pop  <sebastian.pop@amd.com>
2857
2858         * graphite.c: Cleanup foo.
2859
2860 2009-06-16  Sebastian Pop  <sebastian.pop@amd.com>
2861
2862         * Merge from mainline (r143684:148293).
2863         * Disabled libpcp until it gets fixed.
2864
2865 2009-06-05  Sebastian Pop  <sebastian.pop@amd.com>
2866             Harsha Jagasia  <harsha.jagasia@amd.com>
2867
2868         * graphite-interchange.c: New.
2869         * Makefile.in (graphite-interchange.o): New.
2870         * graphite-poly.h (interchange_profitable_p): Declared.
2871         * graphite-ppl.h (value_max): New.
2872
2873 2009-06-04  Sebastian Pop  <sebastian.pop@amd.com>
2874
2875         * graphite-dependences.c (dependence_polyhedron): Use pdr_dim.
2876         * graphite-poly.h: Fix some comments.
2877         (pdr_dim): New.
2878         (pdr_scop): New.
2879
2880 2009-06-04  Sebastian Pop  <sebastian.pop@amd.com>
2881
2882         * graphite-poly.h
2883         (pdr_accessp_nb_subscripts): Renamed pdr_nb_subscripts.
2884         (pdr_accessp_nb_iterators): Renamed pdr_dim_iter_domain.
2885         (pdr_accessp_nb_params): Renamed pdr_nb_params.
2886         (pdr_accessp_alias_set_dim): Renamed pdr_alias_set_dim.
2887         (pdr_accessp_subscript_dim): Renamed pdr_subscript_dim.
2888         (pdr_accessp_iterator_dim): Renamed pdr_iterator_dim.
2889         (pdr_accessp_param_dim): Renamed pdr_parameter_dim.
2890         (pbb_nb_loops): Renamed pbb_dim_iter_domain.
2891         * graphite-clast-to-gimple.c: Same.
2892         * graphite-dependences.c: Same.
2893         * graphite-poly.c: Same.
2894         * graphite-sese-to-poly.c: Same.
2895
2896 2009-06-03  Sebastian Pop  <sebastian.pop@amd.com>
2897
2898         * graphite-clast-to-gimple.c (build_iv_mapping): Insert full
2899         expressions for an IV rename, as returned by clast_to_gcc_expression.
2900         (copy_renames): Rename new_name to expr.
2901         * sese.c (debug_rename_elt): Same.
2902         (get_rename): Same.
2903         (set_rename): Same.
2904         (sese_adjust_liveout_phis): Call force_gimple_operand before using
2905         the information from the rename map.
2906         (rename_variables_in_stmt): Same.
2907         (add_loop_exit_phis): Rename new_name to expr.
2908         (insert_loop_close_phis): Same.
2909         (add_guard_exit_phis): Same.  Call force_gimple_operand.
2910         * sese.h (struct rename_map_elt): Rename new_name to expr.
2911         (new_rename_map_elt): Same.
2912
2913 2009-06-03  Sebastian Pop  <sebastian.pop@amd.com>
2914
2915         * graphite-clast-to-gimple.c (build_iv_mapping): Use set_rename.
2916         * sese.c (set_rename): Make it extern.
2917         * sese.h (set_rename): Declared.
2918
2919 2009-06-03  Sebastian Pop  <sebastian.pop@amd.com>
2920
2921         * graphite-poly.c (extend_scattering): Free values.
2922         * graphite-ppl.c (new_Cloog_Domain_from_ppl_Pointset_Powerset):
2923         Free iterators.
2924         (ppl_print_powerset_matrix): Same.
2925         * graphite-scop-detection.c (free_scops_1): New.
2926         (limit_scops): Call free_scops_1.
2927         * graphite-sese-to-poly.c (build_scop_bbs_1): Free dom.
2928         (build_poly_dr): Free PPL coefficients.
2929         * tree-parloops.c (rewrite_all_phi_nodes_with_iv): Free bbs.
2930
2931 2009-06-02  Sebastian Pop  <sebastian.pop@amd.com>
2932
2933         * graphite-dependences.c: New.
2934         * graphite-data-ref.c: Removed.
2935         * graphite-data-ref.h: Removed.
2936         * Makefile.in (graphite-data-ref.o): Removed.
2937         (graphite-dependences.o): Added.
2938         * graphite-clast-to-gimple.c: Remove dependence on graphite-data-ref.h.
2939         * graphite-poly.c: Same.
2940         Move the data dependence testing to graphite-dependences.c.
2941
2942 2009-05-19  Tobias Grosser  <grosser@fim.uni-passau.de>
2943
2944         * graphite-scop-detection.c (graphite_can_represent_loop): Renamed
2945         from graphite_cannot_represent_loop. Code refactored.
2946         (scopdet_basic_block_info): Call graphite_can_represent_loop.
2947
2948 2009-05-17  Li Feng  <nemokingdom@gmail.com>
2949
2950         * gcc.dg/graphite/graphite_autopar/graphite_autopar.exp:
2951         Cover all the testcases (not only the filtered ones).
2952
2953 2009-05-17  Tobias Grosser  <grosser@fim.uni-passau.de>
2954
2955         * graphite-scop-detection.c (stmt_simple_for_scop_p): Remove
2956         unnecessary check. Update comments. Move check for REAL_TYPE here.
2957         (harmful_stmt_in_bb): Remove checks for conditions. This is already
2958         done in (stmt_simple_for_scop_p).
2959
2960 2009-05-14 Tobias Grosser  <grosser@fim.uni-passau.de>
2961
2962         * graphite.c (print_global_statistics): New.
2963         (print_graphite_scop_statistic): New.
2964         (print_graphite_statistics): New.
2965         (graphite_initialize, graphite_transform_loops): Print statistics.
2966         * graphite-scop-detection (build_scops): Print statistics.
2967         (print_graphite_scop_statistics): New.
2968         (print_graphite_statistics): New.
2969
2970 2009-05-13  Sebastian Pop  <sebastian.pop@amd.com>
2971
2972         * graphite-clast-to-gimple.c (struct clast_name_index): Removed.
2973         (debug_clast_name_index): Removed.
2974         (debug_clast_name_indexes_1): Removed.
2975         (debug_clast_name_indexes): Removed.
2976         (clast_name_index_elt_info): Removed.
2977         (eq_clast_name_indexes): Removed.
2978         (clast_name_to_index): Removed.
2979         (new_clast_name_index): Removed.
2980         (save_clast_name_index): Removed.
2981         (save_var_name): Moved...
2982         (init_sese_params_index): Removed.
2983         (clast_name_to_gcc): Remove use of name_tree.
2984         (initialize_cloog_names): Same.
2985         (gloog): Do not call init_sese_params_index.
2986         * graphite-sese-to-poly.c (save_var_name): ...here.
2987         (parameter_index_in_region): New.
2988         * sese.c (new_sese): Initialize SESE_PARAMS_NAMES.
2989         (parameter_index_in_region): Removed.
2990         (is_parameter): Remove use of name_tree.
2991         * sese.h (struct name_tree): Removed.
2992         (struct sese): Remove use of name_tree.  New field params_names.
2993         (SESE_PARAMS_NAMES): New.
2994         (SESE_PARAMS): Remove duplicate.
2995         (parameter_index_in_region): Removed.
2996         (sese_nb_params): Remove use of name_tree.
2997         (struct clast_name_index): New.
2998         (new_clast_name_index): New.
2999         (clast_name_to_index): New.
3000         (save_clast_name_index): New.
3001         (debug_clast_name_index): New.
3002         (debug_clast_name_indexes_1): New.
3003         (debug_clast_name_indexes): New.
3004         (clast_name_index_elt_info): New.
3005         (eq_clast_name_indexes): New.
3006
3007 2009-05-13  Sebastian Pop  <sebastian.pop@amd.com>
3008
3009         * graphite-clast-to-gimple.c (compute_cloog_iv_types_1): Call
3010         pbb_to_depth_to_oldiv.  Remove call to oldiv_for_loop.
3011         (graphite_loop_normal_form): Do not pass region.  Do not
3012         initialize SESE_OLDIVS.
3013         (build_graphite_loop_normal_form): Update call to
3014         graphite_loop_normal_form.
3015         * sese.c (debug_oldivs): Removed.
3016         (new_sese): Do not initialize SESE_OLDIVS.
3017         (free_sese): Do not free SESE_OLDIVS.
3018         (oldiv_for_loop): Removed.
3019         * sese.h (struct sese): Remove old_ivs.
3020         (SESE_OLDIVS): Removed.
3021         (oldiv_for_loop): Removed.
3022
3023 2009-05-13  Sebastian Pop  <sebastian.pop@amd.com>
3024
3025         * graphite-clast-to-gimple.c (clast_name_to_gcc): Pass newivs,
3026         remove ivstack.  Remove call to loop_iv_stack_get_iv_from_name,
3027         replaced by a call to newivs_to_depth_to_newiv.
3028         (clast_to_gcc_expression): Pass newivs, remove ivstack.
3029         (clast_to_gcc_expression_red): Same.
3030         (gcc_type_for_clast_expr): Same.
3031         (gcc_type_for_clast_eq): Same.
3032         (graphite_translate_clast_equation): Same.
3033         (graphite_create_guard_cond_expr): Same.
3034         (graphite_create_new_guard): Same.
3035         (graphite_create_new_loop): Same.
3036         (build_iv_mapping): Same.
3037         (translate_clast): Same.
3038         (gloog): Same.
3039         (loop_iv_stack_patch_for_consts): Removed.  *
3040         sese.c (iv_stack_entry_is_constant): Removed.
3041         (iv_stack_entry_is_iv): Removed.
3042         (loop_iv_stack_push_iv): Removed.
3043         (loop_iv_stack_insert_constant): Removed.
3044         (loop_iv_stack_pop): Removed.
3045         (loop_iv_stack_get_iv): Removed.
3046         (loop_iv_stack_get_iv_from_name): Removed.
3047         (debug_loop_iv_stack): Removed.
3048         (free_loop_iv_stack): Removed.
3049         (loop_iv_stack_remove_constants): Removed.  *
3050         sese.h (iv_stack_entry_kind): Removed.
3051         (iv_stack_entry_data_union): Removed.
3052         (iv_stack_entry_struct): Removed.
3053         (iv_stack_entry_p): Removed.
3054         (debug_oldivs, debug_loop_iv_stack, loop_iv_stack_insert_constant,
3055         loop_iv_stack_get_iv_from_name, loop_iv_stack_push_iv,
3056         loop_iv_stack_get_iv, loop_iv_stack_remove_constants,
3057         loop_iv_stack_pop, free_loop_iv_stack): Removed.
3058         (gbb_loop_at_index): Fix indenting.
3059         (gbb_loop_index): Removed.
3060
3061 2009-05-13  Sebastian Pop  <sebastian.pop@amd.com>
3062
3063         * graphite-clast-to-gimple.c (clast_name_to_gcc): Do not use strcmp.
3064         Call clast_name_to_index.
3065
3066 2009-05-13  Sebastian Pop  <sebastian.pop@amd.com>
3067
3068         * graphite-clast-to-gimple.c (clast_name_to_gcc): Pass region,
3069         do not pass params.  Get params from SESE_PARAMS.
3070         (clast_to_gcc_expression): Same.
3071         (clast_to_gcc_expression_red): Same.
3072         (gcc_type_for_clast_eq): Same.
3073         (graphite_translate_clast_equation): Same.
3074         (graphite_create_new_loop): Same.
3075         * sese.c (rename_variables_in_stmt): Fix comment.
3076
3077 2009-05-13  Sebastian Pop  <sebastian.pop@amd.com>
3078
3079         * graphite-clast-to-gimple.c (graphite_create_new_loop): Pass
3080         newivs_index.
3081         Call save_clast_name_index.
3082         (translate_clast): Pass newivs_index.
3083         (gloog): Create and free newivs_index.
3084
3085 2009-05-13  Sebastian Pop  <sebastian.pop@amd.com>
3086
3087         * graphite-clast-to-gimple.c (clast_name_index): New structure.
3088         (clast_name_index_p): New type.
3089         (debug_clast_name_index): New.
3090         (debug_clast_name_indexes_1): New.
3091         (debug_clast_name_indexes): New.
3092         (clast_name_index_elt_info): New.
3093         (eq_clast_name_indexes): New.
3094         (clast_name_to_index): New.
3095         (new_clast_name_index): New.
3096         (save_clast_name_index): New.
3097         (init_sese_params_index): New.
3098         (gloog): Call init_sese_params_index.
3099         * graphite-clast-to-gimple.h (debug_clast_name_indexes): Declared.
3100         * sese.c (new_sese): Initialize SESE_PARAMS_INDEX.
3101         (free_sese): Free SESE_PARAMS_INDEX.
3102         * sese.h (struct sese): Add params_index.
3103         (SESE_PARAMS_INDEX): New.
3104
3105 2009-05-13  Sebastian Pop  <sebastian.pop@amd.com>
3106
3107         * graphite-clast-to-gimple.c (newivs_to_depth_to_newiv): New.
3108         (graphite_create_new_loop): Pass the newivs vector.  Push the
3109         newly created IV to newivs.
3110         (translate_clast): Pass the newivs vector.
3111         (gloog): Create and destroy the newivs vector.
3112
3113 2009-05-13  Sebastian Pop  <sebastian.pop@amd.com>
3114
3115         * graphite-clast-to-gimple.c (pbb_to_depth_to_oldiv): New.
3116         (graphite_loop_normal_form): Initialize loop->aux with the unique
3117         IV that has been created.
3118
3119 2009-05-13 Tobias Grosser  <grosser@fim.uni-passau.de>
3120
3121         * tree-chrec.c (evolution_function_right_is_integer_cst): Allow
3122         scev with parameters in the base part. They where forbidden
3123         exidently.
3124
3125 2009-05-11  Li Feng  <nemokingdom@gmail.com>
3126
3127         * gcc.dg/graphite/graphite.exp: Set different default
3128         compile options by file names.
3129         * gcc.dg/graphite/block{0-6}.c: Remove dg-option line.
3130         * gcc.dg/graphite/id-{1-9}.c: Ditto.
3131         * gcc.dg/graphite/scop-{0-20}.c: Ditto.
3132         * gcc.dg/graphite/scop-matmult.c: Ditto.
3133
3134 2009-05-08  Li Feng <nemokingdom@gmail.com>
3135
3136         * gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: New.
3137         * gcc.dg/graphite/graphite_autopar/force-parallel-1.c: New.
3138         * gcc.dg/graphite/graphite_autopar/force-parallel-2.c: New.
3139         * gcc.dg/graphite/graphite_autopar/force-parallel-3.c: New.
3140
3141 2009-05-07  Tobias Grosser  <grosser@fim.uni-passau.de>
3142
3143         * graphite-scop-detection (build_scops_1): Fix little bug introduced
3144         by final cleanup.
3145
3146 2009-05-07  Tobias Grosser  <grosser@fim.uni-passau.de>
3147
3148         * graphite-scop-detection.c (graphite_can_represent_scev): Only
3149         allow integer constant strides.
3150         (graphite_can_represent_expr): Depend on outermost_loop.
3151         (stmt_simple_memref_p, graphite_cannot_represent_loop,
3152         harmful_stmt_in_bb, is_simple_operand, stmt_simple_for_scop_p,
3153         build_scops_1): Same.
3154         (scopdet_basic_block_info): Same and insert layered SCoP
3155         detection.
3156         (try_generate_gimple_bb): Cleanup.
3157         (build_scops): Enable data references.
3158
3159         * gcc.dg/graphite/id-5.c: New.
3160         * gcc.dg/graphite/id-9.c: New.
3161         * tree-chrec.c (evolution_function_right_is_integer_cst): New.
3162         * tree-chrec.h (evolution_function_right_is_integer_cst): New.
3163
3164 2009-05-06  Tobias Grosser  <grosser@fim.uni-passau.de>
3165
3166         * sese.c (expand_scalar_variables_ssa_name): Only build expressions,
3167         that we have not yet built for this SCoP.
3168
3169 2009-05-06  Tobias Grosser  <grosser@fim.uni-passau.de>
3170
3171         * sese.c (expand_scalar_variables_expr): Fix expand_scalar_variables
3172         for complex numbers.
3173
3174 2009-05-06  Tobias Grosser  <grosser@fim.uni-passau.de>
3175
3176         * graphite-ppl.c: Fix build if cloog is not available.
3177
3178 2009-05-04  Li Feng  <nemokingdom@gmail.com>
3179
3180         * tree-parloops.c (loop_parallel_p): Remove construction of
3181         NITER and REDUCTION_LIST.
3182         (try_get_loop_niter): New.
3183         (try_create_reduction_list): New.
3184         (parallelize_loops): Bypass the failed checkings in autopar
3185         when can_be_parallel in loop structure is set to true.
3186
3187 2009-05-01  Tobias Grosser  <grosser@fim.uni-passau.de>
3188
3189         * gcc.dg/graphite/id-6.c: Update testcase.
3190         * gcc.dg/graphite/scop-3.c: Dito.
3191
3192 2009-05-01  Tobias Grosser  <grosser@fim.uni-passau.de>
3193
3194         * graphite-scop-detection.c (stmt_simple_for_scop_p):
3195         Enable EQ_EXPR and NE_EXPR again.
3196
3197 2009-04-30  Tobias Grosser  <grosser@fim.uni-passau.de>
3198
3199         * graphite-scop-detection.c (graphite_can_represent_scev):
3200         Add check if scev is affine multivariate.
3201         (harmful_stmt_in_bb): Check if we can represent the conditions.
3202         (scopdet_basic_block_info (basic_block bb, VEC): Pass the loop to
3203         harmful_stmt_in_bb.
3204         * gcc.dg/graphite/id-7.c: New.
3205
3206 2009-04-30  Tobias Grosser  <grosser@fim.uni-passau.de>
3207
3208         * graphite-sese-to-poly.c (bb_contains_non_iv_scalar_phi_nodes):
3209         Check all bbs in region, not only the bbs that are represented in
3210         GRAPHITE.
3211         (build_poly_scop): Add newline.
3212         * gcc.dg/graphite/id-8.c: New.
3213
3214 2009-04-30  Li Feng  <nemokingdom@gmail.com>
3215
3216         * cfgloop.c (alloc_loop): Initialize can_be_parallel to false
3217         when loop initialize.
3218         * cfgloop.h (struct loop): Introduce flag can_be_parallel.
3219         * common.opt: Declare flag_graphite_force_parallel.
3220         * graphite-clast-to-gimple.c (translate_clast): Mark the innermost
3221         loop parallel.
3222         * graphite-poly.c (apply_poly_transforms): Introduce
3223         flag_graphite_force_parallel.
3224         * tree-ssa-loop.c (gate_graphite_transforms): ditto.
3225         * toplev.c (process_options): ditto and replace a not correctly
3226         encoded space.
3227
3228 2009-04-30  Li Feng  <nemokingdom@gmail.com>
3229
3230         * graphite-clast-to-gimple.c (loop_iv_stack_patch_for_consts):
3231         Change the call of gbb_loop_at_index and/or gbb_loop_index due
3232         to the redefinition.
3233         (compute_cloog_iv_types_1): ditto.
3234         (build_iv_mapping): ditto.
3235         * graphite-sese-to-poly.c (new_gimple_bb): Remove GBB_LOOPS related
3236         initialization.
3237         (free_gimple_bb): Removed GBB_LOOPS related free part.
3238         (build_bb_loops): Removed.
3239         * sese.h (struct gimple_bb): Removed loops.
3240         (GBB_LOOPS): Removed.
3241         (gbb_loop_at_index): Instead of using GBB_LOOPS, we use sese instead.
3242         (gbb_loop_index): ditto.
3243
3244 2009-04-24  Tobias Grosser  <grosser@fim.uni-passau.de>
3245
3246         * graphite-scop-detection.c (graphite_can_represent_scev): Do not
3247         allow non constant strides.
3248         * gcc.dg/graphite/scop-20.c: New.
3249
3250 2009-04-24  Sebastian Pop  <sebastian.pop@amd.com>
3251
3252         * graphite-scop-detection.c (dot_all_scops): Fix system call
3253         return value warning.
3254         (dot_scop): Same.
3255
3256 2009-04-24  Sebastian Pop  <sebastian.pop@amd.com>
3257
3258         * gcc.dg/graphite/id-6.c: Fix pattern.
3259         * gcc.dg/graphite/scop-3.c: Same.
3260
3261 2009-04-24  Sebastian Pop  <sebastian.pop@amd.com>
3262
3263         * graphite-poly.c (map_into_dep_poly, map_dr_into_dep_poly,
3264         build_pairwise_constraint, dr_equality_constraints,
3265         build_pairwise_scheduling_equality,
3266         build_pairwise_scheduling_inequality, lexicographically_gt_p,
3267         build_lexicographically_gt_constraint, dependence_polyhedron,
3268         graphite_legal_transform_dr, graphite_legal_transform_bb,
3269         graphite_legal_transform): New.
3270         * graphite-poly.h (graphite_legal_transform): Declared.
3271         * graphite-sese-to-poly.c (build_poly_scop): Call to
3272         graphite_legal_transform is disabled for the moment.
3273
3274 2009-04-24  Sebastian Pop  <sebastian.pop@amd.com>
3275
3276         * graphite-poly.h (pbb_nb_scattering_dims): New.
3277         (pbb_nb_scattering): Use it.
3278
3279 2009-04-24  Sebastian Pop  <sebastian.pop@amd.com>
3280
3281         * graphite-ppl.c (ppl_insert_dimensions_pointset): Add
3282         Pointset_Powerset version of ppl_insert_dimensions.
3283         * graphite-ppl.h (ppl_insert_dimensions_pointset): Declared.
3284
3285 2009-04-24  Sebastian Pop  <sebastian.pop@amd.com>
3286
3287         * graphite-ppl.c (ppl_insert_dimensions): Fix formatting.
3288
3289 2009-04-24  Sebastian Pop  <sebastian.pop@amd.com>
3290
3291         * graphite-poly.h: Fix comment.
3292
3293 2009-04-24  Sebastian Pop  <sebastian.pop@amd.com>
3294
3295         * graphite-sese-to-poly.c (build_poly_dr): Fix data ref multiplier.
3296
3297 2009-04-24  Tobias Grosser  <grosser@fim.uni-passau.de>
3298
3299         * sese.c (expand_scalar_variables_stmt): Only iterate over the old
3300         statements.
3301
3302 2009-04-24  Tobias Grosser  <grosser@fim.uni-passau.de>
3303
3304         * graphite-sese-to-poly.c (var_used_in_not_loop_header_phi_node): New.
3305         (graphite_stmt_p): Represent bbs necessary to build the phi nodes of
3306         conditions.
3307
3308 2009-04-20  Sebastian Pop  <sebastian.pop@amd.com>
3309
3310         * graphite-scop-detection.c (stmt_simple_for_scop_p): Do not
3311         handle EQ_EXPR and NE_EXPR.
3312
3313 2009-04-17  Tobias Grosser  <grosser@fim.uni-passau.de>
3314
3315         * graphite-poly.h (poly_dr): Fix comment.
3316
3317 2009-04-09  Sebastian Pop  <sebastian.pop@amd.com>
3318             Tobias Grosser  <grosser@fim.uni-passau.de>
3319
3320         * graphite-poly.c (new_poly_bb): Do not initialize PBB_DOMAIN
3321         with a zero dimension polyhedron.
3322         (find_scop_parameters): Move the call to scop_set_nb_params here.
3323         (build_loop_iteration_domains): Store in loop->aux the iteration
3324         domain polyhedron.
3325         (build_scop_iteration_domain): Fix PBB_DOMAIN for bbs not surrounded
3326         by any loop in scop.
3327         (build_poly_scop): Do not call scop_set_nb_params.
3328
3329 2009-04-09  Sebastian Pop  <sebastian.pop@amd.com>
3330             Tobias Grosser  <grosser@fim.uni-passau.de>
3331
3332         * graphite-sese-to-poly.c (add_condition_to_pbb): Pass code to
3333         add_condition_to_domain not GT_EXPR.
3334
3335 2009-04-09  Tobias Grosser  <grosser@fim.uni-passau.de>
3336
3337         * graphite-ppl.c (debug_ppl_powerset_matrix): New.
3338         * graphite-ppl.h (debug_ppl_powerset_matrix): New.
3339         * graphite-sese-to-poly.c (add_condition_to_pbb): Use
3340         upper_bound_assign to calculate unions.
3341         * gcc.dg/graphite/id-6.c: New.
3342
3343 2009-04-09  Tobias Grosser  <grosser@fim.uni-passau.de>
3344
3345         * graphite-scop-detection.c (canonicalize_loop_closed_ssa): Do not
3346         handle abnormal edges.
3347
3348 2009-04-09  Tobias Grosser  <grosser@fim.uni-passau.de>
3349
3350         * graphite-poly.c (new_poly_dr, free_poly_dr): New.
3351         (free_poly_bb): Also free poly_drs.
3352         * graphite-poly.h (new_poly_dr, free_poly_dr): New.
3353         (poly_dr): Polyhedron to Pointset_Powerset.
3354         (pdr_accessp_nb_subscripts): Same.
3355         * graphite-sese-to-poly.c (build_poly_dr): Same. And actually build
3356         poly_drs.
3357
3358 2009-04-08  Sebastian Pop  <sebastian.pop@amd.com>
3359
3360         * graphite-clast-to-gimple.c (initialize_cloog_names): Change cloog
3361         names into more meaningful names.
3362
3363 2009-04-08  Sebastian Pop  <sebastian.pop@amd.com>
3364
3365         * gfortran.dg/graphite/interchange-1.c: New.
3366         * gfortran.dg/graphite/interchange-2.c: New.
3367
3368 2009-04-08  Sebastian Pop  <sebastian.pop@amd.com>
3369
3370         * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not build
3371         the reduction_list.
3372         * tree-parloops.c (rewrite_phi_with_iv): New.
3373         (rewrite_all_phi_nodes_with_iv): New.
3374         (canonicalize_loop_ivs): Call them.
3375
3376 2009-04-08  Sebastian Pop  <sebastian.pop@amd.com>
3377
3378         * graphite-sese-to-poly.c (try_generate_gimple_bb): Use
3379         graphite_find_data_references_in_stmt.
3380         * tree-data-ref.c (graphite_find_data_references_in_stmt): New.
3381         * tree-data-ref.h (graphite_find_data_references_in_stmt): Declared.
3382
3383 2009-04-08  Sebastian Pop  <sebastian.pop@amd.com>
3384
3385         * sese.c (add_loop_exit_phis): Don't fail on non SSA_NAME renames.
3386
3387 2009-04-08  Sebastian Pop  <sebastian.pop@amd.com>
3388
3389         * graphite-sese-to-poly.c (build_scop_bbs_1): Use bb_in_sese_p
3390         instead of bb_in_region.
3391         (flag_bb_in_region): Same.  Renamed flag_bb_in_sese.
3392         (build_sese_conditions): Use flag_bb_in_sese.
3393         * sese.c (register_bb_in_sese): Removed.
3394         (new_sese): Remove initialization of SESE_REGION_BBS.
3395         (free_sese): Do not free SESE_REGION_BBS.
3396         * sese.h (struct sese): Remove field region_basic_blocks.
3397         (SESE_REGION_BBS): Removed.
3398         (bb_in_sese_p): Implement in function of bb_in_region.
3399
3400 2009-04-08  Sebastian Pop  <sebastian.pop@amd.com>
3401
3402         * graphite-scop-detection.c (limit_scops): Deal only with single exit
3403         loops.
3404
3405 2009-04-08  Tobias Grosser  <grosser@fim.uni-passau.de>
3406
3407         * graphite-scop-detection.c (stmt_simple_for_scop_p): Allow NE_EXPR
3408         and EQ_EXPR.
3409         * graphite-sese-to-poly.c (create_linear_expr_from_tree): New.
3410         (add_condition_to_domain): New.
3411         (add_condition_to_pbb): New.
3412         (add_conditions_to_domain): Cleanup and handle of NE_EXPR and EQ_EXPR.
3413         * gcc.dg/graphite/scop-3.c: Update number of detected SCoPs.
3414
3415 2009-04-08  Tobias Grosser  <grosser@fim.uni-passau.de>
3416
3417         * graphite-clast-to-gimple.c (build_cl