]> git.ipfire.org Git - thirdparty/gcc.git/blame - gcc/ChangeLog.graphite
2009-10-14 Tobias Grosser <grosser@fim.uni-passau.de>
[thirdparty/gcc.git] / gcc / ChangeLog.graphite
CommitLineData
4d6599d0 12009-10-14 Tobias Grosser <grosser@fim.uni-passau.de>
2
3 * testsuite/gcc.dg/graphite/id-15.c: (8 * 8) replaced with
4 sizeof(unsigned long) to make it run on 32bit systems.
5
62009-10-14 Tobias Grosser <grosser@fim.uni-passau.de>
7
8 * testsuite/gcc.dg/graphite/run-id-1.c: Use smaller matrix to not
9 SEGFAULT on 32bit.
10
96233858 112009-10-14 Ramakrishna Upadrasta <Ramakrishna.Upadrasta@inria.fr>
12
4d6599d0 13 * graphite-sese-to-poly.c (write_alias_graph_to_ascii_dimacs): Fix
14 Comment.
96233858 15 (write_alias_graph_to_ascii_dot): New.
16 (write_alias_graph_to_ascii_ecc): Ditto.
4d6599d0 17 (partition_drs_to_sets): Add testing of optimality of current method
18 which assigns alias numbers according to DFS Comopnent number. used
19 as heuristic for the upcoming ECC algorithm.
96233858 20 (build_scop_drs): Write to file also with the ecc and dot format.
21
8eedbd74 222009-10-13 Sebastian Pop <sebastian.pop@amd.com>
23
24 * gfortran.dg/graphite/interchange-1.f: XFail.
25
ef98ee10 262009-10-13 Sebastian Pop <sebastian.pop@amd.com>
27
28 * graphite.c (graphite_initialize): Do not handle functions with
29 more than 100 basic blocks.
30
b8ad26cc 312009-10-13 Sebastian Pop <sebastian.pop@amd.com>
32
33 * graphite-blocking.c (pbb_do_strip_mine): Use
34 PARAM_LOOP_BLOCK_TILE_SIZE.
35
4938b827 362009-10-13 Sebastian Pop <sebastian.pop@amd.com>
37
38 * graphite-poly.c (dot_lst_1): New.
39 (dot_lst): New.
40 * graphite-poly.h (dot_lst): Declared.
41
a7d089ac 422009-10-13 Sebastian Pop <sebastian.pop@amd.com>
43
44 * graphite-dependences.c (dot_deps_stmt_1): New.
45 (dot_deps_stmt): New.
46 * graphite-dependences.h (dot_deps_stmt): Declared.
47
dd27e8aa 482009-10-09 Sebastian Pop <sebastian.pop@amd.com>
49
50 * graphite-sese-to-poly.c (rewrite_cross_bb_scalar_dependence): Do
51 not replace cross BB scalar dependences ending on PHI nodes.
52 (rewrite_cross_bb_scalar_deps): Filter out GIMPLE_PHI nodes.
53
dbe2e816 542009-10-09 Sebastian Pop <sebastian.pop@amd.com>
55
56 * graphite-poly.c (apply_poly_transforms): Implement the high
57 level driver for flag_loop_block.
58 * tree-ssa-loop.c (gate_graphite_transforms): Remove call to sorry for
59 flag_loop_block.
60
61 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK): Add
62 -floop-block.
63 * gfortran.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK):
64 Add -floop-block.
65
89d077e8 662009-10-09 Sebastian Pop <sebastian.pop@amd.com>
67
68 * graphite-poly.h (lst_find_pbb): New.
69 (find_lst_loop): New.
70
220b380e 712009-10-09 Sebastian Pop <sebastian.pop@amd.com>
72
73 * graphite-poly.c (new_scop): Remove init of SCOP_DEP_GRAPH.
74 * graphite-poly.h (struct scop): Remove dep_graph field.
75 (SCOP_DEP_GRAPH): Removed.
76
554eeadb 772009-10-09 Sebastian Pop <sebastian.pop@amd.com>
78
79 * graphite-poly.h (copy_lst): Do full copy of LST.
80
30105622 812009-10-07 Sebastian Pop <sebastian.pop@amd.com>
82
83 * graphite-sese-to-poly.c (reduction_phi_p): Call remove_invariant_phi
84 when the loop stride is zero.
85
86 * gcc.dg/graphite/id-16.c: New.
87
f007fe97 882009-10-06 Sebastian Pop <sebastian.pop@amd.com>
89
90 * graphite-dependences.c (reduction_dr_1): New.
91 (reduction_dr_p): New.
92 (graphite_legal_transform_dr): Call reduction_dr_p.
93 (reduction_ddr): Renamed reduction_ddr_p.
94 * graphite-poly.h (same_pdr_p): New.
95 (number_of_write_pdrs): New.
96 * graphite-sese-to-poly.c (nb_data_writes_in_bb): New.
97 (split_reduction_stmt): Do not split reduction statements
98 when there are no writes to memory.
99 (translate_scalar_reduction_to_array_for_stmt): Insert the
100 memory reduction statement just after the scalar reduction statement.
101
102 * gcc.dg/graphite/interchange-10.c: Updated to differ from interchange-4.c.
103 Un-XFAIL-ed.
104 * gcc.dg/graphite/interchange-3.c: Un-XFAIL-ed.
105 * gcc.dg/graphite/interchange-4.c: Un-XFAIL-ed.
106
4d0382bc 1072009-10-06 Sebastian Pop <sebastian.pop@amd.com>
108
109 * graphite-interchange.c (lst_apply_interchange): New.
110 (lst_interchange_profitable_p): New.
111 (lst_try_interchange_loops): New.
112 (lst_try_interchange): New.
113 (lst_do_interchange): New.
114 (pbb_do_interchange): Removed.
115 (scop_do_interchange): Call lst_do_interchange.
116
f77385d3 1172009-10-06 Sebastian Pop <sebastian.pop@amd.com>
118
119 * graphite-poly.c (print_scop): Print SCOP_ORIGINAL_SCHEDULE and
120 SCOP_TRANSFORMED_SCHEDULE.
121 (loop_to_lst): New.
122 (scop_to_lst): New.
123 (print_lst): New.
124 (debug_lst): New.
125 * graphite-poly.h (lst_p): New.
126 (struct lst): New.
127 (LST_LOOP_P): New.
128 (LST_LOOP_FATHER): New.
129 (LST_PBB): New.
130 (LST_SEQ): New.
131 (scop_to_lst): Declared.
132 (print_lst): Declared.
133 (debug_lst): Declared.
134 (new_lst_loop): New.
135 (new_lst_stmt): New.
136 (copy_lst): New.
137 (lst_depth): New.
138 (lst_dewey_number): New.
139 (struct scop): Add original_schedule and transformed_schedule fields.
140 (SCOP_ORIGINAL_SCHEDULE): New.
141 (SCOP_TRANSFORMED_SCHEDULE): New.
142 * graphite-sese-to-poly.c (build_poly_scop): Call scop_to_lst.
143
30f4f4a6 1442009-10-05 Sebastian Pop <sebastian.pop@amd.com>
145
146 * graphite-dependences.c (reduction_ddr): New.
147 (graphite_legal_transform_bb): Call reduction_ddr.
148 * graphite-poly.c (new_poly_bb): Pass a new bool parameter.
149 Initialize PBB_IS_REDUCTION.
150 * graphite-poly.h (struct poly_bb): New bool field is_reduction.
151 (PBB_IS_REDUCTION): New.
152 (new_poly_bb): Update declaration.
153 * graphite-scop-detection.h (build_scop_bbs): Removed.
154 (nb_reductions_in_loop): Removed.
155 * graphite-sese-to-poly.c (try_generate_gimple_bb): Pass a sbitmap
156 parameter for reductions.
157 (try_generate_gimple_bb): Update call to new_poly_bb.
158 (build_scop_bbs_1): Same.
159 (build_scop_bbs): Same.
160 (gsi_for_phi_node): New.
161 (scalar_close_phi_node_p): Remove gcc_assert.
162 (split_reduction_stmt): New.
163 (is_reduction_operation_p): New.
164 (phi_contains_arg): New.
165 (follow_ssa_with_commutative_ops): New.
166 (detect_commutative_reduction_arg): New.
167 (detect_commutative_reduction_assign): New.
168 (follow_inital_value_to_phi): New.
169 (edge_initial_value_for_loop_phi): New.
170 (initial_value_for_loop_phi): New.
171 (detect_commutative_reduction): New.
172 (translate_scalar_reduction_to_array_for_stmt): New.
173 (insert_copyout): New.
174 (insert_copyin): New.
175 (translate_scalar_reduction_to_array): New.
176 (rewrite_commutative_reductions_out_of_ssa_close_phi): New.
177 (rewrite_commutative_reductions_out_of_ssa_loop): New.
178 (rewrite_commutative_reductions_out_of_ssa): New.
179 (build_poly_scop): Call rewrite_commutative_reductions_out_of_ssa.
180 * sese.h (split_region_for_bb): New.
181
182 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK): Add -ffast-math.
183 * gcc.dg/graphite/interchange-1.c: Fix format.
184 * gcc.dg/graphite/interchange-10.c: New.
185
dcdff5dc 1862009-10-05 Sebastian Pop <sebastian.pop@amd.com>
187
188 * graphite-sese-to-poly.c (insert_out_of_ssa_copy): Remove
189 buggy assert.
190
5061777c 1912009-10-05 Sebastian Pop <sebastian.pop@amd.com>
192
193 * graphite-sese-to-poly.c (scev_analyzable_p): New.
194 (rewrite_cross_bb_scalar_dependence): New.
195 (rewrite_cross_bb_scalar_deps): New.
196 (rewrite_reductions_out_of_ssa): Use bb_in_sese_p.
197 Call rewrite_cross_bb_scalar_deps.
198
52123e43 1992009-10-05 Sebastian Pop <sebastian.pop@amd.com>
200
201 * graphite-sese-to-poly.c (gsi_for_ssa_name_def): Removed.
202 (insert_out_of_ssa_copy): Directly use gsi_after_labels and
203 gsi_for_stmt.
204
ef43e998 2052009-10-05 Sebastian Pop <sebastian.pop@amd.com>
206
207 * graphite-clast-to-gimple.c (build_cloog_prog): Use pbb_index.
208 * graphite-interchange.c (pbb_do_interchange): Same.
209 * graphite-poly.c (print_scattering_function): Same.
210 (debug_pdrs): Same.
211 * graphite-poly.h (pbb_loop): New.
212 * graphite-sese-to-poly.c (create_linear_expr_from_tree): Use pbb_loop.
213
7bf7d520 2142009-09-27 Sebastian Pop <sebastian.pop@amd.com>
215
216 * graphite-scop-detection.c (limit_scops): Do not build poly_bbs.
217
9c48819a 2182009-09-27 Sebastian Pop <sebastian.pop@amd.com>
219
220 * graphite-sese-to-poly.c (partition_drs_to_sets): Drs is not modified,
221 so don't pass a pointer to it.
222 (build_alias_set_for_drs): Same.
223 (build_base_obj_set_for_drs): Same.
224 (build_scop_drs): Same.
225
af3b89d1 2262009-09-26 Li Feng <nemokingdom@gmail.com>
227
228 * graphite-sese-to-poly.c (build_scop_drs): Disable writing to file
229 the alias graph of data references.
230
8dee37ec 2312009-09-25 Li Feng <nemokingdom@gmail.com>
232
233 * graphite-sese-to-poly.c (write_alias_graph_to_ascii_dimacs): New.
234 (build_scop_drs): When debugging, write the alias graph to file,
235 otherwise, should be disabled.
236
3cc56eaf 2372009-09-17 Sebastian Pop <sebastian.pop@amd.com>
238
239 * graphite-scop-detection.c (stmt_simple_memref_p): Removed.
240 (is_simple_operand): Remove call to stmt_simple_memref_p.
241 (stmt_simple_for_scop_p): Update call to is_simple_operand.
242
4d62cf0c 2432009-09-17 David Edelsohn <edelsohn@gnu.org>
244
7a9c68c3 245 * testsuite/gcc.dg/graphite/interchange-mvt.c: New File.
4d62cf0c 246 * testsuite/gcc.dg/graphite/scop-dsyrk.c: New File.
247 * testsuite/gcc.dg/graphite/scop-dsyr2k.c: New File.
248 * testsuite/gcc.dg/graphite/scop-mvt.c: New File.
249 * testsuite/gcc.dg/graphite/scop-sor.c: New File.
250
ae11f03b 2512009-09-17 Li Feng <nemokingdom@gmail.com>
252
253 PR middle-end/41118
254 * graphite-dependences.c (poly_drs_may_alias_p): Adjust definition.
255 (pddr_original_scattering): Make sure 2 pdr2 in the same base object set.
256 (graphite_carried_dependence_level_k): Ditto.
257 * graphite-poly.c (new_poly_dr): Add init of PDR_BASE_OBJECT_SET.
258 * graphite-poly.h (struct poly_dr): Add member dr_base_object_set.
259 (new_poly_dr): Adjust declaration.
260 * graphite-sese-to-poly.c (free_data_refs_aux): New.
261 (free_gimple_bb): Added free_data_refs_aux.
262 (build_poly_dr): Add dr_base_object_set.
263 (partition_drs_to_sets): New.
264 (dr_same_base_object_p): New.
265 (build_alias_set_for_drs): New.
266 (build_base_object_set_for_drs): New.
267 (build_scop_drs): Add build_base_obj_set_for_drs.
268 * graphite-sese-to-poly.h: Added #define for alias set number index and
269 base object set index.
270 * libgomp/testsuite/libgomp.graphite/force-parallel-6.c: Refine tests.
271 * libgomp/testsuite/libgomp.graphite/pr4118.c: New.
272
e5d72697 2732009-09-16 Alexander Monakov <amonakov@ispras.ru>
274
275 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Add bounds only
276 for ARRAY_REFs. Use array_ref_{low,up}_bound to determine bounds.
277
db899978 2782009-09-14 Sebastian Pop <sebastian.pop@amd.com>
279
280 * graphite-sese-to-poly.c (struct irp_data): Removed.
281 (idx_record_params): Removed.
282 (find_params_in_bb): Scan for parameters the access functions; don't
283 parse the tree representation.
284
e5b6be5e 2852009-09-14 Sebastian Pop <sebastian.pop@amd.com>
286
287 * tree-ssa-loop.c (gate_graphite_transforms): Disable Graphite
288 passes at -O1 and below.
289
f631009f 2902009-09-14 Sebastian Pop <sebastian.pop@amd.com>
291
292 * graphite-blocking.c: Fix order of includes: tree-chrec.h, then
293 tree-scalar-evolution.h, and then tree-data-ref.h.
294 * graphite-clast-to-gimple.c: Same.
295 * graphite-dependences.c: Same.
296 * graphite-interchange.c: Same.
297 * graphite-poly.c: Same.
298 * graphite-scop-detection.c: Same.
299 * graphite-sese-to-poly.c: Same.
300 * graphite.c: Same.
301 * lambda-code.c: Same.
302 * matrix-reorg.c: Same.
303 * tree-data-ref.c: Same.
304 * tree-if-conv.c: Same.
305 * tree-loop-distribu: Same.: Same.
306 * tree-loop-linear.c: Same.
307 * tree-parloops.c: Same.
308 * tree-predcom.c: Same.
309 * tree-vect-patterns.c: Same.
310
5e803fbe 3112009-09-02 Sebastian Pop <sebastian.pop@amd.com>
312
313 Partially revert the previous patch, except the following.
314 * tree-scalar-evolution.c (instantiate_scev_not): Adapted to pass
315 as parameters the operands of the not expression.
316
c43f1e90 3172009-09-01 Sebastian Pop <sebastian.pop@amd.com>
318
319 * tree-scalar-evolution.c (instantiate_scev_assign): New.
320 Do not call analyze_scalar_evolution on assignments.
321 (instantiate_scev_phi): Call analyze_scalar_evolution.
322 (instantiate_scev_name): Call instantiate_scev_assign and
323 instantiate_scev_phi.
324 (instantiate_scev_not): Adapted to pass as parameters the operands
325 of the not expression.
326
9e9aa0c6 3272009-09-01 Sebastian Pop <sebastian.pop@amd.com>
328
329 * tree-scalar-evolution.c (instantiate_scev_binary): Adapted
330 to pass as parameters the operands of the binary expression.
331
9d206f16 3322009-09-01 Sebastian Pop <sebastian.pop@amd.com>
333
334 * tree-scalar-evolution.c (instantiate_scev_bitnot): Renamed
335 instantiate_scev_not. Handle NEGATE_EXPR.
336 (instantiate_scev_r): Handle NEGATE_EXPR.
337
d91a99f1 3382009-09-01 Sebastian Pop <sebastian.pop@amd.com>
339
340 * tree-scalar-evolution.c (instantiate_scev_1): Renamed
341 instantiate_scev_r.
342 (instantiate_scev_r): Move code in instantiate_scev_2
343 and instantiate_scev_1.
344
378a6626 3452009-09-01 Sebastian Pop <sebastian.pop@amd.com>
346
347 * tree-scalar-evolution.c (instantiate_scev_3): New.
348 (instantiate_scev_1): Move code in instantiate_scev_3.
349
a819f845 3502009-09-01 Sebastian Pop <sebastian.pop@amd.com>
351
352 * tree-scalar-evolution.c (instantiate_scev_poly): New.
353 (instantiate_scev_1): Move code in instantiate_scev_poly.
354
39251a91 3552009-09-01 Sebastian Pop <sebastian.pop@amd.com>
356
357 * tree-scalar-evolution.c (instantiate_scev_bitnot): New.
358 (instantiate_scev_1): Move code in instantiate_scev_bitnot.
359
7723692a 3602009-09-01 Sebastian Pop <sebastian.pop@amd.com>
361
362 * tree-scalar-evolution.c (instantiate_scev_convert): New.
363 (instantiate_scev_1): Move code in instantiate_scev_convert.
364
5a10dfba 3652009-09-01 Sebastian Pop <sebastian.pop@amd.com>
366
367 * tree-scalar-evolution.c (instantiate_scev_binary): New.
368 (instantiate_scev_1): Move code in instantiate_scev_binary.
369
0731d869 3702009-09-01 Sebastian Pop <sebastian.pop@amd.com>
371
372 * tree-scalar-evolution.c (instantiate_scev_name): New.
373 (instantiate_scev_1): Move code in instantiate_scev_name.
374
3752009-08-28 Sebastian Pop <sebastian.pop@amd.com>
376
377 * Merge from mainline (150992:151171).
378
9e3531b5 3792009-08-25 Sebastian Pop <sebastian.pop@amd.com>
380
381 * graphite-dependences.c (graphite_legal_transform_bb): Call
382 pbb_remove_duplicate_pdrs.
383 * graphite-poly.c (can_collapse_pdr): Removed.
384 (pdr_find_duplicate): Removed.
385 (can_collapse_pdrs): New.
386 (pbb_remove_duplicate_pdrs): New.
387 (new_poly_dr): Do not look for duplicates.
388 * graphite-poly.h (struct poly_bb): New field pdr_duplicates_removed.
389 (PBB_PDR_DUPLICATES_REMOVED): New.
390 (pbb_remove_duplicate_pdrs): Declared.
391
11b2102e 3922009-08-25 Sebastian Pop <sebastian.pop@amd.com>
393
394 * graphite-interchange.c (pbb_interchange_profitable_p): Adjust
395 the strides by multiplying by PDR_NB_REFS.
396 * graphite-poly.c (can_collapse_pdr): New.
397 (pdr_find_duplicate): New.
398 (new_poly_dr): Call pdr_find_duplicate. Collapse duplicate PDRs.
399 Initialize PDR_NB_REFS.
400 * graphite-poly.h (struct poly_dr): Add field nb_refs.
401 (PDR_NB_REFS): New.
402 (new_poly_dr): Number of subscripts is a graphite_dim_t.
403
4042009-08-25 Sebastian Pop <sebastian.pop@amd.com>
405
406 Revert one of the previous commits:
407 * graphite-dependences.c (graphite_legal_transform_bb): Avoid
408 the computation of symmetric data dependence relations.
409 (dependency_between_pbbs_p): Same.
410
d0aaf399 4112009-08-25 Sebastian Pop <sebastian.pop@amd.com>
412
413 PR middle-end/40965
414 * graphite-poly.c (apply_poly_transforms): Remove legality test before
415 any transform.
416
79698ff3 4172009-08-25 Sebastian Pop <sebastian.pop@amd.com>
418
419 * graphite-dependences.c (pddr_original_scattering): Return NULL
420 for read-read dependence relations.
421 * graphite-poly.h (enum poly_dr_type): Fix comment.
422 (pdr_read_p): New.
423 (pdr_write_p): New.
424 (pdr_may_write_p): New.
425
c04f2da7 4262009-08-25 Sebastian Pop <sebastian.pop@amd.com>
427
428 * graphite-poly.h (enum POLY_DR_TYPE): Renamed poly_dr_type.
429 (struct poly_dr): Same.
430 (new_poly_dr): Same.
431 * graphite-poly.c (new_poly_dr): Same.
432
ee0d08ad 4332009-08-25 Konrad Trifunovic <konrad.trifunovic@gmail.com>
434 Sebastian Pop <sebastian.pop@amd.com>
435
436 * graphite-blocking.c (pbb_strip_mine_loop_depth): Renamed
437 pbb_strip_mine_time_depth. Changed the implementation so that
438 transformation is expressed as a transformation on
439 time (scatttering) dimensions. Also, ensures that the 2d+1
440 scheduling format is preserved.
441 (pbb_strip_mine_profitable_p): Profitability is based on the
442 iteration number of a given time (scattering) dimension,
443 and not on a original loop depth dimension.
444 (pbb_strip_mine): Call pbb_number_of_iterations_at_time.
445 (pbb_do_strip_mine): Call psct_dynamic_dim.
446 * graphite-poly.c (pbb_number_of_iterations_at_time): New.
447 * graphite-poly.h (pbb_number_of_iterations_at_time): Declared.
448 (pbb_nb_dynamic_scattering_transform): New.
449 (psct_dynamic_dim): New.
450
55c54afb 4512009-08-25 Konrad Trifunovic <konrad.trifunovic@gmail.com>
452
453 * graphite-ppl.c (ppl_max_for_le): Renamed ppl_max_for_le_pointset.
454 * graphite-ppl.h (ppl_max_for_le): Renamed ppl_max_for_le_pointset.
455 * graphite-poly.c (pbb_number_of_iterations): Rename ppl_max_for_le.
456 * graphite-interchange.c (build_linearized_memory_access): Same.
457 (memory_stride_in_loop): Same.
458
96b6d5d7 4592009-08-25 Sebastian Pop <sebastian.pop@amd.com>
460
461 * graphite-dependences.c (pddr_original_scattering): New.
462 (graphite_legal_transform_dr): Call pddr_original_scattering.
463 (dot_deps_1): New.
464 (dot_deps): New.
465 * graphite-dependences.h (dot_deps): Declared.
466 * graphite-poly.c (new_poly_dr): Initialize PDR_ID.
467 (print_pdr): Print PDR_ID.
468 * graphite-poly.h (struct poly_dr): Add field id.
469 (PDR_ID): New.
470 (pbb_index): New.
471 * graphite-scop-detection.c (dot_all_scops_1): Cleanup comment.
472
2b3a572c 4732009-08-22 Sebastian Pop <sebastian.pop@amd.com>
474
475 * graphite-dependences.c (graphite_carried_dependence_level_k): Do
476 not delete the original dependence relation.
477
4782009-08-21 Sebastian Pop <sebastian.pop@amd.com>
479
480 * graphite-dependences.c (graphite_legal_transform_bb): Avoid
481 the computation of symmetric data dependence relations.
482 (dependency_between_pbbs_p): Same.
483
0d6b5db2 4842009-08-21 Sebastian Pop <sebastian.pop@amd.com>
485
486 * graphite-dependences.c (new_poly_dr_pair): Renamed new_poly_ddr.
487 (eq_poly_dr_pair_p): Renamed eq_poly_ddr_p.
488 (hash_poly_dr_pair_p): Renamed hash_poly_ddr_p.
489 (free_poly_ddr): New.
490 (pddr_is_empty): New.
491 (dependence_polyhedron_1): Now returns a poly_ddr_p.
492 (dependence_polyhedron): Same. Remove useless gcc_assert.
493 Remove fprintfs.
494 (graphite_legal_transform_dr): Call pddr_is_empty and free_poly_ddr.
495 (graphite_carried_dependence_level_k): Call pddr_is_empty.
496 * graphite-dependences.h (enum poly_dependence_kind): New.
497 (poly_dr_pair): Renamed poly_ddr. Added a field kind.
498 (PDRP_SOURCE): Renamed PDDR_SOURCE.
499 (PDRP_SINK): Renamed PDDR_SINK.
500 (PDRP_DDP): Renamed PDDR_DDP.
501 (PDDR_KIND): New.
502 (free_poly_ddr): Declared.
503 * graphite-poly.c (new_scop): Use the new hash function names.
504 * graphite-poly.h (struct scop): Renamed field original_pdr_pairs
505 into original_pddrs.
506 (SCOP_ORIGINAL_PDR_PAIRS): Renamed SCOP_ORIGINAL_PDDRS.
507
5082009-08-21 Sebastian Pop <sebastian.pop@amd.com>
509
510 * Merge from mainline (150764:150992).
511
02df46c6 5122009-08-18 Sebastian Pop <sebastian.pop@amd.com>
513
514 * cfgloopmanip.c (create_empty_loop_on_edge): Generate upper
515 bounds with LT_EXPR to make niter analysis more precise on code
516 generated by Graphite.
517
70a1a7a2 5182009-08-18 Sebastian Pop <sebastian.pop@amd.com>
519
520 * graphite-dependences.c (graphite_legal_transform_dr): Fix formatting.
521 (graphite_legal_transform_bb): Same.
522 (poly_drs_may_alias_p): Same.
523
19eec579 5242009-08-15 Sebastian Pop <sebastian.pop@amd.com>
525
526 PR middle-end/40981
527 * graphite-ppl.c (ppl_max_for_le): Correct the use of
528 ppl_Pointset_Powerset_C_Polyhedron_maximize.
529
5302009-08-13 Sebastian Pop <sebastian.pop@amd.com>
531
532 * graphite-poly.c (print_pbb): Print PBB index.
533
5342009-08-13 Sebastian Pop <sebastian.pop@amd.com>
535
536 * Merge from mainline (r150672:150764).
537
5382009-08-13 Sebastian Pop <sebastian.pop@amd.com>
539
540 * graphite-interchange.c (ppl_max_for_le): Moved...
541 * graphite-poly.c (pbb_number_of_iterations): Call ppl_max_for_le.
542 * graphite-ppl.c (ppl_max_for_le): ... here.
543 * graphite-ppl.h (ppl_max_for_le): Declared.
544
5452009-08-12 Sebastian Pop <sebastian.pop@amd.com>
546
547 * Merge from mainline (r150372:150672).
548
43f8b6ab 5492009-08-11 Sebastian Pop <sebastian.pop@amd.com>
550
551 PR middle-end/40980
552 * sese.c (convert_for_phi_arg): New.
553 (add_guard_exit_phis): Use convert_for_phi_arg.
554
555 * testsuite/gfortran.dg/graphite/id-17.f: New.
556
96da1999 5572009-08-11 Sebastian Pop <sebastian.pop@amd.com>
558
559 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Dont add
560 unknown subscript upper bounds.
561
562 * testsuite/gcc.dg/graphite/interchange-6.c: Un-XFAIL.
563
80020e9d 5642009-08-11 Sebastian Pop <sebastian.pop@amd.com>
565 Pranav Garg <pranav.garg2107@gmail.com>
566
567 * graphite-interchange.c (gather_access_strides): Removed.
568 (ppl_max_for_le): New.
569 (build_linearized_memory_access): New.
570 (memory_stride_in_loop): New.
571 (pbb_interchange_profitable_p): Reimplemented.
572 * graphite-ppl.h (ppl_new_id_map): New.
573 (ppl_interchange): New.
574
575 * testsuite/gcc.dg/graphite/interchange-6.c: XFAILed.
576
c9fce634 5772009-08-11 Sebastian Pop <sebastian.pop@amd.com>
578
579 * graphite-interchange.c (compute_subscript): Removed.
580 (compute_array_size_cstr): Removed.
581 (compute_array_size_poly): Removed.
582 (compute_array_size): Removed.
583 (gather_access_strides_poly): Removed.
584 (gather_access_strides): Empty.
585
85f74b79 5862009-08-11 Sebastian Pop <sebastian.pop@amd.com>
587
588 * graphite-dependences.c (dependence_polyhedron_1): Replace
589 pdr_nb_subscripts with PDR_NB_SUBSCRIPTS.
590 (graphite_legal_transform_dr): Same.
591 (graphite_carried_dependence_level_k): Same.
592 * graphite-poly.c (new_poly_dr): Add a parameter nb_subscripts.
593 Initialize PDR_NB_SUBSCRIPTS.
594 (print_pdr_access_layout): Replace pdr_nb_subscripts with
595 PDR_NB_SUBSCRIPTS.
596 * graphite-poly.h (struct poly_dr): Add nb_subscripts field.
597 (PDR_NB_SUBSCRIPTS): New.
598 (pdr_nb_subscripts): Removed.
599 (pdr_dim): Simplified.
600 * graphite-sese-to-poly.c (build_poly_dr): Replace pdr_nb_subscripts
601 with PDR_NB_SUBSCRIPTS.
602
19b42529 6032009-08-11 Sebastian Pop <sebastian.pop@amd.com>
604
605 * graphite-interchange.c (compute_array_size): Remove use of
606 PDR_DATA_CONTAINER.
607 * graphite-poly.c (new_poly_dr): Remove argument data_container.
608 Do not initialize PDR_DATA_CONTAINER.
609 (print_pdr): Do not print PDR_DATA_CONTAINER.
610 * graphite-poly.h (struct poly_dr): Remove data_container field.
611 (PDR_DATA_CONTAINER): Removed.
612 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Remove use of
613 PDR_DATA_CONTAINER.
614 (build_poly_dr): Same.
615
9daa8810 6162009-08-11 Sebastian Pop <sebastian.pop@amd.com>
617
618 * testsuite/gcc.dg/graphite/interchange-9.c: New.
619
0835eab6 6202009-08-05 Konrad Trifunovic <konrad.trifunovic@gmail.com>
621 Sebastian Pop <sebastian.pop@amd.com>
622
623 * graphite-dependences.c (graphite_legal_transform_dr): Work on a
624 copy of the dependence polyhedron. Free the temporary objects.
625 (graphite_carried_dependence_level_k): Free unused objects before
626 returning.
627
628 * testsuite/gcc.dg/graphite/interchange-1.c: XFAILed.
629 * testsuite/gcc.dg/graphite/interchange-2.c: XFAILed.
630 * testsuite/gcc.dg/graphite/interchange-3.c: XFAILed.
631 * testsuite/gcc.dg/graphite/interchange-4.c: XFAILed.
632 * testsuite/gcc.dg/graphite/interchange-7.c: XFAILed.
633
a741358d 6342009-08-05 Sebastian Pop <sebastian.pop@amd.com>
635
636 * graphite-blocking.c (scop_do_strip_mine): Call store_scattering.
637 Early return without analyzing the data dependences if no
638 transform has been done. Call restore_scattering if the transform
639 is not legal.
640 (graphite-interchange.c): Same.
641 * graphite-poly.c (print_scattering_function): Test for PBB_TRANSFORMED.
642 (graphite_read_transforms): Initialize PBB_TRANSFORMED.
643 (apply_poly_transforms): Do not gcc_assert that
644 the transform is legal.
645 (new_poly_bb): Initialize PBB_TRANSFORMED, PBB_SAVED, and PBB_ORIGINAL.
646 Do not initialize PBB_NB_SCATTERING_TRANSFORM, PBB_NB_LOCAL_VARIABLES,
647 PBB_TRANSFORMED_SCATTERING, and PBB_ORIGINAL_SCATTERING.
648 (free_poly_dr): Free PBB_TRANSFORMED, PBB_SAVED, and PBB_ORIGINAL.
649 * graphite-poly.h (struct poly_scattering): New.
650 (struct poly_bb): Add original, transformed, and saved fields.
651 Remove transformed_scattering, original_scattering, nb_local_variables,
652 and nb_scattering_transform fields.
653 (PBB_ORIGINAL, PBB_TRANSFORMED, PBB_SAVED): New.
654 (poly_scattering_new): New.
655 (poly_scattering_free): New.
656 (poly_scattering_copy): New.
657 (store_scattering_pbb): New.
658 (store_scattering): New.
659 (restore_scattering_pbb): New.
660 (restore_scattering): New.
661 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons):
662 Initialize PBB_TRANSFORMED and PBB_ORIGINAL.
9daa8810 663
95b2e0d3 6642009-08-05 Sebastian Pop <sebastian.pop@amd.com>
665
666 * graphite-poly.c (print_pbb): Add parentheses in the pretty print.
667 (print_scop): Same.
668
675d86b2 6692009-08-05 Sebastian Pop <sebastian.pop@amd.com>
670
671 * Makefile.in (graphite.o): Depends on PREDICT_H.
672 * graphite.c: Include predict.h.
673 (graphite_finalize): Call tree_estimate_probability.
674 * predict.c (predict_loops): Do not call scev_initialize and
675 scev_finalize.
676 (tree_estimate_probability_bb): New.
677 (tree_estimate_probability): Do not initialize loops: move that
678 code to the driver. Call tree_estimate_probability_bb.
679 (tree_estimate_probability_driver): New.
680 (pass_profile): Use tree_estimate_probability_driver.
681 * predict.h (tree_estimate_probability): Declared.
682
525c22c4 6832009-08-05 Sebastian Pop <sebastian.pop@amd.com>
684
685 * graphite-clast-to-gimple.c (gloog): Add time to TV_GRAPHITE_CODE_GEN.
686 * graphite-dependences.c (graphite_legal_transform): Add time to
687 TV_GRAPHITE_DATA_DEPS.
688 (dependency_between_pbbs_p): Same.
689 * timevar.def (TV_GRAPHITE_DATA_DEPS, TV_GRAPHITE_CODE_GEN): New.
690
6912009-08-03 Sebastian Pop <sebastian.pop@amd.com>
692
693 * Merge from mainline (r149952:150372).
694
c6bb733d 6952009-07-28 Sebastian Pop <sebastian.pop@amd.com>
696
697 * ChangeLog.graphite: Fix indenting, white spaces and 80 columns.
698 * graphite-blocking.c: Same.
699 * graphite-clast-to-gimple.c: Same.
700 * graphite-dependences.c: Same.
701 * graphite-poly.c: Same.
702 * graphite-poly.h: Same.
703 * graphite-ppl.c: Same.
704 * graphite-scop-detection.c: Same.
705 * graphite-sese-to-poly.c: Same.
706 * graphite.c: Same.
707
7082009-07-28 Sebastian Pop <sebastian.pop@amd.com>
709
710 * graphite-sese-to-poly.c (loop_entry_phi_arg): New.
711 (remove_simple_copy_phi): New.
712 (remove_invariant_phi): New.
713 (simple_copy_phi_p): New.
714 (reduction_phi_p): New.
715 (gsi_for_ssa_name_def): New.
716 (insert_out_of_ssa_copy): New.
717 (insert_out_of_ssa_copy_on_edge): New.
718 (create_zero_dim_array): New.
719 (scalar_close_phi_node_p): New.
720 (rewrite_close_phi_out_of_ssa): New.
721 (rewrite_phi_out_of_ssa): New.
722 (rewrite_reductions_out_of_ssa): New.
723 (build_poly_scop): Call rewrite_reductions_out_of_ssa.
724
725 * testsuite/gcc.dg/graphite/id-11.c: New.
726 * testsuite/gcc.dg/graphite/id-15.c: New.
727 * testsuite/gcc.dg/graphite/interchange-1.c: Un-XFAIL.
728 * testsuite/gcc.dg/graphite/interchange-2.c: Un-XFAIL.
729 * testsuite/gcc.dg/graphite/interchange-3.c: Un-XFAIL.
730 * testsuite/gcc.dg/graphite/interchange-4.c: Un-XFAIL.
731 * testsuite/gcc.dg/graphite/interchange-7.c: Un-XFAIL.
732 * testsuite/gcc.dg/graphite/scop-matmult.c: Un-XFAIL.
733 * testsuite/gfortran.dg/graphite/id-13.f: New.
734 * testsuite/gfortran.dg/graphite/id-5.f: New.
735
7362009-07-28 Sebastian Pop <sebastian.pop@amd.com>
737
738 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not
739 check that nb_reductions_in_loop is zero.
740 * graphite-scop-detection.c (harmful_stmt_in_bb): Don't filter out
741 reduction phi nodes.
742 (nb_reductions_in_loop): Removed.
743 (graphite_can_represent_loop): Do not call nb_reductions_in_loop.
744 * graphite-sese-to-poly.c (phi_node_is_iv): Removed.
745 (bb_contains_non_iv_scalar_phi_nodes): Removed.
746 (scop_contains_non_iv_scalar_phi_nodes): Removed.
747 (build_poly_scop): Do not call scop_contains_non_iv_scalar_phi_nodes.
748
7492009-07-28 Sebastian Pop <sebastian.pop@amd.com>
750
751 * graphite-clast-to-gimple.c (build_cloog_prog): Do not code generate
752 statements that have an empty iteration domain.
753 * testsuite/gfortran.dg/graphite/id-16.f: New.
754
7552009-07-28 Sebastian Pop <sebastian.pop@amd.com>
756
757 * tree-scalar-evolution.c (instantiate_scev_1): Return
758 chrec_dont_know when the result is not above instantiate_below.
759 * graphite-scop-detection.c (scopdet_basic_block_info): Fix formatting.
760 * graphite-sese-to-poly.c (create_linear_expr_from_tree): Assert that
761 the tree has a known scalar evolution.
762 * testsuite/gfortran.dg/graphite/id-14.f: New.
763 * testsuite/gfortran.dg/graphite/id-15.f: New.
764
7652009-07-28 Sebastian Pop <sebastian.pop@amd.com>
766
767 * sese.c (rename_variables_in_stmt): Pass in an extra parameter
768 insert_gsi.
769 (rename_variables): Keep inserting renames after the ones already
770 inserted.
771
7722009-07-28 Sebastian Pop <sebastian.pop@amd.com>
773
774 * graphite-sese-to-poly.c (compare_bb_depths): New.
775 (graphite_sort_dominated_info): New.
776 (build_scop_bbs_1): Call graphite_sort_dominated_info.
777 (build_scop_scattering): Fix comment.
778
7792009-07-28 Sebastian Pop <sebastian.pop@amd.com>
780
781 * graphite.c (graphite_finalize): Call print_loops instead of
782 dump_function_to_file.
783 * testsuite/gcc.dg/graphite/graphite.exp: Fix formatting.
784 * testsuite/gcc.dg/graphite/pr35356-1.c: New. Look for the number of
785 loops generated in the graphite output file.
786 * testsuite/gcc.dg/graphite/pr35356-2.c: New.
787 * testsuite/gcc.dg/graphite/pr35356-3.c: New. XFAILed for now.
788 * testsuite/gfortran.dg/graphite/id-12.f: New.
789
7902009-07-24 Li Feng <nemokingdom@gmail.com>
791
792 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-8.c:
793 Remove 2 XFAIL.
794
7952009-07-24 Li Feng <nemokingdom@gmail.com>
796 Tobias Grosser <grosser@fim.uni-passau.de>
797
798 * graphite-sese-to-poly.c (pdr_add_alias_set): Use data reference's
799 alias set number build alias in ACCESSES polyhedron.
800 (build_alias_set_for_drs): New.
801 (build_pbb_drs): Added build_alias_set_for_drs.
802 * graphite-dependences.c (poly_drs_may_alias_p): New.
803 (graphite_carried_dependence_level_k): Check alias information
804 before building polyhedron.
805
8062009-07-24 Tobias Grosser <grosser@fim.uni-passau.de>
807
808 * Makefile.in (lambda-code.o): Fix formatting.
809
8102009-07-24 Tobias Grosser <grosser@fim.uni-passau.de>
811
812 * Merge from mainline (r149350-149952)
813
8142009-07-18 Tobias Grosser <grosser@fim.uni-passau.de>
815
816 * graphite-poly.c (apply_poly_transforms): Move strip_mine
817 before interchange to prepare for loop blocking.
818
8192009-07-18 Tobias Grosser <grosser@fim.uni-passau.de>
820
821 * graphite-poly.c (apply_poly_transforms): Add checks after every
822 transformation.
823 * graphite-sese-to-poly.c (build_poly_scop): Remove check, as already
824 done in apply_poly_transforms.
825
8262009-07-17 Konrad Trifunovic <konrad.trifunovic@gmail.com>
827
828 * graphite-dependences.c (build_lexicographically_gt_constraint):
829 Replace RES parameter with *RES.
830 (dependence_polyhedron_1): Pass an address of the parameter RES
831 instead of value of RES.
832
8332009-07-16 Sebastian Pop <sebastian.pop@amd.com>
834
835 * graphite.c (graphite_finalize): Fix comment.
836 (graphite_transform_loops): Reset scev info after code generation
837 of each scop.
838
8392009-07-16 Sebastian Pop <sebastian.pop@amd.com>
840
841 * graphite.c (graphite_finalize): Call scev_reset.
842
8432009-07-16 Sebastian Pop <sebastian.pop@amd.com>
844
845 * graphite-clast-to-gimple.c (compute_cloog_iv_types): Do not create
846 GBB_CLOOG_IV_TYPES hash table twice.
847 * graphite-sese-to-poly.c (free_gimple_bb): Call free_data_refs.
848 (add_condition_to_domain): Clear GMP values.
849
8502009-07-16 Sebastian Pop <sebastian.pop@amd.com>
851
852 * graphite-dependences.c: Fix formatting.
853 * graphite-poly.c (free_poly_dr): Also free PDR_DATA_CONTAINER.
854 (pbb_number_of_iterations): Free ppl_Linear_Expression.
855 * graphite-sese-to-poly.c: Fix formatting.
856 * graphite.c (graphite_transform_loops): Create the hash table
857 after the early return.
858
8592009-07-16 Sebastian Pop <sebastian.pop@amd.com>
860
861 * testsuite/gcc.dg/graphite/id-14.c: New.
862 * testsuite/gcc.dg/graphite/pr40157.c: New.
863 * testsuite/gfortran.dg/graphite/id-11.f: New.
864
8652009-07-16 Sebastian Pop <sebastian.pop@amd.com>
866
867 * graphite-sese-to-poly.c (nb_pbbs_in_loops): New.
868 (build_poly_scop): Return false when there are no pbbs within
869 loops to avoid to pass to cloog scops with no loops.
870
8712009-07-16 Sebastian Pop <sebastian.pop@amd.com>
872
873 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons): Avoid
874 useless test "i % 2".
875 (build_pbb_scattering_polyhedrons): Fix formatting.
876 (build_poly_dr): Same.
877 * graphite.c (graphite_transform_loops): Restructure.
878
8792009-07-14 Razya Ladelsky <razya@il.ibm.com>
880
881 * tree-ssa-loop-manip.c (rewrite_phi_with_iv): Remove
882 reduction_list parameter.
883 (rewrite_all_phi_nodes_with_iv): Same.
884 (canonicalize_loop_ivs): Same.
885 * tree-parloops.c (struct brli): Removed.
886 (build_reduction_list_info): Removed.
887 (build_new_reduction): New.
888 (analyze_reduction_list): Removed.
889 (gather_scalar_reductions): Find reductions instead of phi
890 nodes that can't be canonicalized.
891 (try_create_reduction_list): Remove reduction_list parameter.
892 (gen_parallel_loop): Same.
893 (parallelize_loops): Remove analyze_reductions variable,
894 initialization and free.
895 Change reduction_list htab initialization to reduction_info
896 elements instead of ssa names.
897 Call try_create_reduction_list and gen_parallel_loop without
898 analyzed_reduction argument.
899 * graphite-clast-to-gimple (graphite_loop_normal_form): Call
900 canonicalize_loop_ivs with one less argument.
901 * tree-flow.h (canonicalize_loop_ivs): Remove one argument.
902
9032009-07-14 Konrad Trifunovic <konrad.trifunovic@gmail.com>
904
905 * graphite-dependences.c (new_poly_dr_pair): New.
906 (dependence_polyhedron): Renamed into dependence_polyhedron_1.
907 (new_poly_dr_pair): New.
908 (eq_poly_dr_pair_p): New.
909 (hash_poly_dr_pair_p): New.
910 * graphite-dependences.h (struct poly_dr_pair): New.
911 (eq_poly_dr_pair_p): Declared.
912 (hash_poly_dr_pair_p): Declared.
913 * graphite-poly.c (new_scop): Initialize SCOP_ORIGINAL_PDR_PAIRS.
914 (free_scop): Free SCOP_ORIGINAL_PDR_PAIRS.
915 * graphite-poly.h (struct scop): Add original_pdr_pairs field.
916 * Makefile.in (graphite-poly.o): Add dependence on
917 graphite-dependences.h.
918
9192009-07-14 Sebastian Pop <sebastian.pop@amd.com>
920
921 * graphite-scop-detection.c (graphite_can_represent_scev): Do not let
922 polynomials of degree > 1 pass to Graphite.
923 * tree-chrec.c (scev_is_linear_expression): Call
924 evolution_function_is_affine_multivariate_p.
925 * testsuite/gfortran.dg/graphite/id-10.f90: New.
926
9272009-07-14 Sebastian Pop <sebastian.pop@amd.com>
928
929 * tree-scalar-evolution.c (compute_overall_effect_of_inner_loop):
930 Instantiate scevs varying in outer loops.
931 * testsuite/gfortran.dg/graphite/id-9.f: Correct testcase.
932
9332009-07-14 Sebastian Pop <sebastian.pop@amd.com>
934
935 * graphite-sese-to-poly.c (build_loop_iteration_domains): Do not insert
936 redundant constraint.
937
9382009-07-14 Sebastian Pop <sebastian.pop@amd.com>
939
940 * testsuite/gcc.dg/graphite/graphite.exp: Fix comments.
941 * testsuite/gfortran.dg/graphite/graphite.exp: Trigger actions
942 based on the file names as in the C testsuite.
943 * testsuite/gfortran.dg/graphite/block-1.f90: Fix patterns.
944 * testsuite/gfortran.dg/graphite/block-2.f: Same.
945 * testsuite/gfortran.dg/graphite/block-3.f90: Same.
946 * testsuite/gfortran.dg/graphite/block-4.f90: Same.
947 * testsuite/gfortran.dg/graphite/id-1.f90: Same.
948 * testsuite/gfortran.dg/graphite/id-2.f90: Same.
949 * testsuite/gfortran.dg/graphite/id-3.f90: Same.
950 * testsuite/gfortran.dg/graphite/id-4.f90: Same.
951 * testsuite/gfortran.dg/graphite/id-6.f: Same.
952 * testsuite/gfortran.dg/graphite/id-9.f: Same.
953 * testsuite/gfortran.dg/graphite/interchange-1.f: Same.
954 * testsuite/gfortran.dg/graphite/interchange-2.f: Same.
955 * testsuite/gfortran.dg/graphite/scop-1.f: Same.
956
9572009-07-14 Sebastian Pop <sebastian.pop@amd.com>
958
959 * sese.c (expand_scalar_variables_call): New.
960 (expand_scalar_variables_ssa_name): Handle calls in expander.
961
9622009-07-13 Sebastian Pop <sebastian.pop@amd.com>
963
964 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-6.c:
965 Expect to see the pattern twice.
966 * testsuite/gcc.dg/graphite/interchange-0.c: Un-XFAIL.
967 * testsuite/gcc.dg/graphite/interchange-5.c: Same.
968 * testsuite/gcc.dg/graphite/interchange-6.c: Same.
969
9702009-07-13 Sebastian Pop <sebastian.pop@amd.com>
971
972 * testsuite/gcc.dg/graphite/id-10.c: New.
973 * testsuite/gcc.dg/graphite/id-12.c: New.
974 * testsuite/gfortran.dg/graphite/id-7.f: New.
975 * testsuite/gfortran.dg/graphite/id-8.f: New.
976
9772009-07-13 Sebastian Pop <sebastian.pop@amd.com>
978
979 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Fix division by
980 zero.
981
9822009-07-13 Sebastian Pop <sebastian.pop@amd.com>
983
984 * sese.c (rename_variables_in_stmt): Call fold_convert during renaming.
985
9862009-07-13 Sebastian Pop <sebastian.pop@amd.com>
987
988 * sese.c (expand_scalar_variables_stmt): Avoid unnecessary expansion.
989
9902009-07-10 Sebastian Pop <sebastian.pop@amd.com>
991
992 * graphite-sese-to-poly.c (pdr_add_memory_accesses): Fix order of
993 building PDR subscripts.
994
9952009-07-10 Sebastian Pop <sebastian.pop@amd.com>
996
997 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Fix the
998 computation of array sizes.
999
10002009-07-10 Sebastian Pop <sebastian.pop@amd.com>
1001
1002 * graphite-sese-to-poly.c (add_param_constraints): Disabled.
1003
10042009-07-10 Tobias Grosser <grosser@fim.uni-passau.de>
1005
1006 * graphite-dependences.c (map_into_dep_poly, map_dr_into_dep_poly,
1007 build_pairwise_constraint, dr_equality_constraints,
1008 build_pairwise_scheduling_equality,
1009 build_pairwise_scheduling_inequality, lexicographically_gt_p,
1010 build_lexicographically_gt_constraint, dependence_polyhedron,
1011 graphite_legal_transform_dr, graphite_carried_dependence_level_k):
1012 Move from NNC_Polyhedron to C_Polyhedron.
1013 * graphite-interchange.c (compute_array_size_poly,
1014 gather_access_strides): Dito.
1015 * graphite-poly.c (apply_poly_transforms, new_poly_dr, free_poly_bb,
1016 free_scop, pbb_number_of_iterations): Dito.
1017 * graphite-poly.h (struct poly_dr, pdr_nb_subscripts, struct poly_bb,
1018 pbb_dim_iter_domain, struct scop): Dito.
1019 * graphite-ppl.c (new_Constraint_System_from_Cloog_Matrix,
1020 new_Cloog_Domain_from_ppl_Polyhedron,
1021 new_Cloog_Domain_from_ppl_Pointset_Powerset, ppl_set_coef_gmp,
1022 ppl_insert_dimensions_pointset, ppl_insert_dimensions_pointset,
1023 ppl_strip_loop, ppl_strip_loop, ppl_print_polyhedron_matrix,
1024 ppl_print_powerset_matrix, debug_ppl_polyhedron_matrix,
1025 debug_ppl_powerset_matrix, ppl_read_polyhedron_matrix): Dito.
1026 * graphite-ppl.h (ppl_Pointset_Powerset_C_Polyhedron_t,
1027 new_C_Polyhedron_from_Cloog_Matrix, ppl_print_powerset_matrix,
1028 debug_ppl_powerset_matrix, ppl_insert_dimensions_pointset): Dito.
1029 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons,
1030 build_loop_iteration_domains, ppl_constraint_type_from_tree_code,
1031 add_condition_to_domain, add_condition_to_pbb, build_scop_context,
1032 build_scop_iteration_domain, build_poly_dr): Dito
1033
10342009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1035
1036 * testsuite/gcc.dg/graphite/graphite.exp: Added a rule to execute
1037 run-id-*.c files.
1038 * testsuite/gcc.dg/graphite/run-id-1.c: New.
1039
10402009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1041
1042 * graphite-sese-to-poly.c (build_loop_iteration_domains): Add the
1043 positivity constraint on the symbolic number of iterations.
1044
10452009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1046
1047 * graphite-sese-to-poly.c (build_loop_iteration_domains): Rewrite.
1048
10492009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1050 Tobias Grosser <grosser@fim.uni-passau.de>
1051
1052 * graphite-clast-to-gimple.c (build_scop_context): Removed.
1053 (build_cloog_prog): Directly use SCOP_CONTEXT.
1054 * graphite-poly.c (new_scop): Initialize SCOP_CONTEXT.
1055 (free_scop): Free SCOP_CONTEXT.
1056 (print_scop_context): New.
1057 (print_scop): Call print_scop_context.
1058 (debug_scop_context): New.
1059 * graphite-poly.h (print_scop_context, debug_scop_context): Declared.
1060 (struct scop): Added field context.
1061 (SCOP_CONTEXT): New.
1062 * graphite-sese-to-poly.c (add_param_constraints): New.
1063 (build_scop_context): New.
1064 (build_poly_scop): Call build_scop_context.
1065
10662009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1067
1068 * graphite-clast-to-gimple.c (gmp_cst_to_tree): Moved...
1069 * graphite-ppl.c (ppl_set_inhomogeneous_gmp, ppl_set_coef_gmp): New.
1070 (ppl_set_inhomogeneous, ppl_set_coef): Moved...
1071 * graphite-ppl.h: Include double-int.h and tree.h.
1072 (ppl_set_inhomogeneous_gmp, ppl_set_coef_gmp): Declared.
1073 (ppl_set_inhomogeneous, ppl_set_coef): ...here.
1074 (gmp_cst_to_tree): ...here. Reimplemented using mpz_get_double_int.
1075 (tree_int_to_gmp, ppl_set_inhomogeneous_tree, ppl_set_coef_tree): New.
1076
10772009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1078
1079 * graphite-clast-to-gimple.c (clast_to_gcc_expression_red): Generate
1080 POINTER_PLUS_EXPR for pointer types.
1081 (clast_to_gcc_expression): Same.
1082
10832009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1084
1085 * graphite-poly.c (print_scattering_function): Early return when
1086 PBB_TRANSFORMED_SCATTERING is not initialized.
1087 (print_pbb_domain): Early return when PBB_DOMAIN is not initialized.
1088
10892009-07-08 Sebastian Pop <sebastian.pop@amd.com>
1090
1091 * tree-parloops.c (analyze_reduction_list): Remove unused variable
1092 to fix bootstrap.
1093
10942009-07-08 Razya Ladelsky <razya@il.ibm.com>
1095
1096 * tree-parloops.c (analyze_reduction_list): Change return
1097 value to void.
1098 (try_create_reduction_list): Move the call to
1099 analyze_reduction_list to the beginining.
1100 Call reduction_phi with analyzed_reductions as argument
1101 instead of reduction_list.
1102
11032009-07-08 Tobias Grosser <grosser@fim.uni-passau.de>
1104
1105 * Merge from mainline (r148296:149346)
1106
11072009-07-07 Sebastian Pop <sebastian.pop@amd.com>
1108
1109 * graphite-scop-detection.c (graphite_can_represent_init): New.
1110 (graphite_can_represent_scev): Call graphite_can_represent_init:
1111 check that the initial value does not contain multiplications of
1112 parameters.
1113 (stmt_has_simple_data_refs_p): New.
1114 (stmt_simple_for_scop_p): Call stmt_simple_for_scop_p.
1115 (is_simple_operand): Fix formatting.
1116 * graphite-sese-to-poly.c (try_generate_gimple_bb): Fix formatting.
1117
11182009-07-07 Sebastian Pop <sebastian.pop@amd.com>
1119
1120 * testsuite/gcc.dg/graphite/id-13.c: New.
1121 * graphite-sese-to-poly.c (graphite_stmt_p): Do not call
1122 analyze_scalar_evolution, use scalar_evolution_in_region.
1123 (scan_tree_for_params_right_scev): Add extra assert.
1124 (parameter_index_in_region_1): Split from parameter_index_in_region.
1125 (idx_record_params): Use scalar_evolution_in_region.
1126 (find_params_in_bb): Same.
1127 (find_scop_parameters): Same.
1128 (build_loop_iteration_domains): Same.
1129 (create_linear_expr_from_tree): Same.
1130 * sese.c (scalar_evolution_in_region): New.
1131 * sese.h (scalar_evolution_in_region): Declared.
1132 (defined_in_sese_p): New.
1133 * tree-scalar-evolution.c (compute_overall_effect_of_inner_loop): Not
1134 static anymore.
1135 * tree-scalar-evolution.h (compute_overall_effect_of_inner_loop):
1136 Declared.
1137
11382009-07-07 Sebastian Pop <sebastian.pop@amd.com>
1139
1140 * Makefile.in: Replace dependences on tree-chrec.h with SCEV_H.
1141 TREE_DATA_REF_H also implies SCEV_H.
1142
11432009-07-07 Sebastian Pop <sebastian.pop@amd.com>
1144
1145 * graphite-poly.c (print_scop_params): New.
1146 (print_scop): Call print_scop_params.
1147 (debug_scop_params): New.
1148 * graphite-poly.h (print_scop_params, debug_scop_params): Declared.
1149
11502009-07-07 Li Feng <nemokingdom@gmail.com>
1151
1152 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-4.c: New.
1153 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-5.c: New.
1154 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-6.c: New.
1155 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-7.c: New.
1156 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-8.c: New.
1157 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-9.c: New.
1158
11592009-07-07 Li Feng <nemokingdom@gmail.com>
1160
1161 * graphite-clast-to-gimple.c (mark_loops_parallel): Dump information
1162 for dependency checking part.
1163 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-1.c: Add
1164 tests for dependency checking.
1165 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-2.c: Ditto.
1166 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-3.c: Ditto.
1167 * testsuite/gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: Add
1168 flag -fdump-tree-graphite-all for autopar testsuites.
1169
11702009-07-06 Sebastian Pop <sebastian.pop@amd.com>
1171
1172 * Makefile.in (tree-ssa-loop-manip.o): Depends on langhooks.h.
1173 * tree-parloops.c (rewrite_phi_with_iv, rewrite_all_phi_nodes_with_iv,
1174 canonicalize_loop_ivs): Moved...
1175 * tree-ssa-loop-manip.c: ... here. Include langhooks.h.
1176
11772009-07-06 Sebastian Pop <sebastian.pop@amd.com>
1178
1179 * tree-parloops.c (try_create_reduction_list): Pass an extra
1180 argument analyzed_reductions. Call analyze_reduction_list.
1181 (gen_parallel_loop): Do not call analyze_reduction_list.
1182 (parallelize_loops): Init and finalize analyzed_reductions.
1183
11842009-07-06 Li Feng <nemokingdom@gmail.com>
1185
1186 * testsuite/gcc.dg/graphite/graphite_autopar/graphite_autopar.exp:
1187 Added flag -fno-loop-strip-mine for autopar testcase.
1188
11892009-07-04 Li Feng <nemokingdom@gmail.com>
1190
1191 * graphite-dependences.c (graphite_carried_dependence_level_k): Use
1192 transformed scattering dimension instead of unmatch orignal when
1193 calling dependence_polyhedron.
1194
11952009-06-30 Sebastian Pop <sebastian.pop@amd.com>
1196
1197 * opts.c (decode_options): Enable flag_loop_strip_mine at -O2.
1198
11992009-06-30 Sebastian Pop <sebastian.pop@amd.com>
1200
1201 * graphite-poly.c (pbb_number_of_iterations): Check for returned
1202 value 1 from ppl_Pointset_Powerset_NNC_Polyhedron_maximize.
1203
12042009-06-30 Sebastian Pop <sebastian.pop@amd.com>
1205
1206 * graphite-blocking.c (pbb_strip_mine_profitable_p): New.
1207 (pbb_do_strip_mine): Call pbb_strip_mine_profitable_p.
1208 * graphite-poly.c (pbb_number_of_iterations): New.
1209 * graphite-poly.h (pbb_number_of_iterations): Declared.
1210 (pbb_iterator_dim, pbb_parameter_dim): New.
1211
12122009-06-29 Sebastian Pop <sebastian.pop@amd.com>
1213
1214 * graphite-clast-to-gimple.c (graphite_create_new_loop): Revert the
1215 last commit on type of lower and upper bound of loops.
1216
12172009-06-29 Li Feng <nemokingdom@gmail.com>
1218
1219 * Makefile.in (graphite-clast-to-gimple.o): Added dependence on
1220 graphite-dependences.h.
1221 * graphite-clast-to-gimple.c (new_bb_pbb_def): New.
1222 (mark_bb_with_pbb): New.
1223 (get_stmtfor_depth): New.
1224 (find_pbb_via_hash): New.
1225 (dependency_in_loop_p): New.
1226 (mark_loops_parallel): New.
1227 (free_aux_in_new_loops): New.
1228 (translate_clast): Add parameter BB_PBB_MAPPING. Mark newly created
1229 bb with it's relevant pbb. Mark newly created loops. Remove mark
1230 innermost loop parallel without checking.
1231 (gloog): Add parameter BB_PBB_MAPPING.
1232 * graphite-clast-to-gimple.h (struct bb_pbb_def): New.
1233 (gloog): Change declaration.
1234 (mark_loop_parallel): Make extern.
1235 (free_aux_in_new_loops): Declare.
1236 (bb_pbb_map_hash): New.
1237 (eq_bb_pbb_map): New.
1238 * graphite.c (graphite_transform_loops): Added BB_PBB_MAPPING. Trigger
1239 auto parallelization when flag_graphite_force_parallel is set.
1240 (graphite_finalize): Added free_aux_in_new_loops.
1241 * tree-parloops.c (parallelize_loops): Only generate parallel code for
1242 the innermost loop that marked parallel. Use
1243 flag_graphite_force_parallel instead of loop->can_be_parallel.
1244 (loop_parallel_p): Move inner most checking out of function.
1245
12462009-06-26 Sebastian Pop <sebastian.pop@amd.com>
1247
1248 * graphite-clast-to-gimple.c (graphite_create_new_loop): Make the
1249 type of lower and upper bound of loops signed long int.
1250
12512009-06-26 Sebastian Pop <sebastian.pop@amd.com>
1252
1253 * cfgloopmanip.c (create_empty_loop_on_edge): Gimplify the loop exit
1254 expression outside the loop.
1255
12562009-06-26 Sebastian Pop <sebastian.pop@amd.com>
1257
1258 * gcc.dg/graphite/interchange-8.c: New.
1259
12602009-06-26 Sebastian Pop <sebastian.pop@amd.com>
1261
1262 * gcc.dg/graphite/interchange-0.c: XFailed.
1263 * gcc.dg/graphite/interchange-5.c: XFailed.
1264 * gcc.dg/graphite/interchange-6.c: XFailed.
1265
12662009-06-26 Sebastian Pop <sebastian.pop@amd.com>
1267
1268 * graphite-interchange.c (compute_array_size_poly): The end of the
1269 recursion should return 1.
1270
12712009-06-26 Sebastian Pop <sebastian.pop@amd.com>
1272
1273 * graphite-interchange.c (compute_array_size_cstr): Allow the
1274 subscript multiplier to be -1.
1275 (compute_array_size): Use PDR_DATA_CONTAINER and not PDR_ACCESSES.
1276 * graphite-poly.c (new_poly_dr): Takes an extra argument for the
1277 data_container. Initializes PDR_DATA_CONTAINER.
1278 (print_pdr_access_layout): New.
1279 (print_pdr): Call print_pdr_access_layout. Print PDR_DATA_CONTAINER.
1280 * graphite-poly.h (struct poly_dr): Adjust comment. Add a new field
1281 data_container.
1282 (PDR_DATA_CONTAINER): New.
1283 (new_poly_dr): Update declaration.
1284 * graphite-sese-to-poly.c (pdr_add_data_dimensions): New.
1285 (build_poly_dr): Call pdr_add_data_dimensions.
1286
12872009-06-26 Sebastian Pop <sebastian.pop@amd.com>
1288
1289 * graphite-poly.h (struct poly_dr): Fix comment.
1290 * graphite-sese-to-poly.c (pdr_add_alias_set): New.
1291 (pdr_add_memory_accesses): New.
1292 (build_poly_dr): Call pdr_add_memory_accesses and pdr_add_alias_set.
1293
12942009-06-26 Sebastian Pop <sebastian.pop@amd.com>
1295
1296 * graphite-poly.c (print_pdrs, debug_pdrs): New.
1297 (print_pbb): Add call to print_pdrs.
1298 * graphite-poly.h (print_pdrs, debug_pdrs): Declared.
1299
13002009-06-24 Konrad Trifunovic <konrad.trifunovic@gmail.com>
1301 Li Feng <nemokingdom@gmail.com>
1302
1303 * graphite-dependences.c (graphite_carried_dependence_level_k): New.
1304 (dependency_between_pbbs_p): New.
1305 (lexicographically_gt_p): Assure !empty_p before polyhedron
1306 intersection assign.
1307 (build_lexicographically_gt_constraint): Correct lexicographically
1308 judging.
1309 * graphite-dependences.h: New.
1310 * Makefile.in (graphite-dependences.o): Add graphite-dependences.h.
1311
13122009-06-24 Sebastian Pop <sebastian.pop@amd.com>
1313
1314 * graphite-clast-to-gimple.c (print_clast_stmt): New.
1315 (gloog): Print to dump_file the generated clast.
1316 * graphite-clast-to-gimple.h (print_clast_stmt): Declared.
1317 * graphite-interchange.c (pbb_do_interchange): Fix dump formatting.
1318
13192009-06-24 Sebastian Pop <sebastian.pop@amd.com>
1320
1321 * graphite-poly.c (extend_scattering): Increment
1322 PBB_NB_LOCAL_VARIABLES by the number of added dimensions.
1323
13242009-06-24 Sebastian Pop <sebastian.pop@amd.com>
1325
1326 * graphite-interchange.c (compute_array_size_poly): Added exit of
1327 recursion condition. Continue iterating even after the first equality.
1328 (compute_array_size): Same.
1329
13302009-06-24 Li Feng <nemokingdom@gmail.com>
1331
1332 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-1.c: Update
1333 -fdump-tree-final_cleanup to -fdump-tree-optimized.
1334 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-2.c: Ditto.
1335 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-3.c: Ditto.
1336 * testsuite/gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: Ditto.
1337
13382009-06-23 Sebastian Pop <sebastian.pop@amd.com>
1339
1340 * sese.c (expand_scalar_variables_stmt): Expand scalar variables
1341 only when the use verifies is_gimple_reg.
1342
13432009-06-23 Sebastian Pop <sebastian.pop@amd.com>
1344
1345 * graphite-clast-to-gimple.c (build_cloog_prog): Fix memory corruption.
1346 Allocate scaldims after call to unify_scattering_dimensions.
1347
13482009-06-23 Sebastian Pop <sebastian.pop@amd.com>
1349
1350 * graphite-clast-to-gimple.c (translate_clast): Fix memory leak.
1351
13522009-06-23 Sebastian Pop <sebastian.pop@amd.com>
1353 Albert Cohen <albert.cohen@inria.fr>
1354
1355 * graphite-blocking.c (pbb_strip_mine_loop_depth): Do not use local
1356 variables for the strip mining.
1357
13582009-06-23 Sebastian Pop <sebastian.pop@amd.com>
1359 Pranav Garg <pranav.garg2107@gmail.com>
1360
1361 * Makefile.in (OBJS-common): Added graphite-blocking.o.
1362 (graphite-sese-to-poly.o): Moved down to be in lexicographical order.
1363 (graphite-blocking.o): New rule.
1364 (graphite-poly.o, graphite-ppl.o): Moved to be in lexicographical order.
1365 * graphite-blocking.c: New.
1366 * graphite-poly.c (apply_poly_transforms): Call scop_do_strip_mine for
1367 flag_loop_strip_mine.
1368 (psct_scattering_dim_for_loop_depth): New.
1369 * graphite-poly.h (scop_do_strip_mine): Declared.
1370 (psct_add_local_variable): Increment PBB_NB_LOCAL_VARIABLES.
1371 * tree-ssa-loop.c (gate_graphite_transforms): Do not fail when using
1372 flag_loop_strip_mine.
1373
13742009-06-23 Sebastian Pop <sebastian.pop@amd.com>
1375
1376 * graphite-poly.c (extend_scattering): Avoid initializing and freeing
1377 a GMP value and a PPL coefficient at each iteration of a loop.
1378
13792009-06-23 Sebastian Pop <sebastian.pop@amd.com>
1380
1381 * graphite-dependences.c (dependence_polyhedron): Do not use
1382 pbb_nb_scattering_dims anymore. Use pbb_nb_scattering_orig and
1383 pbb_nb_scattering_transform.
1384 (graphite_legal_transform_dr): Same.
1385 * graphite-poly.c (extend_scattering): Same.
1386 (unify_scattering_dimensions): Same.
1387 (print_scattering_function): Same.
1388 (new_poly_bb): Initialize PBB_NB_SCATTERING_TRANSFORM and
1389 PBB_NB_LOCAL_VARIABLES.
1390 * graphite-poly.h (pbb_nb_scattering): Removed declaration.
1391 (struct poly_bb): Added nb_local_variables and nb_scattering_transform.
1392 (PBB_NB_LOCAL_VARIABLES, PBB_NB_SCATTERING_TRANSFORM): New.
1393 (pbb_nb_scattering_orig, pbb_nb_scattering_transform): New.
1394 (pbb_nb_scattering_dims, pbb_nb_scattering): Removed.
1395 (pbb_nb_scattering_transform): New.
1396 (pbb_nb_local_vars): Return PBB_NB_LOCAL_VARIABLES.
1397 (psco_scattering_dim): Add assert on parameters.
1398 (psct_scattering_dim): Same.
1399 (psct_scattering_dim_for_loop_depth): Declared.
1400 (psct_local_var_dim): New.
1401 (psco_iterator_dim, psco_parameter_dim): Add assert on parameters.
1402 (psct_iterator_dim, psct_parameter_dim): Same. To maintain the
1403 correct layout, call pbb_nb_local_vars.
1404 (psct_add_local_variable, psct_add_scattering_dimension): New.
1405 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons):
1406 Initialize PBB_NB_SCATTERING_TRANSFORM.
1407
14082009-06-23 Sebastian Pop <sebastian.pop@amd.com>
1409
1410 * graphite-ppl.c (set_inhomogeneous): Renamed ppl_set_inhomogeneous.
1411 (set_coef): Renamed ppl_set_coef.
1412 * graphite-ppl.h (ppl_set_inhomogeneous, ppl_set_coef): Declared.
1413
14142009-06-23 Sebastian Pop <sebastian.pop@amd.com>
1415
1416 * graphite-dependences.c (build_pairwise_scheduling_inequality): Don't
1417 test a boolean against 1.
1418 * graphite-interchange.c (pbb_interchange_loop_depths): Do not build
1419 a new polyhedron for the PBB_TRANSFORMED_SCATTERING.
1420 (pbb_do_interchange): Returns true when a transform has been performed.
1421 (scop_do_interchange): Same.
1422 * graphite-poly.c (apply_poly_transforms): Use the return value of
1423 scop_do_interchange.
1424 * graphite-poly.h (scop_do_interchange): Update declaration.
1425
14262009-06-23 Tobias Grosser <grosser@fim.uni-passau.de>
1427
1428 * graphite-clast-to-gimple.c (gloog): Reset loop->aux right
1429 after last use.
1430 * sese.c (sese_reset_aux_in_loops): New.
1431 * sese.h (sese_reset_aux_in_loops): New.
1432
14332009-06-19 Sebastian Pop <sebastian.pop@amd.com>
1434
1435 * graphite-sese-to-poly.c (scan_tree_for_params_int): Pass in the
1436 multiplier and multiply the constant by the multiplier.
1437 (scan_tree_for_params): Bound the multiplier to its MULT_EXPR.
1438 (build_poly_dr): Do not use the multiplier to define the subscript.
1439
14402009-06-19 Sebastian Pop <sebastian.pop@amd.com>
1441
1442 * graphite-poly.c (new_poly_dr): Pass an extra argument for the
1443 compiler's data reference. Initialize PDR_CDR.
1444 (print_pdr): Call dump_data_reference.
1445 * graphite-poly.h (struct poly_dr): Rename black_box into pbb.
1446 Add compiler_dr field.
1447 (PDR_BB): Renamed PDR_PBB.
1448 (PDR_CDR): New.
1449 * graphite-sese-to-poly.c (build_poly_dr): Pass to new_poly_dr
1450 GCC's data reference representation.
1451 * tree-data-ref.c (debug_data_references, debug_data_reference): New.
1452 * tree-data-ref.h (debug_data_references, debug_data_reference): Decl.
1453
14542009-06-19 Sebastian Pop <sebastian.pop@amd.com>
1455
1456 * graphite-poly.c (print_scattering_function): Also print the layout.
1457 * graphite-poly.h (pbb_nb_local_vars): New.
1458
14592009-06-19 Sebastian Pop <sebastian.pop@amd.com>
1460
1461 * graphite-poly.c (print_pbb_domain): Also print the layout names.
1462
14632009-06-19 Sebastian Pop <sebastian.pop@amd.com>
1464
1465 * graphite-poly.c (print_pdr, debug_pdr): New.
1466 * graphite-poly.h (print_pdr, debug_pdr): Declared.
1467 (PDR_BASE): Removed.
1468
14692009-06-18 Sebastian Pop <sebastian.pop@amd.com>
1470
1471 * gcc/testsuite/gcc.dg/graphite/interchange-{1..7}.c: New avatars of
1472 ltrans-{1..6,8}.c.
1473
14742009-06-18 Sebastian Pop <sebastian.pop@amd.com>
1475
1476 * graphite-interchange.c (compute_subscript): Allow also -1 in the
1477 subscript identification column.
1478 (pbb_do_interchange): Print to dump_file that some loops "will be
1479 interchanged". Rely on that chain of characters in the testcases.
1480 * gcc.dg/graphite/interchange-0.c: New.
1481 * gcc.dg/graphite/graphite.exp: Iterate over the testsuite
1482 interchange-*.c files and compile them with -floop-interchange.
1483
14842009-06-18 Pranav Garg <pranav.garg2107@gmail.com>
1485
1486 * graphite-interchange.c (interchange_profitable_p): Renamed
1487 pbb_interchange_profitable_p.
1488
14892009-06-18 Sebastian Pop <sebastian.pop@amd.com>
1490 Harsha Jagasia <harsha.jagasia@amd.com>
1491 Pranav Garg <pranav.garg2107@gmail.com>
1492
1493 * graphite-interchange.c (interchange_profitable_p): Make static.
1494 (pbb_interchange_loop_depths, pbb_do_interchange,
1495 scop_do_interchange): New.
1496 * graphite-poly.c (apply_poly_transforms): Call scop_do_interchange
1497 for flag_loop_interchange.
1498 * graphite-poly.h (scop_do_interchange): Declared.
1499 * tree-ssa-loop.c (gate_graphite_transforms): Do not fail when
1500 flag_loop_interchange is used.
1501
15022009-06-18 Sebastian Pop <sebastian.pop@amd.com>
1503
1504 * graphite-dependences.c (dependence_polyhedron): Update use of
1505 pbb_nb_scattering_dims.
1506 * graphite-poly.h (pbb_nb_scattering_dims): Do not pass SCOP.
1507 (pbb_nb_scattering): Update use of pbb_nb_scattering_dims.
1508 (psco_scattering_dim, psct_scattering_dim, psco_iterator_dim,
1509 psct_iterator_dim, psco_parameter_dim, psct_parameter_dim): New.
1510
15112009-06-16 Sebastian Pop <sebastian.pop@amd.com>
1512
1513 * graphite.c: Cleanup foo.
1514
15152009-06-16 Sebastian Pop <sebastian.pop@amd.com>
1516
1517 * Merge from mainline (r143684:148293).
1518 * Disabled libpcp until it gets fixed.
1519
15202009-06-05 Sebastian Pop <sebastian.pop@amd.com>
1521 Harsha Jagasia <harsha.jagasia@amd.com>
1522
1523 * graphite-interchange.c: New.
1524 * Makefile.in (graphite-interchange.o): New.
1525 * graphite-poly.h (interchange_profitable_p): Declared.
1526 * graphite-ppl.h (value_max): New.
1527
15282009-06-04 Sebastian Pop <sebastian.pop@amd.com>
1529
1530 * graphite-dependences.c (dependence_polyhedron): Use pdr_dim.
1531 * graphite-poly.h: Fix some comments.
1532 (pdr_dim): New.
1533 (pdr_scop): New.
1534
15352009-06-04 Sebastian Pop <sebastian.pop@amd.com>
1536
1537 * graphite-poly.h
1538 (pdr_accessp_nb_subscripts): Renamed pdr_nb_subscripts.
1539 (pdr_accessp_nb_iterators): Renamed pdr_dim_iter_domain.
1540 (pdr_accessp_nb_params): Renamed pdr_nb_params.
1541 (pdr_accessp_alias_set_dim): Renamed pdr_alias_set_dim.
1542 (pdr_accessp_subscript_dim): Renamed pdr_subscript_dim.
1543 (pdr_accessp_iterator_dim): Renamed pdr_iterator_dim.
1544 (pdr_accessp_param_dim): Renamed pdr_parameter_dim.
1545 (pbb_nb_loops): Renamed pbb_dim_iter_domain.
1546 * graphite-clast-to-gimple.c: Same.
1547 * graphite-dependences.c: Same.
1548 * graphite-poly.c: Same.
1549 * graphite-sese-to-poly.c: Same.
1550
15512009-06-03 Sebastian Pop <sebastian.pop@amd.com>
1552
1553 * graphite-clast-to-gimple.c (build_iv_mapping): Insert full
1554 expressions for an IV rename, as returned by clast_to_gcc_expression.
1555 (copy_renames): Rename new_name to expr.
1556 * sese.c (debug_rename_elt): Same.
1557 (get_rename): Same.
1558 (set_rename): Same.
1559 (sese_adjust_liveout_phis): Call force_gimple_operand before using
1560 the information from the rename map.
1561 (rename_variables_in_stmt): Same.
1562 (add_loop_exit_phis): Rename new_name to expr.
1563 (insert_loop_close_phis): Same.
1564 (add_guard_exit_phis): Same. Call force_gimple_operand.
1565 * sese.h (struct rename_map_elt): Rename new_name to expr.
1566 (new_rename_map_elt): Same.
1567
15682009-06-03 Sebastian Pop <sebastian.pop@amd.com>
1569
1570 * graphite-clast-to-gimple.c (build_iv_mapping): Use set_rename.
1571 * sese.c (set_rename): Make it extern.
1572 * sese.h (set_rename): Declared.
1573
15742009-06-03 Sebastian Pop <sebastian.pop@amd.com>
1575
1576 * graphite-poly.c (extend_scattering): Free values.
1577 * graphite-ppl.c (new_Cloog_Domain_from_ppl_Pointset_Powerset):
1578 Free iterators.
1579 (ppl_print_powerset_matrix): Same.
1580 * graphite-scop-detection.c (free_scops_1): New.
1581 (limit_scops): Call free_scops_1.
1582 * graphite-sese-to-poly.c (build_scop_bbs_1): Free dom.
1583 (build_poly_dr): Free PPL coefficients.
1584 * tree-parloops.c (rewrite_all_phi_nodes_with_iv): Free bbs.
1585
15862009-06-02 Sebastian Pop <sebastian.pop@amd.com>
1587
1588 * graphite-dependences.c: New.
1589 * graphite-data-ref.c: Removed.
1590 * graphite-data-ref.h: Removed.
1591 * Makefile.in (graphite-data-ref.o): Removed.
1592 (graphite-dependences.o): Added.
1593 * graphite-clast-to-gimple.c: Remove dependence on graphite-data-ref.h.
1594 * graphite-poly.c: Same.
1595 Move the data dependence testing to graphite-dependences.c.
1596
15972009-05-19 Tobias Grosser <grosser@fim.uni-passau.de>
1598
1599 * graphite-scop-detection.c (graphite_can_represent_loop): Renamed
1600 from graphite_cannot_represent_loop. Code refactored.
1601 (scopdet_basic_block_info): Call graphite_can_represent_loop.
1602
16032009-05-17 Li Feng <nemokingdom@gmail.com>
1604
1605 * testsuite/gcc.dg/graphite/graphite_autopar/graphite_autopar.exp:
1606 Cover all the testcases (not only the filtered ones).
1607
16082009-05-17 Tobias Grosser <grosser@fim.uni-passau.de>
1609
1610 * graphite-scop-detection.c (stmt_simple_for_scop_p): Remove
1611 unnecessary check. Update comments. Move check for REAL_TYPE here.
1612 (harmful_stmt_in_bb): Remove checks for conditions. This is already
1613 done in (stmt_simple_for_scop_p).
1614
16152009-05-14 Tobias Grosser <grosser@fim.uni-passau.de>
1616
1617 * graphite.c (print_global_statistics): New.
1618 (print_graphite_scop_statistic): New.
1619 (print_graphite_statistics): New.
1620 (graphite_initialize, graphite_transform_loops): Print statistics.
1621 * graphite-scop-detection (build_scops): Print statistics.
1622 (print_graphite_scop_statistics): New.
1623 (print_graphite_statistics): New.
1624
16252009-05-13 Sebastian Pop <sebastian.pop@amd.com>
1626
1627 * graphite-clast-to-gimple.c (struct clast_name_index): Removed.
1628 (debug_clast_name_index): Removed.
1629 (debug_clast_name_indexes_1): Removed.
1630 (debug_clast_name_indexes): Removed.
1631 (clast_name_index_elt_info): Removed.
1632 (eq_clast_name_indexes): Removed.
1633 (clast_name_to_index): Removed.
1634 (new_clast_name_index): Removed.
1635 (save_clast_name_index): Removed.
1636 (save_var_name): Moved...
1637 (init_sese_params_index): Removed.
1638 (clast_name_to_gcc): Remove use of name_tree.
1639 (initialize_cloog_names): Same.
1640 (gloog): Do not call init_sese_params_index.
1641 * graphite-sese-to-poly.c (save_var_name): ...here.
1642 (parameter_index_in_region): New.
1643 * sese.c (new_sese): Initialize SESE_PARAMS_NAMES.
1644 (parameter_index_in_region): Removed.
1645 (is_parameter): Remove use of name_tree.
1646 * sese.h (struct name_tree): Removed.
1647 (struct sese): Remove use of name_tree. New field params_names.
1648 (SESE_PARAMS_NAMES): New.
1649 (SESE_PARAMS): Remove duplicate.
1650 (parameter_index_in_region): Removed.
1651 (sese_nb_params): Remove use of name_tree.
1652 (struct clast_name_index): New.
1653 (new_clast_name_index): New.
1654 (clast_name_to_index): New.
1655 (save_clast_name_index): New.
1656 (debug_clast_name_index): New.
1657 (debug_clast_name_indexes_1): New.
1658 (debug_clast_name_indexes): New.
1659 (clast_name_index_elt_info): New.
1660 (eq_clast_name_indexes): New.
1661
16622009-05-13 Sebastian Pop <sebastian.pop@amd.com>
1663
1664 * graphite-clast-to-gimple.c (compute_cloog_iv_types_1): Call
1665 pbb_to_depth_to_oldiv. Remove call to oldiv_for_loop.
1666 (graphite_loop_normal_form): Do not pass region. Do not
1667 initialize SESE_OLDIVS.
1668 (build_graphite_loop_normal_form): Update call to
1669 graphite_loop_normal_form.
1670 * sese.c (debug_oldivs): Removed.
1671 (new_sese): Do not initialize SESE_OLDIVS.
1672 (free_sese): Do not free SESE_OLDIVS.
1673 (oldiv_for_loop): Removed.
1674 * sese.h (struct sese): Remove old_ivs.
1675 (SESE_OLDIVS): Removed.
1676 (oldiv_for_loop): Removed.
1677
16782009-05-13 Sebastian Pop <sebastian.pop@amd.com>
1679
1680 * graphite-clast-to-gimple.c (clast_name_to_gcc): Pass newivs,
1681 remove ivstack. Remove call to loop_iv_stack_get_iv_from_name,
1682 replaced by a call to newivs_to_depth_to_newiv.
1683 (clast_to_gcc_expression): Pass newivs, remove ivstack.
1684 (clast_to_gcc_expression_red): Same.
1685 (gcc_type_for_clast_expr): Same.
1686 (gcc_type_for_clast_eq): Same.
1687 (graphite_translate_clast_equation): Same.
1688 (graphite_create_guard_cond_expr): Same.
1689 (graphite_create_new_guard): Same.
1690 (graphite_create_new_loop): Same.
1691 (build_iv_mapping): Same.
1692 (translate_clast): Same.
1693 (gloog): Same.
1694 (loop_iv_stack_patch_for_consts): Removed. *
1695 sese.c (iv_stack_entry_is_constant): Removed.
1696 (iv_stack_entry_is_iv): Removed.
1697 (loop_iv_stack_push_iv): Removed.
1698 (loop_iv_stack_insert_constant): Removed.
1699 (loop_iv_stack_pop): Removed.
1700 (loop_iv_stack_get_iv): Removed.
1701 (loop_iv_stack_get_iv_from_name): Removed.
1702 (debug_loop_iv_stack): Removed.
1703 (free_loop_iv_stack): Removed.
1704 (loop_iv_stack_remove_constants): Removed. *
1705 sese.h (iv_stack_entry_kind): Removed.
1706 (iv_stack_entry_data_union): Removed.
1707 (iv_stack_entry_struct): Removed.
1708 (iv_stack_entry_p): Removed.
1709 (debug_oldivs, debug_loop_iv_stack, loop_iv_stack_insert_constant,
1710 loop_iv_stack_get_iv_from_name, loop_iv_stack_push_iv,
1711 loop_iv_stack_get_iv, loop_iv_stack_remove_constants,
1712 loop_iv_stack_pop, free_loop_iv_stack): Removed.
1713 (gbb_loop_at_index): Fix indenting.
1714 (gbb_loop_index): Removed.
1715
17162009-05-13 Sebastian Pop <sebastian.pop@amd.com>
1717
1718 * graphite-clast-to-gimple.c (clast_name_to_gcc): Do not use strcmp.
1719 Call clast_name_to_index.
1720
17212009-05-13 Sebastian Pop <sebastian.pop@amd.com>
1722
1723 * graphite-clast-to-gimple.c (clast_name_to_gcc): Pass region,
1724 do not pass params. Get params from SESE_PARAMS.
1725 (clast_to_gcc_expression): Same.
1726 (clast_to_gcc_expression_red): Same.
1727 (gcc_type_for_clast_eq): Same.
1728 (graphite_translate_clast_equation): Same.
1729 (graphite_create_new_loop): Same.
1730 * sese.c (rename_variables_in_stmt): Fix comment.
1731
17322009-05-13 Sebastian Pop <sebastian.pop@amd.com>
1733
1734 * graphite-clast-to-gimple.c (graphite_create_new_loop): Pass
1735 newivs_index.
1736 Call save_clast_name_index.
1737 (translate_clast): Pass newivs_index.
1738 (gloog): Create and free newivs_index.
1739
17402009-05-13 Sebastian Pop <sebastian.pop@amd.com>
1741
1742 * graphite-clast-to-gimple.c (clast_name_index): New structure.
1743 (clast_name_index_p): New type.
1744 (debug_clast_name_index): New.
1745 (debug_clast_name_indexes_1): New.
1746 (debug_clast_name_indexes): New.
1747 (clast_name_index_elt_info): New.
1748 (eq_clast_name_indexes): New.
1749 (clast_name_to_index): New.
1750 (new_clast_name_index): New.
1751 (save_clast_name_index): New.
1752 (init_sese_params_index): New.
1753 (gloog): Call init_sese_params_index.
1754 * graphite-clast-to-gimple.h (debug_clast_name_indexes): Declared.
1755 * sese.c (new_sese): Initialize SESE_PARAMS_INDEX.
1756 (free_sese): Free SESE_PARAMS_INDEX.
1757 * sese.h (struct sese): Add params_index.
1758 (SESE_PARAMS_INDEX): New.
1759
17602009-05-13 Sebastian Pop <sebastian.pop@amd.com>
1761
1762 * graphite-clast-to-gimple.c (newivs_to_depth_to_newiv): New.
1763 (graphite_create_new_loop): Pass the newivs vector. Push the
1764 newly created IV to newivs.
1765 (translate_clast): Pass the newivs vector.
1766 (gloog): Create and destroy the newivs vector.
1767
17682009-05-13 Sebastian Pop <sebastian.pop@amd.com>
1769
1770 * graphite-clast-to-gimple.c (pbb_to_depth_to_oldiv): New.
1771 (graphite_loop_normal_form): Initialize loop->aux with the unique
1772 IV that has been created.
1773
17742009-05-13 Tobias Grosser <grosser@fim.uni-passau.de>
1775
1776 * tree-chrec.c (evolution_function_right_is_integer_cst): Allow
1777 scev with parameters in the base part. They where forbidden
1778 exidently.
1779
17802009-05-11 Li Feng <nemokingdom@gmail.com>
1781
1782 * testsuite/gcc.dg/graphite/graphite.exp: Set different default
1783 compile options by file names.
1784 * testsuite/gcc.dg/graphite/block{0-6}.c: Remove dg-option line.
1785 * testsuite/gcc.dg/graphite/id-{1-9}.c: Ditto.
1786 * testsuite/gcc.dg/graphite/scop-{0-20}.c: Ditto.
1787 * testsuite/gcc.dg/graphite/scop-matmult.c: Ditto.
1788
17892009-05-08 Li Feng <nemokingdom@gmail.com>
1790
1791 * testsuite/gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: New.
1792 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-1.c: New.
1793 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-2.c: New.
1794 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-3.c: New.
1795
17962009-05-07 Tobias Grosser <grosser@fim.uni-passau.de>
1797
1798 * graphite-scop-detection (build_scops_1): Fix little bug introduced
1799 by final cleanup.
1800
18012009-05-07 Tobias Grosser <grosser@fim.uni-passau.de>
1802
1803 * graphite-scop-detection.c (graphite_can_represent_scev): Only
1804 allow integer constant strides.
1805 (graphite_can_represent_expr): Depend on outermost_loop.
1806 (stmt_simple_memref_p, graphite_cannot_represent_loop,
1807 harmful_stmt_in_bb, is_simple_operand, stmt_simple_for_scop_p,
1808 build_scops_1): Same.
1809 (scopdet_basic_block_info): Same and insert layered SCoP
1810 detection.
1811 (try_generate_gimple_bb): Cleanup.
1812 (build_scops): Enable data references.
1813
1814 * testsuite/gcc.dg/graphite/id-5.c: New.
1815 * testsuite/gcc.dg/graphite/id-9.c: New.
1816 * tree-chrec.c (evolution_function_right_is_integer_cst): New.
1817 * tree-chrec.h (evolution_function_right_is_integer_cst): New.
1818
18192009-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
1820
1821 * sese.c (expand_scalar_variables_ssa_name): Only build expressions,
1822 that we have not yet built for this SCoP.
1823
18242009-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
1825
1826 * sese.c (expand_scalar_variables_expr): Fix expand_scalar_variables
1827 for complex numbers.
1828
18292009-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
1830
1831 * graphite-ppl.c: Fix build if cloog is not available.
1832
18332009-05-04 Li Feng <nemokingdom@gmail.com>
1834
1835 * tree-parloops.c (loop_parallel_p): Remove construction of
1836 NITER and REDUCTION_LIST.
1837 (try_get_loop_niter): New.
1838 (try_create_reduction_list): New.
1839 (parallelize_loops): Bypass the failed checkings in autopar
1840 when can_be_parallel in loop structure is set to true.
1841
18422009-05-01 Tobias Grosser <grosser@fim.uni-passau.de>
1843
1844 * testsuite/gcc.dg/graphite/id-6.c: Update testcase.
1845 * testsuite/gcc.dg/graphite/scop-3.c: Dito.
1846
18472009-05-01 Tobias Grosser <grosser@fim.uni-passau.de>
1848
1849 * graphite-scop-detection.c (stmt_simple_for_scop_p):
1850 Enable EQ_EXPR and NE_EXPR again.
1851
18522009-04-30 Tobias Grosser <grosser@fim.uni-passau.de>
1853
1854 * graphite-scop-detection.c (graphite_can_represent_scev):
1855 Add check if scev is affine multivariate.
1856 (harmful_stmt_in_bb): Check if we can represent the conditions.
1857 (scopdet_basic_block_info (basic_block bb, VEC): Pass the loop to
1858 harmful_stmt_in_bb.
1859 * testsuite/gcc.dg/graphite/id-7.c: New.
1860
18612009-04-30 Tobias Grosser <grosser@fim.uni-passau.de>
1862
1863 * graphite-sese-to-poly.c (bb_contains_non_iv_scalar_phi_nodes):
1864 Check all bbs in region, not only the bbs that are represented in
1865 GRAPHITE.
1866 (build_poly_scop): Add newline.
1867 * testsuite/gcc.dg/graphite/id-8.c: New.
1868
18692009-04-30 Li Feng <nemokingdom@gmail.com>
1870
1871 * cfgloop.c (alloc_loop): Initialize can_be_parallel to false
1872 when loop initialize.
1873 * cfgloop.h (struct loop): Introduce flag can_be_parallel.
1874 * common.opt: Declare flag_graphite_force_parallel.
1875 * graphite-clast-to-gimple.c (translate_clast): Mark the innermost
1876 loop parallel.
1877 * graphite-poly.c (apply_poly_transforms): Introduce
1878 flag_graphite_force_parallel.
1879 * tree-ssa-loop.c (gate_graphite_transforms): ditto.
1880 * toplev.c (process_options): ditto and replace a not correctly
1881 encoded space.
1882
18832009-04-30 Li Feng <nemokingdom@gmail.com>
1884
1885 * graphite-clast-to-gimple.c (loop_iv_stack_patch_for_consts):
1886 Change the call of gbb_loop_at_index and/or gbb_loop_index due
1887 to the redefinition.
1888 (compute_cloog_iv_types_1): ditto.
1889 (build_iv_mapping): ditto.
1890 * graphite-sese-to-poly.c (new_gimple_bb): Remove GBB_LOOPS related
1891 initialization.
1892 (free_gimple_bb): Removed GBB_LOOPS related free part.
1893 (build_bb_loops): Removed.
1894 * sese.h (struct gimple_bb): Removed loops.
1895 (GBB_LOOPS): Removed.
1896 (gbb_loop_at_index): Instead of using GBB_LOOPS, we use sese instead.
1897 (gbb_loop_index): ditto.
1898
18992009-04-24 Tobias Grosser <grosser@fim.uni-passau.de>
1900
1901 * graphite-scop-detection.c (graphite_can_represent_scev): Do not
1902 allow non constant strides.
1903 * testsuite/gcc.dg/graphite/scop-20.c: New.
1904
19052009-04-24 Sebastian Pop <sebastian.pop@amd.com>
1906
1907 * graphite-scop-detection.c (dot_all_scops): Fix system call
1908 return value warning.
1909 (dot_scop): Same.
1910
19112009-04-24 Sebastian Pop <sebastian.pop@amd.com>
1912
1913 * testsuite/gcc.dg/graphite/id-6.c: Fix pattern.
1914 * testsuite/gcc.dg/graphite/scop-3.c: Same.
1915
19162009-04-24 Sebastian Pop <sebastian.pop@amd.com>
1917
1918 * graphite-poly.c (map_into_dep_poly, map_dr_into_dep_poly,
1919 build_pairwise_constraint, dr_equality_constraints,
1920 build_pairwise_scheduling_equality,
1921 build_pairwise_scheduling_inequality, lexicographically_gt_p,
1922 build_lexicographically_gt_constraint, dependence_polyhedron,
1923 graphite_legal_transform_dr, graphite_legal_transform_bb,
1924 graphite_legal_transform): New.
1925 * graphite-poly.h (graphite_legal_transform): Declared.
1926 * graphite-sese-to-poly.c (build_poly_scop): Call to
1927 graphite_legal_transform is disabled for the moment.
1928
19292009-04-24 Sebastian Pop <sebastian.pop@amd.com>
1930
1931 * graphite-poly.h (pbb_nb_scattering_dims): New.
1932 (pbb_nb_scattering): Use it.
1933
19342009-04-24 Sebastian Pop <sebastian.pop@amd.com>
1935
1936 * graphite-ppl.c (ppl_insert_dimensions_pointset): Add
1937 Pointset_Powerset version of ppl_insert_dimensions.
1938 * graphite-ppl.h (ppl_insert_dimensions_pointset): Declared.
1939
19402009-04-24 Sebastian Pop <sebastian.pop@amd.com>
1941
1942 * graphite-ppl.c (ppl_insert_dimensions): Fix formatting.
1943
19442009-04-24 Sebastian Pop <sebastian.pop@amd.com>
1945
1946 * graphite-poly.h: Fix comment.
1947
19482009-04-24 Sebastian Pop <sebastian.pop@amd.com>
1949
1950 * graphite-sese-to-poly.c (build_poly_dr): Fix data ref multiplier.
1951
19522009-04-24 Tobias Grosser <grosser@fim.uni-passau.de>
1953
1954 * sese.c (expand_scalar_variables_stmt): Only iterate over the old
1955 statements.
1956
19572009-04-24 Tobias Grosser <grosser@fim.uni-passau.de>
1958
1959 * graphite-sese-to-poly.c (var_used_in_not_loop_header_phi_node): New.
1960 (graphite_stmt_p): Represent bbs necessary to build the phi nodes of
1961 conditions.
1962
19632009-04-20 Sebastian Pop <sebastian.pop@amd.com>
1964
1965 * graphite-scop-detection.c (stmt_simple_for_scop_p): Do not
1966 handle EQ_EXPR and NE_EXPR.
1967
19682009-04-17 Tobias Grosser <grosser@fim.uni-passau.de>
1969
1970 * graphite-poly.h (poly_dr): Fix comment.
1971
19722009-04-09 Sebastian Pop <sebastian.pop@amd.com>
1973 Tobias Grosser <grosser@fim.uni-passau.de>
1974
1975 * graphite-poly.c (new_poly_bb): Do not initialize PBB_DOMAIN
1976 with a zero dimension polyhedron.
1977 (find_scop_parameters): Move the call to scop_set_nb_params here.
1978 (build_loop_iteration_domains): Store in loop->aux the iteration
1979 domain polyhedron.
1980 (build_scop_iteration_domain): Fix PBB_DOMAIN for bbs not surrounded
1981 by any loop in scop.
1982 (build_poly_scop): Do not call scop_set_nb_params.
1983
19842009-04-09 Sebastian Pop <sebastian.pop@amd.com>
1985 Tobias Grosser <grosser@fim.uni-passau.de>
1986
1987 * graphite-sese-to-poly.c (add_condition_to_pbb): Pass code to
1988 add_condition_to_domain not GT_EXPR.
1989
19902009-04-09 Tobias Grosser <grosser@fim.uni-passau.de>
1991
1992 * graphite-ppl.c (debug_ppl_powerset_matrix): New.
1993 * graphite-ppl.h (debug_ppl_powerset_matrix): New.
1994 * graphite-sese-to-poly.c (add_condition_to_pbb): Use
1995 upper_bound_assign to calculate unions.
1996 * testsuite/gcc.dg/graphite/id-6.c: New.
1997
19982009-04-09 Tobias Grosser <grosser@fim.uni-passau.de>
1999
2000 * graphite-scop-detection.c (canonicalize_loop_closed_ssa): Do not
2001 handle abnormal edges.
2002
20032009-04-09 Tobias Grosser <grosser@fim.uni-passau.de>
2004
2005 * graphite-poly.c (new_poly_dr, free_poly_dr): New.
2006 (free_poly_bb): Also free poly_drs.
2007 * graphite-poly.h (new_poly_dr, free_poly_dr): New.
2008 (poly_dr): Polyhedron to Pointset_Powerset.
2009 (pdr_accessp_nb_subscripts): Same.
2010 * graphite-sese-to-poly.c (build_poly_dr): Same. And actually build
2011 poly_drs.
2012
20132009-04-08 Sebastian Pop <sebastian.pop@amd.com>
2014
2015 * graphite-clast-to-gimple.c (initialize_cloog_names): Change cloog
2016 names into more meaningful names.
2017
20182009-04-08 Sebastian Pop <sebastian.pop@amd.com>
2019
2020 * testsuite/gfortran.dg/graphite/interchange-1.c: New.
2021 * testsuite/gfortran.dg/graphite/interchange-2.c: New.
2022
20232009-04-08 Sebastian Pop <sebastian.pop@amd.com>
2024
2025 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not build
2026 the reduction_list.
2027 * tree-parloops.c (rewrite_phi_with_iv): New.
2028 (rewrite_all_phi_nodes_with_iv): New.
2029 (canonicalize_loop_ivs): Call them.
2030
20312009-04-08 Sebastian Pop <sebastian.pop@amd.com>
2032
2033 * graphite-sese-to-poly.c (try_generate_gimple_bb): Use
2034 graphite_find_data_references_in_stmt.
2035 * tree-data-ref.c (graphite_find_data_references_in_stmt): New.
2036 * tree-data-ref.h (graphite_find_data_references_in_stmt): Declared.
2037
20382009-04-08 Sebastian Pop <sebastian.pop@amd.com>
2039
2040 * sese.c (add_loop_exit_phis): Don't fail on non SSA_NAME renames.
2041
20422009-04-08 Sebastian Pop <sebastian.pop@amd.com>
2043
2044 * graphite-sese-to-poly.c (build_scop_bbs_1): Use bb_in_sese_p
2045 instead of bb_in_region.
2046 (flag_bb_in_region): Same. Renamed flag_bb_in_sese.
2047 (build_sese_conditions): Use flag_bb_in_sese.
2048 * sese.c (register_bb_in_sese): Removed.
2049 (new_sese): Remove initialization of SESE_REGION_BBS.
2050 (free_sese): Do not free SESE_REGION_BBS.
2051 * sese.h (struct sese): Remove field region_basic_blocks.
2052 (SESE_REGION_BBS): Removed.
2053 (bb_in_sese_p): Implement in function of bb_in_region.
2054
20552009-04-08 Sebastian Pop <sebastian.pop@amd.com>
2056
2057 * graphite-scop-detection.c (limit_scops): Deal only with single exit
2058 loops.
2059
20602009-04-08 Tobias Grosser <grosser@fim.uni-passau.de>
2061
2062 * graphite-scop-detection.c (stmt_simple_for_scop_p): Allow NE_EXPR
2063 and EQ_EXPR.
2064 * graphite-sese-to-poly.c (create_linear_expr_from_tree): New.
2065 (add_condition_to_domain): New.
2066 (add_condition_to_pbb): New.
2067 (add_conditions_to_domain): Cleanup and handle of NE_EXPR and EQ_EXPR.
2068 * testsuite/gcc.dg/graphite/scop-3.c: Update number of detected SCoPs.
2069
20702009-04-08 Tobias Grosser <grosser@fim.uni-passau.de>
2071
2072 * graphite-clast-to-gimple.c (build_cloog_prog): ppl_Polyhedron ->
2073 ppl_Pointset_Powerset.
2074 * graphite-poly.c (new_poly_bb, free_poly_bb): Same.
2075 * graphite-poly.h (poly_bb): poly_bb.domain Same.
2076 (pbb_nb_loops): Same.
2077 * graphite-sese-to-poly.c (build_loop_iteration_domains,
2078 add_conditions_to_domain): Same.
2079 * graphite-ppl.c (new_Cloog_Domain_from_ppl_Pointset_Powerset): New.
2080 (ppl_print_polyhedron_matrix): ppl_Polyhedron_t ->
2081 ppl_const_Polyhedron_t.
2082 (ppl_print_powerset_matrix): New.
2083 * graphite-ppl.h (new_Cloog_Domain_from_ppl_Pointset_Powerset,
2084 ppl_print_powerset_matrix): New.
2085 (ppl_print_polyhedron_matrix): Updated.
2086
20872009-04-07 Sebastian Pop <sebastian.pop@amd.com>
2088
2089 * tree-scalar-evolution.c (analyze_scalar_evolution_1): Fix comment.
2090
20912009-04-07 Sebastian Pop <sebastian.pop@amd.com>
2092
2093 * graphite-poly.c (extend_scattering): Fix indenting. Free cstr.
2094 (print_iteration_domains, debug_iteration_domain,
2095 debug_iteration_domains): New.
2096 * graphite-poly.h (print_iteration_domains, debug_iteration_domain,
2097 debug_iteration_domains): Declared.
2098 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons): Fix
2099 indenting.
2100
21012009-04-03 Tobias Grosser <grosser@fim.uni-passau.de>
2102 Sebastian Pop <sebastian.pop@amd.com>
2103
2104 * graphite-poly.h (print_iteration_domain): New.
2105 * graphite-sese-to-poly.c (add_conditions_to_domain): Fixed bug.
2106 (build_sese_conditions_1, build_sese_conditions_after,
2107 build_sese_conditions_before): New.
2108 (build_sese_conditions): Rewritten.
2109
21102009-04-03 Sebastian Pop <sebastian.pop@amd.com>
2111 Tobias Grosser <grosser@fim.uni-passau.de>
2112
2113 Cleanup of code generation liveouts.
2114 * graphite-clast-to-gimple.c (translate_clast): Use a single
2115 rename_map instead of one per translated statement.
2116 Do not use SESE_LIVEOUT_RENAMES.
2117 (graphite_loop_normal_form): Do not use SESE_REDUCTION_LIST.
2118 (gloog): Do not use SESE_LIVEOUT_RENAMES.
2119 * graphite-scop-detection.c (harmful_stmt_in_bb): Return the close
2120 phi node of a reduction: when a loop contains a reduction used outside
2121 the loop, there should be a scalar close phi node on the exit block.
2122 * sese.c (new_sese): Do not initialize SESE_LIVEOUT,
2123 SESE_LIVEOUT_RENAMES, and SESE_REDUCTION_LIST.
2124 (free_sese): Do not free them.
2125 (sese_build_liveouts_use): Do not use them.
2126 (sese_build_liveouts_bb): Same.
2127 (sese_build_liveouts): Same.
2128 (sese_insert_phis_for_liveouts): Same.
2129 (sese_adjust_phis_for_liveouts): Same. Renamed sese_adjust_liveout_phis.
2130 (defined_in_loop_p): New.
2131 (alive_after_loop): New.
2132 (close_phi_not_yet_inserted_p): New.
2133 (struct alep, alep_p): New.
2134 (add_loop_exit_phis): Remove from the rename_map all the names defined
2135 in the code generated loop.
2136 (insert_loop_close_phis): Traverse the rename_map passed to it.
2137 Don't use SESE_LIVEOUT_RENAMES.
2138 (default_liveout_before_guard): Renamed default_before_guard.
2139 (insert_guard_phis): Do not use SESE_LIVEOUT_RENAMES.
2140 (graphite_copy_stmts_from_block): Do not directly call set_rename.
2141 (register_sese_liveout_renames): Removed.
2142 (copy_bb_and_scalar_dependences): Do not call it.
2143 * sese.h (struct sese): Removed fields: liveout, liveout_renames, and
2144 reduction_list.
2145 (SESE_LIVEOUT): Removed.
2146 (SESE_LIVEOUT_RENAMES): Removed.
2147 (SESE_REDUCTION_LIST): Removed.
2148 (sese_build_liveouts): Removed.
2149 (sese_adjust_phis_for_liveouts): Renamed sese_adjust_liveout_phis.
2150 (insert_loop_close_phis): Pass a htab_t instead of a sese.
2151 (insert_guard_phis): Same.
2152 (rename_map_elt): Declare a VEC of them.
2153 * tree-parloops.c (canonicalize_loop_ivs): reduction_list contains
2154 trees not pointers to trees.
2155
2156 Rewrite in canonical close SSA form:
2157 * graphite-scop-detection.c (contains_only_close_phi_nodes): New.
2158 (limit_scops): Close the scop after the block containing the close phi
2159 nodes.
2160 (canonicalize_loop_closed_ssa): New.
2161 (canonicalize_loop_closed_ssa_form): New.
2162 (build_scops): Call canonicalize_loop_closed_ssa_form.
2163
2164 * graphite-sese-to-poly.c: Fix typos.
2165
21662009-04-03 Sebastian Pop <sebastian.pop@amd.com>
2167
2168 * graphite-poly.c (print_scattering_function, print_pbb_domain):
2169 Extended.
2170 (dump_gbb_conditions, dump_gbb_cases, print_iteration_domain): New.
2171 (print_pbb): Add conditions.
2172
21732009-04-01 Tobias Grosser <grosser@fim.uni-passau.de>
2174 Sebastian Pop <sebastian.pop@amd.com>
2175
2176 * graphite-scop-detection.c (bb_in_sd_region): Use bb_in_region.
2177 * graphite-sese-to-poly.c (all_non_dominated_preds_marked_p): New.
2178 (build_scop_bbs_1): New.
2179 (build_scop_bbs): Rewrite.
2180 * sese.h (bb_in_region): New.
2181
21822009-03-29 Tobias Grosser <grosser@fim.uni-passau.de>
2183
2184 * graphite-poly.c (new_poly_bb, free_poly_bb): Initialize/free
2185 poly_drs vector.
2186 (print_scop): Style.
2187 * graphite-poly.h (poly_bb): Add drs vector.
2188 (PBB_DRS): Add accessor.
2189 * graphite-sese-to-poly.c (build_poly_dr): New.
2190 (build_pbb_drs, build_scop_drs): New.
2191 (build_poly_scop): call build_scop_drs (Disabled at the moment).
2192
21932009-03-29 Tobias Grosser <grosser@fim.uni-passau.de>
2194
2195 * tree-ssa-loop.c: Include forgotten toplev.h
2196
21972009-03-29 Tobias Grosser <grosser@fim.uni-passau.de>
2198
2199 * graphite-poly.c: (apply_poly_transforms): sorry -> gcc_unreachable.
2200 * testsuite/gcc.dg/graphite/pr37883.c: Remove -floop-*
2201 * testsuite/gcc.dg/graphite/pr37928.c: Same
2202 * testsuite/gcc.dg/graphite/pr38409.c: Same
2203 * testsuite/gcc.dg/graphite/pr38498.c: Same
2204 * testsuite/gcc.dg/graphite/pr38559.c: Same
2205 * testsuite/gcc.dg/graphite/pr39335.c: Same
2206 * testsuite/gcc.dg/graphite/pr39335_1.c: Same
2207 * testsuite/gfortran.dg/graphite/block-2.f: Same
2208 * tree-ssa-loop.c (gate_graphite_transforms): Always fail if called
2209 with -floop-*.
2210
22112009-03-28 Tobias Grosser <grosser@fim.uni-passau.de>
2212
2213 * graphite-sese-to-poly.c (ref_nb_loops, build_access_matrix_with_af,
2214 build_access_matrix, build_scop_data_accesses): Remove access function
2215 building. (We get a new version soon).
2216 (build_bb_loops, scan_tree_for_params_right_scev): Update.
2217 * sese.h (nb_loops_around_loop_in_sese): Remove.
2218 (sese_loop_depth): Do not use SESE_LOOP_NEST any more.
2219
22202009-03-27 Tobias Grosser <grosser@fim.uni-passau.de>
2221 Sebastian Pop <sebastian.pop@amd.com>
2222
2223 * graphite-scop-detection.c (struct scopdet_info): Rename last
2224 field to exit.
2225 (scopdet_basic_block_info, build_scops_1): Don't use
2226 CDI_POST_DOMINATORS. CDI_POST_DOMINATORS should never be used.
2227
22282009-03-26 Tobias Grosser <grosser@fim.uni-passau.de>
2229 Sebastian Pop <sebastian.pop@amd.com>
2230
2231 * graphite-clast-to-gimple.c (gloog): Call sese_build_liveouts.
2232 * sese.c (sese_build_liveouts_use): Renamed from
2233 sese_build_livein_liveouts_use. Remove liveins.
2234 (sese_build_liveouts_bb): Renamed from sese_build_livein_liveouts_bb.
2235 Call sese_build_liveouts_use.
2236 (sese_build_liveouts): Renamed from sese_build_livein_liveouts.
2237 Call sese_build_liveouts_bb.
2238 (new_sese, free_sese): Remove liveins.
2239 (sese_add_exit_phis_var): Deleted.
2240 (sese_insert_phis_for_liveouts): Call sese_add_exit_phis_edge
2241 directly.
2242 (graphite_copy_stmts_from_block): Remove SESE_NUM_VER.
2243
2244 * sese.h (sese): Remove num_ver and livein.
2245 (SESE_LIVEIN, SESE_LIVEIN_VER, SESE_NUM_VER): Removed.
2246
22472009-03-25 Tobias Grosser <grosser@fim.uni-passau.de>
2248
2249 * graphite-sese-to-poly.c (build_scop_scattering): Fix compile.
2250
22512009-03-25 Tobias Grosser <grosser@fim.uni-passau.de>
2252
2253 * graphite-sese-to-poly.c (compare_prefix_loops): Removed.
2254 (build_scop_scattering): Do not use compare_prefix_loops any more.
2255 (nb_common_loops): New.
2256
22572009-03-24 Sebastian Pop <sebastian.pop@amd.com>
2258
2259 * sese.c (get_new_name_from_old_name): Renamed get_rename.
2260 (register_old_and_new_names): Renamed set_rename.
2261
22622009-03-24 Sebastian Pop <sebastian.pop@amd.com>
2263
2264 * graphite-scop-detection.h (nb_reductions_in_loop): Revert removal
2265 of the decl from the previous commit.
2266
22672009-03-24 Sebastian Pop <sebastian.pop@amd.com>
2268
2269 * graphite-scop-detection.c (dot_scop): New.
2270 * graphite-scop-detection.h (dot_scop): Declared.
2271
22722009-03-24 Sebastian Pop <sebastian.pop@amd.com>
2273
2274 * graphite-sese-to-poly.c (compare_prefix_loops): Fix compare.
2275
22762009-03-24 Sebastian Pop <sebastian.pop@amd.com>
2277
2278 * cfgloopmanip.c (create_empty_loop_on_edge): Generate the loop exit
2279 condition at the end of the loop.
2280 * graphite.c (graphite_initialize, graphite_finalize): Print to
2281 dump_file the compiled function.
2282 * graphite-clast-to-gimple.c (graphite_create_new_loop): Update use
2283 of create_empty_loop_on_edge.
2284 (translate_clast): Update the code generation of loops for the new
2285 shape of loops.
2286 * cfgloop.h (create_empty_loop_on_edge): Update declaration.
2287
22882009-03-24 Sebastian Pop <sebastian.pop@amd.com>
2289
2290 Reverted the patch from 2009-03-19.
2291
22922009-03-19 Tobias Grosser <grosser@fim.uni-passau.de>
2293
2294 * graphite-poly.c (new_poly_bb, free_poly_bb): Initialize/free
2295 poly_drs vector.
2296 (print_scop): Style.
2297 * graphite-poly.h (poly_bb): Add drs vector.
2298 (PBB_DRS): Add accessor.
2299 * graphite-sese-to-poly.c (ref_nb_loops): Remove.
2300 (build_access_matrix_with_af, build_access_matrix,
2301 build_scop_data_accesses): Delete.
2302 (build_poly_dr): New.
2303 (build_pbb_drs, build_scop_drs): New.
2304 (build_poly_scop): call build_scop_drs.
2305
23062009-03-13 Sebastian Pop <sebastian.pop@amd.com>
2307
2308 * graphite-scop-detection.c (dot_all_scops_1): Close the table
2309 once per basic block.
2310
23112009-03-13 Tobias Grosser <grosser@fim.uni-passau.de>
2312
2313 * graphite-scop-detection.c (graphite_can_represent_scev): New.
2314 (graphite_can_represent_expr): Renamed from loop_affine_expr
2315 and enhanced.
2316 (stmt_simple_for_scop_p): Call graphite_can_represent_expr.
2317 (graphite_cannot_represent_loop): Add scop_entry to parameters.
2318 (scopdet_basic_block_info): Actually define entry_block.
2319 (stmt_simple_memref_p): Moved here from ...
2320
2321 * tree-data-ref.c (stmt_simple_memref_p): here.
2322 * tree-data-ref.h (stmt_simple_memref_p): Removed.
2323
23242009-03-13 Tobias Grosser <grosser@fim.uni-passau.de>
2325
2326 * testsuite/gcc.dg/graphite/id-4.c: New.
2327
23282009-03-12 Sebastian Pop <sebastian.pop@amd.com>
2329
2330 * sese.c (expand_scalar_variables_expr): Handle tcc_comparison.
2331 (register_old_and_new_names): Update the content of the map.
2332 When there was already a rename_map_elt in the map at that
2333 location, free it.
2334 (copy_bb_and_scalar_dependences): Do rename_variables after
2335 expand_scalar_variables.
2336 * graphite-clast-to-gimple.c (build_iv_mapping): Update the content
2337 of the map. When there was already a rename_map_elt in the
2338 map at that location, free it.
2339 (translate_clast): Pass the rename_map. Do not initialize and free
2340 a rename_map per stmt_user.
2341 (gloog): Initialize and free one rename_map and pass it to
2342 translate_clast.
2343
23442009-03-12 Sebastian Pop <sebastian.pop@amd.com>
2345
2346 * sese.c (expand_scalar_variables_stmt,
2347 expand_scalar_variables_ssa_name): Add a gimple_stmt_iterator
2348 parameter.
2349 (expand_scalar_variables_expr): Handle REALPART_EXPR and IMAGPART_EXPR.
2350 (expand_scalar_variables): Pass to expand_scalar_variables_stmt
2351 the gimple_stmt_iterator of the statement to be expanded.
2352 * graphite-scop-detection.c (is_simple_operand): Do handle
2353 REALPART_EXPR.
2354
23552009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
2356
2357 * graphite-scop-detection.c (is_simple_operand): Do not handle
2358 REALPART_EXPR.
2359 * testsuite/gcc.dg/graphite/id-2.c: New.
2360
2361 * graphite-sese-to-poly.c (build_bb_loops,
2362 add_value_to_dim, scan_tree_for_params_right_scev,
2363 scan_tree_for_params_int, scan_tree_for_params, idx_record_params,
2364 find_params_in_bb, build_loop_iteration_domains,
2365 add_conditions_to_domain): Remove subtract.
2366
23672009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
2368
2369 * graphite-clast-to-gimple.c (loop_iv_stack_patch_for_consts,
2370 build_iv_mapping, compute_cloog_iv_types_1, build_cloog_prog):
2371 pbb_loop_at_index -> gbb_loop_at_index.
2372 * graphite-poly.c (new_poly_bb, new_scop): New accessors.
2373 (debug_loop_vec): Delete.
2374 * graphite-poly.h (poly_bb, scop): Change black_box and region to void
2375 pointer. Move LOOPS to gimple_bb_p and insert nb_params.
2376 (PBB_LOOPS): Removed.
2377 (PBB_BLACK_BOX): Insert cast.
2378 (pbb_set_black_box): New setter.
2379 (pbb_loop_at_index, pbb_loop_index): Removed.
2380 (scop_set_region, scop_set_nb_params): New.
2381 * graphite-sese-to-poly.c (new_gimple_bb, free_gimple_bb,
2382 build_scop_scattering, build_bb_loops): Add GBB_LOOPS.
2383 (build_poly_scop): Use scop_set_nb_params.
2384 * sese.h (gimple_bb): Add LOOPS.
2385 (GBB_LOOPS, gbb_loop_index, gbb_loop_at_index): New.
2386
23872009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
2388
2389 Revert previous commit.
2390
23912009-03-11 Sebastian Pop <sebastian.pop@amd.com>
2392
2393 * sese.c (expand_scalar_variables_expr): Handle tcc_comparison.
2394 (register_old_and_new_names): Update the content of the map.
2395 When there was already a rename_map_elt in the map at that
2396 location, free it.
2397 (copy_bb_and_scalar_dependences): Do rename_variables after
2398 expand_scalar_variables.
2399 * graphite-clast-to-gimple.c (build_iv_mapping): Update the content
2400 of the map. When there was already a rename_map_elt in the
2401 map at that location, free it.
2402 (translate_clast): Pass the rename_map. Do not initialize and free
2403 a rename_map per stmt_user.
2404 (gloog): Initialize and free one rename_map and pass it to
2405 translate_clast.
2406
24072009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
2408
2409 Remove forgotten line in revert.
2410
24112009-03-11 Sebastian Pop <sebastian.pop@amd.com>
2412
2413 Revert previous commit.
2414
24152009-03-10 Sebastian Pop <sebastian.pop@amd.com>
2416
2417 * sese.c (register_old_and_new_names): Update the content
2418 of the map. When there was already a rename_map_elt in the
2419 map at that location, free it.
2420 (copy_bb_and_scalar_dependences): Do rename_variables after
2421 expand_scalar_variables.
2422 * graphite-clast-to-gimple.c (build_iv_mapping): Update the content
2423 of the map. When there was already a rename_map_elt in the
2424 map at that location, free it.
2425 (translate_clast): Pass the rename_map. Do not initialize and free
2426 a rename_map per stmt_user.
2427 (gloog): Initialize and free one rename_map and pass it to
2428 translate_clast.
2429
24302009-03-10 Sebastian Pop <sebastian.pop@amd.com>
2431
2432 * graphite-clast-to-gimple.c (translate_clast): context_loop
2433 is never NULL.
2434
24352009-03-10 Tobias Grosser <grosser@fim.uni-passau.de>
2436 Sebastian Pop <sebastian.pop@amd.com>
2437
2438 * graphite-ppl.c (ppl_insert_dimensions): Fix stupid mistake
2439 of the use of ppl_Polyhedron_map_space_dimensions.
2440
24412009-03-10 Tobias Grosser <grosser@fim.uni-passau.de>
2442 Sebastian Pop <sebastian.pop@amd.com>
2443
2444 * graphite-poly.c (unify_scattering_dimensions): Fix types.
2445 * graphite-poly.h (poly_dr_p, poly_dr, POLY_DR_TYPE, PDR_BB,
2446 PDR_TYPE, PDR_ACCESSES, pdr_accessp_nb_subscripts,
2447 pdr_accessp_nb_iterators, pdr_accessp_nb_params,
2448 pdr_accessp_alias_set_dim, pdr_accessp_subscript_dim,
2449 pdr_accessp_iterator_dim, pdr_accessp_param_dim,
2450 pbb_nb_params): New.
2451 (pbb_nb_loops, pbb_nb_scattering, scop_nb_params,
2452 nb_loops_around_pbb): Adapt return types.
2453
24542009-03-09 Tobias Grosser <grosser@fim.uni-passau.de>
2455
2456 * Makefile.in (graphite.o, graphite-sese-to-poly.o,
2457 graphite-clast-to-gimple.o, graphite-data-ref.o,
2458 graphite-scop-detection.o, graphite-poly.o): Add
2459 more headers.
2460
24612009-03-05 Tobias Grosser <grosser@fim.uni-passau.de>
2462
2463 * Makefile.in (graphite.o, graphite-sese-to-poly.o,
2464 graphite-clast-to-gimple.o, graphite-data-ref.o,
2465 graphite-scop-detection.o, graphite-poly.o): Add graphite-poly.h.
2466
24672009-03-04 Tobias Grosser <grosser@fim.uni-passau.de>
2468
2469 * testsuite/gcc.dg/graphite/pr37485.c: Remove -floop-block
2470 * testsuite/gcc.dg/graphite/pr37828.c: Same.
2471 * testsuite/gcc.dg/graphite/pr37684.c: Same.
2472 * testsuite/gcc.dg/graphite/block-0.c: Same.
2473 * testsuite/gcc.dg/graphite/block-1.c: Same.
2474 * testsuite/gcc.dg/graphite/block-2.c: Same.
2475 * testsuite/gcc.dg/graphite/block-3.c: Same.
2476 * testsuite/gcc.dg/graphite/block-4.c: Same.
2477 * testsuite/gcc.dg/graphite/block-5.c: Same.
2478 * testsuite/gcc.dg/graphite/block-6.c: Same.
2479 * testsuite/gfortran.dg/graphite/pr38083.f90: Same.
2480 * testsuite/gfortran.dg/graphite/block-1.f90: Same.
2481 * testsuite/gfortran.dg/graphite/block-3.f90: Same.
2482 * testsuite/gfortran.dg/graphite/pr37852.f90: Same.
2483 * testsuite/gfortran.dg/graphite/block-4.f90: Same.
2484 * testsuite/gfortran.dg/graphite/pr37980.f90: Same.
2485 * testsuite/gfortran.dg/graphite/pr38953.f90: Same.
2486 * testsuite/gfortran.dg/graphite/pr37857.f90: Same.
2487 * opts.c: Remove -floop-block from -O2.
2488 * graphite-poly.c: Fail if -floop-block -floop-interchange or
2489 -floop-strip-mine are used.
2490
24912009-03-04 Tobias Grosser <grosser@fim.uni-passau.de>
2492 Sebastian Pop <sebastian.pop@amd.com>
2493
2494 * graphite-clast-to-gimple.c (build_cloog_prog): Unify scattering
2495 dimensions.
2496 * graphite-poly.c (pbb_compare, graphite_sort_pbbs,
2497 graphite_trans_bb_move_loop, graphite_trans_bb_strip_mine,
2498 strip_mine_profitable_p, is_interchange_valid,
2499 graphite_trans_bb_block, graphite_trans_loop_block,
2500 graphite_trans_scop_block): Temporary removed.
2501 (extend_scattering, unify_scattering_dimensions): New.
2502 (print_scattering_function, graphite_read_transforms):
2503 PBB_SCATTERING -> PBB_TRANSFORMED_SCATTERING.
2504 (graphite_generate_scattering_fns): Removed.
2505 (apply_poly_transforms): Cleanup.
2506 (free_poly_bb): Add PBB_SCATTERING -> PBB_TRANSFORMED_SCATTERING.
2507 (schedule_to_scattering): Moved.
2508 (PBB_STATIC_SCHEDULE, PBB_SCATTERING): Removed.
2509 (PBB_ORIGINAL_SCATTERING, PBB_TRANSFORMED_SCATTERING): New.
2510 (pbb_nb_scattering): New.
2511 (SCOP_ENTRY, SCOP_EXIT, SCOP_REGION_BBS, SCOP_DEP_GRAPH, SCOP_PARAMS,
2512 SCOP_LOOP_NEST, SCOP_PARAMS, SCOP_OLDIVS, SCOP_LIVEOUT_RENAMES):
2513 Removed.
2514 * graphite-ppl.c (ppl_insert_dimensions): Extended and renamed from
2515 shift_poly.
2516 (ppl_strip_loop): PBB_SCATTERING -> PBB_TRANSFORMED_SCATTERING.
2517 * graphite-scop-detection.c (dot_all_scops_1): PBB_SCATTERING
2518 -> PBB_TRANSFORMED_SCATTERING.
2519 * graphite-sese-to-poly.c (build_scop_bbs): Remove region.
2520 (build_pbb_scattering_polyhedron): Moved from schedule_to_scattering.
2521 (build_scop_scattering): Renamed from build_scop_canonical_schedules.
2522 (check_poly_representation): Do not return bool.
2523 (graphite_transform_loops): Reformat.
2524 * sese.h (SESE_ENTRY_BB, SESE_EXIT_BB): New.
2525
25262009-03-04 Sebastian Pop <sebastian.pop@amd.com>
2527
2528 * graphite-poly.c (print_pbb_domain, print_pbb, print_scop,
2529 debug_pbb_domain, debug_pbb, debug_scop): New.
2530 * graphite-poly.h (print_pbb_domain, print_pbb, print_scop,
2531 debug_pbb_domain, debug_pbb, debug_scop): Declared.
2532
25332009-03-02 Sebastian Pop <sebastian.pop@amd.com>
2534
2535 PR middle-end/39335
2536 * tree-parloops.c (canonicalize_loop_ivs): Call fold_convert
2537 when the type precision of the induction variable should be
2538 larger than the type precision of nit.
2539 (gen_parallel_loop): Update use of canonicalize_loop_ivs.
2540 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Same.
2541 * tree-flow.h (canonicalize_loop_ivs): Update declaration.
2542
2543 * testsuite/gcc.dg/graphite/pr39335_1.c: New.
2544 * testsuite/gcc.dg/graphite/pr39335.c: New.
2545
25462009-03-02 Sebastian Pop <sebastian.pop@amd.com>
2547
2548 * tree-parloops.c (canonicalize_loop_ivs): reduction_list contains
2549 SSA_NAMES not struct reduction_info.
2550
25512009-03-02 Sebastian Pop <sebastian.pop@amd.com>
2552
2553 * sese.c (expand_scalar_variables_expr): Handle ADDR_EXPR.
2554
25552009-02-27 Sebastian Pop <sebastian.pop@amd.com>
2556 Tobias Grosser <grosser@fim.uni-passau.de>
2557
2558 * sese.c (new_sese): Initialize SESE_REDUCTION_LIST.
2559 (free_sese): Free SESE_REDUCTION_LIST.
2560 * sese.h (struct sese): Add field reduction_list.
2561 (SESE_REDUCTION_LIST): New.
2562 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Call
2563 canonicalize_loop_ivs on SESE_REDUCTION_LIST.
2564
25652009-02-27 Sebastian Pop <sebastian.pop@amd.com>
2566 Tobias Grosser <grosser@fim.uni-passau.de>
2567
2568 * tree-flow.h (gather_scalar_reductions): Use struct loop * instead
2569 of loop_p.
2570
25712009-02-27 Sebastian Pop <sebastian.pop@amd.com>
2572 Tobias Grosser <grosser@fim.uni-passau.de>
2573
2574 * tree-parloops.c (struct brli, build_reduction_list_info,
2575 analyze_reduction_list, gather_scalar_reductions): New.
2576 (loop_parallel_p): Build a reduction list containing only
2577 PHI_RESULT SSA_NAMEs: call gather_scalar_reductions.
2578 (gen_parallel_loop): Call the analysis analyze_reduction_list.
2579 (parallelize_loops): Now reduction_list is a htab_t of SSA_NAMEs.
2580 * tree-flow.h (gather_scalar_reductions): Declared.
2581
25822009-02-26 Sebastian Pop <sebastian.pop@amd.com>
2583
2584 PR middle-end/39308
2585 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not call
2586 number_of_iterations_exit from a gcc_assert.
2587
25882009-02-25 Sebastian Pop <sebastian.pop@amd.com>
2589 Jan Sjodin <jan.sjodin@amd.com>
2590
2591 * output.h (graphite_out_file, graphite_in_file): Declared.
2592 * toplev.c (graphite_out_file, graphite_in_file): New.
2593 (init_asm_output): Initialize graphite_in_file and graphite_out_file.
2594 * graphite-clast-to-gimple.c (build_cloog_prog): Read PBB_SCATTERING.
2595 Don't call schedule_to_scattering.
2596 * common.opt (fgraphite-write, fgraphite-read): New.
2597 * graphite-poly.c: Include output.h.
2598 (print_scattering_function, print_scattering_functions,
2599 debug_scattering_function, debug_scattering_functions,
2600 graphite_write_transforms, graphite_read_transforms,
2601 graphite_generate_scattering_fns): New.
2602 (apply_poly_transforms): Do not apply transform if flag_graphite_read.
2603 Call graphite_generate_scattering_fns, graphite_write_transforms,
2604 graphite_read_transforms.
2605 (new_poly_bb): Initialize PBB_SCATTERING.
2606 (free_poly_bb): Free PBB_SCATTERING.
2607 (schedule_to_scattering): Does not return, initialize PBB_SCATTERING.
2608 * graphite-poly.h (struct poly_bb): Add field scattering.
2609 (PBB_SCATTERING): New.
2610 (print_scattering_function, print_scattering_functions,
2611 debug_scattering_function, debug_scattering_functions): Declared.
2612 * graphite-ppl.c (cloog_matrix_to_ppl_constraint): Matrices contain
2613 GMP values, not integers!
2614 (ppl_print_polyhedron_matrix, debug_ppl_polyhedron_matrix,
2615 ppl_read_polyhedron_matrix): New.
2616 * graphite-ppl.h (ppl_print_polyhedron_matrix,
2617 debug_ppl_polyhedron_matrix,
2618 ppl_read_polyhedron_matrix): Declared.
2619 * Makefile.in (graphite-poly.o): Depends on output.h.
2620
26212009-02-23 Sebastian Pop <sebastian.pop@amd.com>
2622 Tobias Grosser <grosser@fim.uni-passau.de>
2623
2624 Revert this change:
2625 * graphite-scop-detection.c (stmt_simple_for_scop_p): Analyze
2626 scalar evolutions in the scop_entry->loop_father.
2627
26282009-02-23 Sebastian Pop <sebastian.pop@amd.com>
2629 Tobias Grosser <grosser@fim.uni-passau.de>
2630
2631 * graphite.h (ref_nb_loops): Remove declaration.
2632 (struct gimple_bb, gimple_bb_p, GBB_BB, GBB_DATA_REFS, GBB_CONDITIONS,
2633 GBB_CONDITION_CASES, GBB_CLOOG_IV_TYPES, gbb_loop, print_gimple_bb,
2634 debug_gbb): Moved to sese.h.
2635 * sese.h: As said.
2636
26372009-02-23 Sebastian Pop <sebastian.pop@amd.com>
2638 Tobias Grosser <grosser@fim.uni-passau.de>
2639
2640 * graphite-data-ref.[ch]: Disable.
2641
26422009-02-23 Sebastian Pop <sebastian.pop@amd.com>
2643 Tobias Grosser <grosser@fim.uni-passau.de>
2644
2645 * graphite-scop-detection.c (stmt_simple_for_scop_p): Analyze
2646 scalar evolutions in the scop_entry->loop_father.
2647
26482009-02-23 Sebastian Pop <sebastian.pop@amd.com>
2649
2650 * graphite-scop-detection.c (nb_reductions_in_loop): Moved here...
2651 (graphite_cannot_represent_loop_niter): Renamed
2652 graphite_cannot_represent_loop. Call nb_reductions_in_loop.
2653 (limit_scops): build_sese_loop_nests does not return a bool.
2654 * graphite-scop-detection.h (nb_reductions_in_loop): Declared.
2655 * sese.c (nb_reductions_in_loop): ... from here.
2656 (graphite_loop_normal_form): ... from here.
2657 (sese_record_loop): Does not fail, so does not return a bool.
2658 (build_sese_loop_nests): Same.
2659 * sese.h (build_sese_loop_nests): Update declaration.
2660 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Moved here...
2661 (build_graphite_loop_normal_form): New.
2662 (gloog): Call build_graphite_loop_normal_form.
2663 * graphite-sese-to-poly.c (build_poly_scop): Don't fail on
2664 build_sese_loop_nests.
2665
2666 * testsuite/gcc.dg/graphite/id-1.c: New.
2667
26682009-02-23 Sebastian Pop <sebastian.pop@amd.com>
2669 Tobias Grosser <grosser@fim.uni-passau.de>
2670
2671 * graphite-sese-to-poly.c (scan_tree_for_params): Remove REAL_CST.
2672 The SCoP detection fix is sufficient.
2673
26742009-02-21 Sebastian Pop <sebastian.pop@amd.com>
2675
2676 PR tree-optimization/39260
2677 * graphite-scop-detection.c (harmful_stmt_in_bb): Stop a SCoP when
2678 the basic block contains a condition with a real type.
2679 * graphite-sese-to-poly.c (scan_tree_for_params): Handle REAL_CST.
2680
2681 * gcc.dg/graphite/pr39260.c: New.
2682
26832009-02-21 Sebastian Pop <sebastian.pop@amd.com>
2684
2685 * graphite-poly.c: Inlcude params.h.
2686 (graphite_trans_loop_block): Use PARAM_LOOP_BLOCK_TILE_SIZE for
2687 the size of a tile.
2688 * Makefile.in (graphite-poly.o): Depend on PARAMS_H.
2689 * params.def (PARAM_LOOP_BLOCK_TILE_SIZE): Define.
2690
26912009-02-20 Sebastian Pop <sebastian.pop@amd.com>
2692 Tobias Grosser <grosser@fim.uni-passau.de>
2693
2694 * graphite-scop-detection.c (dot_all_scops_1,
2695 dot_all_scops): Moved here.
2696 * graphite-scop-detection.h (dot_all_scops): Declared here.
2697 * graphite.c (graphite_initialize, graphite_finalize): New.
2698 (graphite_transform_loops): Cleaned up.
2699 * sese.c (debug_oldivs): Moved here.
2700 * graphite-poly.c (graphite_apply_transformations): Renamed
2701 apply_poly_transforms.
2702 (debug_loop_vec): Moved here.
2703 * graphite-sese-to-poly.c (build_bb_loops, build_sese_conditions_1,
2704 scop_contains_non_iv_scalar_phi_nodes, build_sese_conditions,
2705 find_scop_parameters, build_scop_iteration_domain,
2706 add_conditions_to_constraints, build_scop_canonical_schedules,
2707 build_scop_data_accesses): Now static.
2708 (build_poly_scop, check_poly_representation): New.
2709
27102009-02-20 Sebastian Pop <sebastian.pop@amd.com>
2711
2712 * graphite.c (graphite_stmt_p, new_gimple_bb, free_gimple_bb,
2713 remove_gbbs_in_scop, free_scops, try_generate_gimple_bb,
2714 build_scop_bbs, ref_nb_loops, compare_prefix_loops,
2715 build_scop_canonical_schedules, build_bb_loops, add_value_to_dim,
2716 scan_tree_for_params_right_scev, scan_tree_for_params_int,
2717 scan_tree_for_params, struct irp_data, dx_record_params,
2718 find_params_in_bb, find_scop_parameters, gbb_from_bb,
2719 build_loop_iteration_domains, add_conditions_to_domain,
2720 phi_node_is_iv, bb_contains_non_iv_scalar_phi_nodes,
2721 scop_contains_non_iv_scalar_phi_nodes, build_sese_conditions_1,
2722 build_sese_conditions, add_conditions_to_constraints,
2723 build_scop_iteration_domain, build_access_matrix_with_af,
2724 build_access_matrix,
2725 build_scop_data_accesses): Moved to graphite-sese-to-poly.c.
2726
2727 * graphite-sese-to-poly.c: New.
2728 * graphite-sese-to-poly.h: New.
2729
2730 * Makefile.in: Add new rule for graphite-sese-to-poly.o.
2731
27322009-02-20 Sebastian Pop <sebastian.pop@amd.com>
2733
2734 * graphite.c: Split graphite code generation to a new file.
2735 (graphite_verify, gmp_cst_to_tree, clast_name_to_gcc,
2736 max_precision_type, clast_to_gcc_expression_red,
2737 clast_to_gcc_expression, gcc_type_for_clast_expr,
2738 gcc_type_for_clast_eq, loop_iv_stack_patch_for_consts,
2739 graphite_translate_clast_equation, graphite_create_guard_cond_expr,
2740 graphite_create_new_guard, clast_get_body_of_loop,
2741 gcc_type_for_cloog_iv, gcc_type_for_iv_of_clast_loop,
2742 graphite_create_new_loop, build_iv_mapping, copy_renames,
2743 translate_clast, find_cloog_iv_in_expr, compute_cloog_iv_types_1,
2744 compute_cloog_iv_types, free_scattering, save_var_name,
2745 initialize_cloog_names, build_scop_context, build_cloog_prog,
2746 set_cloog_options, debug_clast_stmt, scop_to_clast,
2747 print_generated_program, debug_generated_program,
2748 gloog): Moved to graphite-clast-to-gimple.c.
2749
2750 (struct cloog_prog_clast): Moved to graphite-clast-to-gimple.h.
2751
2752 (iv_stack_entry_is_constant, iv_stack_entry_is_iv,
2753 loop_iv_stack_push_iv, loop_iv_stack_insert_constant,
2754 loop_iv_stack_pop, loop_iv_stack_get_iv,
2755 loop_iv_stack_get_iv_from_name, debug_loop_iv_stack,
2756 free_loop_iv_stack, loop_iv_stack_remove_constants,
2757 debug_rename_elt, debug_rename_map_1, debug_rename_map,
2758 rename_map_elt_info, eq_rename_map_elts, debug_ivtype_elt,
2759 debug_ivtype_map_1, debug_ivtype_map, ivtype_map_elt_info,
2760 eq_ivtype_map_elts, sese_add_exit_phis_edge,
2761 sese_add_exit_phis_var, sese_insert_phis_for_liveouts,
2762 get_vdef_before_sese, sese_adjust_vphi,
2763 get_new_name_from_old_name, sese_adjust_phis_for_liveouts,
2764 oldiv_for_loop, rename_variables_in_stmt, is_parameter,
2765 is_iv, expand_scalar_variables_ssa_name,
2766 expand_scalar_variables_expr, expand_scalar_variables_stmt,
2767 expand_scalar_variables, rename_variables, remove_condition,
2768 get_true_edge_from_guard_bb, get_false_edge_from_guard_bb,
2769 add_loop_exit_phis, insert_loop_close_phis, struct igp,
2770 default_liveout_before_guard, add_guard_exit_phis,
2771 insert_guard_phis, register_old_and_new_names,
2772 graphite_copy_stmts_from_block, register_sese_liveout_renames,
2773 copy_bb_and_scalar_dependences, outermost_loop_in_sese,
2774 if_region_set_false_region, create_if_region_on_edge,
2775 move_sese_in_condition): Moved to sese.c.
2776
2777 (nb_loops_around_loop_in_sese, struct ifsese, if_region_entry,
2778 if_region_exit, if_region_get_condition_block,
2779 struct rename_map_elt, new_rename_map_elt, enum iv_stack_entry_kind,
2780 union iv_stack_entry_data_union, struct iv_stack_entry_struct,
2781 iv_stack_entry_p, loop_iv_stack, struct ivtype_map_elt,
2782 ivtype_map_elt, new_ivtype_map_elt,
2783 recompute_all_dominators): Moved to sese.h.
2784
2785 * graphite-clast-to-gimple.c: New.
2786 * graphite-clast-to-gimple.h: New.
2787 * Makefile.in: Add new rule for graphite-clast-to-gimple.o.
2788 * sese.c: Modified as said above.
2789 * sese.h: Same.
2790
27912009-02-20 Sebastian Pop <sebastian.pop@amd.com>
2792
2793 * graphite.c: Split scop detection to a new file.
2794 (enum gbb_type, gbb_type, get_bb_type, struct sd_region_p, sd_region,
2795 move_sd_regions, loop_affine_expr, exclude_component_ref,
2796 is_simple_operand, stmt_simple_for_scop_p, harmful_stmt_in_bb,
2797 graphite_cannot_represent_loop_niter, struct scopdet_info,
2798 scopdet_basic_block_info, build_scops_1, bb_in_sd_region,
2799 find_single_entry_edge, find_single_exit_edge,
2800 create_single_entry_edge, sd_region_without_exit,
2801 create_single_exit_edge, unmark_exit_edges, mark_exit_edges,
2802 create_sese_edges, build_graphite_scops, limit_scops, build_scops):
2803 Moved to graphite-scop-detection.c.
2804
2805 * graphite-scop-detection.c: New.
2806 * graphite-scop-detection.h: New.
2807 * Makefile.in: Add new rule for graphite-scop-detection.o.
2808
2809 * sese.c: Include tree-chrec.h, tree-data-ref.h, and
2810 tree-scalar-evolution.h.
2811 (nb_reductions_in_loop, graphite_loop_normal_form, sese_record_loop,
2812 build_sese_loop_nests): Moved here from graphite.c.
2813 (param_index): Renamed parameter_index_in_region.
2814
28152009-02-18 Tobias Grosser <grosser@fim.uni-passau.de>
2816 Sebastian Pop <sebastian.pop@amd.com>
2817
2818 * gcc.dg/graphite/block-0.c: Expected to fail now.
2819 * gcc.dg/graphite/block-1.c: Same.
2820 * gcc.dg/graphite/block-5.c: Same.
2821 * gcc.dg/graphite/block-6.c: Same.
2822
28232009-02-18 Tobias Grosser <grosser@fim.uni-passau.de>
2824 Sebastian Pop <sebastian.pop@amd.com>
2825
2826 * graphite.h: Separate from graphite_bb_p the polyhedral
2827 representation in poly_bb_p and the GCC specifics in gimple_bb_p.
2828 (struct data_dependence_polyhedron, RDGE_DDP, ddp_p): Moved to
2829 graphite-data-ref.h.
2830 (struct poly_bb, PBB_SCOP, PBB_STATIC_SCHEDULE, PBB_DOMAIN,
2831 PBB_BLACK_BOX, PBB_LOOPS, pbb_nb_loops, pbb_loop_at_index,
2832 pbb_loop_index, struct scop, SCOP_BBS, SCOP_REGION, SCOP_ENTRY,
2833 SCOP_EXIT, SCOP_REGION_BBS, SCOP_DEP_GRAPH, SCOP_PARAMS,
2834 SCOP_LOOP_NEST, SCOP_PARAMS, SCOP_OLDIVS, SCOP_LIVEOUT_RENAMES,
2835 scop_nb_params): Moved to graphite-poly.h.
2836 * graphite-data-ref.c: Same.
2837 * graphite-data-ref.h: New.
2838 * graphite.c: Same.
2839 (pbb_compare, graphite_sort_pbbs, graphite_trans_bb_move_loop,
2840 graphite_trans_bb_strip_mine, strip_mine_profitable_p,
2841 is_interchange_valid, graphite_trans_bb_block,
2842 graphite_trans_loop_block, scop_max_loop_depth,
2843 graphite_trans_scop_block, graphite_apply_transformations,
2844 new_poly_bb, free_poly_bb, new_scop, free_scop): Moved to
2845 graphite-poly.c.
2846 * graphite-poly.h: New.
2847 * graphite-poly.c: New.
2848 * Makefile.in (OBJS-common): Add graphite-poly.o.
2849 (graphite-poly.o): New rule.
2850 * tree-data-ref.h (struct data_reference): Remove unused scop field.
2851 (DR_SCOP): Removed.
2852
28532009-02-18 Sebastian Pop <sebastian.pop@amd.com>
2854 Tobias Grosser <grosser@fim.uni-passau.de>
2855
2856 * graphite.c: Replace gb -> gbb.
2857 * graphite.h: Same.
2858 * graphite-data-ref.c: Same.
2859
28602009-02-18 Sebastian Pop <sebastian.pop@amd.com>
2861 Tobias Grosser <grosser@fim.uni-passau.de>
2862
2863 * Makefile.in (OBJS-commmon): Add sese.o.
2864 (sese.o): New.
2865 (graphite.o): Add sese.h.
2866 * graphite.c (bb_in_ss_p, loop_in_sese_p,
2867 sese_build_livein_liveouts_use, sese_build_livein_liveouts_bb,
2868 sese_build_livein_liveouts, register_bb_in_sese, new_sese, free_sese):
2869 Move to sese.
2870 (block_before_scop): Add missing return.
2871 (new_scop, free_scop): Remove SESE data structures.
2872 (scop_record_loop, scan_tree_for_params, find_params_in_bb,
2873 find_scop_parameters, build_loop_iteration_domains,
2874 add_conditions_to_domain, register_scop_liveout_renames,
2875 copy_bb_and_scalar_dependences): Scop -> SESE.
2876
2877 (add_conditions_to_domain): SCoP -> SESE and remove check
2878 (scop_contains_non_iv_scalar_phi_nodes): New.
2879 (build_scop_conditions_1, build_scop_conditions): Remove check for
2880 non iv scalar phi nodes.
2881 (print_scop_statistics): New.
2882 (graphite_transform_loops): Cleanup.
2883
2884 * graphite.h: Move to sese & cleanup.
2885 * sese.c: New.
2886 * sese.h: New.
2887
28882009-02-16 Sebastian Pop <sebastian.pop@amd.com>
2889 Tobias Grosser <grosser@fim.uni-passau.de>
2890
2891 * graphite.c (build_scop_conditions_1): Conditions are only
2892 at the end of a basic block.
2893
28942009-02-16 Sebastian Pop <sebastian.pop@amd.com>
2895 Tobias Grosser <grosser@fim.uni-passau>
2896
2897 * graphite.h (struct graphite_bb): Remove compressed_alpha_matrix
2898 field.
2899 (GBB_ALPHA): Removed.
2900
29012009-02-16 Sebastian Pop <sebastian.pop@amd.com>
2902 Tobias Grosser <grosser@fim.uni-passau.de>
2903
2904 * graphite-data-ref.c (graphite_test_dependence): Don't use
2905 GBB_DYNAMIC_SCHEDULE.
2906 * graphite.c (new_graphite_bb): Same.
2907 (free_graphite_bb): Same.
2908 (build_scop_dynamic_schedules): Removed.
2909 (graphite_transform_loops): Don't call it.
2910 * graphite.h (struct graphite_bb): Remove dynamic_schedule field.
2911 (GBB_DYNAMIC_SCHEDULE): Removed.
2912
29132009-02-16 Sebastian Pop <sebastian.pop@amd.com>
2914 Tobias Grosser <grosser@fim.uni-passau.de>
2915
2916 * graphite.c (schedule_to_scattering): Don't use CloogMatrix.
2917 (print_graphite_bb): Same.
2918 (build_cloog_prog): Same.
2919
29202009-02-16 Sebastian Pop <sebastian.pop@amd.com>
2921 Tobias Grosser <grosser@fim.uni-passau.de>
2922
2923 * graphite.c (build_cloog_prog): Don't use CloogMatrix.
2924
29252009-02-16 Sebastian Pop <sebastian.pop@amd.com>
2926 Tobias Grosser <grosser@fim.uni-passau.de>
2927
2928 * graphite.c (build_scop_context): Don't use CloogMatrix.
2929 * graphite-ppl.c (new_Cloog_Domain_from_ppl_Polyhedron): New.
2930 * graphite-ppl.h (new_Cloog_Domain_from_ppl_Polyhedron): Declared.
2931
29322009-02-16 Sebastian Pop <sebastian.pop@amd.com>
2933 Tobias Grosser <grosser@fim.uni-passau.de>
2934
2935 * graphite.h (struct scop): Move params, old_ivs, loops, loop_nest,
2936 liveout_renames, add_params fields...
2937 (struct sese): ... here.
2938 (SESE_PARAMS, SESE_LOOPS, SESE_LOOP_NEST, SESE_ADD_PARAMS,
2939 SESE_PARAMS, SESE_OLDIVS, SESE_LIVEOUT_RENAMES): New.
2940
29412009-02-16 Sebastian Pop <sebastian.pop@amd.com>
2942 Tobias Grosser <grosser@fim.uni-passau.de>
2943
2944 * graphite.c (print_scop): Do not print the CLooG program.
2945 (new_scop, free_scop, initialize_cloog_names, build_scop_context,
2946 build_cloog_prog, gloog): Don't use SCOP_PROG.
2947 (find_transform): Renamed scop_to_clast.
2948 (print_generated_program, debug_generated_program): New.
2949 (graphite_transform_loops): Adapt to new interface.
2950 * graphite.h (struct scop): Remove program field.
2951 (SCOP_PROG): Removed.
2952 (print_generated_program, debug_generated_program): Declared.
2953
29542009-02-16 Sebastian Pop <sebastian.pop@amd.com>
2955
2956 * graphite-data-ref.c (schedule_precedes_p, schedule_same_p): New.
2957 (statement_precedes_p): Use schedule_same_p and schedule_precedes_p.
2958 * graphite.c (gbb_compare, schedule_to_scattering, print_graphite_bb,
2959 free_graphite_bb, build_scop_canonical_schedules,
2960 graphite_trans_bb_strip_mine, graphite_trans_scop_block): Static
2961 schedules are now represented using a ppl_Linear_Expression_t.
2962 * graphite.h (struct graphite_bb): Same.
2963 * graphite-ppl.c (ppl_lexico_compare_linear_expressions): New.
2964 * graphite-ppl.h (ppl_lexico_compare_linear_expressions): Declared.
2965
29662009-02-15 Sebastian Pop <sebastian.pop@amd.com>
2967
2968 * graphite.c: Free local memory.
2969 * graphite-ppl.c: Same.
2970
29712009-02-15 Sebastian Pop <sebastian.pop@amd.com>
2972
2973 * graphite.c (const_column_index, get_first_matching_sign_row_index,
2974 get_lower_bound_row, get_upper_bound_row, copy_constraint,
2975 swap_constraint_variables, scale_constraint_variable): Removed.
2976 (graphite_trans_bb_strip_mine): Remove pong.
2977 * graphite-ppl.c: Include missing header files.
2978 (set_inhomogeneous, set_coef, shift_poly, ppl_strip_loop): New.
2979 * graphite-ppl.h (ppl_strip_loop): Declared.
2980 * Makefile.in (graphite-ppl.o): Adjust dependences.
2981
29822009-02-14 Sebastian Pop <sebastian.pop@amd.com>
2983
2984 * graphite.c (build_loop_iteration_domains): Remove ping pong.
2985 (build_scop_iteration_domain): Same.
2986
29872009-02-13 Sebastian Pop <sebastian.pop@amd.com>
2988
2989 * graphite.c (scan_tree_for_params, add_conditions_to_domain): Remove
2990 ping pong.
2991 (add_value_to_dim, scan_tree_for_params_right_scev,
2992 scan_tree_for_params_int): New.
2993 * graphite-ppl.c (oppose_constraint): New.
2994 (insert_constraint_into_matrix): Implement missing cases.
2995 * graphite-ppl.h (insert_constraint_into_matrix): Declared.
2996
29972009-02-13 Sebastian Pop <sebastian.pop@amd.com>
2998
2999 * graphite.c (graphite_trans_bb_move_loop): Remove ping pong,
3000 use ppl_move_dimension.
3001
30022009-02-12 Sebastian Pop <sebastian.pop@amd.com>
3003
3004 * graphite-data-ref.c: Domains are now ppl_Polyhedra_t.
3005 * graphite.c: Same.
3006 * graphite.h: Same.
3007 * graphite-ppl.c: Same.
3008 * graphite-ppl.h: Same.
3009
30102009-02-12 Sebastian Pop <sebastian.pop@amd.com>
3011
3012 Revert last 3 commits.
3013
30142009-02-10 Sebastian Pop <sebastian.pop@amd.com>
3015
3016 * graphite.c (scan_tree_for_params, add_conditions_to_domain): Remove
3017 ping pong.
3018 (add_value_to_dim, scan_tree_for_params_right_scev,
3019 scan_tree_for_params_int): New.
3020 * graphite-ppl.c (oppose_constraint): New.
3021 (insert_constraint_into_matrix): Implement missing cases.
3022 * graphite-ppl.h (insert_constraint_into_matrix): Declared.
3023
30242009-02-10 Sebastian Pop <sebastian.pop@amd.com>
3025
3026 * graphite.c (graphite_trans_bb_move_loop): Remove unused variables.
3027
30282009-02-10 Sebastian Pop <sebastian.pop@amd.com>
3029 Tobias Grosser <grosser@fim.uni-passau.de>
3030
3031 * graphite.c (graphite_trans_bb_move_loop): Remove ping pong,
3032 use ppl_move_dimension.
3033 * graphite-ppl.c (ppl_move_dimension): New.
3034 * graphite-ppl.h (ppl_move_dimension): Declared.
3035
30362009-02-10 Sebastian Pop <sebastian.pop@amd.com>
3037
3038 * graphite.c: Do not include cloog/cloog.h.
3039 (print_graphite_bb): Remove ping pong, call PPL print function.
3040
30412009-02-10 Tobias Grosser <grosser@fim.uni-passau.de>
3042
3043 * Makefile.in (OBJS-common): Add graphite-ppl.o.
3044 (graphite.o): Add dependence on graphite-ppl.h.
3045 (graphite-ppl.o): New.
3046 (graphite-data-ref.c): Ping pong between PPL data structures
3047 and matrices.
3048 * graphite-ppl.c: New.
3049 * graphite-ppl.h: New.
3050 * graphite.c: Include graphite-ppl.h.
3051 (print_graphite_bb, add_conditions_to_domain, build_cloog_prog,
3052 graphite_trans_bb_move_loop, graphite_trans_bb_strip_mine):
3053 Ping pong between PPL data structures and matrices.
3054 (new_graphite_bb): Create a PPL constraint system.
3055 Call ppl_delete_Constraint_System instead of cloog_matrix_free.
3056 (build_loop_iteration_domains): Use PPL functions.
3057 * graphite.h: Include graphite-ppl.h. Fix comments.
3058 (graphite_bb): Use a ppl_Constraint_System_t instead of
3059 CloogMatrix for representing the domain.
3060 (scop): Remove static_schedule.
3061 (gbb_nb_loops): Ping pong between PPL data structures and matrices.
3062
30632009-02-06 Sebastian Pop <sebastian.pop@amd.com>
3064
3065 * graphite.c: Fix some comments.
3066
30672009-02-05 Sebastian Pop <sebastian.pop@amd.com>
3068
3069 PR middle-end/38953
3070 * graphite.c (if_region_set_false_region): After moving a region
3071 in the false branch of a condition, remove the empty dummy
3072 basic block.
3073 (gloog): Remove wrong fix for PR38953.
3074
30752009-02-03 Tobias Grosser <grosser@fim.uni-passau.de>
3076
3077 * graphite.c (bb_in_sese_p, sese_build_livein_liveouts_use,
3078 sese_build_livein_liveouts_bb, sese_build_livein_liveouts,
3079 register_bb_in_sese, new_sese, free_sese): Moved.
3080 (dot_scop_1, build_scop_loop_nests, build_loop_iteration_domains,
3081 outermost_loop_in_scop, build_scop_iteration_domain,
3082 expand_scalar_variables_ssa_name, get_vdef_before_scop,
3083 limit_scops): Use bb_in_sese_p instead of bb_in_scop_p.
3084 Use loop_in_sese_p instead of loop_in_scop_p.
3085 (new_graphite_bb, new_scop, gloog): Do not initialize SCOP_BBS_B.
3086 (free_scop): Do not free SCOP_BBS_B.
3087 (nb_loops_around_loop_in_scop, nb_loops_around_gb,
3088 ref_nb_loops): Moved here...
3089 * graphite.h (ref_nb_loops): ... from here.
3090 (struct scop): Remove bbs_b bitmap.
3091 (SCOP_BBS_B, bb_in_scop_p, loop_in_scop_p): Removed.
3092 * testsuite/gcc.dg/graphite/scop-19.c: New
3093
30942009-02-03 Tobias Grosser <grosser@fim.uni-passau.de>
3095
3096 * graphite.c (scopdet_basic_block_info): Fix bug in scop
3097 detection.
3098
30992009-01-30 Tobias Grosser <grosser@fim.uni-passau.de>
3100
3101 * graphite.c (new_loop_to_cloog_loop_str, hash_loop_to_cloog_loop,
3102 eq_loop_to_cloog_loop): Remove.
3103 (new_scop, free_scop): Remove SCOP_LOOP2CLOOG_LOOP.
3104 * graphite.h (struct scop): Remove loop2cloog_loop.
3105 (loop_domain_dim, loop_iteration_vector_dim): Remove.
3106
31072009-01-30 Tobias Grosser <grosser@fim.uni-passau.de>
3108
3109 * opts.c (decode_options): Only add graphite options to O2
3110 if we compile with graphite enabled.
3111
31122009-01-26 Sebastian Pop <sebastian.pop@amd.com>
3113
3114 * Merge from mainline (r143163:143684).
3115
31162009-01-26 Sebastian Pop <sebastian.pop@amd.com>
3117
3118 * graphite.c (debug_value): Removed.
3119 * graphite.h (debug_value): Removed.
3120
31212009-01-23 Sebastian Pop <sebastian.pop@amd.com>
3122
3123 * passes.c (init_optimization_passes): Do not call pass_copy_prop
3124 after graphite: pass_copy_prop does not maintain a proper loop closed
3125 SSA form. pass_copy_prop should be fixed.
3126
31272009-01-23 Sebastian Pop <sebastian.pop@amd.com>
3128
3129 * graphite.c (scop_adjust_phis_for_liveouts): Fix warning.
3130
31312009-01-23 Sebastian Pop <sebastian.pop@amd.com>
3132
3133 * graphite.c (graphite_verify): Add a call to verify_loop_closed_ssa.
3134 (gloog): Split the exit of the scop when the scop exit is a loop exit.
3135 (graphite_transform_loops): Only call cleanup_tree_cfg if gloog
3136 changed the CFG.
3137
31382009-01-20 Sebastian Pop <sebastian.pop@amd.com>
3139
3140 * graphite.c (gloog): Return true when code gen succeeded.
3141 (graphite_transform_loops): Do not call cleanup_tree_cfg if
3142 the code of the function did not changed. After cleanup_tree_cfg
3143 call rewrite_into_loop_closed_ssa to maintain the loop closed ssa
3144 form.
3145
31462009-01-19 Sebastian Pop <sebastian.pop@amd.com>
3147
3148 * graphite.c (stmt_simple_for_scop_p): Also handle cases when
3149 gimple_call_lhs is NULL.
3150
31512009-01-16 Sebastian Pop <sebastian.pop@amd.com>
3152 Tobias Grosser <tobi.grosser@amd.com>
3153
3154 * graphite.c (graphite_trans_scop_block): Do not block single
3155 nested loops.
3156
31572009-01-15 Sebastian Pop <sebastian.pop@amd.com>
3158 Tobias Grosser <tobi.grosser@amd.com>
3159
3160 * graphite.c (build_scop_canonical_schedules): Start schedules at
3161 zero.
3162
31632009-01-15 Sebastian Pop <sebastian.pop@amd.com>
3164 Tobias Grosser <tobi.grosser@amd.com>
3165
3166 * graphite.c (compare_prefix_loops): New.
3167 (build_scop_canonical_schedules): Rewritten.
3168 (graphite_transform_loops): Move build_scop_canonical_schedules
3169 after build_scop_iteration_domain.
3170
31712009-01-14 Sebastian Pop <sebastian.pop@amd.com>
3172 Tobias Grosser <tobi.grosser@amd.com>
3173
3174 * graphite.c (add_conditions_to_domain): Add the loops to
3175 the dimension of the iteration domain. Do copy the domain
3176 only when it exists.
3177 (build_scop_conditions_1): Do not call add_conditions_to_domain.
3178 (add_conditions_to_constraints): New.
3179 (can_generate_code_stmt, can_generate_code): Removed.
3180 (gloog): Do not call can_generate_code.
3181 (graphite_transform_loops): Call add_conditions_to_constraints
3182 after building the iteration domain.
3183
31842009-01-14 Sebastian Pop <sebastian.pop@amd.com>
3185 Tobias Grosser <tobi.grosser@amd.com>
3186 Jan Sjodin <jan.sjodin@amd.com>
3187
3188 * graphite.c (scan_tree_for_params): On substractions negate
3189 all the coefficients of the term.
3190 (clast_to_gcc_expression_red): New. Handle reduction expressions
3191 of more than two operands.
3192 (clast_to_gcc_expression): Call clast_to_gcc_expression_red.
3193 (get_vdef_before_scop): Handle also the case of default definitions.
3194
31952009-01-14 Sebastian Pop <sebastian.pop@amd.com>
3196
3197 PR middle-end/38431
3198 * graphite.c (get_vdef_before_scop, scop_adjust_vphi): New.
3199 (scop_adjust_phis_for_liveouts): Call scop_adjust_vphi.
3200 (gloog): Do not call cleanup_tree_cfg.
3201 (graphite_transform_loops): Call cleanup_tree_cfg after all
3202 scops have been code generated.
3203
32042009-01-13 Sebastian Pop <sebastian.pop@amd.com>
3205
3206 * passes.c (init_optimization_passes): Schedule after
3207 graphite transforms pass_copy_prop, pass_dce_loop and pass_lim.
3208
32092009-01-13 Sebastian Pop <sebastian.pop@amd.com>
3210
3211 * graphite.c (expand_scalar_variables_stmt): Do not pass loop_p.
3212 Fix comment.
3213 (expand_scalar_variables_ssa_name): Do not pass loop_p. Fix comment.
3214 Set the type of an expression to the type of its assign statement.
3215 (expand_scalar_variables_expr): Do not pass loop_p.
3216 Fix comment. Stop recursion on tcc_constant or tcc_declaration.
3217 (copy_bb_and_scalar_dependences): Do not pass loop_p.
3218 (translate_clast): Update call to copy_bb_and_scalar_dependences.
3219
32202009-01-11 Sebastian Pop <sebastian.pop@amd.com>
3221
3222 * graphite.c (expand_scalar_variables_ssa_name): Set the type of
3223 an expression to the gimple_expr_type of its assign statement.
3224 (expand_scalar_variables_expr): Stop recursion on tcc_constant
3225 or tcc_declaration.
3226
32272009-01-11 Sebastian Pop <sebastian.pop@amd.com>
3228
3229 PR tree-optimization/38786
3230 * testsuite/gcc.dg/graphite/pr38786.c: New.
3231 * graphite.c (expand_scalar_variables_ssa_name): New, outlined from
3232 the SSA_NAME case of expand_scalar_variables_expr.
3233 (expand_scalar_variables_expr): Also gather the scalar computation
3234 used to index the memory access.
3235 (expand_scalar_variables_stmt): Pass to expand_scalar_variables_expr
3236 the gimple_stmt_iterator where it inserts new code.
3237
32382009-01-10 Sebastian Pop <sebastian.pop@amd.com>
3239
3240 * testsuite/gcc.dg/graphite/block-3.c: Fix compile error on 32bit.
3241
32422009-01-10 Sebastian Pop <sebastian.pop@amd.com>
3243
3244 * opts.c (decode_options): Enable flag_graphite_identity and
3245 flag_loop_block in -O2 and above.
3246
32472009-01-08 Sebastian Pop <sebastian.pop@amd.com>
3248
3249 * libjava/classpath/lib/gnu/java/awt/peer/gtk/GtkMouseInfoPeer.class:
3250 Fix merge problem: replace with the file from trunk.
3251
32522009-01-08 Sebastian Pop <sebastian.pop@amd.com>
3253
3254 * Merge from mainline (r141727:143163).
3255
32562009-01-07 Sebastian Pop <sebastian.pop@amd.com>
3257 Jan Sjodin <jan.sjodin@amd.com>
3258
3259 PR tree-optimization/38559
3260 * testsuite/gcc.dg/graphite/pr38559.c: New.
3261
3262 * graphite.c (debug_value, copy_constraint,
3263 swap_constraint_variables, scale_constraint_variable, ): New.
3264 (get_lower_bound, get_upper_bound): Removed.
3265 (graphite_trans_bb_strip_mine): Clean up this code that works
3266 only for constant number of iterations. Fully copy upper and
3267 lower bound constraints, not only the constant part of them.
3268 * graphite.h (debug_value): Declared.
3269
32702009-01-06 Jan Sjodin <jan.sjodin@amd.com>
3271
3272 PR tree-optimization/38492
3273 PR tree-optimization/38498
3274 * tree-check.c (operator_is_linear, scev_is_linear_expression): New.
3275 * tree-chrec.h (scev_is_linear_expression): Declared.
3276 * graphite.c (graphite_cannot_represent_loop_niter): New.
3277 (scopdet_basic_block_info): Call graphite_cannot_represent_loop_niter.
3278 (graphite_loop_normal_form): Use gcc_assert.
3279 (scan_tree_for_params): Use CASE_CONVERT.
3280 (phi_node_is_iv, bb_contains_non_iv_scalar_phi_nodes): New.
3281 (build_scop_conditions_1): Call bb_contains_non_iv_scalar_phi_nodes.
3282 Use gcc_assert. Discard scops that contain unhandled cases.
3283 (build_scop_conditions): Return a boolean status for unhandled cases.
3284 (strip_mine_profitable_p): Print the loop number, not its depth.
3285 (is_interchange_valid): Pass the depth of the loop nest, don't
3286 recompute it wrongly.
3287 (graphite_trans_bb_block): Same.
3288 (graphite_trans_bb_block): Print tentative of loop blocking.
3289 (graphite_trans_scop_block): Do not print that the loop has been
3290 blocked.
3291 (graphite_transform_loops): Do not handle scops that contain condition
3292 scalar phi nodes.
3293
3294 * testsuite/gcc.dg/graphite/pr38500.c: Fixed warning as committed
3295 in trunk.
3296 * testsuite/gcc.dg/graphite/block-0.c: Update test.
3297 * testsuite/gcc.dg/graphite/block-1.c: Same.
3298 * testsuite/gcc.dg/graphite/block-2.c: Remove xfail and test for
3299 blocking.
3300 * testsuite/gcc.dg/graphite/block-4.c: Remove test for strip mine.
3301 * testsuite/gcc.dg/graphite/block-3.c: New.
3302 * testsuite/gcc.dg/graphite/pr38498.c: New.
3303
33042008-12-22 Harsha Jagasia <harsha.jagasia@amd.com>
3305
3306 PR tree-optimization/38510
3307 * gcc.dg/graphite/pr38510.c: New.
3308 * graphite.c (recompute_all_dominators): Call mark_irreducible_loops.
3309 (translate_clast): Call recompute_all_dominators before
3310 graphite_verify.
3311 (gloog): Call recompute_all_dominators before graphite_verify.
3312
33132008-12-12 Sebastian Pop <sebastian.pop@amd.com>
3314
3315 PR tree-optimization/38492
3316 * graphite.c (rename_map_elt, debug_rename_elt,
3317 debug_rename_map_1, debug_rename_map, new_rename_map_elt,
3318 rename_map_elt_info, eq_rename_map_elts,
3319 get_new_name_from_old_name, bb_in_sese_p): Moved around.
3320 (sese_find_uses_to_rename_use): Renamed sese_build_livein_liveouts_use.
3321 (sese_find_uses_to_rename_bb): Renamed sese_build_livein_liveouts_bb.
3322 (sese_build_livein_liveouts): New.
3323 (new_sese, free_sese): New.
3324 (new_scop): Call new_sese.
3325 (free_scop): Call free_sese.
3326 (rename_variables_from_edge, rename_phis_end_scop): Removed.
3327 (register_old_new_names): Renamed register_old_and_new_names.
3328 (register_scop_liveout_renames, add_loop_exit_phis,
3329 insert_loop_close_phis, struct igp,
3330 default_liveout_before_guard, add_guard_exit_phis,
3331 insert_guard_phis, copy_renames): New.
3332 (translate_clast): Call insert_loop_close_phis and insert_guard_phis.
3333 (sese_add_exit_phis_edge): Renamed scop_add_exit_phis_edge.
3334 (rewrite_into_sese_closed_ssa): Renamed scop_insert_phis_for_liveouts.
3335 (scop_adjust_phis_for_liveouts): New.
3336 (gloog): Call scop_adjust_phis_for_liveouts.
3337
3338 * graphite.h (struct sese): Documented. Added fields liveout,
3339 num_ver and livein.
3340 (SESE_LIVEOUT, SESE_LIVEIN, SESE_LIVEIN_VER, SESE_NUM_VER): New.
3341 (new_sese, free_sese, sese_build_livein_liveouts): Declared.
3342 (struct scop): Added field liveout_renames.
3343 (SCOP_LIVEOUT_RENAMES): New.
3344
33452008-12-11 Sebastian Pop <sebastian.pop@amd.com>
3346
3347 PR tree-optimization/38409
3348 * gcc.dg/graphite/pr38409.c: New.
3349 * graphite.c (nb_reductions_in_loop): Use simple_iv.
3350
33512008-12-11 Sebastian Pop <sebastian.pop@amd.com>
3352
3353 * graphite.c (gcc_type_for_cloog_iv): By default return
3354 integer_type_node.
3355 (graphite_create_new_loop): Don't fold_convert the already
3356 fold_convert-ed expression.
3357
33582008-12-11 Harsha Jagasia <harsha.jagasia@amd.com>
3359
3360 PR tree-optimization/38446
3361 * gcc.dg/graphite/pr38446.c: New.
3362 * graphite.c (register_bb_in_sese): New.
3363 (bb_in_sese_p): Check if bb belongs to sese region by explicitly
3364 looking at the bbs in the region.
3365 * graphite.h (sese): Add region_basic_blocks pointer set to
3366 structure and initialize at the time of defining new scop.
3367
33682008-12-11 Tobias Grosser <grosser@fim.uni-passau.de>
3369
3370 * graphite.c (new_graphite_bb): Initialize GBB_STATIC_SCHEDULE.
3371 (find_params_in_bb): Do not free data refs.
3372 (free_graphite_bb): Add FIXME on disabled free_data_refs.
3373
33742008-12-11 Sebastian Pop <sebastian.pop@amd.com>
3375
3376 * testsuite/gcc.dg/graphite/scop-16.c: Test only scop specific info.
3377 * testsuite/gcc.dg/graphite/scop-17.c: Same.
3378 * testsuite/gcc.dg/graphite/block-5.c: New.
3379 * testsuite/gcc.dg/graphite/block-6.c: New.
3380 * testsuite/gcc.dg/graphite/pr37485.c: Clean dump file after.
3381 * testsuite/gcc.dg/graphite/pr37684.c: Same.
3382 * testsuite/gcc.dg/graphite/block-2.c: Same.
3383
3384 * graphite.c (struct ivtype_map_elt): New.
3385 (debug_ivtype_elt, debug_ivtype_map_1, debug_ivtype_map,
3386 new_ivtype_map_elt, ivtype_map_elt_info, eq_ivtype_map_elts,
3387 gcc_type_for_cloog_iv): New.
3388 (loop_iv_stack_patch_for_consts): Use the type of the induction
3389 variable from the original loop, except for the automatically
3390 generated loops, i.e., in the case of a strip-mined loop, in
3391 which case there is no original loop: in that case just use
3392 integer_type_node.
3393 (new_graphite_bb): Initialize GBB_CLOOG_IV_TYPES.
3394 (free_graphite_bb): Free GBB_CLOOG_IV_TYPES.
3395 (clast_name_to_gcc): Accept params to be NULL.
3396 (clast_to_gcc_expression): Take an extra parameter for the type.
3397 Convert to that type all the expressions built by this function.
3398 (gcc_type_for_clast_expr, gcc_type_for_clast_eq): New.
3399 (graphite_translate_clast_equation): Compute the type of the
3400 clast_equation before translating its LHS and RHS.
3401 (clast_get_body_of_loop, gcc_type_for_iv_of_clast_loop): New.
3402 (graphite_create_new_loop): Compute the type of the induction
3403 variable before translating the lower and upper bounds and before
3404 creating the induction variable.
3405 (rename_variables_from_edge, rename_phis_end_scop): New.
3406 (copy_bb_and_scalar_dependences): Call rename_phis_end_scop.
3407 (sese_add_exit_phis_edge): Do not use integer_zero_node.
3408 (find_cloog_iv_in_expr, compute_cloog_iv_types_1,
3409 compute_cloog_iv_types): New.
3410 (gloog): Call compute_cloog_iv_types before starting the
3411 translation of the clast.
3412
3413 * graphite.h (struct graphite_bb): New field cloog_iv_types.
3414 (GBB_CLOOG_IV_TYPES): New.
3415 (debug_ivtype_map): Declared.
3416 (oldiv_for_loop): New.
3417
34182008-12-10 Tobias Grosser <grosser@fim.uni-passau.de>
3419
3420 PR middle-end/38459
3421 * graphite.c (new_scop): Initialize SCOP_ADD_PARAMS.
3422 (param_index): Assert if parameter is not know after parameter
3423 detection.
3424 (find_params_in_bb): Detect params directly in GBB_CONDITIONS.
3425 (find_scop_parameters): Mark, that we have finished parameter
3426 detection.
3427 (graphite_transform_loops): Move condition detection before parameter
3428 detection.
3429 * graphite.h (struct scop): Add SCOP_ADD_PARAMS.
3430 * testsuite/gfortran.dg/graphite/pr38459.f90: New.
3431
34322008-12-09 Tobias Grosser <grosser@fim.uni-passau.de>
3433
3434 * graphite.c (graphite_transform_loops): Always call find_transform ()
3435 in ENABLE_CHECKING. So we test these code paths, even if we do not
3436 generate code.
3437
34382008-12-09 Tobias Grosser <grosser@fim.uni-passau.de>
3439
3440 * graphite.c (print_graphite_bb): Fix printing to file != dump_file.
3441 (print_scop): Ditto.
3442
34432008-12-08 Tobias Grosser <grosser@fim.uni-passau.de>
3444
3445 PR middle-end/38084
3446 Fix testsuite/gfortran.dg/graphite/id-3.f90.
3447 * graphite.c (scopdet_basic_block_info): Fix bug that found some
3448 regions more than once.
3449
34502008-12-03 Sebastian Pop <sebastian.pop@amd.com>
3451
3452 Fix testsuite/gfortran.dg/graphite/id-4.f90.
3453 * graphite.c (scan_tree_for_params): Do not compute the multiplicand
3454 when not needed.
3455
34562008-12-03 Sebastian Pop <sebastian.pop@amd.com>
3457
3458 Fix testsuite/gfortran.dg/graphite/id-1.f90.
3459 * graphite.c (gmp_cst_to_tree): Pass the type in parameter.
3460 (loop_iv_stack_patch_for_consts): Update use of gmp_cst_to_tree.
3461 (max_precision_type): New.
3462 (value_clast): Removed.
3463 (clast_to_gcc_expression): Be more careful to types of expressions.
3464 Use max_precision_type and update use of gmp_cst_to_tree.
3465 (graphite_translate_clast_equation): Use max_precision_type.
3466 (graphite_create_guard_cond_expr): Do not use integer_type_node,
3467 use the type of the condition.
3468 (graphite_create_new_loop): Do not use integer_type_node, use the
3469 max_precision_type of lb and ub.
3470
34712008-12-03 Sebastian Pop <sebastian.pop@amd.com>
3472
3473 * graphite.c (build_scops_1): Initialize open_scop.exit
3474 and sinfo.last.
3475
34762008-12-02 Sebastian Pop <sebastian.pop@amd.com>
3477
3478 * testsuite/gcc.dg/graphite/pr38084.c: New.
3479 * testsuite/gfortran.dg/graphite/id-1.f90: New.
3480 * testsuite/gfortran.dg/graphite/id-2.f90: New.
3481 * testsuite/gfortran.dg/graphite/id-3.f90: New.
3482 * testsuite/gfortran.dg/graphite/id-4.f90: New.
3483 * testsuite/gfortran.dg/graphite/pr37857.f90: New.
3484
34852008-12-02 Sebastian Pop <sebastian.pop@amd.com>
3486 Jan Sjodin <jan.sjodin@amd.com>
3487 Harsha Jagasia <harsha.jagasia@amd.com>
3488
3489 PR middle-end/37852
3490 PR middle-end/37883
3491 PR middle-end/37928
3492 PR middle-end/37980
3493 PR middle-end/38038
3494 PR middle-end/38039
3495 PR middle-end/38073
3496 PR middle-end/38083
3497 PR middle-end/38125
3498
3499 * testsuite/gcc.dg/graphite/pr38073.c: New.
3500 * testsuite/gcc.dg/graphite/pr37928.c: New.
3501 * testsuite/gcc.dg/graphite/pr37883.c: New.
3502 * testsuite/gcc.dg/graphite/pr38125.c: New.
3503 * testsuite/gfortran.dg/graphite/pr38083.f90: New.
3504 * testsuite/gfortran.dg/graphite/pr37852.f90: New.
3505 * testsuite/gfortran.dg/graphite/pr37980.f90: New.
3506
3507 * testsuite/gcc.dg/graphite/scop-18.c: Remove reduction, test for
3508 the number of detected scops. Copy exact same test for loop
3509 blocking...
3510 * testsuite/gcc.dg/graphite/block-1.c: Fix the number of expected
3511 loops to be blocked as reductions are not handled.
3512 * testsuite/gcc.dg/graphite/block-4.c: ...here. New.
3513
3514 * tree-phinodes.c (remove_phi_nodes): New, extracted from...
3515 * tree-cfg.c (remove_phi_nodes_and_edges_for_unreachable_block):
3516 ...here.
3517 * tree-flow.h (remove_phi_nodes, canonicalize_loop_ivs): Declared.
3518 * Makefile.in (graphite.o): Depend on value-prof.h.
3519 (graphite.o-warn): Removed -Wno-error.
3520 * tree-parloops.c (canonicalize_loop_ivs): Allow reduction_list
3521 to be a NULL pointer. Call update_stmt. Return the newly created
3522 cannonical induction variable.
3523
3524 * graphite.h (debug_rename_map): Declared. Fix some comments.
3525
3526 * graphite.c: Reimplement the code generation from graphite to gimple.
3527 Include value-prof.h.
3528 (loop_iv_stack_get_iv): Do not return NULL for constant substitutions.
3529 (get_old_iv_from_ssa_name): Removed.
3530 (graphite_stmt_p): New.
3531 (new_graphite_bb): Test for useful statements before building a
3532 graphite statement for the basic block.
3533 (free_graphite_bb): Do not free GBB_DATA_REFS: this is a bug
3534 in free_data_ref that calls BITMAP_FREE (DR_VOPS (dr)) without
3535 reason.
3536 (recompute_all_dominators, graphite_verify,
3537 nb_reductions_in_loop, graphite_loop_normal_form): New.
3538 (scop_record_loop): Call graphite_loop_normal_form.
3539 (build_scop_loop_nests): Iterate over all the blocks of the
3540 function instead of relying on the incomplete information from
3541 SCOP_BBS. Return the success of the operation.
3542 (find_params_in_bb): Use the data from GBB_DATA_REFS.
3543 (add_bb_domains): Removed.
3544 (build_loop_iteration_domains): Don't call add_bb_domains.
3545 Add the iteration domain only to the basic blocks that have been
3546 translated to graphite.
3547 (build_scop_conditions_1): Add constraints only if the basic
3548 block have been translated to graphite.
3549 (build_scop_data_accesses): Completely disabled until data
3550 dependence is correctly implemented.
3551 (debug_rename_elt, debug_rename_map_1, debug_rename_map): New.
3552 (remove_all_edges_1, remove_all_edges): Removed.
3553 (get_new_name_from_old_name): New.
3554 (graphite_rename_variables_in_stmt): Renamed
3555 rename_variables_in_stmt. Call get_new_name_from_old_name.
3556 Use replace_exp and update_stmt.
3557 (is_old_iv): Renamed is_iv.
3558 (expand_scalar_variables_stmt): Extra parameter for renaming map.
3559 Use replace_exp and update_stmt.
3560 (expand_scalar_variables_expr): Same. Use the map to get the
3561 new names for the renaming of induction variables and for the
3562 renaming of variables after a basic block has been copied.
3563 (expand_scalar_variables): Same.
3564 (graphite_rename_variables): Renamed rename_variables.
3565 (move_phi_nodes): Removed.
3566 (get_false_edge_from_guard_bb): New.
3567 (build_iv_mapping): Do not insert the induction variable of a
3568 loop in the renaming iv map if the basic block does not belong
3569 to that loop.
3570 (register_old_new_names, graphite_copy_stmts_from_block,
3571 copy_bb_and_scalar_dependences): New.
3572 (translate_clast): Heavily reimplemented: copy basic blocks,
3573 do not move them. Finally, in call cleanup_tree_cfg in gloog.
3574 At each translation step call graphite_verify ensuring the
3575 consistency of the SSA, loops and dominators information.
3576 (collect_virtual_phis, find_vdef_for_var_in_bb,
3577 find_vdef_for_var_1, find_vdef_for_var,
3578 patch_phis_for_virtual_defs): Removed huge hack.
3579 (mark_old_loops, remove_dead_loops, skip_phi_defs,
3580 collect_scop_exit_phi_args, patch_scop_exit_phi_args,
3581 gbb_can_be_ignored, scop_remove_ignoreable_gbbs, ): Removed.
3582 (remove_sese_region, ifsese, if_region_entry, if_region_exit,
3583 if_region_get_condition_block, if_region_set_false_region,
3584 create_if_region_on_edge, move_sese_in_condition, bb_in_sese_p,
3585 sese_find_uses_to_rename_use, sese_find_uses_to_rename_bb,
3586 sese_add_exit_phis_edge, sese_add_exit_phis_var,
3587 rewrite_into_sese_closed_ssa): New.
3588 (gloog): Remove dead code. Early return if code cannot be
3589 generated. Call cleanup_tree_cfg once the scop has been code
3590 generated.
3591 (graphite_trans_scop_block, graphite_trans_loop_block): Do not
3592 block loops with less than two loops.
3593 (graphite_apply_transformations): Remove the call to
3594 scop_remove_ignoreable_gbbs.
3595 (limit_scops): When build_scop_loop_nests fails, continue on
3596 the next scop. Fix open_scop.entry.
3597 (graphite_transform_loops): Call recompute_all_dominators: force the
3598 recomputation of correct CDI_DOMINATORS and CDI_POST_DOMINATORS.
3599 Call initialize_original_copy_tables and free_original_copy_tables
3600 to be able to copy basic blocks during code generation.
3601 When build_scop_loop_nests fails, continue on next scop.
3602 (value_clast): New union.
3603 (clast_to_gcc_expression): Fix type cast warning.
3604
36052008-11-09 Sebastian Pop <sebastian.pop@amd.com>
3606
3607 * Merge from mainline (r140838:141727).
3608
36092008-11-05 Tobias Grosser <grosser@fim.uni-passau.de>
3610
3611 PR middle-end/37833
3612
3613 * graphite.c (scan_tree_for_params): Add POINTER_PLUS_EXPR.
3614
36152008-11-05 Tobias Grosser <grosser@fim.uni-passau.de>
3616
3617 PR middle-end/37943
3618
3619 * graphite.c (scopdet_basic_block_info): Fix loops with multiple
3620 exits and conditions.
3621 * testsuite/gcc.dg/graphite/pr37943.c: New.
3622
36232008-10-23 Tobias Grosser <grosser@fim.uni-passau.de>
3624
3625 PR middle-end/37886
3626 * graphite.c (gloog): Replace EXIT_BLOCK_PTR with scop exit.
3627
36282008-10-23 Tobias Grosser <grosser@fim.uni-passau.de>
3629
3630 * doc/invoke.texi: Fix spaces.
3631
36322008-10-22 Sebastian Pop <sebastian.pop@amd.com>
3633
3634 PR tree-optimization/37891
3635 Reverted last commit.
3636 * graphite.c (create_single_entry_edge): Set
3637 EDGE_IRREDUCIBLE_LOOP and BB_IRREDUCIBLE_LOOP.
3638
36392008-10-21 Sebastian Pop <sebastian.pop@amd.com>
3640 Mitul Thakkar <mitul.thakkar@amd.com>
3641
3642 * graphite.c (create_single_entry_edge): Set
3643 EDGE_IRREDUCIBLE_LOOP and BB_IRREDUCIBLE_LOOP.
3644
36452008-10-16 Tobias Grosser <grosser@fim.uni-passau.de>
3646
3647 * doc/invoke.texi: Add -fgraphite-identity.
3648 * graphite.c (graphite_apply_transformations): Check for
3649 -fgraphite-identity.
3650 * toplev.c (process_options): Add flag_graphite_identity.
3651 * tree-ssa-loop.c: Add flag_graphite_identity.
3652
36532008-10-14 Sebastian Pop <sebastian.pop@amd.com>
3654
3655 Undo changes from 2008-10-02:
3656 * tree-ssa-loop-ivopts.c (rewrite_use_nonlinear_expr): Convert
3657 operand type when copying the operand to a variable of different type.
3658 * cfgloopmanip.c (create_empty_loop_on_edge): Write exit condition
3659 with the IV name after increment.
3660
36612008-10-14 Sebastian Pop <sebastian.pop@amd.com>
3662 Harsha Jagasia <harsha.jagasia@amd.com>
3663
3664 PR tree-optimization/37828
3665 * testsuite/gcc.dg/graphite/pr37828.c: New.
3666 * graphite.c (graphite_trans_loop_block): Do not loop block
3667 single nested loops.
3668
36692008-10-09 Harsha Jagasia <harsha.jagasia@amd.com>
3670 Sebastian Pop <sebastian.pop@amd.com>
3671
3672 * graphite.c (struct rename_map_elt, new_rename_map_elt,
3673 rename_map_elt_info, eq_rename_map_elts): New.
3674 (graphite_rename_ivs_stmt): Renamed graphite_rename_variables_in_stmt.
3675 (expand_scalar_variables_expr): Change parameters.
3676 (expand_scalar_variables_stmt): Same.
3677 (expand_scalar_variables): Same.
3678 (graphite_rename_ivs): Rename graphite_rename_variables.
3679 (build_iv_mapping): New.
3680 (translate_clast): Call build_iv_mapping.
3681 * graphite.h (gbb_p): New name.
3682
36832008-10-03 Harsha Jagasia <harsha.jagasia@amd.com>
3684
3685 PR tree-optimization/37684
3686 * gcc.dg/graphite/pr37684.c: New.
3687 * graphite.c (exclude_component_ref): New.
3688 (is_simple_operand): Call exclude_component_ref.
3689
36902008-10-02 Jan Sjodin <jan.sjodin@amd.com>
3691 Harsha Jagasia <harsha.jagasia@amd.com>
3692
3693 PR tree-optimization/37485
3694 * gcc.dg/graphite/block-2.c: New
3695 * graphite.c (gmp_cst_to_tree): Moved.
3696 (iv_stack_entry_is_constant): New.
3697 (iv_stack_entry_is_iv): New.
3698 (loop_iv_stack_push): Renamed to loop_iv_stack_push_iv.
3699 (loop_iv_stack_insert_constant): New.
3700 (loop_iv_stack_pop): Use new datatpype.
3701 (loop_iv_stack_get_iv): Same.
3702 (loop_iv_stack_get_iv_from_name): Same.
3703 (loop_iv_stack_debug): Renamed to debug_loop_iv_stack.
3704 (loop_iv_stack_patch_for_consts): New.
3705 (loop_iv_stack_remove_constants): New.
3706 (graphite_create_new_loop): Use loop_iv_stack_push_iv.
3707 (translate_clast): Call loop_iv_stack_patch_for_consts and
3708 loop_iv_stack_remove_constants.
3709 (gloog): Use new datatype. Redirect construction edge to end
3710 block to avoid accidental deletion.
3711 * graphite.h (enum iv_stack_entry_kind): New. Tag for data in
3712 iv stack entry.
3713 (union iv_stack_entry_data): New. Data in iv stack entry.
3714 (struct iv_stack_entry): New. Datatype for iv stack entries.
3715
37162008-10-02 Sebastian Pop <sebastian.pop@amd.com>
3717
3718 * tree-ssa-loop-ivopts.c (rewrite_use_nonlinear_expr): Convert
3719 operand type when copying the operand to a variable of different type.
3720
37212008-10-02 Sebastian Pop <sebastian.pop@amd.com>
3722
3723 * cfgloopmanip.c (create_empty_loop_on_edge): Write exit condition
3724 with the IV name after increment.
3725
37262008-10-02 Sebastian Pop <sebastian.pop@amd.com>
3727
3728 * Merge from mainline (r140164:140838).
3729
37302008-09-10 Konrad Trifunovic <konrad.trifunovic@inria.fr>
3731
3732 * graphite-data-ref.c: New.
3733 * graphite.c (print_scop): Also dump the dependence graph.
3734 (bb_in_scop_p, loop_in_scop_p, nb_loops_around_gb): Moved...
3735 (new_scop): Initialize SCOP_DEP_GRAPH.
3736 (build_scop_dynamic_schedules): New.
3737 (build_access_matrix_with_af): Fixed column numbering.
3738 (graphite_transform_loops): Call build_scop_dynamic_schedules.
3739 * graphite.h: Add ifndef/define guards against multiple inclusion.
3740 (struct scop): Add dep_graph field.
3741 (SCOP_DEP_GRAPH): Defined.
3742 (ref_nb_loops): Fixed and moved to other position.
3743 (bb_in_scop_p, loop_in_scop_p, nb_loops_around_gb): ... here.
3744 (nb_loops_around_loop_in_scop): New.
3745 (graphite_dump_dependence_graph): Declared.
3746 (graphite_build_rdg_all_levels): Declared.
3747 (graphite_test_dependence): Declared.
3748 * Makefile.in (graphite-data-ref.o): New target.
3749
37502008-09-09 Sebastian Pop <sebastian.pop@amd.com>
3751
3752 * Merge from mainline (139870:140164).
3753
37542008-09-01 Sebastian Pop <sebastian.pop@amd.com>
3755
3756 * Merge from mainline (138275:139870).
3757 * testsuite/gcc.dg/graphite/scop-matmult.c: XFailed as one of
3758 the commits from trunk broke the niter detection.
3759
37602008-09-01 Sebastian Pop <sebastian.pop@amd.com>
3761
3762 * graphite.c: Add more documentation. Fix formatting.
3763 (debug_loop_vec, debug_oldivs, loop_iv_stack,
3764 loop_iv_stack_debug): Moved...
3765 (schedule_to_scattering): Move before use.
3766 (dot_all_scops): Include in "#if 0" the code for system
3767 call dotty.
3768
3769 * graphite.h: (debug_loop_vec, debug_oldivs, loop_iv_stack,
3770 loop_iv_stack_debug): ...here.
3771
37722008-08-29 Jan Sjodin <jan.sjodin@amd.com>
3773
3774 * tree-phinodes.c (make_phi_node): Extern.
3775 (add_phi_node_to_bb): New.
3776 (create_phi_node): Call add_phi_node_to_bb.
3777 * tree-ssa-loop-ivopts.c (get_phi_with_result): New.
3778 (remove_statement): Handle case where stored phi was updated
3779 and is no longer the same.
3780 * graphite.c (is_parameter): New.
3781 (is_old_iv): New.
3782 (expand_scalar_variables_expr): New.
3783 (expand_scalar_variables_stmt): New.
3784 (expand_scalar_variables): New.
3785 (move_phi_nodes): Create new phi instead of moving old one.
3786 (translate_clast): Call expand_scalar_variables.
3787 (find_vdef_for_var_in_bb): Also scan regular definitions.
3788 (skip_phi_defs): New.
3789 (collect_scop_exit_phi_args): New.
3790 (patch_scop_exit_phi_args): New.
3791 (gloog): Patch phis after scop.
3792 * tree-flow.h: (add_phi_node_to_bb): Declared.
3793 (make_phi_node): Declared.
3794
37952008-08-26 Sebastian Pop <sebastian.pop@amd.com>
3796
3797 * graphite.c (end_scop): Split the entry of the scop when it
3798 is the header of the loop in which the scop is ending.
3799 (build_scops_1, limit_scops): Update uses of end_scop.
3800
38012008-08-26 Sebastian Pop <sebastian.pop@amd.com>
3802
3803 * graphite.c (dot_all_scops_1): Do not fail on uninitialized
3804 SCOP_ENTRY or SCOP_EXIT.
3805
38062008-08-25 Sebastian Pop <sebastian.pop@amd.com>
3807
3808 * graphite.c (get_construction_edge): Removed.
3809 (gloog): Construction edge is the scop entry edge.
3810
38112008-08-25 Sebastian Pop <sebastian.pop@amd.com>
3812
3813 * graphite.c (can_generate_for_scop): Removed.
3814 (gloog): Do not call it.
3815
38162008-08-25 Sebastian Pop <sebastian.pop@amd.com>
3817
3818 * graphite.c (new_scop): Entry of a scop is an edge.
3819 Initialize SESE region.
3820 (free_scop): Free SESE region.
3821 (build_scops_1, scopdet_bb_info): Work on edges, not on bbs.
3822 (split_difficult_bb): New, split from end_scop.
3823 (end_scop): Exit of a scop is an edge.
3824 (build_scop_bbs): Never check CDI_POST_DOMINATORS: this info is
3825 not automatically updated and thus is always wrong.
3826 * graphite.h (struct sese): New.
3827 (SESE_ENTRY): New.
3828 (SESE_EXIT): New.
3829 (struct scop): New field for a SESE region. Remove entry, exit.
3830 (SCOP_ENTRY, SCOP_EXIT): Update definitions to match same
3831 semantics as before. Moved comment around.
3832
38332008-08-25 Tobias Grosser <grosser@fim.uni-passau.de>
3834 Sebastian Pop <sebastian.pop@amd.com>
3835
3836 * graphite.c (graphite_transform_loops): Always enable gloog
3837 and find_transform when ENABLE_CHECKING.
3838
38392008-08-25 Sebastian Pop <sebastian.pop@amd.com>
3840
3841 * graphite.c (graphite_transform_loops): Move pretty printer
3842 of SCOPs before doing any transform. Remove call to print_scops
3843 and dot_all_scops_1.
3844
38452008-08-25 Sebastian Pop <sebastian.pop@amd.com>
3846
3847 * graphite.c (dump_gbb_conditions): Don't try to print NULL pointers.
3848 (print_graphite_bb): Same.
3849
38502008-08-25 Sebastian Pop <sebastian.pop@amd.com>
3851
3852 * graphite.c (dot_all_scops_1): Cleanup.
3853 (move_scops): Fix comment.
3854
38552008-08-25 Sebastian Pop <sebastian.pop@amd.com>
3856
3857 * graphite.c (build_scop_bbs): Revert commit 139355:
3858
3859 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
3860 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
3861
3862 * graphite.c (build_scop_bbs): Factor up code.
3863
38642008-08-25 Tobias Grosser <grosser@fim.uni-passau.de>
3865
3866 * graphite.c (gloog): Update dominator info.
3867
38682008-08-25 Tobias Grosser <grosser@fim.uni-passau.de>
3869
3870 * graphite.c (remove_cond_exprs): Do not fail on empty bbs.
3871
38722008-08-24 Sebastian Pop <sebastian.pop@amd.com>
3873
3874 * graphite.c (new_graphite_bb): Remove GBB_INDEX_TO_NUM_MAP
3875 initialization.
3876 (free_graphite_bb): Remove GBB_INDEX_TO_NUM_MAP free.
3877 (translate_clast): Correct formatting.
3878 * graphite.h (struct num_map): Removed.
3879 (struct graphite_bb): Remove num_map field.
3880 (GBB_INDEX_TO_NUM_MAP): Removed.
3881
38822008-08-24 Sebastian Pop <sebastian.pop@amd.com>
3883
3884 * graphite.c (build_access_matrix_with_af): Fix comments.
3885 (build_scop_data_accesses): Same.
3886
38872008-08-24 Sebastian Pop <sebastian.pop@amd.com>
3888
3889 * graphite.c (build_scop_data_accesses): Don't construct
3890 access matrices. Add a FIXME and an assert condition that
3891 should pass when the access matrices will be needed.
3892
38932008-08-24 Sebastian Pop <sebastian.pop@amd.com>
3894
3895 * tree-data-ref.c (stmt_simple_memref_p): Don't call
3896 really_constant_p.
3897 * graphite.c (build_graphite_bb): Renamed new_graphite_bb.
3898 Moved close by free_graphite_bb.
3899 (free_graphite_bb): Call free_data_refs. Reset bb->aux.
3900 (new_scop): Move close by free_scop.
3901 (graphite_transform_loops): Avoid linear scan to reset bb->aux.
3902
39032008-08-22 Jan Sjodin <jan.sjodin@amd.com>
3904
3905 * cfgloopmanip.c (create_empty_if_region_on_edge): New.
3906 * graphite.c (clast_to_gcc_expression): Call gmp_cst_to_tree
3907 instead of recursive call.
3908 (graphite_translate_clast_equation): New.
3909 (graphite_create_guard_cond_expr): New.
3910 (graphite_create_new_guard): New.
3911 (get_stack_index_from_iv): Removed.
3912 (graphite_rename_ivs_stmt): Use gbb_loop_index.
3913 (get_true_edge_from_guard_bb): New.
3914 (translate_clast): Handle stmt_guard in clast.
3915 (get_construction_edge): Allow construction edge detection for
3916 a scope entry with multiple predecessors if one predecessor is
3917 the immediate dominator of scope entry.
3918 (can_generate_code_stmt): Enable code generation for clast_guard.
3919 (gloog): Use correct context loop. Removed check for post dominators.
3920 * cfgloop.h (create_empty_if_region_on_edge): Declared.
3921
39222008-08-21 Sebastian Pop <sebastian.pop@amd.com>
3923
3924 * graphite.c (remove_dead_loops): Document better which
3925 loops are removed.
3926
39272008-08-21 Sebastian Pop <sebastian.pop@amd.com>
3928
3929 * Makefile.in: Rename POLYLIBLIBS and POLYLIBINC to PPLLIBS
3930 and PPLINC.
3931 (graphite.o): Also depends on pointer-set.h.
3932
39332008-08-21 Sebastian Pop <sebastian.pop@amd.com>
3934
3935 * graphite.c (scop_record_loop): Fix compile warning.
3936
39372008-08-21 Harsha Jagasia <harsha.jagasia@amd.com>
3938 Sebastian Pop <sebastian.pop@amd.com>
3939
3940 * graphite.c (scop_record_loop): DECL_NAME can be NULL.
3941
39422008-08-21 Sebastian Pop <sebastian.pop@amd.com>
3943
3944 * graphite.c (build_graphite_bb): Initialize bb->aux to
3945 point to the graphite_bb_p.
3946 (graphite_bb_from_bb): Renamed gbb_from_bb; returns the
3947 content of bb->aux.
3948 (add_bb_domains): Does not use the scop parameter.
3949 (graphite_transform_loops): Clean bb->aux at the end.
3950
39512008-08-20 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
3952 Sebastian Pop <sebastian.pop@amd.com>
3953
3954 * testsuite/lib/target-supports.exp
3955 (check_effective_target_fgraphite): New.
3956
3957 * testsuite/gcc.dg/graphite/graphite.exp: Early exit when
3958 check_effective_target_fgraphite returns false.
3959 Set dg-do-what-default to compile.
3960 (scan-graphite-dump-times): Removed.
3961 * testsuite/gfortran.dg/graphite/graphite.exp: Same.
3962
3963 * testsuite/gcc.dg/graphite/scop-0.c: Do not use "dg-do compile".
3964 Use scan-tree-dump-times instead of scan-graphite-dump-times.
3965 * testsuite/gcc.dg/graphite/scop-1.c: Same.
3966 * testsuite/gcc.dg/graphite/scop-2.c: Same.
3967 * testsuite/gcc.dg/graphite/scop-3.c: Same.
3968 * testsuite/gcc.dg/graphite/scop-4.c: Same.
3969 * testsuite/gcc.dg/graphite/scop-5.c: Same.
3970 * testsuite/gcc.dg/graphite/scop-6.c: Same.
3971 * testsuite/gcc.dg/graphite/scop-7.c: Same.
3972 * testsuite/gcc.dg/graphite/scop-8.c: Same.
3973 * testsuite/gcc.dg/graphite/scop-9.c: Same.
3974 * testsuite/gcc.dg/graphite/scop-10.c: Same.
3975 * testsuite/gcc.dg/graphite/scop-11.c: Same.
3976 * testsuite/gcc.dg/graphite/scop-12.c: Same.
3977 * testsuite/gcc.dg/graphite/scop-13.c: Same.
3978 * testsuite/gcc.dg/graphite/scop-matmult.c: Same.
3979 * testsuite/gcc.dg/graphite/scop-14.c: Same.
3980 * testsuite/gcc.dg/graphite/scop-15.c: Same.
3981 * testsuite/gcc.dg/graphite/block-0.c: Same.
3982 * testsuite/gcc.dg/graphite/scop-16.c: Same.
3983 * testsuite/gcc.dg/graphite/block-1.c: Same.
3984 * testsuite/gcc.dg/graphite/scop-17.c: Same.
3985 * testsuite/gcc.dg/graphite/scop-18.c: Same.
3986 * testsuite/gfortran.dg/graphite/block-1.f90: Same.
3987 * testsuite/gfortran.dg/graphite/scop-1.f: Same.
3988 * testsuite/gfortran.dg/graphite/block-2.f: Same.
3989
39902008-08-20 Sebastian Pop <sebastian.pop@amd.com>
3991
3992 * graphite.c: Fix some XXX comments.
3993 (build_scop_dynamic_schedules): Removed.
3994
39952008-08-20 Sebastian Pop <sebastian.pop@amd.com>
3996
3997 * graphite.h (scop_max_loop_depth): Moved...
3998 * graphite.c (scop_max_loop_depth): ...here.
3999 (remove_all_edges_1): New.
4000 (remove_all_edges): Factored code.
4001 (remove_cond_exprs): Check only the last statement for
4002 a GIMPLE_COND expression.
4003
40042008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4005
4006 * graphite.c (scan_tree_for_params): Early return when the
4007 expression is a chrec_dont_know. Handle case NEGATE_EXPR.
4008 (find_scop_parameters): Factor out code.
4009 (graphite_trans_bb_strip_mine): Remove dead code.
4010
40112008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4012
4013 * graphite.c (clast_to_gcc_expression, graphite_create_new_loop,
4014 graphite_trans_bb_move_loop): Factor asserts.
4015 (gloog): Perform sanity checks only for ENABLE_CHECKING.
4016 Do not call calculate_dominance_info and estimate_bb_frequencies.
4017
40182008-08-20 Jan Sjodin <jan.sjodin@amd.com>
4019
4020 * graphite.c (create_loops_mapping, free_loops_mapping,
4021 create_loops_mapping_num, debug_loop_mapping_1,
4022 debug_loop_mapping, graphite_loops_mapping_max_loop_num,
4023 get_loop_mapping_for_num, graphite_loops_mapping_add_child,
4024 graphite_loops_mapping_add_child_num,
4025 graphite_loops_mapping_insert_child,
4026 graphite_loops_mapping_parent, get_loop_mapped_depth_for_num,
4027 get_loop_mapped_depth, split_loop_mapped_depth_for_num,
4028 loop_mapped_depth_split_loop, swap_loop_mapped_depth_for_num,
4029 create_num_from_index, get_num_from_index,
4030 swap_loop_mapped_depth): Removed.
4031 (new_scop): Do not initialize SCOP_LOOPS_MAPPING.
4032 (free_scop): Do not call free_loops_mapping.
4033 (graphite_get_new_iv_stack_index_from_old_iv): Renamed
4034 get_stack_index_from_iv. Use GBB_LOOPS instead of calling
4035 get_loop_mapped_depth.
4036 (graphite_trans_bb_move_loop): Do not update the loop mapping.
4037 (graphite_trans_bb_strip_mine): Same.
4038 * graphite.h (graphite_loops_mapping, graphite_loop_node): Removed.
4039 (struct scop): Remove field loops_mapping.
4040
40412008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4042 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
4043
4044 * graphite.c (scop_record_loop): Factor out one level of the
4045 condition by early return.
4046 (build_scop_loop_nests): Format following FSF coding style.
4047 (build_scop_dynamic_schedules): Factor out code.
4048 (scopdet_bb_info): Reindent. Default case should not be reachable.
4049
40502008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4051 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
4052
4053 * graphite.c (loop_affine_expr): Check for DECL_P or struct
4054 assignments that are not handled as simple operands for now.
4055
40562008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4057 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
4058
4059 * graphite.c (build_scop_bbs): Factor up code.
4060
40612008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4062 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
4063
4064 * graphite.c (stmt_simple_for_scop_p): Factor code out
4065 of the loop.
4066 (enum gbb_type): New. Group all the GBB_* types under it.
4067 (is_loop_exit): Moved...
4068 (end_scop): Enable BB spliting.
4069 * cfgloop.c (is_loop_exit): ...here. Reimplemented.
4070 * cfgloop.h (is_loop_exit): Declared.
4071
40722008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4073
4074 * doc/invoke.texi: Remove strides from examples containing
4075 DO loops when the strides are equal to 1.
4076
40772008-08-20 Harsha Jagasia <harsha.jagasia@amd.com>
4078 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
4079
4080 * graphite.c (graphite_trans_scop_block): Or the result with
4081 the result from graphite_trans_loop_block.
4082 * testsuite/gcc.dg/graphite/block-1.c: New.
4083 * testsuite/gfortran.dg/graphite/block-1.f90: New.
4084 * testsuite/gfortran.dg/graphite/block-2.f: New.
4085
40862008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4087
4088 * graphite.c (graphite_transform_loops): Call cloog_initialize
4089 and cloog_finalize.
4090
40912008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4092
4093 * tree-data-ref.c) (stmt_simple_memref_p): New.
4094 * tree-data-ref.h (stmt_simple_memref_p): Declared.
4095 * graphite.c (stmt_simple_memref_for_scop_p): Removed.
4096 (is_simple_operand): Call stmt_simple_memref_p.
4097
4098 * testsuite/gcc.dg/graphite/scop-matmult.c: Updated for not
4099 using pointer arithmetic, as this is optimized by PRE and
4100 makes the code too difficult to analyze.
4101
4102 * testsuite/gcc.dg/graphite/scop-18.c: Same.
4103
41042008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4105
4106 * gdbinit.in (pgg): New.
4107
41082008-08-15 Tobias Grosser <grosser@fim.uni-passau.de>
4109
4110 * graphite.c (graphite_trans_loop_block): Fix warning.
4111
41122008-08-15 Tobias Grosser <grosser@fim.uni-passau.de>
4113
4114 * graphite.c (graphite_trans_loop_block): Fix my merge error.
4115
41162008-08-15 Tobias Grosser <grosser@fim.uni-passau.de>
4117
4118 * graphite.c (graphite_trans_bb_block): Remove check for
4119 flag_loop_strip_mine, flag_loop_block, flag_loop_interchange.
4120 Check if loop blocking is profitable for every loop, before applying
4121 the changes.
4122 (graphite_apply_transformations): Call graphite_trans_bb_block only,
4123 if flag_loop_block is set.
4124
41252008-08-14 Sebastian Pop <sebastian.pop@amd.com>
4126
4127 * graphite.c: Add some more documentation for the loop
4128 mapping.
4129
41302008-08-14 Sebastian Pop <sebastian.pop@amd.com>
4131
4132 * Makefile.in (tree-data-ref.o): Remove dependence on graphite.h.
4133 * graphite.c: Format on less than 80 columns.
4134 * graphite.h: Same.
4135
41362008-08-14 Sebastian Pop <sebastian.pop@amd.com>
4137
4138 * cfgloopmanip.c (loopify): Use update_dominators_in_loop.
4139
41402008-08-14 Sebastian Pop <sebastian.pop@amd.com>
4141
4142 * doc/invoke.texi (floop-block, floop-strip-mine,
4143 floop-interchange): Update documentation with examples.
4144
41452008-08-13 Sebastian Pop <sebastian.pop@amd.com>
4146
4147 * cfgloopmanip.c (create_empty_loop_on_edge): Don't call
4148 add_referenced_var.
4149 * graphite.c (graphite_create_new_loop): Call add_referenced_var.
4150
41512008-08-13 Sebastian Pop <sebastian.pop@amd.com>
4152
4153 * cfgloopmanip.c (create_empty_loop_on_edge): Improve documentation.
4154 Factor gcc_asserts into a single one. Use force_gimple_operand_gsi.
4155 * tree-scalar-evolution.c: Revert useless changes.
4156 * tree-phinodes.c: Same.
4157 * cfghooks.c: Same.
4158 * vec.h: Same.
4159 * tree-vectorizer.h: Same.
4160 * tree-flow.h: Same.
4161 * tree-cfg.c: Same.
4162 * common.opt (fgraphite): Update documentation.
4163
41642008-08-12 Harsha Jagasia <harsha.jagasia@amd.com>
4165
4166 * doc/invoke.texi (-floop-block, -floop-strip-mine,
4167 -floop-interchange): Add more text for explaining what each of these
4168 flags is doing.
4169 * tree-into-ssa.c (gimple_vec): Moved to...
4170 * graphite.c: Include gimple.h.
4171 (gimple_vec): Moved to...
4172 (del_loop_to_cloog_loop): Removed.
4173 (loop_affine_expr): Do not call create_data_ref when the
4174 operand is a constant.
4175 (new_scop): Use free instead of del_loop_to_cloog_loop.
4176 * Makefile.in (graphite.o): Depend on GIMPLE_H.
4177 * gimple.h (gimple_vec): ... here.
4178
41792008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
4180
4181 * graphite.c (scopdet_bb_info): Only allow loops with known number of
4182 latch executions.
4183 (build_loop_iteration_domains): Fail, if latch executions unknown.
4184
41852008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
4186
4187 * graphite.c (add_conditions_to_domain): New.
4188 (build_scop_conditions_1): Call add_conditions_to_domain.
4189 (set_cloog_options): Allow to disable optimizations.
4190
41912008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
4192
4193 * graphite.c (find_params_in_bb): Look for parameters in conditions.
4194 Do not use walk_dominator_tree.
4195 (find_scop_parameters): Do not use walk_dominator_tree.
4196
41972008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
4198
4199 * graphite.c (scan_tree_for_params) Add / Subtract inequality.
4200 (idx_record_params): Adapt.
4201 * graphite.h (scop_gimple_loop_depth): New.
4202
42032008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
4204
4205 * graphite.c (build_scop_dynamic_schedules): Remove value_init.
4206 (scan_tree_for_params): Remove value_init.
4207 (build_scop_context): Remove value_init.
4208 (build_loop_iteration_domains): Remove value_init.
4209 (schedule_to_scattering): Remove value_init.
4210 (graphite_trans_bb_strip_mine): Remove value_init.
4211
42122008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
4213
4214 * gcc/graphite.c (limit_scops): New.
4215 (graphite_transform_loops): Add limit SCoPs.
4216 * gcc/testsuite/gcc.dg/graphite/scop-0.c: Update number of SCoPs.
4217 * gcc/testsuite/gcc.dg/graphite/scop-1.c: Update number of SCoPs.
4218 * gcc/testsuite/gcc.dg/graphite/scop-10.c: Update number of SCoPs.
4219 * gcc/testsuite/gcc.dg/graphite/scop-11.c: Update number of SCoPs.
4220 * gcc/testsuite/gcc.dg/graphite/scop-12.c: Update number of SCoPs.
4221 * gcc/testsuite/gcc.dg/graphite/scop-13.c: Update number of SCoPs.
4222 * gcc/testsuite/gcc.dg/graphite/scop-14.c: Update number of SCoPs.
4223 * gcc/testsuite/gcc.dg/graphite/scop-15.c: Update number of SCoPs.
4224 * gcc/testsuite/gcc.dg/graphite/scop-16.c: Update number of SCoPs.
4225 Change loop numbers.
4226 * gcc/testsuite/gcc.dg/graphite/scop-17.c: Update number of SCoPs.
4227 Change loop numbers.
4228 * gcc/testsuite/gcc.dg/graphite/scop-18.c: Update number of SCoPs.
4229 * gcc/testsuite/gcc.dg/graphite/scop-2.c: Update number of SCoPs.
4230 * gcc/testsuite/gcc.dg/graphite/scop-3.c: Update number of SCoPs.
4231 * gcc/testsuite/gcc.dg/graphite/scop-4.c: Update number of SCoPs.
4232 * gcc/testsuite/gcc.dg/graphite/scop-5.c: Update number of SCoPs.
4233 * gcc/testsuite/gcc.dg/graphite/scop-6.c: Update number of SCoPs.
4234 * gcc/testsuite/gcc.dg/graphite/scop-7.c: Update number of SCoPs.
4235 * gcc/testsuite/gcc.dg/graphite/scop-8.c: Update number of SCoPs.
4236 * gcc/testsuite/gcc.dg/graphite/scop-9.c: Update number of SCoPs.
4237 * gcc/testsuite/gcc.dg/graphite/scop-matmult.c: Update number of SCoPs.
4238
42392008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
4240
4241 * graphite.c (graphite_transform_loops): Call always find_transform.
4242
42432008-08-08 Tobias Grosser <grosser@fim.uni-passau.de>
4244
4245 * graphite.c (free_loops_mapping): New.
4246 (stmt_simple_for_scop_p): Fix typo.
4247 (stmt_simple_for_scop_p): Fix tuples functions, that
4248 broke polyhedron.
4249 (free_graphite_bb): Fix some memleaks.
4250 (free_scop): Fix some memleaks.
4251 (scopdet_bb_info): Do not forget some tmp SCoPs.
4252 (find_params_in_bb): Fix some memleaks.
4253 (clast_to_gcc_expression): Fix warning.
4254
42552008-08-07 Tobias Grosser <grosser@fim.uni-passau.de>
4256
4257 * testsuite/gcc.dg/graphite/scop-16.c: Fix for 32bit.
4258 * testsuite/gcc.dg/graphite/scop-17.c: Fix for 32bit.
4259
42602008-08-04 Sebastian Pop <sebastian.pop@amd.com>
4261
4262 * tree-ssa-loop.c (tree-ssa-loop.o): Do not include toplev.h.
4263 Move code ifdef-ed HAVE_cloog...
4264 * graphite.c: Include toplev.h.
4265 ... here.
4266 * Makefile.in (OBJS-common): Always build graphite.o.
4267 (BACKEND): Remove @GRAPHITE@.
4268 (tree-ssa-loop.o): Do not depend on TOPLEV_H.
4269 (graphite.o): Depend on TOPLEV_H.
4270
42712008-08-04 Sebastian Pop <sebastian.pop@amd.com>
4272
4273 * Makefile.in (tree-ssa-loop.o): Depend on TOPLEV_H.
4274 Remove typo left from polylib to ppl conversion.
4275 * graphite.c (graphite_transforms): Use sorry instead of fatal.
4276
42772008-08-03 Sebastian Pop <sebastian.pop@amd.com>
4278
4279 * toplev.c (process_options): Move the graphite loop optimization
4280 flags...
4281 * tree-ssa-loop.c (graphite_transforms): ... here.
4282 When not configured with CLooG, print to dump_file that
4283 Graphite transforms were not performed.
4284 * testsuite/gcc.dg/graphite/graphite.exp (scan-graphite-dump-times):
4285 New.
4286 * testsuite/gcc.dg/graphite/*.c: Updated all testcases to use
4287 scan-graphite-dump-times.
4288
42892008-08-03 Sebastian Pop <sebastian.pop@amd.com>
4290
4291 * graphite.c (dot_scop, dot_all_scops): Do not call system.
4292 Do not open /tmp/scop.dot and /tmp/allscops.dot.
4293
42942008-08-02 Sebastian Pop <sebastian.pop@amd.com>
4295 Jan Sjodin <jan.sjodin@amd.com>
4296
4297 * configure: Regenerated.
4298 * omp-low.c (expand_omp_sections): Remove now unused code.
4299 * config.in (HAVE_polylib): Removed.
4300 * configure.ac (HAVE_polylib, POLYLIBLIBS, POLYLIBINC): Removed.
4301 (PPLLIBS, PPLINC): Added.
4302 * graphite.c: Replace unsigned with int wherever possible.
4303 Don't access Cloog's data structures, but use accessor functions.
4304 Clast's stmt->type is now implemented as a vtable: change the
4305 switches of stmt->type into ifs.
4306 (polylib/polylibgmp.h): Don't include.
4307 (initialize_dependence_polyhedron,
4308 initialize_data_dependence_polyhedron, is_empty_polyhedron,
4309 statement_precedes_p, test_dependence, build_rdg_all_levels,
4310 dump_dependence_graph): Removed until this code is cleaned up
4311 or ported to Cloog.
4312 * Makefile.in (POLYLIBLIBS): Renamed PPLLIBS.
4313 (POLYLIBINC): Renamed PPLINC.
4314
43152008-08-01 Harsha Jagasia <harsha.jagasia@amd.com>
4316 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
4317 Jan Sjodin <jan.sjodin@amd.com>
4318
4319 Finish the merge and tuplification of graphite.
4320
43212008-07-24 Sebastian Pop <sebastian.pop@amd.com>
4322 Jan Sjodin <jan.sjodin@amd.com>
4323
4324 Partial merge from mainline (138072:138275).
4325 * graphite.c still has to be tuplified.
4326
43272008-07-29 Jan Sjodin <jan.sjodin@amd.com>
4328
4329 * graphite.c (graphite_loops_mapping_max_loop_num): New.
4330 (create_num_from_index): New.
4331 (get_num_from_index): Also pass in the graphite BB.
4332 (free_graphite_bb): Free GBB_INDEX_TO_NUM_MAP.
4333 (build_graphite_bb): Initialize GBB_INDEX_TO_NUM_MAP.
4334 (graphite_trans_bb_strip_mine): Call create_num_from_index.
4335 (is_interchange_valid): Return false when failing.
4336 * graphite.h (struct num_map): New.
4337 (struct graphite_bb): New field num_map.
4338 (GBB_LOOPS_MAPPING): Renamed GBB_INDEX_TO_NUM_MAP.
4339
43402008-07-29 Tobias Grosser <grosser@fim.uni-passau.de>
4341
4342 * graphite.c (dump_gbb_conditions): Print also conditions like
4343 "if (a)". Remove dublicated code and use print_generic_expr ().
4344 (stmt_simple_for_scop_p): Only allow conditions we can handle
4345 {<, <=, >, >=}.
4346
43472008-07-25 Jan Sjodin <jan.sjodin@amd.com>
4348
4349 * graphite.h (struct scop): Removed new_ivs field.
4350 (SCOP_NEWIVS): Deleted.
4351 * graphite.c (new_scop, free_scop, clast_name_to_gcc,
4352 clast_to_gcc_expression, graphite_create_new_loop):
4353 Removed use of new_ivs.
4354
43552008-07-25 Jan Sjodin <jan.sjodin@amd.com>
4356
4357 * graphite.c (debug_oldivs, debug_loop_vec, create_loops_mapping,
4358 create_loops_mapping_num, debug_loop_mapping_1): New.
4359 (debug_loop_mapping): Call debug_loop_mapping_1.
4360 (get_loop_mapping_for_num,
4361 graphite_loops_mapping_add_child,
4362 graphite_loops_mapping_add_child_num,
4363 graphite_loops_mapping_insert_child,
4364 graphite_loops_mapping_parent,
4365 split_loop_mapped_depth_for_num,
4366 loop_mapped_depth_split_loop): New.
4367 (increment_loop_mapped_depths): Removed.
4368 (swap_loop_mapped_depth_for_num): Reimplemented.
4369 (new_scop): Call create_loops_mapping.
4370 (scop_record_loop): Call graphite_loops_mapping_insert_child.
4371 (translate_clast): Pass the old loop father in parameter, and pass
4372 it to get_old_iv_from_ssa_name.
4373 (remove_edges_around_useless_blocks, can_generate_code_stmt,
4374 can_generate_code, can_generate_for_scop): New.
4375 (graphite_trans_bb_block): Returns false when it fails to transform.
4376 * graphite.h (graphite_loop_node, graphite_loops_mapping): New.
4377
43782008-07-25 Sebastian Pop <sebastian.pop@amd.com>
4379
4380 Reverted all the changes related to the streamization and
4381 loop fusion.
4382 These changes are now tracked in the streamization branch.
4383
43842008-07-25 Sebastian Pop <sebastian.pop@amd.com>
4385 Jan Sjodin <jan.sjodin@amd.com>
4386
4387 * graphite.c (gbb_compare): Correctly constify.
4388 (gbb_can_be_ignored): Indent.
4389 (graphite_trans_scop_swap_1and2): Add legality check.
4390 Remove dead FIXMEs.
4391
43922008-07-25 Sebastian Pop <sebastian.pop@amd.com>
4393
4394 Remove fallouts from "Reverted the Condate changes".
4395 * tree.h: Remove unused decl.
4396 * testsuite/gcc.dg/tree-checker: Same.
4397 * timevar.def: Remove counter.
4398
43992008-07-24 Sebastian Pop <sebastian.pop@amd.com>
4400
4401 * Merge from mainline (135673:138072).
4402
4403 Reverted the MIRO changes (from 2008-04-05) that are now
4404 tracked in the miro branch.
4405 * tree-bounds.c: Removed.
4406 * tree-bounds.h: Removed.
4407
4408 Reverted the Condate changes (from 2006-07-04, 2007-03-20) that
4409 are now tracked in the condate branch.
4410 * tree-check.c: Removed.
4411 * tree-match.c: Removed.
4412 * condate.y: Removed.
4413
44142008-07-24 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
4415
4416 * common.opt: New user flag -floop-block, -floop-strip-mine
4417 and -floop-interchange.
4418 * toplev.c (process_options): Enable -fgraphite pass if any one of the
4419 graphite loop optimization flags is turned on.
4420 * graphite.c (graphite_apply_transformations): Add flag_loop_block,
4421 flag_loop_strip_mine and flag_loop_interchange checks before
4422 optimizations.
4423 * doc/invoke.texi: Remove -fgraphite and add -floop-block,
4424 -floop-strip-mine and -floop-interchange.
4425 * testsuite/gcc.dg/graphite/block-0.c: Add -floop-block and remove
4426 -fgraphite.
4427 * testsuite/gcc.dg/graphite/scop-16.c: Ditto.
4428 * testsuite/gcc.dg/graphite/scop-17.c: Ditto.
4429 * testsuite/gcc.dg/graphite/scop-18.c: Ditto.
4430
44312008-07-23 Jan Sjodin <jan.sjodin@amd.com>
4432 Sebastian Pop <sebastian.pop@amd.com>
4433
4434 * cfgloopmanip.c (update_dominators_in_loop): Make it static.
4435 (create_empty_loop_on_edge): More fixes.
4436 * tree-phinodes.c (resize_phi_node): Extern.
4437 (unlink_phi_node, move_phi_node): New split from remove_phi_node.
4438 * cfghooks.c (update_dominator_information): New split from
4439 split_edge.
4440 * tree-vectorizer.c (rename_variables_in_bb): Extern.
4441 * tree-dfa.c (collect_dfa_stats): Start walking the CFG on the
4442 successor of the function entry block.
4443
4444 * graphite.c: Include pointer-set.h.
4445 (debug_loop_mapping, increment_loop_mapped_depths,
4446 get_loop_mapped_depth_for_num, get_loop_mapped_depth,
4447 set_loop_mapped_depth_for_num, set_loop_mapped_depth,
4448 swap_loop_mapped_depth_for_num, get_num_from_index,
4449 swap_loop_mapped_depth, loop_iv_stack_debug,
4450 loop_iv_stack_push, loop_iv_stack_pop, loop_iv_stack_get_iv,
4451 loop_iv_stack_get_iv_from_name, loop_iv_stack_debug,
4452 get_old_iv_from_ssa_name): New.
4453 (new_scop): Initialize SCOP_LOOPS_MAPPING.
4454 (free_scop): Free SCOP_LOOPS_MAPPING.
4455 (scop_record_loop): Record old ivs.
4456 (create_var_name): Removed.
4457 (initialize_cloog_names): Allocate double space in case strip mine
4458 applies to all loops once.
4459 (clast_name_to_gcc): Look up in the map ivstack passed in parameter.
4460 (clast_to_gcc_expression): Same. Implement more clast to gimple
4461 translation.
4462 (graphite_create_new_loop): Pass in ivstack.
4463 (remove_all_edges): Pass in the construction_edge.
4464 (graphite_remove_iv): Removed.
4465 (graphite_rename_ivs, graphite_rename_ivs_stmt,
4466 remove_cond_exprs): Rewritten.
4467 (move_phi_nodes): New.
4468 (disconnect_virtual_phi_nodes, disconnect_cond_expr): Removed.
4469 (translate_clast): Pass in ivstack. Rewrite some cases.
4470 (set_cloog_options, debug_clast_stmt): New.
4471 (find_transform): Use set_cloog_options.
4472 (outermost_loop_layer): Removed.
4473 (get_construction_edge, collect_virtual_phis, find_vdef_for_var_in_bb,
4474 find_vdef_for_var_1, find_vdef_for_var, patch_phis_for_virtual_defs,
4475 mark_old_loops, remove_dead_loops): New.
4476 (gloog): Rewritten.
4477 (graphite_trans_bb_move_loop): Call swap_loop_mapped_depth.
4478 (const_column_index, get_first_matching_sign_row_index,
4479 get_lower_bound_row, get_upper_bound_row, get_lower_bound,
4480 get_upper_bound): New.
4481 (graphite_trans_bb_strip_mine): Also update the iv map.
4482
4483 * graphite.h (graphite_loops_mapping, GBB_LOOPS_MAPPING): New.
4484 (struct name_tree): Add a loop field.
4485 (struct scop): Add a graphite_loops_mapping field.
4486 (SCOP_LOOPS_MAPPING): New.
4487 (debug_clast_stmt): Declare.
4488 * lambda.h (find_induction_var_from_exit_cond): Declare.
4489 (lambda-code.c): (find_induction_var_from_exit_cond): Extern.
4490 * cfgloop.h (update_dominators_in_loop): Removed declaration.
4491 (create_empty_loop_on_edge): Updated.
4492 * tree-flow.h (remove_bb, resize_phi_node, move_phi_node,
4493 rename_variables_in_bb): Declare.
4494 * tree-cfg.c (remove_bb): Extern.
4495
4496 * testsuite/gcc.dg/graphite/block-0.c: New.
4497
44982008-07-21 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
4499 Sebastian Pop <sebastian.pop@amd.com>
4500
4501 * graphite.c (strip_mine_profitable_p): New.
4502 (graphite_trans_bb_block): Disable strip mining if not profitable.
4503
4504 * testsuite/gcc.dg/graphite/scop-18.c: New.
4505 * testsuite/gcc.dg/graphite/scop-17.c: Fixed.
4506 * testsuite/gcc.dg/graphite/scop-16.c: Fixed.
4507
45082008-07-17 Harsha Jagasia <harsha.jagasia@amd.com>
4509 Jan Sjodin <jan.sjodin@amd.com>
4510 Sebastian Pop <sebastian.pop@amd.com>
4511
4512 * graphite.c (is_interchange_valid): New.
4513 (graphite_trans_bb_block): Check loop nest of basic block for legality
4514 of interchange.
4515
4516 * graphite.h (gbb_inner_most_loop_index, outer_most_loop_1,
4517 outer_most_loop, gbb_outer_most_loop_index): New.
4518
4519 * tree-loop-linear.c (perfect_loop_nest_depth): Remove static.
4520 * tree-flow.h (perfect_loop_nest_depth): Declare as extern.
4521 * testsuite/gcc.dg/graphite/scop-16.c: New.
4522 * testsuite/gcc.dg/graphite/scop-17.c: New.
4523
45242008-07-11 Tobias Grosser <grosser@fim.uni-passau.de>
4525
4526 * graphite.c (scop_remove_ignoreable_gbbs): Also update bitmap.
4527 (graphite_trans_scop_block): Ignore SCoPs without bbs.
4528
45292008-07-11 Tobias Grosser <grosser@fim.uni-passau.de>
4530
4531 * graphite.c (new_scop): Initialize SCOP_EXIT.
4532 (scopdet_info): Add.
4533 (scopdet_bb_info): Rename from is_bb_addable. Cleanup, bugfixes.
4534 (build_scops_1): Cleanup, bugfixes.
4535 (build_scops): Cleanup.
4536
4537 * testsuite/gcc.dg/graphite/scop-matmult.c: Remove duplicated code.
4538 * testsuite/gcc.dg/graphite/scop-15.c: Add SCoP numbers.
4539
45402008-07-10 Harsha Jagasia <harsha.jagasia@amd.com>
4541
4542 * testsuite/gfortran.dg/graphite/scop-1.f: Update to reduced test case.
4543
4544 * testsuite/gfortran.dg/graphite/graphite.exp: Use
4545 DEFAULT_GRAPHITE_FLAGS.
4546
4547 * testsuite/gcc.dg/graphite/scop-15.c: Update to reduced test case.
4548
45492008-07-10 Harsha Jagasia <harsha.jagasia@amd.com>
4550
4551 * graphite.c (scan_tree_for_params): Do not assert any more if
4552 MULT_EXPR parameter is negative.
4553
4554 * testsuite/gfortran.dg/graphite/scop-1.f: New.
4555
4556 * testsuite/gfortran.dg/graphite/graphite.exp: New.
4557
4558 * testsuite/gcc.dg/graphite/scop-15.c: New.
4559
45602008-07-10 Harsha Jagasia <harsha.jagasia@amd.com>
4561
4562 * graphite.c (is_bb_addable): Fix segfault in spec gzip and reformat.
4563
45642008-07-10 Tobias Grosser <grosser@fim.uni-passau.de>
4565
4566 * graphite.c (graphite_trans_bb_swap_loops): Rename from
4567 graphite_swap_loops.
4568 (graphite_trans_bb_move_loop): New.
4569 (graphite_trans_bb_strip_mine): Rename from graphite_strip_mine_loop.
4570 (graphite_trans_bb_block): New.
4571 (graphite_trans_loop_block): New.
4572 (graphite_trans_scop_swap_1and2): Rename from
4573 graphite_trans_swap_1and2.
4574 (graphite_trans_scop_strip): Rename from graphite_trans_strip.
4575 (graphite_trans_scop_block): New.
4576 (graphite_apply_transformations): Rename from
4577 graphite_transformations.
4578
4579 * testsuite/gcc.dg/graphite/scop-matmult.c: New.
4580
45812008-07-10 Tobias Grosser <grosser@fim.uni-passau.de>
4582
4583 * graphite.c (gbb_compare): New.
4584 (graphite_sort_gbbs): New.
4585 (gbb_can_be_ignored): New.
4586 (scop_remove_ignoreable_gbbs): New.
4587 (graphite_transformations): Cleanup and add
4588 scop_remove_ignoreable_gbbs.
4589 * lambda.h (lambda_vector_compare): New.
4590
45912008-07-09 Tobias Grosser <grosser@fim.uni-passau.de>
4592
4593 * graphite.c (print_graphite_bb): Correct printing of static schedule.
4594 (graphite_swap_loops): int -> unsigned
4595 (graphite_strip_mine_loop): int -> unsigned, Fix SCHEDULE
4596 (graphite_transformations): New.
4597 (graphite_transform_loops): Move to graphite_transformations.
4598 * graphite.h (gbb_nb_loops): Return unsigned.
4599
46002008-07-04 Tobias Grosser <grosser@fim.uni-passau.de>
4601
4602 * graphite.c (scan_tree_for_params): Fix insertion of parameters into
4603 the domain matrix. This makes scop-0.c work again.
4604
46052008-06-20 Richard Guenther <rguenther@suse.de>
4606
4607 * graphite.h: Adjust copyright to GPLv3.
4608 * graphite.c: Likewise.
4609 (stmt_simple_memref_for_scop_p): Split out from ...
4610 (stmt_simple_for_scop_p): ... here. Fix handling of calls
4611 and simplify.
4612 (get_bb_type): Optimize.
4613 (is_pred): Remove.
4614 (is_bb_addable): Fix memleak, replace is_pred call with
4615 single_pred.
4616 (build_scops): Use current_loops.
4617 (param_index): Fix memleak.
4618
46192008-06-20 Konrad Trifunovic <konrad.trifunovic@inria.fr>
4620
4621 * graphite.c: Fix formatting.
4622
46232008-06-19 Konrad Trifunovic <konrad.trifunovic@inria.fr>
4624
4625 * graphite.c (new_scop): Memory allocation for SCOP_{NEWIVS, OLDIVS}.
4626 (free_scop): Memory deallocation for SCOP_NEWIVS, SCOP_OLDIVS.
4627 (create_var_name, save_var_name): Newly defined functions.
4628 (initialize_cloog_names): Part of the code factored out to
4629 save_var_name.
4630 (clast_to_gcc_expression): Now handles the case of clast_red_sum
4631 in clast_reduction statement.
4632 (graphite_create_new_loop): Now takes a new parameter
4633 for outer_loop.
4634 (translate_clast): Now also takes the context_loop and bb_exit
4635 parameters. Rewritten the code so that it creates a gimple code
4636 inside the given context.
4637 (outermost_loop_layer, graphite_remove_iv, graphite_rename_ivs,
4638 remove_cond_expr, disconnect_cond_expr,
4639 disconnect_virtual_phi_nodes): Newly defined functions.
4640 * graphite.h (struct scop): added old_ivs vector.
4641 SCOP_OLDIVS: New macro.
4642
46432008-06-19 Sebastian Pop <sebastian.pop@amd.com>
4644
4645 * cfgloopmanip.c: Add missing function comments, fix formatting.
4646
46472008-06-18 Konrad Trifunovic <konrad.trifunovic@inria.fr>
4648
4649 * cfgloopmanip.c (update_dominators_in_loop): Defined.
4650 (create_empty_loop_on_edge): Defined.
4651 * tree-parloops.c (canonicalize_loop_ivs): Returns tree
4652 instead of void.
4653 * cfgloop.h (create_empty_loop_on_edge): Declared as extern.
4654 (update_dominators_in_loop): Declared as extern
4655 * tree-flow.h (canonicalize_loop_ivs): Declared as extern.
4656
46572008-06-16 Tobias Grosser <grosser@fim.uni-passau.de>
4658
4659 * graphite.c (print_graphite_bb): Allow changing number of loops
4660 in SCoP domain.
4661 (initialize_cloog_names): Allow changing number of loops.
4662 (build_cloog_prog): Simplify.
4663 (find_transform): Enable cloog option --strides.
4664 (graphite_swap_loops): New.
4665 (graphite_strip_mine_loop): New.
4666 (graphite_trans_swap_1and2): New.
4667 (graphite_trans_strip): New.
4668 (graphite_transform_loops): Add graphite_trans_strip.
4669 * graphite.h (scop_max_loop_depth): New.
4670
46712008-06-15 Tobias Grosser <grosser@fim.uni-passau.de>
4672
4673 * graphite.c (build_scop_iteration_domain): Remove forgotten
4674 line. (Fixes compile)
4675
46762008-06-15 Tobias Grosser <grosser@fim.uni-passau.de>
4677
4678 * graphite.c (print_graphite_bb): Add output of GBB_LOOPS.
4679 (build_graphite_bb): Add GBB_LOOPS and GBB_DOMAIN and reorder.
4680 (build_bb_loops): New.
4681 (graphite_transform_loops): Add build_bb_loops.
4682 (schedule_to_scattering): Use gbb_nb_loops to support changing loop
4683 numbers.
4684 * graphite.h (graphite_bb): Add loops.
4685 (gbb_nb_loops): New.
4686 (gbb_loop_at_index): New.
4687 (gbb_loop_index): New.
4688 (nb_params_in_scop): Renamed to scop_nb_params. Updated all functions
4689 using nb_params_in_scop.
4690
46912008-06-14 Tobias Grosser <grosser@fim.uni-passau.de>
4692
4693 * graphite.c (print_graphite_bb): Adapt to minimized schedule.
4694 (build_scop_canonical_schedules): Build minimized schedule.
4695 (schedule_to_scattering): Adapt to minimized schedule.
4696 * graphite.h (graphite_bb): Add/Update descriptions.
4697
46982008-06-14 Adrien Eliche <aeliche@isty.uvsq.fr>
4699 Tobias Grosser <grosser@fim.uni-passau.de>
4700
4701 * graphite.c (print_graphite_bb): Add condition printing.
4702 (dump_value): New.
4703 (dump_gbb_conditions): New.
4704 (build_scop_conditions_1): New.
4705 (build_scop_conditions): New.
4706 * graphite.h (graphite_bb): Add conditions.
4707
47082008-06-14 Tobias Grosser <grosser@fim.uni-passau.de>
4709
4710 * graphite.c (print_graphite_bb):
4711 (free_graphite_bb): New.
4712 (free_scop): Free bbs.
4713 (get_bb_type): Free doms.
4714 (build_scop_context): Free context matrix.
4715 (build_loop_iteration_domains): Remove unused code.
4716 (build_cloog_prog): Free scattering function and blocklist.
4717 (find_transform): Free options.
4718
47192008-06-13 Tobias Grosser <grosser@fim.uni-passau.de>
4720
4721 * graphite.c (loop_body_to_cloog_stmts): Rename to add_bb_domains.
4722 Remove unnecessery cloog data structures. Make a copy of the domain
4723 (setup_cloog_loop): Rename to build_loop_iteration_domains. Remove
4724 unnecessary cloog data structures. Fix memory leaks. Remove insert
4725 into SCOP_LOOP2CLOOG_LOOP as the inserted CloogLoops will never be
4726 used.
4727 (build_scop_iteration_domain): Remove unnecessary cloog
4728 data structures. Fix memory leaks.
4729 (graphite_transform_loops): Disable build_scop_dynamic_schedules as it
4730 uses SCOP_LOOP2CLOOG_LOOP, that is at the moment not working.
4731
47322008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
4733
4734 * graphite.c (find_scop_params): Remove initialize_cloog_names.
4735
47362008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
4737
4738 * graphite.c (end_scop): Style fix.
4739 (schedule_to_scattering): Style and comment fix.
4740
47412008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
4742 * graphite.c (print_graphite_bb): Fix definiton of
4743 schedule_to_scattering.
4744 (initialize_cloog_names): Change nb_scattdims to max loop
4745 depth in SCoP.
4746 (schedule_to_scattering): Take parameter for number of scattering
4747 dimensions.
4748 (build_cloog_prog): Only build as much scattering dimensions as
4749 necessary.
4750
47512008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
4752
4753 * graphite.c (end_scop): Disable bb splitting. Fixes SIGSEGV
4754 in polyhedron/aermod.f90.
4755
47562008-06-11 Tobias Grosser <grosser@fim.uni-passau.de>
4757 Dwarak Rajagopal <dwarak.rajagopal@amd.com>
4758 Harsha Jagasia <harsha.jagasia@amd.com>
4759
4760 * graphite.c (is_bb_addable): Fix segfault.
4761
47622008-06-10 Tobias Grosser <grosser@fim.uni-passau.de>
4763
4764 * graphite.c (is_bb_addable): Fix memory leak, handling of loops
4765 with multiple exits and conditional handling in edge cases.
4766 (is_loop_exit): Fix memory leak. (Forgotten in last commit)
4767
4768 * testsuite/gcc.dg/graphite/scop-14.c: New.
4769
47702008-06-06 Tobias Grosser <grosser@fim.uni-passau.de>
4771 Adrien Eliche <aeliche@isty.uvsq.fr>
4772
4773 * graphite.c (is_bb_addable): Add more comments and enhance
4774 readablity of the source code. Fix memory leak.
4775 (is_loop_exit): Fix memory leak.
4776
47772008-06-05 Tobias Grosser <grosser@fim.uni-passau.de>
4778
4779 * graphite.c (first_loop_in_scop): Deleted.
4780 (setup_cloog_loop): Only walk the loop chain for inner loops.
4781 (build_scop_iteration_domain): Execute setup_cloog_loop for
4782 all loops in the first layer.
4783
47842008-06-05 Tobias Grosser <grosser@fim.uni-passau.de>
4785
4786 * graphite.c (scan_tree_for_params): Change the way params are
4787 added to be indepenent of the number of loops.
4788 (setup_cloog_loop): Revert to short matrix format. Fix parameter
4789 handling.
4790 (build_cloog_prog): Revert to short matrix format.
4791
47922008-06-05 Sebastian Pop <sebastian.pop@amd.com>
4793 Dwarak Rajagopal <dwarak.rajagopal@amd.com>
4794
4795 * tree-loop-fusion.c (fuse_loops): Fix uninitialized variable
4796 warning.
4797
47982008-06-05 Sebastian Pop <sebastian.pop@amd.com>
4799
4800 * graphite.c (nb_data_refs_in_scop): New.
4801 (graphite_transform_loops): Print more stats: number of
4802 loops, basic blocks and data references per scop.
4803
48042008-06-04 Sebastian Pop <sebastian.pop@amd.com>
4805 Jan Sjodin <jan.sjodin@amd.com>
4806
4807 * graphite.c (loop_affine_expr, idx_record_params,
4808 find_scop_parameters, setup_cloog_loop): Use instantiate_scev
4809 instead of instantiate_parameters.
4810
48112008-06-04 Tobias Grosser <grosser@fim.uni-passau.de>
4812
4813 * graphite.c (schedule_to_scattering): Fix scattering dimensions,
4814 add support for parameters, add STATIC_SCHEDULE at the right places,
4815 cleanup.
4816
48172008-06-04 Tobias Grosser <grosser@fim.uni-passau.de>
4818
4819 * graphite.c (build_scop_loop_nests): Only add the loops, that
4820 are contained completely in the SCoP.
4821 (build_cloog_prog): Disable scattering, until schedule_to_scattering
4822 and the domains are fixed.
4823 (build_scop_canonical_schedules): Add support for bbs not contained
4824 in any SCoP.
4825
48262008-06-04 Tobias Grosser <grosser@fim.uni-passau.de>
4827
4828 * graphite.h (scop_contains_loop): Update comments to match
4829 the actual behavior.
4830 (scop_contains_loop): New.
4831 * graphite.c (schedule_to_scattering): Use scop_contains_loop.
4832
48332008-06-04 Sebastian Pop <sebastian.pop@amd.com>
4834
4835 * graphite.c (get_bb_type): On function body, i.e. loop_0,
4836 don't mark blocks as GBB_LOOP_SING_EXIT_HEADER, mark them
4837 as GBB_COND_HEADER.
4838
48392008-06-04 Sebastian Pop <sebastian.pop@amd.com>
4840 Tobias Grosser <grosser@fim.uni-passau.de>
4841
4842 * graphite.c (graphite_transform_loops): Early return when
4843 there are no loops in the function.
4844
48452008-05-31 Sebastian Pop <sebastian.pop@amd.com>
4846 Jan Sjodin <jan.sjodin@amd.com>
4847
4848 * graphite.c (scan_tree_for_params, setup_cloog_loop): Compute the
4849 offset of the last loop.
4850 (setup_cloog_loop): Copy the entire outer constraint matrix.
4851
48522008-05-31 Sebastian Pop <sebastian.pop@amd.com>
4853 Jan Sjodin <jan.sjodin@amd.com>
4854
4855 * graphite.c (stmt_in_scop_p, function_parameter_p,
4856 invariant_in_scop_p): Removed.
4857 (scan_tree_for_params): Can be used with no constraint
4858 matrix for gathering parameters.
4859 (idx_record_params): Don't use idx_record_param, instead use
4860 scan_tree_for_params.
4861 (find_scop_parameters): Same.
4862 (setup_cloog_loop, build_scop_iteration_domain, build_cloog_prog):
4863 Fix the size of loop domains.
4864 (schedule_to_scattering): Exit when the outer loop is not in scop.
4865 (find_transform): Enable build_cloog_prog.
4866
48672008-05-31 Sebastian Pop <sebastian.pop@amd.com>
4868 Jan Sjodin <jan.sjodin@amd.com>
4869
4870 * graphite.c (schedule_to_scattering): Make scattering domains
4871 uniformly of the same size, as required by CLooG 0.14.0 and before.
4872
48732008-05-31 Sebastian Pop <sebastian.pop@amd.com>
4874 Jan Sjodin <jan.sjodin@amd.com>
4875
4876 * graphite.c (schedule_to_scattering): Rewrite, correct the
4877 translation of the scheduling function to scattering.
4878 (build_cloog_prog): Call schedule_to_scattering only once.
4879 * graphite.h (scop_loop_index): Do not fail for loops not
4880 in the scop: return -1.
4881
48822008-05-30 Tobias Grosser <grosser@fim.uni-passau.de>
4883
4884 * graphite.c (build_graphite_bb): Initialize GBB_DOMAIN.
4885 (loop_body_to_cloog_stmts): Export GBB_DOMAIN.
4886 (setup_cloog_loop): Export GBB_DOMAIN.
4887 (build_cloog_prog): New. Create new CLOOG_PROG, which should be
4888 able to rebuild the original control flow.
4889 * graphite.h (graphite_bb): Add domain field and access macro.
4890 (GBB_DOMAIN): New.
4891
48922008-05-30 Sebastian Pop <sebastian.pop@amd.com>
4893
4894 * graphite.c (debug_gbb): New.
4895 (print_scop, build_graphite_bb): Use SCOP_BBS.
4896 (build_scop_bbs): Reimplemented.
4897 (dfs_bb_in_scop_p): Removed.
4898 (build_scop_loop_nests): Reorder loops inserted in
4899 SCOP_LOOP_NEST: outer loops should come first.
4900 (build_scop_canonical_schedules): Reinitialize at zero
4901 the components of the SCOP_STATIC_SCHEDULE for the loops
4902 that have already been parsed.
4903
4904 * graphite.h (debug_gbb): Declared.
4905
49062008-05-30 Sebastian Pop <sebastian.pop@amd.com>
4907 Jan Sjodin <jan.sjodin@amd.com>
4908
4909 * graphite.c (create_empty_loop): Renamed graphite_create_new_loop.
4910 (graphite_loop_to_gcc_loop): Removed.
4911 (remove_all_edges): New.
4912 (graphite_stmt_to_gcc_stmt): Renamed translate_clast.
4913 (gloog): Remove useless code.
4914
49152008-05-29 Tobias Grosser <grosser@fim.uni-passau.de>
4916
4917 * graphite.c (get_bb_type): Reworked. We distinguish between
4918 loops with one or multiple exits.
4919 (is_loop_exit): New.
4920 (is_pred): New.
4921 (is_bb_addable): Rework condition handling, now support for case
4922 case statements and loops with multiple exits.
4923
4924 * testsuite/gcc.dg/graphite/scop-11.c: New.
4925 * testsuite/gcc.dg/graphite/scop-12.c: New.
4926 * testsuite/gcc.dg/graphite/scop-13.c: New.
4927
49282008-05-29 Tobias Grosser <grosser@fim.uni-passau.de>
4929
4930 * graphite.c (dot_all_scops_1): Fix some colors. Reuse colors, if
4931 we have too many colors.
4932
49332008-05-22 Sandeep Maram <smaram_b04@iiita.ac.in>
4934
4935 * doc/invoke.texi (-ftree-loop-fusion): Document.
4936 * tree-pass.h (pass_loop_fusion): Declared.
4937 * tree-loop-fusion.c: New.
4938 * timevar.def (TV_TREE_LOOP_FUSION): Declared.
4939 * tree-data-ref.c (find_data_references_in_loop): Make extern.
4940 * tree-data-ref.h (find_data_references_in_loop): Declared.
4941 * common.opt (ftree-loop-fusion): Declared.
4942 * Makefile.in (tree-loop-fusion.o): Added rule and to OBJS-common.
4943
49442008-05-21 Sebastian Pop <sebastian.pop@amd.com>
4945
4946 * graphite.c (build_access_matrix): Fix typo from the merge.
4947
49482008-05-20 Sebastian Pop <sebastian.pop@amd.com>
4949
4950 * Merge from mainline (130800:135673).
4951
49522008-05-07 Sebastian Pop <sebastian.pop@amd.com>
4953
4954 * graphite.c (end_scop): The exit of the scop is not part of the scop.
4955 Update dominators after splitting.
4956
49572008-05-07 Sebastian Pop <sebastian.pop@amd.com>
4958
4959 * graphite.c (is_bb_addable): Return the harmful statement.
4960 Factor up some code.
4961 (end_scop): New. Splits end of scope bbs on a harmful statement.
4962 (build_scops_1): Call end_scop.
4963
49642008-05-07 Sebastian Pop <sebastian.pop@amd.com>
4965
4966 * graphite.c: (succs_at_same_depth, end_scop, all_preds_visited_p,
4967 all_succs_visited_p, start_new_scop_for_each_succ, start_new_scop,
4968 add_dominators_to_open_scops, stop_last_open_scop, scop_end_loop,
4969 build_scops_1): Removed.
4970 (build_scops_2): Renamed build_scops_1.
4971
49722008-05-06 Sebastian Pop <sebastian.pop@amd.com>
4973
4974 * graphite.c: Fix formatting.
4975
49762008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
4977
4978 * graphite.c (get_bb_type): New.
4979 (move_scops): New.
4980 (build_scops_2): New.
4981 (is_bb_addable): New.
4982 (build_scops): Switch the scop detection.
4983 (build_scop_bbs): Add entry bb to scop.
4984 * graphite.h (struct scop): Update comment.
4985
49862008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
4987
4988 * graphite.c (dot_all_scops_1): Fix some incorrect colors and add
4989 more colors.
4990
49912008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
4992
4993 * testsuite/gcc.dg/graphite/scop-1.c: Update.
4994 * testsuite/gcc.dg/graphite/scop-2.c: Update.
4995 * testsuite/gcc.dg/graphite/scop-4.c: Update.
4996 * testsuite/gcc.dg/graphite/scop-5.c: Add.
4997 * testsuite/gcc.dg/graphite/scop-6.c: Add.
4998
49992008-05-06 Sebastian Pop <sebastian.pop@amd.com>
5000
5001 * testsuite/gcc.dg/graphite/scop-0.c: Add.
5002 * testsuite/gcc.dg/graphite/scop-7.c: Add.
5003 * testsuite/gcc.dg/graphite/scop-8.c: Add.
5004 * testsuite/gcc.dg/graphite/scop-9.c: Add.
5005 * testsuite/gcc.dg/graphite/scop-10.c: Add.
5006
50072008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
5008
5009 * graphite.c (scop_affine_expr): Renamed to loop_affine_expr.
5010 Check affine expressions depending on the outermost loop
5011 instead of a scop.
5012 (stmt_simple_for_scop_p): Same.
5013 (harmfule_stmt_in_scop): Same.
5014
50152008-04-28 Tobias Grosser <grosser@fim.uni-passau.de>
5016
5017 * graphite.c (dot_all_scops): Remove incorrect difficult bb coloring,
5018 mark entry and exit, that are not part of the SCoP and update HTML
5019 formatting.
5020
50212008-04-25 Sebastian Pop <sebastian.pop@amd.com>
5022
5023 * graphite.c (basic_block_simple_for_scop_p): Renamed
5024 harmful_stmt_in_bb.
5025 (save_scop, preds_at_same_depth, test_for_scop_bound): Removed.
5026 (add_dominators_to_open_scops, build_scops_1): Reimplemented.
5027 (all_preds_visited_p, all_succs_visited_p,
5028 start_new_scop_for_each_succ, start_new_scop, stop_last_open_scop,
5029 scop_end_loop): New.
5030 (build_scops): Do not use dfs_enumerate_from.
5031
5032 * testsuite/gcc.dg/graphite/scop-{1,2,4}.c: Updated.
5033
50342008-04-23 Sebastian Pop <sebastian.pop@amd.com>
5035
5036 * graphite.c: Add comments to functions that are missing a
5037 description.
5038 (graphite_create_iv): Removed. Merged in graphite_loop_to_gcc_loop.
5039
50402008-04-23 Sebastian Pop <sebastian.pop@amd.com>
5041
5042 * graphite.c (nb_params_in_scop): Moved...
5043 (graphite_bb_from_bb, loop_body_to_cloog_stmts): New.
5044 (setup_cloog_loop): Call loop_body_to_cloog_stmts.
5045 (clast_to_gcc_expression): Reduce column size to less than 80.
5046 (graphite_create_iv): Return the new name of the IV.
5047 (find_transform): Set options->esp and options->cpp.
5048 (gloog): Comment out the invalidation of the old loop code.
5049 (initialize_dependence_polyhedron): Replace scop_nb_params with
5050 nb_params_in_scop.
5051
5052 * graphite.h (nb_params_in_scop): ... here.
5053 (scop_nb_params): Removed.
5054 (loop_domain_dim): Return something even when the loop was not
5055 found in the hash table: avoid ICEing on all the graphite.exp
5056 testcases.
5057
50582008-04-14 Konrad Trifunovic <konrad.trifunovic@inria.fr>
5059
5060 * tree-chrec.c (for_each_scev_op): SCEV can have 3 operands.
5061
5062 * graphite.c (build_scop_dynamic_schedules): Schedule is built
5063 according to nesting level.
5064 (find_scop_parameters): Call instantiate_parameters.
5065 (scan_tree_for_params): Extend it to handle general affine bounds.
5066 Inner loop bound can depend on outer loop induction variable.
5067 (setup_cloog_loop): tmp variable is allocated on stack. Call
5068 instantiate_parameters with respect to outermost_loop_in_scop.
5069 (loop_domain_dim, ref_nb_loops, loop_iteration_vector_dim): moved to
5070 graphite.h.
5071 (create_empty_loop): Function loopify should be given edge
5072 probability, instead of edge frequency. Dominance relation from
5073 switch_bb to loop_header.
5074 (clast_to_gcc_expression): Added handling of clast_reduction node.
5075 (gloog): New functionality for removing old loop.
5076 (test_dependence): Factored out from build_rdg_all_levels.
5077 (build_rdg_all_levels): Dependence testing factored out to
5078 test_dependence function.
5079
5080 * graphite.h (struct graphite_bb): Extended with dynamic_schedule.
5081 (loop_domain_dim, ref_nb_loops, loop_iteration_vector_dim): Moved
5082 from graphite.c
5083
50842008-04-07 Sebastian Pop <sebastian.pop@amd.com>
5085
5086 * graphite.c (free_scop, param_index, initialize_cloog_names,
5087 nb_params_in_scop): Use name_tree map instead of just a tree
5088 for keeping track of the variable name associated to that tree.
5089 (create_empty_loop, gmp_cst_to_tree, clast_name_to_gcc,
5090 clast_to_gcc_expression, graphite_create_iv,
5091 graphite_loop_to_gcc_loop, graphite_cond_to_gcc_cond,
5092 graphite_stmt_to_gcc_stmt): New.
5093 (gloog): Call these.
5094 * graphite.h (struct name_tree): New.
5095 (struct scop): Use name_tree instead of tree for params.
5096 Store a vector of name_tree for new_ivs.
5097 (SCOP_NEWIVS): New.
5098 (scop_nb_params): Use name_tree instead of tree.
5099
51002008-04-05 Alexander Lamaison <awl03@doc.ic.ac.uk>
5101 Sebastian Pop <sebastian.pop@amd.com>
5102
5103 * tree-bounds.c: New.
5104 * tree-bounds.h: New.
5105 * tree-pass.h: Declare pass_bounds_early and pass_bounds_late.
5106 * passes.c: Schedule pass_bounds_early, pass_bounds_late.
5107 * builtins.c (expand_builtin_alloca): Add flag_bounds as for
5108 flag_mudflap.
5109 * gcc.c: Same.
5110 * toplev.c: Same.
5111 * c-cppbuiltin.c: Same.
5112 * c-pragma.c: Same.
5113 * common.opt: Same.
5114 * varasm.c: Same.
5115 * tree-outof-ssa.c: Same.
5116 * c-common.c: Same.
5117 * Makefile.in: Same.
5118
51192008-03-15 Antoniu Pop <antoniu.pop@gmail.com>
5120 Sebastian Pop <sebastian.pop@amd.com>
5121
5122 * tree-loop-distribution.c (remaining_stmts,
5123 upstream_mem_writes): Removed static variables.
5124 (copy_loop_before, create_bb_after_loop,
5125 mark_nodes_having_upstream_mem_writes, free_rdg_components,
5126 rdg_build_components, rdg_build_partitions,
5127 dump_rdg_partitions): Extern.
5128 (generate_loops_for_partition, generate_code_for_partition): Do not
5129 return a bool.
5130 (already_processed_vertex_p, predecessor_has_mem_write,
5131 mark_nodes_having_upstream_mem_writes, has_upstream_mem_writes,
5132 rdg_flag_all_uses, rdg_flag_uses, rdg_flag_vertex_and_dependent,
5133 rdg_flag_loop_exits, rdg_flag_similar_memory_accesses,
5134 build_rdg_partition_for_component, rdg_build_partitions, ldist_gen):
5135 Pass remaining_stmts and upstream_mem_writes as parameters.
5136 (rdg_component): Moved...
5137 (build_rdg_partition_for_component): Do not aggregate components when
5138 flag_streamize_loops is set.
5139 (gen_sequential_loops): New.
5140 (ldist_gen): Call gen_sequential_loops.
5141
5142 * tree-pass.h (pass_loop_streamization): Declared.
5143
5144 * omp-low.c (expand_omp_sections): Call add_bb_to_loop on created
5145 basic blocks when loops structures exist.
5146
5147 * builtin-types.def (BT_FN_VOID_PTR_PTR_INT): New.
5148
5149 * tree-ssa-loop-ivopts.c (expr_invariant_in_region_p): New.
5150
5151 * tree-parloops.c (take_address_of, eliminate_local_variables_1,
5152 eliminate_local_variables_stmt, eliminate_local_variables,
5153 separate_decls_in_loop_name, separate_decls_in_loop_stmt,
5154 separate_decls_in_loop, gen_parallel_loop): Make them work on a region
5155 of code delimited by two edges in the CFG.
5156 (separate_decls_in_loop_name): Renamed separate_decls_in_region_name.
5157 (separate_decls_in_loop_stmt): Renamed separate_decls_in_region_stmt.
5158 (separate_decls_in_loop): Renamed separate_decls_in_region. Isolate
5159 the case of parallelisation of reductions.
5160 (create_loop_fn): Extern.
5161 (create_omp_parallel_region): New.
5162
5163 * tree-data-ref.c (dump_data_dependence_relation): Don't call
5164 dump_data_reference for printing dra and drb.
5165 (create_rdg_edge_for_ddr, create_rdg_edges_for_scalar): Initialise
5166 RDGE_RELATION.
5167 (build_rdg): Don't call free_dependence_relations for the moment, as
5168 we attach dependence relations on each edge of the RDG.
5169 To be fixed later.
5170
5171 * tree-data-ref.h (rdg_component): ...here.
5172 (struct rdg_edge): New field ddr_p relation.
5173 (RDGE_RELATION): New.
5174 (create_bb_after_loop, copy_loop_before,
5175 mark_nodes_having_upstream_mem_writes, rdg_build_components,
5176 rdg_build_partitions, dump_rdg_partitions,
5177 free_rdg_components): Declared.
5178
5179 * omp-builtins.def (BUILT_IN_GOMP_STREAM_ALIGN_PUSH,
5180 BUILT_IN_GOMP_STREAM_ALIGN_POP): New.
5181
5182 * tree-loop-streamization.c: New.
5183
5184 * tree-flow.h (gather_blocks_in_sese_region, create_loop_fn,
5185 create_omp_parallel_region, expr_invariant_in_region_p): Declared.
5186
5187 * Makefile.in (tree-loop-streamization.o): Added to OBJS-common.
5188
5189 * tree-cfg.c (gather_blocks_in_sese_region): Extern.
5190
5191 * passes.c: Schedule pass_loop_streamization.
5192
51932008-03-08 Tobias Grosser <grosser@fmi.uni-passau.de>
5194
5195 * graphite.c (dot_all_scops_1): Fix formatting for difficult bbs and
5196 update comment.
5197
51982008-03-07 Tobias Grosser <grosser@fim.uni-passau.de>
5199
5200 * graphite.c (dot_all_scops): Update formatting.
5201 Bbs can now be part of more than one SCoP.
5202
52032008-03-04 Sebastian Pop <sebastian.pop@amd.com>
5204
5205 * graphite.c (new_loop_to_cloog_loop_str, setup_cloog_loop): Fix
5206 malloc problems.
5207 (loop_domain_dim): Check for unregistered toplev SCOP loop.
5208 * graphite.h (loop_to_cloog_loop): New.
5209
52102008-03-04 Konrad Trifunovic <konrad.trifunovic@inria.fr>
5211
5212 * graphite.c (loop_domain_dim, ref_nb_loops,
5213 loop_iteration_vector_dim): New.
5214 (build_access_matrix_with_af, build_access_matrix,
5215 initialize_dependence_polyhedron): Fixed for new matrix layout.
5216 No longer assume that all iteration domains are of the same
5217 dimensionality.
5218
52192008-03-02 Sebastian Pop <sebastian.pop@amd.com>
5220
5221 * tree-scalar-evolution.c (instantiate_parameters_1): An SSA_NAME
5222 defined in a loop at depth 0 is invariant.
5223 * tree-chrec.c (evolution_function_is_invariant_rec_p): Ditto.
5224 * tree-ssa-loop-ivopts.c (expr_invariant_in_loop_p): Should never
5225 be called at loop depth 0.
5226
5227 * graphite.c (basic_block_simple_for_scop_p): Take the scop as
5228 a parameter.
5229 (dot_all_scops_1): Update use of basic_block_simple_for_scop_p.
5230 (down_open_scop): Removed.
5231 (loop_in_scop_p): Redefined.
5232 (scop_affine_expr): New argument: scop.
5233 (stmt_simple_for_scop_p): New argument: scop. RETURN_EXPR is not
5234 a harmful statement ending a scop.
5235 (basic_block_simple_for_scop_p): New argument: scop.
5236 (get_loop_start): Removed.
5237 (new_scop): Initialize SCOP_LOOPS.
5238 (free_scop): Free SCOP_LOOPS.
5239 (succs_at_same_depth, preds_at_same_depth): New.
5240 (end_scop): Test the validity of a scop.
5241 (add_dominators_to_open_scops): New.
5242 (test_for_scop_bound): Call add_dominators_to_open_scops.
5243 Add cases for opening and closing multiple scops.
5244 (build_scops, build_scop_bbs): Iterate over basic blocks in
5245 depth first order.
5246 (build_graphite_bb): Pass scop directly.
5247 (dfs_bb_in_scop_p): New.
5248 (scop_record_loop): Use SCOP_LOOPS for not recording the same loop
5249 several times.
5250 (nb_loops_around_gb): Use loop_in_scop_p.
5251 (schedule_to_scattering): Disabled for the moment the code computing
5252 the "textual order for outer loop".
5253
5254 * graphite.h (struct scop): New field loops.
5255 (SCOP_LOOPS): New.
5256 (scop_loop_index): Test that the given loop belongs to SCOP_LOOPS.
5257
5258 * testsuite/gcc.dg/graphite/scop-{1,...,7}.c: Updated.
5259
52602008-02-27 Antoniu Pop <antoniu.pop@gmail.com>
5261 Sebastian Pop <sebastian.pop@amd.com>
5262
5263 * builtin-types.def (BT_FN_PTR_SIZE_UINT, BT_FN_BOOL_PTR): New.
5264 * common.opt (fstreamize-loops): New.
5265 * omp-builtins.def (BUILT_IN_GOMP_STREAM_CREATE,
5266 BUILT_IN_GOMP_STREAM_PUSH, BUILT_IN_GOMP_STREAM_HEAD,
5267 BUILT_IN_GOMP_STREAM_POP, BUILT_IN_GOMP_STREAM_EOS_P,
5268 BUILT_IN_GOMP_STREAM_SET_EOS, BUILT_IN_GOMP_STREAM_DESTROY): New.
5269
52702008-02-22 Konrad Trifunovic <konrad.trifunovic@inria.fr>
5271
5272 * tree-data-ref.c (build_empty_rdg): New.
5273 (build_rdg): Use it.
5274 * tree-data-ref.h (build_empty_rdg): Declared.
5275 * graphite.c (free_scop): Free SCOP_LOOP2CLOOG_LOOP.
5276 (find_vertex_for_stmt): Removed.
5277 (build_rdg_all_levels): Use build_empty_rdg and rdg_vertex_for_stmt.
5278
52792008-02-21 Sebastian Pop <sebastian.pop@amd.com>
5280
5281 * tree-loop-distribution.c (generate_builtin): After cancelling the
5282 loop tree, also delete basic blocks.
5283 (rdg_flag_uses): Stop recursion when a vertex has already been
5284 processed.
5285
52862008-02-15 Konrad Trifunovic <konrad.trifunovic@inria.fr>
5287
5288 * graphite.c (build_scop_alpha): Removed.
5289 (graphite_transform_loops): Add a dummy call to build_all_rdg_levels
5290 and dump_dependence_graph to avoid compiler warnings.
5291
52922008-02-14 Konrad Trifunovic <konrad.trifunovic@inria.fr>
5293
5294 * tree-data-ref.c (dr_may_alias_p, create_rdg_vertices): Extern.
5295 * tree-data-ref.h (dr_may_alias_p, create_rdg_vertices): Declared.
5296 * graphite.c (new_loop_to_cloog_loop_str, hash_loop_to_cloog_loop,
5297 eq_loop_to_cloog_loop, del_loop_to_cloog_loop): New.
5298 (new_scop, setup_cloog_loop): Initialize SCOP_LOOP2CLOOG_LOOP.
5299 (initialize_dependence_polyhedron, find_vertex_for_stmt,
5300 initialize_data_dependence_polyhedron, is_empty_polyhedron,
5301 statement_precedes_p, build_rdg_all_levels, build_scop_alpha,
5302 dump_dependence_graph): New.
5303 * graphite.h (struct graphite_bb): New field compressed_alpha_matrix.
5304 (GBB_ALPHA): New.
5305 (struct scop): New field loop2cloog_loop.
5306 (SCOP_LOOP2CLOOG_LOOP, struct data_dependence_polyhedron,
5307 RDGE_DDP, ddp_p, struct loop_to_cloog_loop_str): New.
5308
53092008-02-10 Konrad Trifunovic <konrad.trifunovic@inria.fr>
5310
5311 * graphite.c (build_graphite_bb): Fix initialization
5312 of the graphite basic block.
5313
53142008-02-05 Sebastian Pop <sebastian.pop@amd.com>
5315
5316 * graphite.c (scan_tree_for_params): Rewrite for the new layout of
5317 loop domain matrix. Pass in the number of loops contained in the
5318 constraint matrix.
5319 (nb_loops_around_gb): Moved before setup_cloog_loop that uses it.
5320 (setup_cloog_loop): Rewrite for the new layout of loop domain matrix:
5321 loops that are not surrounding the current loop are not represented
5322 in the domain constraint matrix.
5323 (build_scop_iteration_domain): Initial domain constraint matrix
5324 contains only the eq/ineq, cst, and scop parameters columns.
5325
53262008-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
5327
5328 * graphite.c (schedule_to_scattering, nb_loops_around_gb): New.
5329 (print_graphite_bb): Print scattering.
5330
53312008-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
5332
5333 * graphite.c (initialize_cloog_names): Initialize names of
5334 scattering variables.
5335
53362009-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
5337
5338 * graphite.c (dot_all_scops_1): Disable debug output while
5339 printing graph.
5340
53412008-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
5342
5343 * graphite.c (find_transform): Change cloog output language to C.
5344
53452008-01-27 Sebastian Pop <sebastian.pop@amd.com>
5346
5347 * tree-loop-distribution.c (generate_memset_zero,
5348 generate_builtin, generate_code_for_partition,
5349 rdg_flag_all_uses): New.
5350 (rdg_flag_uses): Gather in the same partition the statements defining
5351 the VUSES of the current statement.
5352 (rdg_flag_similar_stores): Renamed rdg_flag_similar_memory_accesses.
5353 Gather in the same partition not only the stores to the same memory
5354 access, but also the reads.
5355 (ldist_generate_loops): Renamed ldist_gen.
5356
53572008-01-24 Sebastian Pop <sebastian.pop@amd.com>
5358 Tobias Grosser <grosser@fmi.uni-passau.de>
5359
5360 * graphite.c (setup_cloog_loop): Chain all cloog loops with the
5361 next pointer, don't use the inner pointer.
5362
53632008-01-20 Tobias Grosser <grosser@fmi.uni-passau.de>
5364
5365 * graphite.c (dot_all_scops, dot_all_scops_1): New.
5366 (find_transform): Call dot_all_1.
5367 * graphite.h (dot_all_scops): Declared.
5368
53692007-12-14 Sebastian Pop <sebastian.pop@amd.com>
5370
5371 * tree-loop-distribution.c: Fix apsi.f ICE.
5372 (create_bb_after_loop): New.
5373 (generate_loops_for_partition): Use it.
5374 * testsuite/gfortran.dg/ldist-1.f90: New.
5375
5376 * tree-data-ref.c (dot_rdg): Use /tmp/rdg.dot for dotty format.
5377 * graphite.c (dot_scop): Use /tmp/scop.dot for dotty format.
5378
53792007-12-13 Tobias Grosser <grosser@fmi.uni-passau.de>
5380
5381 * graphite.c (find_transform): Dump cloog program sent to cloog.
5382
53832007-12-13 Tobias Grosser <grosser@fmi.uni-passau.de>
5384
5385 * graphite.c (initialize_cloog_names): Initialize cloog
5386 iterator names.
5387
53882007-12-13 Tobias Grosser <grosser@fmi.uni-passau.de>
5389
5390 * graphite.c (build_scop_context): Fix typo, for the matrix
5391 format: insert '0 >= 0' instead of '-1 >= 0'.
5392
53932007-12-13 Sebastian Pop <sebastian.pop@amd.com>
5394
5395 * Fix merge problems.
5396
53972007-12-13 Sebastian Pop <sebastian.pop@amd.com>
5398
5399 * graphite.c (setup_cloog_loop): Fix typo.
5400
54012007-12-12 Sebastian Pop <sebastian.pop@amd.com>
5402
5403 * doc/invoke.texi (-ftree-loop-distribution): Documented.
5404 * tree-loop-distribution.c: Reimplemented.
5405 * tree-pass.h (pass_loop_distribution): New.
5406 * tree-scalar-evolution.c (number_of_iterations_for_all_loops): Use
5407 print_loops.
5408 * graphds.h (struct graph): New field indexes.
5409 * timevar.def (TV_TREE_LOOP_DISTRIBUTION): New.
5410
5411 * tree-vect-analyze.c: Remove declaration of static functions when not
5412 needed.
5413 * tree-vectorizer.c: Same.
5414 (rename_variables_in_loop): Now extern.
5415 (slpeel_tree_duplicate_loop_to_edge_cfg): Renamed
5416 tree_duplicate_loop_to_edge_cfg. Reset PENDING_STMT for edges after
5417 calling redirect_edge_and_branch_force.
5418
5419 * tree-vectorizer.h (tree_duplicate_loop_on_edge): Declared.
5420
5421 * tree-data-ref.c: Don't include tree-chrec.h.
5422 (debug_data_dependence_relations): New.
5423 (dump_data_dependence_relation): Call dump_data_reference on data refs
5424 in the relation.
5425 (same_access_functions): Moved...
5426 (find_vertex_for_stmt): Renamed rdg_vertex_for_stmt.
5427 (dump_rdg_vertex, debug_rdg_vertex, dump_rdg_component,
5428 debug_rdg_component, dump_rdg, debug_rdg, dot_rdg_1, dot_rdg,
5429 struct rdg_vertex_info, ): New.
5430 (create_rdg_edge_for_ddr): Compute the dependence level before looking
5431 at DDR_REVERSED_P.
5432 (create_rdg_vertices): Initialize the htab of graph->indexes.
5433 Initialize RDG_MEM_WRITE_STMT and RDG_MEM_READS_STMT.
5434 (stmts_from_loop): Don't save LABEL_EXPR.
5435 (hash_stmt_vertex_info, eq_stmt_vertex_info,
5436 hash_stmt_vertex_del): New.
5437 (build_rdg): Initialize rdg->indexes.
5438 (free_rdg, stores_from_loop, ref_base_address,
5439 rdg_defs_used_in_other_loops_p, have_similar_memory_accesses,
5440 have_similar_memory_accesses_1, ref_base_address_1,
5441 remove_similar_memory_refs): New.
5442
5443 * tree-data-ref.h: Include tree-chrec.h.
5444 (debug_data_dependence_relations): Declared.
5445 (same_access_functions): ...here. Now static inline.
5446 (ddr_is_anti_dependent, ddrs_have_anti_deps,
5447 ddr_dependence_level): New.
5448 (struct rdg_vertex): New fields has_mem_write, has_mem_reads.
5449 (RDGV_HAS_MEM_WRITE, RDGV_HAS_MEM_READS, RDG_STMT, RDG_MEM_WRITE_STMT,
5450 RDG_MEM_READS_STMT): New.
5451 (dump_rdg_vertex, debug_rdg_vertex, dump_rdg_component,
5452 debug_rdg_component, dump_rdg, debug_rdg, dot_rdg,
5453 rdg_vertex_for_stmt): Declared.
5454 (struct rdg_edge): New field level.
5455 (RDGE_LEVEL, free_rdg): New.
5456 (stores_from_loop, remove_similar_memory_refs,
5457 rdg_defs_used_in_other_loops_p,
5458 have_similar_memory_accesses): Declared.
5459 (rdg_has_similar_memory_accesses): New.
5460
5461 * lambda.h (dependence_level): New.
5462 * common.opt (ftree-loop-distribution): New.
5463 * tree-flow.h (debug_loop_ir): Renamed debug_loops.
5464 (print_loop_ir): Renamed print_loops.
5465 (debug_loop, debug_loop_num, print_loops_bb, mark_virtual_ops_in_bb,
5466 tree_duplicate_loop_to_edge_cfg, rename_variables_in_loop): Declared.
5467 * Makefile.in (TREE_DATA_REF_H): Depends on tree-chrec.h.
5468 (tree-loop-distribution.o): Added.
5469 * tree-cfg.c (mark_virtual_ops_in_region): Use mark_virtual_ops_in_bb.
5470 (mark_virtual_ops_in_bb): New.
5471 (print_loops_bb, debug_loop_num, debug_loop): New.
5472 * passes.c: Scheduled pass_loop_distribution.
5473
54742007-12-12 Konrad Trifunovic <konrad.trifunovic@inria.fr>
5475
5476 * graphite.c (scan_tree_for_params): Correct the number of columns
5477 for polylib format.
5478 (nb_flat_iterator): New.
5479 (setup_cloog_loop): Initialize to 1 the first column for inequalities.
5480 (build_scop_iteration_domain): Correct the number of columns for
5481 polylib format.
5482
54832007-12-12 Sebastian Pop <sebastian.pop@amd.com>
5484
5485 * Merge from mainline (129697:130800).
5486
54872007-10-30 Sebastian Pop <sebastian.pop@amd.com>
5488
5489 * graphite.c (build_graphite_bb): SCoP's basic blocks are post
5490 dominated by SCoP's exit.
5491 (graphite_transform_loops): Compute post dominators.
5492
54932007-10-28 Sebastian Pop <sebastian.pop@amd.com>
5494
5495 * Merge from mainline (127169:129697).
5496
54972007-10-28 Sebastian Pop <sebastian.pop@amd.com>
5498
5499 * graphite.c (affine_expr): Renamed scop_affine_expr. Use an extra
5500 parameter for the basic block that contains the expression. Use
5501 outermost_loop_in_scop for evolution_function_is_affine_multivariate_p.
5502 (stmt_simple_for_scop_p): Pass to scop_affine_expr the basic block of
5503 the expression.
5504 * graphite.h (gbb_loop): New.
5505 (GBB_LOOP): Removed.
5506
55072007-08-03 Sebastian Pop <sebpop@gmail.com>
5508
5509 * Makefile.in: Fix merge problem.
5510
55112007-08-03 Sebastian Pop <sebpop@gmail.com>
5512
5513 * Merge from mainline (125309:127169).
5514 * tree-loop-distribution.c: Disabled.
5515
55162007-06-05 Sebastian Pop <sebpop@gmail.com>
5517
5518 * Merge from mainline (r123693:125309).
5519
55202007-05-30 Sebastian Pop <sebpop@gmail.com>
5521
5522 * tree-loop-distribution.c (correct_modify_expr_p): Renamed
5523 correct_modify_p
5524 (correct_modify_p, check_statements, number_of_lvalue_uses,
5525 number_of_scalar_dependences, create_edges): Use GIMPLE_MODIFY_STMT
5526 instead of MODIFY_EXPR.
5527 (update_edge_with_ddv): Don't pass index_of_edge. Initialize
5528 and push new edges.
5529
55302007-05-24 Sebastian Pop <sebpop@gmail.com>
5531
5532 * tree-loop-distribution.c (struct rdg): Replace arrays by
5533 VECs for edges and vertices.
5534 (RDG_NBV, RDG_NBE, RDG_VERTEX, RDG_EDGE): Removed.
5535 (RDGV_NB_PARTITIONS): New.
5536 (PRDG_NBV, PRDG_NBE): Removed.
5537 (build_scc_graph, correct_partitions_p, mark_partitions, build_prdg,
5538 dump_rdg, find_vertex_with_stmt, create_vertices, free_rdg,
5539 number_of_scalar_dependences, create_edges, build_rdg): Use VECs.
5540
55412007-05-17 Georges-Andre Silber <silber@cri.ensmp.fr>
5542 Sebastian Pop <sebpop@gmail.com>
5543
5544 * doc/invoke.texi (-ftree-loop-distribution): Document.
5545 * tree-loop-distribution.c: New file.
5546 * tree-pass.h (pass_loop_distribution): Declared.
5547 * timevar.def (TV_TREE_LOOP_DISTRIBUTION): New.
5548 * tree-data-ref.c (initialize_data_dependence_relation): Initialize
5549 and set reversed_p.
5550 * tree-data-ref.h (data_dependence_relation): Add reversed_p.
5551 (DDR_REVERSED_P): New.
5552 * common.opt (-ftree-loop-distribution): New.
5553 * tree-flow.h (distribute_loops): Declared.
5554 * Makefile.in (OBJS-common): Depend on tree-loop-distribution.o.
5555 * passes.c (init_optimization_passes): Schedule loop distribution.
5556
55572007-05-12 Sebastian Pop <sebastian.pop@inria.fr>
5558
5559 * graphite.c (print_graphite_bb): Don't call dump_data_references.
5560 (print_scop): Don't print when scop is NULL.
5561 (build_scop_context, find_transform): Don't output to stderr.
5562
55632007-05-09 Sebastian Pop <sebastian.pop@inria.fr>
5564
5565 * tree-data-ref.c: Don't include graphite.h.
5566 Comment out the code for printing data reference's scop.
5567 (build_access_matrix_with_af): Moved...
5568 * tree-data-ref.h (build_access_matrix_with_af): Removed declaration.
5569 * graphite.c (build_access_matrix_with_af): ... here. Now static.
5570 (print_graphite_bb): Print basic block's schedule.
5571 (print_scop): Don't print the schedule, call cloog's pretty printer.
5572 (bb_in_scop_p): A basic block is in a scop only if it is both
5573 dominated and postdominated by the scop's entry and exit basic blocks.
5574 (function_parameter_p): New.
5575 (invariant_in_scop_p): Use function_parameter_p.
5576 (new_scop, save_scop): New.
5577 (end_scop, test_for_scop_bound, build_scops): Use new_scop, and
5578 save_scop.
5579 (scan_tree_for_params): Directly build the constraint as CloogMatrix.
5580 (loop_in_scop_p): New.
5581 (scop_record_loop): Use loop_in_scop_p.
5582 (build_scop_domain): Renamed build_scop_iteration_domain.
5583 (setup_cloog_loop, initialize_cloog_names, find_scop_parameters,
5584 nb_params_in_scop, build_scop_context, first_loop_in_scop,
5585 setup_cloog_loop, dot_scop_1, dot_scop): New.
5586 * graphite.h (GBB_LOOP, SCOP_PROG, dot_scop): New.
5587 (struct scop): Add a pointer to cloog's representation of a program.
5588
55892007-04-14 Sebastian Pop <sebastian.pop@inria.fr>
5590
5591 * doc/invoke.texi (-ftree-check-verbose): Renamed
5592 -ftree-checks-verbose.
5593 * common.opt (flag_tree_check_verbose): Renamed
5594 flag_tree_checks_verbose.
5595 * tree-check.c (tree_check_warning): Use flag_tree_checks_verbose.
5596
55972007-04-14 Sebastian Pop <sebastian.pop@inria.fr>
5598
5599 * configure: Regenerated.
5600 * config.in: Regenerated.
5601 * tree-ssa-loop.c (graphite_transforms): Execute
5602 graphite_transform_loops only when HAVE_cloog.
5603 * configure.ac (HAVE_polylib, HAVE_cloog, GRAPHITE): Defined.
5604 * graphite.c: Include polylibgmp.h and cloog.h.
5605 (graphite_transform_loops): Removed loops parameter.
5606 * tree-flow.h (graphite_transform_loops): Update declaration.
5607 * Makefile.in (POLYLIBLIBS, POLYLIBINC, CLOOGLIBS, CLOOGINC): New.
5608 (LIBS): Depend on CLOOGLIBS and on POLYLIBLIBS.
5609 (INCLUDES): Depend on POLYLIBINC and on CLOOGINC.
5610 (OBJS-common): Remove dependence on graphite.o.
5611 (BACKEND): Depend on @GRAPHITE@.
5612
56132007-04-13 Sebastian Pop <sebastian.pop@inria.fr>
5614
5615 * doc/invoke.texi (-ftree-check-verbose): Documented.
5616 * testsuite/gcc.dg/tree-checker/tree-checks-1.c: New.
5617 * testsuite/gcc.dg/tree-checker/tree-checks-2.c: New.
5618 * testsuite/gcc.dg/tree-checker/tree-checks-3.c: New.
5619 * testsuite/gcc.dg/tree-checker/tree-checks-4.c: New.
5620 * testsuite/gcc.dg/tree-checker/tree-checks.exp: New.
5621 * testsuite/gcc.dg/tree-checker/condates.crp: New.
5622 * common.opt (ftree-checks-verbose): New.
5623 * tree-check.c (tree_check_warning): Move extra stderr output
5624 under control of flag_tree_check_verbose.
5625
56262007-04-12 Sebastian Pop <sebastian.pop@inria.fr>
5627
5628 * tree-match.c: Fix comments formatting.
5629 * tree-match.h: Fix comments formatting.
5630 * tree-check.c: Fix comments formatting.
5631 (tree_check_init): Restructure.
5632
56332007-04-12 Nic Volanschi <nic.volanschi@free.fr>
5634
5635 * doc/invoke.texi (-ftree-check, -ftree-checks): Documented.
5636
56372007-04-10 Sebastian Pop <sebastian.pop@inria.fr>
5638
5639 * Merge from mainline (r120733:123693).
5640
56412007-03-20 Nic Volanschi <nic.volanschi@free.fr>
5642
5643 * condate.y: New file.
5644 * tree-match.h (struct patt_info_s): New field sign.
5645 (struct condate_s): New field msg.
5646 (normalize_condate, name_condate, add_condate): New.
5647 (conds[], condate_parse): Made extern.
5648 * tree-check.c (tree_check_warning): First arg changed to cond;
5649 warning reformatted.
5650 (tree_check_init): Reset the TREE_VISITED bit on every CFG node.
5651 (tree_scan): New.
5652 (tree_check): Process trivial condates.
5653 (read_delimited_string): Removed.
5654 (print_cond): Print name and msg.
5655 (conds[]): Made extern.
5656 (parse_tree_check_file_once): Rewritten to use the parser in
5657 condate.y.
5658 Processing of option --tree_check_string moved to tree_scan().
5659 * Makefile.in: Added condate.y
5660
56612007-03-12 Sebastian Pop <sebastian.pop@inria.fr>
5662
5663 * tree-pretty-print.c (dump_generic_bb_buff, lazy_dump_generic_node):
5664 Use VECs instead of varrays.
5665 * diagnostic.h (lazy_dump_generic_node): Update declaration.
5666 * Makefile.in (pretty-print.o): Depend on vec.h.
5667 * pretty-print.c: Include tree.h and vec.h.
5668 (pp_clear_state, pp_write_list_to_stream, pp_base_format,
5669 pp_base_format, pp_construct, pp_base_string, pp_lazy_mode,
5670 new_tree_chunk, pp_add_tree, pp_add_string, pp_add_char, pp_write_list,
5671 pp_free_list): Use VECs instead of varrays.
5672 * pretty-print.h: Do not include varray.h.
5673 (struct tree_chunk_s): Declaration moved before its use.
5674 (output_buffer): Rename varray field to chunks.
5675 * tree-match.c (tree_equal, chunk_1st_char, chunks_lookahead,
5676 tree_1st_char, match_chunks_pattinfo, match_tree_pattinfo,
5677 save_global_holes): Use VECs instead of varrays.
5678 * tree-match.h: Declare VECs of cfg_node, and hole_p.
5679 * tree-check.c (scan_cfg_stmts, push_node,
5680 print_matching_stmt): Removed.
5681 (tree_check_instance, push_global_holes_if_new, tree_check,
5682 execute_tree_check): Use VECs instead of varrays.
5683 (gate_tree_check): Don't execute the CFG check when basic_block_info
5684 is not available.
5685
56862007-01-12 Sebastian Pop <sebastian.pop@inria.fr>
5687
5688 * Merge from mainline (r115016:120733).
5689
56902007-01-12 Sebastian Pop <sebastian.pop@inria.fr>
5691
5692 * Merge from mainline (r117632:117661).
5693
56942007-01-12 Sebastian Pop <sebastian.pop@inria.fr>
5695
5696 * tree-dump.c (dump_option_value_in): Add TDF_DEBUG.
5697 * tree-pass.h (TDF_DEBUG, debug_p): New.
5698 * tree-scalar-evolution.c (set_scalar_evolution, get_scalar_evolution,
5699 get_scalar_evolution, add_to_evolution, set_nb_iterations_in_loop,
5700 get_loop_exit_condition, analyze_evolution_in_loop,
5701 analyze_initial_condition, analyze_scalar_evolution,
5702 instantiate_parameters, number_of_latch_executions): Use debug_p.
5703 * tree-chrec.c (chrec_apply): Use debug_p.
5704 * tree-data-ref.c: Include graphite.h.
5705 (dump_data_reference): Print also the access matrix.
5706 (analyze_array, analyze_indirect_ref, init_data_ref,
5707 analyze_offset_expr, address_analysis, object_analysis,
5708 create_data_ref, finalize_ddr_dependent,
5709 non_affine_dependence_relation, analyze_ziv_subscript,
5710 analyze_siv_subscript_cst_affine,
5711 compute_overlap_steps_for_affine_1_2, analyze_subscript_affine_affine,
5712 can_use_analyze_subscript_affine_affine, analyze_siv_subscript,
5713 analyze_miv_subscript, analyze_overlapping_iterations,
5714 build_classic_dist_vector, subscript_dependence_tester,
5715 compute_affine_dependence, analyze_all_data_dependences): Use debug_p.
5716 (build_access_matrix_with_af): No longer static.
5717 * tree-data-ref.h (scop_p): ... declaration here.
5718 (data_reference.scop): New field.
5719 (DR_SCOP, DR_ACCESS_MATRIX): New.
5720 (build_access_matrix_with_af, dr_num_subscripts): Declared.
5721 * graphite.c (print_graphite_bb): Call dump_data_references.
5722 (print_scop): Use scop_nb_loops and scop_dim_domain.
5723 (test_for_scop_bound): Use debug_p.
5724 (scan_tree_for_params): Use scop_nb_loops, scop_nb_loops and
5725 scop_nb_params.
5726 (scop_loop_index): Moved...
5727 (scop_record_loop): New.
5728 (build_scop_loop_nests): Use scop_record_loop.
5729 (build_scop_domain): Use scop_dim_domain.
5730 (build_access_matrix): Implemented.
5731 (build_scop_canonical_schedules): Use scop_nb_loops.
5732 (build_graphite_bb): Initialize GBB_SCOP.
5733 * graphite.h (scop_p): Moved...
5734 (graphite_bb.scop): New field.
5735 (graphite_bb.iteration_domain, GBB_DOMAIN, scop.nb_params,
5736 scop.nb_loops, scop.dim_domain, SCOP_NB_LOOPS, SCOP_NB_PARAMS,
5737 SCOP_DIM_DOMAIN, SCOP_STMTS): Removed.
5738 (scop_nb_params, scop_nb_loops, scop_dim_domain, gbb_dim_domain,
5739 scop_loop_index): New.
5740 * Makefile.in (tree-data-ref.o): Depends on graphite.h.
5741
57422007-01-05 Sebastian Pop <sebastian.pop@inria.fr>
5743
5744 * Merge from mainline (r117661:120450).
5745
57462006-10-12 Sebastian Pop <sebastian.pop@inria.fr>
5747
5748 * tree-scalar-evolution.c (instantiate_parameters_1): Don't stop
5749 at the first declaration outside the varying loop, instantiate as
5750 far as possible.
5751 * tree-chrec.c (for_each_scev_op): New.
5752 * tree-chrec.h (for_each_scev_op): Declared.
5753 * tree-ssa-loop.c (pass_graphite_trans): Don't dump the function.
5754 * tree-data-ref.c (get_references_in_stmt,
5755 find_data_references_in_stmt): New, from trunk.
5756 (find_data_references_in_loop): Use get_references_in_stmt
5757 and find_data_references_in_loop, modified as in trunk.
5758 (build_access_matrix_with_af): New.
5759 * tree-data-ref.h (data_reference): Add a field access_matrix.
5760 (data_ref_loc): New, as in trunk.
5761 * graphite.c (print_graphite_bb, bb_in_scop_p, stmt_in_scop_p,
5762 invariant_in_scop_p, param_index, scan_tree_for_params,
5763 scop_loop_index, build_scop_loop_nests, build_scop_domain, irp_data,
5764 idx_record_param, idx_record_params, build_access_matrix,
5765 build_scop_data_accesses, build_scop_canonical_schedules,
5766 build_graphite_bb, build_scop_bbs, find_params_in_bb,
5767 build_scop_params): New.
5768 * graphite.h (graphite_bb): New.
5769 (scop): Add fields static_schedule, params, loop_nest,
5770 iteration_domain.
5771 * lambda.h: Declare vecs of lambda_matrix.
5772 * tree-flow.h (print_loop_ir_bb): Declared.
5773 * tree-cfg.c (print_loop_ir_bb): New.
5774 (print_loop): Use print_loop_ir_bb.
5775
57762006-10-12 Sebastian Pop <pop@cri.ensmp.fr>
5777
5778 * Merge from mainline (r115016:117632).
5779
57802006-10-11 Sebastian Pop <pop@cri.ensmp.fr>
5781
5782 * graphite.c (debug_scops): Adjust definition for avoiding a bootstrap
5783 break due to a warning.
5784
57852006-10-10 Sebastian Pop <pop@cri.ensmp.fr>
5786
5787 * graphite.c (print_scops, debug_scops): New.
5788 (graphite_transform): Renamed graphite_find_transform.
5789 * graphite.h (debug_scops): Declared.
5790
57912006-08-17 Sebastian Pop <pop@cri.ensmp.fr>
5792
5793 * tree-match.c: Reformat following the GNU style.
5794 * tree-match.h: Reformat following the GNU style.
5795 * tree-pattern.h: Removed empty file.
5796 * Makefile.in: Remove references to tree-pattern.h.
5797 * tree-check.c: Reformat following the GNU style.
5798 (execute_tree_check): Move gate condition code to...
5799 (gate_tree_check): ...here. New function.
5800 (pass_check): Use the gate function.
5801
58022006-07-04 Nic Volanschi <nic.volanschi@free.fr>
5803
5804 * tree-pattern.h: New. Tree pattern matching and checking using
5805 concrete syntax.
5806 * tree-check.c: New. Tree/CFG checking pass.
5807 * tree-match.c: New. Library for tree pattern matching.
5808 * opts.c, common.opt: Add options --ftree-check & --ftree-checks.
5809 * toplev.c, flags.h: Add globals for tree-check pass.
5810 * Makefile.in: Integrate the files in tree-check pass.
5811 * timevar.def, tree-optimize.c, tree-pass.h: Register tree-check pass.
5812 * pretty-print.c, pretty-print.h, tree-pretty-print.c, diagnostic.h:
5813 Introduce a "lazy" pretty-print mode.
5814 * tree.c, tree.h: Add tree_name.
5815
58162006-07-04 Sebastian Pop <pop@cri.ensmp.fr>
5817
5818 * doc/invoke.texi (-fgraphite): Correct typo.
5819 * tree-scalar-evolution.c (number_of_iterations_for_all_loops): Update
5820 use of print_loop_ir.
5821 * testsuite/gcc.dg/graphite/scop-1.c: New.
5822 * testsuite/gcc.dg/graphite/scop-2.c: New.
5823 * testsuite/gcc.dg/graphite/graphite.exp: New.
5824 * graphite.c: Include domwalk.h.
5825 (print_scop): Print only the entry and exit blocks.
5826 (debug_scop): No longer static.
5827 (affine_expr): Fix formating. Return also true when the expression is
5828 constant.
5829 (stmt_simple_for_scop_p): Fix formating.
5830 (build_scops): Use domwalk.
5831 (get_loop_start, end_scop, test_for_scop_bound): New.
5832 (graphite_transform_loops): Avoid printing on stderr.
5833 * graphite.h (debug_scop): Declared.
5834 * tree-flow.h (debug_loop_ir, print_loop_ir): Update declarations.
5835 * Makefile.in (graphite.o): Depend on domwalk.h.
5836 * tree-cfg.c (print_loop, print_pred_bbs, print_succ_bbs): Remove
5837 declarations for static functions.
5838 (print_loop, print_loop_ir, debug_loop_ir): Use an extra parameter for
5839 controlling output verbosity.
5840
58412006-06-26 Sebastian Pop <pop@cri.ensmp.fr>
5842 Plesco Alexandru <shurikx@gmail.com>
5843
5844 * doc/invoke.texi (-fgraphite): Document.
5845 * tree-pass.h (pass_graphite_transforms): Declared.
5846 * timevar.def (TV_GRAPHITE_TRANSFORMS): New.
5847 * tree-ssa-loop.c (graphite_transforms, gate_graphite_transforms): New.
5848 (pass_graphite_transforms): Defined.
5849 * tree-data-ref.c (free_data_ref, data_reference): Extern.
5850 * tree-data-ref.h (free_data_ref, data_reference): Declared.
5851 * graphite.c, graphite.h: New.
5852 * common.opt (fgraphite): Declared.
5853 * tree-flow.h (graphite_transform_loops): Declared.
5854 * Makefile.in (OBJS-common): Add graphite.o.
5855 (graphite.o): New rule.
5856 * passes.c (pass_graphite_transforms): Scheduled.
5857