OSDN Git Service

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