1 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
3 * graphite-blocking.c (pbb_do_strip_mine): Use
4 PARAM_LOOP_BLOCK_TILE_SIZE.
6 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
8 * graphite-poly.c (dot_lst_1): New.
10 * graphite-poly.h (dot_lst): Declared.
12 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
14 * graphite-dependences.c (dot_deps_stmt_1): New.
16 * graphite-dependences.h (dot_deps_stmt): Declared.
18 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
20 * graphite-sese-to-poly.c (rewrite_cross_bb_scalar_dependence): Do
21 not replace cross BB scalar dependences ending on PHI nodes.
22 (rewrite_cross_bb_scalar_deps): Filter out GIMPLE_PHI nodes.
24 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
26 * graphite-poly.c (apply_poly_transforms): Implement the high
27 level driver for flag_loop_block.
28 * tree-ssa-loop.c (gate_graphite_transforms): Remove call to sorry for
31 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK): Add
33 * gfortran.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK):
36 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
38 * graphite-poly.h (lst_find_pbb): New.
41 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
43 * graphite-poly.c (new_scop): Remove init of SCOP_DEP_GRAPH.
44 * graphite-poly.h (struct scop): Remove dep_graph field.
45 (SCOP_DEP_GRAPH): Removed.
47 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
49 * graphite-poly.h (copy_lst): Do full copy of LST.
51 2009-10-07 Sebastian Pop <sebastian.pop@amd.com>
53 * graphite-sese-to-poly.c (reduction_phi_p): Call remove_invariant_phi
54 when the loop stride is zero.
56 * gcc.dg/graphite/id-16.c: New.
58 2009-10-06 Sebastian Pop <sebastian.pop@amd.com>
60 * graphite-dependences.c (reduction_dr_1): New.
61 (reduction_dr_p): New.
62 (graphite_legal_transform_dr): Call reduction_dr_p.
63 (reduction_ddr): Renamed reduction_ddr_p.
64 * graphite-poly.h (same_pdr_p): New.
65 (number_of_write_pdrs): New.
66 * graphite-sese-to-poly.c (nb_data_writes_in_bb): New.
67 (split_reduction_stmt): Do not split reduction statements
68 when there are no writes to memory.
69 (translate_scalar_reduction_to_array_for_stmt): Insert the
70 memory reduction statement just after the scalar reduction statement.
72 * gcc.dg/graphite/interchange-10.c: Updated to differ from interchange-4.c.
74 * gcc.dg/graphite/interchange-3.c: Un-XFAIL-ed.
75 * gcc.dg/graphite/interchange-4.c: Un-XFAIL-ed.
77 2009-10-06 Sebastian Pop <sebastian.pop@amd.com>
79 * graphite-interchange.c (lst_apply_interchange): New.
80 (lst_interchange_profitable_p): New.
81 (lst_try_interchange_loops): New.
82 (lst_try_interchange): New.
83 (lst_do_interchange): New.
84 (pbb_do_interchange): Removed.
85 (scop_do_interchange): Call lst_do_interchange.
87 2009-10-06 Sebastian Pop <sebastian.pop@amd.com>
89 * graphite-poly.c (print_scop): Print SCOP_ORIGINAL_SCHEDULE and
90 SCOP_TRANSFORMED_SCHEDULE.
95 * graphite-poly.h (lst_p): New.
98 (LST_LOOP_FATHER): New.
101 (scop_to_lst): Declared.
102 (print_lst): Declared.
103 (debug_lst): Declared.
108 (lst_dewey_number): New.
109 (struct scop): Add original_schedule and transformed_schedule fields.
110 (SCOP_ORIGINAL_SCHEDULE): New.
111 (SCOP_TRANSFORMED_SCHEDULE): New.
112 * graphite-sese-to-poly.c (build_poly_scop): Call scop_to_lst.
114 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
116 * graphite-dependences.c (reduction_ddr): New.
117 (graphite_legal_transform_bb): Call reduction_ddr.
118 * graphite-poly.c (new_poly_bb): Pass a new bool parameter.
119 Initialize PBB_IS_REDUCTION.
120 * graphite-poly.h (struct poly_bb): New bool field is_reduction.
121 (PBB_IS_REDUCTION): New.
122 (new_poly_bb): Update declaration.
123 * graphite-scop-detection.h (build_scop_bbs): Removed.
124 (nb_reductions_in_loop): Removed.
125 * graphite-sese-to-poly.c (try_generate_gimple_bb): Pass a sbitmap
126 parameter for reductions.
127 (try_generate_gimple_bb): Update call to new_poly_bb.
128 (build_scop_bbs_1): Same.
129 (build_scop_bbs): Same.
130 (gsi_for_phi_node): New.
131 (scalar_close_phi_node_p): Remove gcc_assert.
132 (split_reduction_stmt): New.
133 (is_reduction_operation_p): New.
134 (phi_contains_arg): New.
135 (follow_ssa_with_commutative_ops): New.
136 (detect_commutative_reduction_arg): New.
137 (detect_commutative_reduction_assign): New.
138 (follow_inital_value_to_phi): New.
139 (edge_initial_value_for_loop_phi): New.
140 (initial_value_for_loop_phi): New.
141 (detect_commutative_reduction): New.
142 (translate_scalar_reduction_to_array_for_stmt): New.
143 (insert_copyout): New.
144 (insert_copyin): New.
145 (translate_scalar_reduction_to_array): New.
146 (rewrite_commutative_reductions_out_of_ssa_close_phi): New.
147 (rewrite_commutative_reductions_out_of_ssa_loop): New.
148 (rewrite_commutative_reductions_out_of_ssa): New.
149 (build_poly_scop): Call rewrite_commutative_reductions_out_of_ssa.
150 * sese.h (split_region_for_bb): New.
152 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK): Add -ffast-math.
153 * gcc.dg/graphite/interchange-1.c: Fix format.
154 * gcc.dg/graphite/interchange-10.c: New.
156 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
158 * graphite-sese-to-poly.c (insert_out_of_ssa_copy): Remove
161 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
163 * graphite-sese-to-poly.c (scev_analyzable_p): New.
164 (rewrite_cross_bb_scalar_dependence): New.
165 (rewrite_cross_bb_scalar_deps): New.
166 (rewrite_reductions_out_of_ssa): Use bb_in_sese_p.
167 Call rewrite_cross_bb_scalar_deps.
169 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
171 * graphite-sese-to-poly.c (gsi_for_ssa_name_def): Removed.
172 (insert_out_of_ssa_copy): Directly use gsi_after_labels and
175 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
177 * graphite-clast-to-gimple.c (build_cloog_prog): Use pbb_index.
178 * graphite-interchange.c (pbb_do_interchange): Same.
179 * graphite-poly.c (print_scattering_function): Same.
181 * graphite-poly.h (pbb_loop): New.
182 * graphite-sese-to-poly.c (create_linear_expr_from_tree): Use pbb_loop.
184 2009-09-27 Sebastian Pop <sebastian.pop@amd.com>
186 * graphite-scop-detection.c (limit_scops): Do not build poly_bbs.
188 2009-09-27 Sebastian Pop <sebastian.pop@amd.com>
190 * graphite-sese-to-poly.c (partition_drs_to_sets): Drs is not modified,
191 so don't pass a pointer to it.
192 (build_alias_set_for_drs): Same.
193 (build_base_obj_set_for_drs): Same.
194 (build_scop_drs): Same.
196 2009-09-26 Li Feng <nemokingdom@gmail.com>
198 * graphite-sese-to-poly.c (build_scop_drs): Disable writing to file
199 the alias graph of data references.
201 2009-09-25 Li Feng <nemokingdom@gmail.com>
203 * graphite-sese-to-poly.c (write_alias_graph_to_ascii_dimacs): New.
204 (build_scop_drs): When debugging, write the alias graph to file,
205 otherwise, should be disabled.
207 2009-09-17 Sebastian Pop <sebastian.pop@amd.com>
209 * graphite-scop-detection.c (stmt_simple_memref_p): Removed.
210 (is_simple_operand): Remove call to stmt_simple_memref_p.
211 (stmt_simple_for_scop_p): Update call to is_simple_operand.
213 2009-09-17 David Edelsohn <edelsohn@gnu.org>
215 * testsuite/gcc.dg/graphite/interchange-mvt.c: New File.
216 * testsuite/gcc.dg/graphite/scop-dsyrk.c: New File.
217 * testsuite/gcc.dg/graphite/scop-dsyr2k.c: New File.
218 * testsuite/gcc.dg/graphite/scop-mvt.c: New File.
219 * testsuite/gcc.dg/graphite/scop-sor.c: New File.
221 2009-09-17 Li Feng <nemokingdom@gmail.com>
224 * graphite-dependences.c (poly_drs_may_alias_p): Adjust definition.
225 (pddr_original_scattering): Make sure 2 pdr2 in the same base object set.
226 (graphite_carried_dependence_level_k): Ditto.
227 * graphite-poly.c (new_poly_dr): Add init of PDR_BASE_OBJECT_SET.
228 * graphite-poly.h (struct poly_dr): Add member dr_base_object_set.
229 (new_poly_dr): Adjust declaration.
230 * graphite-sese-to-poly.c (free_data_refs_aux): New.
231 (free_gimple_bb): Added free_data_refs_aux.
232 (build_poly_dr): Add dr_base_object_set.
233 (partition_drs_to_sets): New.
234 (dr_same_base_object_p): New.
235 (build_alias_set_for_drs): New.
236 (build_base_object_set_for_drs): New.
237 (build_scop_drs): Add build_base_obj_set_for_drs.
238 * graphite-sese-to-poly.h: Added #define for alias set number index and
239 base object set index.
240 * libgomp/testsuite/libgomp.graphite/force-parallel-6.c: Refine tests.
241 * libgomp/testsuite/libgomp.graphite/pr4118.c: New.
243 2009-09-16 Alexander Monakov <amonakov@ispras.ru>
245 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Add bounds only
246 for ARRAY_REFs. Use array_ref_{low,up}_bound to determine bounds.
248 2009-09-14 Sebastian Pop <sebastian.pop@amd.com>
250 * graphite-sese-to-poly.c (struct irp_data): Removed.
251 (idx_record_params): Removed.
252 (find_params_in_bb): Scan for parameters the access functions; don't
253 parse the tree representation.
255 2009-09-14 Sebastian Pop <sebastian.pop@amd.com>
257 * tree-ssa-loop.c (gate_graphite_transforms): Disable Graphite
258 passes at -O1 and below.
260 2009-09-14 Sebastian Pop <sebastian.pop@amd.com>
262 * graphite-blocking.c: Fix order of includes: tree-chrec.h, then
263 tree-scalar-evolution.h, and then tree-data-ref.h.
264 * graphite-clast-to-gimple.c: Same.
265 * graphite-dependences.c: Same.
266 * graphite-interchange.c: Same.
267 * graphite-poly.c: Same.
268 * graphite-scop-detection.c: Same.
269 * graphite-sese-to-poly.c: Same.
271 * lambda-code.c: Same.
272 * matrix-reorg.c: Same.
273 * tree-data-ref.c: Same.
274 * tree-if-conv.c: Same.
275 * tree-loop-distribu: Same.: Same.
276 * tree-loop-linear.c: Same.
277 * tree-parloops.c: Same.
278 * tree-predcom.c: Same.
279 * tree-vect-patterns.c: Same.
281 2009-09-02 Sebastian Pop <sebastian.pop@amd.com>
283 Partially revert the previous patch, except the following.
284 * tree-scalar-evolution.c (instantiate_scev_not): Adapted to pass
285 as parameters the operands of the not expression.
287 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
289 * tree-scalar-evolution.c (instantiate_scev_assign): New.
290 Do not call analyze_scalar_evolution on assignments.
291 (instantiate_scev_phi): Call analyze_scalar_evolution.
292 (instantiate_scev_name): Call instantiate_scev_assign and
293 instantiate_scev_phi.
294 (instantiate_scev_not): Adapted to pass as parameters the operands
295 of the not expression.
297 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
299 * tree-scalar-evolution.c (instantiate_scev_binary): Adapted
300 to pass as parameters the operands of the binary expression.
302 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
304 * tree-scalar-evolution.c (instantiate_scev_bitnot): Renamed
305 instantiate_scev_not. Handle NEGATE_EXPR.
306 (instantiate_scev_r): Handle NEGATE_EXPR.
308 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
310 * tree-scalar-evolution.c (instantiate_scev_1): Renamed
312 (instantiate_scev_r): Move code in instantiate_scev_2
313 and instantiate_scev_1.
315 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
317 * tree-scalar-evolution.c (instantiate_scev_3): New.
318 (instantiate_scev_1): Move code in instantiate_scev_3.
320 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
322 * tree-scalar-evolution.c (instantiate_scev_poly): New.
323 (instantiate_scev_1): Move code in instantiate_scev_poly.
325 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
327 * tree-scalar-evolution.c (instantiate_scev_bitnot): New.
328 (instantiate_scev_1): Move code in instantiate_scev_bitnot.
330 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
332 * tree-scalar-evolution.c (instantiate_scev_convert): New.
333 (instantiate_scev_1): Move code in instantiate_scev_convert.
335 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
337 * tree-scalar-evolution.c (instantiate_scev_binary): New.
338 (instantiate_scev_1): Move code in instantiate_scev_binary.
340 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
342 * tree-scalar-evolution.c (instantiate_scev_name): New.
343 (instantiate_scev_1): Move code in instantiate_scev_name.
345 2009-08-28 Sebastian Pop <sebastian.pop@amd.com>
347 * Merge from mainline (150992:151171).
349 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
351 * graphite-dependences.c (graphite_legal_transform_bb): Call
352 pbb_remove_duplicate_pdrs.
353 * graphite-poly.c (can_collapse_pdr): Removed.
354 (pdr_find_duplicate): Removed.
355 (can_collapse_pdrs): New.
356 (pbb_remove_duplicate_pdrs): New.
357 (new_poly_dr): Do not look for duplicates.
358 * graphite-poly.h (struct poly_bb): New field pdr_duplicates_removed.
359 (PBB_PDR_DUPLICATES_REMOVED): New.
360 (pbb_remove_duplicate_pdrs): Declared.
362 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
364 * graphite-interchange.c (pbb_interchange_profitable_p): Adjust
365 the strides by multiplying by PDR_NB_REFS.
366 * graphite-poly.c (can_collapse_pdr): New.
367 (pdr_find_duplicate): New.
368 (new_poly_dr): Call pdr_find_duplicate. Collapse duplicate PDRs.
369 Initialize PDR_NB_REFS.
370 * graphite-poly.h (struct poly_dr): Add field nb_refs.
372 (new_poly_dr): Number of subscripts is a graphite_dim_t.
374 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
376 Revert one of the previous commits:
377 * graphite-dependences.c (graphite_legal_transform_bb): Avoid
378 the computation of symmetric data dependence relations.
379 (dependency_between_pbbs_p): Same.
381 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
384 * graphite-poly.c (apply_poly_transforms): Remove legality test before
387 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
389 * graphite-dependences.c (pddr_original_scattering): Return NULL
390 for read-read dependence relations.
391 * graphite-poly.h (enum poly_dr_type): Fix comment.
394 (pdr_may_write_p): New.
396 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
398 * graphite-poly.h (enum POLY_DR_TYPE): Renamed poly_dr_type.
399 (struct poly_dr): Same.
401 * graphite-poly.c (new_poly_dr): Same.
403 2009-08-25 Konrad Trifunovic <konrad.trifunovic@gmail.com>
404 Sebastian Pop <sebastian.pop@amd.com>
406 * graphite-blocking.c (pbb_strip_mine_loop_depth): Renamed
407 pbb_strip_mine_time_depth. Changed the implementation so that
408 transformation is expressed as a transformation on
409 time (scatttering) dimensions. Also, ensures that the 2d+1
410 scheduling format is preserved.
411 (pbb_strip_mine_profitable_p): Profitability is based on the
412 iteration number of a given time (scattering) dimension,
413 and not on a original loop depth dimension.
414 (pbb_strip_mine): Call pbb_number_of_iterations_at_time.
415 (pbb_do_strip_mine): Call psct_dynamic_dim.
416 * graphite-poly.c (pbb_number_of_iterations_at_time): New.
417 * graphite-poly.h (pbb_number_of_iterations_at_time): Declared.
418 (pbb_nb_dynamic_scattering_transform): New.
419 (psct_dynamic_dim): New.
421 2009-08-25 Konrad Trifunovic <konrad.trifunovic@gmail.com>
423 * graphite-ppl.c (ppl_max_for_le): Renamed ppl_max_for_le_pointset.
424 * graphite-ppl.h (ppl_max_for_le): Renamed ppl_max_for_le_pointset.
425 * graphite-poly.c (pbb_number_of_iterations): Rename ppl_max_for_le.
426 * graphite-interchange.c (build_linearized_memory_access): Same.
427 (memory_stride_in_loop): Same.
429 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
431 * graphite-dependences.c (pddr_original_scattering): New.
432 (graphite_legal_transform_dr): Call pddr_original_scattering.
435 * graphite-dependences.h (dot_deps): Declared.
436 * graphite-poly.c (new_poly_dr): Initialize PDR_ID.
437 (print_pdr): Print PDR_ID.
438 * graphite-poly.h (struct poly_dr): Add field id.
441 * graphite-scop-detection.c (dot_all_scops_1): Cleanup comment.
443 2009-08-22 Sebastian Pop <sebastian.pop@amd.com>
445 * graphite-dependences.c (graphite_carried_dependence_level_k): Do
446 not delete the original dependence relation.
448 2009-08-21 Sebastian Pop <sebastian.pop@amd.com>
450 * graphite-dependences.c (graphite_legal_transform_bb): Avoid
451 the computation of symmetric data dependence relations.
452 (dependency_between_pbbs_p): Same.
454 2009-08-21 Sebastian Pop <sebastian.pop@amd.com>
456 * graphite-dependences.c (new_poly_dr_pair): Renamed new_poly_ddr.
457 (eq_poly_dr_pair_p): Renamed eq_poly_ddr_p.
458 (hash_poly_dr_pair_p): Renamed hash_poly_ddr_p.
459 (free_poly_ddr): New.
460 (pddr_is_empty): New.
461 (dependence_polyhedron_1): Now returns a poly_ddr_p.
462 (dependence_polyhedron): Same. Remove useless gcc_assert.
464 (graphite_legal_transform_dr): Call pddr_is_empty and free_poly_ddr.
465 (graphite_carried_dependence_level_k): Call pddr_is_empty.
466 * graphite-dependences.h (enum poly_dependence_kind): New.
467 (poly_dr_pair): Renamed poly_ddr. Added a field kind.
468 (PDRP_SOURCE): Renamed PDDR_SOURCE.
469 (PDRP_SINK): Renamed PDDR_SINK.
470 (PDRP_DDP): Renamed PDDR_DDP.
472 (free_poly_ddr): Declared.
473 * graphite-poly.c (new_scop): Use the new hash function names.
474 * graphite-poly.h (struct scop): Renamed field original_pdr_pairs
476 (SCOP_ORIGINAL_PDR_PAIRS): Renamed SCOP_ORIGINAL_PDDRS.
478 2009-08-21 Sebastian Pop <sebastian.pop@amd.com>
480 * Merge from mainline (150764:150992).
482 2009-08-18 Sebastian Pop <sebastian.pop@amd.com>
484 * cfgloopmanip.c (create_empty_loop_on_edge): Generate upper
485 bounds with LT_EXPR to make niter analysis more precise on code
486 generated by Graphite.
488 2009-08-18 Sebastian Pop <sebastian.pop@amd.com>
490 * graphite-dependences.c (graphite_legal_transform_dr): Fix formatting.
491 (graphite_legal_transform_bb): Same.
492 (poly_drs_may_alias_p): Same.
494 2009-08-15 Sebastian Pop <sebastian.pop@amd.com>
497 * graphite-ppl.c (ppl_max_for_le): Correct the use of
498 ppl_Pointset_Powerset_C_Polyhedron_maximize.
500 2009-08-13 Sebastian Pop <sebastian.pop@amd.com>
502 * graphite-poly.c (print_pbb): Print PBB index.
504 2009-08-13 Sebastian Pop <sebastian.pop@amd.com>
506 * Merge from mainline (r150672:150764).
508 2009-08-13 Sebastian Pop <sebastian.pop@amd.com>
510 * graphite-interchange.c (ppl_max_for_le): Moved...
511 * graphite-poly.c (pbb_number_of_iterations): Call ppl_max_for_le.
512 * graphite-ppl.c (ppl_max_for_le): ... here.
513 * graphite-ppl.h (ppl_max_for_le): Declared.
515 2009-08-12 Sebastian Pop <sebastian.pop@amd.com>
517 * Merge from mainline (r150372:150672).
519 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
522 * sese.c (convert_for_phi_arg): New.
523 (add_guard_exit_phis): Use convert_for_phi_arg.
525 * testsuite/gfortran.dg/graphite/id-17.f: New.
527 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
529 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Dont add
530 unknown subscript upper bounds.
532 * testsuite/gcc.dg/graphite/interchange-6.c: Un-XFAIL.
534 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
535 Pranav Garg <pranav.garg2107@gmail.com>
537 * graphite-interchange.c (gather_access_strides): Removed.
538 (ppl_max_for_le): New.
539 (build_linearized_memory_access): New.
540 (memory_stride_in_loop): New.
541 (pbb_interchange_profitable_p): Reimplemented.
542 * graphite-ppl.h (ppl_new_id_map): New.
543 (ppl_interchange): New.
545 * testsuite/gcc.dg/graphite/interchange-6.c: XFAILed.
547 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
549 * graphite-interchange.c (compute_subscript): Removed.
550 (compute_array_size_cstr): Removed.
551 (compute_array_size_poly): Removed.
552 (compute_array_size): Removed.
553 (gather_access_strides_poly): Removed.
554 (gather_access_strides): Empty.
556 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
558 * graphite-dependences.c (dependence_polyhedron_1): Replace
559 pdr_nb_subscripts with PDR_NB_SUBSCRIPTS.
560 (graphite_legal_transform_dr): Same.
561 (graphite_carried_dependence_level_k): Same.
562 * graphite-poly.c (new_poly_dr): Add a parameter nb_subscripts.
563 Initialize PDR_NB_SUBSCRIPTS.
564 (print_pdr_access_layout): Replace pdr_nb_subscripts with
566 * graphite-poly.h (struct poly_dr): Add nb_subscripts field.
567 (PDR_NB_SUBSCRIPTS): New.
568 (pdr_nb_subscripts): Removed.
569 (pdr_dim): Simplified.
570 * graphite-sese-to-poly.c (build_poly_dr): Replace pdr_nb_subscripts
571 with PDR_NB_SUBSCRIPTS.
573 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
575 * graphite-interchange.c (compute_array_size): Remove use of
577 * graphite-poly.c (new_poly_dr): Remove argument data_container.
578 Do not initialize PDR_DATA_CONTAINER.
579 (print_pdr): Do not print PDR_DATA_CONTAINER.
580 * graphite-poly.h (struct poly_dr): Remove data_container field.
581 (PDR_DATA_CONTAINER): Removed.
582 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Remove use of
584 (build_poly_dr): Same.
586 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
588 * testsuite/gcc.dg/graphite/interchange-9.c: New.
590 2009-08-05 Konrad Trifunovic <konrad.trifunovic@gmail.com>
591 Sebastian Pop <sebastian.pop@amd.com>
593 * graphite-dependences.c (graphite_legal_transform_dr): Work on a
594 copy of the dependence polyhedron. Free the temporary objects.
595 (graphite_carried_dependence_level_k): Free unused objects before
598 * testsuite/gcc.dg/graphite/interchange-1.c: XFAILed.
599 * testsuite/gcc.dg/graphite/interchange-2.c: XFAILed.
600 * testsuite/gcc.dg/graphite/interchange-3.c: XFAILed.
601 * testsuite/gcc.dg/graphite/interchange-4.c: XFAILed.
602 * testsuite/gcc.dg/graphite/interchange-7.c: XFAILed.
604 2009-08-05 Sebastian Pop <sebastian.pop@amd.com>
606 * graphite-blocking.c (scop_do_strip_mine): Call store_scattering.
607 Early return without analyzing the data dependences if no
608 transform has been done. Call restore_scattering if the transform
610 (graphite-interchange.c): Same.
611 * graphite-poly.c (print_scattering_function): Test for PBB_TRANSFORMED.
612 (graphite_read_transforms): Initialize PBB_TRANSFORMED.
613 (apply_poly_transforms): Do not gcc_assert that
614 the transform is legal.
615 (new_poly_bb): Initialize PBB_TRANSFORMED, PBB_SAVED, and PBB_ORIGINAL.
616 Do not initialize PBB_NB_SCATTERING_TRANSFORM, PBB_NB_LOCAL_VARIABLES,
617 PBB_TRANSFORMED_SCATTERING, and PBB_ORIGINAL_SCATTERING.
618 (free_poly_dr): Free PBB_TRANSFORMED, PBB_SAVED, and PBB_ORIGINAL.
619 * graphite-poly.h (struct poly_scattering): New.
620 (struct poly_bb): Add original, transformed, and saved fields.
621 Remove transformed_scattering, original_scattering, nb_local_variables,
622 and nb_scattering_transform fields.
623 (PBB_ORIGINAL, PBB_TRANSFORMED, PBB_SAVED): New.
624 (poly_scattering_new): New.
625 (poly_scattering_free): New.
626 (poly_scattering_copy): New.
627 (store_scattering_pbb): New.
628 (store_scattering): New.
629 (restore_scattering_pbb): New.
630 (restore_scattering): New.
631 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons):
632 Initialize PBB_TRANSFORMED and PBB_ORIGINAL.
634 2009-08-05 Sebastian Pop <sebastian.pop@amd.com>
636 * graphite-poly.c (print_pbb): Add parentheses in the pretty print.
639 2009-08-05 Sebastian Pop <sebastian.pop@amd.com>
641 * Makefile.in (graphite.o): Depends on PREDICT_H.
642 * graphite.c: Include predict.h.
643 (graphite_finalize): Call tree_estimate_probability.
644 * predict.c (predict_loops): Do not call scev_initialize and
646 (tree_estimate_probability_bb): New.
647 (tree_estimate_probability): Do not initialize loops: move that
648 code to the driver. Call tree_estimate_probability_bb.
649 (tree_estimate_probability_driver): New.
650 (pass_profile): Use tree_estimate_probability_driver.
651 * predict.h (tree_estimate_probability): Declared.
653 2009-08-05 Sebastian Pop <sebastian.pop@amd.com>
655 * graphite-clast-to-gimple.c (gloog): Add time to TV_GRAPHITE_CODE_GEN.
656 * graphite-dependences.c (graphite_legal_transform): Add time to
657 TV_GRAPHITE_DATA_DEPS.
658 (dependency_between_pbbs_p): Same.
659 * timevar.def (TV_GRAPHITE_DATA_DEPS, TV_GRAPHITE_CODE_GEN): New.
661 2009-08-03 Sebastian Pop <sebastian.pop@amd.com>
663 * Merge from mainline (r149952:150372).
665 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
667 * ChangeLog.graphite: Fix indenting, white spaces and 80 columns.
668 * graphite-blocking.c: Same.
669 * graphite-clast-to-gimple.c: Same.
670 * graphite-dependences.c: Same.
671 * graphite-poly.c: Same.
672 * graphite-poly.h: Same.
673 * graphite-ppl.c: Same.
674 * graphite-scop-detection.c: Same.
675 * graphite-sese-to-poly.c: Same.
678 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
680 * graphite-sese-to-poly.c (loop_entry_phi_arg): New.
681 (remove_simple_copy_phi): New.
682 (remove_invariant_phi): New.
683 (simple_copy_phi_p): New.
684 (reduction_phi_p): New.
685 (gsi_for_ssa_name_def): New.
686 (insert_out_of_ssa_copy): New.
687 (insert_out_of_ssa_copy_on_edge): New.
688 (create_zero_dim_array): New.
689 (scalar_close_phi_node_p): New.
690 (rewrite_close_phi_out_of_ssa): New.
691 (rewrite_phi_out_of_ssa): New.
692 (rewrite_reductions_out_of_ssa): New.
693 (build_poly_scop): Call rewrite_reductions_out_of_ssa.
695 * testsuite/gcc.dg/graphite/id-11.c: New.
696 * testsuite/gcc.dg/graphite/id-15.c: New.
697 * testsuite/gcc.dg/graphite/interchange-1.c: Un-XFAIL.
698 * testsuite/gcc.dg/graphite/interchange-2.c: Un-XFAIL.
699 * testsuite/gcc.dg/graphite/interchange-3.c: Un-XFAIL.
700 * testsuite/gcc.dg/graphite/interchange-4.c: Un-XFAIL.
701 * testsuite/gcc.dg/graphite/interchange-7.c: Un-XFAIL.
702 * testsuite/gcc.dg/graphite/scop-matmult.c: Un-XFAIL.
703 * testsuite/gfortran.dg/graphite/id-13.f: New.
704 * testsuite/gfortran.dg/graphite/id-5.f: New.
706 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
708 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not
709 check that nb_reductions_in_loop is zero.
710 * graphite-scop-detection.c (harmful_stmt_in_bb): Don't filter out
712 (nb_reductions_in_loop): Removed.
713 (graphite_can_represent_loop): Do not call nb_reductions_in_loop.
714 * graphite-sese-to-poly.c (phi_node_is_iv): Removed.
715 (bb_contains_non_iv_scalar_phi_nodes): Removed.
716 (scop_contains_non_iv_scalar_phi_nodes): Removed.
717 (build_poly_scop): Do not call scop_contains_non_iv_scalar_phi_nodes.
719 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
721 * graphite-clast-to-gimple.c (build_cloog_prog): Do not code generate
722 statements that have an empty iteration domain.
723 * testsuite/gfortran.dg/graphite/id-16.f: New.
725 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
727 * tree-scalar-evolution.c (instantiate_scev_1): Return
728 chrec_dont_know when the result is not above instantiate_below.
729 * graphite-scop-detection.c (scopdet_basic_block_info): Fix formatting.
730 * graphite-sese-to-poly.c (create_linear_expr_from_tree): Assert that
731 the tree has a known scalar evolution.
732 * testsuite/gfortran.dg/graphite/id-14.f: New.
733 * testsuite/gfortran.dg/graphite/id-15.f: New.
735 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
737 * sese.c (rename_variables_in_stmt): Pass in an extra parameter
739 (rename_variables): Keep inserting renames after the ones already
742 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
744 * graphite-sese-to-poly.c (compare_bb_depths): New.
745 (graphite_sort_dominated_info): New.
746 (build_scop_bbs_1): Call graphite_sort_dominated_info.
747 (build_scop_scattering): Fix comment.
749 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
751 * graphite.c (graphite_finalize): Call print_loops instead of
752 dump_function_to_file.
753 * testsuite/gcc.dg/graphite/graphite.exp: Fix formatting.
754 * testsuite/gcc.dg/graphite/pr35356-1.c: New. Look for the number of
755 loops generated in the graphite output file.
756 * testsuite/gcc.dg/graphite/pr35356-2.c: New.
757 * testsuite/gcc.dg/graphite/pr35356-3.c: New. XFAILed for now.
758 * testsuite/gfortran.dg/graphite/id-12.f: New.
760 2009-07-24 Li Feng <nemokingdom@gmail.com>
762 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-8.c:
765 2009-07-24 Li Feng <nemokingdom@gmail.com>
766 Tobias Grosser <grosser@fim.uni-passau.de>
768 * graphite-sese-to-poly.c (pdr_add_alias_set): Use data reference's
769 alias set number build alias in ACCESSES polyhedron.
770 (build_alias_set_for_drs): New.
771 (build_pbb_drs): Added build_alias_set_for_drs.
772 * graphite-dependences.c (poly_drs_may_alias_p): New.
773 (graphite_carried_dependence_level_k): Check alias information
774 before building polyhedron.
776 2009-07-24 Tobias Grosser <grosser@fim.uni-passau.de>
778 * Makefile.in (lambda-code.o): Fix formatting.
780 2009-07-24 Tobias Grosser <grosser@fim.uni-passau.de>
782 * Merge from mainline (r149350-149952)
784 2009-07-18 Tobias Grosser <grosser@fim.uni-passau.de>
786 * graphite-poly.c (apply_poly_transforms): Move strip_mine
787 before interchange to prepare for loop blocking.
789 2009-07-18 Tobias Grosser <grosser@fim.uni-passau.de>
791 * graphite-poly.c (apply_poly_transforms): Add checks after every
793 * graphite-sese-to-poly.c (build_poly_scop): Remove check, as already
794 done in apply_poly_transforms.
796 2009-07-17 Konrad Trifunovic <konrad.trifunovic@gmail.com>
798 * graphite-dependences.c (build_lexicographically_gt_constraint):
799 Replace RES parameter with *RES.
800 (dependence_polyhedron_1): Pass an address of the parameter RES
801 instead of value of RES.
803 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
805 * graphite.c (graphite_finalize): Fix comment.
806 (graphite_transform_loops): Reset scev info after code generation
809 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
811 * graphite.c (graphite_finalize): Call scev_reset.
813 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
815 * graphite-clast-to-gimple.c (compute_cloog_iv_types): Do not create
816 GBB_CLOOG_IV_TYPES hash table twice.
817 * graphite-sese-to-poly.c (free_gimple_bb): Call free_data_refs.
818 (add_condition_to_domain): Clear GMP values.
820 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
822 * graphite-dependences.c: Fix formatting.
823 * graphite-poly.c (free_poly_dr): Also free PDR_DATA_CONTAINER.
824 (pbb_number_of_iterations): Free ppl_Linear_Expression.
825 * graphite-sese-to-poly.c: Fix formatting.
826 * graphite.c (graphite_transform_loops): Create the hash table
827 after the early return.
829 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
831 * testsuite/gcc.dg/graphite/id-14.c: New.
832 * testsuite/gcc.dg/graphite/pr40157.c: New.
833 * testsuite/gfortran.dg/graphite/id-11.f: New.
835 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
837 * graphite-sese-to-poly.c (nb_pbbs_in_loops): New.
838 (build_poly_scop): Return false when there are no pbbs within
839 loops to avoid to pass to cloog scops with no loops.
841 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
843 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons): Avoid
844 useless test "i % 2".
845 (build_pbb_scattering_polyhedrons): Fix formatting.
846 (build_poly_dr): Same.
847 * graphite.c (graphite_transform_loops): Restructure.
849 2009-07-14 Razya Ladelsky <razya@il.ibm.com>
851 * tree-ssa-loop-manip.c (rewrite_phi_with_iv): Remove
852 reduction_list parameter.
853 (rewrite_all_phi_nodes_with_iv): Same.
854 (canonicalize_loop_ivs): Same.
855 * tree-parloops.c (struct brli): Removed.
856 (build_reduction_list_info): Removed.
857 (build_new_reduction): New.
858 (analyze_reduction_list): Removed.
859 (gather_scalar_reductions): Find reductions instead of phi
860 nodes that can't be canonicalized.
861 (try_create_reduction_list): Remove reduction_list parameter.
862 (gen_parallel_loop): Same.
863 (parallelize_loops): Remove analyze_reductions variable,
864 initialization and free.
865 Change reduction_list htab initialization to reduction_info
866 elements instead of ssa names.
867 Call try_create_reduction_list and gen_parallel_loop without
868 analyzed_reduction argument.
869 * graphite-clast-to-gimple (graphite_loop_normal_form): Call
870 canonicalize_loop_ivs with one less argument.
871 * tree-flow.h (canonicalize_loop_ivs): Remove one argument.
873 2009-07-14 Konrad Trifunovic <konrad.trifunovic@gmail.com>
875 * graphite-dependences.c (new_poly_dr_pair): New.
876 (dependence_polyhedron): Renamed into dependence_polyhedron_1.
877 (new_poly_dr_pair): New.
878 (eq_poly_dr_pair_p): New.
879 (hash_poly_dr_pair_p): New.
880 * graphite-dependences.h (struct poly_dr_pair): New.
881 (eq_poly_dr_pair_p): Declared.
882 (hash_poly_dr_pair_p): Declared.
883 * graphite-poly.c (new_scop): Initialize SCOP_ORIGINAL_PDR_PAIRS.
884 (free_scop): Free SCOP_ORIGINAL_PDR_PAIRS.
885 * graphite-poly.h (struct scop): Add original_pdr_pairs field.
886 * Makefile.in (graphite-poly.o): Add dependence on
887 graphite-dependences.h.
889 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
891 * graphite-scop-detection.c (graphite_can_represent_scev): Do not let
892 polynomials of degree > 1 pass to Graphite.
893 * tree-chrec.c (scev_is_linear_expression): Call
894 evolution_function_is_affine_multivariate_p.
895 * testsuite/gfortran.dg/graphite/id-10.f90: New.
897 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
899 * tree-scalar-evolution.c (compute_overall_effect_of_inner_loop):
900 Instantiate scevs varying in outer loops.
901 * testsuite/gfortran.dg/graphite/id-9.f: Correct testcase.
903 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
905 * graphite-sese-to-poly.c (build_loop_iteration_domains): Do not insert
906 redundant constraint.
908 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
910 * testsuite/gcc.dg/graphite/graphite.exp: Fix comments.
911 * testsuite/gfortran.dg/graphite/graphite.exp: Trigger actions
912 based on the file names as in the C testsuite.
913 * testsuite/gfortran.dg/graphite/block-1.f90: Fix patterns.
914 * testsuite/gfortran.dg/graphite/block-2.f: Same.
915 * testsuite/gfortran.dg/graphite/block-3.f90: Same.
916 * testsuite/gfortran.dg/graphite/block-4.f90: Same.
917 * testsuite/gfortran.dg/graphite/id-1.f90: Same.
918 * testsuite/gfortran.dg/graphite/id-2.f90: Same.
919 * testsuite/gfortran.dg/graphite/id-3.f90: Same.
920 * testsuite/gfortran.dg/graphite/id-4.f90: Same.
921 * testsuite/gfortran.dg/graphite/id-6.f: Same.
922 * testsuite/gfortran.dg/graphite/id-9.f: Same.
923 * testsuite/gfortran.dg/graphite/interchange-1.f: Same.
924 * testsuite/gfortran.dg/graphite/interchange-2.f: Same.
925 * testsuite/gfortran.dg/graphite/scop-1.f: Same.
927 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
929 * sese.c (expand_scalar_variables_call): New.
930 (expand_scalar_variables_ssa_name): Handle calls in expander.
932 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
934 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-6.c:
935 Expect to see the pattern twice.
936 * testsuite/gcc.dg/graphite/interchange-0.c: Un-XFAIL.
937 * testsuite/gcc.dg/graphite/interchange-5.c: Same.
938 * testsuite/gcc.dg/graphite/interchange-6.c: Same.
940 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
942 * testsuite/gcc.dg/graphite/id-10.c: New.
943 * testsuite/gcc.dg/graphite/id-12.c: New.
944 * testsuite/gfortran.dg/graphite/id-7.f: New.
945 * testsuite/gfortran.dg/graphite/id-8.f: New.
947 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
949 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Fix division by
952 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
954 * sese.c (rename_variables_in_stmt): Call fold_convert during renaming.
956 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
958 * sese.c (expand_scalar_variables_stmt): Avoid unnecessary expansion.
960 2009-07-10 Sebastian Pop <sebastian.pop@amd.com>
962 * graphite-sese-to-poly.c (pdr_add_memory_accesses): Fix order of
963 building PDR subscripts.
965 2009-07-10 Sebastian Pop <sebastian.pop@amd.com>
967 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Fix the
968 computation of array sizes.
970 2009-07-10 Sebastian Pop <sebastian.pop@amd.com>
972 * graphite-sese-to-poly.c (add_param_constraints): Disabled.
974 2009-07-10 Tobias Grosser <grosser@fim.uni-passau.de>
976 * graphite-dependences.c (map_into_dep_poly, map_dr_into_dep_poly,
977 build_pairwise_constraint, dr_equality_constraints,
978 build_pairwise_scheduling_equality,
979 build_pairwise_scheduling_inequality, lexicographically_gt_p,
980 build_lexicographically_gt_constraint, dependence_polyhedron,
981 graphite_legal_transform_dr, graphite_carried_dependence_level_k):
982 Move from NNC_Polyhedron to C_Polyhedron.
983 * graphite-interchange.c (compute_array_size_poly,
984 gather_access_strides): Dito.
985 * graphite-poly.c (apply_poly_transforms, new_poly_dr, free_poly_bb,
986 free_scop, pbb_number_of_iterations): Dito.
987 * graphite-poly.h (struct poly_dr, pdr_nb_subscripts, struct poly_bb,
988 pbb_dim_iter_domain, struct scop): Dito.
989 * graphite-ppl.c (new_Constraint_System_from_Cloog_Matrix,
990 new_Cloog_Domain_from_ppl_Polyhedron,
991 new_Cloog_Domain_from_ppl_Pointset_Powerset, ppl_set_coef_gmp,
992 ppl_insert_dimensions_pointset, ppl_insert_dimensions_pointset,
993 ppl_strip_loop, ppl_strip_loop, ppl_print_polyhedron_matrix,
994 ppl_print_powerset_matrix, debug_ppl_polyhedron_matrix,
995 debug_ppl_powerset_matrix, ppl_read_polyhedron_matrix): Dito.
996 * graphite-ppl.h (ppl_Pointset_Powerset_C_Polyhedron_t,
997 new_C_Polyhedron_from_Cloog_Matrix, ppl_print_powerset_matrix,
998 debug_ppl_powerset_matrix, ppl_insert_dimensions_pointset): Dito.
999 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons,
1000 build_loop_iteration_domains, ppl_constraint_type_from_tree_code,
1001 add_condition_to_domain, add_condition_to_pbb, build_scop_context,
1002 build_scop_iteration_domain, build_poly_dr): Dito
1004 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1006 * testsuite/gcc.dg/graphite/graphite.exp: Added a rule to execute
1008 * testsuite/gcc.dg/graphite/run-id-1.c: New.
1010 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1012 * graphite-sese-to-poly.c (build_loop_iteration_domains): Add the
1013 positivity constraint on the symbolic number of iterations.
1015 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1017 * graphite-sese-to-poly.c (build_loop_iteration_domains): Rewrite.
1019 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1020 Tobias Grosser <grosser@fim.uni-passau.de>
1022 * graphite-clast-to-gimple.c (build_scop_context): Removed.
1023 (build_cloog_prog): Directly use SCOP_CONTEXT.
1024 * graphite-poly.c (new_scop): Initialize SCOP_CONTEXT.
1025 (free_scop): Free SCOP_CONTEXT.
1026 (print_scop_context): New.
1027 (print_scop): Call print_scop_context.
1028 (debug_scop_context): New.
1029 * graphite-poly.h (print_scop_context, debug_scop_context): Declared.
1030 (struct scop): Added field context.
1031 (SCOP_CONTEXT): New.
1032 * graphite-sese-to-poly.c (add_param_constraints): New.
1033 (build_scop_context): New.
1034 (build_poly_scop): Call build_scop_context.
1036 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1038 * graphite-clast-to-gimple.c (gmp_cst_to_tree): Moved...
1039 * graphite-ppl.c (ppl_set_inhomogeneous_gmp, ppl_set_coef_gmp): New.
1040 (ppl_set_inhomogeneous, ppl_set_coef): Moved...
1041 * graphite-ppl.h: Include double-int.h and tree.h.
1042 (ppl_set_inhomogeneous_gmp, ppl_set_coef_gmp): Declared.
1043 (ppl_set_inhomogeneous, ppl_set_coef): ...here.
1044 (gmp_cst_to_tree): ...here. Reimplemented using mpz_get_double_int.
1045 (tree_int_to_gmp, ppl_set_inhomogeneous_tree, ppl_set_coef_tree): New.
1047 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1049 * graphite-clast-to-gimple.c (clast_to_gcc_expression_red): Generate
1050 POINTER_PLUS_EXPR for pointer types.
1051 (clast_to_gcc_expression): Same.
1053 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1055 * graphite-poly.c (print_scattering_function): Early return when
1056 PBB_TRANSFORMED_SCATTERING is not initialized.
1057 (print_pbb_domain): Early return when PBB_DOMAIN is not initialized.
1059 2009-07-08 Sebastian Pop <sebastian.pop@amd.com>
1061 * tree-parloops.c (analyze_reduction_list): Remove unused variable
1064 2009-07-08 Razya Ladelsky <razya@il.ibm.com>
1066 * tree-parloops.c (analyze_reduction_list): Change return
1068 (try_create_reduction_list): Move the call to
1069 analyze_reduction_list to the beginining.
1070 Call reduction_phi with analyzed_reductions as argument
1071 instead of reduction_list.
1073 2009-07-08 Tobias Grosser <grosser@fim.uni-passau.de>
1075 * Merge from mainline (r148296:149346)
1077 2009-07-07 Sebastian Pop <sebastian.pop@amd.com>
1079 * graphite-scop-detection.c (graphite_can_represent_init): New.
1080 (graphite_can_represent_scev): Call graphite_can_represent_init:
1081 check that the initial value does not contain multiplications of
1083 (stmt_has_simple_data_refs_p): New.
1084 (stmt_simple_for_scop_p): Call stmt_simple_for_scop_p.
1085 (is_simple_operand): Fix formatting.
1086 * graphite-sese-to-poly.c (try_generate_gimple_bb): Fix formatting.
1088 2009-07-07 Sebastian Pop <sebastian.pop@amd.com>
1090 * testsuite/gcc.dg/graphite/id-13.c: New.
1091 * graphite-sese-to-poly.c (graphite_stmt_p): Do not call
1092 analyze_scalar_evolution, use scalar_evolution_in_region.
1093 (scan_tree_for_params_right_scev): Add extra assert.
1094 (parameter_index_in_region_1): Split from parameter_index_in_region.
1095 (idx_record_params): Use scalar_evolution_in_region.
1096 (find_params_in_bb): Same.
1097 (find_scop_parameters): Same.
1098 (build_loop_iteration_domains): Same.
1099 (create_linear_expr_from_tree): Same.
1100 * sese.c (scalar_evolution_in_region): New.
1101 * sese.h (scalar_evolution_in_region): Declared.
1102 (defined_in_sese_p): New.
1103 * tree-scalar-evolution.c (compute_overall_effect_of_inner_loop): Not
1105 * tree-scalar-evolution.h (compute_overall_effect_of_inner_loop):
1108 2009-07-07 Sebastian Pop <sebastian.pop@amd.com>
1110 * Makefile.in: Replace dependences on tree-chrec.h with SCEV_H.
1111 TREE_DATA_REF_H also implies SCEV_H.
1113 2009-07-07 Sebastian Pop <sebastian.pop@amd.com>
1115 * graphite-poly.c (print_scop_params): New.
1116 (print_scop): Call print_scop_params.
1117 (debug_scop_params): New.
1118 * graphite-poly.h (print_scop_params, debug_scop_params): Declared.
1120 2009-07-07 Li Feng <nemokingdom@gmail.com>
1122 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-4.c: New.
1123 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-5.c: New.
1124 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-6.c: New.
1125 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-7.c: New.
1126 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-8.c: New.
1127 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-9.c: New.
1129 2009-07-07 Li Feng <nemokingdom@gmail.com>
1131 * graphite-clast-to-gimple.c (mark_loops_parallel): Dump information
1132 for dependency checking part.
1133 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-1.c: Add
1134 tests for dependency checking.
1135 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-2.c: Ditto.
1136 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-3.c: Ditto.
1137 * testsuite/gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: Add
1138 flag -fdump-tree-graphite-all for autopar testsuites.
1140 2009-07-06 Sebastian Pop <sebastian.pop@amd.com>
1142 * Makefile.in (tree-ssa-loop-manip.o): Depends on langhooks.h.
1143 * tree-parloops.c (rewrite_phi_with_iv, rewrite_all_phi_nodes_with_iv,
1144 canonicalize_loop_ivs): Moved...
1145 * tree-ssa-loop-manip.c: ... here. Include langhooks.h.
1147 2009-07-06 Sebastian Pop <sebastian.pop@amd.com>
1149 * tree-parloops.c (try_create_reduction_list): Pass an extra
1150 argument analyzed_reductions. Call analyze_reduction_list.
1151 (gen_parallel_loop): Do not call analyze_reduction_list.
1152 (parallelize_loops): Init and finalize analyzed_reductions.
1154 2009-07-06 Li Feng <nemokingdom@gmail.com>
1156 * testsuite/gcc.dg/graphite/graphite_autopar/graphite_autopar.exp:
1157 Added flag -fno-loop-strip-mine for autopar testcase.
1159 2009-07-04 Li Feng <nemokingdom@gmail.com>
1161 * graphite-dependences.c (graphite_carried_dependence_level_k): Use
1162 transformed scattering dimension instead of unmatch orignal when
1163 calling dependence_polyhedron.
1165 2009-06-30 Sebastian Pop <sebastian.pop@amd.com>
1167 * opts.c (decode_options): Enable flag_loop_strip_mine at -O2.
1169 2009-06-30 Sebastian Pop <sebastian.pop@amd.com>
1171 * graphite-poly.c (pbb_number_of_iterations): Check for returned
1172 value 1 from ppl_Pointset_Powerset_NNC_Polyhedron_maximize.
1174 2009-06-30 Sebastian Pop <sebastian.pop@amd.com>
1176 * graphite-blocking.c (pbb_strip_mine_profitable_p): New.
1177 (pbb_do_strip_mine): Call pbb_strip_mine_profitable_p.
1178 * graphite-poly.c (pbb_number_of_iterations): New.
1179 * graphite-poly.h (pbb_number_of_iterations): Declared.
1180 (pbb_iterator_dim, pbb_parameter_dim): New.
1182 2009-06-29 Sebastian Pop <sebastian.pop@amd.com>
1184 * graphite-clast-to-gimple.c (graphite_create_new_loop): Revert the
1185 last commit on type of lower and upper bound of loops.
1187 2009-06-29 Li Feng <nemokingdom@gmail.com>
1189 * Makefile.in (graphite-clast-to-gimple.o): Added dependence on
1190 graphite-dependences.h.
1191 * graphite-clast-to-gimple.c (new_bb_pbb_def): New.
1192 (mark_bb_with_pbb): New.
1193 (get_stmtfor_depth): New.
1194 (find_pbb_via_hash): New.
1195 (dependency_in_loop_p): New.
1196 (mark_loops_parallel): New.
1197 (free_aux_in_new_loops): New.
1198 (translate_clast): Add parameter BB_PBB_MAPPING. Mark newly created
1199 bb with it's relevant pbb. Mark newly created loops. Remove mark
1200 innermost loop parallel without checking.
1201 (gloog): Add parameter BB_PBB_MAPPING.
1202 * graphite-clast-to-gimple.h (struct bb_pbb_def): New.
1203 (gloog): Change declaration.
1204 (mark_loop_parallel): Make extern.
1205 (free_aux_in_new_loops): Declare.
1206 (bb_pbb_map_hash): New.
1207 (eq_bb_pbb_map): New.
1208 * graphite.c (graphite_transform_loops): Added BB_PBB_MAPPING. Trigger
1209 auto parallelization when flag_graphite_force_parallel is set.
1210 (graphite_finalize): Added free_aux_in_new_loops.
1211 * tree-parloops.c (parallelize_loops): Only generate parallel code for
1212 the innermost loop that marked parallel. Use
1213 flag_graphite_force_parallel instead of loop->can_be_parallel.
1214 (loop_parallel_p): Move inner most checking out of function.
1216 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
1218 * graphite-clast-to-gimple.c (graphite_create_new_loop): Make the
1219 type of lower and upper bound of loops signed long int.
1221 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
1223 * cfgloopmanip.c (create_empty_loop_on_edge): Gimplify the loop exit
1224 expression outside the loop.
1226 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
1228 * gcc.dg/graphite/interchange-8.c: New.
1230 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
1232 * gcc.dg/graphite/interchange-0.c: XFailed.
1233 * gcc.dg/graphite/interchange-5.c: XFailed.
1234 * gcc.dg/graphite/interchange-6.c: XFailed.
1236 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
1238 * graphite-interchange.c (compute_array_size_poly): The end of the
1239 recursion should return 1.
1241 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
1243 * graphite-interchange.c (compute_array_size_cstr): Allow the
1244 subscript multiplier to be -1.
1245 (compute_array_size): Use PDR_DATA_CONTAINER and not PDR_ACCESSES.
1246 * graphite-poly.c (new_poly_dr): Takes an extra argument for the
1247 data_container. Initializes PDR_DATA_CONTAINER.
1248 (print_pdr_access_layout): New.
1249 (print_pdr): Call print_pdr_access_layout. Print PDR_DATA_CONTAINER.
1250 * graphite-poly.h (struct poly_dr): Adjust comment. Add a new field
1252 (PDR_DATA_CONTAINER): New.
1253 (new_poly_dr): Update declaration.
1254 * graphite-sese-to-poly.c (pdr_add_data_dimensions): New.
1255 (build_poly_dr): Call pdr_add_data_dimensions.
1257 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
1259 * graphite-poly.h (struct poly_dr): Fix comment.
1260 * graphite-sese-to-poly.c (pdr_add_alias_set): New.
1261 (pdr_add_memory_accesses): New.
1262 (build_poly_dr): Call pdr_add_memory_accesses and pdr_add_alias_set.
1264 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
1266 * graphite-poly.c (print_pdrs, debug_pdrs): New.
1267 (print_pbb): Add call to print_pdrs.
1268 * graphite-poly.h (print_pdrs, debug_pdrs): Declared.
1270 2009-06-24 Konrad Trifunovic <konrad.trifunovic@gmail.com>
1271 Li Feng <nemokingdom@gmail.com>
1273 * graphite-dependences.c (graphite_carried_dependence_level_k): New.
1274 (dependency_between_pbbs_p): New.
1275 (lexicographically_gt_p): Assure !empty_p before polyhedron
1276 intersection assign.
1277 (build_lexicographically_gt_constraint): Correct lexicographically
1279 * graphite-dependences.h: New.
1280 * Makefile.in (graphite-dependences.o): Add graphite-dependences.h.
1282 2009-06-24 Sebastian Pop <sebastian.pop@amd.com>
1284 * graphite-clast-to-gimple.c (print_clast_stmt): New.
1285 (gloog): Print to dump_file the generated clast.
1286 * graphite-clast-to-gimple.h (print_clast_stmt): Declared.
1287 * graphite-interchange.c (pbb_do_interchange): Fix dump formatting.
1289 2009-06-24 Sebastian Pop <sebastian.pop@amd.com>
1291 * graphite-poly.c (extend_scattering): Increment
1292 PBB_NB_LOCAL_VARIABLES by the number of added dimensions.
1294 2009-06-24 Sebastian Pop <sebastian.pop@amd.com>
1296 * graphite-interchange.c (compute_array_size_poly): Added exit of
1297 recursion condition. Continue iterating even after the first equality.
1298 (compute_array_size): Same.
1300 2009-06-24 Li Feng <nemokingdom@gmail.com>
1302 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-1.c: Update
1303 -fdump-tree-final_cleanup to -fdump-tree-optimized.
1304 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-2.c: Ditto.
1305 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-3.c: Ditto.
1306 * testsuite/gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: Ditto.
1308 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
1310 * sese.c (expand_scalar_variables_stmt): Expand scalar variables
1311 only when the use verifies is_gimple_reg.
1313 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
1315 * graphite-clast-to-gimple.c (build_cloog_prog): Fix memory corruption.
1316 Allocate scaldims after call to unify_scattering_dimensions.
1318 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
1320 * graphite-clast-to-gimple.c (translate_clast): Fix memory leak.
1322 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
1323 Albert Cohen <albert.cohen@inria.fr>
1325 * graphite-blocking.c (pbb_strip_mine_loop_depth): Do not use local
1326 variables for the strip mining.
1328 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
1329 Pranav Garg <pranav.garg2107@gmail.com>
1331 * Makefile.in (OBJS-common): Added graphite-blocking.o.
1332 (graphite-sese-to-poly.o): Moved down to be in lexicographical order.
1333 (graphite-blocking.o): New rule.
1334 (graphite-poly.o, graphite-ppl.o): Moved to be in lexicographical order.
1335 * graphite-blocking.c: New.
1336 * graphite-poly.c (apply_poly_transforms): Call scop_do_strip_mine for
1337 flag_loop_strip_mine.
1338 (psct_scattering_dim_for_loop_depth): New.
1339 * graphite-poly.h (scop_do_strip_mine): Declared.
1340 (psct_add_local_variable): Increment PBB_NB_LOCAL_VARIABLES.
1341 * tree-ssa-loop.c (gate_graphite_transforms): Do not fail when using
1342 flag_loop_strip_mine.
1344 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
1346 * graphite-poly.c (extend_scattering): Avoid initializing and freeing
1347 a GMP value and a PPL coefficient at each iteration of a loop.
1349 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
1351 * graphite-dependences.c (dependence_polyhedron): Do not use
1352 pbb_nb_scattering_dims anymore. Use pbb_nb_scattering_orig and
1353 pbb_nb_scattering_transform.
1354 (graphite_legal_transform_dr): Same.
1355 * graphite-poly.c (extend_scattering): Same.
1356 (unify_scattering_dimensions): Same.
1357 (print_scattering_function): Same.
1358 (new_poly_bb): Initialize PBB_NB_SCATTERING_TRANSFORM and
1359 PBB_NB_LOCAL_VARIABLES.
1360 * graphite-poly.h (pbb_nb_scattering): Removed declaration.
1361 (struct poly_bb): Added nb_local_variables and nb_scattering_transform.
1362 (PBB_NB_LOCAL_VARIABLES, PBB_NB_SCATTERING_TRANSFORM): New.
1363 (pbb_nb_scattering_orig, pbb_nb_scattering_transform): New.
1364 (pbb_nb_scattering_dims, pbb_nb_scattering): Removed.
1365 (pbb_nb_scattering_transform): New.
1366 (pbb_nb_local_vars): Return PBB_NB_LOCAL_VARIABLES.
1367 (psco_scattering_dim): Add assert on parameters.
1368 (psct_scattering_dim): Same.
1369 (psct_scattering_dim_for_loop_depth): Declared.
1370 (psct_local_var_dim): New.
1371 (psco_iterator_dim, psco_parameter_dim): Add assert on parameters.
1372 (psct_iterator_dim, psct_parameter_dim): Same. To maintain the
1373 correct layout, call pbb_nb_local_vars.
1374 (psct_add_local_variable, psct_add_scattering_dimension): New.
1375 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons):
1376 Initialize PBB_NB_SCATTERING_TRANSFORM.
1378 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
1380 * graphite-ppl.c (set_inhomogeneous): Renamed ppl_set_inhomogeneous.
1381 (set_coef): Renamed ppl_set_coef.
1382 * graphite-ppl.h (ppl_set_inhomogeneous, ppl_set_coef): Declared.
1384 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
1386 * graphite-dependences.c (build_pairwise_scheduling_inequality): Don't
1387 test a boolean against 1.
1388 * graphite-interchange.c (pbb_interchange_loop_depths): Do not build
1389 a new polyhedron for the PBB_TRANSFORMED_SCATTERING.
1390 (pbb_do_interchange): Returns true when a transform has been performed.
1391 (scop_do_interchange): Same.
1392 * graphite-poly.c (apply_poly_transforms): Use the return value of
1393 scop_do_interchange.
1394 * graphite-poly.h (scop_do_interchange): Update declaration.
1396 2009-06-23 Tobias Grosser <grosser@fim.uni-passau.de>
1398 * graphite-clast-to-gimple.c (gloog): Reset loop->aux right
1400 * sese.c (sese_reset_aux_in_loops): New.
1401 * sese.h (sese_reset_aux_in_loops): New.
1403 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
1405 * graphite-sese-to-poly.c (scan_tree_for_params_int): Pass in the
1406 multiplier and multiply the constant by the multiplier.
1407 (scan_tree_for_params): Bound the multiplier to its MULT_EXPR.
1408 (build_poly_dr): Do not use the multiplier to define the subscript.
1410 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
1412 * graphite-poly.c (new_poly_dr): Pass an extra argument for the
1413 compiler's data reference. Initialize PDR_CDR.
1414 (print_pdr): Call dump_data_reference.
1415 * graphite-poly.h (struct poly_dr): Rename black_box into pbb.
1416 Add compiler_dr field.
1417 (PDR_BB): Renamed PDR_PBB.
1419 * graphite-sese-to-poly.c (build_poly_dr): Pass to new_poly_dr
1420 GCC's data reference representation.
1421 * tree-data-ref.c (debug_data_references, debug_data_reference): New.
1422 * tree-data-ref.h (debug_data_references, debug_data_reference): Decl.
1424 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
1426 * graphite-poly.c (print_scattering_function): Also print the layout.
1427 * graphite-poly.h (pbb_nb_local_vars): New.
1429 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
1431 * graphite-poly.c (print_pbb_domain): Also print the layout names.
1433 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
1435 * graphite-poly.c (print_pdr, debug_pdr): New.
1436 * graphite-poly.h (print_pdr, debug_pdr): Declared.
1437 (PDR_BASE): Removed.
1439 2009-06-18 Sebastian Pop <sebastian.pop@amd.com>
1441 * gcc/testsuite/gcc.dg/graphite/interchange-{1..7}.c: New avatars of
1444 2009-06-18 Sebastian Pop <sebastian.pop@amd.com>
1446 * graphite-interchange.c (compute_subscript): Allow also -1 in the
1447 subscript identification column.
1448 (pbb_do_interchange): Print to dump_file that some loops "will be
1449 interchanged". Rely on that chain of characters in the testcases.
1450 * gcc.dg/graphite/interchange-0.c: New.
1451 * gcc.dg/graphite/graphite.exp: Iterate over the testsuite
1452 interchange-*.c files and compile them with -floop-interchange.
1454 2009-06-18 Pranav Garg <pranav.garg2107@gmail.com>
1456 * graphite-interchange.c (interchange_profitable_p): Renamed
1457 pbb_interchange_profitable_p.
1459 2009-06-18 Sebastian Pop <sebastian.pop@amd.com>
1460 Harsha Jagasia <harsha.jagasia@amd.com>
1461 Pranav Garg <pranav.garg2107@gmail.com>
1463 * graphite-interchange.c (interchange_profitable_p): Make static.
1464 (pbb_interchange_loop_depths, pbb_do_interchange,
1465 scop_do_interchange): New.
1466 * graphite-poly.c (apply_poly_transforms): Call scop_do_interchange
1467 for flag_loop_interchange.
1468 * graphite-poly.h (scop_do_interchange): Declared.
1469 * tree-ssa-loop.c (gate_graphite_transforms): Do not fail when
1470 flag_loop_interchange is used.
1472 2009-06-18 Sebastian Pop <sebastian.pop@amd.com>
1474 * graphite-dependences.c (dependence_polyhedron): Update use of
1475 pbb_nb_scattering_dims.
1476 * graphite-poly.h (pbb_nb_scattering_dims): Do not pass SCOP.
1477 (pbb_nb_scattering): Update use of pbb_nb_scattering_dims.
1478 (psco_scattering_dim, psct_scattering_dim, psco_iterator_dim,
1479 psct_iterator_dim, psco_parameter_dim, psct_parameter_dim): New.
1481 2009-06-16 Sebastian Pop <sebastian.pop@amd.com>
1483 * graphite.c: Cleanup foo.
1485 2009-06-16 Sebastian Pop <sebastian.pop@amd.com>
1487 * Merge from mainline (r143684:148293).
1488 * Disabled libpcp until it gets fixed.
1490 2009-06-05 Sebastian Pop <sebastian.pop@amd.com>
1491 Harsha Jagasia <harsha.jagasia@amd.com>
1493 * graphite-interchange.c: New.
1494 * Makefile.in (graphite-interchange.o): New.
1495 * graphite-poly.h (interchange_profitable_p): Declared.
1496 * graphite-ppl.h (value_max): New.
1498 2009-06-04 Sebastian Pop <sebastian.pop@amd.com>
1500 * graphite-dependences.c (dependence_polyhedron): Use pdr_dim.
1501 * graphite-poly.h: Fix some comments.
1505 2009-06-04 Sebastian Pop <sebastian.pop@amd.com>
1508 (pdr_accessp_nb_subscripts): Renamed pdr_nb_subscripts.
1509 (pdr_accessp_nb_iterators): Renamed pdr_dim_iter_domain.
1510 (pdr_accessp_nb_params): Renamed pdr_nb_params.
1511 (pdr_accessp_alias_set_dim): Renamed pdr_alias_set_dim.
1512 (pdr_accessp_subscript_dim): Renamed pdr_subscript_dim.
1513 (pdr_accessp_iterator_dim): Renamed pdr_iterator_dim.
1514 (pdr_accessp_param_dim): Renamed pdr_parameter_dim.
1515 (pbb_nb_loops): Renamed pbb_dim_iter_domain.
1516 * graphite-clast-to-gimple.c: Same.
1517 * graphite-dependences.c: Same.
1518 * graphite-poly.c: Same.
1519 * graphite-sese-to-poly.c: Same.
1521 2009-06-03 Sebastian Pop <sebastian.pop@amd.com>
1523 * graphite-clast-to-gimple.c (build_iv_mapping): Insert full
1524 expressions for an IV rename, as returned by clast_to_gcc_expression.
1525 (copy_renames): Rename new_name to expr.
1526 * sese.c (debug_rename_elt): Same.
1529 (sese_adjust_liveout_phis): Call force_gimple_operand before using
1530 the information from the rename map.
1531 (rename_variables_in_stmt): Same.
1532 (add_loop_exit_phis): Rename new_name to expr.
1533 (insert_loop_close_phis): Same.
1534 (add_guard_exit_phis): Same. Call force_gimple_operand.
1535 * sese.h (struct rename_map_elt): Rename new_name to expr.
1536 (new_rename_map_elt): Same.
1538 2009-06-03 Sebastian Pop <sebastian.pop@amd.com>
1540 * graphite-clast-to-gimple.c (build_iv_mapping): Use set_rename.
1541 * sese.c (set_rename): Make it extern.
1542 * sese.h (set_rename): Declared.
1544 2009-06-03 Sebastian Pop <sebastian.pop@amd.com>
1546 * graphite-poly.c (extend_scattering): Free values.
1547 * graphite-ppl.c (new_Cloog_Domain_from_ppl_Pointset_Powerset):
1549 (ppl_print_powerset_matrix): Same.
1550 * graphite-scop-detection.c (free_scops_1): New.
1551 (limit_scops): Call free_scops_1.
1552 * graphite-sese-to-poly.c (build_scop_bbs_1): Free dom.
1553 (build_poly_dr): Free PPL coefficients.
1554 * tree-parloops.c (rewrite_all_phi_nodes_with_iv): Free bbs.
1556 2009-06-02 Sebastian Pop <sebastian.pop@amd.com>
1558 * graphite-dependences.c: New.
1559 * graphite-data-ref.c: Removed.
1560 * graphite-data-ref.h: Removed.
1561 * Makefile.in (graphite-data-ref.o): Removed.
1562 (graphite-dependences.o): Added.
1563 * graphite-clast-to-gimple.c: Remove dependence on graphite-data-ref.h.
1564 * graphite-poly.c: Same.
1565 Move the data dependence testing to graphite-dependences.c.
1567 2009-05-19 Tobias Grosser <grosser@fim.uni-passau.de>
1569 * graphite-scop-detection.c (graphite_can_represent_loop): Renamed
1570 from graphite_cannot_represent_loop. Code refactored.
1571 (scopdet_basic_block_info): Call graphite_can_represent_loop.
1573 2009-05-17 Li Feng <nemokingdom@gmail.com>
1575 * testsuite/gcc.dg/graphite/graphite_autopar/graphite_autopar.exp:
1576 Cover all the testcases (not only the filtered ones).
1578 2009-05-17 Tobias Grosser <grosser@fim.uni-passau.de>
1580 * graphite-scop-detection.c (stmt_simple_for_scop_p): Remove
1581 unnecessary check. Update comments. Move check for REAL_TYPE here.
1582 (harmful_stmt_in_bb): Remove checks for conditions. This is already
1583 done in (stmt_simple_for_scop_p).
1585 2009-05-14 Tobias Grosser <grosser@fim.uni-passau.de>
1587 * graphite.c (print_global_statistics): New.
1588 (print_graphite_scop_statistic): New.
1589 (print_graphite_statistics): New.
1590 (graphite_initialize, graphite_transform_loops): Print statistics.
1591 * graphite-scop-detection (build_scops): Print statistics.
1592 (print_graphite_scop_statistics): New.
1593 (print_graphite_statistics): New.
1595 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
1597 * graphite-clast-to-gimple.c (struct clast_name_index): Removed.
1598 (debug_clast_name_index): Removed.
1599 (debug_clast_name_indexes_1): Removed.
1600 (debug_clast_name_indexes): Removed.
1601 (clast_name_index_elt_info): Removed.
1602 (eq_clast_name_indexes): Removed.
1603 (clast_name_to_index): Removed.
1604 (new_clast_name_index): Removed.
1605 (save_clast_name_index): Removed.
1606 (save_var_name): Moved...
1607 (init_sese_params_index): Removed.
1608 (clast_name_to_gcc): Remove use of name_tree.
1609 (initialize_cloog_names): Same.
1610 (gloog): Do not call init_sese_params_index.
1611 * graphite-sese-to-poly.c (save_var_name): ...here.
1612 (parameter_index_in_region): New.
1613 * sese.c (new_sese): Initialize SESE_PARAMS_NAMES.
1614 (parameter_index_in_region): Removed.
1615 (is_parameter): Remove use of name_tree.
1616 * sese.h (struct name_tree): Removed.
1617 (struct sese): Remove use of name_tree. New field params_names.
1618 (SESE_PARAMS_NAMES): New.
1619 (SESE_PARAMS): Remove duplicate.
1620 (parameter_index_in_region): Removed.
1621 (sese_nb_params): Remove use of name_tree.
1622 (struct clast_name_index): New.
1623 (new_clast_name_index): New.
1624 (clast_name_to_index): New.
1625 (save_clast_name_index): New.
1626 (debug_clast_name_index): New.
1627 (debug_clast_name_indexes_1): New.
1628 (debug_clast_name_indexes): New.
1629 (clast_name_index_elt_info): New.
1630 (eq_clast_name_indexes): New.
1632 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
1634 * graphite-clast-to-gimple.c (compute_cloog_iv_types_1): Call
1635 pbb_to_depth_to_oldiv. Remove call to oldiv_for_loop.
1636 (graphite_loop_normal_form): Do not pass region. Do not
1637 initialize SESE_OLDIVS.
1638 (build_graphite_loop_normal_form): Update call to
1639 graphite_loop_normal_form.
1640 * sese.c (debug_oldivs): Removed.
1641 (new_sese): Do not initialize SESE_OLDIVS.
1642 (free_sese): Do not free SESE_OLDIVS.
1643 (oldiv_for_loop): Removed.
1644 * sese.h (struct sese): Remove old_ivs.
1645 (SESE_OLDIVS): Removed.
1646 (oldiv_for_loop): Removed.
1648 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
1650 * graphite-clast-to-gimple.c (clast_name_to_gcc): Pass newivs,
1651 remove ivstack. Remove call to loop_iv_stack_get_iv_from_name,
1652 replaced by a call to newivs_to_depth_to_newiv.
1653 (clast_to_gcc_expression): Pass newivs, remove ivstack.
1654 (clast_to_gcc_expression_red): Same.
1655 (gcc_type_for_clast_expr): Same.
1656 (gcc_type_for_clast_eq): Same.
1657 (graphite_translate_clast_equation): Same.
1658 (graphite_create_guard_cond_expr): Same.
1659 (graphite_create_new_guard): Same.
1660 (graphite_create_new_loop): Same.
1661 (build_iv_mapping): Same.
1662 (translate_clast): Same.
1664 (loop_iv_stack_patch_for_consts): Removed. *
1665 sese.c (iv_stack_entry_is_constant): Removed.
1666 (iv_stack_entry_is_iv): Removed.
1667 (loop_iv_stack_push_iv): Removed.
1668 (loop_iv_stack_insert_constant): Removed.
1669 (loop_iv_stack_pop): Removed.
1670 (loop_iv_stack_get_iv): Removed.
1671 (loop_iv_stack_get_iv_from_name): Removed.
1672 (debug_loop_iv_stack): Removed.
1673 (free_loop_iv_stack): Removed.
1674 (loop_iv_stack_remove_constants): Removed. *
1675 sese.h (iv_stack_entry_kind): Removed.
1676 (iv_stack_entry_data_union): Removed.
1677 (iv_stack_entry_struct): Removed.
1678 (iv_stack_entry_p): Removed.
1679 (debug_oldivs, debug_loop_iv_stack, loop_iv_stack_insert_constant,
1680 loop_iv_stack_get_iv_from_name, loop_iv_stack_push_iv,
1681 loop_iv_stack_get_iv, loop_iv_stack_remove_constants,
1682 loop_iv_stack_pop, free_loop_iv_stack): Removed.
1683 (gbb_loop_at_index): Fix indenting.
1684 (gbb_loop_index): Removed.
1686 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
1688 * graphite-clast-to-gimple.c (clast_name_to_gcc): Do not use strcmp.
1689 Call clast_name_to_index.
1691 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
1693 * graphite-clast-to-gimple.c (clast_name_to_gcc): Pass region,
1694 do not pass params. Get params from SESE_PARAMS.
1695 (clast_to_gcc_expression): Same.
1696 (clast_to_gcc_expression_red): Same.
1697 (gcc_type_for_clast_eq): Same.
1698 (graphite_translate_clast_equation): Same.
1699 (graphite_create_new_loop): Same.
1700 * sese.c (rename_variables_in_stmt): Fix comment.
1702 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
1704 * graphite-clast-to-gimple.c (graphite_create_new_loop): Pass
1706 Call save_clast_name_index.
1707 (translate_clast): Pass newivs_index.
1708 (gloog): Create and free newivs_index.
1710 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
1712 * graphite-clast-to-gimple.c (clast_name_index): New structure.
1713 (clast_name_index_p): New type.
1714 (debug_clast_name_index): New.
1715 (debug_clast_name_indexes_1): New.
1716 (debug_clast_name_indexes): New.
1717 (clast_name_index_elt_info): New.
1718 (eq_clast_name_indexes): New.
1719 (clast_name_to_index): New.
1720 (new_clast_name_index): New.
1721 (save_clast_name_index): New.
1722 (init_sese_params_index): New.
1723 (gloog): Call init_sese_params_index.
1724 * graphite-clast-to-gimple.h (debug_clast_name_indexes): Declared.
1725 * sese.c (new_sese): Initialize SESE_PARAMS_INDEX.
1726 (free_sese): Free SESE_PARAMS_INDEX.
1727 * sese.h (struct sese): Add params_index.
1728 (SESE_PARAMS_INDEX): New.
1730 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
1732 * graphite-clast-to-gimple.c (newivs_to_depth_to_newiv): New.
1733 (graphite_create_new_loop): Pass the newivs vector. Push the
1734 newly created IV to newivs.
1735 (translate_clast): Pass the newivs vector.
1736 (gloog): Create and destroy the newivs vector.
1738 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
1740 * graphite-clast-to-gimple.c (pbb_to_depth_to_oldiv): New.
1741 (graphite_loop_normal_form): Initialize loop->aux with the unique
1742 IV that has been created.
1744 2009-05-13 Tobias Grosser <grosser@fim.uni-passau.de>
1746 * tree-chrec.c (evolution_function_right_is_integer_cst): Allow
1747 scev with parameters in the base part. They where forbidden
1750 2009-05-11 Li Feng <nemokingdom@gmail.com>
1752 * testsuite/gcc.dg/graphite/graphite.exp: Set different default
1753 compile options by file names.
1754 * testsuite/gcc.dg/graphite/block{0-6}.c: Remove dg-option line.
1755 * testsuite/gcc.dg/graphite/id-{1-9}.c: Ditto.
1756 * testsuite/gcc.dg/graphite/scop-{0-20}.c: Ditto.
1757 * testsuite/gcc.dg/graphite/scop-matmult.c: Ditto.
1759 2009-05-08 Li Feng <nemokingdom@gmail.com>
1761 * testsuite/gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: New.
1762 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-1.c: New.
1763 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-2.c: New.
1764 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-3.c: New.
1766 2009-05-07 Tobias Grosser <grosser@fim.uni-passau.de>
1768 * graphite-scop-detection (build_scops_1): Fix little bug introduced
1771 2009-05-07 Tobias Grosser <grosser@fim.uni-passau.de>
1773 * graphite-scop-detection.c (graphite_can_represent_scev): Only
1774 allow integer constant strides.
1775 (graphite_can_represent_expr): Depend on outermost_loop.
1776 (stmt_simple_memref_p, graphite_cannot_represent_loop,
1777 harmful_stmt_in_bb, is_simple_operand, stmt_simple_for_scop_p,
1778 build_scops_1): Same.
1779 (scopdet_basic_block_info): Same and insert layered SCoP
1781 (try_generate_gimple_bb): Cleanup.
1782 (build_scops): Enable data references.
1784 * testsuite/gcc.dg/graphite/id-5.c: New.
1785 * testsuite/gcc.dg/graphite/id-9.c: New.
1786 * tree-chrec.c (evolution_function_right_is_integer_cst): New.
1787 * tree-chrec.h (evolution_function_right_is_integer_cst): New.
1789 2009-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
1791 * sese.c (expand_scalar_variables_ssa_name): Only build expressions,
1792 that we have not yet built for this SCoP.
1794 2009-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
1796 * sese.c (expand_scalar_variables_expr): Fix expand_scalar_variables
1797 for complex numbers.
1799 2009-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
1801 * graphite-ppl.c: Fix build if cloog is not available.
1803 2009-05-04 Li Feng <nemokingdom@gmail.com>
1805 * tree-parloops.c (loop_parallel_p): Remove construction of
1806 NITER and REDUCTION_LIST.
1807 (try_get_loop_niter): New.
1808 (try_create_reduction_list): New.
1809 (parallelize_loops): Bypass the failed checkings in autopar
1810 when can_be_parallel in loop structure is set to true.
1812 2009-05-01 Tobias Grosser <grosser@fim.uni-passau.de>
1814 * testsuite/gcc.dg/graphite/id-6.c: Update testcase.
1815 * testsuite/gcc.dg/graphite/scop-3.c: Dito.
1817 2009-05-01 Tobias Grosser <grosser@fim.uni-passau.de>
1819 * graphite-scop-detection.c (stmt_simple_for_scop_p):
1820 Enable EQ_EXPR and NE_EXPR again.
1822 2009-04-30 Tobias Grosser <grosser@fim.uni-passau.de>
1824 * graphite-scop-detection.c (graphite_can_represent_scev):
1825 Add check if scev is affine multivariate.
1826 (harmful_stmt_in_bb): Check if we can represent the conditions.
1827 (scopdet_basic_block_info (basic_block bb, VEC): Pass the loop to
1829 * testsuite/gcc.dg/graphite/id-7.c: New.
1831 2009-04-30 Tobias Grosser <grosser@fim.uni-passau.de>
1833 * graphite-sese-to-poly.c (bb_contains_non_iv_scalar_phi_nodes):
1834 Check all bbs in region, not only the bbs that are represented in
1836 (build_poly_scop): Add newline.
1837 * testsuite/gcc.dg/graphite/id-8.c: New.
1839 2009-04-30 Li Feng <nemokingdom@gmail.com>
1841 * cfgloop.c (alloc_loop): Initialize can_be_parallel to false
1842 when loop initialize.
1843 * cfgloop.h (struct loop): Introduce flag can_be_parallel.
1844 * common.opt: Declare flag_graphite_force_parallel.
1845 * graphite-clast-to-gimple.c (translate_clast): Mark the innermost
1847 * graphite-poly.c (apply_poly_transforms): Introduce
1848 flag_graphite_force_parallel.
1849 * tree-ssa-loop.c (gate_graphite_transforms): ditto.
1850 * toplev.c (process_options): ditto and replace a not correctly
1853 2009-04-30 Li Feng <nemokingdom@gmail.com>
1855 * graphite-clast-to-gimple.c (loop_iv_stack_patch_for_consts):
1856 Change the call of gbb_loop_at_index and/or gbb_loop_index due
1857 to the redefinition.
1858 (compute_cloog_iv_types_1): ditto.
1859 (build_iv_mapping): ditto.
1860 * graphite-sese-to-poly.c (new_gimple_bb): Remove GBB_LOOPS related
1862 (free_gimple_bb): Removed GBB_LOOPS related free part.
1863 (build_bb_loops): Removed.
1864 * sese.h (struct gimple_bb): Removed loops.
1865 (GBB_LOOPS): Removed.
1866 (gbb_loop_at_index): Instead of using GBB_LOOPS, we use sese instead.
1867 (gbb_loop_index): ditto.
1869 2009-04-24 Tobias Grosser <grosser@fim.uni-passau.de>
1871 * graphite-scop-detection.c (graphite_can_represent_scev): Do not
1872 allow non constant strides.
1873 * testsuite/gcc.dg/graphite/scop-20.c: New.
1875 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
1877 * graphite-scop-detection.c (dot_all_scops): Fix system call
1878 return value warning.
1881 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
1883 * testsuite/gcc.dg/graphite/id-6.c: Fix pattern.
1884 * testsuite/gcc.dg/graphite/scop-3.c: Same.
1886 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
1888 * graphite-poly.c (map_into_dep_poly, map_dr_into_dep_poly,
1889 build_pairwise_constraint, dr_equality_constraints,
1890 build_pairwise_scheduling_equality,
1891 build_pairwise_scheduling_inequality, lexicographically_gt_p,
1892 build_lexicographically_gt_constraint, dependence_polyhedron,
1893 graphite_legal_transform_dr, graphite_legal_transform_bb,
1894 graphite_legal_transform): New.
1895 * graphite-poly.h (graphite_legal_transform): Declared.
1896 * graphite-sese-to-poly.c (build_poly_scop): Call to
1897 graphite_legal_transform is disabled for the moment.
1899 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
1901 * graphite-poly.h (pbb_nb_scattering_dims): New.
1902 (pbb_nb_scattering): Use it.
1904 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
1906 * graphite-ppl.c (ppl_insert_dimensions_pointset): Add
1907 Pointset_Powerset version of ppl_insert_dimensions.
1908 * graphite-ppl.h (ppl_insert_dimensions_pointset): Declared.
1910 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
1912 * graphite-ppl.c (ppl_insert_dimensions): Fix formatting.
1914 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
1916 * graphite-poly.h: Fix comment.
1918 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
1920 * graphite-sese-to-poly.c (build_poly_dr): Fix data ref multiplier.
1922 2009-04-24 Tobias Grosser <grosser@fim.uni-passau.de>
1924 * sese.c (expand_scalar_variables_stmt): Only iterate over the old
1927 2009-04-24 Tobias Grosser <grosser@fim.uni-passau.de>
1929 * graphite-sese-to-poly.c (var_used_in_not_loop_header_phi_node): New.
1930 (graphite_stmt_p): Represent bbs necessary to build the phi nodes of
1933 2009-04-20 Sebastian Pop <sebastian.pop@amd.com>
1935 * graphite-scop-detection.c (stmt_simple_for_scop_p): Do not
1936 handle EQ_EXPR and NE_EXPR.
1938 2009-04-17 Tobias Grosser <grosser@fim.uni-passau.de>
1940 * graphite-poly.h (poly_dr): Fix comment.
1942 2009-04-09 Sebastian Pop <sebastian.pop@amd.com>
1943 Tobias Grosser <grosser@fim.uni-passau.de>
1945 * graphite-poly.c (new_poly_bb): Do not initialize PBB_DOMAIN
1946 with a zero dimension polyhedron.
1947 (find_scop_parameters): Move the call to scop_set_nb_params here.
1948 (build_loop_iteration_domains): Store in loop->aux the iteration
1950 (build_scop_iteration_domain): Fix PBB_DOMAIN for bbs not surrounded
1951 by any loop in scop.
1952 (build_poly_scop): Do not call scop_set_nb_params.
1954 2009-04-09 Sebastian Pop <sebastian.pop@amd.com>
1955 Tobias Grosser <grosser@fim.uni-passau.de>
1957 * graphite-sese-to-poly.c (add_condition_to_pbb): Pass code to
1958 add_condition_to_domain not GT_EXPR.
1960 2009-04-09 Tobias Grosser <grosser@fim.uni-passau.de>
1962 * graphite-ppl.c (debug_ppl_powerset_matrix): New.
1963 * graphite-ppl.h (debug_ppl_powerset_matrix): New.
1964 * graphite-sese-to-poly.c (add_condition_to_pbb): Use
1965 upper_bound_assign to calculate unions.
1966 * testsuite/gcc.dg/graphite/id-6.c: New.
1968 2009-04-09 Tobias Grosser <grosser@fim.uni-passau.de>
1970 * graphite-scop-detection.c (canonicalize_loop_closed_ssa): Do not
1971 handle abnormal edges.
1973 2009-04-09 Tobias Grosser <grosser@fim.uni-passau.de>
1975 * graphite-poly.c (new_poly_dr, free_poly_dr): New.
1976 (free_poly_bb): Also free poly_drs.
1977 * graphite-poly.h (new_poly_dr, free_poly_dr): New.
1978 (poly_dr): Polyhedron to Pointset_Powerset.
1979 (pdr_accessp_nb_subscripts): Same.
1980 * graphite-sese-to-poly.c (build_poly_dr): Same. And actually build
1983 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
1985 * graphite-clast-to-gimple.c (initialize_cloog_names): Change cloog
1986 names into more meaningful names.
1988 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
1990 * testsuite/gfortran.dg/graphite/interchange-1.c: New.
1991 * testsuite/gfortran.dg/graphite/interchange-2.c: New.
1993 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
1995 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not build
1997 * tree-parloops.c (rewrite_phi_with_iv): New.
1998 (rewrite_all_phi_nodes_with_iv): New.
1999 (canonicalize_loop_ivs): Call them.
2001 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
2003 * graphite-sese-to-poly.c (try_generate_gimple_bb): Use
2004 graphite_find_data_references_in_stmt.
2005 * tree-data-ref.c (graphite_find_data_references_in_stmt): New.
2006 * tree-data-ref.h (graphite_find_data_references_in_stmt): Declared.
2008 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
2010 * sese.c (add_loop_exit_phis): Don't fail on non SSA_NAME renames.
2012 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
2014 * graphite-sese-to-poly.c (build_scop_bbs_1): Use bb_in_sese_p
2015 instead of bb_in_region.
2016 (flag_bb_in_region): Same. Renamed flag_bb_in_sese.
2017 (build_sese_conditions): Use flag_bb_in_sese.
2018 * sese.c (register_bb_in_sese): Removed.
2019 (new_sese): Remove initialization of SESE_REGION_BBS.
2020 (free_sese): Do not free SESE_REGION_BBS.
2021 * sese.h (struct sese): Remove field region_basic_blocks.
2022 (SESE_REGION_BBS): Removed.
2023 (bb_in_sese_p): Implement in function of bb_in_region.
2025 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
2027 * graphite-scop-detection.c (limit_scops): Deal only with single exit
2030 2009-04-08 Tobias Grosser <grosser@fim.uni-passau.de>
2032 * graphite-scop-detection.c (stmt_simple_for_scop_p): Allow NE_EXPR
2034 * graphite-sese-to-poly.c (create_linear_expr_from_tree): New.
2035 (add_condition_to_domain): New.
2036 (add_condition_to_pbb): New.
2037 (add_conditions_to_domain): Cleanup and handle of NE_EXPR and EQ_EXPR.
2038 * testsuite/gcc.dg/graphite/scop-3.c: Update number of detected SCoPs.
2040 2009-04-08 Tobias Grosser <grosser@fim.uni-passau.de>
2042 * graphite-clast-to-gimple.c (build_cloog_prog): ppl_Polyhedron ->
2043 ppl_Pointset_Powerset.
2044 * graphite-poly.c (new_poly_bb, free_poly_bb): Same.
2045 * graphite-poly.h (poly_bb): poly_bb.domain Same.
2046 (pbb_nb_loops): Same.
2047 * graphite-sese-to-poly.c (build_loop_iteration_domains,
2048 add_conditions_to_domain): Same.
2049 * graphite-ppl.c (new_Cloog_Domain_from_ppl_Pointset_Powerset): New.
2050 (ppl_print_polyhedron_matrix): ppl_Polyhedron_t ->
2051 ppl_const_Polyhedron_t.
2052 (ppl_print_powerset_matrix): New.
2053 * graphite-ppl.h (new_Cloog_Domain_from_ppl_Pointset_Powerset,
2054 ppl_print_powerset_matrix): New.
2055 (ppl_print_polyhedron_matrix): Updated.
2057 2009-04-07 Sebastian Pop <sebastian.pop@amd.com>
2059 * tree-scalar-evolution.c (analyze_scalar_evolution_1): Fix comment.
2061 2009-04-07 Sebastian Pop <sebastian.pop@amd.com>
2063 * graphite-poly.c (extend_scattering): Fix indenting. Free cstr.
2064 (print_iteration_domains, debug_iteration_domain,
2065 debug_iteration_domains): New.
2066 * graphite-poly.h (print_iteration_domains, debug_iteration_domain,
2067 debug_iteration_domains): Declared.
2068 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons): Fix
2071 2009-04-03 Tobias Grosser <grosser@fim.uni-passau.de>
2072 Sebastian Pop <sebastian.pop@amd.com>
2074 * graphite-poly.h (print_iteration_domain): New.
2075 * graphite-sese-to-poly.c (add_conditions_to_domain): Fixed bug.
2076 (build_sese_conditions_1, build_sese_conditions_after,
2077 build_sese_conditions_before): New.
2078 (build_sese_conditions): Rewritten.
2080 2009-04-03 Sebastian Pop <sebastian.pop@amd.com>
2081 Tobias Grosser <grosser@fim.uni-passau.de>
2083 Cleanup of code generation liveouts.
2084 * graphite-clast-to-gimple.c (translate_clast): Use a single
2085 rename_map instead of one per translated statement.
2086 Do not use SESE_LIVEOUT_RENAMES.
2087 (graphite_loop_normal_form): Do not use SESE_REDUCTION_LIST.
2088 (gloog): Do not use SESE_LIVEOUT_RENAMES.
2089 * graphite-scop-detection.c (harmful_stmt_in_bb): Return the close
2090 phi node of a reduction: when a loop contains a reduction used outside
2091 the loop, there should be a scalar close phi node on the exit block.
2092 * sese.c (new_sese): Do not initialize SESE_LIVEOUT,
2093 SESE_LIVEOUT_RENAMES, and SESE_REDUCTION_LIST.
2094 (free_sese): Do not free them.
2095 (sese_build_liveouts_use): Do not use them.
2096 (sese_build_liveouts_bb): Same.
2097 (sese_build_liveouts): Same.
2098 (sese_insert_phis_for_liveouts): Same.
2099 (sese_adjust_phis_for_liveouts): Same. Renamed sese_adjust_liveout_phis.
2100 (defined_in_loop_p): New.
2101 (alive_after_loop): New.
2102 (close_phi_not_yet_inserted_p): New.
2103 (struct alep, alep_p): New.
2104 (add_loop_exit_phis): Remove from the rename_map all the names defined
2105 in the code generated loop.
2106 (insert_loop_close_phis): Traverse the rename_map passed to it.
2107 Don't use SESE_LIVEOUT_RENAMES.
2108 (default_liveout_before_guard): Renamed default_before_guard.
2109 (insert_guard_phis): Do not use SESE_LIVEOUT_RENAMES.
2110 (graphite_copy_stmts_from_block): Do not directly call set_rename.
2111 (register_sese_liveout_renames): Removed.
2112 (copy_bb_and_scalar_dependences): Do not call it.
2113 * sese.h (struct sese): Removed fields: liveout, liveout_renames, and
2115 (SESE_LIVEOUT): Removed.
2116 (SESE_LIVEOUT_RENAMES): Removed.
2117 (SESE_REDUCTION_LIST): Removed.
2118 (sese_build_liveouts): Removed.
2119 (sese_adjust_phis_for_liveouts): Renamed sese_adjust_liveout_phis.
2120 (insert_loop_close_phis): Pass a htab_t instead of a sese.
2121 (insert_guard_phis): Same.
2122 (rename_map_elt): Declare a VEC of them.
2123 * tree-parloops.c (canonicalize_loop_ivs): reduction_list contains
2124 trees not pointers to trees.
2126 Rewrite in canonical close SSA form:
2127 * graphite-scop-detection.c (contains_only_close_phi_nodes): New.
2128 (limit_scops): Close the scop after the block containing the close phi
2130 (canonicalize_loop_closed_ssa): New.
2131 (canonicalize_loop_closed_ssa_form): New.
2132 (build_scops): Call canonicalize_loop_closed_ssa_form.
2134 * graphite-sese-to-poly.c: Fix typos.
2136 2009-04-03 Sebastian Pop <sebastian.pop@amd.com>
2138 * graphite-poly.c (print_scattering_function, print_pbb_domain):
2140 (dump_gbb_conditions, dump_gbb_cases, print_iteration_domain): New.
2141 (print_pbb): Add conditions.
2143 2009-04-01 Tobias Grosser <grosser@fim.uni-passau.de>
2144 Sebastian Pop <sebastian.pop@amd.com>
2146 * graphite-scop-detection.c (bb_in_sd_region): Use bb_in_region.
2147 * graphite-sese-to-poly.c (all_non_dominated_preds_marked_p): New.
2148 (build_scop_bbs_1): New.
2149 (build_scop_bbs): Rewrite.
2150 * sese.h (bb_in_region): New.
2152 2009-03-29 Tobias Grosser <grosser@fim.uni-passau.de>
2154 * graphite-poly.c (new_poly_bb, free_poly_bb): Initialize/free
2156 (print_scop): Style.
2157 * graphite-poly.h (poly_bb): Add drs vector.
2158 (PBB_DRS): Add accessor.
2159 * graphite-sese-to-poly.c (build_poly_dr): New.
2160 (build_pbb_drs, build_scop_drs): New.
2161 (build_poly_scop): call build_scop_drs (Disabled at the moment).
2163 2009-03-29 Tobias Grosser <grosser@fim.uni-passau.de>
2165 * tree-ssa-loop.c: Include forgotten toplev.h
2167 2009-03-29 Tobias Grosser <grosser@fim.uni-passau.de>
2169 * graphite-poly.c: (apply_poly_transforms): sorry -> gcc_unreachable.
2170 * testsuite/gcc.dg/graphite/pr37883.c: Remove -floop-*
2171 * testsuite/gcc.dg/graphite/pr37928.c: Same
2172 * testsuite/gcc.dg/graphite/pr38409.c: Same
2173 * testsuite/gcc.dg/graphite/pr38498.c: Same
2174 * testsuite/gcc.dg/graphite/pr38559.c: Same
2175 * testsuite/gcc.dg/graphite/pr39335.c: Same
2176 * testsuite/gcc.dg/graphite/pr39335_1.c: Same
2177 * testsuite/gfortran.dg/graphite/block-2.f: Same
2178 * tree-ssa-loop.c (gate_graphite_transforms): Always fail if called
2181 2009-03-28 Tobias Grosser <grosser@fim.uni-passau.de>
2183 * graphite-sese-to-poly.c (ref_nb_loops, build_access_matrix_with_af,
2184 build_access_matrix, build_scop_data_accesses): Remove access function
2185 building. (We get a new version soon).
2186 (build_bb_loops, scan_tree_for_params_right_scev): Update.
2187 * sese.h (nb_loops_around_loop_in_sese): Remove.
2188 (sese_loop_depth): Do not use SESE_LOOP_NEST any more.
2190 2009-03-27 Tobias Grosser <grosser@fim.uni-passau.de>
2191 Sebastian Pop <sebastian.pop@amd.com>
2193 * graphite-scop-detection.c (struct scopdet_info): Rename last
2195 (scopdet_basic_block_info, build_scops_1): Don't use
2196 CDI_POST_DOMINATORS. CDI_POST_DOMINATORS should never be used.
2198 2009-03-26 Tobias Grosser <grosser@fim.uni-passau.de>
2199 Sebastian Pop <sebastian.pop@amd.com>
2201 * graphite-clast-to-gimple.c (gloog): Call sese_build_liveouts.
2202 * sese.c (sese_build_liveouts_use): Renamed from
2203 sese_build_livein_liveouts_use. Remove liveins.
2204 (sese_build_liveouts_bb): Renamed from sese_build_livein_liveouts_bb.
2205 Call sese_build_liveouts_use.
2206 (sese_build_liveouts): Renamed from sese_build_livein_liveouts.
2207 Call sese_build_liveouts_bb.
2208 (new_sese, free_sese): Remove liveins.
2209 (sese_add_exit_phis_var): Deleted.
2210 (sese_insert_phis_for_liveouts): Call sese_add_exit_phis_edge
2212 (graphite_copy_stmts_from_block): Remove SESE_NUM_VER.
2214 * sese.h (sese): Remove num_ver and livein.
2215 (SESE_LIVEIN, SESE_LIVEIN_VER, SESE_NUM_VER): Removed.
2217 2009-03-25 Tobias Grosser <grosser@fim.uni-passau.de>
2219 * graphite-sese-to-poly.c (build_scop_scattering): Fix compile.
2221 2009-03-25 Tobias Grosser <grosser@fim.uni-passau.de>
2223 * graphite-sese-to-poly.c (compare_prefix_loops): Removed.
2224 (build_scop_scattering): Do not use compare_prefix_loops any more.
2225 (nb_common_loops): New.
2227 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
2229 * sese.c (get_new_name_from_old_name): Renamed get_rename.
2230 (register_old_and_new_names): Renamed set_rename.
2232 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
2234 * graphite-scop-detection.h (nb_reductions_in_loop): Revert removal
2235 of the decl from the previous commit.
2237 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
2239 * graphite-scop-detection.c (dot_scop): New.
2240 * graphite-scop-detection.h (dot_scop): Declared.
2242 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
2244 * graphite-sese-to-poly.c (compare_prefix_loops): Fix compare.
2246 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
2248 * cfgloopmanip.c (create_empty_loop_on_edge): Generate the loop exit
2249 condition at the end of the loop.
2250 * graphite.c (graphite_initialize, graphite_finalize): Print to
2251 dump_file the compiled function.
2252 * graphite-clast-to-gimple.c (graphite_create_new_loop): Update use
2253 of create_empty_loop_on_edge.
2254 (translate_clast): Update the code generation of loops for the new
2256 * cfgloop.h (create_empty_loop_on_edge): Update declaration.
2258 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
2260 Reverted the patch from 2009-03-19.
2262 2009-03-19 Tobias Grosser <grosser@fim.uni-passau.de>
2264 * graphite-poly.c (new_poly_bb, free_poly_bb): Initialize/free
2266 (print_scop): Style.
2267 * graphite-poly.h (poly_bb): Add drs vector.
2268 (PBB_DRS): Add accessor.
2269 * graphite-sese-to-poly.c (ref_nb_loops): Remove.
2270 (build_access_matrix_with_af, build_access_matrix,
2271 build_scop_data_accesses): Delete.
2272 (build_poly_dr): New.
2273 (build_pbb_drs, build_scop_drs): New.
2274 (build_poly_scop): call build_scop_drs.
2276 2009-03-13 Sebastian Pop <sebastian.pop@amd.com>
2278 * graphite-scop-detection.c (dot_all_scops_1): Close the table
2279 once per basic block.
2281 2009-03-13 Tobias Grosser <grosser@fim.uni-passau.de>
2283 * graphite-scop-detection.c (graphite_can_represent_scev): New.
2284 (graphite_can_represent_expr): Renamed from loop_affine_expr
2286 (stmt_simple_for_scop_p): Call graphite_can_represent_expr.
2287 (graphite_cannot_represent_loop): Add scop_entry to parameters.
2288 (scopdet_basic_block_info): Actually define entry_block.
2289 (stmt_simple_memref_p): Moved here from ...
2291 * tree-data-ref.c (stmt_simple_memref_p): here.
2292 * tree-data-ref.h (stmt_simple_memref_p): Removed.
2294 2009-03-13 Tobias Grosser <grosser@fim.uni-passau.de>
2296 * testsuite/gcc.dg/graphite/id-4.c: New.
2298 2009-03-12 Sebastian Pop <sebastian.pop@amd.com>
2300 * sese.c (expand_scalar_variables_expr): Handle tcc_comparison.
2301 (register_old_and_new_names): Update the content of the map.
2302 When there was already a rename_map_elt in the map at that
2304 (copy_bb_and_scalar_dependences): Do rename_variables after
2305 expand_scalar_variables.
2306 * graphite-clast-to-gimple.c (build_iv_mapping): Update the content
2307 of the map. When there was already a rename_map_elt in the
2308 map at that location, free it.
2309 (translate_clast): Pass the rename_map. Do not initialize and free
2310 a rename_map per stmt_user.
2311 (gloog): Initialize and free one rename_map and pass it to
2314 2009-03-12 Sebastian Pop <sebastian.pop@amd.com>
2316 * sese.c (expand_scalar_variables_stmt,
2317 expand_scalar_variables_ssa_name): Add a gimple_stmt_iterator
2319 (expand_scalar_variables_expr): Handle REALPART_EXPR and IMAGPART_EXPR.
2320 (expand_scalar_variables): Pass to expand_scalar_variables_stmt
2321 the gimple_stmt_iterator of the statement to be expanded.
2322 * graphite-scop-detection.c (is_simple_operand): Do handle
2325 2009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
2327 * graphite-scop-detection.c (is_simple_operand): Do not handle
2329 * testsuite/gcc.dg/graphite/id-2.c: New.
2331 * graphite-sese-to-poly.c (build_bb_loops,
2332 add_value_to_dim, scan_tree_for_params_right_scev,
2333 scan_tree_for_params_int, scan_tree_for_params, idx_record_params,
2334 find_params_in_bb, build_loop_iteration_domains,
2335 add_conditions_to_domain): Remove subtract.
2337 2009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
2339 * graphite-clast-to-gimple.c (loop_iv_stack_patch_for_consts,
2340 build_iv_mapping, compute_cloog_iv_types_1, build_cloog_prog):
2341 pbb_loop_at_index -> gbb_loop_at_index.
2342 * graphite-poly.c (new_poly_bb, new_scop): New accessors.
2343 (debug_loop_vec): Delete.
2344 * graphite-poly.h (poly_bb, scop): Change black_box and region to void
2345 pointer. Move LOOPS to gimple_bb_p and insert nb_params.
2346 (PBB_LOOPS): Removed.
2347 (PBB_BLACK_BOX): Insert cast.
2348 (pbb_set_black_box): New setter.
2349 (pbb_loop_at_index, pbb_loop_index): Removed.
2350 (scop_set_region, scop_set_nb_params): New.
2351 * graphite-sese-to-poly.c (new_gimple_bb, free_gimple_bb,
2352 build_scop_scattering, build_bb_loops): Add GBB_LOOPS.
2353 (build_poly_scop): Use scop_set_nb_params.
2354 * sese.h (gimple_bb): Add LOOPS.
2355 (GBB_LOOPS, gbb_loop_index, gbb_loop_at_index): New.
2357 2009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
2359 Revert previous commit.
2361 2009-03-11 Sebastian Pop <sebastian.pop@amd.com>
2363 * sese.c (expand_scalar_variables_expr): Handle tcc_comparison.
2364 (register_old_and_new_names): Update the content of the map.
2365 When there was already a rename_map_elt in the map at that
2367 (copy_bb_and_scalar_dependences): Do rename_variables after
2368 expand_scalar_variables.
2369 * graphite-clast-to-gimple.c (build_iv_mapping): Update the content
2370 of the map. When there was already a rename_map_elt in the
2371 map at that location, free it.
2372 (translate_clast): Pass the rename_map. Do not initialize and free
2373 a rename_map per stmt_user.
2374 (gloog): Initialize and free one rename_map and pass it to
2377 2009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
2379 Remove forgotten line in revert.
2381 2009-03-11 Sebastian Pop <sebastian.pop@amd.com>
2383 Revert previous commit.
2385 2009-03-10 Sebastian Pop <sebastian.pop@amd.com>
2387 * sese.c (register_old_and_new_names): Update the content
2388 of the map. When there was already a rename_map_elt in the
2389 map at that location, free it.
2390 (copy_bb_and_scalar_dependences): Do rename_variables after
2391 expand_scalar_variables.
2392 * graphite-clast-to-gimple.c (build_iv_mapping): Update the content
2393 of the map. When there was already a rename_map_elt in the
2394 map at that location, free it.
2395 (translate_clast): Pass the rename_map. Do not initialize and free
2396 a rename_map per stmt_user.
2397 (gloog): Initialize and free one rename_map and pass it to
2400 2009-03-10 Sebastian Pop <sebastian.pop@amd.com>
2402 * graphite-clast-to-gimple.c (translate_clast): context_loop
2405 2009-03-10 Tobias Grosser <grosser@fim.uni-passau.de>
2406 Sebastian Pop <sebastian.pop@amd.com>
2408 * graphite-ppl.c (ppl_insert_dimensions): Fix stupid mistake
2409 of the use of ppl_Polyhedron_map_space_dimensions.
2411 2009-03-10 Tobias Grosser <grosser@fim.uni-passau.de>
2412 Sebastian Pop <sebastian.pop@amd.com>
2414 * graphite-poly.c (unify_scattering_dimensions): Fix types.
2415 * graphite-poly.h (poly_dr_p, poly_dr, POLY_DR_TYPE, PDR_BB,
2416 PDR_TYPE, PDR_ACCESSES, pdr_accessp_nb_subscripts,
2417 pdr_accessp_nb_iterators, pdr_accessp_nb_params,
2418 pdr_accessp_alias_set_dim, pdr_accessp_subscript_dim,
2419 pdr_accessp_iterator_dim, pdr_accessp_param_dim,
2420 pbb_nb_params): New.
2421 (pbb_nb_loops, pbb_nb_scattering, scop_nb_params,
2422 nb_loops_around_pbb): Adapt return types.
2424 2009-03-09 Tobias Grosser <grosser@fim.uni-passau.de>
2426 * Makefile.in (graphite.o, graphite-sese-to-poly.o,
2427 graphite-clast-to-gimple.o, graphite-data-ref.o,
2428 graphite-scop-detection.o, graphite-poly.o): Add
2431 2009-03-05 Tobias Grosser <grosser@fim.uni-passau.de>
2433 * Makefile.in (graphite.o, graphite-sese-to-poly.o,
2434 graphite-clast-to-gimple.o, graphite-data-ref.o,
2435 graphite-scop-detection.o, graphite-poly.o): Add graphite-poly.h.
2437 2009-03-04 Tobias Grosser <grosser@fim.uni-passau.de>
2439 * testsuite/gcc.dg/graphite/pr37485.c: Remove -floop-block
2440 * testsuite/gcc.dg/graphite/pr37828.c: Same.
2441 * testsuite/gcc.dg/graphite/pr37684.c: Same.
2442 * testsuite/gcc.dg/graphite/block-0.c: Same.
2443 * testsuite/gcc.dg/graphite/block-1.c: Same.
2444 * testsuite/gcc.dg/graphite/block-2.c: Same.
2445 * testsuite/gcc.dg/graphite/block-3.c: Same.
2446 * testsuite/gcc.dg/graphite/block-4.c: Same.
2447 * testsuite/gcc.dg/graphite/block-5.c: Same.
2448 * testsuite/gcc.dg/graphite/block-6.c: Same.
2449 * testsuite/gfortran.dg/graphite/pr38083.f90: Same.
2450 * testsuite/gfortran.dg/graphite/block-1.f90: Same.
2451 * testsuite/gfortran.dg/graphite/block-3.f90: Same.
2452 * testsuite/gfortran.dg/graphite/pr37852.f90: Same.
2453 * testsuite/gfortran.dg/graphite/block-4.f90: Same.
2454 * testsuite/gfortran.dg/graphite/pr37980.f90: Same.
2455 * testsuite/gfortran.dg/graphite/pr38953.f90: Same.
2456 * testsuite/gfortran.dg/graphite/pr37857.f90: Same.
2457 * opts.c: Remove -floop-block from -O2.
2458 * graphite-poly.c: Fail if -floop-block -floop-interchange or
2459 -floop-strip-mine are used.
2461 2009-03-04 Tobias Grosser <grosser@fim.uni-passau.de>
2462 Sebastian Pop <sebastian.pop@amd.com>
2464 * graphite-clast-to-gimple.c (build_cloog_prog): Unify scattering
2466 * graphite-poly.c (pbb_compare, graphite_sort_pbbs,
2467 graphite_trans_bb_move_loop, graphite_trans_bb_strip_mine,
2468 strip_mine_profitable_p, is_interchange_valid,
2469 graphite_trans_bb_block, graphite_trans_loop_block,
2470 graphite_trans_scop_block): Temporary removed.
2471 (extend_scattering, unify_scattering_dimensions): New.
2472 (print_scattering_function, graphite_read_transforms):
2473 PBB_SCATTERING -> PBB_TRANSFORMED_SCATTERING.
2474 (graphite_generate_scattering_fns): Removed.
2475 (apply_poly_transforms): Cleanup.
2476 (free_poly_bb): Add PBB_SCATTERING -> PBB_TRANSFORMED_SCATTERING.
2477 (schedule_to_scattering): Moved.
2478 (PBB_STATIC_SCHEDULE, PBB_SCATTERING): Removed.
2479 (PBB_ORIGINAL_SCATTERING, PBB_TRANSFORMED_SCATTERING): New.
2480 (pbb_nb_scattering): New.
2481 (SCOP_ENTRY, SCOP_EXIT, SCOP_REGION_BBS, SCOP_DEP_GRAPH, SCOP_PARAMS,
2482 SCOP_LOOP_NEST, SCOP_PARAMS, SCOP_OLDIVS, SCOP_LIVEOUT_RENAMES):
2484 * graphite-ppl.c (ppl_insert_dimensions): Extended and renamed from
2486 (ppl_strip_loop): PBB_SCATTERING -> PBB_TRANSFORMED_SCATTERING.
2487 * graphite-scop-detection.c (dot_all_scops_1): PBB_SCATTERING
2488 -> PBB_TRANSFORMED_SCATTERING.
2489 * graphite-sese-to-poly.c (build_scop_bbs): Remove region.
2490 (build_pbb_scattering_polyhedron): Moved from schedule_to_scattering.
2491 (build_scop_scattering): Renamed from build_scop_canonical_schedules.
2492 (check_poly_representation): Do not return bool.
2493 (graphite_transform_loops): Reformat.
2494 * sese.h (SESE_ENTRY_BB, SESE_EXIT_BB): New.
2496 2009-03-04 Sebastian Pop <sebastian.pop@amd.com>
2498 * graphite-poly.c (print_pbb_domain, print_pbb, print_scop,
2499 debug_pbb_domain, debug_pbb, debug_scop): New.
2500 * graphite-poly.h (print_pbb_domain, print_pbb, print_scop,
2501 debug_pbb_domain, debug_pbb, debug_scop): Declared.
2503 2009-03-02 Sebastian Pop <sebastian.pop@amd.com>
2506 * tree-parloops.c (canonicalize_loop_ivs): Call fold_convert
2507 when the type precision of the induction variable should be
2508 larger than the type precision of nit.
2509 (gen_parallel_loop): Update use of canonicalize_loop_ivs.
2510 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Same.
2511 * tree-flow.h (canonicalize_loop_ivs): Update declaration.
2513 * testsuite/gcc.dg/graphite/pr39335_1.c: New.
2514 * testsuite/gcc.dg/graphite/pr39335.c: New.
2516 2009-03-02 Sebastian Pop <sebastian.pop@amd.com>
2518 * tree-parloops.c (canonicalize_loop_ivs): reduction_list contains
2519 SSA_NAMES not struct reduction_info.
2521 2009-03-02 Sebastian Pop <sebastian.pop@amd.com>
2523 * sese.c (expand_scalar_variables_expr): Handle ADDR_EXPR.
2525 2009-02-27 Sebastian Pop <sebastian.pop@amd.com>
2526 Tobias Grosser <grosser@fim.uni-passau.de>
2528 * sese.c (new_sese): Initialize SESE_REDUCTION_LIST.
2529 (free_sese): Free SESE_REDUCTION_LIST.
2530 * sese.h (struct sese): Add field reduction_list.
2531 (SESE_REDUCTION_LIST): New.
2532 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Call
2533 canonicalize_loop_ivs on SESE_REDUCTION_LIST.
2535 2009-02-27 Sebastian Pop <sebastian.pop@amd.com>
2536 Tobias Grosser <grosser@fim.uni-passau.de>
2538 * tree-flow.h (gather_scalar_reductions): Use struct loop * instead
2541 2009-02-27 Sebastian Pop <sebastian.pop@amd.com>
2542 Tobias Grosser <grosser@fim.uni-passau.de>
2544 * tree-parloops.c (struct brli, build_reduction_list_info,
2545 analyze_reduction_list, gather_scalar_reductions): New.
2546 (loop_parallel_p): Build a reduction list containing only
2547 PHI_RESULT SSA_NAMEs: call gather_scalar_reductions.
2548 (gen_parallel_loop): Call the analysis analyze_reduction_list.
2549 (parallelize_loops): Now reduction_list is a htab_t of SSA_NAMEs.
2550 * tree-flow.h (gather_scalar_reductions): Declared.
2552 2009-02-26 Sebastian Pop <sebastian.pop@amd.com>
2555 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not call
2556 number_of_iterations_exit from a gcc_assert.
2558 2009-02-25 Sebastian Pop <sebastian.pop@amd.com>
2559 Jan Sjodin <jan.sjodin@amd.com>
2561 * output.h (graphite_out_file, graphite_in_file): Declared.
2562 * toplev.c (graphite_out_file, graphite_in_file): New.
2563 (init_asm_output): Initialize graphite_in_file and graphite_out_file.
2564 * graphite-clast-to-gimple.c (build_cloog_prog): Read PBB_SCATTERING.
2565 Don't call schedule_to_scattering.
2566 * common.opt (fgraphite-write, fgraphite-read): New.
2567 * graphite-poly.c: Include output.h.
2568 (print_scattering_function, print_scattering_functions,
2569 debug_scattering_function, debug_scattering_functions,
2570 graphite_write_transforms, graphite_read_transforms,
2571 graphite_generate_scattering_fns): New.
2572 (apply_poly_transforms): Do not apply transform if flag_graphite_read.
2573 Call graphite_generate_scattering_fns, graphite_write_transforms,
2574 graphite_read_transforms.
2575 (new_poly_bb): Initialize PBB_SCATTERING.
2576 (free_poly_bb): Free PBB_SCATTERING.
2577 (schedule_to_scattering): Does not return, initialize PBB_SCATTERING.
2578 * graphite-poly.h (struct poly_bb): Add field scattering.
2579 (PBB_SCATTERING): New.
2580 (print_scattering_function, print_scattering_functions,
2581 debug_scattering_function, debug_scattering_functions): Declared.
2582 * graphite-ppl.c (cloog_matrix_to_ppl_constraint): Matrices contain
2583 GMP values, not integers!
2584 (ppl_print_polyhedron_matrix, debug_ppl_polyhedron_matrix,
2585 ppl_read_polyhedron_matrix): New.
2586 * graphite-ppl.h (ppl_print_polyhedron_matrix,
2587 debug_ppl_polyhedron_matrix,
2588 ppl_read_polyhedron_matrix): Declared.
2589 * Makefile.in (graphite-poly.o): Depends on output.h.
2591 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
2592 Tobias Grosser <grosser@fim.uni-passau.de>
2595 * graphite-scop-detection.c (stmt_simple_for_scop_p): Analyze
2596 scalar evolutions in the scop_entry->loop_father.
2598 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
2599 Tobias Grosser <grosser@fim.uni-passau.de>
2601 * graphite.h (ref_nb_loops): Remove declaration.
2602 (struct gimple_bb, gimple_bb_p, GBB_BB, GBB_DATA_REFS, GBB_CONDITIONS,
2603 GBB_CONDITION_CASES, GBB_CLOOG_IV_TYPES, gbb_loop, print_gimple_bb,
2604 debug_gbb): Moved to sese.h.
2607 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
2608 Tobias Grosser <grosser@fim.uni-passau.de>
2610 * graphite-data-ref.[ch]: Disable.
2612 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
2613 Tobias Grosser <grosser@fim.uni-passau.de>
2615 * graphite-scop-detection.c (stmt_simple_for_scop_p): Analyze
2616 scalar evolutions in the scop_entry->loop_father.
2618 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
2620 * graphite-scop-detection.c (nb_reductions_in_loop): Moved here...
2621 (graphite_cannot_represent_loop_niter): Renamed
2622 graphite_cannot_represent_loop. Call nb_reductions_in_loop.
2623 (limit_scops): build_sese_loop_nests does not return a bool.
2624 * graphite-scop-detection.h (nb_reductions_in_loop): Declared.
2625 * sese.c (nb_reductions_in_loop): ... from here.
2626 (graphite_loop_normal_form): ... from here.
2627 (sese_record_loop): Does not fail, so does not return a bool.
2628 (build_sese_loop_nests): Same.
2629 * sese.h (build_sese_loop_nests): Update declaration.
2630 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Moved here...
2631 (build_graphite_loop_normal_form): New.
2632 (gloog): Call build_graphite_loop_normal_form.
2633 * graphite-sese-to-poly.c (build_poly_scop): Don't fail on
2634 build_sese_loop_nests.
2636 * testsuite/gcc.dg/graphite/id-1.c: New.
2638 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
2639 Tobias Grosser <grosser@fim.uni-passau.de>
2641 * graphite-sese-to-poly.c (scan_tree_for_params): Remove REAL_CST.
2642 The SCoP detection fix is sufficient.
2644 2009-02-21 Sebastian Pop <sebastian.pop@amd.com>
2646 PR tree-optimization/39260
2647 * graphite-scop-detection.c (harmful_stmt_in_bb): Stop a SCoP when
2648 the basic block contains a condition with a real type.
2649 * graphite-sese-to-poly.c (scan_tree_for_params): Handle REAL_CST.
2651 * gcc.dg/graphite/pr39260.c: New.
2653 2009-02-21 Sebastian Pop <sebastian.pop@amd.com>
2655 * graphite-poly.c: Inlcude params.h.
2656 (graphite_trans_loop_block): Use PARAM_LOOP_BLOCK_TILE_SIZE for
2658 * Makefile.in (graphite-poly.o): Depend on PARAMS_H.
2659 * params.def (PARAM_LOOP_BLOCK_TILE_SIZE): Define.
2661 2009-02-20 Sebastian Pop <sebastian.pop@amd.com>
2662 Tobias Grosser <grosser@fim.uni-passau.de>
2664 * graphite-scop-detection.c (dot_all_scops_1,
2665 dot_all_scops): Moved here.
2666 * graphite-scop-detection.h (dot_all_scops): Declared here.
2667 * graphite.c (graphite_initialize, graphite_finalize): New.
2668 (graphite_transform_loops): Cleaned up.
2669 * sese.c (debug_oldivs): Moved here.
2670 * graphite-poly.c (graphite_apply_transformations): Renamed
2671 apply_poly_transforms.
2672 (debug_loop_vec): Moved here.
2673 * graphite-sese-to-poly.c (build_bb_loops, build_sese_conditions_1,
2674 scop_contains_non_iv_scalar_phi_nodes, build_sese_conditions,
2675 find_scop_parameters, build_scop_iteration_domain,
2676 add_conditions_to_constraints, build_scop_canonical_schedules,
2677 build_scop_data_accesses): Now static.
2678 (build_poly_scop, check_poly_representation): New.
2680 2009-02-20 Sebastian Pop <sebastian.pop@amd.com>
2682 * graphite.c (graphite_stmt_p, new_gimple_bb, free_gimple_bb,
2683 remove_gbbs_in_scop, free_scops, try_generate_gimple_bb,
2684 build_scop_bbs, ref_nb_loops, compare_prefix_loops,
2685 build_scop_canonical_schedules, build_bb_loops, add_value_to_dim,
2686 scan_tree_for_params_right_scev, scan_tree_for_params_int,
2687 scan_tree_for_params, struct irp_data, dx_record_params,
2688 find_params_in_bb, find_scop_parameters, gbb_from_bb,
2689 build_loop_iteration_domains, add_conditions_to_domain,
2690 phi_node_is_iv, bb_contains_non_iv_scalar_phi_nodes,
2691 scop_contains_non_iv_scalar_phi_nodes, build_sese_conditions_1,
2692 build_sese_conditions, add_conditions_to_constraints,
2693 build_scop_iteration_domain, build_access_matrix_with_af,
2694 build_access_matrix,
2695 build_scop_data_accesses): Moved to graphite-sese-to-poly.c.
2697 * graphite-sese-to-poly.c: New.
2698 * graphite-sese-to-poly.h: New.
2700 * Makefile.in: Add new rule for graphite-sese-to-poly.o.
2702 2009-02-20 Sebastian Pop <sebastian.pop@amd.com>
2704 * graphite.c: Split graphite code generation to a new file.
2705 (graphite_verify, gmp_cst_to_tree, clast_name_to_gcc,
2706 max_precision_type, clast_to_gcc_expression_red,
2707 clast_to_gcc_expression, gcc_type_for_clast_expr,
2708 gcc_type_for_clast_eq, loop_iv_stack_patch_for_consts,
2709 graphite_translate_clast_equation, graphite_create_guard_cond_expr,
2710 graphite_create_new_guard, clast_get_body_of_loop,
2711 gcc_type_for_cloog_iv, gcc_type_for_iv_of_clast_loop,
2712 graphite_create_new_loop, build_iv_mapping, copy_renames,
2713 translate_clast, find_cloog_iv_in_expr, compute_cloog_iv_types_1,
2714 compute_cloog_iv_types, free_scattering, save_var_name,
2715 initialize_cloog_names, build_scop_context, build_cloog_prog,
2716 set_cloog_options, debug_clast_stmt, scop_to_clast,
2717 print_generated_program, debug_generated_program,
2718 gloog): Moved to graphite-clast-to-gimple.c.
2720 (struct cloog_prog_clast): Moved to graphite-clast-to-gimple.h.
2722 (iv_stack_entry_is_constant, iv_stack_entry_is_iv,
2723 loop_iv_stack_push_iv, loop_iv_stack_insert_constant,
2724 loop_iv_stack_pop, loop_iv_stack_get_iv,
2725 loop_iv_stack_get_iv_from_name, debug_loop_iv_stack,
2726 free_loop_iv_stack, loop_iv_stack_remove_constants,
2727 debug_rename_elt, debug_rename_map_1, debug_rename_map,
2728 rename_map_elt_info, eq_rename_map_elts, debug_ivtype_elt,
2729 debug_ivtype_map_1, debug_ivtype_map, ivtype_map_elt_info,
2730 eq_ivtype_map_elts, sese_add_exit_phis_edge,
2731 sese_add_exit_phis_var, sese_insert_phis_for_liveouts,
2732 get_vdef_before_sese, sese_adjust_vphi,
2733 get_new_name_from_old_name, sese_adjust_phis_for_liveouts,
2734 oldiv_for_loop, rename_variables_in_stmt, is_parameter,
2735 is_iv, expand_scalar_variables_ssa_name,
2736 expand_scalar_variables_expr, expand_scalar_variables_stmt,
2737 expand_scalar_variables, rename_variables, remove_condition,
2738 get_true_edge_from_guard_bb, get_false_edge_from_guard_bb,
2739 add_loop_exit_phis, insert_loop_close_phis, struct igp,
2740 default_liveout_before_guard, add_guard_exit_phis,
2741 insert_guard_phis, register_old_and_new_names,
2742 graphite_copy_stmts_from_block, register_sese_liveout_renames,
2743 copy_bb_and_scalar_dependences, outermost_loop_in_sese,
2744 if_region_set_false_region, create_if_region_on_edge,
2745 move_sese_in_condition): Moved to sese.c.
2747 (nb_loops_around_loop_in_sese, struct ifsese, if_region_entry,
2748 if_region_exit, if_region_get_condition_block,
2749 struct rename_map_elt, new_rename_map_elt, enum iv_stack_entry_kind,
2750 union iv_stack_entry_data_union, struct iv_stack_entry_struct,
2751 iv_stack_entry_p, loop_iv_stack, struct ivtype_map_elt,
2752 ivtype_map_elt, new_ivtype_map_elt,
2753 recompute_all_dominators): Moved to sese.h.
2755 * graphite-clast-to-gimple.c: New.
2756 * graphite-clast-to-gimple.h: New.
2757 * Makefile.in: Add new rule for graphite-clast-to-gimple.o.
2758 * sese.c: Modified as said above.
2761 2009-02-20 Sebastian Pop <sebastian.pop@amd.com>
2763 * graphite.c: Split scop detection to a new file.
2764 (enum gbb_type, gbb_type, get_bb_type, struct sd_region_p, sd_region,
2765 move_sd_regions, loop_affine_expr, exclude_component_ref,
2766 is_simple_operand, stmt_simple_for_scop_p, harmful_stmt_in_bb,
2767 graphite_cannot_represent_loop_niter, struct scopdet_info,
2768 scopdet_basic_block_info, build_scops_1, bb_in_sd_region,
2769 find_single_entry_edge, find_single_exit_edge,
2770 create_single_entry_edge, sd_region_without_exit,
2771 create_single_exit_edge, unmark_exit_edges, mark_exit_edges,
2772 create_sese_edges, build_graphite_scops, limit_scops, build_scops):
2773 Moved to graphite-scop-detection.c.
2775 * graphite-scop-detection.c: New.
2776 * graphite-scop-detection.h: New.
2777 * Makefile.in: Add new rule for graphite-scop-detection.o.
2779 * sese.c: Include tree-chrec.h, tree-data-ref.h, and
2780 tree-scalar-evolution.h.
2781 (nb_reductions_in_loop, graphite_loop_normal_form, sese_record_loop,
2782 build_sese_loop_nests): Moved here from graphite.c.
2783 (param_index): Renamed parameter_index_in_region.
2785 2009-02-18 Tobias Grosser <grosser@fim.uni-passau.de>
2786 Sebastian Pop <sebastian.pop@amd.com>
2788 * gcc.dg/graphite/block-0.c: Expected to fail now.
2789 * gcc.dg/graphite/block-1.c: Same.
2790 * gcc.dg/graphite/block-5.c: Same.
2791 * gcc.dg/graphite/block-6.c: Same.
2793 2009-02-18 Tobias Grosser <grosser@fim.uni-passau.de>
2794 Sebastian Pop <sebastian.pop@amd.com>
2796 * graphite.h: Separate from graphite_bb_p the polyhedral
2797 representation in poly_bb_p and the GCC specifics in gimple_bb_p.
2798 (struct data_dependence_polyhedron, RDGE_DDP, ddp_p): Moved to
2799 graphite-data-ref.h.
2800 (struct poly_bb, PBB_SCOP, PBB_STATIC_SCHEDULE, PBB_DOMAIN,
2801 PBB_BLACK_BOX, PBB_LOOPS, pbb_nb_loops, pbb_loop_at_index,
2802 pbb_loop_index, struct scop, SCOP_BBS, SCOP_REGION, SCOP_ENTRY,
2803 SCOP_EXIT, SCOP_REGION_BBS, SCOP_DEP_GRAPH, SCOP_PARAMS,
2804 SCOP_LOOP_NEST, SCOP_PARAMS, SCOP_OLDIVS, SCOP_LIVEOUT_RENAMES,
2805 scop_nb_params): Moved to graphite-poly.h.
2806 * graphite-data-ref.c: Same.
2807 * graphite-data-ref.h: New.
2809 (pbb_compare, graphite_sort_pbbs, graphite_trans_bb_move_loop,
2810 graphite_trans_bb_strip_mine, strip_mine_profitable_p,
2811 is_interchange_valid, graphite_trans_bb_block,
2812 graphite_trans_loop_block, scop_max_loop_depth,
2813 graphite_trans_scop_block, graphite_apply_transformations,
2814 new_poly_bb, free_poly_bb, new_scop, free_scop): Moved to
2816 * graphite-poly.h: New.
2817 * graphite-poly.c: New.
2818 * Makefile.in (OBJS-common): Add graphite-poly.o.
2819 (graphite-poly.o): New rule.
2820 * tree-data-ref.h (struct data_reference): Remove unused scop field.
2823 2009-02-18 Sebastian Pop <sebastian.pop@amd.com>
2824 Tobias Grosser <grosser@fim.uni-passau.de>
2826 * graphite.c: Replace gb -> gbb.
2828 * graphite-data-ref.c: Same.
2830 2009-02-18 Sebastian Pop <sebastian.pop@amd.com>
2831 Tobias Grosser <grosser@fim.uni-passau.de>
2833 * Makefile.in (OBJS-commmon): Add sese.o.
2835 (graphite.o): Add sese.h.
2836 * graphite.c (bb_in_ss_p, loop_in_sese_p,
2837 sese_build_livein_liveouts_use, sese_build_livein_liveouts_bb,
2838 sese_build_livein_liveouts, register_bb_in_sese, new_sese, free_sese):
2840 (block_before_scop): Add missing return.
2841 (new_scop, free_scop): Remove SESE data structures.
2842 (scop_record_loop, scan_tree_for_params, find_params_in_bb,
2843 find_scop_parameters, build_loop_iteration_domains,
2844 add_conditions_to_domain, register_scop_liveout_renames,
2845 copy_bb_and_scalar_dependences): Scop -> SESE.
2847 (add_conditions_to_domain): SCoP -> SESE and remove check
2848 (scop_contains_non_iv_scalar_phi_nodes): New.
2849 (build_scop_conditions_1, build_scop_conditions): Remove check for
2850 non iv scalar phi nodes.
2851 (print_scop_statistics): New.
2852 (graphite_transform_loops): Cleanup.
2854 * graphite.h: Move to sese & cleanup.
2858 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
2859 Tobias Grosser <grosser@fim.uni-passau.de>
2861 * graphite.c (build_scop_conditions_1): Conditions are only
2862 at the end of a basic block.
2864 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
2865 Tobias Grosser <grosser@fim.uni-passau>
2867 * graphite.h (struct graphite_bb): Remove compressed_alpha_matrix
2869 (GBB_ALPHA): Removed.
2871 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
2872 Tobias Grosser <grosser@fim.uni-passau.de>
2874 * graphite-data-ref.c (graphite_test_dependence): Don't use
2875 GBB_DYNAMIC_SCHEDULE.
2876 * graphite.c (new_graphite_bb): Same.
2877 (free_graphite_bb): Same.
2878 (build_scop_dynamic_schedules): Removed.
2879 (graphite_transform_loops): Don't call it.
2880 * graphite.h (struct graphite_bb): Remove dynamic_schedule field.
2881 (GBB_DYNAMIC_SCHEDULE): Removed.
2883 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
2884 Tobias Grosser <grosser@fim.uni-passau.de>
2886 * graphite.c (schedule_to_scattering): Don't use CloogMatrix.
2887 (print_graphite_bb): Same.
2888 (build_cloog_prog): Same.
2890 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
2891 Tobias Grosser <grosser@fim.uni-passau.de>
2893 * graphite.c (build_cloog_prog): Don't use CloogMatrix.
2895 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
2896 Tobias Grosser <grosser@fim.uni-passau.de>
2898 * graphite.c (build_scop_context): Don't use CloogMatrix.
2899 * graphite-ppl.c (new_Cloog_Domain_from_ppl_Polyhedron): New.
2900 * graphite-ppl.h (new_Cloog_Domain_from_ppl_Polyhedron): Declared.
2902 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
2903 Tobias Grosser <grosser@fim.uni-passau.de>
2905 * graphite.h (struct scop): Move params, old_ivs, loops, loop_nest,
2906 liveout_renames, add_params fields...
2907 (struct sese): ... here.
2908 (SESE_PARAMS, SESE_LOOPS, SESE_LOOP_NEST, SESE_ADD_PARAMS,
2909 SESE_PARAMS, SESE_OLDIVS, SESE_LIVEOUT_RENAMES): New.
2911 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
2912 Tobias Grosser <grosser@fim.uni-passau.de>
2914 * graphite.c (print_scop): Do not print the CLooG program.
2915 (new_scop, free_scop, initialize_cloog_names, build_scop_context,
2916 build_cloog_prog, gloog): Don't use SCOP_PROG.
2917 (find_transform): Renamed scop_to_clast.
2918 (print_generated_program, debug_generated_program): New.
2919 (graphite_transform_loops): Adapt to new interface.
2920 * graphite.h (struct scop): Remove program field.
2921 (SCOP_PROG): Removed.
2922 (print_generated_program, debug_generated_program): Declared.
2924 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
2926 * graphite-data-ref.c (schedule_precedes_p, schedule_same_p): New.
2927 (statement_precedes_p): Use schedule_same_p and schedule_precedes_p.
2928 * graphite.c (gbb_compare, schedule_to_scattering, print_graphite_bb,
2929 free_graphite_bb, build_scop_canonical_schedules,
2930 graphite_trans_bb_strip_mine, graphite_trans_scop_block): Static
2931 schedules are now represented using a ppl_Linear_Expression_t.
2932 * graphite.h (struct graphite_bb): Same.
2933 * graphite-ppl.c (ppl_lexico_compare_linear_expressions): New.
2934 * graphite-ppl.h (ppl_lexico_compare_linear_expressions): Declared.
2936 2009-02-15 Sebastian Pop <sebastian.pop@amd.com>
2938 * graphite.c: Free local memory.
2939 * graphite-ppl.c: Same.
2941 2009-02-15 Sebastian Pop <sebastian.pop@amd.com>
2943 * graphite.c (const_column_index, get_first_matching_sign_row_index,
2944 get_lower_bound_row, get_upper_bound_row, copy_constraint,
2945 swap_constraint_variables, scale_constraint_variable): Removed.
2946 (graphite_trans_bb_strip_mine): Remove pong.
2947 * graphite-ppl.c: Include missing header files.
2948 (set_inhomogeneous, set_coef, shift_poly, ppl_strip_loop): New.
2949 * graphite-ppl.h (ppl_strip_loop): Declared.
2950 * Makefile.in (graphite-ppl.o): Adjust dependences.
2952 2009-02-14 Sebastian Pop <sebastian.pop@amd.com>
2954 * graphite.c (build_loop_iteration_domains): Remove ping pong.
2955 (build_scop_iteration_domain): Same.
2957 2009-02-13 Sebastian Pop <sebastian.pop@amd.com>
2959 * graphite.c (scan_tree_for_params, add_conditions_to_domain): Remove
2961 (add_value_to_dim, scan_tree_for_params_right_scev,
2962 scan_tree_for_params_int): New.
2963 * graphite-ppl.c (oppose_constraint): New.
2964 (insert_constraint_into_matrix): Implement missing cases.
2965 * graphite-ppl.h (insert_constraint_into_matrix): Declared.
2967 2009-02-13 Sebastian Pop <sebastian.pop@amd.com>
2969 * graphite.c (graphite_trans_bb_move_loop): Remove ping pong,
2970 use ppl_move_dimension.
2972 2009-02-12 Sebastian Pop <sebastian.pop@amd.com>
2974 * graphite-data-ref.c: Domains are now ppl_Polyhedra_t.
2977 * graphite-ppl.c: Same.
2978 * graphite-ppl.h: Same.
2980 2009-02-12 Sebastian Pop <sebastian.pop@amd.com>
2982 Revert last 3 commits.
2984 2009-02-10 Sebastian Pop <sebastian.pop@amd.com>
2986 * graphite.c (scan_tree_for_params, add_conditions_to_domain): Remove
2988 (add_value_to_dim, scan_tree_for_params_right_scev,
2989 scan_tree_for_params_int): New.
2990 * graphite-ppl.c (oppose_constraint): New.
2991 (insert_constraint_into_matrix): Implement missing cases.
2992 * graphite-ppl.h (insert_constraint_into_matrix): Declared.
2994 2009-02-10 Sebastian Pop <sebastian.pop@amd.com>
2996 * graphite.c (graphite_trans_bb_move_loop): Remove unused variables.
2998 2009-02-10 Sebastian Pop <sebastian.pop@amd.com>
2999 Tobias Grosser <grosser@fim.uni-passau.de>
3001 * graphite.c (graphite_trans_bb_move_loop): Remove ping pong,
3002 use ppl_move_dimension.
3003 * graphite-ppl.c (ppl_move_dimension): New.
3004 * graphite-ppl.h (ppl_move_dimension): Declared.
3006 2009-02-10 Sebastian Pop <sebastian.pop@amd.com>
3008 * graphite.c: Do not include cloog/cloog.h.
3009 (print_graphite_bb): Remove ping pong, call PPL print function.
3011 2009-02-10 Tobias Grosser <grosser@fim.uni-passau.de>
3013 * Makefile.in (OBJS-common): Add graphite-ppl.o.
3014 (graphite.o): Add dependence on graphite-ppl.h.
3015 (graphite-ppl.o): New.
3016 (graphite-data-ref.c): Ping pong between PPL data structures
3018 * graphite-ppl.c: New.
3019 * graphite-ppl.h: New.
3020 * graphite.c: Include graphite-ppl.h.
3021 (print_graphite_bb, add_conditions_to_domain, build_cloog_prog,
3022 graphite_trans_bb_move_loop, graphite_trans_bb_strip_mine):
3023 Ping pong between PPL data structures and matrices.
3024 (new_graphite_bb): Create a PPL constraint system.
3025 Call ppl_delete_Constraint_System instead of cloog_matrix_free.
3026 (build_loop_iteration_domains): Use PPL functions.
3027 * graphite.h: Include graphite-ppl.h. Fix comments.
3028 (graphite_bb): Use a ppl_Constraint_System_t instead of
3029 CloogMatrix for representing the domain.
3030 (scop): Remove static_schedule.
3031 (gbb_nb_loops): Ping pong between PPL data structures and matrices.
3033 2009-02-06 Sebastian Pop <sebastian.pop@amd.com>
3035 * graphite.c: Fix some comments.
3037 2009-02-05 Sebastian Pop <sebastian.pop@amd.com>
3040 * graphite.c (if_region_set_false_region): After moving a region
3041 in the false branch of a condition, remove the empty dummy
3043 (gloog): Remove wrong fix for PR38953.
3045 2009-02-03 Tobias Grosser <grosser@fim.uni-passau.de>
3047 * graphite.c (bb_in_sese_p, sese_build_livein_liveouts_use,
3048 sese_build_livein_liveouts_bb, sese_build_livein_liveouts,
3049 register_bb_in_sese, new_sese, free_sese): Moved.
3050 (dot_scop_1, build_scop_loop_nests, build_loop_iteration_domains,
3051 outermost_loop_in_scop, build_scop_iteration_domain,
3052 expand_scalar_variables_ssa_name, get_vdef_before_scop,
3053 limit_scops): Use bb_in_sese_p instead of bb_in_scop_p.
3054 Use loop_in_sese_p instead of loop_in_scop_p.
3055 (new_graphite_bb, new_scop, gloog): Do not initialize SCOP_BBS_B.
3056 (free_scop): Do not free SCOP_BBS_B.
3057 (nb_loops_around_loop_in_scop, nb_loops_around_gb,
3058 ref_nb_loops): Moved here...
3059 * graphite.h (ref_nb_loops): ... from here.
3060 (struct scop): Remove bbs_b bitmap.
3061 (SCOP_BBS_B, bb_in_scop_p, loop_in_scop_p): Removed.
3062 * testsuite/gcc.dg/graphite/scop-19.c: New
3064 2009-02-03 Tobias Grosser <grosser@fim.uni-passau.de>
3066 * graphite.c (scopdet_basic_block_info): Fix bug in scop
3069 2009-01-30 Tobias Grosser <grosser@fim.uni-passau.de>
3071 * graphite.c (new_loop_to_cloog_loop_str, hash_loop_to_cloog_loop,
3072 eq_loop_to_cloog_loop): Remove.
3073 (new_scop, free_scop): Remove SCOP_LOOP2CLOOG_LOOP.
3074 * graphite.h (struct scop): Remove loop2cloog_loop.
3075 (loop_domain_dim, loop_iteration_vector_dim): Remove.
3077 2009-01-30 Tobias Grosser <grosser@fim.uni-passau.de>
3079 * opts.c (decode_options): Only add graphite options to O2
3080 if we compile with graphite enabled.
3082 2009-01-26 Sebastian Pop <sebastian.pop@amd.com>
3084 * Merge from mainline (r143163:143684).
3086 2009-01-26 Sebastian Pop <sebastian.pop@amd.com>
3088 * graphite.c (debug_value): Removed.
3089 * graphite.h (debug_value): Removed.
3091 2009-01-23 Sebastian Pop <sebastian.pop@amd.com>
3093 * passes.c (init_optimization_passes): Do not call pass_copy_prop
3094 after graphite: pass_copy_prop does not maintain a proper loop closed
3095 SSA form. pass_copy_prop should be fixed.
3097 2009-01-23 Sebastian Pop <sebastian.pop@amd.com>
3099 * graphite.c (scop_adjust_phis_for_liveouts): Fix warning.
3101 2009-01-23 Sebastian Pop <sebastian.pop@amd.com>
3103 * graphite.c (graphite_verify): Add a call to verify_loop_closed_ssa.
3104 (gloog): Split the exit of the scop when the scop exit is a loop exit.
3105 (graphite_transform_loops): Only call cleanup_tree_cfg if gloog
3108 2009-01-20 Sebastian Pop <sebastian.pop@amd.com>
3110 * graphite.c (gloog): Return true when code gen succeeded.
3111 (graphite_transform_loops): Do not call cleanup_tree_cfg if
3112 the code of the function did not changed. After cleanup_tree_cfg
3113 call rewrite_into_loop_closed_ssa to maintain the loop closed ssa
3116 2009-01-19 Sebastian Pop <sebastian.pop@amd.com>
3118 * graphite.c (stmt_simple_for_scop_p): Also handle cases when
3119 gimple_call_lhs is NULL.
3121 2009-01-16 Sebastian Pop <sebastian.pop@amd.com>
3122 Tobias Grosser <tobi.grosser@amd.com>
3124 * graphite.c (graphite_trans_scop_block): Do not block single
3127 2009-01-15 Sebastian Pop <sebastian.pop@amd.com>
3128 Tobias Grosser <tobi.grosser@amd.com>
3130 * graphite.c (build_scop_canonical_schedules): Start schedules at
3133 2009-01-15 Sebastian Pop <sebastian.pop@amd.com>
3134 Tobias Grosser <tobi.grosser@amd.com>
3136 * graphite.c (compare_prefix_loops): New.
3137 (build_scop_canonical_schedules): Rewritten.
3138 (graphite_transform_loops): Move build_scop_canonical_schedules
3139 after build_scop_iteration_domain.
3141 2009-01-14 Sebastian Pop <sebastian.pop@amd.com>
3142 Tobias Grosser <tobi.grosser@amd.com>
3144 * graphite.c (add_conditions_to_domain): Add the loops to
3145 the dimension of the iteration domain. Do copy the domain
3146 only when it exists.
3147 (build_scop_conditions_1): Do not call add_conditions_to_domain.
3148 (add_conditions_to_constraints): New.
3149 (can_generate_code_stmt, can_generate_code): Removed.
3150 (gloog): Do not call can_generate_code.
3151 (graphite_transform_loops): Call add_conditions_to_constraints
3152 after building the iteration domain.
3154 2009-01-14 Sebastian Pop <sebastian.pop@amd.com>
3155 Tobias Grosser <tobi.grosser@amd.com>
3156 Jan Sjodin <jan.sjodin@amd.com>
3158 * graphite.c (scan_tree_for_params): On substractions negate
3159 all the coefficients of the term.
3160 (clast_to_gcc_expression_red): New. Handle reduction expressions
3161 of more than two operands.
3162 (clast_to_gcc_expression): Call clast_to_gcc_expression_red.
3163 (get_vdef_before_scop): Handle also the case of default definitions.
3165 2009-01-14 Sebastian Pop <sebastian.pop@amd.com>
3168 * graphite.c (get_vdef_before_scop, scop_adjust_vphi): New.
3169 (scop_adjust_phis_for_liveouts): Call scop_adjust_vphi.
3170 (gloog): Do not call cleanup_tree_cfg.
3171 (graphite_transform_loops): Call cleanup_tree_cfg after all
3172 scops have been code generated.
3174 2009-01-13 Sebastian Pop <sebastian.pop@amd.com>
3176 * passes.c (init_optimization_passes): Schedule after
3177 graphite transforms pass_copy_prop, pass_dce_loop and pass_lim.
3179 2009-01-13 Sebastian Pop <sebastian.pop@amd.com>
3181 * graphite.c (expand_scalar_variables_stmt): Do not pass loop_p.
3183 (expand_scalar_variables_ssa_name): Do not pass loop_p. Fix comment.
3184 Set the type of an expression to the type of its assign statement.
3185 (expand_scalar_variables_expr): Do not pass loop_p.
3186 Fix comment. Stop recursion on tcc_constant or tcc_declaration.
3187 (copy_bb_and_scalar_dependences): Do not pass loop_p.
3188 (translate_clast): Update call to copy_bb_and_scalar_dependences.
3190 2009-01-11 Sebastian Pop <sebastian.pop@amd.com>
3192 * graphite.c (expand_scalar_variables_ssa_name): Set the type of
3193 an expression to the gimple_expr_type of its assign statement.
3194 (expand_scalar_variables_expr): Stop recursion on tcc_constant
3197 2009-01-11 Sebastian Pop <sebastian.pop@amd.com>
3199 PR tree-optimization/38786
3200 * testsuite/gcc.dg/graphite/pr38786.c: New.
3201 * graphite.c (expand_scalar_variables_ssa_name): New, outlined from
3202 the SSA_NAME case of expand_scalar_variables_expr.
3203 (expand_scalar_variables_expr): Also gather the scalar computation
3204 used to index the memory access.
3205 (expand_scalar_variables_stmt): Pass to expand_scalar_variables_expr
3206 the gimple_stmt_iterator where it inserts new code.
3208 2009-01-10 Sebastian Pop <sebastian.pop@amd.com>
3210 * testsuite/gcc.dg/graphite/block-3.c: Fix compile error on 32bit.
3212 2009-01-10 Sebastian Pop <sebastian.pop@amd.com>
3214 * opts.c (decode_options): Enable flag_graphite_identity and
3215 flag_loop_block in -O2 and above.
3217 2009-01-08 Sebastian Pop <sebastian.pop@amd.com>
3219 * libjava/classpath/lib/gnu/java/awt/peer/gtk/GtkMouseInfoPeer.class:
3220 Fix merge problem: replace with the file from trunk.
3222 2009-01-08 Sebastian Pop <sebastian.pop@amd.com>
3224 * Merge from mainline (r141727:143163).
3226 2009-01-07 Sebastian Pop <sebastian.pop@amd.com>
3227 Jan Sjodin <jan.sjodin@amd.com>
3229 PR tree-optimization/38559
3230 * testsuite/gcc.dg/graphite/pr38559.c: New.
3232 * graphite.c (debug_value, copy_constraint,
3233 swap_constraint_variables, scale_constraint_variable, ): New.
3234 (get_lower_bound, get_upper_bound): Removed.
3235 (graphite_trans_bb_strip_mine): Clean up this code that works
3236 only for constant number of iterations. Fully copy upper and
3237 lower bound constraints, not only the constant part of them.
3238 * graphite.h (debug_value): Declared.
3240 2009-01-06 Jan Sjodin <jan.sjodin@amd.com>
3242 PR tree-optimization/38492
3243 PR tree-optimization/38498
3244 * tree-check.c (operator_is_linear, scev_is_linear_expression): New.
3245 * tree-chrec.h (scev_is_linear_expression): Declared.
3246 * graphite.c (graphite_cannot_represent_loop_niter): New.
3247 (scopdet_basic_block_info): Call graphite_cannot_represent_loop_niter.
3248 (graphite_loop_normal_form): Use gcc_assert.
3249 (scan_tree_for_params): Use CASE_CONVERT.
3250 (phi_node_is_iv, bb_contains_non_iv_scalar_phi_nodes): New.
3251 (build_scop_conditions_1): Call bb_contains_non_iv_scalar_phi_nodes.
3252 Use gcc_assert. Discard scops that contain unhandled cases.
3253 (build_scop_conditions): Return a boolean status for unhandled cases.
3254 (strip_mine_profitable_p): Print the loop number, not its depth.
3255 (is_interchange_valid): Pass the depth of the loop nest, don't
3256 recompute it wrongly.
3257 (graphite_trans_bb_block): Same.
3258 (graphite_trans_bb_block): Print tentative of loop blocking.
3259 (graphite_trans_scop_block): Do not print that the loop has been
3261 (graphite_transform_loops): Do not handle scops that contain condition
3264 * testsuite/gcc.dg/graphite/pr38500.c: Fixed warning as committed
3266 * testsuite/gcc.dg/graphite/block-0.c: Update test.
3267 * testsuite/gcc.dg/graphite/block-1.c: Same.
3268 * testsuite/gcc.dg/graphite/block-2.c: Remove xfail and test for
3270 * testsuite/gcc.dg/graphite/block-4.c: Remove test for strip mine.
3271 * testsuite/gcc.dg/graphite/block-3.c: New.
3272 * testsuite/gcc.dg/graphite/pr38498.c: New.
3274 2008-12-22 Harsha Jagasia <harsha.jagasia@amd.com>
3276 PR tree-optimization/38510
3277 * gcc.dg/graphite/pr38510.c: New.
3278 * graphite.c (recompute_all_dominators): Call mark_irreducible_loops.
3279 (translate_clast): Call recompute_all_dominators before
3281 (gloog): Call recompute_all_dominators before graphite_verify.
3283 2008-12-12 Sebastian Pop <sebastian.pop@amd.com>
3285 PR tree-optimization/38492
3286 * graphite.c (rename_map_elt, debug_rename_elt,
3287 debug_rename_map_1, debug_rename_map, new_rename_map_elt,
3288 rename_map_elt_info, eq_rename_map_elts,
3289 get_new_name_from_old_name, bb_in_sese_p): Moved around.
3290 (sese_find_uses_to_rename_use): Renamed sese_build_livein_liveouts_use.
3291 (sese_find_uses_to_rename_bb): Renamed sese_build_livein_liveouts_bb.
3292 (sese_build_livein_liveouts): New.
3293 (new_sese, free_sese): New.
3294 (new_scop): Call new_sese.
3295 (free_scop): Call free_sese.
3296 (rename_variables_from_edge, rename_phis_end_scop): Removed.
3297 (register_old_new_names): Renamed register_old_and_new_names.
3298 (register_scop_liveout_renames, add_loop_exit_phis,
3299 insert_loop_close_phis, struct igp,
3300 default_liveout_before_guard, add_guard_exit_phis,
3301 insert_guard_phis, copy_renames): New.
3302 (translate_clast): Call insert_loop_close_phis and insert_guard_phis.
3303 (sese_add_exit_phis_edge): Renamed scop_add_exit_phis_edge.
3304 (rewrite_into_sese_closed_ssa): Renamed scop_insert_phis_for_liveouts.
3305 (scop_adjust_phis_for_liveouts): New.
3306 (gloog): Call scop_adjust_phis_for_liveouts.
3308 * graphite.h (struct sese): Documented. Added fields liveout,
3310 (SESE_LIVEOUT, SESE_LIVEIN, SESE_LIVEIN_VER, SESE_NUM_VER): New.
3311 (new_sese, free_sese, sese_build_livein_liveouts): Declared.
3312 (struct scop): Added field liveout_renames.
3313 (SCOP_LIVEOUT_RENAMES): New.
3315 2008-12-11 Sebastian Pop <sebastian.pop@amd.com>
3317 PR tree-optimization/38409
3318 * gcc.dg/graphite/pr38409.c: New.
3319 * graphite.c (nb_reductions_in_loop): Use simple_iv.
3321 2008-12-11 Sebastian Pop <sebastian.pop@amd.com>
3323 * graphite.c (gcc_type_for_cloog_iv): By default return
3325 (graphite_create_new_loop): Don't fold_convert the already
3326 fold_convert-ed expression.
3328 2008-12-11 Harsha Jagasia <harsha.jagasia@amd.com>
3330 PR tree-optimization/38446
3331 * gcc.dg/graphite/pr38446.c: New.
3332 * graphite.c (register_bb_in_sese): New.
3333 (bb_in_sese_p): Check if bb belongs to sese region by explicitly
3334 looking at the bbs in the region.
3335 * graphite.h (sese): Add region_basic_blocks pointer set to
3336 structure and initialize at the time of defining new scop.
3338 2008-12-11 Tobias Grosser <grosser@fim.uni-passau.de>
3340 * graphite.c (new_graphite_bb): Initialize GBB_STATIC_SCHEDULE.
3341 (find_params_in_bb): Do not free data refs.
3342 (free_graphite_bb): Add FIXME on disabled free_data_refs.
3344 2008-12-11 Sebastian Pop <sebastian.pop@amd.com>
3346 * testsuite/gcc.dg/graphite/scop-16.c: Test only scop specific info.
3347 * testsuite/gcc.dg/graphite/scop-17.c: Same.
3348 * testsuite/gcc.dg/graphite/block-5.c: New.
3349 * testsuite/gcc.dg/graphite/block-6.c: New.
3350 * testsuite/gcc.dg/graphite/pr37485.c: Clean dump file after.
3351 * testsuite/gcc.dg/graphite/pr37684.c: Same.
3352 * testsuite/gcc.dg/graphite/block-2.c: Same.
3354 * graphite.c (struct ivtype_map_elt): New.
3355 (debug_ivtype_elt, debug_ivtype_map_1, debug_ivtype_map,
3356 new_ivtype_map_elt, ivtype_map_elt_info, eq_ivtype_map_elts,
3357 gcc_type_for_cloog_iv): New.
3358 (loop_iv_stack_patch_for_consts): Use the type of the induction
3359 variable from the original loop, except for the automatically
3360 generated loops, i.e., in the case of a strip-mined loop, in
3361 which case there is no original loop: in that case just use
3363 (new_graphite_bb): Initialize GBB_CLOOG_IV_TYPES.
3364 (free_graphite_bb): Free GBB_CLOOG_IV_TYPES.
3365 (clast_name_to_gcc): Accept params to be NULL.
3366 (clast_to_gcc_expression): Take an extra parameter for the type.
3367 Convert to that type all the expressions built by this function.
3368 (gcc_type_for_clast_expr, gcc_type_for_clast_eq): New.
3369 (graphite_translate_clast_equation): Compute the type of the
3370 clast_equation before translating its LHS and RHS.
3371 (clast_get_body_of_loop, gcc_type_for_iv_of_clast_loop): New.
3372 (graphite_create_new_loop): Compute the type of the induction
3373 variable before translating the lower and upper bounds and before
3374 creating the induction variable.
3375 (rename_variables_from_edge, rename_phis_end_scop): New.
3376 (copy_bb_and_scalar_dependences): Call rename_phis_end_scop.
3377 (sese_add_exit_phis_edge): Do not use integer_zero_node.
3378 (find_cloog_iv_in_expr, compute_cloog_iv_types_1,
3379 compute_cloog_iv_types): New.
3380 (gloog): Call compute_cloog_iv_types before starting the
3381 translation of the clast.
3383 * graphite.h (struct graphite_bb): New field cloog_iv_types.
3384 (GBB_CLOOG_IV_TYPES): New.
3385 (debug_ivtype_map): Declared.
3386 (oldiv_for_loop): New.
3388 2008-12-10 Tobias Grosser <grosser@fim.uni-passau.de>
3391 * graphite.c (new_scop): Initialize SCOP_ADD_PARAMS.
3392 (param_index): Assert if parameter is not know after parameter
3394 (find_params_in_bb): Detect params directly in GBB_CONDITIONS.
3395 (find_scop_parameters): Mark, that we have finished parameter
3397 (graphite_transform_loops): Move condition detection before parameter
3399 * graphite.h (struct scop): Add SCOP_ADD_PARAMS.
3400 * testsuite/gfortran.dg/graphite/pr38459.f90: New.
3402 2008-12-09 Tobias Grosser <grosser@fim.uni-passau.de>
3404 * graphite.c (graphite_transform_loops): Always call find_transform ()
3405 in ENABLE_CHECKING. So we test these code paths, even if we do not
3408 2008-12-09 Tobias Grosser <grosser@fim.uni-passau.de>
3410 * graphite.c (print_graphite_bb): Fix printing to file != dump_file.
3411 (print_scop): Ditto.
3413 2008-12-08 Tobias Grosser <grosser@fim.uni-passau.de>
3416 Fix testsuite/gfortran.dg/graphite/id-3.f90.
3417 * graphite.c (scopdet_basic_block_info): Fix bug that found some
3418 regions more than once.
3420 2008-12-03 Sebastian Pop <sebastian.pop@amd.com>
3422 Fix testsuite/gfortran.dg/graphite/id-4.f90.
3423 * graphite.c (scan_tree_for_params): Do not compute the multiplicand
3426 2008-12-03 Sebastian Pop <sebastian.pop@amd.com>
3428 Fix testsuite/gfortran.dg/graphite/id-1.f90.
3429 * graphite.c (gmp_cst_to_tree): Pass the type in parameter.
3430 (loop_iv_stack_patch_for_consts): Update use of gmp_cst_to_tree.
3431 (max_precision_type): New.
3432 (value_clast): Removed.
3433 (clast_to_gcc_expression): Be more careful to types of expressions.
3434 Use max_precision_type and update use of gmp_cst_to_tree.
3435 (graphite_translate_clast_equation): Use max_precision_type.
3436 (graphite_create_guard_cond_expr): Do not use integer_type_node,
3437 use the type of the condition.
3438 (graphite_create_new_loop): Do not use integer_type_node, use the
3439 max_precision_type of lb and ub.
3441 2008-12-03 Sebastian Pop <sebastian.pop@amd.com>
3443 * graphite.c (build_scops_1): Initialize open_scop.exit
3446 2008-12-02 Sebastian Pop <sebastian.pop@amd.com>
3448 * testsuite/gcc.dg/graphite/pr38084.c: New.
3449 * testsuite/gfortran.dg/graphite/id-1.f90: New.
3450 * testsuite/gfortran.dg/graphite/id-2.f90: New.
3451 * testsuite/gfortran.dg/graphite/id-3.f90: New.
3452 * testsuite/gfortran.dg/graphite/id-4.f90: New.
3453 * testsuite/gfortran.dg/graphite/pr37857.f90: New.
3455 2008-12-02 Sebastian Pop <sebastian.pop@amd.com>
3456 Jan Sjodin <jan.sjodin@amd.com>
3457 Harsha Jagasia <harsha.jagasia@amd.com>
3469 * testsuite/gcc.dg/graphite/pr38073.c: New.
3470 * testsuite/gcc.dg/graphite/pr37928.c: New.
3471 * testsuite/gcc.dg/graphite/pr37883.c: New.
3472 * testsuite/gcc.dg/graphite/pr38125.c: New.
3473 * testsuite/gfortran.dg/graphite/pr38083.f90: New.
3474 * testsuite/gfortran.dg/graphite/pr37852.f90: New.
3475 * testsuite/gfortran.dg/graphite/pr37980.f90: New.
3477 * testsuite/gcc.dg/graphite/scop-18.c: Remove reduction, test for
3478 the number of detected scops. Copy exact same test for loop
3480 * testsuite/gcc.dg/graphite/block-1.c: Fix the number of expected
3481 loops to be blocked as reductions are not handled.
3482 * testsuite/gcc.dg/graphite/block-4.c: ...here. New.
3484 * tree-phinodes.c (remove_phi_nodes): New, extracted from...
3485 * tree-cfg.c (remove_phi_nodes_and_edges_for_unreachable_block):
3487 * tree-flow.h (remove_phi_nodes, canonicalize_loop_ivs): Declared.
3488 * Makefile.in (graphite.o): Depend on value-prof.h.
3489 (graphite.o-warn): Removed -Wno-error.
3490 * tree-parloops.c (canonicalize_loop_ivs): Allow reduction_list
3491 to be a NULL pointer. Call update_stmt. Return the newly created
3492 cannonical induction variable.
3494 * graphite.h (debug_rename_map): Declared. Fix some comments.
3496 * graphite.c: Reimplement the code generation from graphite to gimple.
3497 Include value-prof.h.
3498 (loop_iv_stack_get_iv): Do not return NULL for constant substitutions.
3499 (get_old_iv_from_ssa_name): Removed.
3500 (graphite_stmt_p): New.
3501 (new_graphite_bb): Test for useful statements before building a
3502 graphite statement for the basic block.
3503 (free_graphite_bb): Do not free GBB_DATA_REFS: this is a bug
3504 in free_data_ref that calls BITMAP_FREE (DR_VOPS (dr)) without
3506 (recompute_all_dominators, graphite_verify,
3507 nb_reductions_in_loop, graphite_loop_normal_form): New.
3508 (scop_record_loop): Call graphite_loop_normal_form.
3509 (build_scop_loop_nests): Iterate over all the blocks of the
3510 function instead of relying on the incomplete information from
3511 SCOP_BBS. Return the success of the operation.
3512 (find_params_in_bb): Use the data from GBB_DATA_REFS.
3513 (add_bb_domains): Removed.
3514 (build_loop_iteration_domains): Don't call add_bb_domains.
3515 Add the iteration domain only to the basic blocks that have been
3516 translated to graphite.
3517 (build_scop_conditions_1): Add constraints only if the basic
3518 block have been translated to graphite.
3519 (build_scop_data_accesses): Completely disabled until data
3520 dependence is correctly implemented.
3521 (debug_rename_elt, debug_rename_map_1, debug_rename_map): New.
3522 (remove_all_edges_1, remove_all_edges): Removed.
3523 (get_new_name_from_old_name): New.
3524 (graphite_rename_variables_in_stmt): Renamed
3525 rename_variables_in_stmt. Call get_new_name_from_old_name.
3526 Use replace_exp and update_stmt.
3527 (is_old_iv): Renamed is_iv.
3528 (expand_scalar_variables_stmt): Extra parameter for renaming map.
3529 Use replace_exp and update_stmt.
3530 (expand_scalar_variables_expr): Same. Use the map to get the
3531 new names for the renaming of induction variables and for the
3532 renaming of variables after a basic block has been copied.
3533 (expand_scalar_variables): Same.
3534 (graphite_rename_variables): Renamed rename_variables.
3535 (move_phi_nodes): Removed.
3536 (get_false_edge_from_guard_bb): New.
3537 (build_iv_mapping): Do not insert the induction variable of a
3538 loop in the renaming iv map if the basic block does not belong
3540 (register_old_new_names, graphite_copy_stmts_from_block,
3541 copy_bb_and_scalar_dependences): New.
3542 (translate_clast): Heavily reimplemented: copy basic blocks,
3543 do not move them. Finally, in call cleanup_tree_cfg in gloog.
3544 At each translation step call graphite_verify ensuring the
3545 consistency of the SSA, loops and dominators information.
3546 (collect_virtual_phis, find_vdef_for_var_in_bb,
3547 find_vdef_for_var_1, find_vdef_for_var,
3548 patch_phis_for_virtual_defs): Removed huge hack.
3549 (mark_old_loops, remove_dead_loops, skip_phi_defs,
3550 collect_scop_exit_phi_args, patch_scop_exit_phi_args,
3551 gbb_can_be_ignored, scop_remove_ignoreable_gbbs, ): Removed.
3552 (remove_sese_region, ifsese, if_region_entry, if_region_exit,
3553 if_region_get_condition_block, if_region_set_false_region,
3554 create_if_region_on_edge, move_sese_in_condition, bb_in_sese_p,
3555 sese_find_uses_to_rename_use, sese_find_uses_to_rename_bb,
3556 sese_add_exit_phis_edge, sese_add_exit_phis_var,
3557 rewrite_into_sese_closed_ssa): New.
3558 (gloog): Remove dead code. Early return if code cannot be
3559 generated. Call cleanup_tree_cfg once the scop has been code
3561 (graphite_trans_scop_block, graphite_trans_loop_block): Do not
3562 block loops with less than two loops.
3563 (graphite_apply_transformations): Remove the call to
3564 scop_remove_ignoreable_gbbs.
3565 (limit_scops): When build_scop_loop_nests fails, continue on
3566 the next scop. Fix open_scop.entry.
3567 (graphite_transform_loops): Call recompute_all_dominators: force the
3568 recomputation of correct CDI_DOMINATORS and CDI_POST_DOMINATORS.
3569 Call initialize_original_copy_tables and free_original_copy_tables
3570 to be able to copy basic blocks during code generation.
3571 When build_scop_loop_nests fails, continue on next scop.
3572 (value_clast): New union.
3573 (clast_to_gcc_expression): Fix type cast warning.
3575 2008-11-09 Sebastian Pop <sebastian.pop@amd.com>
3577 * Merge from mainline (r140838:141727).
3579 2008-11-05 Tobias Grosser <grosser@fim.uni-passau.de>
3583 * graphite.c (scan_tree_for_params): Add POINTER_PLUS_EXPR.
3585 2008-11-05 Tobias Grosser <grosser@fim.uni-passau.de>
3589 * graphite.c (scopdet_basic_block_info): Fix loops with multiple
3590 exits and conditions.
3591 * testsuite/gcc.dg/graphite/pr37943.c: New.
3593 2008-10-23 Tobias Grosser <grosser@fim.uni-passau.de>
3596 * graphite.c (gloog): Replace EXIT_BLOCK_PTR with scop exit.
3598 2008-10-23 Tobias Grosser <grosser@fim.uni-passau.de>
3600 * doc/invoke.texi: Fix spaces.
3602 2008-10-22 Sebastian Pop <sebastian.pop@amd.com>
3604 PR tree-optimization/37891
3605 Reverted last commit.
3606 * graphite.c (create_single_entry_edge): Set
3607 EDGE_IRREDUCIBLE_LOOP and BB_IRREDUCIBLE_LOOP.
3609 2008-10-21 Sebastian Pop <sebastian.pop@amd.com>
3610 Mitul Thakkar <mitul.thakkar@amd.com>
3612 * graphite.c (create_single_entry_edge): Set
3613 EDGE_IRREDUCIBLE_LOOP and BB_IRREDUCIBLE_LOOP.
3615 2008-10-16 Tobias Grosser <grosser@fim.uni-passau.de>
3617 * doc/invoke.texi: Add -fgraphite-identity.
3618 * graphite.c (graphite_apply_transformations): Check for
3619 -fgraphite-identity.
3620 * toplev.c (process_options): Add flag_graphite_identity.
3621 * tree-ssa-loop.c: Add flag_graphite_identity.
3623 2008-10-14 Sebastian Pop <sebastian.pop@amd.com>
3625 Undo changes from 2008-10-02:
3626 * tree-ssa-loop-ivopts.c (rewrite_use_nonlinear_expr): Convert
3627 operand type when copying the operand to a variable of different type.
3628 * cfgloopmanip.c (create_empty_loop_on_edge): Write exit condition
3629 with the IV name after increment.
3631 2008-10-14 Sebastian Pop <sebastian.pop@amd.com>
3632 Harsha Jagasia <harsha.jagasia@amd.com>
3634 PR tree-optimization/37828
3635 * testsuite/gcc.dg/graphite/pr37828.c: New.
3636 * graphite.c (graphite_trans_loop_block): Do not loop block
3637 single nested loops.
3639 2008-10-09 Harsha Jagasia <harsha.jagasia@amd.com>
3640 Sebastian Pop <sebastian.pop@amd.com>
3642 * graphite.c (struct rename_map_elt, new_rename_map_elt,
3643 rename_map_elt_info, eq_rename_map_elts): New.
3644 (graphite_rename_ivs_stmt): Renamed graphite_rename_variables_in_stmt.
3645 (expand_scalar_variables_expr): Change parameters.
3646 (expand_scalar_variables_stmt): Same.
3647 (expand_scalar_variables): Same.
3648 (graphite_rename_ivs): Rename graphite_rename_variables.
3649 (build_iv_mapping): New.
3650 (translate_clast): Call build_iv_mapping.
3651 * graphite.h (gbb_p): New name.
3653 2008-10-03 Harsha Jagasia <harsha.jagasia@amd.com>
3655 PR tree-optimization/37684
3656 * gcc.dg/graphite/pr37684.c: New.
3657 * graphite.c (exclude_component_ref): New.
3658 (is_simple_operand): Call exclude_component_ref.
3660 2008-10-02 Jan Sjodin <jan.sjodin@amd.com>
3661 Harsha Jagasia <harsha.jagasia@amd.com>
3663 PR tree-optimization/37485
3664 * gcc.dg/graphite/block-2.c: New
3665 * graphite.c (gmp_cst_to_tree): Moved.
3666 (iv_stack_entry_is_constant): New.
3667 (iv_stack_entry_is_iv): New.
3668 (loop_iv_stack_push): Renamed to loop_iv_stack_push_iv.
3669 (loop_iv_stack_insert_constant): New.
3670 (loop_iv_stack_pop): Use new datatpype.
3671 (loop_iv_stack_get_iv): Same.
3672 (loop_iv_stack_get_iv_from_name): Same.
3673 (loop_iv_stack_debug): Renamed to debug_loop_iv_stack.
3674 (loop_iv_stack_patch_for_consts): New.
3675 (loop_iv_stack_remove_constants): New.
3676 (graphite_create_new_loop): Use loop_iv_stack_push_iv.
3677 (translate_clast): Call loop_iv_stack_patch_for_consts and
3678 loop_iv_stack_remove_constants.
3679 (gloog): Use new datatype. Redirect construction edge to end
3680 block to avoid accidental deletion.
3681 * graphite.h (enum iv_stack_entry_kind): New. Tag for data in
3683 (union iv_stack_entry_data): New. Data in iv stack entry.
3684 (struct iv_stack_entry): New. Datatype for iv stack entries.
3686 2008-10-02 Sebastian Pop <sebastian.pop@amd.com>
3688 * tree-ssa-loop-ivopts.c (rewrite_use_nonlinear_expr): Convert
3689 operand type when copying the operand to a variable of different type.
3691 2008-10-02 Sebastian Pop <sebastian.pop@amd.com>
3693 * cfgloopmanip.c (create_empty_loop_on_edge): Write exit condition
3694 with the IV name after increment.
3696 2008-10-02 Sebastian Pop <sebastian.pop@amd.com>
3698 * Merge from mainline (r140164:140838).
3700 2008-09-10 Konrad Trifunovic <konrad.trifunovic@inria.fr>
3702 * graphite-data-ref.c: New.
3703 * graphite.c (print_scop): Also dump the dependence graph.
3704 (bb_in_scop_p, loop_in_scop_p, nb_loops_around_gb): Moved...
3705 (new_scop): Initialize SCOP_DEP_GRAPH.
3706 (build_scop_dynamic_schedules): New.
3707 (build_access_matrix_with_af): Fixed column numbering.
3708 (graphite_transform_loops): Call build_scop_dynamic_schedules.
3709 * graphite.h: Add ifndef/define guards against multiple inclusion.
3710 (struct scop): Add dep_graph field.
3711 (SCOP_DEP_GRAPH): Defined.
3712 (ref_nb_loops): Fixed and moved to other position.
3713 (bb_in_scop_p, loop_in_scop_p, nb_loops_around_gb): ... here.
3714 (nb_loops_around_loop_in_scop): New.
3715 (graphite_dump_dependence_graph): Declared.
3716 (graphite_build_rdg_all_levels): Declared.
3717 (graphite_test_dependence): Declared.
3718 * Makefile.in (graphite-data-ref.o): New target.
3720 2008-09-09 Sebastian Pop <sebastian.pop@amd.com>
3722 * Merge from mainline (139870:140164).
3724 2008-09-01 Sebastian Pop <sebastian.pop@amd.com>
3726 * Merge from mainline (138275:139870).
3727 * testsuite/gcc.dg/graphite/scop-matmult.c: XFailed as one of
3728 the commits from trunk broke the niter detection.
3730 2008-09-01 Sebastian Pop <sebastian.pop@amd.com>
3732 * graphite.c: Add more documentation. Fix formatting.
3733 (debug_loop_vec, debug_oldivs, loop_iv_stack,
3734 loop_iv_stack_debug): Moved...
3735 (schedule_to_scattering): Move before use.
3736 (dot_all_scops): Include in "#if 0" the code for system
3739 * graphite.h: (debug_loop_vec, debug_oldivs, loop_iv_stack,
3740 loop_iv_stack_debug): ...here.
3742 2008-08-29 Jan Sjodin <jan.sjodin@amd.com>
3744 * tree-phinodes.c (make_phi_node): Extern.
3745 (add_phi_node_to_bb): New.
3746 (create_phi_node): Call add_phi_node_to_bb.
3747 * tree-ssa-loop-ivopts.c (get_phi_with_result): New.
3748 (remove_statement): Handle case where stored phi was updated
3749 and is no longer the same.
3750 * graphite.c (is_parameter): New.
3752 (expand_scalar_variables_expr): New.
3753 (expand_scalar_variables_stmt): New.
3754 (expand_scalar_variables): New.
3755 (move_phi_nodes): Create new phi instead of moving old one.
3756 (translate_clast): Call expand_scalar_variables.
3757 (find_vdef_for_var_in_bb): Also scan regular definitions.
3758 (skip_phi_defs): New.
3759 (collect_scop_exit_phi_args): New.
3760 (patch_scop_exit_phi_args): New.
3761 (gloog): Patch phis after scop.
3762 * tree-flow.h: (add_phi_node_to_bb): Declared.
3763 (make_phi_node): Declared.
3765 2008-08-26 Sebastian Pop <sebastian.pop@amd.com>
3767 * graphite.c (end_scop): Split the entry of the scop when it
3768 is the header of the loop in which the scop is ending.
3769 (build_scops_1, limit_scops): Update uses of end_scop.
3771 2008-08-26 Sebastian Pop <sebastian.pop@amd.com>
3773 * graphite.c (dot_all_scops_1): Do not fail on uninitialized
3774 SCOP_ENTRY or SCOP_EXIT.
3776 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
3778 * graphite.c (get_construction_edge): Removed.
3779 (gloog): Construction edge is the scop entry edge.
3781 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
3783 * graphite.c (can_generate_for_scop): Removed.
3784 (gloog): Do not call it.
3786 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
3788 * graphite.c (new_scop): Entry of a scop is an edge.
3789 Initialize SESE region.
3790 (free_scop): Free SESE region.
3791 (build_scops_1, scopdet_bb_info): Work on edges, not on bbs.
3792 (split_difficult_bb): New, split from end_scop.
3793 (end_scop): Exit of a scop is an edge.
3794 (build_scop_bbs): Never check CDI_POST_DOMINATORS: this info is
3795 not automatically updated and thus is always wrong.
3796 * graphite.h (struct sese): New.
3799 (struct scop): New field for a SESE region. Remove entry, exit.
3800 (SCOP_ENTRY, SCOP_EXIT): Update definitions to match same
3801 semantics as before. Moved comment around.
3803 2008-08-25 Tobias Grosser <grosser@fim.uni-passau.de>
3804 Sebastian Pop <sebastian.pop@amd.com>
3806 * graphite.c (graphite_transform_loops): Always enable gloog
3807 and find_transform when ENABLE_CHECKING.
3809 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
3811 * graphite.c (graphite_transform_loops): Move pretty printer
3812 of SCOPs before doing any transform. Remove call to print_scops
3813 and dot_all_scops_1.
3815 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
3817 * graphite.c (dump_gbb_conditions): Don't try to print NULL pointers.
3818 (print_graphite_bb): Same.
3820 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
3822 * graphite.c (dot_all_scops_1): Cleanup.
3823 (move_scops): Fix comment.
3825 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
3827 * graphite.c (build_scop_bbs): Revert commit 139355:
3829 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
3830 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
3832 * graphite.c (build_scop_bbs): Factor up code.
3834 2008-08-25 Tobias Grosser <grosser@fim.uni-passau.de>
3836 * graphite.c (gloog): Update dominator info.
3838 2008-08-25 Tobias Grosser <grosser@fim.uni-passau.de>
3840 * graphite.c (remove_cond_exprs): Do not fail on empty bbs.
3842 2008-08-24 Sebastian Pop <sebastian.pop@amd.com>
3844 * graphite.c (new_graphite_bb): Remove GBB_INDEX_TO_NUM_MAP
3846 (free_graphite_bb): Remove GBB_INDEX_TO_NUM_MAP free.
3847 (translate_clast): Correct formatting.
3848 * graphite.h (struct num_map): Removed.
3849 (struct graphite_bb): Remove num_map field.
3850 (GBB_INDEX_TO_NUM_MAP): Removed.
3852 2008-08-24 Sebastian Pop <sebastian.pop@amd.com>
3854 * graphite.c (build_access_matrix_with_af): Fix comments.
3855 (build_scop_data_accesses): Same.
3857 2008-08-24 Sebastian Pop <sebastian.pop@amd.com>
3859 * graphite.c (build_scop_data_accesses): Don't construct
3860 access matrices. Add a FIXME and an assert condition that
3861 should pass when the access matrices will be needed.
3863 2008-08-24 Sebastian Pop <sebastian.pop@amd.com>
3865 * tree-data-ref.c (stmt_simple_memref_p): Don't call
3867 * graphite.c (build_graphite_bb): Renamed new_graphite_bb.
3868 Moved close by free_graphite_bb.
3869 (free_graphite_bb): Call free_data_refs. Reset bb->aux.
3870 (new_scop): Move close by free_scop.
3871 (graphite_transform_loops): Avoid linear scan to reset bb->aux.
3873 2008-08-22 Jan Sjodin <jan.sjodin@amd.com>
3875 * cfgloopmanip.c (create_empty_if_region_on_edge): New.
3876 * graphite.c (clast_to_gcc_expression): Call gmp_cst_to_tree
3877 instead of recursive call.
3878 (graphite_translate_clast_equation): New.
3879 (graphite_create_guard_cond_expr): New.
3880 (graphite_create_new_guard): New.
3881 (get_stack_index_from_iv): Removed.
3882 (graphite_rename_ivs_stmt): Use gbb_loop_index.
3883 (get_true_edge_from_guard_bb): New.
3884 (translate_clast): Handle stmt_guard in clast.
3885 (get_construction_edge): Allow construction edge detection for
3886 a scope entry with multiple predecessors if one predecessor is
3887 the immediate dominator of scope entry.
3888 (can_generate_code_stmt): Enable code generation for clast_guard.
3889 (gloog): Use correct context loop. Removed check for post dominators.
3890 * cfgloop.h (create_empty_if_region_on_edge): Declared.
3892 2008-08-21 Sebastian Pop <sebastian.pop@amd.com>
3894 * graphite.c (remove_dead_loops): Document better which
3897 2008-08-21 Sebastian Pop <sebastian.pop@amd.com>
3899 * Makefile.in: Rename POLYLIBLIBS and POLYLIBINC to PPLLIBS