]> git.ipfire.org Git - thirdparty/gcc.git/blame - gcc/ChangeLog.graphite
Fix PR43097: rename only SSA_NAMEs.
[thirdparty/gcc.git] / gcc / ChangeLog.graphite
CommitLineData
c3382979
SP
12010-02-22 Sebastian Pop <sebastian.pop@amd.com>
2
3 PR middle-end/43140
4 * sese.c (get_rename): Assert that old_name is an SSA_NAME.
5 (rename_variables_in_stmt): Continue when the use is not an SSA_NAME.
6
7 * gfortran.dg/graphite/pr43097.f: New.
8
13cd10a2
SP
92010-02-22 Sebastian Pop <sebastian.pop@amd.com>
10 Manuel López-Ibáñez <manu@gcc.gnu.org>
11
12 PR middle-end/43140
13 * g++.dg/graphite/pr41305.C: Add -Wno-conversion-null.
14
152010-02-22 Sebastian Pop <sebastian.pop@amd.com>
143b72a9
SP
16
17 PR middle-end/43026
18 * sese.c (expand_scalar_variables_expr): Handle COMPONENT_REF.
19
20 * g++.dg/graphite/pr43026.C: New.
21
c2814aab
SP
222010-02-11 Sebastian Pop <sebastian.pop@amd.com>
23
24 PR middle-end/43012
25 * gcc.dg/graphite/pr43012.c: New.
be1c3b28 26
c2814aab 272010-02-10 Sebastian Pop <sebastian.pop@amd.com>
be1c3b28 28
c2814aab 29 * graphite.c (graphite_transform_loops): Re-enable dbg_cnt.
be1c3b28
SP
302010-02-10 Sebastian Pop <sebastian.pop@amd.com>
31
32 * g++.dg/graphite/pr42930.C: New.
33
141ecc24 342010-02-10 Sebastian Pop <sebastian.pop@amd.com>
c4c4983e
SP
35
36 PR middle-end/42930
37 * graphite-scop-detection.c (graphite_can_represent_scev): Call
38 graphite_can_represent_init for MULT_EXPR.
39
141ecc24 402010-02-10 Sebastian Pop <sebastian.pop@amd.com>
a4681954
SP
41
42 PR middle-end/42914
43 PR middle-end/42530
44 * graphite-sese-to-poly.c (remove_phi): New.
45 (translate_scalar_reduction_to_array): Call remove_phi.
46
47 * gcc.dg/graphite/pr42530.c: New.
48 * gcc.dg/graphite/pr42914.c: New.
49
141ecc24 502010-02-10 Sebastian Pop <sebastian.pop@amd.com>
a1954f72
SP
51
52 PR middle-end/42771
53 * graphite-clast-to-gimple.c (gloog): Call rename_sese_parameters.
54 * graphite-clast-to-gimple.h (gloog): Update declaration.
55 * graphite-poly.c (new_scop): Clear POLY_SCOP_P.
56 * graphite-poly.h (struct poly_bb): Add missing comments.
57 (struct scop): Add poly_scop_p field.
58 (POLY_SCOP_P): New.
59 * graphite-sese-to-poly.c (build_poly_scop): Set POLY_SCOP_P.
60 * graphite.c (graphite_transform_loops): Build the polyhedral
61 representation for each scop before code generation.
62 * sese.c (rename_variables_in_operand): Removed.
63 (rename_variables_in_expr): Return the renamed expression.
64 (rename_sese_parameters): New.
65 * sese.h (rename_sese_parameters): Declared.
66
67 * gcc.dg/graphite/pr42771.c: New.
68
0be957dc
SP
692010-02-07 Sebastian Pop <sebastian.pop@amd.com>
70
71 * gcc.dg/graphite/block-0.c: Call abort for runtime test. Always
72 return 0 from main.
73 * gcc.dg/graphite/block-1.c: Same.
74 * gcc.dg/graphite/block-3.c: Same.
75 * gcc.dg/graphite/block-4.c: Same.
76 * gcc.dg/graphite/block-5.c: Same.
77 * gcc.dg/graphite/block-6.c: Same.
78 * gcc.dg/graphite/block-7.c: Same.
79 * gcc.dg/graphite/interchange-0.c: Same.
80 * gcc.dg/graphite/interchange-1.c: Same.
81 * gcc.dg/graphite/interchange-10.c: Same.
82 * gcc.dg/graphite/interchange-11.c: Same.
83 * gcc.dg/graphite/interchange-12.c: Same.
84 * gcc.dg/graphite/interchange-2.c: Same.
85 * gcc.dg/graphite/interchange-3.c: Same.
86 * gcc.dg/graphite/interchange-4.c: Same.
87 * gcc.dg/graphite/interchange-5.c: Same.
88 * gcc.dg/graphite/interchange-6.c: Same.
89 * gcc.dg/graphite/interchange-7.c: Same.
90 * gcc.dg/graphite/interchange-8.c: Same.
91 * gcc.dg/graphite/interchange-9.c: Same.
92 * gcc.dg/graphite/interchange-mvt.c: Same.
93
4d48441c
SP
942010-02-07 Sebastian Pop <sebastian.pop@amd.com>
95
96 * gfortran.dg/graphite/id-19.f: New.
97 * gfortran.dg/graphite/pr14741.f90: New.
98 * gfortran.dg/graphite/pr41924.f90: New.
99 * gfortran.dg/graphite/run-id-2.f90: New.
100
8d2220b2
SP
1012010-02-07 Sebastian Pop <sebastian.pop@amd.com>
102
103 PR middle-end/42988
104 * graphite-dependences.c (dependence_polyhedron): Set PDDR_KIND
105 to unknown_dependence.
106 (graphite_legal_transform_dr): Handle the unknown_dependence.
107 (graphite_carried_dependence_level_k): Same.
108
45489e99
SP
1092010-02-07 Sebastian Pop <sebastian.pop@amd.com>
110
111 * ChangeLog.graphite: Remove testsuite/ or gcc/testsuite/.
112
28f9f145
SP
1132010-02-05 Sebastian Pop <sebastian.pop@amd.com>
114 Konrad Trifunovic <konrad.trifunovic@inria.fr>
115
116 PR middle-end/42637
117 * graphite-dependences.c (build_lexicographical_constraint): Return
118 a union of dependence polyhedra.
119 (dependence_polyhedron_1): Adapt for build_lexicographical_constraint.
120
45489e99
SP
121 * gcc.dg/graphite/block-0.c: Enable runtime check. XFAILed.
122 * gcc.dg/graphite/block-4.c: Same.
123 * gcc.dg/graphite/block-7.c: Same.
124 * gcc.dg/graphite/interchange-12.c: Same.
125 * gcc.dg/graphite/interchange-mvt.c: Same.
126 * gfortran.dg/graphite/interchange-1.f: XFAILed.
127 * gfortran.dg/graphite/interchange-3.f90: XFAILed.
128 * gfortran.dg/graphite/run-id-1.f: New testcase for PR42637.
28f9f145 129
4d0bf08b
SP
1302010-02-03 Sebastian Pop <sebastian.pop@amd.com>
131
45489e99 132 * gcc.dg/graphite/interchange-12.c: Return 0 to avoid
4d0bf08b
SP
133 the execution check to FAIL. This testcase is miscompiled by Graphite
134 and the check should be re-enabled.
45489e99
SP
135 * gcc.dg/graphite/interchange-mvt.c: Same.
136 * gcc.dg/graphite/block-0.c: Same.
137 * gcc.dg/graphite/block-4.c: Same.
138 * gcc.dg/graphite/block-7.c: Same.
4d0bf08b 139
54cf8879
SP
1402010-02-03 Sebastian Pop <sebastian.pop@amd.com>
141
45489e99
SP
142 * gcc.dg/graphite/interchange-mvt.c: Un-XFAILed.
143 * gcc.dg/graphite/scop-0.c: Fix spaces.
144 * gfortran.dg/graphite/block-1.f90: Rewrite expected output.
145 * gfortran.dg/graphite/block-2.f: Same.
146 * gfortran.dg/graphite/block-3.f90: Same.
147 * gfortran.dg/graphite/block-4.f90: Same.
148 * gfortran.dg/graphite/interchange-1.f: Un-XFAILed.
149 * gfortran.dg/graphite/interchange-3.f90: Un-XFAILed.
54cf8879 150
b5eb099f
SP
1512010-02-03 Sebastian Pop <sebastian.pop@amd.com>
152
153 * graphite-dependences.c (new_poly_ddr): Initialize PDDR_KIND and
154 PDDR_ORIGINAL_SCATTERING_P.
155 (pddr_is_empty): Rewritten.
156 (print_dependence_polyhedron_layout): New.
157 (print_pddr): New.
158 (debug_pddr): New.
159 (build_alias_set_powerset): Moved up.
160 (poly_drs_may_alias_p): Moved up.
161 (lexicographically_gt_p): Removed.
162 (build_lexicographically_gt_constraint): Renamed
163 build_lexicographical_constraint, reimplemented.
164 (dependence_polyhedron_1): Simplified parameters.
165 (dependence_polyhedron): Same. Keep along empty PDDRs
166 to make efficient use of the cache.
167 (reduction_dr_p): Compute the PBBs don't pass them as parameters.
168 (graphite_legal_transform_dr): Rewritten.
169 (graphite_legal_transform_bb): Pass fewer arguments to
170 graphite_legal_transform_dr.
171 (graphite_carried_dependence_level_k): Simplified implementation.
172 (dot_original_deps_stmt_1): Call dependence_polyhedron.
173 (dot_transformed_deps_stmt_1): Same.
174 (dot_original_deps): Same.
175 (dot_transformed_deps): Same.
176 * graphite-dependences.h (struct poly_ddr): Added a new field
177 original_scattering_p.
178 (PDDR_ORIGINAL_SCATTERING_P): New.
179 (print_pddr): Declared.
180 (debug_pddr): Declared.
181 * graphite-ppl.c: Clarify comment.
182 * sese.h (print_gimple_bb): Removed unused declaration.
183 (debug_gbb): Same.
184
64630e61
SP
1852010-02-03 Sebastian Pop <sebastian.pop@amd.com>
186
45489e99
SP
187 * g++.dg/graphite/graphite.exp: Rewritten.
188 * gcc.dg/graphite/graphite.exp: Rewritten.
189 * gfortran.dg/graphite/graphite.exp: Rewritten.
190 * gcc.dg/graphite/block-0.c: Added runtime test.
191 * gcc.dg/graphite/block-1.c: Same.
192 * gcc.dg/graphite/block-3.c: Same.
193 * gcc.dg/graphite/block-4.c: Same.
194 * gcc.dg/graphite/block-5.c: Same.
195 * gcc.dg/graphite/block-6.c: Same.
196 * gcc.dg/graphite/block-7.c: Same.
197 * gcc.dg/graphite/interchange-0.c: Same.
198 * gcc.dg/graphite/interchange-1.c: Same.
199 * gcc.dg/graphite/interchange-10.c: Same.
200 * gcc.dg/graphite/interchange-11.c: Same.
201 * gcc.dg/graphite/interchange-12.c: Same.
202 * gcc.dg/graphite/interchange-2.c: Same.
203 * gcc.dg/graphite/interchange-3.c: Same.
204 * gcc.dg/graphite/interchange-4.c: Same.
205 * gcc.dg/graphite/interchange-5.c: Same.
206 * gcc.dg/graphite/interchange-6.c: Same.
207 * gcc.dg/graphite/interchange-7.c: Same.
208 * gcc.dg/graphite/interchange-8.c: Same.
209 * gcc.dg/graphite/interchange-9.c: Same.
210 * gcc.dg/graphite/interchange-mvt.c: Same.
211 * gcc.dg/graphite/run-id-2.c: Remove useless dg-do run.
64630e61 212
4c8f3c48
RU
2132010-01-22 Ramakrishna Upadrasta <Ramakrishna.Upadrasta@inria.fr>
214
215 * graphite-scop-detection.c (dot_all_scops): Make calls to dot run in
216 background.
217
2182010-01-22 Ramakrishna Upadrasta <Ramakrishna.Upadrasta@inria.fr>
219
220 * common.opt: Add -fgraphite-cloog-opts.
221 * graphite-clast-to-gimple.c (set_cloog_options): Same.
222 * opts.c (decode_options): Same.
223
86e4d552
SP
2242010-01-20 Sebastian Pop <sebastian.pop@amd.com>
225
45489e99
SP
226 * gcc.dg/graphite/id-17.c: New.
227 * gcc.dg/graphite/pr41888.c: New.
228 * gcc.dg/graphite/scop-22.c: New.
229 * gfortran.dg/graphite/pr40982.f90: New.
86e4d552 230
3070ac15
SP
2312010-01-20 Sebastian Pop <sebastian.pop@amd.com>
232
233 * graphite-dependences.c: Clarify comments.
234 (build_pddr): Add an extra parameter direction.
235 (graphite_legal_transform_dr): Use build_pddr.
236 (dot_original_deps_stmt_1): Update use of build_pddr.
237 (dot_transformed_deps_stmt_1): Same.
238 (dot_original_deps): Same.
239 (dot_transformed_deps): Same.
240
45489e99
SP
241 * gcc.dg/graphite/interchange-12.c: New.
242 * gcc.dg/graphite/block-7.c: New.
3070ac15 243
a7ed6c90
SP
2442010-01-20 Sebastian Pop <sebastian.pop@amd.com>
245
246 * graphite-dependences.c (pddr_original_scattering): Renamed build_pddr.
247 (pddr_transformed_scattering): Removed.
248 (graphite_legal_transform_dr): Use build_pddr.
249 (dot_original_deps_stmt_1): Same.
250 (dot_transformed_deps_stmt_1): Same.
251 (dot_original_deps): Same.
252 (dot_transformed_deps): Same.
253
e65a7579
SP
2542010-01-20 Sebastian Pop <sebastian.pop@amd.com>
255
256 * graphite-dependences.c (lexicographically_gt_p): Add comments.
257 (build_lexicographically_gt_constraint): Same.
258 (dependence_polyhedron_1): Same.
259 (dependence_polyhedron): Same.
260
7cbd4c5e
SP
2612010-01-20 Sebastian Pop <sebastian.pop@amd.com>
262
263 * graphite-dependences.c (build_pairwise_scheduling_equality): Removed.
264 (build_pairwise_scheduling_inequality): Renamed build_pairwise_scheduling.
265 (lexicographically_gt_p): Change type of direction to int.
266 (build_lexicographically_gt_constraint): Same.
267 (dependence_polyhedron_1): Same.
268 (dependence_polyhedron): Same.
269 (pddr_original_scattering): Use integers for direction.
270 (pddr_transformed_scattering): Same.
271 (graphite_legal_transform_dr): Same.
272 (graphite_carried_dependence_level_k): Same.
273
429ba740
SP
2742010-01-20 Sebastian Pop <sebastian.pop@amd.com>
275
276 * graphite-dependences.c (build_pairwise_constraint): Renamed
277 ppl_build_relation. Moved...
278 (dr_equality_constraints): Use ppl_build_relation.
279 (build_pairwise_scheduling_equality): Same.
280 (build_pairwise_scheduling_inequality): Same.
281 * graphite-ppl.c (ppl_build_relation): ...here.
282 * graphite-ppl.h (ppl_build_relation): Declared.
283
3c7c0158
SP
2842010-01-14 Sebastian Pop <sebastian.pop@amd.com>
285
286 PR middle-end/42681
287 * graphite-clast-to-gimple.c (gloog_error): New static variable.
288 (clast_to_gcc_expression): Do not build MULT_EXPR of POINTER_TYPE_P.
289 Set gloog_error when such an expression failed to be built.
290 (translate_clast): Early return when gloog_error is set.
291 (gloog): Clear gloog_error. When gloog_error is set, call
292 set_ifsese_condition to enable the original code. Return the status
293 of the code generation based on gloog_error.
294 * sese.c (set_ifsese_condition): New.
295 * sese.h (set_ifsese_condition): Declared.
296
45489e99 297 * g++.dg/graphite/pr42681.C: New.
3c7c0158 298
a7bf45de
SP
2992010-01-14 Sebastian Pop <sebastian.pop@amd.com>
300
301 PR middle-end/42732
302 * graphite-clast-to-gimple.c (gloog): Call scev_reset_htab and
303 rename_nb_iterations.
304 * sese.c (rename_variables_in_operand): New.
305 (rename_variables_in_expr): New.
306 (rename_nb_iterations): New.
307 (sese_adjust_liveout_phis): Update the rename_map.
308 * sese.h (rename_nb_iterations): Declared.
309 * tree-scalar-evolution.c (scev_reset_htab): New.
310 (scev_reset): Call scev_reset_htab.
311 * tree-scalar-evolution.h (scev_reset_htab): Declared.
312
45489e99 313 * gfortran.dg/graphite/pr42732.f: New.
a7bf45de 314
e1496917
SP
3152010-01-08 Sebastian Pop <sebastian.pop@amd.com>
316
317 PR middle-end/42393
318 * graphite-clast-to-gimple.c: Fix formatting.
319 * sese.c (defined_in_loop_p): Renamed name_defined_in_loop_p.
320 (expr_defined_in_loop_p): New.
321 (add_loop_exit_phis): Also handle full expressions: remove from
322 the rename_map the expressions defined in the loop that we're closing.
323
45489e99
SP
324 * gfortran.dg/graphite/pr42393-1.f90: New.
325 * gfortran.dg/graphite/pr42393.f90: Add new flags
e1496917
SP
326 -fno-loop-block -fno-loop-interchange -fno-loop-strip-mine to also
327 make this testcase useful in the Graphite branch.
328
c8ae0613
SP
3292010-01-08 Sebastian Pop <sebastian.pop@amd.com>
330
331 * graphite-scop-detection.c (exclude_component_ref): Removed.
332 (is_simple_operand): Removed.
333 (stmt_simple_for_scop_p): Remove use of is_simple_operand.
334
4e98c66c
SP
3352010-01-07 Sebastian Pop <sebastian.pop@amd.com>
336
337 PR middle-end/42221
338 * sese.c (expand_scalar_variables_expr): Follow the SSA links into
339 the array indexing of ADDR_EXPRs.
340
45489e99 341 * gcc.dg/graphite/pr42221.c: New.
4e98c66c 342
fd4a56ff
SP
3432010-01-07 Sebastian Pop <sebastian.pop@amd.com>
344
345 PR middle-end/42521
346 * graphite.c (graphite_finalize): Call scev_reset.
347 (graphite_transform_loops): Do not call scev_reset between the code
348 generation of scops.
349
45489e99 350 * gcc.dg/graphite/pr42521.c: New.
fd4a56ff 351
eaffa762
SP
3522010-01-07 Sebastian Pop <sebastian.pop@amd.com>
353
354 * graphite-interchange.c (memory_stride_in_loop): Renamed
355 pdr_stride_in_loop.
356 (memory_strides_in_loop): Renamed memory_strides_in_loop_1.
357 (memory_strides_in_loop): Memoize the memory strides per loop.
358 (lst_interchange_profitable_p): Do not initialize to zero the memory
359 strides.
360 * graphite-poly.h (struct lst): Add a field memory_strides.
361 (LST_LOOP_MEMORY_STRIDES): New.
362 (new_lst_loop): Initialize LST_LOOP_MEMORY_STRIDES to -1.
363 (free_lst): Clear LST_LOOP_MEMORY_STRIDES.
364
bf69e754
SP
3652010-01-07 Sebastian Pop <sebastian.pop@amd.com>
366
367 * graphite-interchange.c (memory_strides_in_loop_depth): Renamed
368 memory_strides_in_loop. Gather memory strides on a whole loop.
369 (pbb_interchange_profitable_p): Renamed lst_interchange_profitable_p.
370 (lst_interchange_profitable_p): Removed.
371 (lst_try_interchange_loops): Call lst_interchange_profitable_p.
372
9fa29a09
SP
3732010-01-07 Sebastian Pop <sebastian.pop@amd.com>
374
375 Revert patch 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
376 * graphite-clast-to-gimple.c (try_mark_loop_parallel): New.
377 (translate_clast_for, translate_clast_guard, translate_clast, gloog):
378 Remove context_loop and level.
379
11d6ea5e
SP
3802010-01-07 Richard Guenther <rguenther@suse.de>
381
382 PR tree-optimization/42641
383 * sese.c (rename_map_elt_info): Use the SSA name version, do
384 not hash pointers.
385
3862010-01-06 Sebastian Pop <sebastian.pop@amd.com>
387
388 * graphite-blocking.c (scop_do_block): Print "SCoP will be loop
389 blocked" only when both the strip mine and the interchange have
390 been applied.
391
45489e99
SP
392 * gcc.dg/graphite/block-2.c: Removed.
393 * gcc.dg/graphite/block-3.c: Add scan pattern.
394 * gcc.dg/graphite/block-4.c: Same.
395 * gcc.dg/graphite/block-5.c: Same.
396 * gcc.dg/graphite/block-6.c: Same.
11d6ea5e 397
556afcdc
SP
3982010-01-06 Sebastian Pop <sebastian.pop@amd.com>
399
400 * graphite-clast-to-gimple.c (save_clast_name_index): Free slot
401 before allocating a new one.
402 (copy_renames): Check that slot is not NULL.
403 (mark_bb_with_pbb): Same.
404 (compute_cloog_iv_types_1): Same.
405 * graphite-interchange.c (lst_perfect_nestify): Free the before,
406 nest, and after LSTs.
407 (lst_try_interchange_loops): Same.
408
e68c3c6c
SP
4092010-01-05 Sebastian Pop <sebastian.pop@amd.com>
410
411 PR middle-end/42178
412 * graphite-interchange.c (lst_try_interchange_loops): Do not return
413 the before, nest, and after LSTs.
414 (lst_try_interchange): Removed.
415 (lst_interchange_select_inner): Do not iterate over the LSTs if they
416 were modified.
417 (lst_interchange_select_outer): Apply interchange on the outer loop
418 until there are no more changes in the inner loops.
419
a84a556d
SP
4202009-12-18 Sebastian Pop <sebastian.pop@amd.com>
421
422 Revert patch fixing PR middle-end/42221.
423
4242009-12-18 Sebastian Pop <sebastian.pop@amd.com>
425
426 PR middle-end/42180
427 * graphite-sese-to-poly.c (follow_ssa_with_commutative_ops): Handle
428 GIMPLE_CALL.
429
45489e99 430 * gfortran.dg/graphite/pr42180.f90: Add compile flags.
a84a556d 431
b147df0b
SP
4322009-12-18 Sebastian Pop <sebastian.pop@amd.com>
433
434 PR middle-end/42180
435 * graphite-sese-to-poly.c (split_reduction_stmt): Do not split blocks
436 that contain only one statement.
437
45489e99 438 * gfortran.dg/graphite/pr42180.f90: New.
a84a556d 439
ce20f9d6
SP
4402009-12-17 Sebastian Pop <sebastian.pop@amd.com>
441
442 PR middle-end/42393
45489e99 443 * gfortran.dg/graphite/pr42393.f90: New.
ce20f9d6 444
d2a271ac
SP
4452009-12-17 Sebastian Pop <sebastian.pop@amd.com>
446
447 PR middle-end/42186
45489e99 448 * gfortran.dg/graphite/pr42186.f90: New.
d2a271ac 449
403ebc7e
SP
4502009-12-17 Sebastian Pop <sebastian.pop@amd.com>
451
452 PR middle-end/42205
453 * graphite-sese-to-poly.c (translate_scalar_reduction_to_array_for_stmt):
454 Insert the reduction copy in the same block as the phi node.
455 (follow_ssa_with_commutative_ops): Handle GIMPLE_NOPs.
456
45489e99
SP
457 * gcc.dg/graphite/pr42205-1.c: New.
458 * gcc.dg/graphite/pr42205-2.c: New.
403ebc7e
SP
459
4602009-12-17 Sebastian Pop <sebastian.pop@amd.com>
461
462 PR middle-end/42221
463 * sese.c (expand_scalar_variables_expr): Follow the SSA links into
464 the array indexing of ADDR_EXPRs.
465
45489e99 466 * gcc.dg/graphite/pr42221.c: New.
403ebc7e 467
070ba483
SP
4682009-12-17 Sebastian Pop <sebastian.pop@amd.com>
469
470 PR middle-end/42178
471 PR middle-end/42334
472 * graphite-interchange.c (lst_try_interchange): Do not modify OUTER
473 index. Call lst_interchange_select_inner only once.
474 (lst_interchange_select_inner): Update use of lst_try_interchange.
475 (lst_interchange_select_outer): Update.
476
4772009-12-15 Sebastian Pop <sebastian.pop@amd.com>
478
479 PR middle-end/42178
480 PR middle-end/42334
481 * graphite-interchange.c (lst_try_interchange): Do not increment the
482 the OUTER index when there is no AFTER kernel. Do not increment the
483 OUTER index for after processing the AFTER kernel.
484 (lst_interchange_select_inner): Call lst_try_interchange only on loops.
485 (lst_interchange_select_outer): Do not pass in a pointer to the OUTER
486 index. Do not pass to lst_interchange_select_inner the OUTER index.
487 (scop_do_interchange): Update use of lst_interchange_select_outer.
488
45489e99 489 * gfortran.dg/graphite/graphite.exp
070ba483 490 (DEFAULT_FLAGS_GRAPHITE_IDENTITY): Remove -fdump-tree-graphite-all.
45489e99 491 * gfortran.dg/graphite/interchange-1.f: Add comment. Clean
070ba483 492 the graphite dump file.
45489e99
SP
493 * gfortran.dg/graphite/interchange-2.f: Same.
494 * gfortran.dg/graphite/pr42334-1.f: New.
070ba483
SP
495
4962009-12-15 Sebastian Pop <sebastian.pop@amd.com>
497
498 PR middle-end/42178
499 PR middle-end/42334
500 * graphite-interchange.c (lst_perfect_nestify): Reset to NULL the LSTs
501 that are empty.
502 (lst_do_interchange_1): Renamed lst_interchange_select_inner.
503 (lst_try_interchange): Reimplemented.
504 (lst_interchange_select_inner): Same.
505 (lst_do_interchange): Renamed lst_interchange_select_outer.
506 Reimplemented.
507 (scop_do_interchange): Update use of lst_interchange_select_outer.
508
45489e99
SP
509 * g++.dg/graphite/pr42130.C: Add -fgraphite-identity.
510 * gcc.dg/graphite/block-0.c: Un-XFAILed.
511 * gcc.dg/graphite/pr42211.c: New.
512 * gfortran.dg/graphite/pr42334.f90: New.
070ba483 513
4b216ab0
SP
5142009-12-14 Sebastian Pop <sebastian.pop@amd.com>
515
516 PR middle-end/42181
517 * graphite-scop-detection.c (graphite_can_represent_scev): Handle more
518 carefully PLUS_EXPR, MINUS_EXPR, and MULT_EXPR.
519
45489e99 520 * gfortran.dg/graphite/pr42181.f90: New.
4b216ab0 521
c880097d
SP
5222009-12-12 Sebastian Pop <sebpop@gmail.com>
523
524 PR middle-end/42284
525 * graphite-sese-to-poly.c (rewrite_close_phi_out_of_ssa): Call
526 insert_out_of_ssa_copy_on_edge for anything else than SSA_NAMEs.
527 (detect_commutative_reduction_arg): Simplified.
528 (detect_commutative_reduction): Early return when the argument of
529 the close phi is not of an SSA_NAME.
530
45489e99 531 * gcc.dg/graphite/pr42284.c: New.
c880097d
SP
532
5332009-12-11 Alexander Monakov <amonakov@ispras.ru>
534
535 * dbgcnt.def (graphite_scop): New counter.
536 * graphite.c: Include dbgcnt.h
537 (graphite_transform_loops): Use new counter to limit transformations.
538
d505015a
SP
5392009-12-08 Sebastian Pop <sebpop@gmail.com>
540
541 PR middle-end/42285
542 * graphite-scop-detection.c (graphite_can_represent_init): Also
543 handle more complex MULT_EXPRs containing parameters by recursion
544 on the structure.
545
45489e99 546 * gfortran.dg/graphite/pr42285.f90: New.
d505015a
SP
547
5482009-12-01 Tobias Grosser <grosser@fim.uni-passau.de>
549
45489e99 550 * g++.dg/graphite/pr42130.C: Fix type.
d505015a 551
ed807d06
AM
5522009-11-29 Alexander Monakov <amonakov@gcc.gnu.org>
553
45489e99
SP
554 * g++.dg/graphite/pr42130.C: Correct testcase.
555
5562009-11-28 Tobias Grosser <grosser@fim.uni-passau.de>
557
558 * Merge from mainline (154493:154734).
559
5602009-11-28 Tobias Grosser <grosser@fim.uni-passau.de>
561
562 * Merge from mainline (151362:154491).
ed807d06 563
7c246f5e
TG
5642009-11-24 Tobias Grosser <grosser@fim.uni-passau.de>
565
566 * graphite-clast-to-gimple.c (try_mark_loop_parallel,
567 graphite_create_new_loop_guard, translate_clast_for): Fix comments.
568
0dd91484
TG
5692009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
570
571 PR middle-end/42130
572 * graphite-clast-to-gimple.c (graphite_create_new_loop_guard,
573 translate_clast_for_loop): New.
574 (translate_clast_for): Add a condition around the loop, to do not
575 execute loops with zero iterations.
45489e99
SP
576 * g++.dg/graphite/pr42130.C: New.
577 * gcc.dg/graphite/pr35356-2.c: Adapt.
0dd91484 578
fd2d813d
TG
5792009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
580
581 * graphite-clast-to-gimple.c (try_mark_loop_parallel): New.
582 (translate_clast_for, translate_clast_guard, translate_clast, gloog):
583 Remove context_loop and level.
584
9016166f
TG
5852009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
586
587 * graphite-clast-to-gimple.c (translate_clast_user,
588 translate_clast_for, translate_clast_guard): Simplify and move common
589 elements to translate_clast().
590 (translate_clast): Simplify and get common elements.
591
e1f9c1cd
TG
5922009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
593
594 * graphite-clast-to-gimple.c (translate_clast_user,
595 translate_clast_for, translate_clast_guard): Split out of
596 translate_clast.
597
7a521ff2
TG
5982009-11-21 Tobias Grosser <grosser@fim.uni-passau.de>
599
600 * graphite-clast-to-gimple.c (clast_name_index, new_clast_name_index,
601 clast_name_to_index, save_clast_name_index, debug_clast_name_index,
602 debug_clast_name_indexes_1, debug_clast_name_indexes,
603 clast_name_index_elt_info, eq_clast_name_indexes): Moved from sese.h.
604 (clast_name_to_gcc, clast_to_gcc_expression,
605 clast_to_gcc_expression_red, gcc_type_for_clast_expr,
606 gcc_type_for_clast_eq, graphite_translate_clast_equation,
607 graphite_create_guard_cond_expr, graphite_create_new_loop,
608 translate_clast): Add params_index.
609 (initialize_cloog_names): Create parameter strings from scratch, do
610 not reference other strings.
611 (create_params_index): New.
612 (gloog): Initialize params_index.
613 * graphite-scop-detection (free_scops_1): Removed.
614 (limit_scops): Use normal free_scops.
615 * graphite-sese-to-poly.c (save_var_names): Removed.
616 (parameter_index_in_region): Do not initialize SESE_PARAM_NAMES
617 and SESE_PARAMS_INDEX.
618 * sese.c (new_sese, free_sese): Dito.
619 * sese.h (struct sese): Remove params_index, params_names.
620 (SESE_PARAMS_INDEX, SESE_PARAMS_NAMES): Removed.
621
ca11b093
SP
6222009-11-20 Sebastian Pop <sebastian.pop@amd.com>
623
624 Revert the following patch from 2009-09-14:
625 * graphite-blocking.c: Fix order of includes: tree-chrec.h, then
626 tree-scalar-evolution.h, and then tree-data-ref.h.
627 * graphite-clast-to-gimple.c: Same.
628 * graphite-dependences.c: Same.
629 * graphite-interchange.c: Same.
630 * graphite-poly.c: Same.
631 * graphite-scop-detection.c: Same.
632 * graphite-sese-to-poly.c: Same.
633 * graphite.c: Same.
634 * lambda-code.c: Same.
635 * matrix-reorg.c: Same.
636 * tree-data-ref.c: Same.
637 * tree-if-conv.c: Same.
638 * tree-loop-distribu: Same.: Same.
639 * tree-loop-linear.c: Same.
640 * tree-parloops.c: Same.
641 * tree-predcom.c: Same.
642 * tree-vect-patterns.c: Same.
643
8a9e9475
SP
6442009-11-20 Sebastian Pop <sebastian.pop@amd.com>
645
646 Revert patch from 2009-09-14.
647 * tree-ssa-loop.c (gate_graphite_transforms): Re-enable Graphite
648 passes at -O1 and below.
649
4bf4e169
SP
6502009-11-18 Sebastian Pop <sebastian.pop@amd.com>
651
652 PR middle-end/40281
45489e99 653 * gcc.dg/graphite/pr40281.c: New.
4bf4e169
SP
654
655 * tree-scalar-evolution.c (instantiate_scev_poly): Base and stride
656 evolutions should not variate in inner loops.
657
12aec731
SP
6582009-11-18 Sebastian Pop <sebastian.pop@amd.com>
659
660 PR middle-end/42050
45489e99 661 * gfortran.dg/graphite/pr42050.f90: New.
12aec731 662
aec12420
SP
6632009-11-18 Sebastian Pop <sebastian.pop@amd.com>
664
665 * graphite-interchange.c (memory_strides_in_loop_depth): New.
666 (pbb_interchange_profitable_p): Call memory_strides_in_loop_depth.
667
25e20d33
SP
6682009-11-18 Sebastian Pop <sebastian.pop@amd.com>
669
670 * graphite-blocking.c (scop_do_block): New.
671 * graphite-poly.c (apply_poly_transforms): Call scop_do_block.
672 * graphite-poly.h (scop_do_block): Declared.
673
e3bde9f4
SP
6742009-11-18 Sebastian Pop <sebastian.pop@amd.com>
675
676 * graphite-blocking.c (pbb_strip_mine_profitable_p): The parameter
677 depth is the loop nesting depth in the LST. Call psct_dynamic_dim
678 to transform depth into the time_depth before calling
679 pbb_number_of_iterations_at_time.
680 (lst_do_strip_mine): Use a scalar variable instead of recomputing
681 lst_depth.
682
27e432be
SP
6832009-11-18 Sebastian Pop <sebastian.pop@amd.com>
684
685 Reverted the patch for "scattering permutations" from 2009-10-28.
686
687 * graphite-poly.c (print_permutation): New.
688 (debug_permutation): New.
689 (new_poly_bb): Initialize PBB_PERMUTATION.
690 (free_poly_bb): Free PBB_PERMUTATION.
691 * graphite-poly.h (pbb_permutation_elt_p): Declared.
692 (struct pbb_permutation_elt): New.
693 (PBB_PERMUTATION_ELT_STRIDE): New.
694 (PBB_PERMUTATION_ELT_STRIDED_P): New.
695 (PBB_PERMUTATION_ELT_TIME_DIMENSION): New.
696 (new_pbb_permutation_elt): New.
697 (pbb_permutation_elt_free): New.
698 (struct poly_bb): Add field permutation.
699 (PBB_PERMUTATION): New.
700 (print_permutation): Declared.
701 (debug_permutation): Declared.
702
2bc529bf
KT
7032009-11-04 Konrad Trifunovic <konrad.trifunovic@inria.fr>
704
705 * graphite-interchange.c (build_partial_difference): New.
706 (memory_stride_in_loop): Refactored the computation of
707 equality constraints into build_partial_difference function.
708 Added support for debugging stride computations.
709
8c54631d
SP
7102009-11-03 Sebastian Pop <sebastian.pop@amd.com>
711
712 * graphite-clast-to-gimple.c (gloog): Free if_region,
713 if_region->true_region, and if_region->region.
714 * sese.c (if_region_set_false_region): Free if_region->false_region.
715 (create_if_region_on_edge): Do not use GGC_NEW.
716 (move_sese_in_condition): Remove useless initialization.
717
7b7f2ca7
SP
7182009-11-03 Sebastian Pop <sebastian.pop@amd.com>
719
720 * graphite-interchange.c (lst_perfect_nestify): Pass 3 parameters
721 for the loops created by the loop distribution. Do not modify the
722 input LSTs.
723 (lst_try_interchange_loops): Same. Use a temporary LST for the
724 transformed schedule. Call lst_update_scattering before data
725 dependence analysis.
726 (lst_try_interchange): Pass an extra parameter INDEX.
727 (lst_do_interchange_1): New.
728 (lst_do_interchange): Call lst_do_interchange_1.
729 (scop_do_interchange): Call lst_update_scattering.
730 * graphite-poly.c (apply_poly_transforms): Do not call
731 lst_update_scattering.
732 * graphite-poly.h (lst_pred): New.
733 (lst_succ): New.
734 (lst_find_first_pbb): Return NULL when not found.
735 (lst_empty_p): New.
736 (lst_insert_in_sequence): Allow LST1 to be NULL.
737 (lst_replace): New.
738 (lst_substitute_3): New.
739 * gcc.dg/graphite/interchange-1.c: XFail.
740 * gcc.dg/graphite/interchange-8.c: XFail.
741 * gcc.dg/graphite/interchange-11.c: XFail.
742
6119e7d5
SP
7432009-10-30 Sebastian Pop <sebastian.pop@amd.com>
744
745 * graphite-interchange.c (lst_perfectly_nested_p): New.
746 (lst_perfect_nestify): New.
747 (lst_try_interchange_loops): Call store_lst_schedule,
748 lst_perfectly_nested_p, lst_perfect_nestify and restore_lst_schedule.
749 (scop_do_interchange): Avoid redundant legality test.
750 Call lst_do_interchange on a copy of SCOP_TRANSFORMED_SCHEDULE.
751 * graphite-poly.c (apply_poly_transforms): Call lst_update_scattering.
752 * graphite-poly.h (psct_static_dim): New.
753 (lst_dewey_number_at_depth): New.
754 (lst_find_pbb): Restructured.
755 (lst_find_first_pbb): Restructured.
756 (lst_find_last_pbb): New.
757 (lst_contains_p): New.
758 (lst_contains_pbb): New.
759 (lst_create_nest): New.
760 (lst_remove_from_sequence): New.
761 (pbb_update_scattering): New.
762 (lst_update_scattering_under): New.
763 (lst_update_scattering_seq): New.
764 (lst_update_scattering): New.
765 (lst_insert_in_sequence): New.
766 (lst_distribute_lst): New.
767 (lst_remove_all_before_including_pbb): New.
768 (lst_remove_all_before_excluding_pbb): New.
769
431f3f22
SP
7702009-10-30 Sebastian Pop <sebastian.pop@amd.com>
771
772 * tree-ssa-loop-niter.c (finite_loop_p): Do not call twice
773 get_loop_exit_edges.
774
4c768046
SP
7752009-10-30 Sebastian Pop <sebastian.pop@amd.com>
776
777 * graphite-poly.c (pbb_remove_duplicate_pdrs): Free collapsed.
778
5fa8514e
SP
7792009-10-28 Konrad Trifunovic <konrad.trifunovic@gmail.com>
780
781 * graphite-poly.c (print_permutation): New.
782 (debug_permutation): New.
783 (new_poly_bb): Initialize PBB_PERMUTATION.
784 (free_poly_bb): Free PBB_PERMUTATION.
785 * graphite-poly.h (pbb_permutation_elt_p): Declared.
786 (struct pbb_permutation_elt): New.
787 (PBB_PERMUTATION_ELT_STRIDE): New.
788 (PBB_PERMUTATION_ELT_STRIDED_P): New.
789 (PBB_PERMUTATION_ELT_TIME_DIMENSION): New.
790 (new_pbb_permutation_elt): New.
791 (pbb_permutation_elt_free): New.
792 (struct poly_bb): Add field permutation.
793 (PBB_PERMUTATION): New.
794 (print_permutation): Declared.
795 (debug_permutation): Declared.
796
6c6f84d7
SP
7972009-10-26 Sebastian Pop <sebastian.pop@amd.com>
798
799 * graphite-clast-to-gimple.c (gloog): Do not call
800 sese_reset_aux_in_loops.
801 * graphite-sese-to-poly.c (build_loop_iteration_domains): Pass an
802 extra argument for domains. Do not use loop->aux.
803 (build_scop_iteration_domain): Initialize and free domains, pass it
804 to build_loop_iteration_domains and extract the information from
805 domains. Do not use loop->aux.
806 * sese.c (sese_reset_aux_in_loops): Removed.
807 * sese.h (sese_reset_aux_in_loops): Removed.
808
585b3e19
SP
8092009-10-26 Sebastian Pop <sebastian.pop@amd.com>
810
811 * graphite-clast-to-gimple.c (find_pbb_via_hash): Moved up.
812 (dependency_in_loop_p): Same.
813 (translate_clast): Do not use loop->aux. Initialize
814 loop->can_be_parallel.
815 (mark_loops_parallel): Removed.
816 * graphite-clast-to-gimple.h (mark_loops_parallel): Removed.
817 * graphite.c (free_aux_in_new_loops): Removed.
818 (graphite_finalize): Do not call free_aux_in_new_loops.
819 (graphite_transform_loops): Do not call mark_loops_parallel.
820
8212009-10-26 Li Feng <nemokingdom@gmail.com>
a7ed27ac
LF
822
823 * graphite-clast-to-gimple.c (get_stmtfor_depth): Removed.
824 (translate_clast): Pass an extra parameter LEVEL.
825 Call get_scattering_level.
826 * graphite-clast-to-gimple.h (get_scattering_level): New.
827
8e6ef139
SP
8282009-10-22 Sebastian Pop <sebastian.pop@amd.com>
829
830 * cfgloop.c (alloc_loop): Initialize loop->single_iv.
831 * cfgloop.h (struct loop): New field single_iv.
832
833 * graphite-clast-to-gimple.c (pbb_to_depth_to_oldiv): Do not use
834 loop->aux anymore: use loop->single_iv.
835 (graphite_loop_normal_form): Moved...
836 (build_graphite_loop_normal_form): Removed.
837 (gloog): Do not call build_graphite_loop_normal_form.
838 (free_aux_in_new_loops): Moved...
839 (mark_loops_parallel): Restructure.
840 * graphite-clast-to-gimple.h (free_aux_in_new_loops): Do not declare.
841 * graphite-sese-to-poly.c (graphite_loop_normal_form): ...here.
842 (scop_canonicalize_loops): New.
843 (build_poly_scop): Call scop_canonicalize_loops.
844 * graphite.c (free_aux_in_new_loops): ...here.
845
e6dd91b2
SP
8462009-10-22 Sebastian Pop <sebastian.pop@amd.com>
847
848 * g++.dg/graphite/graphite.exp: Add the same rules as in
849 gcc.dg/graphite/graphite.exp.
850
47fb473f
SP
8512009-10-22 Sebastian Pop <sebastian.pop@amd.com>
852
853 * g++.dg/graphite/id-1.C: New.
854
63858ac6
SP
8552009-10-22 Sebastian Pop <sebastian.pop@amd.com>
856
857 * graphite-sese-to-poly.c (create_zero_dim_array): Pass an extra
858 argument base_name.
859 (rewrite_close_phi_out_of_ssa): Update use of create_zero_dim_array.
860 (rewrite_phi_out_of_ssa): Same.
861 (rewrite_cross_bb_scalar_deps): Same.
862 (translate_scalar_reduction_to_array): Same.
863
decfe536
SP
8642009-10-22 Sebastian Pop <sebastian.pop@amd.com>
865
866 * graphite-sese-to-poly.c (build_scop_drs): Disable call to
867 dump_alias_graphs.
868
0d5ef2a9
SP
8692009-10-22 Sebastian Pop <sebastian.pop@amd.com>
870
871 * graphite-sese-to-poly.c (dump_alias_graphs): New.
872 (build_scop_drs): Call dump_alias_graphs.
873
f70de156
SP
8742009-10-22 Sebastian Pop <sebastian.pop@amd.com>
875
876 * graphite-poly.c (new_scop): Initialize SCOP_ORIGINAL_SCHEDULE,
877 SCOP_TRANSFORMED_SCHEDULE, and SCOP_SAVED_SCHEDULE.
878 (free_scop): Call free_lst on SCOP_ORIGINAL_SCHEDULE,
879 SCOP_TRANSFORMED_SCHEDULE, and SCOP_SAVED_SCHEDULE.
880 * graphite-poly.h (free_lst): New.
881 (store_lst_schedule): Free SCOP_SAVED_SCHEDULE.
882 (restore_lst_schedule): Free SCOP_TRANSFORMED_SCHEDULE.
883
74715a9b
SP
8842009-10-22 Sebastian Pop <sebastian.pop@amd.com>
885
886 * graphite-poly.h (struct scop): Add a field saved_schedule.
887 (SCOP_SAVED_SCHEDULE): New.
888 (store_lst_schedule): New.
889 (restore_lst_schedule): New.
890 (store_scattering): Call store_lst_schedule.
891 (restore_scattering): Call restore_lst_schedule.
892
fb00d28e
SP
8932009-10-20 Sebastian Pop <sebastian.pop@amd.com>
894
895 * graphite-sese-to-poly.c (free_data_refs_aux): Fix formatting.
896 (pdr_add_alias_set): Same.
897 (build_poly_dr): Same.
898 (build_alias_set_optimal_p): Same.
899 (build_base_obj_set_for_drs): Same. Do not store the result of
900 graphds_dfs.
901
917f481a
SP
9022009-10-20 Sebastian Pop <sebastian.pop@amd.com>
903
904 * graphite-sese-to-poly.c (build_alias_set_optimal_p): Initialize
905 all_components_are_cliques to 1.
906
2b178a5f
LF
9072009-10-20 Li Feng <nemokingdom@gmail.com>
908
909 * graphite-sese-to-poly.c (free_data_refs_aux): Update to free
910 the new structure.
911 (pdr_add_alias_set): Update retrieving alias_set_num.
912 (build_poly_dr): Update retrieving dr_base_object_set.
913 (partition_drs_to_sets): Remove.
914 (build_alias_set_optimal_p): New.
915 (build_alias_set_for_drs): Rename.
916 (build_scop_drs): Update.
917 * graphite-sese-to-poly.h (struct base_alias_pair): New.
918 (ALIAS_SET_INDEX): Remove.
919 (BASE_OBJECT_SET_INDEX): Remove.
920
e8af4842
SP
9212009-10-20 Sebastian Pop <sebastian.pop@amd.com>
922
923 * sese.c (get_vdef_before_sese): Handle GIMPLE_ASSIGN and GIMPLE_CALL.
924
3899a0b2
SP
9252009-10-20 Sebastian Pop <sebastian.pop@amd.com>
926
927 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Do not infer
928 loop upper bounds for 1-element arrays at end of structures.
929 * tree-flow.h (array_at_struct_end_p): Declared.
930 * tree-ssa-loop-niter.c (array_at_struct_end_p): Not static anymore.
931
e34e5835
SP
9322009-10-20 Sebastian Pop <sebastian.pop@amd.com>
933
934 * g++.dg/graphite/pr41305.C: New.
935
07b0d0e2
AM
9362009-10-20 Alexander Monakov <amonakov@ispras.ru>
937
938 * graphite-sese-to-poly.c (build_loop_iteration_domains): Generalize
939 construction of parameter constraints from loop iteration analysis.
940 * gcc.dg/graphite/run-id-2.c: New test.
941
67255edf
SP
9422009-10-17 Sebastian Pop <sebastian.pop@amd.com>
943
944 * graphite-interchange.c (memory_stride_in_loop): Delete p1, lma
945 and new_cstr.
946
14ba996b
SP
9472009-10-17 Sebastian Pop <sebastian.pop@amd.com>
948
949 * graphite-dependences.c (dependence_polyhedron_1): Remove
950 unused gdim dimensions from the DDR polyhedron.
951
4454141a
SP
9522009-10-17 Sebastian Pop <sebastian.pop@amd.com>
953
954 * graphite-dependences.c (pddr_transformed_scattering): New.
955 (dot_original_deps_stmt_1): New.
956 (dot_transformed_deps_stmt_1): New.
957 (dot_deps_stmt_1): Call dot_original_deps_stmt_1 and
958 dot_transformed_deps_stmt_1.
959 (dot_original_deps): New.
960 (dot_transformed_deps): New.
961 (dot_deps_1): Call dot_original_deps and dot_transformed_deps.
962
dd61070d
SP
9632009-10-17 Sebastian Pop <sebastian.pop@amd.com>
964
965 * graphite-dependences.c (reduction_dr_1): Remove wrong
966 assert: reduction BBs can have multiple reduction writes
4454141a 967 to memory. interchange-3.f90 is an example.
dd61070d 968
65421bcc
SP
9692009-10-17 Sebastian Pop <sebastian.pop@amd.com>
970
971 * gfortran.dg/graphite/interchange-3.f90: New.
972
3e9f43ee
SP
9732009-10-17 Sebastian Pop <sebastian.pop@amd.com>
974
975 * gcc.dg/graphite/interchange-1.c: Un-XFAILed.
976
16bf8ab1
SP
9772009-10-17 Sebastian Pop <sebastian.pop@amd.com>
978
979 * graphite-dependences.c (dependence_polyhedron_1): Add the
980 context to the dependence polyhedron.
981
d422adfa
SP
9822009-10-17 Sebastian Pop <sebastian.pop@amd.com>
983
984 * graphite-poly.c (pbb_remove_duplicate_pdrs): Initialize
985 PBB_PDR_DUPLICATES_REMOVED.
986 (new_poly_bb): Same.
987
62e475c5
SP
9882009-10-17 Sebastian Pop <sebastian.pop@amd.com>
989
990 * graphite-sese-to-poly.c (find_scop_parameters): Initialize
991 SCOP_CONTEXT.
992 (build_loop_iteration_domains): Extract bounds on parameters
993 based on the data size.
994 (build_scop_context): Do not initialize SCOP_CONTEXT;
995 add new constraints.
996
3ecbce7e
SP
9972009-10-17 Sebastian Pop <sebastian.pop@amd.com>
998
999 * graphite-ppl.c (ppl_min_for_le_polyhedron): New.
1000 * graphite-ppl.h (graphite-ppl.h): Declared.
1001
04863400
SP
10022009-10-17 Sebastian Pop <sebastian.pop@amd.com>
1003
1004 * graphite-ppl.c (ppl_print_linear_expr): New.
1005 (debug_ppl_linear_expr): New.
1006 * graphite-ppl.h (ppl_print_linear_expr): Declared.
1007 (debug_ppl_linear_expr): Declared.
1008
009150e1
SP
10092009-10-16 Sebastian Pop <sebastian.pop@amd.com>
1010
1011 * graphite-interchange.c: Fix comments.
1012 * gcc.dg/graphite/block-1.c: Fix comments.
1013
9b196c93
SP
10142009-10-16 Sebastian Pop <sebastian.pop@amd.com>
1015
1016 * gcc.dg/graphite/interchange-7.c: Un-XFAILed.
1017 * gcc.dg/graphite/interchange-9.c: Un-XFAILed.
1018
caa675f8
SP
10192009-10-16 Sebastian Pop <sebastian.pop@amd.com>
1020
1021 Reapply the patch from Alexander Monakov that disappeared during
1022 the last merges from trunk.
1023
1024 2009-09-16 Alexander Monakov <amonakov@ispras.ru>
1025
1026 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Add bounds only
1027 for ARRAY_REFs. Use array_ref_{low,up}_bound to determine bounds.
1028
92d92abb
SP
10292009-10-15 Sebastian Pop <sebastian.pop@amd.com>
1030
1031 * graphite-interchange.c (memory_stride_in_loop): The depth
1032 argument corresponds to a dynamic time dimension, so use
1033 psct_dynamic_dim to refer to the transformed scattering dimension.
1034
23159c56
SP
10352009-10-15 Sebastian Pop <sebastian.pop@amd.com>
1036
1037 * graphite-interchange.c (memory_stride_in_loop): Fix comments.
1038
5c6c42c9
SP
10392009-10-15 Sebastian Pop <sebastian.pop@amd.com>
1040
1041 * graphite-blocking.c (lst_do_strip_mine): Avoid strip mining the
1042 root of the LST.
1043 * graphite-interchange.c (lst_do_interchange): Avoid interchanging
1044 the root of the LST.
1045 * graphite-poly.c (scop_to_lst): Fix LST sequence in an outermost
1046 fake loop.
1047 (print_lst): Print the root of LST in a different format.
1048 * graphite-poly.h (lst_depth): Adjust to include the root of the LST.
1049
f58be90e
SP
10502009-10-15 Sebastian Pop <sebastian.pop@amd.com>
1051
1052 * graphite-poly.c (print_scop): Fix pretty printing of a SCoP.
1053
4e4ee197
SP
10542009-10-15 Sebastian Pop <sebastian.pop@amd.com>
1055
1056 * doc/passes.texi: Document the Graphite infrastructure.
1057
6c4499b6
SP
10582009-10-15 Sebastian Pop <sebastian.pop@amd.com>
1059
1060 * graphite-sese-to-poly.c (insert_copyin): Use gsi_insert_seq_on_edge.
1061 (rewrite_commutative_reductions_out_of_ssa): Call gsi_commit_edge_inserts,
1062 and check the SSA representation.
1063
1064 * gfortran.dg/graphite/id-18.f90: New, reduced from PR41193.
1065
8e49fe91
SP
10662009-10-15 Sebastian Pop <sebastian.pop@amd.com>
1067
1068 * gcc.dg/graphite/pr40157.c: Use -floop-block as reported in the PR.
1069
bb2b2dfc
SP
10702009-10-14 Sebastian Pop <sebastian.pop@amd.com>
1071
1072 * gcc.dg/graphite/interchange-11.c: New.
1073
e7ed4a64
SP
10742009-10-14 Sebastian Pop <sebastian.pop@amd.com>
1075
1076 * gcc.dg/graphite/interchange-8.c: Enable loop interchange.
1077
d7f25aa6
SP
10782009-10-14 Sebastian Pop <sebastian.pop@amd.com>
1079
1080 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK):
1081 Add -fno-loop-strip-mine and -fno-loop-interchange.
1082 (DEFAULT_FLAGS_GRAPHITE_INTERCHANGE): Add -fno-loop-block and
1083 -fno-loop-strip-mine.
1084 * gfortran.dg/graphite/graphite.exp: Same.
1085
6231cf49
SP
10862009-10-14 Sebastian Pop <sebastian.pop@amd.com>
1087
1088 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK):
1089 Renamed DEFAULT_FLAGS_GRAPHITE_BLOCK.
1090 (DEFAULT_CFLAGS_GRAPHITE_IDENTITY): Renamed
1091 DEFAULT_FLAGS_GRAPHITE_IDENTITY.
1092 (DEFAULT_CFLAGS_GRAPHITE_INTERCHANGE): Renamed
1093 DEFAULT_FLAGS_GRAPHITE_INTERCHANGE.
1094 (DEFAULT_CFLAGS_GRAPHITE_SCOP): Renamed
1095 DEFAULT_FLAGS_GRAPHITE_SCOP.
1096 (DEFAULT_CFLAGS_RUN_ID): Renamed DEFAULT_FLAGS_RUN_ID.
1097 (DEFAULT_CFLAGS_GRAPHITE): Renamed DEFAULT_FLAGS_GRAPHITE.
1098
2b7c09a8
SP
10992009-10-14 Sebastian Pop <sebastian.pop@amd.com>
1100
1101 * graphite-poly.c (pbb_number_of_iterations_at_time): Cleanup comments.
1102
b0c7a278
KT
11032009-10-14 Konrad Trifunovic <konrad.trifunovic@gmail.com>
1104 Sebastian Pop <sebastian.pop@amd.com>
1105
1106 * graphite-interchange.c (build_linearized_memory_access): Pass an
1107 offset as parameter.
1108 (memory_stride_in_loop): Include transform scattering in the
1109 access functions to be able to querry the strides in the
1110 transformed loops.
1111 (pbb_interchange_loop_depths): Interchange the psct_dynamic_dim,
1112 not the psct_iterator_dim.
1113
13ae6f91
SP
11142009-10-14 Sebastian Pop <sebastian.pop@amd.com>
1115
1116 * graphite-blocking.c (pbb_do_strip_mine): Removed.
1117 (lst_do_strip_mine_loop): New.
1118 (lst_do_strip_mine): New.
1119 (scop_do_strip_mine): Call lst_do_strip_mine.
1120 * graphite-poly.h (lst_add_loop_under_loop): New.
1121 (lst_find_first_pbb): New.
1122
c0fe753b
SP
11232009-10-14 Sebastian Pop <sebastian.pop@amd.com>
1124
1125 * graphite-poly.c (loop_to_lst): Fix LST creation.
1126
8d75ec87
TG
11272009-10-14 Tobias Grosser <grosser@fim.uni-passau.de>
1128
45489e99 1129 * gcc.dg/graphite/id-15.c: (8 * 8) replaced with
8d75ec87
TG
1130 sizeof(unsigned long) to make it run on 32bit systems.
1131
11322009-10-14 Tobias Grosser <grosser@fim.uni-passau.de>
1133
45489e99 1134 * gcc.dg/graphite/run-id-1.c: Use smaller matrix to not
8d75ec87
TG
1135 SEGFAULT on 32bit.
1136
2e5a7cbf
RU
11372009-10-14 Ramakrishna Upadrasta <Ramakrishna.Upadrasta@inria.fr>
1138
8d75ec87
TG
1139 * graphite-sese-to-poly.c (write_alias_graph_to_ascii_dimacs): Fix
1140 Comment.
2e5a7cbf
RU
1141 (write_alias_graph_to_ascii_dot): New.
1142 (write_alias_graph_to_ascii_ecc): Ditto.
8d75ec87
TG
1143 (partition_drs_to_sets): Add testing of optimality of current method
1144 which assigns alias numbers according to DFS Comopnent number. used
1145 as heuristic for the upcoming ECC algorithm.
2e5a7cbf
RU
1146 (build_scop_drs): Write to file also with the ecc and dot format.
1147
1e82de2a
SP
11482009-10-13 Sebastian Pop <sebastian.pop@amd.com>
1149
1150 * gfortran.dg/graphite/interchange-1.f: XFail.
1151
9bf13085
SP
11522009-10-13 Sebastian Pop <sebastian.pop@amd.com>
1153
1154 * graphite.c (graphite_initialize): Do not handle functions with
1155 more than 100 basic blocks.
1156
e797c5f2
SP
11572009-10-13 Sebastian Pop <sebastian.pop@amd.com>
1158
1159 * graphite-blocking.c (pbb_do_strip_mine): Use
1160 PARAM_LOOP_BLOCK_TILE_SIZE.
1161
bfa00f48
SP
11622009-10-13 Sebastian Pop <sebastian.pop@amd.com>
1163
1164 * graphite-poly.c (dot_lst_1): New.
1165 (dot_lst): New.
1166 * graphite-poly.h (dot_lst): Declared.
1167
3c7bdeb8
SP
11682009-10-13 Sebastian Pop <sebastian.pop@amd.com>
1169
1170 * graphite-dependences.c (dot_deps_stmt_1): New.
1171 (dot_deps_stmt): New.
1172 * graphite-dependences.h (dot_deps_stmt): Declared.
1173
c7dc2fab
SP
11742009-10-09 Sebastian Pop <sebastian.pop@amd.com>
1175
1176 * graphite-sese-to-poly.c (rewrite_cross_bb_scalar_dependence): Do
1177 not replace cross BB scalar dependences ending on PHI nodes.
1178 (rewrite_cross_bb_scalar_deps): Filter out GIMPLE_PHI nodes.
1179
24c79709
SP
11802009-10-09 Sebastian Pop <sebastian.pop@amd.com>
1181
1182 * graphite-poly.c (apply_poly_transforms): Implement the high
1183 level driver for flag_loop_block.
45489e99 1184 * opts.c (decode_options): Enable flag_loop_block at -O2.
24c79709
SP
1185 * tree-ssa-loop.c (gate_graphite_transforms): Remove call to sorry for
1186 flag_loop_block.
1187
1188 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK): Add
1189 -floop-block.
1190 * gfortran.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK):
1191 Add -floop-block.
1192
a0517b76
SP
11932009-10-09 Sebastian Pop <sebastian.pop@amd.com>
1194
1195 * graphite-poly.h (lst_find_pbb): New.
1196 (find_lst_loop): New.
1197
9d077835
SP
11982009-10-09 Sebastian Pop <sebastian.pop@amd.com>
1199
1200 * graphite-poly.c (new_scop): Remove init of SCOP_DEP_GRAPH.
1201 * graphite-poly.h (struct scop): Remove dep_graph field.
1202 (SCOP_DEP_GRAPH): Removed.
1203
75b63a91
SP
12042009-10-09 Sebastian Pop <sebastian.pop@amd.com>
1205
1206 * graphite-poly.h (copy_lst): Do full copy of LST.
1207
7cc4ff8d
SP
12082009-10-07 Sebastian Pop <sebastian.pop@amd.com>
1209
1210 * graphite-sese-to-poly.c (reduction_phi_p): Call remove_invariant_phi
1211 when the loop stride is zero.
1212
1213 * gcc.dg/graphite/id-16.c: New.
1214
60d2a8c3
SP
12152009-10-06 Sebastian Pop <sebastian.pop@amd.com>
1216
1217 * graphite-dependences.c (reduction_dr_1): New.
1218 (reduction_dr_p): New.
1219 (graphite_legal_transform_dr): Call reduction_dr_p.
1220 (reduction_ddr): Renamed reduction_ddr_p.
1221 * graphite-poly.h (same_pdr_p): New.
1222 (number_of_write_pdrs): New.
1223 * graphite-sese-to-poly.c (nb_data_writes_in_bb): New.
1224 (split_reduction_stmt): Do not split reduction statements
1225 when there are no writes to memory.
1226 (translate_scalar_reduction_to_array_for_stmt): Insert the
1227 memory reduction statement just after the scalar reduction statement.
1228
1229 * gcc.dg/graphite/interchange-10.c: Updated to differ from interchange-4.c.
1230 Un-XFAIL-ed.
1231 * gcc.dg/graphite/interchange-3.c: Un-XFAIL-ed.
1232 * gcc.dg/graphite/interchange-4.c: Un-XFAIL-ed.
1233
95baeff8
SP
12342009-10-06 Sebastian Pop <sebastian.pop@amd.com>
1235
1236 * graphite-interchange.c (lst_apply_interchange): New.
1237 (lst_interchange_profitable_p): New.
1238 (lst_try_interchange_loops): New.
1239 (lst_try_interchange): New.
1240 (lst_do_interchange): New.
1241 (pbb_do_interchange): Removed.
1242 (scop_do_interchange): Call lst_do_interchange.
1243
a36d12e2
SP
12442009-10-06 Sebastian Pop <sebastian.pop@amd.com>
1245
1246 * graphite-poly.c (print_scop): Print SCOP_ORIGINAL_SCHEDULE and
1247 SCOP_TRANSFORMED_SCHEDULE.
1248 (loop_to_lst): New.
1249 (scop_to_lst): New.
1250 (print_lst): New.
1251 (debug_lst): New.
1252 * graphite-poly.h (lst_p): New.
1253 (struct lst): New.
1254 (LST_LOOP_P): New.
1255 (LST_LOOP_FATHER): New.
1256 (LST_PBB): New.
1257 (LST_SEQ): New.
1258 (scop_to_lst): Declared.
1259 (print_lst): Declared.
1260 (debug_lst): Declared.
1261 (new_lst_loop): New.
1262 (new_lst_stmt): New.
1263 (copy_lst): New.
1264 (lst_depth): New.
1265 (lst_dewey_number): New.
1266 (struct scop): Add original_schedule and transformed_schedule fields.
1267 (SCOP_ORIGINAL_SCHEDULE): New.
1268 (SCOP_TRANSFORMED_SCHEDULE): New.
1269 * graphite-sese-to-poly.c (build_poly_scop): Call scop_to_lst.
1270
a0dd1440
SP
12712009-10-05 Sebastian Pop <sebastian.pop@amd.com>
1272
1273 * graphite-dependences.c (reduction_ddr): New.
1274 (graphite_legal_transform_bb): Call reduction_ddr.
1275 * graphite-poly.c (new_poly_bb): Pass a new bool parameter.
1276 Initialize PBB_IS_REDUCTION.
1277 * graphite-poly.h (struct poly_bb): New bool field is_reduction.
1278 (PBB_IS_REDUCTION): New.
1279 (new_poly_bb): Update declaration.
1280 * graphite-scop-detection.h (build_scop_bbs): Removed.
1281 (nb_reductions_in_loop): Removed.
1282 * graphite-sese-to-poly.c (try_generate_gimple_bb): Pass a sbitmap
1283 parameter for reductions.
1284 (try_generate_gimple_bb): Update call to new_poly_bb.
1285 (build_scop_bbs_1): Same.
1286 (build_scop_bbs): Same.
1287 (gsi_for_phi_node): New.
1288 (scalar_close_phi_node_p): Remove gcc_assert.
1289 (split_reduction_stmt): New.
1290 (is_reduction_operation_p): New.
1291 (phi_contains_arg): New.
1292 (follow_ssa_with_commutative_ops): New.
1293 (detect_commutative_reduction_arg): New.
1294 (detect_commutative_reduction_assign): New.
1295 (follow_inital_value_to_phi): New.
1296 (edge_initial_value_for_loop_phi): New.
1297 (initial_value_for_loop_phi): New.
1298 (detect_commutative_reduction): New.
1299 (translate_scalar_reduction_to_array_for_stmt): New.
1300 (insert_copyout): New.
1301 (insert_copyin): New.
1302 (translate_scalar_reduction_to_array): New.
1303 (rewrite_commutative_reductions_out_of_ssa_close_phi): New.
1304 (rewrite_commutative_reductions_out_of_ssa_loop): New.
1305 (rewrite_commutative_reductions_out_of_ssa): New.
1306 (build_poly_scop): Call rewrite_commutative_reductions_out_of_ssa.
1307 * sese.h (split_region_for_bb): New.
1308
1309 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK): Add -ffast-math.
1310 * gcc.dg/graphite/interchange-1.c: Fix format.
1311 * gcc.dg/graphite/interchange-10.c: New.
1312
db7e9485
SP
13132009-10-05 Sebastian Pop <sebastian.pop@amd.com>
1314
1315 * graphite-sese-to-poly.c (insert_out_of_ssa_copy): Remove
1316 buggy assert.
1317
5dcc64d9
SP
13182009-10-05 Sebastian Pop <sebastian.pop@amd.com>
1319
1320 * graphite-sese-to-poly.c (scev_analyzable_p): New.
1321 (rewrite_cross_bb_scalar_dependence): New.
1322 (rewrite_cross_bb_scalar_deps): New.
1323 (rewrite_reductions_out_of_ssa): Use bb_in_sese_p.
1324 Call rewrite_cross_bb_scalar_deps.
1325
947121b8
SP
13262009-10-05 Sebastian Pop <sebastian.pop@amd.com>
1327
1328 * graphite-sese-to-poly.c (gsi_for_ssa_name_def): Removed.
1329 (insert_out_of_ssa_copy): Directly use gsi_after_labels and
1330 gsi_for_stmt.
1331
d48e288d
SP
13322009-10-05 Sebastian Pop <sebastian.pop@amd.com>
1333
1334 * graphite-clast-to-gimple.c (build_cloog_prog): Use pbb_index.
1335 * graphite-interchange.c (pbb_do_interchange): Same.
1336 * graphite-poly.c (print_scattering_function): Same.
1337 (debug_pdrs): Same.
1338 * graphite-poly.h (pbb_loop): New.
1339 * graphite-sese-to-poly.c (create_linear_expr_from_tree): Use pbb_loop.
1340
d17286f6
SP
13412009-09-27 Sebastian Pop <sebastian.pop@amd.com>
1342
1343 * graphite-scop-detection.c (limit_scops): Do not build poly_bbs.
1344
ee03cd20
SP
13452009-09-27 Sebastian Pop <sebastian.pop@amd.com>
1346
1347 * graphite-sese-to-poly.c (partition_drs_to_sets): Drs is not modified,
1348 so don't pass a pointer to it.
1349 (build_alias_set_for_drs): Same.
1350 (build_base_obj_set_for_drs): Same.
1351 (build_scop_drs): Same.
1352
888beba1
LF
13532009-09-26 Li Feng <nemokingdom@gmail.com>
1354
1355 * graphite-sese-to-poly.c (build_scop_drs): Disable writing to file
1356 the alias graph of data references.
1357
cd43e5d7
LF
13582009-09-25 Li Feng <nemokingdom@gmail.com>
1359
1360 * graphite-sese-to-poly.c (write_alias_graph_to_ascii_dimacs): New.
1361 (build_scop_drs): When debugging, write the alias graph to file,
1362 otherwise, should be disabled.
1363
45489e99
SP
13642009-09-17 Sebastian Pop <sebastian.pop@amd.com>
1365
1366 * Merge from mainline (151310:151361).
1367
13682009-09-17 Sebastian Pop <sebastian.pop@amd.com>
1369
1370 * Merge from mainline (151171:151310).
1371
13722009-09-17 Sebastian Pop <sebastian.pop@amd.com>
1373
1374 * Merge from mainline (151171:151806).
1375
13762009-09-17 Sebastian Pop <sebastian.pop@amd.com>
1377
1378 * Revert the last commit.
1379
13802009-09-17 Sebastian Pop <sebastian.pop@amd.com>
1381
1382 * Merge from mainline (151171:151819).
1383
aeda6535
SP
13842009-09-17 Sebastian Pop <sebastian.pop@amd.com>
1385
1386 * graphite-scop-detection.c (stmt_simple_memref_p): Removed.
1387 (is_simple_operand): Remove call to stmt_simple_memref_p.
1388 (stmt_simple_for_scop_p): Update call to is_simple_operand.
1389
8b6b8570
DE
13902009-09-17 David Edelsohn <edelsohn@gnu.org>
1391
45489e99
SP
1392 * gcc.dg/graphite/interchange-mvt.c: New File.
1393 * gcc.dg/graphite/scop-dsyrk.c: New File.
1394 * gcc.dg/graphite/scop-dsyr2k.c: New File.
1395 * gcc.dg/graphite/scop-mvt.c: New File.
1396 * gcc.dg/graphite/scop-sor.c: New File.
8b6b8570 1397
1825f9a2
LF
13982009-09-17 Li Feng <nemokingdom@gmail.com>
1399
1825f9a2
LF
1400 * graphite-dependences.c (poly_drs_may_alias_p): Adjust definition.
1401 (pddr_original_scattering): Make sure 2 pdr2 in the same base object set.
1402 (graphite_carried_dependence_level_k): Ditto.
1403 * graphite-poly.c (new_poly_dr): Add init of PDR_BASE_OBJECT_SET.
1404 * graphite-poly.h (struct poly_dr): Add member dr_base_object_set.
1405 (new_poly_dr): Adjust declaration.
1406 * graphite-sese-to-poly.c (free_data_refs_aux): New.
1407 (free_gimple_bb): Added free_data_refs_aux.
1408 (build_poly_dr): Add dr_base_object_set.
1409 (partition_drs_to_sets): New.
1410 (dr_same_base_object_p): New.
1411 (build_alias_set_for_drs): New.
1412 (build_base_object_set_for_drs): New.
1413 (build_scop_drs): Add build_base_obj_set_for_drs.
1414 * graphite-sese-to-poly.h: Added #define for alias set number index and
1415 base object set index.
1416 * libgomp/testsuite/libgomp.graphite/force-parallel-6.c: Refine tests.
1417 * libgomp/testsuite/libgomp.graphite/pr4118.c: New.
1418
ac90803f
SP
14192009-09-16 Alexander Monakov <amonakov@ispras.ru>
1420
1421 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Add bounds only
1422 for ARRAY_REFs. Use array_ref_{low,up}_bound to determine bounds.
1423
54fc808a
SP
14242009-09-14 Sebastian Pop <sebastian.pop@amd.com>
1425
1426 * graphite-sese-to-poly.c (struct irp_data): Removed.
1427 (idx_record_params): Removed.
1428 (find_params_in_bb): Scan for parameters the access functions; don't
1429 parse the tree representation.
1430
e88e021f
SP
14312009-09-14 Sebastian Pop <sebastian.pop@amd.com>
1432
1433 * tree-ssa-loop.c (gate_graphite_transforms): Disable Graphite
1434 passes at -O1 and below.
1435
3690f8d7
SP
14362009-09-14 Sebastian Pop <sebastian.pop@amd.com>
1437
1438 * graphite-blocking.c: Fix order of includes: tree-chrec.h, then
1439 tree-scalar-evolution.h, and then tree-data-ref.h.
1440 * graphite-clast-to-gimple.c: Same.
1441 * graphite-dependences.c: Same.
1442 * graphite-interchange.c: Same.
1443 * graphite-poly.c: Same.
1444 * graphite-scop-detection.c: Same.
1445 * graphite-sese-to-poly.c: Same.
1446 * graphite.c: Same.
1447 * lambda-code.c: Same.
1448 * matrix-reorg.c: Same.
1449 * tree-data-ref.c: Same.
1450 * tree-if-conv.c: Same.
1451 * tree-loop-distribu: Same.: Same.
1452 * tree-loop-linear.c: Same.
1453 * tree-parloops.c: Same.
1454 * tree-predcom.c: Same.
1455 * tree-vect-patterns.c: Same.
1456
2495a183
SP
14572009-09-02 Sebastian Pop <sebastian.pop@amd.com>
1458
1459 Partially revert the previous patch, except the following.
1460 * tree-scalar-evolution.c (instantiate_scev_not): Adapted to pass
1461 as parameters the operands of the not expression.
1462
20179b0d
SP
14632009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1464
1465 * tree-scalar-evolution.c (instantiate_scev_assign): New.
1466 Do not call analyze_scalar_evolution on assignments.
1467 (instantiate_scev_phi): Call analyze_scalar_evolution.
1468 (instantiate_scev_name): Call instantiate_scev_assign and
1469 instantiate_scev_phi.
1470 (instantiate_scev_not): Adapted to pass as parameters the operands
1471 of the not expression.
1472
ffa34f4b
SP
14732009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1474
1475 * tree-scalar-evolution.c (instantiate_scev_binary): Adapted
1476 to pass as parameters the operands of the binary expression.
1477
4b9d48a1
SP
14782009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1479
1480 * tree-scalar-evolution.c (instantiate_scev_bitnot): Renamed
1481 instantiate_scev_not. Handle NEGATE_EXPR.
1482 (instantiate_scev_r): Handle NEGATE_EXPR.
1483
9e5dc77f
SP
14842009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1485
1486 * tree-scalar-evolution.c (instantiate_scev_1): Renamed
1487 instantiate_scev_r.
1488 (instantiate_scev_r): Move code in instantiate_scev_2
1489 and instantiate_scev_1.
1490
d814176c
SP
14912009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1492
1493 * tree-scalar-evolution.c (instantiate_scev_3): New.
1494 (instantiate_scev_1): Move code in instantiate_scev_3.
1495
ec6636eb
SP
14962009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1497
1498 * tree-scalar-evolution.c (instantiate_scev_poly): New.
1499 (instantiate_scev_1): Move code in instantiate_scev_poly.
1500
7ec0665d
SP
15012009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1502
1503 * tree-scalar-evolution.c (instantiate_scev_bitnot): New.
1504 (instantiate_scev_1): Move code in instantiate_scev_bitnot.
1505
9c382ce9
SP
15062009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1507
1508 * tree-scalar-evolution.c (instantiate_scev_convert): New.
1509 (instantiate_scev_1): Move code in instantiate_scev_convert.
1510
15fda317
SP
15112009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1512
1513 * tree-scalar-evolution.c (instantiate_scev_binary): New.
1514 (instantiate_scev_1): Move code in instantiate_scev_binary.
1515
320f5a78
SP
15162009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1517
1518 * tree-scalar-evolution.c (instantiate_scev_name): New.
1519 (instantiate_scev_1): Move code in instantiate_scev_name.
1520
15212009-08-28 Sebastian Pop <sebastian.pop@amd.com>
1522
1523 * Merge from mainline (150992:151171).
1524
45489e99
SP
15252009-08-25 Sebastian Pop <sebastian.pop@amd.com>
1526
1527 * opts.c (decode_options): Enable flag_loop_interchange at -O2.
1528
211694b6
SP
15292009-08-25 Sebastian Pop <sebastian.pop@amd.com>
1530
1531 * graphite-dependences.c (graphite_legal_transform_bb): Call
1532 pbb_remove_duplicate_pdrs.
1533 * graphite-poly.c (can_collapse_pdr): Removed.
1534 (pdr_find_duplicate): Removed.
1535 (can_collapse_pdrs): New.
1536 (pbb_remove_duplicate_pdrs): New.
1537 (new_poly_dr): Do not look for duplicates.
1538 * graphite-poly.h (struct poly_bb): New field pdr_duplicates_removed.
1539 (PBB_PDR_DUPLICATES_REMOVED): New.
1540 (pbb_remove_duplicate_pdrs): Declared.
1541
7bd2a8a7
SP
15422009-08-25 Sebastian Pop <sebastian.pop@amd.com>
1543
1544 * graphite-interchange.c (pbb_interchange_profitable_p): Adjust
1545 the strides by multiplying by PDR_NB_REFS.
1546 * graphite-poly.c (can_collapse_pdr): New.
1547 (pdr_find_duplicate): New.
1548 (new_poly_dr): Call pdr_find_duplicate. Collapse duplicate PDRs.
1549 Initialize PDR_NB_REFS.
1550 * graphite-poly.h (struct poly_dr): Add field nb_refs.
1551 (PDR_NB_REFS): New.
1552 (new_poly_dr): Number of subscripts is a graphite_dim_t.
1553
15542009-08-25 Sebastian Pop <sebastian.pop@amd.com>
1555
1556 Revert one of the previous commits:
1557 * graphite-dependences.c (graphite_legal_transform_bb): Avoid
1558 the computation of symmetric data dependence relations.
1559 (dependency_between_pbbs_p): Same.
1560
93b2db87
SP
15612009-08-25 Sebastian Pop <sebastian.pop@amd.com>
1562
1563 PR middle-end/40965
1564 * graphite-poly.c (apply_poly_transforms): Remove legality test before
1565 any transform.
1566
d8eeb078
SP
15672009-08-25 Sebastian Pop <sebastian.pop@amd.com>
1568
1569 * graphite-dependences.c (pddr_original_scattering): Return NULL
1570 for read-read dependence relations.
1571 * graphite-poly.h (enum poly_dr_type): Fix comment.
1572 (pdr_read_p): New.
1573 (pdr_write_p): New.
1574 (pdr_may_write_p): New.
1575
e6dec0fb
SP
15762009-08-25 Sebastian Pop <sebastian.pop@amd.com>
1577
1578 * graphite-poly.h (enum POLY_DR_TYPE): Renamed poly_dr_type.
1579 (struct poly_dr): Same.
1580 (new_poly_dr): Same.
1581 * graphite-poly.c (new_poly_dr): Same.
1582
baf4b881
KT
15832009-08-25 Konrad Trifunovic <konrad.trifunovic@gmail.com>
1584 Sebastian Pop <sebastian.pop@amd.com>
1585
1586 * graphite-blocking.c (pbb_strip_mine_loop_depth): Renamed
1587 pbb_strip_mine_time_depth. Changed the implementation so that
1588 transformation is expressed as a transformation on
1589 time (scatttering) dimensions. Also, ensures that the 2d+1
1590 scheduling format is preserved.
1591 (pbb_strip_mine_profitable_p): Profitability is based on the
1592 iteration number of a given time (scattering) dimension,
1593 and not on a original loop depth dimension.
1594 (pbb_strip_mine): Call pbb_number_of_iterations_at_time.
1595 (pbb_do_strip_mine): Call psct_dynamic_dim.
1596 * graphite-poly.c (pbb_number_of_iterations_at_time): New.
1597 * graphite-poly.h (pbb_number_of_iterations_at_time): Declared.
1598 (pbb_nb_dynamic_scattering_transform): New.
1599 (psct_dynamic_dim): New.
1600
059a5f9f
KT
16012009-08-25 Konrad Trifunovic <konrad.trifunovic@gmail.com>
1602
1603 * graphite-ppl.c (ppl_max_for_le): Renamed ppl_max_for_le_pointset.
1604 * graphite-ppl.h (ppl_max_for_le): Renamed ppl_max_for_le_pointset.
1605 * graphite-poly.c (pbb_number_of_iterations): Rename ppl_max_for_le.
1606 * graphite-interchange.c (build_linearized_memory_access): Same.
1607 (memory_stride_in_loop): Same.
1608
afae0207
SP
16092009-08-25 Sebastian Pop <sebastian.pop@amd.com>
1610
1611 * graphite-dependences.c (pddr_original_scattering): New.
1612 (graphite_legal_transform_dr): Call pddr_original_scattering.
1613 (dot_deps_1): New.
1614 (dot_deps): New.
1615 * graphite-dependences.h (dot_deps): Declared.
1616 * graphite-poly.c (new_poly_dr): Initialize PDR_ID.
1617 (print_pdr): Print PDR_ID.
1618 * graphite-poly.h (struct poly_dr): Add field id.
1619 (PDR_ID): New.
1620 (pbb_index): New.
1621 * graphite-scop-detection.c (dot_all_scops_1): Cleanup comment.
1622
f8e0bb8b
SP
16232009-08-22 Sebastian Pop <sebastian.pop@amd.com>
1624
1625 * graphite-dependences.c (graphite_carried_dependence_level_k): Do
1626 not delete the original dependence relation.
1627
16282009-08-21 Sebastian Pop <sebastian.pop@amd.com>
1629
1630 * graphite-dependences.c (graphite_legal_transform_bb): Avoid
1631 the computation of symmetric data dependence relations.
1632 (dependency_between_pbbs_p): Same.
1633
e37f165f
SP
16342009-08-21 Sebastian Pop <sebastian.pop@amd.com>
1635
1636 * graphite-dependences.c (new_poly_dr_pair): Renamed new_poly_ddr.
1637 (eq_poly_dr_pair_p): Renamed eq_poly_ddr_p.
1638 (hash_poly_dr_pair_p): Renamed hash_poly_ddr_p.
1639 (free_poly_ddr): New.
1640 (pddr_is_empty): New.
1641 (dependence_polyhedron_1): Now returns a poly_ddr_p.
1642 (dependence_polyhedron): Same. Remove useless gcc_assert.
1643 Remove fprintfs.
1644 (graphite_legal_transform_dr): Call pddr_is_empty and free_poly_ddr.
1645 (graphite_carried_dependence_level_k): Call pddr_is_empty.
1646 * graphite-dependences.h (enum poly_dependence_kind): New.
1647 (poly_dr_pair): Renamed poly_ddr. Added a field kind.
1648 (PDRP_SOURCE): Renamed PDDR_SOURCE.
1649 (PDRP_SINK): Renamed PDDR_SINK.
1650 (PDRP_DDP): Renamed PDDR_DDP.
1651 (PDDR_KIND): New.
1652 (free_poly_ddr): Declared.
1653 * graphite-poly.c (new_scop): Use the new hash function names.
1654 * graphite-poly.h (struct scop): Renamed field original_pdr_pairs
1655 into original_pddrs.
1656 (SCOP_ORIGINAL_PDR_PAIRS): Renamed SCOP_ORIGINAL_PDDRS.
1657
16582009-08-21 Sebastian Pop <sebastian.pop@amd.com>
1659
1660 * Merge from mainline (150764:150992).
1661
45e76e9f
SP
16622009-08-18 Sebastian Pop <sebastian.pop@amd.com>
1663
1664 * cfgloopmanip.c (create_empty_loop_on_edge): Generate upper
1665 bounds with LT_EXPR to make niter analysis more precise on code
1666 generated by Graphite.
1667
66b466c3
SP
16682009-08-18 Sebastian Pop <sebastian.pop@amd.com>
1669
1670 * graphite-dependences.c (graphite_legal_transform_dr): Fix formatting.
1671 (graphite_legal_transform_bb): Same.
1672 (poly_drs_may_alias_p): Same.
1673
f263917c
SP
16742009-08-15 Sebastian Pop <sebastian.pop@amd.com>
1675
1676 PR middle-end/40981
1677 * graphite-ppl.c (ppl_max_for_le): Correct the use of
1678 ppl_Pointset_Powerset_C_Polyhedron_maximize.
1679
16802009-08-13 Sebastian Pop <sebastian.pop@amd.com>
1681
1682 * graphite-poly.c (print_pbb): Print PBB index.
1683
16842009-08-13 Sebastian Pop <sebastian.pop@amd.com>
1685
1686 * Merge from mainline (r150672:150764).
1687
16882009-08-13 Sebastian Pop <sebastian.pop@amd.com>
1689
1690 * graphite-interchange.c (ppl_max_for_le): Moved...
1691 * graphite-poly.c (pbb_number_of_iterations): Call ppl_max_for_le.
1692 * graphite-ppl.c (ppl_max_for_le): ... here.
1693 * graphite-ppl.h (ppl_max_for_le): Declared.
1694
16952009-08-12 Sebastian Pop <sebastian.pop@amd.com>
1696
1697 * Merge from mainline (r150372:150672).
1698
30de1632
SP
16992009-08-11 Sebastian Pop <sebastian.pop@amd.com>
1700
1701 PR middle-end/40980
1702 * sese.c (convert_for_phi_arg): New.
1703 (add_guard_exit_phis): Use convert_for_phi_arg.
1704
45489e99 1705 * gfortran.dg/graphite/id-17.f: New.
30de1632 1706
8c31ebfa
SP
17072009-08-11 Sebastian Pop <sebastian.pop@amd.com>
1708
1709 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Dont add
1710 unknown subscript upper bounds.
1711
45489e99 1712 * gcc.dg/graphite/interchange-6.c: Un-XFAIL.
8c31ebfa 1713
fb9fb290
SP
17142009-08-11 Sebastian Pop <sebastian.pop@amd.com>
1715 Pranav Garg <pranav.garg2107@gmail.com>
1716
1717 * graphite-interchange.c (gather_access_strides): Removed.
1718 (ppl_max_for_le): New.
1719 (build_linearized_memory_access): New.
1720 (memory_stride_in_loop): New.
1721 (pbb_interchange_profitable_p): Reimplemented.
1722 * graphite-ppl.h (ppl_new_id_map): New.
1723 (ppl_interchange): New.
1724
45489e99 1725 * gcc.dg/graphite/interchange-6.c: XFAILed.
fb9fb290 1726
312aea7f
SP
17272009-08-11 Sebastian Pop <sebastian.pop@amd.com>
1728
1729 * graphite-interchange.c (compute_subscript): Removed.
1730 (compute_array_size_cstr): Removed.
1731 (compute_array_size_poly): Removed.
1732 (compute_array_size): Removed.
1733 (gather_access_strides_poly): Removed.
1734 (gather_access_strides): Empty.
1735
25d7cc15
SP
17362009-08-11 Sebastian Pop <sebastian.pop@amd.com>
1737
1738 * graphite-dependences.c (dependence_polyhedron_1): Replace
1739 pdr_nb_subscripts with PDR_NB_SUBSCRIPTS.
1740 (graphite_legal_transform_dr): Same.
1741 (graphite_carried_dependence_level_k): Same.
1742 * graphite-poly.c (new_poly_dr): Add a parameter nb_subscripts.
1743 Initialize PDR_NB_SUBSCRIPTS.
1744 (print_pdr_access_layout): Replace pdr_nb_subscripts with
1745 PDR_NB_SUBSCRIPTS.
1746 * graphite-poly.h (struct poly_dr): Add nb_subscripts field.
1747 (PDR_NB_SUBSCRIPTS): New.
1748 (pdr_nb_subscripts): Removed.
1749 (pdr_dim): Simplified.
1750 * graphite-sese-to-poly.c (build_poly_dr): Replace pdr_nb_subscripts
1751 with PDR_NB_SUBSCRIPTS.
1752
66096911
SP
17532009-08-11 Sebastian Pop <sebastian.pop@amd.com>
1754
1755 * graphite-interchange.c (compute_array_size): Remove use of
1756 PDR_DATA_CONTAINER.
1757 * graphite-poly.c (new_poly_dr): Remove argument data_container.
1758 Do not initialize PDR_DATA_CONTAINER.
1759 (print_pdr): Do not print PDR_DATA_CONTAINER.
1760 * graphite-poly.h (struct poly_dr): Remove data_container field.
1761 (PDR_DATA_CONTAINER): Removed.
1762 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Remove use of
1763 PDR_DATA_CONTAINER.
1764 (build_poly_dr): Same.
1765
273c5dd3
SP
17662009-08-11 Sebastian Pop <sebastian.pop@amd.com>
1767
45489e99 1768 * gcc.dg/graphite/interchange-9.c: New.
273c5dd3 1769
7491e5f0
KT
17702009-08-05 Konrad Trifunovic <konrad.trifunovic@gmail.com>
1771 Sebastian Pop <sebastian.pop@amd.com>
1772
1773 * graphite-dependences.c (graphite_legal_transform_dr): Work on a
1774 copy of the dependence polyhedron. Free the temporary objects.
1775 (graphite_carried_dependence_level_k): Free unused objects before
1776 returning.
1777
45489e99
SP
1778 * gcc.dg/graphite/interchange-1.c: XFAILed.
1779 * gcc.dg/graphite/interchange-2.c: XFAILed.
1780 * gcc.dg/graphite/interchange-3.c: XFAILed.
1781 * gcc.dg/graphite/interchange-4.c: XFAILed.
1782 * gcc.dg/graphite/interchange-7.c: XFAILed.
7491e5f0 1783
f4648ed1
SP
17842009-08-05 Sebastian Pop <sebastian.pop@amd.com>
1785
1786 * graphite-blocking.c (scop_do_strip_mine): Call store_scattering.
1787 Early return without analyzing the data dependences if no
1788 transform has been done. Call restore_scattering if the transform
1789 is not legal.
1790 (graphite-interchange.c): Same.
1791 * graphite-poly.c (print_scattering_function): Test for PBB_TRANSFORMED.
1792 (graphite_read_transforms): Initialize PBB_TRANSFORMED.
1793 (apply_poly_transforms): Do not gcc_assert that
1794 the transform is legal.
1795 (new_poly_bb): Initialize PBB_TRANSFORMED, PBB_SAVED, and PBB_ORIGINAL.
1796 Do not initialize PBB_NB_SCATTERING_TRANSFORM, PBB_NB_LOCAL_VARIABLES,
1797 PBB_TRANSFORMED_SCATTERING, and PBB_ORIGINAL_SCATTERING.
1798 (free_poly_dr): Free PBB_TRANSFORMED, PBB_SAVED, and PBB_ORIGINAL.
1799 * graphite-poly.h (struct poly_scattering): New.
1800 (struct poly_bb): Add original, transformed, and saved fields.
1801 Remove transformed_scattering, original_scattering, nb_local_variables,
1802 and nb_scattering_transform fields.
1803 (PBB_ORIGINAL, PBB_TRANSFORMED, PBB_SAVED): New.
1804 (poly_scattering_new): New.
1805 (poly_scattering_free): New.
1806 (poly_scattering_copy): New.
1807 (store_scattering_pbb): New.
1808 (store_scattering): New.
1809 (restore_scattering_pbb): New.
1810 (restore_scattering): New.
1811 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons):
1812 Initialize PBB_TRANSFORMED and PBB_ORIGINAL.
273c5dd3 1813
e31a5bd4
SP
18142009-08-05 Sebastian Pop <sebastian.pop@amd.com>
1815
1816 * graphite-poly.c (print_pbb): Add parentheses in the pretty print.
1817 (print_scop): Same.
1818
8e88f9fd
SP
18192009-08-05 Sebastian Pop <sebastian.pop@amd.com>
1820
1821 * Makefile.in (graphite.o): Depends on PREDICT_H.
1822 * graphite.c: Include predict.h.
1823 (graphite_finalize): Call tree_estimate_probability.
1824 * predict.c (predict_loops): Do not call scev_initialize and
1825 scev_finalize.
1826 (tree_estimate_probability_bb): New.
1827 (tree_estimate_probability): Do not initialize loops: move that
1828 code to the driver. Call tree_estimate_probability_bb.
1829 (tree_estimate_probability_driver): New.
1830 (pass_profile): Use tree_estimate_probability_driver.
1831 * predict.h (tree_estimate_probability): Declared.
1832
87d4d0ee
SP
18332009-08-05 Sebastian Pop <sebastian.pop@amd.com>
1834
1835 * graphite-clast-to-gimple.c (gloog): Add time to TV_GRAPHITE_CODE_GEN.
1836 * graphite-dependences.c (graphite_legal_transform): Add time to
1837 TV_GRAPHITE_DATA_DEPS.
1838 (dependency_between_pbbs_p): Same.
1839 * timevar.def (TV_GRAPHITE_DATA_DEPS, TV_GRAPHITE_CODE_GEN): New.
1840
18412009-08-03 Sebastian Pop <sebastian.pop@amd.com>
1842
1843 * Merge from mainline (r149952:150372).
1844
2abae5f1
SP
18452009-07-28 Sebastian Pop <sebastian.pop@amd.com>
1846
1847 * ChangeLog.graphite: Fix indenting, white spaces and 80 columns.
1848 * graphite-blocking.c: Same.
1849 * graphite-clast-to-gimple.c: Same.
1850 * graphite-dependences.c: Same.
1851 * graphite-poly.c: Same.
1852 * graphite-poly.h: Same.
1853 * graphite-ppl.c: Same.
1854 * graphite-scop-detection.c: Same.
1855 * graphite-sese-to-poly.c: Same.
1856 * graphite.c: Same.
1857
18582009-07-28 Sebastian Pop <sebastian.pop@amd.com>
1859
1860 * graphite-sese-to-poly.c (loop_entry_phi_arg): New.
1861 (remove_simple_copy_phi): New.
1862 (remove_invariant_phi): New.
1863 (simple_copy_phi_p): New.
1864 (reduction_phi_p): New.
1865 (gsi_for_ssa_name_def): New.
1866 (insert_out_of_ssa_copy): New.
1867 (insert_out_of_ssa_copy_on_edge): New.
1868 (create_zero_dim_array): New.
1869 (scalar_close_phi_node_p): New.
1870 (rewrite_close_phi_out_of_ssa): New.
1871 (rewrite_phi_out_of_ssa): New.
1872 (rewrite_reductions_out_of_ssa): New.
1873 (build_poly_scop): Call rewrite_reductions_out_of_ssa.
1874
45489e99
SP
1875 * gcc.dg/graphite/id-11.c: New.
1876 * gcc.dg/graphite/id-15.c: New.
1877 * gcc.dg/graphite/interchange-1.c: Un-XFAIL.
1878 * gcc.dg/graphite/interchange-2.c: Un-XFAIL.
1879 * gcc.dg/graphite/interchange-3.c: Un-XFAIL.
1880 * gcc.dg/graphite/interchange-4.c: Un-XFAIL.
1881 * gcc.dg/graphite/interchange-7.c: Un-XFAIL.
1882 * gcc.dg/graphite/scop-matmult.c: Un-XFAIL.
1883 * gfortran.dg/graphite/id-13.f: New.
1884 * gfortran.dg/graphite/id-5.f: New.
2abae5f1
SP
1885
18862009-07-28 Sebastian Pop <sebastian.pop@amd.com>
1887
1888 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not
1889 check that nb_reductions_in_loop is zero.
1890 * graphite-scop-detection.c (harmful_stmt_in_bb): Don't filter out
1891 reduction phi nodes.
1892 (nb_reductions_in_loop): Removed.
1893 (graphite_can_represent_loop): Do not call nb_reductions_in_loop.
1894 * graphite-sese-to-poly.c (phi_node_is_iv): Removed.
1895 (bb_contains_non_iv_scalar_phi_nodes): Removed.
1896 (scop_contains_non_iv_scalar_phi_nodes): Removed.
1897 (build_poly_scop): Do not call scop_contains_non_iv_scalar_phi_nodes.
1898
18992009-07-28 Sebastian Pop <sebastian.pop@amd.com>
1900
1901 * graphite-clast-to-gimple.c (build_cloog_prog): Do not code generate
1902 statements that have an empty iteration domain.
45489e99 1903 * gfortran.dg/graphite/id-16.f: New.
2abae5f1
SP
1904
19052009-07-28 Sebastian Pop <sebastian.pop@amd.com>
1906
1907 * tree-scalar-evolution.c (instantiate_scev_1): Return
1908 chrec_dont_know when the result is not above instantiate_below.
1909 * graphite-scop-detection.c (scopdet_basic_block_info): Fix formatting.
1910 * graphite-sese-to-poly.c (create_linear_expr_from_tree): Assert that
1911 the tree has a known scalar evolution.
45489e99
SP
1912 * gfortran.dg/graphite/id-14.f: New.
1913 * gfortran.dg/graphite/id-15.f: New.
2abae5f1
SP
1914
19152009-07-28 Sebastian Pop <sebastian.pop@amd.com>
1916
1917 * sese.c (rename_variables_in_stmt): Pass in an extra parameter
1918 insert_gsi.
1919 (rename_variables): Keep inserting renames after the ones already
1920 inserted.
1921
19222009-07-28 Sebastian Pop <sebastian.pop@amd.com>
1923
1924 * graphite-sese-to-poly.c (compare_bb_depths): New.
1925 (graphite_sort_dominated_info): New.
1926 (build_scop_bbs_1): Call graphite_sort_dominated_info.
1927 (build_scop_scattering): Fix comment.
1928
19292009-07-28 Sebastian Pop <sebastian.pop@amd.com>
1930
1931 * graphite.c (graphite_finalize): Call print_loops instead of
1932 dump_function_to_file.
45489e99
SP
1933 * gcc.dg/graphite/graphite.exp: Fix formatting.
1934 * gcc.dg/graphite/pr35356-1.c: New. Look for the number of
2abae5f1 1935 loops generated in the graphite output file.
45489e99
SP
1936 * gcc.dg/graphite/pr35356-2.c: New.
1937 * gcc.dg/graphite/pr35356-3.c: New. XFAILed for now.
1938 * gfortran.dg/graphite/id-12.f: New.
2abae5f1
SP
1939
19402009-07-24 Li Feng <nemokingdom@gmail.com>
1941
45489e99 1942 * gcc.dg/graphite/graphite_autopar/force-parallel-8.c:
2abae5f1
SP
1943 Remove 2 XFAIL.
1944
19452009-07-24 Li Feng <nemokingdom@gmail.com>
1946 Tobias Grosser <grosser@fim.uni-passau.de>
1947
1948 * graphite-sese-to-poly.c (pdr_add_alias_set): Use data reference's
1949 alias set number build alias in ACCESSES polyhedron.
1950 (build_alias_set_for_drs): New.
1951 (build_pbb_drs): Added build_alias_set_for_drs.
1952 * graphite-dependences.c (poly_drs_may_alias_p): New.
1953 (graphite_carried_dependence_level_k): Check alias information
1954 before building polyhedron.
1955
19562009-07-24 Tobias Grosser <grosser@fim.uni-passau.de>
1957
1958 * Makefile.in (lambda-code.o): Fix formatting.
1959
19602009-07-24 Tobias Grosser <grosser@fim.uni-passau.de>
1961
1962 * Merge from mainline (r149350-149952)
1963
19642009-07-18 Tobias Grosser <grosser@fim.uni-passau.de>
1965
1966 * graphite-poly.c (apply_poly_transforms): Move strip_mine
1967 before interchange to prepare for loop blocking.
1968
19692009-07-18 Tobias Grosser <grosser@fim.uni-passau.de>
1970
1971 * graphite-poly.c (apply_poly_transforms): Add checks after every
1972 transformation.
1973 * graphite-sese-to-poly.c (build_poly_scop): Remove check, as already
1974 done in apply_poly_transforms.
1975
19762009-07-17 Konrad Trifunovic <konrad.trifunovic@gmail.com>
1977
1978 * graphite-dependences.c (build_lexicographically_gt_constraint):
1979 Replace RES parameter with *RES.
1980 (dependence_polyhedron_1): Pass an address of the parameter RES
1981 instead of value of RES.
1982
19832009-07-16 Sebastian Pop <sebastian.pop@amd.com>
1984
1985 * graphite.c (graphite_finalize): Fix comment.
1986 (graphite_transform_loops): Reset scev info after code generation
1987 of each scop.
1988
19892009-07-16 Sebastian Pop <sebastian.pop@amd.com>
1990
1991 * graphite.c (graphite_finalize): Call scev_reset.
1992
19932009-07-16 Sebastian Pop <sebastian.pop@amd.com>
1994
1995 * graphite-clast-to-gimple.c (compute_cloog_iv_types): Do not create
1996 GBB_CLOOG_IV_TYPES hash table twice.
1997 * graphite-sese-to-poly.c (free_gimple_bb): Call free_data_refs.
1998 (add_condition_to_domain): Clear GMP values.
1999
20002009-07-16 Sebastian Pop <sebastian.pop@amd.com>
2001
2002 * graphite-dependences.c: Fix formatting.
2003 * graphite-poly.c (free_poly_dr): Also free PDR_DATA_CONTAINER.
2004 (pbb_number_of_iterations): Free ppl_Linear_Expression.
2005 * graphite-sese-to-poly.c: Fix formatting.
2006 * graphite.c (graphite_transform_loops): Create the hash table
2007 after the early return.
2008
20092009-07-16 Sebastian Pop <sebastian.pop@amd.com>
2010
45489e99
SP
2011 * gcc.dg/graphite/id-14.c: New.
2012 * gcc.dg/graphite/pr40157.c: New.
2013 * gfortran.dg/graphite/id-11.f: New.
2abae5f1
SP
2014
20152009-07-16 Sebastian Pop <sebastian.pop@amd.com>
2016
2017 * graphite-sese-to-poly.c (nb_pbbs_in_loops): New.
2018 (build_poly_scop): Return false when there are no pbbs within
2019 loops to avoid to pass to cloog scops with no loops.
2020
20212009-07-16 Sebastian Pop <sebastian.pop@amd.com>
2022
2023 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons): Avoid
2024 useless test "i % 2".
2025 (build_pbb_scattering_polyhedrons): Fix formatting.
2026 (build_poly_dr): Same.
2027 * graphite.c (graphite_transform_loops): Restructure.
2028
20292009-07-14 Razya Ladelsky <razya@il.ibm.com>
2030
2031 * tree-ssa-loop-manip.c (rewrite_phi_with_iv): Remove
2032 reduction_list parameter.
2033 (rewrite_all_phi_nodes_with_iv): Same.
2034 (canonicalize_loop_ivs): Same.
2035 * tree-parloops.c (struct brli): Removed.
2036 (build_reduction_list_info): Removed.
2037 (build_new_reduction): New.
2038 (analyze_reduction_list): Removed.
2039 (gather_scalar_reductions): Find reductions instead of phi
2040 nodes that can't be canonicalized.
2041 (try_create_reduction_list): Remove reduction_list parameter.
2042 (gen_parallel_loop): Same.
2043 (parallelize_loops): Remove analyze_reductions variable,
2044 initialization and free.
2045 Change reduction_list htab initialization to reduction_info
2046 elements instead of ssa names.
2047 Call try_create_reduction_list and gen_parallel_loop without
2048 analyzed_reduction argument.
2049 * graphite-clast-to-gimple (graphite_loop_normal_form): Call
2050 canonicalize_loop_ivs with one less argument.
2051 * tree-flow.h (canonicalize_loop_ivs): Remove one argument.
2052
20532009-07-14 Konrad Trifunovic <konrad.trifunovic@gmail.com>
2054
2055 * graphite-dependences.c (new_poly_dr_pair): New.
2056 (dependence_polyhedron): Renamed into dependence_polyhedron_1.
2057 (new_poly_dr_pair): New.
2058 (eq_poly_dr_pair_p): New.
2059 (hash_poly_dr_pair_p): New.
2060 * graphite-dependences.h (struct poly_dr_pair): New.
2061 (eq_poly_dr_pair_p): Declared.
2062 (hash_poly_dr_pair_p): Declared.
2063 * graphite-poly.c (new_scop): Initialize SCOP_ORIGINAL_PDR_PAIRS.
2064 (free_scop): Free SCOP_ORIGINAL_PDR_PAIRS.
2065 * graphite-poly.h (struct scop): Add original_pdr_pairs field.
2066 * Makefile.in (graphite-poly.o): Add dependence on
2067 graphite-dependences.h.
2068
20692009-07-14 Sebastian Pop <sebastian.pop@amd.com>
2070
2071 * graphite-scop-detection.c (graphite_can_represent_scev): Do not let
2072 polynomials of degree > 1 pass to Graphite.
2073 * tree-chrec.c (scev_is_linear_expression): Call
2074 evolution_function_is_affine_multivariate_p.
45489e99 2075 * gfortran.dg/graphite/id-10.f90: New.
2abae5f1
SP
2076
20772009-07-14 Sebastian Pop <sebastian.pop@amd.com>
2078
2079 * tree-scalar-evolution.c (compute_overall_effect_of_inner_loop):
2080 Instantiate scevs varying in outer loops.
45489e99 2081 * gfortran.dg/graphite/id-9.f: Correct testcase.
2abae5f1
SP
2082
20832009-07-14 Sebastian Pop <sebastian.pop@amd.com>
2084
2085 * graphite-sese-to-poly.c (build_loop_iteration_domains): Do not insert
2086 redundant constraint.
2087
20882009-07-14 Sebastian Pop <sebastian.pop@amd.com>
2089
45489e99
SP
2090 * gcc.dg/graphite/graphite.exp: Fix comments.
2091 * gfortran.dg/graphite/graphite.exp: Trigger actions
2abae5f1 2092 based on the file names as in the C testsuite.
45489e99
SP
2093 * gfortran.dg/graphite/block-1.f90: Fix patterns.
2094 * gfortran.dg/graphite/block-2.f: Same.
2095 * gfortran.dg/graphite/block-3.f90: Same.
2096 * gfortran.dg/graphite/block-4.f90: Same.
2097 * gfortran.dg/graphite/id-1.f90: Same.
2098 * gfortran.dg/graphite/id-2.f90: Same.
2099 * gfortran.dg/graphite/id-3.f90: Same.
2100 * gfortran.dg/graphite/id-4.f90: Same.
2101 * gfortran.dg/graphite/id-6.f: Same.
2102 * gfortran.dg/graphite/id-9.f: Same.
2103 * gfortran.dg/graphite/interchange-1.f: Same.
2104 * gfortran.dg/graphite/interchange-2.f: Same.
2105 * gfortran.dg/graphite/scop-1.f: Same.
2abae5f1
SP
2106
21072009-07-14 Sebastian Pop <sebastian.pop@amd.com>
2108
2109 * sese.c (expand_scalar_variables_call): New.
2110 (expand_scalar_variables_ssa_name): Handle calls in expander.
2111
21122009-07-13 Sebastian Pop <sebastian.pop@amd.com>
2113
45489e99 2114 * gcc.dg/graphite/graphite_autopar/force-parallel-6.c:
2abae5f1 2115 Expect to see the pattern twice.
45489e99
SP
2116 * gcc.dg/graphite/interchange-0.c: Un-XFAIL.
2117 * gcc.dg/graphite/interchange-5.c: Same.
2118 * gcc.dg/graphite/interchange-6.c: Same.
2abae5f1
SP
2119
21202009-07-13 Sebastian Pop <sebastian.pop@amd.com>
2121
45489e99
SP
2122 * gcc.dg/graphite/id-10.c: New.
2123 * gcc.dg/graphite/id-12.c: New.
2124 * gfortran.dg/graphite/id-7.f: New.
2125 * gfortran.dg/graphite/id-8.f: New.
2abae5f1
SP
2126
21272009-07-13 Sebastian Pop <sebastian.pop@amd.com>
2128
2129 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Fix division by
2130 zero.
2131
21322009-07-13 Sebastian Pop <sebastian.pop@amd.com>
2133
2134 * sese.c (rename_variables_in_stmt): Call fold_convert during renaming.
2135
21362009-07-13 Sebastian Pop <sebastian.pop@amd.com>
2137
2138 * sese.c (expand_scalar_variables_stmt): Avoid unnecessary expansion.
2139
21402009-07-10 Sebastian Pop <sebastian.pop@amd.com>
2141
2142 * graphite-sese-to-poly.c (pdr_add_memory_accesses): Fix order of
2143 building PDR subscripts.
2144
21452009-07-10 Sebastian Pop <sebastian.pop@amd.com>
2146
2147 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Fix the
2148 computation of array sizes.
2149
21502009-07-10 Sebastian Pop <sebastian.pop@amd.com>
2151
2152 * graphite-sese-to-poly.c (add_param_constraints): Disabled.
2153
21542009-07-10 Tobias Grosser <grosser@fim.uni-passau.de>
2155
2156 * graphite-dependences.c (map_into_dep_poly, map_dr_into_dep_poly,
2157 build_pairwise_constraint, dr_equality_constraints,
2158 build_pairwise_scheduling_equality,
2159 build_pairwise_scheduling_inequality, lexicographically_gt_p,
2160 build_lexicographically_gt_constraint, dependence_polyhedron,
2161 graphite_legal_transform_dr, graphite_carried_dependence_level_k):
2162 Move from NNC_Polyhedron to C_Polyhedron.
2163 * graphite-interchange.c (compute_array_size_poly,
2164 gather_access_strides): Dito.
2165 * graphite-poly.c (apply_poly_transforms, new_poly_dr, free_poly_bb,
2166 free_scop, pbb_number_of_iterations): Dito.
2167 * graphite-poly.h (struct poly_dr, pdr_nb_subscripts, struct poly_bb,
2168 pbb_dim_iter_domain, struct scop): Dito.
2169 * graphite-ppl.c (new_Constraint_System_from_Cloog_Matrix,
2170 new_Cloog_Domain_from_ppl_Polyhedron,
2171 new_Cloog_Domain_from_ppl_Pointset_Powerset, ppl_set_coef_gmp,
2172 ppl_insert_dimensions_pointset, ppl_insert_dimensions_pointset,
2173 ppl_strip_loop, ppl_strip_loop, ppl_print_polyhedron_matrix,
2174 ppl_print_powerset_matrix, debug_ppl_polyhedron_matrix,
2175 debug_ppl_powerset_matrix, ppl_read_polyhedron_matrix): Dito.
2176 * graphite-ppl.h (ppl_Pointset_Powerset_C_Polyhedron_t,
2177 new_C_Polyhedron_from_Cloog_Matrix, ppl_print_powerset_matrix,
2178 debug_ppl_powerset_matrix, ppl_insert_dimensions_pointset): Dito.
2179 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons,
2180 build_loop_iteration_domains, ppl_constraint_type_from_tree_code,
2181 add_condition_to_domain, add_condition_to_pbb, build_scop_context,
2182 build_scop_iteration_domain, build_poly_dr): Dito
2183
21842009-07-09 Sebastian Pop <sebastian.pop@amd.com>
2185
45489e99 2186 * gcc.dg/graphite/graphite.exp: Added a rule to execute
2abae5f1 2187 run-id-*.c files.
45489e99 2188 * gcc.dg/graphite/run-id-1.c: New.
2abae5f1
SP
2189
21902009-07-09 Sebastian Pop <sebastian.pop@amd.com>
2191
2192 * graphite-sese-to-poly.c (build_loop_iteration_domains): Add the
2193 positivity constraint on the symbolic number of iterations.
2194
21952009-07-09 Sebastian Pop <sebastian.pop@amd.com>
2196
2197 * graphite-sese-to-poly.c (build_loop_iteration_domains): Rewrite.
2198
21992009-07-09 Sebastian Pop <sebastian.pop@amd.com>
2200 Tobias Grosser <grosser@fim.uni-passau.de>
2201
2202 * graphite-clast-to-gimple.c (build_scop_context): Removed.
2203 (build_cloog_prog): Directly use SCOP_CONTEXT.
2204 * graphite-poly.c (new_scop): Initialize SCOP_CONTEXT.
2205 (free_scop): Free SCOP_CONTEXT.
2206 (print_scop_context): New.
2207 (print_scop): Call print_scop_context.
2208 (debug_scop_context): New.
2209 * graphite-poly.h (print_scop_context, debug_scop_context): Declared.
2210 (struct scop): Added field context.
2211 (SCOP_CONTEXT): New.
2212 * graphite-sese-to-poly.c (add_param_constraints): New.
2213 (build_scop_context): New.
2214 (build_poly_scop): Call build_scop_context.
2215
22162009-07-09 Sebastian Pop <sebastian.pop@amd.com>
2217
2218 * graphite-clast-to-gimple.c (gmp_cst_to_tree): Moved...
2219 * graphite-ppl.c (ppl_set_inhomogeneous_gmp, ppl_set_coef_gmp): New.
2220 (ppl_set_inhomogeneous, ppl_set_coef): Moved...
2221 * graphite-ppl.h: Include double-int.h and tree.h.
2222 (ppl_set_inhomogeneous_gmp, ppl_set_coef_gmp): Declared.
2223 (ppl_set_inhomogeneous, ppl_set_coef): ...here.
2224 (gmp_cst_to_tree): ...here. Reimplemented using mpz_get_double_int.
2225 (tree_int_to_gmp, ppl_set_inhomogeneous_tree, ppl_set_coef_tree): New.
2226
22272009-07-09 Sebastian Pop <sebastian.pop@amd.com>
2228
2229 * graphite-clast-to-gimple.c (clast_to_gcc_expression_red): Generate
2230 POINTER_PLUS_EXPR for pointer types.
2231 (clast_to_gcc_expression): Same.
2232
22332009-07-09 Sebastian Pop <sebastian.pop@amd.com>
2234
2235 * graphite-poly.c (print_scattering_function): Early return when
2236 PBB_TRANSFORMED_SCATTERING is not initialized.
2237 (print_pbb_domain): Early return when PBB_DOMAIN is not initialized.
2238
22392009-07-08 Sebastian Pop <sebastian.pop@amd.com>
2240
2241 * tree-parloops.c (analyze_reduction_list): Remove unused variable
2242 to fix bootstrap.
2243
22442009-07-08 Razya Ladelsky <razya@il.ibm.com>
2245
2246 * tree-parloops.c (analyze_reduction_list): Change return
2247 value to void.
2248 (try_create_reduction_list): Move the call to
2249 analyze_reduction_list to the beginining.
2250 Call reduction_phi with analyzed_reductions as argument
2251 instead of reduction_list.
2252
22532009-07-08 Tobias Grosser <grosser@fim.uni-passau.de>
2254
2255 * Merge from mainline (r148296:149346)
2256
22572009-07-07 Sebastian Pop <sebastian.pop@amd.com>
2258
2259 * graphite-scop-detection.c (graphite_can_represent_init): New.
2260 (graphite_can_represent_scev): Call graphite_can_represent_init:
2261 check that the initial value does not contain multiplications of
2262 parameters.
2263 (stmt_has_simple_data_refs_p): New.
2264 (stmt_simple_for_scop_p): Call stmt_simple_for_scop_p.
2265 (is_simple_operand): Fix formatting.
2266 * graphite-sese-to-poly.c (try_generate_gimple_bb): Fix formatting.
2267
22682009-07-07 Sebastian Pop <sebastian.pop@amd.com>
2269
45489e99 2270 * gcc.dg/graphite/id-13.c: New.
2abae5f1
SP
2271 * graphite-sese-to-poly.c (graphite_stmt_p): Do not call
2272 analyze_scalar_evolution, use scalar_evolution_in_region.
2273 (scan_tree_for_params_right_scev): Add extra assert.
2274 (parameter_index_in_region_1): Split from parameter_index_in_region.
2275 (idx_record_params): Use scalar_evolution_in_region.
2276 (find_params_in_bb): Same.
2277 (find_scop_parameters): Same.
2278 (build_loop_iteration_domains): Same.
2279 (create_linear_expr_from_tree): Same.
2280 * sese.c (scalar_evolution_in_region): New.
2281 * sese.h (scalar_evolution_in_region): Declared.
2282 (defined_in_sese_p): New.
2283 * tree-scalar-evolution.c (compute_overall_effect_of_inner_loop): Not
2284 static anymore.
2285 * tree-scalar-evolution.h (compute_overall_effect_of_inner_loop):
2286 Declared.
2287
22882009-07-07 Sebastian Pop <sebastian.pop@amd.com>
2289
2290 * Makefile.in: Replace dependences on tree-chrec.h with SCEV_H.
2291 TREE_DATA_REF_H also implies SCEV_H.
2292
22932009-07-07 Sebastian Pop <sebastian.pop@amd.com>
2294
2295 * graphite-poly.c (print_scop_params): New.
2296 (print_scop): Call print_scop_params.
2297 (debug_scop_params): New.
2298 * graphite-poly.h (print_scop_params, debug_scop_params): Declared.
2299
23002009-07-07 Li Feng <nemokingdom@gmail.com>
2301
45489e99
SP
2302 * gcc.dg/graphite/graphite_autopar/force-parallel-4.c: New.
2303 * gcc.dg/graphite/graphite_autopar/force-parallel-5.c: New.
2304 * gcc.dg/graphite/graphite_autopar/force-parallel-6.c: New.
2305 * gcc.dg/graphite/graphite_autopar/force-parallel-7.c: New.
2306 * gcc.dg/graphite/graphite_autopar/force-parallel-8.c: New.
2307 * gcc.dg/graphite/graphite_autopar/force-parallel-9.c: New.
2abae5f1
SP
2308
23092009-07-07 Li Feng <nemokingdom@gmail.com>
2310
2311 * graphite-clast-to-gimple.c (mark_loops_parallel): Dump information
2312 for dependency checking part.
45489e99 2313 * gcc.dg/graphite/graphite_autopar/force-parallel-1.c: Add
2abae5f1 2314 tests for dependency checking.
45489e99
SP
2315 * gcc.dg/graphite/graphite_autopar/force-parallel-2.c: Ditto.
2316 * gcc.dg/graphite/graphite_autopar/force-parallel-3.c: Ditto.
2317 * gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: Add
2abae5f1
SP
2318 flag -fdump-tree-graphite-all for autopar testsuites.
2319
23202009-07-06 Sebastian Pop <sebastian.pop@amd.com>
2321
2322 * Makefile.in (tree-ssa-loop-manip.o): Depends on langhooks.h.
2323 * tree-parloops.c (rewrite_phi_with_iv, rewrite_all_phi_nodes_with_iv,
2324 canonicalize_loop_ivs): Moved...
2325 * tree-ssa-loop-manip.c: ... here. Include langhooks.h.
2326
23272009-07-06 Sebastian Pop <sebastian.pop@amd.com>
2328
2329 * tree-parloops.c (try_create_reduction_list): Pass an extra
2330 argument analyzed_reductions. Call analyze_reduction_list.
2331 (gen_parallel_loop): Do not call analyze_reduction_list.
2332 (parallelize_loops): Init and finalize analyzed_reductions.
2333
23342009-07-06 Li Feng <nemokingdom@gmail.com>
2335
45489e99 2336 * gcc.dg/graphite/graphite_autopar/graphite_autopar.exp:
2abae5f1
SP
2337 Added flag -fno-loop-strip-mine for autopar testcase.
2338
23392009-07-04 Li Feng <nemokingdom@gmail.com>
2340
2341 * graphite-dependences.c (graphite_carried_dependence_level_k): Use
2342 transformed scattering dimension instead of unmatch orignal when
2343 calling dependence_polyhedron.
2344
23452009-06-30 Sebastian Pop <sebastian.pop@amd.com>
2346
2347 * opts.c (decode_options): Enable flag_loop_strip_mine at -O2.
2348
23492009-06-30 Sebastian Pop <sebastian.pop@amd.com>
2350
2351 * graphite-poly.c (pbb_number_of_iterations): Check for returned
2352 value 1 from ppl_Pointset_Powerset_NNC_Polyhedron_maximize.
2353
23542009-06-30 Sebastian Pop <sebastian.pop@amd.com>
2355
2356 * graphite-blocking.c (pbb_strip_mine_profitable_p): New.
2357 (pbb_do_strip_mine): Call pbb_strip_mine_profitable_p.
2358 * graphite-poly.c (pbb_number_of_iterations): New.
2359 * graphite-poly.h (pbb_number_of_iterations): Declared.
2360 (pbb_iterator_dim, pbb_parameter_dim): New.
2361
23622009-06-29 Sebastian Pop <sebastian.pop@amd.com>
2363
2364 * graphite-clast-to-gimple.c (graphite_create_new_loop): Revert the
2365 last commit on type of lower and upper bound of loops.
2366
23672009-06-29 Li Feng <nemokingdom@gmail.com>
2368
2369 * Makefile.in (graphite-clast-to-gimple.o): Added dependence on
2370 graphite-dependences.h.
2371 * graphite-clast-to-gimple.c (new_bb_pbb_def): New.
2372 (mark_bb_with_pbb): New.
2373 (get_stmtfor_depth): New.
2374 (find_pbb_via_hash): New.
2375 (dependency_in_loop_p): New.
2376 (mark_loops_parallel): New.
2377 (free_aux_in_new_loops): New.
2378 (translate_clast): Add parameter BB_PBB_MAPPING. Mark newly created
2379 bb with it's relevant pbb. Mark newly created loops. Remove mark
2380 innermost loop parallel without checking.
2381 (gloog): Add parameter BB_PBB_MAPPING.
2382 * graphite-clast-to-gimple.h (struct bb_pbb_def): New.
2383 (gloog): Change declaration.
2384 (mark_loop_parallel): Make extern.
2385 (free_aux_in_new_loops): Declare.
2386 (bb_pbb_map_hash): New.
2387 (eq_bb_pbb_map): New.
2388 * graphite.c (graphite_transform_loops): Added BB_PBB_MAPPING. Trigger
2389 auto parallelization when flag_graphite_force_parallel is set.
2390 (graphite_finalize): Added free_aux_in_new_loops.
2391 * tree-parloops.c (parallelize_loops): Only generate parallel code for
2392 the innermost loop that marked parallel. Use
2393 flag_graphite_force_parallel instead of loop->can_be_parallel.
2394 (loop_parallel_p): Move inner most checking out of function.
2395
23962009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2397
2398 * graphite-clast-to-gimple.c (graphite_create_new_loop): Make the
2399 type of lower and upper bound of loops signed long int.
2400
24012009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2402
2403 * cfgloopmanip.c (create_empty_loop_on_edge): Gimplify the loop exit
2404 expression outside the loop.
2405
24062009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2407
2408 * gcc.dg/graphite/interchange-8.c: New.
2409
24102009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2411
2412 * gcc.dg/graphite/interchange-0.c: XFailed.
2413 * gcc.dg/graphite/interchange-5.c: XFailed.
2414 * gcc.dg/graphite/interchange-6.c: XFailed.
2415
24162009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2417
2418 * graphite-interchange.c (compute_array_size_poly): The end of the
2419 recursion should return 1.
2420
24212009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2422
2423 * graphite-interchange.c (compute_array_size_cstr): Allow the
2424 subscript multiplier to be -1.
2425 (compute_array_size): Use PDR_DATA_CONTAINER and not PDR_ACCESSES.
2426 * graphite-poly.c (new_poly_dr): Takes an extra argument for the
2427 data_container. Initializes PDR_DATA_CONTAINER.
2428 (print_pdr_access_layout): New.
2429 (print_pdr): Call print_pdr_access_layout. Print PDR_DATA_CONTAINER.
2430 * graphite-poly.h (struct poly_dr): Adjust comment. Add a new field
2431 data_container.
2432 (PDR_DATA_CONTAINER): New.
2433 (new_poly_dr): Update declaration.
2434 * graphite-sese-to-poly.c (pdr_add_data_dimensions): New.
2435 (build_poly_dr): Call pdr_add_data_dimensions.
2436
24372009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2438
2439 * graphite-poly.h (struct poly_dr): Fix comment.
2440 * graphite-sese-to-poly.c (pdr_add_alias_set): New.
2441 (pdr_add_memory_accesses): New.
2442 (build_poly_dr): Call pdr_add_memory_accesses and pdr_add_alias_set.
2443
24442009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2445
2446 * graphite-poly.c (print_pdrs, debug_pdrs): New.
2447 (print_pbb): Add call to print_pdrs.
2448 * graphite-poly.h (print_pdrs, debug_pdrs): Declared.
2449
24502009-06-24 Konrad Trifunovic <konrad.trifunovic@gmail.com>
2451 Li Feng <nemokingdom@gmail.com>
2452
2453 * graphite-dependences.c (graphite_carried_dependence_level_k): New.
2454 (dependency_between_pbbs_p): New.
2455 (lexicographically_gt_p): Assure !empty_p before polyhedron
2456 intersection assign.
2457 (build_lexicographically_gt_constraint): Correct lexicographically
2458 judging.
2459 * graphite-dependences.h: New.
2460 * Makefile.in (graphite-dependences.o): Add graphite-dependences.h.
2461
24622009-06-24 Sebastian Pop <sebastian.pop@amd.com>
2463
2464 * graphite-clast-to-gimple.c (print_clast_stmt): New.
2465 (gloog): Print to dump_file the generated clast.
2466 * graphite-clast-to-gimple.h (print_clast_stmt): Declared.
2467 * graphite-interchange.c (pbb_do_interchange): Fix dump formatting.
2468
24692009-06-24 Sebastian Pop <sebastian.pop@amd.com>
2470
2471 * graphite-poly.c (extend_scattering): Increment
2472 PBB_NB_LOCAL_VARIABLES by the number of added dimensions.
2473
24742009-06-24 Sebastian Pop <sebastian.pop@amd.com>
2475
2476 * graphite-interchange.c (compute_array_size_poly): Added exit of
2477 recursion condition. Continue iterating even after the first equality.
2478 (compute_array_size): Same.
2479
24802009-06-24 Li Feng <nemokingdom@gmail.com>
2481
45489e99 2482 * gcc.dg/graphite/graphite_autopar/force-parallel-1.c: Update
2abae5f1 2483 -fdump-tree-final_cleanup to -fdump-tree-optimized.
45489e99
SP
2484 * gcc.dg/graphite/graphite_autopar/force-parallel-2.c: Ditto.
2485 * gcc.dg/graphite/graphite_autopar/force-parallel-3.c: Ditto.
2486 * gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: Ditto.
2abae5f1
SP
2487
24882009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2489
2490 * sese.c (expand_scalar_variables_stmt): Expand scalar variables
2491 only when the use verifies is_gimple_reg.
2492
24932009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2494
2495 * graphite-clast-to-gimple.c (build_cloog_prog): Fix memory corruption.
2496 Allocate scaldims after call to unify_scattering_dimensions.
2497
24982009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2499
2500 * graphite-clast-to-gimple.c (translate_clast): Fix memory leak.
2501
25022009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2503 Albert Cohen <albert.cohen@inria.fr>
2504
2505 * graphite-blocking.c (pbb_strip_mine_loop_depth): Do not use local
2506 variables for the strip mining.
2507
25082009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2509 Pranav Garg <pranav.garg2107@gmail.com>
2510
2511 * Makefile.in (OBJS-common): Added graphite-blocking.o.
2512 (graphite-sese-to-poly.o): Moved down to be in lexicographical order.
2513 (graphite-blocking.o): New rule.
2514 (graphite-poly.o, graphite-ppl.o): Moved to be in lexicographical order.
2515 * graphite-blocking.c: New.
2516 * graphite-poly.c (apply_poly_transforms): Call scop_do_strip_mine for
2517 flag_loop_strip_mine.
2518 (psct_scattering_dim_for_loop_depth): New.
2519 * graphite-poly.h (scop_do_strip_mine): Declared.
2520 (psct_add_local_variable): Increment PBB_NB_LOCAL_VARIABLES.
2521 * tree-ssa-loop.c (gate_graphite_transforms): Do not fail when using
2522 flag_loop_strip_mine.
2523
25242009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2525
2526 * graphite-poly.c (extend_scattering): Avoid initializing and freeing
2527 a GMP value and a PPL coefficient at each iteration of a loop.
2528
25292009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2530
2531 * graphite-dependences.c (dependence_polyhedron): Do not use
2532 pbb_nb_scattering_dims anymore. Use pbb_nb_scattering_orig and
2533 pbb_nb_scattering_transform.
2534 (graphite_legal_transform_dr): Same.
2535 * graphite-poly.c (extend_scattering): Same.
2536 (unify_scattering_dimensions): Same.
2537 (print_scattering_function): Same.
2538 (new_poly_bb): Initialize PBB_NB_SCATTERING_TRANSFORM and
2539 PBB_NB_LOCAL_VARIABLES.
2540 * graphite-poly.h (pbb_nb_scattering): Removed declaration.
2541 (struct poly_bb): Added nb_local_variables and nb_scattering_transform.
2542 (PBB_NB_LOCAL_VARIABLES, PBB_NB_SCATTERING_TRANSFORM): New.
2543 (pbb_nb_scattering_orig, pbb_nb_scattering_transform): New.
2544 (pbb_nb_scattering_dims, pbb_nb_scattering): Removed.
2545 (pbb_nb_scattering_transform): New.
2546 (pbb_nb_local_vars): Return PBB_NB_LOCAL_VARIABLES.
2547 (psco_scattering_dim): Add assert on parameters.
2548 (psct_scattering_dim): Same.
2549 (psct_scattering_dim_for_loop_depth): Declared.
2550 (psct_local_var_dim): New.
2551 (psco_iterator_dim, psco_parameter_dim): Add assert on parameters.
2552 (psct_iterator_dim, psct_parameter_dim): Same. To maintain the
2553 correct layout, call pbb_nb_local_vars.
2554 (psct_add_local_variable, psct_add_scattering_dimension): New.
2555 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons):
2556 Initialize PBB_NB_SCATTERING_TRANSFORM.
2557
25582009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2559
2560 * graphite-ppl.c (set_inhomogeneous): Renamed ppl_set_inhomogeneous.
2561 (set_coef): Renamed ppl_set_coef.
2562 * graphite-ppl.h (ppl_set_inhomogeneous, ppl_set_coef): Declared.
2563
25642009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2565
2566 * graphite-dependences.c (build_pairwise_scheduling_inequality): Don't
2567 test a boolean against 1.
2568 * graphite-interchange.c (pbb_interchange_loop_depths): Do not build
2569 a new polyhedron for the PBB_TRANSFORMED_SCATTERING.
2570 (pbb_do_interchange): Returns true when a transform has been performed.
2571 (scop_do_interchange): Same.
2572 * graphite-poly.c (apply_poly_transforms): Use the return value of
2573 scop_do_interchange.
2574 * graphite-poly.h (scop_do_interchange): Update declaration.
2575
25762009-06-23 Tobias Grosser <grosser@fim.uni-passau.de>
2577
2578 * graphite-clast-to-gimple.c (gloog): Reset loop->aux right
2579 after last use.
2580 * sese.c (sese_reset_aux_in_loops): New.
2581 * sese.h (sese_reset_aux_in_loops): New.
2582
25832009-06-19 Sebastian Pop <sebastian.pop@amd.com>
2584
2585 * graphite-sese-to-poly.c (scan_tree_for_params_int): Pass in the
2586 multiplier and multiply the constant by the multiplier.
2587 (scan_tree_for_params): Bound the multiplier to its MULT_EXPR.
2588 (build_poly_dr): Do not use the multiplier to define the subscript.
2589
25902009-06-19 Sebastian Pop <sebastian.pop@amd.com>
2591
2592 * graphite-poly.c (new_poly_dr): Pass an extra argument for the
2593 compiler's data reference. Initialize PDR_CDR.
2594 (print_pdr): Call dump_data_reference.
2595 * graphite-poly.h (struct poly_dr): Rename black_box into pbb.
2596 Add compiler_dr field.
2597 (PDR_BB): Renamed PDR_PBB.
2598 (PDR_CDR): New.
2599 * graphite-sese-to-poly.c (build_poly_dr): Pass to new_poly_dr
2600 GCC's data reference representation.
2601 * tree-data-ref.c (debug_data_references, debug_data_reference): New.
2602 * tree-data-ref.h (debug_data_references, debug_data_reference): Decl.
2603
26042009-06-19 Sebastian Pop <sebastian.pop@amd.com>
2605
2606 * graphite-poly.c (print_scattering_function): Also print the layout.
2607 * graphite-poly.h (pbb_nb_local_vars): New.
2608
26092009-06-19 Sebastian Pop <sebastian.pop@amd.com>
2610
2611 * graphite-poly.c (print_pbb_domain): Also print the layout names.
2612
26132009-06-19 Sebastian Pop <sebastian.pop@amd.com>
2614
2615 * graphite-poly.c (print_pdr, debug_pdr): New.
2616 * graphite-poly.h (print_pdr, debug_pdr): Declared.
2617 (PDR_BASE): Removed.
2618
26192009-06-18 Sebastian Pop <sebastian.pop@amd.com>
2620
45489e99 2621 * gcc.dg/graphite/interchange-{1..7}.c: New avatars of
2abae5f1
SP
2622 ltrans-{1..6,8}.c.
2623
26242009-06-18 Sebastian Pop <sebastian.pop@amd.com>
2625
2626 * graphite-interchange.c (compute_subscript): Allow also -1 in the
2627 subscript identification column.
2628 (pbb_do_interchange): Print to dump_file that some loops "will be
2629 interchanged". Rely on that chain of characters in the testcases.
2630 * gcc.dg/graphite/interchange-0.c: New.
2631 * gcc.dg/graphite/graphite.exp: Iterate over the testsuite
2632 interchange-*.c files and compile them with -floop-interchange.
2633
26342009-06-18 Pranav Garg <pranav.garg2107@gmail.com>
2635
2636 * graphite-interchange.c (interchange_profitable_p): Renamed
2637 pbb_interchange_profitable_p.
2638
26392009-06-18 Sebastian Pop <sebastian.pop@amd.com>
2640 Harsha Jagasia <harsha.jagasia@amd.com>
2641 Pranav Garg <pranav.garg2107@gmail.com>
2642
2643 * graphite-interchange.c (interchange_profitable_p): Make static.
2644 (pbb_interchange_loop_depths, pbb_do_interchange,
2645 scop_do_interchange): New.
2646 * graphite-poly.c (apply_poly_transforms): Call scop_do_interchange
2647 for flag_loop_interchange.
2648 * graphite-poly.h (scop_do_interchange): Declared.
2649 * tree-ssa-loop.c (gate_graphite_transforms): Do not fail when
2650 flag_loop_interchange is used.
2651
26522009-06-18 Sebastian Pop <sebastian.pop@amd.com>
2653
2654 * graphite-dependences.c (dependence_polyhedron): Update use of
2655 pbb_nb_scattering_dims.
2656 * graphite-poly.h (pbb_nb_scattering_dims): Do not pass SCOP.
2657 (pbb_nb_scattering): Update use of pbb_nb_scattering_dims.
2658 (psco_scattering_dim, psct_scattering_dim, psco_iterator_dim,
2659 psct_iterator_dim, psco_parameter_dim, psct_parameter_dim): New.
2660
26612009-06-16 Sebastian Pop <sebastian.pop@amd.com>
2662
2663 * graphite.c: Cleanup foo.
2664
26652009-06-16 Sebastian Pop <sebastian.pop@amd.com>
2666
2667 * Merge from mainline (r143684:148293).
2668 * Disabled libpcp until it gets fixed.
2669
26702009-06-05 Sebastian Pop <sebastian.pop@amd.com>
2671 Harsha Jagasia <harsha.jagasia@amd.com>
2672
2673 * graphite-interchange.c: New.
2674 * Makefile.in (graphite-interchange.o): New.
2675 * graphite-poly.h (interchange_profitable_p): Declared.
2676 * graphite-ppl.h (value_max): New.
2677
26782009-06-04 Sebastian Pop <sebastian.pop@amd.com>
2679
2680 * graphite-dependences.c (dependence_polyhedron): Use pdr_dim.
2681 * graphite-poly.h: Fix some comments.
2682 (pdr_dim): New.
2683 (pdr_scop): New.
2684
26852009-06-04 Sebastian Pop <sebastian.pop@amd.com>
2686
2687 * graphite-poly.h
2688 (pdr_accessp_nb_subscripts): Renamed pdr_nb_subscripts.
2689 (pdr_accessp_nb_iterators): Renamed pdr_dim_iter_domain.
2690 (pdr_accessp_nb_params): Renamed pdr_nb_params.
2691 (pdr_accessp_alias_set_dim): Renamed pdr_alias_set_dim.
2692 (pdr_accessp_subscript_dim): Renamed pdr_subscript_dim.
2693 (pdr_accessp_iterator_dim): Renamed pdr_iterator_dim.
2694 (pdr_accessp_param_dim): Renamed pdr_parameter_dim.
2695 (pbb_nb_loops): Renamed pbb_dim_iter_domain.
2696 * graphite-clast-to-gimple.c: Same.
2697 * graphite-dependences.c: Same.
2698 * graphite-poly.c: Same.
2699 * graphite-sese-to-poly.c: Same.
2700
27012009-06-03 Sebastian Pop <sebastian.pop@amd.com>
2702
2703 * graphite-clast-to-gimple.c (build_iv_mapping): Insert full
2704 expressions for an IV rename, as returned by clast_to_gcc_expression.
2705 (copy_renames): Rename new_name to expr.
2706 * sese.c (debug_rename_elt): Same.
2707 (get_rename): Same.
2708 (set_rename): Same.
2709 (sese_adjust_liveout_phis): Call force_gimple_operand before using
2710 the information from the rename map.
2711 (rename_variables_in_stmt): Same.
2712 (add_loop_exit_phis): Rename new_name to expr.
2713 (insert_loop_close_phis): Same.
2714 (add_guard_exit_phis): Same. Call force_gimple_operand.
2715 * sese.h (struct rename_map_elt): Rename new_name to expr.
2716 (new_rename_map_elt): Same.
2717
27182009-06-03 Sebastian Pop <sebastian.pop@amd.com>
2719
2720 * graphite-clast-to-gimple.c (build_iv_mapping): Use set_rename.
2721 * sese.c (set_rename): Make it extern.
2722 * sese.h (set_rename): Declared.
2723
27242009-06-03 Sebastian Pop <sebastian.pop@amd.com>
2725
2726 * graphite-poly.c (extend_scattering): Free values.
2727 * graphite-ppl.c (new_Cloog_Domain_from_ppl_Pointset_Powerset):
2728 Free iterators.
2729 (ppl_print_powerset_matrix): Same.
2730 * graphite-scop-detection.c (free_scops_1): New.
2731 (limit_scops): Call free_scops_1.
2732 * graphite-sese-to-poly.c (build_scop_bbs_1): Free dom.
2733 (build_poly_dr): Free PPL coefficients.
2734 * tree-parloops.c (rewrite_all_phi_nodes_with_iv): Free bbs.
2735
27362009-06-02 Sebastian Pop <sebastian.pop@amd.com>
2737
2738 * graphite-dependences.c: New.
2739 * graphite-data-ref.c: Removed.
2740 * graphite-data-ref.h: Removed.
2741 * Makefile.in (graphite-data-ref.o): Removed.
2742 (graphite-dependences.o): Added.
2743 * graphite-clast-to-gimple.c: Remove dependence on graphite-data-ref.h.
2744 * graphite-poly.c: Same.
2745 Move the data dependence testing to graphite-dependences.c.
2746
27472009-05-19 Tobias Grosser <grosser@fim.uni-passau.de>
2748
2749 * graphite-scop-detection.c (graphite_can_represent_loop): Renamed
2750 from graphite_cannot_represent_loop. Code refactored.
2751 (scopdet_basic_block_info): Call graphite_can_represent_loop.
2752
27532009-05-17 Li Feng <nemokingdom@gmail.com>
2754
45489e99 2755 * gcc.dg/graphite/graphite_autopar/graphite_autopar.exp:
2abae5f1
SP
2756 Cover all the testcases (not only the filtered ones).
2757
27582009-05-17 Tobias Grosser <grosser@fim.uni-passau.de>
2759
2760 * graphite-scop-detection.c (stmt_simple_for_scop_p): Remove
2761 unnecessary check. Update comments. Move check for REAL_TYPE here.
2762 (harmful_stmt_in_bb): Remove checks for conditions. This is already
2763 done in (stmt_simple_for_scop_p).
2764
27652009-05-14 Tobias Grosser <grosser@fim.uni-passau.de>
2766
2767 * graphite.c (print_global_statistics): New.
2768 (print_graphite_scop_statistic): New.
2769 (print_graphite_statistics): New.
2770 (graphite_initialize, graphite_transform_loops): Print statistics.
2771 * graphite-scop-detection (build_scops): Print statistics.
2772 (print_graphite_scop_statistics): New.
2773 (print_graphite_statistics): New.
2774
27752009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2776
2777 * graphite-clast-to-gimple.c (struct clast_name_index): Removed.
2778 (debug_clast_name_index): Removed.
2779 (debug_clast_name_indexes_1): Removed.
2780 (debug_clast_name_indexes): Removed.
2781 (clast_name_index_elt_info): Removed.
2782 (eq_clast_name_indexes): Removed.
2783 (clast_name_to_index): Removed.
2784 (new_clast_name_index): Removed.
2785 (save_clast_name_index): Removed.
2786 (save_var_name): Moved...
2787 (init_sese_params_index): Removed.
2788 (clast_name_to_gcc): Remove use of name_tree.
2789 (initialize_cloog_names): Same.
2790 (gloog): Do not call init_sese_params_index.
2791 * graphite-sese-to-poly.c (save_var_name): ...here.
2792 (parameter_index_in_region): New.
2793 * sese.c (new_sese): Initialize SESE_PARAMS_NAMES.
2794 (parameter_index_in_region): Removed.
2795 (is_parameter): Remove use of name_tree.
2796 * sese.h (struct name_tree): Removed.
2797 (struct sese): Remove use of name_tree. New field params_names.
2798 (SESE_PARAMS_NAMES): New.
2799 (SESE_PARAMS): Remove duplicate.
2800 (parameter_index_in_region): Removed.
2801 (sese_nb_params): Remove use of name_tree.
2802 (struct clast_name_index): New.
2803 (new_clast_name_index): New.
2804 (clast_name_to_index): New.
2805 (save_clast_name_index): New.
2806 (debug_clast_name_index): New.
2807 (debug_clast_name_indexes_1): New.
2808 (debug_clast_name_indexes): New.
2809 (clast_name_index_elt_info): New.
2810 (eq_clast_name_indexes): New.
2811
28122009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2813
2814 * graphite-clast-to-gimple.c (compute_cloog_iv_types_1): Call
2815 pbb_to_depth_to_oldiv. Remove call to oldiv_for_loop.
2816 (graphite_loop_normal_form): Do not pass region. Do not
2817 initialize SESE_OLDIVS.
2818 (build_graphite_loop_normal_form): Update call to
2819 graphite_loop_normal_form.
2820 * sese.c (debug_oldivs): Removed.
2821 (new_sese): Do not initialize SESE_OLDIVS.
2822 (free_sese): Do not free SESE_OLDIVS.
2823 (oldiv_for_loop): Removed.
2824 * sese.h (struct sese): Remove old_ivs.
2825 (SESE_OLDIVS): Removed.
2826 (oldiv_for_loop): Removed.
2827
28282009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2829
2830 * graphite-clast-to-gimple.c (clast_name_to_gcc): Pass newivs,
2831 remove ivstack. Remove call to loop_iv_stack_get_iv_from_name,
2832 replaced by a call to newivs_to_depth_to_newiv.
2833 (clast_to_gcc_expression): Pass newivs, remove ivstack.
2834 (clast_to_gcc_expression_red): Same.
2835 (gcc_type_for_clast_expr): Same.
2836 (gcc_type_for_clast_eq): Same.
2837 (graphite_translate_clast_equation): Same.
2838 (graphite_create_guard_cond_expr): Same.
2839 (graphite_create_new_guard): Same.
2840 (graphite_create_new_loop): Same.
2841 (build_iv_mapping): Same.
2842 (translate_clast): Same.
2843 (gloog): Same.
2844 (loop_iv_stack_patch_for_consts): Removed. *
2845 sese.c (iv_stack_entry_is_constant): Removed.
2846 (iv_stack_entry_is_iv): Removed.
2847 (loop_iv_stack_push_iv): Removed.
2848 (loop_iv_stack_insert_constant): Removed.
2849 (loop_iv_stack_pop): Removed.
2850 (loop_iv_stack_get_iv): Removed.
2851 (loop_iv_stack_get_iv_from_name): Removed.
2852 (debug_loop_iv_stack): Removed.
2853 (free_loop_iv_stack): Removed.
2854 (loop_iv_stack_remove_constants): Removed. *
2855 sese.h (iv_stack_entry_kind): Removed.
2856 (iv_stack_entry_data_union): Removed.
2857 (iv_stack_entry_struct): Removed.
2858 (iv_stack_entry_p): Removed.
2859 (debug_oldivs, debug_loop_iv_stack, loop_iv_stack_insert_constant,
2860 loop_iv_stack_get_iv_from_name, loop_iv_stack_push_iv,
2861 loop_iv_stack_get_iv, loop_iv_stack_remove_constants,
2862 loop_iv_stack_pop, free_loop_iv_stack): Removed.
2863 (gbb_loop_at_index): Fix indenting.
2864 (gbb_loop_index): Removed.
2865
28662009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2867
2868 * graphite-clast-to-gimple.c (clast_name_to_gcc): Do not use strcmp.
2869 Call clast_name_to_index.
2870
28712009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2872
2873 * graphite-clast-to-gimple.c (clast_name_to_gcc): Pass region,
2874 do not pass params. Get params from SESE_PARAMS.
2875 (clast_to_gcc_expression): Same.
2876 (clast_to_gcc_expression_red): Same.
2877 (gcc_type_for_clast_eq): Same.
2878 (graphite_translate_clast_equation): Same.
2879 (graphite_create_new_loop): Same.
2880 * sese.c (rename_variables_in_stmt): Fix comment.
2881
28822009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2883
2884 * graphite-clast-to-gimple.c (graphite_create_new_loop): Pass
2885 newivs_index.
2886 Call save_clast_name_index.
2887 (translate_clast): Pass newivs_index.
2888 (gloog): Create and free newivs_index.
2889
28902009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2891
2892 * graphite-clast-to-gimple.c (clast_name_index): New structure.
2893 (clast_name_index_p): New type.
2894 (debug_clast_name_index): New.
2895 (debug_clast_name_indexes_1): New.
2896 (debug_clast_name_indexes): New.
2897 (clast_name_index_elt_info): New.
2898 (eq_clast_name_indexes): New.
2899 (clast_name_to_index): New.
2900 (new_clast_name_index): New.
2901 (save_clast_name_index): New.
2902 (init_sese_params_index): New.
2903 (gloog): Call init_sese_params_index.
2904 * graphite-clast-to-gimple.h (debug_clast_name_indexes): Declared.
2905 * sese.c (new_sese): Initialize SESE_PARAMS_INDEX.
2906 (free_sese): Free SESE_PARAMS_INDEX.
2907 * sese.h (struct sese): Add params_index.
2908 (SESE_PARAMS_INDEX): New.
2909
29102009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2911
2912 * graphite-clast-to-gimple.c (newivs_to_depth_to_newiv): New.
2913 (graphite_create_new_loop): Pass the newivs vector. Push the
2914 newly created IV to newivs.
2915 (translate_clast): Pass the newivs vector.
2916 (gloog): Create and destroy the newivs vector.
2917
29182009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2919
2920 * graphite-clast-to-gimple.c (pbb_to_depth_to_oldiv): New.
2921 (graphite_loop_normal_form): Initialize loop->aux with the unique
2922 IV that has been created.
2923
29242009-05-13 Tobias Grosser <grosser@fim.uni-passau.de>
2925
2926 * tree-chrec.c (evolution_function_right_is_integer_cst): Allow
2927 scev with parameters in the base part. They where forbidden
2928 exidently.
2929
29302009-05-11 Li Feng <nemokingdom@gmail.com>
2931
45489e99 2932 * gcc.dg/graphite/graphite.exp: Set different default
2abae5f1 2933 compile options by file names.
45489e99
SP
2934 * gcc.dg/graphite/block{0-6}.c: Remove dg-option line.
2935 * gcc.dg/graphite/id-{1-9}.c: Ditto.
2936 * gcc.dg/graphite/scop-{0-20}.c: Ditto.
2937 * gcc.dg/graphite/scop-matmult.c: Ditto.
2abae5f1
SP
2938
29392009-05-08 Li Feng <nemokingdom@gmail.com>
2940
45489e99
SP
2941 * gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: New.
2942 * gcc.dg/graphite/graphite_autopar/force-parallel-1.c: New.
2943 * gcc.dg/graphite/graphite_autopar/force-parallel-2.c: New.
2944 * gcc.dg/graphite/graphite_autopar/force-parallel-3.c: New.
2abae5f1
SP
2945
29462009-05-07 Tobias Grosser <grosser@fim.uni-passau.de>
2947
2948 * graphite-scop-detection (build_scops_1): Fix little bug introduced
2949 by final cleanup.
2950
29512009-05-07 Tobias Grosser <grosser@fim.uni-passau.de>
2952
2953 * graphite-scop-detection.c (graphite_can_represent_scev): Only
2954 allow integer constant strides.
2955 (graphite_can_represent_expr): Depend on outermost_loop.
2956 (stmt_simple_memref_p, graphite_cannot_represent_loop,
2957 harmful_stmt_in_bb, is_simple_operand, stmt_simple_for_scop_p,
2958 build_scops_1): Same.
2959 (scopdet_basic_block_info): Same and insert layered SCoP
2960 detection.
2961 (try_generate_gimple_bb): Cleanup.
2962 (build_scops): Enable data references.
2963
45489e99
SP
2964 * gcc.dg/graphite/id-5.c: New.
2965 * gcc.dg/graphite/id-9.c: New.
2abae5f1
SP
2966 * tree-chrec.c (evolution_function_right_is_integer_cst): New.
2967 * tree-chrec.h (evolution_function_right_is_integer_cst): New.
2968
29692009-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
2970
2971 * sese.c (expand_scalar_variables_ssa_name): Only build expressions,
2972 that we have not yet built for this SCoP.
2973
29742009-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
2975
2976 * sese.c (expand_scalar_variables_expr): Fix expand_scalar_variables
2977 for complex numbers.
2978
29792009-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
2980
2981 * graphite-ppl.c: Fix build if cloog is not available.
2982
29832009-05-04 Li Feng <nemokingdom@gmail.com>
2984
2985 * tree-parloops.c (loop_parallel_p): Remove construction of
2986 NITER and REDUCTION_LIST.
2987 (try_get_loop_niter): New.
2988 (try_create_reduction_list): New.
2989 (parallelize_loops): Bypass the failed checkings in autopar
2990 when can_be_parallel in loop structure is set to true.
2991
29922009-05-01 Tobias Grosser <grosser@fim.uni-passau.de>
2993
45489e99
SP
2994 * gcc.dg/graphite/id-6.c: Update testcase.
2995 * gcc.dg/graphite/scop-3.c: Dito.
2abae5f1
SP
2996
29972009-05-01 Tobias Grosser <grosser@fim.uni-passau.de>
2998
2999 * graphite-scop-detection.c (stmt_simple_for_scop_p):
3000 Enable EQ_EXPR and NE_EXPR again.
3001
30022009-04-30 Tobias Grosser <grosser@fim.uni-passau.de>
3003
3004 * graphite-scop-detection.c (graphite_can_represent_scev):
3005 Add check if scev is affine multivariate.
3006 (harmful_stmt_in_bb): Check if we can represent the conditions.
3007 (scopdet_basic_block_info (basic_block bb, VEC): Pass the loop to
3008 harmful_stmt_in_bb.
45489e99 3009 * gcc.dg/graphite/id-7.c: New.
2abae5f1
SP
3010
30112009-04-30 Tobias Grosser <grosser@fim.uni-passau.de>
3012
3013 * graphite-sese-to-poly.c (bb_contains_non_iv_scalar_phi_nodes):
3014 Check all bbs in region, not only the bbs that are represented in
3015 GRAPHITE.
3016 (build_poly_scop): Add newline.
45489e99 3017 * gcc.dg/graphite/id-8.c: New.
2abae5f1
SP
3018
30192009-04-30 Li Feng <nemokingdom@gmail.com>
3020
3021 * cfgloop.c (alloc_loop): Initialize can_be_parallel to false
3022 when loop initialize.
3023 * cfgloop.h (struct loop): Introduce flag can_be_parallel.
3024 * common.opt: Declare flag_graphite_force_parallel.
3025 * graphite-clast-to-gimple.c (translate_clast): Mark the innermost
3026 loop parallel.
3027 * graphite-poly.c (apply_poly_transforms): Introduce
3028 flag_graphite_force_parallel.
3029 * tree-ssa-loop.c (gate_graphite_transforms): ditto.
3030 * toplev.c (process_options): ditto and replace a not correctly
3031 encoded space.
3032
30332009-04-30 Li Feng <nemokingdom@gmail.com>
3034
3035 * graphite-clast-to-gimple.c (loop_iv_stack_patch_for_consts):
3036 Change the call of gbb_loop_at_index and/or gbb_loop_index due
3037 to the redefinition.
3038 (compute_cloog_iv_types_1): ditto.
3039 (build_iv_mapping): ditto.
3040 * graphite-sese-to-poly.c (new_gimple_bb): Remove GBB_LOOPS related
3041 initialization.
3042 (free_gimple_bb): Removed GBB_LOOPS related free part.
3043 (build_bb_loops): Removed.
3044 * sese.h (struct gimple_bb): Removed loops.
3045 (GBB_LOOPS): Removed.
3046 (gbb_loop_at_index): Instead of using GBB_LOOPS, we use sese instead.
3047 (gbb_loop_index): ditto.
3048
30492009-04-24 Tobias Grosser <grosser@fim.uni-passau.de>
3050
3051 * graphite-scop-detection.c (graphite_can_represent_scev): Do not
3052 allow non constant strides.
45489e99 3053 * gcc.dg/graphite/scop-20.c: New.
2abae5f1
SP
3054
30552009-04-24 Sebastian Pop <sebastian.pop@amd.com>
3056
3057 * graphite-scop-detection.c (dot_all_scops): Fix system call
3058 return value warning.
3059 (dot_scop): Same.
3060
30612009-04-24 Sebastian Pop <sebastian.pop@amd.com>
3062
45489e99
SP
3063 * gcc.dg/graphite/id-6.c: Fix pattern.
3064 * gcc.dg/graphite/scop-3.c: Same.
2abae5f1
SP
3065
30662009-04-24 Sebastian Pop <sebastian.pop@amd.com>
3067
3068 * graphite-poly.c (map_into_dep_poly, map_dr_into_dep_poly,
3069 build_pairwise_constraint, dr_equality_constraints,
3070 build_pairwise_scheduling_equality,
3071 build_pairwise_scheduling_inequality, lexicographically_gt_p,
3072 build_lexicographically_gt_constraint, dependence_polyhedron,
3073 graphite_legal_transform_dr, graphite_legal_transform_bb,
3074 graphite_legal_transform): New.
3075 * graphite-poly.h (graphite_legal_transform): Declared.
3076 * graphite-sese-to-poly.c (build_poly_scop): Call to
3077 graphite_legal_transform is disabled for the moment.
3078
30792009-04-24 Sebastian Pop <sebastian.pop@amd.com>
3080
3081 * graphite-poly.h (pbb_nb_scattering_dims): New.
3082 (pbb_nb_scattering): Use it.
3083
30842009-04-24 Sebastian Pop <sebastian.pop@amd.com>
3085
3086 * graphite-ppl.c (ppl_insert_dimensions_pointset): Add
3087 Pointset_Powerset version of ppl_insert_dimensions.
3088 * graphite-ppl.h (ppl_insert_dimensions_pointset): Declared.
3089
30902009-04-24 Sebastian Pop <sebastian.pop@amd.com>
3091
3092 * graphite-ppl.c (ppl_insert_dimensions): Fix formatting.
3093
30942009-04-24 Sebastian Pop <sebastian.pop@amd.com>
3095
3096 * graphite-poly.h: Fix comment.
3097
30982009-04-24 Sebastian Pop <sebastian.pop@amd.com>
3099
3100 * graphite-sese-to-poly.c (build_poly_dr): Fix data ref multiplier.
3101
31022009-04-24 Tobias Grosser <grosser@fim.uni-passau.de>
3103
3104 * sese.c (expand_scalar_variables_stmt): Only iterate over the old
3105 statements.
3106
31072009-04-24 Tobias Grosser <grosser@fim.uni-passau.de>
3108
3109 * graphite-sese-to-poly.c (var_used_in_not_loop_header_phi_node): New.
3110 (graphite_stmt_p): Represent bbs necessary to build the phi nodes of
3111 conditions.
3112
31132009-04-20 Sebastian Pop <sebastian.pop@amd.com>
3114
3115 * graphite-scop-detection.c (stmt_simple_for_scop_p): Do not
3116 handle EQ_EXPR and NE_EXPR.
3117
31182009-04-17 Tobias Grosser <grosser@fim.uni-passau.de>
3119
3120 * graphite-poly.h (poly_dr): Fix comment.
3121
31222009-04-09 Sebastian Pop <sebastian.pop@amd.com>
3123 Tobias Grosser <grosser@fim.uni-passau.de>
3124
3125 * graphite-poly.c (new_poly_bb): Do not initialize PBB_DOMAIN
3126 with a zero dimension polyhedron.
3127 (find_scop_parameters): Move the call to scop_set_nb_params here.
3128 (build_loop_iteration_domains): Store in loop->aux the iteration
3129 domain polyhedron.
3130 (build_scop_iteration_domain): Fix PBB_DOMAIN for bbs not surrounded
3131 by any loop in scop.
3132 (build_poly_scop): Do not call scop_set_nb_params.
3133
31342009-04-09 Sebastian Pop <sebastian.pop@amd.com>
3135 Tobias Grosser <grosser@fim.uni-passau.de>
3136
3137 * graphite-sese-to-poly.c (add_condition_to_pbb): Pass code to
3138 add_condition_to_domain not GT_EXPR.
3139
31402009-04-09 Tobias Grosser <grosser@fim.uni-passau.de>
3141
3142 * graphite-ppl.c (debug_ppl_powerset_matrix): New.
3143 * graphite-ppl.h (debug_ppl_powerset_matrix): New.
3144 * graphite-sese-to-poly.c (add_condition_to_pbb): Use
3145 upper_bound_assign to calculate unions.
45489e99 3146 * gcc.dg/graphite/id-6.c: New.
2abae5f1
SP
3147
31482009-04-09 Tobias Grosser <grosser@fim.uni-passau.de>
3149
3150 * graphite-scop-detection.c (canonicalize_loop_closed_ssa): Do not
3151 handle abnormal edges.
3152
31532009-04-09 Tobias Grosser <grosser@fim.uni-passau.de>
3154
3155 * graphite-poly.c (new_poly_dr, free_poly_dr): New.
3156 (free_poly_bb): Also free poly_drs.
3157 * graphite-poly.h (new_poly_dr, free_poly_dr): New.
3158 (poly_dr): Polyhedron to Pointset_Powerset.
3159 (pdr_accessp_nb_subscripts): Same.
3160 * graphite-sese-to-poly.c (build_poly_dr): Same. And actually build
3161 poly_drs.
3162
31632009-04-08 Sebastian Pop <sebastian.pop@amd.com>
3164
3165 * graphite-clast-to-gimple.c (initialize_cloog_names): Change cloog
3166 names into more meaningful names.
3167
31682009-04-08 Sebastian Pop <sebastian.pop@amd.com>
3169
45489e99
SP
3170 * gfortran.dg/graphite/interchange-1.c: New.
3171 * gfortran.dg/graphite/interchange-2.c: New.
2abae5f1
SP
3172
31732009-04-08 Sebastian Pop <sebastian.pop@amd.com>
3174
3175 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not build
3176 the reduction_list.
3177 * tree-parloops.c (rewrite_phi_with_iv): New.
3178 (rewrite_all_phi_nodes_with_iv): New.
3179 (canonicalize_loop_ivs): Call them.
3180
31812009-04-08 Sebastian Pop <sebastian.pop@amd.com>
3182
3183 * graphite-sese-to-poly.c (try_generate_gimple_bb): Use
3184 graphite_find_data_references_in_stmt.
3185 * tree-data-ref.c (graphite_find_data_references_in_stmt): New.
3186 * tree-data-ref.h (graphite_find_data_references_in_stmt): Declared.
3187
31882009-04-08 Sebastian Pop <sebastian.pop@amd.com>
3189
3190 * sese.c (add_loop_exit_phis): Don't fail on non SSA_NAME renames.
3191
31922009-04-08 Sebastian Pop <sebastian.pop@amd.com>
3193
3194 * graphite-sese-to-poly.c (build_scop_bbs_1): Use bb_in_sese_p
3195 instead of bb_in_region.
3196 (flag_bb_in_region): Same. Renamed flag_bb_in_sese.
3197 (build_sese_conditions): Use flag_bb_in_sese.
3198 * sese.c (register_bb_in_sese): Removed.
3199 (new_sese): Remove initialization of SESE_REGION_BBS.
3200 (free_sese): Do not free SESE_REGION_BBS.
3201 * sese.h (struct sese): Remove field region_basic_blocks.
3202 (SESE_REGION_BBS): Removed.
3203 (bb_in_sese_p): Implement in function of bb_in_region.
3204
32052009-04-08 Sebastian Pop <sebastian.pop@amd.com>
3206
3207 * graphite-scop-detection.c (limit_scops): Deal only with single exit
3208 loops.
3209
32102009-04-08 Tobias Grosser <grosser@fim.uni-passau.de>
3211
3212 * graphite-scop-detection.c (stmt_simple_for_scop_p): Allow NE_EXPR
3213 and EQ_EXPR.
3214 * graphite-sese-to-poly.c (create_linear_expr_from_tree): New.
3215 (add_condition_to_domain): New.
3216 (add_condition_to_pbb): New.
3217 (add_conditions_to_domain): Cleanup and handle of NE_EXPR and EQ_EXPR.
45489e99 3218 * gcc.dg/graphite/scop-3.c: Update number of detected SCoPs.
2abae5f1
SP
3219
32202009-04-08 Tobias Grosser <grosser@fim.uni-passau.de>
3221
3222 * graphite-clast-to-gimple.c (build_cloog_prog): ppl_Polyhedron ->
3223 ppl_Pointset_Powerset.
3224 * graphite-poly.c (new_poly_bb, free_poly_bb): Same.
3225 * graphite-poly.h (poly_bb): poly_bb.domain Same.
3226 (pbb_nb_loops): Same.
3227 * graphite-sese-to-poly.c (build_loop_iteration_domains,
3228 add_conditions_to_domain): Same.
3229 * graphite-ppl.c (new_Cloog_Domain_from_ppl_Pointset_Powerset): New.
3230 (ppl_print_polyhedron_matrix): ppl_Polyhedron_t ->
3231 ppl_const_Polyhedron_t.
3232 (ppl_print_powerset_matrix): New.
3233 * graphite-ppl.h (new_Cloog_Domain_from_ppl_Pointset_Powerset,
3234 ppl_print_powerset_matrix): New.
3235 (ppl_print_polyhedron_matrix): Updated.
3236
32372009-04-07 Sebastian Pop <sebastian.pop@amd.com>
3238
3239 * tree-scalar-evolution.c (analyze_scalar_evolution_1): Fix comment.
3240
32412009-04-07 Sebastian Pop <sebastian.pop@amd.com>
3242
3243 * graphite-poly.c (extend_scattering): Fix indenting. Free cstr.
3244 (print_iteration_domains, debug_iteration_domain,
3245 debug_iteration_domains): New.
3246 * graphite-poly.h (print_iteration_domains, debug_iteration_domain,
3247 debug_iteration_domains): Declared.
3248 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons): Fix
3249 indenting.
3250
32512009-04-03 Tobias Grosser <grosser@fim.uni-passau.de>
3252 Sebastian Pop <sebastian.pop@amd.com>
3253
3254 * graphite-poly.h (print_iteration_domain): New.
3255 * graphite-sese-to-poly.c (add_conditions_to_domain): Fixed bug.
3256 (build_sese_conditions_1, build_sese_conditions_after,
3257 build_sese_conditions_before): New.
3258 (build_sese_conditions): Rewritten.
3259
32602009-04-03 Sebastian Pop <sebastian.pop@amd.com>
3261 Tobias Grosser <grosser@fim.uni-passau.de>
3262
3263 Cleanup of code generation liveouts.
3264 * graphite-clast-to-gimple.c (translate_clast): Use a single
3265 rename_map instead of one per translated statement.
3266 Do not use SESE_LIVEOUT_RENAMES.
3267 (graphite_loop_normal_form): Do not use SESE_REDUCTION_LIST.
3268 (gloog): Do not use SESE_LIVEOUT_RENAMES.
3269 * graphite-scop-detection.c (harmful_stmt_in_bb): Return the close
3270 phi node of a reduction: when a loop contains a reduction used outside
3271 the loop, there should be a scalar close phi node on the exit block.
3272 * sese.c (new_sese): Do not initialize SESE_LIVEOUT,
3273 SESE_LIVEOUT_RENAMES, and SESE_REDUCTION_LIST.
3274 (free_sese): Do not free them.
3275 (sese_build_liveouts_use): Do not use them.
3276 (sese_build_liveouts_bb): Same.
3277 (sese_build_liveouts): Same.
3278 (sese_insert_phis_for_liveouts): Same.
3279 (sese_adjust_phis_for_liveouts): Same. Renamed sese_adjust_liveout_phis.
3280 (defined_in_loop_p): New.
3281 (alive_after_loop): New.
3282 (close_phi_not_yet_inserted_p): New.
3283 (struct alep, alep_p): New.
3284 (add_loop_exit_phis): Remove from the rename_map all the names defined
3285 in the code generated loop.
3286 (insert_loop_close_phis): Traverse the rename_map passed to it.
3287 Don't use SESE_LIVEOUT_RENAMES.
3288 (default_liveout_before_guard): Renamed default_before_guard.
3289 (insert_guard_phis): Do not use SESE_LIVEOUT_RENAMES.
3290 (graphite_copy_stmts_from_block): Do not directly call set_rename.
3291 (register_sese_liveout_renames): Removed.
3292 (copy_bb_and_scalar_dependences): Do not call it.
3293 * sese.h (struct sese): Removed fields: liveout, liveout_renames, and
3294 reduction_list.
3295 (SESE_LIVEOUT): Removed.
3296 (SESE_LIVEOUT_RENAMES): Removed.
3297 (SESE_REDUCTION_LIST): Removed.
3298 (sese_build_liveouts): Removed.
3299 (sese_adjust_phis_for_liveouts): Renamed sese_adjust_liveout_phis.
3300 (insert_loop_close_phis): Pass a htab_t instead of a sese.
3301 (insert_guard_phis): Same.
3302 (rename_map_elt): Declare a VEC of them.
3303 * tree-parloops.c (canonicalize_loop_ivs): reduction_list contains
3304 trees not pointers to trees.
3305
3306 Rewrite in canonical close SSA form:
3307 * graphite-scop-detection.c (contains_only_close_phi_nodes): New.
3308 (limit_scops): Close the scop after the block containing the close phi
3309 nodes.
3310 (canonicalize_loop_closed_ssa): New.
3311 (canonicalize_loop_closed_ssa_form): New.
3312 (build_scops): Call canonicalize_loop_closed_ssa_form.
3313
3314 * graphite-sese-to-poly.c: Fix typos.
3315
33162009-04-03 Sebastian Pop <sebastian.pop@amd.com>
3317
3318 * graphite-poly.c (print_scattering_function, print_pbb_domain):
3319 Extended.
3320 (dump_gbb_conditions, dump_gbb_cases, print_iteration_domain): New.
3321 (print_pbb): Add conditions.
3322
33232009-04-01 Tobias Grosser <grosser@fim.uni-passau.de>
3324 Sebastian Pop <sebastian.pop@amd.com>
3325
3326 * graphite-scop-detection.c (bb_in_sd_region): Use bb_in_region.
3327 * graphite-sese-to-poly.c (all_non_dominated_preds_marked_p): New.
3328 (build_scop_bbs_1): New.
3329 (build_scop_bbs): Rewrite.
3330 * sese.h (bb_in_region): New.
3331
33322009-03-29 Tobias Grosser <grosser@fim.uni-passau.de>
3333
3334 * graphite-poly.c (new_poly_bb, free_poly_bb): Initialize/free
3335 poly_drs vector.
3336 (print_scop): Style.
3337 * graphite-poly.h (poly_bb): Add drs vector.
3338 (PBB_DRS): Add accessor.
3339 * graphite-sese-to-poly.c (build_poly_dr): New.
3340 (build_pbb_drs, build_scop_drs): New.
3341 (build_poly_scop): call build_scop_drs (Disabled at the moment).
3342
33432009-03-29 Tobias Grosser <grosser@fim.uni-passau.de>
3344
3345 * tree-ssa-loop.c: Include forgotten toplev.h
3346
33472009-03-29 Tobias Grosser <grosser@fim.uni-passau.de>
3348
3349 * graphite-poly.c: (apply_poly_transforms): sorry -> gcc_unreachable.
45489e99
SP
3350 * gcc.dg/graphite/pr37883.c: Remove -floop-*
3351 * gcc.dg/graphite/pr37928.c: Same
3352 * gcc.dg/graphite/pr38409.c: Same
3353 * gcc.dg/graphite/pr38498.c: Same
3354 * gcc.dg/graphite/pr38559.c: Same
3355 * gcc.dg/graphite/pr39335.c: Same
3356 * gcc.dg/graphite/pr39335_1.c: Same
3357 * gfortran.dg/graphite/block-2.f: Same
2abae5f1
SP
3358 * tree-ssa-loop.c (gate_graphite_transforms): Always fail if called
3359 with -floop-*.
3360
33612009-03-28 Tobias Grosser <grosser@fim.uni-passau.de>
3362
3363 * graphite-sese-to-poly.c (ref_nb_loops, build_access_matrix_with_af,
3364 build_access_matrix, build_scop_data_accesses): Remove access function
3365 building. (We get a new version soon).
3366 (build_bb_loops, scan_tree_for_params_right_scev): Update.
3367 * sese.h (nb_loops_around_loop_in_sese): Remove.
3368 (sese_loop_depth): Do not use SESE_LOOP_NEST any more.
3369
33702009-03-27 Tobias Grosser <grosser@fim.uni-passau.de>
3371 Sebastian Pop <sebastian.pop@amd.com>
3372
3373 * graphite-scop-detection.c (struct scopdet_info): Rename last
3374 field to exit.
3375 (scopdet_basic_block_info, build_scops_1): Don't use
3376 CDI_POST_DOMINATORS. CDI_POST_DOMINATORS should never be used.
3377
33782009-03-26 Tobias Grosser <grosser@fim.uni-passau.de>
3379 Sebastian Pop <sebastian.pop@amd.com>
3380
3381 * graphite-clast-to-gimple.c (gloog): Call sese_build_liveouts.
3382 * sese.c (sese_build_liveouts_use): Renamed from
3383 sese_build_livein_liveouts_use. Remove liveins.
3384 (sese_build_liveouts_bb): Renamed from sese_build_livein_liveouts_bb.
3385 Call sese_build_liveouts_use.
3386 (sese_build_liveouts): Renamed from sese_build_livein_liveouts.
3387 Call sese_build_liveouts_bb.
3388 (new_sese, free_sese): Remove liveins.
3389 (sese_add_exit_phis_var): Deleted.
3390 (sese_insert_phis_for_liveouts): Call sese_add_exit_phis_edge
3391 directly.
3392 (graphite_copy_stmts_from_block): Remove SESE_NUM_VER.
3393
3394 * sese.h (sese): Remove num_ver and livein.
3395 (SESE_LIVEIN, SESE_LIVEIN_VER, SESE_NUM_VER): Removed.
3396
33972009-03-25 Tobias Grosser <grosser@fim.uni-passau.de>
3398
3399 * graphite-sese-to-poly.c (build_scop_scattering): Fix compile.
3400
34012009-03-25 Tobias Grosser <grosser@fim.uni-passau.de>
3402
3403 * graphite-sese-to-poly.c (compare_prefix_loops): Removed.
3404 (build_scop_scattering): Do not use compare_prefix_loops any more.
3405 (nb_common_loops): New.
3406
34072009-03-24 Sebastian Pop <sebastian.pop@amd.com>
3408
3409 * sese.c (get_new_name_from_old_name): Renamed get_rename.
3410 (register_old_and_new_names): Renamed set_rename.
3411
34122009-03-24 Sebastian Pop <sebastian.pop@amd.com>
3413
3414 * graphite-scop-detection.h (nb_reductions_in_loop): Revert removal
3415 of the decl from the previous commit.
3416
34172009-03-24 Sebastian Pop <sebastian.pop@amd.com>
3418
3419 * graphite-scop-detection.c (dot_scop): New.
3420 * graphite-scop-detection.h (dot_scop): Declared.
3421
34222009-03-24 Sebastian Pop <sebastian.pop@amd.com>
3423
3424 * graphite-sese-to-poly.c (compare_prefix_loops): Fix compare.
3425
34262009-03-24 Sebastian Pop <sebastian.pop@amd.com>
3427
3428 * cfgloopmanip.c (create_empty_loop_on_edge): Generate the loop exit
3429 condition at the end of the loop.
3430 * graphite.c (graphite_initialize, graphite_finalize): Print to
3431 dump_file the compiled function.
3432 * graphite-clast-to-gimple.c (graphite_create_new_loop): Update use
3433 of create_empty_loop_on_edge.
3434 (translate_clast): Update the code generation of loops for the new
3435 shape of loops.
3436 * cfgloop.h (create_empty_loop_on_edge): Update declaration.
3437
34382009-03-24 Sebastian Pop <sebastian.pop@amd.com>
3439
3440 Reverted the patch from 2009-03-19.
3441
34422009-03-19 Tobias Grosser <grosser@fim.uni-passau.de>
3443
3444 * graphite-poly.c (new_poly_bb, free_poly_bb): Initialize/free
3445 poly_drs vector.
3446 (print_scop): Style.
3447 * graphite-poly.h (poly_bb): Add drs vector.
3448 (PBB_DRS): Add accessor.
3449 * graphite-sese-to-poly.c (ref_nb_loops): Remove.
3450 (build_access_matrix_with_af, build_access_matrix,
3451 build_scop_data_accesses): Delete.
3452 (build_poly_dr): New.
3453 (build_pbb_drs, build_scop_drs): New.
3454 (build_poly_scop): call build_scop_drs.
3455
34562009-03-13 Sebastian Pop <sebastian.pop@amd.com>
3457
3458 * graphite-scop-detection.c (dot_all_scops_1): Close the table
3459 once per basic block.
3460
34612009-03-13 Tobias Grosser <grosser@fim.uni-passau.de>
3462
3463 * graphite-scop-detection.c (graphite_can_represent_scev): New.
3464 (graphite_can_represent_expr): Renamed from loop_affine_expr
3465 and enhanced.
3466 (stmt_simple_for_scop_p): Call graphite_can_represent_expr.
3467 (graphite_cannot_represent_loop): Add scop_entry to parameters.
3468 (scopdet_basic_block_info): Actually define entry_block.
3469 (stmt_simple_memref_p): Moved here from ...
3470
3471 * tree-data-ref.c (stmt_simple_memref_p): here.
3472 * tree-data-ref.h (stmt_simple_memref_p): Removed.
3473
34742009-03-13 Tobias Grosser <grosser@fim.uni-passau.de>
3475
45489e99 3476 * gcc.dg/graphite/id-4.c: New.
2abae5f1
SP
3477
34782009-03-12 Sebastian Pop <sebastian.pop@amd.com>
3479
3480 * sese.c (expand_scalar_variables_expr): Handle tcc_comparison.
3481 (register_old_and_new_names): Update the content of the map.
3482 When there was already a rename_map_elt in the map at that
3483 location, free it.
3484 (copy_bb_and_scalar_dependences): Do rename_variables after
3485 expand_scalar_variables.
3486 * graphite-clast-to-gimple.c (build_iv_mapping): Update the content
3487 of the map. When there was already a rename_map_elt in the
3488 map at that location, free it.
3489 (translate_clast): Pass the rename_map. Do not initialize and free
3490 a rename_map per stmt_user.
3491 (gloog): Initialize and free one rename_map and pass it to
3492 translate_clast.
3493
34942009-03-12 Sebastian Pop <sebastian.pop@amd.com>
3495
3496 * sese.c (expand_scalar_variables_stmt,
3497 expand_scalar_variables_ssa_name): Add a gimple_stmt_iterator
3498 parameter.
3499 (expand_scalar_variables_expr): Handle REALPART_EXPR and IMAGPART_EXPR.
3500 (expand_scalar_variables): Pass to expand_scalar_variables_stmt
3501 the gimple_stmt_iterator of the statement to be expanded.
3502 * graphite-scop-detection.c (is_simple_operand): Do handle
3503 REALPART_EXPR.
3504
35052009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
3506
3507 * graphite-scop-detection.c (is_simple_operand): Do not handle
3508 REALPART_EXPR.
45489e99 3509 * gcc.dg/graphite/id-2.c: New.
2abae5f1
SP
3510
3511 * graphite-sese-to-poly.c (build_bb_loops,
3512 add_value_to_dim, scan_tree_for_params_right_scev,
3513 scan_tree_for_params_int, scan_tree_for_params, idx_record_params,
3514 find_params_in_bb, build_loop_iteration_domains,
3515 add_conditions_to_domain): Remove subtract.
3516
35172009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
3518
3519 * graphite-clast-to-gimple.c (loop_iv_stack_patch_for_consts,
3520 build_iv_mapping, compute_cloog_iv_types_1, build_cloog_prog):
3521 pbb_loop_at_index -> gbb_loop_at_index.
3522 * graphite-poly.c (new_poly_bb, new_scop): New accessors.
3523 (debug_loop_vec): Delete.
3524 * graphite-poly.h (poly_bb, scop): Change black_box and region to void
3525 pointer. Move LOOPS to gimple_bb_p and insert nb_params.
3526 (PBB_LOOPS): Removed.
3527 (PBB_BLACK_BOX): Insert cast.
3528 (pbb_set_black_box): New setter.
3529 (pbb_loop_at_index, pbb_loop_index): Removed.
3530 (scop_set_region, scop_set_nb_params): New.
3531 * graphite-sese-to-poly.c (new_gimple_bb, free_gimple_bb,
3532 build_scop_scattering, build_bb_loops): Add GBB_LOOPS.
3533 (build_poly_scop): Use scop_set_nb_params.
3534 * sese.h (gimple_bb): Add LOOPS.
3535 (GBB_LOOPS, gbb_loop_index, gbb_loop_at_index): New.
3536
35372009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
3538
3539 Revert previous commit.
3540
35412009-03-11 Sebastian Pop <sebastian.pop@amd.com>
3542
3543 * sese.c (expand_scalar_variables_expr): Handle tcc_comparison.
3544 (register_old_and_new_names): Update the content of the map.
3545 When there was already a rename_map_elt in the map at that
3546 location, free it.
3547 (copy_bb_and_scalar_dependences): Do rename_variables after
3548 expand_scalar_variables.
3549 * graphite-clast-to-gimple.c (build_iv_mapping): Update the content
3550 of the map. When there was already a rename_map_elt in the
3551 map at that location, free it.
3552 (translate_clast): Pass the rename_map. Do not initialize and free
3553 a rename_map per stmt_user.
3554 (gloog): Initialize and free one rename_map and pass it to
3555 translate_clast.
3556
35572009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
3558
3559 Remove forgotten line in revert.
3560
35612009-03-11 Sebastian Pop <sebastian.pop@amd.com>
3562
3563 Revert previous commit.
3564
35652009-03-10 Sebastian Pop <sebastian.pop@amd.com>
3566
3567 * sese.c (register_old_and_new_names): Update the content
3568 of the map. When there was already a rename_map_elt in the
3569 map at that location, free it.
3570 (copy_bb_and_scalar_dependences): Do rename_variables after
3571 expand_scalar_variables.
3572 * graphite-clast-to-gimple.c (build_iv_mapping): Update the content
3573 of the map. When there was already a rename_map_elt in the
3574 map at that location, free it.
3575 (translate_clast): Pass the rename_map. Do not initialize and free
3576 a rename_map per stmt_user.
3577 (gloog): Initialize and free one rename_map and pass it to
3578 translate_clast.
3579
35802009-03-10 Sebastian Pop <sebastian.pop@amd.com>
3581
3582 * graphite-clast-to-gimple.c (translate_clast): context_loop
3583 is never NULL.
3584
35852009-03-10 Tobias Grosser <grosser@fim.uni-passau.de>
3586 Sebastian Pop <sebastian.pop@amd.com>
3587
3588 * graphite-ppl.c (ppl_insert_dimensions): Fix stupid mistake
3589 of the use of ppl_Polyhedron_map_space_dimensions.
3590
35912009-03-10 Tobias Grosser <grosser@fim.uni-passau.de>
3592 Sebastian Pop <sebastian.pop@amd.com>
3593
3594 * graphite-poly.c (unify_scattering_dimensions): Fix types.
3595 * graphite-poly.h (poly_dr_p, poly_dr, POLY_DR_TYPE, PDR_BB,
3596 PDR_TYPE, PDR_ACCESSES, pdr_accessp_nb_subscripts,
3597 pdr_accessp_nb_iterators, pdr_accessp_nb_params,
3598 pdr_accessp_alias_set_dim, pdr_accessp_subscript_dim,
3599 pdr_accessp_iterator_dim, pdr_accessp_param_dim,
3600 pbb_nb_params): New.
3601 (pbb_nb_loops, pbb_nb_scattering, scop_nb_params,
3602 nb_loops_around_pbb): Adapt return types.
3603
36042009-03-09 Tobias Grosser <grosser@fim.uni-passau.de>
3605
3606 * Makefile.in (graphite.o, graphite-sese-to-poly.o,
3607 graphite-clast-to-gimple.o, graphite-data-ref.o,
3608 graphite-scop-detection.o, graphite-poly.o): Add
3609 more headers.
3610
36112009-03-05 Tobias Grosser <grosser@fim.uni-passau.de>
3612
3613 * Makefile.in (graphite.o, graphite-sese-to-poly.o,
3614 graphite-clast-to-gimple.o, graphite-data-ref.o,
3615 graphite-scop-detection.o, graphite-poly.o): Add graphite-poly.h.
3616
36172009-03-04 Tobias Grosser <grosser@fim.uni-passau.de>
3618
45489e99
SP
3619 * gcc.dg/graphite/pr37485.c: Remove -floop-block
3620 * gcc.dg/graphite/pr37828.c: Same.
3621 * gcc.dg/graphite/pr37684.c: Same.
3622 * gcc.dg/graphite/block-0.c: Same.
3623 * gcc.dg/graphite/block-1.c: Same.
3624 * gcc.dg/graphite/block-2.c: Same.
3625 * gcc.dg/graphite/block-3.c: Same.
3626 * gcc.dg/graphite/block-4.c: Same.
3627 * gcc.dg/graphite/block-5.c: Same.
3628 * gcc.dg/graphite/block-6.c: Same.
3629 * gfortran.dg/graphite/pr38083.f90: Same.
3630 * gfortran.dg/graphite/block-1.f90: Same.
3631 * gfortran.dg/graphite/block-3.f90: Same.
3632 * gfortran.dg/graphite/pr37852.f90: Same.
3633 * gfortran.dg/graphite/block-4.f90: Same.
3634 * gfortran.dg/graphite/pr37980.f90: Same.
3635 * gfortran.dg/graphite/pr38953.f90: Same.
3636 * gfortran.dg/graphite/pr37857.f90: Same.
2abae5f1
SP
3637 * opts.c: Remove -floop-block from -O2.
3638 * graphite-poly.c: Fail if -floop-block -floop-interchange or
3639 -floop-strip-mine are used.
3640
36412009-03-04 Tobias Grosser <grosser@fim.uni-passau.de>
3642 Sebastian Pop <sebastian.pop@amd.com>
3643
3644 * graphite-clast-to-gimple.c (build_cloog_prog): Unify scattering
3645 dimensions.
3646 * graphite-poly.c (pbb_compare, graphite_sort_pbbs,
3647 graphite_trans_bb_move_loop, graphite_trans_bb_strip_mine,
3648 strip_mine_profitable_p, is_interchange_valid,
3649 graphite_trans_bb_block, graphite_trans_loop_block,
3650 graphite_trans_scop_block): Temporary removed.
3651 (extend_scattering, unify_scattering_dimensions): New.
3652 (print_scattering_function, graphite_read_transforms):
3653 PBB_SCATTERING -> PBB_TRANSFORMED_SCATTERING.
3654 (graphite_generate_scattering_fns): Removed.
3655 (apply_poly_transforms): Cleanup.
3656 (free_poly_bb): Add PBB_SCATTERING -> PBB_TRANSFORMED_SCATTERING.
3657 (schedule_to_scattering): Moved.
3658 (PBB_STATIC_SCHEDULE, PBB_SCATTERING): Removed.
3659 (PBB_ORIGINAL_SCATTERING, PBB_TRANSFORMED_SCATTERING): New.
3660 (pbb_nb_scattering): New.
3661 (SCOP_ENTRY, SCOP_EXIT, SCOP_REGION_BBS, SCOP_DEP_GRAPH, SCOP_PARAMS,
3662 SCOP_LOOP_NEST, SCOP_PARAMS, SCOP_OLDIVS, SCOP_LIVEOUT_RENAMES):
3663 Removed.
3664 * graphite-ppl.c (ppl_insert_dimensions): Extended and renamed from
3665 shift_poly.
3666 (ppl_strip_loop): PBB_SCATTERING -> PBB_TRANSFORMED_SCATTERING.
3667 * graphite-scop-detection.c (dot_all_scops_1): PBB_SCATTERING
3668 -> PBB_TRANSFORMED_SCATTERING.
3669 * graphite-sese-to-poly.c (build_scop_bbs): Remove region.
3670 (build_pbb_scattering_polyhedron): Moved from schedule_to_scattering.
3671 (build_scop_scattering): Renamed from build_scop_canonical_schedules.
3672 (check_poly_representation): Do not return bool.
3673 (graphite_transform_loops): Reformat.
3674 * sese.h (SESE_ENTRY_BB, SESE_EXIT_BB): New.
3675
36762009-03-04 Sebastian Pop <sebastian.pop@amd.com>
3677
3678 * graphite-poly.c (print_pbb_domain, print_pbb, print_scop,
3679 debug_pbb_domain, debug_pbb, debug_scop): New.
3680 * graphite-poly.h (print_pbb_domain, print_pbb, print_scop,
3681 debug_pbb_domain, debug_pbb, debug_scop): Declared.
3682
36832009-03-02 Sebastian Pop <sebastian.pop@amd.com>
3684
3685 PR middle-end/39335
3686 * tree-parloops.c (canonicalize_loop_ivs): Call fold_convert
3687 when the type precision of the induction variable should be
3688 larger than the type precision of nit.
3689 (gen_parallel_loop): Update use of canonicalize_loop_ivs.
3690 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Same.
3691 * tree-flow.h (canonicalize_loop_ivs): Update declaration.
3692
45489e99
SP
3693 * gcc.dg/graphite/pr39335_1.c: New.
3694 * gcc.dg/graphite/pr39335.c: New.
2abae5f1
SP
3695
36962009-03-02 Sebastian Pop <sebastian.pop@amd.com>
3697
3698 * tree-parloops.c (canonicalize_loop_ivs): reduction_list contains
3699 SSA_NAMES not struct reduction_info.
3700
37012009-03-02 Sebastian Pop <sebastian.pop@amd.com>
3702
3703 * sese.c (expand_scalar_variables_expr): Handle ADDR_EXPR.
3704
37052009-02-27 Sebastian Pop <sebastian.pop@amd.com>
3706 Tobias Grosser <grosser@fim.uni-passau.de>
3707
3708 * sese.c (new_sese): Initialize SESE_REDUCTION_LIST.
3709 (free_sese): Free SESE_REDUCTION_LIST.
3710 * sese.h (struct sese): Add field reduction_list.
3711 (SESE_REDUCTION_LIST): New.
3712 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Call
3713 canonicalize_loop_ivs on SESE_REDUCTION_LIST.
3714
37152009-02-27 Sebastian Pop <sebastian.pop@amd.com>
3716 Tobias Grosser <grosser@fim.uni-passau.de>
3717
3718 * tree-flow.h (gather_scalar_reductions): Use struct loop * instead
3719 of loop_p.
3720
37212009-02-27 Sebastian Pop <sebastian.pop@amd.com>
3722 Tobias Grosser <grosser@fim.uni-passau.de>
3723
3724 * tree-parloops.c (struct brli, build_reduction_list_info,
3725 analyze_reduction_list, gather_scalar_reductions): New.
3726 (loop_parallel_p): Build a reduction list containing only
3727 PHI_RESULT SSA_NAMEs: call gather_scalar_reductions.
3728 (gen_parallel_loop): Call the analysis analyze_reduction_list.
3729 (parallelize_loops): Now reduction_list is a htab_t of SSA_NAMEs.
3730 * tree-flow.h (gather_scalar_reductions): Declared.
3731
37322009-02-26 Sebastian Pop <sebastian.pop@amd.com>
3733
3734 PR middle-end/39308
3735 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not call
3736 number_of_iterations_exit from a gcc_assert.
3737
37382009-02-25 Sebastian Pop <sebastian.pop@amd.com>
3739 Jan Sjodin <jan.sjodin@amd.com>
3740
3741 * output.h (graphite_out_file, graphite_in_file): Declared.
3742 * toplev.c (graphite_out_file, graphite_in_file): New.
3743 (init_asm_output): Initialize graphite_in_file and graphite_out_file.
3744 * graphite-clast-to-gimple.c (build_cloog_prog): Read PBB_SCATTERING.
3745 Don't call schedule_to_scattering.
3746 * common.opt (fgraphite-write, fgraphite-read): New.
3747 * graphite-poly.c: Include output.h.
3748 (print_scattering_function, print_scattering_functions,
3749 debug_scattering_function, debug_scattering_functions,
3750 graphite_write_transforms, graphite_read_transforms,
3751 graphite_generate_scattering_fns): New.
3752 (apply_poly_transforms): Do not apply transform if flag_graphite_read.
3753 Call graphite_generate_scattering_fns, graphite_write_transforms,
3754 graphite_read_transforms.
3755 (new_poly_bb): Initialize PBB_SCATTERING.
3756 (free_poly_bb): Free PBB_SCATTERING.
3757 (schedule_to_scattering): Does not return, initialize PBB_SCATTERING.
3758 * graphite-poly.h (struct poly_bb): Add field scattering.
3759 (PBB_SCATTERING): New.
3760 (print_scattering_function, print_scattering_functions,
3761 debug_scattering_function, debug_scattering_functions): Declared.
3762 * graphite-ppl.c (cloog_matrix_to_ppl_constraint): Matrices contain
3763 GMP values, not integers!
3764 (ppl_print_polyhedron_matrix, debug_ppl_polyhedron_matrix,
3765 ppl_read_polyhedron_matrix): New.
3766 * graphite-ppl.h (ppl_print_polyhedron_matrix,
3767 debug_ppl_polyhedron_matrix,
3768 ppl_read_polyhedron_matrix): Declared.
3769 * Makefile.in (graphite-poly.o): Depends on output.h.
3770
37712009-02-23 Sebastian Pop <sebastian.pop@amd.com>
3772 Tobias Grosser <grosser@fim.uni-passau.de>
3773
3774 Revert this change:
3775 * graphite-scop-detection.c (stmt_simple_for_scop_p): Analyze
3776 scalar evolutions in the scop_entry->loop_father.
3777
37782009-02-23 Sebastian Pop <sebastian.pop@amd.com>
3779 Tobias Grosser <grosser@fim.uni-passau.de>
3780
3781 * graphite.h (ref_nb_loops): Remove declaration.
3782 (struct gimple_bb, gimple_bb_p, GBB_BB, GBB_DATA_REFS, GBB_CONDITIONS,
3783 GBB_CONDITION_CASES, GBB_CLOOG_IV_TYPES, gbb_loop, print_gimple_bb,
3784 debug_gbb): Moved to sese.h.
3785 * sese.h: As said.
3786
37872009-02-23 Sebastian Pop <sebastian.pop@amd.com>
3788 Tobias Grosser <grosser@fim.uni-passau.de>
3789
3790 * graphite-data-ref.[ch]: Disable.
3791
37922009-02-23 Sebastian Pop <sebastian.pop@amd.com>
3793 Tobias Grosser <grosser@fim.uni-passau.de>
3794
3795 * graphite-scop-detection.c (stmt_simple_for_scop_p): Analyze
3796 scalar evolutions in the scop_entry->loop_father.
3797
37982009-02-23 Sebastian Pop <sebastian.pop@amd.com>
3799
3800 * graphite-scop-detection.c (nb_reductions_in_loop): Moved here...
3801 (graphite_cannot_represent_loop_niter): Renamed
3802 graphite_cannot_represent_loop. Call nb_reductions_in_loop.
3803 (limit_scops): build_sese_loop_nests does not return a bool.
3804 * graphite-scop-detection.h (nb_reductions_in_loop): Declared.
3805 * sese.c (nb_reductions_in_loop): ... from here.
3806 (graphite_loop_normal_form): ... from here.
3807 (sese_record_loop): Does not fail, so does not return a bool.
3808 (build_sese_loop_nests): Same.
3809 * sese.h (build_sese_loop_nests): Update declaration.
3810 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Moved here...
3811 (build_graphite_loop_normal_form): New.
3812 (gloog): Call build_graphite_loop_normal_form.
3813 * graphite-sese-to-poly.c (build_poly_scop): Don't fail on
3814 build_sese_loop_nests.
3815
45489e99 3816 * gcc.dg/graphite/id-1.c: New.
2abae5f1
SP
3817
38182009-02-23 Sebastian Pop <sebastian.pop@amd.com>
3819 Tobias Grosser <grosser@fim.uni-passau.de>
3820
3821 * graphite-sese-to-poly.c (scan_tree_for_params): Remove REAL_CST.
3822 The SCoP detection fix is sufficient.
3823
38242009-02-21 Sebastian Pop <sebastian.pop@amd.com>
3825
3826 PR tree-optimization/39260
3827 * graphite-scop-detection.c (harmful_stmt_in_bb): Stop a SCoP when
3828 the basic block contains a condition with a real type.
3829 * graphite-sese-to-poly.c (scan_tree_for_params): Handle REAL_CST.
3830
3831 * gcc.dg/graphite/pr39260.c: New.
3832
38332009-02-21 Sebastian Pop <sebastian.pop@amd.com>
3834
3835 * graphite-poly.c: Inlcude params.h.
3836 (graphite_trans_loop_block): Use PARAM_LOOP_BLOCK_TILE_SIZE for
3837 the size of a tile.
3838 * Makefile.in (graphite-poly.o): Depend on PARAMS_H.
3839 * params.def (PARAM_LOOP_BLOCK_TILE_SIZE): Define.
3840
38412009-02-20 Sebastian Pop <sebastian.pop@amd.com>
3842 Tobias Grosser <grosser@fim.uni-passau.de>
3843
3844 * graphite-scop-detection.c (dot_all_scops_1,
3845 dot_all_scops): Moved here.
3846 * graphite-scop-detection.h (dot_all_scops): Declared here.
3847 * graphite.c (graphite_initialize, graphite_finalize): New.
3848 (graphite_transform_loops): Cleaned up.
3849 * sese.c (debug_oldivs): Moved here.
3850 * graphite-poly.c (graphite_apply_transformations): Renamed
3851 apply_poly_transforms.
3852 (debug_loop_vec): Moved here.
3853 * graphite-sese-to-poly.c (build_bb_loops, build_sese_conditions_1,
3854 scop_contains_non_iv_scalar_phi_nodes, build_sese_conditions,
3855 find_scop_parameters, build_scop_iteration_domain,
3856 add_conditions_to_constraints, build_scop_canonical_schedules,
3857 build_scop_data_accesses): Now static.
3858 (build_poly_scop, check_poly_representation): New.
3859
38602009-02-20 Sebastian Pop <sebastian.pop@amd.com>
3861
3862 * graphite.c (graphite_stmt_p, new_gimple_bb, free_gimple_bb,
3863 remove_gbbs_in_scop, free_scops, try_generate_gimple_bb,
3864 build_scop_bbs, ref_nb_loops, compare_prefix_loops,
3865 build_scop_canonical_schedules, build_bb_loops, add_value_to_dim,
3866 scan_tree_for_params_right_scev, scan_tree_for_params_int,
3867 scan_tree_for_params, struct irp_data, dx_record_params,
3868 find_params_in_bb, find_scop_parameters, gbb_from_bb,
3869 build_loop_iteration_domains, add_conditions_to_domain,
3870 phi_node_is_iv, bb_contains_non_iv_scalar_phi_nodes,
3871 scop_contains_non_iv_scalar_phi_nodes, build_sese_conditions_1,
3872 build_sese_conditions, add_conditions_to_constraints,
3873 build_scop_iteration_domain, build_access_matrix_with_af,
3874 build_access_matrix,
3875 build_scop_data_accesses): Moved to graphite-sese-to-poly.c.
3876
3877 * graphite-sese-to-poly.c: New.
3878 * graphite-sese-to-poly.h: New.
3879
3880 * Makefile.in: Add new rule for graphite-sese-to-poly.o.
3881
38822009-02-20 Sebastian Pop <sebastian.pop@amd.com>
3883
3884 * graphite.c: Split graphite code generation to a new file.
3885 (graphite_verify, gmp_cst_to_tree, clast_name_to_gcc,
3886 max_precision_type, clast_to_gcc_expression_red,
3887 clast_to_gcc_expression, gcc_type_for_clast_expr,
3888 gcc_type_for_clast_eq, loop_iv_stack_patch_for_consts,
3889 graphite_translate_clast_equation, graphite_create_guard_cond_expr,
3890 graphite_create_new_guard, clast_get_body_of_loop,
3891 gcc_type_for_cloog_iv, gcc_type_for_iv_of_clast_loop,
3892 graphite_create_new_loop, build_iv_mapping, copy_renames,
3893 translate_clast, find_cloog_iv_in_expr, compute_cloog_iv_types_1,
3894 compute_cloog_iv_types, free_scattering, save_var_name,
3895 initialize_cloog_names, build_scop_context, build_cloog_prog,
3896 set_cloog_options, debug_clast_stmt, scop_to_clast,
3897 print_generated_program, debug_generated_program,
3898 gloog): Moved to graphite-clast-to-gimple.c.
3899
3900 (struct cloog_prog_clast): Moved to graphite-clast-to-gimple.h.
3901
3902 (iv_stack_entry_is_constant, iv_stack_entry_is_iv,
3903 loop_iv_stack_push_iv, loop_iv_stack_insert_constant,
3904 loop_iv_stack_pop, loop_iv_stack_get_iv,
3905 loop_iv_stack_get_iv_from_name, debug_loop_iv_stack,
3906 free_loop_iv_stack, loop_iv_stack_remove_constants,
3907 debug_rename_elt, debug_rename_map_1, debug_rename_map,
3908 rename_map_elt_info, eq_rename_map_elts, debug_ivtype_elt,
3909 debug_ivtype_map_1, debug_ivtype_map, ivtype_map_elt_info,
3910 eq_ivtype_map_elts, sese_add_exit_phis_edge,
3911 sese_add_exit_phis_var, sese_insert_phis_for_liveouts,
3912 get_vdef_before_sese, sese_adjust_vphi,
3913 get_new_name_from_old_name, sese_adjust_phis_for_liveouts,
3914 oldiv_for_loop, rename_variables_in_stmt, is_parameter,
3915 is_iv, expand_scalar_variables_ssa_name,
3916 expand_scalar_variables_expr, expand_scalar_variables_stmt,
3917 expand_scalar_variables, rename_variables, remove_condition,
3918 get_true_edge_from_guard_bb, get_false_edge_from_guard_bb,
3919 add_loop_exit_phis, insert_loop_close_phis, struct igp,
3920 default_liveout_before_guard, add_guard_exit_phis,
3921 insert_guard_phis, register_old_and_new_names,
3922 graphite_copy_stmts_from_block, register_sese_liveout_renames,
3923 copy_bb_and_scalar_dependences, outermost_loop_in_sese,
3924 if_region_set_false_region, create_if_region_on_edge,
3925 move_sese_in_condition): Moved to sese.c.
3926
3927 (nb_loops_around_loop_in_sese, struct ifsese, if_region_entry,
3928 if_region_exit, if_region_get_condition_block,
3929 struct rename_map_elt, new_rename_map_elt, enum iv_stack_entry_kind,
3930 union iv_stack_entry_data_union, struct iv_stack_entry_struct,
3931 iv_stack_entry_p, loop_iv_stack, struct ivtype_map_elt,
3932 ivtype_map_elt, new_ivtype_map_elt,
3933 recompute_all_dominators): Moved to sese.h.
3934
3935 * graphite-clast-to-gimple.c: New.
3936 * graphite-clast-to-gimple.h: New.
3937 * Makefile.in: Add new rule for graphite-clast-to-gimple.o.
3938 * sese.c: Modified as said above.
3939 * sese.h: Same.
3940
39412009-02-20 Sebastian Pop <sebastian.pop@amd.com>
3942
3943 * graphite.c: Split scop detection to a new file.
3944 (enum gbb_type, gbb_type, get_bb_type, struct sd_region_p, sd_region,
3945 move_sd_regions, loop_affine_expr, exclude_component_ref,
3946 is_simple_operand, stmt_simple_for_scop_p, harmful_stmt_in_bb,
3947 graphite_cannot_represent_loop_niter, struct scopdet_info,
3948 scopdet_basic_block_info, build_scops_1, bb_in_sd_region,
3949 find_single_entry_edge, find_single_exit_edge,
3950 create_single_entry_edge, sd_region_without_exit,
3951 create_single_exit_edge, unmark_exit_edges, mark_exit_edges,
3952 create_sese_edges, build_graphite_scops, limit_scops, build_scops):
3953 Moved to graphite-scop-detection.c.
3954
3955 * graphite-scop-detection.c: New.
3956 * graphite-scop-detection.h: New.
3957 * Makefile.in: Add new rule for graphite-scop-detection.o.
3958
3959 * sese.c: Include tree-chrec.h, tree-data-ref.h, and
3960 tree-scalar-evolution.h.
3961 (nb_reductions_in_loop, graphite_loop_normal_form, sese_record_loop,
3962 build_sese_loop_nests): Moved here from graphite.c.
3963 (param_index): Renamed parameter_index_in_region.
3964
39652009-02-18 Tobias Grosser <grosser@fim.uni-passau.de>
3966 Sebastian Pop <sebastian.pop@amd.com>
3967
3968 * gcc.dg/graphite/block-0.c: Expected to fail now.
3969 * gcc.dg/graphite/block-1.c: Same.
3970 * gcc.dg/graphite/block-5.c: Same.
3971 * gcc.dg/graphite/block-6.c: Same.
3972
39732009-02-18 Tobias Grosser <grosser@fim.uni-passau.de>
3974 Sebastian Pop <sebastian.pop@amd.com>
3975
3976 * graphite.h: Separate from graphite_bb_p the polyhedral
3977 representation in poly_bb_p and the GCC specifics in gimple_bb_p.
3978 (struct data_dependence_polyhedron, RDGE_DDP, ddp_p): Moved to
3979 graphite-data-ref.h.
3980 (struct poly_bb, PBB_SCOP, PBB_STATIC_SCHEDULE, PBB_DOMAIN,
3981 PBB_BLACK_BOX, PBB_LOOPS, pbb_nb_loops, pbb_loop_at_index,
3982 pbb_loop_index, struct scop, SCOP_BBS, SCOP_REGION, SCOP_ENTRY,
3983 SCOP_EXIT, SCOP_REGION_BBS, SCOP_DEP_GRAPH, SCOP_PARAMS,
3984 SCOP_LOOP_NEST, SCOP_PARAMS, SCOP_OLDIVS, SCOP_LIVEOUT_RENAMES,
3985 scop_nb_params): Moved to graphite-poly.h.
3986 * graphite-data-ref.c: Same.
3987 * graphite-data-ref.h: New.
3988 * graphite.c: Same.
3989 (pbb_compare, graphite_sort_pbbs, graphite_trans_bb_move_loop,
3990 graphite_trans_bb_strip_mine, strip_mine_profitable_p,
3991 is_interchange_valid, graphite_trans_bb_block,
3992 graphite_trans_loop_block, scop_max_loop_depth,
3993 graphite_trans_scop_block, graphite_apply_transformations,
3994 new_poly_bb, free_poly_bb, new_scop, free_scop): Moved to
3995 graphite-poly.c.
3996 * graphite-poly.h: New.
3997 * graphite-poly.c: New.
3998 * Makefile.in (OBJS-common): Add graphite-poly.o.
3999 (graphite-poly.o): New rule.
4000 * tree-data-ref.h (struct data_reference): Remove unused scop field.
4001 (DR_SCOP): Removed.
4002
40032009-02-18 Sebastian Pop <sebastian.pop@amd.com>
4004 Tobias Grosser <grosser@fim.uni-passau.de>
4005
4006 * graphite.c: Replace gb -> gbb.
4007 * graphite.h: Same.
4008 * graphite-data-ref.c: Same.
4009
40102009-02-18 Sebastian Pop <sebastian.pop@amd.com>
4011 Tobias Grosser <grosser@fim.uni-passau.de>
4012
4013 * Makefile.in (OBJS-commmon): Add sese.o.
4014 (sese.o): New.
4015 (graphite.o): Add sese.h.
4016 * graphite.c (bb_in_ss_p, loop_in_sese_p,
4017 sese_build_livein_liveouts_use, sese_build_livein_liveouts_bb,
4018 sese_build_livein_liveouts, register_bb_in_sese, new_sese, free_sese):
4019 Move to sese.
4020 (block_before_scop): Add missing return.
4021 (new_scop, free_scop): Remove SESE data structures.
4022 (scop_record_loop, scan_tree_for_params, find_params_in_bb,
4023 find_scop_parameters, build_loop_iteration_domains,
4024 add_conditions_to_domain, register_scop_liveout_renames,
4025 copy_bb_and_scalar_dependences): Scop -> SESE.
4026
4027 (add_conditions_to_domain): SCoP -> SESE and remove check
4028 (scop_contains_non_iv_scalar_phi_nodes): New.
4029 (build_scop_conditions_1, build_scop_conditions): Remove check for
4030 non iv scalar phi nodes.
4031 (print_scop_statistics): New.
4032 (graphite_transform_loops): Cleanup.
4033
4034 * graphite.h: Move to sese & cleanup.
4035 * sese.c: New.
4036 * sese.h: New.
4037
40382009-02-16 Sebastian Pop <sebastian.pop@amd.com>
4039 Tobias Grosser <grosser@fim.uni-passau.de>
4040
4041 * graphite.c (build_scop_conditions_1): Conditions are only
4042 at the end of a basic block.
4043
40442009-02-16 Sebastian Pop <sebastian.pop@amd.com>
4045 Tobias Grosser <grosser@fim.uni-passau>
4046
4047 * graphite.h (struct graphite_bb): Remove compressed_alpha_matrix
4048 field.
4049 (GBB_ALPHA): Removed.
4050
40512009-02-16 Sebastian Pop <sebastian.pop@amd.com>
4052 Tobias Grosser <grosser@fim.uni-passau.de>
4053
4054 * graphite-data-ref.c (graphite_test_dependence): Don't use
4055 GBB_DYNAMIC_SCHEDULE.
4056 * graphite.c (new_graphite_bb): Same.
4057 (free_graphite_bb): Same.
4058 (build_scop_dynamic_schedules): Removed.
4059 (graphite_transform_loops): Don't call it.
4060 * graphite.h (struct graphite_bb): Remove dynamic_schedule field.
4061 (GBB_DYNAMIC_SCHEDULE): Removed.
4062
40632009-02-16 Sebastian Pop <sebastian.pop@amd.com>
4064 Tobias Grosser <grosser@fim.uni-passau.de>
4065
4066 * graphite.c (schedule_to_scattering): Don't use CloogMatrix.
4067 (print_graphite_bb): Same.
4068 (build_cloog_prog): Same.
4069
40702009-02-16 Sebastian Pop <sebastian.pop@amd.com>
4071 Tobias Grosser <grosser@fim.uni-passau.de>
4072
4073 * graphite.c (build_cloog_prog): Don't use CloogMatrix.
4074
40752009-02-16 Sebastian Pop <sebastian.pop@amd.com>
4076 Tobias Grosser <grosser@fim.uni-passau.de>
4077
4078 * graphite.c (build_scop_context): Don't use CloogMatrix.
4079 * graphite-ppl.c (new_Cloog_Domain_from_ppl_Polyhedron): New.
4080 * graphite-ppl.h (new_Cloog_Domain_from_ppl_Polyhedron): Declared.
4081
40822009-02-16 Sebastian Pop <sebastian.pop@amd.com>
4083 Tobias Grosser <grosser@fim.uni-passau.de>
4084
4085 * graphite.h (struct scop): Move params, old_ivs, loops, loop_nest,
4086 liveout_renames, add_params fields...
4087 (struct sese): ... here.
4088 (SESE_PARAMS, SESE_LOOPS, SESE_LOOP_NEST, SESE_ADD_PARAMS,
4089 SESE_PARAMS, SESE_OLDIVS, SESE_LIVEOUT_RENAMES): New.
4090
40912009-02-16 Sebastian Pop <sebastian.pop@amd.com>
4092 Tobias Grosser <grosser@fim.uni-passau.de>
4093
4094 * graphite.c (print_scop): Do not print the CLooG program.
4095 (new_scop, free_scop, initialize_cloog_names, build_scop_context,
4096 build_cloog_prog, gloog): Don't use SCOP_PROG.
4097 (find_transform): Renamed scop_to_clast.
4098 (print_generated_program, debug_generated_program): New.
4099 (graphite_transform_loops): Adapt to new interface.
4100 * graphite.h (struct scop): Remove program field.
4101 (SCOP_PROG): Removed.
4102 (print_generated_program, debug_generated_program): Declared.
4103
41042009-02-16 Sebastian Pop <sebastian.pop@amd.com>
4105
4106 * graphite-data-ref.c (schedule_precedes_p, schedule_same_p): New.
4107 (statement_precedes_p): Use schedule_same_p and schedule_precedes_p.
4108 * graphite.c (gbb_compare, schedule_to_scattering, print_graphite_bb,
4109 free_graphite_bb, build_scop_canonical_schedules,
4110 graphite_trans_bb_strip_mine, graphite_trans_scop_block): Static
4111 schedules are now represented using a ppl_Linear_Expression_t.
4112 * graphite.h (struct graphite_bb): Same.
4113 * graphite-ppl.c (ppl_lexico_compare_linear_expressions): New.
4114 * graphite-ppl.h (ppl_lexico_compare_linear_expressions): Declared.
4115
41162009-02-15 Sebastian Pop <sebastian.pop@amd.com>
4117
4118 * graphite.c: Free local memory.
4119 * graphite-ppl.c: Same.
4120
41212009-02-15 Sebastian Pop <sebastian.pop@amd.com>
4122
4123 * graphite.c (const_column_index, get_first_matching_sign_row_index,
4124 get_lower_bound_row, get_upper_bound_row, copy_constraint,
4125 swap_constraint_variables, scale_constraint_variable): Removed.
4126 (graphite_trans_bb_strip_mine): Remove pong.
4127 * graphite-ppl.c: Include missing header files.
4128 (set_inhomogeneous, set_coef, shift_poly, ppl_strip_loop): New.
4129 * graphite-ppl.h (ppl_strip_loop): Declared.
4130 * Makefile.in (graphite-ppl.o): Adjust dependences.
4131
41322009-02-14 Sebastian Pop <sebastian.pop@amd.com>
4133
4134 * graphite.c (build_loop_iteration_domains): Remove ping pong.
4135 (build_scop_iteration_domain): Same.
4136
41372009-02-13 Sebastian Pop <sebastian.pop@amd.com>
4138
4139 * graphite.c (scan_tree_for_params, add_conditions_to_domain): Remove
4140 ping pong.
4141 (add_value_to_dim, scan_tree_for_params_right_scev,
4142 scan_tree_for_params_int): New.
4143 * graphite-ppl.c (oppose_constraint): New.
4144 (insert_constraint_into_matrix): Implement missing cases.
4145 * graphite-ppl.h (insert_constraint_into_matrix): Declared.
4146
41472009-02-13 Sebastian Pop <sebastian.pop@amd.com>
4148
4149 * graphite.c (graphite_trans_bb_move_loop): Remove ping pong,
4150 use ppl_move_dimension.
4151
41522009-02-12 Sebastian Pop <sebastian.pop@amd.com>
4153
4154 * graphite-data-ref.c: Domains are now ppl_Polyhedra_t.
4155 * graphite.c: Same.
4156 * graphite.h: Same.
4157 * graphite-ppl.c: Same.
4158 * graphite-ppl.h: Same.
4159
41602009-02-12 Sebastian Pop <sebastian.pop@amd.com>
4161
4162 Revert last 3 commits.
4163
41642009-02-10 Sebastian Pop <sebastian.pop@amd.com>
4165
4166 * graphite.c (scan_tree_for_params, add_conditions_to_domain): Remove
4167 ping pong.
4168 (add_value_to_dim, scan_tree_for_params_right_scev,
4169 scan_tree_for_params_int): New.
4170 * graphite-ppl.c (oppose_constraint): New.
4171 (insert_constraint_into_matrix): Implement missing cases.
4172 * graphite-ppl.h (insert_constraint_into_matrix): Declared.
4173
41742009-02-10 Sebastian Pop <sebastian.pop@amd.com>
4175
4176 * graphite.c (graphite_trans_bb_move_loop): Remove unused variables.
4177
41782009-02-10 Sebastian Pop <sebastian.pop@amd.com>
4179 Tobias Grosser <grosser@fim.uni-passau.de>
4180
4181 * graphite.c (graphite_trans_bb_move_loop): Remove ping pong,
4182 use ppl_move_dimension.
4183 * graphite-ppl.c (ppl_move_dimension): New.
4184 * graphite-ppl.h (ppl_move_dimension): Declared.
4185
41862009-02-10 Sebastian Pop <sebastian.pop@amd.com>
4187
4188 * graphite.c: Do not include cloog/cloog.h.
4189 (print_graphite_bb): Remove ping pong, call PPL print function.
4190
41912009-02-10 Tobias Grosser <grosser@fim.uni-passau.de>
4192
4193 * Makefile.in (OBJS-common): Add graphite-ppl.o.
4194 (graphite.o): Add dependence on graphite-ppl.h.
4195 (graphite-ppl.o): New.
4196 (graphite-data-ref.c): Ping pong between PPL data structures
4197 and matrices.
4198 * graphite-ppl.c: New.
4199 * graphite-ppl.h: New.
4200 * graphite.c: Include graphite-ppl.h.
4201 (print_graphite_bb, add_conditions_to_domain, build_cloog_prog,
4202 graphite_trans_bb_move_loop, graphite_trans_bb_strip_mine):
4203 Ping pong between PPL data structures and matrices.
4204 (new_graphite_bb): Create a PPL constraint system.
4205 Call ppl_delete_Constraint_System instead of cloog_matrix_free.
4206 (build_loop_iteration_domains): Use PPL functions.
4207 * graphite.h: Include graphite-ppl.h. Fix comments.
4208 (graphite_bb): Use a ppl_Constraint_System_t instead of
4209 CloogMatrix for representing the domain.
4210 (scop): Remove static_schedule.
4211 (gbb_nb_loops): Ping pong between PPL data structures and matrices.
4212
42132009-02-06 Sebastian Pop <sebastian.pop@amd.com>
4214
4215 * graphite.c: Fix some comments.
4216
42172009-02-05 Sebastian Pop <sebastian.pop@amd.com>
4218
4219 PR middle-end/38953
4220 * graphite.c (if_region_set_false_region): After moving a region
4221 in the false branch of a condition, remove the empty dummy
4222 basic block.
4223 (gloog): Remove wrong fix for PR38953.
4224
42252009-02-03 Tobias Grosser <grosser@fim.uni-passau.de>
4226
4227 * graphite.c (bb_in_sese_p, sese_build_livein_liveouts_use,
4228 sese_build_livein_liveouts_bb, sese_build_livein_liveouts,
4229 register_bb_in_sese, new_sese, free_sese): Moved.
4230 (dot_scop_1, build_scop_loop_nests, build_loop_iteration_domains,
4231 outermost_loop_in_scop, build_scop_iteration_domain,
4232 expand_scalar_variables_ssa_name, get_vdef_before_scop,
4233 limit_scops): Use bb_in_sese_p instead of bb_in_scop_p.
4234 Use loop_in_sese_p instead of loop_in_scop_p.
4235 (new_graphite_bb, new_scop, gloog): Do not initialize SCOP_BBS_B.
4236 (free_scop): Do not free SCOP_BBS_B.
4237 (nb_loops_around_loop_in_scop, nb_loops_around_gb,
4238 ref_nb_loops): Moved here...
4239 * graphite.h (ref_nb_loops): ... from here.
4240 (struct scop): Remove bbs_b bitmap.
4241 (SCOP_BBS_B, bb_in_scop_p, loop_in_scop_p): Removed.
45489e99 4242 * gcc.dg/graphite/scop-19.c: New
2abae5f1
SP
4243
42442009-02-03 Tobias Grosser <grosser@fim.uni-passau.de>
4245
4246 * graphite.c (scopdet_basic_block_info): Fix bug in scop
4247 detection.
4248
42492009-01-30 Tobias Grosser <grosser@fim.uni-passau.de>
4250
4251 * graphite.c (new_loop_to_cloog_loop_str, hash_loop_to_cloog_loop,
4252 eq_loop_to_cloog_loop): Remove.
4253 (new_scop, free_scop): Remove SCOP_LOOP2CLOOG_LOOP.
4254 * graphite.h (struct scop): Remove loop2cloog_loop.
4255 (loop_domain_dim, loop_iteration_vector_dim): Remove.
4256
42572009-01-30 Tobias Grosser <grosser@fim.uni-passau.de>
4258
4259 * opts.c (decode_options): Only add graphite options to O2
4260 if we compile with graphite enabled.
4261
42622009-01-26 Sebastian Pop <sebastian.pop@amd.com>
4263
4264 * Merge from mainline (r143163:143684).
4265
42662009-01-26 Sebastian Pop <sebastian.pop@amd.com>
4267
4268 * graphite.c (debug_value): Removed.
4269 * graphite.h (debug_value): Removed.
4270
42712009-01-23 Sebastian Pop <sebastian.pop@amd.com>
4272
4273 * passes.c (init_optimization_passes): Do not call pass_copy_prop
4274 after graphite: pass_copy_prop does not maintain a proper loop closed
4275 SSA form. pass_copy_prop should be fixed.
4276
42772009-01-23 Sebastian Pop <sebastian.pop@amd.com>
4278
4279 * graphite.c (scop_adjust_phis_for_liveouts): Fix warning.
4280
42812009-01-23 Sebastian Pop <sebastian.pop@amd.com>
4282
4283 * graphite.c (graphite_verify): Add a call to verify_loop_closed_ssa.
4284 (gloog): Split the exit of the scop when the scop exit is a loop exit.
4285 (graphite_transform_loops): Only call cleanup_tree_cfg if gloog
4286 changed the CFG.
4287
42882009-01-20 Sebastian Pop <sebastian.pop@amd.com>
4289
4290 * graphite.c (gloog): Return true when code gen succeeded.
4291 (graphite_transform_loops): Do not call cleanup_tree_cfg if
4292 the code of the function did not changed. After cleanup_tree_cfg
4293 call rewrite_into_loop_closed_ssa to maintain the loop closed ssa
4294 form.
4295
42962009-01-19 Sebastian Pop <sebastian.pop@amd.com>
4297
4298 * graphite.c (stmt_simple_for_scop_p): Also handle cases when
4299 gimple_call_lhs is NULL.
4300
43012009-01-16 Sebastian Pop <sebastian.pop@amd.com>
4302 Tobias Grosser <tobi.grosser@amd.com>
4303
4304 * graphite.c (graphite_trans_scop_block): Do not block single
4305 nested loops.
4306
43072009-01-15 Sebastian Pop <sebastian.pop@amd.com>
4308 Tobias Grosser <tobi.grosser@amd.com>
4309
4310 * graphite.c (build_scop_canonical_schedules): Start schedules at
4311 zero.
4312
43132009-01-15 Sebastian Pop <sebastian.pop@amd.com>
4314 Tobias Grosser <tobi.grosser@amd.com>
4315
4316 * graphite.c (compare_prefix_loops): New.
4317 (build_scop_canonical_schedules): Rewritten.
4318 (graphite_transform_loops): Move build_scop_canonical_schedules
4319 after build_scop_iteration_domain.
4320
43212009-01-14 Sebastian Pop <sebastian.pop@amd.com>
4322 Tobias Grosser <tobi.grosser@amd.com>
4323
4324 * graphite.c (add_conditions_to_domain): Add the loops to
4325 the dimension of the iteration domain. Do copy the domain
4326 only when it exists.
4327 (build_scop_conditions_1): Do not call add_conditions_to_domain.
4328 (add_conditions_to_constraints): New.
4329 (can_generate_code_stmt, can_generate_code): Removed.
4330 (gloog): Do not call can_generate_code.
4331 (graphite_transform_loops): Call add_conditions_to_constraints
4332 after building the iteration domain.
4333
43342009-01-14 Sebastian Pop <sebastian.pop@amd.com>
4335 Tobias Grosser <tobi.grosser@amd.com>
4336 Jan Sjodin <jan.sjodin@amd.com>
4337
4338 * graphite.c (scan_tree_for_params): On substractions negate
4339 all the coefficients of the term.
4340 (clast_to_gcc_expression_red): New. Handle reduction expressions
4341 of more than two operands.
4342 (clast_to_gcc_expression): Call clast_to_gcc_expression_red.
4343 (get_vdef_before_scop): Handle also the case of default definitions.
4344
43452009-01-14 Sebastian Pop <sebastian.pop@amd.com>
4346
4347 PR middle-end/38431
4348 * graphite.c (get_vdef_before_scop, scop_adjust_vphi): New.
4349 (scop_adjust_phis_for_liveouts): Call scop_adjust_vphi.
4350 (gloog): Do not call cleanup_tree_cfg.
4351 (graphite_transform_loops): Call cleanup_tree_cfg after all
4352 scops have been code generated.
4353
43542009-01-13 Sebastian Pop <sebastian.pop@amd.com>
4355
4356 * passes.c (init_optimization_passes): Schedule after
4357 graphite transforms pass_copy_prop, pass_dce_loop and pass_lim.
4358
43592009-01-13 Sebastian Pop <sebastian.pop@amd.com>
4360
4361 * graphite.c (expand_scalar_variables_stmt): Do not pass loop_p.
4362 Fix comment.
4363 (expand_scalar_variables_ssa_name): Do not pass loop_p. Fix comment.
4364 Set the type of an expression to the type of its assign statement.
4365 (expand_scalar_variables_expr): Do not pass loop_p.
4366 Fix comment. Stop recursion on tcc_constant or tcc_declaration.
4367 (copy_bb_and_scalar_dependences): Do not pass loop_p.
4368 (translate_clast): Update call to copy_bb_and_scalar_dependences.
4369
43702009-01-11 Sebastian Pop <sebastian.pop@amd.com>
4371
4372 * graphite.c (expand_scalar_variables_ssa_name): Set the type of
4373 an expression to the gimple_expr_type of its assign statement.
4374 (expand_scalar_variables_expr): Stop recursion on tcc_constant
4375 or tcc_declaration.
4376
43772009-01-11 Sebastian Pop <sebastian.pop@amd.com>
4378
4379 PR tree-optimization/38786
45489e99 4380 * gcc.dg/graphite/pr38786.c: New.
2abae5f1
SP
4381 * graphite.c (expand_scalar_variables_ssa_name): New, outlined from
4382 the SSA_NAME case of expand_scalar_variables_expr.
4383 (expand_scalar_variables_expr): Also gather the scalar computation
4384 used to index the memory access.
4385 (expand_scalar_variables_stmt): Pass to expand_scalar_variables_expr
4386 the gimple_stmt_iterator where it inserts new code.
4387
43882009-01-10 Sebastian Pop <sebastian.pop@amd.com>
4389
45489e99 4390 * gcc.dg/graphite/block-3.c: Fix compile error on 32bit.
2abae5f1
SP
4391
43922009-01-10 Sebastian Pop <sebastian.pop@amd.com>
4393
4394 * opts.c (decode_options): Enable flag_graphite_identity and
4395 flag_loop_block in -O2 and above.
4396
43972009-01-08 Sebastian Pop <sebastian.pop@amd.com>
4398
4399 * libjava/classpath/lib/gnu/java/awt/peer/gtk/GtkMouseInfoPeer.class:
4400 Fix merge problem: replace with the file from trunk.
4401
44022009-01-08 Sebastian Pop <sebastian.pop@amd.com>
4403
4404 * Merge from mainline (r141727:143163).
4405
44062009-01-07 Sebastian Pop <sebastian.pop@amd.com>
4407 Jan Sjodin <jan.sjodin@amd.com>
4408
4409 PR tree-optimization/38559
45489e99 4410 * gcc.dg/graphite/pr38559.c: New.
2abae5f1
SP
4411
4412 * graphite.c (debug_value, copy_constraint,
4413 swap_constraint_variables, scale_constraint_variable, ): New.
4414 (get_lower_bound, get_upper_bound): Removed.
4415 (graphite_trans_bb_strip_mine): Clean up this code that works
4416 only for constant number of iterations. Fully copy upper and
4417 lower bound constraints, not only the constant part of them.
4418 * graphite.h (debug_value): Declared.
4419
44202009-01-06 Jan Sjodin <jan.sjodin@amd.com>
4421
4422 PR tree-optimization/38492
4423 PR tree-optimization/38498
4424 * tree-check.c (operator_is_linear, scev_is_linear_expression): New.
4425 * tree-chrec.h (scev_is_linear_expression): Declared.
4426 * graphite.c (graphite_cannot_represent_loop_niter): New.
4427 (scopdet_basic_block_info): Call graphite_cannot_represent_loop_niter.
4428 (graphite_loop_normal_form): Use gcc_assert.
4429 (scan_tree_for_params): Use CASE_CONVERT.
4430 (phi_node_is_iv, bb_contains_non_iv_scalar_phi_nodes): New.
4431 (build_scop_conditions_1): Call bb_contains_non_iv_scalar_phi_nodes.
4432 Use gcc_assert. Discard scops that contain unhandled cases.
4433 (build_scop_conditions): Return a boolean status for unhandled cases.
4434 (strip_mine_profitable_p): Print the loop number, not its depth.
4435 (is_interchange_valid): Pass the depth of the loop nest, don't
4436 recompute it wrongly.
4437 (graphite_trans_bb_block): Same.
4438 (graphite_trans_bb_block): Print tentative of loop blocking.
4439 (graphite_trans_scop_block): Do not print that the loop has been
4440 blocked.
4441 (graphite_transform_loops): Do not handle scops that contain condition
4442 scalar phi nodes.
4443
45489e99 4444 * gcc.dg/graphite/pr38500.c: Fixed warning as committed
2abae5f1 4445 in trunk.
45489e99
SP
4446 * gcc.dg/graphite/block-0.c: Update test.
4447 * gcc.dg/graphite/block-1.c: Same.
4448 * gcc.dg/graphite/block-2.c: Remove xfail and test for
2abae5f1 4449 blocking.
45489e99
SP
4450 * gcc.dg/graphite/block-4.c: Remove test for strip mine.
4451 * gcc.dg/graphite/block-3.c: New.
4452 * gcc.dg/graphite/pr38498.c: New.
2abae5f1
SP
4453
44542008-12-22 Harsha Jagasia <harsha.jagasia@amd.com>
4455
4456 PR tree-optimization/38510
4457 * gcc.dg/graphite/pr38510.c: New.
4458 * graphite.c (recompute_all_dominators): Call mark_irreducible_loops.
4459 (translate_clast): Call recompute_all_dominators before
4460 graphite_verify.
4461 (gloog): Call recompute_all_dominators before graphite_verify.
4462
44632008-12-12 Sebastian Pop <sebastian.pop@amd.com>
4464
4465 PR tree-optimization/38492
4466 * graphite.c (rename_map_elt, debug_rename_elt,
4467 debug_rename_map_1, debug_rename_map, new_rename_map_elt,
4468 rename_map_elt_info, eq_rename_map_elts,
4469 get_new_name_from_old_name, bb_in_sese_p): Moved around.
4470 (sese_find_uses_to_rename_use): Renamed sese_build_livein_liveouts_use.
4471 (sese_find_uses_to_rename_bb): Renamed sese_build_livein_liveouts_bb.
4472 (sese_build_livein_liveouts): New.
4473 (new_sese, free_sese): New.
4474 (new_scop): Call new_sese.
4475 (free_scop): Call free_sese.
4476 (rename_variables_from_edge, rename_phis_end_scop): Removed.
4477 (register_old_new_names): Renamed register_old_and_new_names.
4478 (register_scop_liveout_renames, add_loop_exit_phis,
4479 insert_loop_close_phis, struct igp,
4480 default_liveout_before_guard, add_guard_exit_phis,
4481 insert_guard_phis, copy_renames): New.
4482 (translate_clast): Call insert_loop_close_phis and insert_guard_phis.
4483 (sese_add_exit_phis_edge): Renamed scop_add_exit_phis_edge.
4484 (rewrite_into_sese_closed_ssa): Renamed scop_insert_phis_for_liveouts.
4485 (scop_adjust_phis_for_liveouts): New.
4486 (gloog): Call scop_adjust_phis_for_liveouts.
4487
4488 * graphite.h (struct sese): Documented. Added fields liveout,
4489 num_ver and livein.
4490 (SESE_LIVEOUT, SESE_LIVEIN, SESE_LIVEIN_VER, SESE_NUM_VER): New.
4491 (new_sese, free_sese, sese_build_livein_liveouts): Declared.
4492 (struct scop): Added field liveout_renames.
4493 (SCOP_LIVEOUT_RENAMES): New.
4494
44952008-12-11 Sebastian Pop <sebastian.pop@amd.com>
4496
4497 PR tree-optimization/38409
4498 * gcc.dg/graphite/pr38409.c: New.
4499 * graphite.c (nb_reductions_in_loop): Use simple_iv.
4500
45012008-12-11 Sebastian Pop <sebastian.pop@amd.com>
4502
4503 * graphite.c (gcc_type_for_cloog_iv): By default return
4504 integer_type_node.
4505 (graphite_create_new_loop): Don't fold_convert the already
4506 fold_convert-ed expression.
4507
45082008-12-11 Harsha Jagasia <harsha.jagasia@amd.com>
4509
4510 PR tree-optimization/38446
4511 * gcc.dg/graphite/pr38446.c: New.
4512 * graphite.c (register_bb_in_sese): New.
4513 (bb_in_sese_p): Check if bb belongs to sese region by explicitly
4514 looking at the bbs in the region.
4515 * graphite.h (sese): Add region_basic_blocks pointer set to
4516 structure and initialize at the time of defining new scop.
4517
45182008-12-11 Tobias Grosser <grosser@fim.uni-passau.de>
4519
4520 * graphite.c (new_graphite_bb): Initialize GBB_STATIC_SCHEDULE.
4521 (find_params_in_bb): Do not free data refs.
4522 (free_graphite_bb): Add FIXME on disabled free_data_refs.
4523
45242008-12-11 Sebastian Pop <sebastian.pop@amd.com>
4525
45489e99
SP
4526 * gcc.dg/graphite/scop-16.c: Test only scop specific info.
4527 * gcc.dg/graphite/scop-17.c: Same.
4528 * gcc.dg/graphite/block-5.c: New.
4529 * gcc.dg/graphite/block-6.c: New.
4530 * gcc.dg/graphite/pr37485.c: Clean dump file after.
4531 * gcc.dg/graphite/pr37684.c: Same.
4532 * gcc.dg/graphite/block-2.c: Same.
2abae5f1
SP
4533
4534 * graphite.c (struct ivtype_map_elt): New.
4535 (debug_ivtype_elt, debug_ivtype_map_1, debug_ivtype_map,
4536 new_ivtype_map_elt, ivtype_map_elt_info, eq_ivtype_map_elts,
4537 gcc_type_for_cloog_iv): New.
4538 (loop_iv_stack_patch_for_consts): Use the type of the induction
4539 variable from the original loop, except for the automatically
4540 generated loops, i.e., in the case of a strip-mined loop, in
4541 which case there is no original loop: in that case just use
4542 integer_type_node.
4543 (new_graphite_bb): Initialize GBB_CLOOG_IV_TYPES.
4544 (free_graphite_bb): Free GBB_CLOOG_IV_TYPES.
4545 (clast_name_to_gcc): Accept params to be NULL.
4546 (clast_to_gcc_expression): Take an extra parameter for the type.
4547 Convert to that type all the expressions built by this function.
4548 (gcc_type_for_clast_expr, gcc_type_for_clast_eq): New.
4549 (graphite_translate_clast_equation): Compute the type of the
4550 clast_equation before translating its LHS and RHS.
4551 (clast_get_body_of_loop, gcc_type_for_iv_of_clast_loop): New.
4552 (graphite_create_new_loop): Compute the type of the induction
4553 variable before translating the lower and upper bounds and before
4554 creating the induction variable.
4555 (rename_variables_from_edge, rename_phis_end_scop): New.
4556 (copy_bb_and_scalar_dependences): Call rename_phis_end_scop.
4557 (sese_add_exit_phis_edge): Do not use integer_zero_node.
4558 (find_cloog_iv_in_expr, compute_cloog_iv_types_1,
4559 compute_cloog_iv_types): New.
4560 (gloog): Call compute_cloog_iv_types before starting the
4561 translation of the clast.
4562
4563 * graphite.h (struct graphite_bb): New field cloog_iv_types.
4564 (GBB_CLOOG_IV_TYPES): New.
4565 (debug_ivtype_map): Declared.
4566 (oldiv_for_loop): New.
4567
45682008-12-10 Tobias Grosser <grosser@fim.uni-passau.de>
4569
4570 PR middle-end/38459
4571 * graphite.c (new_scop): Initialize SCOP_ADD_PARAMS.
4572 (param_index): Assert if parameter is not know after parameter
4573 detection.
4574 (find_params_in_bb): Detect params directly in GBB_CONDITIONS.
4575 (find_scop_parameters): Mark, that we have finished parameter
4576 detection.
4577 (graphite_transform_loops): Move condition detection before parameter
4578 detection.
4579 * graphite.h (struct scop): Add SCOP_ADD_PARAMS.
45489e99 4580 * gfortran.dg/graphite/pr38459.f90: New.
2abae5f1
SP
4581
45822008-12-09 Tobias Grosser <grosser@fim.uni-passau.de>
4583
4584 * graphite.c (graphite_transform_loops): Always call find_transform ()
4585 in ENABLE_CHECKING. So we test these code paths, even if we do not
4586 generate code.
4587
45882008-12-09 Tobias Grosser <grosser@fim.uni-passau.de>
4589
4590 * graphite.c (print_graphite_bb): Fix printing to file != dump_file.
4591 (print_scop): Ditto.
4592
45932008-12-08 Tobias Grosser <grosser@fim.uni-passau.de>
4594
4595 PR middle-end/38084
45489e99 4596 Fix gfortran.dg/graphite/id-3.f90.
2abae5f1
SP
4597 * graphite.c (scopdet_basic_block_info): Fix bug that found some
4598 regions more than once.
4599
46002008-12-03 Sebastian Pop <sebastian.pop@amd.com>
4601
45489e99 4602 Fix gfortran.dg/graphite/id-4.f90.
2abae5f1
SP
4603 * graphite.c (scan_tree_for_params): Do not compute the multiplicand
4604 when not needed.
4605
46062008-12-03 Sebastian Pop <sebastian.pop@amd.com>
4607
45489e99 4608 Fix gfortran.dg/graphite/id-1.f90.
2abae5f1
SP
4609 * graphite.c (gmp_cst_to_tree): Pass the type in parameter.
4610 (loop_iv_stack_patch_for_consts): Update use of gmp_cst_to_tree.
4611 (max_precision_type): New.
4612 (value_clast): Removed.
4613 (clast_to_gcc_expression): Be more careful to types of expressions.
4614 Use max_precision_type and update use of gmp_cst_to_tree.
4615 (graphite_translate_clast_equation): Use max_precision_type.
4616 (graphite_create_guard_cond_expr): Do not use integer_type_node,
4617 use the type of the condition.
4618 (graphite_create_new_loop): Do not use integer_type_node, use the
4619 max_precision_type of lb and ub.
4620
46212008-12-03 Sebastian Pop <sebastian.pop@amd.com>
4622
4623 * graphite.c (build_scops_1): Initialize open_scop.exit
4624 and sinfo.last.
4625
46262008-12-02 Sebastian Pop <sebastian.pop@amd.com>
4627
45489e99
SP
4628 * gcc.dg/graphite/pr38084.c: New.
4629 * gfortran.dg/graphite/id-1.f90: New.
4630 * gfortran.dg/graphite/id-2.f90: New.
4631 * gfortran.dg/graphite/id-3.f90: New.
4632 * gfortran.dg/graphite/id-4.f90: New.
4633 * gfortran.dg/graphite/pr37857.f90: New.
2abae5f1
SP
4634
46352008-12-02 Sebastian Pop <sebastian.pop@amd.com>
4636 Jan Sjodin <jan.sjodin@amd.com>
4637 Harsha Jagasia <harsha.jagasia@amd.com>
4638
4639 PR middle-end/37852
4640 PR middle-end/37883
4641 PR middle-end/37928
4642 PR middle-end/37980
4643 PR middle-end/38038
4644 PR middle-end/38039
4645 PR middle-end/38073
4646 PR middle-end/38083
4647 PR middle-end/38125
4648
45489e99
SP
4649 * gcc.dg/graphite/pr38073.c: New.
4650 * gcc.dg/graphite/pr37928.c: New.
4651 * gcc.dg/graphite/pr37883.c: New.
4652 * gcc.dg/graphite/pr38125.c: New.
4653 * gfortran.dg/graphite/pr38083.f90: New.
4654 * gfortran.dg/graphite/pr37852.f90: New.
4655 * gfortran.dg/graphite/pr37980.f90: New.
2abae5f1 4656
45489e99 4657 * gcc.dg/graphite/scop-18.c: Remove reduction, test for
2abae5f1
SP
4658 the number of detected scops. Copy exact same test for loop
4659 blocking...
45489e99 4660 * gcc.dg/graphite/block-1.c: Fix the number of expected
2abae5f1 4661 loops to be blocked as reductions are not handled.
45489e99 4662 * gcc.dg/graphite/block-4.c: ...here. New.
2abae5f1
SP
4663
4664 * tree-phinodes.c (remove_phi_nodes): New, extracted from...
4665 * tree-cfg.c (remove_phi_nodes_and_edges_for_unreachable_block):
4666 ...here.
4667 * tree-flow.h (remove_phi_nodes, canonicalize_loop_ivs): Declared.
4668 * Makefile.in (graphite.o): Depend on value-prof.h.
4669 (graphite.o-warn): Removed -Wno-error.
4670 * tree-parloops.c (canonicalize_loop_ivs): Allow reduction_list
4671 to be a NULL pointer. Call update_stmt. Return the newly created
4672 cannonical induction variable.
4673
4674 * graphite.h (debug_rename_map): Declared. Fix some comments.
4675
4676 * graphite.c: Reimplement the code generation from graphite to gimple.
4677 Include value-prof.h.
4678 (loop_iv_stack_get_iv): Do not return NULL for constant substitutions.
4679 (get_old_iv_from_ssa_name): Removed.
4680 (graphite_stmt_p): New.
4681 (new_graphite_bb): Test for useful statements before building a
4682 graphite statement for the basic block.
4683 (free_graphite_bb): Do not free GBB_DATA_REFS: this is a bug
4684 in free_data_ref that calls BITMAP_FREE (DR_VOPS (dr)) without
4685 reason.
4686 (recompute_all_dominators, graphite_verify,
4687 nb_reductions_in_loop, graphite_loop_normal_form): New.
4688 (scop_record_loop): Call graphite_loop_normal_form.
4689 (build_scop_loop_nests): Iterate over all the blocks of the
4690 function instead of relying on the incomplete information from
4691 SCOP_BBS. Return the success of the operation.
4692 (find_params_in_bb): Use the data from GBB_DATA_REFS.
4693 (add_bb_domains): Removed.
4694 (build_loop_iteration_domains): Don't call add_bb_domains.
4695 Add the iteration domain only to the basic blocks that have been
4696 translated to graphite.
4697 (build_scop_conditions_1): Add constraints only if the basic
4698 block have been translated to graphite.
4699 (build_scop_data_accesses): Completely disabled until data
4700 dependence is correctly implemented.
4701 (debug_rename_elt, debug_rename_map_1, debug_rename_map): New.
4702 (remove_all_edges_1, remove_all_edges): Removed.
4703 (get_new_name_from_old_name): New.
4704 (graphite_rename_variables_in_stmt): Renamed
4705 rename_variables_in_stmt. Call get_new_name_from_old_name.
4706 Use replace_exp and update_stmt.
4707 (is_old_iv): Renamed is_iv.
4708 (expand_scalar_variables_stmt): Extra parameter for renaming map.
4709 Use replace_exp and update_stmt.
4710 (expand_scalar_variables_expr): Same. Use the map to get the
4711 new names for the renaming of induction variables and for the
4712 renaming of variables after a basic block has been copied.
4713 (expand_scalar_variables): Same.
4714 (graphite_rename_variables): Renamed rename_variables.
4715 (move_phi_nodes): Removed.
4716 (get_false_edge_from_guard_bb): New.
4717 (build_iv_mapping): Do not insert the induction variable of a
4718 loop in the renaming iv map if the basic block does not belong
4719 to that loop.
4720 (register_old_new_names, graphite_copy_stmts_from_block,
4721 copy_bb_and_scalar_dependences): New.
4722 (translate_clast): Heavily reimplemented: copy basic blocks,
4723 do not move them. Finally, in call cleanup_tree_cfg in gloog.
4724 At each translation step call graphite_verify ensuring the
4725 consistency of the SSA, loops and dominators information.
4726 (collect_virtual_phis, find_vdef_for_var_in_bb,
4727 find_vdef_for_var_1, find_vdef_for_var,
4728 patch_phis_for_virtual_defs): Removed huge hack.
4729 (mark_old_loops, remove_dead_loops, skip_phi_defs,
4730 collect_scop_exit_phi_args, patch_scop_exit_phi_args,
4731 gbb_can_be_ignored, scop_remove_ignoreable_gbbs, ): Removed.
4732 (remove_sese_region, ifsese, if_region_entry, if_region_exit,
4733 if_region_get_condition_block, if_region_set_false_region,
4734 create_if_region_on_edge, move_sese_in_condition, bb_in_sese_p,
4735 sese_find_uses_to_rename_use, sese_find_uses_to_rename_bb,
4736 sese_add_exit_phis_edge, sese_add_exit_phis_var,
4737 rewrite_into_sese_closed_ssa): New.
4738 (gloog): Remove dead code. Early return if code cannot be
4739 generated. Call cleanup_tree_cfg once the scop has been code
4740 generated.
4741 (graphite_trans_scop_block, graphite_trans_loop_block): Do not
4742 block loops with less than two loops.
4743 (graphite_apply_transformations): Remove the call to
4744 scop_remove_ignoreable_gbbs.
4745 (limit_scops): When build_scop_loop_nests fails, continue on
4746 the next scop. Fix open_scop.entry.
4747 (graphite_transform_loops): Call recompute_all_dominators: force the
4748 recomputation of correct CDI_DOMINATORS and CDI_POST_DOMINATORS.
4749 Call initialize_original_copy_tables and free_original_copy_tables
4750 to be able to copy basic blocks during code generation.
4751 When build_scop_loop_nests fails, continue on next scop.
4752 (value_clast): New union.
4753 (clast_to_gcc_expression): Fix type cast warning.
4754
47552008-11-09 Sebastian Pop <sebastian.pop@amd.com>
4756
4757 * Merge from mainline (r140838:141727).
4758
47592008-11-05 Tobias Grosser <grosser@fim.uni-passau.de>
4760
4761 PR middle-end/37833
4762
4763 * graphite.c (scan_tree_for_params): Add POINTER_PLUS_EXPR.
4764
47652008-11-05 Tobias Grosser <grosser@fim.uni-passau.de>
4766
4767 PR middle-end/37943
4768
4769 * graphite.c (scopdet_basic_block_info): Fix loops with multiple
4770 exits and conditions.
45489e99 4771 * gcc.dg/graphite/pr37943.c: New.
2abae5f1
SP
4772
47732008-10-23 Tobias Grosser <grosser@fim.uni-passau.de>
4774
4775 PR middle-end/37886
4776 * graphite.c (gloog): Replace EXIT_BLOCK_PTR with scop exit.
4777
47782008-10-23 Tobias Grosser <grosser@fim.uni-passau.de>
4779
4780 * doc/invoke.texi: Fix spaces.
4781
47822008-10-22 Sebastian Pop <sebastian.pop@amd.com>
4783
4784 PR tree-optimization/37891
4785 Reverted last commit.
4786 * graphite.c (create_single_entry_edge): Set
4787 EDGE_IRREDUCIBLE_LOOP and BB_IRREDUCIBLE_LOOP.
4788
47892008-10-21 Sebastian Pop <sebastian.pop@amd.com>
4790 Mitul Thakkar <mitul.thakkar@amd.com>
4791
4792 * graphite.c (create_single_entry_edge): Set
4793 EDGE_IRREDUCIBLE_LOOP and BB_IRREDUCIBLE_LOOP.
4794
47952008-10-16 Tobias Grosser <grosser@fim.uni-passau.de>
4796
4797 * doc/invoke.texi: Add -fgraphite-identity.
4798 * graphite.c (graphite_apply_transformations): Check for
4799 -fgraphite-identity.
4800 * toplev.c (process_options): Add flag_graphite_identity.
4801 * tree-ssa-loop.c: Add flag_graphite_identity.
4802
48032008-10-14 Sebastian Pop <sebastian.pop@amd.com>
4804
4805 Undo changes from 2008-10-02:
4806 * tree-ssa-loop-ivopts.c (rewrite_use_nonlinear_expr): Convert
4807 operand type when copying the operand to a variable of different type.
4808 * cfgloopmanip.c (create_empty_loop_on_edge): Write exit condition
4809 with the IV name after increment.
4810
48112008-10-14 Sebastian Pop <sebastian.pop@amd.com>
4812 Harsha Jagasia <harsha.jagasia@amd.com>
4813
4814 PR tree-optimization/37828
45489e99 4815 * gcc.dg/graphite/pr37828.c: New.
2abae5f1
SP
4816 * graphite.c (graphite_trans_loop_block): Do not loop block
4817 single nested loops.
4818
48192008-10-09 Harsha Jagasia <harsha.jagasia@amd.com>
4820 Sebastian Pop <sebastian.pop@amd.com>
4821
4822 * graphite.c (struct rename_map_elt, new_rename_map_elt,
4823 rename_map_elt_info, eq_rename_map_elts): New.
4824 (graphite_rename_ivs_stmt): Renamed graphite_rename_variables_in_stmt.
4825 (expand_scalar_variables_expr): Change parameters.
4826 (expand_scalar_variables_stmt): Same.
4827 (expand_scalar_variables): Same.
4828 (graphite_rename_ivs): Rename graphite_rename_variables.
4829 (build_iv_mapping): New.
4830 (translate_clast): Call build_iv_mapping.
4831 * graphite.h (gbb_p): New name.
4832
48332008-10-03 Harsha Jagasia <harsha.jagasia@amd.com>
4834
4835 PR tree-optimization/37684
4836 * gcc.dg/graphite/pr37684.c: New.
4837 * graphite.c (exclude_component_ref): New.
4838 (is_simple_operand): Call exclude_component_ref.
4839
48402008-10-02 Jan Sjodin <jan.sjodin@amd.com>
4841 Harsha Jagasia <harsha.jagasia@amd.com>
4842
4843 PR tree-optimization/37485
4844 * gcc.dg/graphite/block-2.c: New
4845 * graphite.c (gmp_cst_to_tree): Moved.
4846 (iv_stack_entry_is_constant): New.
4847 (iv_stack_entry_is_iv): New.
4848 (loop_iv_stack_push): Renamed to loop_iv_stack_push_iv.
4849 (loop_iv_stack_insert_constant): New.
4850 (loop_iv_stack_pop): Use new datatpype.
4851 (loop_iv_stack_get_iv): Same.
4852 (loop_iv_stack_get_iv_from_name): Same.
4853 (loop_iv_stack_debug): Renamed to debug_loop_iv_stack.
4854 (loop_iv_stack_patch_for_consts): New.
4855 (loop_iv_stack_remove_constants): New.
4856 (graphite_create_new_loop): Use loop_iv_stack_push_iv.
4857 (translate_clast): Call loop_iv_stack_patch_for_consts and
4858 loop_iv_stack_remove_constants.
4859 (gloog): Use new datatype. Redirect construction edge to end
4860 block to avoid accidental deletion.
4861 * graphite.h (enum iv_stack_entry_kind): New. Tag for data in
4862 iv stack entry.
4863 (union iv_stack_entry_data): New. Data in iv stack entry.
4864 (struct iv_stack_entry): New. Datatype for iv stack entries.
4865
48662008-10-02 Sebastian Pop <sebastian.pop@amd.com>
4867
4868 * tree-ssa-loop-ivopts.c (rewrite_use_nonlinear_expr): Convert
4869 operand type when copying the operand to a variable of different type.
4870
48712008-10-02 Sebastian Pop <sebastian.pop@amd.com>
4872
4873 * cfgloopmanip.c (create_empty_loop_on_edge): Write exit condition
4874 with the IV name after increment.
4875
48762008-10-02 Sebastian Pop <sebastian.pop@amd.com>
4877
4878 * Merge from mainline (r140164:140838).
4879
48802008-09-10 Konrad Trifunovic <konrad.trifunovic@inria.fr>
4881
4882 * graphite-data-ref.c: New.
4883 * graphite.c (print_scop): Also dump the dependence graph.
4884 (bb_in_scop_p, loop_in_scop_p, nb_loops_around_gb): Moved...
4885 (new_scop): Initialize SCOP_DEP_GRAPH.
4886 (build_scop_dynamic_schedules): New.
4887 (build_access_matrix_with_af): Fixed column numbering.
4888 (graphite_transform_loops): Call build_scop_dynamic_schedules.
4889 * graphite.h: Add ifndef/define guards against multiple inclusion.
4890 (struct scop): Add dep_graph field.
4891 (SCOP_DEP_GRAPH): Defined.
4892 (ref_nb_loops): Fixed and moved to other position.
4893 (bb_in_scop_p, loop_in_scop_p, nb_loops_around_gb): ... here.
4894 (nb_loops_around_loop_in_scop): New.
4895 (graphite_dump_dependence_graph): Declared.
4896 (graphite_build_rdg_all_levels): Declared.
4897 (graphite_test_dependence): Declared.
4898 * Makefile.in (graphite-data-ref.o): New target.
4899
49002008-09-09 Sebastian Pop <sebastian.pop@amd.com>
4901
4902 * Merge from mainline (139870:140164).
4903
49042008-09-01 Sebastian Pop <sebastian.pop@amd.com>
4905
4906 * Merge from mainline (138275:139870).
45489e99 4907 * gcc.dg/graphite/scop-matmult.c: XFailed as one of
2abae5f1
SP
4908 the commits from trunk broke the niter detection.
4909
49102008-09-01 Sebastian Pop <sebastian.pop@amd.com>
4911
4912 * graphite.c: Add more documentation. Fix formatting.
4913 (debug_loop_vec, debug_oldivs, loop_iv_stack,
4914 loop_iv_stack_debug): Moved...
4915 (schedule_to_scattering): Move before use.
4916 (dot_all_scops): Include in "#if 0" the code for system
4917 call dotty.
4918
4919 * graphite.h: (debug_loop_vec, debug_oldivs, loop_iv_stack,
4920 loop_iv_stack_debug): ...here.
4921
49222008-08-29 Jan Sjodin <jan.sjodin@amd.com>
4923
4924 * tree-phinodes.c (make_phi_node): Extern.
4925 (add_phi_node_to_bb): New.
4926 (create_phi_node): Call add_phi_node_to_bb.
4927 * tree-ssa-loop-ivopts.c (get_phi_with_result): New.
4928 (remove_statement): Handle case where stored phi was updated
4929 and is no longer the same.
4930 * graphite.c (is_parameter): New.
4931 (is_old_iv): New.
4932 (expand_scalar_variables_expr): New.
4933 (expand_scalar_variables_stmt): New.
4934 (expand_scalar_variables): New.
4935 (move_phi_nodes): Create new phi instead of moving old one.
4936 (translate_clast): Call expand_scalar_variables.
4937 (find_vdef_for_var_in_bb): Also scan regular definitions.
4938 (skip_phi_defs): New.
4939 (collect_scop_exit_phi_args): New.
4940 (patch_scop_exit_phi_args): New.
4941 (gloog): Patch phis after scop.
4942 * tree-flow.h: (add_phi_node_to_bb): Declared.
4943 (make_phi_node): Declared.
4944
49452008-08-26 Sebastian Pop <sebastian.pop@amd.com>
4946
4947 * graphite.c (end_scop): Split the entry of the scop when it
4948 is the header of the loop in which the scop is ending.
4949 (build_scops_1, limit_scops): Update uses of end_scop.
4950
49512008-08-26 Sebastian Pop <sebastian.pop@amd.com>
4952
4953 * graphite.c (dot_all_scops_1): Do not fail on uninitialized
4954 SCOP_ENTRY or SCOP_EXIT.
4955
49562008-08-25 Sebastian Pop <sebastian.pop@amd.com>
4957
4958 * graphite.c (get_construction_edge): Removed.
4959 (gloog): Construction edge is the scop entry edge.
4960
49612008-08-25 Sebastian Pop <sebastian.pop@amd.com>
4962
4963 * graphite.c (can_generate_for_scop): Removed.
4964 (gloog): Do not call it.
4965
49662008-08-25 Sebastian Pop <sebastian.pop@amd.com>
4967
4968 * graphite.c (new_scop): Entry of a scop is an edge.
4969 Initialize SESE region.
4970 (free_scop): Free SESE region.
4971 (build_scops_1, scopdet_bb_info): Work on edges, not on bbs.
4972 (split_difficult_bb): New, split from end_scop.
4973 (end_scop): Exit of a scop is an edge.
4974 (build_scop_bbs): Never check CDI_POST_DOMINATORS: this info is
4975 not automatically updated and thus is always wrong.
4976 * graphite.h (struct sese): New.
4977 (SESE_ENTRY): New.
4978 (SESE_EXIT): New.
4979 (struct scop): New field for a SESE region. Remove entry, exit.
4980 (SCOP_ENTRY, SCOP_EXIT): Update definitions to match same
4981 semantics as before. Moved comment around.
4982
49832008-08-25 Tobias Grosser <grosser@fim.uni-passau.de>
4984 Sebastian Pop <sebastian.pop@amd.com>
4985
4986 * graphite.c (graphite_transform_loops): Always enable gloog
4987 and find_transform when ENABLE_CHECKING.
4988
49892008-08-25 Sebastian Pop <sebastian.pop@amd.com>
4990
4991 * graphite.c (graphite_transform_loops): Move pretty printer
4992 of SCOPs before doing any transform. Remove call to print_scops
4993 and dot_all_scops_1.
4994
49952008-08-25 Sebastian Pop <sebastian.pop@amd.com>
4996
4997 * graphite.c (dump_gbb_conditions): Don't try to print NULL pointers.
4998 (print_graphite_bb): Same.
4999
50002008-08-25 Sebastian Pop <sebastian.pop@amd.com>
5001
5002 * graphite.c (dot_all_scops_1): Cleanup.
5003 (move_scops): Fix comment.
5004
50052008-08-25 Sebastian Pop <sebastian.pop@amd.com>
5006
5007 * graphite.c (build_scop_bbs): Revert commit 139355:
5008
5009 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5010 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
5011
5012 * graphite.c (build_scop_bbs): Factor up code.
5013
50142008-08-25 Tobias Grosser <grosser@fim.uni-passau.de>
5015
5016 * graphite.c (gloog): Update dominator info.
5017
50182008-08-25 Tobias Grosser <grosser@fim.uni-passau.de>
5019
5020 * graphite.c (remove_cond_exprs): Do not fail on empty bbs.
5021
50222008-08-24 Sebastian Pop <sebastian.pop@amd.com>
5023
5024 * graphite.c (new_graphite_bb): Remove GBB_INDEX_TO_NUM_MAP
5025 initialization.
5026 (free_graphite_bb): Remove GBB_INDEX_TO_NUM_MAP free.
5027 (translate_clast): Correct formatting.
5028 * graphite.h (struct num_map): Removed.
5029 (struct graphite_bb): Remove num_map field.
5030 (GBB_INDEX_TO_NUM_MAP): Removed.
5031
50322008-08-24 Sebastian Pop <sebastian.pop@amd.com>
5033
5034 * graphite.c (build_access_matrix_with_af): Fix comments.
5035 (build_scop_data_accesses): Same.
5036
50372008-08-24 Sebastian Pop <sebastian.pop@amd.com>
5038
5039 * graphite.c (build_scop_data_accesses): Don't construct
5040 access matrices. Add a FIXME and an assert condition that
5041 should pass when the access matrices will be needed.
5042
50432008-08-24 Sebastian Pop <sebastian.pop@amd.com>
5044
5045 * tree-data-ref.c (stmt_simple_memref_p): Don't call
5046 really_constant_p.
5047 * graphite.c (build_graphite_bb): Renamed new_graphite_bb.
5048 Moved close by free_graphite_bb.
5049 (free_graphite_bb): Call free_data_refs. Reset bb->aux.
5050 (new_scop): Move close by free_scop.
5051 (graphite_transform_loops): Avoid linear scan to reset bb->aux.
5052
50532008-08-22 Jan Sjodin <jan.sjodin@amd.com>
5054
5055 * cfgloopmanip.c (create_empty_if_region_on_edge): New.
5056 * graphite.c (clast_to_gcc_expression): Call gmp_cst_to_tree
5057 instead of recursive call.
5058 (graphite_translate_clast_equation): New.
5059 (graphite_create_guard_cond_expr): New.
5060 (graphite_create_new_guard): New.
5061 (get_stack_index_from_iv): Removed.
5062 (graphite_rename_ivs_stmt): Use gbb_loop_index.
5063 (get_true_edge_from_guard_bb): New.
5064 (translate_clast): Handle stmt_guard in clast.
5065 (get_construction_edge): Allow construction edge detection for
5066 a scope entry with multiple predecessors if one predecessor is
5067 the immediate dominator of scope entry.
5068 (can_generate_code_stmt): Enable code generation for clast_guard.
5069 (gloog): Use correct context loop. Removed check for post dominators.
5070 * cfgloop.h (create_empty_if_region_on_edge): Declared.
5071
50722008-08-21 Sebastian Pop <sebastian.pop@amd.com>
5073
5074 * graphite.c (remove_dead_loops): Document better which
5075 loops are removed.
5076
50772008-08-21 Sebastian Pop <sebastian.pop@amd.com>
5078
5079 * Makefile.in: Rename POLYLIBLIBS and POLYLIBINC to PPLLIBS
5080 and PPLINC.
5081 (graphite.o): Also depends on pointer-set.h.
5082
50832008-08-21 Sebastian Pop <sebastian.pop@amd.com>
5084
5085 * graphite.c (scop_record_loop): Fix compile warning.
5086
50872008-08-21 Harsha Jagasia <harsha.jagasia@amd.com>
5088 Sebastian Pop <sebastian.pop@amd.com>
5089
5090 * graphite.c (scop_record_loop): DECL_NAME can be NULL.
5091
50922008-08-21 Sebastian Pop <sebastian.pop@amd.com>
5093
5094 * graphite.c (build_graphite_bb): Initialize bb->aux to
5095 point to the graphite_bb_p.
5096 (graphite_bb_from_bb): Renamed gbb_from_bb; returns the
5097 content of bb->aux.
5098 (add_bb_domains): Does not use the scop parameter.
5099 (graphite_transform_loops): Clean bb->aux at the end.
5100
51012008-08-20 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
5102 Sebastian Pop <sebastian.pop@amd.com>
5103
45489e99 5104 * lib/target-supports.exp
2abae5f1
SP
5105 (check_effective_target_fgraphite): New.
5106
45489e99 5107 * gcc.dg/graphite/graphite.exp: Early exit when
2abae5f1
SP
5108 check_effective_target_fgraphite returns false.
5109 Set dg-do-what-default to compile.
5110 (scan-graphite-dump-times): Removed.
45489e99 5111 * gfortran.dg/graphite/graphite.exp: Same.
2abae5f1 5112
45489e99 5113 * gcc.dg/graphite/scop-0.c: Do not use "dg-do compile".
2abae5f1 5114 Use scan-tree-dump-times instead of scan-graphite-dump-times.
45489e99
SP
5115 * gcc.dg/graphite/scop-1.c: Same.
5116 * gcc.dg/graphite/scop-2.c: Same.
5117 * gcc.dg/graphite/scop-3.c: Same.
5118 * gcc.dg/graphite/scop-4.c: Same.
5119 * gcc.dg/graphite/scop-5.c: Same.
5120 * gcc.dg/graphite/scop-6.c: Same.
5121 * gcc.dg/graphite/scop-7.c: Same.
5122 * gcc.dg/graphite/scop-8.c: Same.
5123 * gcc.dg/graphite/scop-9.c: Same.
5124 * gcc.dg/graphite/scop-10.c: Same.
5125 * gcc.dg/graphite/scop-11.c: Same.
5126 * gcc.dg/graphite/scop-12.c: Same.
5127 * gcc.dg/graphite/scop-13.c: Same.
5128 * gcc.dg/graphite/scop-matmult.c: Same.
5129 * gcc.dg/graphite/scop-14.c: Same.
5130 * gcc.dg/graphite/scop-15.c: Same.
5131 * gcc.dg/graphite/block-0.c: Same.
5132 * gcc.dg/graphite/scop-16.c: Same.
5133 * gcc.dg/graphite/block-1.c: Same.
5134 * gcc.dg/graphite/scop-17.c: Same.
5135 * gcc.dg/graphite/scop-18.c: Same.
5136 * gfortran.dg/graphite/block-1.f90: Same.
5137 * gfortran.dg/graphite/scop-1.f: Same.
5138 * gfortran.dg/graphite/block-2.f: Same.
2abae5f1
SP
5139
51402008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5141
5142 * graphite.c: Fix some XXX comments.
5143 (build_scop_dynamic_schedules): Removed.
5144
51452008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5146
5147 * graphite.h (scop_max_loop_depth): Moved...
5148 * graphite.c (scop_max_loop_depth): ...here.
5149 (remove_all_edges_1): New.
5150 (remove_all_edges): Factored code.
5151 (remove_cond_exprs): Check only the last statement for
5152 a GIMPLE_COND expression.
5153
51542008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5155
5156 * graphite.c (scan_tree_for_params): Early return when the
5157 expression is a chrec_dont_know. Handle case NEGATE_EXPR.
5158 (find_scop_parameters): Factor out code.
5159 (graphite_trans_bb_strip_mine): Remove dead code.
5160
51612008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5162
5163 * graphite.c (clast_to_gcc_expression, graphite_create_new_loop,
5164 graphite_trans_bb_move_loop): Factor asserts.
5165 (gloog): Perform sanity checks only for ENABLE_CHECKING.
5166 Do not call calculate_dominance_info and estimate_bb_frequencies.
5167
51682008-08-20 Jan Sjodin <jan.sjodin@amd.com>
5169
5170 * graphite.c (create_loops_mapping, free_loops_mapping,
5171 create_loops_mapping_num, debug_loop_mapping_1,
5172 debug_loop_mapping, graphite_loops_mapping_max_loop_num,
5173 get_loop_mapping_for_num, graphite_loops_mapping_add_child,
5174 graphite_loops_mapping_add_child_num,
5175 graphite_loops_mapping_insert_child,
5176 graphite_loops_mapping_parent, get_loop_mapped_depth_for_num,
5177 get_loop_mapped_depth, split_loop_mapped_depth_for_num,
5178 loop_mapped_depth_split_loop, swap_loop_mapped_depth_for_num,
5179 create_num_from_index, get_num_from_index,
5180 swap_loop_mapped_depth): Removed.
5181 (new_scop): Do not initialize SCOP_LOOPS_MAPPING.
5182 (free_scop): Do not call free_loops_mapping.
5183 (graphite_get_new_iv_stack_index_from_old_iv): Renamed
5184 get_stack_index_from_iv. Use GBB_LOOPS instead of calling
5185 get_loop_mapped_depth.
5186 (graphite_trans_bb_move_loop): Do not update the loop mapping.
5187 (graphite_trans_bb_strip_mine): Same.
5188 * graphite.h (graphite_loops_mapping, graphite_loop_node): Removed.
5189 (struct scop): Remove field loops_mapping.
5190
51912008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5192 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
5193
5194 * graphite.c (scop_record_loop): Factor out one level of the
5195 condition by early return.
5196 (build_scop_loop_nests): Format following FSF coding style.
5197 (build_scop_dynamic_schedules): Factor out code.
5198 (scopdet_bb_info): Reindent. Default case should not be reachable.
5199
52002008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5201 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
5202
5203 * graphite.c (loop_affine_expr): Check for DECL_P or struct
5204 assignments that are not handled as simple operands for now.
5205
52062008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5207 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
5208
5209 * graphite.c (build_scop_bbs): Factor up code.
5210
52112008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5212 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
5213
5214 * graphite.c (stmt_simple_for_scop_p): Factor code out
5215 of the loop.
5216 (enum gbb_type): New. Group all the GBB_* types under it.
5217 (is_loop_exit): Moved...
5218 (end_scop): Enable BB spliting.
5219 * cfgloop.c (is_loop_exit): ...here. Reimplemented.
5220 * cfgloop.h (is_loop_exit): Declared.
5221
52222008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5223
5224 * doc/invoke.texi: Remove strides from examples containing
5225 DO loops when the strides are equal to 1.
5226
52272008-08-20 Harsha Jagasia <harsha.jagasia@amd.com>
5228 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
5229
5230 * graphite.c (graphite_trans_scop_block): Or the result with
5231 the result from graphite_trans_loop_block.
45489e99
SP
5232 * gcc.dg/graphite/block-1.c: New.
5233 * gfortran.dg/graphite/block-1.f90: New.
5234 * gfortran.dg/graphite/block-2.f: New.
2abae5f1
SP
5235
52362008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5237
5238 * graphite.c (graphite_transform_loops): Call cloog_initialize
5239 and cloog_finalize.
5240
52412008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5242
5243 * tree-data-ref.c) (stmt_simple_memref_p): New.
5244 * tree-data-ref.h (stmt_simple_memref_p): Declared.
5245 * graphite.c (stmt_simple_memref_for_scop_p): Removed.
5246 (is_simple_operand): Call stmt_simple_memref_p.
5247
45489e99 5248 * gcc.dg/graphite/scop-matmult.c: Updated for not
2abae5f1
SP
5249 using pointer arithmetic, as this is optimized by PRE and
5250 makes the code too difficult to analyze.
5251
45489e99 5252 * gcc.dg/graphite/scop-18.c: Same.
2abae5f1
SP
5253
52542008-08-20 Sebastian Pop <sebastian.pop@amd.com>
5255
5256 * gdbinit.in (pgg): New.
5257
52582008-08-15 Tobias Grosser <grosser@fim.uni-passau.de>
5259
5260 * graphite.c (graphite_trans_loop_block): Fix warning.
5261
52622008-08-15 Tobias Grosser <grosser@fim.uni-passau.de>
5263
5264 * graphite.c (graphite_trans_loop_block): Fix my merge error.
5265
52662008-08-15 Tobias Grosser <grosser@fim.uni-passau.de>
5267
5268 * graphite.c (graphite_trans_bb_block): Remove check for
5269 flag_loop_strip_mine, flag_loop_block, flag_loop_interchange.
5270 Check if loop blocking is profitable for every loop, before applying
5271 the changes.
5272 (graphite_apply_transformations): Call graphite_trans_bb_block only,
5273 if flag_loop_block is set.
5274
52752008-08-14 Sebastian Pop <sebastian.pop@amd.com>
5276
5277 * graphite.c: Add some more documentation for the loop
5278 mapping.
5279
52802008-08-14 Sebastian Pop <sebastian.pop@amd.com>
5281
5282 * Makefile.in (tree-data-ref.o): Remove dependence on graphite.h.
5283 * graphite.c: Format on less than 80 columns.
5284 * graphite.h: Same.
5285
52862008-08-14 Sebastian Pop <sebastian.pop@amd.com>
5287
5288 * cfgloopmanip.c (loopify): Use update_dominators_in_loop.
5289
52902008-08-14 Sebastian Pop <sebastian.pop@amd.com>
5291
5292 * doc/invoke.texi (floop-block, floop-strip-mine,
5293 floop-interchange): Update documentation with examples.
5294
52952008-08-13 Sebastian Pop <sebastian.pop@amd.com>
5296
5297 * cfgloopmanip.c (create_empty_loop_on_edge): Don't call
5298 add_referenced_var.
5299 * graphite.c (graphite_create_new_loop): Call add_referenced_var.
5300
53012008-08-13 Sebastian Pop <sebastian.pop@amd.com>
5302
5303 * cfgloopmanip.c (create_empty_loop_on_edge): Improve documentation.
5304 Factor gcc_asserts into a single one. Use force_gimple_operand_gsi.
5305 * tree-scalar-evolution.c: Revert useless changes.
5306 * tree-phinodes.c: Same.
5307 * cfghooks.c: Same.
5308 * vec.h: Same.
5309 * tree-vectorizer.h: Same.
5310 * tree-flow.h: Same.
5311 * tree-cfg.c: Same.
5312 * common.opt (fgraphite): Update documentation.
5313
53142008-08-12 Harsha Jagasia <harsha.jagasia@amd.com>
5315
5316 * doc/invoke.texi (-floop-block, -floop-strip-mine,
5317 -floop-interchange): Add more text for explaining what each of these
5318 flags is doing.
5319 * tree-into-ssa.c (gimple_vec): Moved to...
5320 * graphite.c: Include gimple.h.
5321 (gimple_vec): Moved to...
5322 (del_loop_to_cloog_loop): Removed.
5323 (loop_affine_expr): Do not call create_data_ref when the
5324 operand is a constant.
5325 (new_scop): Use free instead of del_loop_to_cloog_loop.
5326 * Makefile.in (graphite.o): Depend on GIMPLE_H.
5327 * gimple.h (gimple_vec): ... here.
5328
53292008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5330
5331 * graphite.c (scopdet_bb_info): Only allow loops with known number of
5332 latch executions.
5333 (build_loop_iteration_domains): Fail, if latch executions unknown.
5334
53352008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5336
5337 * graphite.c (add_conditions_to_domain): New.
5338 (build_scop_conditions_1): Call add_conditions_to_domain.
5339 (set_cloog_options): Allow to disable optimizations.
5340
53412008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5342
5343 * graphite.c (find_params_in_bb): Look for parameters in conditions.
5344 Do not use walk_dominator_tree.
5345 (find_scop_parameters): Do not use walk_dominator_tree.
5346
53472008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5348
5349 * graphite.c (scan_tree_for_params) Add / Subtract inequality.
5350 (idx_record_params): Adapt.
5351 * graphite.h (scop_gimple_loop_depth): New.
5352
53532008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5354
5355 * graphite.c (build_scop_dynamic_schedules): Remove value_init.
5356 (scan_tree_for_params): Remove value_init.
5357 (build_scop_context): Remove value_init.
5358 (build_loop_iteration_domains): Remove value_init.
5359 (schedule_to_scattering): Remove value_init.
5360 (graphite_trans_bb_strip_mine): Remove value_init.
5361
53622008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5363
5364 * gcc/graphite.c (limit_scops): New.
5365 (graphite_transform_loops): Add limit SCoPs.
45489e99
SP
5366 * gcc.dg/graphite/scop-0.c: Update number of SCoPs.
5367 * gcc.dg/graphite/scop-1.c: Update number of SCoPs.
5368 * gcc.dg/graphite/scop-10.c: Update number of SCoPs.
5369 * gcc.dg/graphite/scop-11.c: Update number of SCoPs.
5370 * gcc.dg/graphite/scop-12.c: Update number of SCoPs.
5371 * gcc.dg/graphite/scop-13.c: Update number of SCoPs.
5372 * gcc.dg/graphite/scop-14.c: Update number of SCoPs.
5373 * gcc.dg/graphite/scop-15.c: Update number of SCoPs.
5374 * gcc.dg/graphite/scop-16.c: Update number of SCoPs.
2abae5f1 5375 Change loop numbers.
45489e99 5376 * gcc.dg/graphite/scop-17.c: Update number of SCoPs.
2abae5f1 5377 Change loop numbers.
45489e99
SP
5378 * gcc.dg/graphite/scop-18.c: Update number of SCoPs.
5379 * gcc.dg/graphite/scop-2.c: Update number of SCoPs.
5380 * gcc.dg/graphite/scop-3.c: Update number of SCoPs.
5381 * gcc.dg/graphite/scop-4.c: Update number of SCoPs.
5382 * gcc.dg/graphite/scop-5.c: Update number of SCoPs.
5383 * gcc.dg/graphite/scop-6.c: Update number of SCoPs.
5384 * gcc.dg/graphite/scop-7.c: Update number of SCoPs.
5385 * gcc.dg/graphite/scop-8.c: Update number of SCoPs.
5386 * gcc.dg/graphite/scop-9.c: Update number of SCoPs.
5387 * gcc.dg/graphite/scop-matmult.c: Update number of SCoPs.
2abae5f1
SP
5388
53892008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5390
5391 * graphite.c (graphite_transform_loops): Call always find_transform.
5392
53932008-08-08 Tobias Grosser <grosser@fim.uni-passau.de>
5394
5395 * graphite.c (free_loops_mapping): New.
5396 (stmt_simple_for_scop_p): Fix typo.
5397 (stmt_simple_for_scop_p): Fix tuples functions, that
5398 broke polyhedron.
5399 (free_graphite_bb): Fix some memleaks.
5400 (free_scop): Fix some memleaks.
5401 (scopdet_bb_info): Do not forget some tmp SCoPs.
5402 (find_params_in_bb): Fix some memleaks.
5403 (clast_to_gcc_expression): Fix warning.
5404
54052008-08-07 Tobias Grosser <grosser@fim.uni-passau.de>
5406
45489e99
SP
5407 * gcc.dg/graphite/scop-16.c: Fix for 32bit.
5408 * gcc.dg/graphite/scop-17.c: Fix for 32bit.
2abae5f1
SP
5409
54102008-08-04 Sebastian Pop <sebastian.pop@amd.com>
5411
5412 * tree-ssa-loop.c (tree-ssa-loop.o): Do not include toplev.h.
5413 Move code ifdef-ed HAVE_cloog...
5414 * graphite.c: Include toplev.h.
5415 ... here.
5416 * Makefile.in (OBJS-common): Always build graphite.o.
5417 (BACKEND): Remove @GRAPHITE@.
5418 (tree-ssa-loop.o): Do not depend on TOPLEV_H.
5419 (graphite.o): Depend on TOPLEV_H.
5420
54212008-08-04 Sebastian Pop <sebastian.pop@amd.com>
5422
5423 * Makefile.in (tree-ssa-loop.o): Depend on TOPLEV_H.
5424 Remove typo left from polylib to ppl conversion.
5425 * graphite.c (graphite_transforms): Use sorry instead of fatal.
5426
54272008-08-03 Sebastian Pop <sebastian.pop@amd.com>
5428
5429 * toplev.c (process_options): Move the graphite loop optimization
5430 flags...
5431 * tree-ssa-loop.c (graphite_transforms): ... here.
5432 When not configured with CLooG, print to dump_file that
5433 Graphite transforms were not performed.
45489e99 5434 * gcc.dg/graphite/graphite.exp (scan-graphite-dump-times):
2abae5f1 5435 New.
45489e99 5436 * gcc.dg/graphite/*.c: Updated all testcases to use
2abae5f1
SP
5437 scan-graphite-dump-times.
5438
54392008-08-03 Sebastian Pop <sebastian.pop@amd.com>
5440
5441 * graphite.c (dot_scop, dot_all_scops): Do not call system.
5442 Do not open /tmp/scop.dot and /tmp/allscops.dot.
5443
54442008-08-02 Sebastian Pop <sebastian.pop@amd.com>
5445 Jan Sjodin <jan.sjodin@amd.com>
5446
5447 * configure: Regenerated.
5448 * omp-low.c (expand_omp_sections): Remove now unused code.
5449 * config.in (HAVE_polylib): Removed.
5450 * configure.ac (HAVE_polylib, POLYLIBLIBS, POLYLIBINC): Removed.
5451 (PPLLIBS, PPLINC): Added.
5452 * graphite.c: Replace unsigned with int wherever possible.
5453 Don't access Cloog's data structures, but use accessor functions.
5454 Clast's stmt->type is now implemented as a vtable: change the
5455 switches of stmt->type into ifs.
5456 (polylib/polylibgmp.h): Don't include.
5457 (initialize_dependence_polyhedron,
5458 initialize_data_dependence_polyhedron, is_empty_polyhedron,
5459 statement_precedes_p, test_dependence, build_rdg_all_levels,
5460 dump_dependence_graph): Removed until this code is cleaned up
5461 or ported to Cloog.
5462 * Makefile.in (POLYLIBLIBS): Renamed PPLLIBS.
5463 (POLYLIBINC): Renamed PPLINC.
5464
54652008-08-01 Harsha Jagasia <harsha.jagasia@amd.com>
5466 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
5467 Jan Sjodin <jan.sjodin@amd.com>
5468
5469 Finish the merge and tuplification of graphite.
5470
54712008-07-24 Sebastian Pop <sebastian.pop@amd.com>
5472 Jan Sjodin <jan.sjodin@amd.com>
5473
5474 Partial merge from mainline (138072:138275).
5475 * graphite.c still has to be tuplified.
5476
54772008-07-29 Jan Sjodin <jan.sjodin@amd.com>
5478
5479 * graphite.c (graphite_loops_mapping_max_loop_num): New.
5480 (create_num_from_index): New.
5481 (get_num_from_index): Also pass in the graphite BB.
5482 (free_graphite_bb): Free GBB_INDEX_TO_NUM_MAP.
5483 (build_graphite_bb): Initialize GBB_INDEX_TO_NUM_MAP.
5484 (graphite_trans_bb_strip_mine): Call create_num_from_index.
5485 (is_interchange_valid): Return false when failing.
5486 * graphite.h (struct num_map): New.
5487 (struct graphite_bb): New field num_map.
5488 (GBB_LOOPS_MAPPING): Renamed GBB_INDEX_TO_NUM_MAP.
5489
54902008-07-29 Tobias Grosser <grosser@fim.uni-passau.de>
5491
5492 * graphite.c (dump_gbb_conditions): Print also conditions like
5493 "if (a)". Remove dublicated code and use print_generic_expr ().
5494 (stmt_simple_for_scop_p): Only allow conditions we can handle
5495 {<, <=, >, >=}.
5496
54972008-07-25 Jan Sjodin <jan.sjodin@amd.com>
5498
5499 * graphite.h (struct scop): Removed new_ivs field.
5500 (SCOP_NEWIVS): Deleted.
5501 * graphite.c (new_scop, free_scop, clast_name_to_gcc,
5502 clast_to_gcc_expression, graphite_create_new_loop):
5503 Removed use of new_ivs.
5504
55052008-07-25 Jan Sjodin <jan.sjodin@amd.com>
5506
5507 * graphite.c (debug_oldivs, debug_loop_vec, create_loops_mapping,
5508 create_loops_mapping_num, debug_loop_mapping_1): New.
5509 (debug_loop_mapping): Call debug_loop_mapping_1.
5510 (get_loop_mapping_for_num,
5511 graphite_loops_mapping_add_child,
5512 graphite_loops_mapping_add_child_num,
5513 graphite_loops_mapping_insert_child,
5514 graphite_loops_mapping_parent,
5515 split_loop_mapped_depth_for_num,
5516 loop_mapped_depth_split_loop): New.
5517 (increment_loop_mapped_depths): Removed.
5518 (swap_loop_mapped_depth_for_num): Reimplemented.
5519 (new_scop): Call create_loops_mapping.
5520 (scop_record_loop): Call graphite_loops_mapping_insert_child.
5521 (translate_clast): Pass the old loop father in parameter, and pass
5522 it to get_old_iv_from_ssa_name.
5523 (remove_edges_around_useless_blocks, can_generate_code_stmt,
5524 can_generate_code, can_generate_for_scop): New.
5525 (graphite_trans_bb_block): Returns false when it fails to transform.
5526 * graphite.h (graphite_loop_node, graphite_loops_mapping): New.
5527
55282008-07-25 Sebastian Pop <sebastian.pop@amd.com>
5529
5530 Reverted all the changes related to the streamization and
5531 loop fusion.
5532 These changes are now tracked in the streamization branch.
5533
55342008-07-25 Sebastian Pop <sebastian.pop@amd.com>
5535 Jan Sjodin <jan.sjodin@amd.com>
5536
5537 * graphite.c (gbb_compare): Correctly constify.
5538 (gbb_can_be_ignored): Indent.
5539 (graphite_trans_scop_swap_1and2): Add legality check.
5540 Remove dead FIXMEs.
5541
55422008-07-25 Sebastian Pop <sebastian.pop@amd.com>
5543
5544 Remove fallouts from "Reverted the Condate changes".
5545 * tree.h: Remove unused decl.
45489e99 5546 * gcc.dg/tree-checker: Same.
2abae5f1
SP
5547 * timevar.def: Remove counter.
5548
55492008-07-24 Sebastian Pop <sebastian.pop@amd.com>
5550
5551 * Merge from mainline (135673:138072).
5552
5553 Reverted the MIRO changes (from 2008-04-05) that are now
5554 tracked in the miro branch.
5555 * tree-bounds.c: Removed.
5556 * tree-bounds.h: Removed.
5557
5558 Reverted the Condate changes (from 2006-07-04, 2007-03-20) that
5559 are now tracked in the condate branch.
5560 * tree-check.c: Removed.
5561 * tree-match.c: Removed.
5562 * condate.y: Removed.
5563
55642008-07-24 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
5565
5566 * common.opt: New user flag -floop-block, -floop-strip-mine
5567 and -floop-interchange.
5568 * toplev.c (process_options): Enable -fgraphite pass if any one of the
5569 graphite loop optimization flags is turned on.
5570 * graphite.c (graphite_apply_transformations): Add flag_loop_block,
5571 flag_loop_strip_mine and flag_loop_interchange checks before
5572 optimizations.
5573 * doc/invoke.texi: Remove -fgraphite and add -floop-block,
5574 -floop-strip-mine and -floop-interchange.
45489e99 5575 * gcc.dg/graphite/block-0.c: Add -floop-block and remove
2abae5f1 5576 -fgraphite.
45489e99
SP
5577 * gcc.dg/graphite/scop-16.c: Ditto.
5578 * gcc.dg/graphite/scop-17.c: Ditto.
5579 * gcc.dg/graphite/scop-18.c: Ditto.
2abae5f1
SP
5580
55812008-07-23 Jan Sjodin <jan.sjodin@amd.com>
5582 Sebastian Pop <sebastian.pop@amd.com>
5583
5584 * cfgloopmanip.c (update_dominators_in_loop): Make it static.
5585 (create_empty_loop_on_edge): More fixes.
5586 * tree-phinodes.c (resize_phi_node): Extern.
5587 (unlink_phi_node, move_phi_node): New split from remove_phi_node.
5588 * cfghooks.c (update_dominator_information): New split from
5589 split_edge.
5590 * tree-vectorizer.c (rename_variables_in_bb): Extern.
5591 * tree-dfa.c (collect_dfa_stats): Start walking the CFG on the
5592 successor of the function entry block.
5593
5594 * graphite.c: Include pointer-set.h.
5595 (debug_loop_mapping, increment_loop_mapped_depths,
5596 get_loop_mapped_depth_for_num, get_loop_mapped_depth,
5597 set_loop_mapped_depth_for_num, set_loop_mapped_depth,
5598 swap_loop_mapped_depth_for_num, get_num_from_index,
5599 swap_loop_mapped_depth, loop_iv_stack_debug,
5600 loop_iv_stack_push, loop_iv_stack_pop, loop_iv_stack_get_iv,
5601 loop_iv_stack_get_iv_from_name, loop_iv_stack_debug,
5602 get_old_iv_from_ssa_name): New.
5603 (new_scop): Initialize SCOP_LOOPS_MAPPING.
5604 (free_scop): Free SCOP_LOOPS_MAPPING.
5605 (scop_record_loop): Record old ivs.
5606 (create_var_name): Removed.
5607 (initialize_cloog_names): Allocate double space in case strip mine
5608 applies to all loops once.
5609 (clast_name_to_gcc): Look up in the map ivstack passed in parameter.
5610 (clast_to_gcc_expression): Same. Implement more clast to gimple
5611 translation.
5612 (graphite_create_new_loop): Pass in ivstack.
5613 (remove_all_edges): Pass in the construction_edge.
5614 (graphite_remove_iv): Removed.
5615 (graphite_rename_ivs, graphite_rename_ivs_stmt,
5616 remove_cond_exprs): Rewritten.
5617 (move_phi_nodes): New.
5618 (disconnect_virtual_phi_nodes, disconnect_cond_expr): Removed.
5619 (translate_clast): Pass in ivstack. Rewrite some cases.
5620 (set_cloog_options, debug_clast_stmt): New.
5621 (find_transform): Use set_cloog_options.
5622 (outermost_loop_layer): Removed.
5623 (get_construction_edge, collect_virtual_phis, find_vdef_for_var_in_bb,
5624 find_vdef_for_var_1, find_vdef_for_var, patch_phis_for_virtual_defs,
5625 mark_old_loops, remove_dead_loops): New.
5626 (gloog): Rewritten.
5627 (graphite_trans_bb_move_loop): Call swap_loop_mapped_depth.
5628 (const_column_index, get_first_matching_sign_row_index,
5629 get_lower_bound_row, get_upper_bound_row, get_lower_bound,
5630 get_upper_bound): New.
5631 (graphite_trans_bb_strip_mine): Also update the iv map.
5632
5633 * graphite.h (graphite_loops_mapping, GBB_LOOPS_MAPPING): New.
5634 (struct name_tree): Add a loop field.
5635 (struct scop): Add a graphite_loops_mapping field.
5636 (SCOP_LOOPS_MAPPING): New.
5637 (debug_clast_stmt): Declare.
5638 * lambda.h (find_induction_var_from_exit_cond): Declare.
5639 (lambda-code.c): (find_induction_var_from_exit_cond): Extern.
5640 * cfgloop.h (update_dominators_in_loop): Removed declaration.
5641 (create_empty_loop_on_edge): Updated.
5642 * tree-flow.h (remove_bb, resize_phi_node, move_phi_node,
5643 rename_variables_in_bb): Declare.
5644 * tree-cfg.c (remove_bb): Extern.
5645
45489e99 5646 * gcc.dg/graphite/block-0.c: New.
2abae5f1
SP
5647
56482008-07-21 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
5649 Sebastian Pop <sebastian.pop@amd.com>
5650
5651 * graphite.c (strip_mine_profitable_p): New.
5652 (graphite_trans_bb_block): Disable strip mining if not profitable.
5653
45489e99
SP
5654 * gcc.dg/graphite/scop-18.c: New.
5655 * gcc.dg/graphite/scop-17.c: Fixed.
5656 * gcc.dg/graphite/scop-16.c: Fixed.
2abae5f1
SP
5657
56582008-07-17 Harsha Jagasia <harsha.jagasia@amd.com>
5659 Jan Sjodin <jan.sjodin@amd.com>
5660 Sebastian Pop <sebastian.pop@amd.com>
5661
5662 * graphite.c (is_interchange_valid): New.
5663 (graphite_trans_bb_block): Check loop nest of basic block for legality
5664 of interchange.
5665
5666 * graphite.h (gbb_inner_most_loop_index, outer_most_loop_1,
5667 outer_most_loop, gbb_outer_most_loop_index): New.
5668
5669 * tree-loop-linear.c (perfect_loop_nest_depth): Remove static.
5670 * tree-flow.h (perfect_loop_nest_depth): Declare as extern.
45489e99
SP
5671 * gcc.dg/graphite/scop-16.c: New.
5672 * gcc.dg/graphite/scop-17.c: New.
2abae5f1
SP
5673
56742008-07-11 Tobias Grosser <grosser@fim.uni-passau.de>
5675
5676 * graphite.c (scop_remove_ignoreable_gbbs): Also update bitmap.
5677 (graphite_trans_scop_block): Ignore SCoPs without bbs.
5678
56792008-07-11 Tobias Grosser <grosser@fim.uni-passau.de>
5680
5681 * graphite.c (new_scop): Initialize SCOP_EXIT.
5682 (scopdet_info): Add.
5683 (scopdet_bb_info): Rename from is_bb_addable. Cleanup, bugfixes.
5684 (build_scops_1): Cleanup, bugfixes.
5685 (build_scops): Cleanup.
5686
45489e99
SP
5687 * gcc.dg/graphite/scop-matmult.c: Remove duplicated code.
5688 * gcc.dg/graphite/scop-15.c: Add SCoP numbers.
2abae5f1
SP
5689
56902008-07-10 Harsha Jagasia <harsha.jagasia@amd.com>
5691
45489e99 5692 * gfortran.dg/graphite/scop-1.f: Update to reduced test case.
2abae5f1 5693
45489e99 5694 * gfortran.dg/graphite/graphite.exp: Use
2abae5f1
SP
5695 DEFAULT_GRAPHITE_FLAGS.
5696
45489e99 5697 * gcc.dg/graphite/scop-15.c: Update to reduced test case.
2abae5f1
SP
5698
56992008-07-10 Harsha Jagasia <harsha.jagasia@amd.com>
5700
5701 * graphite.c (scan_tree_for_params): Do not assert any more if
5702 MULT_EXPR parameter is negative.
5703
45489e99 5704 * gfortran.dg/graphite/scop-1.f: New.
2abae5f1 5705
45489e99 5706 * gfortran.dg/graphite/graphite.exp: New.
2abae5f1 5707
45489e99 5708 * gcc.dg/graphite/scop-15.c: New.
2abae5f1
SP
5709
57102008-07-10 Harsha Jagasia <harsha.jagasia@amd.com>
5711
5712 * graphite.c (is_bb_addable): Fix segfault in spec gzip and reformat.
5713
57142008-07-10 Tobias Grosser <grosser@fim.uni-passau.de>
5715
5716 * graphite.c (graphite_trans_bb_swap_loops): Rename from
5717 graphite_swap_loops.
5718 (graphite_trans_bb_move_loop): New.
5719 (graphite_trans_bb_strip_mine): Rename from graphite_strip_mine_loop.
5720 (graphite_trans_bb_block): New.
5721 (graphite_trans_loop_block): New.
5722 (graphite_trans_scop_swap_1and2): Rename from
5723 graphite_trans_swap_1and2.
5724 (graphite_trans_scop_strip): Rename from graphite_trans_strip.
5725 (graphite_trans_scop_block): New.
5726 (graphite_apply_transformations): Rename from
5727 graphite_transformations.
5728
45489e99 5729 * gcc.dg/graphite/scop-matmult.c: New.
2abae5f1
SP
5730
57312008-07-10 Tobias Grosser <grosser@fim.uni-passau.de>
5732
5733 * graphite.c (gbb_compare): New.
5734 (graphite_sort_gbbs): New.
5735 (gbb_can_be_ignored): New.
5736 (scop_remove_ignoreable_gbbs): New.
5737 (graphite_transformations): Cleanup and add
5738 scop_remove_ignoreable_gbbs.
5739 * lambda.h (lambda_vector_compare): New.
5740
57412008-07-09 Tobias Grosser <grosser@fim.uni-passau.de>
5742
5743 * graphite.c (print_graphite_bb): Correct printing of static schedule.
5744 (graphite_swap_loops): int -> unsigned
5745 (graphite_strip_mine_loop): int -> unsigned, Fix SCHEDULE
5746 (graphite_transformations): New.
5747 (graphite_transform_loops): Move to graphite_transformations.
5748 * graphite.h (gbb_nb_loops): Return unsigned.
5749
57502008-07-04 Tobias Grosser <grosser@fim.uni-passau.de>
5751
5752 * graphite.c (scan_tree_for_params): Fix insertion of parameters into
5753 the domain matrix. This makes scop-0.c work again.
5754
57552008-06-20 Richard Guenther <rguenther@suse.de>
5756
5757 * graphite.h: Adjust copyright to GPLv3.
5758 * graphite.c: Likewise.
5759 (stmt_simple_memref_for_scop_p): Split out from ...
5760 (stmt_simple_for_scop_p): ... here. Fix handling of calls
5761 and simplify.
5762 (get_bb_type): Optimize.
5763 (is_pred): Remove.
5764 (is_bb_addable): Fix memleak, replace is_pred call with
5765 single_pred.
5766 (build_scops): Use current_loops.
5767 (param_index): Fix memleak.
5768
57692008-06-20 Konrad Trifunovic <konrad.trifunovic@inria.fr>
5770
5771 * graphite.c: Fix formatting.
5772
57732008-06-19 Konrad Trifunovic <konrad.trifunovic@inria.fr>
5774
5775 * graphite.c (new_scop): Memory allocation for SCOP_{NEWIVS, OLDIVS}.
5776 (free_scop): Memory deallocation for SCOP_NEWIVS, SCOP_OLDIVS.
5777 (create_var_name, save_var_name): Newly defined functions.
5778 (initialize_cloog_names): Part of the code factored out to
5779 save_var_name.
5780 (clast_to_gcc_expression): Now handles the case of clast_red_sum
5781 in clast_reduction statement.
5782 (graphite_create_new_loop): Now takes a new parameter
5783 for outer_loop.
5784 (translate_clast): Now also takes the context_loop and bb_exit
5785 parameters. Rewritten the code so that it creates a gimple code
5786 inside the given context.
5787 (outermost_loop_layer, graphite_remove_iv, graphite_rename_ivs,
5788 remove_cond_expr, disconnect_cond_expr,
5789 disconnect_virtual_phi_nodes): Newly defined functions.
5790 * graphite.h (struct scop): added old_ivs vector.
5791 SCOP_OLDIVS: New macro.
5792
57932008-06-19 Sebastian Pop <sebastian.pop@amd.com>
5794
5795 * cfgloopmanip.c: Add missing function comments, fix formatting.
5796
57972008-06-18 Konrad Trifunovic <konrad.trifunovic@inria.fr>
5798
5799 * cfgloopmanip.c (update_dominators_in_loop): Defined.
5800 (create_empty_loop_on_edge): Defined.
5801 * tree-parloops.c (canonicalize_loop_ivs): Returns tree
5802 instead of void.
5803 * cfgloop.h (create_empty_loop_on_edge): Declared as extern.
5804 (update_dominators_in_loop): Declared as extern
5805 * tree-flow.h (canonicalize_loop_ivs): Declared as extern.
5806
58072008-06-16 Tobias Grosser <grosser@fim.uni-passau.de>
5808
5809 * graphite.c (print_graphite_bb): Allow changing number of loops
5810 in SCoP domain.
5811 (initialize_cloog_names): Allow changing number of loops.
5812 (build_cloog_prog): Simplify.
5813 (find_transform): Enable cloog option --strides.
5814 (graphite_swap_loops): New.
5815 (graphite_strip_mine_loop): New.
5816 (graphite_trans_swap_1and2): New.
5817 (graphite_trans_strip): New.
5818 (graphite_transform_loops): Add graphite_trans_strip.
5819 * graphite.h (scop_max_loop_depth): New.
5820
58212008-06-15 Tobias Grosser <grosser@fim.uni-passau.de>
5822
5823 * graphite.c (build_scop_iteration_domain): Remove forgotten
5824 line. (Fixes compile)
5825
58262008-06-15 Tobias Grosser <grosser@fim.uni-passau.de>
5827
5828 * graphite.c (print_graphite_bb): Add output of GBB_LOOPS.
5829 (build_graphite_bb): Add GBB_LOOPS and GBB_DOMAIN and reorder.
5830 (build_bb_loops): New.
5831 (graphite_transform_loops): Add build_bb_loops.
5832 (schedule_to_scattering): Use gbb_nb_loops to support changing loop
5833 numbers.
5834 * graphite.h (graphite_bb): Add loops.
5835 (gbb_nb_loops): New.
5836 (gbb_loop_at_index): New.
5837 (gbb_loop_index): New.
5838 (nb_params_in_scop): Renamed to scop_nb_params. Updated all functions
5839 using nb_params_in_scop.
5840
58412008-06-14 Tobias Grosser <grosser@fim.uni-passau.de>
5842
5843 * graphite.c (print_graphite_bb): Adapt to minimized schedule.
5844 (build_scop_canonical_schedules): Build minimized schedule.
5845 (schedule_to_scattering): Adapt to minimized schedule.
5846 * graphite.h (graphite_bb): Add/Update descriptions.
5847
58482008-06-14 Adrien Eliche <aeliche@isty.uvsq.fr>
5849 Tobias Grosser <grosser@fim.uni-passau.de>
5850
5851 * graphite.c (print_graphite_bb): Add condition printing.
5852 (dump_value): New.
5853 (dump_gbb_conditions): New.
5854 (build_scop_conditions_1): New.
5855 (build_scop_conditions): New.
5856 * graphite.h (graphite_bb): Add conditions.
5857
58582008-06-14 Tobias Grosser <grosser@fim.uni-passau.de>
5859
5860 * graphite.c (print_graphite_bb):
5861 (free_graphite_bb): New.
5862 (free_scop): Free bbs.
5863 (get_bb_type): Free doms.
5864 (build_scop_context): Free context matrix.
5865 (build_loop_iteration_domains): Remove unused code.
5866 (build_cloog_prog): Free scattering function and blocklist.
5867 (find_transform): Free options.
5868
58692008-06-13 Tobias Grosser <grosser@fim.uni-passau.de>
5870
5871 * graphite.c (loop_body_to_cloog_stmts): Rename to add_bb_domains.
5872 Remove unnecessery cloog data structures. Make a copy of the domain
5873 (setup_cloog_loop): Rename to build_loop_iteration_domains. Remove
5874 unnecessary cloog data structures. Fix memory leaks. Remove insert
5875 into SCOP_LOOP2CLOOG_LOOP as the inserted CloogLoops will never be
5876 used.
5877 (build_scop_iteration_domain): Remove unnecessary cloog
5878 data structures. Fix memory leaks.
5879 (graphite_transform_loops): Disable build_scop_dynamic_schedules as it
5880 uses SCOP_LOOP2CLOOG_LOOP, that is at the moment not working.
5881
58822008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
5883
5884 * graphite.c (find_scop_params): Remove initialize_cloog_names.
5885
58862008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
5887
5888 * graphite.c (end_scop): Style fix.
5889 (schedule_to_scattering): Style and comment fix.
5890
58912008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
5892 * graphite.c (print_graphite_bb): Fix definiton of
5893 schedule_to_scattering.
5894 (initialize_cloog_names): Change nb_scattdims to max loop
5895 depth in SCoP.
5896 (schedule_to_scattering): Take parameter for number of scattering
5897 dimensions.
5898 (build_cloog_prog): Only build as much scattering dimensions as
5899 necessary.
5900
59012008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
5902
5903 * graphite.c (end_scop): Disable bb splitting. Fixes SIGSEGV
5904 in polyhedron/aermod.f90.
5905
59062008-06-11 Tobias Grosser <grosser@fim.uni-passau.de>
5907 Dwarak Rajagopal <dwarak.rajagopal@amd.com>
5908 Harsha Jagasia <harsha.jagasia@amd.com>
5909
5910 * graphite.c (is_bb_addable): Fix segfault.
5911
59122008-06-10 Tobias Grosser <grosser@fim.uni-passau.de>
5913
5914 * graphite.c (is_bb_addable): Fix memory leak, handling of loops
5915 with multiple exits and conditional handling in edge cases.
5916 (is_loop_exit): Fix memory leak. (Forgotten in last commit)
5917
45489e99 5918 * gcc.dg/graphite/scop-14.c: New.
2abae5f1
SP
5919
59202008-06-06 Tobias Grosser <grosser@fim.uni-passau.de>
5921 Adrien Eliche <aeliche@isty.uvsq.fr>
5922
5923 * graphite.c (is_bb_addable): Add more comments and enhance
5924 readablity of the source code. Fix memory leak.
5925 (is_loop_exit): Fix memory leak.
5926
59272008-06-05 Tobias Grosser <grosser@fim.uni-passau.de>
5928
5929 * graphite.c (first_loop_in_scop): Deleted.
5930 (setup_cloog_loop): Only walk the loop chain for inner loops.
5931 (build_scop_iteration_domain): Execute setup_cloog_loop for
5932 all loops in the first layer.
5933
59342008-06-05 Tobias Grosser <grosser@fim.uni-passau.de>
5935
5936 * graphite.c (scan_tree_for_params): Change the way params are
5937 added to be indepenent of the number of loops.
5938 (setup_cloog_loop): Revert to short matrix format. Fix parameter
5939 handling.
5940 (build_cloog_prog): Revert to short matrix format.
5941
59422008-06-05 Sebastian Pop <sebastian.pop@amd.com>
5943 Dwarak Rajagopal <dwarak.rajagopal@amd.com>
5944
5945 * tree-loop-fusion.c (fuse_loops): Fix uninitialized variable
5946 warning.
5947
59482008-06-05 Sebastian Pop <sebastian.pop@amd.com>
5949
5950 * graphite.c (nb_data_refs_in_scop): New.
5951 (graphite_transform_loops): Print more stats: number of
5952 loops, basic blocks and data references per scop.
5953
59542008-06-04 Sebastian Pop <sebastian.pop@amd.com>
5955 Jan Sjodin <jan.sjodin@amd.com>
5956
5957 * graphite.c (loop_affine_expr, idx_record_params,
5958 find_scop_parameters, setup_cloog_loop): Use instantiate_scev
5959 instead of instantiate_parameters.
5960
59612008-06-04 Tobias Grosser <grosser@fim.uni-passau.de>
5962
5963 * graphite.c (schedule_to_scattering): Fix scattering dimensions,
5964 add support for parameters, add STATIC_SCHEDULE at the right places,
5965 cleanup.
5966
59672008-06-04 Tobias Grosser <grosser@fim.uni-passau.de>
5968
5969 * graphite.c (build_scop_loop_nests): Only add the loops, that
5970 are contained completely in the SCoP.
5971 (build_cloog_prog): Disable scattering, until schedule_to_scattering
5972 and the domains are fixed.
5973 (build_scop_canonical_schedules): Add support for bbs not contained
5974 in any SCoP.
5975
59762008-06-04 Tobias Grosser <grosser@fim.uni-passau.de>
5977
5978 * graphite.h (scop_contains_loop): Update comments to match
5979 the actual behavior.
5980 (scop_contains_loop): New.
5981 * graphite.c (schedule_to_scattering): Use scop_contains_loop.
5982
59832008-06-04 Sebastian Pop <sebastian.pop@amd.com>
5984
5985 * graphite.c (get_bb_type): On function body, i.e. loop_0,
5986 don't mark blocks as GBB_LOOP_SING_EXIT_HEADER, mark them
5987 as GBB_COND_HEADER.
5988
59892008-06-04 Sebastian Pop <sebastian.pop@amd.com>
5990 Tobias Grosser <grosser@fim.uni-passau.de>
5991
5992 * graphite.c (graphite_transform_loops): Early return when
5993 there are no loops in the function.
5994
59952008-05-31 Sebastian Pop <sebastian.pop@amd.com>
5996 Jan Sjodin <jan.sjodin@amd.com>
5997
5998 * graphite.c (scan_tree_for_params, setup_cloog_loop): Compute the
5999 offset of the last loop.
6000 (setup_cloog_loop): Copy the entire outer constraint matrix.
6001
60022008-05-31 Sebastian Pop <sebastian.pop@amd.com>
6003 Jan Sjodin <jan.sjodin@amd.com>
6004
6005 * graphite.c (stmt_in_scop_p, function_parameter_p,
6006 invariant_in_scop_p): Removed.
6007 (scan_tree_for_params): Can be used with no constraint
6008 matrix for gathering parameters.
6009 (idx_record_params): Don't use idx_record_param, instead use
6010 scan_tree_for_params.
6011 (find_scop_parameters): Same.
6012 (setup_cloog_loop, build_scop_iteration_domain, build_cloog_prog):
6013 Fix the size of loop domains.
6014 (schedule_to_scattering): Exit when the outer loop is not in scop.
6015 (find_transform): Enable build_cloog_prog.
6016
60172008-05-31 Sebastian Pop <sebastian.pop@amd.com>
6018 Jan Sjodin <jan.sjodin@amd.com>
6019
6020 * graphite.c (schedule_to_scattering): Make scattering domains
6021 uniformly of the same size, as required by CLooG 0.14.0 and before.
6022
60232008-05-31 Sebastian Pop <sebastian.pop@amd.com>
6024 Jan Sjodin <jan.sjodin@amd.com>
6025
6026 * graphite.c (schedule_to_scattering): Rewrite, correct the
6027 translation of the scheduling function to scattering.
6028 (build_cloog_prog): Call schedule_to_scattering only once.
6029 * graphite.h (scop_loop_index): Do not fail for loops not
6030 in the scop: return -1.
6031
60322008-05-30 Tobias Grosser <grosser@fim.uni-passau.de>
6033
6034 * graphite.c (build_graphite_bb): Initialize GBB_DOMAIN.
6035 (loop_body_to_cloog_stmts): Export GBB_DOMAIN.
6036 (setup_cloog_loop): Export GBB_DOMAIN.
6037 (build_cloog_prog): New. Create new CLOOG_PROG, which should be
6038 able to rebuild the original control flow.
6039 * graphite.h (graphite_bb): Add domain field and access macro.
6040 (GBB_DOMAIN): New.
6041
60422008-05-30 Sebastian Pop <sebastian.pop@amd.com>
6043
6044 * graphite.c (debug_gbb): New.
6045 (print_scop, build_graphite_bb): Use SCOP_BBS.
6046 (build_scop_bbs): Reimplemented.
6047 (dfs_bb_in_scop_p): Removed.
6048 (build_scop_loop_nests): Reorder loops inserted in
6049 SCOP_LOOP_NEST: outer loops should come first.
6050 (build_scop_canonical_schedules): Reinitialize at zero
6051 the components of the SCOP_STATIC_SCHEDULE for the loops
6052 that have already been parsed.
6053
6054 * graphite.h (debug_gbb): Declared.
6055
60562008-05-30 Sebastian Pop <sebastian.pop@amd.com>
6057 Jan Sjodin <jan.sjodin@amd.com>
6058
6059 * graphite.c (create_empty_loop): Renamed graphite_create_new_loop.
6060 (graphite_loop_to_gcc_loop): Removed.
6061 (remove_all_edges): New.
6062 (graphite_stmt_to_gcc_stmt): Renamed translate_clast.
6063 (gloog): Remove useless code.
6064
60652008-05-29 Tobias Grosser <grosser@fim.uni-passau.de>
6066
6067 * graphite.c (get_bb_type): Reworked. We distinguish between
6068 loops with one or multiple exits.
6069 (is_loop_exit): New.
6070 (is_pred): New.
6071 (is_bb_addable): Rework condition handling, now support for case
6072 case statements and loops with multiple exits.
6073
45489e99
SP
6074 * gcc.dg/graphite/scop-11.c: New.
6075 * gcc.dg/graphite/scop-12.c: New.
6076 * gcc.dg/graphite/scop-13.c: New.
2abae5f1
SP
6077
60782008-05-29 Tobias Grosser <grosser@fim.uni-passau.de>
6079
6080 * graphite.c (dot_all_scops_1): Fix some colors. Reuse colors, if
6081 we have too many colors.
6082
60832008-05-22 Sandeep Maram <smaram_b04@iiita.ac.in>
6084
6085 * doc/invoke.texi (-ftree-loop-fusion): Document.
6086 * tree-pass.h (pass_loop_fusion): Declared.
6087 * tree-loop-fusion.c: New.
6088 * timevar.def (TV_TREE_LOOP_FUSION): Declared.
6089 * tree-data-ref.c (find_data_references_in_loop): Make extern.
6090 * tree-data-ref.h (find_data_references_in_loop): Declared.
6091 * common.opt (ftree-loop-fusion): Declared.
6092 * Makefile.in (tree-loop-fusion.o): Added rule and to OBJS-common.
6093
60942008-05-21 Sebastian Pop <sebastian.pop@amd.com>
6095
6096 * graphite.c (build_access_matrix): Fix typo from the merge.
6097
60982008-05-20 Sebastian Pop <sebastian.pop@amd.com>
6099
6100 * Merge from mainline (130800:135673).
6101
61022008-05-07 Sebastian Pop <sebastian.pop@amd.com>
6103
6104 * graphite.c (end_scop): The exit of the scop is not part of the scop.
6105 Update dominators after splitting.
6106
61072008-05-07 Sebastian Pop <sebastian.pop@amd.com>
6108
6109 * graphite.c (is_bb_addable): Return the harmful statement.
6110 Factor up some code.
6111 (end_scop): New. Splits end of scope bbs on a harmful statement.
6112 (build_scops_1): Call end_scop.
6113
61142008-05-07 Sebastian Pop <sebastian.pop@amd.com>
6115
6116 * graphite.c: (succs_at_same_depth, end_scop, all_preds_visited_p,
6117 all_succs_visited_p, start_new_scop_for_each_succ, start_new_scop,
6118 add_dominators_to_open_scops, stop_last_open_scop, scop_end_loop,
6119 build_scops_1): Removed.
6120 (build_scops_2): Renamed build_scops_1.
6121
61222008-05-06 Sebastian Pop <sebastian.pop@amd.com>
6123
6124 * graphite.c: Fix formatting.
6125
61262008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
6127
6128 * graphite.c (get_bb_type): New.
6129 (move_scops): New.
6130 (build_scops_2): New.
6131 (is_bb_addable): New.
6132 (build_scops): Switch the scop detection.
6133 (build_scop_bbs): Add entry bb to scop.
6134 * graphite.h (struct scop): Update comment.
6135
61362008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
6137
6138 * graphite.c (dot_all_scops_1): Fix some incorrect colors and add
6139 more colors.
6140
61412008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
6142
45489e99
SP
6143 * gcc.dg/graphite/scop-1.c: Update.
6144 * gcc.dg/graphite/scop-2.c: Update.
6145 * gcc.dg/graphite/scop-4.c: Update.
6146 * gcc.dg/graphite/scop-5.c: Add.
6147 * gcc.dg/graphite/scop-6.c: Add.
2abae5f1
SP
6148
61492008-05-06 Sebastian Pop <sebastian.pop@amd.com>
6150
45489e99
SP
6151 * gcc.dg/graphite/scop-0.c: Add.
6152 * gcc.dg/graphite/scop-7.c: Add.
6153 * gcc.dg/graphite/scop-8.c: Add.
6154 * gcc.dg/graphite/scop-9.c: Add.
6155 * gcc.dg/graphite/scop-10.c: Add.
2abae5f1
SP
6156
61572008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
6158
6159 * graphite.c (scop_affine_expr): Renamed to loop_affine_expr.
6160 Check affine expressions depending on the outermost loop
6161 instead of a scop.
6162 (stmt_simple_for_scop_p): Same.
6163 (harmfule_stmt_in_scop): Same.
6164
61652008-04-28 Tobias Grosser <grosser@fim.uni-passau.de>
6166
6167 * graphite.c (dot_all_scops): Remove incorrect difficult bb coloring,
6168 mark entry and exit, that are not part of the SCoP and update HTML
6169 formatting.
6170
61712008-04-25 Sebastian Pop <sebastian.pop@amd.com>
6172
6173 * graphite.c (basic_block_simple_for_scop_p): Renamed
6174 harmful_stmt_in_bb.
6175 (save_scop, preds_at_same_depth, test_for_scop_bound): Removed.
6176 (add_dominators_to_open_scops, build_scops_1): Reimplemented.
6177 (all_preds_visited_p, all_succs_visited_p,
6178 start_new_scop_for_each_succ, start_new_scop, stop_last_open_scop,
6179 scop_end_loop): New.
6180 (build_scops): Do not use dfs_enumerate_from.
6181
45489e99 6182 * gcc.dg/graphite/scop-{1,2,4}.c: Updated.
2abae5f1
SP
6183
61842008-04-23 Sebastian Pop <sebastian.pop@amd.com>
6185
6186 * graphite.c: Add comments to functions that are missing a
6187 description.
6188 (graphite_create_iv): Removed. Merged in graphite_loop_to_gcc_loop.
6189
61902008-04-23 Sebastian Pop <sebastian.pop@amd.com>
6191
6192 * graphite.c (nb_params_in_scop): Moved...
6193 (graphite_bb_from_bb, loop_body_to_cloog_stmts): New.
6194 (setup_cloog_loop): Call loop_body_to_cloog_stmts.
6195 (clast_to_gcc_expression): Reduce column size to less than 80.
6196 (graphite_create_iv): Return the new name of the IV.
6197 (find_transform): Set options->esp and options->cpp.
6198 (gloog): Comment out the invalidation of the old loop code.
6199 (initialize_dependence_polyhedron): Replace scop_nb_params with
6200 nb_params_in_scop.
6201
6202 * graphite.h (nb_params_in_scop): ... here.
6203 (scop_nb_params): Removed.
6204 (loop_domain_dim): Return something even when the loop was not
6205 found in the hash table: avoid ICEing on all the graphite.exp
6206 testcases.
6207
62082008-04-14 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6209
6210 * tree-chrec.c (for_each_scev_op): SCEV can have 3 operands.
6211
6212 * graphite.c (build_scop_dynamic_schedules): Schedule is built
6213 according to nesting level.
6214 (find_scop_parameters): Call instantiate_parameters.
6215 (scan_tree_for_params): Extend it to handle general affine bounds.
6216 Inner loop bound can depend on outer loop induction variable.
6217 (setup_cloog_loop): tmp variable is allocated on stack. Call
6218 instantiate_parameters with respect to outermost_loop_in_scop.
6219 (loop_domain_dim, ref_nb_loops, loop_iteration_vector_dim): moved to
6220 graphite.h.
6221 (create_empty_loop): Function loopify should be given edge
6222 probability, instead of edge frequency. Dominance relation from
6223 switch_bb to loop_header.
6224 (clast_to_gcc_expression): Added handling of clast_reduction node.
6225 (gloog): New functionality for removing old loop.
6226 (test_dependence): Factored out from build_rdg_all_levels.
6227 (build_rdg_all_levels): Dependence testing factored out to
6228 test_dependence function.
6229
6230 * graphite.h (struct graphite_bb): Extended with dynamic_schedule.
6231 (loop_domain_dim, ref_nb_loops, loop_iteration_vector_dim): Moved
6232 from graphite.c
6233
62342008-04-07 Sebastian Pop <sebastian.pop@amd.com>
6235
6236 * graphite.c (free_scop, param_index, initialize_cloog_names,
6237 nb_params_in_scop): Use name_tree map instead of just a tree
6238 for keeping track of the variable name associated to that tree.
6239 (create_empty_loop, gmp_cst_to_tree, clast_name_to_gcc,
6240 clast_to_gcc_expression, graphite_create_iv,
6241 graphite_loop_to_gcc_loop, graphite_cond_to_gcc_cond,
6242 graphite_stmt_to_gcc_stmt): New.
6243 (gloog): Call these.
6244 * graphite.h (struct name_tree): New.
6245 (struct scop): Use name_tree instead of tree for params.
6246 Store a vector of name_tree for new_ivs.
6247 (SCOP_NEWIVS): New.
6248 (scop_nb_params): Use name_tree instead of tree.
6249
62502008-04-05 Alexander Lamaison <awl03@doc.ic.ac.uk>
6251 Sebastian Pop <sebastian.pop@amd.com>
6252
6253 * tree-bounds.c: New.
6254 * tree-bounds.h: New.
6255 * tree-pass.h: Declare pass_bounds_early and pass_bounds_late.
6256 * passes.c: Schedule pass_bounds_early, pass_bounds_late.
6257 * builtins.c (expand_builtin_alloca): Add flag_bounds as for
6258 flag_mudflap.
6259 * gcc.c: Same.
6260 * toplev.c: Same.
6261 * c-cppbuiltin.c: Same.
6262 * c-pragma.c: Same.
6263 * common.opt: Same.
6264 * varasm.c: Same.
6265 * tree-outof-ssa.c: Same.
6266 * c-common.c: Same.
6267 * Makefile.in: Same.
6268
62692008-03-15 Antoniu Pop <antoniu.pop@gmail.com>
6270 Sebastian Pop <sebastian.pop@amd.com>
6271
6272 * tree-loop-distribution.c (remaining_stmts,
6273 upstream_mem_writes): Removed static variables.
6274 (copy_loop_before, create_bb_after_loop,
6275 mark_nodes_having_upstream_mem_writes, free_rdg_components,
6276 rdg_build_components, rdg_build_partitions,
6277 dump_rdg_partitions): Extern.
6278 (generate_loops_for_partition, generate_code_for_partition): Do not
6279 return a bool.
6280 (already_processed_vertex_p, predecessor_has_mem_write,
6281 mark_nodes_having_upstream_mem_writes, has_upstream_mem_writes,
6282 rdg_flag_all_uses, rdg_flag_uses, rdg_flag_vertex_and_dependent,
6283 rdg_flag_loop_exits, rdg_flag_similar_memory_accesses,
6284 build_rdg_partition_for_component, rdg_build_partitions, ldist_gen):
6285 Pass remaining_stmts and upstream_mem_writes as parameters.
6286 (rdg_component): Moved...
6287 (build_rdg_partition_for_component): Do not aggregate components when
6288 flag_streamize_loops is set.
6289 (gen_sequential_loops): New.
6290 (ldist_gen): Call gen_sequential_loops.
6291
6292 * tree-pass.h (pass_loop_streamization): Declared.
6293
6294 * omp-low.c (expand_omp_sections): Call add_bb_to_loop on created
6295 basic blocks when loops structures exist.
6296
6297 * builtin-types.def (BT_FN_VOID_PTR_PTR_INT): New.
6298
6299 * tree-ssa-loop-ivopts.c (expr_invariant_in_region_p): New.
6300
6301 * tree-parloops.c (take_address_of, eliminate_local_variables_1,
6302 eliminate_local_variables_stmt, eliminate_local_variables,
6303 separate_decls_in_loop_name, separate_decls_in_loop_stmt,
6304 separate_decls_in_loop, gen_parallel_loop): Make them work on a region
6305 of code delimited by two edges in the CFG.
6306 (separate_decls_in_loop_name): Renamed separate_decls_in_region_name.
6307 (separate_decls_in_loop_stmt): Renamed separate_decls_in_region_stmt.
6308 (separate_decls_in_loop): Renamed separate_decls_in_region. Isolate
6309 the case of parallelisation of reductions.
6310 (create_loop_fn): Extern.
6311 (create_omp_parallel_region): New.
6312
6313 * tree-data-ref.c (dump_data_dependence_relation): Don't call
6314 dump_data_reference for printing dra and drb.
6315 (create_rdg_edge_for_ddr, create_rdg_edges_for_scalar): Initialise
6316 RDGE_RELATION.
6317 (build_rdg): Don't call free_dependence_relations for the moment, as
6318 we attach dependence relations on each edge of the RDG.
6319 To be fixed later.
6320
6321 * tree-data-ref.h (rdg_component): ...here.
6322 (struct rdg_edge): New field ddr_p relation.
6323 (RDGE_RELATION): New.
6324 (create_bb_after_loop, copy_loop_before,
6325 mark_nodes_having_upstream_mem_writes, rdg_build_components,
6326 rdg_build_partitions, dump_rdg_partitions,
6327 free_rdg_components): Declared.
6328
6329 * omp-builtins.def (BUILT_IN_GOMP_STREAM_ALIGN_PUSH,
6330 BUILT_IN_GOMP_STREAM_ALIGN_POP): New.
6331
6332 * tree-loop-streamization.c: New.
6333
6334 * tree-flow.h (gather_blocks_in_sese_region, create_loop_fn,
6335 create_omp_parallel_region, expr_invariant_in_region_p): Declared.
6336
6337 * Makefile.in (tree-loop-streamization.o): Added to OBJS-common.
6338
6339 * tree-cfg.c (gather_blocks_in_sese_region): Extern.
6340
6341 * passes.c: Schedule pass_loop_streamization.
6342
63432008-03-08 Tobias Grosser <grosser@fmi.uni-passau.de>
6344
6345 * graphite.c (dot_all_scops_1): Fix formatting for difficult bbs and
6346 update comment.
6347
63482008-03-07 Tobias Grosser <grosser@fim.uni-passau.de>
6349
6350 * graphite.c (dot_all_scops): Update formatting.
6351 Bbs can now be part of more than one SCoP.
6352
63532008-03-04 Sebastian Pop <sebastian.pop@amd.com>
6354
6355 * graphite.c (new_loop_to_cloog_loop_str, setup_cloog_loop): Fix
6356 malloc problems.
6357 (loop_domain_dim): Check for unregistered toplev SCOP loop.
6358 * graphite.h (loop_to_cloog_loop): New.
6359
63602008-03-04 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6361
6362 * graphite.c (loop_domain_dim, ref_nb_loops,
6363 loop_iteration_vector_dim): New.
6364 (build_access_matrix_with_af, build_access_matrix,
6365 initialize_dependence_polyhedron): Fixed for new matrix layout.
6366 No longer assume that all iteration domains are of the same
6367 dimensionality.
6368
63692008-03-02 Sebastian Pop <sebastian.pop@amd.com>
6370
6371 * tree-scalar-evolution.c (instantiate_parameters_1): An SSA_NAME
6372 defined in a loop at depth 0 is invariant.
6373 * tree-chrec.c (evolution_function_is_invariant_rec_p): Ditto.
6374 * tree-ssa-loop-ivopts.c (expr_invariant_in_loop_p): Should never
6375 be called at loop depth 0.
6376
6377 * graphite.c (basic_block_simple_for_scop_p): Take the scop as
6378 a parameter.
6379 (dot_all_scops_1): Update use of basic_block_simple_for_scop_p.
6380 (down_open_scop): Removed.
6381 (loop_in_scop_p): Redefined.
6382 (scop_affine_expr): New argument: scop.
6383 (stmt_simple_for_scop_p): New argument: scop. RETURN_EXPR is not
6384 a harmful statement ending a scop.
6385 (basic_block_simple_for_scop_p): New argument: scop.
6386 (get_loop_start): Removed.
6387 (new_scop): Initialize SCOP_LOOPS.
6388 (free_scop): Free SCOP_LOOPS.
6389 (succs_at_same_depth, preds_at_same_depth): New.
6390 (end_scop): Test the validity of a scop.
6391 (add_dominators_to_open_scops): New.
6392 (test_for_scop_bound): Call add_dominators_to_open_scops.
6393 Add cases for opening and closing multiple scops.
6394 (build_scops, build_scop_bbs): Iterate over basic blocks in
6395 depth first order.
6396 (build_graphite_bb): Pass scop directly.
6397 (dfs_bb_in_scop_p): New.
6398 (scop_record_loop): Use SCOP_LOOPS for not recording the same loop
6399 several times.
6400 (nb_loops_around_gb): Use loop_in_scop_p.
6401 (schedule_to_scattering): Disabled for the moment the code computing
6402 the "textual order for outer loop".
6403
6404 * graphite.h (struct scop): New field loops.
6405 (SCOP_LOOPS): New.
6406 (scop_loop_index): Test that the given loop belongs to SCOP_LOOPS.
6407
45489e99 6408 * gcc.dg/graphite/scop-{1,...,7}.c: Updated.
2abae5f1
SP
6409
64102008-02-27 Antoniu Pop <antoniu.pop@gmail.com>
6411 Sebastian Pop <sebastian.pop@amd.com>
6412
6413 * builtin-types.def (BT_FN_PTR_SIZE_UINT, BT_FN_BOOL_PTR): New.
6414 * common.opt (fstreamize-loops): New.
6415 * omp-builtins.def (BUILT_IN_GOMP_STREAM_CREATE,
6416 BUILT_IN_GOMP_STREAM_PUSH, BUILT_IN_GOMP_STREAM_HEAD,
6417 BUILT_IN_GOMP_STREAM_POP, BUILT_IN_GOMP_STREAM_EOS_P,
6418 BUILT_IN_GOMP_STREAM_SET_EOS, BUILT_IN_GOMP_STREAM_DESTROY): New.
6419
64202008-02-22 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6421
6422 * tree-data-ref.c (build_empty_rdg): New.
6423 (build_rdg): Use it.
6424 * tree-data-ref.h (build_empty_rdg): Declared.
6425 * graphite.c (free_scop): Free SCOP_LOOP2CLOOG_LOOP.
6426 (find_vertex_for_stmt): Removed.
6427 (build_rdg_all_levels): Use build_empty_rdg and rdg_vertex_for_stmt.
6428
64292008-02-21 Sebastian Pop <sebastian.pop@amd.com>
6430
6431 * tree-loop-distribution.c (generate_builtin): After cancelling the
6432 loop tree, also delete basic blocks.
6433 (rdg_flag_uses): Stop recursion when a vertex has already been
6434 processed.
6435
64362008-02-15 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6437
6438 * graphite.c (build_scop_alpha): Removed.
6439 (graphite_transform_loops): Add a dummy call to build_all_rdg_levels
6440 and dump_dependence_graph to avoid compiler warnings.
6441
64422008-02-14 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6443
6444 * tree-data-ref.c (dr_may_alias_p, create_rdg_vertices): Extern.
6445 * tree-data-ref.h (dr_may_alias_p, create_rdg_vertices): Declared.
6446 * graphite.c (new_loop_to_cloog_loop_str, hash_loop_to_cloog_loop,
6447 eq_loop_to_cloog_loop, del_loop_to_cloog_loop): New.
6448 (new_scop, setup_cloog_loop): Initialize SCOP_LOOP2CLOOG_LOOP.
6449 (initialize_dependence_polyhedron, find_vertex_for_stmt,
6450 initialize_data_dependence_polyhedron, is_empty_polyhedron,
6451 statement_precedes_p, build_rdg_all_levels, build_scop_alpha,
6452 dump_dependence_graph): New.
6453 * graphite.h (struct graphite_bb): New field compressed_alpha_matrix.
6454 (GBB_ALPHA): New.
6455 (struct scop): New field loop2cloog_loop.
6456 (SCOP_LOOP2CLOOG_LOOP, struct data_dependence_polyhedron,
6457 RDGE_DDP, ddp_p, struct loop_to_cloog_loop_str): New.
6458
64592008-02-10 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6460
6461 * graphite.c (build_graphite_bb): Fix initialization
6462 of the graphite basic block.
6463
64642008-02-05 Sebastian Pop <sebastian.pop@amd.com>
6465
6466 * graphite.c (scan_tree_for_params): Rewrite for the new layout of
6467 loop domain matrix. Pass in the number of loops contained in the
6468 constraint matrix.
6469 (nb_loops_around_gb): Moved before setup_cloog_loop that uses it.
6470 (setup_cloog_loop): Rewrite for the new layout of loop domain matrix:
6471 loops that are not surrounding the current loop are not represented
6472 in the domain constraint matrix.
6473 (build_scop_iteration_domain): Initial domain constraint matrix
6474 contains only the eq/ineq, cst, and scop parameters columns.
6475
64762008-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
6477
6478 * graphite.c (schedule_to_scattering, nb_loops_around_gb): New.
6479 (print_graphite_bb): Print scattering.
6480
64812008-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
6482
6483 * graphite.c (initialize_cloog_names): Initialize names of
6484 scattering variables.
6485
64862009-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
6487
6488 * graphite.c (dot_all_scops_1): Disable debug output while
6489 printing graph.
6490
64912008-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
6492
6493 * graphite.c (find_transform): Change cloog output language to C.
6494
64952008-01-27 Sebastian Pop <sebastian.pop@amd.com>
6496
6497 * tree-loop-distribution.c (generate_memset_zero,
6498 generate_builtin, generate_code_for_partition,
6499 rdg_flag_all_uses): New.
6500 (rdg_flag_uses): Gather in the same partition the statements defining
6501 the VUSES of the current statement.
6502 (rdg_flag_similar_stores): Renamed rdg_flag_similar_memory_accesses.
6503 Gather in the same partition not only the stores to the same memory
6504 access, but also the reads.
6505 (ldist_generate_loops): Renamed ldist_gen.
6506
65072008-01-24 Sebastian Pop <sebastian.pop@amd.com>
6508 Tobias Grosser <grosser@fmi.uni-passau.de>
6509
6510 * graphite.c (setup_cloog_loop): Chain all cloog loops with the
6511 next pointer, don't use the inner pointer.
6512
65132008-01-20 Tobias Grosser <grosser@fmi.uni-passau.de>
6514
6515 * graphite.c (dot_all_scops, dot_all_scops_1): New.
6516 (find_transform): Call dot_all_1.
6517 * graphite.h (dot_all_scops): Declared.
6518
65192007-12-14 Sebastian Pop <sebastian.pop@amd.com>
6520
6521 * tree-loop-distribution.c: Fix apsi.f ICE.
6522 (create_bb_after_loop): New.
6523 (generate_loops_for_partition): Use it.
45489e99 6524 * gfortran.dg/ldist-1.f90: New.
2abae5f1
SP
6525
6526 * tree-data-ref.c (dot_rdg): Use /tmp/rdg.dot for dotty format.
6527 * graphite.c (dot_scop): Use /tmp/scop.dot for dotty format.
6528
65292007-12-13 Tobias Grosser <grosser@fmi.uni-passau.de>
6530
6531 * graphite.c (find_transform): Dump cloog program sent to cloog.
6532
65332007-12-13 Tobias Grosser <grosser@fmi.uni-passau.de>
6534
6535 * graphite.c (initialize_cloog_names): Initialize cloog
6536 iterator names.
6537
65382007-12-13 Tobias Grosser <grosser@fmi.uni-passau.de>
6539
6540 * graphite.c (build_scop_context): Fix typo, for the matrix
6541 format: insert '0 >= 0' instead of '-1 >= 0'.
6542
65432007-12-13 Sebastian Pop <sebastian.pop@amd.com>
6544
6545 * Fix merge problems.
6546
65472007-12-13 Sebastian Pop <sebastian.pop@amd.com>
6548
6549 * graphite.c (setup_cloog_loop): Fix typo.
6550
65512007-12-12 Sebastian Pop <sebastian.pop@amd.com>
6552
6553 * doc/invoke.texi (-ftree-loop-distribution): Documented.
6554 * tree-loop-distribution.c: Reimplemented.
6555 * tree-pass.h (pass_loop_distribution): New.
6556 * tree-scalar-evolution.c (number_of_iterations_for_all_loops): Use
6557 print_loops.
6558 * graphds.h (struct graph): New field indexes.
6559 * timevar.def (TV_TREE_LOOP_DISTRIBUTION): New.
6560
6561 * tree-vect-analyze.c: Remove declaration of static functions when not
6562 needed.
6563 * tree-vectorizer.c: Same.
6564 (rename_variables_in_loop): Now extern.
6565 (slpeel_tree_duplicate_loop_to_edge_cfg): Renamed
6566 tree_duplicate_loop_to_edge_cfg. Reset PENDING_STMT for edges after
6567 calling redirect_edge_and_branch_force.
6568
6569 * tree-vectorizer.h (tree_duplicate_loop_on_edge): Declared.
6570
6571 * tree-data-ref.c: Don't include tree-chrec.h.
6572 (debug_data_dependence_relations): New.
6573 (dump_data_dependence_relation): Call dump_data_reference on data refs
6574 in the relation.
6575 (same_access_functions): Moved...
6576 (find_vertex_for_stmt): Renamed rdg_vertex_for_stmt.
6577 (dump_rdg_vertex, debug_rdg_vertex, dump_rdg_component,
6578 debug_rdg_component, dump_rdg, debug_rdg, dot_rdg_1, dot_rdg,
6579 struct rdg_vertex_info, ): New.
6580 (create_rdg_edge_for_ddr): Compute the dependence level before looking
6581 at DDR_REVERSED_P.
6582 (create_rdg_vertices): Initialize the htab of graph->indexes.
6583 Initialize RDG_MEM_WRITE_STMT and RDG_MEM_READS_STMT.
6584 (stmts_from_loop): Don't save LABEL_EXPR.
6585 (hash_stmt_vertex_info, eq_stmt_vertex_info,
6586 hash_stmt_vertex_del): New.
6587 (build_rdg): Initialize rdg->indexes.
6588 (free_rdg, stores_from_loop, ref_base_address,
6589 rdg_defs_used_in_other_loops_p, have_similar_memory_accesses,
6590 have_similar_memory_accesses_1, ref_base_address_1,
6591 remove_similar_memory_refs): New.
6592
6593 * tree-data-ref.h: Include tree-chrec.h.
6594 (debug_data_dependence_relations): Declared.
6595 (same_access_functions): ...here. Now static inline.
6596 (ddr_is_anti_dependent, ddrs_have_anti_deps,
6597 ddr_dependence_level): New.
6598 (struct rdg_vertex): New fields has_mem_write, has_mem_reads.
6599 (RDGV_HAS_MEM_WRITE, RDGV_HAS_MEM_READS, RDG_STMT, RDG_MEM_WRITE_STMT,
6600 RDG_MEM_READS_STMT): New.
6601 (dump_rdg_vertex, debug_rdg_vertex, dump_rdg_component,
6602 debug_rdg_component, dump_rdg, debug_rdg, dot_rdg,
6603 rdg_vertex_for_stmt): Declared.
6604 (struct rdg_edge): New field level.
6605 (RDGE_LEVEL, free_rdg): New.
6606 (stores_from_loop, remove_similar_memory_refs,
6607 rdg_defs_used_in_other_loops_p,
6608 have_similar_memory_accesses): Declared.
6609 (rdg_has_similar_memory_accesses): New.
6610
6611 * lambda.h (dependence_level): New.
6612 * common.opt (ftree-loop-distribution): New.
6613 * tree-flow.h (debug_loop_ir): Renamed debug_loops.
6614 (print_loop_ir): Renamed print_loops.
6615 (debug_loop, debug_loop_num, print_loops_bb, mark_virtual_ops_in_bb,
6616 tree_duplicate_loop_to_edge_cfg, rename_variables_in_loop): Declared.
6617 * Makefile.in (TREE_DATA_REF_H): Depends on tree-chrec.h.
6618 (tree-loop-distribution.o): Added.
6619 * tree-cfg.c (mark_virtual_ops_in_region): Use mark_virtual_ops_in_bb.
6620 (mark_virtual_ops_in_bb): New.
6621 (print_loops_bb, debug_loop_num, debug_loop): New.
6622 * passes.c: Scheduled pass_loop_distribution.
6623
66242007-12-12 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6625
6626 * graphite.c (scan_tree_for_params): Correct the number of columns
6627 for polylib format.
6628 (nb_flat_iterator): New.
6629 (setup_cloog_loop): Initialize to 1 the first column for inequalities.
6630 (build_scop_iteration_domain): Correct the number of columns for
6631 polylib format.
6632
66332007-12-12 Sebastian Pop <sebastian.pop@amd.com>
6634
6635 * Merge from mainline (129697:130800).
6636
66372007-10-30 Sebastian Pop <sebastian.pop@amd.com>
6638
6639 * graphite.c (build_graphite_bb): SCoP's basic blocks are post
6640 dominated by SCoP's exit.
6641 (graphite_transform_loops): Compute post dominators.
6642
66432007-10-28 Sebastian Pop <sebastian.pop@amd.com>
6644
6645 * Merge from mainline (127169:129697).
6646
66472007-10-28 Sebastian Pop <sebastian.pop@amd.com>
6648
6649 * graphite.c (affine_expr): Renamed scop_affine_expr. Use an extra
6650 parameter for the basic block that contains the expression. Use
6651 outermost_loop_in_scop for evolution_function_is_affine_multivariate_p.
6652 (stmt_simple_for_scop_p): Pass to scop_affine_expr the basic block of
6653 the expression.
6654 * graphite.h (gbb_loop): New.
6655 (GBB_LOOP): Removed.
6656
66572007-08-03 Sebastian Pop <sebpop@gmail.com>
6658
6659 * Makefile.in: Fix merge problem.
6660
66612007-08-03 Sebastian Pop <sebpop@gmail.com>
6662
6663 * Merge from mainline (125309:127169).
6664 * tree-loop-distribution.c: Disabled.
6665
66662007-06-05 Sebastian Pop <sebpop@gmail.com>
6667
6668 * Merge from mainline (r123693:125309).
6669
66702007-05-30 Sebastian Pop <sebpop@gmail.com>
6671
6672 * tree-loop-distribution.c (correct_modify_expr_p): Renamed
6673 correct_modify_p
6674 (correct_modify_p, check_statements, number_of_lvalue_uses,
6675 number_of_scalar_dependences, create_edges): Use GIMPLE_MODIFY_STMT
6676 instead of MODIFY_EXPR.
6677 (update_edge_with_ddv): Don't pass index_of_edge. Initialize
6678 and push new edges.
6679
66802007-05-24 Sebastian Pop <sebpop@gmail.com>
6681
6682 * tree-loop-distribution.c (struct rdg): Replace arrays by
6683 VECs for edges and vertices.
6684 (RDG_NBV, RDG_NBE, RDG_VERTEX, RDG_EDGE): Removed.
6685 (RDGV_NB_PARTITIONS): New.
6686 (PRDG_NBV, PRDG_NBE): Removed.
6687 (build_scc_graph, correct_partitions_p, mark_partitions, build_prdg,
6688 dump_rdg, find_vertex_with_stmt, create_vertices, free_rdg,
6689 number_of_scalar_dependences, create_edges, build_rdg): Use VECs.
6690
66912007-05-17 Georges-Andre Silber <silber@cri.ensmp.fr>
6692 Sebastian Pop <sebpop@gmail.com>
6693
6694 * doc/invoke.texi (-ftree-loop-distribution): Document.
6695 * tree-loop-distribution.c: New file.
6696 * tree-pass.h (pass_loop_distribution): Declared.
6697 * timevar.def (TV_TREE_LOOP_DISTRIBUTION): New.
6698 * tree-data-ref.c (initialize_data_dependence_relation): Initialize
6699 and set reversed_p.
6700 * tree-data-ref.h (data_dependence_relation): Add reversed_p.
6701 (DDR_REVERSED_P): New.
6702 * common.opt (-ftree-loop-distribution): New.
6703 * tree-flow.h (distribute_loops): Declared.
6704 * Makefile.in (OBJS-common): Depend on tree-loop-distribution.o.
6705 * passes.c (init_optimization_passes): Schedule loop distribution.
6706
67072007-05-12 Sebastian Pop <sebastian.pop@inria.fr>
6708
6709 * graphite.c (print_graphite_bb): Don't call dump_data_references.
6710 (print_scop): Don't print when scop is NULL.
6711 (build_scop_context, find_transform): Don't output to stderr.
6712
67132007-05-09 Sebastian Pop <sebastian.pop@inria.fr>
6714
6715 * tree-data-ref.c: Don't include graphite.h.
6716 Comment out the code for printing data reference's scop.
6717 (build_access_matrix_with_af): Moved...
6718 * tree-data-ref.h (build_access_matrix_with_af): Removed declaration.
6719 * graphite.c (build_access_matrix_with_af): ... here. Now static.
6720 (print_graphite_bb): Print basic block's schedule.
6721 (print_scop): Don't print the schedule, call cloog's pretty printer.
6722 (bb_in_scop_p): A basic block is in a scop only if it is both
6723 dominated and postdominated by the scop's entry and exit basic blocks.
6724 (function_parameter_p): New.
6725 (invariant_in_scop_p): Use function_parameter_p.
6726 (new_scop, save_scop): New.
6727 (end_scop, test_for_scop_bound, build_scops): Use new_scop, and
6728 save_scop.
6729 (scan_tree_for_params): Directly build the constraint as CloogMatrix.
6730 (loop_in_scop_p): New.
6731 (scop_record_loop): Use loop_in_scop_p.
6732 (build_scop_domain): Renamed build_scop_iteration_domain.
6733 (setup_cloog_loop, initialize_cloog_names, find_scop_parameters,
6734 nb_params_in_scop, build_scop_context, first_loop_in_scop,
6735 setup_cloog_loop, dot_scop_1, dot_scop): New.
6736 * graphite.h (GBB_LOOP, SCOP_PROG, dot_scop): New.
6737 (struct scop): Add a pointer to cloog's representation of a program.
6738
67392007-04-14 Sebastian Pop <sebastian.pop@inria.fr>
6740
6741 * doc/invoke.texi (-ftree-check-verbose): Renamed
6742 -ftree-checks-verbose.
6743 * common.opt (flag_tree_check_verbose): Renamed
6744 flag_tree_checks_verbose.
6745 * tree-check.c (tree_check_warning): Use flag_tree_checks_verbose.
6746
67472007-04-14 Sebastian Pop <sebastian.pop@inria.fr>
6748
6749 * configure: Regenerated.
6750 * config.in: Regenerated.
6751 * tree-ssa-loop.c (graphite_transforms): Execute
6752 graphite_transform_loops only when HAVE_cloog.
6753 * configure.ac (HAVE_polylib, HAVE_cloog, GRAPHITE): Defined.
6754 * graphite.c: Include polylibgmp.h and cloog.h.
6755 (graphite_transform_loops): Removed loops parameter.
6756 * tree-flow.h (graphite_transform_loops): Update declaration.
6757 * Makefile.in (POLYLIBLIBS, POLYLIBINC, CLOOGLIBS, CLOOGINC): New.
6758 (LIBS): Depend on CLOOGLIBS and on POLYLIBLIBS.
6759 (INCLUDES): Depend on POLYLIBINC and on CLOOGINC.
6760 (OBJS-common): Remove dependence on graphite.o.
6761 (BACKEND): Depend on @GRAPHITE@.
6762
67632007-04-13 Sebastian Pop <sebastian.pop@inria.fr>
6764
6765 * doc/invoke.texi (-ftree-check-verbose): Documented.
45489e99
SP
6766 * gcc.dg/tree-checker/tree-checks-1.c: New.
6767 * gcc.dg/tree-checker/tree-checks-2.c: New.
6768 * gcc.dg/tree-checker/tree-checks-3.c: New.
6769 * gcc.dg/tree-checker/tree-checks-4.c: New.
6770 * gcc.dg/tree-checker/tree-checks.exp: New.
6771 * gcc.dg/tree-checker/condates.crp: New.
2abae5f1
SP
6772 * common.opt (ftree-checks-verbose): New.
6773 * tree-check.c (tree_check_warning): Move extra stderr output
6774 under control of flag_tree_check_verbose.
6775
67762007-04-12 Sebastian Pop <sebastian.pop@inria.fr>
6777
6778 * tree-match.c: Fix comments formatting.
6779 * tree-match.h: Fix comments formatting.
6780 * tree-check.c: Fix comments formatting.
6781 (tree_check_init): Restructure.
6782
67832007-04-12 Nic Volanschi <nic.volanschi@free.fr>
6784
6785 * doc/invoke.texi (-ftree-check, -ftree-checks): Documented.
6786
67872007-04-10 Sebastian Pop <sebastian.pop@inria.fr>
6788
6789 * Merge from mainline (r120733:123693).
6790
67912007-03-20 Nic Volanschi <nic.volanschi@free.fr>
6792
6793 * condate.y: New file.
6794 * tree-match.h (struct patt_info_s): New field sign.
6795 (struct condate_s): New field msg.
6796 (normalize_condate, name_condate, add_condate): New.
6797 (conds[], condate_parse): Made extern.
6798 * tree-check.c (tree_check_warning): First arg changed to cond;
6799 warning reformatted.
6800 (tree_check_init): Reset the TREE_VISITED bit on every CFG node.
6801 (tree_scan): New.
6802 (tree_check): Process trivial condates.
6803 (read_delimited_string): Removed.
6804 (print_cond): Print name and msg.
6805 (conds[]): Made extern.
6806 (parse_tree_check_file_once): Rewritten to use the parser in
6807 condate.y.
6808 Processing of option --tree_check_string moved to tree_scan().
6809 * Makefile.in: Added condate.y
6810
68112007-03-12 Sebastian Pop <sebastian.pop@inria.fr>
6812
6813 * tree-pretty-print.c (dump_generic_bb_buff, lazy_dump_generic_node):
6814 Use VECs instead of varrays.
6815 * diagnostic.h (lazy_dump_generic_node): Update declaration.
6816 * Makefile.in (pretty-print.o): Depend on vec.h.
6817 * pretty-print.c: Include tree.h and vec.h.
6818 (pp_clear_state, pp_write_list_to_stream, pp_base_format,
6819 pp_base_format, pp_construct, pp_base_string, pp_lazy_mode,
6820 new_tree_chunk, pp_add_tree, pp_add_string, pp_add_char, pp_write_list,
6821 pp_free_list): Use VECs instead of varrays.
6822 * pretty-print.h: Do not include varray.h.
6823 (struct tree_chunk_s): Declaration moved before its use.
6824 (output_buffer): Rename varray field to chunks.
6825 * tree-match.c (tree_equal, chunk_1st_char, chunks_lookahead,
6826 tree_1st_char, match_chunks_pattinfo, match_tree_pattinfo,
6827 save_global_holes): Use VECs instead of varrays.
6828 * tree-match.h: Declare VECs of cfg_node, and hole_p.
6829 * tree-check.c (scan_cfg_stmts, push_node,
6830 print_matching_stmt): Removed.
6831 (tree_check_instance, push_global_holes_if_new, tree_check,
6832 execute_tree_check): Use VECs instead of varrays.
6833 (gate_tree_check): Don't execute the CFG check when basic_block_info
6834 is not available.
6835
68362007-01-12 Sebastian Pop <sebastian.pop@inria.fr>
6837
6838 * Merge from mainline (r115016:120733).
6839
68402007-01-12 Sebastian Pop <sebastian.pop@inria.fr>
6841
6842 * Merge from mainline (r117632:117661).
6843
68442007-01-12 Sebastian Pop <sebastian.pop@inria.fr>
6845
6846 * tree-dump.c (dump_option_value_in): Add TDF_DEBUG.
6847 * tree-pass.h (TDF_DEBUG, debug_p): New.
6848 * tree-scalar-evolution.c (set_scalar_evolution, get_scalar_evolution,
6849 get_scalar_evolution, add_to_evolution, set_nb_iterations_in_loop,
6850 get_loop_exit_condition, analyze_evolution_in_loop,
6851 analyze_initial_condition, analyze_scalar_evolution,
6852 instantiate_parameters, number_of_latch_executions): Use debug_p.
6853 * tree-chrec.c (chrec_apply): Use debug_p.
6854 * tree-data-ref.c: Include graphite.h.
6855 (dump_data_reference): Print also the access matrix.
6856 (analyze_array, analyze_indirect_ref, init_data_ref,
6857 analyze_offset_expr, address_analysis, object_analysis,
6858 create_data_ref, finalize_ddr_dependent,
6859 non_affine_dependence_relation, analyze_ziv_subscript,
6860 analyze_siv_subscript_cst_affine,
6861 compute_overlap_steps_for_affine_1_2, analyze_subscript_affine_affine,
6862 can_use_analyze_subscript_affine_affine, analyze_siv_subscript,
6863 analyze_miv_subscript, analyze_overlapping_iterations,
6864 build_classic_dist_vector, subscript_dependence_tester,
6865 compute_affine_dependence, analyze_all_data_dependences): Use debug_p.
6866 (build_access_matrix_with_af): No longer static.
6867 * tree-data-ref.h (scop_p): ... declaration here.
6868 (data_reference.scop): New field.
6869 (DR_SCOP, DR_ACCESS_MATRIX): New.
6870 (build_access_matrix_with_af, dr_num_subscripts): Declared.
6871 * graphite.c (print_graphite_bb): Call dump_data_references.
6872 (print_scop): Use scop_nb_loops and scop_dim_domain.
6873 (test_for_scop_bound): Use debug_p.
6874 (scan_tree_for_params): Use scop_nb_loops, scop_nb_loops and
6875 scop_nb_params.
6876 (scop_loop_index): Moved...
6877 (scop_record_loop): New.
6878 (build_scop_loop_nests): Use scop_record_loop.
6879 (build_scop_domain): Use scop_dim_domain.
6880 (build_access_matrix): Implemented.
6881 (build_scop_canonical_schedules): Use scop_nb_loops.
6882 (build_graphite_bb): Initialize GBB_SCOP.
6883 * graphite.h (scop_p): Moved...
6884 (graphite_bb.scop): New field.
6885 (graphite_bb.iteration_domain, GBB_DOMAIN, scop.nb_params,
6886 scop.nb_loops, scop.dim_domain, SCOP_NB_LOOPS, SCOP_NB_PARAMS,
6887 SCOP_DIM_DOMAIN, SCOP_STMTS): Removed.
6888 (scop_nb_params, scop_nb_loops, scop_dim_domain, gbb_dim_domain,
6889 scop_loop_index): New.
6890 * Makefile.in (tree-data-ref.o): Depends on graphite.h.
6891
68922007-01-05 Sebastian Pop <sebastian.pop@inria.fr>
6893
6894 * Merge from mainline (r117661:120450).
6895
68962006-10-12 Sebastian Pop <sebastian.pop@inria.fr>
6897
6898 * tree-scalar-evolution.c (instantiate_parameters_1): Don't stop
6899 at the first declaration outside the varying loop, instantiate as
6900 far as possible.
6901 * tree-chrec.c (for_each_scev_op): New.
6902 * tree-chrec.h (for_each_scev_op): Declared.
6903 * tree-ssa-loop.c (pass_graphite_trans): Don't dump the function.
6904 * tree-data-ref.c (get_references_in_stmt,
6905 find_data_references_in_stmt): New, from trunk.
6906 (find_data_references_in_loop): Use get_references_in_stmt
6907 and find_data_references_in_loop, modified as in trunk.
6908 (build_access_matrix_with_af): New.
6909 * tree-data-ref.h (data_reference): Add a field access_matrix.
6910 (data_ref_loc): New, as in trunk.
6911 * graphite.c (print_graphite_bb, bb_in_scop_p, stmt_in_scop_p,
6912 invariant_in_scop_p, param_index, scan_tree_for_params,
6913 scop_loop_index, build_scop_loop_nests, build_scop_domain, irp_data,
6914 idx_record_param, idx_record_params, build_access_matrix,
6915 build_scop_data_accesses, build_scop_canonical_schedules,
6916 build_graphite_bb, build_scop_bbs, find_params_in_bb,
6917 build_scop_params): New.
6918 * graphite.h (graphite_bb): New.
6919 (scop): Add fields static_schedule, params, loop_nest,
6920 iteration_domain.
6921 * lambda.h: Declare vecs of lambda_matrix.
6922 * tree-flow.h (print_loop_ir_bb): Declared.
6923 * tree-cfg.c (print_loop_ir_bb): New.
6924 (print_loop): Use print_loop_ir_bb.
6925
69262006-10-12 Sebastian Pop <pop@cri.ensmp.fr>
6927
6928 * Merge from mainline (r115016:117632).
6929
69302006-10-11 Sebastian Pop <pop@cri.ensmp.fr>
6931
6932 * graphite.c (debug_scops): Adjust definition for avoiding a bootstrap
6933 break due to a warning.
6934
69352006-10-10 Sebastian Pop <pop@cri.ensmp.fr>
6936
6937 * graphite.c (print_scops, debug_scops): New.
6938 (graphite_transform): Renamed graphite_find_transform.
6939 * graphite.h (debug_scops): Declared.
6940
69412006-08-17 Sebastian Pop <pop@cri.ensmp.fr>
6942
6943 * tree-match.c: Reformat following the GNU style.
6944 * tree-match.h: Reformat following the GNU style.
6945 * tree-pattern.h: Removed empty file.
6946 * Makefile.in: Remove references to tree-pattern.h.
6947 * tree-check.c: Reformat following the GNU style.
6948 (execute_tree_check): Move gate condition code to...
6949 (gate_tree_check): ...here. New function.
6950 (pass_check): Use the gate function.
6951
69522006-07-04 Nic Volanschi <nic.volanschi@free.fr>
6953
6954 * tree-pattern.h: New. Tree pattern matching and checking using
6955 concrete syntax.
6956 * tree-check.c: New. Tree/CFG checking pass.
6957 * tree-match.c: New. Library for tree pattern matching.
6958 * opts.c, common.opt: Add options --ftree-check & --ftree-checks.
6959 * toplev.c, flags.h: Add globals for tree-check pass.
6960 * Makefile.in: Integrate the files in tree-check pass.
6961 * timevar.def, tree-optimize.c, tree-pass.h: Register tree-check pass.
6962 * pretty-print.c, pretty-print.h, tree-pretty-print.c, diagnostic.h:
6963 Introduce a "lazy" pretty-print mode.
6964 * tree.c, tree.h: Add tree_name.
6965
69662006-07-04 Sebastian Pop <pop@cri.ensmp.fr>
6967
6968 * doc/invoke.texi (-fgraphite): Correct typo.
6969 * tree-scalar-evolution.c (number_of_iterations_for_all_loops): Update
6970 use of print_loop_ir.
45489e99
SP
6971 * gcc.dg/graphite/scop-1.c: New.
6972 * gcc.dg/graphite/scop-2.c: New.
6973 * gcc.dg/graphite/graphite.exp: New.
2abae5f1
SP
6974 * graphite.c: Include domwalk.h.
6975 (print_scop): Print only the entry and exit blocks.
6976 (debug_scop): No longer static.
6977 (affine_expr): Fix formating. Return also true when the expression is
6978 constant.
6979 (stmt_simple_for_scop_p): Fix formating.
6980 (build_scops): Use domwalk.
6981 (get_loop_start, end_scop, test_for_scop_bound): New.
6982 (graphite_transform_loops): Avoid printing on stderr.
6983 * graphite.h (debug_scop): Declared.
6984 * tree-flow.h (debug_loop_ir, print_loop_ir): Update declarations.
6985 * Makefile.in (graphite.o): Depend on domwalk.h.
6986 * tree-cfg.c (print_loop, print_pred_bbs, print_succ_bbs): Remove
6987 declarations for static functions.
6988 (print_loop, print_loop_ir, debug_loop_ir): Use an extra parameter for
6989 controlling output verbosity.
6990
69912006-06-26 Sebastian Pop <pop@cri.ensmp.fr>
6992 Plesco Alexandru <shurikx@gmail.com>
6993
6994 * doc/invoke.texi (-fgraphite): Document.
6995 * tree-pass.h (pass_graphite_transforms): Declared.
6996 * timevar.def (TV_GRAPHITE_TRANSFORMS): New.
6997 * tree-ssa-loop.c (graphite_transforms, gate_graphite_transforms): New.
6998 (pass_graphite_transforms): Defined.
6999 * tree-data-ref.c (free_data_ref, data_reference): Extern.
7000 * tree-data-ref.h (free_data_ref, data_reference): Declared.
7001 * graphite.c, graphite.h: New.
7002 * common.opt (fgraphite): Declared.
7003 * tree-flow.h (graphite_transform_loops): Declared.
7004 * Makefile.in (OBJS-common): Add graphite.o.
7005 (graphite.o): New rule.
7006 * passes.c (pass_graphite_transforms): Scheduled.
7007