]> gcc.gnu.org Git - gcc.git/blame - gcc/ChangeLog.graphite
graphite-poly.h (enum POLY_DR_TYPE): Renamed poly_dr_type.
[gcc.git] / gcc / ChangeLog.graphite
CommitLineData
e6dec0fb
SP
12009-08-25 Sebastian Pop <sebastian.pop@amd.com>
2
3 * graphite-poly.h (enum POLY_DR_TYPE): Renamed poly_dr_type.
4 (struct poly_dr): Same.
5 (new_poly_dr): Same.
6 * graphite-poly.c (new_poly_dr): Same.
7
baf4b881
KT
82009-08-25 Konrad Trifunovic <konrad.trifunovic@gmail.com>
9 Sebastian Pop <sebastian.pop@amd.com>
10
11 * graphite-blocking.c (pbb_strip_mine_loop_depth): Renamed
12 pbb_strip_mine_time_depth. Changed the implementation so that
13 transformation is expressed as a transformation on
14 time (scatttering) dimensions. Also, ensures that the 2d+1
15 scheduling format is preserved.
16 (pbb_strip_mine_profitable_p): Profitability is based on the
17 iteration number of a given time (scattering) dimension,
18 and not on a original loop depth dimension.
19 (pbb_strip_mine): Call pbb_number_of_iterations_at_time.
20 (pbb_do_strip_mine): Call psct_dynamic_dim.
21 * graphite-poly.c (pbb_number_of_iterations_at_time): New.
22 * graphite-poly.h (pbb_number_of_iterations_at_time): Declared.
23 (pbb_nb_dynamic_scattering_transform): New.
24 (psct_dynamic_dim): New.
25
059a5f9f
KT
262009-08-25 Konrad Trifunovic <konrad.trifunovic@gmail.com>
27
28 * graphite-ppl.c (ppl_max_for_le): Renamed ppl_max_for_le_pointset.
29 * graphite-ppl.h (ppl_max_for_le): Renamed ppl_max_for_le_pointset.
30 * graphite-poly.c (pbb_number_of_iterations): Rename ppl_max_for_le.
31 * graphite-interchange.c (build_linearized_memory_access): Same.
32 (memory_stride_in_loop): Same.
33
afae0207
SP
342009-08-25 Sebastian Pop <sebastian.pop@amd.com>
35
36 * graphite-dependences.c (pddr_original_scattering): New.
37 (graphite_legal_transform_dr): Call pddr_original_scattering.
38 (dot_deps_1): New.
39 (dot_deps): New.
40 * graphite-dependences.h (dot_deps): Declared.
41 * graphite-poly.c (new_poly_dr): Initialize PDR_ID.
42 (print_pdr): Print PDR_ID.
43 * graphite-poly.h (struct poly_dr): Add field id.
44 (PDR_ID): New.
45 (pbb_index): New.
46 * graphite-scop-detection.c (dot_all_scops_1): Cleanup comment.
47
f8e0bb8b
SP
482009-08-22 Sebastian Pop <sebastian.pop@amd.com>
49
50 * graphite-dependences.c (graphite_carried_dependence_level_k): Do
51 not delete the original dependence relation.
52
532009-08-21 Sebastian Pop <sebastian.pop@amd.com>
54
55 * graphite-dependences.c (graphite_legal_transform_bb): Avoid
56 the computation of symmetric data dependence relations.
57 (dependency_between_pbbs_p): Same.
58
e37f165f
SP
592009-08-21 Sebastian Pop <sebastian.pop@amd.com>
60
61 * graphite-dependences.c (new_poly_dr_pair): Renamed new_poly_ddr.
62 (eq_poly_dr_pair_p): Renamed eq_poly_ddr_p.
63 (hash_poly_dr_pair_p): Renamed hash_poly_ddr_p.
64 (free_poly_ddr): New.
65 (pddr_is_empty): New.
66 (dependence_polyhedron_1): Now returns a poly_ddr_p.
67 (dependence_polyhedron): Same. Remove useless gcc_assert.
68 Remove fprintfs.
69 (graphite_legal_transform_dr): Call pddr_is_empty and free_poly_ddr.
70 (graphite_carried_dependence_level_k): Call pddr_is_empty.
71 * graphite-dependences.h (enum poly_dependence_kind): New.
72 (poly_dr_pair): Renamed poly_ddr. Added a field kind.
73 (PDRP_SOURCE): Renamed PDDR_SOURCE.
74 (PDRP_SINK): Renamed PDDR_SINK.
75 (PDRP_DDP): Renamed PDDR_DDP.
76 (PDDR_KIND): New.
77 (free_poly_ddr): Declared.
78 * graphite-poly.c (new_scop): Use the new hash function names.
79 * graphite-poly.h (struct scop): Renamed field original_pdr_pairs
80 into original_pddrs.
81 (SCOP_ORIGINAL_PDR_PAIRS): Renamed SCOP_ORIGINAL_PDDRS.
82
832009-08-21 Sebastian Pop <sebastian.pop@amd.com>
84
85 * Merge from mainline (150764:150992).
86
45e76e9f
SP
872009-08-18 Sebastian Pop <sebastian.pop@amd.com>
88
89 * cfgloopmanip.c (create_empty_loop_on_edge): Generate upper
90 bounds with LT_EXPR to make niter analysis more precise on code
91 generated by Graphite.
92
66b466c3
SP
932009-08-18 Sebastian Pop <sebastian.pop@amd.com>
94
95 * graphite-dependences.c (graphite_legal_transform_dr): Fix formatting.
96 (graphite_legal_transform_bb): Same.
97 (poly_drs_may_alias_p): Same.
98
f263917c
SP
992009-08-15 Sebastian Pop <sebastian.pop@amd.com>
100
101 PR middle-end/40981
102 * graphite-ppl.c (ppl_max_for_le): Correct the use of
103 ppl_Pointset_Powerset_C_Polyhedron_maximize.
104
1052009-08-13 Sebastian Pop <sebastian.pop@amd.com>
106
107 * graphite-poly.c (print_pbb): Print PBB index.
108
1092009-08-13 Sebastian Pop <sebastian.pop@amd.com>
110
111 * Merge from mainline (r150672:150764).
112
1132009-08-13 Sebastian Pop <sebastian.pop@amd.com>
114
115 * graphite-interchange.c (ppl_max_for_le): Moved...
116 * graphite-poly.c (pbb_number_of_iterations): Call ppl_max_for_le.
117 * graphite-ppl.c (ppl_max_for_le): ... here.
118 * graphite-ppl.h (ppl_max_for_le): Declared.
119
1202009-08-12 Sebastian Pop <sebastian.pop@amd.com>
121
122 * Merge from mainline (r150372:150672).
123
30de1632
SP
1242009-08-11 Sebastian Pop <sebastian.pop@amd.com>
125
126 PR middle-end/40980
127 * sese.c (convert_for_phi_arg): New.
128 (add_guard_exit_phis): Use convert_for_phi_arg.
129
130 * testsuite/gfortran.dg/graphite/id-17.f: New.
131
8c31ebfa
SP
1322009-08-11 Sebastian Pop <sebastian.pop@amd.com>
133
134 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Dont add
135 unknown subscript upper bounds.
136
137 * testsuite/gcc.dg/graphite/interchange-6.c: Un-XFAIL.
138
fb9fb290
SP
1392009-08-11 Sebastian Pop <sebastian.pop@amd.com>
140 Pranav Garg <pranav.garg2107@gmail.com>
141
142 * graphite-interchange.c (gather_access_strides): Removed.
143 (ppl_max_for_le): New.
144 (build_linearized_memory_access): New.
145 (memory_stride_in_loop): New.
146 (pbb_interchange_profitable_p): Reimplemented.
147 * graphite-ppl.h (ppl_new_id_map): New.
148 (ppl_interchange): New.
149
150 * testsuite/gcc.dg/graphite/interchange-6.c: XFAILed.
151
312aea7f
SP
1522009-08-11 Sebastian Pop <sebastian.pop@amd.com>
153
154 * graphite-interchange.c (compute_subscript): Removed.
155 (compute_array_size_cstr): Removed.
156 (compute_array_size_poly): Removed.
157 (compute_array_size): Removed.
158 (gather_access_strides_poly): Removed.
159 (gather_access_strides): Empty.
160
25d7cc15
SP
1612009-08-11 Sebastian Pop <sebastian.pop@amd.com>
162
163 * graphite-dependences.c (dependence_polyhedron_1): Replace
164 pdr_nb_subscripts with PDR_NB_SUBSCRIPTS.
165 (graphite_legal_transform_dr): Same.
166 (graphite_carried_dependence_level_k): Same.
167 * graphite-poly.c (new_poly_dr): Add a parameter nb_subscripts.
168 Initialize PDR_NB_SUBSCRIPTS.
169 (print_pdr_access_layout): Replace pdr_nb_subscripts with
170 PDR_NB_SUBSCRIPTS.
171 * graphite-poly.h (struct poly_dr): Add nb_subscripts field.
172 (PDR_NB_SUBSCRIPTS): New.
173 (pdr_nb_subscripts): Removed.
174 (pdr_dim): Simplified.
175 * graphite-sese-to-poly.c (build_poly_dr): Replace pdr_nb_subscripts
176 with PDR_NB_SUBSCRIPTS.
177
66096911
SP
1782009-08-11 Sebastian Pop <sebastian.pop@amd.com>
179
180 * graphite-interchange.c (compute_array_size): Remove use of
181 PDR_DATA_CONTAINER.
182 * graphite-poly.c (new_poly_dr): Remove argument data_container.
183 Do not initialize PDR_DATA_CONTAINER.
184 (print_pdr): Do not print PDR_DATA_CONTAINER.
185 * graphite-poly.h (struct poly_dr): Remove data_container field.
186 (PDR_DATA_CONTAINER): Removed.
187 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Remove use of
188 PDR_DATA_CONTAINER.
189 (build_poly_dr): Same.
190
273c5dd3
SP
1912009-08-11 Sebastian Pop <sebastian.pop@amd.com>
192
193 * testsuite/gcc.dg/graphite/interchange-9.c: New.
194
7491e5f0
KT
1952009-08-05 Konrad Trifunovic <konrad.trifunovic@gmail.com>
196 Sebastian Pop <sebastian.pop@amd.com>
197
198 * graphite-dependences.c (graphite_legal_transform_dr): Work on a
199 copy of the dependence polyhedron. Free the temporary objects.
200 (graphite_carried_dependence_level_k): Free unused objects before
201 returning.
202
203 * testsuite/gcc.dg/graphite/interchange-1.c: XFAILed.
204 * testsuite/gcc.dg/graphite/interchange-2.c: XFAILed.
205 * testsuite/gcc.dg/graphite/interchange-3.c: XFAILed.
206 * testsuite/gcc.dg/graphite/interchange-4.c: XFAILed.
207 * testsuite/gcc.dg/graphite/interchange-7.c: XFAILed.
208
f4648ed1
SP
2092009-08-05 Sebastian Pop <sebastian.pop@amd.com>
210
211 * graphite-blocking.c (scop_do_strip_mine): Call store_scattering.
212 Early return without analyzing the data dependences if no
213 transform has been done. Call restore_scattering if the transform
214 is not legal.
215 (graphite-interchange.c): Same.
216 * graphite-poly.c (print_scattering_function): Test for PBB_TRANSFORMED.
217 (graphite_read_transforms): Initialize PBB_TRANSFORMED.
218 (apply_poly_transforms): Do not gcc_assert that
219 the transform is legal.
220 (new_poly_bb): Initialize PBB_TRANSFORMED, PBB_SAVED, and PBB_ORIGINAL.
221 Do not initialize PBB_NB_SCATTERING_TRANSFORM, PBB_NB_LOCAL_VARIABLES,
222 PBB_TRANSFORMED_SCATTERING, and PBB_ORIGINAL_SCATTERING.
223 (free_poly_dr): Free PBB_TRANSFORMED, PBB_SAVED, and PBB_ORIGINAL.
224 * graphite-poly.h (struct poly_scattering): New.
225 (struct poly_bb): Add original, transformed, and saved fields.
226 Remove transformed_scattering, original_scattering, nb_local_variables,
227 and nb_scattering_transform fields.
228 (PBB_ORIGINAL, PBB_TRANSFORMED, PBB_SAVED): New.
229 (poly_scattering_new): New.
230 (poly_scattering_free): New.
231 (poly_scattering_copy): New.
232 (store_scattering_pbb): New.
233 (store_scattering): New.
234 (restore_scattering_pbb): New.
235 (restore_scattering): New.
236 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons):
237 Initialize PBB_TRANSFORMED and PBB_ORIGINAL.
273c5dd3 238
e31a5bd4
SP
2392009-08-05 Sebastian Pop <sebastian.pop@amd.com>
240
241 * graphite-poly.c (print_pbb): Add parentheses in the pretty print.
242 (print_scop): Same.
243
8e88f9fd
SP
2442009-08-05 Sebastian Pop <sebastian.pop@amd.com>
245
246 * Makefile.in (graphite.o): Depends on PREDICT_H.
247 * graphite.c: Include predict.h.
248 (graphite_finalize): Call tree_estimate_probability.
249 * predict.c (predict_loops): Do not call scev_initialize and
250 scev_finalize.
251 (tree_estimate_probability_bb): New.
252 (tree_estimate_probability): Do not initialize loops: move that
253 code to the driver. Call tree_estimate_probability_bb.
254 (tree_estimate_probability_driver): New.
255 (pass_profile): Use tree_estimate_probability_driver.
256 * predict.h (tree_estimate_probability): Declared.
257
87d4d0ee
SP
2582009-08-05 Sebastian Pop <sebastian.pop@amd.com>
259
260 * graphite-clast-to-gimple.c (gloog): Add time to TV_GRAPHITE_CODE_GEN.
261 * graphite-dependences.c (graphite_legal_transform): Add time to
262 TV_GRAPHITE_DATA_DEPS.
263 (dependency_between_pbbs_p): Same.
264 * timevar.def (TV_GRAPHITE_DATA_DEPS, TV_GRAPHITE_CODE_GEN): New.
265
2662009-08-03 Sebastian Pop <sebastian.pop@amd.com>
267
268 * Merge from mainline (r149952:150372).
269
2abae5f1
SP
2702009-07-28 Sebastian Pop <sebastian.pop@amd.com>
271
272 * ChangeLog.graphite: Fix indenting, white spaces and 80 columns.
273 * graphite-blocking.c: Same.
274 * graphite-clast-to-gimple.c: Same.
275 * graphite-dependences.c: Same.
276 * graphite-poly.c: Same.
277 * graphite-poly.h: Same.
278 * graphite-ppl.c: Same.
279 * graphite-scop-detection.c: Same.
280 * graphite-sese-to-poly.c: Same.
281 * graphite.c: Same.
282
2832009-07-28 Sebastian Pop <sebastian.pop@amd.com>
284
285 * graphite-sese-to-poly.c (loop_entry_phi_arg): New.
286 (remove_simple_copy_phi): New.
287 (remove_invariant_phi): New.
288 (simple_copy_phi_p): New.
289 (reduction_phi_p): New.
290 (gsi_for_ssa_name_def): New.
291 (insert_out_of_ssa_copy): New.
292 (insert_out_of_ssa_copy_on_edge): New.
293 (create_zero_dim_array): New.
294 (scalar_close_phi_node_p): New.
295 (rewrite_close_phi_out_of_ssa): New.
296 (rewrite_phi_out_of_ssa): New.
297 (rewrite_reductions_out_of_ssa): New.
298 (build_poly_scop): Call rewrite_reductions_out_of_ssa.
299
300 * testsuite/gcc.dg/graphite/id-11.c: New.
301 * testsuite/gcc.dg/graphite/id-15.c: New.
302 * testsuite/gcc.dg/graphite/interchange-1.c: Un-XFAIL.
303 * testsuite/gcc.dg/graphite/interchange-2.c: Un-XFAIL.
304 * testsuite/gcc.dg/graphite/interchange-3.c: Un-XFAIL.
305 * testsuite/gcc.dg/graphite/interchange-4.c: Un-XFAIL.
306 * testsuite/gcc.dg/graphite/interchange-7.c: Un-XFAIL.
307 * testsuite/gcc.dg/graphite/scop-matmult.c: Un-XFAIL.
308 * testsuite/gfortran.dg/graphite/id-13.f: New.
309 * testsuite/gfortran.dg/graphite/id-5.f: New.
310
3112009-07-28 Sebastian Pop <sebastian.pop@amd.com>
312
313 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not
314 check that nb_reductions_in_loop is zero.
315 * graphite-scop-detection.c (harmful_stmt_in_bb): Don't filter out
316 reduction phi nodes.
317 (nb_reductions_in_loop): Removed.
318 (graphite_can_represent_loop): Do not call nb_reductions_in_loop.
319 * graphite-sese-to-poly.c (phi_node_is_iv): Removed.
320 (bb_contains_non_iv_scalar_phi_nodes): Removed.
321 (scop_contains_non_iv_scalar_phi_nodes): Removed.
322 (build_poly_scop): Do not call scop_contains_non_iv_scalar_phi_nodes.
323
3242009-07-28 Sebastian Pop <sebastian.pop@amd.com>
325
326 * graphite-clast-to-gimple.c (build_cloog_prog): Do not code generate
327 statements that have an empty iteration domain.
328 * testsuite/gfortran.dg/graphite/id-16.f: New.
329
3302009-07-28 Sebastian Pop <sebastian.pop@amd.com>
331
332 * tree-scalar-evolution.c (instantiate_scev_1): Return
333 chrec_dont_know when the result is not above instantiate_below.
334 * graphite-scop-detection.c (scopdet_basic_block_info): Fix formatting.
335 * graphite-sese-to-poly.c (create_linear_expr_from_tree): Assert that
336 the tree has a known scalar evolution.
337 * testsuite/gfortran.dg/graphite/id-14.f: New.
338 * testsuite/gfortran.dg/graphite/id-15.f: New.
339
3402009-07-28 Sebastian Pop <sebastian.pop@amd.com>
341
342 * sese.c (rename_variables_in_stmt): Pass in an extra parameter
343 insert_gsi.
344 (rename_variables): Keep inserting renames after the ones already
345 inserted.
346
3472009-07-28 Sebastian Pop <sebastian.pop@amd.com>
348
349 * graphite-sese-to-poly.c (compare_bb_depths): New.
350 (graphite_sort_dominated_info): New.
351 (build_scop_bbs_1): Call graphite_sort_dominated_info.
352 (build_scop_scattering): Fix comment.
353
3542009-07-28 Sebastian Pop <sebastian.pop@amd.com>
355
356 * graphite.c (graphite_finalize): Call print_loops instead of
357 dump_function_to_file.
358 * testsuite/gcc.dg/graphite/graphite.exp: Fix formatting.
359 * testsuite/gcc.dg/graphite/pr35356-1.c: New. Look for the number of
360 loops generated in the graphite output file.
361 * testsuite/gcc.dg/graphite/pr35356-2.c: New.
362 * testsuite/gcc.dg/graphite/pr35356-3.c: New. XFAILed for now.
363 * testsuite/gfortran.dg/graphite/id-12.f: New.
364
3652009-07-24 Li Feng <nemokingdom@gmail.com>
366
367 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-8.c:
368 Remove 2 XFAIL.
369
3702009-07-24 Li Feng <nemokingdom@gmail.com>
371 Tobias Grosser <grosser@fim.uni-passau.de>
372
373 * graphite-sese-to-poly.c (pdr_add_alias_set): Use data reference's
374 alias set number build alias in ACCESSES polyhedron.
375 (build_alias_set_for_drs): New.
376 (build_pbb_drs): Added build_alias_set_for_drs.
377 * graphite-dependences.c (poly_drs_may_alias_p): New.
378 (graphite_carried_dependence_level_k): Check alias information
379 before building polyhedron.
380
3812009-07-24 Tobias Grosser <grosser@fim.uni-passau.de>
382
383 * Makefile.in (lambda-code.o): Fix formatting.
384
3852009-07-24 Tobias Grosser <grosser@fim.uni-passau.de>
386
387 * Merge from mainline (r149350-149952)
388
3892009-07-18 Tobias Grosser <grosser@fim.uni-passau.de>
390
391 * graphite-poly.c (apply_poly_transforms): Move strip_mine
392 before interchange to prepare for loop blocking.
393
3942009-07-18 Tobias Grosser <grosser@fim.uni-passau.de>
395
396 * graphite-poly.c (apply_poly_transforms): Add checks after every
397 transformation.
398 * graphite-sese-to-poly.c (build_poly_scop): Remove check, as already
399 done in apply_poly_transforms.
400
4012009-07-17 Konrad Trifunovic <konrad.trifunovic@gmail.com>
402
403 * graphite-dependences.c (build_lexicographically_gt_constraint):
404 Replace RES parameter with *RES.
405 (dependence_polyhedron_1): Pass an address of the parameter RES
406 instead of value of RES.
407
4082009-07-16 Sebastian Pop <sebastian.pop@amd.com>
409
410 * graphite.c (graphite_finalize): Fix comment.
411 (graphite_transform_loops): Reset scev info after code generation
412 of each scop.
413
4142009-07-16 Sebastian Pop <sebastian.pop@amd.com>
415
416 * graphite.c (graphite_finalize): Call scev_reset.
417
4182009-07-16 Sebastian Pop <sebastian.pop@amd.com>
419
420 * graphite-clast-to-gimple.c (compute_cloog_iv_types): Do not create
421 GBB_CLOOG_IV_TYPES hash table twice.
422 * graphite-sese-to-poly.c (free_gimple_bb): Call free_data_refs.
423 (add_condition_to_domain): Clear GMP values.
424
4252009-07-16 Sebastian Pop <sebastian.pop@amd.com>
426
427 * graphite-dependences.c: Fix formatting.
428 * graphite-poly.c (free_poly_dr): Also free PDR_DATA_CONTAINER.
429 (pbb_number_of_iterations): Free ppl_Linear_Expression.
430 * graphite-sese-to-poly.c: Fix formatting.
431 * graphite.c (graphite_transform_loops): Create the hash table
432 after the early return.
433
4342009-07-16 Sebastian Pop <sebastian.pop@amd.com>
435
436 * testsuite/gcc.dg/graphite/id-14.c: New.
437 * testsuite/gcc.dg/graphite/pr40157.c: New.
438 * testsuite/gfortran.dg/graphite/id-11.f: New.
439
4402009-07-16 Sebastian Pop <sebastian.pop@amd.com>
441
442 * graphite-sese-to-poly.c (nb_pbbs_in_loops): New.
443 (build_poly_scop): Return false when there are no pbbs within
444 loops to avoid to pass to cloog scops with no loops.
445
4462009-07-16 Sebastian Pop <sebastian.pop@amd.com>
447
448 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons): Avoid
449 useless test "i % 2".
450 (build_pbb_scattering_polyhedrons): Fix formatting.
451 (build_poly_dr): Same.
452 * graphite.c (graphite_transform_loops): Restructure.
453
4542009-07-14 Razya Ladelsky <razya@il.ibm.com>
455
456 * tree-ssa-loop-manip.c (rewrite_phi_with_iv): Remove
457 reduction_list parameter.
458 (rewrite_all_phi_nodes_with_iv): Same.
459 (canonicalize_loop_ivs): Same.
460 * tree-parloops.c (struct brli): Removed.
461 (build_reduction_list_info): Removed.
462 (build_new_reduction): New.
463 (analyze_reduction_list): Removed.
464 (gather_scalar_reductions): Find reductions instead of phi
465 nodes that can't be canonicalized.
466 (try_create_reduction_list): Remove reduction_list parameter.
467 (gen_parallel_loop): Same.
468 (parallelize_loops): Remove analyze_reductions variable,
469 initialization and free.
470 Change reduction_list htab initialization to reduction_info
471 elements instead of ssa names.
472 Call try_create_reduction_list and gen_parallel_loop without
473 analyzed_reduction argument.
474 * graphite-clast-to-gimple (graphite_loop_normal_form): Call
475 canonicalize_loop_ivs with one less argument.
476 * tree-flow.h (canonicalize_loop_ivs): Remove one argument.
477
4782009-07-14 Konrad Trifunovic <konrad.trifunovic@gmail.com>
479
480 * graphite-dependences.c (new_poly_dr_pair): New.
481 (dependence_polyhedron): Renamed into dependence_polyhedron_1.
482 (new_poly_dr_pair): New.
483 (eq_poly_dr_pair_p): New.
484 (hash_poly_dr_pair_p): New.
485 * graphite-dependences.h (struct poly_dr_pair): New.
486 (eq_poly_dr_pair_p): Declared.
487 (hash_poly_dr_pair_p): Declared.
488 * graphite-poly.c (new_scop): Initialize SCOP_ORIGINAL_PDR_PAIRS.
489 (free_scop): Free SCOP_ORIGINAL_PDR_PAIRS.
490 * graphite-poly.h (struct scop): Add original_pdr_pairs field.
491 * Makefile.in (graphite-poly.o): Add dependence on
492 graphite-dependences.h.
493
4942009-07-14 Sebastian Pop <sebastian.pop@amd.com>
495
496 * graphite-scop-detection.c (graphite_can_represent_scev): Do not let
497 polynomials of degree > 1 pass to Graphite.
498 * tree-chrec.c (scev_is_linear_expression): Call
499 evolution_function_is_affine_multivariate_p.
500 * testsuite/gfortran.dg/graphite/id-10.f90: New.
501
5022009-07-14 Sebastian Pop <sebastian.pop@amd.com>
503
504 * tree-scalar-evolution.c (compute_overall_effect_of_inner_loop):
505 Instantiate scevs varying in outer loops.
506 * testsuite/gfortran.dg/graphite/id-9.f: Correct testcase.
507
5082009-07-14 Sebastian Pop <sebastian.pop@amd.com>
509
510 * graphite-sese-to-poly.c (build_loop_iteration_domains): Do not insert
511 redundant constraint.
512
5132009-07-14 Sebastian Pop <sebastian.pop@amd.com>
514
515 * testsuite/gcc.dg/graphite/graphite.exp: Fix comments.
516 * testsuite/gfortran.dg/graphite/graphite.exp: Trigger actions
517 based on the file names as in the C testsuite.
518 * testsuite/gfortran.dg/graphite/block-1.f90: Fix patterns.
519 * testsuite/gfortran.dg/graphite/block-2.f: Same.
520 * testsuite/gfortran.dg/graphite/block-3.f90: Same.
521 * testsuite/gfortran.dg/graphite/block-4.f90: Same.
522 * testsuite/gfortran.dg/graphite/id-1.f90: Same.
523 * testsuite/gfortran.dg/graphite/id-2.f90: Same.
524 * testsuite/gfortran.dg/graphite/id-3.f90: Same.
525 * testsuite/gfortran.dg/graphite/id-4.f90: Same.
526 * testsuite/gfortran.dg/graphite/id-6.f: Same.
527 * testsuite/gfortran.dg/graphite/id-9.f: Same.
528 * testsuite/gfortran.dg/graphite/interchange-1.f: Same.
529 * testsuite/gfortran.dg/graphite/interchange-2.f: Same.
530 * testsuite/gfortran.dg/graphite/scop-1.f: Same.
531
5322009-07-14 Sebastian Pop <sebastian.pop@amd.com>
533
534 * sese.c (expand_scalar_variables_call): New.
535 (expand_scalar_variables_ssa_name): Handle calls in expander.
536
5372009-07-13 Sebastian Pop <sebastian.pop@amd.com>
538
539 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-6.c:
540 Expect to see the pattern twice.
541 * testsuite/gcc.dg/graphite/interchange-0.c: Un-XFAIL.
542 * testsuite/gcc.dg/graphite/interchange-5.c: Same.
543 * testsuite/gcc.dg/graphite/interchange-6.c: Same.
544
5452009-07-13 Sebastian Pop <sebastian.pop@amd.com>
546
547 * testsuite/gcc.dg/graphite/id-10.c: New.
548 * testsuite/gcc.dg/graphite/id-12.c: New.
549 * testsuite/gfortran.dg/graphite/id-7.f: New.
550 * testsuite/gfortran.dg/graphite/id-8.f: New.
551
5522009-07-13 Sebastian Pop <sebastian.pop@amd.com>
553
554 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Fix division by
555 zero.
556
5572009-07-13 Sebastian Pop <sebastian.pop@amd.com>
558
559 * sese.c (rename_variables_in_stmt): Call fold_convert during renaming.
560
5612009-07-13 Sebastian Pop <sebastian.pop@amd.com>
562
563 * sese.c (expand_scalar_variables_stmt): Avoid unnecessary expansion.
564
5652009-07-10 Sebastian Pop <sebastian.pop@amd.com>
566
567 * graphite-sese-to-poly.c (pdr_add_memory_accesses): Fix order of
568 building PDR subscripts.
569
5702009-07-10 Sebastian Pop <sebastian.pop@amd.com>
571
572 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Fix the
573 computation of array sizes.
574
5752009-07-10 Sebastian Pop <sebastian.pop@amd.com>
576
577 * graphite-sese-to-poly.c (add_param_constraints): Disabled.
578
5792009-07-10 Tobias Grosser <grosser@fim.uni-passau.de>
580
581 * graphite-dependences.c (map_into_dep_poly, map_dr_into_dep_poly,
582 build_pairwise_constraint, dr_equality_constraints,
583 build_pairwise_scheduling_equality,
584 build_pairwise_scheduling_inequality, lexicographically_gt_p,
585 build_lexicographically_gt_constraint, dependence_polyhedron,
586 graphite_legal_transform_dr, graphite_carried_dependence_level_k):
587 Move from NNC_Polyhedron to C_Polyhedron.
588 * graphite-interchange.c (compute_array_size_poly,
589 gather_access_strides): Dito.
590 * graphite-poly.c (apply_poly_transforms, new_poly_dr, free_poly_bb,
591 free_scop, pbb_number_of_iterations): Dito.
592 * graphite-poly.h (struct poly_dr, pdr_nb_subscripts, struct poly_bb,
593 pbb_dim_iter_domain, struct scop): Dito.
594 * graphite-ppl.c (new_Constraint_System_from_Cloog_Matrix,
595 new_Cloog_Domain_from_ppl_Polyhedron,
596 new_Cloog_Domain_from_ppl_Pointset_Powerset, ppl_set_coef_gmp,
597 ppl_insert_dimensions_pointset, ppl_insert_dimensions_pointset,
598 ppl_strip_loop, ppl_strip_loop, ppl_print_polyhedron_matrix,
599 ppl_print_powerset_matrix, debug_ppl_polyhedron_matrix,
600 debug_ppl_powerset_matrix, ppl_read_polyhedron_matrix): Dito.
601 * graphite-ppl.h (ppl_Pointset_Powerset_C_Polyhedron_t,
602 new_C_Polyhedron_from_Cloog_Matrix, ppl_print_powerset_matrix,
603 debug_ppl_powerset_matrix, ppl_insert_dimensions_pointset): Dito.
604 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons,
605 build_loop_iteration_domains, ppl_constraint_type_from_tree_code,
606 add_condition_to_domain, add_condition_to_pbb, build_scop_context,
607 build_scop_iteration_domain, build_poly_dr): Dito
608
6092009-07-09 Sebastian Pop <sebastian.pop@amd.com>
610
611 * testsuite/gcc.dg/graphite/graphite.exp: Added a rule to execute
612 run-id-*.c files.
613 * testsuite/gcc.dg/graphite/run-id-1.c: New.
614
6152009-07-09 Sebastian Pop <sebastian.pop@amd.com>
616
617 * graphite-sese-to-poly.c (build_loop_iteration_domains): Add the
618 positivity constraint on the symbolic number of iterations.
619
6202009-07-09 Sebastian Pop <sebastian.pop@amd.com>
621
622 * graphite-sese-to-poly.c (build_loop_iteration_domains): Rewrite.
623
6242009-07-09 Sebastian Pop <sebastian.pop@amd.com>
625 Tobias Grosser <grosser@fim.uni-passau.de>
626
627 * graphite-clast-to-gimple.c (build_scop_context): Removed.
628 (build_cloog_prog): Directly use SCOP_CONTEXT.
629 * graphite-poly.c (new_scop): Initialize SCOP_CONTEXT.
630 (free_scop): Free SCOP_CONTEXT.
631 (print_scop_context): New.
632 (print_scop): Call print_scop_context.
633 (debug_scop_context): New.
634 * graphite-poly.h (print_scop_context, debug_scop_context): Declared.
635 (struct scop): Added field context.
636 (SCOP_CONTEXT): New.
637 * graphite-sese-to-poly.c (add_param_constraints): New.
638 (build_scop_context): New.
639 (build_poly_scop): Call build_scop_context.
640
6412009-07-09 Sebastian Pop <sebastian.pop@amd.com>
642
643 * graphite-clast-to-gimple.c (gmp_cst_to_tree): Moved...
644 * graphite-ppl.c (ppl_set_inhomogeneous_gmp, ppl_set_coef_gmp): New.
645 (ppl_set_inhomogeneous, ppl_set_coef): Moved...
646 * graphite-ppl.h: Include double-int.h and tree.h.
647 (ppl_set_inhomogeneous_gmp, ppl_set_coef_gmp): Declared.
648 (ppl_set_inhomogeneous, ppl_set_coef): ...here.
649 (gmp_cst_to_tree): ...here. Reimplemented using mpz_get_double_int.
650 (tree_int_to_gmp, ppl_set_inhomogeneous_tree, ppl_set_coef_tree): New.
651
6522009-07-09 Sebastian Pop <sebastian.pop@amd.com>
653
654 * graphite-clast-to-gimple.c (clast_to_gcc_expression_red): Generate
655 POINTER_PLUS_EXPR for pointer types.
656 (clast_to_gcc_expression): Same.
657
6582009-07-09 Sebastian Pop <sebastian.pop@amd.com>
659
660 * graphite-poly.c (print_scattering_function): Early return when
661 PBB_TRANSFORMED_SCATTERING is not initialized.
662 (print_pbb_domain): Early return when PBB_DOMAIN is not initialized.
663
6642009-07-08 Sebastian Pop <sebastian.pop@amd.com>
665
666 * tree-parloops.c (analyze_reduction_list): Remove unused variable
667 to fix bootstrap.
668
6692009-07-08 Razya Ladelsky <razya@il.ibm.com>
670
671 * tree-parloops.c (analyze_reduction_list): Change return
672 value to void.
673 (try_create_reduction_list): Move the call to
674 analyze_reduction_list to the beginining.
675 Call reduction_phi with analyzed_reductions as argument
676 instead of reduction_list.
677
6782009-07-08 Tobias Grosser <grosser@fim.uni-passau.de>
679
680 * Merge from mainline (r148296:149346)
681
6822009-07-07 Sebastian Pop <sebastian.pop@amd.com>
683
684 * graphite-scop-detection.c (graphite_can_represent_init): New.
685 (graphite_can_represent_scev): Call graphite_can_represent_init:
686 check that the initial value does not contain multiplications of
687 parameters.
688 (stmt_has_simple_data_refs_p): New.
689 (stmt_simple_for_scop_p): Call stmt_simple_for_scop_p.
690 (is_simple_operand): Fix formatting.
691 * graphite-sese-to-poly.c (try_generate_gimple_bb): Fix formatting.
692
6932009-07-07 Sebastian Pop <sebastian.pop@amd.com>
694
695 * testsuite/gcc.dg/graphite/id-13.c: New.
696 * graphite-sese-to-poly.c (graphite_stmt_p): Do not call
697 analyze_scalar_evolution, use scalar_evolution_in_region.
698 (scan_tree_for_params_right_scev): Add extra assert.
699 (parameter_index_in_region_1): Split from parameter_index_in_region.
700 (idx_record_params): Use scalar_evolution_in_region.
701 (find_params_in_bb): Same.
702 (find_scop_parameters): Same.
703 (build_loop_iteration_domains): Same.
704 (create_linear_expr_from_tree): Same.
705 * sese.c (scalar_evolution_in_region): New.
706 * sese.h (scalar_evolution_in_region): Declared.
707 (defined_in_sese_p): New.
708 * tree-scalar-evolution.c (compute_overall_effect_of_inner_loop): Not
709 static anymore.
710 * tree-scalar-evolution.h (compute_overall_effect_of_inner_loop):
711 Declared.
712
7132009-07-07 Sebastian Pop <sebastian.pop@amd.com>
714
715 * Makefile.in: Replace dependences on tree-chrec.h with SCEV_H.
716 TREE_DATA_REF_H also implies SCEV_H.
717
7182009-07-07 Sebastian Pop <sebastian.pop@amd.com>
719
720 * graphite-poly.c (print_scop_params): New.
721 (print_scop): Call print_scop_params.
722 (debug_scop_params): New.
723 * graphite-poly.h (print_scop_params, debug_scop_params): Declared.
724
7252009-07-07 Li Feng <nemokingdom@gmail.com>
726
727 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-4.c: New.
728 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-5.c: New.
729 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-6.c: New.
730 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-7.c: New.
731 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-8.c: New.
732 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-9.c: New.
733
7342009-07-07 Li Feng <nemokingdom@gmail.com>
735
736 * graphite-clast-to-gimple.c (mark_loops_parallel): Dump information
737 for dependency checking part.
738 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-1.c: Add
739 tests for dependency checking.
740 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-2.c: Ditto.
741 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-3.c: Ditto.
742 * testsuite/gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: Add
743 flag -fdump-tree-graphite-all for autopar testsuites.
744
7452009-07-06 Sebastian Pop <sebastian.pop@amd.com>
746
747 * Makefile.in (tree-ssa-loop-manip.o): Depends on langhooks.h.
748 * tree-parloops.c (rewrite_phi_with_iv, rewrite_all_phi_nodes_with_iv,
749 canonicalize_loop_ivs): Moved...
750 * tree-ssa-loop-manip.c: ... here. Include langhooks.h.
751
7522009-07-06 Sebastian Pop <sebastian.pop@amd.com>
753
754 * tree-parloops.c (try_create_reduction_list): Pass an extra
755 argument analyzed_reductions. Call analyze_reduction_list.
756 (gen_parallel_loop): Do not call analyze_reduction_list.
757 (parallelize_loops): Init and finalize analyzed_reductions.
758
7592009-07-06 Li Feng <nemokingdom@gmail.com>
760
761 * testsuite/gcc.dg/graphite/graphite_autopar/graphite_autopar.exp:
762 Added flag -fno-loop-strip-mine for autopar testcase.
763
7642009-07-04 Li Feng <nemokingdom@gmail.com>
765
766 * graphite-dependences.c (graphite_carried_dependence_level_k): Use
767 transformed scattering dimension instead of unmatch orignal when
768 calling dependence_polyhedron.
769
7702009-06-30 Sebastian Pop <sebastian.pop@amd.com>
771
772 * opts.c (decode_options): Enable flag_loop_strip_mine at -O2.
773
7742009-06-30 Sebastian Pop <sebastian.pop@amd.com>
775
776 * graphite-poly.c (pbb_number_of_iterations): Check for returned
777 value 1 from ppl_Pointset_Powerset_NNC_Polyhedron_maximize.
778
7792009-06-30 Sebastian Pop <sebastian.pop@amd.com>
780
781 * graphite-blocking.c (pbb_strip_mine_profitable_p): New.
782 (pbb_do_strip_mine): Call pbb_strip_mine_profitable_p.
783 * graphite-poly.c (pbb_number_of_iterations): New.
784 * graphite-poly.h (pbb_number_of_iterations): Declared.
785 (pbb_iterator_dim, pbb_parameter_dim): New.
786
7872009-06-29 Sebastian Pop <sebastian.pop@amd.com>
788
789 * graphite-clast-to-gimple.c (graphite_create_new_loop): Revert the
790 last commit on type of lower and upper bound of loops.
791
7922009-06-29 Li Feng <nemokingdom@gmail.com>
793
794 * Makefile.in (graphite-clast-to-gimple.o): Added dependence on
795 graphite-dependences.h.
796 * graphite-clast-to-gimple.c (new_bb_pbb_def): New.
797 (mark_bb_with_pbb): New.
798 (get_stmtfor_depth): New.
799 (find_pbb_via_hash): New.
800 (dependency_in_loop_p): New.
801 (mark_loops_parallel): New.
802 (free_aux_in_new_loops): New.
803 (translate_clast): Add parameter BB_PBB_MAPPING. Mark newly created
804 bb with it's relevant pbb. Mark newly created loops. Remove mark
805 innermost loop parallel without checking.
806 (gloog): Add parameter BB_PBB_MAPPING.
807 * graphite-clast-to-gimple.h (struct bb_pbb_def): New.
808 (gloog): Change declaration.
809 (mark_loop_parallel): Make extern.
810 (free_aux_in_new_loops): Declare.
811 (bb_pbb_map_hash): New.
812 (eq_bb_pbb_map): New.
813 * graphite.c (graphite_transform_loops): Added BB_PBB_MAPPING. Trigger
814 auto parallelization when flag_graphite_force_parallel is set.
815 (graphite_finalize): Added free_aux_in_new_loops.
816 * tree-parloops.c (parallelize_loops): Only generate parallel code for
817 the innermost loop that marked parallel. Use
818 flag_graphite_force_parallel instead of loop->can_be_parallel.
819 (loop_parallel_p): Move inner most checking out of function.
820
8212009-06-26 Sebastian Pop <sebastian.pop@amd.com>
822
823 * graphite-clast-to-gimple.c (graphite_create_new_loop): Make the
824 type of lower and upper bound of loops signed long int.
825
8262009-06-26 Sebastian Pop <sebastian.pop@amd.com>
827
828 * cfgloopmanip.c (create_empty_loop_on_edge): Gimplify the loop exit
829 expression outside the loop.
830
8312009-06-26 Sebastian Pop <sebastian.pop@amd.com>
832
833 * gcc.dg/graphite/interchange-8.c: New.
834
8352009-06-26 Sebastian Pop <sebastian.pop@amd.com>
836
837 * gcc.dg/graphite/interchange-0.c: XFailed.
838 * gcc.dg/graphite/interchange-5.c: XFailed.
839 * gcc.dg/graphite/interchange-6.c: XFailed.
840
8412009-06-26 Sebastian Pop <sebastian.pop@amd.com>
842
843 * graphite-interchange.c (compute_array_size_poly): The end of the
844 recursion should return 1.
845
8462009-06-26 Sebastian Pop <sebastian.pop@amd.com>
847
848 * graphite-interchange.c (compute_array_size_cstr): Allow the
849 subscript multiplier to be -1.
850 (compute_array_size): Use PDR_DATA_CONTAINER and not PDR_ACCESSES.
851 * graphite-poly.c (new_poly_dr): Takes an extra argument for the
852 data_container. Initializes PDR_DATA_CONTAINER.
853 (print_pdr_access_layout): New.
854 (print_pdr): Call print_pdr_access_layout. Print PDR_DATA_CONTAINER.
855 * graphite-poly.h (struct poly_dr): Adjust comment. Add a new field
856 data_container.
857 (PDR_DATA_CONTAINER): New.
858 (new_poly_dr): Update declaration.
859 * graphite-sese-to-poly.c (pdr_add_data_dimensions): New.
860 (build_poly_dr): Call pdr_add_data_dimensions.
861
8622009-06-26 Sebastian Pop <sebastian.pop@amd.com>
863
864 * graphite-poly.h (struct poly_dr): Fix comment.
865 * graphite-sese-to-poly.c (pdr_add_alias_set): New.
866 (pdr_add_memory_accesses): New.
867 (build_poly_dr): Call pdr_add_memory_accesses and pdr_add_alias_set.
868
8692009-06-26 Sebastian Pop <sebastian.pop@amd.com>
870
871 * graphite-poly.c (print_pdrs, debug_pdrs): New.
872 (print_pbb): Add call to print_pdrs.
873 * graphite-poly.h (print_pdrs, debug_pdrs): Declared.
874
8752009-06-24 Konrad Trifunovic <konrad.trifunovic@gmail.com>
876 Li Feng <nemokingdom@gmail.com>
877
878 * graphite-dependences.c (graphite_carried_dependence_level_k): New.
879 (dependency_between_pbbs_p): New.
880 (lexicographically_gt_p): Assure !empty_p before polyhedron
881 intersection assign.
882 (build_lexicographically_gt_constraint): Correct lexicographically
883 judging.
884 * graphite-dependences.h: New.
885 * Makefile.in (graphite-dependences.o): Add graphite-dependences.h.
886
8872009-06-24 Sebastian Pop <sebastian.pop@amd.com>
888
889 * graphite-clast-to-gimple.c (print_clast_stmt): New.
890 (gloog): Print to dump_file the generated clast.
891 * graphite-clast-to-gimple.h (print_clast_stmt): Declared.
892 * graphite-interchange.c (pbb_do_interchange): Fix dump formatting.
893
8942009-06-24 Sebastian Pop <sebastian.pop@amd.com>
895
896 * graphite-poly.c (extend_scattering): Increment
897 PBB_NB_LOCAL_VARIABLES by the number of added dimensions.
898
8992009-06-24 Sebastian Pop <sebastian.pop@amd.com>
900
901 * graphite-interchange.c (compute_array_size_poly): Added exit of
902 recursion condition. Continue iterating even after the first equality.
903 (compute_array_size): Same.
904
9052009-06-24 Li Feng <nemokingdom@gmail.com>
906
907 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-1.c: Update
908 -fdump-tree-final_cleanup to -fdump-tree-optimized.
909 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-2.c: Ditto.
910 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-3.c: Ditto.
911 * testsuite/gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: Ditto.
912
9132009-06-23 Sebastian Pop <sebastian.pop@amd.com>
914
915 * sese.c (expand_scalar_variables_stmt): Expand scalar variables
916 only when the use verifies is_gimple_reg.
917
9182009-06-23 Sebastian Pop <sebastian.pop@amd.com>
919
920 * graphite-clast-to-gimple.c (build_cloog_prog): Fix memory corruption.
921 Allocate scaldims after call to unify_scattering_dimensions.
922
9232009-06-23 Sebastian Pop <sebastian.pop@amd.com>
924
925 * graphite-clast-to-gimple.c (translate_clast): Fix memory leak.
926
9272009-06-23 Sebastian Pop <sebastian.pop@amd.com>
928 Albert Cohen <albert.cohen@inria.fr>
929
930 * graphite-blocking.c (pbb_strip_mine_loop_depth): Do not use local
931 variables for the strip mining.
932
9332009-06-23 Sebastian Pop <sebastian.pop@amd.com>
934 Pranav Garg <pranav.garg2107@gmail.com>
935
936 * Makefile.in (OBJS-common): Added graphite-blocking.o.
937 (graphite-sese-to-poly.o): Moved down to be in lexicographical order.
938 (graphite-blocking.o): New rule.
939 (graphite-poly.o, graphite-ppl.o): Moved to be in lexicographical order.
940 * graphite-blocking.c: New.
941 * graphite-poly.c (apply_poly_transforms): Call scop_do_strip_mine for
942 flag_loop_strip_mine.
943 (psct_scattering_dim_for_loop_depth): New.
944 * graphite-poly.h (scop_do_strip_mine): Declared.
945 (psct_add_local_variable): Increment PBB_NB_LOCAL_VARIABLES.
946 * tree-ssa-loop.c (gate_graphite_transforms): Do not fail when using
947 flag_loop_strip_mine.
948
9492009-06-23 Sebastian Pop <sebastian.pop@amd.com>
950
951 * graphite-poly.c (extend_scattering): Avoid initializing and freeing
952 a GMP value and a PPL coefficient at each iteration of a loop.
953
9542009-06-23 Sebastian Pop <sebastian.pop@amd.com>
955
956 * graphite-dependences.c (dependence_polyhedron): Do not use
957 pbb_nb_scattering_dims anymore. Use pbb_nb_scattering_orig and
958 pbb_nb_scattering_transform.
959 (graphite_legal_transform_dr): Same.
960 * graphite-poly.c (extend_scattering): Same.
961 (unify_scattering_dimensions): Same.
962 (print_scattering_function): Same.
963 (new_poly_bb): Initialize PBB_NB_SCATTERING_TRANSFORM and
964 PBB_NB_LOCAL_VARIABLES.
965 * graphite-poly.h (pbb_nb_scattering): Removed declaration.
966 (struct poly_bb): Added nb_local_variables and nb_scattering_transform.
967 (PBB_NB_LOCAL_VARIABLES, PBB_NB_SCATTERING_TRANSFORM): New.
968 (pbb_nb_scattering_orig, pbb_nb_scattering_transform): New.
969 (pbb_nb_scattering_dims, pbb_nb_scattering): Removed.
970 (pbb_nb_scattering_transform): New.
971 (pbb_nb_local_vars): Return PBB_NB_LOCAL_VARIABLES.
972 (psco_scattering_dim): Add assert on parameters.
973 (psct_scattering_dim): Same.
974 (psct_scattering_dim_for_loop_depth): Declared.
975 (psct_local_var_dim): New.
976 (psco_iterator_dim, psco_parameter_dim): Add assert on parameters.
977 (psct_iterator_dim, psct_parameter_dim): Same. To maintain the
978 correct layout, call pbb_nb_local_vars.
979 (psct_add_local_variable, psct_add_scattering_dimension): New.
980 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons):
981 Initialize PBB_NB_SCATTERING_TRANSFORM.
982
9832009-06-23 Sebastian Pop <sebastian.pop@amd.com>
984
985 * graphite-ppl.c (set_inhomogeneous): Renamed ppl_set_inhomogeneous.
986 (set_coef): Renamed ppl_set_coef.
987 * graphite-ppl.h (ppl_set_inhomogeneous, ppl_set_coef): Declared.
988
9892009-06-23 Sebastian Pop <sebastian.pop@amd.com>
990
991 * graphite-dependences.c (build_pairwise_scheduling_inequality): Don't
992 test a boolean against 1.
993 * graphite-interchange.c (pbb_interchange_loop_depths): Do not build
994 a new polyhedron for the PBB_TRANSFORMED_SCATTERING.
995 (pbb_do_interchange): Returns true when a transform has been performed.
996 (scop_do_interchange): Same.
997 * graphite-poly.c (apply_poly_transforms): Use the return value of
998 scop_do_interchange.
999 * graphite-poly.h (scop_do_interchange): Update declaration.
1000
10012009-06-23 Tobias Grosser <grosser@fim.uni-passau.de>
1002
1003 * graphite-clast-to-gimple.c (gloog): Reset loop->aux right
1004 after last use.
1005 * sese.c (sese_reset_aux_in_loops): New.
1006 * sese.h (sese_reset_aux_in_loops): New.
1007
10082009-06-19 Sebastian Pop <sebastian.pop@amd.com>
1009
1010 * graphite-sese-to-poly.c (scan_tree_for_params_int): Pass in the
1011 multiplier and multiply the constant by the multiplier.
1012 (scan_tree_for_params): Bound the multiplier to its MULT_EXPR.
1013 (build_poly_dr): Do not use the multiplier to define the subscript.
1014
10152009-06-19 Sebastian Pop <sebastian.pop@amd.com>
1016
1017 * graphite-poly.c (new_poly_dr): Pass an extra argument for the
1018 compiler's data reference. Initialize PDR_CDR.
1019 (print_pdr): Call dump_data_reference.
1020 * graphite-poly.h (struct poly_dr): Rename black_box into pbb.
1021 Add compiler_dr field.
1022 (PDR_BB): Renamed PDR_PBB.
1023 (PDR_CDR): New.
1024 * graphite-sese-to-poly.c (build_poly_dr): Pass to new_poly_dr
1025 GCC's data reference representation.
1026 * tree-data-ref.c (debug_data_references, debug_data_reference): New.
1027 * tree-data-ref.h (debug_data_references, debug_data_reference): Decl.
1028
10292009-06-19 Sebastian Pop <sebastian.pop@amd.com>
1030
1031 * graphite-poly.c (print_scattering_function): Also print the layout.
1032 * graphite-poly.h (pbb_nb_local_vars): New.
1033
10342009-06-19 Sebastian Pop <sebastian.pop@amd.com>
1035
1036 * graphite-poly.c (print_pbb_domain): Also print the layout names.
1037
10382009-06-19 Sebastian Pop <sebastian.pop@amd.com>
1039
1040 * graphite-poly.c (print_pdr, debug_pdr): New.
1041 * graphite-poly.h (print_pdr, debug_pdr): Declared.
1042 (PDR_BASE): Removed.
1043
10442009-06-18 Sebastian Pop <sebastian.pop@amd.com>
1045
1046 * gcc/testsuite/gcc.dg/graphite/interchange-{1..7}.c: New avatars of
1047 ltrans-{1..6,8}.c.
1048
10492009-06-18 Sebastian Pop <sebastian.pop@amd.com>
1050
1051 * graphite-interchange.c (compute_subscript): Allow also -1 in the
1052 subscript identification column.
1053 (pbb_do_interchange): Print to dump_file that some loops "will be
1054 interchanged". Rely on that chain of characters in the testcases.
1055 * gcc.dg/graphite/interchange-0.c: New.
1056 * gcc.dg/graphite/graphite.exp: Iterate over the testsuite
1057 interchange-*.c files and compile them with -floop-interchange.
1058
10592009-06-18 Pranav Garg <pranav.garg2107@gmail.com>
1060
1061 * graphite-interchange.c (interchange_profitable_p): Renamed
1062 pbb_interchange_profitable_p.
1063
10642009-06-18 Sebastian Pop <sebastian.pop@amd.com>
1065 Harsha Jagasia <harsha.jagasia@amd.com>
1066 Pranav Garg <pranav.garg2107@gmail.com>
1067
1068 * graphite-interchange.c (interchange_profitable_p): Make static.
1069 (pbb_interchange_loop_depths, pbb_do_interchange,
1070 scop_do_interchange): New.
1071 * graphite-poly.c (apply_poly_transforms): Call scop_do_interchange
1072 for flag_loop_interchange.
1073 * graphite-poly.h (scop_do_interchange): Declared.
1074 * tree-ssa-loop.c (gate_graphite_transforms): Do not fail when
1075 flag_loop_interchange is used.
1076
10772009-06-18 Sebastian Pop <sebastian.pop@amd.com>
1078
1079 * graphite-dependences.c (dependence_polyhedron): Update use of
1080 pbb_nb_scattering_dims.
1081 * graphite-poly.h (pbb_nb_scattering_dims): Do not pass SCOP.
1082 (pbb_nb_scattering): Update use of pbb_nb_scattering_dims.
1083 (psco_scattering_dim, psct_scattering_dim, psco_iterator_dim,
1084 psct_iterator_dim, psco_parameter_dim, psct_parameter_dim): New.
1085
10862009-06-16 Sebastian Pop <sebastian.pop@amd.com>
1087
1088 * graphite.c: Cleanup foo.
1089
10902009-06-16 Sebastian Pop <sebastian.pop@amd.com>
1091
1092 * Merge from mainline (r143684:148293).
1093 * Disabled libpcp until it gets fixed.
1094
10952009-06-05 Sebastian Pop <sebastian.pop@amd.com>
1096 Harsha Jagasia <harsha.jagasia@amd.com>
1097
1098 * graphite-interchange.c: New.
1099 * Makefile.in (graphite-interchange.o): New.
1100 * graphite-poly.h (interchange_profitable_p): Declared.
1101 * graphite-ppl.h (value_max): New.
1102
11032009-06-04 Sebastian Pop <sebastian.pop@amd.com>
1104
1105 * graphite-dependences.c (dependence_polyhedron): Use pdr_dim.
1106 * graphite-poly.h: Fix some comments.
1107 (pdr_dim): New.
1108 (pdr_scop): New.
1109
11102009-06-04 Sebastian Pop <sebastian.pop@amd.com>
1111
1112 * graphite-poly.h
1113 (pdr_accessp_nb_subscripts): Renamed pdr_nb_subscripts.
1114 (pdr_accessp_nb_iterators): Renamed pdr_dim_iter_domain.
1115 (pdr_accessp_nb_params): Renamed pdr_nb_params.
1116 (pdr_accessp_alias_set_dim): Renamed pdr_alias_set_dim.
1117 (pdr_accessp_subscript_dim): Renamed pdr_subscript_dim.
1118 (pdr_accessp_iterator_dim): Renamed pdr_iterator_dim.
1119 (pdr_accessp_param_dim): Renamed pdr_parameter_dim.
1120 (pbb_nb_loops): Renamed pbb_dim_iter_domain.
1121 * graphite-clast-to-gimple.c: Same.
1122 * graphite-dependences.c: Same.
1123 * graphite-poly.c: Same.
1124 * graphite-sese-to-poly.c: Same.
1125
11262009-06-03 Sebastian Pop <sebastian.pop@amd.com>
1127
1128 * graphite-clast-to-gimple.c (build_iv_mapping): Insert full
1129 expressions for an IV rename, as returned by clast_to_gcc_expression.
1130 (copy_renames): Rename new_name to expr.
1131 * sese.c (debug_rename_elt): Same.
1132 (get_rename): Same.
1133 (set_rename): Same.
1134 (sese_adjust_liveout_phis): Call force_gimple_operand before using
1135 the information from the rename map.
1136 (rename_variables_in_stmt): Same.
1137 (add_loop_exit_phis): Rename new_name to expr.
1138 (insert_loop_close_phis): Same.
1139 (add_guard_exit_phis): Same. Call force_gimple_operand.
1140 * sese.h (struct rename_map_elt): Rename new_name to expr.
1141 (new_rename_map_elt): Same.
1142
11432009-06-03 Sebastian Pop <sebastian.pop@amd.com>
1144
1145 * graphite-clast-to-gimple.c (build_iv_mapping): Use set_rename.
1146 * sese.c (set_rename): Make it extern.
1147 * sese.h (set_rename): Declared.
1148
11492009-06-03 Sebastian Pop <sebastian.pop@amd.com>
1150
1151 * graphite-poly.c (extend_scattering): Free values.
1152 * graphite-ppl.c (new_Cloog_Domain_from_ppl_Pointset_Powerset):
1153 Free iterators.
1154 (ppl_print_powerset_matrix): Same.
1155 * graphite-scop-detection.c (free_scops_1): New.
1156 (limit_scops): Call free_scops_1.
1157 * graphite-sese-to-poly.c (build_scop_bbs_1): Free dom.
1158 (build_poly_dr): Free PPL coefficients.
1159 * tree-parloops.c (rewrite_all_phi_nodes_with_iv): Free bbs.
1160
11612009-06-02 Sebastian Pop <sebastian.pop@amd.com>
1162
1163 * graphite-dependences.c: New.
1164 * graphite-data-ref.c: Removed.
1165 * graphite-data-ref.h: Removed.
1166 * Makefile.in (graphite-data-ref.o): Removed.
1167 (graphite-dependences.o): Added.
1168 * graphite-clast-to-gimple.c: Remove dependence on graphite-data-ref.h.
1169 * graphite-poly.c: Same.
1170 Move the data dependence testing to graphite-dependences.c.
1171
11722009-05-19 Tobias Grosser <grosser@fim.uni-passau.de>
1173
1174 * graphite-scop-detection.c (graphite_can_represent_loop): Renamed
1175 from graphite_cannot_represent_loop. Code refactored.
1176 (scopdet_basic_block_info): Call graphite_can_represent_loop.
1177
11782009-05-17 Li Feng <nemokingdom@gmail.com>
1179
1180 * testsuite/gcc.dg/graphite/graphite_autopar/graphite_autopar.exp:
1181 Cover all the testcases (not only the filtered ones).
1182
11832009-05-17 Tobias Grosser <grosser@fim.uni-passau.de>
1184
1185 * graphite-scop-detection.c (stmt_simple_for_scop_p): Remove
1186 unnecessary check. Update comments. Move check for REAL_TYPE here.
1187 (harmful_stmt_in_bb): Remove checks for conditions. This is already
1188 done in (stmt_simple_for_scop_p).
1189
11902009-05-14 Tobias Grosser <grosser@fim.uni-passau.de>
1191
1192 * graphite.c (print_global_statistics): New.
1193 (print_graphite_scop_statistic): New.
1194 (print_graphite_statistics): New.
1195 (graphite_initialize, graphite_transform_loops): Print statistics.
1196 * graphite-scop-detection (build_scops): Print statistics.
1197 (print_graphite_scop_statistics): New.
1198 (print_graphite_statistics): New.
1199
12002009-05-13 Sebastian Pop <sebastian.pop@amd.com>
1201
1202 * graphite-clast-to-gimple.c (struct clast_name_index): Removed.
1203 (debug_clast_name_index): Removed.
1204 (debug_clast_name_indexes_1): Removed.
1205 (debug_clast_name_indexes): Removed.
1206 (clast_name_index_elt_info): Removed.
1207 (eq_clast_name_indexes): Removed.
1208 (clast_name_to_index): Removed.
1209 (new_clast_name_index): Removed.
1210 (save_clast_name_index): Removed.
1211 (save_var_name): Moved...
1212 (init_sese_params_index): Removed.
1213 (clast_name_to_gcc): Remove use of name_tree.
1214 (initialize_cloog_names): Same.
1215 (gloog): Do not call init_sese_params_index.
1216 * graphite-sese-to-poly.c (save_var_name): ...here.
1217 (parameter_index_in_region): New.
1218 * sese.c (new_sese): Initialize SESE_PARAMS_NAMES.
1219 (parameter_index_in_region): Removed.
1220 (is_parameter): Remove use of name_tree.
1221 * sese.h (struct name_tree): Removed.
1222 (struct sese): Remove use of name_tree. New field params_names.
1223 (SESE_PARAMS_NAMES): New.
1224 (SESE_PARAMS): Remove duplicate.
1225 (parameter_index_in_region): Removed.
1226 (sese_nb_params): Remove use of name_tree.
1227 (struct clast_name_index): New.
1228 (new_clast_name_index): New.
1229 (clast_name_to_index): New.
1230 (save_clast_name_index): New.
1231 (debug_clast_name_index): New.
1232 (debug_clast_name_indexes_1): New.
1233 (debug_clast_name_indexes): New.
1234 (clast_name_index_elt_info): New.
1235 (eq_clast_name_indexes): New.
1236
12372009-05-13 Sebastian Pop <sebastian.pop@amd.com>
1238
1239 * graphite-clast-to-gimple.c (compute_cloog_iv_types_1): Call
1240 pbb_to_depth_to_oldiv. Remove call to oldiv_for_loop.
1241 (graphite_loop_normal_form): Do not pass region. Do not
1242 initialize SESE_OLDIVS.
1243 (build_graphite_loop_normal_form): Update call to
1244 graphite_loop_normal_form.
1245 * sese.c (debug_oldivs): Removed.
1246 (new_sese): Do not initialize SESE_OLDIVS.
1247 (free_sese): Do not free SESE_OLDIVS.
1248 (oldiv_for_loop): Removed.
1249 * sese.h (struct sese): Remove old_ivs.
1250 (SESE_OLDIVS): Removed.
1251 (oldiv_for_loop): Removed.
1252
12532009-05-13 Sebastian Pop <sebastian.pop@amd.com>
1254
1255 * graphite-clast-to-gimple.c (clast_name_to_gcc): Pass newivs,
1256 remove ivstack. Remove call to loop_iv_stack_get_iv_from_name,
1257 replaced by a call to newivs_to_depth_to_newiv.
1258 (clast_to_gcc_expression): Pass newivs, remove ivstack.
1259 (clast_to_gcc_expression_red): Same.
1260 (gcc_type_for_clast_expr): Same.
1261 (gcc_type_for_clast_eq): Same.
1262 (graphite_translate_clast_equation): Same.
1263 (graphite_create_guard_cond_expr): Same.
1264 (graphite_create_new_guard): Same.
1265 (graphite_create_new_loop): Same.
1266 (build_iv_mapping): Same.
1267 (translate_clast): Same.
1268 (gloog): Same.
1269 (loop_iv_stack_patch_for_consts): Removed. *
1270 sese.c (iv_stack_entry_is_constant): Removed.
1271 (iv_stack_entry_is_iv): Removed.
1272 (loop_iv_stack_push_iv): Removed.
1273 (loop_iv_stack_insert_constant): Removed.
1274 (loop_iv_stack_pop): Removed.
1275 (loop_iv_stack_get_iv): Removed.
1276 (loop_iv_stack_get_iv_from_name): Removed.
1277 (debug_loop_iv_stack): Removed.
1278 (free_loop_iv_stack): Removed.
1279 (loop_iv_stack_remove_constants): Removed. *
1280 sese.h (iv_stack_entry_kind): Removed.
1281 (iv_stack_entry_data_union): Removed.
1282 (iv_stack_entry_struct): Removed.
1283 (iv_stack_entry_p): Removed.
1284 (debug_oldivs, debug_loop_iv_stack, loop_iv_stack_insert_constant,
1285 loop_iv_stack_get_iv_from_name, loop_iv_stack_push_iv,
1286 loop_iv_stack_get_iv, loop_iv_stack_remove_constants,
1287 loop_iv_stack_pop, free_loop_iv_stack): Removed.
1288 (gbb_loop_at_index): Fix indenting.
1289 (gbb_loop_index): Removed.
1290
12912009-05-13 Sebastian Pop <sebastian.pop@amd.com>
1292
1293 * graphite-clast-to-gimple.c (clast_name_to_gcc): Do not use strcmp.
1294 Call clast_name_to_index.
1295
12962009-05-13 Sebastian Pop <sebastian.pop@amd.com>
1297
1298 * graphite-clast-to-gimple.c (clast_name_to_gcc): Pass region,
1299 do not pass params. Get params from SESE_PARAMS.
1300 (clast_to_gcc_expression): Same.
1301 (clast_to_gcc_expression_red): Same.
1302 (gcc_type_for_clast_eq): Same.
1303 (graphite_translate_clast_equation): Same.
1304 (graphite_create_new_loop): Same.
1305 * sese.c (rename_variables_in_stmt): Fix comment.
1306
13072009-05-13 Sebastian Pop <sebastian.pop@amd.com>
1308
1309 * graphite-clast-to-gimple.c (graphite_create_new_loop): Pass
1310 newivs_index.
1311 Call save_clast_name_index.
1312 (translate_clast): Pass newivs_index.
1313 (gloog): Create and free newivs_index.
1314
13152009-05-13 Sebastian Pop <sebastian.pop@amd.com>
1316
1317 * graphite-clast-to-gimple.c (clast_name_index): New structure.
1318 (clast_name_index_p): New type.
1319 (debug_clast_name_index): New.
1320 (debug_clast_name_indexes_1): New.
1321 (debug_clast_name_indexes): New.
1322 (clast_name_index_elt_info): New.
1323 (eq_clast_name_indexes): New.
1324 (clast_name_to_index): New.
1325 (new_clast_name_index): New.
1326 (save_clast_name_index): New.
1327 (init_sese_params_index): New.
1328 (gloog): Call init_sese_params_index.
1329 * graphite-clast-to-gimple.h (debug_clast_name_indexes): Declared.
1330 * sese.c (new_sese): Initialize SESE_PARAMS_INDEX.
1331 (free_sese): Free SESE_PARAMS_INDEX.
1332 * sese.h (struct sese): Add params_index.
1333 (SESE_PARAMS_INDEX): New.
1334
13352009-05-13 Sebastian Pop <sebastian.pop@amd.com>
1336
1337 * graphite-clast-to-gimple.c (newivs_to_depth_to_newiv): New.
1338 (graphite_create_new_loop): Pass the newivs vector. Push the
1339 newly created IV to newivs.
1340 (translate_clast): Pass the newivs vector.
1341 (gloog): Create and destroy the newivs vector.
1342
13432009-05-13 Sebastian Pop <sebastian.pop@amd.com>
1344
1345 * graphite-clast-to-gimple.c (pbb_to_depth_to_oldiv): New.
1346 (graphite_loop_normal_form): Initialize loop->aux with the unique
1347 IV that has been created.
1348
13492009-05-13 Tobias Grosser <grosser@fim.uni-passau.de>
1350
1351 * tree-chrec.c (evolution_function_right_is_integer_cst): Allow
1352 scev with parameters in the base part. They where forbidden
1353 exidently.
1354
13552009-05-11 Li Feng <nemokingdom@gmail.com>
1356
1357 * testsuite/gcc.dg/graphite/graphite.exp: Set different default
1358 compile options by file names.
1359 * testsuite/gcc.dg/graphite/block{0-6}.c: Remove dg-option line.
1360 * testsuite/gcc.dg/graphite/id-{1-9}.c: Ditto.
1361 * testsuite/gcc.dg/graphite/scop-{0-20}.c: Ditto.
1362 * testsuite/gcc.dg/graphite/scop-matmult.c: Ditto.
1363
13642009-05-08 Li Feng <nemokingdom@gmail.com>
1365
1366 * testsuite/gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: New.
1367 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-1.c: New.
1368 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-2.c: New.
1369 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-3.c: New.
1370
13712009-05-07 Tobias Grosser <grosser@fim.uni-passau.de>
1372
1373 * graphite-scop-detection (build_scops_1): Fix little bug introduced
1374 by final cleanup.
1375
13762009-05-07 Tobias Grosser <grosser@fim.uni-passau.de>
1377
1378 * graphite-scop-detection.c (graphite_can_represent_scev): Only
1379 allow integer constant strides.
1380 (graphite_can_represent_expr): Depend on outermost_loop.
1381 (stmt_simple_memref_p, graphite_cannot_represent_loop,
1382 harmful_stmt_in_bb, is_simple_operand, stmt_simple_for_scop_p,
1383 build_scops_1): Same.
1384 (scopdet_basic_block_info): Same and insert layered SCoP
1385 detection.
1386 (try_generate_gimple_bb): Cleanup.
1387 (build_scops): Enable data references.
1388
1389 * testsuite/gcc.dg/graphite/id-5.c: New.
1390 * testsuite/gcc.dg/graphite/id-9.c: New.
1391 * tree-chrec.c (evolution_function_right_is_integer_cst): New.
1392 * tree-chrec.h (evolution_function_right_is_integer_cst): New.
1393
13942009-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
1395
1396 * sese.c (expand_scalar_variables_ssa_name): Only build expressions,
1397 that we have not yet built for this SCoP.
1398
13992009-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
1400
1401 * sese.c (expand_scalar_variables_expr): Fix expand_scalar_variables
1402 for complex numbers.
1403
14042009-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
1405
1406 * graphite-ppl.c: Fix build if cloog is not available.
1407
14082009-05-04 Li Feng <nemokingdom@gmail.com>
1409
1410 * tree-parloops.c (loop_parallel_p): Remove construction of
1411 NITER and REDUCTION_LIST.
1412 (try_get_loop_niter): New.
1413 (try_create_reduction_list): New.
1414 (parallelize_loops): Bypass the failed checkings in autopar
1415 when can_be_parallel in loop structure is set to true.
1416
14172009-05-01 Tobias Grosser <grosser@fim.uni-passau.de>
1418
1419 * testsuite/gcc.dg/graphite/id-6.c: Update testcase.
1420 * testsuite/gcc.dg/graphite/scop-3.c: Dito.
1421
14222009-05-01 Tobias Grosser <grosser@fim.uni-passau.de>
1423
1424 * graphite-scop-detection.c (stmt_simple_for_scop_p):
1425 Enable EQ_EXPR and NE_EXPR again.
1426
14272009-04-30 Tobias Grosser <grosser@fim.uni-passau.de>
1428
1429 * graphite-scop-detection.c (graphite_can_represent_scev):
1430 Add check if scev is affine multivariate.
1431 (harmful_stmt_in_bb): Check if we can represent the conditions.
1432 (scopdet_basic_block_info (basic_block bb, VEC): Pass the loop to
1433 harmful_stmt_in_bb.
1434 * testsuite/gcc.dg/graphite/id-7.c: New.
1435
14362009-04-30 Tobias Grosser <grosser@fim.uni-passau.de>
1437
1438 * graphite-sese-to-poly.c (bb_contains_non_iv_scalar_phi_nodes):
1439 Check all bbs in region, not only the bbs that are represented in
1440 GRAPHITE.
1441 (build_poly_scop): Add newline.
1442 * testsuite/gcc.dg/graphite/id-8.c: New.
1443
14442009-04-30 Li Feng <nemokingdom@gmail.com>
1445
1446 * cfgloop.c (alloc_loop): Initialize can_be_parallel to false
1447 when loop initialize.
1448 * cfgloop.h (struct loop): Introduce flag can_be_parallel.
1449 * common.opt: Declare flag_graphite_force_parallel.
1450 * graphite-clast-to-gimple.c (translate_clast): Mark the innermost
1451 loop parallel.
1452 * graphite-poly.c (apply_poly_transforms): Introduce
1453 flag_graphite_force_parallel.
1454 * tree-ssa-loop.c (gate_graphite_transforms): ditto.
1455 * toplev.c (process_options): ditto and replace a not correctly
1456 encoded space.
1457
14582009-04-30 Li Feng <nemokingdom@gmail.com>
1459
1460 * graphite-clast-to-gimple.c (loop_iv_stack_patch_for_consts):
1461 Change the call of gbb_loop_at_index and/or gbb_loop_index due
1462 to the redefinition.
1463 (compute_cloog_iv_types_1): ditto.
1464 (build_iv_mapping): ditto.
1465 * graphite-sese-to-poly.c (new_gimple_bb): Remove GBB_LOOPS related
1466 initialization.
1467 (free_gimple_bb): Removed GBB_LOOPS related free part.
1468 (build_bb_loops): Removed.
1469 * sese.h (struct gimple_bb): Removed loops.
1470 (GBB_LOOPS): Removed.
1471 (gbb_loop_at_index): Instead of using GBB_LOOPS, we use sese instead.
1472 (gbb_loop_index): ditto.
1473
14742009-04-24 Tobias Grosser <grosser@fim.uni-passau.de>
1475
1476 * graphite-scop-detection.c (graphite_can_represent_scev): Do not
1477 allow non constant strides.
1478 * testsuite/gcc.dg/graphite/scop-20.c: New.
1479
14802009-04-24 Sebastian Pop <sebastian.pop@amd.com>
1481
1482 * graphite-scop-detection.c (dot_all_scops): Fix system call
1483 return value warning.
1484 (dot_scop): Same.
1485
14862009-04-24 Sebastian Pop <sebastian.pop@amd.com>
1487
1488 * testsuite/gcc.dg/graphite/id-6.c: Fix pattern.
1489 * testsuite/gcc.dg/graphite/scop-3.c: Same.
1490
14912009-04-24 Sebastian Pop <sebastian.pop@amd.com>
1492
1493 * graphite-poly.c (map_into_dep_poly, map_dr_into_dep_poly,
1494 build_pairwise_constraint, dr_equality_constraints,
1495 build_pairwise_scheduling_equality,
1496 build_pairwise_scheduling_inequality, lexicographically_gt_p,
1497 build_lexicographically_gt_constraint, dependence_polyhedron,
1498 graphite_legal_transform_dr, graphite_legal_transform_bb,
1499 graphite_legal_transform): New.
1500 * graphite-poly.h (graphite_legal_transform): Declared.
1501 * graphite-sese-to-poly.c (build_poly_scop): Call to
1502 graphite_legal_transform is disabled for the moment.
1503
15042009-04-24 Sebastian Pop <sebastian.pop@amd.com>
1505
1506 * graphite-poly.h (pbb_nb_scattering_dims): New.
1507 (pbb_nb_scattering): Use it.
1508
15092009-04-24 Sebastian Pop <sebastian.pop@amd.com>
1510
1511 * graphite-ppl.c (ppl_insert_dimensions_pointset): Add
1512 Pointset_Powerset version of ppl_insert_dimensions.
1513 * graphite-ppl.h (ppl_insert_dimensions_pointset): Declared.
1514
15152009-04-24 Sebastian Pop <sebastian.pop@amd.com>
1516
1517 * graphite-ppl.c (ppl_insert_dimensions): Fix formatting.
1518
15192009-04-24 Sebastian Pop <sebastian.pop@amd.com>
1520
1521 * graphite-poly.h: Fix comment.
1522
15232009-04-24 Sebastian Pop <sebastian.pop@amd.com>
1524
1525 * graphite-sese-to-poly.c (build_poly_dr): Fix data ref multiplier.
1526
15272009-04-24 Tobias Grosser <grosser@fim.uni-passau.de>
1528
1529 * sese.c (expand_scalar_variables_stmt): Only iterate over the old
1530 statements.
1531
15322009-04-24 Tobias Grosser <grosser@fim.uni-passau.de>
1533
1534 * graphite-sese-to-poly.c (var_used_in_not_loop_header_phi_node): New.
1535 (graphite_stmt_p): Represent bbs necessary to build the phi nodes of
1536 conditions.
1537
15382009-04-20 Sebastian Pop <sebastian.pop@amd.com>
1539
1540 * graphite-scop-detection.c (stmt_simple_for_scop_p): Do not
1541 handle EQ_EXPR and NE_EXPR.
1542
15432009-04-17 Tobias Grosser <grosser@fim.uni-passau.de>
1544
1545 * graphite-poly.h (poly_dr): Fix comment.
1546
15472009-04-09 Sebastian Pop <sebastian.pop@amd.com>
1548 Tobias Grosser <grosser@fim.uni-passau.de>
1549
1550 * graphite-poly.c (new_poly_bb): Do not initialize PBB_DOMAIN
1551 with a zero dimension polyhedron.
1552 (find_scop_parameters): Move the call to scop_set_nb_params here.
1553 (build_loop_iteration_domains): Store in loop->aux the iteration
1554 domain polyhedron.
1555 (build_scop_iteration_domain): Fix PBB_DOMAIN for bbs not surrounded
1556 by any loop in scop.
1557 (build_poly_scop): Do not call scop_set_nb_params.
1558
15592009-04-09 Sebastian Pop <sebastian.pop@amd.com>
1560 Tobias Grosser <grosser@fim.uni-passau.de>
1561
1562 * graphite-sese-to-poly.c (add_condition_to_pbb): Pass code to
1563 add_condition_to_domain not GT_EXPR.
1564
15652009-04-09 Tobias Grosser <grosser@fim.uni-passau.de>
1566
1567 * graphite-ppl.c (debug_ppl_powerset_matrix): New.
1568 * graphite-ppl.h (debug_ppl_powerset_matrix): New.
1569 * graphite-sese-to-poly.c (add_condition_to_pbb): Use
1570 upper_bound_assign to calculate unions.
1571 * testsuite/gcc.dg/graphite/id-6.c: New.
1572
15732009-04-09 Tobias Grosser <grosser@fim.uni-passau.de>
1574
1575 * graphite-scop-detection.c (canonicalize_loop_closed_ssa): Do not
1576 handle abnormal edges.
1577
15782009-04-09 Tobias Grosser <grosser@fim.uni-passau.de>
1579
1580 * graphite-poly.c (new_poly_dr, free_poly_dr): New.
1581 (free_poly_bb): Also free poly_drs.
1582 * graphite-poly.h (new_poly_dr, free_poly_dr): New.
1583 (poly_dr): Polyhedron to Pointset_Powerset.
1584 (pdr_accessp_nb_subscripts): Same.
1585 * graphite-sese-to-poly.c (build_poly_dr): Same. And actually build
1586 poly_drs.
1587
15882009-04-08 Sebastian Pop <sebastian.pop@amd.com>
1589
1590 * graphite-clast-to-gimple.c (initialize_cloog_names): Change cloog
1591 names into more meaningful names.
1592
15932009-04-08 Sebastian Pop <sebastian.pop@amd.com>
1594
1595 * testsuite/gfortran.dg/graphite/interchange-1.c: New.
1596 * testsuite/gfortran.dg/graphite/interchange-2.c: New.
1597
15982009-04-08 Sebastian Pop <sebastian.pop@amd.com>
1599
1600 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not build
1601 the reduction_list.
1602 * tree-parloops.c (rewrite_phi_with_iv): New.
1603 (rewrite_all_phi_nodes_with_iv): New.
1604 (canonicalize_loop_ivs): Call them.
1605
16062009-04-08 Sebastian Pop <sebastian.pop@amd.com>
1607
1608 * graphite-sese-to-poly.c (try_generate_gimple_bb): Use
1609 graphite_find_data_references_in_stmt.
1610 * tree-data-ref.c (graphite_find_data_references_in_stmt): New.
1611 * tree-data-ref.h (graphite_find_data_references_in_stmt): Declared.
1612
16132009-04-08 Sebastian Pop <sebastian.pop@amd.com>
1614
1615 * sese.c (add_loop_exit_phis): Don't fail on non SSA_NAME renames.
1616
16172009-04-08 Sebastian Pop <sebastian.pop@amd.com>
1618
1619 * graphite-sese-to-poly.c (build_scop_bbs_1): Use bb_in_sese_p
1620 instead of bb_in_region.
1621 (flag_bb_in_region): Same. Renamed flag_bb_in_sese.
1622 (build_sese_conditions): Use flag_bb_in_sese.
1623 * sese.c (register_bb_in_sese): Removed.
1624 (new_sese): Remove initialization of SESE_REGION_BBS.
1625 (free_sese): Do not free SESE_REGION_BBS.
1626 * sese.h (struct sese): Remove field region_basic_blocks.
1627 (SESE_REGION_BBS): Removed.
1628 (bb_in_sese_p): Implement in function of bb_in_region.
1629
16302009-04-08 Sebastian Pop <sebastian.pop@amd.com>
1631
1632 * graphite-scop-detection.c (limit_scops): Deal only with single exit
1633 loops.
1634
16352009-04-08 Tobias Grosser <grosser@fim.uni-passau.de>
1636
1637 * graphite-scop-detection.c (stmt_simple_for_scop_p): Allow NE_EXPR
1638 and EQ_EXPR.
1639 * graphite-sese-to-poly.c (create_linear_expr_from_tree): New.
1640 (add_condition_to_domain): New.
1641 (add_condition_to_pbb): New.
1642 (add_conditions_to_domain): Cleanup and handle of NE_EXPR and EQ_EXPR.
1643 * testsuite/gcc.dg/graphite/scop-3.c: Update number of detected SCoPs.
1644
16452009-04-08 Tobias Grosser <grosser@fim.uni-passau.de>
1646
1647 * graphite-clast-to-gimple.c (build_cloog_prog): ppl_Polyhedron ->
1648 ppl_Pointset_Powerset.
1649 * graphite-poly.c (new_poly_bb, free_poly_bb): Same.
1650 * graphite-poly.h (poly_bb): poly_bb.domain Same.
1651 (pbb_nb_loops): Same.
1652 * graphite-sese-to-poly.c (build_loop_iteration_domains,
1653 add_conditions_to_domain): Same.
1654 * graphite-ppl.c (new_Cloog_Domain_from_ppl_Pointset_Powerset): New.
1655 (ppl_print_polyhedron_matrix): ppl_Polyhedron_t ->
1656 ppl_const_Polyhedron_t.
1657 (ppl_print_powerset_matrix): New.
1658 * graphite-ppl.h (new_Cloog_Domain_from_ppl_Pointset_Powerset,
1659 ppl_print_powerset_matrix): New.
1660 (ppl_print_polyhedron_matrix): Updated.
1661
16622009-04-07 Sebastian Pop <sebastian.pop@amd.com>
1663
1664 * tree-scalar-evolution.c (analyze_scalar_evolution_1): Fix comment.
1665
16662009-04-07 Sebastian Pop <sebastian.pop@amd.com>
1667
1668 * graphite-poly.c (extend_scattering): Fix indenting. Free cstr.
1669 (print_iteration_domains, debug_iteration_domain,
1670 debug_iteration_domains): New.
1671 * graphite-poly.h (print_iteration_domains, debug_iteration_domain,
1672 debug_iteration_domains): Declared.
1673 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons): Fix
1674 indenting.
1675
16762009-04-03 Tobias Grosser <grosser@fim.uni-passau.de>
1677 Sebastian Pop <sebastian.pop@amd.com>
1678
1679 * graphite-poly.h (print_iteration_domain): New.
1680 * graphite-sese-to-poly.c (add_conditions_to_domain): Fixed bug.
1681 (build_sese_conditions_1, build_sese_conditions_after,
1682 build_sese_conditions_before): New.
1683 (build_sese_conditions): Rewritten.
1684
16852009-04-03 Sebastian Pop <sebastian.pop@amd.com>
1686 Tobias Grosser <grosser@fim.uni-passau.de>
1687
1688 Cleanup of code generation liveouts.
1689 * graphite-clast-to-gimple.c (translate_clast): Use a single
1690 rename_map instead of one per translated statement.
1691 Do not use SESE_LIVEOUT_RENAMES.
1692 (graphite_loop_normal_form): Do not use SESE_REDUCTION_LIST.
1693 (gloog): Do not use SESE_LIVEOUT_RENAMES.
1694 * graphite-scop-detection.c (harmful_stmt_in_bb): Return the close
1695 phi node of a reduction: when a loop contains a reduction used outside
1696 the loop, there should be a scalar close phi node on the exit block.
1697 * sese.c (new_sese): Do not initialize SESE_LIVEOUT,
1698 SESE_LIVEOUT_RENAMES, and SESE_REDUCTION_LIST.
1699 (free_sese): Do not free them.
1700 (sese_build_liveouts_use): Do not use them.
1701 (sese_build_liveouts_bb): Same.
1702 (sese_build_liveouts): Same.
1703 (sese_insert_phis_for_liveouts): Same.
1704 (sese_adjust_phis_for_liveouts): Same. Renamed sese_adjust_liveout_phis.
1705 (defined_in_loop_p): New.
1706 (alive_after_loop): New.
1707 (close_phi_not_yet_inserted_p): New.
1708 (struct alep, alep_p): New.
1709 (add_loop_exit_phis): Remove from the rename_map all the names defined
1710 in the code generated loop.
1711 (insert_loop_close_phis): Traverse the rename_map passed to it.
1712 Don't use SESE_LIVEOUT_RENAMES.
1713 (default_liveout_before_guard): Renamed default_before_guard.
1714 (insert_guard_phis): Do not use SESE_LIVEOUT_RENAMES.
1715 (graphite_copy_stmts_from_block): Do not directly call set_rename.
1716 (register_sese_liveout_renames): Removed.
1717 (copy_bb_and_scalar_dependences): Do not call it.
1718 * sese.h (struct sese): Removed fields: liveout, liveout_renames, and
1719 reduction_list.
1720 (SESE_LIVEOUT): Removed.
1721 (SESE_LIVEOUT_RENAMES): Removed.
1722 (SESE_REDUCTION_LIST): Removed.
1723 (sese_build_liveouts): Removed.
1724 (sese_adjust_phis_for_liveouts): Renamed sese_adjust_liveout_phis.
1725 (insert_loop_close_phis): Pass a htab_t instead of a sese.
1726 (insert_guard_phis): Same.
1727 (rename_map_elt): Declare a VEC of them.
1728 * tree-parloops.c (canonicalize_loop_ivs): reduction_list contains
1729 trees not pointers to trees.
1730
1731 Rewrite in canonical close SSA form:
1732 * graphite-scop-detection.c (contains_only_close_phi_nodes): New.
1733 (limit_scops): Close the scop after the block containing the close phi
1734 nodes.
1735 (canonicalize_loop_closed_ssa): New.
1736 (canonicalize_loop_closed_ssa_form): New.
1737 (build_scops): Call canonicalize_loop_closed_ssa_form.
1738
1739 * graphite-sese-to-poly.c: Fix typos.
1740
17412009-04-03 Sebastian Pop <sebastian.pop@amd.com>
1742
1743 * graphite-poly.c (print_scattering_function, print_pbb_domain):
1744 Extended.
1745 (dump_gbb_conditions, dump_gbb_cases, print_iteration_domain): New.
1746 (print_pbb): Add conditions.
1747
17482009-04-01 Tobias Grosser <grosser@fim.uni-passau.de>
1749 Sebastian Pop <sebastian.pop@amd.com>
1750
1751 * graphite-scop-detection.c (bb_in_sd_region): Use bb_in_region.
1752 * graphite-sese-to-poly.c (all_non_dominated_preds_marked_p): New.
1753 (build_scop_bbs_1): New.
1754 (build_scop_bbs): Rewrite.
1755 * sese.h (bb_in_region): New.
1756
17572009-03-29 Tobias Grosser <grosser@fim.uni-passau.de>
1758
1759 * graphite-poly.c (new_poly_bb, free_poly_bb): Initialize/free
1760 poly_drs vector.
1761 (print_scop): Style.
1762 * graphite-poly.h (poly_bb): Add drs vector.
1763 (PBB_DRS): Add accessor.
1764 * graphite-sese-to-poly.c (build_poly_dr): New.
1765 (build_pbb_drs, build_scop_drs): New.
1766 (build_poly_scop): call build_scop_drs (Disabled at the moment).
1767
17682009-03-29 Tobias Grosser <grosser@fim.uni-passau.de>
1769
1770 * tree-ssa-loop.c: Include forgotten toplev.h
1771
17722009-03-29 Tobias Grosser <grosser@fim.uni-passau.de>
1773
1774 * graphite-poly.c: (apply_poly_transforms): sorry -> gcc_unreachable.
1775 * testsuite/gcc.dg/graphite/pr37883.c: Remove -floop-*
1776 * testsuite/gcc.dg/graphite/pr37928.c: Same
1777 * testsuite/gcc.dg/graphite/pr38409.c: Same
1778 * testsuite/gcc.dg/graphite/pr38498.c: Same
1779 * testsuite/gcc.dg/graphite/pr38559.c: Same
1780 * testsuite/gcc.dg/graphite/pr39335.c: Same
1781 * testsuite/gcc.dg/graphite/pr39335_1.c: Same
1782 * testsuite/gfortran.dg/graphite/block-2.f: Same
1783 * tree-ssa-loop.c (gate_graphite_transforms): Always fail if called
1784 with -floop-*.
1785
17862009-03-28 Tobias Grosser <grosser@fim.uni-passau.de>
1787
1788 * graphite-sese-to-poly.c (ref_nb_loops, build_access_matrix_with_af,
1789 build_access_matrix, build_scop_data_accesses): Remove access function
1790 building. (We get a new version soon).
1791 (build_bb_loops, scan_tree_for_params_right_scev): Update.
1792 * sese.h (nb_loops_around_loop_in_sese): Remove.
1793 (sese_loop_depth): Do not use SESE_LOOP_NEST any more.
1794
17952009-03-27 Tobias Grosser <grosser@fim.uni-passau.de>
1796 Sebastian Pop <sebastian.pop@amd.com>
1797
1798 * graphite-scop-detection.c (struct scopdet_info): Rename last
1799 field to exit.
1800 (scopdet_basic_block_info, build_scops_1): Don't use
1801 CDI_POST_DOMINATORS. CDI_POST_DOMINATORS should never be used.
1802
18032009-03-26 Tobias Grosser <grosser@fim.uni-passau.de>
1804 Sebastian Pop <sebastian.pop@amd.com>
1805
1806 * graphite-clast-to-gimple.c (gloog): Call sese_build_liveouts.
1807 * sese.c (sese_build_liveouts_use): Renamed from
1808 sese_build_livein_liveouts_use. Remove liveins.
1809 (sese_build_liveouts_bb): Renamed from sese_build_livein_liveouts_bb.
1810 Call sese_build_liveouts_use.
1811 (sese_build_liveouts): Renamed from sese_build_livein_liveouts.
1812 Call sese_build_liveouts_bb.
1813 (new_sese, free_sese): Remove liveins.
1814 (sese_add_exit_phis_var): Deleted.
1815 (sese_insert_phis_for_liveouts): Call sese_add_exit_phis_edge
1816 directly.
1817 (graphite_copy_stmts_from_block): Remove SESE_NUM_VER.
1818
1819 * sese.h (sese): Remove num_ver and livein.
1820 (SESE_LIVEIN, SESE_LIVEIN_VER, SESE_NUM_VER): Removed.
1821
18222009-03-25 Tobias Grosser <grosser@fim.uni-passau.de>
1823
1824 * graphite-sese-to-poly.c (build_scop_scattering): Fix compile.
1825
18262009-03-25 Tobias Grosser <grosser@fim.uni-passau.de>
1827
1828 * graphite-sese-to-poly.c (compare_prefix_loops): Removed.
1829 (build_scop_scattering): Do not use compare_prefix_loops any more.
1830 (nb_common_loops): New.
1831
18322009-03-24 Sebastian Pop <sebastian.pop@amd.com>
1833
1834 * sese.c (get_new_name_from_old_name): Renamed get_rename.
1835 (register_old_and_new_names): Renamed set_rename.
1836
18372009-03-24 Sebastian Pop <sebastian.pop@amd.com>
1838
1839 * graphite-scop-detection.h (nb_reductions_in_loop): Revert removal
1840 of the decl from the previous commit.
1841
18422009-03-24 Sebastian Pop <sebastian.pop@amd.com>
1843
1844 * graphite-scop-detection.c (dot_scop): New.
1845 * graphite-scop-detection.h (dot_scop): Declared.
1846
18472009-03-24 Sebastian Pop <sebastian.pop@amd.com>
1848
1849 * graphite-sese-to-poly.c (compare_prefix_loops): Fix compare.
1850
18512009-03-24 Sebastian Pop <sebastian.pop@amd.com>
1852
1853 * cfgloopmanip.c (create_empty_loop_on_edge): Generate the loop exit
1854 condition at the end of the loop.
1855 * graphite.c (graphite_initialize, graphite_finalize): Print to
1856 dump_file the compiled function.
1857 * graphite-clast-to-gimple.c (graphite_create_new_loop): Update use
1858 of create_empty_loop_on_edge.
1859 (translate_clast): Update the code generation of loops for the new
1860 shape of loops.
1861 * cfgloop.h (create_empty_loop_on_edge): Update declaration.
1862
18632009-03-24 Sebastian Pop <sebastian.pop@amd.com>
1864
1865 Reverted the patch from 2009-03-19.
1866
18672009-03-19 Tobias Grosser <grosser@fim.uni-passau.de>
1868
1869 * graphite-poly.c (new_poly_bb, free_poly_bb): Initialize/free
1870 poly_drs vector.
1871 (print_scop): Style.
1872 * graphite-poly.h (poly_bb): Add drs vector.
1873 (PBB_DRS): Add accessor.
1874 * graphite-sese-to-poly.c (ref_nb_loops): Remove.
1875 (build_access_matrix_with_af, build_access_matrix,
1876 build_scop_data_accesses): Delete.
1877 (build_poly_dr): New.
1878 (build_pbb_drs, build_scop_drs): New.
1879 (build_poly_scop): call build_scop_drs.
1880
18812009-03-13 Sebastian Pop <sebastian.pop@amd.com>
1882
1883 * graphite-scop-detection.c (dot_all_scops_1): Close the table
1884 once per basic block.
1885
18862009-03-13 Tobias Grosser <grosser@fim.uni-passau.de>
1887
1888 * graphite-scop-detection.c (graphite_can_represent_scev): New.
1889 (graphite_can_represent_expr): Renamed from loop_affine_expr
1890 and enhanced.
1891 (stmt_simple_for_scop_p): Call graphite_can_represent_expr.
1892 (graphite_cannot_represent_loop): Add scop_entry to parameters.
1893 (scopdet_basic_block_info): Actually define entry_block.
1894 (stmt_simple_memref_p): Moved here from ...
1895
1896 * tree-data-ref.c (stmt_simple_memref_p): here.
1897 * tree-data-ref.h (stmt_simple_memref_p): Removed.
1898
18992009-03-13 Tobias Grosser <grosser@fim.uni-passau.de>
1900
1901 * testsuite/gcc.dg/graphite/id-4.c: New.
1902
19032009-03-12 Sebastian Pop <sebastian.pop@amd.com>
1904
1905 * sese.c (expand_scalar_variables_expr): Handle tcc_comparison.
1906 (register_old_and_new_names): Update the content of the map.
1907 When there was already a rename_map_elt in the map at that
1908 location, free it.
1909 (copy_bb_and_scalar_dependences): Do rename_variables after
1910 expand_scalar_variables.
1911 * graphite-clast-to-gimple.c (build_iv_mapping): Update the content
1912 of the map. When there was already a rename_map_elt in the
1913 map at that location, free it.
1914 (translate_clast): Pass the rename_map. Do not initialize and free
1915 a rename_map per stmt_user.
1916 (gloog): Initialize and free one rename_map and pass it to
1917 translate_clast.
1918
19192009-03-12 Sebastian Pop <sebastian.pop@amd.com>
1920
1921 * sese.c (expand_scalar_variables_stmt,
1922 expand_scalar_variables_ssa_name): Add a gimple_stmt_iterator
1923 parameter.
1924 (expand_scalar_variables_expr): Handle REALPART_EXPR and IMAGPART_EXPR.
1925 (expand_scalar_variables): Pass to expand_scalar_variables_stmt
1926 the gimple_stmt_iterator of the statement to be expanded.
1927 * graphite-scop-detection.c (is_simple_operand): Do handle
1928 REALPART_EXPR.
1929
19302009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
1931
1932 * graphite-scop-detection.c (is_simple_operand): Do not handle
1933 REALPART_EXPR.
1934 * testsuite/gcc.dg/graphite/id-2.c: New.
1935
1936 * graphite-sese-to-poly.c (build_bb_loops,
1937 add_value_to_dim, scan_tree_for_params_right_scev,
1938 scan_tree_for_params_int, scan_tree_for_params, idx_record_params,
1939 find_params_in_bb, build_loop_iteration_domains,
1940 add_conditions_to_domain): Remove subtract.
1941
19422009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
1943
1944 * graphite-clast-to-gimple.c (loop_iv_stack_patch_for_consts,
1945 build_iv_mapping, compute_cloog_iv_types_1, build_cloog_prog):
1946 pbb_loop_at_index -> gbb_loop_at_index.
1947 * graphite-poly.c (new_poly_bb, new_scop): New accessors.
1948 (debug_loop_vec): Delete.
1949 * graphite-poly.h (poly_bb, scop): Change black_box and region to void
1950 pointer. Move LOOPS to gimple_bb_p and insert nb_params.
1951 (PBB_LOOPS): Removed.
1952 (PBB_BLACK_BOX): Insert cast.
1953 (pbb_set_black_box): New setter.
1954 (pbb_loop_at_index, pbb_loop_index): Removed.
1955 (scop_set_region, scop_set_nb_params): New.
1956 * graphite-sese-to-poly.c (new_gimple_bb, free_gimple_bb,
1957 build_scop_scattering, build_bb_loops): Add GBB_LOOPS.
1958 (build_poly_scop): Use scop_set_nb_params.
1959 * sese.h (gimple_bb): Add LOOPS.
1960 (GBB_LOOPS, gbb_loop_index, gbb_loop_at_index): New.
1961
19622009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
1963
1964 Revert previous commit.
1965
19662009-03-11 Sebastian Pop <sebastian.pop@amd.com>
1967
1968 * sese.c (expand_scalar_variables_expr): Handle tcc_comparison.
1969 (register_old_and_new_names): Update the content of the map.
1970 When there was already a rename_map_elt in the map at that
1971 location, free it.
1972 (copy_bb_and_scalar_dependences): Do rename_variables after
1973 expand_scalar_variables.
1974 * graphite-clast-to-gimple.c (build_iv_mapping): Update the content
1975 of the map. When there was already a rename_map_elt in the
1976 map at that location, free it.
1977 (translate_clast): Pass the rename_map. Do not initialize and free
1978 a rename_map per stmt_user.
1979 (gloog): Initialize and free one rename_map and pass it to
1980 translate_clast.
1981
19822009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
1983
1984 Remove forgotten line in revert.
1985
19862009-03-11 Sebastian Pop <sebastian.pop@amd.com>
1987
1988 Revert previous commit.
1989
19902009-03-10 Sebastian Pop <sebastian.pop@amd.com>
1991
1992 * sese.c (register_old_and_new_names): Update the content
1993 of the map. When there was already a rename_map_elt in the
1994 map at that location, free it.
1995 (copy_bb_and_scalar_dependences): Do rename_variables after
1996 expand_scalar_variables.
1997 * graphite-clast-to-gimple.c (build_iv_mapping): Update the content
1998 of the map. When there was already a rename_map_elt in the
1999 map at that location, free it.
2000 (translate_clast): Pass the rename_map. Do not initialize and free
2001 a rename_map per stmt_user.
2002 (gloog): Initialize and free one rename_map and pass it to
2003 translate_clast.
2004
20052009-03-10 Sebastian Pop <sebastian.pop@amd.com>
2006
2007 * graphite-clast-to-gimple.c (translate_clast): context_loop
2008 is never NULL.
2009
20102009-03-10 Tobias Grosser <grosser@fim.uni-passau.de>
2011 Sebastian Pop <sebastian.pop@amd.com>
2012
2013 * graphite-ppl.c (ppl_insert_dimensions): Fix stupid mistake
2014 of the use of ppl_Polyhedron_map_space_dimensions.
2015
20162009-03-10 Tobias Grosser <grosser@fim.uni-passau.de>
2017 Sebastian Pop <sebastian.pop@amd.com>
2018
2019 * graphite-poly.c (unify_scattering_dimensions): Fix types.
2020 * graphite-poly.h (poly_dr_p, poly_dr, POLY_DR_TYPE, PDR_BB,
2021 PDR_TYPE, PDR_ACCESSES, pdr_accessp_nb_subscripts,
2022 pdr_accessp_nb_iterators, pdr_accessp_nb_params,
2023 pdr_accessp_alias_set_dim, pdr_accessp_subscript_dim,
2024 pdr_accessp_iterator_dim, pdr_accessp_param_dim,
2025 pbb_nb_params): New.
2026 (pbb_nb_loops, pbb_nb_scattering, scop_nb_params,
2027 nb_loops_around_pbb): Adapt return types.
2028
20292009-03-09 Tobias Grosser <grosser@fim.uni-passau.de>
2030
2031 * Makefile.in (graphite.o, graphite-sese-to-poly.o,
2032 graphite-clast-to-gimple.o, graphite-data-ref.o,
2033 graphite-scop-detection.o, graphite-poly.o): Add
2034 more headers.
2035
20362009-03-05 Tobias Grosser <grosser@fim.uni-passau.de>
2037
2038 * Makefile.in (graphite.o, graphite-sese-to-poly.o,
2039 graphite-clast-to-gimple.o, graphite-data-ref.o,
2040 graphite-scop-detection.o, graphite-poly.o): Add graphite-poly.h.
2041
20422009-03-04 Tobias Grosser <grosser@fim.uni-passau.de>
2043
2044 * testsuite/gcc.dg/graphite/pr37485.c: Remove -floop-block
2045 * testsuite/gcc.dg/graphite/pr37828.c: Same.
2046 * testsuite/gcc.dg/graphite/pr37684.c: Same.
2047 * testsuite/gcc.dg/graphite/block-0.c: Same.
2048 * testsuite/gcc.dg/graphite/block-1.c: Same.
2049 * testsuite/gcc.dg/graphite/block-2.c: Same.
2050 * testsuite/gcc.dg/graphite/block-3.c: Same.
2051 * testsuite/gcc.dg/graphite/block-4.c: Same.
2052 * testsuite/gcc.dg/graphite/block-5.c: Same.
2053 * testsuite/gcc.dg/graphite/block-6.c: Same.
2054 * testsuite/gfortran.dg/graphite/pr38083.f90: Same.
2055 * testsuite/gfortran.dg/graphite/block-1.f90: Same.
2056 * testsuite/gfortran.dg/graphite/block-3.f90: Same.
2057 * testsuite/gfortran.dg/graphite/pr37852.f90: Same.
2058 * testsuite/gfortran.dg/graphite/block-4.f90: Same.
2059 * testsuite/gfortran.dg/graphite/pr37980.f90: Same.
2060 * testsuite/gfortran.dg/graphite/pr38953.f90: Same.
2061 * testsuite/gfortran.dg/graphite/pr37857.f90: Same.
2062 * opts.c: Remove -floop-block from -O2.
2063 * graphite-poly.c: Fail if -floop-block -floop-interchange or
2064 -floop-strip-mine are used.
2065
20662009-03-04 Tobias Grosser <grosser@fim.uni-passau.de>
2067 Sebastian Pop <sebastian.pop@amd.com>
2068
2069 * graphite-clast-to-gimple.c (build_cloog_prog): Unify scattering
2070 dimensions.
2071 * graphite-poly.c (pbb_compare, graphite_sort_pbbs,
2072 graphite_trans_bb_move_loop, graphite_trans_bb_strip_mine,
2073 strip_mine_profitable_p, is_interchange_valid,
2074 graphite_trans_bb_block, graphite_trans_loop_block,
2075 graphite_trans_scop_block): Temporary removed.
2076 (extend_scattering, unify_scattering_dimensions): New.
2077 (print_scattering_function, graphite_read_transforms):
2078 PBB_SCATTERING -> PBB_TRANSFORMED_SCATTERING.
2079 (graphite_generate_scattering_fns): Removed.
2080 (apply_poly_transforms): Cleanup.
2081 (free_poly_bb): Add PBB_SCATTERING -> PBB_TRANSFORMED_SCATTERING.
2082 (schedule_to_scattering): Moved.
2083 (PBB_STATIC_SCHEDULE, PBB_SCATTERING): Removed.
2084 (PBB_ORIGINAL_SCATTERING, PBB_TRANSFORMED_SCATTERING): New.
2085 (pbb_nb_scattering): New.
2086 (SCOP_ENTRY, SCOP_EXIT, SCOP_REGION_BBS, SCOP_DEP_GRAPH, SCOP_PARAMS,
2087 SCOP_LOOP_NEST, SCOP_PARAMS, SCOP_OLDIVS, SCOP_LIVEOUT_RENAMES):
2088 Removed.
2089 * graphite-ppl.c (ppl_insert_dimensions): Extended and renamed from
2090 shift_poly.
2091 (ppl_strip_loop): PBB_SCATTERING -> PBB_TRANSFORMED_SCATTERING.
2092 * graphite-scop-detection.c (dot_all_scops_1): PBB_SCATTERING
2093 -> PBB_TRANSFORMED_SCATTERING.
2094 * graphite-sese-to-poly.c (build_scop_bbs): Remove region.
2095 (build_pbb_scattering_polyhedron): Moved from schedule_to_scattering.
2096 (build_scop_scattering): Renamed from build_scop_canonical_schedules.
2097 (check_poly_representation): Do not return bool.
2098 (graphite_transform_loops): Reformat.
2099 * sese.h (SESE_ENTRY_BB, SESE_EXIT_BB): New.
2100
21012009-03-04 Sebastian Pop <sebastian.pop@amd.com>
2102
2103 * graphite-poly.c (print_pbb_domain, print_pbb, print_scop,
2104 debug_pbb_domain, debug_pbb, debug_scop): New.
2105 * graphite-poly.h (print_pbb_domain, print_pbb, print_scop,
2106 debug_pbb_domain, debug_pbb, debug_scop): Declared.
2107
21082009-03-02 Sebastian Pop <sebastian.pop@amd.com>
2109
2110 PR middle-end/39335
2111 * tree-parloops.c (canonicalize_loop_ivs): Call fold_convert
2112 when the type precision of the induction variable should be
2113 larger than the type precision of nit.
2114 (gen_parallel_loop): Update use of canonicalize_loop_ivs.
2115 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Same.
2116 * tree-flow.h (canonicalize_loop_ivs): Update declaration.
2117
2118 * testsuite/gcc.dg/graphite/pr39335_1.c: New.
2119 * testsuite/gcc.dg/graphite/pr39335.c: New.
2120
21212009-03-02 Sebastian Pop <sebastian.pop@amd.com>
2122
2123 * tree-parloops.c (canonicalize_loop_ivs): reduction_list contains
2124 SSA_NAMES not struct reduction_info.
2125
21262009-03-02 Sebastian Pop <sebastian.pop@amd.com>
2127
2128 * sese.c (expand_scalar_variables_expr): Handle ADDR_EXPR.
2129
21302009-02-27 Sebastian Pop <sebastian.pop@amd.com>
2131 Tobias Grosser <grosser@fim.uni-passau.de>
2132
2133 * sese.c (new_sese): Initialize SESE_REDUCTION_LIST.
2134 (free_sese): Free SESE_REDUCTION_LIST.
2135 * sese.h (struct sese): Add field reduction_list.
2136 (SESE_REDUCTION_LIST): New.
2137 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Call
2138 canonicalize_loop_ivs on SESE_REDUCTION_LIST.
2139
21402009-02-27 Sebastian Pop <sebastian.pop@amd.com>
2141 Tobias Grosser <grosser@fim.uni-passau.de>
2142
2143 * tree-flow.h (gather_scalar_reductions): Use struct loop * instead
2144 of loop_p.
2145
21462009-02-27 Sebastian Pop <sebastian.pop@amd.com>
2147 Tobias Grosser <grosser@fim.uni-passau.de>
2148
2149 * tree-parloops.c (struct brli, build_reduction_list_info,
2150 analyze_reduction_list, gather_scalar_reductions): New.
2151 (loop_parallel_p): Build a reduction list containing only
2152 PHI_RESULT SSA_NAMEs: call gather_scalar_reductions.
2153 (gen_parallel_loop): Call the analysis analyze_reduction_list.
2154 (parallelize_loops): Now reduction_list is a htab_t of SSA_NAMEs.
2155 * tree-flow.h (gather_scalar_reductions): Declared.
2156
21572009-02-26 Sebastian Pop <sebastian.pop@amd.com>
2158
2159 PR middle-end/39308
2160 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not call
2161 number_of_iterations_exit from a gcc_assert.
2162
21632009-02-25 Sebastian Pop <sebastian.pop@amd.com>
2164 Jan Sjodin <jan.sjodin@amd.com>
2165
2166 * output.h (graphite_out_file, graphite_in_file): Declared.
2167 * toplev.c (graphite_out_file, graphite_in_file): New.
2168 (init_asm_output): Initialize graphite_in_file and graphite_out_file.
2169 * graphite-clast-to-gimple.c (build_cloog_prog): Read PBB_SCATTERING.
2170 Don't call schedule_to_scattering.
2171 * common.opt (fgraphite-write, fgraphite-read): New.
2172 * graphite-poly.c: Include output.h.
2173 (print_scattering_function, print_scattering_functions,
2174 debug_scattering_function, debug_scattering_functions,
2175 graphite_write_transforms, graphite_read_transforms,
2176 graphite_generate_scattering_fns): New.
2177 (apply_poly_transforms): Do not apply transform if flag_graphite_read.
2178 Call graphite_generate_scattering_fns, graphite_write_transforms,
2179 graphite_read_transforms.
2180 (new_poly_bb): Initialize PBB_SCATTERING.
2181 (free_poly_bb): Free PBB_SCATTERING.
2182 (schedule_to_scattering): Does not return, initialize PBB_SCATTERING.
2183 * graphite-poly.h (struct poly_bb): Add field scattering.
2184 (PBB_SCATTERING): New.
2185 (print_scattering_function, print_scattering_functions,
2186 debug_scattering_function, debug_scattering_functions): Declared.
2187 * graphite-ppl.c (cloog_matrix_to_ppl_constraint): Matrices contain
2188 GMP values, not integers!
2189 (ppl_print_polyhedron_matrix, debug_ppl_polyhedron_matrix,
2190 ppl_read_polyhedron_matrix): New.
2191 * graphite-ppl.h (ppl_print_polyhedron_matrix,
2192 debug_ppl_polyhedron_matrix,
2193 ppl_read_polyhedron_matrix): Declared.
2194 * Makefile.in (graphite-poly.o): Depends on output.h.
2195
21962009-02-23 Sebastian Pop <sebastian.pop@amd.com>
2197 Tobias Grosser <grosser@fim.uni-passau.de>
2198
2199 Revert this change:
2200 * graphite-scop-detection.c (stmt_simple_for_scop_p): Analyze
2201 scalar evolutions in the scop_entry->loop_father.
2202
22032009-02-23 Sebastian Pop <sebastian.pop@amd.com>
2204 Tobias Grosser <grosser@fim.uni-passau.de>
2205
2206 * graphite.h (ref_nb_loops): Remove declaration.
2207 (struct gimple_bb, gimple_bb_p, GBB_BB, GBB_DATA_REFS, GBB_CONDITIONS,
2208 GBB_CONDITION_CASES, GBB_CLOOG_IV_TYPES, gbb_loop, print_gimple_bb,
2209 debug_gbb): Moved to sese.h.
2210 * sese.h: As said.
2211
22122009-02-23 Sebastian Pop <sebastian.pop@amd.com>
2213 Tobias Grosser <grosser@fim.uni-passau.de>
2214
2215 * graphite-data-ref.[ch]: Disable.
2216
22172009-02-23 Sebastian Pop <sebastian.pop@amd.com>
2218 Tobias Grosser <grosser@fim.uni-passau.de>
2219
2220 * graphite-scop-detection.c (stmt_simple_for_scop_p): Analyze
2221 scalar evolutions in the scop_entry->loop_father.
2222
22232009-02-23 Sebastian Pop <sebastian.pop@amd.com>
2224
2225 * graphite-scop-detection.c (nb_reductions_in_loop): Moved here...
2226 (graphite_cannot_represent_loop_niter): Renamed
2227 graphite_cannot_represent_loop. Call nb_reductions_in_loop.
2228 (limit_scops): build_sese_loop_nests does not return a bool.
2229 * graphite-scop-detection.h (nb_reductions_in_loop): Declared.
2230 * sese.c (nb_reductions_in_loop): ... from here.
2231 (graphite_loop_normal_form): ... from here.
2232 (sese_record_loop): Does not fail, so does not return a bool.
2233 (build_sese_loop_nests): Same.
2234 * sese.h (build_sese_loop_nests): Update declaration.
2235 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Moved here...
2236 (build_graphite_loop_normal_form): New.
2237 (gloog): Call build_graphite_loop_normal_form.
2238 * graphite-sese-to-poly.c (build_poly_scop): Don't fail on
2239 build_sese_loop_nests.
2240
2241 * testsuite/gcc.dg/graphite/id-1.c: New.
2242
22432009-02-23 Sebastian Pop <sebastian.pop@amd.com>
2244 Tobias Grosser <grosser@fim.uni-passau.de>
2245
2246 * graphite-sese-to-poly.c (scan_tree_for_params): Remove REAL_CST.
2247 The SCoP detection fix is sufficient.
2248
22492009-02-21 Sebastian Pop <sebastian.pop@amd.com>
2250
2251 PR tree-optimization/39260
2252 * graphite-scop-detection.c (harmful_stmt_in_bb): Stop a SCoP when
2253 the basic block contains a condition with a real type.
2254 * graphite-sese-to-poly.c (scan_tree_for_params): Handle REAL_CST.
2255
2256 * gcc.dg/graphite/pr39260.c: New.
2257
22582009-02-21 Sebastian Pop <sebastian.pop@amd.com>
2259
2260 * graphite-poly.c: Inlcude params.h.
2261 (graphite_trans_loop_block): Use PARAM_LOOP_BLOCK_TILE_SIZE for
2262 the size of a tile.
2263 * Makefile.in (graphite-poly.o): Depend on PARAMS_H.
2264 * params.def (PARAM_LOOP_BLOCK_TILE_SIZE): Define.
2265
22662009-02-20 Sebastian Pop <sebastian.pop@amd.com>
2267 Tobias Grosser <grosser@fim.uni-passau.de>
2268
2269 * graphite-scop-detection.c (dot_all_scops_1,
2270 dot_all_scops): Moved here.
2271 * graphite-scop-detection.h (dot_all_scops): Declared here.
2272 * graphite.c (graphite_initialize, graphite_finalize): New.
2273 (graphite_transform_loops): Cleaned up.
2274 * sese.c (debug_oldivs): Moved here.
2275 * graphite-poly.c (graphite_apply_transformations): Renamed
2276 apply_poly_transforms.
2277 (debug_loop_vec): Moved here.
2278 * graphite-sese-to-poly.c (build_bb_loops, build_sese_conditions_1,
2279 scop_contains_non_iv_scalar_phi_nodes, build_sese_conditions,
2280 find_scop_parameters, build_scop_iteration_domain,
2281 add_conditions_to_constraints, build_scop_canonical_schedules,
2282 build_scop_data_accesses): Now static.
2283 (build_poly_scop, check_poly_representation): New.
2284
22852009-02-20 Sebastian Pop <sebastian.pop@amd.com>
2286
2287 * graphite.c (graphite_stmt_p, new_gimple_bb, free_gimple_bb,
2288 remove_gbbs_in_scop, free_scops, try_generate_gimple_bb,
2289 build_scop_bbs, ref_nb_loops, compare_prefix_loops,
2290 build_scop_canonical_schedules, build_bb_loops, add_value_to_dim,
2291 scan_tree_for_params_right_scev, scan_tree_for_params_int,
2292 scan_tree_for_params, struct irp_data, dx_record_params,
2293 find_params_in_bb, find_scop_parameters, gbb_from_bb,
2294 build_loop_iteration_domains, add_conditions_to_domain,
2295 phi_node_is_iv, bb_contains_non_iv_scalar_phi_nodes,
2296 scop_contains_non_iv_scalar_phi_nodes, build_sese_conditions_1,
2297 build_sese_conditions, add_conditions_to_constraints,
2298 build_scop_iteration_domain, build_access_matrix_with_af,
2299 build_access_matrix,
2300 build_scop_data_accesses): Moved to graphite-sese-to-poly.c.
2301
2302 * graphite-sese-to-poly.c: New.
2303 * graphite-sese-to-poly.h: New.
2304
2305 * Makefile.in: Add new rule for graphite-sese-to-poly.o.
2306
23072009-02-20 Sebastian Pop <sebastian.pop@amd.com>
2308
2309 * graphite.c: Split graphite code generation to a new file.
2310 (graphite_verify, gmp_cst_to_tree, clast_name_to_gcc,
2311 max_precision_type, clast_to_gcc_expression_red,
2312 clast_to_gcc_expression, gcc_type_for_clast_expr,
2313 gcc_type_for_clast_eq, loop_iv_stack_patch_for_consts,
2314 graphite_translate_clast_equation, graphite_create_guard_cond_expr,
2315 graphite_create_new_guard, clast_get_body_of_loop,
2316 gcc_type_for_cloog_iv, gcc_type_for_iv_of_clast_loop,
2317 graphite_create_new_loop, build_iv_mapping, copy_renames,
2318 translate_clast, find_cloog_iv_in_expr, compute_cloog_iv_types_1,
2319 compute_cloog_iv_types, free_scattering, save_var_name,
2320 initialize_cloog_names, build_scop_context, build_cloog_prog,
2321 set_cloog_options, debug_clast_stmt, scop_to_clast,
2322 print_generated_program, debug_generated_program,
2323 gloog): Moved to graphite-clast-to-gimple.c.
2324
2325 (struct cloog_prog_clast): Moved to graphite-clast-to-gimple.h.
2326
2327 (iv_stack_entry_is_constant, iv_stack_entry_is_iv,
2328 loop_iv_stack_push_iv, loop_iv_stack_insert_constant,
2329 loop_iv_stack_pop, loop_iv_stack_get_iv,
2330 loop_iv_stack_get_iv_from_name, debug_loop_iv_stack,
2331 free_loop_iv_stack, loop_iv_stack_remove_constants,
2332 debug_rename_elt, debug_rename_map_1, debug_rename_map,
2333 rename_map_elt_info, eq_rename_map_elts, debug_ivtype_elt,
2334 debug_ivtype_map_1, debug_ivtype_map, ivtype_map_elt_info,
2335 eq_ivtype_map_elts, sese_add_exit_phis_edge,
2336 sese_add_exit_phis_var, sese_insert_phis_for_liveouts,
2337 get_vdef_before_sese, sese_adjust_vphi,
2338 get_new_name_from_old_name, sese_adjust_phis_for_liveouts,
2339 oldiv_for_loop, rename_variables_in_stmt, is_parameter,
2340 is_iv, expand_scalar_variables_ssa_name,
2341 expand_scalar_variables_expr, expand_scalar_variables_stmt,
2342 expand_scalar_variables, rename_variables, remove_condition,
2343 get_true_edge_from_guard_bb, get_false_edge_from_guard_bb,
2344 add_loop_exit_phis, insert_loop_close_phis, struct igp,
2345 default_liveout_before_guard, add_guard_exit_phis,
2346 insert_guard_phis, register_old_and_new_names,
2347 graphite_copy_stmts_from_block, register_sese_liveout_renames,
2348 copy_bb_and_scalar_dependences, outermost_loop_in_sese,
2349 if_region_set_false_region, create_if_region_on_edge,
2350 move_sese_in_condition): Moved to sese.c.
2351
2352 (nb_loops_around_loop_in_sese, struct ifsese, if_region_entry,
2353 if_region_exit, if_region_get_condition_block,
2354 struct rename_map_elt, new_rename_map_elt, enum iv_stack_entry_kind,
2355 union iv_stack_entry_data_union, struct iv_stack_entry_struct,
2356 iv_stack_entry_p, loop_iv_stack, struct ivtype_map_elt,
2357 ivtype_map_elt, new_ivtype_map_elt,
2358 recompute_all_dominators): Moved to sese.h.
2359
2360 * graphite-clast-to-gimple.c: New.
2361 * graphite-clast-to-gimple.h: New.
2362 * Makefile.in: Add new rule for graphite-clast-to-gimple.o.
2363 * sese.c: Modified as said above.
2364 * sese.h: Same.
2365
23662009-02-20 Sebastian Pop <sebastian.pop@amd.com>
2367
2368 * graphite.c: Split scop detection to a new file.
2369 (enum gbb_type, gbb_type, get_bb_type, struct sd_region_p, sd_region,
2370 move_sd_regions, loop_affine_expr, exclude_component_ref,
2371 is_simple_operand, stmt_simple_for_scop_p, harmful_stmt_in_bb,
2372 graphite_cannot_represent_loop_niter, struct scopdet_info,
2373 scopdet_basic_block_info, build_scops_1, bb_in_sd_region,
2374 find_single_entry_edge, find_single_exit_edge,
2375 create_single_entry_edge, sd_region_without_exit,
2376 create_single_exit_edge, unmark_exit_edges, mark_exit_edges,
2377 create_sese_edges, build_graphite_scops, limit_scops, build_scops):
2378 Moved to graphite-scop-detection.c.
2379
2380 * graphite-scop-detection.c: New.
2381 * graphite-scop-detection.h: New.
2382 * Makefile.in: Add new rule for graphite-scop-detection.o.
2383
2384 * sese.c: Include tree-chrec.h, tree-data-ref.h, and
2385 tree-scalar-evolution.h.
2386 (nb_reductions_in_loop, graphite_loop_normal_form, sese_record_loop,
2387 build_sese_loop_nests): Moved here from graphite.c.
2388 (param_index): Renamed parameter_index_in_region.
2389
23902009-02-18 Tobias Grosser <grosser@fim.uni-passau.de>
2391 Sebastian Pop <sebastian.pop@amd.com>
2392
2393 * gcc.dg/graphite/block-0.c: Expected to fail now.
2394 * gcc.dg/graphite/block-1.c: Same.
2395 * gcc.dg/graphite/block-5.c: Same.
2396 * gcc.dg/graphite/block-6.c: Same.
2397
23982009-02-18 Tobias Grosser <grosser@fim.uni-passau.de>
2399 Sebastian Pop <sebastian.pop@amd.com>
2400
2401 * graphite.h: Separate from graphite_bb_p the polyhedral
2402 representation in poly_bb_p and the GCC specifics in gimple_bb_p.
2403 (struct data_dependence_polyhedron, RDGE_DDP, ddp_p): Moved to
2404 graphite-data-ref.h.
2405 (struct poly_bb, PBB_SCOP, PBB_STATIC_SCHEDULE, PBB_DOMAIN,
2406 PBB_BLACK_BOX, PBB_LOOPS, pbb_nb_loops, pbb_loop_at_index,
2407 pbb_loop_index, struct scop, SCOP_BBS, SCOP_REGION, SCOP_ENTRY,
2408 SCOP_EXIT, SCOP_REGION_BBS, SCOP_DEP_GRAPH, SCOP_PARAMS,
2409 SCOP_LOOP_NEST, SCOP_PARAMS, SCOP_OLDIVS, SCOP_LIVEOUT_RENAMES,
2410 scop_nb_params): Moved to graphite-poly.h.
2411 * graphite-data-ref.c: Same.
2412 * graphite-data-ref.h: New.
2413 * graphite.c: Same.
2414 (pbb_compare, graphite_sort_pbbs, graphite_trans_bb_move_loop,
2415 graphite_trans_bb_strip_mine, strip_mine_profitable_p,
2416 is_interchange_valid, graphite_trans_bb_block,
2417 graphite_trans_loop_block, scop_max_loop_depth,
2418 graphite_trans_scop_block, graphite_apply_transformations,
2419 new_poly_bb, free_poly_bb, new_scop, free_scop): Moved to
2420 graphite-poly.c.
2421 * graphite-poly.h: New.
2422 * graphite-poly.c: New.
2423 * Makefile.in (OBJS-common): Add graphite-poly.o.
2424 (graphite-poly.o): New rule.
2425 * tree-data-ref.h (struct data_reference): Remove unused scop field.
2426 (DR_SCOP): Removed.
2427
24282009-02-18 Sebastian Pop <sebastian.pop@amd.com>
2429 Tobias Grosser <grosser@fim.uni-passau.de>
2430
2431 * graphite.c: Replace gb -> gbb.
2432 * graphite.h: Same.
2433 * graphite-data-ref.c: Same.
2434
24352009-02-18 Sebastian Pop <sebastian.pop@amd.com>
2436 Tobias Grosser <grosser@fim.uni-passau.de>
2437
2438 * Makefile.in (OBJS-commmon): Add sese.o.
2439 (sese.o): New.
2440 (graphite.o): Add sese.h.
2441 * graphite.c (bb_in_ss_p, loop_in_sese_p,
2442 sese_build_livein_liveouts_use, sese_build_livein_liveouts_bb,
2443 sese_build_livein_liveouts, register_bb_in_sese, new_sese, free_sese):
2444 Move to sese.
2445 (block_before_scop): Add missing return.
2446 (new_scop, free_scop): Remove SESE data structures.
2447 (scop_record_loop, scan_tree_for_params, find_params_in_bb,
2448 find_scop_parameters, build_loop_iteration_domains,
2449 add_conditions_to_domain, register_scop_liveout_renames,
2450 copy_bb_and_scalar_dependences): Scop -> SESE.
2451
2452 (add_conditions_to_domain): SCoP -> SESE and remove check
2453 (scop_contains_non_iv_scalar_phi_nodes): New.
2454 (build_scop_conditions_1, build_scop_conditions): Remove check for
2455 non iv scalar phi nodes.
2456 (print_scop_statistics): New.
2457 (graphite_transform_loops): Cleanup.
2458
2459 * graphite.h: Move to sese & cleanup.
2460 * sese.c: New.
2461 * sese.h: New.
2462
24632009-02-16 Sebastian Pop <sebastian.pop@amd.com>
2464 Tobias Grosser <grosser@fim.uni-passau.de>
2465
2466 * graphite.c (build_scop_conditions_1): Conditions are only
2467 at the end of a basic block.
2468
24692009-02-16 Sebastian Pop <sebastian.pop@amd.com>
2470 Tobias Grosser <grosser@fim.uni-passau>
2471
2472 * graphite.h (struct graphite_bb): Remove compressed_alpha_matrix
2473 field.
2474 (GBB_ALPHA): Removed.
2475
24762009-02-16 Sebastian Pop <sebastian.pop@amd.com>
2477 Tobias Grosser <grosser@fim.uni-passau.de>
2478
2479 * graphite-data-ref.c (graphite_test_dependence): Don't use
2480 GBB_DYNAMIC_SCHEDULE.
2481 * graphite.c (new_graphite_bb): Same.
2482 (free_graphite_bb): Same.
2483 (build_scop_dynamic_schedules): Removed.
2484 (graphite_transform_loops): Don't call it.
2485 * graphite.h (struct graphite_bb): Remove dynamic_schedule field.
2486 (GBB_DYNAMIC_SCHEDULE): Removed.
2487
24882009-02-16 Sebastian Pop <sebastian.pop@amd.com>
2489 Tobias Grosser <grosser@fim.uni-passau.de>
2490
2491 * graphite.c (schedule_to_scattering): Don't use CloogMatrix.
2492 (print_graphite_bb): Same.
2493 (build_cloog_prog): Same.
2494
24952009-02-16 Sebastian Pop <sebastian.pop@amd.com>
2496 Tobias Grosser <grosser@fim.uni-passau.de>
2497
2498 * graphite.c (build_cloog_prog): Don't use CloogMatrix.
2499
25002009-02-16 Sebastian Pop <sebastian.pop@amd.com>
2501 Tobias Grosser <grosser@fim.uni-passau.de>
2502
2503 * graphite.c (build_scop_context): Don't use CloogMatrix.
2504 * graphite-ppl.c (new_Cloog_Domain_from_ppl_Polyhedron): New.
2505 * graphite-ppl.h (new_Cloog_Domain_from_ppl_Polyhedron): Declared.
2506
25072009-02-16 Sebastian Pop <sebastian.pop@amd.com>
2508 Tobias Grosser <grosser@fim.uni-passau.de>
2509
2510 * graphite.h (struct scop): Move params, old_ivs, loops, loop_nest,
2511 liveout_renames, add_params fields...
2512 (struct sese): ... here.
2513 (SESE_PARAMS, SESE_LOOPS, SESE_LOOP_NEST, SESE_ADD_PARAMS,
2514 SESE_PARAMS, SESE_OLDIVS, SESE_LIVEOUT_RENAMES): New.
2515
25162009-02-16 Sebastian Pop <sebastian.pop@amd.com>
2517 Tobias Grosser <grosser@fim.uni-passau.de>
2518
2519 * graphite.c (print_scop): Do not print the CLooG program.
2520 (new_scop, free_scop, initialize_cloog_names, build_scop_context,
2521 build_cloog_prog, gloog): Don't use SCOP_PROG.
2522 (find_transform): Renamed scop_to_clast.
2523 (print_generated_program, debug_generated_program): New.
2524 (graphite_transform_loops): Adapt to new interface.
2525 * graphite.h (struct scop): Remove program field.
2526 (SCOP_PROG): Removed.
2527 (print_generated_program, debug_generated_program): Declared.
2528
25292009-02-16 Sebastian Pop <sebastian.pop@amd.com>
2530
2531 * graphite-data-ref.c (schedule_precedes_p, schedule_same_p): New.
2532 (statement_precedes_p): Use schedule_same_p and schedule_precedes_p.
2533 * graphite.c (gbb_compare, schedule_to_scattering, print_graphite_bb,
2534 free_graphite_bb, build_scop_canonical_schedules,
2535 graphite_trans_bb_strip_mine, graphite_trans_scop_block): Static
2536 schedules are now represented using a ppl_Linear_Expression_t.
2537 * graphite.h (struct graphite_bb): Same.
2538 * graphite-ppl.c (ppl_lexico_compare_linear_expressions): New.
2539 * graphite-ppl.h (ppl_lexico_compare_linear_expressions): Declared.
2540
25412009-02-15 Sebastian Pop <sebastian.pop@amd.com>
2542
2543 * graphite.c: Free local memory.
2544 * graphite-ppl.c: Same.
2545
25462009-02-15 Sebastian Pop <sebastian.pop@amd.com>
2547
2548 * graphite.c (const_column_index, get_first_matching_sign_row_index,
2549 get_lower_bound_row, get_upper_bound_row, copy_constraint,
2550 swap_constraint_variables, scale_constraint_variable): Removed.
2551 (graphite_trans_bb_strip_mine): Remove pong.
2552 * graphite-ppl.c: Include missing header files.
2553 (set_inhomogeneous, set_coef, shift_poly, ppl_strip_loop): New.
2554 * graphite-ppl.h (ppl_strip_loop): Declared.
2555 * Makefile.in (graphite-ppl.o): Adjust dependences.
2556
25572009-02-14 Sebastian Pop <sebastian.pop@amd.com>
2558
2559 * graphite.c (build_loop_iteration_domains): Remove ping pong.
2560 (build_scop_iteration_domain): Same.
2561
25622009-02-13 Sebastian Pop <sebastian.pop@amd.com>
2563
2564 * graphite.c (scan_tree_for_params, add_conditions_to_domain): Remove
2565 ping pong.
2566 (add_value_to_dim, scan_tree_for_params_right_scev,
2567 scan_tree_for_params_int): New.
2568 * graphite-ppl.c (oppose_constraint): New.
2569 (insert_constraint_into_matrix): Implement missing cases.
2570 * graphite-ppl.h (insert_constraint_into_matrix): Declared.
2571
25722009-02-13 Sebastian Pop <sebastian.pop@amd.com>
2573
2574 * graphite.c (graphite_trans_bb_move_loop): Remove ping pong,
2575 use ppl_move_dimension.
2576
25772009-02-12 Sebastian Pop <sebastian.pop@amd.com>
2578
2579 * graphite-data-ref.c: Domains are now ppl_Polyhedra_t.
2580 * graphite.c: Same.
2581 * graphite.h: Same.
2582 * graphite-ppl.c: Same.
2583 * graphite-ppl.h: Same.
2584
25852009-02-12 Sebastian Pop <sebastian.pop@amd.com>
2586
2587 Revert last 3 commits.
2588
25892009-02-10 Sebastian Pop <sebastian.pop@amd.com>
2590
2591 * graphite.c (scan_tree_for_params, add_conditions_to_domain): Remove
2592 ping pong.
2593 (add_value_to_dim, scan_tree_for_params_right_scev,
2594 scan_tree_for_params_int): New.
2595 * graphite-ppl.c (oppose_constraint): New.
2596 (insert_constraint_into_matrix): Implement missing cases.
2597 * graphite-ppl.h (insert_constraint_into_matrix): Declared.
2598
25992009-02-10 Sebastian Pop <sebastian.pop@amd.com>
2600
2601 * graphite.c (graphite_trans_bb_move_loop): Remove unused variables.
2602
26032009-02-10 Sebastian Pop <sebastian.pop@amd.com>
2604 Tobias Grosser <grosser@fim.uni-passau.de>
2605
2606 * graphite.c (graphite_trans_bb_move_loop): Remove ping pong,
2607 use ppl_move_dimension.
2608 * graphite-ppl.c (ppl_move_dimension): New.
2609 * graphite-ppl.h (ppl_move_dimension): Declared.
2610
26112009-02-10 Sebastian Pop <sebastian.pop@amd.com>
2612
2613 * graphite.c: Do not include cloog/cloog.h.
2614 (print_graphite_bb): Remove ping pong, call PPL print function.
2615
26162009-02-10 Tobias Grosser <grosser@fim.uni-passau.de>
2617
2618 * Makefile.in (OBJS-common): Add graphite-ppl.o.
2619 (graphite.o): Add dependence on graphite-ppl.h.
2620 (graphite-ppl.o): New.
2621 (graphite-data-ref.c): Ping pong between PPL data structures
2622 and matrices.
2623 * graphite-ppl.c: New.
2624 * graphite-ppl.h: New.
2625 * graphite.c: Include graphite-ppl.h.
2626 (print_graphite_bb, add_conditions_to_domain, build_cloog_prog,
2627 graphite_trans_bb_move_loop, graphite_trans_bb_strip_mine):
2628 Ping pong between PPL data structures and matrices.
2629 (new_graphite_bb): Create a PPL constraint system.
2630 Call ppl_delete_Constraint_System instead of cloog_matrix_free.
2631 (build_loop_iteration_domains): Use PPL functions.
2632 * graphite.h: Include graphite-ppl.h. Fix comments.
2633 (graphite_bb): Use a ppl_Constraint_System_t instead of
2634 CloogMatrix for representing the domain.
2635 (scop): Remove static_schedule.
2636 (gbb_nb_loops): Ping pong between PPL data structures and matrices.
2637
26382009-02-06 Sebastian Pop <sebastian.pop@amd.com>
2639
2640 * graphite.c: Fix some comments.
2641
26422009-02-05 Sebastian Pop <sebastian.pop@amd.com>
2643
2644 PR middle-end/38953
2645 * graphite.c (if_region_set_false_region): After moving a region
2646 in the false branch of a condition, remove the empty dummy
2647 basic block.
2648 (gloog): Remove wrong fix for PR38953.
2649
26502009-02-03 Tobias Grosser <grosser@fim.uni-passau.de>
2651
2652 * graphite.c (bb_in_sese_p, sese_build_livein_liveouts_use,
2653 sese_build_livein_liveouts_bb, sese_build_livein_liveouts,
2654 register_bb_in_sese, new_sese, free_sese): Moved.
2655 (dot_scop_1, build_scop_loop_nests, build_loop_iteration_domains,
2656 outermost_loop_in_scop, build_scop_iteration_domain,
2657 expand_scalar_variables_ssa_name, get_vdef_before_scop,
2658 limit_scops): Use bb_in_sese_p instead of bb_in_scop_p.
2659 Use loop_in_sese_p instead of loop_in_scop_p.
2660 (new_graphite_bb, new_scop, gloog): Do not initialize SCOP_BBS_B.
2661 (free_scop): Do not free SCOP_BBS_B.
2662 (nb_loops_around_loop_in_scop, nb_loops_around_gb,
2663 ref_nb_loops): Moved here...
2664 * graphite.h (ref_nb_loops): ... from here.
2665 (struct scop): Remove bbs_b bitmap.
2666 (SCOP_BBS_B, bb_in_scop_p, loop_in_scop_p): Removed.
2667 * testsuite/gcc.dg/graphite/scop-19.c: New
2668
26692009-02-03 Tobias Grosser <grosser@fim.uni-passau.de>
2670
2671 * graphite.c (scopdet_basic_block_info): Fix bug in scop
2672 detection.
2673
26742009-01-30 Tobias Grosser <grosser@fim.uni-passau.de>
2675
2676 * graphite.c (new_loop_to_cloog_loop_str, hash_loop_to_cloog_loop,
2677 eq_loop_to_cloog_loop): Remove.
2678 (new_scop, free_scop): Remove SCOP_LOOP2CLOOG_LOOP.
2679 * graphite.h (struct scop): Remove loop2cloog_loop.
2680 (loop_domain_dim, loop_iteration_vector_dim): Remove.
2681
26822009-01-30 Tobias Grosser <grosser@fim.uni-passau.de>
2683
2684 * opts.c (decode_options): Only add graphite options to O2
2685 if we compile with graphite enabled.
2686
26872009-01-26 Sebastian Pop <sebastian.pop@amd.com>
2688
2689 * Merge from mainline (r143163:143684).
2690
26912009-01-26 Sebastian Pop <sebastian.pop@amd.com>
2692
2693 * graphite.c (debug_value): Removed.
2694 * graphite.h (debug_value): Removed.
2695
26962009-01-23 Sebastian Pop <sebastian.pop@amd.com>
2697
2698 * passes.c (init_optimization_passes): Do not call pass_copy_prop
2699 after graphite: pass_copy_prop does not maintain a proper loop closed
2700 SSA form. pass_copy_prop should be fixed.
2701
27022009-01-23 Sebastian Pop <sebastian.pop@amd.com>
2703
2704 * graphite.c (scop_adjust_phis_for_liveouts): Fix warning.
2705
27062009-01-23 Sebastian Pop <sebastian.pop@amd.com>
2707
2708 * graphite.c (graphite_verify): Add a call to verify_loop_closed_ssa.
2709 (gloog): Split the exit of the scop when the scop exit is a loop exit.
2710 (graphite_transform_loops): Only call cleanup_tree_cfg if gloog
2711 changed the CFG.
2712
27132009-01-20 Sebastian Pop <sebastian.pop@amd.com>
2714
2715 * graphite.c (gloog): Return true when code gen succeeded.
2716 (graphite_transform_loops): Do not call cleanup_tree_cfg if
2717 the code of the function did not changed. After cleanup_tree_cfg
2718 call rewrite_into_loop_closed_ssa to maintain the loop closed ssa
2719 form.
2720
27212009-01-19 Sebastian Pop <sebastian.pop@amd.com>
2722
2723 * graphite.c (stmt_simple_for_scop_p): Also handle cases when
2724 gimple_call_lhs is NULL.
2725
27262009-01-16 Sebastian Pop <sebastian.pop@amd.com>
2727 Tobias Grosser <tobi.grosser@amd.com>
2728
2729 * graphite.c (graphite_trans_scop_block): Do not block single
2730 nested loops.
2731
27322009-01-15 Sebastian Pop <sebastian.pop@amd.com>
2733 Tobias Grosser <tobi.grosser@amd.com>
2734
2735 * graphite.c (build_scop_canonical_schedules): Start schedules at
2736 zero.
2737
27382009-01-15 Sebastian Pop <sebastian.pop@amd.com>
2739 Tobias Grosser <tobi.grosser@amd.com>
2740
2741 * graphite.c (compare_prefix_loops): New.
2742 (build_scop_canonical_schedules): Rewritten.
2743 (graphite_transform_loops): Move build_scop_canonical_schedules
2744 after build_scop_iteration_domain.
2745
27462009-01-14 Sebastian Pop <sebastian.pop@amd.com>
2747 Tobias Grosser <tobi.grosser@amd.com>
2748
2749 * graphite.c (add_conditions_to_domain): Add the loops to
2750 the dimension of the iteration domain. Do copy the domain
2751 only when it exists.
2752 (build_scop_conditions_1): Do not call add_conditions_to_domain.
2753 (add_conditions_to_constraints): New.
2754 (can_generate_code_stmt, can_generate_code): Removed.
2755 (gloog): Do not call can_generate_code.
2756 (graphite_transform_loops): Call add_conditions_to_constraints
2757 after building the iteration domain.
2758
27592009-01-14 Sebastian Pop <sebastian.pop@amd.com>
2760 Tobias Grosser <tobi.grosser@amd.com>
2761 Jan Sjodin <jan.sjodin@amd.com>
2762
2763 * graphite.c (scan_tree_for_params): On substractions negate
2764 all the coefficients of the term.
2765 (clast_to_gcc_expression_red): New. Handle reduction expressions
2766 of more than two operands.
2767 (clast_to_gcc_expression): Call clast_to_gcc_expression_red.
2768 (get_vdef_before_scop): Handle also the case of default definitions.
2769
27702009-01-14 Sebastian Pop <sebastian.pop@amd.com>
2771
2772 PR middle-end/38431
2773 * graphite.c (get_vdef_before_scop, scop_adjust_vphi): New.
2774 (scop_adjust_phis_for_liveouts): Call scop_adjust_vphi.
2775 (gloog): Do not call cleanup_tree_cfg.
2776 (graphite_transform_loops): Call cleanup_tree_cfg after all
2777 scops have been code generated.
2778
27792009-01-13 Sebastian Pop <sebastian.pop@amd.com>
2780
2781 * passes.c (init_optimization_passes): Schedule after
2782 graphite transforms pass_copy_prop, pass_dce_loop and pass_lim.
2783
27842009-01-13 Sebastian Pop <sebastian.pop@amd.com>
2785
2786 * graphite.c (expand_scalar_variables_stmt): Do not pass loop_p.
2787 Fix comment.
2788 (expand_scalar_variables_ssa_name): Do not pass loop_p. Fix comment.
2789 Set the type of an expression to the type of its assign statement.
2790 (expand_scalar_variables_expr): Do not pass loop_p.
2791 Fix comment. Stop recursion on tcc_constant or tcc_declaration.
2792 (copy_bb_and_scalar_dependences): Do not pass loop_p.
2793 (translate_clast): Update call to copy_bb_and_scalar_dependences.
2794
27952009-01-11 Sebastian Pop <sebastian.pop@amd.com>
2796
2797 * graphite.c (expand_scalar_variables_ssa_name): Set the type of
2798 an expression to the gimple_expr_type of its assign statement.
2799 (expand_scalar_variables_expr): Stop recursion on tcc_constant
2800 or tcc_declaration.
2801
28022009-01-11 Sebastian Pop <sebastian.pop@amd.com>
2803
2804 PR tree-optimization/38786
2805 * testsuite/gcc.dg/graphite/pr38786.c: New.
2806 * graphite.c (expand_scalar_variables_ssa_name): New, outlined from
2807 the SSA_NAME case of expand_scalar_variables_expr.
2808 (expand_scalar_variables_expr): Also gather the scalar computation
2809 used to index the memory access.
2810 (expand_scalar_variables_stmt): Pass to expand_scalar_variables_expr
2811 the gimple_stmt_iterator where it inserts new code.
2812
28132009-01-10 Sebastian Pop <sebastian.pop@amd.com>
2814
2815 * testsuite/gcc.dg/graphite/block-3.c: Fix compile error on 32bit.
2816
28172009-01-10 Sebastian Pop <sebastian.pop@amd.com>
2818
2819 * opts.c (decode_options): Enable flag_graphite_identity and
2820 flag_loop_block in -O2 and above.
2821
28222009-01-08 Sebastian Pop <sebastian.pop@amd.com>
2823
2824 * libjava/classpath/lib/gnu/java/awt/peer/gtk/GtkMouseInfoPeer.class:
2825 Fix merge problem: replace with the file from trunk.
2826
28272009-01-08 Sebastian Pop <sebastian.pop@amd.com>
2828
2829 * Merge from mainline (r141727:143163).
2830
28312009-01-07 Sebastian Pop <sebastian.pop@amd.com>
2832 Jan Sjodin <jan.sjodin@amd.com>
2833
2834 PR tree-optimization/38559
2835 * testsuite/gcc.dg/graphite/pr38559.c: New.
2836
2837 * graphite.c (debug_value, copy_constraint,
2838 swap_constraint_variables, scale_constraint_variable, ): New.
2839 (get_lower_bound, get_upper_bound): Removed.
2840 (graphite_trans_bb_strip_mine): Clean up this code that works
2841 only for constant number of iterations. Fully copy upper and
2842 lower bound constraints, not only the constant part of them.
2843 * graphite.h (debug_value): Declared.
2844
28452009-01-06 Jan Sjodin <jan.sjodin@amd.com>
2846
2847 PR tree-optimization/38492
2848 PR tree-optimization/38498
2849 * tree-check.c (operator_is_linear, scev_is_linear_expression): New.
2850 * tree-chrec.h (scev_is_linear_expression): Declared.
2851 * graphite.c (graphite_cannot_represent_loop_niter): New.
2852 (scopdet_basic_block_info): Call graphite_cannot_represent_loop_niter.
2853 (graphite_loop_normal_form): Use gcc_assert.
2854 (scan_tree_for_params): Use CASE_CONVERT.
2855 (phi_node_is_iv, bb_contains_non_iv_scalar_phi_nodes): New.
2856 (build_scop_conditions_1): Call bb_contains_non_iv_scalar_phi_nodes.
2857 Use gcc_assert. Discard scops that contain unhandled cases.
2858 (build_scop_conditions): Return a boolean status for unhandled cases.
2859 (strip_mine_profitable_p): Print the loop number, not its depth.
2860 (is_interchange_valid): Pass the depth of the loop nest, don't
2861 recompute it wrongly.
2862 (graphite_trans_bb_block): Same.
2863 (graphite_trans_bb_block): Print tentative of loop blocking.
2864 (graphite_trans_scop_block): Do not print that the loop has been
2865 blocked.
2866 (graphite_transform_loops): Do not handle scops that contain condition
2867 scalar phi nodes.
2868
2869 * testsuite/gcc.dg/graphite/pr38500.c: Fixed warning as committed
2870 in trunk.
2871 * testsuite/gcc.dg/graphite/block-0.c: Update test.
2872 * testsuite/gcc.dg/graphite/block-1.c: Same.
2873 * testsuite/gcc.dg/graphite/block-2.c: Remove xfail and test for
2874 blocking.
2875 * testsuite/gcc.dg/graphite/block-4.c: Remove test for strip mine.
2876 * testsuite/gcc.dg/graphite/block-3.c: New.
2877 * testsuite/gcc.dg/graphite/pr38498.c: New.
2878
28792008-12-22 Harsha Jagasia <harsha.jagasia@amd.com>
2880
2881 PR tree-optimization/38510
2882 * gcc.dg/graphite/pr38510.c: New.
2883 * graphite.c (recompute_all_dominators): Call mark_irreducible_loops.
2884 (translate_clast): Call recompute_all_dominators before
2885 graphite_verify.
2886 (gloog): Call recompute_all_dominators before graphite_verify.
2887
28882008-12-12 Sebastian Pop <sebastian.pop@amd.com>
2889
2890 PR tree-optimization/38492
2891 * graphite.c (rename_map_elt, debug_rename_elt,
2892 debug_rename_map_1, debug_rename_map, new_rename_map_elt,
2893 rename_map_elt_info, eq_rename_map_elts,
2894 get_new_name_from_old_name, bb_in_sese_p): Moved around.
2895 (sese_find_uses_to_rename_use): Renamed sese_build_livein_liveouts_use.
2896 (sese_find_uses_to_rename_bb): Renamed sese_build_livein_liveouts_bb.
2897 (sese_build_livein_liveouts): New.
2898 (new_sese, free_sese): New.
2899 (new_scop): Call new_sese.
2900 (free_scop): Call free_sese.
2901 (rename_variables_from_edge, rename_phis_end_scop): Removed.
2902 (register_old_new_names): Renamed register_old_and_new_names.
2903 (register_scop_liveout_renames, add_loop_exit_phis,
2904 insert_loop_close_phis, struct igp,
2905 default_liveout_before_guard, add_guard_exit_phis,
2906 insert_guard_phis, copy_renames): New.
2907 (translate_clast): Call insert_loop_close_phis and insert_guard_phis.
2908 (sese_add_exit_phis_edge): Renamed scop_add_exit_phis_edge.
2909 (rewrite_into_sese_closed_ssa): Renamed scop_insert_phis_for_liveouts.
2910 (scop_adjust_phis_for_liveouts): New.
2911 (gloog): Call scop_adjust_phis_for_liveouts.
2912
2913 * graphite.h (struct sese): Documented. Added fields liveout,
2914 num_ver and livein.
2915 (SESE_LIVEOUT, SESE_LIVEIN, SESE_LIVEIN_VER, SESE_NUM_VER): New.
2916 (new_sese, free_sese, sese_build_livein_liveouts): Declared.
2917 (struct scop): Added field liveout_renames.
2918 (SCOP_LIVEOUT_RENAMES): New.
2919
29202008-12-11 Sebastian Pop <sebastian.pop@amd.com>
2921
2922 PR tree-optimization/38409
2923 * gcc.dg/graphite/pr38409.c: New.
2924 * graphite.c (nb_reductions_in_loop): Use simple_iv.
2925
29262008-12-11 Sebastian Pop <sebastian.pop@amd.com>
2927
2928 * graphite.c (gcc_type_for_cloog_iv): By default return
2929 integer_type_node.
2930 (graphite_create_new_loop): Don't fold_convert the already
2931 fold_convert-ed expression.
2932
29332008-12-11 Harsha Jagasia <harsha.jagasia@amd.com>
2934
2935 PR tree-optimization/38446
2936 * gcc.dg/graphite/pr38446.c: New.
2937 * graphite.c (register_bb_in_sese): New.
2938 (bb_in_sese_p): Check if bb belongs to sese region by explicitly
2939 looking at the bbs in the region.
2940 * graphite.h (sese): Add region_basic_blocks pointer set to
2941 structure and initialize at the time of defining new scop.
2942
29432008-12-11 Tobias Grosser <grosser@fim.uni-passau.de>
2944
2945 * graphite.c (new_graphite_bb): Initialize GBB_STATIC_SCHEDULE.
2946 (find_params_in_bb): Do not free data refs.
2947 (free_graphite_bb): Add FIXME on disabled free_data_refs.
2948
29492008-12-11 Sebastian Pop <sebastian.pop@amd.com>
2950
2951 * testsuite/gcc.dg/graphite/scop-16.c: Test only scop specific info.
2952 * testsuite/gcc.dg/graphite/scop-17.c: Same.
2953 * testsuite/gcc.dg/graphite/block-5.c: New.
2954 * testsuite/gcc.dg/graphite/block-6.c: New.
2955 * testsuite/gcc.dg/graphite/pr37485.c: Clean dump file after.
2956 * testsuite/gcc.dg/graphite/pr37684.c: Same.
2957 * testsuite/gcc.dg/graphite/block-2.c: Same.
2958
2959 * graphite.c (struct ivtype_map_elt): New.
2960 (debug_ivtype_elt, debug_ivtype_map_1, debug_ivtype_map,
2961 new_ivtype_map_elt, ivtype_map_elt_info, eq_ivtype_map_elts,
2962 gcc_type_for_cloog_iv): New.
2963 (loop_iv_stack_patch_for_consts): Use the type of the induction
2964 variable from the original loop, except for the automatically
2965 generated loops, i.e., in the case of a strip-mined loop, in
2966 which case there is no original loop: in that case just use
2967 integer_type_node.
2968 (new_graphite_bb): Initialize GBB_CLOOG_IV_TYPES.
2969 (free_graphite_bb): Free GBB_CLOOG_IV_TYPES.
2970 (clast_name_to_gcc): Accept params to be NULL.
2971 (clast_to_gcc_expression): Take an extra parameter for the type.
2972 Convert to that type all the expressions built by this function.
2973 (gcc_type_for_clast_expr, gcc_type_for_clast_eq): New.
2974 (graphite_translate_clast_equation): Compute the type of the
2975 clast_equation before translating its LHS and RHS.
2976 (clast_get_body_of_loop, gcc_type_for_iv_of_clast_loop): New.
2977 (graphite_create_new_loop): Compute the type of the induction
2978 variable before translating the lower and upper bounds and before
2979 creating the induction variable.
2980 (rename_variables_from_edge, rename_phis_end_scop): New.
2981 (copy_bb_and_scalar_dependences): Call rename_phis_end_scop.
2982 (sese_add_exit_phis_edge): Do not use integer_zero_node.
2983 (find_cloog_iv_in_expr, compute_cloog_iv_types_1,
2984 compute_cloog_iv_types): New.
2985 (gloog): Call compute_cloog_iv_types before starting the
2986 translation of the clast.
2987
2988 * graphite.h (struct graphite_bb): New field cloog_iv_types.
2989 (GBB_CLOOG_IV_TYPES): New.
2990 (debug_ivtype_map): Declared.
2991 (oldiv_for_loop): New.
2992
29932008-12-10 Tobias Grosser <grosser@fim.uni-passau.de>
2994
2995 PR middle-end/38459
2996 * graphite.c (new_scop): Initialize SCOP_ADD_PARAMS.
2997 (param_index): Assert if parameter is not know after parameter
2998 detection.
2999 (find_params_in_bb): Detect params directly in GBB_CONDITIONS.
3000 (find_scop_parameters): Mark, that we have finished parameter
3001 detection.
3002 (graphite_transform_loops): Move condition detection before parameter
3003 detection.
3004 * graphite.h (struct scop): Add SCOP_ADD_PARAMS.
3005 * testsuite/gfortran.dg/graphite/pr38459.f90: New.
3006
30072008-12-09 Tobias Grosser <grosser@fim.uni-passau.de>
3008
3009 * graphite.c (graphite_transform_loops): Always call find_transform ()
3010 in ENABLE_CHECKING. So we test these code paths, even if we do not
3011 generate code.
3012
30132008-12-09 Tobias Grosser <grosser@fim.uni-passau.de>
3014
3015 * graphite.c (print_graphite_bb): Fix printing to file != dump_file.
3016 (print_scop): Ditto.
3017
30182008-12-08 Tobias Grosser <grosser@fim.uni-passau.de>
3019
3020 PR middle-end/38084
3021 Fix testsuite/gfortran.dg/graphite/id-3.f90.
3022 * graphite.c (scopdet_basic_block_info): Fix bug that found some
3023 regions more than once.
3024
30252008-12-03 Sebastian Pop <sebastian.pop@amd.com>
3026
3027 Fix testsuite/gfortran.dg/graphite/id-4.f90.
3028 * graphite.c (scan_tree_for_params): Do not compute the multiplicand
3029 when not needed.
3030
30312008-12-03 Sebastian Pop <sebastian.pop@amd.com>
3032
3033 Fix testsuite/gfortran.dg/graphite/id-1.f90.
3034 * graphite.c (gmp_cst_to_tree): Pass the type in parameter.
3035 (loop_iv_stack_patch_for_consts): Update use of gmp_cst_to_tree.
3036 (max_precision_type): New.
3037 (value_clast): Removed.
3038 (clast_to_gcc_expression): Be more careful to types of expressions.
3039 Use max_precision_type and update use of gmp_cst_to_tree.
3040 (graphite_translate_clast_equation): Use max_precision_type.
3041 (graphite_create_guard_cond_expr): Do not use integer_type_node,
3042 use the type of the condition.
3043 (graphite_create_new_loop): Do not use integer_type_node, use the
3044 max_precision_type of lb and ub.
3045
30462008-12-03 Sebastian Pop <sebastian.pop@amd.com>
3047
3048 * graphite.c (build_scops_1): Initialize open_scop.exit
3049 and sinfo.last.
3050
30512008-12-02 Sebastian Pop <sebastian.pop@amd.com>
3052
3053 * testsuite/gcc.dg/graphite/pr38084.c: New.
3054 * testsuite/gfortran.dg/graphite/id-1.f90: New.
3055 * testsuite/gfortran.dg/graphite/id-2.f90: New.
3056 * testsuite/gfortran.dg/graphite/id-3.f90: New.
3057 * testsuite/gfortran.dg/graphite/id-4.f90: New.
3058 * testsuite/gfortran.dg/graphite/pr37857.f90: New.
3059
30602008-12-02 Sebastian Pop <sebastian.pop@amd.com>
3061 Jan Sjodin <jan.sjodin@amd.com>
3062 Harsha Jagasia <harsha.jagasia@amd.com>
3063
3064 PR middle-end/37852
3065 PR middle-end/37883
3066 PR middle-end/37928
3067 PR middle-end/37980
3068 PR middle-end/38038
3069 PR middle-end/38039
3070 PR middle-end/38073
3071 PR middle-end/38083
3072 PR middle-end/38125
3073
3074 * testsuite/gcc.dg/graphite/pr38073.c: New.
3075 * testsuite/gcc.dg/graphite/pr37928.c: New.
3076 * testsuite/gcc.dg/graphite/pr37883.c: New.
3077 * testsuite/gcc.dg/graphite/pr38125.c: New.
3078 * testsuite/gfortran.dg/graphite/pr38083.f90: New.
3079 * testsuite/gfortran.dg/graphite/pr37852.f90: New.
3080 * testsuite/gfortran.dg/graphite/pr37980.f90: New.
3081
3082 * testsuite/gcc.dg/graphite/scop-18.c: Remove reduction, test for
3083 the number of detected scops. Copy exact same test for loop
3084 blocking...
3085 * testsuite/gcc.dg/graphite/block-1.c: Fix the number of expected
3086 loops to be blocked as reductions are not handled.
3087 * testsuite/gcc.dg/graphite/block-4.c: ...here. New.
3088
3089 * tree-phinodes.c (remove_phi_nodes): New, extracted from...
3090 * tree-cfg.c (remove_phi_nodes_and_edges_for_unreachable_block):
3091 ...here.
3092 * tree-flow.h (remove_phi_nodes, canonicalize_loop_ivs): Declared.
3093 * Makefile.in (graphite.o): Depend on value-prof.h.
3094 (graphite.o-warn): Removed -Wno-error.
3095 * tree-parloops.c (canonicalize_loop_ivs): Allow reduction_list
3096 to be a NULL pointer. Call update_stmt. Return the newly created
3097 cannonical induction variable.
3098
3099 * graphite.h (debug_rename_map): Declared. Fix some comments.
3100
3101 * graphite.c: Reimplement the code generation from graphite to gimple.
3102 Include value-prof.h.
3103 (loop_iv_stack_get_iv): Do not return NULL for constant substitutions.
3104 (get_old_iv_from_ssa_name): Removed.
3105 (graphite_stmt_p): New.
3106 (new_graphite_bb): Test for useful statements before building a
3107 graphite statement for the basic block.
3108 (free_graphite_bb): Do not free GBB_DATA_REFS: this is a bug
3109 in free_data_ref that calls BITMAP_FREE (DR_VOPS (dr)) without
3110 reason.
3111 (recompute_all_dominators, graphite_verify,
3112 nb_reductions_in_loop, graphite_loop_normal_form): New.
3113 (scop_record_loop): Call graphite_loop_normal_form.
3114 (build_scop_loop_nests): Iterate over all the blocks of the
3115 function instead of relying on the incomplete information from
3116 SCOP_BBS. Return the success of the operation.
3117 (find_params_in_bb): Use the data from GBB_DATA_REFS.
3118 (add_bb_domains): Removed.
3119 (build_loop_iteration_domains): Don't call add_bb_domains.
3120 Add the iteration domain only to the basic blocks that have been
3121 translated to graphite.
3122 (build_scop_conditions_1): Add constraints only if the basic
3123 block have been translated to graphite.
3124 (build_scop_data_accesses): Completely disabled until data
3125 dependence is correctly implemented.
3126 (debug_rename_elt, debug_rename_map_1, debug_rename_map): New.
3127 (remove_all_edges_1, remove_all_edges): Removed.
3128 (get_new_name_from_old_name): New.
3129 (graphite_rename_variables_in_stmt): Renamed
3130 rename_variables_in_stmt. Call get_new_name_from_old_name.
3131 Use replace_exp and update_stmt.
3132 (is_old_iv): Renamed is_iv.
3133 (expand_scalar_variables_stmt): Extra parameter for renaming map.
3134 Use replace_exp and update_stmt.
3135 (expand_scalar_variables_expr): Same. Use the map to get the
3136 new names for the renaming of induction variables and for the
3137 renaming of variables after a basic block has been copied.
3138 (expand_scalar_variables): Same.
3139 (graphite_rename_variables): Renamed rename_variables.
3140 (move_phi_nodes): Removed.
3141 (get_false_edge_from_guard_bb): New.
3142 (build_iv_mapping): Do not insert the induction variable of a
3143 loop in the renaming iv map if the basic block does not belong
3144 to that loop.
3145 (register_old_new_names, graphite_copy_stmts_from_block,
3146 copy_bb_and_scalar_dependences): New.
3147 (translate_clast): Heavily reimplemented: copy basic blocks,
3148 do not move them. Finally, in call cleanup_tree_cfg in gloog.
3149 At each translation step call graphite_verify ensuring the
3150 consistency of the SSA, loops and dominators information.
3151 (collect_virtual_phis, find_vdef_for_var_in_bb,
3152 find_vdef_for_var_1, find_vdef_for_var,
3153 patch_phis_for_virtual_defs): Removed huge hack.
3154 (mark_old_loops, remove_dead_loops, skip_phi_defs,
3155 collect_scop_exit_phi_args, patch_scop_exit_phi_args,
3156 gbb_can_be_ignored, scop_remove_ignoreable_gbbs, ): Removed.
3157 (remove_sese_region, ifsese, if_region_entry, if_region_exit,
3158 if_region_get_condition_block, if_region_set_false_region,
3159 create_if_region_on_edge, move_sese_in_condition, bb_in_sese_p,
3160 sese_find_uses_to_rename_use, sese_find_uses_to_rename_bb,
3161 sese_add_exit_phis_edge, sese_add_exit_phis_var,
3162 rewrite_into_sese_closed_ssa): New.
3163 (gloog): Remove dead code. Early return if code cannot be
3164 generated. Call cleanup_tree_cfg once the scop has been code
3165 generated.
3166 (graphite_trans_scop_block, graphite_trans_loop_block): Do not
3167 block loops with less than two loops.
3168 (graphite_apply_transformations): Remove the call to
3169 scop_remove_ignoreable_gbbs.
3170 (limit_scops): When build_scop_loop_nests fails, continue on
3171 the next scop. Fix open_scop.entry.
3172 (graphite_transform_loops): Call recompute_all_dominators: force the
3173 recomputation of correct CDI_DOMINATORS and CDI_POST_DOMINATORS.
3174 Call initialize_original_copy_tables and free_original_copy_tables
3175 to be able to copy basic blocks during code generation.
3176 When build_scop_loop_nests fails, continue on next scop.
3177 (value_clast): New union.
3178 (clast_to_gcc_expression): Fix type cast warning.
3179
31802008-11-09 Sebastian Pop <sebastian.pop@amd.com>
3181
3182 * Merge from mainline (r140838:141727).
3183
31842008-11-05 Tobias Grosser <grosser@fim.uni-passau.de>
3185
3186 PR middle-end/37833
3187
3188 * graphite.c (scan_tree_for_params): Add POINTER_PLUS_EXPR.
3189
31902008-11-05 Tobias Grosser <grosser@fim.uni-passau.de>
3191
3192 PR middle-end/37943
3193
3194 * graphite.c (scopdet_basic_block_info): Fix loops with multiple
3195 exits and conditions.
3196 * testsuite/gcc.dg/graphite/pr37943.c: New.
3197
31982008-10-23 Tobias Grosser <grosser@fim.uni-passau.de>
3199
3200 PR middle-end/37886
3201 * graphite.c (gloog): Replace EXIT_BLOCK_PTR with scop exit.
3202
32032008-10-23 Tobias Grosser <grosser@fim.uni-passau.de>
3204
3205 * doc/invoke.texi: Fix spaces.
3206
32072008-10-22 Sebastian Pop <sebastian.pop@amd.com>
3208
3209 PR tree-optimization/37891
3210 Reverted last commit.
3211 * graphite.c (create_single_entry_edge): Set
3212 EDGE_IRREDUCIBLE_LOOP and BB_IRREDUCIBLE_LOOP.
3213
32142008-10-21 Sebastian Pop <sebastian.pop@amd.com>
3215 Mitul Thakkar <mitul.thakkar@amd.com>
3216
3217 * graphite.c (create_single_entry_edge): Set
3218 EDGE_IRREDUCIBLE_LOOP and BB_IRREDUCIBLE_LOOP.
3219
32202008-10-16 Tobias Grosser <grosser@fim.uni-passau.de>
3221
3222 * doc/invoke.texi: Add -fgraphite-identity.
3223 * graphite.c (graphite_apply_transformations): Check for
3224 -fgraphite-identity.
3225 * toplev.c (process_options): Add flag_graphite_identity.
3226 * tree-ssa-loop.c: Add flag_graphite_identity.
3227
32282008-10-14 Sebastian Pop <sebastian.pop@amd.com>
3229
3230 Undo changes from 2008-10-02:
3231 * tree-ssa-loop-ivopts.c (rewrite_use_nonlinear_expr): Convert
3232 operand type when copying the operand to a variable of different type.
3233 * cfgloopmanip.c (create_empty_loop_on_edge): Write exit condition
3234 with the IV name after increment.
3235
32362008-10-14 Sebastian Pop <sebastian.pop@amd.com>
3237 Harsha Jagasia <harsha.jagasia@amd.com>
3238
3239 PR tree-optimization/37828
3240 * testsuite/gcc.dg/graphite/pr37828.c: New.
3241 * graphite.c (graphite_trans_loop_block): Do not loop block
3242 single nested loops.
3243
32442008-10-09 Harsha Jagasia <harsha.jagasia@amd.com>
3245 Sebastian Pop <sebastian.pop@amd.com>
3246
3247 * graphite.c (struct rename_map_elt, new_rename_map_elt,
3248 rename_map_elt_info, eq_rename_map_elts): New.
3249 (graphite_rename_ivs_stmt): Renamed graphite_rename_variables_in_stmt.
3250 (expand_scalar_variables_expr): Change parameters.
3251 (expand_scalar_variables_stmt): Same.
3252 (expand_scalar_variables): Same.
3253 (graphite_rename_ivs): Rename graphite_rename_variables.
3254 (build_iv_mapping): New.
3255 (translate_clast): Call build_iv_mapping.
3256 * graphite.h (gbb_p): New name.
3257
32582008-10-03 Harsha Jagasia <harsha.jagasia@amd.com>
3259
3260 PR tree-optimization/37684
3261 * gcc.dg/graphite/pr37684.c: New.
3262 * graphite.c (exclude_component_ref): New.
3263 (is_simple_operand): Call exclude_component_ref.
3264
32652008-10-02 Jan Sjodin <jan.sjodin@amd.com>
3266 Harsha Jagasia <harsha.jagasia@amd.com>
3267
3268 PR tree-optimization/37485
3269 * gcc.dg/graphite/block-2.c: New
3270 * graphite.c (gmp_cst_to_tree): Moved.
3271 (iv_stack_entry_is_constant): New.
3272 (iv_stack_entry_is_iv): New.
3273 (loop_iv_stack_push): Renamed to loop_iv_stack_push_iv.
3274 (loop_iv_stack_insert_constant): New.
3275 (loop_iv_stack_pop): Use new datatpype.
3276 (loop_iv_stack_get_iv): Same.
3277 (loop_iv_stack_get_iv_from_name): Same.
3278 (loop_iv_stack_debug): Renamed to debug_loop_iv_stack.
3279 (loop_iv_stack_patch_for_consts): New.
3280 (loop_iv_stack_remove_constants): New.
3281 (graphite_create_new_loop): Use loop_iv_stack_push_iv.
3282 (translate_clast): Call loop_iv_stack_patch_for_consts and
3283 loop_iv_stack_remove_constants.
3284 (gloog): Use new datatype. Redirect construction edge to end
3285 block to avoid accidental deletion.
3286 * graphite.h (enum iv_stack_entry_kind): New. Tag for data in
3287 iv stack entry.
3288 (union iv_stack_entry_data): New. Data in iv stack entry.
3289 (struct iv_stack_entry): New. Datatype for iv stack entries.
3290
32912008-10-02 Sebastian Pop <sebastian.pop@amd.com>
3292
3293 * tree-ssa-loop-ivopts.c (rewrite_use_nonlinear_expr): Convert
3294 operand type when copying the operand to a variable of different type.
3295
32962008-10-02 Sebastian Pop <sebastian.pop@amd.com>
3297
3298 * cfgloopmanip.c (create_empty_loop_on_edge): Write exit condition
3299 with the IV name after increment.
3300
33012008-10-02 Sebastian Pop <sebastian.pop@amd.com>
3302
3303 * Merge from mainline (r140164:140838).
3304
33052008-09-10 Konrad Trifunovic <konrad.trifunovic@inria.fr>
3306
3307 * graphite-data-ref.c: New.
3308 * graphite.c (print_scop): Also dump the dependence graph.
3309 (bb_in_scop_p, loop_in_scop_p, nb_loops_around_gb): Moved...
3310 (new_scop): Initialize SCOP_DEP_GRAPH.
3311 (build_scop_dynamic_schedules): New.
3312 (build_access_matrix_with_af): Fixed column numbering.
3313 (graphite_transform_loops): Call build_scop_dynamic_schedules.
3314 * graphite.h: Add ifndef/define guards against multiple inclusion.
3315 (struct scop): Add dep_graph field.
3316 (SCOP_DEP_GRAPH): Defined.
3317 (ref_nb_loops): Fixed and moved to other position.
3318 (bb_in_scop_p, loop_in_scop_p, nb_loops_around_gb): ... here.
3319 (nb_loops_around_loop_in_scop): New.
3320 (graphite_dump_dependence_graph): Declared.
3321 (graphite_build_rdg_all_levels): Declared.
3322 (graphite_test_dependence): Declared.
3323 * Makefile.in (graphite-data-ref.o): New target.
3324
33252008-09-09 Sebastian Pop <sebastian.pop@amd.com>
3326
3327 * Merge from mainline (139870:140164).
3328
33292008-09-01 Sebastian Pop <sebastian.pop@amd.com>
3330
3331 * Merge from mainline (138275:139870).
3332 * testsuite/gcc.dg/graphite/scop-matmult.c: XFailed as one of
3333 the commits from trunk broke the niter detection.
3334
33352008-09-01 Sebastian Pop <sebastian.pop@amd.com>
3336
3337 * graphite.c: Add more documentation. Fix formatting.
3338 (debug_loop_vec, debug_oldivs, loop_iv_stack,
3339 loop_iv_stack_debug): Moved...
3340 (schedule_to_scattering): Move before use.
3341 (dot_all_scops): Include in "#if 0" the code for system
3342 call dotty.
3343
3344 * graphite.h: (debug_loop_vec, debug_oldivs, loop_iv_stack,
3345 loop_iv_stack_debug): ...here.
3346
33472008-08-29 Jan Sjodin <jan.sjodin@amd.com>
3348
3349 * tree-phinodes.c (make_phi_node): Extern.
3350 (add_phi_node_to_bb): New.
3351 (create_phi_node): Call add_phi_node_to_bb.
3352 * tree-ssa-loop-ivopts.c (get_phi_with_result): New.
3353 (remove_statement): Handle case where stored phi was updated
3354 and is no longer the same.
3355 * graphite.c (is_parameter): New.
3356 (is_old_iv): New.
3357 (expand_scalar_variables_expr): New.
3358 (expand_scalar_variables_stmt): New.
3359 (expand_scalar_variables): New.
3360 (move_phi_nodes): Create new phi instead of moving old one.
3361 (translate_clast): Call expand_scalar_variables.
3362 (find_vdef_for_var_in_bb): Also scan regular definitions.
3363 (skip_phi_defs): New.
3364 (collect_scop_exit_phi_args): New.
3365 (patch_scop_exit_phi_args): New.
3366 (gloog): Patch phis after scop.
3367 * tree-flow.h: (add_phi_node_to_bb): Declared.
3368 (make_phi_node): Declared.
3369
33702008-08-26 Sebastian Pop <sebastian.pop@amd.com>
3371
3372 * graphite.c (end_scop): Split the entry of the scop when it
3373 is the header of the loop in which the scop is ending.
3374 (build_scops_1, limit_scops): Update uses of end_scop.
3375
33762008-08-26 Sebastian Pop <sebastian.pop@amd.com>
3377
3378 * graphite.c (dot_all_scops_1): Do not fail on uninitialized
3379 SCOP_ENTRY or SCOP_EXIT.
3380
33812008-08-25 Sebastian Pop <sebastian.pop@amd.com>
3382
3383 * graphite.c (get_construction_edge): Removed.
3384 (gloog): Construction edge is the scop entry edge.
3385
33862008-08-25 Sebastian Pop <sebastian.pop@amd.com>
3387
3388 * graphite.c (can_generate_for_scop): Removed.
3389 (gloog): Do not call it.
3390
33912008-08-25 Sebastian Pop <sebastian.pop@amd.com>
3392
3393 * graphite.c (new_scop): Entry of a scop is an edge.
3394 Initialize SESE region.
3395 (free_scop): Free SESE region.
3396 (build_scops_1, scopdet_bb_info): Work on edges, not on bbs.
3397 (split_difficult_bb): New, split from end_scop.
3398 (end_scop): Exit of a scop is an edge.
3399 (build_scop_bbs): Never check CDI_POST_DOMINATORS: this info is
3400 not automatically updated and thus is always wrong.
3401 * graphite.h (struct sese): New.
3402 (SESE_ENTRY): New.
3403 (SESE_EXIT): New.
3404 (struct scop): New field for a SESE region. Remove entry, exit.
3405 (SCOP_ENTRY, SCOP_EXIT): Update definitions to match same
3406 semantics as before. Moved comment around.
3407
34082008-08-25 Tobias Grosser <grosser@fim.uni-passau.de>
3409 Sebastian Pop <sebastian.pop@amd.com>
3410
3411 * graphite.c (graphite_transform_loops): Always enable gloog
3412 and find_transform when ENABLE_CHECKING.
3413
34142008-08-25 Sebastian Pop <sebastian.pop@amd.com>
3415
3416 * graphite.c (graphite_transform_loops): Move pretty printer
3417 of SCOPs before doing any transform. Remove call to print_scops
3418 and dot_all_scops_1.
3419
34202008-08-25 Sebastian Pop <sebastian.pop@amd.com>
3421
3422 * graphite.c (dump_gbb_conditions): Don't try to print NULL pointers.
3423 (print_graphite_bb): Same.
3424
34252008-08-25 Sebastian Pop <sebastian.pop@amd.com>
3426
3427 * graphite.c (dot_all_scops_1): Cleanup.
3428 (move_scops): Fix comment.
3429
34302008-08-25 Sebastian Pop <sebastian.pop@amd.com>
3431
3432 * graphite.c (build_scop_bbs): Revert commit 139355:
3433
3434 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
3435 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
3436
3437 * graphite.c (build_scop_bbs): Factor up code.
3438
34392008-08-25 Tobias Grosser <grosser@fim.uni-passau.de>
3440
3441 * graphite.c (gloog): Update dominator info.
3442
34432008-08-25 Tobias Grosser <grosser@fim.uni-passau.de>
3444
3445 * graphite.c (remove_cond_exprs): Do not fail on empty bbs.
3446
34472008-08-24 Sebastian Pop <sebastian.pop@amd.com>
3448
3449 * graphite.c (new_graphite_bb): Remove GBB_INDEX_TO_NUM_MAP
3450 initialization.
3451 (free_graphite_bb): Remove GBB_INDEX_TO_NUM_MAP free.
3452 (translate_clast): Correct formatting.
3453 * graphite.h (struct num_map): Removed.
3454 (struct graphite_bb): Remove num_map field.
3455 (GBB_INDEX_TO_NUM_MAP): Removed.
3456
34572008-08-24 Sebastian Pop <sebastian.pop@amd.com>
3458
3459 * graphite.c (build_access_matrix_with_af): Fix comments.
3460 (build_scop_data_accesses): Same.
3461
34622008-08-24 Sebastian Pop <sebastian.pop@amd.com>
3463
3464 * graphite.c (build_scop_data_accesses): Don't construct
3465 access matrices. Add a FIXME and an assert condition that
3466 should pass when the access matrices will be needed.
3467
34682008-08-24 Sebastian Pop <sebastian.pop@amd.com>
3469
3470 * tree-data-ref.c (stmt_simple_memref_p): Don't call
3471 really_constant_p.
3472 * graphite.c (build_graphite_bb): Renamed new_graphite_bb.
3473 Moved close by free_graphite_bb.
3474 (free_graphite_bb): Call free_data_refs. Reset bb->aux.
3475 (new_scop): Move close by free_scop.
3476 (graphite_transform_loops): Avoid linear scan to reset bb->aux.
3477
34782008-08-22 Jan Sjodin <jan.sjodin@amd.com>
3479
3480 * cfgloopmanip.c (create_empty_if_region_on_edge): New.
3481 * graphite.c (clast_to_gcc_expression): Call gmp_cst_to_tree
3482 instead of recursive call.
3483 (graphite_translate_clast_equation): New.
3484 (graphite_create_guard_cond_expr): New.
3485 (graphite_create_new_guard): New.
3486 (get_stack_index_from_iv): Removed.
3487 (graphite_rename_ivs_stmt): Use gbb_loop_index.
3488 (get_true_edge_from_guard_bb): New.
3489 (translate_clast): Handle stmt_guard in clast.
3490 (get_construction_edge): Allow construction edge detection for
3491 a scope entry with multiple predecessors if one predecessor is
3492 the immediate dominator of scope entry.
3493 (can_generate_code_stmt): Enable code generation for clast_guard.
3494 (gloog): Use correct context loop. Removed check for post dominators.
3495 * cfgloop.h (create_empty_if_region_on_edge): Declared.
3496
34972008-08-21 Sebastian Pop <sebastian.pop@amd.com>
3498
3499 * graphite.c (remove_dead_loops): Document better which
3500 loops are removed.
3501
35022008-08-21 Sebastian Pop <sebastian.pop@amd.com>
3503
3504 * Makefile.in: Rename POLYLIBLIBS and POLYLIBINC to PPLLIBS
3505 and PPLINC.
3506 (graphite.o): Also depends on pointer-set.h.
3507
35082008-08-21 Sebastian Pop <sebastian.pop@amd.com>
3509
3510 * graphite.c (scop_record_loop): Fix compile warning.
3511
35122008-08-21 Harsha Jagasia <harsha.jagasia@amd.com>
3513 Sebastian Pop <sebastian.pop@amd.com>
3514
3515 * graphite.c (scop_record_loop): DECL_NAME can be NULL.
3516
35172008-08-21 Sebastian Pop <sebastian.pop@amd.com>
3518
3519 * graphite.c (build_graphite_bb): Initialize bb->aux to
3520 point to the graphite_bb_p.
3521 (graphite_bb_from_bb): Renamed gbb_from_bb; returns the
3522 content of bb->aux.
3523 (add_bb_domains): Does not use the scop parameter.
3524 (graphite_transform_loops): Clean bb->aux at the end.
3525
35262008-08-20 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
3527 Sebastian Pop <sebastian.pop@amd.com>
3528
3529 * testsuite/lib/target-supports.exp
3530 (check_effective_target_fgraphite): New.
3531
3532 * testsuite/gcc.dg/graphite/graphite.exp: Early exit when
3533 check_effective_target_fgraphite returns false.
3534 Set dg-do-what-default to compile.
3535 (scan-graphite-dump-times): Removed.
3536 * testsuite/gfortran.dg/graphite/graphite.exp: Same.
3537
3538 * testsuite/gcc.dg/graphite/scop-0.c: Do not use "dg-do compile".
3539 Use scan-tree-dump-times instead of scan-graphite-dump-times.
3540 * testsuite/gcc.dg/graphite/scop-1.c: Same.
3541 * testsuite/gcc.dg/graphite/scop-2.c: Same.
3542 * testsuite/gcc.dg/graphite/scop-3.c: Same.
3543 * testsuite/gcc.dg/graphite/scop-4.c: Same.
3544 * testsuite/gcc.dg/graphite/scop-5.c: Same.
3545 * testsuite/gcc.dg/graphite/scop-6.c: Same.
3546 * testsuite/gcc.dg/graphite/scop-7.c: Same.
3547 * testsuite/gcc.dg/graphite/scop-8.c: Same.
3548 * testsuite/gcc.dg/graphite/scop-9.c: Same.
3549 * testsuite/gcc.dg/graphite/scop-10.c: Same.
3550 * testsuite/gcc.dg/graphite/scop-11.c: Same.
3551 * testsuite/gcc.dg/graphite/scop-12.c: Same.
3552 * testsuite/gcc.dg/graphite/scop-13.c: Same.
3553 * testsuite/gcc.dg/graphite/scop-matmult.c: Same.
3554 * testsuite/gcc.dg/graphite/scop-14.c: Same.
3555 * testsuite/gcc.dg/graphite/scop-15.c: Same.
3556 * testsuite/gcc.dg/graphite/block-0.c: Same.
3557 * testsuite/gcc.dg/graphite/scop-16.c: Same.
3558 * testsuite/gcc.dg/graphite/block-1.c: Same.
3559 * testsuite/gcc.dg/graphite/scop-17.c: Same.
3560 * testsuite/gcc.dg/graphite/scop-18.c: Same.
3561 * testsuite/gfortran.dg/graphite/block-1.f90: Same.
3562 * testsuite/gfortran.dg/graphite/scop-1.f: Same.
3563 * testsuite/gfortran.dg/graphite/block-2.f: Same.
3564
35652008-08-20 Sebastian Pop <sebastian.pop@amd.com>
3566
3567 * graphite.c: Fix some XXX comments.
3568 (build_scop_dynamic_schedules): Removed.
3569
35702008-08-20 Sebastian Pop <sebastian.pop@amd.com>
3571
3572 * graphite.h (scop_max_loop_depth): Moved...
3573 * graphite.c (scop_max_loop_depth): ...here.
3574 (remove_all_edges_1): New.
3575 (remove_all_edges): Factored code.
3576 (remove_cond_exprs): Check only the last statement for
3577 a GIMPLE_COND expression.
3578
35792008-08-20 Sebastian Pop <sebastian.pop@amd.com>
3580
3581 * graphite.c (scan_tree_for_params): Early return when the
3582 expression is a chrec_dont_know. Handle case NEGATE_EXPR.
3583 (find_scop_parameters): Factor out code.
3584 (graphite_trans_bb_strip_mine): Remove dead code.
3585
35862008-08-20 Sebastian Pop <sebastian.pop@amd.com>
3587
3588 * graphite.c (clast_to_gcc_expression, graphite_create_new_loop,
3589 graphite_trans_bb_move_loop): Factor asserts.
3590 (gloog): Perform sanity checks only for ENABLE_CHECKING.
3591 Do not call calculate_dominance_info and estimate_bb_frequencies.
3592
35932008-08-20 Jan Sjodin <jan.sjodin@amd.com>
3594
3595 * graphite.c (create_loops_mapping, free_loops_mapping,
3596 create_loops_mapping_num, debug_loop_mapping_1,
3597 debug_loop_mapping, graphite_loops_mapping_max_loop_num,
3598 get_loop_mapping_for_num, graphite_loops_mapping_add_child,
3599 graphite_loops_mapping_add_child_num,
3600 graphite_loops_mapping_insert_child,
3601 graphite_loops_mapping_parent, get_loop_mapped_depth_for_num,
3602 get_loop_mapped_depth, split_loop_mapped_depth_for_num,
3603 loop_mapped_depth_split_loop, swap_loop_mapped_depth_for_num,
3604 create_num_from_index, get_num_from_index,
3605 swap_loop_mapped_depth): Removed.
3606 (new_scop): Do not initialize SCOP_LOOPS_MAPPING.
3607 (free_scop): Do not call free_loops_mapping.
3608 (graphite_get_new_iv_stack_index_from_old_iv): Renamed
3609 get_stack_index_from_iv. Use GBB_LOOPS instead of calling
3610 get_loop_mapped_depth.
3611 (graphite_trans_bb_move_loop): Do not update the loop mapping.
3612 (graphite_trans_bb_strip_mine): Same.
3613 * graphite.h (graphite_loops_mapping, graphite_loop_node): Removed.
3614 (struct scop): Remove field loops_mapping.
3615
36162008-08-20 Sebastian Pop <sebastian.pop@amd.com>
3617 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
3618
3619 * graphite.c (scop_record_loop): Factor out one level of the
3620 condition by early return.
3621 (build_scop_loop_nests): Format following FSF coding style.
3622 (build_scop_dynamic_schedules): Factor out code.
3623 (scopdet_bb_info): Reindent. Default case should not be reachable.
3624
36252008-08-20 Sebastian Pop <sebastian.pop@amd.com>
3626 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
3627
3628 * graphite.c (loop_affine_expr): Check for DECL_P or struct
3629 assignments that are not handled as simple operands for now.
3630
36312008-08-20 Sebastian Pop <sebastian.pop@amd.com>
3632 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
3633
3634 * graphite.c (build_scop_bbs): Factor up code.
3635
36362008-08-20 Sebastian Pop <sebastian.pop@amd.com>
3637 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
3638
3639 * graphite.c (stmt_simple_for_scop_p): Factor code out
3640 of the loop.
3641 (enum gbb_type): New. Group all the GBB_* types under it.
3642 (is_loop_exit): Moved...
3643 (end_scop): Enable BB spliting.
3644 * cfgloop.c (is_loop_exit): ...here. Reimplemented.
3645 * cfgloop.h (is_loop_exit): Declared.
3646
36472008-08-20 Sebastian Pop <sebastian.pop@amd.com>
3648
3649 * doc/invoke.texi: Remove strides from examples containing
3650 DO loops when the strides are equal to 1.
3651
36522008-08-20 Harsha Jagasia <harsha.jagasia@amd.com>
3653 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
3654
3655 * graphite.c (graphite_trans_scop_block): Or the result with
3656 the result from graphite_trans_loop_block.
3657 * testsuite/gcc.dg/graphite/block-1.c: New.
3658 * testsuite/gfortran.dg/graphite/block-1.f90: New.
3659 * testsuite/gfortran.dg/graphite/block-2.f: New.
3660
36612008-08-20 Sebastian Pop <sebastian.pop@amd.com>
3662
3663 * graphite.c (graphite_transform_loops): Call cloog_initialize
3664 and cloog_finalize.
3665
36662008-08-20 Sebastian Pop <sebastian.pop@amd.com>
3667
3668 * tree-data-ref.c) (stmt_simple_memref_p): New.
3669 * tree-data-ref.h (stmt_simple_memref_p): Declared.
3670 * graphite.c (stmt_simple_memref_for_scop_p): Removed.
3671 (is_simple_operand): Call stmt_simple_memref_p.
3672
3673 * testsuite/gcc.dg/graphite/scop-matmult.c: Updated for not
3674 using pointer arithmetic, as this is optimized by PRE and
3675 makes the code too difficult to analyze.
3676
3677 * testsuite/gcc.dg/graphite/scop-18.c: Same.
3678
36792008-08-20 Sebastian Pop <sebastian.pop@amd.com>
3680
3681 * gdbinit.in (pgg): New.
3682
36832008-08-15 Tobias Grosser <grosser@fim.uni-passau.de>
3684
3685 * graphite.c (graphite_trans_loop_block): Fix warning.
3686
36872008-08-15 Tobias Grosser <grosser@fim.uni-passau.de>
3688
3689 * graphite.c (graphite_trans_loop_block): Fix my merge error.
3690
36912008-08-15 Tobias Grosser <grosser@fim.uni-passau.de>
3692
3693 * graphite.c (graphite_trans_bb_block): Remove check for
3694 flag_loop_strip_mine, flag_loop_block, flag_loop_interchange.
3695 Check if loop blocking is profitable for every loop, before applying
3696 the changes.
3697 (graphite_apply_transformations): Call graphite_trans_bb_block only,
3698 if flag_loop_block is set.
3699
37002008-08-14 Sebastian Pop <sebastian.pop@amd.com>
3701
3702 * graphite.c: Add some more documentation for the loop
3703 mapping.
3704
37052008-08-14 Sebastian Pop <sebastian.pop@amd.com>
3706
3707 * Makefile.in (tree-data-ref.o): Remove dependence on graphite.h.
3708 * graphite.c: Format on less than 80 columns.
3709 * graphite.h: Same.
3710
37112008-08-14 Sebastian Pop <sebastian.pop@amd.com>
3712
3713 * cfgloopmanip.c (loopify): Use update_dominators_in_loop.
3714
37152008-08-14 Sebastian Pop <sebastian.pop@amd.com>
3716
3717 * doc/invoke.texi (floop-block, floop-strip-mine,
3718 floop-interchange): Update documentation with examples.
3719
37202008-08-13 Sebastian Pop <sebastian.pop@amd.com>
3721
3722 * cfgloopmanip.c (create_empty_loop_on_edge): Don't call
3723 add_referenced_var.
3724 * graphite.c (graphite_create_new_loop): Call add_referenced_var.
3725
37262008-08-13 Sebastian Pop <sebastian.pop@amd.com>
3727
3728 * cfgloopmanip.c (create_empty_loop_on_edge): Improve documentation.
3729 Factor gcc_asserts into a single one. Use force_gimple_operand_gsi.
3730 * tree-scalar-evolution.c: Revert useless changes.
3731 * tree-phinodes.c: Same.
3732 * cfghooks.c: Same.
3733 * vec.h: Same.
3734 * tree-vectorizer.h: Same.
3735 * tree-flow.h: Same.
3736 * tree-cfg.c: Same.
3737 * common.opt (fgraphite): Update documentation.
3738
37392008-08-12 Harsha Jagasia <harsha.jagasia@amd.com>
3740
3741 * doc/invoke.texi (-floop-block, -floop-strip-mine,
3742 -floop-interchange): Add more text for explaining what each of these
3743 flags is doing.
3744 * tree-into-ssa.c (gimple_vec): Moved to...
3745 * graphite.c: Include gimple.h.
3746 (gimple_vec): Moved to...
3747 (del_loop_to_cloog_loop): Removed.
3748 (loop_affine_expr): Do not call create_data_ref when the
3749 operand is a constant.
3750 (new_scop): Use free instead of del_loop_to_cloog_loop.
3751 * Makefile.in (graphite.o): Depend on GIMPLE_H.
3752 * gimple.h (gimple_vec): ... here.
3753
37542008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
3755
3756 * graphite.c (scopdet_bb_info): Only allow loops with known number of
3757 latch executions.
3758 (build_loop_iteration_domains): Fail, if latch executions unknown.
3759
37602008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
3761
3762 * graphite.c (add_conditions_to_domain): New.
3763 (build_scop_conditions_1): Call add_conditions_to_domain.
3764 (set_cloog_options): Allow to disable optimizations.
3765
37662008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
3767
3768 * graphite.c (find_params_in_bb): Look for parameters in conditions.
3769 Do not use walk_dominator_tree.
3770 (find_scop_parameters): Do not use walk_dominator_tree.
3771
37722008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
3773
3774 * graphite.c (scan_tree_for_params) Add / Subtract inequality.
3775 (idx_record_params): Adapt.
3776 * graphite.h (scop_gimple_loop_depth): New.
3777
37782008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
3779
3780 * graphite.c (build_scop_dynamic_schedules): Remove value_init.
3781 (scan_tree_for_params): Remove value_init.
3782 (build_scop_context): Remove value_init.
3783 (build_loop_iteration_domains): Remove value_init.
3784 (schedule_to_scattering): Remove value_init.
3785 (graphite_trans_bb_strip_mine): Remove value_init.
3786
37872008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
3788
3789 * gcc/graphite.c (limit_scops): New.
3790 (graphite_transform_loops): Add limit SCoPs.
3791 * gcc/testsuite/gcc.dg/graphite/scop-0.c: Update number of SCoPs.
3792 * gcc/testsuite/gcc.dg/graphite/scop-1.c: Update number of SCoPs.
3793 * gcc/testsuite/gcc.dg/graphite/scop-10.c: Update number of SCoPs.
3794 * gcc/testsuite/gcc.dg/graphite/scop-11.c: Update number of SCoPs.
3795 * gcc/testsuite/gcc.dg/graphite/scop-12.c: Update number of SCoPs.
3796 * gcc/testsuite/gcc.dg/graphite/scop-13.c: Update number of SCoPs.
3797 * gcc/testsuite/gcc.dg/graphite/scop-14.c: Update number of SCoPs.
3798 * gcc/testsuite/gcc.dg/graphite/scop-15.c: Update number of SCoPs.
3799 * gcc/testsuite/gcc.dg/graphite/scop-16.c: Update number of SCoPs.
3800 Change loop numbers.
3801 * gcc/testsuite/gcc.dg/graphite/scop-17.c: Update number of SCoPs.
3802 Change loop numbers.
3803 * gcc/testsuite/gcc.dg/graphite/scop-18.c: Update number of SCoPs.
3804 * gcc/testsuite/gcc.dg/graphite/scop-2.c: Update number of SCoPs.
3805 * gcc/testsuite/gcc.dg/graphite/scop-3.c: Update number of SCoPs.
3806 * gcc/testsuite/gcc.dg/graphite/scop-4.c: Update number of SCoPs.
3807 * gcc/testsuite/gcc.dg/graphite/scop-5.c: Update number of SCoPs.
3808 * gcc/testsuite/gcc.dg/graphite/scop-6.c: Update number of SCoPs.
3809 * gcc/testsuite/gcc.dg/graphite/scop-7.c: Update number of SCoPs.
3810 * gcc/testsuite/gcc.dg/graphite/scop-8.c: Update number of SCoPs.
3811 * gcc/testsuite/gcc.dg/graphite/scop-9.c: Update number of SCoPs.
3812 * gcc/testsuite/gcc.dg/graphite/scop-matmult.c: Update number of SCoPs.
3813
38142008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
3815
3816 * graphite.c (graphite_transform_loops): Call always find_transform.
3817
38182008-08-08 Tobias Grosser <grosser@fim.uni-passau.de>
3819
3820 * graphite.c (free_loops_mapping): New.
3821 (stmt_simple_for_scop_p): Fix typo.
3822 (stmt_simple_for_scop_p): Fix tuples functions, that
3823 broke polyhedron.
3824 (free_graphite_bb): Fix some memleaks.
3825 (free_scop): Fix some memleaks.
3826 (scopdet_bb_info): Do not forget some tmp SCoPs.
3827 (find_params_in_bb): Fix some memleaks.
3828 (clast_to_gcc_expression): Fix warning.
3829
38302008-08-07 Tobias Grosser <grosser@fim.uni-passau.de>
3831
3832 * testsuite/gcc.dg/graphite/scop-16.c: Fix for 32bit.
3833 * testsuite/gcc.dg/graphite/scop-17.c: Fix for 32bit.
3834
38352008-08-04 Sebastian Pop <sebastian.pop@amd.com>
3836
3837 * tree-ssa-loop.c (tree-ssa-loop.o): Do not include toplev.h.
3838 Move code ifdef-ed HAVE_cloog...
3839 * graphite.c: Include toplev.h.
3840 ... here.
3841 * Makefile.in (OBJS-common): Always build graphite.o.
3842 (BACKEND): Remove @GRAPHITE@.
3843 (tree-ssa-loop.o): Do not depend on TOPLEV_H.
3844 (graphite.o): Depend on TOPLEV_H.
3845
38462008-08-04 Sebastian Pop <sebastian.pop@amd.com>
3847
3848 * Makefile.in (tree-ssa-loop.o): Depend on TOPLEV_H.
3849 Remove typo left from polylib to ppl conversion.
3850 * graphite.c (graphite_transforms): Use sorry instead of fatal.
3851
38522008-08-03 Sebastian Pop <sebastian.pop@amd.com>
3853
3854 * toplev.c (process_options): Move the graphite loop optimization
3855 flags...
3856 * tree-ssa-loop.c (graphite_transforms): ... here.
3857 When not configured with CLooG, print to dump_file that
3858 Graphite transforms were not performed.
3859 * testsuite/gcc.dg/graphite/graphite.exp (scan-graphite-dump-times):
3860 New.
3861 * testsuite/gcc.dg/graphite/*.c: Updated all testcases to use
3862 scan-graphite-dump-times.
3863
38642008-08-03 Sebastian Pop <sebastian.pop@amd.com>
3865
3866 * graphite.c (dot_scop, dot_all_scops): Do not call system.
3867 Do not open /tmp/scop.dot and /tmp/allscops.dot.
3868
38692008-08-02 Sebastian Pop <sebastian.pop@amd.com>
3870 Jan Sjodin <jan.sjodin@amd.com>
3871
3872 * configure: Regenerated.
3873 * omp-low.c (expand_omp_sections): Remove now unused code.
3874 * config.in (HAVE_polylib): Removed.
3875 * configure.ac (HAVE_polylib, POLYLIBLIBS, POLYLIBINC): Removed.
3876 (PPLLIBS, PPLINC): Added.
3877 * graphite.c: Replace unsigned with int wherever possible.
3878 Don't access Cloog's data structures, but use accessor functions.
3879 Clast's stmt->type is now implemented as a vtable: change the
3880 switches of stmt->type into ifs.
3881 (polylib/polylibgmp.h): Don't include.
3882 (initialize_dependence_polyhedron,
3883 initialize_data_dependence_polyhedron, is_empty_polyhedron,
3884 statement_precedes_p, test_dependence, build_rdg_all_levels,
3885 dump_dependence_graph): Removed until this code is cleaned up
3886 or ported to Cloog.
3887 * Makefile.in (POLYLIBLIBS): Renamed PPLLIBS.
3888 (POLYLIBINC): Renamed PPLINC.
3889
38902008-08-01 Harsha Jagasia <harsha.jagasia@amd.com>
3891 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
3892 Jan Sjodin <jan.sjodin@amd.com>
3893
3894 Finish the merge and tuplification of graphite.
3895
38962008-07-24 Sebastian Pop <sebastian.pop@amd.com>
3897 Jan Sjodin <jan.sjodin@amd.com>
3898
3899 Partial merge from mainline (138072:138275).
3900 * graphite.c still has to be tuplified.
3901
39022008-07-29 Jan Sjodin <jan.sjodin@amd.com>
3903
3904 * graphite.c (graphite_loops_mapping_max_loop_num): New.
3905 (create_num_from_index): New.
3906 (get_num_from_index): Also pass in the graphite BB.
3907 (free_graphite_bb): Free GBB_INDEX_TO_NUM_MAP.
3908 (build_graphite_bb): Initialize GBB_INDEX_TO_NUM_MAP.
3909 (graphite_trans_bb_strip_mine): Call create_num_from_index.
3910 (is_interchange_valid): Return false when failing.
3911 * graphite.h (struct num_map): New.
3912 (struct graphite_bb): New field num_map.
3913 (GBB_LOOPS_MAPPING): Renamed GBB_INDEX_TO_NUM_MAP.
3914
39152008-07-29 Tobias Grosser <grosser@fim.uni-passau.de>
3916
3917 * graphite.c (dump_gbb_conditions): Print also conditions like
3918 "if (a)". Remove dublicated code and use print_generic_expr ().
3919 (stmt_simple_for_scop_p): Only allow conditions we can handle
3920 {<, <=, >, >=}.
3921
39222008-07-25 Jan Sjodin <jan.sjodin@amd.com>
3923
3924 * graphite.h (struct scop): Removed new_ivs field.
3925 (SCOP_NEWIVS): Deleted.
3926 * graphite.c (new_scop, free_scop, clast_name_to_gcc,
3927 clast_to_gcc_expression, graphite_create_new_loop):
3928 Removed use of new_ivs.
3929
39302008-07-25 Jan Sjodin <jan.sjodin@amd.com>
3931
3932 * graphite.c (debug_oldivs, debug_loop_vec, create_loops_mapping,
3933 create_loops_mapping_num, debug_loop_mapping_1): New.
3934 (debug_loop_mapping): Call debug_loop_mapping_1.
3935 (get_loop_mapping_for_num,
3936 graphite_loops_mapping_add_child,
3937 graphite_loops_mapping_add_child_num,
3938 graphite_loops_mapping_insert_child,
3939 graphite_loops_mapping_parent,
3940 split_loop_mapped_depth_for_num,
3941 loop_mapped_depth_split_loop): New.
3942 (increment_loop_mapped_depths): Removed.
3943 (swap_loop_mapped_depth_for_num): Reimplemented.
3944 (new_scop): Call create_loops_mapping.
3945 (scop_record_loop): Call graphite_loops_mapping_insert_child.
3946 (translate_clast): Pass the old loop father in parameter, and pass
3947 it to get_old_iv_from_ssa_name.
3948 (remove_edges_around_useless_blocks, can_generate_code_stmt,
3949 can_generate_code, can_generate_for_scop): New.
3950 (graphite_trans_bb_block): Returns false when it fails to transform.
3951 * graphite.h (graphite_loop_node, graphite_loops_mapping): New.
3952
39532008-07-25 Sebastian Pop <sebastian.pop@amd.com>
3954
3955 Reverted all the changes related to the streamization and
3956 loop fusion.
3957 These changes are now tracked in the streamization branch.
3958
39592008-07-25 Sebastian Pop <sebastian.pop@amd.com>
3960 Jan Sjodin <jan.sjodin@amd.com>
3961
3962 * graphite.c (gbb_compare): Correctly constify.
3963 (gbb_can_be_ignored): Indent.
3964 (graphite_trans_scop_swap_1and2): Add legality check.
3965 Remove dead FIXMEs.
3966
39672008-07-25 Sebastian Pop <sebastian.pop@amd.com>
3968
3969 Remove fallouts from "Reverted the Condate changes".
3970 * tree.h: Remove unused decl.
3971 * testsuite/gcc.dg/tree-checker: Same.
3972 * timevar.def: Remove counter.
3973
39742008-07-24 Sebastian Pop <sebastian.pop@amd.com>
3975
3976 * Merge from mainline (135673:138072).
3977
3978 Reverted the MIRO changes (from 2008-04-05) that are now
3979 tracked in the miro branch.
3980 * tree-bounds.c: Removed.
3981 * tree-bounds.h: Removed.
3982
3983 Reverted the Condate changes (from 2006-07-04, 2007-03-20) that
3984 are now tracked in the condate branch.
3985 * tree-check.c: Removed.
3986 * tree-match.c: Removed.
3987 * condate.y: Removed.
3988
39892008-07-24 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
3990
3991 * common.opt: New user flag -floop-block, -floop-strip-mine
3992 and -floop-interchange.
3993 * toplev.c (process_options): Enable -fgraphite pass if any one of the
3994 graphite loop optimization flags is turned on.
3995 * graphite.c (graphite_apply_transformations): Add flag_loop_block,
3996 flag_loop_strip_mine and flag_loop_interchange checks before
3997 optimizations.
3998 * doc/invoke.texi: Remove -fgraphite and add -floop-block,
3999 -floop-strip-mine and -floop-interchange.
4000 * testsuite/gcc.dg/graphite/block-0.c: Add -floop-block and remove
4001 -fgraphite.
4002 * testsuite/gcc.dg/graphite/scop-16.c: Ditto.
4003 * testsuite/gcc.dg/graphite/scop-17.c: Ditto.
4004 * testsuite/gcc.dg/graphite/scop-18.c: Ditto.
4005
40062008-07-23 Jan Sjodin <jan.sjodin@amd.com>
4007 Sebastian Pop <sebastian.pop@amd.com>
4008
4009 * cfgloopmanip.c (update_dominators_in_loop): Make it static.
4010 (create_empty_loop_on_edge): More fixes.
4011 * tree-phinodes.c (resize_phi_node): Extern.
4012 (unlink_phi_node, move_phi_node): New split from remove_phi_node.
4013 * cfghooks.c (update_dominator_information): New split from
4014 split_edge.
4015 * tree-vectorizer.c (rename_variables_in_bb): Extern.
4016 * tree-dfa.c (collect_dfa_stats): Start walking the CFG on the
4017 successor of the function entry block.
4018
4019 * graphite.c: Include pointer-set.h.
4020 (debug_loop_mapping, increment_loop_mapped_depths,
4021 get_loop_mapped_depth_for_num, get_loop_mapped_depth,
4022 set_loop_mapped_depth_for_num, set_loop_mapped_depth,
4023 swap_loop_mapped_depth_for_num, get_num_from_index,
4024 swap_loop_mapped_depth, loop_iv_stack_debug,
4025 loop_iv_stack_push, loop_iv_stack_pop, loop_iv_stack_get_iv,
4026 loop_iv_stack_get_iv_from_name, loop_iv_stack_debug,
4027 get_old_iv_from_ssa_name): New.
4028 (new_scop): Initialize SCOP_LOOPS_MAPPING.
4029 (free_scop): Free SCOP_LOOPS_MAPPING.
4030 (scop_record_loop): Record old ivs.
4031 (create_var_name): Removed.
4032 (initialize_cloog_names): Allocate double space in case strip mine
4033 applies to all loops once.
4034 (clast_name_to_gcc): Look up in the map ivstack passed in parameter.
4035 (clast_to_gcc_expression): Same. Implement more clast to gimple
4036 translation.
4037 (graphite_create_new_loop): Pass in ivstack.
4038 (remove_all_edges): Pass in the construction_edge.
4039 (graphite_remove_iv): Removed.
4040 (graphite_rename_ivs, graphite_rename_ivs_stmt,
4041 remove_cond_exprs): Rewritten.
4042 (move_phi_nodes): New.
4043 (disconnect_virtual_phi_nodes, disconnect_cond_expr): Removed.
4044 (translate_clast): Pass in ivstack. Rewrite some cases.
4045 (set_cloog_options, debug_clast_stmt): New.
4046 (find_transform): Use set_cloog_options.
4047 (outermost_loop_layer): Removed.
4048 (get_construction_edge, collect_virtual_phis, find_vdef_for_var_in_bb,
4049 find_vdef_for_var_1, find_vdef_for_var, patch_phis_for_virtual_defs,
4050 mark_old_loops, remove_dead_loops): New.
4051 (gloog): Rewritten.
4052 (graphite_trans_bb_move_loop): Call swap_loop_mapped_depth.
4053 (const_column_index, get_first_matching_sign_row_index,
4054 get_lower_bound_row, get_upper_bound_row, get_lower_bound,
4055 get_upper_bound): New.
4056 (graphite_trans_bb_strip_mine): Also update the iv map.
4057
4058 * graphite.h (graphite_loops_mapping, GBB_LOOPS_MAPPING): New.
4059 (struct name_tree): Add a loop field.
4060 (struct scop): Add a graphite_loops_mapping field.
4061 (SCOP_LOOPS_MAPPING): New.
4062 (debug_clast_stmt): Declare.
4063 * lambda.h (find_induction_var_from_exit_cond): Declare.
4064 (lambda-code.c): (find_induction_var_from_exit_cond): Extern.
4065 * cfgloop.h (update_dominators_in_loop): Removed declaration.
4066 (create_empty_loop_on_edge): Updated.
4067 * tree-flow.h (remove_bb, resize_phi_node, move_phi_node,
4068 rename_variables_in_bb): Declare.
4069 * tree-cfg.c (remove_bb): Extern.
4070
4071 * testsuite/gcc.dg/graphite/block-0.c: New.
4072
40732008-07-21 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
4074 Sebastian Pop <sebastian.pop@amd.com>
4075
4076 * graphite.c (strip_mine_profitable_p): New.
4077 (graphite_trans_bb_block): Disable strip mining if not profitable.
4078
4079 * testsuite/gcc.dg/graphite/scop-18.c: New.
4080 * testsuite/gcc.dg/graphite/scop-17.c: Fixed.
4081 * testsuite/gcc.dg/graphite/scop-16.c: Fixed.
4082
40832008-07-17 Harsha Jagasia <harsha.jagasia@amd.com>
4084 Jan Sjodin <jan.sjodin@amd.com>
4085 Sebastian Pop <sebastian.pop@amd.com>
4086
4087 * graphite.c (is_interchange_valid): New.
4088 (graphite_trans_bb_block): Check loop nest of basic block for legality
4089 of interchange.
4090
4091 * graphite.h (gbb_inner_most_loop_index, outer_most_loop_1,
4092 outer_most_loop, gbb_outer_most_loop_index): New.
4093
4094 * tree-loop-linear.c (perfect_loop_nest_depth): Remove static.
4095 * tree-flow.h (perfect_loop_nest_depth): Declare as extern.
4096 * testsuite/gcc.dg/graphite/scop-16.c: New.
4097 * testsuite/gcc.dg/graphite/scop-17.c: New.
4098
40992008-07-11 Tobias Grosser <grosser@fim.uni-passau.de>
4100
4101 * graphite.c (scop_remove_ignoreable_gbbs): Also update bitmap.
4102 (graphite_trans_scop_block): Ignore SCoPs without bbs.
4103
41042008-07-11 Tobias Grosser <grosser@fim.uni-passau.de>
4105
4106 * graphite.c (new_scop): Initialize SCOP_EXIT.
4107 (scopdet_info): Add.
4108 (scopdet_bb_info): Rename from is_bb_addable. Cleanup, bugfixes.
4109 (build_scops_1): Cleanup, bugfixes.
4110 (build_scops): Cleanup.
4111
4112 * testsuite/gcc.dg/graphite/scop-matmult.c: Remove duplicated code.
4113 * testsuite/gcc.dg/graphite/scop-15.c: Add SCoP numbers.
4114
41152008-07-10 Harsha Jagasia <harsha.jagasia@amd.com>
4116
4117 * testsuite/gfortran.dg/graphite/scop-1.f: Update to reduced test case.
4118
4119 * testsuite/gfortran.dg/graphite/graphite.exp: Use
4120 DEFAULT_GRAPHITE_FLAGS.
4121
4122 * testsuite/gcc.dg/graphite/scop-15.c: Update to reduced test case.
4123
41242008-07-10 Harsha Jagasia <harsha.jagasia@amd.com>
4125
4126 * graphite.c (scan_tree_for_params): Do not assert any more if
4127 MULT_EXPR parameter is negative.
4128
4129 * testsuite/gfortran.dg/graphite/scop-1.f: New.
4130
4131 * testsuite/gfortran.dg/graphite/graphite.exp: New.
4132
4133 * testsuite/gcc.dg/graphite/scop-15.c: New.
4134
41352008-07-10 Harsha Jagasia <harsha.jagasia@amd.com>
4136
4137 * graphite.c (is_bb_addable): Fix segfault in spec gzip and reformat.
4138
41392008-07-10 Tobias Grosser <grosser@fim.uni-passau.de>
4140
4141 * graphite.c (graphite_trans_bb_swap_loops): Rename from
4142 graphite_swap_loops.
4143 (graphite_trans_bb_move_loop): New.
4144 (graphite_trans_bb_strip_mine): Rename from graphite_strip_mine_loop.
4145 (graphite_trans_bb_block): New.
4146 (graphite_trans_loop_block): New.
4147 (graphite_trans_scop_swap_1and2): Rename from
4148 graphite_trans_swap_1and2.
4149 (graphite_trans_scop_strip): Rename from graphite_trans_strip.
4150 (graphite_trans_scop_block): New.
4151 (graphite_apply_transformations): Rename from
4152 graphite_transformations.
4153
4154 * testsuite/gcc.dg/graphite/scop-matmult.c: New.
4155
41562008-07-10 Tobias Grosser <grosser@fim.uni-passau.de>
4157
4158 * graphite.c (gbb_compare): New.
4159 (graphite_sort_gbbs): New.
4160 (gbb_can_be_ignored): New.
4161 (scop_remove_ignoreable_gbbs): New.
4162 (graphite_transformations): Cleanup and add
4163 scop_remove_ignoreable_gbbs.
4164 * lambda.h (lambda_vector_compare): New.
4165
41662008-07-09 Tobias Grosser <grosser@fim.uni-passau.de>
4167
4168 * graphite.c (print_graphite_bb): Correct printing of static schedule.
4169 (graphite_swap_loops): int -> unsigned
4170 (graphite_strip_mine_loop): int -> unsigned, Fix SCHEDULE
4171 (graphite_transformations): New.
4172 (graphite_transform_loops): Move to graphite_transformations.
4173 * graphite.h (gbb_nb_loops): Return unsigned.
4174
41752008-07-04 Tobias Grosser <grosser@fim.uni-passau.de>
4176
4177 * graphite.c (scan_tree_for_params): Fix insertion of parameters into
4178 the domain matrix. This makes scop-0.c work again.
4179
41802008-06-20 Richard Guenther <rguenther@suse.de>
4181
4182 * graphite.h: Adjust copyright to GPLv3.
4183 * graphite.c: Likewise.
4184 (stmt_simple_memref_for_scop_p): Split out from ...
4185 (stmt_simple_for_scop_p): ... here. Fix handling of calls
4186 and simplify.
4187 (get_bb_type): Optimize.
4188 (is_pred): Remove.
4189 (is_bb_addable): Fix memleak, replace is_pred call with
4190 single_pred.
4191 (build_scops): Use current_loops.
4192 (param_index): Fix memleak.
4193
41942008-06-20 Konrad Trifunovic <konrad.trifunovic@inria.fr>
4195
4196 * graphite.c: Fix formatting.
4197
41982008-06-19 Konrad Trifunovic <konrad.trifunovic@inria.fr>
4199
4200 * graphite.c (new_scop): Memory allocation for SCOP_{NEWIVS, OLDIVS}.
4201 (free_scop): Memory deallocation for SCOP_NEWIVS, SCOP_OLDIVS.
4202 (create_var_name, save_var_name): Newly defined functions.
4203 (initialize_cloog_names): Part of the code factored out to
4204 save_var_name.
4205 (clast_to_gcc_expression): Now handles the case of clast_red_sum
4206 in clast_reduction statement.
4207 (graphite_create_new_loop): Now takes a new parameter
4208 for outer_loop.
4209 (translate_clast): Now also takes the context_loop and bb_exit
4210 parameters. Rewritten the code so that it creates a gimple code
4211 inside the given context.
4212 (outermost_loop_layer, graphite_remove_iv, graphite_rename_ivs,
4213 remove_cond_expr, disconnect_cond_expr,
4214 disconnect_virtual_phi_nodes): Newly defined functions.
4215 * graphite.h (struct scop): added old_ivs vector.
4216 SCOP_OLDIVS: New macro.
4217
42182008-06-19 Sebastian Pop <sebastian.pop@amd.com>
4219
4220 * cfgloopmanip.c: Add missing function comments, fix formatting.
4221
42222008-06-18 Konrad Trifunovic <konrad.trifunovic@inria.fr>
4223
4224 * cfgloopmanip.c (update_dominators_in_loop): Defined.
4225 (create_empty_loop_on_edge): Defined.
4226 * tree-parloops.c (canonicalize_loop_ivs): Returns tree
4227 instead of void.
4228 * cfgloop.h (create_empty_loop_on_edge): Declared as extern.
4229 (update_dominators_in_loop): Declared as extern
4230 * tree-flow.h (canonicalize_loop_ivs): Declared as extern.
4231
42322008-06-16 Tobias Grosser <grosser@fim.uni-passau.de>
4233
4234 * graphite.c (print_graphite_bb): Allow changing number of loops
4235 in SCoP domain.
4236 (initialize_cloog_names): Allow changing number of loops.
4237 (build_cloog_prog): Simplify.
4238 (find_transform): Enable cloog option --strides.
4239 (graphite_swap_loops): New.
4240 (graphite_strip_mine_loop): New.
4241 (graphite_trans_swap_1and2): New.
4242 (graphite_trans_strip): New.
4243 (graphite_transform_loops): Add graphite_trans_strip.
4244 * graphite.h (scop_max_loop_depth): New.
4245
42462008-06-15 Tobias Grosser <grosser@fim.uni-passau.de>
4247
4248 * graphite.c (build_scop_iteration_domain): Remove forgotten
4249 line. (Fixes compile)
4250
42512008-06-15 Tobias Grosser <grosser@fim.uni-passau.de>
4252
4253 * graphite.c (print_graphite_bb): Add output of GBB_LOOPS.
4254 (build_graphite_bb): Add GBB_LOOPS and GBB_DOMAIN and reorder.
4255 (build_bb_loops): New.
4256 (graphite_transform_loops): Add build_bb_loops.
4257 (schedule_to_scattering): Use gbb_nb_loops to support changing loop
4258 numbers.
4259 * graphite.h (graphite_bb): Add loops.
4260 (gbb_nb_loops): New.
4261 (gbb_loop_at_index): New.
4262 (gbb_loop_index): New.
4263 (nb_params_in_scop): Renamed to scop_nb_params. Updated all functions
4264 using nb_params_in_scop.
4265
42662008-06-14 Tobias Grosser <grosser@fim.uni-passau.de>
4267
4268 * graphite.c (print_graphite_bb): Adapt to minimized schedule.
4269 (build_scop_canonical_schedules): Build minimized schedule.
4270 (schedule_to_scattering): Adapt to minimized schedule.
4271 * graphite.h (graphite_bb): Add/Update descriptions.
4272
42732008-06-14 Adrien Eliche <aeliche@isty.uvsq.fr>
4274 Tobias Grosser <grosser@fim.uni-passau.de>
4275
4276 * graphite.c (print_graphite_bb): Add condition printing.
4277 (dump_value): New.
4278 (dump_gbb_conditions): New.
4279 (build_scop_conditions_1): New.
4280 (build_scop_conditions): New.
4281 * graphite.h (graphite_bb): Add conditions.
4282
42832008-06-14 Tobias Grosser <grosser@fim.uni-passau.de>
4284
4285 * graphite.c (print_graphite_bb):
4286 (free_graphite_bb): New.
4287 (free_scop): Free bbs.
4288 (get_bb_type): Free doms.
4289 (build_scop_context): Free context matrix.
4290 (build_loop_iteration_domains): Remove unused code.
4291 (build_cloog_prog): Free scattering function and blocklist.
4292 (find_transform): Free options.
4293
42942008-06-13 Tobias Grosser <grosser@fim.uni-passau.de>
4295
4296 * graphite.c (loop_body_to_cloog_stmts): Rename to add_bb_domains.
4297 Remove unnecessery cloog data structures. Make a copy of the domain
4298 (setup_cloog_loop): Rename to build_loop_iteration_domains. Remove
4299 unnecessary cloog data structures. Fix memory leaks. Remove insert
4300 into SCOP_LOOP2CLOOG_LOOP as the inserted CloogLoops will never be
4301 used.
4302 (build_scop_iteration_domain): Remove unnecessary cloog
4303 data structures. Fix memory leaks.
4304 (graphite_transform_loops): Disable build_scop_dynamic_schedules as it
4305 uses SCOP_LOOP2CLOOG_LOOP, that is at the moment not working.
4306
43072008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
4308
4309 * graphite.c (find_scop_params): Remove initialize_cloog_names.
4310
43112008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
4312
4313 * graphite.c (end_scop): Style fix.
4314 (schedule_to_scattering): Style and comment fix.
4315
43162008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
4317 * graphite.c (print_graphite_bb): Fix definiton of
4318 schedule_to_scattering.
4319 (initialize_cloog_names): Change nb_scattdims to max loop
4320 depth in SCoP.
4321 (schedule_to_scattering): Take parameter for number of scattering
4322 dimensions.
4323 (build_cloog_prog): Only build as much scattering dimensions as
4324 necessary.
4325
43262008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
4327
4328 * graphite.c (end_scop): Disable bb splitting. Fixes SIGSEGV
4329 in polyhedron/aermod.f90.
4330
43312008-06-11 Tobias Grosser <grosser@fim.uni-passau.de>
4332 Dwarak Rajagopal <dwarak.rajagopal@amd.com>
4333 Harsha Jagasia <harsha.jagasia@amd.com>
4334
4335 * graphite.c (is_bb_addable): Fix segfault.
4336
43372008-06-10 Tobias Grosser <grosser@fim.uni-passau.de>
4338
4339 * graphite.c (is_bb_addable): Fix memory leak, handling of loops
4340 with multiple exits and conditional handling in edge cases.
4341 (is_loop_exit): Fix memory leak. (Forgotten in last commit)
4342
4343 * testsuite/gcc.dg/graphite/scop-14.c: New.
4344
43452008-06-06 Tobias Grosser <grosser@fim.uni-passau.de>
4346 Adrien Eliche <aeliche@isty.uvsq.fr>
4347
4348 * graphite.c (is_bb_addable): Add more comments and enhance
4349 readablity of the source code. Fix memory leak.
4350 (is_loop_exit): Fix memory leak.
4351
43522008-06-05 Tobias Grosser <grosser@fim.uni-passau.de>
4353
4354 * graphite.c (first_loop_in_scop): Deleted.
4355 (setup_cloog_loop): Only walk the loop chain for inner loops.
4356 (build_scop_iteration_domain): Execute setup_cloog_loop for
4357 all loops in the first layer.
4358
43592008-06-05 Tobias Grosser <grosser@fim.uni-passau.de>
4360
4361 * graphite.c (scan_tree_for_params): Change the way params are
4362 added to be indepenent of the number of loops.
4363 (setup_cloog_loop): Revert to short matrix format. Fix parameter
4364 handling.
4365 (build_cloog_prog): Revert to short matrix format.
4366
43672008-06-05 Sebastian Pop <sebastian.pop@amd.com>
4368 Dwarak Rajagopal <dwarak.rajagopal@amd.com>
4369
4370 * tree-loop-fusion.c (fuse_loops): Fix uninitialized variable
4371 warning.
4372
43732008-06-05 Sebastian Pop <sebastian.pop@amd.com>
4374
4375 * graphite.c (nb_data_refs_in_scop): New.
4376 (graphite_transform_loops): Print more stats: number of
4377 loops, basic blocks and data references per scop.
4378
43792008-06-04 Sebastian Pop <sebastian.pop@amd.com>
4380 Jan Sjodin <jan.sjodin@amd.com>
4381
4382 * graphite.c (loop_affine_expr, idx_record_params,
4383 find_scop_parameters, setup_cloog_loop): Use instantiate_scev
4384 instead of instantiate_parameters.
4385
43862008-06-04 Tobias Grosser <grosser@fim.uni-passau.de>
4387
4388 * graphite.c (schedule_to_scattering): Fix scattering dimensions,
4389 add support for parameters, add STATIC_SCHEDULE at the right places,
4390 cleanup.
4391
43922008-06-04 Tobias Grosser <grosser@fim.uni-passau.de>
4393
4394 * graphite.c (build_scop_loop_nests): Only add the loops, that
4395 are contained completely in the SCoP.
4396 (build_cloog_prog): Disable scattering, until schedule_to_scattering
4397 and the domains are fixed.
4398 (build_scop_canonical_schedules): Add support for bbs not contained
4399 in any SCoP.
4400
44012008-06-04 Tobias Grosser <grosser@fim.uni-passau.de>
4402
4403 * graphite.h (scop_contains_loop): Update comments to match
4404 the actual behavior.
4405 (scop_contains_loop): New.
4406 * graphite.c (schedule_to_scattering): Use scop_contains_loop.
4407
44082008-06-04 Sebastian Pop <sebastian.pop@amd.com>
4409
4410 * graphite.c (get_bb_type): On function body, i.e. loop_0,
4411 don't mark blocks as GBB_LOOP_SING_EXIT_HEADER, mark them
4412 as GBB_COND_HEADER.
4413
44142008-06-04 Sebastian Pop <sebastian.pop@amd.com>
4415 Tobias Grosser <grosser@fim.uni-passau.de>
4416
4417 * graphite.c (graphite_transform_loops): Early return when
4418 there are no loops in the function.
4419
44202008-05-31 Sebastian Pop <sebastian.pop@amd.com>
4421 Jan Sjodin <jan.sjodin@amd.com>
4422
4423 * graphite.c (scan_tree_for_params, setup_cloog_loop): Compute the
4424 offset of the last loop.
4425 (setup_cloog_loop): Copy the entire outer constraint matrix.
4426
44272008-05-31 Sebastian Pop <sebastian.pop@amd.com>
4428 Jan Sjodin <jan.sjodin@amd.com>
4429
4430 * graphite.c (stmt_in_scop_p, function_parameter_p,
4431 invariant_in_scop_p): Removed.
4432 (scan_tree_for_params): Can be used with no constraint
4433 matrix for gathering parameters.
4434 (idx_record_params): Don't use idx_record_param, instead use
4435 scan_tree_for_params.
4436 (find_scop_parameters): Same.
4437 (setup_cloog_loop, build_scop_iteration_domain, build_cloog_prog):
4438 Fix the size of loop domains.
4439 (schedule_to_scattering): Exit when the outer loop is not in scop.
4440 (find_transform): Enable build_cloog_prog.
4441
44422008-05-31 Sebastian Pop <sebastian.pop@amd.com>
4443 Jan Sjodin <jan.sjodin@amd.com>
4444
4445 * graphite.c (schedule_to_scattering): Make scattering domains
4446 uniformly of the same size, as required by CLooG 0.14.0 and before.
4447
44482008-05-31 Sebastian Pop <sebastian.pop@amd.com>
4449 Jan Sjodin <jan.sjodin@amd.com>
4450
4451 * graphite.c (schedule_to_scattering): Rewrite, correct the
4452 translation of the scheduling function to scattering.
4453 (build_cloog_prog): Call schedule_to_scattering only once.
4454 * graphite.h (scop_loop_index): Do not fail for loops not
4455 in the scop: return -1.
4456
44572008-05-30 Tobias Grosser <grosser@fim.uni-passau.de>
4458
4459 * graphite.c (build_graphite_bb): Initialize GBB_DOMAIN.
4460 (loop_body_to_cloog_stmts): Export GBB_DOMAIN.
4461 (setup_cloog_loop): Export GBB_DOMAIN.
4462 (build_cloog_prog): New. Create new CLOOG_PROG, which should be
4463 able to rebuild the original control flow.
4464 * graphite.h (graphite_bb): Add domain field and access macro.
4465 (GBB_DOMAIN): New.
4466
44672008-05-30 Sebastian Pop <sebastian.pop@amd.com>
4468
4469 * graphite.c (debug_gbb): New.
4470 (print_scop, build_graphite_bb): Use SCOP_BBS.
4471 (build_scop_bbs): Reimplemented.
4472 (dfs_bb_in_scop_p): Removed.
4473 (build_scop_loop_nests): Reorder loops inserted in
4474 SCOP_LOOP_NEST: outer loops should come first.
4475 (build_scop_canonical_schedules): Reinitialize at zero
4476 the components of the SCOP_STATIC_SCHEDULE for the loops
4477 that have already been parsed.
4478
4479 * graphite.h (debug_gbb): Declared.
4480
44812008-05-30 Sebastian Pop <sebastian.pop@amd.com>
4482 Jan Sjodin <jan.sjodin@amd.com>
4483
4484 * graphite.c (create_empty_loop): Renamed graphite_create_new_loop.
4485 (graphite_loop_to_gcc_loop): Removed.
4486 (remove_all_edges): New.
4487 (graphite_stmt_to_gcc_stmt): Renamed translate_clast.
4488 (gloog): Remove useless code.
4489
44902008-05-29 Tobias Grosser <grosser@fim.uni-passau.de>
4491
4492 * graphite.c (get_bb_type): Reworked. We distinguish between
4493 loops with one or multiple exits.
4494 (is_loop_exit): New.
4495 (is_pred): New.
4496 (is_bb_addable): Rework condition handling, now support for case
4497 case statements and loops with multiple exits.
4498
4499 * testsuite/gcc.dg/graphite/scop-11.c: New.
4500 * testsuite/gcc.dg/graphite/scop-12.c: New.
4501 * testsuite/gcc.dg/graphite/scop-13.c: New.
4502
45032008-05-29 Tobias Grosser <grosser@fim.uni-passau.de>
4504
4505 * graphite.c (dot_all_scops_1): Fix some colors. Reuse colors, if
4506 we have too many colors.
4507
45082008-05-22 Sandeep Maram <smaram_b04@iiita.ac.in>
4509
4510 * doc/invoke.texi (-ftree-loop-fusion): Document.
4511 * tree-pass.h (pass_loop_fusion): Declared.
4512 * tree-loop-fusion.c: New.
4513 * timevar.def (TV_TREE_LOOP_FUSION): Declared.
4514 * tree-data-ref.c (find_data_references_in_loop): Make extern.
4515 * tree-data-ref.h (find_data_references_in_loop): Declared.
4516 * common.opt (ftree-loop-fusion): Declared.
4517 * Makefile.in (tree-loop-fusion.o): Added rule and to OBJS-common.
4518
45192008-05-21 Sebastian Pop <sebastian.pop@amd.com>
4520
4521 * graphite.c (build_access_matrix): Fix typo from the merge.
4522
45232008-05-20 Sebastian Pop <sebastian.pop@amd.com>
4524
4525 * Merge from mainline (130800:135673).
4526
45272008-05-07 Sebastian Pop <sebastian.pop@amd.com>
4528
4529 * graphite.c (end_scop): The exit of the scop is not part of the scop.
4530 Update dominators after splitting.
4531
45322008-05-07 Sebastian Pop <sebastian.pop@amd.com>
4533
4534 * graphite.c (is_bb_addable): Return the harmful statement.
4535 Factor up some code.
4536 (end_scop): New. Splits end of scope bbs on a harmful statement.
4537 (build_scops_1): Call end_scop.
4538
45392008-05-07 Sebastian Pop <sebastian.pop@amd.com>
4540
4541 * graphite.c: (succs_at_same_depth, end_scop, all_preds_visited_p,
4542 all_succs_visited_p, start_new_scop_for_each_succ, start_new_scop,
4543 add_dominators_to_open_scops, stop_last_open_scop, scop_end_loop,
4544 build_scops_1): Removed.
4545 (build_scops_2): Renamed build_scops_1.
4546
45472008-05-06 Sebastian Pop <sebastian.pop@amd.com>
4548
4549 * graphite.c: Fix formatting.
4550
45512008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
4552
4553 * graphite.c (get_bb_type): New.
4554 (move_scops): New.
4555 (build_scops_2): New.
4556 (is_bb_addable): New.
4557 (build_scops): Switch the scop detection.
4558 (build_scop_bbs): Add entry bb to scop.
4559 * graphite.h (struct scop): Update comment.
4560
45612008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
4562
4563 * graphite.c (dot_all_scops_1): Fix some incorrect colors and add
4564 more colors.
4565
45662008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
4567
4568 * testsuite/gcc.dg/graphite/scop-1.c: Update.
4569 * testsuite/gcc.dg/graphite/scop-2.c: Update.
4570 * testsuite/gcc.dg/graphite/scop-4.c: Update.
4571 * testsuite/gcc.dg/graphite/scop-5.c: Add.
4572 * testsuite/gcc.dg/graphite/scop-6.c: Add.
4573
45742008-05-06 Sebastian Pop <sebastian.pop@amd.com>
4575
4576 * testsuite/gcc.dg/graphite/scop-0.c: Add.
4577 * testsuite/gcc.dg/graphite/scop-7.c: Add.
4578 * testsuite/gcc.dg/graphite/scop-8.c: Add.
4579 * testsuite/gcc.dg/graphite/scop-9.c: Add.
4580 * testsuite/gcc.dg/graphite/scop-10.c: Add.
4581
45822008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
4583
4584 * graphite.c (scop_affine_expr): Renamed to loop_affine_expr.
4585 Check affine expressions depending on the outermost loop
4586 instead of a scop.
4587 (stmt_simple_for_scop_p): Same.
4588 (harmfule_stmt_in_scop): Same.
4589
45902008-04-28 Tobias Grosser <grosser@fim.uni-passau.de>
4591
4592 * graphite.c (dot_all_scops): Remove incorrect difficult bb coloring,
4593 mark entry and exit, that are not part of the SCoP and update HTML
4594 formatting.
4595
45962008-04-25 Sebastian Pop <sebastian.pop@amd.com>
4597
4598 * graphite.c (basic_block_simple_for_scop_p): Renamed
4599 harmful_stmt_in_bb.
4600 (save_scop, preds_at_same_depth, test_for_scop_bound): Removed.
4601 (add_dominators_to_open_scops, build_scops_1): Reimplemented.
4602 (all_preds_visited_p, all_succs_visited_p,
4603 start_new_scop_for_each_succ, start_new_scop, stop_last_open_scop,
4604 scop_end_loop): New.
4605 (build_scops): Do not use dfs_enumerate_from.
4606
4607 * testsuite/gcc.dg/graphite/scop-{1,2,4}.c: Updated.
4608
46092008-04-23 Sebastian Pop <sebastian.pop@amd.com>
4610
4611 * graphite.c: Add comments to functions that are missing a
4612 description.
4613 (graphite_create_iv): Removed. Merged in graphite_loop_to_gcc_loop.
4614
46152008-04-23 Sebastian Pop <sebastian.pop@amd.com>
4616
4617 * graphite.c (nb_params_in_scop): Moved...
4618 (graphite_bb_from_bb, loop_body_to_cloog_stmts): New.
4619 (setup_cloog_loop): Call loop_body_to_cloog_stmts.
4620 (clast_to_gcc_expression): Reduce column size to less than 80.
4621 (graphite_create_iv): Return the new name of the IV.
4622 (find_transform): Set options->esp and options->cpp.
4623 (gloog): Comment out the invalidation of the old loop code.
4624 (initialize_dependence_polyhedron): Replace scop_nb_params with
4625 nb_params_in_scop.
4626
4627 * graphite.h (nb_params_in_scop): ... here.
4628 (scop_nb_params): Removed.
4629 (loop_domain_dim): Return something even when the loop was not
4630 found in the hash table: avoid ICEing on all the graphite.exp
4631 testcases.
4632
46332008-04-14 Konrad Trifunovic <konrad.trifunovic@inria.fr>
4634
4635 * tree-chrec.c (for_each_scev_op): SCEV can have 3 operands.
4636
4637 * graphite.c (build_scop_dynamic_schedules): Schedule is built
4638 according to nesting level.
4639 (find_scop_parameters): Call instantiate_parameters.
4640 (scan_tree_for_params): Extend it to handle general affine bounds.
4641 Inner loop bound can depend on outer loop induction variable.
4642 (setup_cloog_loop): tmp variable is allocated on stack. Call
4643 instantiate_parameters with respect to outermost_loop_in_scop.
4644 (loop_domain_dim, ref_nb_loops, loop_iteration_vector_dim): moved to
4645 graphite.h.
4646 (create_empty_loop): Function loopify should be given edge
4647 probability, instead of edge frequency. Dominance relation from
4648 switch_bb to loop_header.
4649 (clast_to_gcc_expression): Added handling of clast_reduction node.
4650 (gloog): New functionality for removing old loop.
4651 (test_dependence): Factored out from build_rdg_all_levels.
4652 (build_rdg_all_levels): Dependence testing factored out to
4653 test_dependence function.
4654
4655 * graphite.h (struct graphite_bb): Extended with dynamic_schedule.
4656 (loop_domain_dim, ref_nb_loops, loop_iteration_vector_dim): Moved
4657 from graphite.c
4658
46592008-04-07 Sebastian Pop <sebastian.pop@amd.com>
4660
4661 * graphite.c (free_scop, param_index, initialize_cloog_names,
4662 nb_params_in_scop): Use name_tree map instead of just a tree
4663 for keeping track of the variable name associated to that tree.
4664 (create_empty_loop, gmp_cst_to_tree, clast_name_to_gcc,
4665 clast_to_gcc_expression, graphite_create_iv,
4666 graphite_loop_to_gcc_loop, graphite_cond_to_gcc_cond,
4667 graphite_stmt_to_gcc_stmt): New.
4668 (gloog): Call these.
4669 * graphite.h (struct name_tree): New.
4670 (struct scop): Use name_tree instead of tree for params.
4671 Store a vector of name_tree for new_ivs.
4672 (SCOP_NEWIVS): New.
4673 (scop_nb_params): Use name_tree instead of tree.
4674
46752008-04-05 Alexander Lamaison <awl03@doc.ic.ac.uk>
4676 Sebastian Pop <sebastian.pop@amd.com>
4677
4678 * tree-bounds.c: New.
4679 * tree-bounds.h: New.
4680 * tree-pass.h: Declare pass_bounds_early and pass_bounds_late.
4681 * passes.c: Schedule pass_bounds_early, pass_bounds_late.
4682 * builtins.c (expand_builtin_alloca): Add flag_bounds as for
4683 flag_mudflap.
4684 * gcc.c: Same.
4685 * toplev.c: Same.
4686 * c-cppbuiltin.c: Same.
4687 * c-pragma.c: Same.
4688 * common.opt: Same.
4689 * varasm.c: Same.
4690 * tree-outof-ssa.c: Same.
4691 * c-common.c: Same.
4692 * Makefile.in: Same.
4693
46942008-03-15 Antoniu Pop <antoniu.pop@gmail.com>
4695 Sebastian Pop <sebastian.pop@amd.com>
4696
4697 * tree-loop-distribution.c (remaining_stmts,
4698 upstream_mem_writes): Removed static variables.
4699 (copy_loop_before, create_bb_after_loop,
4700 mark_nodes_having_upstream_mem_writes, free_rdg_components,
4701 rdg_build_components, rdg_build_partitions,
4702 dump_rdg_partitions): Extern.
4703 (generate_loops_for_partition, generate_code_for_partition): Do not
4704 return a bool.
4705 (already_processed_vertex_p, predecessor_has_mem_write,
4706 mark_nodes_having_upstream_mem_writes, has_upstream_mem_writes,
4707 rdg_flag_all_uses, rdg_flag_uses, rdg_flag_vertex_and_dependent,
4708 rdg_flag_loop_exits, rdg_flag_similar_memory_accesses,
4709 build_rdg_partition_for_component, rdg_build_partitions, ldist_gen):
4710 Pass remaining_stmts and upstream_mem_writes as parameters.
4711 (rdg_component): Moved...
4712 (build_rdg_partition_for_component): Do not aggregate components when
4713 flag_streamize_loops is set.
4714 (gen_sequential_loops): New.
4715 (ldist_gen): Call gen_sequential_loops.
4716
4717 * tree-pass.h (pass_loop_streamization): Declared.
4718
4719 * omp-low.c (expand_omp_sections): Call add_bb_to_loop on created
4720 basic blocks when loops structures exist.
4721
4722 * builtin-types.def (BT_FN_VOID_PTR_PTR_INT): New.
4723
4724 * tree-ssa-loop-ivopts.c (expr_invariant_in_region_p): New.
4725
4726 * tree-parloops.c (take_address_of, eliminate_local_variables_1,
4727 eliminate_local_variables_stmt, eliminate_local_variables,
4728 separate_decls_in_loop_name, separate_decls_in_loop_stmt,
4729 separate_decls_in_loop, gen_parallel_loop): Make them work on a region
4730 of code delimited by two edges in the CFG.
4731 (separate_decls_in_loop_name): Renamed separate_decls_in_region_name.
4732 (separate_decls_in_loop_stmt): Renamed separate_decls_in_region_stmt.
4733 (separate_decls_in_loop): Renamed separate_decls_in_region. Isolate
4734 the case of parallelisation of reductions.
4735 (create_loop_fn): Extern.
4736 (create_omp_parallel_region): New.
4737
4738 * tree-data-ref.c (dump_data_dependence_relation): Don't call
4739 dump_data_reference for printing dra and drb.
4740 (create_rdg_edge_for_ddr, create_rdg_edges_for_scalar): Initialise
4741 RDGE_RELATION.
4742 (build_rdg): Don't call free_dependence_relations for the moment, as
4743 we attach dependence relations on each edge of the RDG.
4744 To be fixed later.
4745
4746 * tree-data-ref.h (rdg_component): ...here.
4747 (struct rdg_edge): New field ddr_p relation.
4748 (RDGE_RELATION): New.
4749 (create_bb_after_loop, copy_loop_before,
4750 mark_nodes_having_upstream_mem_writes, rdg_build_components,
4751 rdg_build_partitions, dump_rdg_partitions,
4752 free_rdg_components): Declared.
4753
4754 * omp-builtins.def (BUILT_IN_GOMP_STREAM_ALIGN_PUSH,
4755 BUILT_IN_GOMP_STREAM_ALIGN_POP): New.
4756
4757 * tree-loop-streamization.c: New.
4758
4759 * tree-flow.h (gather_blocks_in_sese_region, create_loop_fn,
4760 create_omp_parallel_region, expr_invariant_in_region_p): Declared.
4761
4762 * Makefile.in (tree-loop-streamization.o): Added to OBJS-common.
4763
4764 * tree-cfg.c (gather_blocks_in_sese_region): Extern.
4765
4766 * passes.c: Schedule pass_loop_streamization.
4767
47682008-03-08 Tobias Grosser <grosser@fmi.uni-passau.de>
4769
4770 * graphite.c (dot_all_scops_1): Fix formatting for difficult bbs and
4771 update comment.
4772
47732008-03-07 Tobias Grosser <grosser@fim.uni-passau.de>
4774
4775 * graphite.c (dot_all_scops): Update formatting.
4776 Bbs can now be part of more than one SCoP.
4777
47782008-03-04 Sebastian Pop <sebastian.pop@amd.com>
4779
4780 * graphite.c (new_loop_to_cloog_loop_str, setup_cloog_loop): Fix
4781 malloc problems.
4782 (loop_domain_dim): Check for unregistered toplev SCOP loop.
4783 * graphite.h (loop_to_cloog_loop): New.
4784
47852008-03-04 Konrad Trifunovic <konrad.trifunovic@inria.fr>
4786
4787 * graphite.c (loop_domain_dim, ref_nb_loops,
4788 loop_iteration_vector_dim): New.
4789 (build_access_matrix_with_af, build_access_matrix,
4790 initialize_dependence_polyhedron): Fixed for new matrix layout.
4791 No longer assume that all iteration domains are of the same
4792 dimensionality.
4793
47942008-03-02 Sebastian Pop <sebastian.pop@amd.com>
4795
4796 * tree-scalar-evolution.c (instantiate_parameters_1): An SSA_NAME
4797 defined in a loop at depth 0 is invariant.
4798 * tree-chrec.c (evolution_function_is_invariant_rec_p): Ditto.
4799 * tree-ssa-loop-ivopts.c (expr_invariant_in_loop_p): Should never
4800 be called at loop depth 0.
4801
4802 * graphite.c (basic_block_simple_for_scop_p): Take the scop as
4803 a parameter.
4804 (dot_all_scops_1): Update use of basic_block_simple_for_scop_p.
4805 (down_open_scop): Removed.
4806 (loop_in_scop_p): Redefined.
4807 (scop_affine_expr): New argument: scop.
4808 (stmt_simple_for_scop_p): New argument: scop. RETURN_EXPR is not
4809 a harmful statement ending a scop.
4810 (basic_block_simple_for_scop_p): New argument: scop.
4811 (get_loop_start): Removed.
4812 (new_scop): Initialize SCOP_LOOPS.
4813 (free_scop): Free SCOP_LOOPS.
4814 (succs_at_same_depth, preds_at_same_depth): New.
4815 (end_scop): Test the validity of a scop.
4816 (add_dominators_to_open_scops): New.
4817 (test_for_scop_bound): Call add_dominators_to_open_scops.
4818 Add cases for opening and closing multiple scops.
4819 (build_scops, build_scop_bbs): Iterate over basic blocks in
4820 depth first order.
4821 (build_graphite_bb): Pass scop directly.
4822 (dfs_bb_in_scop_p): New.
4823 (scop_record_loop): Use SCOP_LOOPS for not recording the same loop
4824 several times.
4825 (nb_loops_around_gb): Use loop_in_scop_p.
4826 (schedule_to_scattering): Disabled for the moment the code computing
4827 the "textual order for outer loop".
4828
4829 * graphite.h (struct scop): New field loops.
4830 (SCOP_LOOPS): New.
4831 (scop_loop_index): Test that the given loop belongs to SCOP_LOOPS.
4832
4833 * testsuite/gcc.dg/graphite/scop-{1,...,7}.c: Updated.
4834
48352008-02-27 Antoniu Pop <antoniu.pop@gmail.com>
4836 Sebastian Pop <sebastian.pop@amd.com>
4837
4838 * builtin-types.def (BT_FN_PTR_SIZE_UINT, BT_FN_BOOL_PTR): New.
4839 * common.opt (fstreamize-loops): New.
4840 * omp-builtins.def (BUILT_IN_GOMP_STREAM_CREATE,
4841 BUILT_IN_GOMP_STREAM_PUSH, BUILT_IN_GOMP_STREAM_HEAD,
4842 BUILT_IN_GOMP_STREAM_POP, BUILT_IN_GOMP_STREAM_EOS_P,
4843 BUILT_IN_GOMP_STREAM_SET_EOS, BUILT_IN_GOMP_STREAM_DESTROY): New.
4844
48452008-02-22 Konrad Trifunovic <konrad.trifunovic@inria.fr>
4846
4847 * tree-data-ref.c (build_empty_rdg): New.
4848 (build_rdg): Use it.
4849 * tree-data-ref.h (build_empty_rdg): Declared.
4850 * graphite.c (free_scop): Free SCOP_LOOP2CLOOG_LOOP.
4851 (find_vertex_for_stmt): Removed.
4852 (build_rdg_all_levels): Use build_empty_rdg and rdg_vertex_for_stmt.
4853
48542008-02-21 Sebastian Pop <sebastian.pop@amd.com>
4855
4856 * tree-loop-distribution.c (generate_builtin): After cancelling the
4857 loop tree, also delete basic blocks.
4858 (rdg_flag_uses): Stop recursion when a vertex has already been
4859 processed.
4860
48612008-02-15 Konrad Trifunovic <konrad.trifunovic@inria.fr>
4862
4863 * graphite.c (build_scop_alpha): Removed.
4864 (graphite_transform_loops): Add a dummy call to build_all_rdg_levels
4865 and dump_dependence_graph to avoid compiler warnings.
4866
48672008-02-14 Konrad Trifunovic <konrad.trifunovic@inria.fr>
4868
4869 * tree-data-ref.c (dr_may_alias_p, create_rdg_vertices): Extern.
4870 * tree-data-ref.h (dr_may_alias_p, create_rdg_vertices): Declared.
4871 * graphite.c (new_loop_to_cloog_loop_str, hash_loop_to_cloog_loop,
4872 eq_loop_to_cloog_loop, del_loop_to_cloog_loop): New.
4873 (new_scop, setup_cloog_loop): Initialize SCOP_LOOP2CLOOG_LOOP.
4874 (initialize_dependence_polyhedron, find_vertex_for_stmt,
4875 initialize_data_dependence_polyhedron, is_empty_polyhedron,
4876 statement_precedes_p, build_rdg_all_levels, build_scop_alpha,
4877 dump_dependence_graph): New.
4878 * graphite.h (struct graphite_bb): New field compressed_alpha_matrix.
4879 (GBB_ALPHA): New.
4880 (struct scop): New field loop2cloog_loop.
4881 (SCOP_LOOP2CLOOG_LOOP, struct data_dependence_polyhedron,
4882 RDGE_DDP, ddp_p, struct loop_to_cloog_loop_str): New.
4883
48842008-02-10 Konrad Trifunovic <konrad.trifunovic@inria.fr>
4885
4886 * graphite.c (build_graphite_bb): Fix initialization
4887 of the graphite basic block.
4888
48892008-02-05 Sebastian Pop <sebastian.pop@amd.com>
4890
4891 * graphite.c (scan_tree_for_params): Rewrite for the new layout of
4892 loop domain matrix. Pass in the number of loops contained in the
4893 constraint matrix.
4894 (nb_loops_around_gb): Moved before setup_cloog_loop that uses it.
4895 (setup_cloog_loop): Rewrite for the new layout of loop domain matrix:
4896 loops that are not surrounding the current loop are not represented
4897 in the domain constraint matrix.
4898 (build_scop_iteration_domain): Initial domain constraint matrix
4899 contains only the eq/ineq, cst, and scop parameters columns.
4900
49012008-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
4902
4903 * graphite.c (schedule_to_scattering, nb_loops_around_gb): New.
4904 (print_graphite_bb): Print scattering.
4905
49062008-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
4907
4908 * graphite.c (initialize_cloog_names): Initialize names of
4909 scattering variables.
4910
49112009-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
4912
4913 * graphite.c (dot_all_scops_1): Disable debug output while
4914 printing graph.
4915
49162008-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
4917
4918 * graphite.c (find_transform): Change cloog output language to C.
4919
49202008-01-27 Sebastian Pop <sebastian.pop@amd.com>
4921
4922 * tree-loop-distribution.c (generate_memset_zero,
4923 generate_builtin, generate_code_for_partition,
4924 rdg_flag_all_uses): New.
4925 (rdg_flag_uses): Gather in the same partition the statements defining
4926 the VUSES of the current statement.
4927 (rdg_flag_similar_stores): Renamed rdg_flag_similar_memory_accesses.
4928 Gather in the same partition not only the stores to the same memory
4929 access, but also the reads.
4930 (ldist_generate_loops): Renamed ldist_gen.
4931
49322008-01-24 Sebastian Pop <sebastian.pop@amd.com>
4933 Tobias Grosser <grosser@fmi.uni-passau.de>
4934
4935 * graphite.c (setup_cloog_loop): Chain all cloog loops with the
4936 next pointer, don't use the inner pointer.
4937
49382008-01-20 Tobias Grosser <grosser@fmi.uni-passau.de>
4939
4940 * graphite.c (dot_all_scops, dot_all_scops_1): New.
4941 (find_transform): Call dot_all_1.
4942 * graphite.h (dot_all_scops): Declared.
4943
49442007-12-14 Sebastian Pop <sebastian.pop@amd.com>
4945
4946 * tree-loop-distribution.c: Fix apsi.f ICE.
4947 (create_bb_after_loop): New.
4948 (generate_loops_for_partition): Use it.
4949 * testsuite/gfortran.dg/ldist-1.f90: New.
4950
4951 * tree-data-ref.c (dot_rdg): Use /tmp/rdg.dot for dotty format.
4952 * graphite.c (dot_scop): Use /tmp/scop.dot for dotty format.
4953
49542007-12-13 Tobias Grosser <grosser@fmi.uni-passau.de>
4955
4956 * graphite.c (find_transform): Dump cloog program sent to cloog.
4957
49582007-12-13 Tobias Grosser <grosser@fmi.uni-passau.de>
4959
4960 * graphite.c (initialize_cloog_names): Initialize cloog
4961 iterator names.
4962
49632007-12-13 Tobias Grosser <grosser@fmi.uni-passau.de>
4964
4965 * graphite.c (build_scop_context): Fix typo, for the matrix
4966 format: insert '0 >= 0' instead of '-1 >= 0'.
4967
49682007-12-13 Sebastian Pop <sebastian.pop@amd.com>
4969
4970 * Fix merge problems.
4971
49722007-12-13 Sebastian Pop <sebastian.pop@amd.com>
4973
4974 * graphite.c (setup_cloog_loop): Fix typo.
4975
49762007-12-12 Sebastian Pop <sebastian.pop@amd.com>
4977
4978 * doc/invoke.texi (-ftree-loop-distribution): Documented.
4979 * tree-loop-distribution.c: Reimplemented.
4980 * tree-pass.h (pass_loop_distribution): New.
4981 * tree-scalar-evolution.c (number_of_iterations_for_all_loops): Use
4982 print_loops.
4983 * graphds.h (struct graph): New field indexes.
4984 * timevar.def (TV_TREE_LOOP_DISTRIBUTION): New.
4985
4986 * tree-vect-analyze.c: Remove declaration of static functions when not
4987 needed.
4988 * tree-vectorizer.c: Same.
4989 (rename_variables_in_loop): Now extern.
4990 (slpeel_tree_duplicate_loop_to_edge_cfg): Renamed
4991 tree_duplicate_loop_to_edge_cfg. Reset PENDING_STMT for edges after
4992 calling redirect_edge_and_branch_force.
4993
4994 * tree-vectorizer.h (tree_duplicate_loop_on_edge): Declared.
4995
4996 * tree-data-ref.c: Don't include tree-chrec.h.
4997 (debug_data_dependence_relations): New.
4998 (dump_data_dependence_relation): Call dump_data_reference on data refs
4999 in the relation.
5000 (same_access_functions): Moved...
5001 (find_vertex_for_stmt): Renamed rdg_vertex_for_stmt.
5002 (dump_rdg_vertex, debug_rdg_vertex, dump_rdg_component,
5003 debug_rdg_component, dump_rdg, debug_rdg, dot_rdg_1, dot_rdg,
5004 struct rdg_vertex_info, ): New.
5005 (create_rdg_edge_for_ddr): Compute the dependence level before looking
5006 at DDR_REVERSED_P.
5007 (create_rdg_vertices): Initialize the htab of graph->indexes.
5008 Initialize RDG_MEM_WRITE_STMT and RDG_MEM_READS_STMT.
5009 (stmts_from_loop): Don't save LABEL_EXPR.
5010 (hash_stmt_vertex_info, eq_stmt_vertex_info,
5011 hash_stmt_vertex_del): New.
5012 (build_rdg): Initialize rdg->indexes.
5013 (free_rdg, stores_from_loop, ref_base_address,
5014 rdg_defs_used_in_other_loops_p, have_similar_memory_accesses,
5015 have_similar_memory_accesses_1, ref_base_address_1,
5016 remove_similar_memory_refs): New.
5017
5018 * tree-data-ref.h: Include tree-chrec.h.
5019 (debug_data_dependence_relations): Declared.
5020 (same_access_functions): ...here. Now static inline.
5021 (ddr_is_anti_dependent, ddrs_have_anti_deps,
5022 ddr_dependence_level): New.
5023 (struct rdg_vertex): New fields has_mem_write, has_mem_reads.
5024 (RDGV_HAS_MEM_WRITE, RDGV_HAS_MEM_READS, RDG_STMT, RDG_MEM_WRITE_STMT,
5025 RDG_MEM_READS_STMT): New.
5026 (dump_rdg_vertex, debug_rdg_vertex, dump_rdg_component,
5027 debug_rdg_component, dump_rdg, debug_rdg, dot_rdg,
5028 rdg_vertex_for_stmt): Declared.
5029 (struct rdg_edge): New field level.
5030 (RDGE_LEVEL, free_rdg): New.
5031 (stores_from_loop, remove_similar_memory_refs,
5032 rdg_defs_used_in_other_loops_p,
5033 have_similar_memory_accesses): Declared.
5034 (rdg_has_similar_memory_accesses): New.
5035
5036 * lambda.h (dependence_level): New.
5037 * common.opt (ftree-loop-distribution): New.
5038 * tree-flow.h (debug_loop_ir): Renamed debug_loops.
5039 (print_loop_ir): Renamed print_loops.
5040 (debug_loop, debug_loop_num, print_loops_bb, mark_virtual_ops_in_bb,
5041 tree_duplicate_loop_to_edge_cfg, rename_variables_in_loop): Declared.
5042 * Makefile.in (TREE_DATA_REF_H): Depends on tree-chrec.h.
5043 (tree-loop-distribution.o): Added.
5044 * tree-cfg.c (mark_virtual_ops_in_region): Use mark_virtual_ops_in_bb.
5045 (mark_virtual_ops_in_bb): New.
5046 (print_loops_bb, debug_loop_num, debug_loop): New.
5047 * passes.c: Scheduled pass_loop_distribution.
5048
50492007-12-12 Konrad Trifunovic <konrad.trifunovic@inria.fr>
5050
5051 * graphite.c (scan_tree_for_params): Correct the number of columns
5052 for polylib format.
5053 (nb_flat_iterator): New.
5054 (setup_cloog_loop): Initialize to 1 the first column for inequalities.
5055 (build_scop_iteration_domain): Correct the number of columns for
5056 polylib format.
5057
50582007-12-12 Sebastian Pop <sebastian.pop@amd.com>
5059
5060 * Merge from mainline (129697:130800).
5061
50622007-10-30 Sebastian Pop <sebastian.pop@amd.com>
5063
5064 * graphite.c (build_graphite_bb): SCoP's basic blocks are post
5065 dominated by SCoP's exit.
5066 (graphite_transform_loops): Compute post dominators.
5067
50682007-10-28 Sebastian Pop <sebastian.pop@amd.com>
5069
5070 * Merge from mainline (127169:129697).
5071
50722007-10-28 Sebastian Pop <sebastian.pop@amd.com>
5073
5074 * graphite.c (affine_expr): Renamed scop_affine_expr. Use an extra
5075 parameter for the basic block that contains the expression. Use
5076 outermost_loop_in_scop for evolution_function_is_affine_multivariate_p.
5077 (stmt_simple_for_scop_p): Pass to scop_affine_expr the basic block of
5078 the expression.
5079 * graphite.h (gbb_loop): New.
5080 (GBB_LOOP): Removed.
5081
50822007-08-03 Sebastian Pop <sebpop@gmail.com>
5083
5084 * Makefile.in: Fix merge problem.
5085
50862007-08-03 Sebastian Pop <sebpop@gmail.com>
5087
5088 * Merge from mainline (125309:127169).
5089 * tree-loop-distribution.c: Disabled.
5090
50912007-06-05 Sebastian Pop <sebpop@gmail.com>
5092
5093 * Merge from mainline (r123693:125309).
5094
50952007-05-30 Sebastian Pop <sebpop@gmail.com>
5096
5097 * tree-loop-distribution.c (correct_modify_expr_p): Renamed
5098 correct_modify_p
5099 (correct_modify_p, check_statements, number_of_lvalue_uses,
5100 number_of_scalar_dependences, create_edges): Use GIMPLE_MODIFY_STMT
5101 instead of MODIFY_EXPR.
5102 (update_edge_with_ddv): Don't pass index_of_edge. Initialize
5103 and push new edges.
5104
51052007-05-24 Sebastian Pop <sebpop@gmail.com>
5106
5107 * tree-loop-distribution.c (struct rdg): Replace arrays by
5108 VECs for edges and vertices.
5109 (RDG_NBV, RDG_NBE, RDG_VERTEX, RDG_EDGE): Removed.
5110 (RDGV_NB_PARTITIONS): New.
5111 (PRDG_NBV, PRDG_NBE): Removed.
5112 (build_scc_graph, correct_partitions_p, mark_partitions, build_prdg,
5113 dump_rdg, find_vertex_with_stmt, create_vertices, free_rdg,
5114 number_of_scalar_dependences, create_edges, build_rdg): Use VECs.
5115
51162007-05-17 Georges-Andre Silber <silber@cri.ensmp.fr>
5117 Sebastian Pop <sebpop@gmail.com>
5118
5119 * doc/invoke.texi (-ftree-loop-distribution): Document.
5120 * tree-loop-distribution.c: New file.
5121 * tree-pass.h (pass_loop_distribution): Declared.
5122 * timevar.def (TV_TREE_LOOP_DISTRIBUTION): New.
5123 * tree-data-ref.c (initialize_data_dependence_relation): Initialize
5124 and set reversed_p.
5125 * tree-data-ref.h (data_dependence_relation): Add reversed_p.
5126 (DDR_REVERSED_P): New.
5127 * common.opt (-ftree-loop-distribution): New.
5128 * tree-flow.h (distribute_loops): Declared.
5129 * Makefile.in (OBJS-common): Depend on tree-loop-distribution.o.
5130 * passes.c (init_optimization_passes): Schedule loop distribution.
5131
51322007-05-12 Sebastian Pop <sebastian.pop@inria.fr>
5133
5134 * graphite.c (print_graphite_bb): Don't call dump_data_references.
5135 (print_scop): Don't print when scop is NULL.
5136 (build_scop_context, find_transform): Don't output to stderr.
5137
51382007-05-09 Sebastian Pop <sebastian.pop@inria.fr>
5139
5140 * tree-data-ref.c: Don't include graphite.h.
5141 Comment out the code for printing data reference's scop.
5142 (build_access_matrix_with_af): Moved...
5143 * tree-data-ref.h (build_access_matrix_with_af): Removed declaration.
5144 * graphite.c (build_access_matrix_with_af): ... here. Now static.
5145 (print_graphite_bb): Print basic block's schedule.
5146 (print_scop): Don't print the schedule, call cloog's pretty printer.
5147 (bb_in_scop_p): A basic block is in a scop only if it is both
5148 dominated and postdominated by the scop's entry and exit basic blocks.
5149 (function_parameter_p): New.
5150 (invariant_in_scop_p): Use function_parameter_p.
5151 (new_scop, save_scop): New.
5152 (end_scop, test_for_scop_bound, build_scops): Use new_scop, and
5153 save_scop.
5154 (scan_tree_for_params): Directly build the constraint as CloogMatrix.
5155 (loop_in_scop_p): New.
5156 (scop_record_loop): Use loop_in_scop_p.
5157 (build_scop_domain): Renamed build_scop_iteration_domain.
5158 (setup_cloog_loop, initialize_cloog_names, find_scop_parameters,
5159 nb_params_in_scop, build_scop_context, first_loop_in_scop,
5160 setup_cloog_loop, dot_scop_1, dot_scop): New.
5161 * graphite.h (GBB_LOOP, SCOP_PROG, dot_scop): New.
5162 (struct scop): Add a pointer to cloog's representation of a program.
5163
51642007-04-14 Sebastian Pop <sebastian.pop@inria.fr>
5165
5166 * doc/invoke.texi (-ftree-check-verbose): Renamed
5167 -ftree-checks-verbose.
5168 * common.opt (flag_tree_check_verbose): Renamed
5169 flag_tree_checks_verbose.
5170 * tree-check.c (tree_check_warning): Use flag_tree_checks_verbose.
5171
51722007-04-14 Sebastian Pop <sebastian.pop@inria.fr>
5173
5174 * configure: Regenerated.
5175 * config.in: Regenerated.
5176 * tree-ssa-loop.c (graphite_transforms): Execute
5177 graphite_transform_loops only when HAVE_cloog.
5178 * configure.ac (HAVE_polylib, HAVE_cloog, GRAPHITE): Defined.
5179 * graphite.c: Include polylibgmp.h and cloog.h.
5180 (graphite_transform_loops): Removed loops parameter.
5181 * tree-flow.h (graphite_transform_loops): Update declaration.
5182 * Makefile.in (POLYLIBLIBS, POLYLIBINC, CLOOGLIBS, CLOOGINC): New.
5183 (LIBS): Depend on CLOOGLIBS and on POLYLIBLIBS.
5184 (INCLUDES): Depend on POLYLIBINC and on CLOOGINC.
5185 (OBJS-common): Remove dependence on graphite.o.
5186 (BACKEND): Depend on @GRAPHITE@.
5187
51882007-04-13 Sebastian Pop <sebastian.pop@inria.fr>
5189
5190 * doc/invoke.texi (-ftree-check-verbose): Documented.
5191 * testsuite/gcc.dg/tree-checker/tree-checks-1.c: New.
5192 * testsuite/gcc.dg/tree-checker/tree-checks-2.c: New.
5193 * testsuite/gcc.dg/tree-checker/tree-checks-3.c: New.
5194 * testsuite/gcc.dg/tree-checker/tree-checks-4.c: New.
5195 * testsuite/gcc.dg/tree-checker/tree-checks.exp: New.
5196 * testsuite/gcc.dg/tree-checker/condates.crp: New.
5197 * common.opt (ftree-checks-verbose): New.
5198 * tree-check.c (tree_check_warning): Move extra stderr output
5199 under control of flag_tree_check_verbose.
5200
52012007-04-12 Sebastian Pop <sebastian.pop@inria.fr>
5202
5203 * tree-match.c: Fix comments formatting.
5204 * tree-match.h: Fix comments formatting.
5205 * tree-check.c: Fix comments formatting.
5206 (tree_check_init): Restructure.
5207
52082007-04-12 Nic Volanschi <nic.volanschi@free.fr>
5209
5210 * doc/invoke.texi (-ftree-check, -ftree-checks): Documented.
5211
52122007-04-10 Sebastian Pop <sebastian.pop@inria.fr>
5213
5214 * Merge from mainline (r120733:123693).
5215
52162007-03-20 Nic Volanschi <nic.volanschi@free.fr>
5217
5218 * condate.y: New file.
5219 * tree-match.h (struct patt_info_s): New field sign.
5220 (struct condate_s): New field msg.
5221 (normalize_condate, name_condate, add_condate): New.
5222 (conds[], condate_parse): Made extern.
5223 * tree-check.c (tree_check_warning): First arg changed to cond;
5224 warning reformatted.
5225 (tree_check_init): Reset the TREE_VISITED bit on every CFG node.
5226 (tree_scan): New.
5227 (tree_check): Process trivial condates.
5228 (read_delimited_string): Removed.
5229 (print_cond): Print name and msg.
5230 (conds[]): Made extern.
5231 (parse_tree_check_file_once): Rewritten to use the parser in
5232 condate.y.
5233 Processing of option --tree_check_string moved to tree_scan().
5234 * Makefile.in: Added condate.y
5235
52362007-03-12 Sebastian Pop <sebastian.pop@inria.fr>
5237
5238 * tree-pretty-print.c (dump_generic_bb_buff, lazy_dump_generic_node):
5239 Use VECs instead of varrays.
5240 * diagnostic.h (lazy_dump_generic_node): Update declaration.
5241 * Makefile.in (pretty-print.o): Depend on vec.h.
5242 * pretty-print.c: Include tree.h and vec.h.
5243 (pp_clear_state, pp_write_list_to_stream, pp_base_format,
5244 pp_base_format, pp_construct, pp_base_string, pp_lazy_mode,
5245 new_tree_chunk, pp_add_tree, pp_add_string, pp_add_char, pp_write_list,
5246 pp_free_list): Use VECs instead of varrays.
5247 * pretty-print.h: Do not include varray.h.
5248 (struct tree_chunk_s): Declaration moved before its use.
5249 (output_buffer): Rename varray field to chunks.
5250 * tree-match.c (tree_equal, chunk_1st_char, chunks_lookahead,
5251 tree_1st_char, match_chunks_pattinfo, match_tree_pattinfo,
5252 save_global_holes): Use VECs instead of varrays.
5253 * tree-match.h: Declare VECs of cfg_node, and hole_p.
5254 * tree-check.c (scan_cfg_stmts, push_node,
5255 print_matching_stmt): Removed.
5256 (tree_check_instance, push_global_holes_if_new, tree_check,
5257 execute_tree_check): Use VECs instead of varrays.
5258 (gate_tree_check): Don't execute the CFG check when basic_block_info
5259 is not available.
5260
52612007-01-12 Sebastian Pop <sebastian.pop@inria.fr>
5262
5263 * Merge from mainline (r115016:120733).
5264
52652007-01-12 Sebastian Pop <sebastian.pop@inria.fr>
5266
5267 * Merge from mainline (r117632:117661).
5268
52692007-01-12 Sebastian Pop <sebastian.pop@inria.fr>
5270
5271 * tree-dump.c (dump_option_value_in): Add TDF_DEBUG.
5272 * tree-pass.h (TDF_DEBUG, debug_p): New.
5273 * tree-scalar-evolution.c (set_scalar_evolution, get_scalar_evolution,
5274 get_scalar_evolution, add_to_evolution, set_nb_iterations_in_loop,
5275 get_loop_exit_condition, analyze_evolution_in_loop,
5276 analyze_initial_condition, analyze_scalar_evolution,
5277 instantiate_parameters, number_of_latch_executions): Use debug_p.
5278 * tree-chrec.c (chrec_apply): Use debug_p.
5279 * tree-data-ref.c: Include graphite.h.
5280 (dump_data_reference): Print also the access matrix.
5281 (analyze_array, analyze_indirect_ref, init_data_ref,
5282 analyze_offset_expr, address_analysis, object_analysis,
5283 create_data_ref, finalize_ddr_dependent,
5284 non_affine_dependence_relation, analyze_ziv_subscript,
5285 analyze_siv_subscript_cst_affine,
5286 compute_overlap_steps_for_affine_1_2, analyze_subscript_affine_affine,
5287 can_use_analyze_subscript_affine_affine, analyze_siv_subscript,
5288 analyze_miv_subscript, analyze_overlapping_iterations,
5289 build_classic_dist_vector, subscript_dependence_tester,
5290 compute_affine_dependence, analyze_all_data_dependences): Use debug_p.
5291 (build_access_matrix_with_af): No longer static.
5292 * tree-data-ref.h (scop_p): ... declaration here.
5293 (data_reference.scop): New field.
5294 (DR_SCOP, DR_ACCESS_MATRIX): New.
5295 (build_access_matrix_with_af, dr_num_subscripts): Declared.
5296 * graphite.c (print_graphite_bb): Call dump_data_references.
5297 (print_scop): Use scop_nb_loops and scop_dim_domain.
5298 (test_for_scop_bound): Use debug_p.
5299 (scan_tree_for_params): Use scop_nb_loops, scop_nb_loops and
5300 scop_nb_params.
5301 (scop_loop_index): Moved...
5302 (scop_record_loop): New.
5303 (build_scop_loop_nests): Use scop_record_loop.
5304 (build_scop_domain): Use scop_dim_domain.
5305 (build_access_matrix): Implemented.
5306 (build_scop_canonical_schedules): Use scop_nb_loops.
5307 (build_graphite_bb): Initialize GBB_SCOP.
5308 * graphite.h (scop_p): Moved...
5309 (graphite_bb.scop): New field.
5310 (graphite_bb.iteration_domain, GBB_DOMAIN, scop.nb_params,
5311 scop.nb_loops, scop.dim_domain, SCOP_NB_LOOPS, SCOP_NB_PARAMS,
5312 SCOP_DIM_DOMAIN, SCOP_STMTS): Removed.
5313 (scop_nb_params, scop_nb_loops, scop_dim_domain, gbb_dim_domain,
5314 scop_loop_index): New.
5315 * Makefile.in (tree-data-ref.o): Depends on graphite.h.
5316
53172007-01-05 Sebastian Pop <sebastian.pop@inria.fr>
5318
5319 * Merge from mainline (r117661:120450).
5320
53212006-10-12 Sebastian Pop <sebastian.pop@inria.fr>
5322
5323 * tree-scalar-evolution.c (instantiate_parameters_1): Don't stop
5324 at the first declaration outside the varying loop, instantiate as
5325 far as possible.
5326 * tree-chrec.c (for_each_scev_op): New.
5327 * tree-chrec.h (for_each_scev_op): Declared.
5328 * tree-ssa-loop.c (pass_graphite_trans): Don't dump the function.
5329 * tree-data-ref.c (get_references_in_stmt,
5330 find_data_references_in_stmt): New, from trunk.
5331 (find_data_references_in_loop): Use get_references_in_stmt
5332 and find_data_references_in_loop, modified as in trunk.
5333 (build_access_matrix_with_af): New.
5334 * tree-data-ref.h (data_reference): Add a field access_matrix.
5335 (data_ref_loc): New, as in trunk.
5336 * graphite.c (print_graphite_bb, bb_in_scop_p, stmt_in_scop_p,
5337 invariant_in_scop_p, param_index, scan_tree_for_params,
5338 scop_loop_index, build_scop_loop_nests, build_scop_domain, irp_data,
5339 idx_record_param, idx_record_params, build_access_matrix,
5340 build_scop_data_accesses, build_scop_canonical_schedules,
5341 build_graphite_bb, build_scop_bbs, find_params_in_bb,
5342 build_scop_params): New.
5343 * graphite.h (graphite_bb): New.
5344 (scop): Add fields static_schedule, params, loop_nest,
5345 iteration_domain.
5346 * lambda.h: Declare vecs of lambda_matrix.
5347 * tree-flow.h (print_loop_ir_bb): Declared.
5348 * tree-cfg.c (print_loop_ir_bb): New.
5349 (print_loop): Use print_loop_ir_bb.
5350
53512006-10-12 Sebastian Pop <pop@cri.ensmp.fr>
5352
5353 * Merge from mainline (r115016:117632).
5354
53552006-10-11 Sebastian Pop <pop@cri.ensmp.fr>
5356
5357 * graphite.c (debug_scops): Adjust definition for avoiding a bootstrap
5358 break due to a warning.
5359
53602006-10-10 Sebastian Pop <pop@cri.ensmp.fr>
5361
5362 * graphite.c (print_scops, debug_scops): New.
5363 (graphite_transform): Renamed graphite_find_transform.
5364 * graphite.h (debug_scops): Declared.
5365
53662006-08-17 Sebastian Pop <pop@cri.ensmp.fr>
5367
5368 * tree-match.c: Reformat following the GNU style.
5369 * tree-match.h: Reformat following the GNU style.
5370 * tree-pattern.h: Removed empty file.
5371 * Makefile.in: Remove references to tree-pattern.h.
5372 * tree-check.c: Reformat following the GNU style.
5373 (execute_tree_check): Move gate condition code to...
5374 (gate_tree_check): ...here. New function.
5375 (pass_check): Use the gate function.
5376
53772006-07-04 Nic Volanschi <nic.volanschi@free.fr>
5378
5379 * tree-pattern.h: New. Tree pattern matching and checking using
5380 concrete syntax.
5381 * tree-check.c: New. Tree/CFG checking pass.
5382 * tree-match.c: New. Library for tree pattern matching.
5383 * opts.c, common.opt: Add options --ftree-check & --ftree-checks.
5384 * toplev.c, flags.h: Add globals for tree-check pass.
5385 * Makefile.in: Integrate the files in tree-check pass.
5386 * timevar.def, tree-optimize.c, tree-pass.h: Register tree-check pass.
5387 * pretty-print.c, pretty-print.h, tree-pretty-print.c, diagnostic.h:
5388 Introduce a "lazy" pretty-print mode.
5389 * tree.c, tree.h: Add tree_name.
5390
53912006-07-04 Sebastian Pop <pop@cri.ensmp.fr>
5392
5393 * doc/invoke.texi (-fgraphite): Correct typo.
5394 * tree-scalar-evolution.c (number_of_iterations_for_all_loops): Update
5395 use of print_loop_ir.
5396 * testsuite/gcc.dg/graphite/scop-1.c: New.
5397 * testsuite/gcc.dg/graphite/scop-2.c: New.
5398 * testsuite/gcc.dg/graphite/graphite.exp: New.
5399 * graphite.c: Include domwalk.h.
5400 (print_scop): Print only the entry and exit blocks.
5401 (debug_scop): No longer static.
5402 (affine_expr): Fix formating. Return also true when the expression is
5403 constant.
5404 (stmt_simple_for_scop_p): Fix formating.
5405 (build_scops): Use domwalk.
5406 (get_loop_start, end_scop, test_for_scop_bound): New.
5407 (graphite_transform_loops): Avoid printing on stderr.
5408 * graphite.h (debug_scop): Declared.
5409 * tree-flow.h (debug_loop_ir, print_loop_ir): Update declarations.
5410 * Makefile.in (graphite.o): Depend on domwalk.h.
5411 * tree-cfg.c (print_loop, print_pred_bbs, print_succ_bbs): Remove
5412 declarations for static functions.
5413 (print_loop, print_loop_ir, debug_loop_ir): Use an extra parameter for
5414 controlling output verbosity.
5415
54162006-06-26 Sebastian Pop <pop@cri.ensmp.fr>
5417 Plesco Alexandru <shurikx@gmail.com>
5418
5419 * doc/invoke.texi (-fgraphite): Document.
5420 * tree-pass.h (pass_graphite_transforms): Declared.
5421 * timevar.def (TV_GRAPHITE_TRANSFORMS): New.
5422 * tree-ssa-loop.c (graphite_transforms, gate_graphite_transforms): New.
5423 (pass_graphite_transforms): Defined.
5424 * tree-data-ref.c (free_data_ref, data_reference): Extern.
5425 * tree-data-ref.h (free_data_ref, data_reference): Declared.
5426 * graphite.c, graphite.h: New.
5427 * common.opt (fgraphite): Declared.
5428 * tree-flow.h (graphite_transform_loops): Declared.
5429 * Makefile.in (OBJS-common): Add graphite.o.
5430 (graphite.o): New rule.
5431 * passes.c (pass_graphite_transforms): Scheduled.
5432
This page took 0.512029 seconds and 5 git commands to generate.