1 2010-01-20 Sebastian Pop <sebastian.pop@amd.com>
3 * graphite-dependences.c (build_pairwise_constraint): Renamed
4 ppl_build_relation. Moved...
5 (dr_equality_constraints): Use ppl_build_relation.
6 (build_pairwise_scheduling_equality): Same.
7 (build_pairwise_scheduling_inequality): Same.
8 * graphite-ppl.c (ppl_build_relation): ...here.
9 * graphite-ppl.h (ppl_build_relation): Declared.
11 2010-01-14 Sebastian Pop <sebastian.pop@amd.com>
14 * graphite-clast-to-gimple.c (gloog_error): New static variable.
15 (clast_to_gcc_expression): Do not build MULT_EXPR of POINTER_TYPE_P.
16 Set gloog_error when such an expression failed to be built.
17 (translate_clast): Early return when gloog_error is set.
18 (gloog): Clear gloog_error. When gloog_error is set, call
19 set_ifsese_condition to enable the original code. Return the status
20 of the code generation based on gloog_error.
21 * sese.c (set_ifsese_condition): New.
22 * sese.h (set_ifsese_condition): Declared.
24 * testsuite/g++.dg/graphite/pr42681.C: New.
26 2010-01-14 Sebastian Pop <sebastian.pop@amd.com>
29 * graphite-clast-to-gimple.c (gloog): Call scev_reset_htab and
31 * sese.c (rename_variables_in_operand): New.
32 (rename_variables_in_expr): New.
33 (rename_nb_iterations): New.
34 (sese_adjust_liveout_phis): Update the rename_map.
35 * sese.h (rename_nb_iterations): Declared.
36 * tree-scalar-evolution.c (scev_reset_htab): New.
37 (scev_reset): Call scev_reset_htab.
38 * tree-scalar-evolution.h (scev_reset_htab): Declared.
40 * testsuite/gfortran.dg/graphite/pr42732.f: New.
42 2010-01-08 Sebastian Pop <sebastian.pop@amd.com>
45 * graphite-clast-to-gimple.c: Fix formatting.
46 * sese.c (defined_in_loop_p): Renamed name_defined_in_loop_p.
47 (expr_defined_in_loop_p): New.
48 (add_loop_exit_phis): Also handle full expressions: remove from
49 the rename_map the expressions defined in the loop that we're closing.
51 * testsuite/gfortran.dg/graphite/pr42393-1.f90: New.
52 * testsuite/gfortran.dg/graphite/pr42393.f90: Add new flags
53 -fno-loop-block -fno-loop-interchange -fno-loop-strip-mine to also
54 make this testcase useful in the Graphite branch.
56 2010-01-08 Sebastian Pop <sebastian.pop@amd.com>
58 * graphite-scop-detection.c (exclude_component_ref): Removed.
59 (is_simple_operand): Removed.
60 (stmt_simple_for_scop_p): Remove use of is_simple_operand.
62 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
65 * sese.c (expand_scalar_variables_expr): Follow the SSA links into
66 the array indexing of ADDR_EXPRs.
68 * testsuite/gcc.dg/graphite/pr42221.c: New.
70 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
73 * graphite.c (graphite_finalize): Call scev_reset.
74 (graphite_transform_loops): Do not call scev_reset between the code
77 * testsuite/gcc.dg/graphite/pr42521.c: New.
79 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
81 * graphite-interchange.c (memory_stride_in_loop): Renamed
83 (memory_strides_in_loop): Renamed memory_strides_in_loop_1.
84 (memory_strides_in_loop): Memoize the memory strides per loop.
85 (lst_interchange_profitable_p): Do not initialize to zero the memory
87 * graphite-poly.h (struct lst): Add a field memory_strides.
88 (LST_LOOP_MEMORY_STRIDES): New.
89 (new_lst_loop): Initialize LST_LOOP_MEMORY_STRIDES to -1.
90 (free_lst): Clear LST_LOOP_MEMORY_STRIDES.
92 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
94 * graphite-interchange.c (memory_strides_in_loop_depth): Renamed
95 memory_strides_in_loop. Gather memory strides on a whole loop.
96 (pbb_interchange_profitable_p): Renamed lst_interchange_profitable_p.
97 (lst_interchange_profitable_p): Removed.
98 (lst_try_interchange_loops): Call lst_interchange_profitable_p.
100 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
102 Revert patch 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
103 * graphite-clast-to-gimple.c (try_mark_loop_parallel): New.
104 (translate_clast_for, translate_clast_guard, translate_clast, gloog):
105 Remove context_loop and level.
107 2010-01-07 Richard Guenther <rguenther@suse.de>
109 PR tree-optimization/42641
110 * sese.c (rename_map_elt_info): Use the SSA name version, do
113 2010-01-06 Sebastian Pop <sebastian.pop@amd.com>
115 * graphite-blocking.c (scop_do_block): Print "SCoP will be loop
116 blocked" only when both the strip mine and the interchange have
119 * testsuite/gcc.dg/graphite/block-2.c: Removed.
120 * testsuite/gcc.dg/graphite/block-3.c: Add scan pattern.
121 * testsuite/gcc.dg/graphite/block-4.c: Same.
122 * testsuite/gcc.dg/graphite/block-5.c: Same.
123 * testsuite/gcc.dg/graphite/block-6.c: Same.
125 2010-01-06 Sebastian Pop <sebastian.pop@amd.com>
127 * graphite-clast-to-gimple.c (save_clast_name_index): Free slot
128 before allocating a new one.
129 (copy_renames): Check that slot is not NULL.
130 (mark_bb_with_pbb): Same.
131 (compute_cloog_iv_types_1): Same.
132 * graphite-interchange.c (lst_perfect_nestify): Free the before,
133 nest, and after LSTs.
134 (lst_try_interchange_loops): Same.
136 2010-01-05 Sebastian Pop <sebastian.pop@amd.com>
139 * graphite-interchange.c (lst_try_interchange_loops): Do not return
140 the before, nest, and after LSTs.
141 (lst_try_interchange): Removed.
142 (lst_interchange_select_inner): Do not iterate over the LSTs if they
144 (lst_interchange_select_outer): Apply interchange on the outer loop
145 until there are no more changes in the inner loops.
147 2009-12-18 Sebastian Pop <sebastian.pop@amd.com>
149 Revert patch fixing PR middle-end/42221.
151 2009-12-18 Sebastian Pop <sebastian.pop@amd.com>
154 * graphite-sese-to-poly.c (follow_ssa_with_commutative_ops): Handle
157 * testsuite/gfortran.dg/graphite/pr42180.f90: Add compile flags.
159 2009-12-18 Sebastian Pop <sebastian.pop@amd.com>
162 * graphite-sese-to-poly.c (split_reduction_stmt): Do not split blocks
163 that contain only one statement.
165 * testsuite/gfortran.dg/graphite/pr42180.f90: New.
167 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
170 * testsuite/gfortran.dg/graphite/pr42393.f90: New.
172 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
175 * testsuite/gfortran.dg/graphite/pr42186.f90: New.
177 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
180 * graphite-sese-to-poly.c (translate_scalar_reduction_to_array_for_stmt):
181 Insert the reduction copy in the same block as the phi node.
182 (follow_ssa_with_commutative_ops): Handle GIMPLE_NOPs.
184 * testsuite/gcc.dg/graphite/pr42205-1.c: New.
185 * testsuite/gcc.dg/graphite/pr42205-2.c: New.
187 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
190 * sese.c (expand_scalar_variables_expr): Follow the SSA links into
191 the array indexing of ADDR_EXPRs.
193 * testsuite/gcc.dg/graphite/pr42221.c: New.
195 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
199 * graphite-interchange.c (lst_try_interchange): Do not modify OUTER
200 index. Call lst_interchange_select_inner only once.
201 (lst_interchange_select_inner): Update use of lst_try_interchange.
202 (lst_interchange_select_outer): Update.
204 2009-12-15 Sebastian Pop <sebastian.pop@amd.com>
208 * graphite-interchange.c (lst_try_interchange): Do not increment the
209 the OUTER index when there is no AFTER kernel. Do not increment the
210 OUTER index for after processing the AFTER kernel.
211 (lst_interchange_select_inner): Call lst_try_interchange only on loops.
212 (lst_interchange_select_outer): Do not pass in a pointer to the OUTER
213 index. Do not pass to lst_interchange_select_inner the OUTER index.
214 (scop_do_interchange): Update use of lst_interchange_select_outer.
216 * testsuite/gfortran.dg/graphite/graphite.exp
217 (DEFAULT_FLAGS_GRAPHITE_IDENTITY): Remove -fdump-tree-graphite-all.
218 * testsuite/gfortran.dg/graphite/interchange-1.f: Add comment. Clean
219 the graphite dump file.
220 * testsuite/gfortran.dg/graphite/interchange-2.f: Same.
221 * testsuite/gfortran.dg/graphite/pr42334-1.f: New.
223 2009-12-15 Sebastian Pop <sebastian.pop@amd.com>
227 * graphite-interchange.c (lst_perfect_nestify): Reset to NULL the LSTs
229 (lst_do_interchange_1): Renamed lst_interchange_select_inner.
230 (lst_try_interchange): Reimplemented.
231 (lst_interchange_select_inner): Same.
232 (lst_do_interchange): Renamed lst_interchange_select_outer.
234 (scop_do_interchange): Update use of lst_interchange_select_outer.
236 * testsuite/g++.dg/graphite/pr42130.C: Add -fgraphite-identity.
237 * testsuite/gcc.dg/graphite/block-0.c: Un-XFAILed.
238 * testsuite/gcc.dg/graphite/pr42211.c: New.
239 * testsuite/gfortran.dg/graphite/pr42334.f90: New.
241 2009-12-14 Sebastian Pop <sebastian.pop@amd.com>
244 * graphite-scop-detection.c (graphite_can_represent_scev): Handle more
245 carefully PLUS_EXPR, MINUS_EXPR, and MULT_EXPR.
247 * testsuite/gfortran.dg/graphite/pr42181.f90: New.
249 2009-12-12 Sebastian Pop <sebpop@gmail.com>
252 * graphite-sese-to-poly.c (rewrite_close_phi_out_of_ssa): Call
253 insert_out_of_ssa_copy_on_edge for anything else than SSA_NAMEs.
254 (detect_commutative_reduction_arg): Simplified.
255 (detect_commutative_reduction): Early return when the argument of
256 the close phi is not of an SSA_NAME.
258 * testsuite/gcc.dg/graphite/pr42284.c: New.
260 2009-12-11 Alexander Monakov <amonakov@ispras.ru>
262 * dbgcnt.def (graphite_scop): New counter.
263 * graphite.c: Include dbgcnt.h
264 (graphite_transform_loops): Use new counter to limit transformations.
266 2009-12-08 Sebastian Pop <sebpop@gmail.com>
269 * graphite-scop-detection.c (graphite_can_represent_init): Also
270 handle more complex MULT_EXPRs containing parameters by recursion
273 * testsuite/gfortran.dg/graphite/pr42285.f90: New.
275 2009-12-01 Tobias Grosser <grosser@fim.uni-passau.de>
277 * testsuite/g++.dg/graphite/pr42130.C: Fix type.
279 2009-11-29 Alexander Monakov <amonakov@gcc.gnu.org>
281 * testsuite/g++.dg/graphite/pr42130.C: Correct testcase.
283 2009-11-24 Tobias Grosser <grosser@fim.uni-passau.de>
285 * graphite-clast-to-gimple.c (try_mark_loop_parallel,
286 graphite_create_new_loop_guard, translate_clast_for): Fix comments.
288 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
291 * graphite-clast-to-gimple.c (graphite_create_new_loop_guard,
292 translate_clast_for_loop): New.
293 (translate_clast_for): Add a condition around the loop, to do not
294 execute loops with zero iterations.
295 * testsuite/g++.dg/graphite/pr42130.C: New.
296 * testsuite/gcc.dg/graphite/pr35356-2.c: Adapt.
298 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
300 * graphite-clast-to-gimple.c (try_mark_loop_parallel): New.
301 (translate_clast_for, translate_clast_guard, translate_clast, gloog):
302 Remove context_loop and level.
304 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
306 * graphite-clast-to-gimple.c (translate_clast_user,
307 translate_clast_for, translate_clast_guard): Simplify and move common
308 elements to translate_clast().
309 (translate_clast): Simplify and get common elements.
311 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
313 * graphite-clast-to-gimple.c (translate_clast_user,
314 translate_clast_for, translate_clast_guard): Split out of
317 2009-11-21 Tobias Grosser <grosser@fim.uni-passau.de>
319 * graphite-clast-to-gimple.c (clast_name_index, new_clast_name_index,
320 clast_name_to_index, save_clast_name_index, debug_clast_name_index,
321 debug_clast_name_indexes_1, debug_clast_name_indexes,
322 clast_name_index_elt_info, eq_clast_name_indexes): Moved from sese.h.
323 (clast_name_to_gcc, clast_to_gcc_expression,
324 clast_to_gcc_expression_red, gcc_type_for_clast_expr,
325 gcc_type_for_clast_eq, graphite_translate_clast_equation,
326 graphite_create_guard_cond_expr, graphite_create_new_loop,
327 translate_clast): Add params_index.
328 (initialize_cloog_names): Create parameter strings from scratch, do
329 not reference other strings.
330 (create_params_index): New.
331 (gloog): Initialize params_index.
332 * graphite-scop-detection (free_scops_1): Removed.
333 (limit_scops): Use normal free_scops.
334 * graphite-sese-to-poly.c (save_var_names): Removed.
335 (parameter_index_in_region): Do not initialize SESE_PARAM_NAMES
336 and SESE_PARAMS_INDEX.
337 * sese.c (new_sese, free_sese): Dito.
338 * sese.h (struct sese): Remove params_index, params_names.
339 (SESE_PARAMS_INDEX, SESE_PARAMS_NAMES): Removed.
341 2009-11-20 Sebastian Pop <sebastian.pop@amd.com>
343 Revert the following patch from 2009-09-14:
344 * graphite-blocking.c: Fix order of includes: tree-chrec.h, then
345 tree-scalar-evolution.h, and then tree-data-ref.h.
346 * graphite-clast-to-gimple.c: Same.
347 * graphite-dependences.c: Same.
348 * graphite-interchange.c: Same.
349 * graphite-poly.c: Same.
350 * graphite-scop-detection.c: Same.
351 * graphite-sese-to-poly.c: Same.
353 * lambda-code.c: Same.
354 * matrix-reorg.c: Same.
355 * tree-data-ref.c: Same.
356 * tree-if-conv.c: Same.
357 * tree-loop-distribu: Same.: Same.
358 * tree-loop-linear.c: Same.
359 * tree-parloops.c: Same.
360 * tree-predcom.c: Same.
361 * tree-vect-patterns.c: Same.
363 2009-11-20 Sebastian Pop <sebastian.pop@amd.com>
365 Revert patch from 2009-09-14.
366 * tree-ssa-loop.c (gate_graphite_transforms): Re-enable Graphite
367 passes at -O1 and below.
369 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
372 * testsuite/gcc.dg/graphite/pr40281.c: New.
374 * tree-scalar-evolution.c (instantiate_scev_poly): Base and stride
375 evolutions should not variate in inner loops.
377 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
380 * testsuite/gfortran.dg/graphite/pr42050.f90: New.
382 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
384 * graphite-interchange.c (memory_strides_in_loop_depth): New.
385 (pbb_interchange_profitable_p): Call memory_strides_in_loop_depth.
387 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
389 * graphite-blocking.c (scop_do_block): New.
390 * graphite-poly.c (apply_poly_transforms): Call scop_do_block.
391 * graphite-poly.h (scop_do_block): Declared.
393 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
395 * graphite-blocking.c (pbb_strip_mine_profitable_p): The parameter
396 depth is the loop nesting depth in the LST. Call psct_dynamic_dim
397 to transform depth into the time_depth before calling
398 pbb_number_of_iterations_at_time.
399 (lst_do_strip_mine): Use a scalar variable instead of recomputing
402 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
404 Reverted the patch for "scattering permutations" from 2009-10-28.
406 * graphite-poly.c (print_permutation): New.
407 (debug_permutation): New.
408 (new_poly_bb): Initialize PBB_PERMUTATION.
409 (free_poly_bb): Free PBB_PERMUTATION.
410 * graphite-poly.h (pbb_permutation_elt_p): Declared.
411 (struct pbb_permutation_elt): New.
412 (PBB_PERMUTATION_ELT_STRIDE): New.
413 (PBB_PERMUTATION_ELT_STRIDED_P): New.
414 (PBB_PERMUTATION_ELT_TIME_DIMENSION): New.
415 (new_pbb_permutation_elt): New.
416 (pbb_permutation_elt_free): New.
417 (struct poly_bb): Add field permutation.
418 (PBB_PERMUTATION): New.
419 (print_permutation): Declared.
420 (debug_permutation): Declared.
422 2009-11-04 Konrad Trifunovic <konrad.trifunovic@inria.fr>
424 * graphite-interchange.c (build_partial_difference): New.
425 (memory_stride_in_loop): Refactored the computation of
426 equality constraints into build_partial_difference function.
427 Added support for debugging stride computations.
429 2009-11-03 Sebastian Pop <sebastian.pop@amd.com>
431 * graphite-clast-to-gimple.c (gloog): Free if_region,
432 if_region->true_region, and if_region->region.
433 * sese.c (if_region_set_false_region): Free if_region->false_region.
434 (create_if_region_on_edge): Do not use GGC_NEW.
435 (move_sese_in_condition): Remove useless initialization.
437 2009-11-03 Sebastian Pop <sebastian.pop@amd.com>
439 * graphite-interchange.c (lst_perfect_nestify): Pass 3 parameters
440 for the loops created by the loop distribution. Do not modify the
442 (lst_try_interchange_loops): Same. Use a temporary LST for the
443 transformed schedule. Call lst_update_scattering before data
445 (lst_try_interchange): Pass an extra parameter INDEX.
446 (lst_do_interchange_1): New.
447 (lst_do_interchange): Call lst_do_interchange_1.
448 (scop_do_interchange): Call lst_update_scattering.
449 * graphite-poly.c (apply_poly_transforms): Do not call
450 lst_update_scattering.
451 * graphite-poly.h (lst_pred): New.
453 (lst_find_first_pbb): Return NULL when not found.
455 (lst_insert_in_sequence): Allow LST1 to be NULL.
457 (lst_substitute_3): New.
458 * gcc.dg/graphite/interchange-1.c: XFail.
459 * gcc.dg/graphite/interchange-8.c: XFail.
460 * gcc.dg/graphite/interchange-11.c: XFail.
462 2009-10-30 Sebastian Pop <sebastian.pop@amd.com>
464 * graphite-interchange.c (lst_perfectly_nested_p): New.
465 (lst_perfect_nestify): New.
466 (lst_try_interchange_loops): Call store_lst_schedule,
467 lst_perfectly_nested_p, lst_perfect_nestify and restore_lst_schedule.
468 (scop_do_interchange): Avoid redundant legality test.
469 Call lst_do_interchange on a copy of SCOP_TRANSFORMED_SCHEDULE.
470 * graphite-poly.c (apply_poly_transforms): Call lst_update_scattering.
471 * graphite-poly.h (psct_static_dim): New.
472 (lst_dewey_number_at_depth): New.
473 (lst_find_pbb): Restructured.
474 (lst_find_first_pbb): Restructured.
475 (lst_find_last_pbb): New.
476 (lst_contains_p): New.
477 (lst_contains_pbb): New.
478 (lst_create_nest): New.
479 (lst_remove_from_sequence): New.
480 (pbb_update_scattering): New.
481 (lst_update_scattering_under): New.
482 (lst_update_scattering_seq): New.
483 (lst_update_scattering): New.
484 (lst_insert_in_sequence): New.
485 (lst_distribute_lst): New.
486 (lst_remove_all_before_including_pbb): New.
487 (lst_remove_all_before_excluding_pbb): New.
489 2009-10-30 Sebastian Pop <sebastian.pop@amd.com>
491 * tree-ssa-loop-niter.c (finite_loop_p): Do not call twice
494 2009-10-30 Sebastian Pop <sebastian.pop@amd.com>
496 * graphite-poly.c (pbb_remove_duplicate_pdrs): Free collapsed.
498 2009-10-28 Konrad Trifunovic <konrad.trifunovic@gmail.com>
500 * graphite-poly.c (print_permutation): New.
501 (debug_permutation): New.
502 (new_poly_bb): Initialize PBB_PERMUTATION.
503 (free_poly_bb): Free PBB_PERMUTATION.
504 * graphite-poly.h (pbb_permutation_elt_p): Declared.
505 (struct pbb_permutation_elt): New.
506 (PBB_PERMUTATION_ELT_STRIDE): New.
507 (PBB_PERMUTATION_ELT_STRIDED_P): New.
508 (PBB_PERMUTATION_ELT_TIME_DIMENSION): New.
509 (new_pbb_permutation_elt): New.
510 (pbb_permutation_elt_free): New.
511 (struct poly_bb): Add field permutation.
512 (PBB_PERMUTATION): New.
513 (print_permutation): Declared.
514 (debug_permutation): Declared.
516 2009-10-26 Sebastian Pop <sebastian.pop@amd.com>
518 * graphite-clast-to-gimple.c (gloog): Do not call
519 sese_reset_aux_in_loops.
520 * graphite-sese-to-poly.c (build_loop_iteration_domains): Pass an
521 extra argument for domains. Do not use loop->aux.
522 (build_scop_iteration_domain): Initialize and free domains, pass it
523 to build_loop_iteration_domains and extract the information from
524 domains. Do not use loop->aux.
525 * sese.c (sese_reset_aux_in_loops): Removed.
526 * sese.h (sese_reset_aux_in_loops): Removed.
528 2009-10-26 Sebastian Pop <sebastian.pop@amd.com>
530 * graphite-clast-to-gimple.c (find_pbb_via_hash): Moved up.
531 (dependency_in_loop_p): Same.
532 (translate_clast): Do not use loop->aux. Initialize
533 loop->can_be_parallel.
534 (mark_loops_parallel): Removed.
535 * graphite-clast-to-gimple.h (mark_loops_parallel): Removed.
536 * graphite.c (free_aux_in_new_loops): Removed.
537 (graphite_finalize): Do not call free_aux_in_new_loops.
538 (graphite_transform_loops): Do not call mark_loops_parallel.
540 2009-10-26 Li Feng <nemokingdom@gmail.com>
542 * graphite-clast-to-gimple.c (get_stmtfor_depth): Removed.
543 (translate_clast): Pass an extra parameter LEVEL.
544 Call get_scattering_level.
545 * graphite-clast-to-gimple.h (get_scattering_level): New.
547 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
549 * cfgloop.c (alloc_loop): Initialize loop->single_iv.
550 * cfgloop.h (struct loop): New field single_iv.
552 * graphite-clast-to-gimple.c (pbb_to_depth_to_oldiv): Do not use
553 loop->aux anymore: use loop->single_iv.
554 (graphite_loop_normal_form): Moved...
555 (build_graphite_loop_normal_form): Removed.
556 (gloog): Do not call build_graphite_loop_normal_form.
557 (free_aux_in_new_loops): Moved...
558 (mark_loops_parallel): Restructure.
559 * graphite-clast-to-gimple.h (free_aux_in_new_loops): Do not declare.
560 * graphite-sese-to-poly.c (graphite_loop_normal_form): ...here.
561 (scop_canonicalize_loops): New.
562 (build_poly_scop): Call scop_canonicalize_loops.
563 * graphite.c (free_aux_in_new_loops): ...here.
565 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
567 * g++.dg/graphite/graphite.exp: Add the same rules as in
568 gcc.dg/graphite/graphite.exp.
570 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
572 * g++.dg/graphite/id-1.C: New.
574 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
576 * graphite-sese-to-poly.c (create_zero_dim_array): Pass an extra
578 (rewrite_close_phi_out_of_ssa): Update use of create_zero_dim_array.
579 (rewrite_phi_out_of_ssa): Same.
580 (rewrite_cross_bb_scalar_deps): Same.
581 (translate_scalar_reduction_to_array): Same.
583 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
585 * graphite-sese-to-poly.c (build_scop_drs): Disable call to
588 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
590 * graphite-sese-to-poly.c (dump_alias_graphs): New.
591 (build_scop_drs): Call dump_alias_graphs.
593 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
595 * graphite-poly.c (new_scop): Initialize SCOP_ORIGINAL_SCHEDULE,
596 SCOP_TRANSFORMED_SCHEDULE, and SCOP_SAVED_SCHEDULE.
597 (free_scop): Call free_lst on SCOP_ORIGINAL_SCHEDULE,
598 SCOP_TRANSFORMED_SCHEDULE, and SCOP_SAVED_SCHEDULE.
599 * graphite-poly.h (free_lst): New.
600 (store_lst_schedule): Free SCOP_SAVED_SCHEDULE.
601 (restore_lst_schedule): Free SCOP_TRANSFORMED_SCHEDULE.
603 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
605 * graphite-poly.h (struct scop): Add a field saved_schedule.
606 (SCOP_SAVED_SCHEDULE): New.
607 (store_lst_schedule): New.
608 (restore_lst_schedule): New.
609 (store_scattering): Call store_lst_schedule.
610 (restore_scattering): Call restore_lst_schedule.
612 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
614 * graphite-sese-to-poly.c (free_data_refs_aux): Fix formatting.
615 (pdr_add_alias_set): Same.
616 (build_poly_dr): Same.
617 (build_alias_set_optimal_p): Same.
618 (build_base_obj_set_for_drs): Same. Do not store the result of
621 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
623 * graphite-sese-to-poly.c (build_alias_set_optimal_p): Initialize
624 all_components_are_cliques to 1.
626 2009-10-20 Li Feng <nemokingdom@gmail.com>
628 * graphite-sese-to-poly.c (free_data_refs_aux): Update to free
630 (pdr_add_alias_set): Update retrieving alias_set_num.
631 (build_poly_dr): Update retrieving dr_base_object_set.
632 (partition_drs_to_sets): Remove.
633 (build_alias_set_optimal_p): New.
634 (build_alias_set_for_drs): Rename.
635 (build_scop_drs): Update.
636 * graphite-sese-to-poly.h (struct base_alias_pair): New.
637 (ALIAS_SET_INDEX): Remove.
638 (BASE_OBJECT_SET_INDEX): Remove.
640 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
642 * sese.c (get_vdef_before_sese): Handle GIMPLE_ASSIGN and GIMPLE_CALL.
644 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
646 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Do not infer
647 loop upper bounds for 1-element arrays at end of structures.
648 * tree-flow.h (array_at_struct_end_p): Declared.
649 * tree-ssa-loop-niter.c (array_at_struct_end_p): Not static anymore.
651 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
653 * g++.dg/graphite/pr41305.C: New.
655 2009-10-20 Alexander Monakov <amonakov@ispras.ru>
657 * graphite-sese-to-poly.c (build_loop_iteration_domains): Generalize
658 construction of parameter constraints from loop iteration analysis.
659 * gcc.dg/graphite/run-id-2.c: New test.
661 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
663 * graphite-interchange.c (memory_stride_in_loop): Delete p1, lma
666 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
668 * graphite-dependences.c (dependence_polyhedron_1): Remove
669 unused gdim dimensions from the DDR polyhedron.
671 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
673 * graphite-dependences.c (pddr_transformed_scattering): New.
674 (dot_original_deps_stmt_1): New.
675 (dot_transformed_deps_stmt_1): New.
676 (dot_deps_stmt_1): Call dot_original_deps_stmt_1 and
677 dot_transformed_deps_stmt_1.
678 (dot_original_deps): New.
679 (dot_transformed_deps): New.
680 (dot_deps_1): Call dot_original_deps and dot_transformed_deps.
682 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
684 * graphite-dependences.c (reduction_dr_1): Remove wrong
685 assert: reduction BBs can have multiple reduction writes
686 to memory. interchange-3.f90 is an example.
688 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
690 * gfortran.dg/graphite/interchange-3.f90: New.
692 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
694 * gcc.dg/graphite/interchange-1.c: Un-XFAILed.
696 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
698 * graphite-dependences.c (dependence_polyhedron_1): Add the
699 context to the dependence polyhedron.
701 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
703 * graphite-poly.c (pbb_remove_duplicate_pdrs): Initialize
704 PBB_PDR_DUPLICATES_REMOVED.
707 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
709 * graphite-sese-to-poly.c (find_scop_parameters): Initialize
711 (build_loop_iteration_domains): Extract bounds on parameters
712 based on the data size.
713 (build_scop_context): Do not initialize SCOP_CONTEXT;
716 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
718 * graphite-ppl.c (ppl_min_for_le_polyhedron): New.
719 * graphite-ppl.h (graphite-ppl.h): Declared.
721 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
723 * graphite-ppl.c (ppl_print_linear_expr): New.
724 (debug_ppl_linear_expr): New.
725 * graphite-ppl.h (ppl_print_linear_expr): Declared.
726 (debug_ppl_linear_expr): Declared.
728 2009-10-16 Sebastian Pop <sebastian.pop@amd.com>
730 * graphite-interchange.c: Fix comments.
731 * gcc.dg/graphite/block-1.c: Fix comments.
733 2009-10-16 Sebastian Pop <sebastian.pop@amd.com>
735 * gcc.dg/graphite/interchange-7.c: Un-XFAILed.
736 * gcc.dg/graphite/interchange-9.c: Un-XFAILed.
738 2009-10-16 Sebastian Pop <sebastian.pop@amd.com>
740 Reapply the patch from Alexander Monakov that disappeared during
741 the last merges from trunk.
743 2009-09-16 Alexander Monakov <amonakov@ispras.ru>
745 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Add bounds only
746 for ARRAY_REFs. Use array_ref_{low,up}_bound to determine bounds.
748 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
750 * graphite-interchange.c (memory_stride_in_loop): The depth
751 argument corresponds to a dynamic time dimension, so use
752 psct_dynamic_dim to refer to the transformed scattering dimension.
754 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
756 * graphite-interchange.c (memory_stride_in_loop): Fix comments.
758 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
760 * graphite-blocking.c (lst_do_strip_mine): Avoid strip mining the
762 * graphite-interchange.c (lst_do_interchange): Avoid interchanging
764 * graphite-poly.c (scop_to_lst): Fix LST sequence in an outermost
766 (print_lst): Print the root of LST in a different format.
767 * graphite-poly.h (lst_depth): Adjust to include the root of the LST.
769 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
771 * graphite-poly.c (print_scop): Fix pretty printing of a SCoP.
773 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
775 * doc/passes.texi: Document the Graphite infrastructure.
777 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
779 * graphite-sese-to-poly.c (insert_copyin): Use gsi_insert_seq_on_edge.
780 (rewrite_commutative_reductions_out_of_ssa): Call gsi_commit_edge_inserts,
781 and check the SSA representation.
783 * gfortran.dg/graphite/id-18.f90: New, reduced from PR41193.
785 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
787 * gcc.dg/graphite/pr40157.c: Use -floop-block as reported in the PR.
789 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
791 * gcc.dg/graphite/interchange-11.c: New.
793 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
795 * gcc.dg/graphite/interchange-8.c: Enable loop interchange.
797 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
799 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK):
800 Add -fno-loop-strip-mine and -fno-loop-interchange.
801 (DEFAULT_FLAGS_GRAPHITE_INTERCHANGE): Add -fno-loop-block and
802 -fno-loop-strip-mine.
803 * gfortran.dg/graphite/graphite.exp: Same.
805 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
807 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK):
808 Renamed DEFAULT_FLAGS_GRAPHITE_BLOCK.
809 (DEFAULT_CFLAGS_GRAPHITE_IDENTITY): Renamed
810 DEFAULT_FLAGS_GRAPHITE_IDENTITY.
811 (DEFAULT_CFLAGS_GRAPHITE_INTERCHANGE): Renamed
812 DEFAULT_FLAGS_GRAPHITE_INTERCHANGE.
813 (DEFAULT_CFLAGS_GRAPHITE_SCOP): Renamed
814 DEFAULT_FLAGS_GRAPHITE_SCOP.
815 (DEFAULT_CFLAGS_RUN_ID): Renamed DEFAULT_FLAGS_RUN_ID.
816 (DEFAULT_CFLAGS_GRAPHITE): Renamed DEFAULT_FLAGS_GRAPHITE.
818 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
820 * graphite-poly.c (pbb_number_of_iterations_at_time): Cleanup comments.
822 2009-10-14 Konrad Trifunovic <konrad.trifunovic@gmail.com>
823 Sebastian Pop <sebastian.pop@amd.com>
825 * graphite-interchange.c (build_linearized_memory_access): Pass an
827 (memory_stride_in_loop): Include transform scattering in the
828 access functions to be able to querry the strides in the
830 (pbb_interchange_loop_depths): Interchange the psct_dynamic_dim,
831 not the psct_iterator_dim.
833 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
835 * graphite-blocking.c (pbb_do_strip_mine): Removed.
836 (lst_do_strip_mine_loop): New.
837 (lst_do_strip_mine): New.
838 (scop_do_strip_mine): Call lst_do_strip_mine.
839 * graphite-poly.h (lst_add_loop_under_loop): New.
840 (lst_find_first_pbb): New.
842 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
844 * graphite-poly.c (loop_to_lst): Fix LST creation.
846 2009-10-14 Tobias Grosser <grosser@fim.uni-passau.de>
848 * testsuite/gcc.dg/graphite/id-15.c: (8 * 8) replaced with
849 sizeof(unsigned long) to make it run on 32bit systems.
851 2009-10-14 Tobias Grosser <grosser@fim.uni-passau.de>
853 * testsuite/gcc.dg/graphite/run-id-1.c: Use smaller matrix to not
856 2009-10-14 Ramakrishna Upadrasta <Ramakrishna.Upadrasta@inria.fr>
858 * graphite-sese-to-poly.c (write_alias_graph_to_ascii_dimacs): Fix
860 (write_alias_graph_to_ascii_dot): New.
861 (write_alias_graph_to_ascii_ecc): Ditto.
862 (partition_drs_to_sets): Add testing of optimality of current method
863 which assigns alias numbers according to DFS Comopnent number. used
864 as heuristic for the upcoming ECC algorithm.
865 (build_scop_drs): Write to file also with the ecc and dot format.
867 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
869 * gfortran.dg/graphite/interchange-1.f: XFail.
871 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
873 * graphite.c (graphite_initialize): Do not handle functions with
874 more than 100 basic blocks.
876 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
878 * graphite-blocking.c (pbb_do_strip_mine): Use
879 PARAM_LOOP_BLOCK_TILE_SIZE.
881 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
883 * graphite-poly.c (dot_lst_1): New.
885 * graphite-poly.h (dot_lst): Declared.
887 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
889 * graphite-dependences.c (dot_deps_stmt_1): New.
890 (dot_deps_stmt): New.
891 * graphite-dependences.h (dot_deps_stmt): Declared.
893 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
895 * graphite-sese-to-poly.c (rewrite_cross_bb_scalar_dependence): Do
896 not replace cross BB scalar dependences ending on PHI nodes.
897 (rewrite_cross_bb_scalar_deps): Filter out GIMPLE_PHI nodes.
899 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
901 * graphite-poly.c (apply_poly_transforms): Implement the high
902 level driver for flag_loop_block.
903 * tree-ssa-loop.c (gate_graphite_transforms): Remove call to sorry for
906 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK): Add
908 * gfortran.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK):
911 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
913 * graphite-poly.h (lst_find_pbb): New.
914 (find_lst_loop): New.
916 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
918 * graphite-poly.c (new_scop): Remove init of SCOP_DEP_GRAPH.
919 * graphite-poly.h (struct scop): Remove dep_graph field.
920 (SCOP_DEP_GRAPH): Removed.
922 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
924 * graphite-poly.h (copy_lst): Do full copy of LST.
926 2009-10-07 Sebastian Pop <sebastian.pop@amd.com>
928 * graphite-sese-to-poly.c (reduction_phi_p): Call remove_invariant_phi
929 when the loop stride is zero.
931 * gcc.dg/graphite/id-16.c: New.
933 2009-10-06 Sebastian Pop <sebastian.pop@amd.com>
935 * graphite-dependences.c (reduction_dr_1): New.
936 (reduction_dr_p): New.
937 (graphite_legal_transform_dr): Call reduction_dr_p.
938 (reduction_ddr): Renamed reduction_ddr_p.
939 * graphite-poly.h (same_pdr_p): New.
940 (number_of_write_pdrs): New.
941 * graphite-sese-to-poly.c (nb_data_writes_in_bb): New.
942 (split_reduction_stmt): Do not split reduction statements
943 when there are no writes to memory.
944 (translate_scalar_reduction_to_array_for_stmt): Insert the
945 memory reduction statement just after the scalar reduction statement.
947 * gcc.dg/graphite/interchange-10.c: Updated to differ from interchange-4.c.
949 * gcc.dg/graphite/interchange-3.c: Un-XFAIL-ed.
950 * gcc.dg/graphite/interchange-4.c: Un-XFAIL-ed.
952 2009-10-06 Sebastian Pop <sebastian.pop@amd.com>
954 * graphite-interchange.c (lst_apply_interchange): New.
955 (lst_interchange_profitable_p): New.
956 (lst_try_interchange_loops): New.
957 (lst_try_interchange): New.
958 (lst_do_interchange): New.
959 (pbb_do_interchange): Removed.
960 (scop_do_interchange): Call lst_do_interchange.
962 2009-10-06 Sebastian Pop <sebastian.pop@amd.com>
964 * graphite-poly.c (print_scop): Print SCOP_ORIGINAL_SCHEDULE and
965 SCOP_TRANSFORMED_SCHEDULE.
970 * graphite-poly.h (lst_p): New.
973 (LST_LOOP_FATHER): New.
976 (scop_to_lst): Declared.
977 (print_lst): Declared.
978 (debug_lst): Declared.
983 (lst_dewey_number): New.
984 (struct scop): Add original_schedule and transformed_schedule fields.
985 (SCOP_ORIGINAL_SCHEDULE): New.
986 (SCOP_TRANSFORMED_SCHEDULE): New.
987 * graphite-sese-to-poly.c (build_poly_scop): Call scop_to_lst.
989 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
991 * graphite-dependences.c (reduction_ddr): New.
992 (graphite_legal_transform_bb): Call reduction_ddr.
993 * graphite-poly.c (new_poly_bb): Pass a new bool parameter.
994 Initialize PBB_IS_REDUCTION.
995 * graphite-poly.h (struct poly_bb): New bool field is_reduction.
996 (PBB_IS_REDUCTION): New.
997 (new_poly_bb): Update declaration.
998 * graphite-scop-detection.h (build_scop_bbs): Removed.
999 (nb_reductions_in_loop): Removed.
1000 * graphite-sese-to-poly.c (try_generate_gimple_bb): Pass a sbitmap
1001 parameter for reductions.
1002 (try_generate_gimple_bb): Update call to new_poly_bb.
1003 (build_scop_bbs_1): Same.
1004 (build_scop_bbs): Same.
1005 (gsi_for_phi_node): New.
1006 (scalar_close_phi_node_p): Remove gcc_assert.
1007 (split_reduction_stmt): New.
1008 (is_reduction_operation_p): New.
1009 (phi_contains_arg): New.
1010 (follow_ssa_with_commutative_ops): New.
1011 (detect_commutative_reduction_arg): New.
1012 (detect_commutative_reduction_assign): New.
1013 (follow_inital_value_to_phi): New.
1014 (edge_initial_value_for_loop_phi): New.
1015 (initial_value_for_loop_phi): New.
1016 (detect_commutative_reduction): New.
1017 (translate_scalar_reduction_to_array_for_stmt): New.
1018 (insert_copyout): New.
1019 (insert_copyin): New.
1020 (translate_scalar_reduction_to_array): New.
1021 (rewrite_commutative_reductions_out_of_ssa_close_phi): New.
1022 (rewrite_commutative_reductions_out_of_ssa_loop): New.
1023 (rewrite_commutative_reductions_out_of_ssa): New.
1024 (build_poly_scop): Call rewrite_commutative_reductions_out_of_ssa.
1025 * sese.h (split_region_for_bb): New.
1027 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK): Add -ffast-math.
1028 * gcc.dg/graphite/interchange-1.c: Fix format.
1029 * gcc.dg/graphite/interchange-10.c: New.
1031 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
1033 * graphite-sese-to-poly.c (insert_out_of_ssa_copy): Remove
1036 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
1038 * graphite-sese-to-poly.c (scev_analyzable_p): New.
1039 (rewrite_cross_bb_scalar_dependence): New.
1040 (rewrite_cross_bb_scalar_deps): New.
1041 (rewrite_reductions_out_of_ssa): Use bb_in_sese_p.
1042 Call rewrite_cross_bb_scalar_deps.
1044 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
1046 * graphite-sese-to-poly.c (gsi_for_ssa_name_def): Removed.
1047 (insert_out_of_ssa_copy): Directly use gsi_after_labels and
1050 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
1052 * graphite-clast-to-gimple.c (build_cloog_prog): Use pbb_index.
1053 * graphite-interchange.c (pbb_do_interchange): Same.
1054 * graphite-poly.c (print_scattering_function): Same.
1056 * graphite-poly.h (pbb_loop): New.
1057 * graphite-sese-to-poly.c (create_linear_expr_from_tree): Use pbb_loop.
1059 2009-09-27 Sebastian Pop <sebastian.pop@amd.com>
1061 * graphite-scop-detection.c (limit_scops): Do not build poly_bbs.
1063 2009-09-27 Sebastian Pop <sebastian.pop@amd.com>
1065 * graphite-sese-to-poly.c (partition_drs_to_sets): Drs is not modified,
1066 so don't pass a pointer to it.
1067 (build_alias_set_for_drs): Same.
1068 (build_base_obj_set_for_drs): Same.
1069 (build_scop_drs): Same.
1071 2009-09-26 Li Feng <nemokingdom@gmail.com>
1073 * graphite-sese-to-poly.c (build_scop_drs): Disable writing to file
1074 the alias graph of data references.
1076 2009-09-25 Li Feng <nemokingdom@gmail.com>
1078 * graphite-sese-to-poly.c (write_alias_graph_to_ascii_dimacs): New.
1079 (build_scop_drs): When debugging, write the alias graph to file,
1080 otherwise, should be disabled.
1082 2009-09-17 Sebastian Pop <sebastian.pop@amd.com>
1084 * graphite-scop-detection.c (stmt_simple_memref_p): Removed.
1085 (is_simple_operand): Remove call to stmt_simple_memref_p.
1086 (stmt_simple_for_scop_p): Update call to is_simple_operand.
1088 2009-09-17 David Edelsohn <edelsohn@gnu.org>
1090 * testsuite/gcc.dg/graphite/interchange-mvt.c: New File.
1091 * testsuite/gcc.dg/graphite/scop-dsyrk.c: New File.
1092 * testsuite/gcc.dg/graphite/scop-dsyr2k.c: New File.
1093 * testsuite/gcc.dg/graphite/scop-mvt.c: New File.
1094 * testsuite/gcc.dg/graphite/scop-sor.c: New File.
1096 2009-09-17 Li Feng <nemokingdom@gmail.com>
1099 * graphite-dependences.c (poly_drs_may_alias_p): Adjust definition.
1100 (pddr_original_scattering): Make sure 2 pdr2 in the same base object set.
1101 (graphite_carried_dependence_level_k): Ditto.
1102 * graphite-poly.c (new_poly_dr): Add init of PDR_BASE_OBJECT_SET.
1103 * graphite-poly.h (struct poly_dr): Add member dr_base_object_set.
1104 (new_poly_dr): Adjust declaration.
1105 * graphite-sese-to-poly.c (free_data_refs_aux): New.
1106 (free_gimple_bb): Added free_data_refs_aux.
1107 (build_poly_dr): Add dr_base_object_set.
1108 (partition_drs_to_sets): New.
1109 (dr_same_base_object_p): New.
1110 (build_alias_set_for_drs): New.
1111 (build_base_object_set_for_drs): New.
1112 (build_scop_drs): Add build_base_obj_set_for_drs.
1113 * graphite-sese-to-poly.h: Added #define for alias set number index and
1114 base object set index.
1115 * libgomp/testsuite/libgomp.graphite/force-parallel-6.c: Refine tests.
1116 * libgomp/testsuite/libgomp.graphite/pr4118.c: New.
1118 2009-09-16 Alexander Monakov <amonakov@ispras.ru>
1120 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Add bounds only
1121 for ARRAY_REFs. Use array_ref_{low,up}_bound to determine bounds.
1123 2009-09-14 Sebastian Pop <sebastian.pop@amd.com>
1125 * graphite-sese-to-poly.c (struct irp_data): Removed.
1126 (idx_record_params): Removed.
1127 (find_params_in_bb): Scan for parameters the access functions; don't
1128 parse the tree representation.
1130 2009-09-14 Sebastian Pop <sebastian.pop@amd.com>
1132 * tree-ssa-loop.c (gate_graphite_transforms): Disable Graphite
1133 passes at -O1 and below.
1135 2009-09-14 Sebastian Pop <sebastian.pop@amd.com>
1137 * graphite-blocking.c: Fix order of includes: tree-chrec.h, then
1138 tree-scalar-evolution.h, and then tree-data-ref.h.
1139 * graphite-clast-to-gimple.c: Same.
1140 * graphite-dependences.c: Same.
1141 * graphite-interchange.c: Same.
1142 * graphite-poly.c: Same.
1143 * graphite-scop-detection.c: Same.
1144 * graphite-sese-to-poly.c: Same.
1146 * lambda-code.c: Same.
1147 * matrix-reorg.c: Same.
1148 * tree-data-ref.c: Same.
1149 * tree-if-conv.c: Same.
1150 * tree-loop-distribu: Same.: Same.
1151 * tree-loop-linear.c: Same.
1152 * tree-parloops.c: Same.
1153 * tree-predcom.c: Same.
1154 * tree-vect-patterns.c: Same.
1156 2009-09-02 Sebastian Pop <sebastian.pop@amd.com>
1158 Partially revert the previous patch, except the following.
1159 * tree-scalar-evolution.c (instantiate_scev_not): Adapted to pass
1160 as parameters the operands of the not expression.
1162 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1164 * tree-scalar-evolution.c (instantiate_scev_assign): New.
1165 Do not call analyze_scalar_evolution on assignments.
1166 (instantiate_scev_phi): Call analyze_scalar_evolution.
1167 (instantiate_scev_name): Call instantiate_scev_assign and
1168 instantiate_scev_phi.
1169 (instantiate_scev_not): Adapted to pass as parameters the operands
1170 of the not expression.
1172 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1174 * tree-scalar-evolution.c (instantiate_scev_binary): Adapted
1175 to pass as parameters the operands of the binary expression.
1177 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1179 * tree-scalar-evolution.c (instantiate_scev_bitnot): Renamed
1180 instantiate_scev_not. Handle NEGATE_EXPR.
1181 (instantiate_scev_r): Handle NEGATE_EXPR.
1183 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1185 * tree-scalar-evolution.c (instantiate_scev_1): Renamed
1187 (instantiate_scev_r): Move code in instantiate_scev_2
1188 and instantiate_scev_1.
1190 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1192 * tree-scalar-evolution.c (instantiate_scev_3): New.
1193 (instantiate_scev_1): Move code in instantiate_scev_3.
1195 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1197 * tree-scalar-evolution.c (instantiate_scev_poly): New.
1198 (instantiate_scev_1): Move code in instantiate_scev_poly.
1200 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1202 * tree-scalar-evolution.c (instantiate_scev_bitnot): New.
1203 (instantiate_scev_1): Move code in instantiate_scev_bitnot.
1205 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1207 * tree-scalar-evolution.c (instantiate_scev_convert): New.
1208 (instantiate_scev_1): Move code in instantiate_scev_convert.
1210 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1212 * tree-scalar-evolution.c (instantiate_scev_binary): New.
1213 (instantiate_scev_1): Move code in instantiate_scev_binary.
1215 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1217 * tree-scalar-evolution.c (instantiate_scev_name): New.
1218 (instantiate_scev_1): Move code in instantiate_scev_name.
1220 2009-08-28 Sebastian Pop <sebastian.pop@amd.com>
1222 * Merge from mainline (150992:151171).
1224 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
1226 * graphite-dependences.c (graphite_legal_transform_bb): Call
1227 pbb_remove_duplicate_pdrs.
1228 * graphite-poly.c (can_collapse_pdr): Removed.
1229 (pdr_find_duplicate): Removed.
1230 (can_collapse_pdrs): New.
1231 (pbb_remove_duplicate_pdrs): New.
1232 (new_poly_dr): Do not look for duplicates.
1233 * graphite-poly.h (struct poly_bb): New field pdr_duplicates_removed.
1234 (PBB_PDR_DUPLICATES_REMOVED): New.
1235 (pbb_remove_duplicate_pdrs): Declared.
1237 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
1239 * graphite-interchange.c (pbb_interchange_profitable_p): Adjust
1240 the strides by multiplying by PDR_NB_REFS.
1241 * graphite-poly.c (can_collapse_pdr): New.
1242 (pdr_find_duplicate): New.
1243 (new_poly_dr): Call pdr_find_duplicate. Collapse duplicate PDRs.
1244 Initialize PDR_NB_REFS.
1245 * graphite-poly.h (struct poly_dr): Add field nb_refs.
1247 (new_poly_dr): Number of subscripts is a graphite_dim_t.
1249 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
1251 Revert one of the previous commits:
1252 * graphite-dependences.c (graphite_legal_transform_bb): Avoid
1253 the computation of symmetric data dependence relations.
1254 (dependency_between_pbbs_p): Same.
1256 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
1259 * graphite-poly.c (apply_poly_transforms): Remove legality test before
1262 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
1264 * graphite-dependences.c (pddr_original_scattering): Return NULL
1265 for read-read dependence relations.
1266 * graphite-poly.h (enum poly_dr_type): Fix comment.
1269 (pdr_may_write_p): New.
1271 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
1273 * graphite-poly.h (enum POLY_DR_TYPE): Renamed poly_dr_type.
1274 (struct poly_dr): Same.
1275 (new_poly_dr): Same.
1276 * graphite-poly.c (new_poly_dr): Same.
1278 2009-08-25 Konrad Trifunovic <konrad.trifunovic@gmail.com>
1279 Sebastian Pop <sebastian.pop@amd.com>
1281 * graphite-blocking.c (pbb_strip_mine_loop_depth): Renamed
1282 pbb_strip_mine_time_depth. Changed the implementation so that
1283 transformation is expressed as a transformation on
1284 time (scatttering) dimensions. Also, ensures that the 2d+1
1285 scheduling format is preserved.
1286 (pbb_strip_mine_profitable_p): Profitability is based on the
1287 iteration number of a given time (scattering) dimension,
1288 and not on a original loop depth dimension.
1289 (pbb_strip_mine): Call pbb_number_of_iterations_at_time.
1290 (pbb_do_strip_mine): Call psct_dynamic_dim.
1291 * graphite-poly.c (pbb_number_of_iterations_at_time): New.
1292 * graphite-poly.h (pbb_number_of_iterations_at_time): Declared.
1293 (pbb_nb_dynamic_scattering_transform): New.
1294 (psct_dynamic_dim): New.
1296 2009-08-25 Konrad Trifunovic <konrad.trifunovic@gmail.com>
1298 * graphite-ppl.c (ppl_max_for_le): Renamed ppl_max_for_le_pointset.
1299 * graphite-ppl.h (ppl_max_for_le): Renamed ppl_max_for_le_pointset.
1300 * graphite-poly.c (pbb_number_of_iterations): Rename ppl_max_for_le.
1301 * graphite-interchange.c (build_linearized_memory_access): Same.
1302 (memory_stride_in_loop): Same.
1304 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
1306 * graphite-dependences.c (pddr_original_scattering): New.
1307 (graphite_legal_transform_dr): Call pddr_original_scattering.
1310 * graphite-dependences.h (dot_deps): Declared.
1311 * graphite-poly.c (new_poly_dr): Initialize PDR_ID.
1312 (print_pdr): Print PDR_ID.
1313 * graphite-poly.h (struct poly_dr): Add field id.
1316 * graphite-scop-detection.c (dot_all_scops_1): Cleanup comment.
1318 2009-08-22 Sebastian Pop <sebastian.pop@amd.com>
1320 * graphite-dependences.c (graphite_carried_dependence_level_k): Do
1321 not delete the original dependence relation.
1323 2009-08-21 Sebastian Pop <sebastian.pop@amd.com>
1325 * graphite-dependences.c (graphite_legal_transform_bb): Avoid
1326 the computation of symmetric data dependence relations.
1327 (dependency_between_pbbs_p): Same.
1329 2009-08-21 Sebastian Pop <sebastian.pop@amd.com>
1331 * graphite-dependences.c (new_poly_dr_pair): Renamed new_poly_ddr.
1332 (eq_poly_dr_pair_p): Renamed eq_poly_ddr_p.
1333 (hash_poly_dr_pair_p): Renamed hash_poly_ddr_p.
1334 (free_poly_ddr): New.
1335 (pddr_is_empty): New.
1336 (dependence_polyhedron_1): Now returns a poly_ddr_p.
1337 (dependence_polyhedron): Same. Remove useless gcc_assert.
1339 (graphite_legal_transform_dr): Call pddr_is_empty and free_poly_ddr.
1340 (graphite_carried_dependence_level_k): Call pddr_is_empty.
1341 * graphite-dependences.h (enum poly_dependence_kind): New.
1342 (poly_dr_pair): Renamed poly_ddr. Added a field kind.
1343 (PDRP_SOURCE): Renamed PDDR_SOURCE.
1344 (PDRP_SINK): Renamed PDDR_SINK.
1345 (PDRP_DDP): Renamed PDDR_DDP.
1347 (free_poly_ddr): Declared.
1348 * graphite-poly.c (new_scop): Use the new hash function names.
1349 * graphite-poly.h (struct scop): Renamed field original_pdr_pairs
1350 into original_pddrs.
1351 (SCOP_ORIGINAL_PDR_PAIRS): Renamed SCOP_ORIGINAL_PDDRS.
1353 2009-08-21 Sebastian Pop <sebastian.pop@amd.com>
1355 * Merge from mainline (150764:150992).
1357 2009-08-18 Sebastian Pop <sebastian.pop@amd.com>
1359 * cfgloopmanip.c (create_empty_loop_on_edge): Generate upper
1360 bounds with LT_EXPR to make niter analysis more precise on code
1361 generated by Graphite.
1363 2009-08-18 Sebastian Pop <sebastian.pop@amd.com>
1365 * graphite-dependences.c (graphite_legal_transform_dr): Fix formatting.
1366 (graphite_legal_transform_bb): Same.
1367 (poly_drs_may_alias_p): Same.
1369 2009-08-15 Sebastian Pop <sebastian.pop@amd.com>
1372 * graphite-ppl.c (ppl_max_for_le): Correct the use of
1373 ppl_Pointset_Powerset_C_Polyhedron_maximize.
1375 2009-08-13 Sebastian Pop <sebastian.pop@amd.com>
1377 * graphite-poly.c (print_pbb): Print PBB index.
1379 2009-08-13 Sebastian Pop <sebastian.pop@amd.com>
1381 * Merge from mainline (r150672:150764).
1383 2009-08-13 Sebastian Pop <sebastian.pop@amd.com>
1385 * graphite-interchange.c (ppl_max_for_le): Moved...
1386 * graphite-poly.c (pbb_number_of_iterations): Call ppl_max_for_le.
1387 * graphite-ppl.c (ppl_max_for_le): ... here.
1388 * graphite-ppl.h (ppl_max_for_le): Declared.
1390 2009-08-12 Sebastian Pop <sebastian.pop@amd.com>
1392 * Merge from mainline (r150372:150672).
1394 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
1397 * sese.c (convert_for_phi_arg): New.
1398 (add_guard_exit_phis): Use convert_for_phi_arg.
1400 * testsuite/gfortran.dg/graphite/id-17.f: New.
1402 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
1404 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Dont add
1405 unknown subscript upper bounds.
1407 * testsuite/gcc.dg/graphite/interchange-6.c: Un-XFAIL.
1409 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
1410 Pranav Garg <pranav.garg2107@gmail.com>
1412 * graphite-interchange.c (gather_access_strides): Removed.
1413 (ppl_max_for_le): New.
1414 (build_linearized_memory_access): New.
1415 (memory_stride_in_loop): New.
1416 (pbb_interchange_profitable_p): Reimplemented.
1417 * graphite-ppl.h (ppl_new_id_map): New.
1418 (ppl_interchange): New.
1420 * testsuite/gcc.dg/graphite/interchange-6.c: XFAILed.
1422 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
1424 * graphite-interchange.c (compute_subscript): Removed.
1425 (compute_array_size_cstr): Removed.
1426 (compute_array_size_poly): Removed.
1427 (compute_array_size): Removed.
1428 (gather_access_strides_poly): Removed.
1429 (gather_access_strides): Empty.
1431 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
1433 * graphite-dependences.c (dependence_polyhedron_1): Replace
1434 pdr_nb_subscripts with PDR_NB_SUBSCRIPTS.
1435 (graphite_legal_transform_dr): Same.
1436 (graphite_carried_dependence_level_k): Same.
1437 * graphite-poly.c (new_poly_dr): Add a parameter nb_subscripts.
1438 Initialize PDR_NB_SUBSCRIPTS.
1439 (print_pdr_access_layout): Replace pdr_nb_subscripts with
1441 * graphite-poly.h (struct poly_dr): Add nb_subscripts field.
1442 (PDR_NB_SUBSCRIPTS): New.
1443 (pdr_nb_subscripts): Removed.
1444 (pdr_dim): Simplified.
1445 * graphite-sese-to-poly.c (build_poly_dr): Replace pdr_nb_subscripts
1446 with PDR_NB_SUBSCRIPTS.
1448 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
1450 * graphite-interchange.c (compute_array_size): Remove use of
1452 * graphite-poly.c (new_poly_dr): Remove argument data_container.
1453 Do not initialize PDR_DATA_CONTAINER.
1454 (print_pdr): Do not print PDR_DATA_CONTAINER.
1455 * graphite-poly.h (struct poly_dr): Remove data_container field.
1456 (PDR_DATA_CONTAINER): Removed.
1457 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Remove use of
1459 (build_poly_dr): Same.
1461 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
1463 * testsuite/gcc.dg/graphite/interchange-9.c: New.
1465 2009-08-05 Konrad Trifunovic <konrad.trifunovic@gmail.com>
1466 Sebastian Pop <sebastian.pop@amd.com>
1468 * graphite-dependences.c (graphite_legal_transform_dr): Work on a
1469 copy of the dependence polyhedron. Free the temporary objects.
1470 (graphite_carried_dependence_level_k): Free unused objects before
1473 * testsuite/gcc.dg/graphite/interchange-1.c: XFAILed.
1474 * testsuite/gcc.dg/graphite/interchange-2.c: XFAILed.
1475 * testsuite/gcc.dg/graphite/interchange-3.c: XFAILed.
1476 * testsuite/gcc.dg/graphite/interchange-4.c: XFAILed.
1477 * testsuite/gcc.dg/graphite/interchange-7.c: XFAILed.
1479 2009-08-05 Sebastian Pop <sebastian.pop@amd.com>
1481 * graphite-blocking.c (scop_do_strip_mine): Call store_scattering.
1482 Early return without analyzing the data dependences if no
1483 transform has been done. Call restore_scattering if the transform
1485 (graphite-interchange.c): Same.
1486 * graphite-poly.c (print_scattering_function): Test for PBB_TRANSFORMED.
1487 (graphite_read_transforms): Initialize PBB_TRANSFORMED.
1488 (apply_poly_transforms): Do not gcc_assert that
1489 the transform is legal.
1490 (new_poly_bb): Initialize PBB_TRANSFORMED, PBB_SAVED, and PBB_ORIGINAL.
1491 Do not initialize PBB_NB_SCATTERING_TRANSFORM, PBB_NB_LOCAL_VARIABLES,
1492 PBB_TRANSFORMED_SCATTERING, and PBB_ORIGINAL_SCATTERING.
1493 (free_poly_dr): Free PBB_TRANSFORMED, PBB_SAVED, and PBB_ORIGINAL.
1494 * graphite-poly.h (struct poly_scattering): New.
1495 (struct poly_bb): Add original, transformed, and saved fields.
1496 Remove transformed_scattering, original_scattering, nb_local_variables,
1497 and nb_scattering_transform fields.
1498 (PBB_ORIGINAL, PBB_TRANSFORMED, PBB_SAVED): New.
1499 (poly_scattering_new): New.
1500 (poly_scattering_free): New.
1501 (poly_scattering_copy): New.
1502 (store_scattering_pbb): New.
1503 (store_scattering): New.
1504 (restore_scattering_pbb): New.
1505 (restore_scattering): New.
1506 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons):
1507 Initialize PBB_TRANSFORMED and PBB_ORIGINAL.
1509 2009-08-05 Sebastian Pop <sebastian.pop@amd.com>
1511 * graphite-poly.c (print_pbb): Add parentheses in the pretty print.
1514 2009-08-05 Sebastian Pop <sebastian.pop@amd.com>
1516 * Makefile.in (graphite.o): Depends on PREDICT_H.
1517 * graphite.c: Include predict.h.
1518 (graphite_finalize): Call tree_estimate_probability.
1519 * predict.c (predict_loops): Do not call scev_initialize and
1521 (tree_estimate_probability_bb): New.
1522 (tree_estimate_probability): Do not initialize loops: move that
1523 code to the driver. Call tree_estimate_probability_bb.
1524 (tree_estimate_probability_driver): New.
1525 (pass_profile): Use tree_estimate_probability_driver.
1526 * predict.h (tree_estimate_probability): Declared.
1528 2009-08-05 Sebastian Pop <sebastian.pop@amd.com>
1530 * graphite-clast-to-gimple.c (gloog): Add time to TV_GRAPHITE_CODE_GEN.
1531 * graphite-dependences.c (graphite_legal_transform): Add time to
1532 TV_GRAPHITE_DATA_DEPS.
1533 (dependency_between_pbbs_p): Same.
1534 * timevar.def (TV_GRAPHITE_DATA_DEPS, TV_GRAPHITE_CODE_GEN): New.
1536 2009-08-03 Sebastian Pop <sebastian.pop@amd.com>
1538 * Merge from mainline (r149952:150372).
1540 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
1542 * ChangeLog.graphite: Fix indenting, white spaces and 80 columns.
1543 * graphite-blocking.c: Same.
1544 * graphite-clast-to-gimple.c: Same.
1545 * graphite-dependences.c: Same.
1546 * graphite-poly.c: Same.
1547 * graphite-poly.h: Same.
1548 * graphite-ppl.c: Same.
1549 * graphite-scop-detection.c: Same.
1550 * graphite-sese-to-poly.c: Same.
1553 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
1555 * graphite-sese-to-poly.c (loop_entry_phi_arg): New.
1556 (remove_simple_copy_phi): New.
1557 (remove_invariant_phi): New.
1558 (simple_copy_phi_p): New.
1559 (reduction_phi_p): New.
1560 (gsi_for_ssa_name_def): New.
1561 (insert_out_of_ssa_copy): New.
1562 (insert_out_of_ssa_copy_on_edge): New.
1563 (create_zero_dim_array): New.
1564 (scalar_close_phi_node_p): New.
1565 (rewrite_close_phi_out_of_ssa): New.
1566 (rewrite_phi_out_of_ssa): New.
1567 (rewrite_reductions_out_of_ssa): New.
1568 (build_poly_scop): Call rewrite_reductions_out_of_ssa.
1570 * testsuite/gcc.dg/graphite/id-11.c: New.
1571 * testsuite/gcc.dg/graphite/id-15.c: New.
1572 * testsuite/gcc.dg/graphite/interchange-1.c: Un-XFAIL.
1573 * testsuite/gcc.dg/graphite/interchange-2.c: Un-XFAIL.
1574 * testsuite/gcc.dg/graphite/interchange-3.c: Un-XFAIL.
1575 * testsuite/gcc.dg/graphite/interchange-4.c: Un-XFAIL.
1576 * testsuite/gcc.dg/graphite/interchange-7.c: Un-XFAIL.
1577 * testsuite/gcc.dg/graphite/scop-matmult.c: Un-XFAIL.
1578 * testsuite/gfortran.dg/graphite/id-13.f: New.
1579 * testsuite/gfortran.dg/graphite/id-5.f: New.
1581 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
1583 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not
1584 check that nb_reductions_in_loop is zero.
1585 * graphite-scop-detection.c (harmful_stmt_in_bb): Don't filter out
1586 reduction phi nodes.
1587 (nb_reductions_in_loop): Removed.
1588 (graphite_can_represent_loop): Do not call nb_reductions_in_loop.
1589 * graphite-sese-to-poly.c (phi_node_is_iv): Removed.
1590 (bb_contains_non_iv_scalar_phi_nodes): Removed.
1591 (scop_contains_non_iv_scalar_phi_nodes): Removed.
1592 (build_poly_scop): Do not call scop_contains_non_iv_scalar_phi_nodes.
1594 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
1596 * graphite-clast-to-gimple.c (build_cloog_prog): Do not code generate
1597 statements that have an empty iteration domain.
1598 * testsuite/gfortran.dg/graphite/id-16.f: New.
1600 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
1602 * tree-scalar-evolution.c (instantiate_scev_1): Return
1603 chrec_dont_know when the result is not above instantiate_below.
1604 * graphite-scop-detection.c (scopdet_basic_block_info): Fix formatting.
1605 * graphite-sese-to-poly.c (create_linear_expr_from_tree): Assert that
1606 the tree has a known scalar evolution.
1607 * testsuite/gfortran.dg/graphite/id-14.f: New.
1608 * testsuite/gfortran.dg/graphite/id-15.f: New.
1610 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
1612 * sese.c (rename_variables_in_stmt): Pass in an extra parameter
1614 (rename_variables): Keep inserting renames after the ones already
1617 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
1619 * graphite-sese-to-poly.c (compare_bb_depths): New.
1620 (graphite_sort_dominated_info): New.
1621 (build_scop_bbs_1): Call graphite_sort_dominated_info.
1622 (build_scop_scattering): Fix comment.
1624 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
1626 * graphite.c (graphite_finalize): Call print_loops instead of
1627 dump_function_to_file.
1628 * testsuite/gcc.dg/graphite/graphite.exp: Fix formatting.
1629 * testsuite/gcc.dg/graphite/pr35356-1.c: New. Look for the number of
1630 loops generated in the graphite output file.
1631 * testsuite/gcc.dg/graphite/pr35356-2.c: New.
1632 * testsuite/gcc.dg/graphite/pr35356-3.c: New. XFAILed for now.
1633 * testsuite/gfortran.dg/graphite/id-12.f: New.
1635 2009-07-24 Li Feng <nemokingdom@gmail.com>
1637 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-8.c:
1640 2009-07-24 Li Feng <nemokingdom@gmail.com>
1641 Tobias Grosser <grosser@fim.uni-passau.de>
1643 * graphite-sese-to-poly.c (pdr_add_alias_set): Use data reference's
1644 alias set number build alias in ACCESSES polyhedron.
1645 (build_alias_set_for_drs): New.
1646 (build_pbb_drs): Added build_alias_set_for_drs.
1647 * graphite-dependences.c (poly_drs_may_alias_p): New.
1648 (graphite_carried_dependence_level_k): Check alias information
1649 before building polyhedron.
1651 2009-07-24 Tobias Grosser <grosser@fim.uni-passau.de>
1653 * Makefile.in (lambda-code.o): Fix formatting.
1655 2009-07-24 Tobias Grosser <grosser@fim.uni-passau.de>
1657 * Merge from mainline (r149350-149952)
1659 2009-07-18 Tobias Grosser <grosser@fim.uni-passau.de>
1661 * graphite-poly.c (apply_poly_transforms): Move strip_mine
1662 before interchange to prepare for loop blocking.
1664 2009-07-18 Tobias Grosser <grosser@fim.uni-passau.de>
1666 * graphite-poly.c (apply_poly_transforms): Add checks after every
1668 * graphite-sese-to-poly.c (build_poly_scop): Remove check, as already
1669 done in apply_poly_transforms.
1671 2009-07-17 Konrad Trifunovic <konrad.trifunovic@gmail.com>
1673 * graphite-dependences.c (build_lexicographically_gt_constraint):
1674 Replace RES parameter with *RES.
1675 (dependence_polyhedron_1): Pass an address of the parameter RES
1676 instead of value of RES.
1678 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
1680 * graphite.c (graphite_finalize): Fix comment.
1681 (graphite_transform_loops): Reset scev info after code generation
1684 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
1686 * graphite.c (graphite_finalize): Call scev_reset.
1688 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
1690 * graphite-clast-to-gimple.c (compute_cloog_iv_types): Do not create
1691 GBB_CLOOG_IV_TYPES hash table twice.
1692 * graphite-sese-to-poly.c (free_gimple_bb): Call free_data_refs.
1693 (add_condition_to_domain): Clear GMP values.
1695 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
1697 * graphite-dependences.c: Fix formatting.
1698 * graphite-poly.c (free_poly_dr): Also free PDR_DATA_CONTAINER.
1699 (pbb_number_of_iterations): Free ppl_Linear_Expression.
1700 * graphite-sese-to-poly.c: Fix formatting.
1701 * graphite.c (graphite_transform_loops): Create the hash table
1702 after the early return.
1704 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
1706 * testsuite/gcc.dg/graphite/id-14.c: New.
1707 * testsuite/gcc.dg/graphite/pr40157.c: New.
1708 * testsuite/gfortran.dg/graphite/id-11.f: New.
1710 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
1712 * graphite-sese-to-poly.c (nb_pbbs_in_loops): New.
1713 (build_poly_scop): Return false when there are no pbbs within
1714 loops to avoid to pass to cloog scops with no loops.
1716 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
1718 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons): Avoid
1719 useless test "i % 2".
1720 (build_pbb_scattering_polyhedrons): Fix formatting.
1721 (build_poly_dr): Same.
1722 * graphite.c (graphite_transform_loops): Restructure.
1724 2009-07-14 Razya Ladelsky <razya@il.ibm.com>
1726 * tree-ssa-loop-manip.c (rewrite_phi_with_iv): Remove
1727 reduction_list parameter.
1728 (rewrite_all_phi_nodes_with_iv): Same.
1729 (canonicalize_loop_ivs): Same.
1730 * tree-parloops.c (struct brli): Removed.
1731 (build_reduction_list_info): Removed.
1732 (build_new_reduction): New.
1733 (analyze_reduction_list): Removed.
1734 (gather_scalar_reductions): Find reductions instead of phi
1735 nodes that can't be canonicalized.
1736 (try_create_reduction_list): Remove reduction_list parameter.
1737 (gen_parallel_loop): Same.
1738 (parallelize_loops): Remove analyze_reductions variable,
1739 initialization and free.
1740 Change reduction_list htab initialization to reduction_info
1741 elements instead of ssa names.
1742 Call try_create_reduction_list and gen_parallel_loop without
1743 analyzed_reduction argument.
1744 * graphite-clast-to-gimple (graphite_loop_normal_form): Call
1745 canonicalize_loop_ivs with one less argument.
1746 * tree-flow.h (canonicalize_loop_ivs): Remove one argument.
1748 2009-07-14 Konrad Trifunovic <konrad.trifunovic@gmail.com>
1750 * graphite-dependences.c (new_poly_dr_pair): New.
1751 (dependence_polyhedron): Renamed into dependence_polyhedron_1.
1752 (new_poly_dr_pair): New.
1753 (eq_poly_dr_pair_p): New.
1754 (hash_poly_dr_pair_p): New.
1755 * graphite-dependences.h (struct poly_dr_pair): New.
1756 (eq_poly_dr_pair_p): Declared.
1757 (hash_poly_dr_pair_p): Declared.
1758 * graphite-poly.c (new_scop): Initialize SCOP_ORIGINAL_PDR_PAIRS.
1759 (free_scop): Free SCOP_ORIGINAL_PDR_PAIRS.
1760 * graphite-poly.h (struct scop): Add original_pdr_pairs field.
1761 * Makefile.in (graphite-poly.o): Add dependence on
1762 graphite-dependences.h.
1764 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
1766 * graphite-scop-detection.c (graphite_can_represent_scev): Do not let
1767 polynomials of degree > 1 pass to Graphite.
1768 * tree-chrec.c (scev_is_linear_expression): Call
1769 evolution_function_is_affine_multivariate_p.
1770 * testsuite/gfortran.dg/graphite/id-10.f90: New.
1772 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
1774 * tree-scalar-evolution.c (compute_overall_effect_of_inner_loop):
1775 Instantiate scevs varying in outer loops.
1776 * testsuite/gfortran.dg/graphite/id-9.f: Correct testcase.
1778 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
1780 * graphite-sese-to-poly.c (build_loop_iteration_domains): Do not insert
1781 redundant constraint.
1783 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
1785 * testsuite/gcc.dg/graphite/graphite.exp: Fix comments.
1786 * testsuite/gfortran.dg/graphite/graphite.exp: Trigger actions
1787 based on the file names as in the C testsuite.
1788 * testsuite/gfortran.dg/graphite/block-1.f90: Fix patterns.
1789 * testsuite/gfortran.dg/graphite/block-2.f: Same.
1790 * testsuite/gfortran.dg/graphite/block-3.f90: Same.
1791 * testsuite/gfortran.dg/graphite/block-4.f90: Same.
1792 * testsuite/gfortran.dg/graphite/id-1.f90: Same.
1793 * testsuite/gfortran.dg/graphite/id-2.f90: Same.
1794 * testsuite/gfortran.dg/graphite/id-3.f90: Same.
1795 * testsuite/gfortran.dg/graphite/id-4.f90: Same.
1796 * testsuite/gfortran.dg/graphite/id-6.f: Same.
1797 * testsuite/gfortran.dg/graphite/id-9.f: Same.
1798 * testsuite/gfortran.dg/graphite/interchange-1.f: Same.
1799 * testsuite/gfortran.dg/graphite/interchange-2.f: Same.
1800 * testsuite/gfortran.dg/graphite/scop-1.f: Same.
1802 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
1804 * sese.c (expand_scalar_variables_call): New.
1805 (expand_scalar_variables_ssa_name): Handle calls in expander.
1807 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
1809 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-6.c:
1810 Expect to see the pattern twice.
1811 * testsuite/gcc.dg/graphite/interchange-0.c: Un-XFAIL.
1812 * testsuite/gcc.dg/graphite/interchange-5.c: Same.
1813 * testsuite/gcc.dg/graphite/interchange-6.c: Same.
1815 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
1817 * testsuite/gcc.dg/graphite/id-10.c: New.
1818 * testsuite/gcc.dg/graphite/id-12.c: New.
1819 * testsuite/gfortran.dg/graphite/id-7.f: New.
1820 * testsuite/gfortran.dg/graphite/id-8.f: New.
1822 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
1824 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Fix division by
1827 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
1829 * sese.c (rename_variables_in_stmt): Call fold_convert during renaming.
1831 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
1833 * sese.c (expand_scalar_variables_stmt): Avoid unnecessary expansion.
1835 2009-07-10 Sebastian Pop <sebastian.pop@amd.com>
1837 * graphite-sese-to-poly.c (pdr_add_memory_accesses): Fix order of
1838 building PDR subscripts.
1840 2009-07-10 Sebastian Pop <sebastian.pop@amd.com>
1842 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Fix the
1843 computation of array sizes.
1845 2009-07-10 Sebastian Pop <sebastian.pop@amd.com>
1847 * graphite-sese-to-poly.c (add_param_constraints): Disabled.
1849 2009-07-10 Tobias Grosser <grosser@fim.uni-passau.de>
1851 * graphite-dependences.c (map_into_dep_poly, map_dr_into_dep_poly,
1852 build_pairwise_constraint, dr_equality_constraints,
1853 build_pairwise_scheduling_equality,
1854 build_pairwise_scheduling_inequality, lexicographically_gt_p,
1855 build_lexicographically_gt_constraint, dependence_polyhedron,
1856 graphite_legal_transform_dr, graphite_carried_dependence_level_k):
1857 Move from NNC_Polyhedron to C_Polyhedron.
1858 * graphite-interchange.c (compute_array_size_poly,
1859 gather_access_strides): Dito.
1860 * graphite-poly.c (apply_poly_transforms, new_poly_dr, free_poly_bb,
1861 free_scop, pbb_number_of_iterations): Dito.
1862 * graphite-poly.h (struct poly_dr, pdr_nb_subscripts, struct poly_bb,
1863 pbb_dim_iter_domain, struct scop): Dito.
1864 * graphite-ppl.c (new_Constraint_System_from_Cloog_Matrix,
1865 new_Cloog_Domain_from_ppl_Polyhedron,
1866 new_Cloog_Domain_from_ppl_Pointset_Powerset, ppl_set_coef_gmp,
1867 ppl_insert_dimensions_pointset, ppl_insert_dimensions_pointset,
1868 ppl_strip_loop, ppl_strip_loop, ppl_print_polyhedron_matrix,
1869 ppl_print_powerset_matrix, debug_ppl_polyhedron_matrix,
1870 debug_ppl_powerset_matrix, ppl_read_polyhedron_matrix): Dito.
1871 * graphite-ppl.h (ppl_Pointset_Powerset_C_Polyhedron_t,
1872 new_C_Polyhedron_from_Cloog_Matrix, ppl_print_powerset_matrix,
1873 debug_ppl_powerset_matrix, ppl_insert_dimensions_pointset): Dito.
1874 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons,
1875 build_loop_iteration_domains, ppl_constraint_type_from_tree_code,
1876 add_condition_to_domain, add_condition_to_pbb, build_scop_context,
1877 build_scop_iteration_domain, build_poly_dr): Dito
1879 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1881 * testsuite/gcc.dg/graphite/graphite.exp: Added a rule to execute
1883 * testsuite/gcc.dg/graphite/run-id-1.c: New.
1885 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1887 * graphite-sese-to-poly.c (build_loop_iteration_domains): Add the
1888 positivity constraint on the symbolic number of iterations.
1890 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1892 * graphite-sese-to-poly.c (build_loop_iteration_domains): Rewrite.
1894 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1895 Tobias Grosser <grosser@fim.uni-passau.de>
1897 * graphite-clast-to-gimple.c (build_scop_context): Removed.
1898 (build_cloog_prog): Directly use SCOP_CONTEXT.
1899 * graphite-poly.c (new_scop): Initialize SCOP_CONTEXT.
1900 (free_scop): Free SCOP_CONTEXT.
1901 (print_scop_context): New.
1902 (print_scop): Call print_scop_context.
1903 (debug_scop_context): New.
1904 * graphite-poly.h (print_scop_context, debug_scop_context): Declared.
1905 (struct scop): Added field context.
1906 (SCOP_CONTEXT): New.
1907 * graphite-sese-to-poly.c (add_param_constraints): New.
1908 (build_scop_context): New.
1909 (build_poly_scop): Call build_scop_context.
1911 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1913 * graphite-clast-to-gimple.c (gmp_cst_to_tree): Moved...
1914 * graphite-ppl.c (ppl_set_inhomogeneous_gmp, ppl_set_coef_gmp): New.
1915 (ppl_set_inhomogeneous, ppl_set_coef): Moved...
1916 * graphite-ppl.h: Include double-int.h and tree.h.
1917 (ppl_set_inhomogeneous_gmp, ppl_set_coef_gmp): Declared.
1918 (ppl_set_inhomogeneous, ppl_set_coef): ...here.
1919 (gmp_cst_to_tree): ...here. Reimplemented using mpz_get_double_int.
1920 (tree_int_to_gmp, ppl_set_inhomogeneous_tree, ppl_set_coef_tree): New.
1922 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1924 * graphite-clast-to-gimple.c (clast_to_gcc_expression_red): Generate
1925 POINTER_PLUS_EXPR for pointer types.
1926 (clast_to_gcc_expression): Same.
1928 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1930 * graphite-poly.c (print_scattering_function): Early return when
1931 PBB_TRANSFORMED_SCATTERING is not initialized.
1932 (print_pbb_domain): Early return when PBB_DOMAIN is not initialized.
1934 2009-07-08 Sebastian Pop <sebastian.pop@amd.com>
1936 * tree-parloops.c (analyze_reduction_list): Remove unused variable
1939 2009-07-08 Razya Ladelsky <razya@il.ibm.com>
1941 * tree-parloops.c (analyze_reduction_list): Change return
1943 (try_create_reduction_list): Move the call to
1944 analyze_reduction_list to the beginining.
1945 Call reduction_phi with analyzed_reductions as argument
1946 instead of reduction_list.
1948 2009-07-08 Tobias Grosser <grosser@fim.uni-passau.de>
1950 * Merge from mainline (r148296:149346)
1952 2009-07-07 Sebastian Pop <sebastian.pop@amd.com>
1954 * graphite-scop-detection.c (graphite_can_represent_init): New.
1955 (graphite_can_represent_scev): Call graphite_can_represent_init:
1956 check that the initial value does not contain multiplications of
1958 (stmt_has_simple_data_refs_p): New.
1959 (stmt_simple_for_scop_p): Call stmt_simple_for_scop_p.
1960 (is_simple_operand): Fix formatting.
1961 * graphite-sese-to-poly.c (try_generate_gimple_bb): Fix formatting.
1963 2009-07-07 Sebastian Pop <sebastian.pop@amd.com>
1965 * testsuite/gcc.dg/graphite/id-13.c: New.
1966 * graphite-sese-to-poly.c (graphite_stmt_p): Do not call
1967 analyze_scalar_evolution, use scalar_evolution_in_region.
1968 (scan_tree_for_params_right_scev): Add extra assert.
1969 (parameter_index_in_region_1): Split from parameter_index_in_region.
1970 (idx_record_params): Use scalar_evolution_in_region.
1971 (find_params_in_bb): Same.
1972 (find_scop_parameters): Same.
1973 (build_loop_iteration_domains): Same.
1974 (create_linear_expr_from_tree): Same.
1975 * sese.c (scalar_evolution_in_region): New.
1976 * sese.h (scalar_evolution_in_region): Declared.
1977 (defined_in_sese_p): New.
1978 * tree-scalar-evolution.c (compute_overall_effect_of_inner_loop): Not
1980 * tree-scalar-evolution.h (compute_overall_effect_of_inner_loop):
1983 2009-07-07 Sebastian Pop <sebastian.pop@amd.com>
1985 * Makefile.in: Replace dependences on tree-chrec.h with SCEV_H.
1986 TREE_DATA_REF_H also implies SCEV_H.
1988 2009-07-07 Sebastian Pop <sebastian.pop@amd.com>
1990 * graphite-poly.c (print_scop_params): New.
1991 (print_scop): Call print_scop_params.
1992 (debug_scop_params): New.
1993 * graphite-poly.h (print_scop_params, debug_scop_params): Declared.
1995 2009-07-07 Li Feng <nemokingdom@gmail.com>
1997 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-4.c: New.
1998 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-5.c: New.
1999 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-6.c: New.
2000 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-7.c: New.
2001 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-8.c: New.
2002 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-9.c: New.
2004 2009-07-07 Li Feng <nemokingdom@gmail.com>
2006 * graphite-clast-to-gimple.c (mark_loops_parallel): Dump information
2007 for dependency checking part.
2008 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-1.c: Add
2009 tests for dependency checking.
2010 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-2.c: Ditto.
2011 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-3.c: Ditto.
2012 * testsuite/gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: Add
2013 flag -fdump-tree-graphite-all for autopar testsuites.
2015 2009-07-06 Sebastian Pop <sebastian.pop@amd.com>
2017 * Makefile.in (tree-ssa-loop-manip.o): Depends on langhooks.h.
2018 * tree-parloops.c (rewrite_phi_with_iv, rewrite_all_phi_nodes_with_iv,
2019 canonicalize_loop_ivs): Moved...
2020 * tree-ssa-loop-manip.c: ... here. Include langhooks.h.
2022 2009-07-06 Sebastian Pop <sebastian.pop@amd.com>
2024 * tree-parloops.c (try_create_reduction_list): Pass an extra
2025 argument analyzed_reductions. Call analyze_reduction_list.
2026 (gen_parallel_loop): Do not call analyze_reduction_list.
2027 (parallelize_loops): Init and finalize analyzed_reductions.
2029 2009-07-06 Li Feng <nemokingdom@gmail.com>
2031 * testsuite/gcc.dg/graphite/graphite_autopar/graphite_autopar.exp:
2032 Added flag -fno-loop-strip-mine for autopar testcase.
2034 2009-07-04 Li Feng <nemokingdom@gmail.com>
2036 * graphite-dependences.c (graphite_carried_dependence_level_k): Use
2037 transformed scattering dimension instead of unmatch orignal when
2038 calling dependence_polyhedron.
2040 2009-06-30 Sebastian Pop <sebastian.pop@amd.com>
2042 * opts.c (decode_options): Enable flag_loop_strip_mine at -O2.
2044 2009-06-30 Sebastian Pop <sebastian.pop@amd.com>
2046 * graphite-poly.c (pbb_number_of_iterations): Check for returned
2047 value 1 from ppl_Pointset_Powerset_NNC_Polyhedron_maximize.
2049 2009-06-30 Sebastian Pop <sebastian.pop@amd.com>
2051 * graphite-blocking.c (pbb_strip_mine_profitable_p): New.
2052 (pbb_do_strip_mine): Call pbb_strip_mine_profitable_p.
2053 * graphite-poly.c (pbb_number_of_iterations): New.
2054 * graphite-poly.h (pbb_number_of_iterations): Declared.
2055 (pbb_iterator_dim, pbb_parameter_dim): New.
2057 2009-06-29 Sebastian Pop <sebastian.pop@amd.com>
2059 * graphite-clast-to-gimple.c (graphite_create_new_loop): Revert the
2060 last commit on type of lower and upper bound of loops.
2062 2009-06-29 Li Feng <nemokingdom@gmail.com>
2064 * Makefile.in (graphite-clast-to-gimple.o): Added dependence on
2065 graphite-dependences.h.
2066 * graphite-clast-to-gimple.c (new_bb_pbb_def): New.
2067 (mark_bb_with_pbb): New.
2068 (get_stmtfor_depth): New.
2069 (find_pbb_via_hash): New.
2070 (dependency_in_loop_p): New.
2071 (mark_loops_parallel): New.
2072 (free_aux_in_new_loops): New.
2073 (translate_clast): Add parameter BB_PBB_MAPPING. Mark newly created
2074 bb with it's relevant pbb. Mark newly created loops. Remove mark
2075 innermost loop parallel without checking.
2076 (gloog): Add parameter BB_PBB_MAPPING.
2077 * graphite-clast-to-gimple.h (struct bb_pbb_def): New.
2078 (gloog): Change declaration.
2079 (mark_loop_parallel): Make extern.
2080 (free_aux_in_new_loops): Declare.
2081 (bb_pbb_map_hash): New.
2082 (eq_bb_pbb_map): New.
2083 * graphite.c (graphite_transform_loops): Added BB_PBB_MAPPING. Trigger
2084 auto parallelization when flag_graphite_force_parallel is set.
2085 (graphite_finalize): Added free_aux_in_new_loops.
2086 * tree-parloops.c (parallelize_loops): Only generate parallel code for
2087 the innermost loop that marked parallel. Use
2088 flag_graphite_force_parallel instead of loop->can_be_parallel.
2089 (loop_parallel_p): Move inner most checking out of function.
2091 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2093 * graphite-clast-to-gimple.c (graphite_create_new_loop): Make the
2094 type of lower and upper bound of loops signed long int.
2096 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2098 * cfgloopmanip.c (create_empty_loop_on_edge): Gimplify the loop exit
2099 expression outside the loop.
2101 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2103 * gcc.dg/graphite/interchange-8.c: New.
2105 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2107 * gcc.dg/graphite/interchange-0.c: XFailed.
2108 * gcc.dg/graphite/interchange-5.c: XFailed.
2109 * gcc.dg/graphite/interchange-6.c: XFailed.
2111 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2113 * graphite-interchange.c (compute_array_size_poly): The end of the
2114 recursion should return 1.
2116 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2118 * graphite-interchange.c (compute_array_size_cstr): Allow the
2119 subscript multiplier to be -1.
2120 (compute_array_size): Use PDR_DATA_CONTAINER and not PDR_ACCESSES.
2121 * graphite-poly.c (new_poly_dr): Takes an extra argument for the
2122 data_container. Initializes PDR_DATA_CONTAINER.
2123 (print_pdr_access_layout): New.
2124 (print_pdr): Call print_pdr_access_layout. Print PDR_DATA_CONTAINER.
2125 * graphite-poly.h (struct poly_dr): Adjust comment. Add a new field
2127 (PDR_DATA_CONTAINER): New.
2128 (new_poly_dr): Update declaration.
2129 * graphite-sese-to-poly.c (pdr_add_data_dimensions): New.
2130 (build_poly_dr): Call pdr_add_data_dimensions.
2132 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2134 * graphite-poly.h (struct poly_dr): Fix comment.
2135 * graphite-sese-to-poly.c (pdr_add_alias_set): New.
2136 (pdr_add_memory_accesses): New.
2137 (build_poly_dr): Call pdr_add_memory_accesses and pdr_add_alias_set.
2139 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2141 * graphite-poly.c (print_pdrs, debug_pdrs): New.
2142 (print_pbb): Add call to print_pdrs.
2143 * graphite-poly.h (print_pdrs, debug_pdrs): Declared.
2145 2009-06-24 Konrad Trifunovic <konrad.trifunovic@gmail.com>
2146 Li Feng <nemokingdom@gmail.com>
2148 * graphite-dependences.c (graphite_carried_dependence_level_k): New.
2149 (dependency_between_pbbs_p): New.
2150 (lexicographically_gt_p): Assure !empty_p before polyhedron
2151 intersection assign.
2152 (build_lexicographically_gt_constraint): Correct lexicographically
2154 * graphite-dependences.h: New.
2155 * Makefile.in (graphite-dependences.o): Add graphite-dependences.h.
2157 2009-06-24 Sebastian Pop <sebastian.pop@amd.com>
2159 * graphite-clast-to-gimple.c (print_clast_stmt): New.
2160 (gloog): Print to dump_file the generated clast.
2161 * graphite-clast-to-gimple.h (print_clast_stmt): Declared.
2162 * graphite-interchange.c (pbb_do_interchange): Fix dump formatting.
2164 2009-06-24 Sebastian Pop <sebastian.pop@amd.com>
2166 * graphite-poly.c (extend_scattering): Increment
2167 PBB_NB_LOCAL_VARIABLES by the number of added dimensions.
2169 2009-06-24 Sebastian Pop <sebastian.pop@amd.com>
2171 * graphite-interchange.c (compute_array_size_poly): Added exit of
2172 recursion condition. Continue iterating even after the first equality.
2173 (compute_array_size): Same.
2175 2009-06-24 Li Feng <nemokingdom@gmail.com>
2177 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-1.c: Update
2178 -fdump-tree-final_cleanup to -fdump-tree-optimized.
2179 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-2.c: Ditto.
2180 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-3.c: Ditto.
2181 * testsuite/gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: Ditto.
2183 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2185 * sese.c (expand_scalar_variables_stmt): Expand scalar variables
2186 only when the use verifies is_gimple_reg.
2188 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2190 * graphite-clast-to-gimple.c (build_cloog_prog): Fix memory corruption.
2191 Allocate scaldims after call to unify_scattering_dimensions.
2193 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2195 * graphite-clast-to-gimple.c (translate_clast): Fix memory leak.
2197 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2198 Albert Cohen <albert.cohen@inria.fr>
2200 * graphite-blocking.c (pbb_strip_mine_loop_depth): Do not use local
2201 variables for the strip mining.
2203 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2204 Pranav Garg <pranav.garg2107@gmail.com>
2206 * Makefile.in (OBJS-common): Added graphite-blocking.o.
2207 (graphite-sese-to-poly.o): Moved down to be in lexicographical order.
2208 (graphite-blocking.o): New rule.
2209 (graphite-poly.o, graphite-ppl.o): Moved to be in lexicographical order.
2210 * graphite-blocking.c: New.
2211 * graphite-poly.c (apply_poly_transforms): Call scop_do_strip_mine for
2212 flag_loop_strip_mine.
2213 (psct_scattering_dim_for_loop_depth): New.
2214 * graphite-poly.h (scop_do_strip_mine): Declared.
2215 (psct_add_local_variable): Increment PBB_NB_LOCAL_VARIABLES.
2216 * tree-ssa-loop.c (gate_graphite_transforms): Do not fail when using
2217 flag_loop_strip_mine.
2219 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2221 * graphite-poly.c (extend_scattering): Avoid initializing and freeing
2222 a GMP value and a PPL coefficient at each iteration of a loop.
2224 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2226 * graphite-dependences.c (dependence_polyhedron): Do not use
2227 pbb_nb_scattering_dims anymore. Use pbb_nb_scattering_orig and
2228 pbb_nb_scattering_transform.
2229 (graphite_legal_transform_dr): Same.
2230 * graphite-poly.c (extend_scattering): Same.
2231 (unify_scattering_dimensions): Same.
2232 (print_scattering_function): Same.
2233 (new_poly_bb): Initialize PBB_NB_SCATTERING_TRANSFORM and
2234 PBB_NB_LOCAL_VARIABLES.
2235 * graphite-poly.h (pbb_nb_scattering): Removed declaration.
2236 (struct poly_bb): Added nb_local_variables and nb_scattering_transform.
2237 (PBB_NB_LOCAL_VARIABLES, PBB_NB_SCATTERING_TRANSFORM): New.
2238 (pbb_nb_scattering_orig, pbb_nb_scattering_transform): New.
2239 (pbb_nb_scattering_dims, pbb_nb_scattering): Removed.
2240 (pbb_nb_scattering_transform): New.
2241 (pbb_nb_local_vars): Return PBB_NB_LOCAL_VARIABLES.
2242 (psco_scattering_dim): Add assert on parameters.
2243 (psct_scattering_dim): Same.
2244 (psct_scattering_dim_for_loop_depth): Declared.
2245 (psct_local_var_dim): New.
2246 (psco_iterator_dim, psco_parameter_dim): Add assert on parameters.
2247 (psct_iterator_dim, psct_parameter_dim): Same. To maintain the
2248 correct layout, call pbb_nb_local_vars.
2249 (psct_add_local_variable, psct_add_scattering_dimension): New.
2250 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons):
2251 Initialize PBB_NB_SCATTERING_TRANSFORM.
2253 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2255 * graphite-ppl.c (set_inhomogeneous): Renamed ppl_set_inhomogeneous.
2256 (set_coef): Renamed ppl_set_coef.
2257 * graphite-ppl.h (ppl_set_inhomogeneous, ppl_set_coef): Declared.
2259 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2261 * graphite-dependences.c (build_pairwise_scheduling_inequality): Don't
2262 test a boolean against 1.
2263 * graphite-interchange.c (pbb_interchange_loop_depths): Do not build
2264 a new polyhedron for the PBB_TRANSFORMED_SCATTERING.
2265 (pbb_do_interchange): Returns true when a transform has been performed.
2266 (scop_do_interchange): Same.
2267 * graphite-poly.c (apply_poly_transforms): Use the return value of
2268 scop_do_interchange.
2269 * graphite-poly.h (scop_do_interchange): Update declaration.
2271 2009-06-23 Tobias Grosser <grosser@fim.uni-passau.de>
2273 * graphite-clast-to-gimple.c (gloog): Reset loop->aux right
2275 * sese.c (sese_reset_aux_in_loops): New.
2276 * sese.h (sese_reset_aux_in_loops): New.
2278 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
2280 * graphite-sese-to-poly.c (scan_tree_for_params_int): Pass in the
2281 multiplier and multiply the constant by the multiplier.
2282 (scan_tree_for_params): Bound the multiplier to its MULT_EXPR.
2283 (build_poly_dr): Do not use the multiplier to define the subscript.
2285 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
2287 * graphite-poly.c (new_poly_dr): Pass an extra argument for the
2288 compiler's data reference. Initialize PDR_CDR.
2289 (print_pdr): Call dump_data_reference.
2290 * graphite-poly.h (struct poly_dr): Rename black_box into pbb.
2291 Add compiler_dr field.
2292 (PDR_BB): Renamed PDR_PBB.
2294 * graphite-sese-to-poly.c (build_poly_dr): Pass to new_poly_dr
2295 GCC's data reference representation.
2296 * tree-data-ref.c (debug_data_references, debug_data_reference): New.
2297 * tree-data-ref.h (debug_data_references, debug_data_reference): Decl.
2299 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
2301 * graphite-poly.c (print_scattering_function): Also print the layout.
2302 * graphite-poly.h (pbb_nb_local_vars): New.
2304 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
2306 * graphite-poly.c (print_pbb_domain): Also print the layout names.
2308 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
2310 * graphite-poly.c (print_pdr, debug_pdr): New.
2311 * graphite-poly.h (print_pdr, debug_pdr): Declared.
2312 (PDR_BASE): Removed.
2314 2009-06-18 Sebastian Pop <sebastian.pop@amd.com>
2316 * gcc/testsuite/gcc.dg/graphite/interchange-{1..7}.c: New avatars of
2319 2009-06-18 Sebastian Pop <sebastian.pop@amd.com>
2321 * graphite-interchange.c (compute_subscript): Allow also -1 in the
2322 subscript identification column.
2323 (pbb_do_interchange): Print to dump_file that some loops "will be
2324 interchanged". Rely on that chain of characters in the testcases.
2325 * gcc.dg/graphite/interchange-0.c: New.
2326 * gcc.dg/graphite/graphite.exp: Iterate over the testsuite
2327 interchange-*.c files and compile them with -floop-interchange.
2329 2009-06-18 Pranav Garg <pranav.garg2107@gmail.com>
2331 * graphite-interchange.c (interchange_profitable_p): Renamed
2332 pbb_interchange_profitable_p.
2334 2009-06-18 Sebastian Pop <sebastian.pop@amd.com>
2335 Harsha Jagasia <harsha.jagasia@amd.com>
2336 Pranav Garg <pranav.garg2107@gmail.com>
2338 * graphite-interchange.c (interchange_profitable_p): Make static.
2339 (pbb_interchange_loop_depths, pbb_do_interchange,
2340 scop_do_interchange): New.
2341 * graphite-poly.c (apply_poly_transforms): Call scop_do_interchange
2342 for flag_loop_interchange.
2343 * graphite-poly.h (scop_do_interchange): Declared.
2344 * tree-ssa-loop.c (gate_graphite_transforms): Do not fail when
2345 flag_loop_interchange is used.
2347 2009-06-18 Sebastian Pop <sebastian.pop@amd.com>
2349 * graphite-dependences.c (dependence_polyhedron): Update use of
2350 pbb_nb_scattering_dims.
2351 * graphite-poly.h (pbb_nb_scattering_dims): Do not pass SCOP.
2352 (pbb_nb_scattering): Update use of pbb_nb_scattering_dims.
2353 (psco_scattering_dim, psct_scattering_dim, psco_iterator_dim,
2354 psct_iterator_dim, psco_parameter_dim, psct_parameter_dim): New.
2356 2009-06-16 Sebastian Pop <sebastian.pop@amd.com>
2358 * graphite.c: Cleanup foo.
2360 2009-06-16 Sebastian Pop <sebastian.pop@amd.com>
2362 * Merge from mainline (r143684:148293).
2363 * Disabled libpcp until it gets fixed.
2365 2009-06-05 Sebastian Pop <sebastian.pop@amd.com>
2366 Harsha Jagasia <harsha.jagasia@amd.com>
2368 * graphite-interchange.c: New.
2369 * Makefile.in (graphite-interchange.o): New.
2370 * graphite-poly.h (interchange_profitable_p): Declared.
2371 * graphite-ppl.h (value_max): New.
2373 2009-06-04 Sebastian Pop <sebastian.pop@amd.com>
2375 * graphite-dependences.c (dependence_polyhedron): Use pdr_dim.
2376 * graphite-poly.h: Fix some comments.
2380 2009-06-04 Sebastian Pop <sebastian.pop@amd.com>
2383 (pdr_accessp_nb_subscripts): Renamed pdr_nb_subscripts.
2384 (pdr_accessp_nb_iterators): Renamed pdr_dim_iter_domain.
2385 (pdr_accessp_nb_params): Renamed pdr_nb_params.
2386 (pdr_accessp_alias_set_dim): Renamed pdr_alias_set_dim.
2387 (pdr_accessp_subscript_dim): Renamed pdr_subscript_dim.
2388 (pdr_accessp_iterator_dim): Renamed pdr_iterator_dim.
2389 (pdr_accessp_param_dim): Renamed pdr_parameter_dim.
2390 (pbb_nb_loops): Renamed pbb_dim_iter_domain.
2391 * graphite-clast-to-gimple.c: Same.
2392 * graphite-dependences.c: Same.
2393 * graphite-poly.c: Same.
2394 * graphite-sese-to-poly.c: Same.
2396 2009-06-03 Sebastian Pop <sebastian.pop@amd.com>
2398 * graphite-clast-to-gimple.c (build_iv_mapping): Insert full
2399 expressions for an IV rename, as returned by clast_to_gcc_expression.
2400 (copy_renames): Rename new_name to expr.
2401 * sese.c (debug_rename_elt): Same.
2404 (sese_adjust_liveout_phis): Call force_gimple_operand before using
2405 the information from the rename map.
2406 (rename_variables_in_stmt): Same.
2407 (add_loop_exit_phis): Rename new_name to expr.
2408 (insert_loop_close_phis): Same.
2409 (add_guard_exit_phis): Same. Call force_gimple_operand.
2410 * sese.h (struct rename_map_elt): Rename new_name to expr.
2411 (new_rename_map_elt): Same.
2413 2009-06-03 Sebastian Pop <sebastian.pop@amd.com>
2415 * graphite-clast-to-gimple.c (build_iv_mapping): Use set_rename.
2416 * sese.c (set_rename): Make it extern.
2417 * sese.h (set_rename): Declared.
2419 2009-06-03 Sebastian Pop <sebastian.pop@amd.com>
2421 * graphite-poly.c (extend_scattering): Free values.
2422 * graphite-ppl.c (new_Cloog_Domain_from_ppl_Pointset_Powerset):
2424 (ppl_print_powerset_matrix): Same.
2425 * graphite-scop-detection.c (free_scops_1): New.
2426 (limit_scops): Call free_scops_1.
2427 * graphite-sese-to-poly.c (build_scop_bbs_1): Free dom.
2428 (build_poly_dr): Free PPL coefficients.
2429 * tree-parloops.c (rewrite_all_phi_nodes_with_iv): Free bbs.
2431 2009-06-02 Sebastian Pop <sebastian.pop@amd.com>
2433 * graphite-dependences.c: New.
2434 * graphite-data-ref.c: Removed.
2435 * graphite-data-ref.h: Removed.
2436 * Makefile.in (graphite-data-ref.o): Removed.
2437 (graphite-dependences.o): Added.
2438 * graphite-clast-to-gimple.c: Remove dependence on graphite-data-ref.h.
2439 * graphite-poly.c: Same.
2440 Move the data dependence testing to graphite-dependences.c.
2442 2009-05-19 Tobias Grosser <grosser@fim.uni-passau.de>
2444 * graphite-scop-detection.c (graphite_can_represent_loop): Renamed
2445 from graphite_cannot_represent_loop. Code refactored.
2446 (scopdet_basic_block_info): Call graphite_can_represent_loop.
2448 2009-05-17 Li Feng <nemokingdom@gmail.com>
2450 * testsuite/gcc.dg/graphite/graphite_autopar/graphite_autopar.exp:
2451 Cover all the testcases (not only the filtered ones).
2453 2009-05-17 Tobias Grosser <grosser@fim.uni-passau.de>
2455 * graphite-scop-detection.c (stmt_simple_for_scop_p): Remove
2456 unnecessary check. Update comments. Move check for REAL_TYPE here.
2457 (harmful_stmt_in_bb): Remove checks for conditions. This is already
2458 done in (stmt_simple_for_scop_p).
2460 2009-05-14 Tobias Grosser <grosser@fim.uni-passau.de>
2462 * graphite.c (print_global_statistics): New.
2463 (print_graphite_scop_statistic): New.
2464 (print_graphite_statistics): New.
2465 (graphite_initialize, graphite_transform_loops): Print statistics.
2466 * graphite-scop-detection (build_scops): Print statistics.
2467 (print_graphite_scop_statistics): New.
2468 (print_graphite_statistics): New.
2470 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2472 * graphite-clast-to-gimple.c (struct clast_name_index): Removed.
2473 (debug_clast_name_index): Removed.
2474 (debug_clast_name_indexes_1): Removed.
2475 (debug_clast_name_indexes): Removed.
2476 (clast_name_index_elt_info): Removed.
2477 (eq_clast_name_indexes): Removed.
2478 (clast_name_to_index): Removed.
2479 (new_clast_name_index): Removed.
2480 (save_clast_name_index): Removed.
2481 (save_var_name): Moved...
2482 (init_sese_params_index): Removed.
2483 (clast_name_to_gcc): Remove use of name_tree.
2484 (initialize_cloog_names): Same.
2485 (gloog): Do not call init_sese_params_index.
2486 * graphite-sese-to-poly.c (save_var_name): ...here.
2487 (parameter_index_in_region): New.
2488 * sese.c (new_sese): Initialize SESE_PARAMS_NAMES.
2489 (parameter_index_in_region): Removed.
2490 (is_parameter): Remove use of name_tree.
2491 * sese.h (struct name_tree): Removed.
2492 (struct sese): Remove use of name_tree. New field params_names.
2493 (SESE_PARAMS_NAMES): New.
2494 (SESE_PARAMS): Remove duplicate.
2495 (parameter_index_in_region): Removed.
2496 (sese_nb_params): Remove use of name_tree.
2497 (struct clast_name_index): New.
2498 (new_clast_name_index): New.
2499 (clast_name_to_index): New.
2500 (save_clast_name_index): New.
2501 (debug_clast_name_index): New.
2502 (debug_clast_name_indexes_1): New.
2503 (debug_clast_name_indexes): New.
2504 (clast_name_index_elt_info): New.
2505 (eq_clast_name_indexes): New.
2507 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2509 * graphite-clast-to-gimple.c (compute_cloog_iv_types_1): Call
2510 pbb_to_depth_to_oldiv. Remove call to oldiv_for_loop.
2511 (graphite_loop_normal_form): Do not pass region. Do not
2512 initialize SESE_OLDIVS.
2513 (build_graphite_loop_normal_form): Update call to
2514 graphite_loop_normal_form.
2515 * sese.c (debug_oldivs): Removed.
2516 (new_sese): Do not initialize SESE_OLDIVS.
2517 (free_sese): Do not free SESE_OLDIVS.
2518 (oldiv_for_loop): Removed.
2519 * sese.h (struct sese): Remove old_ivs.
2520 (SESE_OLDIVS): Removed.
2521 (oldiv_for_loop): Removed.
2523 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2525 * graphite-clast-to-gimple.c (clast_name_to_gcc): Pass newivs,
2526 remove ivstack. Remove call to loop_iv_stack_get_iv_from_name,
2527 replaced by a call to newivs_to_depth_to_newiv.
2528 (clast_to_gcc_expression): Pass newivs, remove ivstack.
2529 (clast_to_gcc_expression_red): Same.
2530 (gcc_type_for_clast_expr): Same.
2531 (gcc_type_for_clast_eq): Same.
2532 (graphite_translate_clast_equation): Same.
2533 (graphite_create_guard_cond_expr): Same.
2534 (graphite_create_new_guard): Same.
2535 (graphite_create_new_loop): Same.
2536 (build_iv_mapping): Same.
2537 (translate_clast): Same.
2539 (loop_iv_stack_patch_for_consts): Removed. *
2540 sese.c (iv_stack_entry_is_constant): Removed.
2541 (iv_stack_entry_is_iv): Removed.
2542 (loop_iv_stack_push_iv): Removed.
2543 (loop_iv_stack_insert_constant): Removed.
2544 (loop_iv_stack_pop): Removed.
2545 (loop_iv_stack_get_iv): Removed.
2546 (loop_iv_stack_get_iv_from_name): Removed.
2547 (debug_loop_iv_stack): Removed.
2548 (free_loop_iv_stack): Removed.
2549 (loop_iv_stack_remove_constants): Removed. *
2550 sese.h (iv_stack_entry_kind): Removed.
2551 (iv_stack_entry_data_union): Removed.
2552 (iv_stack_entry_struct): Removed.
2553 (iv_stack_entry_p): Removed.
2554 (debug_oldivs, debug_loop_iv_stack, loop_iv_stack_insert_constant,
2555 loop_iv_stack_get_iv_from_name, loop_iv_stack_push_iv,
2556 loop_iv_stack_get_iv, loop_iv_stack_remove_constants,
2557 loop_iv_stack_pop, free_loop_iv_stack): Removed.
2558 (gbb_loop_at_index): Fix indenting.
2559 (gbb_loop_index): Removed.
2561 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2563 * graphite-clast-to-gimple.c (clast_name_to_gcc): Do not use strcmp.
2564 Call clast_name_to_index.
2566 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2568 * graphite-clast-to-gimple.c (clast_name_to_gcc): Pass region,
2569 do not pass params. Get params from SESE_PARAMS.
2570 (clast_to_gcc_expression): Same.
2571 (clast_to_gcc_expression_red): Same.
2572 (gcc_type_for_clast_eq): Same.
2573 (graphite_translate_clast_equation): Same.
2574 (graphite_create_new_loop): Same.
2575 * sese.c (rename_variables_in_stmt): Fix comment.
2577 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2579 * graphite-clast-to-gimple.c (graphite_create_new_loop): Pass
2581 Call save_clast_name_index.
2582 (translate_clast): Pass newivs_index.
2583 (gloog): Create and free newivs_index.
2585 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2587 * graphite-clast-to-gimple.c (clast_name_index): New structure.
2588 (clast_name_index_p): New type.
2589 (debug_clast_name_index): New.
2590 (debug_clast_name_indexes_1): New.
2591 (debug_clast_name_indexes): New.
2592 (clast_name_index_elt_info): New.
2593 (eq_clast_name_indexes): New.
2594 (clast_name_to_index): New.
2595 (new_clast_name_index): New.
2596 (save_clast_name_index): New.
2597 (init_sese_params_index): New.
2598 (gloog): Call init_sese_params_index.
2599 * graphite-clast-to-gimple.h (debug_clast_name_indexes): Declared.
2600 * sese.c (new_sese): Initialize SESE_PARAMS_INDEX.
2601 (free_sese): Free SESE_PARAMS_INDEX.
2602 * sese.h (struct sese): Add params_index.
2603 (SESE_PARAMS_INDEX): New.
2605 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2607 * graphite-clast-to-gimple.c (newivs_to_depth_to_newiv): New.
2608 (graphite_create_new_loop): Pass the newivs vector. Push the
2609 newly created IV to newivs.
2610 (translate_clast): Pass the newivs vector.
2611 (gloog): Create and destroy the newivs vector.
2613 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2615 * graphite-clast-to-gimple.c (pbb_to_depth_to_oldiv): New.
2616 (graphite_loop_normal_form): Initialize loop->aux with the unique
2617 IV that has been created.
2619 2009-05-13 Tobias Grosser <grosser@fim.uni-passau.de>
2621 * tree-chrec.c (evolution_function_right_is_integer_cst): Allow
2622 scev with parameters in the base part. They where forbidden
2625 2009-05-11 Li Feng <nemokingdom@gmail.com>
2627 * testsuite/gcc.dg/graphite/graphite.exp: Set different default
2628 compile options by file names.
2629 * testsuite/gcc.dg/graphite/block{0-6}.c: Remove dg-option line.
2630 * testsuite/gcc.dg/graphite/id-{1-9}.c: Ditto.
2631 * testsuite/gcc.dg/graphite/scop-{0-20}.c: Ditto.
2632 * testsuite/gcc.dg/graphite/scop-matmult.c: Ditto.
2634 2009-05-08 Li Feng <nemokingdom@gmail.com>
2636 * testsuite/gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: New.
2637 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-1.c: New.
2638 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-2.c: New.
2639 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-3.c: New.
2641 2009-05-07 Tobias Grosser <grosser@fim.uni-passau.de>
2643 * graphite-scop-detection (build_scops_1): Fix little bug introduced
2646 2009-05-07 Tobias Grosser <grosser@fim.uni-passau.de>
2648 * graphite-scop-detection.c (graphite_can_represent_scev): Only
2649 allow integer constant strides.
2650 (graphite_can_represent_expr): Depend on outermost_loop.
2651 (stmt_simple_memref_p, graphite_cannot_represent_loop,
2652 harmful_stmt_in_bb, is_simple_operand, stmt_simple_for_scop_p,
2653 build_scops_1): Same.
2654 (scopdet_basic_block_info): Same and insert layered SCoP
2656 (try_generate_gimple_bb): Cleanup.
2657 (build_scops): Enable data references.
2659 * testsuite/gcc.dg/graphite/id-5.c: New.
2660 * testsuite/gcc.dg/graphite/id-9.c: New.
2661 * tree-chrec.c (evolution_function_right_is_integer_cst): New.
2662 * tree-chrec.h (evolution_function_right_is_integer_cst): New.
2664 2009-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
2666 * sese.c (expand_scalar_variables_ssa_name): Only build expressions,
2667 that we have not yet built for this SCoP.
2669 2009-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
2671 * sese.c (expand_scalar_variables_expr): Fix expand_scalar_variables
2672 for complex numbers.
2674 2009-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
2676 * graphite-ppl.c: Fix build if cloog is not available.
2678 2009-05-04 Li Feng <nemokingdom@gmail.com>
2680 * tree-parloops.c (loop_parallel_p): Remove construction of
2681 NITER and REDUCTION_LIST.
2682 (try_get_loop_niter): New.
2683 (try_create_reduction_list): New.
2684 (parallelize_loops): Bypass the failed checkings in autopar
2685 when can_be_parallel in loop structure is set to true.
2687 2009-05-01 Tobias Grosser <grosser@fim.uni-passau.de>
2689 * testsuite/gcc.dg/graphite/id-6.c: Update testcase.
2690 * testsuite/gcc.dg/graphite/scop-3.c: Dito.
2692 2009-05-01 Tobias Grosser <grosser@fim.uni-passau.de>
2694 * graphite-scop-detection.c (stmt_simple_for_scop_p):
2695 Enable EQ_EXPR and NE_EXPR again.
2697 2009-04-30 Tobias Grosser <grosser@fim.uni-passau.de>
2699 * graphite-scop-detection.c (graphite_can_represent_scev):
2700 Add check if scev is affine multivariate.
2701 (harmful_stmt_in_bb): Check if we can represent the conditions.
2702 (scopdet_basic_block_info (basic_block bb, VEC): Pass the loop to
2704 * testsuite/gcc.dg/graphite/id-7.c: New.
2706 2009-04-30 Tobias Grosser <grosser@fim.uni-passau.de>
2708 * graphite-sese-to-poly.c (bb_contains_non_iv_scalar_phi_nodes):
2709 Check all bbs in region, not only the bbs that are represented in
2711 (build_poly_scop): Add newline.
2712 * testsuite/gcc.dg/graphite/id-8.c: New.
2714 2009-04-30 Li Feng <nemokingdom@gmail.com>
2716 * cfgloop.c (alloc_loop): Initialize can_be_parallel to false
2717 when loop initialize.
2718 * cfgloop.h (struct loop): Introduce flag can_be_parallel.
2719 * common.opt: Declare flag_graphite_force_parallel.
2720 * graphite-clast-to-gimple.c (translate_clast): Mark the innermost
2722 * graphite-poly.c (apply_poly_transforms): Introduce
2723 flag_graphite_force_parallel.
2724 * tree-ssa-loop.c (gate_graphite_transforms): ditto.
2725 * toplev.c (process_options): ditto and replace a not correctly
2728 2009-04-30 Li Feng <nemokingdom@gmail.com>
2730 * graphite-clast-to-gimple.c (loop_iv_stack_patch_for_consts):
2731 Change the call of gbb_loop_at_index and/or gbb_loop_index due
2732 to the redefinition.
2733 (compute_cloog_iv_types_1): ditto.
2734 (build_iv_mapping): ditto.
2735 * graphite-sese-to-poly.c (new_gimple_bb): Remove GBB_LOOPS related
2737 (free_gimple_bb): Removed GBB_LOOPS related free part.
2738 (build_bb_loops): Removed.
2739 * sese.h (struct gimple_bb): Removed loops.
2740 (GBB_LOOPS): Removed.
2741 (gbb_loop_at_index): Instead of using GBB_LOOPS, we use sese instead.
2742 (gbb_loop_index): ditto.
2744 2009-04-24 Tobias Grosser <grosser@fim.uni-passau.de>
2746 * graphite-scop-detection.c (graphite_can_represent_scev): Do not
2747 allow non constant strides.
2748 * testsuite/gcc.dg/graphite/scop-20.c: New.
2750 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
2752 * graphite-scop-detection.c (dot_all_scops): Fix system call
2753 return value warning.
2756 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
2758 * testsuite/gcc.dg/graphite/id-6.c: Fix pattern.
2759 * testsuite/gcc.dg/graphite/scop-3.c: Same.
2761 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
2763 * graphite-poly.c (map_into_dep_poly, map_dr_into_dep_poly,
2764 build_pairwise_constraint, dr_equality_constraints,
2765 build_pairwise_scheduling_equality,
2766 build_pairwise_scheduling_inequality, lexicographically_gt_p,
2767 build_lexicographically_gt_constraint, dependence_polyhedron,
2768 graphite_legal_transform_dr, graphite_legal_transform_bb,
2769 graphite_legal_transform): New.
2770 * graphite-poly.h (graphite_legal_transform): Declared.
2771 * graphite-sese-to-poly.c (build_poly_scop): Call to
2772 graphite_legal_transform is disabled for the moment.
2774 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
2776 * graphite-poly.h (pbb_nb_scattering_dims): New.
2777 (pbb_nb_scattering): Use it.
2779 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
2781 * graphite-ppl.c (ppl_insert_dimensions_pointset): Add
2782 Pointset_Powerset version of ppl_insert_dimensions.
2783 * graphite-ppl.h (ppl_insert_dimensions_pointset): Declared.
2785 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
2787 * graphite-ppl.c (ppl_insert_dimensions): Fix formatting.
2789 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
2791 * graphite-poly.h: Fix comment.
2793 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
2795 * graphite-sese-to-poly.c (build_poly_dr): Fix data ref multiplier.
2797 2009-04-24 Tobias Grosser <grosser@fim.uni-passau.de>
2799 * sese.c (expand_scalar_variables_stmt): Only iterate over the old
2802 2009-04-24 Tobias Grosser <grosser@fim.uni-passau.de>
2804 * graphite-sese-to-poly.c (var_used_in_not_loop_header_phi_node): New.
2805 (graphite_stmt_p): Represent bbs necessary to build the phi nodes of
2808 2009-04-20 Sebastian Pop <sebastian.pop@amd.com>
2810 * graphite-scop-detection.c (stmt_simple_for_scop_p): Do not
2811 handle EQ_EXPR and NE_EXPR.
2813 2009-04-17 Tobias Grosser <grosser@fim.uni-passau.de>
2815 * graphite-poly.h (poly_dr): Fix comment.
2817 2009-04-09 Sebastian Pop <sebastian.pop@amd.com>
2818 Tobias Grosser <grosser@fim.uni-passau.de>
2820 * graphite-poly.c (new_poly_bb): Do not initialize PBB_DOMAIN
2821 with a zero dimension polyhedron.
2822 (find_scop_parameters): Move the call to scop_set_nb_params here.
2823 (build_loop_iteration_domains): Store in loop->aux the iteration
2825 (build_scop_iteration_domain): Fix PBB_DOMAIN for bbs not surrounded
2826 by any loop in scop.
2827 (build_poly_scop): Do not call scop_set_nb_params.
2829 2009-04-09 Sebastian Pop <sebastian.pop@amd.com>
2830 Tobias Grosser <grosser@fim.uni-passau.de>
2832 * graphite-sese-to-poly.c (add_condition_to_pbb): Pass code to
2833 add_condition_to_domain not GT_EXPR.
2835 2009-04-09 Tobias Grosser <grosser@fim.uni-passau.de>
2837 * graphite-ppl.c (debug_ppl_powerset_matrix): New.
2838 * graphite-ppl.h (debug_ppl_powerset_matrix): New.
2839 * graphite-sese-to-poly.c (add_condition_to_pbb): Use
2840 upper_bound_assign to calculate unions.
2841 * testsuite/gcc.dg/graphite/id-6.c: New.
2843 2009-04-09 Tobias Grosser <grosser@fim.uni-passau.de>
2845 * graphite-scop-detection.c (canonicalize_loop_closed_ssa): Do not
2846 handle abnormal edges.
2848 2009-04-09 Tobias Grosser <grosser@fim.uni-passau.de>
2850 * graphite-poly.c (new_poly_dr, free_poly_dr): New.
2851 (free_poly_bb): Also free poly_drs.
2852 * graphite-poly.h (new_poly_dr, free_poly_dr): New.
2853 (poly_dr): Polyhedron to Pointset_Powerset.
2854 (pdr_accessp_nb_subscripts): Same.
2855 * graphite-sese-to-poly.c (build_poly_dr): Same. And actually build
2858 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
2860 * graphite-clast-to-gimple.c (initialize_cloog_names): Change cloog
2861 names into more meaningful names.
2863 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
2865 * testsuite/gfortran.dg/graphite/interchange-1.c: New.
2866 * testsuite/gfortran.dg/graphite/interchange-2.c: New.
2868 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
2870 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not build
2872 * tree-parloops.c (rewrite_phi_with_iv): New.
2873 (rewrite_all_phi_nodes_with_iv): New.
2874 (canonicalize_loop_ivs): Call them.
2876 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
2878 * graphite-sese-to-poly.c (try_generate_gimple_bb): Use
2879 graphite_find_data_references_in_stmt.
2880 * tree-data-ref.c (graphite_find_data_references_in_stmt): New.
2881 * tree-data-ref.h (graphite_find_data_references_in_stmt): Declared.
2883 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
2885 * sese.c (add_loop_exit_phis): Don't fail on non SSA_NAME renames.
2887 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
2889 * graphite-sese-to-poly.c (build_scop_bbs_1): Use bb_in_sese_p
2890 instead of bb_in_region.
2891 (flag_bb_in_region): Same. Renamed flag_bb_in_sese.
2892 (build_sese_conditions): Use flag_bb_in_sese.
2893 * sese.c (register_bb_in_sese): Removed.
2894 (new_sese): Remove initialization of SESE_REGION_BBS.
2895 (free_sese): Do not free SESE_REGION_BBS.
2896 * sese.h (struct sese): Remove field region_basic_blocks.
2897 (SESE_REGION_BBS): Removed.
2898 (bb_in_sese_p): Implement in function of bb_in_region.
2900 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
2902 * graphite-scop-detection.c (limit_scops): Deal only with single exit
2905 2009-04-08 Tobias Grosser <grosser@fim.uni-passau.de>
2907 * graphite-scop-detection.c (stmt_simple_for_scop_p): Allow NE_EXPR
2909 * graphite-sese-to-poly.c (create_linear_expr_from_tree): New.
2910 (add_condition_to_domain): New.
2911 (add_condition_to_pbb): New.
2912 (add_conditions_to_domain): Cleanup and handle of NE_EXPR and EQ_EXPR.
2913 * testsuite/gcc.dg/graphite/scop-3.c: Update number of detected SCoPs.
2915 2009-04-08 Tobias Grosser <grosser@fim.uni-passau.de>
2917 * graphite-clast-to-gimple.c (build_cloog_prog): ppl_Polyhedron ->
2918 ppl_Pointset_Powerset.
2919 * graphite-poly.c (new_poly_bb, free_poly_bb): Same.
2920 * graphite-poly.h (poly_bb): poly_bb.domain Same.
2921 (pbb_nb_loops): Same.
2922 * graphite-sese-to-poly.c (build_loop_iteration_domains,
2923 add_conditions_to_domain): Same.
2924 * graphite-ppl.c (new_Cloog_Domain_from_ppl_Pointset_Powerset): New.
2925 (ppl_print_polyhedron_matrix): ppl_Polyhedron_t ->
2926 ppl_const_Polyhedron_t.
2927 (ppl_print_powerset_matrix): New.
2928 * graphite-ppl.h (new_Cloog_Domain_from_ppl_Pointset_Powerset,
2929 ppl_print_powerset_matrix): New.
2930 (ppl_print_polyhedron_matrix): Updated.
2932 2009-04-07 Sebastian Pop <sebastian.pop@amd.com>
2934 * tree-scalar-evolution.c (analyze_scalar_evolution_1): Fix comment.
2936 2009-04-07 Sebastian Pop <sebastian.pop@amd.com>
2938 * graphite-poly.c (extend_scattering): Fix indenting. Free cstr.
2939 (print_iteration_domains, debug_iteration_domain,
2940 debug_iteration_domains): New.
2941 * graphite-poly.h (print_iteration_domains, debug_iteration_domain,
2942 debug_iteration_domains): Declared.
2943 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons): Fix
2946 2009-04-03 Tobias Grosser <grosser@fim.uni-passau.de>
2947 Sebastian Pop <sebastian.pop@amd.com>
2949 * graphite-poly.h (print_iteration_domain): New.
2950 * graphite-sese-to-poly.c (add_conditions_to_domain): Fixed bug.
2951 (build_sese_conditions_1, build_sese_conditions_after,
2952 build_sese_conditions_before): New.
2953 (build_sese_conditions): Rewritten.
2955 2009-04-03 Sebastian Pop <sebastian.pop@amd.com>
2956 Tobias Grosser <grosser@fim.uni-passau.de>
2958 Cleanup of code generation liveouts.
2959 * graphite-clast-to-gimple.c (translate_clast): Use a single
2960 rename_map instead of one per translated statement.
2961 Do not use SESE_LIVEOUT_RENAMES.
2962 (graphite_loop_normal_form): Do not use SESE_REDUCTION_LIST.
2963 (gloog): Do not use SESE_LIVEOUT_RENAMES.
2964 * graphite-scop-detection.c (harmful_stmt_in_bb): Return the close
2965 phi node of a reduction: when a loop contains a reduction used outside
2966 the loop, there should be a scalar close phi node on the exit block.
2967 * sese.c (new_sese): Do not initialize SESE_LIVEOUT,
2968 SESE_LIVEOUT_RENAMES, and SESE_REDUCTION_LIST.
2969 (free_sese): Do not free them.
2970 (sese_build_liveouts_use): Do not use them.
2971 (sese_build_liveouts_bb): Same.
2972 (sese_build_liveouts): Same.
2973 (sese_insert_phis_for_liveouts): Same.
2974 (sese_adjust_phis_for_liveouts): Same. Renamed sese_adjust_liveout_phis.
2975 (defined_in_loop_p): New.
2976 (alive_after_loop): New.
2977 (close_phi_not_yet_inserted_p): New.
2978 (struct alep, alep_p): New.
2979 (add_loop_exit_phis): Remove from the rename_map all the names defined
2980 in the code generated loop.
2981 (insert_loop_close_phis): Traverse the rename_map passed to it.
2982 Don't use SESE_LIVEOUT_RENAMES.
2983 (default_liveout_before_guard): Renamed default_before_guard.
2984 (insert_guard_phis): Do not use SESE_LIVEOUT_RENAMES.
2985 (graphite_copy_stmts_from_block): Do not directly call set_rename.
2986 (register_sese_liveout_renames): Removed.
2987 (copy_bb_and_scalar_dependences): Do not call it.
2988 * sese.h (struct sese): Removed fields: liveout, liveout_renames, and
2990 (SESE_LIVEOUT): Removed.
2991 (SESE_LIVEOUT_RENAMES): Removed.
2992 (SESE_REDUCTION_LIST): Removed.
2993 (sese_build_liveouts): Removed.
2994 (sese_adjust_phis_for_liveouts): Renamed sese_adjust_liveout_phis.
2995 (insert_loop_close_phis): Pass a htab_t instead of a sese.
2996 (insert_guard_phis): Same.
2997 (rename_map_elt): Declare a VEC of them.
2998 * tree-parloops.c (canonicalize_loop_ivs): reduction_list contains
2999 trees not pointers to trees.
3001 Rewrite in canonical close SSA form:
3002 * graphite-scop-detection.c (contains_only_close_phi_nodes): New.
3003 (limit_scops): Close the scop after the block containing the close phi
3005 (canonicalize_loop_closed_ssa): New.
3006 (canonicalize_loop_closed_ssa_form): New.
3007 (build_scops): Call canonicalize_loop_closed_ssa_form.
3009 * graphite-sese-to-poly.c: Fix typos.
3011 2009-04-03 Sebastian Pop <sebastian.pop@amd.com>
3013 * graphite-poly.c (print_scattering_function, print_pbb_domain):
3015 (dump_gbb_conditions, dump_gbb_cases, print_iteration_domain): New.
3016 (print_pbb): Add conditions.
3018 2009-04-01 Tobias Grosser <grosser@fim.uni-passau.de>
3019 Sebastian Pop <sebastian.pop@amd.com>
3021 * graphite-scop-detection.c (bb_in_sd_region): Use bb_in_region.
3022 * graphite-sese-to-poly.c (all_non_dominated_preds_marked_p): New.
3023 (build_scop_bbs_1): New.
3024 (build_scop_bbs): Rewrite.
3025 * sese.h (bb_in_region): New.
3027 2009-03-29 Tobias Grosser <grosser@fim.uni-passau.de>
3029 * graphite-poly.c (new_poly_bb, free_poly_bb): Initialize/free
3031 (print_scop): Style.
3032 * graphite-poly.h (poly_bb): Add drs vector.
3033 (PBB_DRS): Add accessor.
3034 * graphite-sese-to-poly.c (build_poly_dr): New.
3035 (build_pbb_drs, build_scop_drs): New.
3036 (build_poly_scop): call build_scop_drs (Disabled at the moment).
3038 2009-03-29 Tobias Grosser <grosser@fim.uni-passau.de>
3040 * tree-ssa-loop.c: Include forgotten toplev.h
3042 2009-03-29 Tobias Grosser <grosser@fim.uni-passau.de>
3044 * graphite-poly.c: (apply_poly_transforms): sorry -> gcc_unreachable.
3045 * testsuite/gcc.dg/graphite/pr37883.c: Remove -floop-*
3046 * testsuite/gcc.dg/graphite/pr37928.c: Same
3047 * testsuite/gcc.dg/graphite/pr38409.c: Same
3048 * testsuite/gcc.dg/graphite/pr38498.c: Same
3049 * testsuite/gcc.dg/graphite/pr38559.c: Same
3050 * testsuite/gcc.dg/graphite/pr39335.c: Same
3051 * testsuite/gcc.dg/graphite/pr39335_1.c: Same
3052 * testsuite/gfortran.dg/graphite/block-2.f: Same
3053 * tree-ssa-loop.c (gate_graphite_transforms): Always fail if called
3056 2009-03-28 Tobias Grosser <grosser@fim.uni-passau.de>
3058 * graphite-sese-to-poly.c (ref_nb_loops, build_access_matrix_with_af,
3059 build_access_matrix, build_scop_data_accesses): Remove access function
3060 building. (We get a new version soon).
3061 (build_bb_loops, scan_tree_for_params_right_scev): Update.
3062 * sese.h (nb_loops_around_loop_in_sese): Remove.
3063 (sese_loop_depth): Do not use SESE_LOOP_NEST any more.
3065 2009-03-27 Tobias Grosser <grosser@fim.uni-passau.de>
3066 Sebastian Pop <sebastian.pop@amd.com>
3068 * graphite-scop-detection.c (struct scopdet_info): Rename last
3070 (scopdet_basic_block_info, build_scops_1): Don't use
3071 CDI_POST_DOMINATORS. CDI_POST_DOMINATORS should never be used.
3073 2009-03-26 Tobias Grosser <grosser@fim.uni-passau.de>
3074 Sebastian Pop <sebastian.pop@amd.com>
3076 * graphite-clast-to-gimple.c (gloog): Call sese_build_liveouts.
3077 * sese.c (sese_build_liveouts_use): Renamed from
3078 sese_build_livein_liveouts_use. Remove liveins.
3079 (sese_build_liveouts_bb): Renamed from sese_build_livein_liveouts_bb.
3080 Call sese_build_liveouts_use.
3081 (sese_build_liveouts): Renamed from sese_build_livein_liveouts.
3082 Call sese_build_liveouts_bb.
3083 (new_sese, free_sese): Remove liveins.
3084 (sese_add_exit_phis_var): Deleted.
3085 (sese_insert_phis_for_liveouts): Call sese_add_exit_phis_edge
3087 (graphite_copy_stmts_from_block): Remove SESE_NUM_VER.
3089 * sese.h (sese): Remove num_ver and livein.
3090 (SESE_LIVEIN, SESE_LIVEIN_VER, SESE_NUM_VER): Removed.
3092 2009-03-25 Tobias Grosser <grosser@fim.uni-passau.de>
3094 * graphite-sese-to-poly.c (build_scop_scattering): Fix compile.
3096 2009-03-25 Tobias Grosser <grosser@fim.uni-passau.de>
3098 * graphite-sese-to-poly.c (compare_prefix_loops): Removed.
3099 (build_scop_scattering): Do not use compare_prefix_loops any more.
3100 (nb_common_loops): New.
3102 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
3104 * sese.c (get_new_name_from_old_name): Renamed get_rename.
3105 (register_old_and_new_names): Renamed set_rename.
3107 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
3109 * graphite-scop-detection.h (nb_reductions_in_loop): Revert removal
3110 of the decl from the previous commit.
3112 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
3114 * graphite-scop-detection.c (dot_scop): New.
3115 * graphite-scop-detection.h (dot_scop): Declared.
3117 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
3119 * graphite-sese-to-poly.c (compare_prefix_loops): Fix compare.
3121 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
3123 * cfgloopmanip.c (create_empty_loop_on_edge): Generate the loop exit
3124 condition at the end of the loop.
3125 * graphite.c (graphite_initialize, graphite_finalize): Print to
3126 dump_file the compiled function.
3127 * graphite-clast-to-gimple.c (graphite_create_new_loop): Update use
3128 of create_empty_loop_on_edge.
3129 (translate_clast): Update the code generation of loops for the new
3131 * cfgloop.h (create_empty_loop_on_edge): Update declaration.
3133 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
3135 Reverted the patch from 2009-03-19.
3137 2009-03-19 Tobias Grosser <grosser@fim.uni-passau.de>
3139 * graphite-poly.c (new_poly_bb, free_poly_bb): Initialize/free
3141 (print_scop): Style.
3142 * graphite-poly.h (poly_bb): Add drs vector.
3143 (PBB_DRS): Add accessor.
3144 * graphite-sese-to-poly.c (ref_nb_loops): Remove.
3145 (build_access_matrix_with_af, build_access_matrix,
3146 build_scop_data_accesses): Delete.
3147 (build_poly_dr): New.
3148 (build_pbb_drs, build_scop_drs): New.
3149 (build_poly_scop): call build_scop_drs.
3151 2009-03-13 Sebastian Pop <sebastian.pop@amd.com>
3153 * graphite-scop-detection.c (dot_all_scops_1): Close the table
3154 once per basic block.
3156 2009-03-13 Tobias Grosser <grosser@fim.uni-passau.de>
3158 * graphite-scop-detection.c (graphite_can_represent_scev): New.
3159 (graphite_can_represent_expr): Renamed from loop_affine_expr
3161 (stmt_simple_for_scop_p): Call graphite_can_represent_expr.
3162 (graphite_cannot_represent_loop): Add scop_entry to parameters.
3163 (scopdet_basic_block_info): Actually define entry_block.
3164 (stmt_simple_memref_p): Moved here from ...
3166 * tree-data-ref.c (stmt_simple_memref_p): here.
3167 * tree-data-ref.h (stmt_simple_memref_p): Removed.
3169 2009-03-13 Tobias Grosser <grosser@fim.uni-passau.de>
3171 * testsuite/gcc.dg/graphite/id-4.c: New.
3173 2009-03-12 Sebastian Pop <sebastian.pop@amd.com>
3175 * sese.c (expand_scalar_variables_expr): Handle tcc_comparison.
3176 (register_old_and_new_names): Update the content of the map.
3177 When there was already a rename_map_elt in the map at that
3179 (copy_bb_and_scalar_dependences): Do rename_variables after
3180 expand_scalar_variables.
3181 * graphite-clast-to-gimple.c (build_iv_mapping): Update the content
3182 of the map. When there was already a rename_map_elt in the
3183 map at that location, free it.
3184 (translate_clast): Pass the rename_map. Do not initialize and free
3185 a rename_map per stmt_user.
3186 (gloog): Initialize and free one rename_map and pass it to
3189 2009-03-12 Sebastian Pop <sebastian.pop@amd.com>
3191 * sese.c (expand_scalar_variables_stmt,
3192 expand_scalar_variables_ssa_name): Add a gimple_stmt_iterator
3194 (expand_scalar_variables_expr): Handle REALPART_EXPR and IMAGPART_EXPR.
3195 (expand_scalar_variables): Pass to expand_scalar_variables_stmt
3196 the gimple_stmt_iterator of the statement to be expanded.
3197 * graphite-scop-detection.c (is_simple_operand): Do handle
3200 2009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
3202 * graphite-scop-detection.c (is_simple_operand): Do not handle
3204 * testsuite/gcc.dg/graphite/id-2.c: New.
3206 * graphite-sese-to-poly.c (build_bb_loops,
3207 add_value_to_dim, scan_tree_for_params_right_scev,
3208 scan_tree_for_params_int, scan_tree_for_params, idx_record_params,
3209 find_params_in_bb, build_loop_iteration_domains,
3210 add_conditions_to_domain): Remove subtract.
3212 2009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
3214 * graphite-clast-to-gimple.c (loop_iv_stack_patch_for_consts,
3215 build_iv_mapping, compute_cloog_iv_types_1, build_cloog_prog):
3216 pbb_loop_at_index -> gbb_loop_at_index.
3217 * graphite-poly.c (new_poly_bb, new_scop): New accessors.
3218 (debug_loop_vec): Delete.
3219 * graphite-poly.h (poly_bb, scop): Change black_box and region to void
3220 pointer. Move LOOPS to gimple_bb_p and insert nb_params.
3221 (PBB_LOOPS): Removed.
3222 (PBB_BLACK_BOX): Insert cast.
3223 (pbb_set_black_box): New setter.
3224 (pbb_loop_at_index, pbb_loop_index): Removed.
3225 (scop_set_region, scop_set_nb_params): New.
3226 * graphite-sese-to-poly.c (new_gimple_bb, free_gimple_bb,
3227 build_scop_scattering, build_bb_loops): Add GBB_LOOPS.
3228 (build_poly_scop): Use scop_set_nb_params.
3229 * sese.h (gimple_bb): Add LOOPS.
3230 (GBB_LOOPS, gbb_loop_index, gbb_loop_at_index): New.
3232 2009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
3234 Revert previous commit.
3236 2009-03-11 Sebastian Pop <sebastian.pop@amd.com>
3238 * sese.c (expand_scalar_variables_expr): Handle tcc_comparison.
3239 (register_old_and_new_names): Update the content of the map.
3240 When there was already a rename_map_elt in the map at that
3242 (copy_bb_and_scalar_dependences): Do rename_variables after
3243 expand_scalar_variables.
3244 * graphite-clast-to-gimple.c (build_iv_mapping): Update the content
3245 of the map. When there was already a rename_map_elt in the
3246 map at that location, free it.
3247 (translate_clast): Pass the rename_map. Do not initialize and free
3248 a rename_map per stmt_user.
3249 (gloog): Initialize and free one rename_map and pass it to
3252 2009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
3254 Remove forgotten line in revert.
3256 2009-03-11 Sebastian Pop <sebastian.pop@amd.com>
3258 Revert previous commit.
3260 2009-03-10 Sebastian Pop <sebastian.pop@amd.com>
3262 * sese.c (register_old_and_new_names): Update the content
3263 of the map. When there was already a rename_map_elt in the
3264 map at that location, free it.
3265 (copy_bb_and_scalar_dependences): Do rename_variables after
3266 expand_scalar_variables.
3267 * graphite-clast-to-gimple.c (build_iv_mapping): Update the content
3268 of the map. When there was already a rename_map_elt in the
3269 map at that location, free it.
3270 (translate_clast): Pass the rename_map. Do not initialize and free
3271 a rename_map per stmt_user.
3272 (gloog): Initialize and free one rename_map and pass it to
3275 2009-03-10 Sebastian Pop <sebastian.pop@amd.com>
3277 * graphite-clast-to-gimple.c (translate_clast): context_loop
3280 2009-03-10 Tobias Grosser <grosser@fim.uni-passau.de>
3281 Sebastian Pop <sebastian.pop@amd.com>
3283 * graphite-ppl.c (ppl_insert_dimensions): Fix stupid mistake
3284 of the use of ppl_Polyhedron_map_space_dimensions.
3286 2009-03-10 Tobias Grosser <grosser@fim.uni-passau.de>
3287 Sebastian Pop <sebastian.pop@amd.com>
3289 * graphite-poly.c (unify_scattering_dimensions): Fix types.
3290 * graphite-poly.h (poly_dr_p, poly_dr, POLY_DR_TYPE, PDR_BB,
3291 PDR_TYPE, PDR_ACCESSES, pdr_accessp_nb_subscripts,
3292 pdr_accessp_nb_iterators, pdr_accessp_nb_params,
3293 pdr_accessp_alias_set_dim, pdr_accessp_subscript_dim,
3294 pdr_accessp_iterator_dim, pdr_accessp_param_dim,
3295 pbb_nb_params): New.
3296 (pbb_nb_loops, pbb_nb_scattering, scop_nb_params,
3297 nb_loops_around_pbb): Adapt return types.
3299 2009-03-09 Tobias Grosser <grosser@fim.uni-passau.de>
3301 * Makefile.in (graphite.o, graphite-sese-to-poly.o,
3302 graphite-clast-to-gimple.o, graphite-data-ref.o,
3303 graphite-scop-detection.o, graphite-poly.o): Add
3306 2009-03-05 Tobias Grosser <grosser@fim.uni-passau.de>
3308 * Makefile.in (graphite.o, graphite-sese-to-poly.o,
3309 graphite-clast-to-gimple.o, graphite-data-ref.o,
3310 graphite-scop-detection.o, graphite-poly.o): Add graphite-poly.h.
3312 2009-03-04 Tobias Grosser <grosser@fim.uni-passau.de>
3314 * testsuite/gcc.dg/graphite/pr37485.c: Remove -floop-block
3315 * testsuite/gcc.dg/graphite/pr37828.c: Same.
3316 * testsuite/gcc.dg/graphite/pr37684.c: Same.
3317 * testsuite/gcc.dg/graphite/block-0.c: Same.
3318 * testsuite/gcc.dg/graphite/block-1.c: Same.
3319 * testsuite/gcc.dg/graphite/block-2.c: Same.
3320 * testsuite/gcc.dg/graphite/block-3.c: Same.
3321 * testsuite/gcc.dg/graphite/block-4.c: Same.
3322 * testsuite/gcc.dg/graphite/block-5.c: Same.
3323 * testsuite/gcc.dg/graphite/block-6.c: Same.
3324 * testsuite/gfortran.dg/graphite/pr38083.f90: Same.
3325 * testsuite/gfortran.dg/graphite/block-1.f90: Same.
3326 * testsuite/gfortran.dg/graphite/block-3.f90: Same.
3327 * testsuite/gfortran.dg/graphite/pr37852.f90: Same.
3328 * testsuite/gfortran.dg/graphite/block-4.f90: Same.
3329 * testsuite/gfortran.dg/graphite/pr37980.f90: Same.
3330 * testsuite/gfortran.dg/graphite/pr38953.f90: Same.
3331 * testsuite/gfortran.dg/graphite/pr37857.f90: Same.
3332 * opts.c: Remove -floop-block from -O2.
3333 * graphite-poly.c: Fail if -floop-block -floop-interchange or
3334 -floop-strip-mine are used.
3336 2009-03-04 Tobias Grosser <grosser@fim.uni-passau.de>
3337 Sebastian Pop <sebastian.pop@amd.com>
3339 * graphite-clast-to-gimple.c (build_cloog_prog): Unify scattering
3341 * graphite-poly.c (pbb_compare, graphite_sort_pbbs,
3342 graphite_trans_bb_move_loop, graphite_trans_bb_strip_mine,
3343 strip_mine_profitable_p, is_interchange_valid,
3344 graphite_trans_bb_block, graphite_trans_loop_block,
3345 graphite_trans_scop_block): Temporary removed.
3346 (extend_scattering, unify_scattering_dimensions): New.
3347 (print_scattering_function, graphite_read_transforms):
3348 PBB_SCATTERING -> PBB_TRANSFORMED_SCATTERING.
3349 (graphite_generate_scattering_fns): Removed.
3350 (apply_poly_transforms): Cleanup.
3351 (free_poly_bb): Add PBB_SCATTERING -> PBB_TRANSFORMED_SCATTERING.
3352 (schedule_to_scattering): Moved.
3353 (PBB_STATIC_SCHEDULE, PBB_SCATTERING): Removed.
3354 (PBB_ORIGINAL_SCATTERING, PBB_TRANSFORMED_SCATTERING): New.
3355 (pbb_nb_scattering): New.
3356 (SCOP_ENTRY, SCOP_EXIT, SCOP_REGION_BBS, SCOP_DEP_GRAPH, SCOP_PARAMS,
3357 SCOP_LOOP_NEST, SCOP_PARAMS, SCOP_OLDIVS, SCOP_LIVEOUT_RENAMES):
3359 * graphite-ppl.c (ppl_insert_dimensions): Extended and renamed from
3361 (ppl_strip_loop): PBB_SCATTERING -> PBB_TRANSFORMED_SCATTERING.
3362 * graphite-scop-detection.c (dot_all_scops_1): PBB_SCATTERING
3363 -> PBB_TRANSFORMED_SCATTERING.
3364 * graphite-sese-to-poly.c (build_scop_bbs): Remove region.
3365 (build_pbb_scattering_polyhedron): Moved from schedule_to_scattering.
3366 (build_scop_scattering): Renamed from build_scop_canonical_schedules.
3367 (check_poly_representation): Do not return bool.
3368 (graphite_transform_loops): Reformat.
3369 * sese.h (SESE_ENTRY_BB, SESE_EXIT_BB): New.
3371 2009-03-04 Sebastian Pop <sebastian.pop@amd.com>
3373 * graphite-poly.c (print_pbb_domain, print_pbb, print_scop,
3374 debug_pbb_domain, debug_pbb, debug_scop): New.
3375 * graphite-poly.h (print_pbb_domain, print_pbb, print_scop,
3376 debug_pbb_domain, debug_pbb, debug_scop): Declared.
3378 2009-03-02 Sebastian Pop <sebastian.pop@amd.com>
3381 * tree-parloops.c (canonicalize_loop_ivs): Call fold_convert
3382 when the type precision of the induction variable should be
3383 larger than the type precision of nit.
3384 (gen_parallel_loop): Update use of canonicalize_loop_ivs.
3385 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Same.
3386 * tree-flow.h (canonicalize_loop_ivs): Update declaration.
3388 * testsuite/gcc.dg/graphite/pr39335_1.c: New.
3389 * testsuite/gcc.dg/graphite/pr39335.c: New.
3391 2009-03-02 Sebastian Pop <sebastian.pop@amd.com>
3393 * tree-parloops.c (canonicalize_loop_ivs): reduction_list contains
3394 SSA_NAMES not struct reduction_info.
3396 2009-03-02 Sebastian Pop <sebastian.pop@amd.com>
3398 * sese.c (expand_scalar_variables_expr): Handle ADDR_EXPR.
3400 2009-02-27 Sebastian Pop <sebastian.pop@amd.com>
3401 Tobias Grosser <grosser@fim.uni-passau.de>
3403 * sese.c (new_sese): Initialize SESE_REDUCTION_LIST.
3404 (free_sese): Free SESE_REDUCTION_LIST.
3405 * sese.h (struct sese): Add field reduction_list.
3406 (SESE_REDUCTION_LIST): New.
3407 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Call
3408 canonicalize_loop_ivs on SESE_REDUCTION_LIST.
3410 2009-02-27 Sebastian Pop <sebastian.pop@amd.com>
3411 Tobias Grosser <grosser@fim.uni-passau.de>
3413 * tree-flow.h (gather_scalar_reductions): Use struct loop * instead
3416 2009-02-27 Sebastian Pop <sebastian.pop@amd.com>
3417 Tobias Grosser <grosser@fim.uni-passau.de>
3419 * tree-parloops.c (struct brli, build_reduction_list_info,
3420 analyze_reduction_list, gather_scalar_reductions): New.
3421 (loop_parallel_p): Build a reduction list containing only
3422 PHI_RESULT SSA_NAMEs: call gather_scalar_reductions.
3423 (gen_parallel_loop): Call the analysis analyze_reduction_list.
3424 (parallelize_loops): Now reduction_list is a htab_t of SSA_NAMEs.
3425 * tree-flow.h (gather_scalar_reductions): Declared.
3427 2009-02-26 Sebastian Pop <sebastian.pop@amd.com>
3430 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not call
3431 number_of_iterations_exit from a gcc_assert.
3433 2009-02-25 Sebastian Pop <sebastian.pop@amd.com>
3434 Jan Sjodin <jan.sjodin@amd.com>
3436 * output.h (graphite_out_file, graphite_in_file): Declared.
3437 * toplev.c (graphite_out_file, graphite_in_file): New.
3438 (init_asm_output): Initialize graphite_in_file and graphite_out_file.
3439 * graphite-clast-to-gimple.c (build_cloog_prog): Read PBB_SCATTERING.
3440 Don't call schedule_to_scattering.
3441 * common.opt (fgraphite-write, fgraphite-read): New.
3442 * graphite-poly.c: Include output.h.
3443 (print_scattering_function, print_scattering_functions,
3444 debug_scattering_function, debug_scattering_functions,
3445 graphite_write_transforms, graphite_read_transforms,
3446 graphite_generate_scattering_fns): New.
3447 (apply_poly_transforms): Do not apply transform if flag_graphite_read.
3448 Call graphite_generate_scattering_fns, graphite_write_transforms,
3449 graphite_read_transforms.
3450 (new_poly_bb): Initialize PBB_SCATTERING.
3451 (free_poly_bb): Free PBB_SCATTERING.
3452 (schedule_to_scattering): Does not return, initialize PBB_SCATTERING.
3453 * graphite-poly.h (struct poly_bb): Add field scattering.
3454 (PBB_SCATTERING): New.
3455 (print_scattering_function, print_scattering_functions,
3456 debug_scattering_function, debug_scattering_functions): Declared.
3457 * graphite-ppl.c (cloog_matrix_to_ppl_constraint): Matrices contain
3458 GMP values, not integers!
3459 (ppl_print_polyhedron_matrix, debug_ppl_polyhedron_matrix,
3460 ppl_read_polyhedron_matrix): New.
3461 * graphite-ppl.h (ppl_print_polyhedron_matrix,
3462 debug_ppl_polyhedron_matrix,
3463 ppl_read_polyhedron_matrix): Declared.
3464 * Makefile.in (graphite-poly.o): Depends on output.h.
3466 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
3467 Tobias Grosser <grosser@fim.uni-passau.de>
3470 * graphite-scop-detection.c (stmt_simple_for_scop_p): Analyze
3471 scalar evolutions in the scop_entry->loop_father.
3473 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
3474 Tobias Grosser <grosser@fim.uni-passau.de>
3476 * graphite.h (ref_nb_loops): Remove declaration.
3477 (struct gimple_bb, gimple_bb_p, GBB_BB, GBB_DATA_REFS, GBB_CONDITIONS,
3478 GBB_CONDITION_CASES, GBB_CLOOG_IV_TYPES, gbb_loop, print_gimple_bb,
3479 debug_gbb): Moved to sese.h.
3482 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
3483 Tobias Grosser <grosser@fim.uni-passau.de>
3485 * graphite-data-ref.[ch]: Disable.
3487 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
3488 Tobias Grosser <grosser@fim.uni-passau.de>
3490 * graphite-scop-detection.c (stmt_simple_for_scop_p): Analyze
3491 scalar evolutions in the scop_entry->loop_father.
3493 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
3495 * graphite-scop-detection.c (nb_reductions_in_loop): Moved here...
3496 (graphite_cannot_represent_loop_niter): Renamed
3497 graphite_cannot_represent_loop. Call nb_reductions_in_loop.
3498 (limit_scops): build_sese_loop_nests does not return a bool.
3499 * graphite-scop-detection.h (nb_reductions_in_loop): Declared.
3500 * sese.c (nb_reductions_in_loop): ... from here.
3501 (graphite_loop_normal_form): ... from here.
3502 (sese_record_loop): Does not fail, so does not return a bool.
3503 (build_sese_loop_nests): Same.
3504 * sese.h (build_sese_loop_nests): Update declaration.
3505 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Moved here...
3506 (build_graphite_loop_normal_form): New.
3507 (gloog): Call build_graphite_loop_normal_form.
3508 * graphite-sese-to-poly.c (build_poly_scop): Don't fail on
3509 build_sese_loop_nests.
3511 * testsuite/gcc.dg/graphite/id-1.c: New.
3513 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
3514 Tobias Grosser <grosser@fim.uni-passau.de>
3516 * graphite-sese-to-poly.c (scan_tree_for_params): Remove REAL_CST.
3517 The SCoP detection fix is sufficient.
3519 2009-02-21 Sebastian Pop <sebastian.pop@amd.com>
3521 PR tree-optimization/39260
3522 * graphite-scop-detection.c (harmful_stmt_in_bb): Stop a SCoP when
3523 the basic block contains a condition with a real type.
3524 * graphite-sese-to-poly.c (scan_tree_for_params): Handle REAL_CST.
3526 * gcc.dg/graphite/pr39260.c: New.
3528 2009-02-21 Sebastian Pop <sebastian.pop@amd.com>
3530 * graphite-poly.c: Inlcude params.h.
3531 (graphite_trans_loop_block): Use PARAM_LOOP_BLOCK_TILE_SIZE for
3533 * Makefile.in (graphite-poly.o): Depend on PARAMS_H.
3534 * params.def (PARAM_LOOP_BLOCK_TILE_SIZE): Define.
3536 2009-02-20 Sebastian Pop <sebastian.pop@amd.com>
3537 Tobias Grosser <grosser@fim.uni-passau.de>
3539 * graphite-scop-detection.c (dot_all_scops_1,
3540 dot_all_scops): Moved here.
3541 * graphite-scop-detection.h (dot_all_scops): Declared here.
3542 * graphite.c (graphite_initialize, graphite_finalize): New.
3543 (graphite_transform_loops): Cleaned up.
3544 * sese.c (debug_oldivs): Moved here.
3545 * graphite-poly.c (graphite_apply_transformations): Renamed
3546 apply_poly_transforms.
3547 (debug_loop_vec): Moved here.
3548 * graphite-sese-to-poly.c (build_bb_loops, build_sese_conditions_1,
3549 scop_contains_non_iv_scalar_phi_nodes, build_sese_conditions,
3550 find_scop_parameters, build_scop_iteration_domain,
3551 add_conditions_to_constraints, build_scop_canonical_schedules,
3552 build_scop_data_accesses): Now static.
3553 (build_poly_scop, check_poly_representation): New.
3555 2009-02-20 Sebastian Pop <sebastian.pop@amd.com>
3557 * graphite.c (graphite_stmt_p, new_gimple_bb, free_gimple_bb,
3558 remove_gbbs_in_scop, free_scops, try_generate_gimple_bb,
3559 build_scop_bbs, ref_nb_loops, compare_prefix_loops,
3560 build_scop_canonical_schedules, build_bb_loops, add_value_to_dim,
3561 scan_tree_for_params_right_scev, scan_tree_for_params_int,
3562 scan_tree_for_params, struct irp_data, dx_record_params,
3563 find_params_in_bb, find_scop_parameters, gbb_from_bb,
3564 build_loop_iteration_domains, add_conditions_to_domain,
3565 phi_node_is_iv, bb_contains_non_iv_scalar_phi_nodes,
3566 scop_contains_non_iv_scalar_phi_nodes, build_sese_conditions_1,
3567 build_sese_conditions, add_conditions_to_constraints,
3568 build_scop_iteration_domain, build_access_matrix_with_af,
3569 build_access_matrix,
3570 build_scop_data_accesses): Moved to graphite-sese-to-poly.c.
3572 * graphite-sese-to-poly.c: New.
3573 * graphite-sese-to-poly.h: New.
3575 * Makefile.in: Add new rule for graphite-sese-to-poly.o.
3577 2009-02-20 Sebastian Pop <sebastian.pop@amd.com>
3579 * graphite.c: Split graphite code generation to a new file.
3580 (graphite_verify, gmp_cst_to_tree, clast_name_to_gcc,
3581 max_precision_type, clast_to_gcc_expression_red,
3582 clast_to_gcc_expression, gcc_type_for_clast_expr,
3583 gcc_type_for_clast_eq, loop_iv_stack_patch_for_consts,
3584 graphite_translate_clast_equation, graphite_create_guard_cond_expr,
3585 graphite_create_new_guard, clast_get_body_of_loop,
3586 gcc_type_for_cloog_iv, gcc_type_for_iv_of_clast_loop,
3587 graphite_create_new_loop, build_iv_mapping, copy_renames,
3588 translate_clast, find_cloog_iv_in_expr, compute_cloog_iv_types_1,
3589 compute_cloog_iv_types, free_scattering, save_var_name,
3590 initialize_cloog_names, build_scop_context, build_cloog_prog,
3591 set_cloog_options, debug_clast_stmt, scop_to_clast,
3592 print_generated_program, debug_generated_program,
3593 gloog): Moved to graphite-clast-to-gimple.c.
3595 (struct cloog_prog_clast): Moved to graphite-clast-to-gimple.h.
3597 (iv_stack_entry_is_constant, iv_stack_entry_is_iv,
3598 loop_iv_stack_push_iv, loop_iv_stack_insert_constant,
3599 loop_iv_stack_pop, loop_iv_stack_get_iv,
3600 loop_iv_stack_get_iv_from_name, debug_loop_iv_stack,
3601 free_loop_iv_stack, loop_iv_stack_remove_constants,
3602 debug_rename_elt, debug_rename_map_1, debug_rename_map,
3603 rename_map_elt_info, eq_rename_map_elts, debug_ivtype_elt,
3604 debug_ivtype_map_1, debug_ivtype_map, ivtype_map_elt_info,
3605 eq_ivtype_map_elts, sese_add_exit_phis_edge,
3606 sese_add_exit_phis_var, sese_insert_phis_for_liveouts,
3607 get_vdef_before_sese, sese_adjust_vphi,
3608 get_new_name_from_old_name, sese_adjust_phis_for_liveouts,
3609 oldiv_for_loop, rename_variables_in_stmt, is_parameter,
3610 is_iv, expand_scalar_variables_ssa_name,
3611 expand_scalar_variables_expr, expand_scalar_variables_stmt,
3612 expand_scalar_variables, rename_variables, remove_condition,
3613 get_true_edge_from_guard_bb, get_false_edge_from_guard_bb,
3614 add_loop_exit_phis, insert_loop_close_phis, struct igp,
3615 default_liveout_before_guard, add_guard_exit_phis,
3616 insert_guard_phis, register_old_and_new_names,
3617 graphite_copy_stmts_from_block, register_sese_liveout_renames,
3618 copy_bb_and_scalar_dependences, outermost_loop_in_sese,
3619 if_region_set_false_region, create_if_region_on_edge,
3620 move_sese_in_condition): Moved to sese.c.
3622 (nb_loops_around_loop_in_sese, struct ifsese, if_region_entry,
3623 if_region_exit, if_region_get_condition_block,
3624 struct rename_map_elt, new_rename_map_elt, enum iv_stack_entry_kind,
3625 union iv_stack_entry_data_union, struct iv_stack_entry_struct,
3626 iv_stack_entry_p, loop_iv_stack, struct ivtype_map_elt,
3627 ivtype_map_elt, new_ivtype_map_elt,
3628 recompute_all_dominators): Moved to sese.h.
3630 * graphite-clast-to-gimple.c: New.
3631 * graphite-clast-to-gimple.h: New.
3632 * Makefile.in: Add new rule for graphite-clast-to-gimple.o.
3633 * sese.c: Modified as said above.
3636 2009-02-20 Sebastian Pop <sebastian.pop@amd.com>
3638 * graphite.c: Split scop detection to a new file.
3639 (enum gbb_type, gbb_type, get_bb_type, struct sd_region_p, sd_region,
3640 move_sd_regions, loop_affine_expr, exclude_component_ref,
3641 is_simple_operand, stmt_simple_for_scop_p, harmful_stmt_in_bb,
3642 graphite_cannot_represent_loop_niter, struct scopdet_info,
3643 scopdet_basic_block_info, build_scops_1, bb_in_sd_region,
3644 find_single_entry_edge, find_single_exit_edge,
3645 create_single_entry_edge, sd_region_without_exit,
3646 create_single_exit_edge, unmark_exit_edges, mark_exit_edges,
3647 create_sese_edges, build_graphite_scops, limit_scops, build_scops):
3648 Moved to graphite-scop-detection.c.
3650 * graphite-scop-detection.c: New.
3651 * graphite-scop-detection.h: New.
3652 * Makefile.in: Add new rule for graphite-scop-detection.o.
3654 * sese.c: Include tree-chrec.h, tree-data-ref.h, and
3655 tree-scalar-evolution.h.
3656 (nb_reductions_in_loop, graphite_loop_normal_form, sese_record_loop,
3657 build_sese_loop_nests): Moved here from graphite.c.
3658 (param_index): Renamed parameter_index_in_region.
3660 2009-02-18 Tobias Grosser <grosser@fim.uni-passau.de>
3661 Sebastian Pop <sebastian.pop@amd.com>
3663 * gcc.dg/graphite/block-0.c: Expected to fail now.
3664 * gcc.dg/graphite/block-1.c: Same.
3665 * gcc.dg/graphite/block-5.c: Same.
3666 * gcc.dg/graphite/block-6.c: Same.
3668 2009-02-18 Tobias Grosser <grosser@fim.uni-passau.de>
3669 Sebastian Pop <sebastian.pop@amd.com>
3671 * graphite.h: Separate from graphite_bb_p the polyhedral
3672 representation in poly_bb_p and the GCC specifics in gimple_bb_p.
3673 (struct data_dependence_polyhedron, RDGE_DDP, ddp_p): Moved to
3674 graphite-data-ref.h.
3675 (struct poly_bb, PBB_SCOP, PBB_STATIC_SCHEDULE, PBB_DOMAIN,
3676 PBB_BLACK_BOX, PBB_LOOPS, pbb_nb_loops, pbb_loop_at_index,
3677 pbb_loop_index, struct scop, SCOP_BBS, SCOP_REGION, SCOP_ENTRY,
3678 SCOP_EXIT, SCOP_REGION_BBS, SCOP_DEP_GRAPH, SCOP_PARAMS,
3679 SCOP_LOOP_NEST, SCOP_PARAMS, SCOP_OLDIVS, SCOP_LIVEOUT_RENAMES,
3680 scop_nb_params): Moved to graphite-poly.h.
3681 * graphite-data-ref.c: Same.
3682 * graphite-data-ref.h: New.
3684 (pbb_compare, graphite_sort_pbbs, graphite_trans_bb_move_loop,
3685 graphite_trans_bb_strip_mine, strip_mine_profitable_p,
3686 is_interchange_valid, graphite_trans_bb_block,
3687 graphite_trans_loop_block, scop_max_loop_depth,
3688 graphite_trans_scop_block, graphite_apply_transformations,
3689 new_poly_bb, free_poly_bb, new_scop, free_scop): Moved to
3691 * graphite-poly.h: New.
3692 * graphite-poly.c: New.
3693 * Makefile.in (OBJS-common): Add graphite-poly.o.
3694 (graphite-poly.o): New rule.
3695 * tree-data-ref.h (struct data_reference): Remove unused scop field.
3698 2009-02-18 Sebastian Pop <sebastian.pop@amd.com>
3699 Tobias Grosser <grosser@fim.uni-passau.de>
3701 * graphite.c: Replace gb -> gbb.
3703 * graphite-data-ref.c: Same.
3705 2009-02-18 Sebastian Pop <sebastian.pop@amd.com>
3706 Tobias Grosser <grosser@fim.uni-passau.de>
3708 * Makefile.in (OBJS-commmon): Add sese.o.
3710 (graphite.o): Add sese.h.
3711 * graphite.c (bb_in_ss_p, loop_in_sese_p,
3712 sese_build_livein_liveouts_use, sese_build_livein_liveouts_bb,
3713 sese_build_livein_liveouts, register_bb_in_sese, new_sese, free_sese):
3715 (block_before_scop): Add missing return.
3716 (new_scop, free_scop): Remove SESE data structures.
3717 (scop_record_loop, scan_tree_for_params, find_params_in_bb,
3718 find_scop_parameters, build_loop_iteration_domains,
3719 add_conditions_to_domain, register_scop_liveout_renames,
3720 copy_bb_and_scalar_dependences): Scop -> SESE.
3722 (add_conditions_to_domain): SCoP -> SESE and remove check
3723 (scop_contains_non_iv_scalar_phi_nodes): New.
3724 (build_scop_conditions_1, build_scop_conditions): Remove check for
3725 non iv scalar phi nodes.
3726 (print_scop_statistics): New.
3727 (graphite_transform_loops): Cleanup.
3729 * graphite.h: Move to sese & cleanup.
3733 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
3734 Tobias Grosser <grosser@fim.uni-passau.de>
3736 * graphite.c (build_scop_conditions_1): Conditions are only
3737 at the end of a basic block.
3739 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
3740 Tobias Grosser <grosser@fim.uni-passau>
3742 * graphite.h (struct graphite_bb): Remove compressed_alpha_matrix
3744 (GBB_ALPHA): Removed.
3746 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
3747 Tobias Grosser <grosser@fim.uni-passau.de>
3749 * graphite-data-ref.c (graphite_test_dependence): Don't use
3750 GBB_DYNAMIC_SCHEDULE.
3751 * graphite.c (new_graphite_bb): Same.
3752 (free_graphite_bb): Same.
3753 (build_scop_dynamic_schedules): Removed.
3754 (graphite_transform_loops): Don't call it.
3755 * graphite.h (struct graphite_bb): Remove dynamic_schedule field.
3756 (GBB_DYNAMIC_SCHEDULE): Removed.
3758 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
3759 Tobias Grosser <grosser@fim.uni-passau.de>
3761 * graphite.c (schedule_to_scattering): Don't use CloogMatrix.
3762 (print_graphite_bb): Same.
3763 (build_cloog_prog): Same.
3765 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
3766 Tobias Grosser <grosser@fim.uni-passau.de>
3768 * graphite.c (build_cloog_prog): Don't use CloogMatrix.
3770 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
3771 Tobias Grosser <grosser@fim.uni-passau.de>
3773 * graphite.c (build_scop_context): Don't use CloogMatrix.
3774 * graphite-ppl.c (new_Cloog_Domain_from_ppl_Polyhedron): New.
3775 * graphite-ppl.h (new_Cloog_Domain_from_ppl_Polyhedron): Declared.
3777 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
3778 Tobias Grosser <grosser@fim.uni-passau.de>
3780 * graphite.h (struct scop): Move params, old_ivs, loops, loop_nest,
3781 liveout_renames, add_params fields...
3782 (struct sese): ... here.
3783 (SESE_PARAMS, SESE_LOOPS, SESE_LOOP_NEST, SESE_ADD_PARAMS,
3784 SESE_PARAMS, SESE_OLDIVS, SESE_LIVEOUT_RENAMES): New.
3786 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
3787 Tobias Grosser <grosser@fim.uni-passau.de>
3789 * graphite.c (print_scop): Do not print the CLooG program.
3790 (new_scop, free_scop, initialize_cloog_names, build_scop_context,
3791 build_cloog_prog, gloog): Don't use SCOP_PROG.
3792 (find_transform): Renamed scop_to_clast.
3793 (print_generated_program, debug_generated_program): New.
3794 (graphite_transform_loops): Adapt to new interface.
3795 * graphite.h (struct scop): Remove program field.
3796 (SCOP_PROG): Removed.
3797 (print_generated_program, debug_generated_program): Declared.
3799 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
3801 * graphite-data-ref.c (schedule_precedes_p, schedule_same_p): New.
3802 (statement_precedes_p): Use schedule_same_p and schedule_precedes_p.
3803 * graphite.c (gbb_compare, schedule_to_scattering, print_graphite_bb,
3804 free_graphite_bb, build_scop_canonical_schedules,
3805 graphite_trans_bb_strip_mine, graphite_trans_scop_block): Static
3806 schedules are now represented using a ppl_Linear_Expression_t.
3807 * graphite.h (struct graphite_bb): Same.
3808 * graphite-ppl.c (ppl_lexico_compare_linear_expressions): New.
3809 * graphite-ppl.h (ppl_lexico_compare_linear_expressions): Declared.
3811 2009-02-15 Sebastian Pop <sebastian.pop@amd.com>
3813 * graphite.c: Free local memory.
3814 * graphite-ppl.c: Same.
3816 2009-02-15 Sebastian Pop <sebastian.pop@amd.com>
3818 * graphite.c (const_column_index, get_first_matching_sign_row_index,
3819 get_lower_bound_row, get_upper_bound_row, copy_constraint,
3820 swap_constraint_variables, scale_constraint_variable): Removed.
3821 (graphite_trans_bb_strip_mine): Remove pong.
3822 * graphite-ppl.c: Include missing header files.
3823 (set_inhomogeneous, set_coef, shift_poly, ppl_strip_loop): New.
3824 * graphite-ppl.h (ppl_strip_loop): Declared.
3825 * Makefile.in (graphite-ppl.o): Adjust dependences.
3827 2009-02-14 Sebastian Pop <sebastian.pop@amd.com>
3829 * graphite.c (build_loop_iteration_domains): Remove ping pong.
3830 (build_scop_iteration_domain): Same.
3832 2009-02-13 Sebastian Pop <sebastian.pop@amd.com>
3834 * graphite.c (scan_tree_for_params, add_conditions_to_domain): Remove
3836 (add_value_to_dim, scan_tree_for_params_right_scev,
3837 scan_tree_for_params_int): New.
3838 * graphite-ppl.c (oppose_constraint): New.
3839 (insert_constraint_into_matrix): Implement missing cases.
3840 * graphite-ppl.h (insert_constraint_into_matrix): Declared.
3842 2009-02-13 Sebastian Pop <sebastian.pop@amd.com>
3844 * graphite.c (graphite_trans_bb_move_loop): Remove ping pong,
3845 use ppl_move_dimension.
3847 2009-02-12 Sebastian Pop <sebastian.pop@amd.com>
3849 * graphite-data-ref.c: Domains are now ppl_Polyhedra_t.
3852 * graphite-ppl.c: Same.
3853 * graphite-ppl.h: Same.
3855 2009-02-12 Sebastian Pop <sebastian.pop@amd.com>
3857 Revert last 3 commits.
3859 2009-02-10 Sebastian Pop <sebastian.pop@amd.com>
3861 * graphite.c (scan_tree_for_params, add_conditions_to_domain): Remove
3863 (add_value_to_dim, scan_tree_for_params_right_scev,
3864 scan_tree_for_params_int): New.
3865 * graphite-ppl.c (oppose_constraint): New.
3866 (insert_constraint_into_matrix): Implement missing cases.
3867 * graphite-ppl.h (insert_constraint_into_matrix): Declared.
3869 2009-02-10 Sebastian Pop <sebastian.pop@amd.com>
3871 * graphite.c (graphite_trans_bb_move_loop): Remove unused variables.
3873 2009-02-10 Sebastian Pop <sebastian.pop@amd.com>
3874 Tobias Grosser <grosser@fim.uni-passau.de>
3876 * graphite.c (graphite_trans_bb_move_loop): Remove ping pong,
3877 use ppl_move_dimension.
3878 * graphite-ppl.c (ppl_move_dimension): New.
3879 * graphite-ppl.h (ppl_move_dimension): Declared.
3881 2009-02-10 Sebastian Pop <sebastian.pop@amd.com>
3883 * graphite.c: Do not include cloog/cloog.h.
3884 (print_graphite_bb): Remove ping pong, call PPL print function.
3886 2009-02-10 Tobias Grosser <grosser@fim.uni-passau.de>
3888 * Makefile.in (OBJS-common): Add graphite-ppl.o.
3889 (graphite.o): Add dependence on graphite-ppl.h.
3890 (graphite-ppl.o): New.
3891 (graphite-data-ref.c): Ping pong between PPL data structures
3893 * graphite-ppl.c: New.
3894 * graphite-ppl.h: New.
3895 * graphite.c: Include graphite-ppl.h.
3896 (print_graphite_bb, add_conditions_to_domain, build_cloog_prog,
3897 graphite_trans_bb_move_loop, graphite_trans_bb_strip_mine):
3898 Ping pong between PPL data structures and matrices.
3899 (new_graphite_bb): Create a PPL constraint system.
3900 Call ppl_delete_Constraint_System instead of cloog_matrix_free.
3901 (build_loop_iteration_domains): Use PPL functions.
3902 * graphite.h: Include graphite-ppl.h. Fix comments.
3903 (graphite_bb): Use a ppl_Constraint_System_t instead of
3904 CloogMatrix for representing the domain.
3905 (scop): Remove static_schedule.
3906 (gbb_nb_loops): Ping pong between PPL data structures and matrices.
3908 2009-02-06 Sebastian Pop <sebastian.pop@amd.com>
3910 * graphite.c: Fix some comments.
3912 2009-02-05 Sebastian Pop <sebastian.pop@amd.com>
3915 * graphite.c (if_region_set_false_region): After moving a region
3916 in the false branch of a condition, remove the empty dummy
3918 (gloog): Remove wrong fix for PR38953.
3920 2009-02-03 Tobias Grosser <grosser@fim.uni-passau.de>
3922 * graphite.c (bb_in_sese_p, sese_build_livein_liveouts_use,
3923 sese_build_livein_liveouts_bb, sese_build_livein_liveouts,
3924 register_bb_in_sese, new_sese, free_sese): Moved.
3925 (dot_scop_1, build_scop_loop_nests, build_loop_iteration_domains,
3926 outermost_loop_in_scop, build_scop_iteration_domain,
3927 expand_scalar_variables_ssa_name, get_vdef_before_scop,
3928 limit_scops): Use bb_in_sese_p instead of bb_in_scop_p.
3929 Use loop_in_sese_p instead of loop_in_scop_p.
3930 (new_graphite_bb, new_scop, gloog): Do not initialize SCOP_BBS_B.
3931 (free_scop): Do not free SCOP_BBS_B.
3932 (nb_loops_around_loop_in_scop, nb_loops_around_gb,
3933 ref_nb_loops): Moved here...
3934 * graphite.h (ref_nb_loops): ... from here.
3935 (struct scop): Remove bbs_b bitmap.
3936 (SCOP_BBS_B, bb_in_scop_p, loop_in_scop_p): Removed.
3937 * testsuite/gcc.dg/graphite/scop-19.c: New
3939 2009-02-03 Tobias Grosser <grosser@fim.uni-passau.de>
3941 * graphite.c (scopdet_basic_block_info): Fix bug in scop
3944 2009-01-30 Tobias Grosser <grosser@fim.uni-passau.de>
3946 * graphite.c (new_loop_to_cloog_loop_str, hash_loop_to_cloog_loop,
3947 eq_loop_to_cloog_loop): Remove.
3948 (new_scop, free_scop): Remove SCOP_LOOP2CLOOG_LOOP.
3949 * graphite.h (struct scop): Remove loop2cloog_loop.
3950 (loop_domain_dim, loop_iteration_vector_dim): Remove.
3952 2009-01-30 Tobias Grosser <grosser@fim.uni-passau.de>
3954 * opts.c (decode_options): Only add graphite options to O2
3955 if we compile with graphite enabled.
3957 2009-01-26 Sebastian Pop <sebastian.pop@amd.com>
3959 * Merge from mainline (r143163:143684).
3961 2009-01-26 Sebastian Pop <sebastian.pop@amd.com>
3963 * graphite.c (debug_value): Removed.
3964 * graphite.h (debug_value): Removed.
3966 2009-01-23 Sebastian Pop <sebastian.pop@amd.com>
3968 * passes.c (init_optimization_passes): Do not call pass_copy_prop
3969 after graphite: pass_copy_prop does not maintain a proper loop closed
3970 SSA form. pass_copy_prop should be fixed.
3972 2009-01-23 Sebastian Pop <sebastian.pop@amd.com>
3974 * graphite.c (scop_adjust_phis_for_liveouts): Fix warning.
3976 2009-01-23 Sebastian Pop <sebastian.pop@amd.com>
3978 * graphite.c (graphite_verify): Add a call to verify_loop_closed_ssa.
3979 (gloog): Split the exit of the scop when the scop exit is a loop exit.
3980 (graphite_transform_loops): Only call cleanup_tree_cfg if gloog
3983 2009-01-20 Sebastian Pop <sebastian.pop@amd.com>
3985 * graphite.c (gloog): Return true when code gen succeeded.
3986 (graphite_transform_loops): Do not call cleanup_tree_cfg if
3987 the code of the function did not changed. After cleanup_tree_cfg
3988 call rewrite_into_loop_closed_ssa to maintain the loop closed ssa
3991 2009-01-19 Sebastian Pop <sebastian.pop@amd.com>
3993 * graphite.c (stmt_simple_for_scop_p): Also handle cases when
3994 gimple_call_lhs is NULL.
3996 2009-01-16 Sebastian Pop <sebastian.pop@amd.com>
3997 Tobias Grosser <tobi.grosser@amd.com>
3999 * graphite.c (graphite_trans_scop_block): Do not block single
4002 2009-01-15 Sebastian Pop <sebastian.pop@amd.com>
4003 Tobias Grosser <tobi.grosser@amd.com>
4005 * graphite.c (build_scop_canonical_schedules): Start schedules at
4008 2009-01-15 Sebastian Pop <sebastian.pop@amd.com>
4009 Tobias Grosser <tobi.grosser@amd.com>
4011 * graphite.c (compare_prefix_loops): New.
4012 (build_scop_canonical_schedules): Rewritten.
4013 (graphite_transform_loops): Move build_scop_canonical_schedules
4014 after build_scop_iteration_domain.
4016 2009-01-14 Sebastian Pop <sebastian.pop@amd.com>
4017 Tobias Grosser <tobi.grosser@amd.com>
4019 * graphite.c (add_conditions_to_domain): Add the loops to
4020 the dimension of the iteration domain. Do copy the domain
4021 only when it exists.
4022 (build_scop_conditions_1): Do not call add_conditions_to_domain.
4023 (add_conditions_to_constraints): New.
4024 (can_generate_code_stmt, can_generate_code): Removed.
4025 (gloog): Do not call can_generate_code.
4026 (graphite_transform_loops): Call add_conditions_to_constraints
4027 after building the iteration domain.
4029 2009-01-14 Sebastian Pop <sebastian.pop@amd.com>
4030 Tobias Grosser <tobi.grosser@amd.com>
4031 Jan Sjodin <jan.sjodin@amd.com>
4033 * graphite.c (scan_tree_for_params): On substractions negate
4034 all the coefficients of the term.
4035 (clast_to_gcc_expression_red): New. Handle reduction expressions
4036 of more than two operands.
4037 (clast_to_gcc_expression): Call clast_to_gcc_expression_red.
4038 (get_vdef_before_scop): Handle also the case of default definitions.
4040 2009-01-14 Sebastian Pop <sebastian.pop@amd.com>
4043 * graphite.c (get_vdef_before_scop, scop_adjust_vphi): New.
4044 (scop_adjust_phis_for_liveouts): Call scop_adjust_vphi.
4045 (gloog): Do not call cleanup_tree_cfg.
4046 (graphite_transform_loops): Call cleanup_tree_cfg after all
4047 scops have been code generated.
4049 2009-01-13 Sebastian Pop <sebastian.pop@amd.com>
4051 * passes.c (init_optimization_passes): Schedule after
4052 graphite transforms pass_copy_prop, pass_dce_loop and pass_lim.
4054 2009-01-13 Sebastian Pop <sebastian.pop@amd.com>
4056 * graphite.c (expand_scalar_variables_stmt): Do not pass loop_p.
4058 (expand_scalar_variables_ssa_name): Do not pass loop_p. Fix comment.
4059 Set the type of an expression to the type of its assign statement.
4060 (expand_scalar_variables_expr): Do not pass loop_p.
4061 Fix comment. Stop recursion on tcc_constant or tcc_declaration.
4062 (copy_bb_and_scalar_dependences): Do not pass loop_p.
4063 (translate_clast): Update call to copy_bb_and_scalar_dependences.
4065 2009-01-11 Sebastian Pop <sebastian.pop@amd.com>
4067 * graphite.c (expand_scalar_variables_ssa_name): Set the type of
4068 an expression to the gimple_expr_type of its assign statement.
4069 (expand_scalar_variables_expr): Stop recursion on tcc_constant
4072 2009-01-11 Sebastian Pop <sebastian.pop@amd.com>
4074 PR tree-optimization/38786
4075 * testsuite/gcc.dg/graphite/pr38786.c: New.
4076 * graphite.c (expand_scalar_variables_ssa_name): New, outlined from
4077 the SSA_NAME case of expand_scalar_variables_expr.
4078 (expand_scalar_variables_expr): Also gather the scalar computation
4079 used to index the memory access.
4080 (expand_scalar_variables_stmt): Pass to expand_scalar_variables_expr
4081 the gimple_stmt_iterator where it inserts new code.
4083 2009-01-10 Sebastian Pop <sebastian.pop@amd.com>
4085 * testsuite/gcc.dg/graphite/block-3.c: Fix compile error on 32bit.
4087 2009-01-10 Sebastian Pop <sebastian.pop@amd.com>
4089 * opts.c (decode_options): Enable flag_graphite_identity and
4090 flag_loop_block in -O2 and above.
4092 2009-01-08 Sebastian Pop <sebastian.pop@amd.com>
4094 * libjava/classpath/lib/gnu/java/awt/peer/gtk/GtkMouseInfoPeer.class:
4095 Fix merge problem: replace with the file from trunk.
4097 2009-01-08 Sebastian Pop <sebastian.pop@amd.com>
4099 * Merge from mainline (r141727:143163).
4101 2009-01-07 Sebastian Pop <sebastian.pop@amd.com>
4102 Jan Sjodin <jan.sjodin@amd.com>
4104 PR tree-optimization/38559
4105 * testsuite/gcc.dg/graphite/pr38559.c: New.
4107 * graphite.c (debug_value, copy_constraint,
4108 swap_constraint_variables, scale_constraint_variable, ): New.
4109 (get_lower_bound, get_upper_bound): Removed.
4110 (graphite_trans_bb_strip_mine): Clean up this code that works
4111 only for constant number of iterations. Fully copy upper and
4112 lower bound constraints, not only the constant part of them.
4113 * graphite.h (debug_value): Declared.
4115 2009-01-06 Jan Sjodin <jan.sjodin@amd.com>
4117 PR tree-optimization/38492
4118 PR tree-optimization/38498
4119 * tree-check.c (operator_is_linear, scev_is_linear_expression): New.
4120 * tree-chrec.h (scev_is_linear_expression): Declared.
4121 * graphite.c (graphite_cannot_represent_loop_niter): New.
4122 (scopdet_basic_block_info): Call graphite_cannot_represent_loop_niter.
4123 (graphite_loop_normal_form): Use gcc_assert.
4124 (scan_tree_for_params): Use CASE_CONVERT.
4125 (phi_node_is_iv, bb_contains_non_iv_scalar_phi_nodes): New.
4126 (build_scop_conditions_1): Call bb_contains_non_iv_scalar_phi_nodes.
4127 Use gcc_assert. Discard scops that contain unhandled cases.
4128 (build_scop_conditions): Return a boolean status for unhandled cases.
4129 (strip_mine_profitable_p): Print the loop number, not its depth.
4130 (is_interchange_valid): Pass the depth of the loop nest, don't
4131 recompute it wrongly.
4132 (graphite_trans_bb_block): Same.
4133 (graphite_trans_bb_block): Print tentative of loop blocking.
4134 (graphite_trans_scop_block): Do not print that the loop has been
4136 (graphite_transform_loops): Do not handle scops that contain condition
4139 * testsuite/gcc.dg/graphite/pr38500.c: Fixed warning as committed
4141 * testsuite/gcc.dg/graphite/block-0.c: Update test.
4142 * testsuite/gcc.dg/graphite/block-1.c: Same.
4143 * testsuite/gcc.dg/graphite/block-2.c: Remove xfail and test for
4145 * testsuite/gcc.dg/graphite/block-4.c: Remove test for strip mine.
4146 * testsuite/gcc.dg/graphite/block-3.c: New.
4147 * testsuite/gcc.dg/graphite/pr38498.c: New.
4149 2008-12-22 Harsha Jagasia <harsha.jagasia@amd.com>
4151 PR tree-optimization/38510
4152 * gcc.dg/graphite/pr38510.c: New.
4153 * graphite.c (recompute_all_dominators): Call mark_irreducible_loops.
4154 (translate_clast): Call recompute_all_dominators before
4156 (gloog): Call recompute_all_dominators before graphite_verify.
4158 2008-12-12 Sebastian Pop <sebastian.pop@amd.com>
4160 PR tree-optimization/38492
4161 * graphite.c (rename_map_elt, debug_rename_elt,
4162 debug_rename_map_1, debug_rename_map, new_rename_map_elt,
4163 rename_map_elt_info, eq_rename_map_elts,
4164 get_new_name_from_old_name, bb_in_sese_p): Moved around.
4165 (sese_find_uses_to_rename_use): Renamed sese_build_livein_liveouts_use.
4166 (sese_find_uses_to_rename_bb): Renamed sese_build_livein_liveouts_bb.
4167 (sese_build_livein_liveouts): New.
4168 (new_sese, free_sese): New.
4169 (new_scop): Call new_sese.
4170 (free_scop): Call free_sese.
4171 (rename_variables_from_edge, rename_phis_end_scop): Removed.
4172 (register_old_new_names): Renamed register_old_and_new_names.
4173 (register_scop_liveout_renames, add_loop_exit_phis,
4174 insert_loop_close_phis, struct igp,
4175 default_liveout_before_guard, add_guard_exit_phis,
4176 insert_guard_phis, copy_renames): New.
4177 (translate_clast): Call insert_loop_close_phis and insert_guard_phis.
4178 (sese_add_exit_phis_edge): Renamed scop_add_exit_phis_edge.
4179 (rewrite_into_sese_closed_ssa): Renamed scop_insert_phis_for_liveouts.
4180 (scop_adjust_phis_for_liveouts): New.
4181 (gloog): Call scop_adjust_phis_for_liveouts.
4183 * graphite.h (struct sese): Documented. Added fields liveout,
4185 (SESE_LIVEOUT, SESE_LIVEIN, SESE_LIVEIN_VER, SESE_NUM_VER): New.
4186 (new_sese, free_sese, sese_build_livein_liveouts): Declared.
4187 (struct scop): Added field liveout_renames.
4188 (SCOP_LIVEOUT_RENAMES): New.
4190 2008-12-11 Sebastian Pop <sebastian.pop@amd.com>
4192 PR tree-optimization/38409
4193 * gcc.dg/graphite/pr38409.c: New.
4194 * graphite.c (nb_reductions_in_loop): Use simple_iv.
4196 2008-12-11 Sebastian Pop <sebastian.pop@amd.com>
4198 * graphite.c (gcc_type_for_cloog_iv): By default return
4200 (graphite_create_new_loop): Don't fold_convert the already
4201 fold_convert-ed expression.
4203 2008-12-11 Harsha Jagasia <harsha.jagasia@amd.com>
4205 PR tree-optimization/38446
4206 * gcc.dg/graphite/pr38446.c: New.
4207 * graphite.c (register_bb_in_sese): New.
4208 (bb_in_sese_p): Check if bb belongs to sese region by explicitly
4209 looking at the bbs in the region.
4210 * graphite.h (sese): Add region_basic_blocks pointer set to
4211 structure and initialize at the time of defining new scop.
4213 2008-12-11 Tobias Grosser <grosser@fim.uni-passau.de>
4215 * graphite.c (new_graphite_bb): Initialize GBB_STATIC_SCHEDULE.
4216 (find_params_in_bb): Do not free data refs.
4217 (free_graphite_bb): Add FIXME on disabled free_data_refs.
4219 2008-12-11 Sebastian Pop <sebastian.pop@amd.com>
4221 * testsuite/gcc.dg/graphite/scop-16.c: Test only scop specific info.
4222 * testsuite/gcc.dg/graphite/scop-17.c: Same.
4223 * testsuite/gcc.dg/graphite/block-5.c: New.
4224 * testsuite/gcc.dg/graphite/block-6.c: New.
4225 * testsuite/gcc.dg/graphite/pr37485.c: Clean dump file after.
4226 * testsuite/gcc.dg/graphite/pr37684.c: Same.
4227 * testsuite/gcc.dg/graphite/block-2.c: Same.
4229 * graphite.c (struct ivtype_map_elt): New.
4230 (debug_ivtype_elt, debug_ivtype_map_1, debug_ivtype_map,
4231 new_ivtype_map_elt, ivtype_map_elt_info, eq_ivtype_map_elts,
4232 gcc_type_for_cloog_iv): New.
4233 (loop_iv_stack_patch_for_consts): Use the type of the induction
4234 variable from the original loop, except for the automatically
4235 generated loops, i.e., in the case of a strip-mined loop, in
4236 which case there is no original loop: in that case just use
4238 (new_graphite_bb): Initialize GBB_CLOOG_IV_TYPES.
4239 (free_graphite_bb): Free GBB_CLOOG_IV_TYPES.
4240 (clast_name_to_gcc): Accept params to be NULL.
4241 (clast_to_gcc_expression): Take an extra parameter for the type.
4242 Convert to that type all the expressions built by this function.
4243 (gcc_type_for_clast_expr, gcc_type_for_clast_eq): New.
4244 (graphite_translate_clast_equation): Compute the type of the
4245 clast_equation before translating its LHS and RHS.
4246 (clast_get_body_of_loop, gcc_type_for_iv_of_clast_loop): New.
4247 (graphite_create_new_loop): Compute the type of the induction
4248 variable before translating the lower and upper bounds and before
4249 creating the induction variable.
4250 (rename_variables_from_edge, rename_phis_end_scop): New.
4251 (copy_bb_and_scalar_dependences): Call rename_phis_end_scop.
4252 (sese_add_exit_phis_edge): Do not use integer_zero_node.
4253 (find_cloog_iv_in_expr, compute_cloog_iv_types_1,
4254 compute_cloog_iv_types): New.
4255 (gloog): Call compute_cloog_iv_types before starting the
4256 translation of the clast.
4258 * graphite.h (struct graphite_bb): New field cloog_iv_types.
4259 (GBB_CLOOG_IV_TYPES): New.
4260 (debug_ivtype_map): Declared.
4261 (oldiv_for_loop): New.
4263 2008-12-10 Tobias Grosser <grosser@fim.uni-passau.de>
4266 * graphite.c (new_scop): Initialize SCOP_ADD_PARAMS.
4267 (param_index): Assert if parameter is not know after parameter
4269 (find_params_in_bb): Detect params directly in GBB_CONDITIONS.
4270 (find_scop_parameters): Mark, that we have finished parameter
4272 (graphite_transform_loops): Move condition detection before parameter
4274 * graphite.h (struct scop): Add SCOP_ADD_PARAMS.
4275 * testsuite/gfortran.dg/graphite/pr38459.f90: New.
4277 2008-12-09 Tobias Grosser <grosser@fim.uni-passau.de>
4279 * graphite.c (graphite_transform_loops): Always call find_transform ()
4280 in ENABLE_CHECKING. So we test these code paths, even if we do not
4283 2008-12-09 Tobias Grosser <grosser@fim.uni-passau.de>
4285 * graphite.c (print_graphite_bb): Fix printing to file != dump_file.
4286 (print_scop): Ditto.
4288 2008-12-08 Tobias Grosser <grosser@fim.uni-passau.de>
4291 Fix testsuite/gfortran.dg/graphite/id-3.f90.
4292 * graphite.c (scopdet_basic_block_info): Fix bug that found some
4293 regions more than once.
4295 2008-12-03 Sebastian Pop <sebastian.pop@amd.com>
4297 Fix testsuite/gfortran.dg/graphite/id-4.f90.
4298 * graphite.c (scan_tree_for_params): Do not compute the multiplicand
4301 2008-12-03 Sebastian Pop <sebastian.pop@amd.com>
4303 Fix testsuite/gfortran.dg/graphite/id-1.f90.
4304 * graphite.c (gmp_cst_to_tree): Pass the type in parameter.
4305 (loop_iv_stack_patch_for_consts): Update use of gmp_cst_to_tree.
4306 (max_precision_type): New.
4307 (value_clast): Removed.
4308 (clast_to_gcc_expression): Be more careful to types of expressions.
4309 Use max_precision_type and update use of gmp_cst_to_tree.
4310 (graphite_translate_clast_equation): Use max_precision_type.
4311 (graphite_create_guard_cond_expr): Do not use integer_type_node,
4312 use the type of the condition.
4313 (graphite_create_new_loop): Do not use integer_type_node, use the
4314 max_precision_type of lb and ub.
4316 2008-12-03 Sebastian Pop <sebastian.pop@amd.com>
4318 * graphite.c (build_scops_1): Initialize open_scop.exit
4321 2008-12-02 Sebastian Pop <sebastian.pop@amd.com>
4323 * testsuite/gcc.dg/graphite/pr38084.c: New.
4324 * testsuite/gfortran.dg/graphite/id-1.f90: New.
4325 * testsuite/gfortran.dg/graphite/id-2.f90: New.
4326 * testsuite/gfortran.dg/graphite/id-3.f90: New.
4327 * testsuite/gfortran.dg/graphite/id-4.f90: New.
4328 * testsuite/gfortran.dg/graphite/pr37857.f90: New.
4330 2008-12-02 Sebastian Pop <sebastian.pop@amd.com>
4331 Jan Sjodin <jan.sjodin@amd.com>
4332 Harsha Jagasia <harsha.jagasia@amd.com>
4344 * testsuite/gcc.dg/graphite/pr38073.c: New.
4345 * testsuite/gcc.dg/graphite/pr37928.c: New.
4346 * testsuite/gcc.dg/graphite/pr37883.c: New.
4347 * testsuite/gcc.dg/graphite/pr38125.c: New.
4348 * testsuite/gfortran.dg/graphite/pr38083.f90: New.
4349 * testsuite/gfortran.dg/graphite/pr37852.f90: New.
4350 * testsuite/gfortran.dg/graphite/pr37980.f90: New.
4352 * testsuite/gcc.dg/graphite/scop-18.c: Remove reduction, test for
4353 the number of detected scops. Copy exact same test for loop
4355 * testsuite/gcc.dg/graphite/block-1.c: Fix the number of expected
4356 loops to be blocked as reductions are not handled.
4357 * testsuite/gcc.dg/graphite/block-4.c: ...here. New.
4359 * tree-phinodes.c (remove_phi_nodes): New, extracted from...
4360 * tree-cfg.c (remove_phi_nodes_and_edges_for_unreachable_block):
4362 * tree-flow.h (remove_phi_nodes, canonicalize_loop_ivs): Declared.
4363 * Makefile.in (graphite.o): Depend on value-prof.h.
4364 (graphite.o-warn): Removed -Wno-error.
4365 * tree-parloops.c (canonicalize_loop_ivs): Allow reduction_list
4366 to be a NULL pointer. Call update_stmt. Return the newly created
4367 cannonical induction variable.
4369 * graphite.h (debug_rename_map): Declared. Fix some comments.
4371 * graphite.c: Reimplement the code generation from graphite to gimple.
4372 Include value-prof.h.
4373 (loop_iv_stack_get_iv): Do not return NULL for constant substitutions.
4374 (get_old_iv_from_ssa_name): Removed.
4375 (graphite_stmt_p): New.
4376 (new_graphite_bb): Test for useful statements before building a
4377 graphite statement for the basic block.
4378 (free_graphite_bb): Do not free GBB_DATA_REFS: this is a bug
4379 in free_data_ref that calls BITMAP_FREE (DR_VOPS (dr)) without
4381 (recompute_all_dominators, graphite_verify,
4382 nb_reductions_in_loop, graphite_loop_normal_form): New.
4383 (scop_record_loop): Call graphite_loop_normal_form.
4384 (build_scop_loop_nests): Iterate over all the blocks of the
4385 function instead of relying on the incomplete information from
4386 SCOP_BBS. Return the success of the operation.
4387 (find_params_in_bb): Use the data from GBB_DATA_REFS.
4388 (add_bb_domains): Removed.
4389 (build_loop_iteration_domains): Don't call add_bb_domains.
4390 Add the iteration domain only to the basic blocks that have been
4391 translated to graphite.
4392 (build_scop_conditions_1): Add constraints only if the basic
4393 block have been translated to graphite.
4394 (build_scop_data_accesses): Completely disabled until data
4395 dependence is correctly implemented.
4396 (debug_rename_elt, debug_rename_map_1, debug_rename_map): New.
4397 (remove_all_edges_1, remove_all_edges): Removed.
4398 (get_new_name_from_old_name): New.
4399 (graphite_rename_variables_in_stmt): Renamed
4400 rename_variables_in_stmt. Call get_new_name_from_old_name.
4401 Use replace_exp and update_stmt.
4402 (is_old_iv): Renamed is_iv.
4403 (expand_scalar_variables_stmt): Extra parameter for renaming map.
4404 Use replace_exp and update_stmt.
4405 (expand_scalar_variables_expr): Same. Use the map to get the
4406 new names for the renaming of induction variables and for the
4407 renaming of variables after a basic block has been copied.
4408 (expand_scalar_variables): Same.
4409 (graphite_rename_variables): Renamed rename_variables.
4410 (move_phi_nodes): Removed.
4411 (get_false_edge_from_guard_bb): New.
4412 (build_iv_mapping): Do not insert the induction variable of a
4413 loop in the renaming iv map if the basic block does not belong
4415 (register_old_new_names, graphite_copy_stmts_from_block,
4416 copy_bb_and_scalar_dependences): New.
4417 (translate_clast): Heavily reimplemented: copy basic blocks,
4418 do not move them. Finally, in call cleanup_tree_cfg in gloog.
4419 At each translation step call graphite_verify ensuring the
4420 consistency of the SSA, loops and dominators information.
4421 (collect_virtual_phis, find_vdef_for_var_in_bb,
4422 find_vdef_for_var_1, find_vdef_for_var,
4423 patch_phis_for_virtual_defs): Removed huge hack.
4424 (mark_old_loops, remove_dead_loops, skip_phi_defs,
4425 collect_scop_exit_phi_args, patch_scop_exit_phi_args,
4426 gbb_can_be_ignored, scop_remove_ignoreable_gbbs, ): Removed.
4427 (remove_sese_region, ifsese, if_region_entry, if_region_exit,
4428 if_region_get_condition_block, if_region_set_false_region,
4429 create_if_region_on_edge, move_sese_in_condition, bb_in_sese_p,
4430 sese_find_uses_to_rename_use, sese_find_uses_to_rename_bb,
4431 sese_add_exit_phis_edge, sese_add_exit_phis_var,
4432 rewrite_into_sese_closed_ssa): New.
4433 (gloog): Remove dead code. Early return if code cannot be
4434 generated. Call cleanup_tree_cfg once the scop has been code
4436 (graphite_trans_scop_block, graphite_trans_loop_block): Do not
4437 block loops with less than two loops.
4438 (graphite_apply_transformations): Remove the call to
4439 scop_remove_ignoreable_gbbs.
4440 (limit_scops): When build_scop_loop_nests fails, continue on
4441 the next scop. Fix open_scop.entry.
4442 (graphite_transform_loops): Call recompute_all_dominators: force the
4443 recomputation of correct CDI_DOMINATORS and CDI_POST_DOMINATORS.
4444 Call initialize_original_copy_tables and free_original_copy_tables
4445 to be able to copy basic blocks during code generation.
4446 When build_scop_loop_nests fails, continue on next scop.
4447 (value_clast): New union.
4448 (clast_to_gcc_expression): Fix type cast warning.
4450 2008-11-09 Sebastian Pop <sebastian.pop@amd.com>
4452 * Merge from mainline (r140838:141727).
4454 2008-11-05 Tobias Grosser <grosser@fim.uni-passau.de>
4458 * graphite.c (scan_tree_for_params): Add POINTER_PLUS_EXPR.
4460 2008-11-05 Tobias Grosser <grosser@fim.uni-passau.de>
4464 * graphite.c (scopdet_basic_block_info): Fix loops with multiple
4465 exits and conditions.
4466 * testsuite/gcc.dg/graphite/pr37943.c: New.
4468 2008-10-23 Tobias Grosser <grosser@fim.uni-passau.de>
4471 * graphite.c (gloog): Replace EXIT_BLOCK_PTR with scop exit.
4473 2008-10-23 Tobias Grosser <grosser@fim.uni-passau.de>
4475 * doc/invoke.texi: Fix spaces.
4477 2008-10-22 Sebastian Pop <sebastian.pop@amd.com>
4479 PR tree-optimization/37891
4480 Reverted last commit.
4481 * graphite.c (create_single_entry_edge): Set
4482 EDGE_IRREDUCIBLE_LOOP and BB_IRREDUCIBLE_LOOP.
4484 2008-10-21 Sebastian Pop <sebastian.pop@amd.com>
4485 Mitul Thakkar <mitul.thakkar@amd.com>
4487 * graphite.c (create_single_entry_edge): Set
4488 EDGE_IRREDUCIBLE_LOOP and BB_IRREDUCIBLE_LOOP.
4490 2008-10-16 Tobias Grosser <grosser@fim.uni-passau.de>
4492 * doc/invoke.texi: Add -fgraphite-identity.
4493 * graphite.c (graphite_apply_transformations): Check for
4494 -fgraphite-identity.
4495 * toplev.c (process_options): Add flag_graphite_identity.
4496 * tree-ssa-loop.c: Add flag_graphite_identity.
4498 2008-10-14 Sebastian Pop <sebastian.pop@amd.com>
4500 Undo changes from 2008-10-02:
4501 * tree-ssa-loop-ivopts.c (rewrite_use_nonlinear_expr): Convert
4502 operand type when copying the operand to a variable of different type.
4503 * cfgloopmanip.c (create_empty_loop_on_edge): Write exit condition
4504 with the IV name after increment.
4506 2008-10-14 Sebastian Pop <sebastian.pop@amd.com>
4507 Harsha Jagasia <harsha.jagasia@amd.com>
4509 PR tree-optimization/37828
4510 * testsuite/gcc.dg/graphite/pr37828.c: New.
4511 * graphite.c (graphite_trans_loop_block): Do not loop block
4512 single nested loops.
4514 2008-10-09 Harsha Jagasia <harsha.jagasia@amd.com>
4515 Sebastian Pop <sebastian.pop@amd.com>
4517 * graphite.c (struct rename_map_elt, new_rename_map_elt,
4518 rename_map_elt_info, eq_rename_map_elts): New.
4519 (graphite_rename_ivs_stmt): Renamed graphite_rename_variables_in_stmt.
4520 (expand_scalar_variables_expr): Change parameters.
4521 (expand_scalar_variables_stmt): Same.
4522 (expand_scalar_variables): Same.
4523 (graphite_rename_ivs): Rename graphite_rename_variables.
4524 (build_iv_mapping): New.
4525 (translate_clast): Call build_iv_mapping.
4526 * graphite.h (gbb_p): New name.
4528 2008-10-03 Harsha Jagasia <harsha.jagasia@amd.com>
4530 PR tree-optimization/37684
4531 * gcc.dg/graphite/pr37684.c: New.
4532 * graphite.c (exclude_component_ref): New.
4533 (is_simple_operand): Call exclude_component_ref.
4535 2008-10-02 Jan Sjodin <jan.sjodin@amd.com>
4536 Harsha Jagasia <harsha.jagasia@amd.com>
4538 PR tree-optimization/37485
4539 * gcc.dg/graphite/block-2.c: New
4540 * graphite.c (gmp_cst_to_tree): Moved.
4541 (iv_stack_entry_is_constant): New.
4542 (iv_stack_entry_is_iv): New.
4543 (loop_iv_stack_push): Renamed to loop_iv_stack_push_iv.
4544 (loop_iv_stack_insert_constant): New.
4545 (loop_iv_stack_pop): Use new datatpype.
4546 (loop_iv_stack_get_iv): Same.
4547 (loop_iv_stack_get_iv_from_name): Same.
4548 (loop_iv_stack_debug): Renamed to debug_loop_iv_stack.
4549 (loop_iv_stack_patch_for_consts): New.
4550 (loop_iv_stack_remove_constants): New.
4551 (graphite_create_new_loop): Use loop_iv_stack_push_iv.
4552 (translate_clast): Call loop_iv_stack_patch_for_consts and
4553 loop_iv_stack_remove_constants.
4554 (gloog): Use new datatype. Redirect construction edge to end
4555 block to avoid accidental deletion.
4556 * graphite.h (enum iv_stack_entry_kind): New. Tag for data in
4558 (union iv_stack_entry_data): New. Data in iv stack entry.
4559 (struct iv_stack_entry): New. Datatype for iv stack entries.
4561 2008-10-02 Sebastian Pop <sebastian.pop@amd.com>
4563 * tree-ssa-loop-ivopts.c (rewrite_use_nonlinear_expr): Convert
4564 operand type when copying the operand to a variable of different type.
4566 2008-10-02 Sebastian Pop <sebastian.pop@amd.com>
4568 * cfgloopmanip.c (create_empty_loop_on_edge): Write exit condition
4569 with the IV name after increment.
4571 2008-10-02 Sebastian Pop <sebastian.pop@amd.com>
4573 * Merge from mainline (r140164:140838).
4575 2008-09-10 Konrad Trifunovic <konrad.trifunovic@inria.fr>
4577 * graphite-data-ref.c: New.
4578 * graphite.c (print_scop): Also dump the dependence graph.
4579 (bb_in_scop_p, loop_in_scop_p, nb_loops_around_gb): Moved...
4580 (new_scop): Initialize SCOP_DEP_GRAPH.
4581 (build_scop_dynamic_schedules): New.
4582 (build_access_matrix_with_af): Fixed column numbering.
4583 (graphite_transform_loops): Call build_scop_dynamic_schedules.
4584 * graphite.h: Add ifndef/define guards against multiple inclusion.
4585 (struct scop): Add dep_graph field.
4586 (SCOP_DEP_GRAPH): Defined.
4587 (ref_nb_loops): Fixed and moved to other position.
4588 (bb_in_scop_p, loop_in_scop_p, nb_loops_around_gb): ... here.
4589 (nb_loops_around_loop_in_scop): New.
4590 (graphite_dump_dependence_graph): Declared.
4591 (graphite_build_rdg_all_levels): Declared.
4592 (graphite_test_dependence): Declared.
4593 * Makefile.in (graphite-data-ref.o): New target.
4595 2008-09-09 Sebastian Pop <sebastian.pop@amd.com>
4597 * Merge from mainline (139870:140164).
4599 2008-09-01 Sebastian Pop <sebastian.pop@amd.com>
4601 * Merge from mainline (138275:139870).
4602 * testsuite/gcc.dg/graphite/scop-matmult.c: XFailed as one of
4603 the commits from trunk broke the niter detection.
4605 2008-09-01 Sebastian Pop <sebastian.pop@amd.com>
4607 * graphite.c: Add more documentation. Fix formatting.
4608 (debug_loop_vec, debug_oldivs, loop_iv_stack,
4609 loop_iv_stack_debug): Moved...
4610 (schedule_to_scattering): Move before use.
4611 (dot_all_scops): Include in "#if 0" the code for system
4614 * graphite.h: (debug_loop_vec, debug_oldivs, loop_iv_stack,
4615 loop_iv_stack_debug): ...here.
4617 2008-08-29 Jan Sjodin <jan.sjodin@amd.com>
4619 * tree-phinodes.c (make_phi_node): Extern.
4620 (add_phi_node_to_bb): New.
4621 (create_phi_node): Call add_phi_node_to_bb.
4622 * tree-ssa-loop-ivopts.c (get_phi_with_result): New.
4623 (remove_statement): Handle case where stored phi was updated
4624 and is no longer the same.
4625 * graphite.c (is_parameter): New.
4627 (expand_scalar_variables_expr): New.
4628 (expand_scalar_variables_stmt): New.
4629 (expand_scalar_variables): New.
4630 (move_phi_nodes): Create new phi instead of moving old one.
4631 (translate_clast): Call expand_scalar_variables.
4632 (find_vdef_for_var_in_bb): Also scan regular definitions.
4633 (skip_phi_defs): New.
4634 (collect_scop_exit_phi_args): New.
4635 (patch_scop_exit_phi_args): New.
4636 (gloog): Patch phis after scop.
4637 * tree-flow.h: (add_phi_node_to_bb): Declared.
4638 (make_phi_node): Declared.
4640 2008-08-26 Sebastian Pop <sebastian.pop@amd.com>
4642 * graphite.c (end_scop): Split the entry of the scop when it
4643 is the header of the loop in which the scop is ending.
4644 (build_scops_1, limit_scops): Update uses of end_scop.
4646 2008-08-26 Sebastian Pop <sebastian.pop@amd.com>
4648 * graphite.c (dot_all_scops_1): Do not fail on uninitialized
4649 SCOP_ENTRY or SCOP_EXIT.
4651 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
4653 * graphite.c (get_construction_edge): Removed.
4654 (gloog): Construction edge is the scop entry edge.
4656 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
4658 * graphite.c (can_generate_for_scop): Removed.
4659 (gloog): Do not call it.
4661 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
4663 * graphite.c (new_scop): Entry of a scop is an edge.
4664 Initialize SESE region.
4665 (free_scop): Free SESE region.
4666 (build_scops_1, scopdet_bb_info): Work on edges, not on bbs.
4667 (split_difficult_bb): New, split from end_scop.
4668 (end_scop): Exit of a scop is an edge.
4669 (build_scop_bbs): Never check CDI_POST_DOMINATORS: this info is
4670 not automatically updated and thus is always wrong.
4671 * graphite.h (struct sese): New.
4674 (struct scop): New field for a SESE region. Remove entry, exit.
4675 (SCOP_ENTRY, SCOP_EXIT): Update definitions to match same
4676 semantics as before. Moved comment around.
4678 2008-08-25 Tobias Grosser <grosser@fim.uni-passau.de>
4679 Sebastian Pop <sebastian.pop@amd.com>
4681 * graphite.c (graphite_transform_loops): Always enable gloog
4682 and find_transform when ENABLE_CHECKING.
4684 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
4686 * graphite.c (graphite_transform_loops): Move pretty printer
4687 of SCOPs before doing any transform. Remove call to print_scops
4688 and dot_all_scops_1.
4690 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
4692 * graphite.c (dump_gbb_conditions): Don't try to print NULL pointers.
4693 (print_graphite_bb): Same.
4695 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
4697 * graphite.c (dot_all_scops_1): Cleanup.
4698 (move_scops): Fix comment.
4700 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
4702 * graphite.c (build_scop_bbs): Revert commit 139355:
4704 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4705 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
4707 * graphite.c (build_scop_bbs): Factor up code.
4709 2008-08-25 Tobias Grosser <grosser@fim.uni-passau.de>
4711 * graphite.c (gloog): Update dominator info.
4713 2008-08-25 Tobias Grosser <grosser@fim.uni-passau.de>
4715 * graphite.c (remove_cond_exprs): Do not fail on empty bbs.
4717 2008-08-24 Sebastian Pop <sebastian.pop@amd.com>
4719 * graphite.c (new_graphite_bb): Remove GBB_INDEX_TO_NUM_MAP
4721 (free_graphite_bb): Remove GBB_INDEX_TO_NUM_MAP free.
4722 (translate_clast): Correct formatting.
4723 * graphite.h (struct num_map): Removed.
4724 (struct graphite_bb): Remove num_map field.
4725 (GBB_INDEX_TO_NUM_MAP): Removed.
4727 2008-08-24 Sebastian Pop <sebastian.pop@amd.com>
4729 * graphite.c (build_access_matrix_with_af): Fix comments.
4730 (build_scop_data_accesses): Same.
4732 2008-08-24 Sebastian Pop <sebastian.pop@amd.com>
4734 * graphite.c (build_scop_data_accesses): Don't construct
4735 access matrices. Add a FIXME and an assert condition that
4736 should pass when the access matrices will be needed.
4738 2008-08-24 Sebastian Pop <sebastian.pop@amd.com>
4740 * tree-data-ref.c (stmt_simple_memref_p): Don't call
4742 * graphite.c (build_graphite_bb): Renamed new_graphite_bb.
4743 Moved close by free_graphite_bb.
4744 (free_graphite_bb): Call free_data_refs. Reset bb->aux.
4745 (new_scop): Move close by free_scop.
4746 (graphite_transform_loops): Avoid linear scan to reset bb->aux.
4748 2008-08-22 Jan Sjodin <jan.sjodin@amd.com>
4750 * cfgloopmanip.c (create_empty_if_region_on_edge): New.
4751 * graphite.c (clast_to_gcc_expression): Call gmp_cst_to_tree
4752 instead of recursive call.
4753 (graphite_translate_clast_equation): New.
4754 (graphite_create_guard_cond_expr): New.
4755 (graphite_create_new_guard): New.
4756 (get_stack_index_from_iv): Removed.
4757 (graphite_rename_ivs_stmt): Use gbb_loop_index.
4758 (get_true_edge_from_guard_bb): New.
4759 (translate_clast): Handle stmt_guard in clast.
4760 (get_construction_edge): Allow construction edge detection for
4761 a scope entry with multiple predecessors if one predecessor is
4762 the immediate dominator of scope entry.
4763 (can_generate_code_stmt): Enable code generation for clast_guard.
4764 (gloog): Use correct context loop. Removed check for post dominators.
4765 * cfgloop.h (create_empty_if_region_on_edge): Declared.
4767 2008-08-21 Sebastian Pop <sebastian.pop@amd.com>
4769 * graphite.c (remove_dead_loops): Document better which
4772 2008-08-21 Sebastian Pop <sebastian.pop@amd.com>
4774 * Makefile.in: Rename POLYLIBLIBS and POLYLIBINC to PPLLIBS
4776 (graphite.o): Also depends on pointer-set.h.
4778 2008-08-21 Sebastian Pop <sebastian.pop@amd.com>
4780 * graphite.c (scop_record_loop): Fix compile warning.
4782 2008-08-21 Harsha Jagasia <harsha.jagasia@amd.com>
4783 Sebastian Pop <sebastian.pop@amd.com>
4785 * graphite.c (scop_record_loop): DECL_NAME can be NULL.
4787 2008-08-21 Sebastian Pop <sebastian.pop@amd.com>
4789 * graphite.c (build_graphite_bb): Initialize bb->aux to
4790 point to the graphite_bb_p.
4791 (graphite_bb_from_bb): Renamed gbb_from_bb; returns the
4793 (add_bb_domains): Does not use the scop parameter.
4794 (graphite_transform_loops): Clean bb->aux at the end.
4796 2008-08-20 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
4797 Sebastian Pop <sebastian.pop@amd.com>
4799 * testsuite/lib/target-supports.exp
4800 (check_effective_target_fgraphite): New.
4802 * testsuite/gcc.dg/graphite/graphite.exp: Early exit when
4803 check_effective_target_fgraphite returns false.
4804 Set dg-do-what-default to compile.
4805 (scan-graphite-dump-times): Removed.
4806 * testsuite/gfortran.dg/graphite/graphite.exp: Same.
4808 * testsuite/gcc.dg/graphite/scop-0.c: Do not use "dg-do compile".
4809 Use scan-tree-dump-times instead of scan-graphite-dump-times.
4810 * testsuite/gcc.dg/graphite/scop-1.c: Same.
4811 * testsuite/gcc.dg/graphite/scop-2.c: Same.
4812 * testsuite/gcc.dg/graphite/scop-3.c: Same.
4813 * testsuite/gcc.dg/graphite/scop-4.c: Same.
4814 * testsuite/gcc.dg/graphite/scop-5.c: Same.
4815 * testsuite/gcc.dg/graphite/scop-6.c: Same.
4816 * testsuite/gcc.dg/graphite/scop-7.c: Same.
4817 * testsuite/gcc.dg/graphite/scop-8.c: Same.
4818 * testsuite/gcc.dg/graphite/scop-9.c: Same.
4819 * testsuite/gcc.dg/graphite/scop-10.c: Same.
4820 * testsuite/gcc.dg/graphite/scop-11.c: Same.
4821 * testsuite/gcc.dg/graphite/scop-12.c: Same.
4822 * testsuite/gcc.dg/graphite/scop-13.c: Same.
4823 * testsuite/gcc.dg/graphite/scop-matmult.c: Same.
4824 * testsuite/gcc.dg/graphite/scop-14.c: Same.
4825 * testsuite/gcc.dg/graphite/scop-15.c: Same.
4826 * testsuite/gcc.dg/graphite/block-0.c: Same.
4827 * testsuite/gcc.dg/graphite/scop-16.c: Same.
4828 * testsuite/gcc.dg/graphite/block-1.c: Same.
4829 * testsuite/gcc.dg/graphite/scop-17.c: Same.
4830 * testsuite/gcc.dg/graphite/scop-18.c: Same.
4831 * testsuite/gfortran.dg/graphite/block-1.f90: Same.
4832 * testsuite/gfortran.dg/graphite/scop-1.f: Same.
4833 * testsuite/gfortran.dg/graphite/block-2.f: Same.
4835 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4837 * graphite.c: Fix some XXX comments.
4838 (build_scop_dynamic_schedules): Removed.
4840 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4842 * graphite.h (scop_max_loop_depth): Moved...
4843 * graphite.c (scop_max_loop_depth): ...here.
4844 (remove_all_edges_1): New.
4845 (remove_all_edges): Factored code.
4846 (remove_cond_exprs): Check only the last statement for
4847 a GIMPLE_COND expression.
4849 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4851 * graphite.c (scan_tree_for_params): Early return when the
4852 expression is a chrec_dont_know. Handle case NEGATE_EXPR.
4853 (find_scop_parameters): Factor out code.
4854 (graphite_trans_bb_strip_mine): Remove dead code.
4856 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4858 * graphite.c (clast_to_gcc_expression, graphite_create_new_loop,
4859 graphite_trans_bb_move_loop): Factor asserts.
4860 (gloog): Perform sanity checks only for ENABLE_CHECKING.
4861 Do not call calculate_dominance_info and estimate_bb_frequencies.
4863 2008-08-20 Jan Sjodin <jan.sjodin@amd.com>
4865 * graphite.c (create_loops_mapping, free_loops_mapping,
4866 create_loops_mapping_num, debug_loop_mapping_1,
4867 debug_loop_mapping, graphite_loops_mapping_max_loop_num,
4868 get_loop_mapping_for_num, graphite_loops_mapping_add_child,
4869 graphite_loops_mapping_add_child_num,
4870 graphite_loops_mapping_insert_child,
4871 graphite_loops_mapping_parent, get_loop_mapped_depth_for_num,
4872 get_loop_mapped_depth, split_loop_mapped_depth_for_num,
4873 loop_mapped_depth_split_loop, swap_loop_mapped_depth_for_num,
4874 create_num_from_index, get_num_from_index,
4875 swap_loop_mapped_depth): Removed.
4876 (new_scop): Do not initialize SCOP_LOOPS_MAPPING.
4877 (free_scop): Do not call free_loops_mapping.
4878 (graphite_get_new_iv_stack_index_from_old_iv): Renamed
4879 get_stack_index_from_iv. Use GBB_LOOPS instead of calling
4880 get_loop_mapped_depth.
4881 (graphite_trans_bb_move_loop): Do not update the loop mapping.
4882 (graphite_trans_bb_strip_mine): Same.
4883 * graphite.h (graphite_loops_mapping, graphite_loop_node): Removed.
4884 (struct scop): Remove field loops_mapping.
4886 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4887 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
4889 * graphite.c (scop_record_loop): Factor out one level of the
4890 condition by early return.
4891 (build_scop_loop_nests): Format following FSF coding style.
4892 (build_scop_dynamic_schedules): Factor out code.
4893 (scopdet_bb_info): Reindent. Default case should not be reachable.
4895 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4896 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
4898 * graphite.c (loop_affine_expr): Check for DECL_P or struct
4899 assignments that are not handled as simple operands for now.
4901 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4902 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
4904 * graphite.c (build_scop_bbs): Factor up code.
4906 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4907 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
4909 * graphite.c (stmt_simple_for_scop_p): Factor code out
4911 (enum gbb_type): New. Group all the GBB_* types under it.
4912 (is_loop_exit): Moved...
4913 (end_scop): Enable BB spliting.
4914 * cfgloop.c (is_loop_exit): ...here. Reimplemented.
4915 * cfgloop.h (is_loop_exit): Declared.
4917 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4919 * doc/invoke.texi: Remove strides from examples containing
4920 DO loops when the strides are equal to 1.
4922 2008-08-20 Harsha Jagasia <harsha.jagasia@amd.com>
4923 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
4925 * graphite.c (graphite_trans_scop_block): Or the result with
4926 the result from graphite_trans_loop_block.
4927 * testsuite/gcc.dg/graphite/block-1.c: New.
4928 * testsuite/gfortran.dg/graphite/block-1.f90: New.
4929 * testsuite/gfortran.dg/graphite/block-2.f: New.
4931 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4933 * graphite.c (graphite_transform_loops): Call cloog_initialize
4936 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4938 * tree-data-ref.c) (stmt_simple_memref_p): New.
4939 * tree-data-ref.h (stmt_simple_memref_p): Declared.
4940 * graphite.c (stmt_simple_memref_for_scop_p): Removed.
4941 (is_simple_operand): Call stmt_simple_memref_p.
4943 * testsuite/gcc.dg/graphite/scop-matmult.c: Updated for not
4944 using pointer arithmetic, as this is optimized by PRE and
4945 makes the code too difficult to analyze.
4947 * testsuite/gcc.dg/graphite/scop-18.c: Same.
4949 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4951 * gdbinit.in (pgg): New.
4953 2008-08-15 Tobias Grosser <grosser@fim.uni-passau.de>
4955 * graphite.c (graphite_trans_loop_block): Fix warning.
4957 2008-08-15 Tobias Grosser <grosser@fim.uni-passau.de>
4959 * graphite.c (graphite_trans_loop_block): Fix my merge error.
4961 2008-08-15 Tobias Grosser <grosser@fim.uni-passau.de>
4963 * graphite.c (graphite_trans_bb_block): Remove check for
4964 flag_loop_strip_mine, flag_loop_block, flag_loop_interchange.
4965 Check if loop blocking is profitable for every loop, before applying
4967 (graphite_apply_transformations): Call graphite_trans_bb_block only,
4968 if flag_loop_block is set.
4970 2008-08-14 Sebastian Pop <sebastian.pop@amd.com>
4972 * graphite.c: Add some more documentation for the loop
4975 2008-08-14 Sebastian Pop <sebastian.pop@amd.com>
4977 * Makefile.in (tree-data-ref.o): Remove dependence on graphite.h.
4978 * graphite.c: Format on less than 80 columns.
4981 2008-08-14 Sebastian Pop <sebastian.pop@amd.com>
4983 * cfgloopmanip.c (loopify): Use update_dominators_in_loop.
4985 2008-08-14 Sebastian Pop <sebastian.pop@amd.com>
4987 * doc/invoke.texi (floop-block, floop-strip-mine,
4988 floop-interchange): Update documentation with examples.
4990 2008-08-13 Sebastian Pop <sebastian.pop@amd.com>
4992 * cfgloopmanip.c (create_empty_loop_on_edge): Don't call
4994 * graphite.c (graphite_create_new_loop): Call add_referenced_var.
4996 2008-08-13 Sebastian Pop <sebastian.pop@amd.com>
4998 * cfgloopmanip.c (create_empty_loop_on_edge): Improve documentation.
4999 Factor gcc_asserts into a single one. Use force_gimple_operand_gsi.
5000 * tree-scalar-evolution.c: Revert useless changes.
5001 * tree-phinodes.c: Same.
5004 * tree-vectorizer.h: Same.
5005 * tree-flow.h: Same.
5007 * common.opt (fgraphite): Update documentation.
5009 2008-08-12 Harsha Jagasia <harsha.jagasia@amd.com>
5011 * doc/invoke.texi (-floop-block, -floop-strip-mine,
5012 -floop-interchange): Add more text for explaining what each of these
5014 * tree-into-ssa.c (gimple_vec): Moved to...
5015 * graphite.c: Include gimple.h.
5016 (gimple_vec): Moved to...
5017 (del_loop_to_cloog_loop): Removed.
5018 (loop_affine_expr): Do not call create_data_ref when the
5019 operand is a constant.
5020 (new_scop): Use free instead of del_loop_to_cloog_loop.
5021 * Makefile.in (graphite.o): Depend on GIMPLE_H.
5022 * gimple.h (gimple_vec): ... here.
5024 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5026 * graphite.c (scopdet_bb_info): Only allow loops with known number of
5028 (build_loop_iteration_domains): Fail, if latch executions unknown.
5030 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5032 * graphite.c (add_conditions_to_domain): New.
5033 (build_scop_conditions_1): Call add_conditions_to_domain.
5034 (set_cloog_options): Allow to disable optimizations.
5036 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5038 * graphite.c (find_params_in_bb): Look for parameters in conditions.
5039 Do not use walk_dominator_tree.
5040 (find_scop_parameters): Do not use walk_dominator_tree.
5042 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5044 * graphite.c (scan_tree_for_params) Add / Subtract inequality.
5045 (idx_record_params): Adapt.
5046 * graphite.h (scop_gimple_loop_depth): New.
5048 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5050 * graphite.c (build_scop_dynamic_schedules): Remove value_init.
5051 (scan_tree_for_params): Remove value_init.
5052 (build_scop_context): Remove value_init.
5053 (build_loop_iteration_domains): Remove value_init.
5054 (schedule_to_scattering): Remove value_init.
5055 (graphite_trans_bb_strip_mine): Remove value_init.
5057 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5059 * gcc/graphite.c (limit_scops): New.
5060 (graphite_transform_loops): Add limit SCoPs.
5061 * gcc/testsuite/gcc.dg/graphite/scop-0.c: Update number of SCoPs.
5062 * gcc/testsuite/gcc.dg/graphite/scop-1.c: Update number of SCoPs.
5063 * gcc/testsuite/gcc.dg/graphite/scop-10.c: Update number of SCoPs.
5064 * gcc/testsuite/gcc.dg/graphite/scop-11.c: Update number of SCoPs.
5065 * gcc/testsuite/gcc.dg/graphite/scop-12.c: Update number of SCoPs.
5066 * gcc/testsuite/gcc.dg/graphite/scop-13.c: Update number of SCoPs.
5067 * gcc/testsuite/gcc.dg/graphite/scop-14.c: Update number of SCoPs.
5068 * gcc/testsuite/gcc.dg/graphite/scop-15.c: Update number of SCoPs.
5069 * gcc/testsuite/gcc.dg/graphite/scop-16.c: Update number of SCoPs.
5070 Change loop numbers.
5071 * gcc/testsuite/gcc.dg/graphite/scop-17.c: Update number of SCoPs.
5072 Change loop numbers.
5073 * gcc/testsuite/gcc.dg/graphite/scop-18.c: Update number of SCoPs.
5074 * gcc/testsuite/gcc.dg/graphite/scop-2.c: Update number of SCoPs.
5075 * gcc/testsuite/gcc.dg/graphite/scop-3.c: Update number of SCoPs.
5076 * gcc/testsuite/gcc.dg/graphite/scop-4.c: Update number of SCoPs.
5077 * gcc/testsuite/gcc.dg/graphite/scop-5.c: Update number of SCoPs.
5078 * gcc/testsuite/gcc.dg/graphite/scop-6.c: Update number of SCoPs.
5079 * gcc/testsuite/gcc.dg/graphite/scop-7.c: Update number of SCoPs.
5080 * gcc/testsuite/gcc.dg/graphite/scop-8.c: Update number of SCoPs.
5081 * gcc/testsuite/gcc.dg/graphite/scop-9.c: Update number of SCoPs.
5082 * gcc/testsuite/gcc.dg/graphite/scop-matmult.c: Update number of SCoPs.
5084 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5086 * graphite.c (graphite_transform_loops): Call always find_transform.
5088 2008-08-08 Tobias Grosser <grosser@fim.uni-passau.de>
5090 * graphite.c (free_loops_mapping): New.
5091 (stmt_simple_for_scop_p): Fix typo.
5092 (stmt_simple_for_scop_p): Fix tuples functions, that
5094 (free_graphite_bb): Fix some memleaks.
5095 (free_scop): Fix some memleaks.
5096 (scopdet_bb_info): Do not forget some tmp SCoPs.
5097 (find_params_in_bb): Fix some memleaks.
5098 (clast_to_gcc_expression): Fix warning.
5100 2008-08-07 Tobias Grosser <grosser@fim.uni-passau.de>
5102 * testsuite/gcc.dg/graphite/scop-16.c: Fix for 32bit.
5103 * testsuite/gcc.dg/graphite/scop-17.c: Fix for 32bit.
5105 2008-08-04 Sebastian Pop <sebastian.pop@amd.com>
5107 * tree-ssa-loop.c (tree-ssa-loop.o): Do not include toplev.h.
5108 Move code ifdef-ed HAVE_cloog...
5109 * graphite.c: Include toplev.h.
5111 * Makefile.in (OBJS-common): Always build graphite.o.
5112 (BACKEND): Remove @GRAPHITE@.
5113 (tree-ssa-loop.o): Do not depend on TOPLEV_H.
5114 (graphite.o): Depend on TOPLEV_H.
5116 2008-08-04 Sebastian Pop <sebastian.pop@amd.com>
5118 * Makefile.in (tree-ssa-loop.o): Depend on TOPLEV_H.
5119 Remove typo left from polylib to ppl conversion.
5120 * graphite.c (graphite_transforms): Use sorry instead of fatal.
5122 2008-08-03 Sebastian Pop <sebastian.pop@amd.com>
5124 * toplev.c (process_options): Move the graphite loop optimization
5126 * tree-ssa-loop.c (graphite_transforms): ... here.
5127 When not configured with CLooG, print to dump_file that
5128 Graphite transforms were not performed.
5129 * testsuite/gcc.dg/graphite/graphite.exp (scan-graphite-dump-times):
5131 * testsuite/gcc.dg/graphite/*.c: Updated all testcases to use
5132 scan-graphite-dump-times.
5134 2008-08-03 Sebastian Pop <sebastian.pop@amd.com>
5136 * graphite.c (dot_scop, dot_all_scops): Do not call system.
5137 Do not open /tmp/scop.dot and /tmp/allscops.dot.
5139 2008-08-02 Sebastian Pop <sebastian.pop@amd.com>
5140 Jan Sjodin <jan.sjodin@amd.com>
5142 * configure: Regenerated.
5143 * omp-low.c (expand_omp_sections): Remove now unused code.
5144 * config.in (HAVE_polylib): Removed.
5145 * configure.ac (HAVE_polylib, POLYLIBLIBS, POLYLIBINC): Removed.
5146 (PPLLIBS, PPLINC): Added.
5147 * graphite.c: Replace unsigned with int wherever possible.
5148 Don't access Cloog's data structures, but use accessor functions.
5149 Clast's stmt->type is now implemented as a vtable: change the
5150 switches of stmt->type into ifs.
5151 (polylib/polylibgmp.h): Don't include.
5152 (initialize_dependence_polyhedron,
5153 initialize_data_dependence_polyhedron, is_empty_polyhedron,
5154 statement_precedes_p, test_dependence, build_rdg_all_levels,
5155 dump_dependence_graph): Removed until this code is cleaned up
5157 * Makefile.in (POLYLIBLIBS): Renamed PPLLIBS.
5158 (POLYLIBINC): Renamed PPLINC.
5160 2008-08-01 Harsha Jagasia <harsha.jagasia@amd.com>
5161 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
5162 Jan Sjodin <jan.sjodin@amd.com>
5164 Finish the merge and tuplification of graphite.
5166 2008-07-24 Sebastian Pop <sebastian.pop@amd.com>
5167 Jan Sjodin <jan.sjodin@amd.com>
5169 Partial merge from mainline (138072:138275).
5170 * graphite.c still has to be tuplified.
5172 2008-07-29 Jan Sjodin <jan.sjodin@amd.com>
5174 * graphite.c (graphite_loops_mapping_max_loop_num): New.
5175 (create_num_from_index): New.
5176 (get_num_from_index): Also pass in the graphite BB.
5177 (free_graphite_bb): Free GBB_INDEX_TO_NUM_MAP.
5178 (build_graphite_bb): Initialize GBB_INDEX_TO_NUM_MAP.
5179 (graphite_trans_bb_strip_mine): Call create_num_from_index.
5180 (is_interchange_valid): Return false when failing.
5181 * graphite.h (struct num_map): New.
5182 (struct graphite_bb): New field num_map.
5183 (GBB_LOOPS_MAPPING): Renamed GBB_INDEX_TO_NUM_MAP.
5185 2008-07-29 Tobias Grosser <grosser@fim.uni-passau.de>
5187 * graphite.c (dump_gbb_conditions): Print also conditions like
5188 "if (a)". Remove dublicated code and use print_generic_expr ().
5189 (stmt_simple_for_scop_p): Only allow conditions we can handle
5192 2008-07-25 Jan Sjodin <jan.sjodin@amd.com>
5194 * graphite.h (struct scop): Removed new_ivs field.
5195 (SCOP_NEWIVS): Deleted.
5196 * graphite.c (new_scop, free_scop, clast_name_to_gcc,
5197 clast_to_gcc_expression, graphite_create_new_loop):
5198 Removed use of new_ivs.
5200 2008-07-25 Jan Sjodin <jan.sjodin@amd.com>
5202 * graphite.c (debug_oldivs, debug_loop_vec, create_loops_mapping,
5203 create_loops_mapping_num, debug_loop_mapping_1): New.
5204 (debug_loop_mapping): Call debug_loop_mapping_1.
5205 (get_loop_mapping_for_num,
5206 graphite_loops_mapping_add_child,
5207 graphite_loops_mapping_add_child_num,
5208 graphite_loops_mapping_insert_child,
5209 graphite_loops_mapping_parent,
5210 split_loop_mapped_depth_for_num,
5211 loop_mapped_depth_split_loop): New.
5212 (increment_loop_mapped_depths): Removed.
5213 (swap_loop_mapped_depth_for_num): Reimplemented.
5214 (new_scop): Call create_loops_mapping.
5215 (scop_record_loop): Call graphite_loops_mapping_insert_child.
5216 (translate_clast): Pass the old loop father in parameter, and pass
5217 it to get_old_iv_from_ssa_name.
5218 (remove_edges_around_useless_blocks, can_generate_code_stmt,
5219 can_generate_code, can_generate_for_scop): New.
5220 (graphite_trans_bb_block): Returns false when it fails to transform.
5221 * graphite.h (graphite_loop_node, graphite_loops_mapping): New.
5223 2008-07-25 Sebastian Pop <sebastian.pop@amd.com>
5225 Reverted all the changes related to the streamization and
5227 These changes are now tracked in the streamization branch.
5229 2008-07-25 Sebastian Pop <sebastian.pop@amd.com>
5230 Jan Sjodin <jan.sjodin@amd.com>
5232 * graphite.c (gbb_compare): Correctly constify.
5233 (gbb_can_be_ignored): Indent.
5234 (graphite_trans_scop_swap_1and2): Add legality check.
5237 2008-07-25 Sebastian Pop <sebastian.pop@amd.com>
5239 Remove fallouts from "Reverted the Condate changes".
5240 * tree.h: Remove unused decl.
5241 * testsuite/gcc.dg/tree-checker: Same.
5242 * timevar.def: Remove counter.
5244 2008-07-24 Sebastian Pop <sebastian.pop@amd.com>
5246 * Merge from mainline (135673:138072).
5248 Reverted the MIRO changes (from 2008-04-05) that are now
5249 tracked in the miro branch.
5250 * tree-bounds.c: Removed.
5251 * tree-bounds.h: Removed.
5253 Reverted the Condate changes (from 2006-07-04, 2007-03-20) that
5254 are now tracked in the condate branch.
5255 * tree-check.c: Removed.
5256 * tree-match.c: Removed.
5257 * condate.y: Removed.
5259 2008-07-24 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
5261 * common.opt: New user flag -floop-block, -floop-strip-mine
5262 and -floop-interchange.
5263 * toplev.c (process_options): Enable -fgraphite pass if any one of the
5264 graphite loop optimization flags is turned on.
5265 * graphite.c (graphite_apply_transformations): Add flag_loop_block,
5266 flag_loop_strip_mine and flag_loop_interchange checks before
5268 * doc/invoke.texi: Remove -fgraphite and add -floop-block,
5269 -floop-strip-mine and -floop-interchange.
5270 * testsuite/gcc.dg/graphite/block-0.c: Add -floop-block and remove
5272 * testsuite/gcc.dg/graphite/scop-16.c: Ditto.
5273 * testsuite/gcc.dg/graphite/scop-17.c: Ditto.
5274 * testsuite/gcc.dg/graphite/scop-18.c: Ditto.
5276 2008-07-23 Jan Sjodin <jan.sjodin@amd.com>
5277 Sebastian Pop <sebastian.pop@amd.com>
5279 * cfgloopmanip.c (update_dominators_in_loop): Make it static.
5280 (create_empty_loop_on_edge): More fixes.
5281 * tree-phinodes.c (resize_phi_node): Extern.
5282 (unlink_phi_node, move_phi_node): New split from remove_phi_node.
5283 * cfghooks.c (update_dominator_information): New split from
5285 * tree-vectorizer.c (rename_variables_in_bb): Extern.
5286 * tree-dfa.c (collect_dfa_stats): Start walking the CFG on the
5287 successor of the function entry block.
5289 * graphite.c: Include pointer-set.h.
5290 (debug_loop_mapping, increment_loop_mapped_depths,
5291 get_loop_mapped_depth_for_num, get_loop_mapped_depth,
5292 set_loop_mapped_depth_for_num, set_loop_mapped_depth,
5293 swap_loop_mapped_depth_for_num, get_num_from_index,
5294 swap_loop_mapped_depth, loop_iv_stack_debug,
5295 loop_iv_stack_push, loop_iv_stack_pop, loop_iv_stack_get_iv,
5296 loop_iv_stack_get_iv_from_name, loop_iv_stack_debug,
5297 get_old_iv_from_ssa_name): New.
5298 (new_scop): Initialize SCOP_LOOPS_MAPPING.
5299 (free_scop): Free SCOP_LOOPS_MAPPING.
5300 (scop_record_loop): Record old ivs.
5301 (create_var_name): Removed.
5302 (initialize_cloog_names): Allocate double space in case strip mine
5303 applies to all loops once.
5304 (clast_name_to_gcc): Look up in the map ivstack passed in parameter.
5305 (clast_to_gcc_expression): Same. Implement more clast to gimple
5307 (graphite_create_new_loop): Pass in ivstack.
5308 (remove_all_edges): Pass in the construction_edge.
5309 (graphite_remove_iv): Removed.
5310 (graphite_rename_ivs, graphite_rename_ivs_stmt,
5311 remove_cond_exprs): Rewritten.
5312 (move_phi_nodes): New.
5313 (disconnect_virtual_phi_nodes, disconnect_cond_expr): Removed.
5314 (translate_clast): Pass in ivstack. Rewrite some cases.
5315 (set_cloog_options, debug_clast_stmt): New.
5316 (find_transform): Use set_cloog_options.
5317 (outermost_loop_layer): Removed.
5318 (get_construction_edge, collect_virtual_phis, find_vdef_for_var_in_bb,
5319 find_vdef_for_var_1, find_vdef_for_var, patch_phis_for_virtual_defs,
5320 mark_old_loops, remove_dead_loops): New.
5322 (graphite_trans_bb_move_loop): Call swap_loop_mapped_depth.
5323 (const_column_index, get_first_matching_sign_row_index,
5324 get_lower_bound_row, get_upper_bound_row, get_lower_bound,
5325 get_upper_bound): New.
5326 (graphite_trans_bb_strip_mine): Also update the iv map.
5328 * graphite.h (graphite_loops_mapping, GBB_LOOPS_MAPPING): New.
5329 (struct name_tree): Add a loop field.
5330 (struct scop): Add a graphite_loops_mapping field.
5331 (SCOP_LOOPS_MAPPING): New.
5332 (debug_clast_stmt): Declare.
5333 * lambda.h (find_induction_var_from_exit_cond): Declare.
5334 (lambda-code.c): (find_induction_var_from_exit_cond): Extern.
5335 * cfgloop.h (update_dominators_in_loop): Removed declaration.
5336 (create_empty_loop_on_edge): Updated.
5337 * tree-flow.h (remove_bb, resize_phi_node, move_phi_node,
5338 rename_variables_in_bb): Declare.
5339 * tree-cfg.c (remove_bb): Extern.
5341 * testsuite/gcc.dg/graphite/block-0.c: New.
5343 2008-07-21 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
5344 Sebastian Pop <sebastian.pop@amd.com>
5346 * graphite.c (strip_mine_profitable_p): New.
5347 (graphite_trans_bb_block): Disable strip mining if not profitable.
5349 * testsuite/gcc.dg/graphite/scop-18.c: New.
5350 * testsuite/gcc.dg/graphite/scop-17.c: Fixed.
5351 * testsuite/gcc.dg/graphite/scop-16.c: Fixed.
5353 2008-07-17 Harsha Jagasia <harsha.jagasia@amd.com>
5354 Jan Sjodin <jan.sjodin@amd.com>
5355 Sebastian Pop <sebastian.pop@amd.com>
5357 * graphite.c (is_interchange_valid): New.
5358 (graphite_trans_bb_block): Check loop nest of basic block for legality
5361 * graphite.h (gbb_inner_most_loop_index, outer_most_loop_1,
5362 outer_most_loop, gbb_outer_most_loop_index): New.
5364 * tree-loop-linear.c (perfect_loop_nest_depth): Remove static.
5365 * tree-flow.h (perfect_loop_nest_depth): Declare as extern.
5366 * testsuite/gcc.dg/graphite/scop-16.c: New.
5367 * testsuite/gcc.dg/graphite/scop-17.c: New.
5369 2008-07-11 Tobias Grosser <grosser@fim.uni-passau.de>
5371 * graphite.c (scop_remove_ignoreable_gbbs): Also update bitmap.
5372 (graphite_trans_scop_block): Ignore SCoPs without bbs.
5374 2008-07-11 Tobias Grosser <grosser@fim.uni-passau.de>
5376 * graphite.c (new_scop): Initialize SCOP_EXIT.
5377 (scopdet_info): Add.
5378 (scopdet_bb_info): Rename from is_bb_addable. Cleanup, bugfixes.
5379 (build_scops_1): Cleanup, bugfixes.
5380 (build_scops): Cleanup.
5382 * testsuite/gcc.dg/graphite/scop-matmult.c: Remove duplicated code.
5383 * testsuite/gcc.dg/graphite/scop-15.c: Add SCoP numbers.
5385 2008-07-10 Harsha Jagasia <harsha.jagasia@amd.com>
5387 * testsuite/gfortran.dg/graphite/scop-1.f: Update to reduced test case.
5389 * testsuite/gfortran.dg/graphite/graphite.exp: Use
5390 DEFAULT_GRAPHITE_FLAGS.
5392 * testsuite/gcc.dg/graphite/scop-15.c: Update to reduced test case.
5394 2008-07-10 Harsha Jagasia <harsha.jagasia@amd.com>
5396 * graphite.c (scan_tree_for_params): Do not assert any more if
5397 MULT_EXPR parameter is negative.
5399 * testsuite/gfortran.dg/graphite/scop-1.f: New.
5401 * testsuite/gfortran.dg/graphite/graphite.exp: New.
5403 * testsuite/gcc.dg/graphite/scop-15.c: New.
5405 2008-07-10 Harsha Jagasia <harsha.jagasia@amd.com>
5407 * graphite.c (is_bb_addable): Fix segfault in spec gzip and reformat.
5409 2008-07-10 Tobias Grosser <grosser@fim.uni-passau.de>
5411 * graphite.c (graphite_trans_bb_swap_loops): Rename from
5412 graphite_swap_loops.
5413 (graphite_trans_bb_move_loop): New.
5414 (graphite_trans_bb_strip_mine): Rename from graphite_strip_mine_loop.
5415 (graphite_trans_bb_block): New.
5416 (graphite_trans_loop_block): New.
5417 (graphite_trans_scop_swap_1and2): Rename from
5418 graphite_trans_swap_1and2.
5419 (graphite_trans_scop_strip): Rename from graphite_trans_strip.
5420 (graphite_trans_scop_block): New.
5421 (graphite_apply_transformations): Rename from
5422 graphite_transformations.
5424 * testsuite/gcc.dg/graphite/scop-matmult.c: New.
5426 2008-07-10 Tobias Grosser <grosser@fim.uni-passau.de>
5428 * graphite.c (gbb_compare): New.
5429 (graphite_sort_gbbs): New.
5430 (gbb_can_be_ignored): New.
5431 (scop_remove_ignoreable_gbbs): New.
5432 (graphite_transformations): Cleanup and add
5433 scop_remove_ignoreable_gbbs.
5434 * lambda.h (lambda_vector_compare): New.
5436 2008-07-09 Tobias Grosser <grosser@fim.uni-passau.de>
5438 * graphite.c (print_graphite_bb): Correct printing of static schedule.
5439 (graphite_swap_loops): int -> unsigned
5440 (graphite_strip_mine_loop): int -> unsigned, Fix SCHEDULE
5441 (graphite_transformations): New.
5442 (graphite_transform_loops): Move to graphite_transformations.
5443 * graphite.h (gbb_nb_loops): Return unsigned.
5445 2008-07-04 Tobias Grosser <grosser@fim.uni-passau.de>
5447 * graphite.c (scan_tree_for_params): Fix insertion of parameters into
5448 the domain matrix. This makes scop-0.c work again.
5450 2008-06-20 Richard Guenther <rguenther@suse.de>
5452 * graphite.h: Adjust copyright to GPLv3.
5453 * graphite.c: Likewise.
5454 (stmt_simple_memref_for_scop_p): Split out from ...
5455 (stmt_simple_for_scop_p): ... here. Fix handling of calls
5457 (get_bb_type): Optimize.
5459 (is_bb_addable): Fix memleak, replace is_pred call with
5461 (build_scops): Use current_loops.
5462 (param_index): Fix memleak.
5464 2008-06-20 Konrad Trifunovic <konrad.trifunovic@inria.fr>
5466 * graphite.c: Fix formatting.
5468 2008-06-19 Konrad Trifunovic <konrad.trifunovic@inria.fr>
5470 * graphite.c (new_scop): Memory allocation for SCOP_{NEWIVS, OLDIVS}.
5471 (free_scop): Memory deallocation for SCOP_NEWIVS, SCOP_OLDIVS.
5472 (create_var_name, save_var_name): Newly defined functions.
5473 (initialize_cloog_names): Part of the code factored out to
5475 (clast_to_gcc_expression): Now handles the case of clast_red_sum
5476 in clast_reduction statement.
5477 (graphite_create_new_loop): Now takes a new parameter
5479 (translate_clast): Now also takes the context_loop and bb_exit
5480 parameters. Rewritten the code so that it creates a gimple code
5481 inside the given context.
5482 (outermost_loop_layer, graphite_remove_iv, graphite_rename_ivs,
5483 remove_cond_expr, disconnect_cond_expr,
5484 disconnect_virtual_phi_nodes): Newly defined functions.
5485 * graphite.h (struct scop): added old_ivs vector.
5486 SCOP_OLDIVS: New macro.
5488 2008-06-19 Sebastian Pop <sebastian.pop@amd.com>
5490 * cfgloopmanip.c: Add missing function comments, fix formatting.
5492 2008-06-18 Konrad Trifunovic <konrad.trifunovic@inria.fr>
5494 * cfgloopmanip.c (update_dominators_in_loop): Defined.
5495 (create_empty_loop_on_edge): Defined.
5496 * tree-parloops.c (canonicalize_loop_ivs): Returns tree
5498 * cfgloop.h (create_empty_loop_on_edge): Declared as extern.
5499 (update_dominators_in_loop): Declared as extern
5500 * tree-flow.h (canonicalize_loop_ivs): Declared as extern.
5502 2008-06-16 Tobias Grosser <grosser@fim.uni-passau.de>
5504 * graphite.c (print_graphite_bb): Allow changing number of loops
5506 (initialize_cloog_names): Allow changing number of loops.
5507 (build_cloog_prog): Simplify.
5508 (find_transform): Enable cloog option --strides.
5509 (graphite_swap_loops): New.
5510 (graphite_strip_mine_loop): New.
5511 (graphite_trans_swap_1and2): New.
5512 (graphite_trans_strip): New.
5513 (graphite_transform_loops): Add graphite_trans_strip.
5514 * graphite.h (scop_max_loop_depth): New.
5516 2008-06-15 Tobias Grosser <grosser@fim.uni-passau.de>
5518 * graphite.c (build_scop_iteration_domain): Remove forgotten
5519 line. (Fixes compile)
5521 2008-06-15 Tobias Grosser <grosser@fim.uni-passau.de>
5523 * graphite.c (print_graphite_bb): Add output of GBB_LOOPS.
5524 (build_graphite_bb): Add GBB_LOOPS and GBB_DOMAIN and reorder.
5525 (build_bb_loops): New.
5526 (graphite_transform_loops): Add build_bb_loops.
5527 (schedule_to_scattering): Use gbb_nb_loops to support changing loop
5529 * graphite.h (graphite_bb): Add loops.
5530 (gbb_nb_loops): New.
5531 (gbb_loop_at_index): New.
5532 (gbb_loop_index): New.
5533 (nb_params_in_scop): Renamed to scop_nb_params. Updated all functions
5534 using nb_params_in_scop.
5536 2008-06-14 Tobias Grosser <grosser@fim.uni-passau.de>
5538 * graphite.c (print_graphite_bb): Adapt to minimized schedule.
5539 (build_scop_canonical_schedules): Build minimized schedule.
5540 (schedule_to_scattering): Adapt to minimized schedule.
5541 * graphite.h (graphite_bb): Add/Update descriptions.
5543 2008-06-14 Adrien Eliche <aeliche@isty.uvsq.fr>
5544 Tobias Grosser <grosser@fim.uni-passau.de>
5546 * graphite.c (print_graphite_bb): Add condition printing.
5548 (dump_gbb_conditions): New.
5549 (build_scop_conditions_1): New.
5550 (build_scop_conditions): New.
5551 * graphite.h (graphite_bb): Add conditions.
5553 2008-06-14 Tobias Grosser <grosser@fim.uni-passau.de>
5555 * graphite.c (print_graphite_bb):
5556 (free_graphite_bb): New.
5557 (free_scop): Free bbs.
5558 (get_bb_type): Free doms.
5559 (build_scop_context): Free context matrix.
5560 (build_loop_iteration_domains): Remove unused code.
5561 (build_cloog_prog): Free scattering function and blocklist.
5562 (find_transform): Free options.
5564 2008-06-13 Tobias Grosser <grosser@fim.uni-passau.de>
5566 * graphite.c (loop_body_to_cloog_stmts): Rename to add_bb_domains.
5567 Remove unnecessery cloog data structures. Make a copy of the domain
5568 (setup_cloog_loop): Rename to build_loop_iteration_domains. Remove
5569 unnecessary cloog data structures. Fix memory leaks. Remove insert
5570 into SCOP_LOOP2CLOOG_LOOP as the inserted CloogLoops will never be
5572 (build_scop_iteration_domain): Remove unnecessary cloog
5573 data structures. Fix memory leaks.
5574 (graphite_transform_loops): Disable build_scop_dynamic_schedules as it
5575 uses SCOP_LOOP2CLOOG_LOOP, that is at the moment not working.
5577 2008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
5579 * graphite.c (find_scop_params): Remove initialize_cloog_names.
5581 2008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
5583 * graphite.c (end_scop): Style fix.
5584 (schedule_to_scattering): Style and comment fix.
5586 2008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
5587 * graphite.c (print_graphite_bb): Fix definiton of
5588 schedule_to_scattering.
5589 (initialize_cloog_names): Change nb_scattdims to max loop
5591 (schedule_to_scattering): Take parameter for number of scattering
5593 (build_cloog_prog): Only build as much scattering dimensions as
5596 2008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
5598 * graphite.c (end_scop): Disable bb splitting. Fixes SIGSEGV
5599 in polyhedron/aermod.f90.
5601 2008-06-11 Tobias Grosser <grosser@fim.uni-passau.de>
5602 Dwarak Rajagopal <dwarak.rajagopal@amd.com>
5603 Harsha Jagasia <harsha.jagasia@amd.com>
5605 * graphite.c (is_bb_addable): Fix segfault.
5607 2008-06-10 Tobias Grosser <grosser@fim.uni-passau.de>
5609 * graphite.c (is_bb_addable): Fix memory leak, handling of loops
5610 with multiple exits and conditional handling in edge cases.
5611 (is_loop_exit): Fix memory leak. (Forgotten in last commit)
5613 * testsuite/gcc.dg/graphite/scop-14.c: New.
5615 2008-06-06 Tobias Grosser <grosser@fim.uni-passau.de>
5616 Adrien Eliche <aeliche@isty.uvsq.fr>
5618 * graphite.c (is_bb_addable): Add more comments and enhance
5619 readablity of the source code. Fix memory leak.
5620 (is_loop_exit): Fix memory leak.
5622 2008-06-05 Tobias Grosser <grosser@fim.uni-passau.de>
5624 * graphite.c (first_loop_in_scop): Deleted.
5625 (setup_cloog_loop): Only walk the loop chain for inner loops.
5626 (build_scop_iteration_domain): Execute setup_cloog_loop for
5627 all loops in the first layer.
5629 2008-06-05 Tobias Grosser <grosser@fim.uni-passau.de>
5631 * graphite.c (scan_tree_for_params): Change the way params are
5632 added to be indepenent of the number of loops.
5633 (setup_cloog_loop): Revert to short matrix format. Fix parameter
5635 (build_cloog_prog): Revert to short matrix format.
5637 2008-06-05 Sebastian Pop <sebastian.pop@amd.com>
5638 Dwarak Rajagopal <dwarak.rajagopal@amd.com>
5640 * tree-loop-fusion.c (fuse_loops): Fix uninitialized variable
5643 2008-06-05 Sebastian Pop <sebastian.pop@amd.com>
5645 * graphite.c (nb_data_refs_in_scop): New.
5646 (graphite_transform_loops): Print more stats: number of
5647 loops, basic blocks and data references per scop.
5649 2008-06-04 Sebastian Pop <sebastian.pop@amd.com>
5650 Jan Sjodin <jan.sjodin@amd.com>
5652 * graphite.c (loop_affine_expr, idx_record_params,
5653 find_scop_parameters, setup_cloog_loop): Use instantiate_scev
5654 instead of instantiate_parameters.
5656 2008-06-04 Tobias Grosser <grosser@fim.uni-passau.de>
5658 * graphite.c (schedule_to_scattering): Fix scattering dimensions,
5659 add support for parameters, add STATIC_SCHEDULE at the right places,
5662 2008-06-04 Tobias Grosser <grosser@fim.uni-passau.de>
5664 * graphite.c (build_scop_loop_nests): Only add the loops, that
5665 are contained completely in the SCoP.
5666 (build_cloog_prog): Disable scattering, until schedule_to_scattering
5667 and the domains are fixed.
5668 (build_scop_canonical_schedules): Add support for bbs not contained
5671 2008-06-04 Tobias Grosser <grosser@fim.uni-passau.de>
5673 * graphite.h (scop_contains_loop): Update comments to match
5674 the actual behavior.
5675 (scop_contains_loop): New.
5676 * graphite.c (schedule_to_scattering): Use scop_contains_loop.
5678 2008-06-04 Sebastian Pop <sebastian.pop@amd.com>
5680 * graphite.c (get_bb_type): On function body, i.e. loop_0,
5681 don't mark blocks as GBB_LOOP_SING_EXIT_HEADER, mark them
5684 2008-06-04 Sebastian Pop <sebastian.pop@amd.com>
5685 Tobias Grosser <grosser@fim.uni-passau.de>
5687 * graphite.c (graphite_transform_loops): Early return when
5688 there are no loops in the function.
5690 2008-05-31 Sebastian Pop <sebastian.pop@amd.com>
5691 Jan Sjodin <jan.sjodin@amd.com>
5693 * graphite.c (scan_tree_for_params, setup_cloog_loop): Compute the
5694 offset of the last loop.
5695 (setup_cloog_loop): Copy the entire outer constraint matrix.
5697 2008-05-31 Sebastian Pop <sebastian.pop@amd.com>
5698 Jan Sjodin <jan.sjodin@amd.com>
5700 * graphite.c (stmt_in_scop_p, function_parameter_p,
5701 invariant_in_scop_p): Removed.
5702 (scan_tree_for_params): Can be used with no constraint
5703 matrix for gathering parameters.
5704 (idx_record_params): Don't use idx_record_param, instead use
5705 scan_tree_for_params.
5706 (find_scop_parameters): Same.
5707 (setup_cloog_loop, build_scop_iteration_domain, build_cloog_prog):
5708 Fix the size of loop domains.
5709 (schedule_to_scattering): Exit when the outer loop is not in scop.
5710 (find_transform): Enable build_cloog_prog.
5712 2008-05-31 Sebastian Pop <sebastian.pop@amd.com>
5713 Jan Sjodin <jan.sjodin@amd.com>
5715 * graphite.c (schedule_to_scattering): Make scattering domains
5716 uniformly of the same size, as required by CLooG 0.14.0 and before.
5718 2008-05-31 Sebastian Pop <sebastian.pop@amd.com>
5719 Jan Sjodin <jan.sjodin@amd.com>
5721 * graphite.c (schedule_to_scattering): Rewrite, correct the
5722 translation of the scheduling function to scattering.
5723 (build_cloog_prog): Call schedule_to_scattering only once.
5724 * graphite.h (scop_loop_index): Do not fail for loops not
5725 in the scop: return -1.
5727 2008-05-30 Tobias Grosser <grosser@fim.uni-passau.de>
5729 * graphite.c (build_graphite_bb): Initialize GBB_DOMAIN.
5730 (loop_body_to_cloog_stmts): Export GBB_DOMAIN.
5731 (setup_cloog_loop): Export GBB_DOMAIN.
5732 (build_cloog_prog): New. Create new CLOOG_PROG, which should be
5733 able to rebuild the original control flow.
5734 * graphite.h (graphite_bb): Add domain field and access macro.
5737 2008-05-30 Sebastian Pop <sebastian.pop@amd.com>
5739 * graphite.c (debug_gbb): New.
5740 (print_scop, build_graphite_bb): Use SCOP_BBS.
5741 (build_scop_bbs): Reimplemented.
5742 (dfs_bb_in_scop_p): Removed.
5743 (build_scop_loop_nests): Reorder loops inserted in
5744 SCOP_LOOP_NEST: outer loops should come first.
5745 (build_scop_canonical_schedules): Reinitialize at zero
5746 the components of the SCOP_STATIC_SCHEDULE for the loops
5747 that have already been parsed.
5749 * graphite.h (debug_gbb): Declared.
5751 2008-05-30 Sebastian Pop <sebastian.pop@amd.com>
5752 Jan Sjodin <jan.sjodin@amd.com>
5754 * graphite.c (create_empty_loop): Renamed graphite_create_new_loop.
5755 (graphite_loop_to_gcc_loop): Removed.
5756 (remove_all_edges): New.
5757 (graphite_stmt_to_gcc_stmt): Renamed translate_clast.
5758 (gloog): Remove useless code.
5760 2008-05-29 Tobias Grosser <grosser@fim.uni-passau.de>
5762 * graphite.c (get_bb_type): Reworked. We distinguish between
5763 loops with one or multiple exits.
5764 (is_loop_exit): New.
5766 (is_bb_addable): Rework condition handling, now support for case
5767 case statements and loops with multiple exits.
5769 * testsuite/gcc.dg/graphite/scop-11.c: New.
5770 * testsuite/gcc.dg/graphite/scop-12.c: New.
5771 * testsuite/gcc.dg/graphite/scop-13.c: New.
5773 2008-05-29 Tobias Grosser <grosser@fim.uni-passau.de>
5775 * graphite.c (dot_all_scops_1): Fix some colors. Reuse colors, if
5776 we have too many colors.
5778 2008-05-22 Sandeep Maram <smaram_b04@iiita.ac.in>
5780 * doc/invoke.texi (-ftree-loop-fusion): Document.
5781 * tree-pass.h (pass_loop_fusion): Declared.
5782 * tree-loop-fusion.c: New.
5783 * timevar.def (TV_TREE_LOOP_FUSION): Declared.
5784 * tree-data-ref.c (find_data_references_in_loop): Make extern.
5785 * tree-data-ref.h (find_data_references_in_loop): Declared.
5786 * common.opt (ftree-loop-fusion): Declared.
5787 * Makefile.in (tree-loop-fusion.o): Added rule and to OBJS-common.
5789 2008-05-21 Sebastian Pop <sebastian.pop@amd.com>
5791 * graphite.c (build_access_matrix): Fix typo from the merge.
5793 2008-05-20 Sebastian Pop <sebastian.pop@amd.com>
5795 * Merge from mainline (130800:135673).
5797 2008-05-07 Sebastian Pop <sebastian.pop@amd.com>
5799 * graphite.c (end_scop): The exit of the scop is not part of the scop.
5800 Update dominators after splitting.
5802 2008-05-07 Sebastian Pop <sebastian.pop@amd.com>
5804 * graphite.c (is_bb_addable): Return the harmful statement.
5805 Factor up some code.
5806 (end_scop): New. Splits end of scope bbs on a harmful statement.
5807 (build_scops_1): Call end_scop.
5809 2008-05-07 Sebastian Pop <sebastian.pop@amd.com>
5811 * graphite.c: (succs_at_same_depth, end_scop, all_preds_visited_p,
5812 all_succs_visited_p, start_new_scop_for_each_succ, start_new_scop,
5813 add_dominators_to_open_scops, stop_last_open_scop, scop_end_loop,
5814 build_scops_1): Removed.
5815 (build_scops_2): Renamed build_scops_1.
5817 2008-05-06 Sebastian Pop <sebastian.pop@amd.com>
5819 * graphite.c: Fix formatting.
5821 2008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
5823 * graphite.c (get_bb_type): New.
5825 (build_scops_2): New.
5826 (is_bb_addable): New.
5827 (build_scops): Switch the scop detection.
5828 (build_scop_bbs): Add entry bb to scop.
5829 * graphite.h (struct scop): Update comment.
5831 2008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
5833 * graphite.c (dot_all_scops_1): Fix some incorrect colors and add
5836 2008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
5838 * testsuite/gcc.dg/graphite/scop-1.c: Update.
5839 * testsuite/gcc.dg/graphite/scop-2.c: Update.
5840 * testsuite/gcc.dg/graphite/scop-4.c: Update.
5841 * testsuite/gcc.dg/graphite/scop-5.c: Add.
5842 * testsuite/gcc.dg/graphite/scop-6.c: Add.
5844 2008-05-06 Sebastian Pop <sebastian.pop@amd.com>
5846 * testsuite/gcc.dg/graphite/scop-0.c: Add.
5847 * testsuite/gcc.dg/graphite/scop-7.c: Add.
5848 * testsuite/gcc.dg/graphite/scop-8.c: Add.
5849 * testsuite/gcc.dg/graphite/scop-9.c: Add.
5850 * testsuite/gcc.dg/graphite/scop-10.c: Add.
5852 2008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
5854 * graphite.c (scop_affine_expr): Renamed to loop_affine_expr.
5855 Check affine expressions depending on the outermost loop
5857 (stmt_simple_for_scop_p): Same.
5858 (harmfule_stmt_in_scop): Same.
5860 2008-04-28 Tobias Grosser <grosser@fim.uni-passau.de>
5862 * graphite.c (dot_all_scops): Remove incorrect difficult bb coloring,
5863 mark entry and exit, that are not part of the SCoP and update HTML
5866 2008-04-25 Sebastian Pop <sebastian.pop@amd.com>
5868 * graphite.c (basic_block_simple_for_scop_p): Renamed
5870 (save_scop, preds_at_same_depth, test_for_scop_bound): Removed.
5871 (add_dominators_to_open_scops, build_scops_1): Reimplemented.
5872 (all_preds_visited_p, all_succs_visited_p,
5873 start_new_scop_for_each_succ, start_new_scop, stop_last_open_scop,
5874 scop_end_loop): New.
5875 (build_scops): Do not use dfs_enumerate_from.
5877 * testsuite/gcc.dg/graphite/scop-{1,2,4}.c: Updated.
5879 2008-04-23 Sebastian Pop <sebastian.pop@amd.com>
5881 * graphite.c: Add comments to functions that are missing a
5883 (graphite_create_iv): Removed. Merged in graphite_loop_to_gcc_loop.
5885 2008-04-23 Sebastian Pop <sebastian.pop@amd.com>
5887 * graphite.c (nb_params_in_scop): Moved...
5888 (graphite_bb_from_bb, loop_body_to_cloog_stmts): New.
5889 (setup_cloog_loop): Call loop_body_to_cloog_stmts.
5890 (clast_to_gcc_expression): Reduce column size to less than 80.
5891 (graphite_create_iv): Return the new name of the IV.
5892 (find_transform): Set options->esp and options->cpp.
5893 (gloog): Comment out the invalidation of the old loop code.
5894 (initialize_dependence_polyhedron): Replace scop_nb_params with
5897 * graphite.h (nb_params_in_scop): ... here.
5898 (scop_nb_params): Removed.
5899 (loop_domain_dim): Return something even when the loop was not
5900 found in the hash table: avoid ICEing on all the graphite.exp
5903 2008-04-14 Konrad Trifunovic <konrad.trifunovic@inria.fr>
5905 * tree-chrec.c (for_each_scev_op): SCEV can have 3 operands.
5907 * graphite.c (build_scop_dynamic_schedules): Schedule is built
5908 according to nesting level.
5909 (find_scop_parameters): Call instantiate_parameters.
5910 (scan_tree_for_params): Extend it to handle general affine bounds.
5911 Inner loop bound can depend on outer loop induction variable.
5912 (setup_cloog_loop): tmp variable is allocated on stack. Call
5913 instantiate_parameters with respect to outermost_loop_in_scop.
5914 (loop_domain_dim, ref_nb_loops, loop_iteration_vector_dim): moved to
5916 (create_empty_loop): Function loopify should be given edge
5917 probability, instead of edge frequency. Dominance relation from
5918 switch_bb to loop_header.
5919 (clast_to_gcc_expression): Added handling of clast_reduction node.
5920 (gloog): New functionality for removing old loop.
5921 (test_dependence): Factored out from build_rdg_all_levels.
5922 (build_rdg_all_levels): Dependence testing factored out to
5923 test_dependence function.
5925 * graphite.h (struct graphite_bb): Extended with dynamic_schedule.
5926 (loop_domain_dim, ref_nb_loops, loop_iteration_vector_dim): Moved
5929 2008-04-07 Sebastian Pop <sebastian.pop@amd.com>
5931 * graphite.c (free_scop, param_index, initialize_cloog_names,
5932 nb_params_in_scop): Use name_tree map instead of just a tree
5933 for keeping track of the variable name associated to that tree.
5934 (create_empty_loop, gmp_cst_to_tree, clast_name_to_gcc,
5935 clast_to_gcc_expression, graphite_create_iv,
5936 graphite_loop_to_gcc_loop, graphite_cond_to_gcc_cond,
5937 graphite_stmt_to_gcc_stmt): New.
5938 (gloog): Call these.
5939 * graphite.h (struct name_tree): New.
5940 (struct scop): Use name_tree instead of tree for params.
5941 Store a vector of name_tree for new_ivs.
5943 (scop_nb_params): Use name_tree instead of tree.
5945 2008-04-05 Alexander Lamaison <awl03@doc.ic.ac.uk>
5946 Sebastian Pop <sebastian.pop@amd.com>
5948 * tree-bounds.c: New.
5949 * tree-bounds.h: New.
5950 * tree-pass.h: Declare pass_bounds_early and pass_bounds_late.
5951 * passes.c: Schedule pass_bounds_early, pass_bounds_late.
5952 * builtins.c (expand_builtin_alloca): Add flag_bounds as for
5956 * c-cppbuiltin.c: Same.
5960 * tree-outof-ssa.c: Same.
5962 * Makefile.in: Same.
5964 2008-03-15 Antoniu Pop <antoniu.pop@gmail.com>
5965 Sebastian Pop <sebastian.pop@amd.com>
5967 * tree-loop-distribution.c (remaining_stmts,
5968 upstream_mem_writes): Removed static variables.
5969 (copy_loop_before, create_bb_after_loop,
5970 mark_nodes_having_upstream_mem_writes, free_rdg_components,
5971 rdg_build_components, rdg_build_partitions,
5972 dump_rdg_partitions): Extern.
5973 (generate_loops_for_partition, generate_code_for_partition): Do not
5975 (already_processed_vertex_p, predecessor_has_mem_write,
5976 mark_nodes_having_upstream_mem_writes, has_upstream_mem_writes,
5977 rdg_flag_all_uses, rdg_flag_uses, rdg_flag_vertex_and_dependent,
5978 rdg_flag_loop_exits, rdg_flag_similar_memory_accesses,
5979 build_rdg_partition_for_component, rdg_build_partitions, ldist_gen):
5980 Pass remaining_stmts and upstream_mem_writes as parameters.
5981 (rdg_component): Moved...
5982 (build_rdg_partition_for_component): Do not aggregate components when
5983 flag_streamize_loops is set.
5984 (gen_sequential_loops): New.
5985 (ldist_gen): Call gen_sequential_loops.
5987 * tree-pass.h (pass_loop_streamization): Declared.
5989 * omp-low.c (expand_omp_sections): Call add_bb_to_loop on created
5990 basic blocks when loops structures exist.
5992 * builtin-types.def (BT_FN_VOID_PTR_PTR_INT): New.
5994 * tree-ssa-loop-ivopts.c (expr_invariant_in_region_p): New.
5996 * tree-parloops.c (take_address_of, eliminate_local_variables_1,
5997 eliminate_local_variables_stmt, eliminate_local_variables,
5998 separate_decls_in_loop_name, separate_decls_in_loop_stmt,
5999 separate_decls_in_loop, gen_parallel_loop): Make them work on a region
6000 of code delimited by two edges in the CFG.
6001 (separate_decls_in_loop_name): Renamed separate_decls_in_region_name.
6002 (separate_decls_in_loop_stmt): Renamed separate_decls_in_region_stmt.
6003 (separate_decls_in_loop): Renamed separate_decls_in_region. Isolate
6004 the case of parallelisation of reductions.
6005 (create_loop_fn): Extern.
6006 (create_omp_parallel_region): New.
6008 * tree-data-ref.c (dump_data_dependence_relation): Don't call
6009 dump_data_reference for printing dra and drb.
6010 (create_rdg_edge_for_ddr, create_rdg_edges_for_scalar): Initialise
6012 (build_rdg): Don't call free_dependence_relations for the moment, as
6013 we attach dependence relations on each edge of the RDG.
6016 * tree-data-ref.h (rdg_component): ...here.
6017 (struct rdg_edge): New field ddr_p relation.
6018 (RDGE_RELATION): New.
6019 (create_bb_after_loop, copy_loop_before,
6020 mark_nodes_having_upstream_mem_writes, rdg_build_components,
6021 rdg_build_partitions, dump_rdg_partitions,
6022 free_rdg_components): Declared.
6024 * omp-builtins.def (BUILT_IN_GOMP_STREAM_ALIGN_PUSH,
6025 BUILT_IN_GOMP_STREAM_ALIGN_POP): New.
6027 * tree-loop-streamization.c: New.
6029 * tree-flow.h (gather_blocks_in_sese_region, create_loop_fn,
6030 create_omp_parallel_region, expr_invariant_in_region_p): Declared.
6032 * Makefile.in (tree-loop-streamization.o): Added to OBJS-common.
6034 * tree-cfg.c (gather_blocks_in_sese_region): Extern.
6036 * passes.c: Schedule pass_loop_streamization.
6038 2008-03-08 Tobias Grosser <grosser@fmi.uni-passau.de>
6040 * graphite.c (dot_all_scops_1): Fix formatting for difficult bbs and
6043 2008-03-07 Tobias Grosser <grosser@fim.uni-passau.de>
6045 * graphite.c (dot_all_scops): Update formatting.
6046 Bbs can now be part of more than one SCoP.
6048 2008-03-04 Sebastian Pop <sebastian.pop@amd.com>
6050 * graphite.c (new_loop_to_cloog_loop_str, setup_cloog_loop): Fix
6052 (loop_domain_dim): Check for unregistered toplev SCOP loop.
6053 * graphite.h (loop_to_cloog_loop): New.
6055 2008-03-04 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6057 * graphite.c (loop_domain_dim, ref_nb_loops,
6058 loop_iteration_vector_dim): New.
6059 (build_access_matrix_with_af, build_access_matrix,
6060 initialize_dependence_polyhedron): Fixed for new matrix layout.
6061 No longer assume that all iteration domains are of the same
6064 2008-03-02 Sebastian Pop <sebastian.pop@amd.com>
6066 * tree-scalar-evolution.c (instantiate_parameters_1): An SSA_NAME
6067 defined in a loop at depth 0 is invariant.
6068 * tree-chrec.c (evolution_function_is_invariant_rec_p): Ditto.
6069 * tree-ssa-loop-ivopts.c (expr_invariant_in_loop_p): Should never
6070 be called at loop depth 0.
6072 * graphite.c (basic_block_simple_for_scop_p): Take the scop as
6074 (dot_all_scops_1): Update use of basic_block_simple_for_scop_p.
6075 (down_open_scop): Removed.
6076 (loop_in_scop_p): Redefined.
6077 (scop_affine_expr): New argument: scop.
6078 (stmt_simple_for_scop_p): New argument: scop. RETURN_EXPR is not
6079 a harmful statement ending a scop.
6080 (basic_block_simple_for_scop_p): New argument: scop.
6081 (get_loop_start): Removed.
6082 (new_scop): Initialize SCOP_LOOPS.
6083 (free_scop): Free SCOP_LOOPS.
6084 (succs_at_same_depth, preds_at_same_depth): New.
6085 (end_scop): Test the validity of a scop.
6086 (add_dominators_to_open_scops): New.
6087 (test_for_scop_bound): Call add_dominators_to_open_scops.
6088 Add cases for opening and closing multiple scops.
6089 (build_scops, build_scop_bbs): Iterate over basic blocks in
6091 (build_graphite_bb): Pass scop directly.
6092 (dfs_bb_in_scop_p): New.
6093 (scop_record_loop): Use SCOP_LOOPS for not recording the same loop
6095 (nb_loops_around_gb): Use loop_in_scop_p.
6096 (schedule_to_scattering): Disabled for the moment the code computing
6097 the "textual order for outer loop".
6099 * graphite.h (struct scop): New field loops.
6101 (scop_loop_index): Test that the given loop belongs to SCOP_LOOPS.
6103 * testsuite/gcc.dg/graphite/scop-{1,...,7}.c: Updated.
6105 2008-02-27 Antoniu Pop <antoniu.pop@gmail.com>
6106 Sebastian Pop <sebastian.pop@amd.com>
6108 * builtin-types.def (BT_FN_PTR_SIZE_UINT, BT_FN_BOOL_PTR): New.
6109 * common.opt (fstreamize-loops): New.
6110 * omp-builtins.def (BUILT_IN_GOMP_STREAM_CREATE,
6111 BUILT_IN_GOMP_STREAM_PUSH, BUILT_IN_GOMP_STREAM_HEAD,
6112 BUILT_IN_GOMP_STREAM_POP, BUILT_IN_GOMP_STREAM_EOS_P,
6113 BUILT_IN_GOMP_STREAM_SET_EOS, BUILT_IN_GOMP_STREAM_DESTROY): New.
6115 2008-02-22 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6117 * tree-data-ref.c (build_empty_rdg): New.
6118 (build_rdg): Use it.
6119 * tree-data-ref.h (build_empty_rdg): Declared.
6120 * graphite.c (free_scop): Free SCOP_LOOP2CLOOG_LOOP.
6121 (find_vertex_for_stmt): Removed.
6122 (build_rdg_all_levels): Use build_empty_rdg and rdg_vertex_for_stmt.
6124 2008-02-21 Sebastian Pop <sebastian.pop@amd.com>
6126 * tree-loop-distribution.c (generate_builtin): After cancelling the
6127 loop tree, also delete basic blocks.
6128 (rdg_flag_uses): Stop recursion when a vertex has already been
6131 2008-02-15 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6133 * graphite.c (build_scop_alpha): Removed.
6134 (graphite_transform_loops): Add a dummy call to build_all_rdg_levels
6135 and dump_dependence_graph to avoid compiler warnings.
6137 2008-02-14 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6139 * tree-data-ref.c (dr_may_alias_p, create_rdg_vertices): Extern.
6140 * tree-data-ref.h (dr_may_alias_p, create_rdg_vertices): Declared.
6141 * graphite.c (new_loop_to_cloog_loop_str, hash_loop_to_cloog_loop,
6142 eq_loop_to_cloog_loop, del_loop_to_cloog_loop): New.
6143 (new_scop, setup_cloog_loop): Initialize SCOP_LOOP2CLOOG_LOOP.
6144 (initialize_dependence_polyhedron, find_vertex_for_stmt,
6145 initialize_data_dependence_polyhedron, is_empty_polyhedron,
6146 statement_precedes_p, build_rdg_all_levels, build_scop_alpha,
6147 dump_dependence_graph): New.
6148 * graphite.h (struct graphite_bb): New field compressed_alpha_matrix.
6150 (struct scop): New field loop2cloog_loop.
6151 (SCOP_LOOP2CLOOG_LOOP, struct data_dependence_polyhedron,
6152 RDGE_DDP, ddp_p, struct loop_to_cloog_loop_str): New.
6154 2008-02-10 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6156 * graphite.c (build_graphite_bb): Fix initialization
6157 of the graphite basic block.
6159 2008-02-05 Sebastian Pop <sebastian.pop@amd.com>
6161 * graphite.c (scan_tree_for_params): Rewrite for the new layout of
6162 loop domain matrix. Pass in the number of loops contained in the
6164 (nb_loops_around_gb): Moved before setup_cloog_loop that uses it.
6165 (setup_cloog_loop): Rewrite for the new layout of loop domain matrix:
6166 loops that are not surrounding the current loop are not represented
6167 in the domain constraint matrix.
6168 (build_scop_iteration_domain): Initial domain constraint matrix
6169 contains only the eq/ineq, cst, and scop parameters columns.
6171 2008-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
6173 * graphite.c (schedule_to_scattering, nb_loops_around_gb): New.
6174 (print_graphite_bb): Print scattering.
6176 2008-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
6178 * graphite.c (initialize_cloog_names): Initialize names of
6179 scattering variables.
6181 2009-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
6183 * graphite.c (dot_all_scops_1): Disable debug output while
6186 2008-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
6188 * graphite.c (find_transform): Change cloog output language to C.
6190 2008-01-27 Sebastian Pop <sebastian.pop@amd.com>
6192 * tree-loop-distribution.c (generate_memset_zero,
6193 generate_builtin, generate_code_for_partition,
6194 rdg_flag_all_uses): New.
6195 (rdg_flag_uses): Gather in the same partition the statements defining
6196 the VUSES of the current statement.
6197 (rdg_flag_similar_stores): Renamed rdg_flag_similar_memory_accesses.
6198 Gather in the same partition not only the stores to the same memory
6199 access, but also the reads.
6200 (ldist_generate_loops): Renamed ldist_gen.
6202 2008-01-24 Sebastian Pop <sebastian.pop@amd.com>
6203 Tobias Grosser <grosser@fmi.uni-passau.de>
6205 * graphite.c (setup_cloog_loop): Chain all cloog loops with the
6206 next pointer, don't use the inner pointer.
6208 2008-01-20 Tobias Grosser <grosser@fmi.uni-passau.de>
6210 * graphite.c (dot_all_scops, dot_all_scops_1): New.
6211 (find_transform): Call dot_all_1.
6212 * graphite.h (dot_all_scops): Declared.
6214 2007-12-14 Sebastian Pop <sebastian.pop@amd.com>
6216 * tree-loop-distribution.c: Fix apsi.f ICE.
6217 (create_bb_after_loop): New.
6218 (generate_loops_for_partition): Use it.
6219 * testsuite/gfortran.dg/ldist-1.f90: New.
6221 * tree-data-ref.c (dot_rdg): Use /tmp/rdg.dot for dotty format.
6222 * graphite.c (dot_scop): Use /tmp/scop.dot for dotty format.
6224 2007-12-13 Tobias Grosser <grosser@fmi.uni-passau.de>
6226 * graphite.c (find_transform): Dump cloog program sent to cloog.
6228 2007-12-13 Tobias Grosser <grosser@fmi.uni-passau.de>
6230 * graphite.c (initialize_cloog_names): Initialize cloog
6233 2007-12-13 Tobias Grosser <grosser@fmi.uni-passau.de>
6235 * graphite.c (build_scop_context): Fix typo, for the matrix
6236 format: insert '0 >= 0' instead of '-1 >= 0'.
6238 2007-12-13 Sebastian Pop <sebastian.pop@amd.com>
6240 * Fix merge problems.
6242 2007-12-13 Sebastian Pop <sebastian.pop@amd.com>
6244 * graphite.c (setup_cloog_loop): Fix typo.
6246 2007-12-12 Sebastian Pop <sebastian.pop@amd.com>
6248 * doc/invoke.texi (-ftree-loop-distribution): Documented.
6249 * tree-loop-distribution.c: Reimplemented.
6250 * tree-pass.h (pass_loop_distribution): New.
6251 * tree-scalar-evolution.c (number_of_iterations_for_all_loops): Use
6253 * graphds.h (struct graph): New field indexes.
6254 * timevar.def (TV_TREE_LOOP_DISTRIBUTION): New.
6256 * tree-vect-analyze.c: Remove declaration of static functions when not
6258 * tree-vectorizer.c: Same.
6259 (rename_variables_in_loop): Now extern.
6260 (slpeel_tree_duplicate_loop_to_edge_cfg): Renamed
6261 tree_duplicate_loop_to_edge_cfg. Reset PENDING_STMT for edges after
6262 calling redirect_edge_and_branch_force.
6264 * tree-vectorizer.h (tree_duplicate_loop_on_edge): Declared.
6266 * tree-data-ref.c: Don't include tree-chrec.h.
6267 (debug_data_dependence_relations): New.
6268 (dump_data_dependence_relation): Call dump_data_reference on data refs
6270 (same_access_functions): Moved...
6271 (find_vertex_for_stmt): Renamed rdg_vertex_for_stmt.
6272 (dump_rdg_vertex, debug_rdg_vertex, dump_rdg_component,
6273 debug_rdg_component, dump_rdg, debug_rdg, dot_rdg_1, dot_rdg,
6274 struct rdg_vertex_info, ): New.
6275 (create_rdg_edge_for_ddr): Compute the dependence level before looking
6277 (create_rdg_vertices): Initialize the htab of graph->indexes.
6278 Initialize RDG_MEM_WRITE_STMT and RDG_MEM_READS_STMT.
6279 (stmts_from_loop): Don't save LABEL_EXPR.
6280 (hash_stmt_vertex_info, eq_stmt_vertex_info,
6281 hash_stmt_vertex_del): New.
6282 (build_rdg): Initialize rdg->indexes.
6283 (free_rdg, stores_from_loop, ref_base_address,
6284 rdg_defs_used_in_other_loops_p, have_similar_memory_accesses,
6285 have_similar_memory_accesses_1, ref_base_address_1,
6286 remove_similar_memory_refs): New.
6288 * tree-data-ref.h: Include tree-chrec.h.
6289 (debug_data_dependence_relations): Declared.
6290 (same_access_functions): ...here. Now static inline.
6291 (ddr_is_anti_dependent, ddrs_have_anti_deps,
6292 ddr_dependence_level): New.
6293 (struct rdg_vertex): New fields has_mem_write, has_mem_reads.
6294 (RDGV_HAS_MEM_WRITE, RDGV_HAS_MEM_READS, RDG_STMT, RDG_MEM_WRITE_STMT,
6295 RDG_MEM_READS_STMT): New.
6296 (dump_rdg_vertex, debug_rdg_vertex, dump_rdg_component,
6297 debug_rdg_component, dump_rdg, debug_rdg, dot_rdg,
6298 rdg_vertex_for_stmt): Declared.
6299 (struct rdg_edge): New field level.
6300 (RDGE_LEVEL, free_rdg): New.
6301 (stores_from_loop, remove_similar_memory_refs,
6302 rdg_defs_used_in_other_loops_p,
6303 have_similar_memory_accesses): Declared.
6304 (rdg_has_similar_memory_accesses): New.
6306 * lambda.h (dependence_level): New.
6307 * common.opt (ftree-loop-distribution): New.
6308 * tree-flow.h (debug_loop_ir): Renamed debug_loops.
6309 (print_loop_ir): Renamed print_loops.
6310 (debug_loop, debug_loop_num, print_loops_bb, mark_virtual_ops_in_bb,
6311 tree_duplicate_loop_to_edge_cfg, rename_variables_in_loop): Declared.
6312 * Makefile.in (TREE_DATA_REF_H): Depends on tree-chrec.h.
6313 (tree-loop-distribution.o): Added.
6314 * tree-cfg.c (mark_virtual_ops_in_region): Use mark_virtual_ops_in_bb.
6315 (mark_virtual_ops_in_bb): New.
6316 (print_loops_bb, debug_loop_num, debug_loop): New.
6317 * passes.c: Scheduled pass_loop_distribution.
6319 2007-12-12 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6321 * graphite.c (scan_tree_for_params): Correct the number of columns
6323 (nb_flat_iterator): New.
6324 (setup_cloog_loop): Initialize to 1 the first column for inequalities.
6325 (build_scop_iteration_domain): Correct the number of columns for
6328 2007-12-12 Sebastian Pop <sebastian.pop@amd.com>
6330 * Merge from mainline (129697:130800).
6332 2007-10-30 Sebastian Pop <sebastian.pop@amd.com>
6334 * graphite.c (build_graphite_bb): SCoP's basic blocks are post
6335 dominated by SCoP's exit.
6336 (graphite_transform_loops): Compute post dominators.
6338 2007-10-28 Sebastian Pop <sebastian.pop@amd.com>
6340 * Merge from mainline (127169:129697).
6342 2007-10-28 Sebastian Pop <sebastian.pop@amd.com>
6344 * graphite.c (affine_expr): Renamed scop_affine_expr. Use an extra
6345 parameter for the basic block that contains the expression. Use
6346 outermost_loop_in_scop for evolution_function_is_affine_multivariate_p.
6347 (stmt_simple_for_scop_p): Pass to scop_affine_expr the basic block of
6349 * graphite.h (gbb_loop): New.
6350 (GBB_LOOP): Removed.
6352 2007-08-03 Sebastian Pop <sebpop@gmail.com>
6354 * Makefile.in: Fix merge problem.
6356 2007-08-03 Sebastian Pop <sebpop@gmail.com>
6358 * Merge from mainline (125309:127169).
6359 * tree-loop-distribution.c: Disabled.
6361 2007-06-05 Sebastian Pop <sebpop@gmail.com>
6363 * Merge from mainline (r123693:125309).
6365 2007-05-30 Sebastian Pop <sebpop@gmail.com>
6367 * tree-loop-distribution.c (correct_modify_expr_p): Renamed
6369 (correct_modify_p, check_statements, number_of_lvalue_uses,
6370 number_of_scalar_dependences, create_edges): Use GIMPLE_MODIFY_STMT
6371 instead of MODIFY_EXPR.
6372 (update_edge_with_ddv): Don't pass index_of_edge. Initialize
6375 2007-05-24 Sebastian Pop <sebpop@gmail.com>
6377 * tree-loop-distribution.c (struct rdg): Replace arrays by
6378 VECs for edges and vertices.
6379 (RDG_NBV, RDG_NBE, RDG_VERTEX, RDG_EDGE): Removed.
6380 (RDGV_NB_PARTITIONS): New.
6381 (PRDG_NBV, PRDG_NBE): Removed.
6382 (build_scc_graph, correct_partitions_p, mark_partitions, build_prdg,
6383 dump_rdg, find_vertex_with_stmt, create_vertices, free_rdg,
6384 number_of_scalar_dependences, create_edges, build_rdg): Use VECs.
6386 2007-05-17 Georges-Andre Silber <silber@cri.ensmp.fr>
6387 Sebastian Pop <sebpop@gmail.com>
6389 * doc/invoke.texi (-ftree-loop-distribution): Document.
6390 * tree-loop-distribution.c: New file.
6391 * tree-pass.h (pass_loop_distribution): Declared.
6392 * timevar.def (TV_TREE_LOOP_DISTRIBUTION): New.
6393 * tree-data-ref.c (initialize_data_dependence_relation): Initialize
6395 * tree-data-ref.h (data_dependence_relation): Add reversed_p.
6396 (DDR_REVERSED_P): New.
6397 * common.opt (-ftree-loop-distribution): New.
6398 * tree-flow.h (distribute_loops): Declared.
6399 * Makefile.in (OBJS-common): Depend on tree-loop-distribution.o.
6400 * passes.c (init_optimization_passes): Schedule loop distribution.
6402 2007-05-12 Sebastian Pop <sebastian.pop@inria.fr>
6404 * graphite.c (print_graphite_bb): Don't call dump_data_references.
6405 (print_scop): Don't print when scop is NULL.
6406 (build_scop_context, find_transform): Don't output to stderr.
6408 2007-05-09 Sebastian Pop <sebastian.pop@inria.fr>
6410 * tree-data-ref.c: Don't include graphite.h.
6411 Comment out the code for printing data reference's scop.
6412 (build_access_matrix_with_af): Moved...
6413 * tree-data-ref.h (build_access_matrix_with_af): Removed declaration.
6414 * graphite.c (build_access_matrix_with_af): ... here. Now static.
6415 (print_graphite_bb): Print basic block's schedule.
6416 (print_scop): Don't print the schedule, call cloog's pretty printer.
6417 (bb_in_scop_p): A basic block is in a scop only if it is both
6418 dominated and postdominated by the scop's entry and exit basic blocks.
6419 (function_parameter_p): New.
6420 (invariant_in_scop_p): Use function_parameter_p.
6421 (new_scop, save_scop): New.
6422 (end_scop, test_for_scop_bound, build_scops): Use new_scop, and
6424 (scan_tree_for_params): Directly build the constraint as CloogMatrix.
6425 (loop_in_scop_p): New.
6426 (scop_record_loop): Use loop_in_scop_p.
6427 (build_scop_domain): Renamed build_scop_iteration_domain.
6428 (setup_cloog_loop, initialize_cloog_names, find_scop_parameters,
6429 nb_params_in_scop, build_scop_context, first_loop_in_scop,
6430 setup_cloog_loop, dot_scop_1, dot_scop): New.
6431 * graphite.h (GBB_LOOP, SCOP_PROG, dot_scop): New.
6432 (struct scop): Add a pointer to cloog's representation of a program.
6434 2007-04-14 Sebastian Pop <sebastian.pop@inria.fr>
6436 * doc/invoke.texi (-ftree-check-verbose): Renamed
6437 -ftree-checks-verbose.
6438 * common.opt (flag_tree_check_verbose): Renamed
6439 flag_tree_checks_verbose.
6440 * tree-check.c (tree_check_warning): Use flag_tree_checks_verbose.
6442 2007-04-14 Sebastian Pop <sebastian.pop@inria.fr>
6444 * configure: Regenerated.
6445 * config.in: Regenerated.
6446 * tree-ssa-loop.c (graphite_transforms): Execute
6447 graphite_transform_loops only when HAVE_cloog.
6448 * configure.ac (HAVE_polylib, HAVE_cloog, GRAPHITE): Defined.
6449 * graphite.c: Include polylibgmp.h and cloog.h.
6450 (graphite_transform_loops): Removed loops parameter.
6451 * tree-flow.h (graphite_transform_loops): Update declaration.
6452 * Makefile.in (POLYLIBLIBS, POLYLIBINC, CLOOGLIBS, CLOOGINC): New.
6453 (LIBS): Depend on CLOOGLIBS and on POLYLIBLIBS.
6454 (INCLUDES): Depend on POLYLIBINC and on CLOOGINC.
6455 (OBJS-common): Remove dependence on graphite.o.
6456 (BACKEND): Depend on @GRAPHITE@.
6458 2007-04-13 Sebastian Pop <sebastian.pop@inria.fr>
6460 * doc/invoke.texi (-ftree-check-verbose): Documented.
6461 * testsuite/gcc.dg/tree-checker/tree-checks-1.c: New.
6462 * testsuite/gcc.dg/tree-checker/tree-checks-2.c: New.
6463 * testsuite/gcc.dg/tree-checker/tree-checks-3.c: New.
6464 * testsuite/gcc.dg/tree-checker/tree-checks-4.c: New.
6465 * testsuite/gcc.dg/tree-checker/tree-checks.exp: New.
6466 * testsuite/gcc.dg/tree-checker/condates.crp: New.
6467 * common.opt (ftree-checks-verbose): New.
6468 * tree-check.c (tree_check_warning): Move extra stderr output
6469 under control of flag_tree_check_verbose.
6471 2007-04-12 Sebastian Pop <sebastian.pop@inria.fr>
6473 * tree-match.c: Fix comments formatting.
6474 * tree-match.h: Fix comments formatting.
6475 * tree-check.c: Fix comments formatting.
6476 (tree_check_init): Restructure.
6478 2007-04-12 Nic Volanschi <nic.volanschi@free.fr>
6480 * doc/invoke.texi (-ftree-check, -ftree-checks): Documented.
6482 2007-04-10 Sebastian Pop <sebastian.pop@inria.fr>
6484 * Merge from mainline (r120733:123693).
6486 2007-03-20 Nic Volanschi <nic.volanschi@free.fr>
6488 * condate.y: New file.
6489 * tree-match.h (struct patt_info_s): New field sign.
6490 (struct condate_s): New field msg.
6491 (normalize_condate, name_condate, add_condate): New.
6492 (conds[], condate_parse): Made extern.
6493 * tree-check.c (tree_check_warning): First arg changed to cond;
6494 warning reformatted.
6495 (tree_check_init): Reset the TREE_VISITED bit on every CFG node.
6497 (tree_check): Process trivial condates.
6498 (read_delimited_string): Removed.
6499 (print_cond): Print name and msg.
6500 (conds[]): Made extern.
6501 (parse_tree_check_file_once): Rewritten to use the parser in
6503 Processing of option --tree_check_string moved to tree_scan().
6504 * Makefile.in: Added condate.y
6506 2007-03-12 Sebastian Pop <sebastian.pop@inria.fr>
6508 * tree-pretty-print.c (dump_generic_bb_buff, lazy_dump_generic_node):
6509 Use VECs instead of varrays.
6510 * diagnostic.h (lazy_dump_generic_node): Update declaration.
6511 * Makefile.in (pretty-print.o): Depend on vec.h.
6512 * pretty-print.c: Include tree.h and vec.h.
6513 (pp_clear_state, pp_write_list_to_stream, pp_base_format,
6514 pp_base_format, pp_construct, pp_base_string, pp_lazy_mode,
6515 new_tree_chunk, pp_add_tree, pp_add_string, pp_add_char, pp_write_list,
6516 pp_free_list): Use VECs instead of varrays.
6517 * pretty-print.h: Do not include varray.h.
6518 (struct tree_chunk_s): Declaration moved before its use.
6519 (output_buffer): Rename varray field to chunks.
6520 * tree-match.c (tree_equal, chunk_1st_char, chunks_lookahead,
6521 tree_1st_char, match_chunks_pattinfo, match_tree_pattinfo,
6522 save_global_holes): Use VECs instead of varrays.
6523 * tree-match.h: Declare VECs of cfg_node, and hole_p.
6524 * tree-check.c (scan_cfg_stmts, push_node,
6525 print_matching_stmt): Removed.
6526 (tree_check_instance, push_global_holes_if_new, tree_check,
6527 execute_tree_check): Use VECs instead of varrays.
6528 (gate_tree_check): Don't execute the CFG check when basic_block_info
6531 2007-01-12 Sebastian Pop <sebastian.pop@inria.fr>
6533 * Merge from mainline (r115016:120733).
6535 2007-01-12 Sebastian Pop <sebastian.pop@inria.fr>
6537 * Merge from mainline (r117632:117661).
6539 2007-01-12 Sebastian Pop <sebastian.pop@inria.fr>
6541 * tree-dump.c (dump_option_value_in): Add TDF_DEBUG.
6542 * tree-pass.h (TDF_DEBUG, debug_p): New.
6543 * tree-scalar-evolution.c (set_scalar_evolution, get_scalar_evolution,
6544 get_scalar_evolution, add_to_evolution, set_nb_iterations_in_loop,
6545 get_loop_exit_condition, analyze_evolution_in_loop,
6546 analyze_initial_condition, analyze_scalar_evolution,
6547 instantiate_parameters, number_of_latch_executions): Use debug_p.
6548 * tree-chrec.c (chrec_apply): Use debug_p.
6549 * tree-data-ref.c: Include graphite.h.
6550 (dump_data_reference): Print also the access matrix.
6551 (analyze_array, analyze_indirect_ref, init_data_ref,
6552 analyze_offset_expr, address_analysis, object_analysis,
6553 create_data_ref, finalize_ddr_dependent,
6554 non_affine_dependence_relation, analyze_ziv_subscript,
6555 analyze_siv_subscript_cst_affine,
6556 compute_overlap_steps_for_affine_1_2, analyze_subscript_affine_affine,
6557 can_use_analyze_subscript_affine_affine, analyze_siv_subscript,
6558 analyze_miv_subscript, analyze_overlapping_iterations,
6559 build_classic_dist_vector, subscript_dependence_tester,
6560 compute_affine_dependence, analyze_all_data_dependences): Use debug_p.
6561 (build_access_matrix_with_af): No longer static.
6562 * tree-data-ref.h (scop_p): ... declaration here.
6563 (data_reference.scop): New field.
6564 (DR_SCOP, DR_ACCESS_MATRIX): New.
6565 (build_access_matrix_with_af, dr_num_subscripts): Declared.
6566 * graphite.c (print_graphite_bb): Call dump_data_references.
6567 (print_scop): Use scop_nb_loops and scop_dim_domain.
6568 (test_for_scop_bound): Use debug_p.
6569 (scan_tree_for_params): Use scop_nb_loops, scop_nb_loops and
6571 (scop_loop_index): Moved...
6572 (scop_record_loop): New.
6573 (build_scop_loop_nests): Use scop_record_loop.
6574 (build_scop_domain): Use scop_dim_domain.
6575 (build_access_matrix): Implemented.
6576 (build_scop_canonical_schedules): Use scop_nb_loops.
6577 (build_graphite_bb): Initialize GBB_SCOP.
6578 * graphite.h (scop_p): Moved...
6579 (graphite_bb.scop): New field.
6580 (graphite_bb.iteration_domain, GBB_DOMAIN, scop.nb_params,
6581 scop.nb_loops, scop.dim_domain, SCOP_NB_LOOPS, SCOP_NB_PARAMS,
6582 SCOP_DIM_DOMAIN, SCOP_STMTS): Removed.
6583 (scop_nb_params, scop_nb_loops, scop_dim_domain, gbb_dim_domain,
6584 scop_loop_index): New.
6585 * Makefile.in (tree-data-ref.o): Depends on graphite.h.
6587 2007-01-05 Sebastian Pop <sebastian.pop@inria.fr>
6589 * Merge from mainline (r117661:120450).
6591 2006-10-12 Sebastian Pop <sebastian.pop@inria.fr>
6593 * tree-scalar-evolution.c (instantiate_parameters_1): Don't stop
6594 at the first declaration outside the varying loop, instantiate as
6596 * tree-chrec.c (for_each_scev_op): New.
6597 * tree-chrec.h (for_each_scev_op): Declared.
6598 * tree-ssa-loop.c (pass_graphite_trans): Don't dump the function.
6599 * tree-data-ref.c (get_references_in_stmt,
6600 find_data_references_in_stmt): New, from trunk.
6601 (find_data_references_in_loop): Use get_references_in_stmt
6602 and find_data_references_in_loop, modified as in trunk.
6603 (build_access_matrix_with_af): New.
6604 * tree-data-ref.h (data_reference): Add a field access_matrix.
6605 (data_ref_loc): New, as in trunk.
6606 * graphite.c (print_graphite_bb, bb_in_scop_p, stmt_in_scop_p,
6607 invariant_in_scop_p, param_index, scan_tree_for_params,
6608 scop_loop_index, build_scop_loop_nests, build_scop_domain, irp_data,
6609 idx_record_param, idx_record_params, build_access_matrix,
6610 build_scop_data_accesses, build_scop_canonical_schedules,
6611 build_graphite_bb, build_scop_bbs, find_params_in_bb,
6612 build_scop_params): New.
6613 * graphite.h (graphite_bb): New.
6614 (scop): Add fields static_schedule, params, loop_nest,
6616 * lambda.h: Declare vecs of lambda_matrix.
6617 * tree-flow.h (print_loop_ir_bb): Declared.
6618 * tree-cfg.c (print_loop_ir_bb): New.
6619 (print_loop): Use print_loop_ir_bb.
6621 2006-10-12 Sebastian Pop <pop@cri.ensmp.fr>
6623 * Merge from mainline (r115016:117632).
6625 2006-10-11 Sebastian Pop <pop@cri.ensmp.fr>
6627 * graphite.c (debug_scops): Adjust definition for avoiding a bootstrap
6628 break due to a warning.
6630 2006-10-10 Sebastian Pop <pop@cri.ensmp.fr>
6632 * graphite.c (print_scops, debug_scops): New.
6633 (graphite_transform): Renamed graphite_find_transform.
6634 * graphite.h (debug_scops): Declared.
6636 2006-08-17 Sebastian Pop <pop@cri.ensmp.fr>
6638 * tree-match.c: Reformat following the GNU style.
6639 * tree-match.h: Reformat following the GNU style.
6640 * tree-pattern.h: Removed empty file.
6641 * Makefile.in: Remove references to tree-pattern.h.
6642 * tree-check.c: Reformat following the GNU style.
6643 (execute_tree_check): Move gate condition code to...
6644 (gate_tree_check): ...here. New function.
6645 (pass_check): Use the gate function.
6647 2006-07-04 Nic Volanschi <nic.volanschi@free.fr>
6649 * tree-pattern.h: New. Tree pattern matching and checking using
6651 * tree-check.c: New. Tree/CFG checking pass.
6652 * tree-match.c: New. Library for tree pattern matching.
6653 * opts.c, common.opt: Add options --ftree-check & --ftree-checks.
6654 * toplev.c, flags.h: Add globals for tree-check pass.
6655 * Makefile.in: Integrate the files in tree-check pass.
6656 * timevar.def, tree-optimize.c, tree-pass.h: Register tree-check pass.
6657 * pretty-print.c, pretty-print.h, tree-pretty-print.c, diagnostic.h:
6658 Introduce a "lazy" pretty-print mode.
6659 * tree.c, tree.h: Add tree_name.
6661 2006-07-04 Sebastian Pop <pop@cri.ensmp.fr>
6663 * doc/invoke.texi (-fgraphite): Correct typo.
6664 * tree-scalar-evolution.c (number_of_iterations_for_all_loops): Update
6665 use of print_loop_ir.
6666 * testsuite/gcc.dg/graphite/scop-1.c: New.
6667 * testsuite/gcc.dg/graphite/scop-2.c: New.
6668 * testsuite/gcc.dg/graphite/graphite.exp: New.
6669 * graphite.c: Include domwalk.h.
6670 (print_scop): Print only the entry and exit blocks.
6671 (debug_scop): No longer static.
6672 (affine_expr): Fix formating. Return also true when the expression is
6674 (stmt_simple_for_scop_p): Fix formating.
6675 (build_scops): Use domwalk.
6676 (get_loop_start, end_scop, test_for_scop_bound): New.
6677 (graphite_transform_loops): Avoid printing on stderr.
6678 * graphite.h (debug_scop): Declared.
6679 * tree-flow.h (debug_loop_ir, print_loop_ir): Update declarations.
6680 * Makefile.in (graphite.o): Depend on domwalk.h.
6681 * tree-cfg.c (print_loop, print_pred_bbs, print_succ_bbs): Remove
6682 declarations for static functions.
6683 (print_loop, print_loop_ir, debug_loop_ir): Use an extra parameter for
6684 controlling output verbosity.
6686 2006-06-26 Sebastian Pop <pop@cri.ensmp.fr>
6687 Plesco Alexandru <shurikx@gmail.com>
6689 * doc/invoke.texi (-fgraphite): Document.
6690 * tree-pass.h (pass_graphite_transforms): Declared.
6691 * timevar.def (TV_GRAPHITE_TRANSFORMS): New.
6692 * tree-ssa-loop.c (graphite_transforms, gate_graphite_transforms): New.
6693 (pass_graphite_transforms): Defined.
6694 * tree-data-ref.c (free_data_ref, data_reference): Extern.
6695 * tree-data-ref.h (free_data_ref, data_reference): Declared.
6696 * graphite.c, graphite.h: New.
6697 * common.opt (fgraphite): Declared.
6698 * tree-flow.h (graphite_transform_loops): Declared.
6699 * Makefile.in (OBJS-common): Add graphite.o.
6700 (graphite.o): New rule.
6701 * passes.c (pass_graphite_transforms): Scheduled.