1 2010-01-14 Sebastian Pop <sebastian.pop@amd.com>
4 * graphite-clast-to-gimple.c (gloog_error): New static variable.
5 (clast_to_gcc_expression): Do not build MULT_EXPR of POINTER_TYPE_P.
6 Set gloog_error when such an expression failed to be built.
7 (translate_clast): Early return when gloog_error is set.
8 (gloog): Clear gloog_error. When gloog_error is set, call
9 set_ifsese_condition to enable the original code. Return the status
10 of the code generation based on gloog_error.
11 * sese.c (set_ifsese_condition): New.
12 * sese.h (set_ifsese_condition): Declared.
14 * testsuite/g++.dg/graphite/pr42681.C: New.
16 2010-01-14 Sebastian Pop <sebastian.pop@amd.com>
19 * graphite-clast-to-gimple.c (gloog): Call scev_reset_htab and
21 * sese.c (rename_variables_in_operand): New.
22 (rename_variables_in_expr): New.
23 (rename_nb_iterations): New.
24 (sese_adjust_liveout_phis): Update the rename_map.
25 * sese.h (rename_nb_iterations): Declared.
26 * tree-scalar-evolution.c (scev_reset_htab): New.
27 (scev_reset): Call scev_reset_htab.
28 * tree-scalar-evolution.h (scev_reset_htab): Declared.
30 * testsuite/gfortran.dg/graphite/pr42732.f: New.
32 2010-01-08 Sebastian Pop <sebastian.pop@amd.com>
35 * graphite-clast-to-gimple.c: Fix formatting.
36 * sese.c (defined_in_loop_p): Renamed name_defined_in_loop_p.
37 (expr_defined_in_loop_p): New.
38 (add_loop_exit_phis): Also handle full expressions: remove from
39 the rename_map the expressions defined in the loop that we're closing.
41 * testsuite/gfortran.dg/graphite/pr42393-1.f90: New.
42 * testsuite/gfortran.dg/graphite/pr42393.f90: Add new flags
43 -fno-loop-block -fno-loop-interchange -fno-loop-strip-mine to also
44 make this testcase useful in the Graphite branch.
46 2010-01-08 Sebastian Pop <sebastian.pop@amd.com>
48 * graphite-scop-detection.c (exclude_component_ref): Removed.
49 (is_simple_operand): Removed.
50 (stmt_simple_for_scop_p): Remove use of is_simple_operand.
52 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
55 * sese.c (expand_scalar_variables_expr): Follow the SSA links into
56 the array indexing of ADDR_EXPRs.
58 * testsuite/gcc.dg/graphite/pr42221.c: New.
60 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
63 * graphite.c (graphite_finalize): Call scev_reset.
64 (graphite_transform_loops): Do not call scev_reset between the code
67 * testsuite/gcc.dg/graphite/pr42521.c: New.
69 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
71 * graphite-interchange.c (memory_stride_in_loop): Renamed
73 (memory_strides_in_loop): Renamed memory_strides_in_loop_1.
74 (memory_strides_in_loop): Memoize the memory strides per loop.
75 (lst_interchange_profitable_p): Do not initialize to zero the memory
77 * graphite-poly.h (struct lst): Add a field memory_strides.
78 (LST_LOOP_MEMORY_STRIDES): New.
79 (new_lst_loop): Initialize LST_LOOP_MEMORY_STRIDES to -1.
80 (free_lst): Clear LST_LOOP_MEMORY_STRIDES.
82 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
84 * graphite-interchange.c (memory_strides_in_loop_depth): Renamed
85 memory_strides_in_loop. Gather memory strides on a whole loop.
86 (pbb_interchange_profitable_p): Renamed lst_interchange_profitable_p.
87 (lst_interchange_profitable_p): Removed.
88 (lst_try_interchange_loops): Call lst_interchange_profitable_p.
90 2010-01-07 Sebastian Pop <sebastian.pop@amd.com>
92 Revert patch 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
93 * graphite-clast-to-gimple.c (try_mark_loop_parallel): New.
94 (translate_clast_for, translate_clast_guard, translate_clast, gloog):
95 Remove context_loop and level.
97 2010-01-07 Richard Guenther <rguenther@suse.de>
99 PR tree-optimization/42641
100 * sese.c (rename_map_elt_info): Use the SSA name version, do
103 2010-01-06 Sebastian Pop <sebastian.pop@amd.com>
105 * graphite-blocking.c (scop_do_block): Print "SCoP will be loop
106 blocked" only when both the strip mine and the interchange have
109 * testsuite/gcc.dg/graphite/block-2.c: Removed.
110 * testsuite/gcc.dg/graphite/block-3.c: Add scan pattern.
111 * testsuite/gcc.dg/graphite/block-4.c: Same.
112 * testsuite/gcc.dg/graphite/block-5.c: Same.
113 * testsuite/gcc.dg/graphite/block-6.c: Same.
115 2010-01-06 Sebastian Pop <sebastian.pop@amd.com>
117 * graphite-clast-to-gimple.c (save_clast_name_index): Free slot
118 before allocating a new one.
119 (copy_renames): Check that slot is not NULL.
120 (mark_bb_with_pbb): Same.
121 (compute_cloog_iv_types_1): Same.
122 * graphite-interchange.c (lst_perfect_nestify): Free the before,
123 nest, and after LSTs.
124 (lst_try_interchange_loops): Same.
126 2010-01-05 Sebastian Pop <sebastian.pop@amd.com>
129 * graphite-interchange.c (lst_try_interchange_loops): Do not return
130 the before, nest, and after LSTs.
131 (lst_try_interchange): Removed.
132 (lst_interchange_select_inner): Do not iterate over the LSTs if they
134 (lst_interchange_select_outer): Apply interchange on the outer loop
135 until there are no more changes in the inner loops.
137 2009-12-18 Sebastian Pop <sebastian.pop@amd.com>
139 Revert patch fixing PR middle-end/42221.
141 2009-12-18 Sebastian Pop <sebastian.pop@amd.com>
144 * graphite-sese-to-poly.c (follow_ssa_with_commutative_ops): Handle
147 * testsuite/gfortran.dg/graphite/pr42180.f90: Add compile flags.
149 2009-12-18 Sebastian Pop <sebastian.pop@amd.com>
152 * graphite-sese-to-poly.c (split_reduction_stmt): Do not split blocks
153 that contain only one statement.
155 * testsuite/gfortran.dg/graphite/pr42180.f90: New.
157 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
160 * testsuite/gfortran.dg/graphite/pr42393.f90: New.
162 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
165 * testsuite/gfortran.dg/graphite/pr42186.f90: New.
167 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
170 * graphite-sese-to-poly.c (translate_scalar_reduction_to_array_for_stmt):
171 Insert the reduction copy in the same block as the phi node.
172 (follow_ssa_with_commutative_ops): Handle GIMPLE_NOPs.
174 * testsuite/gcc.dg/graphite/pr42205-1.c: New.
175 * testsuite/gcc.dg/graphite/pr42205-2.c: New.
177 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
180 * sese.c (expand_scalar_variables_expr): Follow the SSA links into
181 the array indexing of ADDR_EXPRs.
183 * testsuite/gcc.dg/graphite/pr42221.c: New.
185 2009-12-17 Sebastian Pop <sebastian.pop@amd.com>
189 * graphite-interchange.c (lst_try_interchange): Do not modify OUTER
190 index. Call lst_interchange_select_inner only once.
191 (lst_interchange_select_inner): Update use of lst_try_interchange.
192 (lst_interchange_select_outer): Update.
194 2009-12-15 Sebastian Pop <sebastian.pop@amd.com>
198 * graphite-interchange.c (lst_try_interchange): Do not increment the
199 the OUTER index when there is no AFTER kernel. Do not increment the
200 OUTER index for after processing the AFTER kernel.
201 (lst_interchange_select_inner): Call lst_try_interchange only on loops.
202 (lst_interchange_select_outer): Do not pass in a pointer to the OUTER
203 index. Do not pass to lst_interchange_select_inner the OUTER index.
204 (scop_do_interchange): Update use of lst_interchange_select_outer.
206 * testsuite/gfortran.dg/graphite/graphite.exp
207 (DEFAULT_FLAGS_GRAPHITE_IDENTITY): Remove -fdump-tree-graphite-all.
208 * testsuite/gfortran.dg/graphite/interchange-1.f: Add comment. Clean
209 the graphite dump file.
210 * testsuite/gfortran.dg/graphite/interchange-2.f: Same.
211 * testsuite/gfortran.dg/graphite/pr42334-1.f: New.
213 2009-12-15 Sebastian Pop <sebastian.pop@amd.com>
217 * graphite-interchange.c (lst_perfect_nestify): Reset to NULL the LSTs
219 (lst_do_interchange_1): Renamed lst_interchange_select_inner.
220 (lst_try_interchange): Reimplemented.
221 (lst_interchange_select_inner): Same.
222 (lst_do_interchange): Renamed lst_interchange_select_outer.
224 (scop_do_interchange): Update use of lst_interchange_select_outer.
226 * testsuite/g++.dg/graphite/pr42130.C: Add -fgraphite-identity.
227 * testsuite/gcc.dg/graphite/block-0.c: Un-XFAILed.
228 * testsuite/gcc.dg/graphite/pr42211.c: New.
229 * testsuite/gfortran.dg/graphite/pr42334.f90: New.
231 2009-12-14 Sebastian Pop <sebastian.pop@amd.com>
234 * graphite-scop-detection.c (graphite_can_represent_scev): Handle more
235 carefully PLUS_EXPR, MINUS_EXPR, and MULT_EXPR.
237 * testsuite/gfortran.dg/graphite/pr42181.f90: New.
239 2009-12-12 Sebastian Pop <sebpop@gmail.com>
242 * graphite-sese-to-poly.c (rewrite_close_phi_out_of_ssa): Call
243 insert_out_of_ssa_copy_on_edge for anything else than SSA_NAMEs.
244 (detect_commutative_reduction_arg): Simplified.
245 (detect_commutative_reduction): Early return when the argument of
246 the close phi is not of an SSA_NAME.
248 * testsuite/gcc.dg/graphite/pr42284.c: New.
250 2009-12-11 Alexander Monakov <amonakov@ispras.ru>
252 * dbgcnt.def (graphite_scop): New counter.
253 * graphite.c: Include dbgcnt.h
254 (graphite_transform_loops): Use new counter to limit transformations.
256 2009-12-08 Sebastian Pop <sebpop@gmail.com>
259 * graphite-scop-detection.c (graphite_can_represent_init): Also
260 handle more complex MULT_EXPRs containing parameters by recursion
263 * testsuite/gfortran.dg/graphite/pr42285.f90: New.
265 2009-12-01 Tobias Grosser <grosser@fim.uni-passau.de>
267 * testsuite/g++.dg/graphite/pr42130.C: Fix type.
269 2009-11-29 Alexander Monakov <amonakov@gcc.gnu.org>
271 * testsuite/g++.dg/graphite/pr42130.C: Correct testcase.
273 2009-11-28 Tobias Grosser <grosser@fim.uni-passau.de>
275 * Merge from mainline (154493:154734).
277 2009-11-28 Tobias Grosser <grosser@fim.uni-passau.de>
279 * Merge from mainline (151362:154491).
281 2009-11-24 Tobias Grosser <grosser@fim.uni-passau.de>
283 * graphite-clast-to-gimple.c (try_mark_loop_parallel,
284 graphite_create_new_loop_guard, translate_clast_for): Fix comments.
286 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
289 * graphite-clast-to-gimple.c (graphite_create_new_loop_guard,
290 translate_clast_for_loop): New.
291 (translate_clast_for): Add a condition around the loop, to do not
292 execute loops with zero iterations.
293 * testsuite/g++.dg/graphite/pr42130.C: New.
294 * testsuite/gcc.dg/graphite/pr35356-2.c: Adapt.
296 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
298 * graphite-clast-to-gimple.c (try_mark_loop_parallel): New.
299 (translate_clast_for, translate_clast_guard, translate_clast, gloog):
300 Remove context_loop and level.
302 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
304 * graphite-clast-to-gimple.c (translate_clast_user,
305 translate_clast_for, translate_clast_guard): Simplify and move common
306 elements to translate_clast().
307 (translate_clast): Simplify and get common elements.
309 2009-11-23 Tobias Grosser <grosser@fim.uni-passau.de>
311 * graphite-clast-to-gimple.c (translate_clast_user,
312 translate_clast_for, translate_clast_guard): Split out of
315 2009-11-21 Tobias Grosser <grosser@fim.uni-passau.de>
317 * graphite-clast-to-gimple.c (clast_name_index, new_clast_name_index,
318 clast_name_to_index, save_clast_name_index, debug_clast_name_index,
319 debug_clast_name_indexes_1, debug_clast_name_indexes,
320 clast_name_index_elt_info, eq_clast_name_indexes): Moved from sese.h.
321 (clast_name_to_gcc, clast_to_gcc_expression,
322 clast_to_gcc_expression_red, gcc_type_for_clast_expr,
323 gcc_type_for_clast_eq, graphite_translate_clast_equation,
324 graphite_create_guard_cond_expr, graphite_create_new_loop,
325 translate_clast): Add params_index.
326 (initialize_cloog_names): Create parameter strings from scratch, do
327 not reference other strings.
328 (create_params_index): New.
329 (gloog): Initialize params_index.
330 * graphite-scop-detection (free_scops_1): Removed.
331 (limit_scops): Use normal free_scops.
332 * graphite-sese-to-poly.c (save_var_names): Removed.
333 (parameter_index_in_region): Do not initialize SESE_PARAM_NAMES
334 and SESE_PARAMS_INDEX.
335 * sese.c (new_sese, free_sese): Dito.
336 * sese.h (struct sese): Remove params_index, params_names.
337 (SESE_PARAMS_INDEX, SESE_PARAMS_NAMES): Removed.
339 2009-11-20 Sebastian Pop <sebastian.pop@amd.com>
341 Revert the following patch from 2009-09-14:
342 * graphite-blocking.c: Fix order of includes: tree-chrec.h, then
343 tree-scalar-evolution.h, and then tree-data-ref.h.
344 * graphite-clast-to-gimple.c: Same.
345 * graphite-dependences.c: Same.
346 * graphite-interchange.c: Same.
347 * graphite-poly.c: Same.
348 * graphite-scop-detection.c: Same.
349 * graphite-sese-to-poly.c: Same.
351 * lambda-code.c: Same.
352 * matrix-reorg.c: Same.
353 * tree-data-ref.c: Same.
354 * tree-if-conv.c: Same.
355 * tree-loop-distribu: Same.: Same.
356 * tree-loop-linear.c: Same.
357 * tree-parloops.c: Same.
358 * tree-predcom.c: Same.
359 * tree-vect-patterns.c: Same.
361 2009-11-20 Sebastian Pop <sebastian.pop@amd.com>
363 Revert patch from 2009-09-14.
364 * tree-ssa-loop.c (gate_graphite_transforms): Re-enable Graphite
365 passes at -O1 and below.
367 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
370 * testsuite/gcc.dg/graphite/pr40281.c: New.
372 * tree-scalar-evolution.c (instantiate_scev_poly): Base and stride
373 evolutions should not variate in inner loops.
375 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
378 * testsuite/gfortran.dg/graphite/pr42050.f90: New.
380 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
382 * graphite-interchange.c (memory_strides_in_loop_depth): New.
383 (pbb_interchange_profitable_p): Call memory_strides_in_loop_depth.
385 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
387 * graphite-blocking.c (scop_do_block): New.
388 * graphite-poly.c (apply_poly_transforms): Call scop_do_block.
389 * graphite-poly.h (scop_do_block): Declared.
391 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
393 * graphite-blocking.c (pbb_strip_mine_profitable_p): The parameter
394 depth is the loop nesting depth in the LST. Call psct_dynamic_dim
395 to transform depth into the time_depth before calling
396 pbb_number_of_iterations_at_time.
397 (lst_do_strip_mine): Use a scalar variable instead of recomputing
400 2009-11-18 Sebastian Pop <sebastian.pop@amd.com>
402 Reverted the patch for "scattering permutations" from 2009-10-28.
404 * graphite-poly.c (print_permutation): New.
405 (debug_permutation): New.
406 (new_poly_bb): Initialize PBB_PERMUTATION.
407 (free_poly_bb): Free PBB_PERMUTATION.
408 * graphite-poly.h (pbb_permutation_elt_p): Declared.
409 (struct pbb_permutation_elt): New.
410 (PBB_PERMUTATION_ELT_STRIDE): New.
411 (PBB_PERMUTATION_ELT_STRIDED_P): New.
412 (PBB_PERMUTATION_ELT_TIME_DIMENSION): New.
413 (new_pbb_permutation_elt): New.
414 (pbb_permutation_elt_free): New.
415 (struct poly_bb): Add field permutation.
416 (PBB_PERMUTATION): New.
417 (print_permutation): Declared.
418 (debug_permutation): Declared.
420 2009-11-04 Konrad Trifunovic <konrad.trifunovic@inria.fr>
422 * graphite-interchange.c (build_partial_difference): New.
423 (memory_stride_in_loop): Refactored the computation of
424 equality constraints into build_partial_difference function.
425 Added support for debugging stride computations.
427 2009-11-03 Sebastian Pop <sebastian.pop@amd.com>
429 * graphite-clast-to-gimple.c (gloog): Free if_region,
430 if_region->true_region, and if_region->region.
431 * sese.c (if_region_set_false_region): Free if_region->false_region.
432 (create_if_region_on_edge): Do not use GGC_NEW.
433 (move_sese_in_condition): Remove useless initialization.
435 2009-11-03 Sebastian Pop <sebastian.pop@amd.com>
437 * graphite-interchange.c (lst_perfect_nestify): Pass 3 parameters
438 for the loops created by the loop distribution. Do not modify the
440 (lst_try_interchange_loops): Same. Use a temporary LST for the
441 transformed schedule. Call lst_update_scattering before data
443 (lst_try_interchange): Pass an extra parameter INDEX.
444 (lst_do_interchange_1): New.
445 (lst_do_interchange): Call lst_do_interchange_1.
446 (scop_do_interchange): Call lst_update_scattering.
447 * graphite-poly.c (apply_poly_transforms): Do not call
448 lst_update_scattering.
449 * graphite-poly.h (lst_pred): New.
451 (lst_find_first_pbb): Return NULL when not found.
453 (lst_insert_in_sequence): Allow LST1 to be NULL.
455 (lst_substitute_3): New.
456 * gcc.dg/graphite/interchange-1.c: XFail.
457 * gcc.dg/graphite/interchange-8.c: XFail.
458 * gcc.dg/graphite/interchange-11.c: XFail.
460 2009-10-30 Sebastian Pop <sebastian.pop@amd.com>
462 * graphite-interchange.c (lst_perfectly_nested_p): New.
463 (lst_perfect_nestify): New.
464 (lst_try_interchange_loops): Call store_lst_schedule,
465 lst_perfectly_nested_p, lst_perfect_nestify and restore_lst_schedule.
466 (scop_do_interchange): Avoid redundant legality test.
467 Call lst_do_interchange on a copy of SCOP_TRANSFORMED_SCHEDULE.
468 * graphite-poly.c (apply_poly_transforms): Call lst_update_scattering.
469 * graphite-poly.h (psct_static_dim): New.
470 (lst_dewey_number_at_depth): New.
471 (lst_find_pbb): Restructured.
472 (lst_find_first_pbb): Restructured.
473 (lst_find_last_pbb): New.
474 (lst_contains_p): New.
475 (lst_contains_pbb): New.
476 (lst_create_nest): New.
477 (lst_remove_from_sequence): New.
478 (pbb_update_scattering): New.
479 (lst_update_scattering_under): New.
480 (lst_update_scattering_seq): New.
481 (lst_update_scattering): New.
482 (lst_insert_in_sequence): New.
483 (lst_distribute_lst): New.
484 (lst_remove_all_before_including_pbb): New.
485 (lst_remove_all_before_excluding_pbb): New.
487 2009-10-30 Sebastian Pop <sebastian.pop@amd.com>
489 * tree-ssa-loop-niter.c (finite_loop_p): Do not call twice
492 2009-10-30 Sebastian Pop <sebastian.pop@amd.com>
494 * graphite-poly.c (pbb_remove_duplicate_pdrs): Free collapsed.
496 2009-10-28 Konrad Trifunovic <konrad.trifunovic@gmail.com>
498 * graphite-poly.c (print_permutation): New.
499 (debug_permutation): New.
500 (new_poly_bb): Initialize PBB_PERMUTATION.
501 (free_poly_bb): Free PBB_PERMUTATION.
502 * graphite-poly.h (pbb_permutation_elt_p): Declared.
503 (struct pbb_permutation_elt): New.
504 (PBB_PERMUTATION_ELT_STRIDE): New.
505 (PBB_PERMUTATION_ELT_STRIDED_P): New.
506 (PBB_PERMUTATION_ELT_TIME_DIMENSION): New.
507 (new_pbb_permutation_elt): New.
508 (pbb_permutation_elt_free): New.
509 (struct poly_bb): Add field permutation.
510 (PBB_PERMUTATION): New.
511 (print_permutation): Declared.
512 (debug_permutation): Declared.
514 2009-10-26 Sebastian Pop <sebastian.pop@amd.com>
516 * graphite-clast-to-gimple.c (gloog): Do not call
517 sese_reset_aux_in_loops.
518 * graphite-sese-to-poly.c (build_loop_iteration_domains): Pass an
519 extra argument for domains. Do not use loop->aux.
520 (build_scop_iteration_domain): Initialize and free domains, pass it
521 to build_loop_iteration_domains and extract the information from
522 domains. Do not use loop->aux.
523 * sese.c (sese_reset_aux_in_loops): Removed.
524 * sese.h (sese_reset_aux_in_loops): Removed.
526 2009-10-26 Sebastian Pop <sebastian.pop@amd.com>
528 * graphite-clast-to-gimple.c (find_pbb_via_hash): Moved up.
529 (dependency_in_loop_p): Same.
530 (translate_clast): Do not use loop->aux. Initialize
531 loop->can_be_parallel.
532 (mark_loops_parallel): Removed.
533 * graphite-clast-to-gimple.h (mark_loops_parallel): Removed.
534 * graphite.c (free_aux_in_new_loops): Removed.
535 (graphite_finalize): Do not call free_aux_in_new_loops.
536 (graphite_transform_loops): Do not call mark_loops_parallel.
538 2009-10-26 Li Feng <nemokingdom@gmail.com>
540 * graphite-clast-to-gimple.c (get_stmtfor_depth): Removed.
541 (translate_clast): Pass an extra parameter LEVEL.
542 Call get_scattering_level.
543 * graphite-clast-to-gimple.h (get_scattering_level): New.
545 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
547 * cfgloop.c (alloc_loop): Initialize loop->single_iv.
548 * cfgloop.h (struct loop): New field single_iv.
550 * graphite-clast-to-gimple.c (pbb_to_depth_to_oldiv): Do not use
551 loop->aux anymore: use loop->single_iv.
552 (graphite_loop_normal_form): Moved...
553 (build_graphite_loop_normal_form): Removed.
554 (gloog): Do not call build_graphite_loop_normal_form.
555 (free_aux_in_new_loops): Moved...
556 (mark_loops_parallel): Restructure.
557 * graphite-clast-to-gimple.h (free_aux_in_new_loops): Do not declare.
558 * graphite-sese-to-poly.c (graphite_loop_normal_form): ...here.
559 (scop_canonicalize_loops): New.
560 (build_poly_scop): Call scop_canonicalize_loops.
561 * graphite.c (free_aux_in_new_loops): ...here.
563 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
565 * g++.dg/graphite/graphite.exp: Add the same rules as in
566 gcc.dg/graphite/graphite.exp.
568 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
570 * g++.dg/graphite/id-1.C: New.
572 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
574 * graphite-sese-to-poly.c (create_zero_dim_array): Pass an extra
576 (rewrite_close_phi_out_of_ssa): Update use of create_zero_dim_array.
577 (rewrite_phi_out_of_ssa): Same.
578 (rewrite_cross_bb_scalar_deps): Same.
579 (translate_scalar_reduction_to_array): Same.
581 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
583 * graphite-sese-to-poly.c (build_scop_drs): Disable call to
586 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
588 * graphite-sese-to-poly.c (dump_alias_graphs): New.
589 (build_scop_drs): Call dump_alias_graphs.
591 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
593 * graphite-poly.c (new_scop): Initialize SCOP_ORIGINAL_SCHEDULE,
594 SCOP_TRANSFORMED_SCHEDULE, and SCOP_SAVED_SCHEDULE.
595 (free_scop): Call free_lst on SCOP_ORIGINAL_SCHEDULE,
596 SCOP_TRANSFORMED_SCHEDULE, and SCOP_SAVED_SCHEDULE.
597 * graphite-poly.h (free_lst): New.
598 (store_lst_schedule): Free SCOP_SAVED_SCHEDULE.
599 (restore_lst_schedule): Free SCOP_TRANSFORMED_SCHEDULE.
601 2009-10-22 Sebastian Pop <sebastian.pop@amd.com>
603 * graphite-poly.h (struct scop): Add a field saved_schedule.
604 (SCOP_SAVED_SCHEDULE): New.
605 (store_lst_schedule): New.
606 (restore_lst_schedule): New.
607 (store_scattering): Call store_lst_schedule.
608 (restore_scattering): Call restore_lst_schedule.
610 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
612 * graphite-sese-to-poly.c (free_data_refs_aux): Fix formatting.
613 (pdr_add_alias_set): Same.
614 (build_poly_dr): Same.
615 (build_alias_set_optimal_p): Same.
616 (build_base_obj_set_for_drs): Same. Do not store the result of
619 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
621 * graphite-sese-to-poly.c (build_alias_set_optimal_p): Initialize
622 all_components_are_cliques to 1.
624 2009-10-20 Li Feng <nemokingdom@gmail.com>
626 * graphite-sese-to-poly.c (free_data_refs_aux): Update to free
628 (pdr_add_alias_set): Update retrieving alias_set_num.
629 (build_poly_dr): Update retrieving dr_base_object_set.
630 (partition_drs_to_sets): Remove.
631 (build_alias_set_optimal_p): New.
632 (build_alias_set_for_drs): Rename.
633 (build_scop_drs): Update.
634 * graphite-sese-to-poly.h (struct base_alias_pair): New.
635 (ALIAS_SET_INDEX): Remove.
636 (BASE_OBJECT_SET_INDEX): Remove.
638 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
640 * sese.c (get_vdef_before_sese): Handle GIMPLE_ASSIGN and GIMPLE_CALL.
642 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
644 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Do not infer
645 loop upper bounds for 1-element arrays at end of structures.
646 * tree-flow.h (array_at_struct_end_p): Declared.
647 * tree-ssa-loop-niter.c (array_at_struct_end_p): Not static anymore.
649 2009-10-20 Sebastian Pop <sebastian.pop@amd.com>
651 * g++.dg/graphite/pr41305.C: New.
653 2009-10-20 Alexander Monakov <amonakov@ispras.ru>
655 * graphite-sese-to-poly.c (build_loop_iteration_domains): Generalize
656 construction of parameter constraints from loop iteration analysis.
657 * gcc.dg/graphite/run-id-2.c: New test.
659 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
661 * graphite-interchange.c (memory_stride_in_loop): Delete p1, lma
664 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
666 * graphite-dependences.c (dependence_polyhedron_1): Remove
667 unused gdim dimensions from the DDR polyhedron.
669 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
671 * graphite-dependences.c (pddr_transformed_scattering): New.
672 (dot_original_deps_stmt_1): New.
673 (dot_transformed_deps_stmt_1): New.
674 (dot_deps_stmt_1): Call dot_original_deps_stmt_1 and
675 dot_transformed_deps_stmt_1.
676 (dot_original_deps): New.
677 (dot_transformed_deps): New.
678 (dot_deps_1): Call dot_original_deps and dot_transformed_deps.
680 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
682 * graphite-dependences.c (reduction_dr_1): Remove wrong
683 assert: reduction BBs can have multiple reduction writes
684 to memory. interchange-3.f90 is an example.
686 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
688 * gfortran.dg/graphite/interchange-3.f90: New.
690 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
692 * gcc.dg/graphite/interchange-1.c: Un-XFAILed.
694 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
696 * graphite-dependences.c (dependence_polyhedron_1): Add the
697 context to the dependence polyhedron.
699 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
701 * graphite-poly.c (pbb_remove_duplicate_pdrs): Initialize
702 PBB_PDR_DUPLICATES_REMOVED.
705 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
707 * graphite-sese-to-poly.c (find_scop_parameters): Initialize
709 (build_loop_iteration_domains): Extract bounds on parameters
710 based on the data size.
711 (build_scop_context): Do not initialize SCOP_CONTEXT;
714 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
716 * graphite-ppl.c (ppl_min_for_le_polyhedron): New.
717 * graphite-ppl.h (graphite-ppl.h): Declared.
719 2009-10-17 Sebastian Pop <sebastian.pop@amd.com>
721 * graphite-ppl.c (ppl_print_linear_expr): New.
722 (debug_ppl_linear_expr): New.
723 * graphite-ppl.h (ppl_print_linear_expr): Declared.
724 (debug_ppl_linear_expr): Declared.
726 2009-10-16 Sebastian Pop <sebastian.pop@amd.com>
728 * graphite-interchange.c: Fix comments.
729 * gcc.dg/graphite/block-1.c: Fix comments.
731 2009-10-16 Sebastian Pop <sebastian.pop@amd.com>
733 * gcc.dg/graphite/interchange-7.c: Un-XFAILed.
734 * gcc.dg/graphite/interchange-9.c: Un-XFAILed.
736 2009-10-16 Sebastian Pop <sebastian.pop@amd.com>
738 Reapply the patch from Alexander Monakov that disappeared during
739 the last merges from trunk.
741 2009-09-16 Alexander Monakov <amonakov@ispras.ru>
743 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Add bounds only
744 for ARRAY_REFs. Use array_ref_{low,up}_bound to determine bounds.
746 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
748 * graphite-interchange.c (memory_stride_in_loop): The depth
749 argument corresponds to a dynamic time dimension, so use
750 psct_dynamic_dim to refer to the transformed scattering dimension.
752 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
754 * graphite-interchange.c (memory_stride_in_loop): Fix comments.
756 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
758 * graphite-blocking.c (lst_do_strip_mine): Avoid strip mining the
760 * graphite-interchange.c (lst_do_interchange): Avoid interchanging
762 * graphite-poly.c (scop_to_lst): Fix LST sequence in an outermost
764 (print_lst): Print the root of LST in a different format.
765 * graphite-poly.h (lst_depth): Adjust to include the root of the LST.
767 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
769 * graphite-poly.c (print_scop): Fix pretty printing of a SCoP.
771 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
773 * doc/passes.texi: Document the Graphite infrastructure.
775 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
777 * graphite-sese-to-poly.c (insert_copyin): Use gsi_insert_seq_on_edge.
778 (rewrite_commutative_reductions_out_of_ssa): Call gsi_commit_edge_inserts,
779 and check the SSA representation.
781 * gfortran.dg/graphite/id-18.f90: New, reduced from PR41193.
783 2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
785 * gcc.dg/graphite/pr40157.c: Use -floop-block as reported in the PR.
787 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
789 * gcc.dg/graphite/interchange-11.c: New.
791 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
793 * gcc.dg/graphite/interchange-8.c: Enable loop interchange.
795 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
797 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK):
798 Add -fno-loop-strip-mine and -fno-loop-interchange.
799 (DEFAULT_FLAGS_GRAPHITE_INTERCHANGE): Add -fno-loop-block and
800 -fno-loop-strip-mine.
801 * gfortran.dg/graphite/graphite.exp: Same.
803 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
805 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK):
806 Renamed DEFAULT_FLAGS_GRAPHITE_BLOCK.
807 (DEFAULT_CFLAGS_GRAPHITE_IDENTITY): Renamed
808 DEFAULT_FLAGS_GRAPHITE_IDENTITY.
809 (DEFAULT_CFLAGS_GRAPHITE_INTERCHANGE): Renamed
810 DEFAULT_FLAGS_GRAPHITE_INTERCHANGE.
811 (DEFAULT_CFLAGS_GRAPHITE_SCOP): Renamed
812 DEFAULT_FLAGS_GRAPHITE_SCOP.
813 (DEFAULT_CFLAGS_RUN_ID): Renamed DEFAULT_FLAGS_RUN_ID.
814 (DEFAULT_CFLAGS_GRAPHITE): Renamed DEFAULT_FLAGS_GRAPHITE.
816 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
818 * graphite-poly.c (pbb_number_of_iterations_at_time): Cleanup comments.
820 2009-10-14 Konrad Trifunovic <konrad.trifunovic@gmail.com>
821 Sebastian Pop <sebastian.pop@amd.com>
823 * graphite-interchange.c (build_linearized_memory_access): Pass an
825 (memory_stride_in_loop): Include transform scattering in the
826 access functions to be able to querry the strides in the
828 (pbb_interchange_loop_depths): Interchange the psct_dynamic_dim,
829 not the psct_iterator_dim.
831 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
833 * graphite-blocking.c (pbb_do_strip_mine): Removed.
834 (lst_do_strip_mine_loop): New.
835 (lst_do_strip_mine): New.
836 (scop_do_strip_mine): Call lst_do_strip_mine.
837 * graphite-poly.h (lst_add_loop_under_loop): New.
838 (lst_find_first_pbb): New.
840 2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
842 * graphite-poly.c (loop_to_lst): Fix LST creation.
844 2009-10-14 Tobias Grosser <grosser@fim.uni-passau.de>
846 * testsuite/gcc.dg/graphite/id-15.c: (8 * 8) replaced with
847 sizeof(unsigned long) to make it run on 32bit systems.
849 2009-10-14 Tobias Grosser <grosser@fim.uni-passau.de>
851 * testsuite/gcc.dg/graphite/run-id-1.c: Use smaller matrix to not
854 2009-10-14 Ramakrishna Upadrasta <Ramakrishna.Upadrasta@inria.fr>
856 * graphite-sese-to-poly.c (write_alias_graph_to_ascii_dimacs): Fix
858 (write_alias_graph_to_ascii_dot): New.
859 (write_alias_graph_to_ascii_ecc): Ditto.
860 (partition_drs_to_sets): Add testing of optimality of current method
861 which assigns alias numbers according to DFS Comopnent number. used
862 as heuristic for the upcoming ECC algorithm.
863 (build_scop_drs): Write to file also with the ecc and dot format.
865 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
867 * gfortran.dg/graphite/interchange-1.f: XFail.
869 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
871 * graphite.c (graphite_initialize): Do not handle functions with
872 more than 100 basic blocks.
874 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
876 * graphite-blocking.c (pbb_do_strip_mine): Use
877 PARAM_LOOP_BLOCK_TILE_SIZE.
879 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
881 * graphite-poly.c (dot_lst_1): New.
883 * graphite-poly.h (dot_lst): Declared.
885 2009-10-13 Sebastian Pop <sebastian.pop@amd.com>
887 * graphite-dependences.c (dot_deps_stmt_1): New.
888 (dot_deps_stmt): New.
889 * graphite-dependences.h (dot_deps_stmt): Declared.
891 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
893 * graphite-sese-to-poly.c (rewrite_cross_bb_scalar_dependence): Do
894 not replace cross BB scalar dependences ending on PHI nodes.
895 (rewrite_cross_bb_scalar_deps): Filter out GIMPLE_PHI nodes.
897 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
899 * graphite-poly.c (apply_poly_transforms): Implement the high
900 level driver for flag_loop_block.
901 * opts.c (decode_options): Enable flag_loop_block at -O2.
902 * tree-ssa-loop.c (gate_graphite_transforms): Remove call to sorry for
905 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK): Add
907 * gfortran.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK):
910 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
912 * graphite-poly.h (lst_find_pbb): New.
913 (find_lst_loop): New.
915 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
917 * graphite-poly.c (new_scop): Remove init of SCOP_DEP_GRAPH.
918 * graphite-poly.h (struct scop): Remove dep_graph field.
919 (SCOP_DEP_GRAPH): Removed.
921 2009-10-09 Sebastian Pop <sebastian.pop@amd.com>
923 * graphite-poly.h (copy_lst): Do full copy of LST.
925 2009-10-07 Sebastian Pop <sebastian.pop@amd.com>
927 * graphite-sese-to-poly.c (reduction_phi_p): Call remove_invariant_phi
928 when the loop stride is zero.
930 * gcc.dg/graphite/id-16.c: New.
932 2009-10-06 Sebastian Pop <sebastian.pop@amd.com>
934 * graphite-dependences.c (reduction_dr_1): New.
935 (reduction_dr_p): New.
936 (graphite_legal_transform_dr): Call reduction_dr_p.
937 (reduction_ddr): Renamed reduction_ddr_p.
938 * graphite-poly.h (same_pdr_p): New.
939 (number_of_write_pdrs): New.
940 * graphite-sese-to-poly.c (nb_data_writes_in_bb): New.
941 (split_reduction_stmt): Do not split reduction statements
942 when there are no writes to memory.
943 (translate_scalar_reduction_to_array_for_stmt): Insert the
944 memory reduction statement just after the scalar reduction statement.
946 * gcc.dg/graphite/interchange-10.c: Updated to differ from interchange-4.c.
948 * gcc.dg/graphite/interchange-3.c: Un-XFAIL-ed.
949 * gcc.dg/graphite/interchange-4.c: Un-XFAIL-ed.
951 2009-10-06 Sebastian Pop <sebastian.pop@amd.com>
953 * graphite-interchange.c (lst_apply_interchange): New.
954 (lst_interchange_profitable_p): New.
955 (lst_try_interchange_loops): New.
956 (lst_try_interchange): New.
957 (lst_do_interchange): New.
958 (pbb_do_interchange): Removed.
959 (scop_do_interchange): Call lst_do_interchange.
961 2009-10-06 Sebastian Pop <sebastian.pop@amd.com>
963 * graphite-poly.c (print_scop): Print SCOP_ORIGINAL_SCHEDULE and
964 SCOP_TRANSFORMED_SCHEDULE.
969 * graphite-poly.h (lst_p): New.
972 (LST_LOOP_FATHER): New.
975 (scop_to_lst): Declared.
976 (print_lst): Declared.
977 (debug_lst): Declared.
982 (lst_dewey_number): New.
983 (struct scop): Add original_schedule and transformed_schedule fields.
984 (SCOP_ORIGINAL_SCHEDULE): New.
985 (SCOP_TRANSFORMED_SCHEDULE): New.
986 * graphite-sese-to-poly.c (build_poly_scop): Call scop_to_lst.
988 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
990 * graphite-dependences.c (reduction_ddr): New.
991 (graphite_legal_transform_bb): Call reduction_ddr.
992 * graphite-poly.c (new_poly_bb): Pass a new bool parameter.
993 Initialize PBB_IS_REDUCTION.
994 * graphite-poly.h (struct poly_bb): New bool field is_reduction.
995 (PBB_IS_REDUCTION): New.
996 (new_poly_bb): Update declaration.
997 * graphite-scop-detection.h (build_scop_bbs): Removed.
998 (nb_reductions_in_loop): Removed.
999 * graphite-sese-to-poly.c (try_generate_gimple_bb): Pass a sbitmap
1000 parameter for reductions.
1001 (try_generate_gimple_bb): Update call to new_poly_bb.
1002 (build_scop_bbs_1): Same.
1003 (build_scop_bbs): Same.
1004 (gsi_for_phi_node): New.
1005 (scalar_close_phi_node_p): Remove gcc_assert.
1006 (split_reduction_stmt): New.
1007 (is_reduction_operation_p): New.
1008 (phi_contains_arg): New.
1009 (follow_ssa_with_commutative_ops): New.
1010 (detect_commutative_reduction_arg): New.
1011 (detect_commutative_reduction_assign): New.
1012 (follow_inital_value_to_phi): New.
1013 (edge_initial_value_for_loop_phi): New.
1014 (initial_value_for_loop_phi): New.
1015 (detect_commutative_reduction): New.
1016 (translate_scalar_reduction_to_array_for_stmt): New.
1017 (insert_copyout): New.
1018 (insert_copyin): New.
1019 (translate_scalar_reduction_to_array): New.
1020 (rewrite_commutative_reductions_out_of_ssa_close_phi): New.
1021 (rewrite_commutative_reductions_out_of_ssa_loop): New.
1022 (rewrite_commutative_reductions_out_of_ssa): New.
1023 (build_poly_scop): Call rewrite_commutative_reductions_out_of_ssa.
1024 * sese.h (split_region_for_bb): New.
1026 * gcc.dg/graphite/graphite.exp (DEFAULT_CFLAGS_GRAPHITE_BLOCK): Add -ffast-math.
1027 * gcc.dg/graphite/interchange-1.c: Fix format.
1028 * gcc.dg/graphite/interchange-10.c: New.
1030 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
1032 * graphite-sese-to-poly.c (insert_out_of_ssa_copy): Remove
1035 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
1037 * graphite-sese-to-poly.c (scev_analyzable_p): New.
1038 (rewrite_cross_bb_scalar_dependence): New.
1039 (rewrite_cross_bb_scalar_deps): New.
1040 (rewrite_reductions_out_of_ssa): Use bb_in_sese_p.
1041 Call rewrite_cross_bb_scalar_deps.
1043 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
1045 * graphite-sese-to-poly.c (gsi_for_ssa_name_def): Removed.
1046 (insert_out_of_ssa_copy): Directly use gsi_after_labels and
1049 2009-10-05 Sebastian Pop <sebastian.pop@amd.com>
1051 * graphite-clast-to-gimple.c (build_cloog_prog): Use pbb_index.
1052 * graphite-interchange.c (pbb_do_interchange): Same.
1053 * graphite-poly.c (print_scattering_function): Same.
1055 * graphite-poly.h (pbb_loop): New.
1056 * graphite-sese-to-poly.c (create_linear_expr_from_tree): Use pbb_loop.
1058 2009-09-27 Sebastian Pop <sebastian.pop@amd.com>
1060 * graphite-scop-detection.c (limit_scops): Do not build poly_bbs.
1062 2009-09-27 Sebastian Pop <sebastian.pop@amd.com>
1064 * graphite-sese-to-poly.c (partition_drs_to_sets): Drs is not modified,
1065 so don't pass a pointer to it.
1066 (build_alias_set_for_drs): Same.
1067 (build_base_obj_set_for_drs): Same.
1068 (build_scop_drs): Same.
1070 2009-09-26 Li Feng <nemokingdom@gmail.com>
1072 * graphite-sese-to-poly.c (build_scop_drs): Disable writing to file
1073 the alias graph of data references.
1075 2009-09-25 Li Feng <nemokingdom@gmail.com>
1077 * graphite-sese-to-poly.c (write_alias_graph_to_ascii_dimacs): New.
1078 (build_scop_drs): When debugging, write the alias graph to file,
1079 otherwise, should be disabled.
1081 2009-09-17 Sebastian Pop <sebastian.pop@amd.com>
1083 * Merge from mainline (151310:151361).
1085 2009-09-17 Sebastian Pop <sebastian.pop@amd.com>
1087 * Merge from mainline (151171:151310).
1089 2009-09-17 Sebastian Pop <sebastian.pop@amd.com>
1091 * Merge from mainline (151171:151806).
1093 2009-09-17 Sebastian Pop <sebastian.pop@amd.com>
1095 * Revert the last commit.
1097 2009-09-17 Sebastian Pop <sebastian.pop@amd.com>
1099 * Merge from mainline (151171:151819).
1101 2009-09-17 Sebastian Pop <sebastian.pop@amd.com>
1103 * graphite-scop-detection.c (stmt_simple_memref_p): Removed.
1104 (is_simple_operand): Remove call to stmt_simple_memref_p.
1105 (stmt_simple_for_scop_p): Update call to is_simple_operand.
1107 2009-09-17 David Edelsohn <edelsohn@gnu.org>
1109 * testsuite/gcc.dg/graphite/interchange-mvt.c: New File.
1110 * testsuite/gcc.dg/graphite/scop-dsyrk.c: New File.
1111 * testsuite/gcc.dg/graphite/scop-dsyr2k.c: New File.
1112 * testsuite/gcc.dg/graphite/scop-mvt.c: New File.
1113 * testsuite/gcc.dg/graphite/scop-sor.c: New File.
1115 2009-09-17 Li Feng <nemokingdom@gmail.com>
1117 * graphite-dependences.c (poly_drs_may_alias_p): Adjust definition.
1118 (pddr_original_scattering): Make sure 2 pdr2 in the same base object set.
1119 (graphite_carried_dependence_level_k): Ditto.
1120 * graphite-poly.c (new_poly_dr): Add init of PDR_BASE_OBJECT_SET.
1121 * graphite-poly.h (struct poly_dr): Add member dr_base_object_set.
1122 (new_poly_dr): Adjust declaration.
1123 * graphite-sese-to-poly.c (free_data_refs_aux): New.
1124 (free_gimple_bb): Added free_data_refs_aux.
1125 (build_poly_dr): Add dr_base_object_set.
1126 (partition_drs_to_sets): New.
1127 (dr_same_base_object_p): New.
1128 (build_alias_set_for_drs): New.
1129 (build_base_object_set_for_drs): New.
1130 (build_scop_drs): Add build_base_obj_set_for_drs.
1131 * graphite-sese-to-poly.h: Added #define for alias set number index and
1132 base object set index.
1133 * libgomp/testsuite/libgomp.graphite/force-parallel-6.c: Refine tests.
1134 * libgomp/testsuite/libgomp.graphite/pr4118.c: New.
1136 2009-09-16 Alexander Monakov <amonakov@ispras.ru>
1138 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Add bounds only
1139 for ARRAY_REFs. Use array_ref_{low,up}_bound to determine bounds.
1141 2009-09-14 Sebastian Pop <sebastian.pop@amd.com>
1143 * graphite-sese-to-poly.c (struct irp_data): Removed.
1144 (idx_record_params): Removed.
1145 (find_params_in_bb): Scan for parameters the access functions; don't
1146 parse the tree representation.
1148 2009-09-14 Sebastian Pop <sebastian.pop@amd.com>
1150 * tree-ssa-loop.c (gate_graphite_transforms): Disable Graphite
1151 passes at -O1 and below.
1153 2009-09-14 Sebastian Pop <sebastian.pop@amd.com>
1155 * graphite-blocking.c: Fix order of includes: tree-chrec.h, then
1156 tree-scalar-evolution.h, and then tree-data-ref.h.
1157 * graphite-clast-to-gimple.c: Same.
1158 * graphite-dependences.c: Same.
1159 * graphite-interchange.c: Same.
1160 * graphite-poly.c: Same.
1161 * graphite-scop-detection.c: Same.
1162 * graphite-sese-to-poly.c: Same.
1164 * lambda-code.c: Same.
1165 * matrix-reorg.c: Same.
1166 * tree-data-ref.c: Same.
1167 * tree-if-conv.c: Same.
1168 * tree-loop-distribu: Same.: Same.
1169 * tree-loop-linear.c: Same.
1170 * tree-parloops.c: Same.
1171 * tree-predcom.c: Same.
1172 * tree-vect-patterns.c: Same.
1174 2009-09-02 Sebastian Pop <sebastian.pop@amd.com>
1176 Partially revert the previous patch, except the following.
1177 * tree-scalar-evolution.c (instantiate_scev_not): Adapted to pass
1178 as parameters the operands of the not expression.
1180 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1182 * tree-scalar-evolution.c (instantiate_scev_assign): New.
1183 Do not call analyze_scalar_evolution on assignments.
1184 (instantiate_scev_phi): Call analyze_scalar_evolution.
1185 (instantiate_scev_name): Call instantiate_scev_assign and
1186 instantiate_scev_phi.
1187 (instantiate_scev_not): Adapted to pass as parameters the operands
1188 of the not expression.
1190 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1192 * tree-scalar-evolution.c (instantiate_scev_binary): Adapted
1193 to pass as parameters the operands of the binary expression.
1195 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1197 * tree-scalar-evolution.c (instantiate_scev_bitnot): Renamed
1198 instantiate_scev_not. Handle NEGATE_EXPR.
1199 (instantiate_scev_r): Handle NEGATE_EXPR.
1201 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1203 * tree-scalar-evolution.c (instantiate_scev_1): Renamed
1205 (instantiate_scev_r): Move code in instantiate_scev_2
1206 and instantiate_scev_1.
1208 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1210 * tree-scalar-evolution.c (instantiate_scev_3): New.
1211 (instantiate_scev_1): Move code in instantiate_scev_3.
1213 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1215 * tree-scalar-evolution.c (instantiate_scev_poly): New.
1216 (instantiate_scev_1): Move code in instantiate_scev_poly.
1218 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1220 * tree-scalar-evolution.c (instantiate_scev_bitnot): New.
1221 (instantiate_scev_1): Move code in instantiate_scev_bitnot.
1223 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1225 * tree-scalar-evolution.c (instantiate_scev_convert): New.
1226 (instantiate_scev_1): Move code in instantiate_scev_convert.
1228 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1230 * tree-scalar-evolution.c (instantiate_scev_binary): New.
1231 (instantiate_scev_1): Move code in instantiate_scev_binary.
1233 2009-09-01 Sebastian Pop <sebastian.pop@amd.com>
1235 * tree-scalar-evolution.c (instantiate_scev_name): New.
1236 (instantiate_scev_1): Move code in instantiate_scev_name.
1238 2009-08-28 Sebastian Pop <sebastian.pop@amd.com>
1240 * Merge from mainline (150992:151171).
1242 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
1244 * opts.c (decode_options): Enable flag_loop_interchange at -O2.
1246 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
1248 * graphite-dependences.c (graphite_legal_transform_bb): Call
1249 pbb_remove_duplicate_pdrs.
1250 * graphite-poly.c (can_collapse_pdr): Removed.
1251 (pdr_find_duplicate): Removed.
1252 (can_collapse_pdrs): New.
1253 (pbb_remove_duplicate_pdrs): New.
1254 (new_poly_dr): Do not look for duplicates.
1255 * graphite-poly.h (struct poly_bb): New field pdr_duplicates_removed.
1256 (PBB_PDR_DUPLICATES_REMOVED): New.
1257 (pbb_remove_duplicate_pdrs): Declared.
1259 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
1261 * graphite-interchange.c (pbb_interchange_profitable_p): Adjust
1262 the strides by multiplying by PDR_NB_REFS.
1263 * graphite-poly.c (can_collapse_pdr): New.
1264 (pdr_find_duplicate): New.
1265 (new_poly_dr): Call pdr_find_duplicate. Collapse duplicate PDRs.
1266 Initialize PDR_NB_REFS.
1267 * graphite-poly.h (struct poly_dr): Add field nb_refs.
1269 (new_poly_dr): Number of subscripts is a graphite_dim_t.
1271 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
1273 Revert one of the previous commits:
1274 * graphite-dependences.c (graphite_legal_transform_bb): Avoid
1275 the computation of symmetric data dependence relations.
1276 (dependency_between_pbbs_p): Same.
1278 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
1281 * graphite-poly.c (apply_poly_transforms): Remove legality test before
1284 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
1286 * graphite-dependences.c (pddr_original_scattering): Return NULL
1287 for read-read dependence relations.
1288 * graphite-poly.h (enum poly_dr_type): Fix comment.
1291 (pdr_may_write_p): New.
1293 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
1295 * graphite-poly.h (enum POLY_DR_TYPE): Renamed poly_dr_type.
1296 (struct poly_dr): Same.
1297 (new_poly_dr): Same.
1298 * graphite-poly.c (new_poly_dr): Same.
1300 2009-08-25 Konrad Trifunovic <konrad.trifunovic@gmail.com>
1301 Sebastian Pop <sebastian.pop@amd.com>
1303 * graphite-blocking.c (pbb_strip_mine_loop_depth): Renamed
1304 pbb_strip_mine_time_depth. Changed the implementation so that
1305 transformation is expressed as a transformation on
1306 time (scatttering) dimensions. Also, ensures that the 2d+1
1307 scheduling format is preserved.
1308 (pbb_strip_mine_profitable_p): Profitability is based on the
1309 iteration number of a given time (scattering) dimension,
1310 and not on a original loop depth dimension.
1311 (pbb_strip_mine): Call pbb_number_of_iterations_at_time.
1312 (pbb_do_strip_mine): Call psct_dynamic_dim.
1313 * graphite-poly.c (pbb_number_of_iterations_at_time): New.
1314 * graphite-poly.h (pbb_number_of_iterations_at_time): Declared.
1315 (pbb_nb_dynamic_scattering_transform): New.
1316 (psct_dynamic_dim): New.
1318 2009-08-25 Konrad Trifunovic <konrad.trifunovic@gmail.com>
1320 * graphite-ppl.c (ppl_max_for_le): Renamed ppl_max_for_le_pointset.
1321 * graphite-ppl.h (ppl_max_for_le): Renamed ppl_max_for_le_pointset.
1322 * graphite-poly.c (pbb_number_of_iterations): Rename ppl_max_for_le.
1323 * graphite-interchange.c (build_linearized_memory_access): Same.
1324 (memory_stride_in_loop): Same.
1326 2009-08-25 Sebastian Pop <sebastian.pop@amd.com>
1328 * graphite-dependences.c (pddr_original_scattering): New.
1329 (graphite_legal_transform_dr): Call pddr_original_scattering.
1332 * graphite-dependences.h (dot_deps): Declared.
1333 * graphite-poly.c (new_poly_dr): Initialize PDR_ID.
1334 (print_pdr): Print PDR_ID.
1335 * graphite-poly.h (struct poly_dr): Add field id.
1338 * graphite-scop-detection.c (dot_all_scops_1): Cleanup comment.
1340 2009-08-22 Sebastian Pop <sebastian.pop@amd.com>
1342 * graphite-dependences.c (graphite_carried_dependence_level_k): Do
1343 not delete the original dependence relation.
1345 2009-08-21 Sebastian Pop <sebastian.pop@amd.com>
1347 * graphite-dependences.c (graphite_legal_transform_bb): Avoid
1348 the computation of symmetric data dependence relations.
1349 (dependency_between_pbbs_p): Same.
1351 2009-08-21 Sebastian Pop <sebastian.pop@amd.com>
1353 * graphite-dependences.c (new_poly_dr_pair): Renamed new_poly_ddr.
1354 (eq_poly_dr_pair_p): Renamed eq_poly_ddr_p.
1355 (hash_poly_dr_pair_p): Renamed hash_poly_ddr_p.
1356 (free_poly_ddr): New.
1357 (pddr_is_empty): New.
1358 (dependence_polyhedron_1): Now returns a poly_ddr_p.
1359 (dependence_polyhedron): Same. Remove useless gcc_assert.
1361 (graphite_legal_transform_dr): Call pddr_is_empty and free_poly_ddr.
1362 (graphite_carried_dependence_level_k): Call pddr_is_empty.
1363 * graphite-dependences.h (enum poly_dependence_kind): New.
1364 (poly_dr_pair): Renamed poly_ddr. Added a field kind.
1365 (PDRP_SOURCE): Renamed PDDR_SOURCE.
1366 (PDRP_SINK): Renamed PDDR_SINK.
1367 (PDRP_DDP): Renamed PDDR_DDP.
1369 (free_poly_ddr): Declared.
1370 * graphite-poly.c (new_scop): Use the new hash function names.
1371 * graphite-poly.h (struct scop): Renamed field original_pdr_pairs
1372 into original_pddrs.
1373 (SCOP_ORIGINAL_PDR_PAIRS): Renamed SCOP_ORIGINAL_PDDRS.
1375 2009-08-21 Sebastian Pop <sebastian.pop@amd.com>
1377 * Merge from mainline (150764:150992).
1379 2009-08-18 Sebastian Pop <sebastian.pop@amd.com>
1381 * cfgloopmanip.c (create_empty_loop_on_edge): Generate upper
1382 bounds with LT_EXPR to make niter analysis more precise on code
1383 generated by Graphite.
1385 2009-08-18 Sebastian Pop <sebastian.pop@amd.com>
1387 * graphite-dependences.c (graphite_legal_transform_dr): Fix formatting.
1388 (graphite_legal_transform_bb): Same.
1389 (poly_drs_may_alias_p): Same.
1391 2009-08-15 Sebastian Pop <sebastian.pop@amd.com>
1394 * graphite-ppl.c (ppl_max_for_le): Correct the use of
1395 ppl_Pointset_Powerset_C_Polyhedron_maximize.
1397 2009-08-13 Sebastian Pop <sebastian.pop@amd.com>
1399 * graphite-poly.c (print_pbb): Print PBB index.
1401 2009-08-13 Sebastian Pop <sebastian.pop@amd.com>
1403 * Merge from mainline (r150672:150764).
1405 2009-08-13 Sebastian Pop <sebastian.pop@amd.com>
1407 * graphite-interchange.c (ppl_max_for_le): Moved...
1408 * graphite-poly.c (pbb_number_of_iterations): Call ppl_max_for_le.
1409 * graphite-ppl.c (ppl_max_for_le): ... here.
1410 * graphite-ppl.h (ppl_max_for_le): Declared.
1412 2009-08-12 Sebastian Pop <sebastian.pop@amd.com>
1414 * Merge from mainline (r150372:150672).
1416 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
1419 * sese.c (convert_for_phi_arg): New.
1420 (add_guard_exit_phis): Use convert_for_phi_arg.
1422 * testsuite/gfortran.dg/graphite/id-17.f: New.
1424 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
1426 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Dont add
1427 unknown subscript upper bounds.
1429 * testsuite/gcc.dg/graphite/interchange-6.c: Un-XFAIL.
1431 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
1432 Pranav Garg <pranav.garg2107@gmail.com>
1434 * graphite-interchange.c (gather_access_strides): Removed.
1435 (ppl_max_for_le): New.
1436 (build_linearized_memory_access): New.
1437 (memory_stride_in_loop): New.
1438 (pbb_interchange_profitable_p): Reimplemented.
1439 * graphite-ppl.h (ppl_new_id_map): New.
1440 (ppl_interchange): New.
1442 * testsuite/gcc.dg/graphite/interchange-6.c: XFAILed.
1444 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
1446 * graphite-interchange.c (compute_subscript): Removed.
1447 (compute_array_size_cstr): Removed.
1448 (compute_array_size_poly): Removed.
1449 (compute_array_size): Removed.
1450 (gather_access_strides_poly): Removed.
1451 (gather_access_strides): Empty.
1453 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
1455 * graphite-dependences.c (dependence_polyhedron_1): Replace
1456 pdr_nb_subscripts with PDR_NB_SUBSCRIPTS.
1457 (graphite_legal_transform_dr): Same.
1458 (graphite_carried_dependence_level_k): Same.
1459 * graphite-poly.c (new_poly_dr): Add a parameter nb_subscripts.
1460 Initialize PDR_NB_SUBSCRIPTS.
1461 (print_pdr_access_layout): Replace pdr_nb_subscripts with
1463 * graphite-poly.h (struct poly_dr): Add nb_subscripts field.
1464 (PDR_NB_SUBSCRIPTS): New.
1465 (pdr_nb_subscripts): Removed.
1466 (pdr_dim): Simplified.
1467 * graphite-sese-to-poly.c (build_poly_dr): Replace pdr_nb_subscripts
1468 with PDR_NB_SUBSCRIPTS.
1470 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
1472 * graphite-interchange.c (compute_array_size): Remove use of
1474 * graphite-poly.c (new_poly_dr): Remove argument data_container.
1475 Do not initialize PDR_DATA_CONTAINER.
1476 (print_pdr): Do not print PDR_DATA_CONTAINER.
1477 * graphite-poly.h (struct poly_dr): Remove data_container field.
1478 (PDR_DATA_CONTAINER): Removed.
1479 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Remove use of
1481 (build_poly_dr): Same.
1483 2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
1485 * testsuite/gcc.dg/graphite/interchange-9.c: New.
1487 2009-08-05 Konrad Trifunovic <konrad.trifunovic@gmail.com>
1488 Sebastian Pop <sebastian.pop@amd.com>
1490 * graphite-dependences.c (graphite_legal_transform_dr): Work on a
1491 copy of the dependence polyhedron. Free the temporary objects.
1492 (graphite_carried_dependence_level_k): Free unused objects before
1495 * testsuite/gcc.dg/graphite/interchange-1.c: XFAILed.
1496 * testsuite/gcc.dg/graphite/interchange-2.c: XFAILed.
1497 * testsuite/gcc.dg/graphite/interchange-3.c: XFAILed.
1498 * testsuite/gcc.dg/graphite/interchange-4.c: XFAILed.
1499 * testsuite/gcc.dg/graphite/interchange-7.c: XFAILed.
1501 2009-08-05 Sebastian Pop <sebastian.pop@amd.com>
1503 * graphite-blocking.c (scop_do_strip_mine): Call store_scattering.
1504 Early return without analyzing the data dependences if no
1505 transform has been done. Call restore_scattering if the transform
1507 (graphite-interchange.c): Same.
1508 * graphite-poly.c (print_scattering_function): Test for PBB_TRANSFORMED.
1509 (graphite_read_transforms): Initialize PBB_TRANSFORMED.
1510 (apply_poly_transforms): Do not gcc_assert that
1511 the transform is legal.
1512 (new_poly_bb): Initialize PBB_TRANSFORMED, PBB_SAVED, and PBB_ORIGINAL.
1513 Do not initialize PBB_NB_SCATTERING_TRANSFORM, PBB_NB_LOCAL_VARIABLES,
1514 PBB_TRANSFORMED_SCATTERING, and PBB_ORIGINAL_SCATTERING.
1515 (free_poly_dr): Free PBB_TRANSFORMED, PBB_SAVED, and PBB_ORIGINAL.
1516 * graphite-poly.h (struct poly_scattering): New.
1517 (struct poly_bb): Add original, transformed, and saved fields.
1518 Remove transformed_scattering, original_scattering, nb_local_variables,
1519 and nb_scattering_transform fields.
1520 (PBB_ORIGINAL, PBB_TRANSFORMED, PBB_SAVED): New.
1521 (poly_scattering_new): New.
1522 (poly_scattering_free): New.
1523 (poly_scattering_copy): New.
1524 (store_scattering_pbb): New.
1525 (store_scattering): New.
1526 (restore_scattering_pbb): New.
1527 (restore_scattering): New.
1528 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons):
1529 Initialize PBB_TRANSFORMED and PBB_ORIGINAL.
1531 2009-08-05 Sebastian Pop <sebastian.pop@amd.com>
1533 * graphite-poly.c (print_pbb): Add parentheses in the pretty print.
1536 2009-08-05 Sebastian Pop <sebastian.pop@amd.com>
1538 * Makefile.in (graphite.o): Depends on PREDICT_H.
1539 * graphite.c: Include predict.h.
1540 (graphite_finalize): Call tree_estimate_probability.
1541 * predict.c (predict_loops): Do not call scev_initialize and
1543 (tree_estimate_probability_bb): New.
1544 (tree_estimate_probability): Do not initialize loops: move that
1545 code to the driver. Call tree_estimate_probability_bb.
1546 (tree_estimate_probability_driver): New.
1547 (pass_profile): Use tree_estimate_probability_driver.
1548 * predict.h (tree_estimate_probability): Declared.
1550 2009-08-05 Sebastian Pop <sebastian.pop@amd.com>
1552 * graphite-clast-to-gimple.c (gloog): Add time to TV_GRAPHITE_CODE_GEN.
1553 * graphite-dependences.c (graphite_legal_transform): Add time to
1554 TV_GRAPHITE_DATA_DEPS.
1555 (dependency_between_pbbs_p): Same.
1556 * timevar.def (TV_GRAPHITE_DATA_DEPS, TV_GRAPHITE_CODE_GEN): New.
1558 2009-08-03 Sebastian Pop <sebastian.pop@amd.com>
1560 * Merge from mainline (r149952:150372).
1562 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
1564 * ChangeLog.graphite: Fix indenting, white spaces and 80 columns.
1565 * graphite-blocking.c: Same.
1566 * graphite-clast-to-gimple.c: Same.
1567 * graphite-dependences.c: Same.
1568 * graphite-poly.c: Same.
1569 * graphite-poly.h: Same.
1570 * graphite-ppl.c: Same.
1571 * graphite-scop-detection.c: Same.
1572 * graphite-sese-to-poly.c: Same.
1575 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
1577 * graphite-sese-to-poly.c (loop_entry_phi_arg): New.
1578 (remove_simple_copy_phi): New.
1579 (remove_invariant_phi): New.
1580 (simple_copy_phi_p): New.
1581 (reduction_phi_p): New.
1582 (gsi_for_ssa_name_def): New.
1583 (insert_out_of_ssa_copy): New.
1584 (insert_out_of_ssa_copy_on_edge): New.
1585 (create_zero_dim_array): New.
1586 (scalar_close_phi_node_p): New.
1587 (rewrite_close_phi_out_of_ssa): New.
1588 (rewrite_phi_out_of_ssa): New.
1589 (rewrite_reductions_out_of_ssa): New.
1590 (build_poly_scop): Call rewrite_reductions_out_of_ssa.
1592 * testsuite/gcc.dg/graphite/id-11.c: New.
1593 * testsuite/gcc.dg/graphite/id-15.c: New.
1594 * testsuite/gcc.dg/graphite/interchange-1.c: Un-XFAIL.
1595 * testsuite/gcc.dg/graphite/interchange-2.c: Un-XFAIL.
1596 * testsuite/gcc.dg/graphite/interchange-3.c: Un-XFAIL.
1597 * testsuite/gcc.dg/graphite/interchange-4.c: Un-XFAIL.
1598 * testsuite/gcc.dg/graphite/interchange-7.c: Un-XFAIL.
1599 * testsuite/gcc.dg/graphite/scop-matmult.c: Un-XFAIL.
1600 * testsuite/gfortran.dg/graphite/id-13.f: New.
1601 * testsuite/gfortran.dg/graphite/id-5.f: New.
1603 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
1605 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not
1606 check that nb_reductions_in_loop is zero.
1607 * graphite-scop-detection.c (harmful_stmt_in_bb): Don't filter out
1608 reduction phi nodes.
1609 (nb_reductions_in_loop): Removed.
1610 (graphite_can_represent_loop): Do not call nb_reductions_in_loop.
1611 * graphite-sese-to-poly.c (phi_node_is_iv): Removed.
1612 (bb_contains_non_iv_scalar_phi_nodes): Removed.
1613 (scop_contains_non_iv_scalar_phi_nodes): Removed.
1614 (build_poly_scop): Do not call scop_contains_non_iv_scalar_phi_nodes.
1616 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
1618 * graphite-clast-to-gimple.c (build_cloog_prog): Do not code generate
1619 statements that have an empty iteration domain.
1620 * testsuite/gfortran.dg/graphite/id-16.f: New.
1622 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
1624 * tree-scalar-evolution.c (instantiate_scev_1): Return
1625 chrec_dont_know when the result is not above instantiate_below.
1626 * graphite-scop-detection.c (scopdet_basic_block_info): Fix formatting.
1627 * graphite-sese-to-poly.c (create_linear_expr_from_tree): Assert that
1628 the tree has a known scalar evolution.
1629 * testsuite/gfortran.dg/graphite/id-14.f: New.
1630 * testsuite/gfortran.dg/graphite/id-15.f: New.
1632 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
1634 * sese.c (rename_variables_in_stmt): Pass in an extra parameter
1636 (rename_variables): Keep inserting renames after the ones already
1639 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
1641 * graphite-sese-to-poly.c (compare_bb_depths): New.
1642 (graphite_sort_dominated_info): New.
1643 (build_scop_bbs_1): Call graphite_sort_dominated_info.
1644 (build_scop_scattering): Fix comment.
1646 2009-07-28 Sebastian Pop <sebastian.pop@amd.com>
1648 * graphite.c (graphite_finalize): Call print_loops instead of
1649 dump_function_to_file.
1650 * testsuite/gcc.dg/graphite/graphite.exp: Fix formatting.
1651 * testsuite/gcc.dg/graphite/pr35356-1.c: New. Look for the number of
1652 loops generated in the graphite output file.
1653 * testsuite/gcc.dg/graphite/pr35356-2.c: New.
1654 * testsuite/gcc.dg/graphite/pr35356-3.c: New. XFAILed for now.
1655 * testsuite/gfortran.dg/graphite/id-12.f: New.
1657 2009-07-24 Li Feng <nemokingdom@gmail.com>
1659 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-8.c:
1662 2009-07-24 Li Feng <nemokingdom@gmail.com>
1663 Tobias Grosser <grosser@fim.uni-passau.de>
1665 * graphite-sese-to-poly.c (pdr_add_alias_set): Use data reference's
1666 alias set number build alias in ACCESSES polyhedron.
1667 (build_alias_set_for_drs): New.
1668 (build_pbb_drs): Added build_alias_set_for_drs.
1669 * graphite-dependences.c (poly_drs_may_alias_p): New.
1670 (graphite_carried_dependence_level_k): Check alias information
1671 before building polyhedron.
1673 2009-07-24 Tobias Grosser <grosser@fim.uni-passau.de>
1675 * Makefile.in (lambda-code.o): Fix formatting.
1677 2009-07-24 Tobias Grosser <grosser@fim.uni-passau.de>
1679 * Merge from mainline (r149350-149952)
1681 2009-07-18 Tobias Grosser <grosser@fim.uni-passau.de>
1683 * graphite-poly.c (apply_poly_transforms): Move strip_mine
1684 before interchange to prepare for loop blocking.
1686 2009-07-18 Tobias Grosser <grosser@fim.uni-passau.de>
1688 * graphite-poly.c (apply_poly_transforms): Add checks after every
1690 * graphite-sese-to-poly.c (build_poly_scop): Remove check, as already
1691 done in apply_poly_transforms.
1693 2009-07-17 Konrad Trifunovic <konrad.trifunovic@gmail.com>
1695 * graphite-dependences.c (build_lexicographically_gt_constraint):
1696 Replace RES parameter with *RES.
1697 (dependence_polyhedron_1): Pass an address of the parameter RES
1698 instead of value of RES.
1700 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
1702 * graphite.c (graphite_finalize): Fix comment.
1703 (graphite_transform_loops): Reset scev info after code generation
1706 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
1708 * graphite.c (graphite_finalize): Call scev_reset.
1710 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
1712 * graphite-clast-to-gimple.c (compute_cloog_iv_types): Do not create
1713 GBB_CLOOG_IV_TYPES hash table twice.
1714 * graphite-sese-to-poly.c (free_gimple_bb): Call free_data_refs.
1715 (add_condition_to_domain): Clear GMP values.
1717 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
1719 * graphite-dependences.c: Fix formatting.
1720 * graphite-poly.c (free_poly_dr): Also free PDR_DATA_CONTAINER.
1721 (pbb_number_of_iterations): Free ppl_Linear_Expression.
1722 * graphite-sese-to-poly.c: Fix formatting.
1723 * graphite.c (graphite_transform_loops): Create the hash table
1724 after the early return.
1726 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
1728 * testsuite/gcc.dg/graphite/id-14.c: New.
1729 * testsuite/gcc.dg/graphite/pr40157.c: New.
1730 * testsuite/gfortran.dg/graphite/id-11.f: New.
1732 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
1734 * graphite-sese-to-poly.c (nb_pbbs_in_loops): New.
1735 (build_poly_scop): Return false when there are no pbbs within
1736 loops to avoid to pass to cloog scops with no loops.
1738 2009-07-16 Sebastian Pop <sebastian.pop@amd.com>
1740 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons): Avoid
1741 useless test "i % 2".
1742 (build_pbb_scattering_polyhedrons): Fix formatting.
1743 (build_poly_dr): Same.
1744 * graphite.c (graphite_transform_loops): Restructure.
1746 2009-07-14 Razya Ladelsky <razya@il.ibm.com>
1748 * tree-ssa-loop-manip.c (rewrite_phi_with_iv): Remove
1749 reduction_list parameter.
1750 (rewrite_all_phi_nodes_with_iv): Same.
1751 (canonicalize_loop_ivs): Same.
1752 * tree-parloops.c (struct brli): Removed.
1753 (build_reduction_list_info): Removed.
1754 (build_new_reduction): New.
1755 (analyze_reduction_list): Removed.
1756 (gather_scalar_reductions): Find reductions instead of phi
1757 nodes that can't be canonicalized.
1758 (try_create_reduction_list): Remove reduction_list parameter.
1759 (gen_parallel_loop): Same.
1760 (parallelize_loops): Remove analyze_reductions variable,
1761 initialization and free.
1762 Change reduction_list htab initialization to reduction_info
1763 elements instead of ssa names.
1764 Call try_create_reduction_list and gen_parallel_loop without
1765 analyzed_reduction argument.
1766 * graphite-clast-to-gimple (graphite_loop_normal_form): Call
1767 canonicalize_loop_ivs with one less argument.
1768 * tree-flow.h (canonicalize_loop_ivs): Remove one argument.
1770 2009-07-14 Konrad Trifunovic <konrad.trifunovic@gmail.com>
1772 * graphite-dependences.c (new_poly_dr_pair): New.
1773 (dependence_polyhedron): Renamed into dependence_polyhedron_1.
1774 (new_poly_dr_pair): New.
1775 (eq_poly_dr_pair_p): New.
1776 (hash_poly_dr_pair_p): New.
1777 * graphite-dependences.h (struct poly_dr_pair): New.
1778 (eq_poly_dr_pair_p): Declared.
1779 (hash_poly_dr_pair_p): Declared.
1780 * graphite-poly.c (new_scop): Initialize SCOP_ORIGINAL_PDR_PAIRS.
1781 (free_scop): Free SCOP_ORIGINAL_PDR_PAIRS.
1782 * graphite-poly.h (struct scop): Add original_pdr_pairs field.
1783 * Makefile.in (graphite-poly.o): Add dependence on
1784 graphite-dependences.h.
1786 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
1788 * graphite-scop-detection.c (graphite_can_represent_scev): Do not let
1789 polynomials of degree > 1 pass to Graphite.
1790 * tree-chrec.c (scev_is_linear_expression): Call
1791 evolution_function_is_affine_multivariate_p.
1792 * testsuite/gfortran.dg/graphite/id-10.f90: New.
1794 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
1796 * tree-scalar-evolution.c (compute_overall_effect_of_inner_loop):
1797 Instantiate scevs varying in outer loops.
1798 * testsuite/gfortran.dg/graphite/id-9.f: Correct testcase.
1800 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
1802 * graphite-sese-to-poly.c (build_loop_iteration_domains): Do not insert
1803 redundant constraint.
1805 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
1807 * testsuite/gcc.dg/graphite/graphite.exp: Fix comments.
1808 * testsuite/gfortran.dg/graphite/graphite.exp: Trigger actions
1809 based on the file names as in the C testsuite.
1810 * testsuite/gfortran.dg/graphite/block-1.f90: Fix patterns.
1811 * testsuite/gfortran.dg/graphite/block-2.f: Same.
1812 * testsuite/gfortran.dg/graphite/block-3.f90: Same.
1813 * testsuite/gfortran.dg/graphite/block-4.f90: Same.
1814 * testsuite/gfortran.dg/graphite/id-1.f90: Same.
1815 * testsuite/gfortran.dg/graphite/id-2.f90: Same.
1816 * testsuite/gfortran.dg/graphite/id-3.f90: Same.
1817 * testsuite/gfortran.dg/graphite/id-4.f90: Same.
1818 * testsuite/gfortran.dg/graphite/id-6.f: Same.
1819 * testsuite/gfortran.dg/graphite/id-9.f: Same.
1820 * testsuite/gfortran.dg/graphite/interchange-1.f: Same.
1821 * testsuite/gfortran.dg/graphite/interchange-2.f: Same.
1822 * testsuite/gfortran.dg/graphite/scop-1.f: Same.
1824 2009-07-14 Sebastian Pop <sebastian.pop@amd.com>
1826 * sese.c (expand_scalar_variables_call): New.
1827 (expand_scalar_variables_ssa_name): Handle calls in expander.
1829 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
1831 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-6.c:
1832 Expect to see the pattern twice.
1833 * testsuite/gcc.dg/graphite/interchange-0.c: Un-XFAIL.
1834 * testsuite/gcc.dg/graphite/interchange-5.c: Same.
1835 * testsuite/gcc.dg/graphite/interchange-6.c: Same.
1837 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
1839 * testsuite/gcc.dg/graphite/id-10.c: New.
1840 * testsuite/gcc.dg/graphite/id-12.c: New.
1841 * testsuite/gfortran.dg/graphite/id-7.f: New.
1842 * testsuite/gfortran.dg/graphite/id-8.f: New.
1844 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
1846 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Fix division by
1849 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
1851 * sese.c (rename_variables_in_stmt): Call fold_convert during renaming.
1853 2009-07-13 Sebastian Pop <sebastian.pop@amd.com>
1855 * sese.c (expand_scalar_variables_stmt): Avoid unnecessary expansion.
1857 2009-07-10 Sebastian Pop <sebastian.pop@amd.com>
1859 * graphite-sese-to-poly.c (pdr_add_memory_accesses): Fix order of
1860 building PDR subscripts.
1862 2009-07-10 Sebastian Pop <sebastian.pop@amd.com>
1864 * graphite-sese-to-poly.c (pdr_add_data_dimensions): Fix the
1865 computation of array sizes.
1867 2009-07-10 Sebastian Pop <sebastian.pop@amd.com>
1869 * graphite-sese-to-poly.c (add_param_constraints): Disabled.
1871 2009-07-10 Tobias Grosser <grosser@fim.uni-passau.de>
1873 * graphite-dependences.c (map_into_dep_poly, map_dr_into_dep_poly,
1874 build_pairwise_constraint, dr_equality_constraints,
1875 build_pairwise_scheduling_equality,
1876 build_pairwise_scheduling_inequality, lexicographically_gt_p,
1877 build_lexicographically_gt_constraint, dependence_polyhedron,
1878 graphite_legal_transform_dr, graphite_carried_dependence_level_k):
1879 Move from NNC_Polyhedron to C_Polyhedron.
1880 * graphite-interchange.c (compute_array_size_poly,
1881 gather_access_strides): Dito.
1882 * graphite-poly.c (apply_poly_transforms, new_poly_dr, free_poly_bb,
1883 free_scop, pbb_number_of_iterations): Dito.
1884 * graphite-poly.h (struct poly_dr, pdr_nb_subscripts, struct poly_bb,
1885 pbb_dim_iter_domain, struct scop): Dito.
1886 * graphite-ppl.c (new_Constraint_System_from_Cloog_Matrix,
1887 new_Cloog_Domain_from_ppl_Polyhedron,
1888 new_Cloog_Domain_from_ppl_Pointset_Powerset, ppl_set_coef_gmp,
1889 ppl_insert_dimensions_pointset, ppl_insert_dimensions_pointset,
1890 ppl_strip_loop, ppl_strip_loop, ppl_print_polyhedron_matrix,
1891 ppl_print_powerset_matrix, debug_ppl_polyhedron_matrix,
1892 debug_ppl_powerset_matrix, ppl_read_polyhedron_matrix): Dito.
1893 * graphite-ppl.h (ppl_Pointset_Powerset_C_Polyhedron_t,
1894 new_C_Polyhedron_from_Cloog_Matrix, ppl_print_powerset_matrix,
1895 debug_ppl_powerset_matrix, ppl_insert_dimensions_pointset): Dito.
1896 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons,
1897 build_loop_iteration_domains, ppl_constraint_type_from_tree_code,
1898 add_condition_to_domain, add_condition_to_pbb, build_scop_context,
1899 build_scop_iteration_domain, build_poly_dr): Dito
1901 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1903 * testsuite/gcc.dg/graphite/graphite.exp: Added a rule to execute
1905 * testsuite/gcc.dg/graphite/run-id-1.c: New.
1907 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1909 * graphite-sese-to-poly.c (build_loop_iteration_domains): Add the
1910 positivity constraint on the symbolic number of iterations.
1912 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1914 * graphite-sese-to-poly.c (build_loop_iteration_domains): Rewrite.
1916 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1917 Tobias Grosser <grosser@fim.uni-passau.de>
1919 * graphite-clast-to-gimple.c (build_scop_context): Removed.
1920 (build_cloog_prog): Directly use SCOP_CONTEXT.
1921 * graphite-poly.c (new_scop): Initialize SCOP_CONTEXT.
1922 (free_scop): Free SCOP_CONTEXT.
1923 (print_scop_context): New.
1924 (print_scop): Call print_scop_context.
1925 (debug_scop_context): New.
1926 * graphite-poly.h (print_scop_context, debug_scop_context): Declared.
1927 (struct scop): Added field context.
1928 (SCOP_CONTEXT): New.
1929 * graphite-sese-to-poly.c (add_param_constraints): New.
1930 (build_scop_context): New.
1931 (build_poly_scop): Call build_scop_context.
1933 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1935 * graphite-clast-to-gimple.c (gmp_cst_to_tree): Moved...
1936 * graphite-ppl.c (ppl_set_inhomogeneous_gmp, ppl_set_coef_gmp): New.
1937 (ppl_set_inhomogeneous, ppl_set_coef): Moved...
1938 * graphite-ppl.h: Include double-int.h and tree.h.
1939 (ppl_set_inhomogeneous_gmp, ppl_set_coef_gmp): Declared.
1940 (ppl_set_inhomogeneous, ppl_set_coef): ...here.
1941 (gmp_cst_to_tree): ...here. Reimplemented using mpz_get_double_int.
1942 (tree_int_to_gmp, ppl_set_inhomogeneous_tree, ppl_set_coef_tree): New.
1944 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1946 * graphite-clast-to-gimple.c (clast_to_gcc_expression_red): Generate
1947 POINTER_PLUS_EXPR for pointer types.
1948 (clast_to_gcc_expression): Same.
1950 2009-07-09 Sebastian Pop <sebastian.pop@amd.com>
1952 * graphite-poly.c (print_scattering_function): Early return when
1953 PBB_TRANSFORMED_SCATTERING is not initialized.
1954 (print_pbb_domain): Early return when PBB_DOMAIN is not initialized.
1956 2009-07-08 Sebastian Pop <sebastian.pop@amd.com>
1958 * tree-parloops.c (analyze_reduction_list): Remove unused variable
1961 2009-07-08 Razya Ladelsky <razya@il.ibm.com>
1963 * tree-parloops.c (analyze_reduction_list): Change return
1965 (try_create_reduction_list): Move the call to
1966 analyze_reduction_list to the beginining.
1967 Call reduction_phi with analyzed_reductions as argument
1968 instead of reduction_list.
1970 2009-07-08 Tobias Grosser <grosser@fim.uni-passau.de>
1972 * Merge from mainline (r148296:149346)
1974 2009-07-07 Sebastian Pop <sebastian.pop@amd.com>
1976 * graphite-scop-detection.c (graphite_can_represent_init): New.
1977 (graphite_can_represent_scev): Call graphite_can_represent_init:
1978 check that the initial value does not contain multiplications of
1980 (stmt_has_simple_data_refs_p): New.
1981 (stmt_simple_for_scop_p): Call stmt_simple_for_scop_p.
1982 (is_simple_operand): Fix formatting.
1983 * graphite-sese-to-poly.c (try_generate_gimple_bb): Fix formatting.
1985 2009-07-07 Sebastian Pop <sebastian.pop@amd.com>
1987 * testsuite/gcc.dg/graphite/id-13.c: New.
1988 * graphite-sese-to-poly.c (graphite_stmt_p): Do not call
1989 analyze_scalar_evolution, use scalar_evolution_in_region.
1990 (scan_tree_for_params_right_scev): Add extra assert.
1991 (parameter_index_in_region_1): Split from parameter_index_in_region.
1992 (idx_record_params): Use scalar_evolution_in_region.
1993 (find_params_in_bb): Same.
1994 (find_scop_parameters): Same.
1995 (build_loop_iteration_domains): Same.
1996 (create_linear_expr_from_tree): Same.
1997 * sese.c (scalar_evolution_in_region): New.
1998 * sese.h (scalar_evolution_in_region): Declared.
1999 (defined_in_sese_p): New.
2000 * tree-scalar-evolution.c (compute_overall_effect_of_inner_loop): Not
2002 * tree-scalar-evolution.h (compute_overall_effect_of_inner_loop):
2005 2009-07-07 Sebastian Pop <sebastian.pop@amd.com>
2007 * Makefile.in: Replace dependences on tree-chrec.h with SCEV_H.
2008 TREE_DATA_REF_H also implies SCEV_H.
2010 2009-07-07 Sebastian Pop <sebastian.pop@amd.com>
2012 * graphite-poly.c (print_scop_params): New.
2013 (print_scop): Call print_scop_params.
2014 (debug_scop_params): New.
2015 * graphite-poly.h (print_scop_params, debug_scop_params): Declared.
2017 2009-07-07 Li Feng <nemokingdom@gmail.com>
2019 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-4.c: New.
2020 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-5.c: New.
2021 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-6.c: New.
2022 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-7.c: New.
2023 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-8.c: New.
2024 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-9.c: New.
2026 2009-07-07 Li Feng <nemokingdom@gmail.com>
2028 * graphite-clast-to-gimple.c (mark_loops_parallel): Dump information
2029 for dependency checking part.
2030 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-1.c: Add
2031 tests for dependency checking.
2032 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-2.c: Ditto.
2033 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-3.c: Ditto.
2034 * testsuite/gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: Add
2035 flag -fdump-tree-graphite-all for autopar testsuites.
2037 2009-07-06 Sebastian Pop <sebastian.pop@amd.com>
2039 * Makefile.in (tree-ssa-loop-manip.o): Depends on langhooks.h.
2040 * tree-parloops.c (rewrite_phi_with_iv, rewrite_all_phi_nodes_with_iv,
2041 canonicalize_loop_ivs): Moved...
2042 * tree-ssa-loop-manip.c: ... here. Include langhooks.h.
2044 2009-07-06 Sebastian Pop <sebastian.pop@amd.com>
2046 * tree-parloops.c (try_create_reduction_list): Pass an extra
2047 argument analyzed_reductions. Call analyze_reduction_list.
2048 (gen_parallel_loop): Do not call analyze_reduction_list.
2049 (parallelize_loops): Init and finalize analyzed_reductions.
2051 2009-07-06 Li Feng <nemokingdom@gmail.com>
2053 * testsuite/gcc.dg/graphite/graphite_autopar/graphite_autopar.exp:
2054 Added flag -fno-loop-strip-mine for autopar testcase.
2056 2009-07-04 Li Feng <nemokingdom@gmail.com>
2058 * graphite-dependences.c (graphite_carried_dependence_level_k): Use
2059 transformed scattering dimension instead of unmatch orignal when
2060 calling dependence_polyhedron.
2062 2009-06-30 Sebastian Pop <sebastian.pop@amd.com>
2064 * opts.c (decode_options): Enable flag_loop_strip_mine at -O2.
2066 2009-06-30 Sebastian Pop <sebastian.pop@amd.com>
2068 * graphite-poly.c (pbb_number_of_iterations): Check for returned
2069 value 1 from ppl_Pointset_Powerset_NNC_Polyhedron_maximize.
2071 2009-06-30 Sebastian Pop <sebastian.pop@amd.com>
2073 * graphite-blocking.c (pbb_strip_mine_profitable_p): New.
2074 (pbb_do_strip_mine): Call pbb_strip_mine_profitable_p.
2075 * graphite-poly.c (pbb_number_of_iterations): New.
2076 * graphite-poly.h (pbb_number_of_iterations): Declared.
2077 (pbb_iterator_dim, pbb_parameter_dim): New.
2079 2009-06-29 Sebastian Pop <sebastian.pop@amd.com>
2081 * graphite-clast-to-gimple.c (graphite_create_new_loop): Revert the
2082 last commit on type of lower and upper bound of loops.
2084 2009-06-29 Li Feng <nemokingdom@gmail.com>
2086 * Makefile.in (graphite-clast-to-gimple.o): Added dependence on
2087 graphite-dependences.h.
2088 * graphite-clast-to-gimple.c (new_bb_pbb_def): New.
2089 (mark_bb_with_pbb): New.
2090 (get_stmtfor_depth): New.
2091 (find_pbb_via_hash): New.
2092 (dependency_in_loop_p): New.
2093 (mark_loops_parallel): New.
2094 (free_aux_in_new_loops): New.
2095 (translate_clast): Add parameter BB_PBB_MAPPING. Mark newly created
2096 bb with it's relevant pbb. Mark newly created loops. Remove mark
2097 innermost loop parallel without checking.
2098 (gloog): Add parameter BB_PBB_MAPPING.
2099 * graphite-clast-to-gimple.h (struct bb_pbb_def): New.
2100 (gloog): Change declaration.
2101 (mark_loop_parallel): Make extern.
2102 (free_aux_in_new_loops): Declare.
2103 (bb_pbb_map_hash): New.
2104 (eq_bb_pbb_map): New.
2105 * graphite.c (graphite_transform_loops): Added BB_PBB_MAPPING. Trigger
2106 auto parallelization when flag_graphite_force_parallel is set.
2107 (graphite_finalize): Added free_aux_in_new_loops.
2108 * tree-parloops.c (parallelize_loops): Only generate parallel code for
2109 the innermost loop that marked parallel. Use
2110 flag_graphite_force_parallel instead of loop->can_be_parallel.
2111 (loop_parallel_p): Move inner most checking out of function.
2113 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2115 * graphite-clast-to-gimple.c (graphite_create_new_loop): Make the
2116 type of lower and upper bound of loops signed long int.
2118 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2120 * cfgloopmanip.c (create_empty_loop_on_edge): Gimplify the loop exit
2121 expression outside the loop.
2123 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2125 * gcc.dg/graphite/interchange-8.c: New.
2127 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2129 * gcc.dg/graphite/interchange-0.c: XFailed.
2130 * gcc.dg/graphite/interchange-5.c: XFailed.
2131 * gcc.dg/graphite/interchange-6.c: XFailed.
2133 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2135 * graphite-interchange.c (compute_array_size_poly): The end of the
2136 recursion should return 1.
2138 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2140 * graphite-interchange.c (compute_array_size_cstr): Allow the
2141 subscript multiplier to be -1.
2142 (compute_array_size): Use PDR_DATA_CONTAINER and not PDR_ACCESSES.
2143 * graphite-poly.c (new_poly_dr): Takes an extra argument for the
2144 data_container. Initializes PDR_DATA_CONTAINER.
2145 (print_pdr_access_layout): New.
2146 (print_pdr): Call print_pdr_access_layout. Print PDR_DATA_CONTAINER.
2147 * graphite-poly.h (struct poly_dr): Adjust comment. Add a new field
2149 (PDR_DATA_CONTAINER): New.
2150 (new_poly_dr): Update declaration.
2151 * graphite-sese-to-poly.c (pdr_add_data_dimensions): New.
2152 (build_poly_dr): Call pdr_add_data_dimensions.
2154 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2156 * graphite-poly.h (struct poly_dr): Fix comment.
2157 * graphite-sese-to-poly.c (pdr_add_alias_set): New.
2158 (pdr_add_memory_accesses): New.
2159 (build_poly_dr): Call pdr_add_memory_accesses and pdr_add_alias_set.
2161 2009-06-26 Sebastian Pop <sebastian.pop@amd.com>
2163 * graphite-poly.c (print_pdrs, debug_pdrs): New.
2164 (print_pbb): Add call to print_pdrs.
2165 * graphite-poly.h (print_pdrs, debug_pdrs): Declared.
2167 2009-06-24 Konrad Trifunovic <konrad.trifunovic@gmail.com>
2168 Li Feng <nemokingdom@gmail.com>
2170 * graphite-dependences.c (graphite_carried_dependence_level_k): New.
2171 (dependency_between_pbbs_p): New.
2172 (lexicographically_gt_p): Assure !empty_p before polyhedron
2173 intersection assign.
2174 (build_lexicographically_gt_constraint): Correct lexicographically
2176 * graphite-dependences.h: New.
2177 * Makefile.in (graphite-dependences.o): Add graphite-dependences.h.
2179 2009-06-24 Sebastian Pop <sebastian.pop@amd.com>
2181 * graphite-clast-to-gimple.c (print_clast_stmt): New.
2182 (gloog): Print to dump_file the generated clast.
2183 * graphite-clast-to-gimple.h (print_clast_stmt): Declared.
2184 * graphite-interchange.c (pbb_do_interchange): Fix dump formatting.
2186 2009-06-24 Sebastian Pop <sebastian.pop@amd.com>
2188 * graphite-poly.c (extend_scattering): Increment
2189 PBB_NB_LOCAL_VARIABLES by the number of added dimensions.
2191 2009-06-24 Sebastian Pop <sebastian.pop@amd.com>
2193 * graphite-interchange.c (compute_array_size_poly): Added exit of
2194 recursion condition. Continue iterating even after the first equality.
2195 (compute_array_size): Same.
2197 2009-06-24 Li Feng <nemokingdom@gmail.com>
2199 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-1.c: Update
2200 -fdump-tree-final_cleanup to -fdump-tree-optimized.
2201 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-2.c: Ditto.
2202 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-3.c: Ditto.
2203 * testsuite/gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: Ditto.
2205 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2207 * sese.c (expand_scalar_variables_stmt): Expand scalar variables
2208 only when the use verifies is_gimple_reg.
2210 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2212 * graphite-clast-to-gimple.c (build_cloog_prog): Fix memory corruption.
2213 Allocate scaldims after call to unify_scattering_dimensions.
2215 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2217 * graphite-clast-to-gimple.c (translate_clast): Fix memory leak.
2219 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2220 Albert Cohen <albert.cohen@inria.fr>
2222 * graphite-blocking.c (pbb_strip_mine_loop_depth): Do not use local
2223 variables for the strip mining.
2225 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2226 Pranav Garg <pranav.garg2107@gmail.com>
2228 * Makefile.in (OBJS-common): Added graphite-blocking.o.
2229 (graphite-sese-to-poly.o): Moved down to be in lexicographical order.
2230 (graphite-blocking.o): New rule.
2231 (graphite-poly.o, graphite-ppl.o): Moved to be in lexicographical order.
2232 * graphite-blocking.c: New.
2233 * graphite-poly.c (apply_poly_transforms): Call scop_do_strip_mine for
2234 flag_loop_strip_mine.
2235 (psct_scattering_dim_for_loop_depth): New.
2236 * graphite-poly.h (scop_do_strip_mine): Declared.
2237 (psct_add_local_variable): Increment PBB_NB_LOCAL_VARIABLES.
2238 * tree-ssa-loop.c (gate_graphite_transforms): Do not fail when using
2239 flag_loop_strip_mine.
2241 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2243 * graphite-poly.c (extend_scattering): Avoid initializing and freeing
2244 a GMP value and a PPL coefficient at each iteration of a loop.
2246 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2248 * graphite-dependences.c (dependence_polyhedron): Do not use
2249 pbb_nb_scattering_dims anymore. Use pbb_nb_scattering_orig and
2250 pbb_nb_scattering_transform.
2251 (graphite_legal_transform_dr): Same.
2252 * graphite-poly.c (extend_scattering): Same.
2253 (unify_scattering_dimensions): Same.
2254 (print_scattering_function): Same.
2255 (new_poly_bb): Initialize PBB_NB_SCATTERING_TRANSFORM and
2256 PBB_NB_LOCAL_VARIABLES.
2257 * graphite-poly.h (pbb_nb_scattering): Removed declaration.
2258 (struct poly_bb): Added nb_local_variables and nb_scattering_transform.
2259 (PBB_NB_LOCAL_VARIABLES, PBB_NB_SCATTERING_TRANSFORM): New.
2260 (pbb_nb_scattering_orig, pbb_nb_scattering_transform): New.
2261 (pbb_nb_scattering_dims, pbb_nb_scattering): Removed.
2262 (pbb_nb_scattering_transform): New.
2263 (pbb_nb_local_vars): Return PBB_NB_LOCAL_VARIABLES.
2264 (psco_scattering_dim): Add assert on parameters.
2265 (psct_scattering_dim): Same.
2266 (psct_scattering_dim_for_loop_depth): Declared.
2267 (psct_local_var_dim): New.
2268 (psco_iterator_dim, psco_parameter_dim): Add assert on parameters.
2269 (psct_iterator_dim, psct_parameter_dim): Same. To maintain the
2270 correct layout, call pbb_nb_local_vars.
2271 (psct_add_local_variable, psct_add_scattering_dimension): New.
2272 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons):
2273 Initialize PBB_NB_SCATTERING_TRANSFORM.
2275 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2277 * graphite-ppl.c (set_inhomogeneous): Renamed ppl_set_inhomogeneous.
2278 (set_coef): Renamed ppl_set_coef.
2279 * graphite-ppl.h (ppl_set_inhomogeneous, ppl_set_coef): Declared.
2281 2009-06-23 Sebastian Pop <sebastian.pop@amd.com>
2283 * graphite-dependences.c (build_pairwise_scheduling_inequality): Don't
2284 test a boolean against 1.
2285 * graphite-interchange.c (pbb_interchange_loop_depths): Do not build
2286 a new polyhedron for the PBB_TRANSFORMED_SCATTERING.
2287 (pbb_do_interchange): Returns true when a transform has been performed.
2288 (scop_do_interchange): Same.
2289 * graphite-poly.c (apply_poly_transforms): Use the return value of
2290 scop_do_interchange.
2291 * graphite-poly.h (scop_do_interchange): Update declaration.
2293 2009-06-23 Tobias Grosser <grosser@fim.uni-passau.de>
2295 * graphite-clast-to-gimple.c (gloog): Reset loop->aux right
2297 * sese.c (sese_reset_aux_in_loops): New.
2298 * sese.h (sese_reset_aux_in_loops): New.
2300 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
2302 * graphite-sese-to-poly.c (scan_tree_for_params_int): Pass in the
2303 multiplier and multiply the constant by the multiplier.
2304 (scan_tree_for_params): Bound the multiplier to its MULT_EXPR.
2305 (build_poly_dr): Do not use the multiplier to define the subscript.
2307 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
2309 * graphite-poly.c (new_poly_dr): Pass an extra argument for the
2310 compiler's data reference. Initialize PDR_CDR.
2311 (print_pdr): Call dump_data_reference.
2312 * graphite-poly.h (struct poly_dr): Rename black_box into pbb.
2313 Add compiler_dr field.
2314 (PDR_BB): Renamed PDR_PBB.
2316 * graphite-sese-to-poly.c (build_poly_dr): Pass to new_poly_dr
2317 GCC's data reference representation.
2318 * tree-data-ref.c (debug_data_references, debug_data_reference): New.
2319 * tree-data-ref.h (debug_data_references, debug_data_reference): Decl.
2321 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
2323 * graphite-poly.c (print_scattering_function): Also print the layout.
2324 * graphite-poly.h (pbb_nb_local_vars): New.
2326 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
2328 * graphite-poly.c (print_pbb_domain): Also print the layout names.
2330 2009-06-19 Sebastian Pop <sebastian.pop@amd.com>
2332 * graphite-poly.c (print_pdr, debug_pdr): New.
2333 * graphite-poly.h (print_pdr, debug_pdr): Declared.
2334 (PDR_BASE): Removed.
2336 2009-06-18 Sebastian Pop <sebastian.pop@amd.com>
2338 * gcc/testsuite/gcc.dg/graphite/interchange-{1..7}.c: New avatars of
2341 2009-06-18 Sebastian Pop <sebastian.pop@amd.com>
2343 * graphite-interchange.c (compute_subscript): Allow also -1 in the
2344 subscript identification column.
2345 (pbb_do_interchange): Print to dump_file that some loops "will be
2346 interchanged". Rely on that chain of characters in the testcases.
2347 * gcc.dg/graphite/interchange-0.c: New.
2348 * gcc.dg/graphite/graphite.exp: Iterate over the testsuite
2349 interchange-*.c files and compile them with -floop-interchange.
2351 2009-06-18 Pranav Garg <pranav.garg2107@gmail.com>
2353 * graphite-interchange.c (interchange_profitable_p): Renamed
2354 pbb_interchange_profitable_p.
2356 2009-06-18 Sebastian Pop <sebastian.pop@amd.com>
2357 Harsha Jagasia <harsha.jagasia@amd.com>
2358 Pranav Garg <pranav.garg2107@gmail.com>
2360 * graphite-interchange.c (interchange_profitable_p): Make static.
2361 (pbb_interchange_loop_depths, pbb_do_interchange,
2362 scop_do_interchange): New.
2363 * graphite-poly.c (apply_poly_transforms): Call scop_do_interchange
2364 for flag_loop_interchange.
2365 * graphite-poly.h (scop_do_interchange): Declared.
2366 * tree-ssa-loop.c (gate_graphite_transforms): Do not fail when
2367 flag_loop_interchange is used.
2369 2009-06-18 Sebastian Pop <sebastian.pop@amd.com>
2371 * graphite-dependences.c (dependence_polyhedron): Update use of
2372 pbb_nb_scattering_dims.
2373 * graphite-poly.h (pbb_nb_scattering_dims): Do not pass SCOP.
2374 (pbb_nb_scattering): Update use of pbb_nb_scattering_dims.
2375 (psco_scattering_dim, psct_scattering_dim, psco_iterator_dim,
2376 psct_iterator_dim, psco_parameter_dim, psct_parameter_dim): New.
2378 2009-06-16 Sebastian Pop <sebastian.pop@amd.com>
2380 * graphite.c: Cleanup foo.
2382 2009-06-16 Sebastian Pop <sebastian.pop@amd.com>
2384 * Merge from mainline (r143684:148293).
2385 * Disabled libpcp until it gets fixed.
2387 2009-06-05 Sebastian Pop <sebastian.pop@amd.com>
2388 Harsha Jagasia <harsha.jagasia@amd.com>
2390 * graphite-interchange.c: New.
2391 * Makefile.in (graphite-interchange.o): New.
2392 * graphite-poly.h (interchange_profitable_p): Declared.
2393 * graphite-ppl.h (value_max): New.
2395 2009-06-04 Sebastian Pop <sebastian.pop@amd.com>
2397 * graphite-dependences.c (dependence_polyhedron): Use pdr_dim.
2398 * graphite-poly.h: Fix some comments.
2402 2009-06-04 Sebastian Pop <sebastian.pop@amd.com>
2405 (pdr_accessp_nb_subscripts): Renamed pdr_nb_subscripts.
2406 (pdr_accessp_nb_iterators): Renamed pdr_dim_iter_domain.
2407 (pdr_accessp_nb_params): Renamed pdr_nb_params.
2408 (pdr_accessp_alias_set_dim): Renamed pdr_alias_set_dim.
2409 (pdr_accessp_subscript_dim): Renamed pdr_subscript_dim.
2410 (pdr_accessp_iterator_dim): Renamed pdr_iterator_dim.
2411 (pdr_accessp_param_dim): Renamed pdr_parameter_dim.
2412 (pbb_nb_loops): Renamed pbb_dim_iter_domain.
2413 * graphite-clast-to-gimple.c: Same.
2414 * graphite-dependences.c: Same.
2415 * graphite-poly.c: Same.
2416 * graphite-sese-to-poly.c: Same.
2418 2009-06-03 Sebastian Pop <sebastian.pop@amd.com>
2420 * graphite-clast-to-gimple.c (build_iv_mapping): Insert full
2421 expressions for an IV rename, as returned by clast_to_gcc_expression.
2422 (copy_renames): Rename new_name to expr.
2423 * sese.c (debug_rename_elt): Same.
2426 (sese_adjust_liveout_phis): Call force_gimple_operand before using
2427 the information from the rename map.
2428 (rename_variables_in_stmt): Same.
2429 (add_loop_exit_phis): Rename new_name to expr.
2430 (insert_loop_close_phis): Same.
2431 (add_guard_exit_phis): Same. Call force_gimple_operand.
2432 * sese.h (struct rename_map_elt): Rename new_name to expr.
2433 (new_rename_map_elt): Same.
2435 2009-06-03 Sebastian Pop <sebastian.pop@amd.com>
2437 * graphite-clast-to-gimple.c (build_iv_mapping): Use set_rename.
2438 * sese.c (set_rename): Make it extern.
2439 * sese.h (set_rename): Declared.
2441 2009-06-03 Sebastian Pop <sebastian.pop@amd.com>
2443 * graphite-poly.c (extend_scattering): Free values.
2444 * graphite-ppl.c (new_Cloog_Domain_from_ppl_Pointset_Powerset):
2446 (ppl_print_powerset_matrix): Same.
2447 * graphite-scop-detection.c (free_scops_1): New.
2448 (limit_scops): Call free_scops_1.
2449 * graphite-sese-to-poly.c (build_scop_bbs_1): Free dom.
2450 (build_poly_dr): Free PPL coefficients.
2451 * tree-parloops.c (rewrite_all_phi_nodes_with_iv): Free bbs.
2453 2009-06-02 Sebastian Pop <sebastian.pop@amd.com>
2455 * graphite-dependences.c: New.
2456 * graphite-data-ref.c: Removed.
2457 * graphite-data-ref.h: Removed.
2458 * Makefile.in (graphite-data-ref.o): Removed.
2459 (graphite-dependences.o): Added.
2460 * graphite-clast-to-gimple.c: Remove dependence on graphite-data-ref.h.
2461 * graphite-poly.c: Same.
2462 Move the data dependence testing to graphite-dependences.c.
2464 2009-05-19 Tobias Grosser <grosser@fim.uni-passau.de>
2466 * graphite-scop-detection.c (graphite_can_represent_loop): Renamed
2467 from graphite_cannot_represent_loop. Code refactored.
2468 (scopdet_basic_block_info): Call graphite_can_represent_loop.
2470 2009-05-17 Li Feng <nemokingdom@gmail.com>
2472 * testsuite/gcc.dg/graphite/graphite_autopar/graphite_autopar.exp:
2473 Cover all the testcases (not only the filtered ones).
2475 2009-05-17 Tobias Grosser <grosser@fim.uni-passau.de>
2477 * graphite-scop-detection.c (stmt_simple_for_scop_p): Remove
2478 unnecessary check. Update comments. Move check for REAL_TYPE here.
2479 (harmful_stmt_in_bb): Remove checks for conditions. This is already
2480 done in (stmt_simple_for_scop_p).
2482 2009-05-14 Tobias Grosser <grosser@fim.uni-passau.de>
2484 * graphite.c (print_global_statistics): New.
2485 (print_graphite_scop_statistic): New.
2486 (print_graphite_statistics): New.
2487 (graphite_initialize, graphite_transform_loops): Print statistics.
2488 * graphite-scop-detection (build_scops): Print statistics.
2489 (print_graphite_scop_statistics): New.
2490 (print_graphite_statistics): New.
2492 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2494 * graphite-clast-to-gimple.c (struct clast_name_index): Removed.
2495 (debug_clast_name_index): Removed.
2496 (debug_clast_name_indexes_1): Removed.
2497 (debug_clast_name_indexes): Removed.
2498 (clast_name_index_elt_info): Removed.
2499 (eq_clast_name_indexes): Removed.
2500 (clast_name_to_index): Removed.
2501 (new_clast_name_index): Removed.
2502 (save_clast_name_index): Removed.
2503 (save_var_name): Moved...
2504 (init_sese_params_index): Removed.
2505 (clast_name_to_gcc): Remove use of name_tree.
2506 (initialize_cloog_names): Same.
2507 (gloog): Do not call init_sese_params_index.
2508 * graphite-sese-to-poly.c (save_var_name): ...here.
2509 (parameter_index_in_region): New.
2510 * sese.c (new_sese): Initialize SESE_PARAMS_NAMES.
2511 (parameter_index_in_region): Removed.
2512 (is_parameter): Remove use of name_tree.
2513 * sese.h (struct name_tree): Removed.
2514 (struct sese): Remove use of name_tree. New field params_names.
2515 (SESE_PARAMS_NAMES): New.
2516 (SESE_PARAMS): Remove duplicate.
2517 (parameter_index_in_region): Removed.
2518 (sese_nb_params): Remove use of name_tree.
2519 (struct clast_name_index): New.
2520 (new_clast_name_index): New.
2521 (clast_name_to_index): New.
2522 (save_clast_name_index): New.
2523 (debug_clast_name_index): New.
2524 (debug_clast_name_indexes_1): New.
2525 (debug_clast_name_indexes): New.
2526 (clast_name_index_elt_info): New.
2527 (eq_clast_name_indexes): New.
2529 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2531 * graphite-clast-to-gimple.c (compute_cloog_iv_types_1): Call
2532 pbb_to_depth_to_oldiv. Remove call to oldiv_for_loop.
2533 (graphite_loop_normal_form): Do not pass region. Do not
2534 initialize SESE_OLDIVS.
2535 (build_graphite_loop_normal_form): Update call to
2536 graphite_loop_normal_form.
2537 * sese.c (debug_oldivs): Removed.
2538 (new_sese): Do not initialize SESE_OLDIVS.
2539 (free_sese): Do not free SESE_OLDIVS.
2540 (oldiv_for_loop): Removed.
2541 * sese.h (struct sese): Remove old_ivs.
2542 (SESE_OLDIVS): Removed.
2543 (oldiv_for_loop): Removed.
2545 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2547 * graphite-clast-to-gimple.c (clast_name_to_gcc): Pass newivs,
2548 remove ivstack. Remove call to loop_iv_stack_get_iv_from_name,
2549 replaced by a call to newivs_to_depth_to_newiv.
2550 (clast_to_gcc_expression): Pass newivs, remove ivstack.
2551 (clast_to_gcc_expression_red): Same.
2552 (gcc_type_for_clast_expr): Same.
2553 (gcc_type_for_clast_eq): Same.
2554 (graphite_translate_clast_equation): Same.
2555 (graphite_create_guard_cond_expr): Same.
2556 (graphite_create_new_guard): Same.
2557 (graphite_create_new_loop): Same.
2558 (build_iv_mapping): Same.
2559 (translate_clast): Same.
2561 (loop_iv_stack_patch_for_consts): Removed. *
2562 sese.c (iv_stack_entry_is_constant): Removed.
2563 (iv_stack_entry_is_iv): Removed.
2564 (loop_iv_stack_push_iv): Removed.
2565 (loop_iv_stack_insert_constant): Removed.
2566 (loop_iv_stack_pop): Removed.
2567 (loop_iv_stack_get_iv): Removed.
2568 (loop_iv_stack_get_iv_from_name): Removed.
2569 (debug_loop_iv_stack): Removed.
2570 (free_loop_iv_stack): Removed.
2571 (loop_iv_stack_remove_constants): Removed. *
2572 sese.h (iv_stack_entry_kind): Removed.
2573 (iv_stack_entry_data_union): Removed.
2574 (iv_stack_entry_struct): Removed.
2575 (iv_stack_entry_p): Removed.
2576 (debug_oldivs, debug_loop_iv_stack, loop_iv_stack_insert_constant,
2577 loop_iv_stack_get_iv_from_name, loop_iv_stack_push_iv,
2578 loop_iv_stack_get_iv, loop_iv_stack_remove_constants,
2579 loop_iv_stack_pop, free_loop_iv_stack): Removed.
2580 (gbb_loop_at_index): Fix indenting.
2581 (gbb_loop_index): Removed.
2583 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2585 * graphite-clast-to-gimple.c (clast_name_to_gcc): Do not use strcmp.
2586 Call clast_name_to_index.
2588 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2590 * graphite-clast-to-gimple.c (clast_name_to_gcc): Pass region,
2591 do not pass params. Get params from SESE_PARAMS.
2592 (clast_to_gcc_expression): Same.
2593 (clast_to_gcc_expression_red): Same.
2594 (gcc_type_for_clast_eq): Same.
2595 (graphite_translate_clast_equation): Same.
2596 (graphite_create_new_loop): Same.
2597 * sese.c (rename_variables_in_stmt): Fix comment.
2599 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2601 * graphite-clast-to-gimple.c (graphite_create_new_loop): Pass
2603 Call save_clast_name_index.
2604 (translate_clast): Pass newivs_index.
2605 (gloog): Create and free newivs_index.
2607 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2609 * graphite-clast-to-gimple.c (clast_name_index): New structure.
2610 (clast_name_index_p): New type.
2611 (debug_clast_name_index): New.
2612 (debug_clast_name_indexes_1): New.
2613 (debug_clast_name_indexes): New.
2614 (clast_name_index_elt_info): New.
2615 (eq_clast_name_indexes): New.
2616 (clast_name_to_index): New.
2617 (new_clast_name_index): New.
2618 (save_clast_name_index): New.
2619 (init_sese_params_index): New.
2620 (gloog): Call init_sese_params_index.
2621 * graphite-clast-to-gimple.h (debug_clast_name_indexes): Declared.
2622 * sese.c (new_sese): Initialize SESE_PARAMS_INDEX.
2623 (free_sese): Free SESE_PARAMS_INDEX.
2624 * sese.h (struct sese): Add params_index.
2625 (SESE_PARAMS_INDEX): New.
2627 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2629 * graphite-clast-to-gimple.c (newivs_to_depth_to_newiv): New.
2630 (graphite_create_new_loop): Pass the newivs vector. Push the
2631 newly created IV to newivs.
2632 (translate_clast): Pass the newivs vector.
2633 (gloog): Create and destroy the newivs vector.
2635 2009-05-13 Sebastian Pop <sebastian.pop@amd.com>
2637 * graphite-clast-to-gimple.c (pbb_to_depth_to_oldiv): New.
2638 (graphite_loop_normal_form): Initialize loop->aux with the unique
2639 IV that has been created.
2641 2009-05-13 Tobias Grosser <grosser@fim.uni-passau.de>
2643 * tree-chrec.c (evolution_function_right_is_integer_cst): Allow
2644 scev with parameters in the base part. They where forbidden
2647 2009-05-11 Li Feng <nemokingdom@gmail.com>
2649 * testsuite/gcc.dg/graphite/graphite.exp: Set different default
2650 compile options by file names.
2651 * testsuite/gcc.dg/graphite/block{0-6}.c: Remove dg-option line.
2652 * testsuite/gcc.dg/graphite/id-{1-9}.c: Ditto.
2653 * testsuite/gcc.dg/graphite/scop-{0-20}.c: Ditto.
2654 * testsuite/gcc.dg/graphite/scop-matmult.c: Ditto.
2656 2009-05-08 Li Feng <nemokingdom@gmail.com>
2658 * testsuite/gcc.dg/graphite/graphite_autopar/graphite_autopar.exp: New.
2659 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-1.c: New.
2660 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-2.c: New.
2661 * testsuite/gcc.dg/graphite/graphite_autopar/force-parallel-3.c: New.
2663 2009-05-07 Tobias Grosser <grosser@fim.uni-passau.de>
2665 * graphite-scop-detection (build_scops_1): Fix little bug introduced
2668 2009-05-07 Tobias Grosser <grosser@fim.uni-passau.de>
2670 * graphite-scop-detection.c (graphite_can_represent_scev): Only
2671 allow integer constant strides.
2672 (graphite_can_represent_expr): Depend on outermost_loop.
2673 (stmt_simple_memref_p, graphite_cannot_represent_loop,
2674 harmful_stmt_in_bb, is_simple_operand, stmt_simple_for_scop_p,
2675 build_scops_1): Same.
2676 (scopdet_basic_block_info): Same and insert layered SCoP
2678 (try_generate_gimple_bb): Cleanup.
2679 (build_scops): Enable data references.
2681 * testsuite/gcc.dg/graphite/id-5.c: New.
2682 * testsuite/gcc.dg/graphite/id-9.c: New.
2683 * tree-chrec.c (evolution_function_right_is_integer_cst): New.
2684 * tree-chrec.h (evolution_function_right_is_integer_cst): New.
2686 2009-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
2688 * sese.c (expand_scalar_variables_ssa_name): Only build expressions,
2689 that we have not yet built for this SCoP.
2691 2009-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
2693 * sese.c (expand_scalar_variables_expr): Fix expand_scalar_variables
2694 for complex numbers.
2696 2009-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
2698 * graphite-ppl.c: Fix build if cloog is not available.
2700 2009-05-04 Li Feng <nemokingdom@gmail.com>
2702 * tree-parloops.c (loop_parallel_p): Remove construction of
2703 NITER and REDUCTION_LIST.
2704 (try_get_loop_niter): New.
2705 (try_create_reduction_list): New.
2706 (parallelize_loops): Bypass the failed checkings in autopar
2707 when can_be_parallel in loop structure is set to true.
2709 2009-05-01 Tobias Grosser <grosser@fim.uni-passau.de>
2711 * testsuite/gcc.dg/graphite/id-6.c: Update testcase.
2712 * testsuite/gcc.dg/graphite/scop-3.c: Dito.
2714 2009-05-01 Tobias Grosser <grosser@fim.uni-passau.de>
2716 * graphite-scop-detection.c (stmt_simple_for_scop_p):
2717 Enable EQ_EXPR and NE_EXPR again.
2719 2009-04-30 Tobias Grosser <grosser@fim.uni-passau.de>
2721 * graphite-scop-detection.c (graphite_can_represent_scev):
2722 Add check if scev is affine multivariate.
2723 (harmful_stmt_in_bb): Check if we can represent the conditions.
2724 (scopdet_basic_block_info (basic_block bb, VEC): Pass the loop to
2726 * testsuite/gcc.dg/graphite/id-7.c: New.
2728 2009-04-30 Tobias Grosser <grosser@fim.uni-passau.de>
2730 * graphite-sese-to-poly.c (bb_contains_non_iv_scalar_phi_nodes):
2731 Check all bbs in region, not only the bbs that are represented in
2733 (build_poly_scop): Add newline.
2734 * testsuite/gcc.dg/graphite/id-8.c: New.
2736 2009-04-30 Li Feng <nemokingdom@gmail.com>
2738 * cfgloop.c (alloc_loop): Initialize can_be_parallel to false
2739 when loop initialize.
2740 * cfgloop.h (struct loop): Introduce flag can_be_parallel.
2741 * common.opt: Declare flag_graphite_force_parallel.
2742 * graphite-clast-to-gimple.c (translate_clast): Mark the innermost
2744 * graphite-poly.c (apply_poly_transforms): Introduce
2745 flag_graphite_force_parallel.
2746 * tree-ssa-loop.c (gate_graphite_transforms): ditto.
2747 * toplev.c (process_options): ditto and replace a not correctly
2750 2009-04-30 Li Feng <nemokingdom@gmail.com>
2752 * graphite-clast-to-gimple.c (loop_iv_stack_patch_for_consts):
2753 Change the call of gbb_loop_at_index and/or gbb_loop_index due
2754 to the redefinition.
2755 (compute_cloog_iv_types_1): ditto.
2756 (build_iv_mapping): ditto.
2757 * graphite-sese-to-poly.c (new_gimple_bb): Remove GBB_LOOPS related
2759 (free_gimple_bb): Removed GBB_LOOPS related free part.
2760 (build_bb_loops): Removed.
2761 * sese.h (struct gimple_bb): Removed loops.
2762 (GBB_LOOPS): Removed.
2763 (gbb_loop_at_index): Instead of using GBB_LOOPS, we use sese instead.
2764 (gbb_loop_index): ditto.
2766 2009-04-24 Tobias Grosser <grosser@fim.uni-passau.de>
2768 * graphite-scop-detection.c (graphite_can_represent_scev): Do not
2769 allow non constant strides.
2770 * testsuite/gcc.dg/graphite/scop-20.c: New.
2772 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
2774 * graphite-scop-detection.c (dot_all_scops): Fix system call
2775 return value warning.
2778 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
2780 * testsuite/gcc.dg/graphite/id-6.c: Fix pattern.
2781 * testsuite/gcc.dg/graphite/scop-3.c: Same.
2783 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
2785 * graphite-poly.c (map_into_dep_poly, map_dr_into_dep_poly,
2786 build_pairwise_constraint, dr_equality_constraints,
2787 build_pairwise_scheduling_equality,
2788 build_pairwise_scheduling_inequality, lexicographically_gt_p,
2789 build_lexicographically_gt_constraint, dependence_polyhedron,
2790 graphite_legal_transform_dr, graphite_legal_transform_bb,
2791 graphite_legal_transform): New.
2792 * graphite-poly.h (graphite_legal_transform): Declared.
2793 * graphite-sese-to-poly.c (build_poly_scop): Call to
2794 graphite_legal_transform is disabled for the moment.
2796 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
2798 * graphite-poly.h (pbb_nb_scattering_dims): New.
2799 (pbb_nb_scattering): Use it.
2801 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
2803 * graphite-ppl.c (ppl_insert_dimensions_pointset): Add
2804 Pointset_Powerset version of ppl_insert_dimensions.
2805 * graphite-ppl.h (ppl_insert_dimensions_pointset): Declared.
2807 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
2809 * graphite-ppl.c (ppl_insert_dimensions): Fix formatting.
2811 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
2813 * graphite-poly.h: Fix comment.
2815 2009-04-24 Sebastian Pop <sebastian.pop@amd.com>
2817 * graphite-sese-to-poly.c (build_poly_dr): Fix data ref multiplier.
2819 2009-04-24 Tobias Grosser <grosser@fim.uni-passau.de>
2821 * sese.c (expand_scalar_variables_stmt): Only iterate over the old
2824 2009-04-24 Tobias Grosser <grosser@fim.uni-passau.de>
2826 * graphite-sese-to-poly.c (var_used_in_not_loop_header_phi_node): New.
2827 (graphite_stmt_p): Represent bbs necessary to build the phi nodes of
2830 2009-04-20 Sebastian Pop <sebastian.pop@amd.com>
2832 * graphite-scop-detection.c (stmt_simple_for_scop_p): Do not
2833 handle EQ_EXPR and NE_EXPR.
2835 2009-04-17 Tobias Grosser <grosser@fim.uni-passau.de>
2837 * graphite-poly.h (poly_dr): Fix comment.
2839 2009-04-09 Sebastian Pop <sebastian.pop@amd.com>
2840 Tobias Grosser <grosser@fim.uni-passau.de>
2842 * graphite-poly.c (new_poly_bb): Do not initialize PBB_DOMAIN
2843 with a zero dimension polyhedron.
2844 (find_scop_parameters): Move the call to scop_set_nb_params here.
2845 (build_loop_iteration_domains): Store in loop->aux the iteration
2847 (build_scop_iteration_domain): Fix PBB_DOMAIN for bbs not surrounded
2848 by any loop in scop.
2849 (build_poly_scop): Do not call scop_set_nb_params.
2851 2009-04-09 Sebastian Pop <sebastian.pop@amd.com>
2852 Tobias Grosser <grosser@fim.uni-passau.de>
2854 * graphite-sese-to-poly.c (add_condition_to_pbb): Pass code to
2855 add_condition_to_domain not GT_EXPR.
2857 2009-04-09 Tobias Grosser <grosser@fim.uni-passau.de>
2859 * graphite-ppl.c (debug_ppl_powerset_matrix): New.
2860 * graphite-ppl.h (debug_ppl_powerset_matrix): New.
2861 * graphite-sese-to-poly.c (add_condition_to_pbb): Use
2862 upper_bound_assign to calculate unions.
2863 * testsuite/gcc.dg/graphite/id-6.c: New.
2865 2009-04-09 Tobias Grosser <grosser@fim.uni-passau.de>
2867 * graphite-scop-detection.c (canonicalize_loop_closed_ssa): Do not
2868 handle abnormal edges.
2870 2009-04-09 Tobias Grosser <grosser@fim.uni-passau.de>
2872 * graphite-poly.c (new_poly_dr, free_poly_dr): New.
2873 (free_poly_bb): Also free poly_drs.
2874 * graphite-poly.h (new_poly_dr, free_poly_dr): New.
2875 (poly_dr): Polyhedron to Pointset_Powerset.
2876 (pdr_accessp_nb_subscripts): Same.
2877 * graphite-sese-to-poly.c (build_poly_dr): Same. And actually build
2880 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
2882 * graphite-clast-to-gimple.c (initialize_cloog_names): Change cloog
2883 names into more meaningful names.
2885 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
2887 * testsuite/gfortran.dg/graphite/interchange-1.c: New.
2888 * testsuite/gfortran.dg/graphite/interchange-2.c: New.
2890 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
2892 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not build
2894 * tree-parloops.c (rewrite_phi_with_iv): New.
2895 (rewrite_all_phi_nodes_with_iv): New.
2896 (canonicalize_loop_ivs): Call them.
2898 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
2900 * graphite-sese-to-poly.c (try_generate_gimple_bb): Use
2901 graphite_find_data_references_in_stmt.
2902 * tree-data-ref.c (graphite_find_data_references_in_stmt): New.
2903 * tree-data-ref.h (graphite_find_data_references_in_stmt): Declared.
2905 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
2907 * sese.c (add_loop_exit_phis): Don't fail on non SSA_NAME renames.
2909 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
2911 * graphite-sese-to-poly.c (build_scop_bbs_1): Use bb_in_sese_p
2912 instead of bb_in_region.
2913 (flag_bb_in_region): Same. Renamed flag_bb_in_sese.
2914 (build_sese_conditions): Use flag_bb_in_sese.
2915 * sese.c (register_bb_in_sese): Removed.
2916 (new_sese): Remove initialization of SESE_REGION_BBS.
2917 (free_sese): Do not free SESE_REGION_BBS.
2918 * sese.h (struct sese): Remove field region_basic_blocks.
2919 (SESE_REGION_BBS): Removed.
2920 (bb_in_sese_p): Implement in function of bb_in_region.
2922 2009-04-08 Sebastian Pop <sebastian.pop@amd.com>
2924 * graphite-scop-detection.c (limit_scops): Deal only with single exit
2927 2009-04-08 Tobias Grosser <grosser@fim.uni-passau.de>
2929 * graphite-scop-detection.c (stmt_simple_for_scop_p): Allow NE_EXPR
2931 * graphite-sese-to-poly.c (create_linear_expr_from_tree): New.
2932 (add_condition_to_domain): New.
2933 (add_condition_to_pbb): New.
2934 (add_conditions_to_domain): Cleanup and handle of NE_EXPR and EQ_EXPR.
2935 * testsuite/gcc.dg/graphite/scop-3.c: Update number of detected SCoPs.
2937 2009-04-08 Tobias Grosser <grosser@fim.uni-passau.de>
2939 * graphite-clast-to-gimple.c (build_cloog_prog): ppl_Polyhedron ->
2940 ppl_Pointset_Powerset.
2941 * graphite-poly.c (new_poly_bb, free_poly_bb): Same.
2942 * graphite-poly.h (poly_bb): poly_bb.domain Same.
2943 (pbb_nb_loops): Same.
2944 * graphite-sese-to-poly.c (build_loop_iteration_domains,
2945 add_conditions_to_domain): Same.
2946 * graphite-ppl.c (new_Cloog_Domain_from_ppl_Pointset_Powerset): New.
2947 (ppl_print_polyhedron_matrix): ppl_Polyhedron_t ->
2948 ppl_const_Polyhedron_t.
2949 (ppl_print_powerset_matrix): New.
2950 * graphite-ppl.h (new_Cloog_Domain_from_ppl_Pointset_Powerset,
2951 ppl_print_powerset_matrix): New.
2952 (ppl_print_polyhedron_matrix): Updated.
2954 2009-04-07 Sebastian Pop <sebastian.pop@amd.com>
2956 * tree-scalar-evolution.c (analyze_scalar_evolution_1): Fix comment.
2958 2009-04-07 Sebastian Pop <sebastian.pop@amd.com>
2960 * graphite-poly.c (extend_scattering): Fix indenting. Free cstr.
2961 (print_iteration_domains, debug_iteration_domain,
2962 debug_iteration_domains): New.
2963 * graphite-poly.h (print_iteration_domains, debug_iteration_domain,
2964 debug_iteration_domains): Declared.
2965 * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons): Fix
2968 2009-04-03 Tobias Grosser <grosser@fim.uni-passau.de>
2969 Sebastian Pop <sebastian.pop@amd.com>
2971 * graphite-poly.h (print_iteration_domain): New.
2972 * graphite-sese-to-poly.c (add_conditions_to_domain): Fixed bug.
2973 (build_sese_conditions_1, build_sese_conditions_after,
2974 build_sese_conditions_before): New.
2975 (build_sese_conditions): Rewritten.
2977 2009-04-03 Sebastian Pop <sebastian.pop@amd.com>
2978 Tobias Grosser <grosser@fim.uni-passau.de>
2980 Cleanup of code generation liveouts.
2981 * graphite-clast-to-gimple.c (translate_clast): Use a single
2982 rename_map instead of one per translated statement.
2983 Do not use SESE_LIVEOUT_RENAMES.
2984 (graphite_loop_normal_form): Do not use SESE_REDUCTION_LIST.
2985 (gloog): Do not use SESE_LIVEOUT_RENAMES.
2986 * graphite-scop-detection.c (harmful_stmt_in_bb): Return the close
2987 phi node of a reduction: when a loop contains a reduction used outside
2988 the loop, there should be a scalar close phi node on the exit block.
2989 * sese.c (new_sese): Do not initialize SESE_LIVEOUT,
2990 SESE_LIVEOUT_RENAMES, and SESE_REDUCTION_LIST.
2991 (free_sese): Do not free them.
2992 (sese_build_liveouts_use): Do not use them.
2993 (sese_build_liveouts_bb): Same.
2994 (sese_build_liveouts): Same.
2995 (sese_insert_phis_for_liveouts): Same.
2996 (sese_adjust_phis_for_liveouts): Same. Renamed sese_adjust_liveout_phis.
2997 (defined_in_loop_p): New.
2998 (alive_after_loop): New.
2999 (close_phi_not_yet_inserted_p): New.
3000 (struct alep, alep_p): New.
3001 (add_loop_exit_phis): Remove from the rename_map all the names defined
3002 in the code generated loop.
3003 (insert_loop_close_phis): Traverse the rename_map passed to it.
3004 Don't use SESE_LIVEOUT_RENAMES.
3005 (default_liveout_before_guard): Renamed default_before_guard.
3006 (insert_guard_phis): Do not use SESE_LIVEOUT_RENAMES.
3007 (graphite_copy_stmts_from_block): Do not directly call set_rename.
3008 (register_sese_liveout_renames): Removed.
3009 (copy_bb_and_scalar_dependences): Do not call it.
3010 * sese.h (struct sese): Removed fields: liveout, liveout_renames, and
3012 (SESE_LIVEOUT): Removed.
3013 (SESE_LIVEOUT_RENAMES): Removed.
3014 (SESE_REDUCTION_LIST): Removed.
3015 (sese_build_liveouts): Removed.
3016 (sese_adjust_phis_for_liveouts): Renamed sese_adjust_liveout_phis.
3017 (insert_loop_close_phis): Pass a htab_t instead of a sese.
3018 (insert_guard_phis): Same.
3019 (rename_map_elt): Declare a VEC of them.
3020 * tree-parloops.c (canonicalize_loop_ivs): reduction_list contains
3021 trees not pointers to trees.
3023 Rewrite in canonical close SSA form:
3024 * graphite-scop-detection.c (contains_only_close_phi_nodes): New.
3025 (limit_scops): Close the scop after the block containing the close phi
3027 (canonicalize_loop_closed_ssa): New.
3028 (canonicalize_loop_closed_ssa_form): New.
3029 (build_scops): Call canonicalize_loop_closed_ssa_form.
3031 * graphite-sese-to-poly.c: Fix typos.
3033 2009-04-03 Sebastian Pop <sebastian.pop@amd.com>
3035 * graphite-poly.c (print_scattering_function, print_pbb_domain):
3037 (dump_gbb_conditions, dump_gbb_cases, print_iteration_domain): New.
3038 (print_pbb): Add conditions.
3040 2009-04-01 Tobias Grosser <grosser@fim.uni-passau.de>
3041 Sebastian Pop <sebastian.pop@amd.com>
3043 * graphite-scop-detection.c (bb_in_sd_region): Use bb_in_region.
3044 * graphite-sese-to-poly.c (all_non_dominated_preds_marked_p): New.
3045 (build_scop_bbs_1): New.
3046 (build_scop_bbs): Rewrite.
3047 * sese.h (bb_in_region): New.
3049 2009-03-29 Tobias Grosser <grosser@fim.uni-passau.de>
3051 * graphite-poly.c (new_poly_bb, free_poly_bb): Initialize/free
3053 (print_scop): Style.
3054 * graphite-poly.h (poly_bb): Add drs vector.
3055 (PBB_DRS): Add accessor.
3056 * graphite-sese-to-poly.c (build_poly_dr): New.
3057 (build_pbb_drs, build_scop_drs): New.
3058 (build_poly_scop): call build_scop_drs (Disabled at the moment).
3060 2009-03-29 Tobias Grosser <grosser@fim.uni-passau.de>
3062 * tree-ssa-loop.c: Include forgotten toplev.h
3064 2009-03-29 Tobias Grosser <grosser@fim.uni-passau.de>
3066 * graphite-poly.c: (apply_poly_transforms): sorry -> gcc_unreachable.
3067 * testsuite/gcc.dg/graphite/pr37883.c: Remove -floop-*
3068 * testsuite/gcc.dg/graphite/pr37928.c: Same
3069 * testsuite/gcc.dg/graphite/pr38409.c: Same
3070 * testsuite/gcc.dg/graphite/pr38498.c: Same
3071 * testsuite/gcc.dg/graphite/pr38559.c: Same
3072 * testsuite/gcc.dg/graphite/pr39335.c: Same
3073 * testsuite/gcc.dg/graphite/pr39335_1.c: Same
3074 * testsuite/gfortran.dg/graphite/block-2.f: Same
3075 * tree-ssa-loop.c (gate_graphite_transforms): Always fail if called
3078 2009-03-28 Tobias Grosser <grosser@fim.uni-passau.de>
3080 * graphite-sese-to-poly.c (ref_nb_loops, build_access_matrix_with_af,
3081 build_access_matrix, build_scop_data_accesses): Remove access function
3082 building. (We get a new version soon).
3083 (build_bb_loops, scan_tree_for_params_right_scev): Update.
3084 * sese.h (nb_loops_around_loop_in_sese): Remove.
3085 (sese_loop_depth): Do not use SESE_LOOP_NEST any more.
3087 2009-03-27 Tobias Grosser <grosser@fim.uni-passau.de>
3088 Sebastian Pop <sebastian.pop@amd.com>
3090 * graphite-scop-detection.c (struct scopdet_info): Rename last
3092 (scopdet_basic_block_info, build_scops_1): Don't use
3093 CDI_POST_DOMINATORS. CDI_POST_DOMINATORS should never be used.
3095 2009-03-26 Tobias Grosser <grosser@fim.uni-passau.de>
3096 Sebastian Pop <sebastian.pop@amd.com>
3098 * graphite-clast-to-gimple.c (gloog): Call sese_build_liveouts.
3099 * sese.c (sese_build_liveouts_use): Renamed from
3100 sese_build_livein_liveouts_use. Remove liveins.
3101 (sese_build_liveouts_bb): Renamed from sese_build_livein_liveouts_bb.
3102 Call sese_build_liveouts_use.
3103 (sese_build_liveouts): Renamed from sese_build_livein_liveouts.
3104 Call sese_build_liveouts_bb.
3105 (new_sese, free_sese): Remove liveins.
3106 (sese_add_exit_phis_var): Deleted.
3107 (sese_insert_phis_for_liveouts): Call sese_add_exit_phis_edge
3109 (graphite_copy_stmts_from_block): Remove SESE_NUM_VER.
3111 * sese.h (sese): Remove num_ver and livein.
3112 (SESE_LIVEIN, SESE_LIVEIN_VER, SESE_NUM_VER): Removed.
3114 2009-03-25 Tobias Grosser <grosser@fim.uni-passau.de>
3116 * graphite-sese-to-poly.c (build_scop_scattering): Fix compile.
3118 2009-03-25 Tobias Grosser <grosser@fim.uni-passau.de>
3120 * graphite-sese-to-poly.c (compare_prefix_loops): Removed.
3121 (build_scop_scattering): Do not use compare_prefix_loops any more.
3122 (nb_common_loops): New.
3124 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
3126 * sese.c (get_new_name_from_old_name): Renamed get_rename.
3127 (register_old_and_new_names): Renamed set_rename.
3129 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
3131 * graphite-scop-detection.h (nb_reductions_in_loop): Revert removal
3132 of the decl from the previous commit.
3134 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
3136 * graphite-scop-detection.c (dot_scop): New.
3137 * graphite-scop-detection.h (dot_scop): Declared.
3139 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
3141 * graphite-sese-to-poly.c (compare_prefix_loops): Fix compare.
3143 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
3145 * cfgloopmanip.c (create_empty_loop_on_edge): Generate the loop exit
3146 condition at the end of the loop.
3147 * graphite.c (graphite_initialize, graphite_finalize): Print to
3148 dump_file the compiled function.
3149 * graphite-clast-to-gimple.c (graphite_create_new_loop): Update use
3150 of create_empty_loop_on_edge.
3151 (translate_clast): Update the code generation of loops for the new
3153 * cfgloop.h (create_empty_loop_on_edge): Update declaration.
3155 2009-03-24 Sebastian Pop <sebastian.pop@amd.com>
3157 Reverted the patch from 2009-03-19.
3159 2009-03-19 Tobias Grosser <grosser@fim.uni-passau.de>
3161 * graphite-poly.c (new_poly_bb, free_poly_bb): Initialize/free
3163 (print_scop): Style.
3164 * graphite-poly.h (poly_bb): Add drs vector.
3165 (PBB_DRS): Add accessor.
3166 * graphite-sese-to-poly.c (ref_nb_loops): Remove.
3167 (build_access_matrix_with_af, build_access_matrix,
3168 build_scop_data_accesses): Delete.
3169 (build_poly_dr): New.
3170 (build_pbb_drs, build_scop_drs): New.
3171 (build_poly_scop): call build_scop_drs.
3173 2009-03-13 Sebastian Pop <sebastian.pop@amd.com>
3175 * graphite-scop-detection.c (dot_all_scops_1): Close the table
3176 once per basic block.
3178 2009-03-13 Tobias Grosser <grosser@fim.uni-passau.de>
3180 * graphite-scop-detection.c (graphite_can_represent_scev): New.
3181 (graphite_can_represent_expr): Renamed from loop_affine_expr
3183 (stmt_simple_for_scop_p): Call graphite_can_represent_expr.
3184 (graphite_cannot_represent_loop): Add scop_entry to parameters.
3185 (scopdet_basic_block_info): Actually define entry_block.
3186 (stmt_simple_memref_p): Moved here from ...
3188 * tree-data-ref.c (stmt_simple_memref_p): here.
3189 * tree-data-ref.h (stmt_simple_memref_p): Removed.
3191 2009-03-13 Tobias Grosser <grosser@fim.uni-passau.de>
3193 * testsuite/gcc.dg/graphite/id-4.c: New.
3195 2009-03-12 Sebastian Pop <sebastian.pop@amd.com>
3197 * sese.c (expand_scalar_variables_expr): Handle tcc_comparison.
3198 (register_old_and_new_names): Update the content of the map.
3199 When there was already a rename_map_elt in the map at that
3201 (copy_bb_and_scalar_dependences): Do rename_variables after
3202 expand_scalar_variables.
3203 * graphite-clast-to-gimple.c (build_iv_mapping): Update the content
3204 of the map. When there was already a rename_map_elt in the
3205 map at that location, free it.
3206 (translate_clast): Pass the rename_map. Do not initialize and free
3207 a rename_map per stmt_user.
3208 (gloog): Initialize and free one rename_map and pass it to
3211 2009-03-12 Sebastian Pop <sebastian.pop@amd.com>
3213 * sese.c (expand_scalar_variables_stmt,
3214 expand_scalar_variables_ssa_name): Add a gimple_stmt_iterator
3216 (expand_scalar_variables_expr): Handle REALPART_EXPR and IMAGPART_EXPR.
3217 (expand_scalar_variables): Pass to expand_scalar_variables_stmt
3218 the gimple_stmt_iterator of the statement to be expanded.
3219 * graphite-scop-detection.c (is_simple_operand): Do handle
3222 2009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
3224 * graphite-scop-detection.c (is_simple_operand): Do not handle
3226 * testsuite/gcc.dg/graphite/id-2.c: New.
3228 * graphite-sese-to-poly.c (build_bb_loops,
3229 add_value_to_dim, scan_tree_for_params_right_scev,
3230 scan_tree_for_params_int, scan_tree_for_params, idx_record_params,
3231 find_params_in_bb, build_loop_iteration_domains,
3232 add_conditions_to_domain): Remove subtract.
3234 2009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
3236 * graphite-clast-to-gimple.c (loop_iv_stack_patch_for_consts,
3237 build_iv_mapping, compute_cloog_iv_types_1, build_cloog_prog):
3238 pbb_loop_at_index -> gbb_loop_at_index.
3239 * graphite-poly.c (new_poly_bb, new_scop): New accessors.
3240 (debug_loop_vec): Delete.
3241 * graphite-poly.h (poly_bb, scop): Change black_box and region to void
3242 pointer. Move LOOPS to gimple_bb_p and insert nb_params.
3243 (PBB_LOOPS): Removed.
3244 (PBB_BLACK_BOX): Insert cast.
3245 (pbb_set_black_box): New setter.
3246 (pbb_loop_at_index, pbb_loop_index): Removed.
3247 (scop_set_region, scop_set_nb_params): New.
3248 * graphite-sese-to-poly.c (new_gimple_bb, free_gimple_bb,
3249 build_scop_scattering, build_bb_loops): Add GBB_LOOPS.
3250 (build_poly_scop): Use scop_set_nb_params.
3251 * sese.h (gimple_bb): Add LOOPS.
3252 (GBB_LOOPS, gbb_loop_index, gbb_loop_at_index): New.
3254 2009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
3256 Revert previous commit.
3258 2009-03-11 Sebastian Pop <sebastian.pop@amd.com>
3260 * sese.c (expand_scalar_variables_expr): Handle tcc_comparison.
3261 (register_old_and_new_names): Update the content of the map.
3262 When there was already a rename_map_elt in the map at that
3264 (copy_bb_and_scalar_dependences): Do rename_variables after
3265 expand_scalar_variables.
3266 * graphite-clast-to-gimple.c (build_iv_mapping): Update the content
3267 of the map. When there was already a rename_map_elt in the
3268 map at that location, free it.
3269 (translate_clast): Pass the rename_map. Do not initialize and free
3270 a rename_map per stmt_user.
3271 (gloog): Initialize and free one rename_map and pass it to
3274 2009-03-11 Tobias Grosser <grosser@fim.uni-passau.de>
3276 Remove forgotten line in revert.
3278 2009-03-11 Sebastian Pop <sebastian.pop@amd.com>
3280 Revert previous commit.
3282 2009-03-10 Sebastian Pop <sebastian.pop@amd.com>
3284 * sese.c (register_old_and_new_names): Update the content
3285 of the map. When there was already a rename_map_elt in the
3286 map at that location, free it.
3287 (copy_bb_and_scalar_dependences): Do rename_variables after
3288 expand_scalar_variables.
3289 * graphite-clast-to-gimple.c (build_iv_mapping): Update the content
3290 of the map. When there was already a rename_map_elt in the
3291 map at that location, free it.
3292 (translate_clast): Pass the rename_map. Do not initialize and free
3293 a rename_map per stmt_user.
3294 (gloog): Initialize and free one rename_map and pass it to
3297 2009-03-10 Sebastian Pop <sebastian.pop@amd.com>
3299 * graphite-clast-to-gimple.c (translate_clast): context_loop
3302 2009-03-10 Tobias Grosser <grosser@fim.uni-passau.de>
3303 Sebastian Pop <sebastian.pop@amd.com>
3305 * graphite-ppl.c (ppl_insert_dimensions): Fix stupid mistake
3306 of the use of ppl_Polyhedron_map_space_dimensions.
3308 2009-03-10 Tobias Grosser <grosser@fim.uni-passau.de>
3309 Sebastian Pop <sebastian.pop@amd.com>
3311 * graphite-poly.c (unify_scattering_dimensions): Fix types.
3312 * graphite-poly.h (poly_dr_p, poly_dr, POLY_DR_TYPE, PDR_BB,
3313 PDR_TYPE, PDR_ACCESSES, pdr_accessp_nb_subscripts,
3314 pdr_accessp_nb_iterators, pdr_accessp_nb_params,
3315 pdr_accessp_alias_set_dim, pdr_accessp_subscript_dim,
3316 pdr_accessp_iterator_dim, pdr_accessp_param_dim,
3317 pbb_nb_params): New.
3318 (pbb_nb_loops, pbb_nb_scattering, scop_nb_params,
3319 nb_loops_around_pbb): Adapt return types.
3321 2009-03-09 Tobias Grosser <grosser@fim.uni-passau.de>
3323 * Makefile.in (graphite.o, graphite-sese-to-poly.o,
3324 graphite-clast-to-gimple.o, graphite-data-ref.o,
3325 graphite-scop-detection.o, graphite-poly.o): Add
3328 2009-03-05 Tobias Grosser <grosser@fim.uni-passau.de>
3330 * Makefile.in (graphite.o, graphite-sese-to-poly.o,
3331 graphite-clast-to-gimple.o, graphite-data-ref.o,
3332 graphite-scop-detection.o, graphite-poly.o): Add graphite-poly.h.
3334 2009-03-04 Tobias Grosser <grosser@fim.uni-passau.de>
3336 * testsuite/gcc.dg/graphite/pr37485.c: Remove -floop-block
3337 * testsuite/gcc.dg/graphite/pr37828.c: Same.
3338 * testsuite/gcc.dg/graphite/pr37684.c: Same.
3339 * testsuite/gcc.dg/graphite/block-0.c: Same.
3340 * testsuite/gcc.dg/graphite/block-1.c: Same.
3341 * testsuite/gcc.dg/graphite/block-2.c: Same.
3342 * testsuite/gcc.dg/graphite/block-3.c: Same.
3343 * testsuite/gcc.dg/graphite/block-4.c: Same.
3344 * testsuite/gcc.dg/graphite/block-5.c: Same.
3345 * testsuite/gcc.dg/graphite/block-6.c: Same.
3346 * testsuite/gfortran.dg/graphite/pr38083.f90: Same.
3347 * testsuite/gfortran.dg/graphite/block-1.f90: Same.
3348 * testsuite/gfortran.dg/graphite/block-3.f90: Same.
3349 * testsuite/gfortran.dg/graphite/pr37852.f90: Same.
3350 * testsuite/gfortran.dg/graphite/block-4.f90: Same.
3351 * testsuite/gfortran.dg/graphite/pr37980.f90: Same.
3352 * testsuite/gfortran.dg/graphite/pr38953.f90: Same.
3353 * testsuite/gfortran.dg/graphite/pr37857.f90: Same.
3354 * opts.c: Remove -floop-block from -O2.
3355 * graphite-poly.c: Fail if -floop-block -floop-interchange or
3356 -floop-strip-mine are used.
3358 2009-03-04 Tobias Grosser <grosser@fim.uni-passau.de>
3359 Sebastian Pop <sebastian.pop@amd.com>
3361 * graphite-clast-to-gimple.c (build_cloog_prog): Unify scattering
3363 * graphite-poly.c (pbb_compare, graphite_sort_pbbs,
3364 graphite_trans_bb_move_loop, graphite_trans_bb_strip_mine,
3365 strip_mine_profitable_p, is_interchange_valid,
3366 graphite_trans_bb_block, graphite_trans_loop_block,
3367 graphite_trans_scop_block): Temporary removed.
3368 (extend_scattering, unify_scattering_dimensions): New.
3369 (print_scattering_function, graphite_read_transforms):
3370 PBB_SCATTERING -> PBB_TRANSFORMED_SCATTERING.
3371 (graphite_generate_scattering_fns): Removed.
3372 (apply_poly_transforms): Cleanup.
3373 (free_poly_bb): Add PBB_SCATTERING -> PBB_TRANSFORMED_SCATTERING.
3374 (schedule_to_scattering): Moved.
3375 (PBB_STATIC_SCHEDULE, PBB_SCATTERING): Removed.
3376 (PBB_ORIGINAL_SCATTERING, PBB_TRANSFORMED_SCATTERING): New.
3377 (pbb_nb_scattering): New.
3378 (SCOP_ENTRY, SCOP_EXIT, SCOP_REGION_BBS, SCOP_DEP_GRAPH, SCOP_PARAMS,
3379 SCOP_LOOP_NEST, SCOP_PARAMS, SCOP_OLDIVS, SCOP_LIVEOUT_RENAMES):
3381 * graphite-ppl.c (ppl_insert_dimensions): Extended and renamed from
3383 (ppl_strip_loop): PBB_SCATTERING -> PBB_TRANSFORMED_SCATTERING.
3384 * graphite-scop-detection.c (dot_all_scops_1): PBB_SCATTERING
3385 -> PBB_TRANSFORMED_SCATTERING.
3386 * graphite-sese-to-poly.c (build_scop_bbs): Remove region.
3387 (build_pbb_scattering_polyhedron): Moved from schedule_to_scattering.
3388 (build_scop_scattering): Renamed from build_scop_canonical_schedules.
3389 (check_poly_representation): Do not return bool.
3390 (graphite_transform_loops): Reformat.
3391 * sese.h (SESE_ENTRY_BB, SESE_EXIT_BB): New.
3393 2009-03-04 Sebastian Pop <sebastian.pop@amd.com>
3395 * graphite-poly.c (print_pbb_domain, print_pbb, print_scop,
3396 debug_pbb_domain, debug_pbb, debug_scop): New.
3397 * graphite-poly.h (print_pbb_domain, print_pbb, print_scop,
3398 debug_pbb_domain, debug_pbb, debug_scop): Declared.
3400 2009-03-02 Sebastian Pop <sebastian.pop@amd.com>
3403 * tree-parloops.c (canonicalize_loop_ivs): Call fold_convert
3404 when the type precision of the induction variable should be
3405 larger than the type precision of nit.
3406 (gen_parallel_loop): Update use of canonicalize_loop_ivs.
3407 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Same.
3408 * tree-flow.h (canonicalize_loop_ivs): Update declaration.
3410 * testsuite/gcc.dg/graphite/pr39335_1.c: New.
3411 * testsuite/gcc.dg/graphite/pr39335.c: New.
3413 2009-03-02 Sebastian Pop <sebastian.pop@amd.com>
3415 * tree-parloops.c (canonicalize_loop_ivs): reduction_list contains
3416 SSA_NAMES not struct reduction_info.
3418 2009-03-02 Sebastian Pop <sebastian.pop@amd.com>
3420 * sese.c (expand_scalar_variables_expr): Handle ADDR_EXPR.
3422 2009-02-27 Sebastian Pop <sebastian.pop@amd.com>
3423 Tobias Grosser <grosser@fim.uni-passau.de>
3425 * sese.c (new_sese): Initialize SESE_REDUCTION_LIST.
3426 (free_sese): Free SESE_REDUCTION_LIST.
3427 * sese.h (struct sese): Add field reduction_list.
3428 (SESE_REDUCTION_LIST): New.
3429 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Call
3430 canonicalize_loop_ivs on SESE_REDUCTION_LIST.
3432 2009-02-27 Sebastian Pop <sebastian.pop@amd.com>
3433 Tobias Grosser <grosser@fim.uni-passau.de>
3435 * tree-flow.h (gather_scalar_reductions): Use struct loop * instead
3438 2009-02-27 Sebastian Pop <sebastian.pop@amd.com>
3439 Tobias Grosser <grosser@fim.uni-passau.de>
3441 * tree-parloops.c (struct brli, build_reduction_list_info,
3442 analyze_reduction_list, gather_scalar_reductions): New.
3443 (loop_parallel_p): Build a reduction list containing only
3444 PHI_RESULT SSA_NAMEs: call gather_scalar_reductions.
3445 (gen_parallel_loop): Call the analysis analyze_reduction_list.
3446 (parallelize_loops): Now reduction_list is a htab_t of SSA_NAMEs.
3447 * tree-flow.h (gather_scalar_reductions): Declared.
3449 2009-02-26 Sebastian Pop <sebastian.pop@amd.com>
3452 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Do not call
3453 number_of_iterations_exit from a gcc_assert.
3455 2009-02-25 Sebastian Pop <sebastian.pop@amd.com>
3456 Jan Sjodin <jan.sjodin@amd.com>
3458 * output.h (graphite_out_file, graphite_in_file): Declared.
3459 * toplev.c (graphite_out_file, graphite_in_file): New.
3460 (init_asm_output): Initialize graphite_in_file and graphite_out_file.
3461 * graphite-clast-to-gimple.c (build_cloog_prog): Read PBB_SCATTERING.
3462 Don't call schedule_to_scattering.
3463 * common.opt (fgraphite-write, fgraphite-read): New.
3464 * graphite-poly.c: Include output.h.
3465 (print_scattering_function, print_scattering_functions,
3466 debug_scattering_function, debug_scattering_functions,
3467 graphite_write_transforms, graphite_read_transforms,
3468 graphite_generate_scattering_fns): New.
3469 (apply_poly_transforms): Do not apply transform if flag_graphite_read.
3470 Call graphite_generate_scattering_fns, graphite_write_transforms,
3471 graphite_read_transforms.
3472 (new_poly_bb): Initialize PBB_SCATTERING.
3473 (free_poly_bb): Free PBB_SCATTERING.
3474 (schedule_to_scattering): Does not return, initialize PBB_SCATTERING.
3475 * graphite-poly.h (struct poly_bb): Add field scattering.
3476 (PBB_SCATTERING): New.
3477 (print_scattering_function, print_scattering_functions,
3478 debug_scattering_function, debug_scattering_functions): Declared.
3479 * graphite-ppl.c (cloog_matrix_to_ppl_constraint): Matrices contain
3480 GMP values, not integers!
3481 (ppl_print_polyhedron_matrix, debug_ppl_polyhedron_matrix,
3482 ppl_read_polyhedron_matrix): New.
3483 * graphite-ppl.h (ppl_print_polyhedron_matrix,
3484 debug_ppl_polyhedron_matrix,
3485 ppl_read_polyhedron_matrix): Declared.
3486 * Makefile.in (graphite-poly.o): Depends on output.h.
3488 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
3489 Tobias Grosser <grosser@fim.uni-passau.de>
3492 * graphite-scop-detection.c (stmt_simple_for_scop_p): Analyze
3493 scalar evolutions in the scop_entry->loop_father.
3495 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
3496 Tobias Grosser <grosser@fim.uni-passau.de>
3498 * graphite.h (ref_nb_loops): Remove declaration.
3499 (struct gimple_bb, gimple_bb_p, GBB_BB, GBB_DATA_REFS, GBB_CONDITIONS,
3500 GBB_CONDITION_CASES, GBB_CLOOG_IV_TYPES, gbb_loop, print_gimple_bb,
3501 debug_gbb): Moved to sese.h.
3504 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
3505 Tobias Grosser <grosser@fim.uni-passau.de>
3507 * graphite-data-ref.[ch]: Disable.
3509 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
3510 Tobias Grosser <grosser@fim.uni-passau.de>
3512 * graphite-scop-detection.c (stmt_simple_for_scop_p): Analyze
3513 scalar evolutions in the scop_entry->loop_father.
3515 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
3517 * graphite-scop-detection.c (nb_reductions_in_loop): Moved here...
3518 (graphite_cannot_represent_loop_niter): Renamed
3519 graphite_cannot_represent_loop. Call nb_reductions_in_loop.
3520 (limit_scops): build_sese_loop_nests does not return a bool.
3521 * graphite-scop-detection.h (nb_reductions_in_loop): Declared.
3522 * sese.c (nb_reductions_in_loop): ... from here.
3523 (graphite_loop_normal_form): ... from here.
3524 (sese_record_loop): Does not fail, so does not return a bool.
3525 (build_sese_loop_nests): Same.
3526 * sese.h (build_sese_loop_nests): Update declaration.
3527 * graphite-clast-to-gimple.c (graphite_loop_normal_form): Moved here...
3528 (build_graphite_loop_normal_form): New.
3529 (gloog): Call build_graphite_loop_normal_form.
3530 * graphite-sese-to-poly.c (build_poly_scop): Don't fail on
3531 build_sese_loop_nests.
3533 * testsuite/gcc.dg/graphite/id-1.c: New.
3535 2009-02-23 Sebastian Pop <sebastian.pop@amd.com>
3536 Tobias Grosser <grosser@fim.uni-passau.de>
3538 * graphite-sese-to-poly.c (scan_tree_for_params): Remove REAL_CST.
3539 The SCoP detection fix is sufficient.
3541 2009-02-21 Sebastian Pop <sebastian.pop@amd.com>
3543 PR tree-optimization/39260
3544 * graphite-scop-detection.c (harmful_stmt_in_bb): Stop a SCoP when
3545 the basic block contains a condition with a real type.
3546 * graphite-sese-to-poly.c (scan_tree_for_params): Handle REAL_CST.
3548 * gcc.dg/graphite/pr39260.c: New.
3550 2009-02-21 Sebastian Pop <sebastian.pop@amd.com>
3552 * graphite-poly.c: Inlcude params.h.
3553 (graphite_trans_loop_block): Use PARAM_LOOP_BLOCK_TILE_SIZE for
3555 * Makefile.in (graphite-poly.o): Depend on PARAMS_H.
3556 * params.def (PARAM_LOOP_BLOCK_TILE_SIZE): Define.
3558 2009-02-20 Sebastian Pop <sebastian.pop@amd.com>
3559 Tobias Grosser <grosser@fim.uni-passau.de>
3561 * graphite-scop-detection.c (dot_all_scops_1,
3562 dot_all_scops): Moved here.
3563 * graphite-scop-detection.h (dot_all_scops): Declared here.
3564 * graphite.c (graphite_initialize, graphite_finalize): New.
3565 (graphite_transform_loops): Cleaned up.
3566 * sese.c (debug_oldivs): Moved here.
3567 * graphite-poly.c (graphite_apply_transformations): Renamed
3568 apply_poly_transforms.
3569 (debug_loop_vec): Moved here.
3570 * graphite-sese-to-poly.c (build_bb_loops, build_sese_conditions_1,
3571 scop_contains_non_iv_scalar_phi_nodes, build_sese_conditions,
3572 find_scop_parameters, build_scop_iteration_domain,
3573 add_conditions_to_constraints, build_scop_canonical_schedules,
3574 build_scop_data_accesses): Now static.
3575 (build_poly_scop, check_poly_representation): New.
3577 2009-02-20 Sebastian Pop <sebastian.pop@amd.com>
3579 * graphite.c (graphite_stmt_p, new_gimple_bb, free_gimple_bb,
3580 remove_gbbs_in_scop, free_scops, try_generate_gimple_bb,
3581 build_scop_bbs, ref_nb_loops, compare_prefix_loops,
3582 build_scop_canonical_schedules, build_bb_loops, add_value_to_dim,
3583 scan_tree_for_params_right_scev, scan_tree_for_params_int,
3584 scan_tree_for_params, struct irp_data, dx_record_params,
3585 find_params_in_bb, find_scop_parameters, gbb_from_bb,
3586 build_loop_iteration_domains, add_conditions_to_domain,
3587 phi_node_is_iv, bb_contains_non_iv_scalar_phi_nodes,
3588 scop_contains_non_iv_scalar_phi_nodes, build_sese_conditions_1,
3589 build_sese_conditions, add_conditions_to_constraints,
3590 build_scop_iteration_domain, build_access_matrix_with_af,
3591 build_access_matrix,
3592 build_scop_data_accesses): Moved to graphite-sese-to-poly.c.
3594 * graphite-sese-to-poly.c: New.
3595 * graphite-sese-to-poly.h: New.
3597 * Makefile.in: Add new rule for graphite-sese-to-poly.o.
3599 2009-02-20 Sebastian Pop <sebastian.pop@amd.com>
3601 * graphite.c: Split graphite code generation to a new file.
3602 (graphite_verify, gmp_cst_to_tree, clast_name_to_gcc,
3603 max_precision_type, clast_to_gcc_expression_red,
3604 clast_to_gcc_expression, gcc_type_for_clast_expr,
3605 gcc_type_for_clast_eq, loop_iv_stack_patch_for_consts,
3606 graphite_translate_clast_equation, graphite_create_guard_cond_expr,
3607 graphite_create_new_guard, clast_get_body_of_loop,
3608 gcc_type_for_cloog_iv, gcc_type_for_iv_of_clast_loop,
3609 graphite_create_new_loop, build_iv_mapping, copy_renames,
3610 translate_clast, find_cloog_iv_in_expr, compute_cloog_iv_types_1,
3611 compute_cloog_iv_types, free_scattering, save_var_name,
3612 initialize_cloog_names, build_scop_context, build_cloog_prog,
3613 set_cloog_options, debug_clast_stmt, scop_to_clast,
3614 print_generated_program, debug_generated_program,
3615 gloog): Moved to graphite-clast-to-gimple.c.
3617 (struct cloog_prog_clast): Moved to graphite-clast-to-gimple.h.
3619 (iv_stack_entry_is_constant, iv_stack_entry_is_iv,
3620 loop_iv_stack_push_iv, loop_iv_stack_insert_constant,
3621 loop_iv_stack_pop, loop_iv_stack_get_iv,
3622 loop_iv_stack_get_iv_from_name, debug_loop_iv_stack,
3623 free_loop_iv_stack, loop_iv_stack_remove_constants,
3624 debug_rename_elt, debug_rename_map_1, debug_rename_map,
3625 rename_map_elt_info, eq_rename_map_elts, debug_ivtype_elt,
3626 debug_ivtype_map_1, debug_ivtype_map, ivtype_map_elt_info,
3627 eq_ivtype_map_elts, sese_add_exit_phis_edge,
3628 sese_add_exit_phis_var, sese_insert_phis_for_liveouts,
3629 get_vdef_before_sese, sese_adjust_vphi,
3630 get_new_name_from_old_name, sese_adjust_phis_for_liveouts,
3631 oldiv_for_loop, rename_variables_in_stmt, is_parameter,
3632 is_iv, expand_scalar_variables_ssa_name,
3633 expand_scalar_variables_expr, expand_scalar_variables_stmt,
3634 expand_scalar_variables, rename_variables, remove_condition,
3635 get_true_edge_from_guard_bb, get_false_edge_from_guard_bb,
3636 add_loop_exit_phis, insert_loop_close_phis, struct igp,
3637 default_liveout_before_guard, add_guard_exit_phis,
3638 insert_guard_phis, register_old_and_new_names,
3639 graphite_copy_stmts_from_block, register_sese_liveout_renames,
3640 copy_bb_and_scalar_dependences, outermost_loop_in_sese,
3641 if_region_set_false_region, create_if_region_on_edge,
3642 move_sese_in_condition): Moved to sese.c.
3644 (nb_loops_around_loop_in_sese, struct ifsese, if_region_entry,
3645 if_region_exit, if_region_get_condition_block,
3646 struct rename_map_elt, new_rename_map_elt, enum iv_stack_entry_kind,
3647 union iv_stack_entry_data_union, struct iv_stack_entry_struct,
3648 iv_stack_entry_p, loop_iv_stack, struct ivtype_map_elt,
3649 ivtype_map_elt, new_ivtype_map_elt,
3650 recompute_all_dominators): Moved to sese.h.
3652 * graphite-clast-to-gimple.c: New.
3653 * graphite-clast-to-gimple.h: New.
3654 * Makefile.in: Add new rule for graphite-clast-to-gimple.o.
3655 * sese.c: Modified as said above.
3658 2009-02-20 Sebastian Pop <sebastian.pop@amd.com>
3660 * graphite.c: Split scop detection to a new file.
3661 (enum gbb_type, gbb_type, get_bb_type, struct sd_region_p, sd_region,
3662 move_sd_regions, loop_affine_expr, exclude_component_ref,
3663 is_simple_operand, stmt_simple_for_scop_p, harmful_stmt_in_bb,
3664 graphite_cannot_represent_loop_niter, struct scopdet_info,
3665 scopdet_basic_block_info, build_scops_1, bb_in_sd_region,
3666 find_single_entry_edge, find_single_exit_edge,
3667 create_single_entry_edge, sd_region_without_exit,
3668 create_single_exit_edge, unmark_exit_edges, mark_exit_edges,
3669 create_sese_edges, build_graphite_scops, limit_scops, build_scops):
3670 Moved to graphite-scop-detection.c.
3672 * graphite-scop-detection.c: New.
3673 * graphite-scop-detection.h: New.
3674 * Makefile.in: Add new rule for graphite-scop-detection.o.
3676 * sese.c: Include tree-chrec.h, tree-data-ref.h, and
3677 tree-scalar-evolution.h.
3678 (nb_reductions_in_loop, graphite_loop_normal_form, sese_record_loop,
3679 build_sese_loop_nests): Moved here from graphite.c.
3680 (param_index): Renamed parameter_index_in_region.
3682 2009-02-18 Tobias Grosser <grosser@fim.uni-passau.de>
3683 Sebastian Pop <sebastian.pop@amd.com>
3685 * gcc.dg/graphite/block-0.c: Expected to fail now.
3686 * gcc.dg/graphite/block-1.c: Same.
3687 * gcc.dg/graphite/block-5.c: Same.
3688 * gcc.dg/graphite/block-6.c: Same.
3690 2009-02-18 Tobias Grosser <grosser@fim.uni-passau.de>
3691 Sebastian Pop <sebastian.pop@amd.com>
3693 * graphite.h: Separate from graphite_bb_p the polyhedral
3694 representation in poly_bb_p and the GCC specifics in gimple_bb_p.
3695 (struct data_dependence_polyhedron, RDGE_DDP, ddp_p): Moved to
3696 graphite-data-ref.h.
3697 (struct poly_bb, PBB_SCOP, PBB_STATIC_SCHEDULE, PBB_DOMAIN,
3698 PBB_BLACK_BOX, PBB_LOOPS, pbb_nb_loops, pbb_loop_at_index,
3699 pbb_loop_index, struct scop, SCOP_BBS, SCOP_REGION, SCOP_ENTRY,
3700 SCOP_EXIT, SCOP_REGION_BBS, SCOP_DEP_GRAPH, SCOP_PARAMS,
3701 SCOP_LOOP_NEST, SCOP_PARAMS, SCOP_OLDIVS, SCOP_LIVEOUT_RENAMES,
3702 scop_nb_params): Moved to graphite-poly.h.
3703 * graphite-data-ref.c: Same.
3704 * graphite-data-ref.h: New.
3706 (pbb_compare, graphite_sort_pbbs, graphite_trans_bb_move_loop,
3707 graphite_trans_bb_strip_mine, strip_mine_profitable_p,
3708 is_interchange_valid, graphite_trans_bb_block,
3709 graphite_trans_loop_block, scop_max_loop_depth,
3710 graphite_trans_scop_block, graphite_apply_transformations,
3711 new_poly_bb, free_poly_bb, new_scop, free_scop): Moved to
3713 * graphite-poly.h: New.
3714 * graphite-poly.c: New.
3715 * Makefile.in (OBJS-common): Add graphite-poly.o.
3716 (graphite-poly.o): New rule.
3717 * tree-data-ref.h (struct data_reference): Remove unused scop field.
3720 2009-02-18 Sebastian Pop <sebastian.pop@amd.com>
3721 Tobias Grosser <grosser@fim.uni-passau.de>
3723 * graphite.c: Replace gb -> gbb.
3725 * graphite-data-ref.c: Same.
3727 2009-02-18 Sebastian Pop <sebastian.pop@amd.com>
3728 Tobias Grosser <grosser@fim.uni-passau.de>
3730 * Makefile.in (OBJS-commmon): Add sese.o.
3732 (graphite.o): Add sese.h.
3733 * graphite.c (bb_in_ss_p, loop_in_sese_p,
3734 sese_build_livein_liveouts_use, sese_build_livein_liveouts_bb,
3735 sese_build_livein_liveouts, register_bb_in_sese, new_sese, free_sese):
3737 (block_before_scop): Add missing return.
3738 (new_scop, free_scop): Remove SESE data structures.
3739 (scop_record_loop, scan_tree_for_params, find_params_in_bb,
3740 find_scop_parameters, build_loop_iteration_domains,
3741 add_conditions_to_domain, register_scop_liveout_renames,
3742 copy_bb_and_scalar_dependences): Scop -> SESE.
3744 (add_conditions_to_domain): SCoP -> SESE and remove check
3745 (scop_contains_non_iv_scalar_phi_nodes): New.
3746 (build_scop_conditions_1, build_scop_conditions): Remove check for
3747 non iv scalar phi nodes.
3748 (print_scop_statistics): New.
3749 (graphite_transform_loops): Cleanup.
3751 * graphite.h: Move to sese & cleanup.
3755 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
3756 Tobias Grosser <grosser@fim.uni-passau.de>
3758 * graphite.c (build_scop_conditions_1): Conditions are only
3759 at the end of a basic block.
3761 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
3762 Tobias Grosser <grosser@fim.uni-passau>
3764 * graphite.h (struct graphite_bb): Remove compressed_alpha_matrix
3766 (GBB_ALPHA): Removed.
3768 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
3769 Tobias Grosser <grosser@fim.uni-passau.de>
3771 * graphite-data-ref.c (graphite_test_dependence): Don't use
3772 GBB_DYNAMIC_SCHEDULE.
3773 * graphite.c (new_graphite_bb): Same.
3774 (free_graphite_bb): Same.
3775 (build_scop_dynamic_schedules): Removed.
3776 (graphite_transform_loops): Don't call it.
3777 * graphite.h (struct graphite_bb): Remove dynamic_schedule field.
3778 (GBB_DYNAMIC_SCHEDULE): Removed.
3780 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
3781 Tobias Grosser <grosser@fim.uni-passau.de>
3783 * graphite.c (schedule_to_scattering): Don't use CloogMatrix.
3784 (print_graphite_bb): Same.
3785 (build_cloog_prog): Same.
3787 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
3788 Tobias Grosser <grosser@fim.uni-passau.de>
3790 * graphite.c (build_cloog_prog): Don't use CloogMatrix.
3792 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
3793 Tobias Grosser <grosser@fim.uni-passau.de>
3795 * graphite.c (build_scop_context): Don't use CloogMatrix.
3796 * graphite-ppl.c (new_Cloog_Domain_from_ppl_Polyhedron): New.
3797 * graphite-ppl.h (new_Cloog_Domain_from_ppl_Polyhedron): Declared.
3799 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
3800 Tobias Grosser <grosser@fim.uni-passau.de>
3802 * graphite.h (struct scop): Move params, old_ivs, loops, loop_nest,
3803 liveout_renames, add_params fields...
3804 (struct sese): ... here.
3805 (SESE_PARAMS, SESE_LOOPS, SESE_LOOP_NEST, SESE_ADD_PARAMS,
3806 SESE_PARAMS, SESE_OLDIVS, SESE_LIVEOUT_RENAMES): New.
3808 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
3809 Tobias Grosser <grosser@fim.uni-passau.de>
3811 * graphite.c (print_scop): Do not print the CLooG program.
3812 (new_scop, free_scop, initialize_cloog_names, build_scop_context,
3813 build_cloog_prog, gloog): Don't use SCOP_PROG.
3814 (find_transform): Renamed scop_to_clast.
3815 (print_generated_program, debug_generated_program): New.
3816 (graphite_transform_loops): Adapt to new interface.
3817 * graphite.h (struct scop): Remove program field.
3818 (SCOP_PROG): Removed.
3819 (print_generated_program, debug_generated_program): Declared.
3821 2009-02-16 Sebastian Pop <sebastian.pop@amd.com>
3823 * graphite-data-ref.c (schedule_precedes_p, schedule_same_p): New.
3824 (statement_precedes_p): Use schedule_same_p and schedule_precedes_p.
3825 * graphite.c (gbb_compare, schedule_to_scattering, print_graphite_bb,
3826 free_graphite_bb, build_scop_canonical_schedules,
3827 graphite_trans_bb_strip_mine, graphite_trans_scop_block): Static
3828 schedules are now represented using a ppl_Linear_Expression_t.
3829 * graphite.h (struct graphite_bb): Same.
3830 * graphite-ppl.c (ppl_lexico_compare_linear_expressions): New.
3831 * graphite-ppl.h (ppl_lexico_compare_linear_expressions): Declared.
3833 2009-02-15 Sebastian Pop <sebastian.pop@amd.com>
3835 * graphite.c: Free local memory.
3836 * graphite-ppl.c: Same.
3838 2009-02-15 Sebastian Pop <sebastian.pop@amd.com>
3840 * graphite.c (const_column_index, get_first_matching_sign_row_index,
3841 get_lower_bound_row, get_upper_bound_row, copy_constraint,
3842 swap_constraint_variables, scale_constraint_variable): Removed.
3843 (graphite_trans_bb_strip_mine): Remove pong.
3844 * graphite-ppl.c: Include missing header files.
3845 (set_inhomogeneous, set_coef, shift_poly, ppl_strip_loop): New.
3846 * graphite-ppl.h (ppl_strip_loop): Declared.
3847 * Makefile.in (graphite-ppl.o): Adjust dependences.
3849 2009-02-14 Sebastian Pop <sebastian.pop@amd.com>
3851 * graphite.c (build_loop_iteration_domains): Remove ping pong.
3852 (build_scop_iteration_domain): Same.
3854 2009-02-13 Sebastian Pop <sebastian.pop@amd.com>
3856 * graphite.c (scan_tree_for_params, add_conditions_to_domain): Remove
3858 (add_value_to_dim, scan_tree_for_params_right_scev,
3859 scan_tree_for_params_int): New.
3860 * graphite-ppl.c (oppose_constraint): New.
3861 (insert_constraint_into_matrix): Implement missing cases.
3862 * graphite-ppl.h (insert_constraint_into_matrix): Declared.
3864 2009-02-13 Sebastian Pop <sebastian.pop@amd.com>
3866 * graphite.c (graphite_trans_bb_move_loop): Remove ping pong,
3867 use ppl_move_dimension.
3869 2009-02-12 Sebastian Pop <sebastian.pop@amd.com>
3871 * graphite-data-ref.c: Domains are now ppl_Polyhedra_t.
3874 * graphite-ppl.c: Same.
3875 * graphite-ppl.h: Same.
3877 2009-02-12 Sebastian Pop <sebastian.pop@amd.com>
3879 Revert last 3 commits.
3881 2009-02-10 Sebastian Pop <sebastian.pop@amd.com>
3883 * graphite.c (scan_tree_for_params, add_conditions_to_domain): Remove
3885 (add_value_to_dim, scan_tree_for_params_right_scev,
3886 scan_tree_for_params_int): New.
3887 * graphite-ppl.c (oppose_constraint): New.
3888 (insert_constraint_into_matrix): Implement missing cases.
3889 * graphite-ppl.h (insert_constraint_into_matrix): Declared.
3891 2009-02-10 Sebastian Pop <sebastian.pop@amd.com>
3893 * graphite.c (graphite_trans_bb_move_loop): Remove unused variables.
3895 2009-02-10 Sebastian Pop <sebastian.pop@amd.com>
3896 Tobias Grosser <grosser@fim.uni-passau.de>
3898 * graphite.c (graphite_trans_bb_move_loop): Remove ping pong,
3899 use ppl_move_dimension.
3900 * graphite-ppl.c (ppl_move_dimension): New.
3901 * graphite-ppl.h (ppl_move_dimension): Declared.
3903 2009-02-10 Sebastian Pop <sebastian.pop@amd.com>
3905 * graphite.c: Do not include cloog/cloog.h.
3906 (print_graphite_bb): Remove ping pong, call PPL print function.
3908 2009-02-10 Tobias Grosser <grosser@fim.uni-passau.de>
3910 * Makefile.in (OBJS-common): Add graphite-ppl.o.
3911 (graphite.o): Add dependence on graphite-ppl.h.
3912 (graphite-ppl.o): New.
3913 (graphite-data-ref.c): Ping pong between PPL data structures
3915 * graphite-ppl.c: New.
3916 * graphite-ppl.h: New.
3917 * graphite.c: Include graphite-ppl.h.
3918 (print_graphite_bb, add_conditions_to_domain, build_cloog_prog,
3919 graphite_trans_bb_move_loop, graphite_trans_bb_strip_mine):
3920 Ping pong between PPL data structures and matrices.
3921 (new_graphite_bb): Create a PPL constraint system.
3922 Call ppl_delete_Constraint_System instead of cloog_matrix_free.
3923 (build_loop_iteration_domains): Use PPL functions.
3924 * graphite.h: Include graphite-ppl.h. Fix comments.
3925 (graphite_bb): Use a ppl_Constraint_System_t instead of
3926 CloogMatrix for representing the domain.
3927 (scop): Remove static_schedule.
3928 (gbb_nb_loops): Ping pong between PPL data structures and matrices.
3930 2009-02-06 Sebastian Pop <sebastian.pop@amd.com>
3932 * graphite.c: Fix some comments.
3934 2009-02-05 Sebastian Pop <sebastian.pop@amd.com>
3937 * graphite.c (if_region_set_false_region): After moving a region
3938 in the false branch of a condition, remove the empty dummy
3940 (gloog): Remove wrong fix for PR38953.
3942 2009-02-03 Tobias Grosser <grosser@fim.uni-passau.de>
3944 * graphite.c (bb_in_sese_p, sese_build_livein_liveouts_use,
3945 sese_build_livein_liveouts_bb, sese_build_livein_liveouts,
3946 register_bb_in_sese, new_sese, free_sese): Moved.
3947 (dot_scop_1, build_scop_loop_nests, build_loop_iteration_domains,
3948 outermost_loop_in_scop, build_scop_iteration_domain,
3949 expand_scalar_variables_ssa_name, get_vdef_before_scop,
3950 limit_scops): Use bb_in_sese_p instead of bb_in_scop_p.
3951 Use loop_in_sese_p instead of loop_in_scop_p.
3952 (new_graphite_bb, new_scop, gloog): Do not initialize SCOP_BBS_B.
3953 (free_scop): Do not free SCOP_BBS_B.
3954 (nb_loops_around_loop_in_scop, nb_loops_around_gb,
3955 ref_nb_loops): Moved here...
3956 * graphite.h (ref_nb_loops): ... from here.
3957 (struct scop): Remove bbs_b bitmap.
3958 (SCOP_BBS_B, bb_in_scop_p, loop_in_scop_p): Removed.
3959 * testsuite/gcc.dg/graphite/scop-19.c: New
3961 2009-02-03 Tobias Grosser <grosser@fim.uni-passau.de>
3963 * graphite.c (scopdet_basic_block_info): Fix bug in scop
3966 2009-01-30 Tobias Grosser <grosser@fim.uni-passau.de>
3968 * graphite.c (new_loop_to_cloog_loop_str, hash_loop_to_cloog_loop,
3969 eq_loop_to_cloog_loop): Remove.
3970 (new_scop, free_scop): Remove SCOP_LOOP2CLOOG_LOOP.
3971 * graphite.h (struct scop): Remove loop2cloog_loop.
3972 (loop_domain_dim, loop_iteration_vector_dim): Remove.
3974 2009-01-30 Tobias Grosser <grosser@fim.uni-passau.de>
3976 * opts.c (decode_options): Only add graphite options to O2
3977 if we compile with graphite enabled.
3979 2009-01-26 Sebastian Pop <sebastian.pop@amd.com>
3981 * Merge from mainline (r143163:143684).
3983 2009-01-26 Sebastian Pop <sebastian.pop@amd.com>
3985 * graphite.c (debug_value): Removed.
3986 * graphite.h (debug_value): Removed.
3988 2009-01-23 Sebastian Pop <sebastian.pop@amd.com>
3990 * passes.c (init_optimization_passes): Do not call pass_copy_prop
3991 after graphite: pass_copy_prop does not maintain a proper loop closed
3992 SSA form. pass_copy_prop should be fixed.
3994 2009-01-23 Sebastian Pop <sebastian.pop@amd.com>
3996 * graphite.c (scop_adjust_phis_for_liveouts): Fix warning.
3998 2009-01-23 Sebastian Pop <sebastian.pop@amd.com>
4000 * graphite.c (graphite_verify): Add a call to verify_loop_closed_ssa.
4001 (gloog): Split the exit of the scop when the scop exit is a loop exit.
4002 (graphite_transform_loops): Only call cleanup_tree_cfg if gloog
4005 2009-01-20 Sebastian Pop <sebastian.pop@amd.com>
4007 * graphite.c (gloog): Return true when code gen succeeded.
4008 (graphite_transform_loops): Do not call cleanup_tree_cfg if
4009 the code of the function did not changed. After cleanup_tree_cfg
4010 call rewrite_into_loop_closed_ssa to maintain the loop closed ssa
4013 2009-01-19 Sebastian Pop <sebastian.pop@amd.com>
4015 * graphite.c (stmt_simple_for_scop_p): Also handle cases when
4016 gimple_call_lhs is NULL.
4018 2009-01-16 Sebastian Pop <sebastian.pop@amd.com>
4019 Tobias Grosser <tobi.grosser@amd.com>
4021 * graphite.c (graphite_trans_scop_block): Do not block single
4024 2009-01-15 Sebastian Pop <sebastian.pop@amd.com>
4025 Tobias Grosser <tobi.grosser@amd.com>
4027 * graphite.c (build_scop_canonical_schedules): Start schedules at
4030 2009-01-15 Sebastian Pop <sebastian.pop@amd.com>
4031 Tobias Grosser <tobi.grosser@amd.com>
4033 * graphite.c (compare_prefix_loops): New.
4034 (build_scop_canonical_schedules): Rewritten.
4035 (graphite_transform_loops): Move build_scop_canonical_schedules
4036 after build_scop_iteration_domain.
4038 2009-01-14 Sebastian Pop <sebastian.pop@amd.com>
4039 Tobias Grosser <tobi.grosser@amd.com>
4041 * graphite.c (add_conditions_to_domain): Add the loops to
4042 the dimension of the iteration domain. Do copy the domain
4043 only when it exists.
4044 (build_scop_conditions_1): Do not call add_conditions_to_domain.
4045 (add_conditions_to_constraints): New.
4046 (can_generate_code_stmt, can_generate_code): Removed.
4047 (gloog): Do not call can_generate_code.
4048 (graphite_transform_loops): Call add_conditions_to_constraints
4049 after building the iteration domain.
4051 2009-01-14 Sebastian Pop <sebastian.pop@amd.com>
4052 Tobias Grosser <tobi.grosser@amd.com>
4053 Jan Sjodin <jan.sjodin@amd.com>
4055 * graphite.c (scan_tree_for_params): On substractions negate
4056 all the coefficients of the term.
4057 (clast_to_gcc_expression_red): New. Handle reduction expressions
4058 of more than two operands.
4059 (clast_to_gcc_expression): Call clast_to_gcc_expression_red.
4060 (get_vdef_before_scop): Handle also the case of default definitions.
4062 2009-01-14 Sebastian Pop <sebastian.pop@amd.com>
4065 * graphite.c (get_vdef_before_scop, scop_adjust_vphi): New.
4066 (scop_adjust_phis_for_liveouts): Call scop_adjust_vphi.
4067 (gloog): Do not call cleanup_tree_cfg.
4068 (graphite_transform_loops): Call cleanup_tree_cfg after all
4069 scops have been code generated.
4071 2009-01-13 Sebastian Pop <sebastian.pop@amd.com>
4073 * passes.c (init_optimization_passes): Schedule after
4074 graphite transforms pass_copy_prop, pass_dce_loop and pass_lim.
4076 2009-01-13 Sebastian Pop <sebastian.pop@amd.com>
4078 * graphite.c (expand_scalar_variables_stmt): Do not pass loop_p.
4080 (expand_scalar_variables_ssa_name): Do not pass loop_p. Fix comment.
4081 Set the type of an expression to the type of its assign statement.
4082 (expand_scalar_variables_expr): Do not pass loop_p.
4083 Fix comment. Stop recursion on tcc_constant or tcc_declaration.
4084 (copy_bb_and_scalar_dependences): Do not pass loop_p.
4085 (translate_clast): Update call to copy_bb_and_scalar_dependences.
4087 2009-01-11 Sebastian Pop <sebastian.pop@amd.com>
4089 * graphite.c (expand_scalar_variables_ssa_name): Set the type of
4090 an expression to the gimple_expr_type of its assign statement.
4091 (expand_scalar_variables_expr): Stop recursion on tcc_constant
4094 2009-01-11 Sebastian Pop <sebastian.pop@amd.com>
4096 PR tree-optimization/38786
4097 * testsuite/gcc.dg/graphite/pr38786.c: New.
4098 * graphite.c (expand_scalar_variables_ssa_name): New, outlined from
4099 the SSA_NAME case of expand_scalar_variables_expr.
4100 (expand_scalar_variables_expr): Also gather the scalar computation
4101 used to index the memory access.
4102 (expand_scalar_variables_stmt): Pass to expand_scalar_variables_expr
4103 the gimple_stmt_iterator where it inserts new code.
4105 2009-01-10 Sebastian Pop <sebastian.pop@amd.com>
4107 * testsuite/gcc.dg/graphite/block-3.c: Fix compile error on 32bit.
4109 2009-01-10 Sebastian Pop <sebastian.pop@amd.com>
4111 * opts.c (decode_options): Enable flag_graphite_identity and
4112 flag_loop_block in -O2 and above.
4114 2009-01-08 Sebastian Pop <sebastian.pop@amd.com>
4116 * libjava/classpath/lib/gnu/java/awt/peer/gtk/GtkMouseInfoPeer.class:
4117 Fix merge problem: replace with the file from trunk.
4119 2009-01-08 Sebastian Pop <sebastian.pop@amd.com>
4121 * Merge from mainline (r141727:143163).
4123 2009-01-07 Sebastian Pop <sebastian.pop@amd.com>
4124 Jan Sjodin <jan.sjodin@amd.com>
4126 PR tree-optimization/38559
4127 * testsuite/gcc.dg/graphite/pr38559.c: New.
4129 * graphite.c (debug_value, copy_constraint,
4130 swap_constraint_variables, scale_constraint_variable, ): New.
4131 (get_lower_bound, get_upper_bound): Removed.
4132 (graphite_trans_bb_strip_mine): Clean up this code that works
4133 only for constant number of iterations. Fully copy upper and
4134 lower bound constraints, not only the constant part of them.
4135 * graphite.h (debug_value): Declared.
4137 2009-01-06 Jan Sjodin <jan.sjodin@amd.com>
4139 PR tree-optimization/38492
4140 PR tree-optimization/38498
4141 * tree-check.c (operator_is_linear, scev_is_linear_expression): New.
4142 * tree-chrec.h (scev_is_linear_expression): Declared.
4143 * graphite.c (graphite_cannot_represent_loop_niter): New.
4144 (scopdet_basic_block_info): Call graphite_cannot_represent_loop_niter.
4145 (graphite_loop_normal_form): Use gcc_assert.
4146 (scan_tree_for_params): Use CASE_CONVERT.
4147 (phi_node_is_iv, bb_contains_non_iv_scalar_phi_nodes): New.
4148 (build_scop_conditions_1): Call bb_contains_non_iv_scalar_phi_nodes.
4149 Use gcc_assert. Discard scops that contain unhandled cases.
4150 (build_scop_conditions): Return a boolean status for unhandled cases.
4151 (strip_mine_profitable_p): Print the loop number, not its depth.
4152 (is_interchange_valid): Pass the depth of the loop nest, don't
4153 recompute it wrongly.
4154 (graphite_trans_bb_block): Same.
4155 (graphite_trans_bb_block): Print tentative of loop blocking.
4156 (graphite_trans_scop_block): Do not print that the loop has been
4158 (graphite_transform_loops): Do not handle scops that contain condition
4161 * testsuite/gcc.dg/graphite/pr38500.c: Fixed warning as committed
4163 * testsuite/gcc.dg/graphite/block-0.c: Update test.
4164 * testsuite/gcc.dg/graphite/block-1.c: Same.
4165 * testsuite/gcc.dg/graphite/block-2.c: Remove xfail and test for
4167 * testsuite/gcc.dg/graphite/block-4.c: Remove test for strip mine.
4168 * testsuite/gcc.dg/graphite/block-3.c: New.
4169 * testsuite/gcc.dg/graphite/pr38498.c: New.
4171 2008-12-22 Harsha Jagasia <harsha.jagasia@amd.com>
4173 PR tree-optimization/38510
4174 * gcc.dg/graphite/pr38510.c: New.
4175 * graphite.c (recompute_all_dominators): Call mark_irreducible_loops.
4176 (translate_clast): Call recompute_all_dominators before
4178 (gloog): Call recompute_all_dominators before graphite_verify.
4180 2008-12-12 Sebastian Pop <sebastian.pop@amd.com>
4182 PR tree-optimization/38492
4183 * graphite.c (rename_map_elt, debug_rename_elt,
4184 debug_rename_map_1, debug_rename_map, new_rename_map_elt,
4185 rename_map_elt_info, eq_rename_map_elts,
4186 get_new_name_from_old_name, bb_in_sese_p): Moved around.
4187 (sese_find_uses_to_rename_use): Renamed sese_build_livein_liveouts_use.
4188 (sese_find_uses_to_rename_bb): Renamed sese_build_livein_liveouts_bb.
4189 (sese_build_livein_liveouts): New.
4190 (new_sese, free_sese): New.
4191 (new_scop): Call new_sese.
4192 (free_scop): Call free_sese.
4193 (rename_variables_from_edge, rename_phis_end_scop): Removed.
4194 (register_old_new_names): Renamed register_old_and_new_names.
4195 (register_scop_liveout_renames, add_loop_exit_phis,
4196 insert_loop_close_phis, struct igp,
4197 default_liveout_before_guard, add_guard_exit_phis,
4198 insert_guard_phis, copy_renames): New.
4199 (translate_clast): Call insert_loop_close_phis and insert_guard_phis.
4200 (sese_add_exit_phis_edge): Renamed scop_add_exit_phis_edge.
4201 (rewrite_into_sese_closed_ssa): Renamed scop_insert_phis_for_liveouts.
4202 (scop_adjust_phis_for_liveouts): New.
4203 (gloog): Call scop_adjust_phis_for_liveouts.
4205 * graphite.h (struct sese): Documented. Added fields liveout,
4207 (SESE_LIVEOUT, SESE_LIVEIN, SESE_LIVEIN_VER, SESE_NUM_VER): New.
4208 (new_sese, free_sese, sese_build_livein_liveouts): Declared.
4209 (struct scop): Added field liveout_renames.
4210 (SCOP_LIVEOUT_RENAMES): New.
4212 2008-12-11 Sebastian Pop <sebastian.pop@amd.com>
4214 PR tree-optimization/38409
4215 * gcc.dg/graphite/pr38409.c: New.
4216 * graphite.c (nb_reductions_in_loop): Use simple_iv.
4218 2008-12-11 Sebastian Pop <sebastian.pop@amd.com>
4220 * graphite.c (gcc_type_for_cloog_iv): By default return
4222 (graphite_create_new_loop): Don't fold_convert the already
4223 fold_convert-ed expression.
4225 2008-12-11 Harsha Jagasia <harsha.jagasia@amd.com>
4227 PR tree-optimization/38446
4228 * gcc.dg/graphite/pr38446.c: New.
4229 * graphite.c (register_bb_in_sese): New.
4230 (bb_in_sese_p): Check if bb belongs to sese region by explicitly
4231 looking at the bbs in the region.
4232 * graphite.h (sese): Add region_basic_blocks pointer set to
4233 structure and initialize at the time of defining new scop.
4235 2008-12-11 Tobias Grosser <grosser@fim.uni-passau.de>
4237 * graphite.c (new_graphite_bb): Initialize GBB_STATIC_SCHEDULE.
4238 (find_params_in_bb): Do not free data refs.
4239 (free_graphite_bb): Add FIXME on disabled free_data_refs.
4241 2008-12-11 Sebastian Pop <sebastian.pop@amd.com>
4243 * testsuite/gcc.dg/graphite/scop-16.c: Test only scop specific info.
4244 * testsuite/gcc.dg/graphite/scop-17.c: Same.
4245 * testsuite/gcc.dg/graphite/block-5.c: New.
4246 * testsuite/gcc.dg/graphite/block-6.c: New.
4247 * testsuite/gcc.dg/graphite/pr37485.c: Clean dump file after.
4248 * testsuite/gcc.dg/graphite/pr37684.c: Same.
4249 * testsuite/gcc.dg/graphite/block-2.c: Same.
4251 * graphite.c (struct ivtype_map_elt): New.
4252 (debug_ivtype_elt, debug_ivtype_map_1, debug_ivtype_map,
4253 new_ivtype_map_elt, ivtype_map_elt_info, eq_ivtype_map_elts,
4254 gcc_type_for_cloog_iv): New.
4255 (loop_iv_stack_patch_for_consts): Use the type of the induction
4256 variable from the original loop, except for the automatically
4257 generated loops, i.e., in the case of a strip-mined loop, in
4258 which case there is no original loop: in that case just use
4260 (new_graphite_bb): Initialize GBB_CLOOG_IV_TYPES.
4261 (free_graphite_bb): Free GBB_CLOOG_IV_TYPES.
4262 (clast_name_to_gcc): Accept params to be NULL.
4263 (clast_to_gcc_expression): Take an extra parameter for the type.
4264 Convert to that type all the expressions built by this function.
4265 (gcc_type_for_clast_expr, gcc_type_for_clast_eq): New.
4266 (graphite_translate_clast_equation): Compute the type of the
4267 clast_equation before translating its LHS and RHS.
4268 (clast_get_body_of_loop, gcc_type_for_iv_of_clast_loop): New.
4269 (graphite_create_new_loop): Compute the type of the induction
4270 variable before translating the lower and upper bounds and before
4271 creating the induction variable.
4272 (rename_variables_from_edge, rename_phis_end_scop): New.
4273 (copy_bb_and_scalar_dependences): Call rename_phis_end_scop.
4274 (sese_add_exit_phis_edge): Do not use integer_zero_node.
4275 (find_cloog_iv_in_expr, compute_cloog_iv_types_1,
4276 compute_cloog_iv_types): New.
4277 (gloog): Call compute_cloog_iv_types before starting the
4278 translation of the clast.
4280 * graphite.h (struct graphite_bb): New field cloog_iv_types.
4281 (GBB_CLOOG_IV_TYPES): New.
4282 (debug_ivtype_map): Declared.
4283 (oldiv_for_loop): New.
4285 2008-12-10 Tobias Grosser <grosser@fim.uni-passau.de>
4288 * graphite.c (new_scop): Initialize SCOP_ADD_PARAMS.
4289 (param_index): Assert if parameter is not know after parameter
4291 (find_params_in_bb): Detect params directly in GBB_CONDITIONS.
4292 (find_scop_parameters): Mark, that we have finished parameter
4294 (graphite_transform_loops): Move condition detection before parameter
4296 * graphite.h (struct scop): Add SCOP_ADD_PARAMS.
4297 * testsuite/gfortran.dg/graphite/pr38459.f90: New.
4299 2008-12-09 Tobias Grosser <grosser@fim.uni-passau.de>
4301 * graphite.c (graphite_transform_loops): Always call find_transform ()
4302 in ENABLE_CHECKING. So we test these code paths, even if we do not
4305 2008-12-09 Tobias Grosser <grosser@fim.uni-passau.de>
4307 * graphite.c (print_graphite_bb): Fix printing to file != dump_file.
4308 (print_scop): Ditto.
4310 2008-12-08 Tobias Grosser <grosser@fim.uni-passau.de>
4313 Fix testsuite/gfortran.dg/graphite/id-3.f90.
4314 * graphite.c (scopdet_basic_block_info): Fix bug that found some
4315 regions more than once.
4317 2008-12-03 Sebastian Pop <sebastian.pop@amd.com>
4319 Fix testsuite/gfortran.dg/graphite/id-4.f90.
4320 * graphite.c (scan_tree_for_params): Do not compute the multiplicand
4323 2008-12-03 Sebastian Pop <sebastian.pop@amd.com>
4325 Fix testsuite/gfortran.dg/graphite/id-1.f90.
4326 * graphite.c (gmp_cst_to_tree): Pass the type in parameter.
4327 (loop_iv_stack_patch_for_consts): Update use of gmp_cst_to_tree.
4328 (max_precision_type): New.
4329 (value_clast): Removed.
4330 (clast_to_gcc_expression): Be more careful to types of expressions.
4331 Use max_precision_type and update use of gmp_cst_to_tree.
4332 (graphite_translate_clast_equation): Use max_precision_type.
4333 (graphite_create_guard_cond_expr): Do not use integer_type_node,
4334 use the type of the condition.
4335 (graphite_create_new_loop): Do not use integer_type_node, use the
4336 max_precision_type of lb and ub.
4338 2008-12-03 Sebastian Pop <sebastian.pop@amd.com>
4340 * graphite.c (build_scops_1): Initialize open_scop.exit
4343 2008-12-02 Sebastian Pop <sebastian.pop@amd.com>
4345 * testsuite/gcc.dg/graphite/pr38084.c: New.
4346 * testsuite/gfortran.dg/graphite/id-1.f90: New.
4347 * testsuite/gfortran.dg/graphite/id-2.f90: New.
4348 * testsuite/gfortran.dg/graphite/id-3.f90: New.
4349 * testsuite/gfortran.dg/graphite/id-4.f90: New.
4350 * testsuite/gfortran.dg/graphite/pr37857.f90: New.
4352 2008-12-02 Sebastian Pop <sebastian.pop@amd.com>
4353 Jan Sjodin <jan.sjodin@amd.com>
4354 Harsha Jagasia <harsha.jagasia@amd.com>
4366 * testsuite/gcc.dg/graphite/pr38073.c: New.
4367 * testsuite/gcc.dg/graphite/pr37928.c: New.
4368 * testsuite/gcc.dg/graphite/pr37883.c: New.
4369 * testsuite/gcc.dg/graphite/pr38125.c: New.
4370 * testsuite/gfortran.dg/graphite/pr38083.f90: New.
4371 * testsuite/gfortran.dg/graphite/pr37852.f90: New.
4372 * testsuite/gfortran.dg/graphite/pr37980.f90: New.
4374 * testsuite/gcc.dg/graphite/scop-18.c: Remove reduction, test for
4375 the number of detected scops. Copy exact same test for loop
4377 * testsuite/gcc.dg/graphite/block-1.c: Fix the number of expected
4378 loops to be blocked as reductions are not handled.
4379 * testsuite/gcc.dg/graphite/block-4.c: ...here. New.
4381 * tree-phinodes.c (remove_phi_nodes): New, extracted from...
4382 * tree-cfg.c (remove_phi_nodes_and_edges_for_unreachable_block):
4384 * tree-flow.h (remove_phi_nodes, canonicalize_loop_ivs): Declared.
4385 * Makefile.in (graphite.o): Depend on value-prof.h.
4386 (graphite.o-warn): Removed -Wno-error.
4387 * tree-parloops.c (canonicalize_loop_ivs): Allow reduction_list
4388 to be a NULL pointer. Call update_stmt. Return the newly created
4389 cannonical induction variable.
4391 * graphite.h (debug_rename_map): Declared. Fix some comments.
4393 * graphite.c: Reimplement the code generation from graphite to gimple.
4394 Include value-prof.h.
4395 (loop_iv_stack_get_iv): Do not return NULL for constant substitutions.
4396 (get_old_iv_from_ssa_name): Removed.
4397 (graphite_stmt_p): New.
4398 (new_graphite_bb): Test for useful statements before building a
4399 graphite statement for the basic block.
4400 (free_graphite_bb): Do not free GBB_DATA_REFS: this is a bug
4401 in free_data_ref that calls BITMAP_FREE (DR_VOPS (dr)) without
4403 (recompute_all_dominators, graphite_verify,
4404 nb_reductions_in_loop, graphite_loop_normal_form): New.
4405 (scop_record_loop): Call graphite_loop_normal_form.
4406 (build_scop_loop_nests): Iterate over all the blocks of the
4407 function instead of relying on the incomplete information from
4408 SCOP_BBS. Return the success of the operation.
4409 (find_params_in_bb): Use the data from GBB_DATA_REFS.
4410 (add_bb_domains): Removed.
4411 (build_loop_iteration_domains): Don't call add_bb_domains.
4412 Add the iteration domain only to the basic blocks that have been
4413 translated to graphite.
4414 (build_scop_conditions_1): Add constraints only if the basic
4415 block have been translated to graphite.
4416 (build_scop_data_accesses): Completely disabled until data
4417 dependence is correctly implemented.
4418 (debug_rename_elt, debug_rename_map_1, debug_rename_map): New.
4419 (remove_all_edges_1, remove_all_edges): Removed.
4420 (get_new_name_from_old_name): New.
4421 (graphite_rename_variables_in_stmt): Renamed
4422 rename_variables_in_stmt. Call get_new_name_from_old_name.
4423 Use replace_exp and update_stmt.
4424 (is_old_iv): Renamed is_iv.
4425 (expand_scalar_variables_stmt): Extra parameter for renaming map.
4426 Use replace_exp and update_stmt.
4427 (expand_scalar_variables_expr): Same. Use the map to get the
4428 new names for the renaming of induction variables and for the
4429 renaming of variables after a basic block has been copied.
4430 (expand_scalar_variables): Same.
4431 (graphite_rename_variables): Renamed rename_variables.
4432 (move_phi_nodes): Removed.
4433 (get_false_edge_from_guard_bb): New.
4434 (build_iv_mapping): Do not insert the induction variable of a
4435 loop in the renaming iv map if the basic block does not belong
4437 (register_old_new_names, graphite_copy_stmts_from_block,
4438 copy_bb_and_scalar_dependences): New.
4439 (translate_clast): Heavily reimplemented: copy basic blocks,
4440 do not move them. Finally, in call cleanup_tree_cfg in gloog.
4441 At each translation step call graphite_verify ensuring the
4442 consistency of the SSA, loops and dominators information.
4443 (collect_virtual_phis, find_vdef_for_var_in_bb,
4444 find_vdef_for_var_1, find_vdef_for_var,
4445 patch_phis_for_virtual_defs): Removed huge hack.
4446 (mark_old_loops, remove_dead_loops, skip_phi_defs,
4447 collect_scop_exit_phi_args, patch_scop_exit_phi_args,
4448 gbb_can_be_ignored, scop_remove_ignoreable_gbbs, ): Removed.
4449 (remove_sese_region, ifsese, if_region_entry, if_region_exit,
4450 if_region_get_condition_block, if_region_set_false_region,
4451 create_if_region_on_edge, move_sese_in_condition, bb_in_sese_p,
4452 sese_find_uses_to_rename_use, sese_find_uses_to_rename_bb,
4453 sese_add_exit_phis_edge, sese_add_exit_phis_var,
4454 rewrite_into_sese_closed_ssa): New.
4455 (gloog): Remove dead code. Early return if code cannot be
4456 generated. Call cleanup_tree_cfg once the scop has been code
4458 (graphite_trans_scop_block, graphite_trans_loop_block): Do not
4459 block loops with less than two loops.
4460 (graphite_apply_transformations): Remove the call to
4461 scop_remove_ignoreable_gbbs.
4462 (limit_scops): When build_scop_loop_nests fails, continue on
4463 the next scop. Fix open_scop.entry.
4464 (graphite_transform_loops): Call recompute_all_dominators: force the
4465 recomputation of correct CDI_DOMINATORS and CDI_POST_DOMINATORS.
4466 Call initialize_original_copy_tables and free_original_copy_tables
4467 to be able to copy basic blocks during code generation.
4468 When build_scop_loop_nests fails, continue on next scop.
4469 (value_clast): New union.
4470 (clast_to_gcc_expression): Fix type cast warning.
4472 2008-11-09 Sebastian Pop <sebastian.pop@amd.com>
4474 * Merge from mainline (r140838:141727).
4476 2008-11-05 Tobias Grosser <grosser@fim.uni-passau.de>
4480 * graphite.c (scan_tree_for_params): Add POINTER_PLUS_EXPR.
4482 2008-11-05 Tobias Grosser <grosser@fim.uni-passau.de>
4486 * graphite.c (scopdet_basic_block_info): Fix loops with multiple
4487 exits and conditions.
4488 * testsuite/gcc.dg/graphite/pr37943.c: New.
4490 2008-10-23 Tobias Grosser <grosser@fim.uni-passau.de>
4493 * graphite.c (gloog): Replace EXIT_BLOCK_PTR with scop exit.
4495 2008-10-23 Tobias Grosser <grosser@fim.uni-passau.de>
4497 * doc/invoke.texi: Fix spaces.
4499 2008-10-22 Sebastian Pop <sebastian.pop@amd.com>
4501 PR tree-optimization/37891
4502 Reverted last commit.
4503 * graphite.c (create_single_entry_edge): Set
4504 EDGE_IRREDUCIBLE_LOOP and BB_IRREDUCIBLE_LOOP.
4506 2008-10-21 Sebastian Pop <sebastian.pop@amd.com>
4507 Mitul Thakkar <mitul.thakkar@amd.com>
4509 * graphite.c (create_single_entry_edge): Set
4510 EDGE_IRREDUCIBLE_LOOP and BB_IRREDUCIBLE_LOOP.
4512 2008-10-16 Tobias Grosser <grosser@fim.uni-passau.de>
4514 * doc/invoke.texi: Add -fgraphite-identity.
4515 * graphite.c (graphite_apply_transformations): Check for
4516 -fgraphite-identity.
4517 * toplev.c (process_options): Add flag_graphite_identity.
4518 * tree-ssa-loop.c: Add flag_graphite_identity.
4520 2008-10-14 Sebastian Pop <sebastian.pop@amd.com>
4522 Undo changes from 2008-10-02:
4523 * tree-ssa-loop-ivopts.c (rewrite_use_nonlinear_expr): Convert
4524 operand type when copying the operand to a variable of different type.
4525 * cfgloopmanip.c (create_empty_loop_on_edge): Write exit condition
4526 with the IV name after increment.
4528 2008-10-14 Sebastian Pop <sebastian.pop@amd.com>
4529 Harsha Jagasia <harsha.jagasia@amd.com>
4531 PR tree-optimization/37828
4532 * testsuite/gcc.dg/graphite/pr37828.c: New.
4533 * graphite.c (graphite_trans_loop_block): Do not loop block
4534 single nested loops.
4536 2008-10-09 Harsha Jagasia <harsha.jagasia@amd.com>
4537 Sebastian Pop <sebastian.pop@amd.com>
4539 * graphite.c (struct rename_map_elt, new_rename_map_elt,
4540 rename_map_elt_info, eq_rename_map_elts): New.
4541 (graphite_rename_ivs_stmt): Renamed graphite_rename_variables_in_stmt.
4542 (expand_scalar_variables_expr): Change parameters.
4543 (expand_scalar_variables_stmt): Same.
4544 (expand_scalar_variables): Same.
4545 (graphite_rename_ivs): Rename graphite_rename_variables.
4546 (build_iv_mapping): New.
4547 (translate_clast): Call build_iv_mapping.
4548 * graphite.h (gbb_p): New name.
4550 2008-10-03 Harsha Jagasia <harsha.jagasia@amd.com>
4552 PR tree-optimization/37684
4553 * gcc.dg/graphite/pr37684.c: New.
4554 * graphite.c (exclude_component_ref): New.
4555 (is_simple_operand): Call exclude_component_ref.
4557 2008-10-02 Jan Sjodin <jan.sjodin@amd.com>
4558 Harsha Jagasia <harsha.jagasia@amd.com>
4560 PR tree-optimization/37485
4561 * gcc.dg/graphite/block-2.c: New
4562 * graphite.c (gmp_cst_to_tree): Moved.
4563 (iv_stack_entry_is_constant): New.
4564 (iv_stack_entry_is_iv): New.
4565 (loop_iv_stack_push): Renamed to loop_iv_stack_push_iv.
4566 (loop_iv_stack_insert_constant): New.
4567 (loop_iv_stack_pop): Use new datatpype.
4568 (loop_iv_stack_get_iv): Same.
4569 (loop_iv_stack_get_iv_from_name): Same.
4570 (loop_iv_stack_debug): Renamed to debug_loop_iv_stack.
4571 (loop_iv_stack_patch_for_consts): New.
4572 (loop_iv_stack_remove_constants): New.
4573 (graphite_create_new_loop): Use loop_iv_stack_push_iv.
4574 (translate_clast): Call loop_iv_stack_patch_for_consts and
4575 loop_iv_stack_remove_constants.
4576 (gloog): Use new datatype. Redirect construction edge to end
4577 block to avoid accidental deletion.
4578 * graphite.h (enum iv_stack_entry_kind): New. Tag for data in
4580 (union iv_stack_entry_data): New. Data in iv stack entry.
4581 (struct iv_stack_entry): New. Datatype for iv stack entries.
4583 2008-10-02 Sebastian Pop <sebastian.pop@amd.com>
4585 * tree-ssa-loop-ivopts.c (rewrite_use_nonlinear_expr): Convert
4586 operand type when copying the operand to a variable of different type.
4588 2008-10-02 Sebastian Pop <sebastian.pop@amd.com>
4590 * cfgloopmanip.c (create_empty_loop_on_edge): Write exit condition
4591 with the IV name after increment.
4593 2008-10-02 Sebastian Pop <sebastian.pop@amd.com>
4595 * Merge from mainline (r140164:140838).
4597 2008-09-10 Konrad Trifunovic <konrad.trifunovic@inria.fr>
4599 * graphite-data-ref.c: New.
4600 * graphite.c (print_scop): Also dump the dependence graph.
4601 (bb_in_scop_p, loop_in_scop_p, nb_loops_around_gb): Moved...
4602 (new_scop): Initialize SCOP_DEP_GRAPH.
4603 (build_scop_dynamic_schedules): New.
4604 (build_access_matrix_with_af): Fixed column numbering.
4605 (graphite_transform_loops): Call build_scop_dynamic_schedules.
4606 * graphite.h: Add ifndef/define guards against multiple inclusion.
4607 (struct scop): Add dep_graph field.
4608 (SCOP_DEP_GRAPH): Defined.
4609 (ref_nb_loops): Fixed and moved to other position.
4610 (bb_in_scop_p, loop_in_scop_p, nb_loops_around_gb): ... here.
4611 (nb_loops_around_loop_in_scop): New.
4612 (graphite_dump_dependence_graph): Declared.
4613 (graphite_build_rdg_all_levels): Declared.
4614 (graphite_test_dependence): Declared.
4615 * Makefile.in (graphite-data-ref.o): New target.
4617 2008-09-09 Sebastian Pop <sebastian.pop@amd.com>
4619 * Merge from mainline (139870:140164).
4621 2008-09-01 Sebastian Pop <sebastian.pop@amd.com>
4623 * Merge from mainline (138275:139870).
4624 * testsuite/gcc.dg/graphite/scop-matmult.c: XFailed as one of
4625 the commits from trunk broke the niter detection.
4627 2008-09-01 Sebastian Pop <sebastian.pop@amd.com>
4629 * graphite.c: Add more documentation. Fix formatting.
4630 (debug_loop_vec, debug_oldivs, loop_iv_stack,
4631 loop_iv_stack_debug): Moved...
4632 (schedule_to_scattering): Move before use.
4633 (dot_all_scops): Include in "#if 0" the code for system
4636 * graphite.h: (debug_loop_vec, debug_oldivs, loop_iv_stack,
4637 loop_iv_stack_debug): ...here.
4639 2008-08-29 Jan Sjodin <jan.sjodin@amd.com>
4641 * tree-phinodes.c (make_phi_node): Extern.
4642 (add_phi_node_to_bb): New.
4643 (create_phi_node): Call add_phi_node_to_bb.
4644 * tree-ssa-loop-ivopts.c (get_phi_with_result): New.
4645 (remove_statement): Handle case where stored phi was updated
4646 and is no longer the same.
4647 * graphite.c (is_parameter): New.
4649 (expand_scalar_variables_expr): New.
4650 (expand_scalar_variables_stmt): New.
4651 (expand_scalar_variables): New.
4652 (move_phi_nodes): Create new phi instead of moving old one.
4653 (translate_clast): Call expand_scalar_variables.
4654 (find_vdef_for_var_in_bb): Also scan regular definitions.
4655 (skip_phi_defs): New.
4656 (collect_scop_exit_phi_args): New.
4657 (patch_scop_exit_phi_args): New.
4658 (gloog): Patch phis after scop.
4659 * tree-flow.h: (add_phi_node_to_bb): Declared.
4660 (make_phi_node): Declared.
4662 2008-08-26 Sebastian Pop <sebastian.pop@amd.com>
4664 * graphite.c (end_scop): Split the entry of the scop when it
4665 is the header of the loop in which the scop is ending.
4666 (build_scops_1, limit_scops): Update uses of end_scop.
4668 2008-08-26 Sebastian Pop <sebastian.pop@amd.com>
4670 * graphite.c (dot_all_scops_1): Do not fail on uninitialized
4671 SCOP_ENTRY or SCOP_EXIT.
4673 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
4675 * graphite.c (get_construction_edge): Removed.
4676 (gloog): Construction edge is the scop entry edge.
4678 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
4680 * graphite.c (can_generate_for_scop): Removed.
4681 (gloog): Do not call it.
4683 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
4685 * graphite.c (new_scop): Entry of a scop is an edge.
4686 Initialize SESE region.
4687 (free_scop): Free SESE region.
4688 (build_scops_1, scopdet_bb_info): Work on edges, not on bbs.
4689 (split_difficult_bb): New, split from end_scop.
4690 (end_scop): Exit of a scop is an edge.
4691 (build_scop_bbs): Never check CDI_POST_DOMINATORS: this info is
4692 not automatically updated and thus is always wrong.
4693 * graphite.h (struct sese): New.
4696 (struct scop): New field for a SESE region. Remove entry, exit.
4697 (SCOP_ENTRY, SCOP_EXIT): Update definitions to match same
4698 semantics as before. Moved comment around.
4700 2008-08-25 Tobias Grosser <grosser@fim.uni-passau.de>
4701 Sebastian Pop <sebastian.pop@amd.com>
4703 * graphite.c (graphite_transform_loops): Always enable gloog
4704 and find_transform when ENABLE_CHECKING.
4706 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
4708 * graphite.c (graphite_transform_loops): Move pretty printer
4709 of SCOPs before doing any transform. Remove call to print_scops
4710 and dot_all_scops_1.
4712 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
4714 * graphite.c (dump_gbb_conditions): Don't try to print NULL pointers.
4715 (print_graphite_bb): Same.
4717 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
4719 * graphite.c (dot_all_scops_1): Cleanup.
4720 (move_scops): Fix comment.
4722 2008-08-25 Sebastian Pop <sebastian.pop@amd.com>
4724 * graphite.c (build_scop_bbs): Revert commit 139355:
4726 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4727 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
4729 * graphite.c (build_scop_bbs): Factor up code.
4731 2008-08-25 Tobias Grosser <grosser@fim.uni-passau.de>
4733 * graphite.c (gloog): Update dominator info.
4735 2008-08-25 Tobias Grosser <grosser@fim.uni-passau.de>
4737 * graphite.c (remove_cond_exprs): Do not fail on empty bbs.
4739 2008-08-24 Sebastian Pop <sebastian.pop@amd.com>
4741 * graphite.c (new_graphite_bb): Remove GBB_INDEX_TO_NUM_MAP
4743 (free_graphite_bb): Remove GBB_INDEX_TO_NUM_MAP free.
4744 (translate_clast): Correct formatting.
4745 * graphite.h (struct num_map): Removed.
4746 (struct graphite_bb): Remove num_map field.
4747 (GBB_INDEX_TO_NUM_MAP): Removed.
4749 2008-08-24 Sebastian Pop <sebastian.pop@amd.com>
4751 * graphite.c (build_access_matrix_with_af): Fix comments.
4752 (build_scop_data_accesses): Same.
4754 2008-08-24 Sebastian Pop <sebastian.pop@amd.com>
4756 * graphite.c (build_scop_data_accesses): Don't construct
4757 access matrices. Add a FIXME and an assert condition that
4758 should pass when the access matrices will be needed.
4760 2008-08-24 Sebastian Pop <sebastian.pop@amd.com>
4762 * tree-data-ref.c (stmt_simple_memref_p): Don't call
4764 * graphite.c (build_graphite_bb): Renamed new_graphite_bb.
4765 Moved close by free_graphite_bb.
4766 (free_graphite_bb): Call free_data_refs. Reset bb->aux.
4767 (new_scop): Move close by free_scop.
4768 (graphite_transform_loops): Avoid linear scan to reset bb->aux.
4770 2008-08-22 Jan Sjodin <jan.sjodin@amd.com>
4772 * cfgloopmanip.c (create_empty_if_region_on_edge): New.
4773 * graphite.c (clast_to_gcc_expression): Call gmp_cst_to_tree
4774 instead of recursive call.
4775 (graphite_translate_clast_equation): New.
4776 (graphite_create_guard_cond_expr): New.
4777 (graphite_create_new_guard): New.
4778 (get_stack_index_from_iv): Removed.
4779 (graphite_rename_ivs_stmt): Use gbb_loop_index.
4780 (get_true_edge_from_guard_bb): New.
4781 (translate_clast): Handle stmt_guard in clast.
4782 (get_construction_edge): Allow construction edge detection for
4783 a scope entry with multiple predecessors if one predecessor is
4784 the immediate dominator of scope entry.
4785 (can_generate_code_stmt): Enable code generation for clast_guard.
4786 (gloog): Use correct context loop. Removed check for post dominators.
4787 * cfgloop.h (create_empty_if_region_on_edge): Declared.
4789 2008-08-21 Sebastian Pop <sebastian.pop@amd.com>
4791 * graphite.c (remove_dead_loops): Document better which
4794 2008-08-21 Sebastian Pop <sebastian.pop@amd.com>
4796 * Makefile.in: Rename POLYLIBLIBS and POLYLIBINC to PPLLIBS
4798 (graphite.o): Also depends on pointer-set.h.
4800 2008-08-21 Sebastian Pop <sebastian.pop@amd.com>
4802 * graphite.c (scop_record_loop): Fix compile warning.
4804 2008-08-21 Harsha Jagasia <harsha.jagasia@amd.com>
4805 Sebastian Pop <sebastian.pop@amd.com>
4807 * graphite.c (scop_record_loop): DECL_NAME can be NULL.
4809 2008-08-21 Sebastian Pop <sebastian.pop@amd.com>
4811 * graphite.c (build_graphite_bb): Initialize bb->aux to
4812 point to the graphite_bb_p.
4813 (graphite_bb_from_bb): Renamed gbb_from_bb; returns the
4815 (add_bb_domains): Does not use the scop parameter.
4816 (graphite_transform_loops): Clean bb->aux at the end.
4818 2008-08-20 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
4819 Sebastian Pop <sebastian.pop@amd.com>
4821 * testsuite/lib/target-supports.exp
4822 (check_effective_target_fgraphite): New.
4824 * testsuite/gcc.dg/graphite/graphite.exp: Early exit when
4825 check_effective_target_fgraphite returns false.
4826 Set dg-do-what-default to compile.
4827 (scan-graphite-dump-times): Removed.
4828 * testsuite/gfortran.dg/graphite/graphite.exp: Same.
4830 * testsuite/gcc.dg/graphite/scop-0.c: Do not use "dg-do compile".
4831 Use scan-tree-dump-times instead of scan-graphite-dump-times.
4832 * testsuite/gcc.dg/graphite/scop-1.c: Same.
4833 * testsuite/gcc.dg/graphite/scop-2.c: Same.
4834 * testsuite/gcc.dg/graphite/scop-3.c: Same.
4835 * testsuite/gcc.dg/graphite/scop-4.c: Same.
4836 * testsuite/gcc.dg/graphite/scop-5.c: Same.
4837 * testsuite/gcc.dg/graphite/scop-6.c: Same.
4838 * testsuite/gcc.dg/graphite/scop-7.c: Same.
4839 * testsuite/gcc.dg/graphite/scop-8.c: Same.
4840 * testsuite/gcc.dg/graphite/scop-9.c: Same.
4841 * testsuite/gcc.dg/graphite/scop-10.c: Same.
4842 * testsuite/gcc.dg/graphite/scop-11.c: Same.
4843 * testsuite/gcc.dg/graphite/scop-12.c: Same.
4844 * testsuite/gcc.dg/graphite/scop-13.c: Same.
4845 * testsuite/gcc.dg/graphite/scop-matmult.c: Same.
4846 * testsuite/gcc.dg/graphite/scop-14.c: Same.
4847 * testsuite/gcc.dg/graphite/scop-15.c: Same.
4848 * testsuite/gcc.dg/graphite/block-0.c: Same.
4849 * testsuite/gcc.dg/graphite/scop-16.c: Same.
4850 * testsuite/gcc.dg/graphite/block-1.c: Same.
4851 * testsuite/gcc.dg/graphite/scop-17.c: Same.
4852 * testsuite/gcc.dg/graphite/scop-18.c: Same.
4853 * testsuite/gfortran.dg/graphite/block-1.f90: Same.
4854 * testsuite/gfortran.dg/graphite/scop-1.f: Same.
4855 * testsuite/gfortran.dg/graphite/block-2.f: Same.
4857 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4859 * graphite.c: Fix some XXX comments.
4860 (build_scop_dynamic_schedules): Removed.
4862 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4864 * graphite.h (scop_max_loop_depth): Moved...
4865 * graphite.c (scop_max_loop_depth): ...here.
4866 (remove_all_edges_1): New.
4867 (remove_all_edges): Factored code.
4868 (remove_cond_exprs): Check only the last statement for
4869 a GIMPLE_COND expression.
4871 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4873 * graphite.c (scan_tree_for_params): Early return when the
4874 expression is a chrec_dont_know. Handle case NEGATE_EXPR.
4875 (find_scop_parameters): Factor out code.
4876 (graphite_trans_bb_strip_mine): Remove dead code.
4878 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4880 * graphite.c (clast_to_gcc_expression, graphite_create_new_loop,
4881 graphite_trans_bb_move_loop): Factor asserts.
4882 (gloog): Perform sanity checks only for ENABLE_CHECKING.
4883 Do not call calculate_dominance_info and estimate_bb_frequencies.
4885 2008-08-20 Jan Sjodin <jan.sjodin@amd.com>
4887 * graphite.c (create_loops_mapping, free_loops_mapping,
4888 create_loops_mapping_num, debug_loop_mapping_1,
4889 debug_loop_mapping, graphite_loops_mapping_max_loop_num,
4890 get_loop_mapping_for_num, graphite_loops_mapping_add_child,
4891 graphite_loops_mapping_add_child_num,
4892 graphite_loops_mapping_insert_child,
4893 graphite_loops_mapping_parent, get_loop_mapped_depth_for_num,
4894 get_loop_mapped_depth, split_loop_mapped_depth_for_num,
4895 loop_mapped_depth_split_loop, swap_loop_mapped_depth_for_num,
4896 create_num_from_index, get_num_from_index,
4897 swap_loop_mapped_depth): Removed.
4898 (new_scop): Do not initialize SCOP_LOOPS_MAPPING.
4899 (free_scop): Do not call free_loops_mapping.
4900 (graphite_get_new_iv_stack_index_from_old_iv): Renamed
4901 get_stack_index_from_iv. Use GBB_LOOPS instead of calling
4902 get_loop_mapped_depth.
4903 (graphite_trans_bb_move_loop): Do not update the loop mapping.
4904 (graphite_trans_bb_strip_mine): Same.
4905 * graphite.h (graphite_loops_mapping, graphite_loop_node): Removed.
4906 (struct scop): Remove field loops_mapping.
4908 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4909 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
4911 * graphite.c (scop_record_loop): Factor out one level of the
4912 condition by early return.
4913 (build_scop_loop_nests): Format following FSF coding style.
4914 (build_scop_dynamic_schedules): Factor out code.
4915 (scopdet_bb_info): Reindent. Default case should not be reachable.
4917 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4918 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
4920 * graphite.c (loop_affine_expr): Check for DECL_P or struct
4921 assignments that are not handled as simple operands for now.
4923 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4924 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
4926 * graphite.c (build_scop_bbs): Factor up code.
4928 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4929 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
4931 * graphite.c (stmt_simple_for_scop_p): Factor code out
4933 (enum gbb_type): New. Group all the GBB_* types under it.
4934 (is_loop_exit): Moved...
4935 (end_scop): Enable BB spliting.
4936 * cfgloop.c (is_loop_exit): ...here. Reimplemented.
4937 * cfgloop.h (is_loop_exit): Declared.
4939 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4941 * doc/invoke.texi: Remove strides from examples containing
4942 DO loops when the strides are equal to 1.
4944 2008-08-20 Harsha Jagasia <harsha.jagasia@amd.com>
4945 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
4947 * graphite.c (graphite_trans_scop_block): Or the result with
4948 the result from graphite_trans_loop_block.
4949 * testsuite/gcc.dg/graphite/block-1.c: New.
4950 * testsuite/gfortran.dg/graphite/block-1.f90: New.
4951 * testsuite/gfortran.dg/graphite/block-2.f: New.
4953 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4955 * graphite.c (graphite_transform_loops): Call cloog_initialize
4958 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4960 * tree-data-ref.c) (stmt_simple_memref_p): New.
4961 * tree-data-ref.h (stmt_simple_memref_p): Declared.
4962 * graphite.c (stmt_simple_memref_for_scop_p): Removed.
4963 (is_simple_operand): Call stmt_simple_memref_p.
4965 * testsuite/gcc.dg/graphite/scop-matmult.c: Updated for not
4966 using pointer arithmetic, as this is optimized by PRE and
4967 makes the code too difficult to analyze.
4969 * testsuite/gcc.dg/graphite/scop-18.c: Same.
4971 2008-08-20 Sebastian Pop <sebastian.pop@amd.com>
4973 * gdbinit.in (pgg): New.
4975 2008-08-15 Tobias Grosser <grosser@fim.uni-passau.de>
4977 * graphite.c (graphite_trans_loop_block): Fix warning.
4979 2008-08-15 Tobias Grosser <grosser@fim.uni-passau.de>
4981 * graphite.c (graphite_trans_loop_block): Fix my merge error.
4983 2008-08-15 Tobias Grosser <grosser@fim.uni-passau.de>
4985 * graphite.c (graphite_trans_bb_block): Remove check for
4986 flag_loop_strip_mine, flag_loop_block, flag_loop_interchange.
4987 Check if loop blocking is profitable for every loop, before applying
4989 (graphite_apply_transformations): Call graphite_trans_bb_block only,
4990 if flag_loop_block is set.
4992 2008-08-14 Sebastian Pop <sebastian.pop@amd.com>
4994 * graphite.c: Add some more documentation for the loop
4997 2008-08-14 Sebastian Pop <sebastian.pop@amd.com>
4999 * Makefile.in (tree-data-ref.o): Remove dependence on graphite.h.
5000 * graphite.c: Format on less than 80 columns.
5003 2008-08-14 Sebastian Pop <sebastian.pop@amd.com>
5005 * cfgloopmanip.c (loopify): Use update_dominators_in_loop.
5007 2008-08-14 Sebastian Pop <sebastian.pop@amd.com>
5009 * doc/invoke.texi (floop-block, floop-strip-mine,
5010 floop-interchange): Update documentation with examples.
5012 2008-08-13 Sebastian Pop <sebastian.pop@amd.com>
5014 * cfgloopmanip.c (create_empty_loop_on_edge): Don't call
5016 * graphite.c (graphite_create_new_loop): Call add_referenced_var.
5018 2008-08-13 Sebastian Pop <sebastian.pop@amd.com>
5020 * cfgloopmanip.c (create_empty_loop_on_edge): Improve documentation.
5021 Factor gcc_asserts into a single one. Use force_gimple_operand_gsi.
5022 * tree-scalar-evolution.c: Revert useless changes.
5023 * tree-phinodes.c: Same.
5026 * tree-vectorizer.h: Same.
5027 * tree-flow.h: Same.
5029 * common.opt (fgraphite): Update documentation.
5031 2008-08-12 Harsha Jagasia <harsha.jagasia@amd.com>
5033 * doc/invoke.texi (-floop-block, -floop-strip-mine,
5034 -floop-interchange): Add more text for explaining what each of these
5036 * tree-into-ssa.c (gimple_vec): Moved to...
5037 * graphite.c: Include gimple.h.
5038 (gimple_vec): Moved to...
5039 (del_loop_to_cloog_loop): Removed.
5040 (loop_affine_expr): Do not call create_data_ref when the
5041 operand is a constant.
5042 (new_scop): Use free instead of del_loop_to_cloog_loop.
5043 * Makefile.in (graphite.o): Depend on GIMPLE_H.
5044 * gimple.h (gimple_vec): ... here.
5046 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5048 * graphite.c (scopdet_bb_info): Only allow loops with known number of
5050 (build_loop_iteration_domains): Fail, if latch executions unknown.
5052 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5054 * graphite.c (add_conditions_to_domain): New.
5055 (build_scop_conditions_1): Call add_conditions_to_domain.
5056 (set_cloog_options): Allow to disable optimizations.
5058 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5060 * graphite.c (find_params_in_bb): Look for parameters in conditions.
5061 Do not use walk_dominator_tree.
5062 (find_scop_parameters): Do not use walk_dominator_tree.
5064 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5066 * graphite.c (scan_tree_for_params) Add / Subtract inequality.
5067 (idx_record_params): Adapt.
5068 * graphite.h (scop_gimple_loop_depth): New.
5070 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5072 * graphite.c (build_scop_dynamic_schedules): Remove value_init.
5073 (scan_tree_for_params): Remove value_init.
5074 (build_scop_context): Remove value_init.
5075 (build_loop_iteration_domains): Remove value_init.
5076 (schedule_to_scattering): Remove value_init.
5077 (graphite_trans_bb_strip_mine): Remove value_init.
5079 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5081 * gcc/graphite.c (limit_scops): New.
5082 (graphite_transform_loops): Add limit SCoPs.
5083 * gcc/testsuite/gcc.dg/graphite/scop-0.c: Update number of SCoPs.
5084 * gcc/testsuite/gcc.dg/graphite/scop-1.c: Update number of SCoPs.
5085 * gcc/testsuite/gcc.dg/graphite/scop-10.c: Update number of SCoPs.
5086 * gcc/testsuite/gcc.dg/graphite/scop-11.c: Update number of SCoPs.
5087 * gcc/testsuite/gcc.dg/graphite/scop-12.c: Update number of SCoPs.
5088 * gcc/testsuite/gcc.dg/graphite/scop-13.c: Update number of SCoPs.
5089 * gcc/testsuite/gcc.dg/graphite/scop-14.c: Update number of SCoPs.
5090 * gcc/testsuite/gcc.dg/graphite/scop-15.c: Update number of SCoPs.
5091 * gcc/testsuite/gcc.dg/graphite/scop-16.c: Update number of SCoPs.
5092 Change loop numbers.
5093 * gcc/testsuite/gcc.dg/graphite/scop-17.c: Update number of SCoPs.
5094 Change loop numbers.
5095 * gcc/testsuite/gcc.dg/graphite/scop-18.c: Update number of SCoPs.
5096 * gcc/testsuite/gcc.dg/graphite/scop-2.c: Update number of SCoPs.
5097 * gcc/testsuite/gcc.dg/graphite/scop-3.c: Update number of SCoPs.
5098 * gcc/testsuite/gcc.dg/graphite/scop-4.c: Update number of SCoPs.
5099 * gcc/testsuite/gcc.dg/graphite/scop-5.c: Update number of SCoPs.
5100 * gcc/testsuite/gcc.dg/graphite/scop-6.c: Update number of SCoPs.
5101 * gcc/testsuite/gcc.dg/graphite/scop-7.c: Update number of SCoPs.
5102 * gcc/testsuite/gcc.dg/graphite/scop-8.c: Update number of SCoPs.
5103 * gcc/testsuite/gcc.dg/graphite/scop-9.c: Update number of SCoPs.
5104 * gcc/testsuite/gcc.dg/graphite/scop-matmult.c: Update number of SCoPs.
5106 2008-08-11 Tobias Grosser <grosser@fim.uni-passau.de>
5108 * graphite.c (graphite_transform_loops): Call always find_transform.
5110 2008-08-08 Tobias Grosser <grosser@fim.uni-passau.de>
5112 * graphite.c (free_loops_mapping): New.
5113 (stmt_simple_for_scop_p): Fix typo.
5114 (stmt_simple_for_scop_p): Fix tuples functions, that
5116 (free_graphite_bb): Fix some memleaks.
5117 (free_scop): Fix some memleaks.
5118 (scopdet_bb_info): Do not forget some tmp SCoPs.
5119 (find_params_in_bb): Fix some memleaks.
5120 (clast_to_gcc_expression): Fix warning.
5122 2008-08-07 Tobias Grosser <grosser@fim.uni-passau.de>
5124 * testsuite/gcc.dg/graphite/scop-16.c: Fix for 32bit.
5125 * testsuite/gcc.dg/graphite/scop-17.c: Fix for 32bit.
5127 2008-08-04 Sebastian Pop <sebastian.pop@amd.com>
5129 * tree-ssa-loop.c (tree-ssa-loop.o): Do not include toplev.h.
5130 Move code ifdef-ed HAVE_cloog...
5131 * graphite.c: Include toplev.h.
5133 * Makefile.in (OBJS-common): Always build graphite.o.
5134 (BACKEND): Remove @GRAPHITE@.
5135 (tree-ssa-loop.o): Do not depend on TOPLEV_H.
5136 (graphite.o): Depend on TOPLEV_H.
5138 2008-08-04 Sebastian Pop <sebastian.pop@amd.com>
5140 * Makefile.in (tree-ssa-loop.o): Depend on TOPLEV_H.
5141 Remove typo left from polylib to ppl conversion.
5142 * graphite.c (graphite_transforms): Use sorry instead of fatal.
5144 2008-08-03 Sebastian Pop <sebastian.pop@amd.com>
5146 * toplev.c (process_options): Move the graphite loop optimization
5148 * tree-ssa-loop.c (graphite_transforms): ... here.
5149 When not configured with CLooG, print to dump_file that
5150 Graphite transforms were not performed.
5151 * testsuite/gcc.dg/graphite/graphite.exp (scan-graphite-dump-times):
5153 * testsuite/gcc.dg/graphite/*.c: Updated all testcases to use
5154 scan-graphite-dump-times.
5156 2008-08-03 Sebastian Pop <sebastian.pop@amd.com>
5158 * graphite.c (dot_scop, dot_all_scops): Do not call system.
5159 Do not open /tmp/scop.dot and /tmp/allscops.dot.
5161 2008-08-02 Sebastian Pop <sebastian.pop@amd.com>
5162 Jan Sjodin <jan.sjodin@amd.com>
5164 * configure: Regenerated.
5165 * omp-low.c (expand_omp_sections): Remove now unused code.
5166 * config.in (HAVE_polylib): Removed.
5167 * configure.ac (HAVE_polylib, POLYLIBLIBS, POLYLIBINC): Removed.
5168 (PPLLIBS, PPLINC): Added.
5169 * graphite.c: Replace unsigned with int wherever possible.
5170 Don't access Cloog's data structures, but use accessor functions.
5171 Clast's stmt->type is now implemented as a vtable: change the
5172 switches of stmt->type into ifs.
5173 (polylib/polylibgmp.h): Don't include.
5174 (initialize_dependence_polyhedron,
5175 initialize_data_dependence_polyhedron, is_empty_polyhedron,
5176 statement_precedes_p, test_dependence, build_rdg_all_levels,
5177 dump_dependence_graph): Removed until this code is cleaned up
5179 * Makefile.in (POLYLIBLIBS): Renamed PPLLIBS.
5180 (POLYLIBINC): Renamed PPLINC.
5182 2008-08-01 Harsha Jagasia <harsha.jagasia@amd.com>
5183 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
5184 Jan Sjodin <jan.sjodin@amd.com>
5186 Finish the merge and tuplification of graphite.
5188 2008-07-24 Sebastian Pop <sebastian.pop@amd.com>
5189 Jan Sjodin <jan.sjodin@amd.com>
5191 Partial merge from mainline (138072:138275).
5192 * graphite.c still has to be tuplified.
5194 2008-07-29 Jan Sjodin <jan.sjodin@amd.com>
5196 * graphite.c (graphite_loops_mapping_max_loop_num): New.
5197 (create_num_from_index): New.
5198 (get_num_from_index): Also pass in the graphite BB.
5199 (free_graphite_bb): Free GBB_INDEX_TO_NUM_MAP.
5200 (build_graphite_bb): Initialize GBB_INDEX_TO_NUM_MAP.
5201 (graphite_trans_bb_strip_mine): Call create_num_from_index.
5202 (is_interchange_valid): Return false when failing.
5203 * graphite.h (struct num_map): New.
5204 (struct graphite_bb): New field num_map.
5205 (GBB_LOOPS_MAPPING): Renamed GBB_INDEX_TO_NUM_MAP.
5207 2008-07-29 Tobias Grosser <grosser@fim.uni-passau.de>
5209 * graphite.c (dump_gbb_conditions): Print also conditions like
5210 "if (a)". Remove dublicated code and use print_generic_expr ().
5211 (stmt_simple_for_scop_p): Only allow conditions we can handle
5214 2008-07-25 Jan Sjodin <jan.sjodin@amd.com>
5216 * graphite.h (struct scop): Removed new_ivs field.
5217 (SCOP_NEWIVS): Deleted.
5218 * graphite.c (new_scop, free_scop, clast_name_to_gcc,
5219 clast_to_gcc_expression, graphite_create_new_loop):
5220 Removed use of new_ivs.
5222 2008-07-25 Jan Sjodin <jan.sjodin@amd.com>
5224 * graphite.c (debug_oldivs, debug_loop_vec, create_loops_mapping,
5225 create_loops_mapping_num, debug_loop_mapping_1): New.
5226 (debug_loop_mapping): Call debug_loop_mapping_1.
5227 (get_loop_mapping_for_num,
5228 graphite_loops_mapping_add_child,
5229 graphite_loops_mapping_add_child_num,
5230 graphite_loops_mapping_insert_child,
5231 graphite_loops_mapping_parent,
5232 split_loop_mapped_depth_for_num,
5233 loop_mapped_depth_split_loop): New.
5234 (increment_loop_mapped_depths): Removed.
5235 (swap_loop_mapped_depth_for_num): Reimplemented.
5236 (new_scop): Call create_loops_mapping.
5237 (scop_record_loop): Call graphite_loops_mapping_insert_child.
5238 (translate_clast): Pass the old loop father in parameter, and pass
5239 it to get_old_iv_from_ssa_name.
5240 (remove_edges_around_useless_blocks, can_generate_code_stmt,
5241 can_generate_code, can_generate_for_scop): New.
5242 (graphite_trans_bb_block): Returns false when it fails to transform.
5243 * graphite.h (graphite_loop_node, graphite_loops_mapping): New.
5245 2008-07-25 Sebastian Pop <sebastian.pop@amd.com>
5247 Reverted all the changes related to the streamization and
5249 These changes are now tracked in the streamization branch.
5251 2008-07-25 Sebastian Pop <sebastian.pop@amd.com>
5252 Jan Sjodin <jan.sjodin@amd.com>
5254 * graphite.c (gbb_compare): Correctly constify.
5255 (gbb_can_be_ignored): Indent.
5256 (graphite_trans_scop_swap_1and2): Add legality check.
5259 2008-07-25 Sebastian Pop <sebastian.pop@amd.com>
5261 Remove fallouts from "Reverted the Condate changes".
5262 * tree.h: Remove unused decl.
5263 * testsuite/gcc.dg/tree-checker: Same.
5264 * timevar.def: Remove counter.
5266 2008-07-24 Sebastian Pop <sebastian.pop@amd.com>
5268 * Merge from mainline (135673:138072).
5270 Reverted the MIRO changes (from 2008-04-05) that are now
5271 tracked in the miro branch.
5272 * tree-bounds.c: Removed.
5273 * tree-bounds.h: Removed.
5275 Reverted the Condate changes (from 2006-07-04, 2007-03-20) that
5276 are now tracked in the condate branch.
5277 * tree-check.c: Removed.
5278 * tree-match.c: Removed.
5279 * condate.y: Removed.
5281 2008-07-24 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
5283 * common.opt: New user flag -floop-block, -floop-strip-mine
5284 and -floop-interchange.
5285 * toplev.c (process_options): Enable -fgraphite pass if any one of the
5286 graphite loop optimization flags is turned on.
5287 * graphite.c (graphite_apply_transformations): Add flag_loop_block,
5288 flag_loop_strip_mine and flag_loop_interchange checks before
5290 * doc/invoke.texi: Remove -fgraphite and add -floop-block,
5291 -floop-strip-mine and -floop-interchange.
5292 * testsuite/gcc.dg/graphite/block-0.c: Add -floop-block and remove
5294 * testsuite/gcc.dg/graphite/scop-16.c: Ditto.
5295 * testsuite/gcc.dg/graphite/scop-17.c: Ditto.
5296 * testsuite/gcc.dg/graphite/scop-18.c: Ditto.
5298 2008-07-23 Jan Sjodin <jan.sjodin@amd.com>
5299 Sebastian Pop <sebastian.pop@amd.com>
5301 * cfgloopmanip.c (update_dominators_in_loop): Make it static.
5302 (create_empty_loop_on_edge): More fixes.
5303 * tree-phinodes.c (resize_phi_node): Extern.
5304 (unlink_phi_node, move_phi_node): New split from remove_phi_node.
5305 * cfghooks.c (update_dominator_information): New split from
5307 * tree-vectorizer.c (rename_variables_in_bb): Extern.
5308 * tree-dfa.c (collect_dfa_stats): Start walking the CFG on the
5309 successor of the function entry block.
5311 * graphite.c: Include pointer-set.h.
5312 (debug_loop_mapping, increment_loop_mapped_depths,
5313 get_loop_mapped_depth_for_num, get_loop_mapped_depth,
5314 set_loop_mapped_depth_for_num, set_loop_mapped_depth,
5315 swap_loop_mapped_depth_for_num, get_num_from_index,
5316 swap_loop_mapped_depth, loop_iv_stack_debug,
5317 loop_iv_stack_push, loop_iv_stack_pop, loop_iv_stack_get_iv,
5318 loop_iv_stack_get_iv_from_name, loop_iv_stack_debug,
5319 get_old_iv_from_ssa_name): New.
5320 (new_scop): Initialize SCOP_LOOPS_MAPPING.
5321 (free_scop): Free SCOP_LOOPS_MAPPING.
5322 (scop_record_loop): Record old ivs.
5323 (create_var_name): Removed.
5324 (initialize_cloog_names): Allocate double space in case strip mine
5325 applies to all loops once.
5326 (clast_name_to_gcc): Look up in the map ivstack passed in parameter.
5327 (clast_to_gcc_expression): Same. Implement more clast to gimple
5329 (graphite_create_new_loop): Pass in ivstack.
5330 (remove_all_edges): Pass in the construction_edge.
5331 (graphite_remove_iv): Removed.
5332 (graphite_rename_ivs, graphite_rename_ivs_stmt,
5333 remove_cond_exprs): Rewritten.
5334 (move_phi_nodes): New.
5335 (disconnect_virtual_phi_nodes, disconnect_cond_expr): Removed.
5336 (translate_clast): Pass in ivstack. Rewrite some cases.
5337 (set_cloog_options, debug_clast_stmt): New.
5338 (find_transform): Use set_cloog_options.
5339 (outermost_loop_layer): Removed.
5340 (get_construction_edge, collect_virtual_phis, find_vdef_for_var_in_bb,
5341 find_vdef_for_var_1, find_vdef_for_var, patch_phis_for_virtual_defs,
5342 mark_old_loops, remove_dead_loops): New.
5344 (graphite_trans_bb_move_loop): Call swap_loop_mapped_depth.
5345 (const_column_index, get_first_matching_sign_row_index,
5346 get_lower_bound_row, get_upper_bound_row, get_lower_bound,
5347 get_upper_bound): New.
5348 (graphite_trans_bb_strip_mine): Also update the iv map.
5350 * graphite.h (graphite_loops_mapping, GBB_LOOPS_MAPPING): New.
5351 (struct name_tree): Add a loop field.
5352 (struct scop): Add a graphite_loops_mapping field.
5353 (SCOP_LOOPS_MAPPING): New.
5354 (debug_clast_stmt): Declare.
5355 * lambda.h (find_induction_var_from_exit_cond): Declare.
5356 (lambda-code.c): (find_induction_var_from_exit_cond): Extern.
5357 * cfgloop.h (update_dominators_in_loop): Removed declaration.
5358 (create_empty_loop_on_edge): Updated.
5359 * tree-flow.h (remove_bb, resize_phi_node, move_phi_node,
5360 rename_variables_in_bb): Declare.
5361 * tree-cfg.c (remove_bb): Extern.
5363 * testsuite/gcc.dg/graphite/block-0.c: New.
5365 2008-07-21 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
5366 Sebastian Pop <sebastian.pop@amd.com>
5368 * graphite.c (strip_mine_profitable_p): New.
5369 (graphite_trans_bb_block): Disable strip mining if not profitable.
5371 * testsuite/gcc.dg/graphite/scop-18.c: New.
5372 * testsuite/gcc.dg/graphite/scop-17.c: Fixed.
5373 * testsuite/gcc.dg/graphite/scop-16.c: Fixed.
5375 2008-07-17 Harsha Jagasia <harsha.jagasia@amd.com>
5376 Jan Sjodin <jan.sjodin@amd.com>
5377 Sebastian Pop <sebastian.pop@amd.com>
5379 * graphite.c (is_interchange_valid): New.
5380 (graphite_trans_bb_block): Check loop nest of basic block for legality
5383 * graphite.h (gbb_inner_most_loop_index, outer_most_loop_1,
5384 outer_most_loop, gbb_outer_most_loop_index): New.
5386 * tree-loop-linear.c (perfect_loop_nest_depth): Remove static.
5387 * tree-flow.h (perfect_loop_nest_depth): Declare as extern.
5388 * testsuite/gcc.dg/graphite/scop-16.c: New.
5389 * testsuite/gcc.dg/graphite/scop-17.c: New.
5391 2008-07-11 Tobias Grosser <grosser@fim.uni-passau.de>
5393 * graphite.c (scop_remove_ignoreable_gbbs): Also update bitmap.
5394 (graphite_trans_scop_block): Ignore SCoPs without bbs.
5396 2008-07-11 Tobias Grosser <grosser@fim.uni-passau.de>
5398 * graphite.c (new_scop): Initialize SCOP_EXIT.
5399 (scopdet_info): Add.
5400 (scopdet_bb_info): Rename from is_bb_addable. Cleanup, bugfixes.
5401 (build_scops_1): Cleanup, bugfixes.
5402 (build_scops): Cleanup.
5404 * testsuite/gcc.dg/graphite/scop-matmult.c: Remove duplicated code.
5405 * testsuite/gcc.dg/graphite/scop-15.c: Add SCoP numbers.
5407 2008-07-10 Harsha Jagasia <harsha.jagasia@amd.com>
5409 * testsuite/gfortran.dg/graphite/scop-1.f: Update to reduced test case.
5411 * testsuite/gfortran.dg/graphite/graphite.exp: Use
5412 DEFAULT_GRAPHITE_FLAGS.
5414 * testsuite/gcc.dg/graphite/scop-15.c: Update to reduced test case.
5416 2008-07-10 Harsha Jagasia <harsha.jagasia@amd.com>
5418 * graphite.c (scan_tree_for_params): Do not assert any more if
5419 MULT_EXPR parameter is negative.
5421 * testsuite/gfortran.dg/graphite/scop-1.f: New.
5423 * testsuite/gfortran.dg/graphite/graphite.exp: New.
5425 * testsuite/gcc.dg/graphite/scop-15.c: New.
5427 2008-07-10 Harsha Jagasia <harsha.jagasia@amd.com>
5429 * graphite.c (is_bb_addable): Fix segfault in spec gzip and reformat.
5431 2008-07-10 Tobias Grosser <grosser@fim.uni-passau.de>
5433 * graphite.c (graphite_trans_bb_swap_loops): Rename from
5434 graphite_swap_loops.
5435 (graphite_trans_bb_move_loop): New.
5436 (graphite_trans_bb_strip_mine): Rename from graphite_strip_mine_loop.
5437 (graphite_trans_bb_block): New.
5438 (graphite_trans_loop_block): New.
5439 (graphite_trans_scop_swap_1and2): Rename from
5440 graphite_trans_swap_1and2.
5441 (graphite_trans_scop_strip): Rename from graphite_trans_strip.
5442 (graphite_trans_scop_block): New.
5443 (graphite_apply_transformations): Rename from
5444 graphite_transformations.
5446 * testsuite/gcc.dg/graphite/scop-matmult.c: New.
5448 2008-07-10 Tobias Grosser <grosser@fim.uni-passau.de>
5450 * graphite.c (gbb_compare): New.
5451 (graphite_sort_gbbs): New.
5452 (gbb_can_be_ignored): New.
5453 (scop_remove_ignoreable_gbbs): New.
5454 (graphite_transformations): Cleanup and add
5455 scop_remove_ignoreable_gbbs.
5456 * lambda.h (lambda_vector_compare): New.
5458 2008-07-09 Tobias Grosser <grosser@fim.uni-passau.de>
5460 * graphite.c (print_graphite_bb): Correct printing of static schedule.
5461 (graphite_swap_loops): int -> unsigned
5462 (graphite_strip_mine_loop): int -> unsigned, Fix SCHEDULE
5463 (graphite_transformations): New.
5464 (graphite_transform_loops): Move to graphite_transformations.
5465 * graphite.h (gbb_nb_loops): Return unsigned.
5467 2008-07-04 Tobias Grosser <grosser@fim.uni-passau.de>
5469 * graphite.c (scan_tree_for_params): Fix insertion of parameters into
5470 the domain matrix. This makes scop-0.c work again.
5472 2008-06-20 Richard Guenther <rguenther@suse.de>
5474 * graphite.h: Adjust copyright to GPLv3.
5475 * graphite.c: Likewise.
5476 (stmt_simple_memref_for_scop_p): Split out from ...
5477 (stmt_simple_for_scop_p): ... here. Fix handling of calls
5479 (get_bb_type): Optimize.
5481 (is_bb_addable): Fix memleak, replace is_pred call with
5483 (build_scops): Use current_loops.
5484 (param_index): Fix memleak.
5486 2008-06-20 Konrad Trifunovic <konrad.trifunovic@inria.fr>
5488 * graphite.c: Fix formatting.
5490 2008-06-19 Konrad Trifunovic <konrad.trifunovic@inria.fr>
5492 * graphite.c (new_scop): Memory allocation for SCOP_{NEWIVS, OLDIVS}.
5493 (free_scop): Memory deallocation for SCOP_NEWIVS, SCOP_OLDIVS.
5494 (create_var_name, save_var_name): Newly defined functions.
5495 (initialize_cloog_names): Part of the code factored out to
5497 (clast_to_gcc_expression): Now handles the case of clast_red_sum
5498 in clast_reduction statement.
5499 (graphite_create_new_loop): Now takes a new parameter
5501 (translate_clast): Now also takes the context_loop and bb_exit
5502 parameters. Rewritten the code so that it creates a gimple code
5503 inside the given context.
5504 (outermost_loop_layer, graphite_remove_iv, graphite_rename_ivs,
5505 remove_cond_expr, disconnect_cond_expr,
5506 disconnect_virtual_phi_nodes): Newly defined functions.
5507 * graphite.h (struct scop): added old_ivs vector.
5508 SCOP_OLDIVS: New macro.
5510 2008-06-19 Sebastian Pop <sebastian.pop@amd.com>
5512 * cfgloopmanip.c: Add missing function comments, fix formatting.
5514 2008-06-18 Konrad Trifunovic <konrad.trifunovic@inria.fr>
5516 * cfgloopmanip.c (update_dominators_in_loop): Defined.
5517 (create_empty_loop_on_edge): Defined.
5518 * tree-parloops.c (canonicalize_loop_ivs): Returns tree
5520 * cfgloop.h (create_empty_loop_on_edge): Declared as extern.
5521 (update_dominators_in_loop): Declared as extern
5522 * tree-flow.h (canonicalize_loop_ivs): Declared as extern.
5524 2008-06-16 Tobias Grosser <grosser@fim.uni-passau.de>
5526 * graphite.c (print_graphite_bb): Allow changing number of loops
5528 (initialize_cloog_names): Allow changing number of loops.
5529 (build_cloog_prog): Simplify.
5530 (find_transform): Enable cloog option --strides.
5531 (graphite_swap_loops): New.
5532 (graphite_strip_mine_loop): New.
5533 (graphite_trans_swap_1and2): New.
5534 (graphite_trans_strip): New.
5535 (graphite_transform_loops): Add graphite_trans_strip.
5536 * graphite.h (scop_max_loop_depth): New.
5538 2008-06-15 Tobias Grosser <grosser@fim.uni-passau.de>
5540 * graphite.c (build_scop_iteration_domain): Remove forgotten
5541 line. (Fixes compile)
5543 2008-06-15 Tobias Grosser <grosser@fim.uni-passau.de>
5545 * graphite.c (print_graphite_bb): Add output of GBB_LOOPS.
5546 (build_graphite_bb): Add GBB_LOOPS and GBB_DOMAIN and reorder.
5547 (build_bb_loops): New.
5548 (graphite_transform_loops): Add build_bb_loops.
5549 (schedule_to_scattering): Use gbb_nb_loops to support changing loop
5551 * graphite.h (graphite_bb): Add loops.
5552 (gbb_nb_loops): New.
5553 (gbb_loop_at_index): New.
5554 (gbb_loop_index): New.
5555 (nb_params_in_scop): Renamed to scop_nb_params. Updated all functions
5556 using nb_params_in_scop.
5558 2008-06-14 Tobias Grosser <grosser@fim.uni-passau.de>
5560 * graphite.c (print_graphite_bb): Adapt to minimized schedule.
5561 (build_scop_canonical_schedules): Build minimized schedule.
5562 (schedule_to_scattering): Adapt to minimized schedule.
5563 * graphite.h (graphite_bb): Add/Update descriptions.
5565 2008-06-14 Adrien Eliche <aeliche@isty.uvsq.fr>
5566 Tobias Grosser <grosser@fim.uni-passau.de>
5568 * graphite.c (print_graphite_bb): Add condition printing.
5570 (dump_gbb_conditions): New.
5571 (build_scop_conditions_1): New.
5572 (build_scop_conditions): New.
5573 * graphite.h (graphite_bb): Add conditions.
5575 2008-06-14 Tobias Grosser <grosser@fim.uni-passau.de>
5577 * graphite.c (print_graphite_bb):
5578 (free_graphite_bb): New.
5579 (free_scop): Free bbs.
5580 (get_bb_type): Free doms.
5581 (build_scop_context): Free context matrix.
5582 (build_loop_iteration_domains): Remove unused code.
5583 (build_cloog_prog): Free scattering function and blocklist.
5584 (find_transform): Free options.
5586 2008-06-13 Tobias Grosser <grosser@fim.uni-passau.de>
5588 * graphite.c (loop_body_to_cloog_stmts): Rename to add_bb_domains.
5589 Remove unnecessery cloog data structures. Make a copy of the domain
5590 (setup_cloog_loop): Rename to build_loop_iteration_domains. Remove
5591 unnecessary cloog data structures. Fix memory leaks. Remove insert
5592 into SCOP_LOOP2CLOOG_LOOP as the inserted CloogLoops will never be
5594 (build_scop_iteration_domain): Remove unnecessary cloog
5595 data structures. Fix memory leaks.
5596 (graphite_transform_loops): Disable build_scop_dynamic_schedules as it
5597 uses SCOP_LOOP2CLOOG_LOOP, that is at the moment not working.
5599 2008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
5601 * graphite.c (find_scop_params): Remove initialize_cloog_names.
5603 2008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
5605 * graphite.c (end_scop): Style fix.
5606 (schedule_to_scattering): Style and comment fix.
5608 2008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
5609 * graphite.c (print_graphite_bb): Fix definiton of
5610 schedule_to_scattering.
5611 (initialize_cloog_names): Change nb_scattdims to max loop
5613 (schedule_to_scattering): Take parameter for number of scattering
5615 (build_cloog_prog): Only build as much scattering dimensions as
5618 2008-06-12 Tobias Grosser <grosser@fim.uni-passau.de>
5620 * graphite.c (end_scop): Disable bb splitting. Fixes SIGSEGV
5621 in polyhedron/aermod.f90.
5623 2008-06-11 Tobias Grosser <grosser@fim.uni-passau.de>
5624 Dwarak Rajagopal <dwarak.rajagopal@amd.com>
5625 Harsha Jagasia <harsha.jagasia@amd.com>
5627 * graphite.c (is_bb_addable): Fix segfault.
5629 2008-06-10 Tobias Grosser <grosser@fim.uni-passau.de>
5631 * graphite.c (is_bb_addable): Fix memory leak, handling of loops
5632 with multiple exits and conditional handling in edge cases.
5633 (is_loop_exit): Fix memory leak. (Forgotten in last commit)
5635 * testsuite/gcc.dg/graphite/scop-14.c: New.
5637 2008-06-06 Tobias Grosser <grosser@fim.uni-passau.de>
5638 Adrien Eliche <aeliche@isty.uvsq.fr>
5640 * graphite.c (is_bb_addable): Add more comments and enhance
5641 readablity of the source code. Fix memory leak.
5642 (is_loop_exit): Fix memory leak.
5644 2008-06-05 Tobias Grosser <grosser@fim.uni-passau.de>
5646 * graphite.c (first_loop_in_scop): Deleted.
5647 (setup_cloog_loop): Only walk the loop chain for inner loops.
5648 (build_scop_iteration_domain): Execute setup_cloog_loop for
5649 all loops in the first layer.
5651 2008-06-05 Tobias Grosser <grosser@fim.uni-passau.de>
5653 * graphite.c (scan_tree_for_params): Change the way params are
5654 added to be indepenent of the number of loops.
5655 (setup_cloog_loop): Revert to short matrix format. Fix parameter
5657 (build_cloog_prog): Revert to short matrix format.
5659 2008-06-05 Sebastian Pop <sebastian.pop@amd.com>
5660 Dwarak Rajagopal <dwarak.rajagopal@amd.com>
5662 * tree-loop-fusion.c (fuse_loops): Fix uninitialized variable
5665 2008-06-05 Sebastian Pop <sebastian.pop@amd.com>
5667 * graphite.c (nb_data_refs_in_scop): New.
5668 (graphite_transform_loops): Print more stats: number of
5669 loops, basic blocks and data references per scop.
5671 2008-06-04 Sebastian Pop <sebastian.pop@amd.com>
5672 Jan Sjodin <jan.sjodin@amd.com>
5674 * graphite.c (loop_affine_expr, idx_record_params,
5675 find_scop_parameters, setup_cloog_loop): Use instantiate_scev
5676 instead of instantiate_parameters.
5678 2008-06-04 Tobias Grosser <grosser@fim.uni-passau.de>
5680 * graphite.c (schedule_to_scattering): Fix scattering dimensions,
5681 add support for parameters, add STATIC_SCHEDULE at the right places,
5684 2008-06-04 Tobias Grosser <grosser@fim.uni-passau.de>
5686 * graphite.c (build_scop_loop_nests): Only add the loops, that
5687 are contained completely in the SCoP.
5688 (build_cloog_prog): Disable scattering, until schedule_to_scattering
5689 and the domains are fixed.
5690 (build_scop_canonical_schedules): Add support for bbs not contained
5693 2008-06-04 Tobias Grosser <grosser@fim.uni-passau.de>
5695 * graphite.h (scop_contains_loop): Update comments to match
5696 the actual behavior.
5697 (scop_contains_loop): New.
5698 * graphite.c (schedule_to_scattering): Use scop_contains_loop.
5700 2008-06-04 Sebastian Pop <sebastian.pop@amd.com>
5702 * graphite.c (get_bb_type): On function body, i.e. loop_0,
5703 don't mark blocks as GBB_LOOP_SING_EXIT_HEADER, mark them
5706 2008-06-04 Sebastian Pop <sebastian.pop@amd.com>
5707 Tobias Grosser <grosser@fim.uni-passau.de>
5709 * graphite.c (graphite_transform_loops): Early return when
5710 there are no loops in the function.
5712 2008-05-31 Sebastian Pop <sebastian.pop@amd.com>
5713 Jan Sjodin <jan.sjodin@amd.com>
5715 * graphite.c (scan_tree_for_params, setup_cloog_loop): Compute the
5716 offset of the last loop.
5717 (setup_cloog_loop): Copy the entire outer constraint matrix.
5719 2008-05-31 Sebastian Pop <sebastian.pop@amd.com>
5720 Jan Sjodin <jan.sjodin@amd.com>
5722 * graphite.c (stmt_in_scop_p, function_parameter_p,
5723 invariant_in_scop_p): Removed.
5724 (scan_tree_for_params): Can be used with no constraint
5725 matrix for gathering parameters.
5726 (idx_record_params): Don't use idx_record_param, instead use
5727 scan_tree_for_params.
5728 (find_scop_parameters): Same.
5729 (setup_cloog_loop, build_scop_iteration_domain, build_cloog_prog):
5730 Fix the size of loop domains.
5731 (schedule_to_scattering): Exit when the outer loop is not in scop.
5732 (find_transform): Enable build_cloog_prog.
5734 2008-05-31 Sebastian Pop <sebastian.pop@amd.com>
5735 Jan Sjodin <jan.sjodin@amd.com>
5737 * graphite.c (schedule_to_scattering): Make scattering domains
5738 uniformly of the same size, as required by CLooG 0.14.0 and before.
5740 2008-05-31 Sebastian Pop <sebastian.pop@amd.com>
5741 Jan Sjodin <jan.sjodin@amd.com>
5743 * graphite.c (schedule_to_scattering): Rewrite, correct the
5744 translation of the scheduling function to scattering.
5745 (build_cloog_prog): Call schedule_to_scattering only once.
5746 * graphite.h (scop_loop_index): Do not fail for loops not
5747 in the scop: return -1.
5749 2008-05-30 Tobias Grosser <grosser@fim.uni-passau.de>
5751 * graphite.c (build_graphite_bb): Initialize GBB_DOMAIN.
5752 (loop_body_to_cloog_stmts): Export GBB_DOMAIN.
5753 (setup_cloog_loop): Export GBB_DOMAIN.
5754 (build_cloog_prog): New. Create new CLOOG_PROG, which should be
5755 able to rebuild the original control flow.
5756 * graphite.h (graphite_bb): Add domain field and access macro.
5759 2008-05-30 Sebastian Pop <sebastian.pop@amd.com>
5761 * graphite.c (debug_gbb): New.
5762 (print_scop, build_graphite_bb): Use SCOP_BBS.
5763 (build_scop_bbs): Reimplemented.
5764 (dfs_bb_in_scop_p): Removed.
5765 (build_scop_loop_nests): Reorder loops inserted in
5766 SCOP_LOOP_NEST: outer loops should come first.
5767 (build_scop_canonical_schedules): Reinitialize at zero
5768 the components of the SCOP_STATIC_SCHEDULE for the loops
5769 that have already been parsed.
5771 * graphite.h (debug_gbb): Declared.
5773 2008-05-30 Sebastian Pop <sebastian.pop@amd.com>
5774 Jan Sjodin <jan.sjodin@amd.com>
5776 * graphite.c (create_empty_loop): Renamed graphite_create_new_loop.
5777 (graphite_loop_to_gcc_loop): Removed.
5778 (remove_all_edges): New.
5779 (graphite_stmt_to_gcc_stmt): Renamed translate_clast.
5780 (gloog): Remove useless code.
5782 2008-05-29 Tobias Grosser <grosser@fim.uni-passau.de>
5784 * graphite.c (get_bb_type): Reworked. We distinguish between
5785 loops with one or multiple exits.
5786 (is_loop_exit): New.
5788 (is_bb_addable): Rework condition handling, now support for case
5789 case statements and loops with multiple exits.
5791 * testsuite/gcc.dg/graphite/scop-11.c: New.
5792 * testsuite/gcc.dg/graphite/scop-12.c: New.
5793 * testsuite/gcc.dg/graphite/scop-13.c: New.
5795 2008-05-29 Tobias Grosser <grosser@fim.uni-passau.de>
5797 * graphite.c (dot_all_scops_1): Fix some colors. Reuse colors, if
5798 we have too many colors.
5800 2008-05-22 Sandeep Maram <smaram_b04@iiita.ac.in>
5802 * doc/invoke.texi (-ftree-loop-fusion): Document.
5803 * tree-pass.h (pass_loop_fusion): Declared.
5804 * tree-loop-fusion.c: New.
5805 * timevar.def (TV_TREE_LOOP_FUSION): Declared.
5806 * tree-data-ref.c (find_data_references_in_loop): Make extern.
5807 * tree-data-ref.h (find_data_references_in_loop): Declared.
5808 * common.opt (ftree-loop-fusion): Declared.
5809 * Makefile.in (tree-loop-fusion.o): Added rule and to OBJS-common.
5811 2008-05-21 Sebastian Pop <sebastian.pop@amd.com>
5813 * graphite.c (build_access_matrix): Fix typo from the merge.
5815 2008-05-20 Sebastian Pop <sebastian.pop@amd.com>
5817 * Merge from mainline (130800:135673).
5819 2008-05-07 Sebastian Pop <sebastian.pop@amd.com>
5821 * graphite.c (end_scop): The exit of the scop is not part of the scop.
5822 Update dominators after splitting.
5824 2008-05-07 Sebastian Pop <sebastian.pop@amd.com>
5826 * graphite.c (is_bb_addable): Return the harmful statement.
5827 Factor up some code.
5828 (end_scop): New. Splits end of scope bbs on a harmful statement.
5829 (build_scops_1): Call end_scop.
5831 2008-05-07 Sebastian Pop <sebastian.pop@amd.com>
5833 * graphite.c: (succs_at_same_depth, end_scop, all_preds_visited_p,
5834 all_succs_visited_p, start_new_scop_for_each_succ, start_new_scop,
5835 add_dominators_to_open_scops, stop_last_open_scop, scop_end_loop,
5836 build_scops_1): Removed.
5837 (build_scops_2): Renamed build_scops_1.
5839 2008-05-06 Sebastian Pop <sebastian.pop@amd.com>
5841 * graphite.c: Fix formatting.
5843 2008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
5845 * graphite.c (get_bb_type): New.
5847 (build_scops_2): New.
5848 (is_bb_addable): New.
5849 (build_scops): Switch the scop detection.
5850 (build_scop_bbs): Add entry bb to scop.
5851 * graphite.h (struct scop): Update comment.
5853 2008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
5855 * graphite.c (dot_all_scops_1): Fix some incorrect colors and add
5858 2008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
5860 * testsuite/gcc.dg/graphite/scop-1.c: Update.
5861 * testsuite/gcc.dg/graphite/scop-2.c: Update.
5862 * testsuite/gcc.dg/graphite/scop-4.c: Update.
5863 * testsuite/gcc.dg/graphite/scop-5.c: Add.
5864 * testsuite/gcc.dg/graphite/scop-6.c: Add.
5866 2008-05-06 Sebastian Pop <sebastian.pop@amd.com>
5868 * testsuite/gcc.dg/graphite/scop-0.c: Add.
5869 * testsuite/gcc.dg/graphite/scop-7.c: Add.
5870 * testsuite/gcc.dg/graphite/scop-8.c: Add.
5871 * testsuite/gcc.dg/graphite/scop-9.c: Add.
5872 * testsuite/gcc.dg/graphite/scop-10.c: Add.
5874 2008-05-06 Tobias Grosser <grosser@fim.uni-passau.de>
5876 * graphite.c (scop_affine_expr): Renamed to loop_affine_expr.
5877 Check affine expressions depending on the outermost loop
5879 (stmt_simple_for_scop_p): Same.
5880 (harmfule_stmt_in_scop): Same.
5882 2008-04-28 Tobias Grosser <grosser@fim.uni-passau.de>
5884 * graphite.c (dot_all_scops): Remove incorrect difficult bb coloring,
5885 mark entry and exit, that are not part of the SCoP and update HTML
5888 2008-04-25 Sebastian Pop <sebastian.pop@amd.com>
5890 * graphite.c (basic_block_simple_for_scop_p): Renamed
5892 (save_scop, preds_at_same_depth, test_for_scop_bound): Removed.
5893 (add_dominators_to_open_scops, build_scops_1): Reimplemented.
5894 (all_preds_visited_p, all_succs_visited_p,
5895 start_new_scop_for_each_succ, start_new_scop, stop_last_open_scop,
5896 scop_end_loop): New.
5897 (build_scops): Do not use dfs_enumerate_from.
5899 * testsuite/gcc.dg/graphite/scop-{1,2,4}.c: Updated.
5901 2008-04-23 Sebastian Pop <sebastian.pop@amd.com>
5903 * graphite.c: Add comments to functions that are missing a
5905 (graphite_create_iv): Removed. Merged in graphite_loop_to_gcc_loop.
5907 2008-04-23 Sebastian Pop <sebastian.pop@amd.com>
5909 * graphite.c (nb_params_in_scop): Moved...
5910 (graphite_bb_from_bb, loop_body_to_cloog_stmts): New.
5911 (setup_cloog_loop): Call loop_body_to_cloog_stmts.
5912 (clast_to_gcc_expression): Reduce column size to less than 80.
5913 (graphite_create_iv): Return the new name of the IV.
5914 (find_transform): Set options->esp and options->cpp.
5915 (gloog): Comment out the invalidation of the old loop code.
5916 (initialize_dependence_polyhedron): Replace scop_nb_params with
5919 * graphite.h (nb_params_in_scop): ... here.
5920 (scop_nb_params): Removed.
5921 (loop_domain_dim): Return something even when the loop was not
5922 found in the hash table: avoid ICEing on all the graphite.exp
5925 2008-04-14 Konrad Trifunovic <konrad.trifunovic@inria.fr>
5927 * tree-chrec.c (for_each_scev_op): SCEV can have 3 operands.
5929 * graphite.c (build_scop_dynamic_schedules): Schedule is built
5930 according to nesting level.
5931 (find_scop_parameters): Call instantiate_parameters.
5932 (scan_tree_for_params): Extend it to handle general affine bounds.
5933 Inner loop bound can depend on outer loop induction variable.
5934 (setup_cloog_loop): tmp variable is allocated on stack. Call
5935 instantiate_parameters with respect to outermost_loop_in_scop.
5936 (loop_domain_dim, ref_nb_loops, loop_iteration_vector_dim): moved to
5938 (create_empty_loop): Function loopify should be given edge
5939 probability, instead of edge frequency. Dominance relation from
5940 switch_bb to loop_header.
5941 (clast_to_gcc_expression): Added handling of clast_reduction node.
5942 (gloog): New functionality for removing old loop.
5943 (test_dependence): Factored out from build_rdg_all_levels.
5944 (build_rdg_all_levels): Dependence testing factored out to
5945 test_dependence function.
5947 * graphite.h (struct graphite_bb): Extended with dynamic_schedule.
5948 (loop_domain_dim, ref_nb_loops, loop_iteration_vector_dim): Moved
5951 2008-04-07 Sebastian Pop <sebastian.pop@amd.com>
5953 * graphite.c (free_scop, param_index, initialize_cloog_names,
5954 nb_params_in_scop): Use name_tree map instead of just a tree
5955 for keeping track of the variable name associated to that tree.
5956 (create_empty_loop, gmp_cst_to_tree, clast_name_to_gcc,
5957 clast_to_gcc_expression, graphite_create_iv,
5958 graphite_loop_to_gcc_loop, graphite_cond_to_gcc_cond,
5959 graphite_stmt_to_gcc_stmt): New.
5960 (gloog): Call these.
5961 * graphite.h (struct name_tree): New.
5962 (struct scop): Use name_tree instead of tree for params.
5963 Store a vector of name_tree for new_ivs.
5965 (scop_nb_params): Use name_tree instead of tree.
5967 2008-04-05 Alexander Lamaison <awl03@doc.ic.ac.uk>
5968 Sebastian Pop <sebastian.pop@amd.com>
5970 * tree-bounds.c: New.
5971 * tree-bounds.h: New.
5972 * tree-pass.h: Declare pass_bounds_early and pass_bounds_late.
5973 * passes.c: Schedule pass_bounds_early, pass_bounds_late.
5974 * builtins.c (expand_builtin_alloca): Add flag_bounds as for
5978 * c-cppbuiltin.c: Same.
5982 * tree-outof-ssa.c: Same.
5984 * Makefile.in: Same.
5986 2008-03-15 Antoniu Pop <antoniu.pop@gmail.com>
5987 Sebastian Pop <sebastian.pop@amd.com>
5989 * tree-loop-distribution.c (remaining_stmts,
5990 upstream_mem_writes): Removed static variables.
5991 (copy_loop_before, create_bb_after_loop,
5992 mark_nodes_having_upstream_mem_writes, free_rdg_components,
5993 rdg_build_components, rdg_build_partitions,
5994 dump_rdg_partitions): Extern.
5995 (generate_loops_for_partition, generate_code_for_partition): Do not
5997 (already_processed_vertex_p, predecessor_has_mem_write,
5998 mark_nodes_having_upstream_mem_writes, has_upstream_mem_writes,
5999 rdg_flag_all_uses, rdg_flag_uses, rdg_flag_vertex_and_dependent,
6000 rdg_flag_loop_exits, rdg_flag_similar_memory_accesses,
6001 build_rdg_partition_for_component, rdg_build_partitions, ldist_gen):
6002 Pass remaining_stmts and upstream_mem_writes as parameters.
6003 (rdg_component): Moved...
6004 (build_rdg_partition_for_component): Do not aggregate components when
6005 flag_streamize_loops is set.
6006 (gen_sequential_loops): New.
6007 (ldist_gen): Call gen_sequential_loops.
6009 * tree-pass.h (pass_loop_streamization): Declared.
6011 * omp-low.c (expand_omp_sections): Call add_bb_to_loop on created
6012 basic blocks when loops structures exist.
6014 * builtin-types.def (BT_FN_VOID_PTR_PTR_INT): New.
6016 * tree-ssa-loop-ivopts.c (expr_invariant_in_region_p): New.
6018 * tree-parloops.c (take_address_of, eliminate_local_variables_1,
6019 eliminate_local_variables_stmt, eliminate_local_variables,
6020 separate_decls_in_loop_name, separate_decls_in_loop_stmt,
6021 separate_decls_in_loop, gen_parallel_loop): Make them work on a region
6022 of code delimited by two edges in the CFG.
6023 (separate_decls_in_loop_name): Renamed separate_decls_in_region_name.
6024 (separate_decls_in_loop_stmt): Renamed separate_decls_in_region_stmt.
6025 (separate_decls_in_loop): Renamed separate_decls_in_region. Isolate
6026 the case of parallelisation of reductions.
6027 (create_loop_fn): Extern.
6028 (create_omp_parallel_region): New.
6030 * tree-data-ref.c (dump_data_dependence_relation): Don't call
6031 dump_data_reference for printing dra and drb.
6032 (create_rdg_edge_for_ddr, create_rdg_edges_for_scalar): Initialise
6034 (build_rdg): Don't call free_dependence_relations for the moment, as
6035 we attach dependence relations on each edge of the RDG.
6038 * tree-data-ref.h (rdg_component): ...here.
6039 (struct rdg_edge): New field ddr_p relation.
6040 (RDGE_RELATION): New.
6041 (create_bb_after_loop, copy_loop_before,
6042 mark_nodes_having_upstream_mem_writes, rdg_build_components,
6043 rdg_build_partitions, dump_rdg_partitions,
6044 free_rdg_components): Declared.
6046 * omp-builtins.def (BUILT_IN_GOMP_STREAM_ALIGN_PUSH,
6047 BUILT_IN_GOMP_STREAM_ALIGN_POP): New.
6049 * tree-loop-streamization.c: New.
6051 * tree-flow.h (gather_blocks_in_sese_region, create_loop_fn,
6052 create_omp_parallel_region, expr_invariant_in_region_p): Declared.
6054 * Makefile.in (tree-loop-streamization.o): Added to OBJS-common.
6056 * tree-cfg.c (gather_blocks_in_sese_region): Extern.
6058 * passes.c: Schedule pass_loop_streamization.
6060 2008-03-08 Tobias Grosser <grosser@fmi.uni-passau.de>
6062 * graphite.c (dot_all_scops_1): Fix formatting for difficult bbs and
6065 2008-03-07 Tobias Grosser <grosser@fim.uni-passau.de>
6067 * graphite.c (dot_all_scops): Update formatting.
6068 Bbs can now be part of more than one SCoP.
6070 2008-03-04 Sebastian Pop <sebastian.pop@amd.com>
6072 * graphite.c (new_loop_to_cloog_loop_str, setup_cloog_loop): Fix
6074 (loop_domain_dim): Check for unregistered toplev SCOP loop.
6075 * graphite.h (loop_to_cloog_loop): New.
6077 2008-03-04 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6079 * graphite.c (loop_domain_dim, ref_nb_loops,
6080 loop_iteration_vector_dim): New.
6081 (build_access_matrix_with_af, build_access_matrix,
6082 initialize_dependence_polyhedron): Fixed for new matrix layout.
6083 No longer assume that all iteration domains are of the same
6086 2008-03-02 Sebastian Pop <sebastian.pop@amd.com>
6088 * tree-scalar-evolution.c (instantiate_parameters_1): An SSA_NAME
6089 defined in a loop at depth 0 is invariant.
6090 * tree-chrec.c (evolution_function_is_invariant_rec_p): Ditto.
6091 * tree-ssa-loop-ivopts.c (expr_invariant_in_loop_p): Should never
6092 be called at loop depth 0.
6094 * graphite.c (basic_block_simple_for_scop_p): Take the scop as
6096 (dot_all_scops_1): Update use of basic_block_simple_for_scop_p.
6097 (down_open_scop): Removed.
6098 (loop_in_scop_p): Redefined.
6099 (scop_affine_expr): New argument: scop.
6100 (stmt_simple_for_scop_p): New argument: scop. RETURN_EXPR is not
6101 a harmful statement ending a scop.
6102 (basic_block_simple_for_scop_p): New argument: scop.
6103 (get_loop_start): Removed.
6104 (new_scop): Initialize SCOP_LOOPS.
6105 (free_scop): Free SCOP_LOOPS.
6106 (succs_at_same_depth, preds_at_same_depth): New.
6107 (end_scop): Test the validity of a scop.
6108 (add_dominators_to_open_scops): New.
6109 (test_for_scop_bound): Call add_dominators_to_open_scops.
6110 Add cases for opening and closing multiple scops.
6111 (build_scops, build_scop_bbs): Iterate over basic blocks in
6113 (build_graphite_bb): Pass scop directly.
6114 (dfs_bb_in_scop_p): New.
6115 (scop_record_loop): Use SCOP_LOOPS for not recording the same loop
6117 (nb_loops_around_gb): Use loop_in_scop_p.
6118 (schedule_to_scattering): Disabled for the moment the code computing
6119 the "textual order for outer loop".
6121 * graphite.h (struct scop): New field loops.
6123 (scop_loop_index): Test that the given loop belongs to SCOP_LOOPS.
6125 * testsuite/gcc.dg/graphite/scop-{1,...,7}.c: Updated.
6127 2008-02-27 Antoniu Pop <antoniu.pop@gmail.com>
6128 Sebastian Pop <sebastian.pop@amd.com>
6130 * builtin-types.def (BT_FN_PTR_SIZE_UINT, BT_FN_BOOL_PTR): New.
6131 * common.opt (fstreamize-loops): New.
6132 * omp-builtins.def (BUILT_IN_GOMP_STREAM_CREATE,
6133 BUILT_IN_GOMP_STREAM_PUSH, BUILT_IN_GOMP_STREAM_HEAD,
6134 BUILT_IN_GOMP_STREAM_POP, BUILT_IN_GOMP_STREAM_EOS_P,
6135 BUILT_IN_GOMP_STREAM_SET_EOS, BUILT_IN_GOMP_STREAM_DESTROY): New.
6137 2008-02-22 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6139 * tree-data-ref.c (build_empty_rdg): New.
6140 (build_rdg): Use it.
6141 * tree-data-ref.h (build_empty_rdg): Declared.
6142 * graphite.c (free_scop): Free SCOP_LOOP2CLOOG_LOOP.
6143 (find_vertex_for_stmt): Removed.
6144 (build_rdg_all_levels): Use build_empty_rdg and rdg_vertex_for_stmt.
6146 2008-02-21 Sebastian Pop <sebastian.pop@amd.com>
6148 * tree-loop-distribution.c (generate_builtin): After cancelling the
6149 loop tree, also delete basic blocks.
6150 (rdg_flag_uses): Stop recursion when a vertex has already been
6153 2008-02-15 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6155 * graphite.c (build_scop_alpha): Removed.
6156 (graphite_transform_loops): Add a dummy call to build_all_rdg_levels
6157 and dump_dependence_graph to avoid compiler warnings.
6159 2008-02-14 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6161 * tree-data-ref.c (dr_may_alias_p, create_rdg_vertices): Extern.
6162 * tree-data-ref.h (dr_may_alias_p, create_rdg_vertices): Declared.
6163 * graphite.c (new_loop_to_cloog_loop_str, hash_loop_to_cloog_loop,
6164 eq_loop_to_cloog_loop, del_loop_to_cloog_loop): New.
6165 (new_scop, setup_cloog_loop): Initialize SCOP_LOOP2CLOOG_LOOP.
6166 (initialize_dependence_polyhedron, find_vertex_for_stmt,
6167 initialize_data_dependence_polyhedron, is_empty_polyhedron,
6168 statement_precedes_p, build_rdg_all_levels, build_scop_alpha,
6169 dump_dependence_graph): New.
6170 * graphite.h (struct graphite_bb): New field compressed_alpha_matrix.
6172 (struct scop): New field loop2cloog_loop.
6173 (SCOP_LOOP2CLOOG_LOOP, struct data_dependence_polyhedron,
6174 RDGE_DDP, ddp_p, struct loop_to_cloog_loop_str): New.
6176 2008-02-10 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6178 * graphite.c (build_graphite_bb): Fix initialization
6179 of the graphite basic block.
6181 2008-02-05 Sebastian Pop <sebastian.pop@amd.com>
6183 * graphite.c (scan_tree_for_params): Rewrite for the new layout of
6184 loop domain matrix. Pass in the number of loops contained in the
6186 (nb_loops_around_gb): Moved before setup_cloog_loop that uses it.
6187 (setup_cloog_loop): Rewrite for the new layout of loop domain matrix:
6188 loops that are not surrounding the current loop are not represented
6189 in the domain constraint matrix.
6190 (build_scop_iteration_domain): Initial domain constraint matrix
6191 contains only the eq/ineq, cst, and scop parameters columns.
6193 2008-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
6195 * graphite.c (schedule_to_scattering, nb_loops_around_gb): New.
6196 (print_graphite_bb): Print scattering.
6198 2008-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
6200 * graphite.c (initialize_cloog_names): Initialize names of
6201 scattering variables.
6203 2009-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
6205 * graphite.c (dot_all_scops_1): Disable debug output while
6208 2008-01-29 Tobias Grosser <grosser@fim.uni-passau.de>
6210 * graphite.c (find_transform): Change cloog output language to C.
6212 2008-01-27 Sebastian Pop <sebastian.pop@amd.com>
6214 * tree-loop-distribution.c (generate_memset_zero,
6215 generate_builtin, generate_code_for_partition,
6216 rdg_flag_all_uses): New.
6217 (rdg_flag_uses): Gather in the same partition the statements defining
6218 the VUSES of the current statement.
6219 (rdg_flag_similar_stores): Renamed rdg_flag_similar_memory_accesses.
6220 Gather in the same partition not only the stores to the same memory
6221 access, but also the reads.
6222 (ldist_generate_loops): Renamed ldist_gen.
6224 2008-01-24 Sebastian Pop <sebastian.pop@amd.com>
6225 Tobias Grosser <grosser@fmi.uni-passau.de>
6227 * graphite.c (setup_cloog_loop): Chain all cloog loops with the
6228 next pointer, don't use the inner pointer.
6230 2008-01-20 Tobias Grosser <grosser@fmi.uni-passau.de>
6232 * graphite.c (dot_all_scops, dot_all_scops_1): New.
6233 (find_transform): Call dot_all_1.
6234 * graphite.h (dot_all_scops): Declared.
6236 2007-12-14 Sebastian Pop <sebastian.pop@amd.com>
6238 * tree-loop-distribution.c: Fix apsi.f ICE.
6239 (create_bb_after_loop): New.
6240 (generate_loops_for_partition): Use it.
6241 * testsuite/gfortran.dg/ldist-1.f90: New.
6243 * tree-data-ref.c (dot_rdg): Use /tmp/rdg.dot for dotty format.
6244 * graphite.c (dot_scop): Use /tmp/scop.dot for dotty format.
6246 2007-12-13 Tobias Grosser <grosser@fmi.uni-passau.de>
6248 * graphite.c (find_transform): Dump cloog program sent to cloog.
6250 2007-12-13 Tobias Grosser <grosser@fmi.uni-passau.de>
6252 * graphite.c (initialize_cloog_names): Initialize cloog
6255 2007-12-13 Tobias Grosser <grosser@fmi.uni-passau.de>
6257 * graphite.c (build_scop_context): Fix typo, for the matrix
6258 format: insert '0 >= 0' instead of '-1 >= 0'.
6260 2007-12-13 Sebastian Pop <sebastian.pop@amd.com>
6262 * Fix merge problems.
6264 2007-12-13 Sebastian Pop <sebastian.pop@amd.com>
6266 * graphite.c (setup_cloog_loop): Fix typo.
6268 2007-12-12 Sebastian Pop <sebastian.pop@amd.com>
6270 * doc/invoke.texi (-ftree-loop-distribution): Documented.
6271 * tree-loop-distribution.c: Reimplemented.
6272 * tree-pass.h (pass_loop_distribution): New.
6273 * tree-scalar-evolution.c (number_of_iterations_for_all_loops): Use
6275 * graphds.h (struct graph): New field indexes.
6276 * timevar.def (TV_TREE_LOOP_DISTRIBUTION): New.
6278 * tree-vect-analyze.c: Remove declaration of static functions when not
6280 * tree-vectorizer.c: Same.
6281 (rename_variables_in_loop): Now extern.
6282 (slpeel_tree_duplicate_loop_to_edge_cfg): Renamed
6283 tree_duplicate_loop_to_edge_cfg. Reset PENDING_STMT for edges after
6284 calling redirect_edge_and_branch_force.
6286 * tree-vectorizer.h (tree_duplicate_loop_on_edge): Declared.
6288 * tree-data-ref.c: Don't include tree-chrec.h.
6289 (debug_data_dependence_relations): New.
6290 (dump_data_dependence_relation): Call dump_data_reference on data refs
6292 (same_access_functions): Moved...
6293 (find_vertex_for_stmt): Renamed rdg_vertex_for_stmt.
6294 (dump_rdg_vertex, debug_rdg_vertex, dump_rdg_component,
6295 debug_rdg_component, dump_rdg, debug_rdg, dot_rdg_1, dot_rdg,
6296 struct rdg_vertex_info, ): New.
6297 (create_rdg_edge_for_ddr): Compute the dependence level before looking
6299 (create_rdg_vertices): Initialize the htab of graph->indexes.
6300 Initialize RDG_MEM_WRITE_STMT and RDG_MEM_READS_STMT.
6301 (stmts_from_loop): Don't save LABEL_EXPR.
6302 (hash_stmt_vertex_info, eq_stmt_vertex_info,
6303 hash_stmt_vertex_del): New.
6304 (build_rdg): Initialize rdg->indexes.
6305 (free_rdg, stores_from_loop, ref_base_address,
6306 rdg_defs_used_in_other_loops_p, have_similar_memory_accesses,
6307 have_similar_memory_accesses_1, ref_base_address_1,
6308 remove_similar_memory_refs): New.
6310 * tree-data-ref.h: Include tree-chrec.h.
6311 (debug_data_dependence_relations): Declared.
6312 (same_access_functions): ...here. Now static inline.
6313 (ddr_is_anti_dependent, ddrs_have_anti_deps,
6314 ddr_dependence_level): New.
6315 (struct rdg_vertex): New fields has_mem_write, has_mem_reads.
6316 (RDGV_HAS_MEM_WRITE, RDGV_HAS_MEM_READS, RDG_STMT, RDG_MEM_WRITE_STMT,
6317 RDG_MEM_READS_STMT): New.
6318 (dump_rdg_vertex, debug_rdg_vertex, dump_rdg_component,
6319 debug_rdg_component, dump_rdg, debug_rdg, dot_rdg,
6320 rdg_vertex_for_stmt): Declared.
6321 (struct rdg_edge): New field level.
6322 (RDGE_LEVEL, free_rdg): New.
6323 (stores_from_loop, remove_similar_memory_refs,
6324 rdg_defs_used_in_other_loops_p,
6325 have_similar_memory_accesses): Declared.
6326 (rdg_has_similar_memory_accesses): New.
6328 * lambda.h (dependence_level): New.
6329 * common.opt (ftree-loop-distribution): New.
6330 * tree-flow.h (debug_loop_ir): Renamed debug_loops.
6331 (print_loop_ir): Renamed print_loops.
6332 (debug_loop, debug_loop_num, print_loops_bb, mark_virtual_ops_in_bb,
6333 tree_duplicate_loop_to_edge_cfg, rename_variables_in_loop): Declared.
6334 * Makefile.in (TREE_DATA_REF_H): Depends on tree-chrec.h.
6335 (tree-loop-distribution.o): Added.
6336 * tree-cfg.c (mark_virtual_ops_in_region): Use mark_virtual_ops_in_bb.
6337 (mark_virtual_ops_in_bb): New.
6338 (print_loops_bb, debug_loop_num, debug_loop): New.
6339 * passes.c: Scheduled pass_loop_distribution.
6341 2007-12-12 Konrad Trifunovic <konrad.trifunovic@inria.fr>
6343 * graphite.c (scan_tree_for_params): Correct the number of columns
6345 (nb_flat_iterator): New.
6346 (setup_cloog_loop): Initialize to 1 the first column for inequalities.
6347 (build_scop_iteration_domain): Correct the number of columns for
6350 2007-12-12 Sebastian Pop <sebastian.pop@amd.com>
6352 * Merge from mainline (129697:130800).
6354 2007-10-30 Sebastian Pop <sebastian.pop@amd.com>
6356 * graphite.c (build_graphite_bb): SCoP's basic blocks are post
6357 dominated by SCoP's exit.
6358 (graphite_transform_loops): Compute post dominators.
6360 2007-10-28 Sebastian Pop <sebastian.pop@amd.com>
6362 * Merge from mainline (127169:129697).
6364 2007-10-28 Sebastian Pop <sebastian.pop@amd.com>
6366 * graphite.c (affine_expr): Renamed scop_affine_expr. Use an extra
6367 parameter for the basic block that contains the expression. Use
6368 outermost_loop_in_scop for evolution_function_is_affine_multivariate_p.
6369 (stmt_simple_for_scop_p): Pass to scop_affine_expr the basic block of
6371 * graphite.h (gbb_loop): New.
6372 (GBB_LOOP): Removed.
6374 2007-08-03 Sebastian Pop <sebpop@gmail.com>
6376 * Makefile.in: Fix merge problem.
6378 2007-08-03 Sebastian Pop <sebpop@gmail.com>
6380 * Merge from mainline (125309:127169).
6381 * tree-loop-distribution.c: Disabled.
6383 2007-06-05 Sebastian Pop <sebpop@gmail.com>
6385 * Merge from mainline (r123693:125309).
6387 2007-05-30 Sebastian Pop <sebpop@gmail.com>
6389 * tree-loop-distribution.c (correct_modify_expr_p): Renamed
6391 (correct_modify_p, check_statements, number_of_lvalue_uses,
6392 number_of_scalar_dependences, create_edges): Use GIMPLE_MODIFY_STMT
6393 instead of MODIFY_EXPR.
6394 (update_edge_with_ddv): Don't pass index_of_edge. Initialize
6397 2007-05-24 Sebastian Pop <sebpop@gmail.com>
6399 * tree-loop-distribution.c (struct rdg): Replace arrays by
6400 VECs for edges and vertices.
6401 (RDG_NBV, RDG_NBE, RDG_VERTEX, RDG_EDGE): Removed.
6402 (RDGV_NB_PARTITIONS): New.
6403 (PRDG_NBV, PRDG_NBE): Removed.
6404 (build_scc_graph, correct_partitions_p, mark_partitions, build_prdg,
6405 dump_rdg, find_vertex_with_stmt, create_vertices, free_rdg,
6406 number_of_scalar_dependences, create_edges, build_rdg): Use VECs.
6408 2007-05-17 Georges-Andre Silber <silber@cri.ensmp.fr>
6409 Sebastian Pop <sebpop@gmail.com>
6411 * doc/invoke.texi (-ftree-loop-distribution): Document.
6412 * tree-loop-distribution.c: New file.
6413 * tree-pass.h (pass_loop_distribution): Declared.
6414 * timevar.def (TV_TREE_LOOP_DISTRIBUTION): New.
6415 * tree-data-ref.c (initialize_data_dependence_relation): Initialize
6417 * tree-data-ref.h (data_dependence_relation): Add reversed_p.
6418 (DDR_REVERSED_P): New.
6419 * common.opt (-ftree-loop-distribution): New.
6420 * tree-flow.h (distribute_loops): Declared.
6421 * Makefile.in (OBJS-common): Depend on tree-loop-distribution.o.
6422 * passes.c (init_optimization_passes): Schedule loop distribution.
6424 2007-05-12 Sebastian Pop <sebastian.pop@inria.fr>
6426 * graphite.c (print_graphite_bb): Don't call dump_data_references.
6427 (print_scop): Don't print when scop is NULL.
6428 (build_scop_context, find_transform): Don't output to stderr.
6430 2007-05-09 Sebastian Pop <sebastian.pop@inria.fr>
6432 * tree-data-ref.c: Don't include graphite.h.
6433 Comment out the code for printing data reference's scop.
6434 (build_access_matrix_with_af): Moved...
6435 * tree-data-ref.h (build_access_matrix_with_af): Removed declaration.
6436 * graphite.c (build_access_matrix_with_af): ... here. Now static.
6437 (print_graphite_bb): Print basic block's schedule.
6438 (print_scop): Don't print the schedule, call cloog's pretty printer.
6439 (bb_in_scop_p): A basic block is in a scop only if it is both
6440 dominated and postdominated by the scop's entry and exit basic blocks.
6441 (function_parameter_p): New.
6442 (invariant_in_scop_p): Use function_parameter_p.
6443 (new_scop, save_scop): New.
6444 (end_scop, test_for_scop_bound, build_scops): Use new_scop, and
6446 (scan_tree_for_params): Directly build the constraint as CloogMatrix.
6447 (loop_in_scop_p): New.
6448 (scop_record_loop): Use loop_in_scop_p.
6449 (build_scop_domain): Renamed build_scop_iteration_domain.
6450 (setup_cloog_loop, initialize_cloog_names, find_scop_parameters,
6451 nb_params_in_scop, build_scop_context, first_loop_in_scop,
6452 setup_cloog_loop, dot_scop_1, dot_scop): New.
6453 * graphite.h (GBB_LOOP, SCOP_PROG, dot_scop): New.
6454 (struct scop): Add a pointer to cloog's representation of a program.
6456 2007-04-14 Sebastian Pop <sebastian.pop@inria.fr>
6458 * doc/invoke.texi (-ftree-check-verbose): Renamed
6459 -ftree-checks-verbose.
6460 * common.opt (flag_tree_check_verbose): Renamed
6461 flag_tree_checks_verbose.
6462 * tree-check.c (tree_check_warning): Use flag_tree_checks_verbose.
6464 2007-04-14 Sebastian Pop <sebastian.pop@inria.fr>
6466 * configure: Regenerated.
6467 * config.in: Regenerated.
6468 * tree-ssa-loop.c (graphite_transforms): Execute
6469 graphite_transform_loops only when HAVE_cloog.
6470 * configure.ac (HAVE_polylib, HAVE_cloog, GRAPHITE): Defined.
6471 * graphite.c: Include polylibgmp.h and cloog.h.
6472 (graphite_transform_loops): Removed loops parameter.
6473 * tree-flow.h (graphite_transform_loops): Update declaration.
6474 * Makefile.in (POLYLIBLIBS, POLYLIBINC, CLOOGLIBS, CLOOGINC): New.
6475 (LIBS): Depend on CLOOGLIBS and on POLYLIBLIBS.
6476 (INCLUDES): Depend on POLYLIBINC and on CLOOGINC.
6477 (OBJS-common): Remove dependence on graphite.o.
6478 (BACKEND): Depend on @GRAPHITE@.
6480 2007-04-13 Sebastian Pop <sebastian.pop@inria.fr>
6482 * doc/invoke.texi (-ftree-check-verbose): Documented.
6483 * testsuite/gcc.dg/tree-checker/tree-checks-1.c: New.
6484 * testsuite/gcc.dg/tree-checker/tree-checks-2.c: New.
6485 * testsuite/gcc.dg/tree-checker/tree-checks-3.c: New.
6486 * testsuite/gcc.dg/tree-checker/tree-checks-4.c: New.
6487 * testsuite/gcc.dg/tree-checker/tree-checks.exp: New.
6488 * testsuite/gcc.dg/tree-checker/condates.crp: New.
6489 * common.opt (ftree-checks-verbose): New.
6490 * tree-check.c (tree_check_warning): Move extra stderr output
6491 under control of flag_tree_check_verbose.
6493 2007-04-12 Sebastian Pop <sebastian.pop@inria.fr>
6495 * tree-match.c: Fix comments formatting.
6496 * tree-match.h: Fix comments formatting.
6497 * tree-check.c: Fix comments formatting.
6498 (tree_check_init): Restructure.
6500 2007-04-12 Nic Volanschi <nic.volanschi@free.fr>
6502 * doc/invoke.texi (-ftree-check, -ftree-checks): Documented.
6504 2007-04-10 Sebastian Pop <sebastian.pop@inria.fr>
6506 * Merge from mainline (r120733:123693).
6508 2007-03-20 Nic Volanschi <nic.volanschi@free.fr>
6510 * condate.y: New file.
6511 * tree-match.h (struct patt_info_s): New field sign.
6512 (struct condate_s): New field msg.
6513 (normalize_condate, name_condate, add_condate): New.
6514 (conds[], condate_parse): Made extern.
6515 * tree-check.c (tree_check_warning): First arg changed to cond;
6516 warning reformatted.
6517 (tree_check_init): Reset the TREE_VISITED bit on every CFG node.
6519 (tree_check): Process trivial condates.
6520 (read_delimited_string): Removed.
6521 (print_cond): Print name and msg.
6522 (conds[]): Made extern.
6523 (parse_tree_check_file_once): Rewritten to use the parser in
6525 Processing of option --tree_check_string moved to tree_scan().
6526 * Makefile.in: Added condate.y
6528 2007-03-12 Sebastian Pop <sebastian.pop@inria.fr>
6530 * tree-pretty-print.c (dump_generic_bb_buff, lazy_dump_generic_node):
6531 Use VECs instead of varrays.
6532 * diagnostic.h (lazy_dump_generic_node): Update declaration.
6533 * Makefile.in (pretty-print.o): Depend on vec.h.
6534 * pretty-print.c: Include tree.h and vec.h.
6535 (pp_clear_state, pp_write_list_to_stream, pp_base_format,
6536 pp_base_format, pp_construct, pp_base_string, pp_lazy_mode,
6537 new_tree_chunk, pp_add_tree, pp_add_string, pp_add_char, pp_write_list,
6538 pp_free_list): Use VECs instead of varrays.
6539 * pretty-print.h: Do not include varray.h.
6540 (struct tree_chunk_s): Declaration moved before its use.
6541 (output_buffer): Rename varray field to chunks.
6542 * tree-match.c (tree_equal, chunk_1st_char, chunks_lookahead,
6543 tree_1st_char, match_chunks_pattinfo, match_tree_pattinfo,
6544 save_global_holes): Use VECs instead of varrays.
6545 * tree-match.h: Declare VECs of cfg_node, and hole_p.
6546 * tree-check.c (scan_cfg_stmts, push_node,
6547 print_matching_stmt): Removed.
6548 (tree_check_instance, push_global_holes_if_new, tree_check,
6549 execute_tree_check): Use VECs instead of varrays.
6550 (gate_tree_check): Don't execute the CFG check when basic_block_info
6553 2007-01-12 Sebastian Pop <sebastian.pop@inria.fr>
6555 * Merge from mainline (r115016:120733).
6557 2007-01-12 Sebastian Pop <sebastian.pop@inria.fr>
6559 * Merge from mainline (r117632:117661).
6561 2007-01-12 Sebastian Pop <sebastian.pop@inria.fr>
6563 * tree-dump.c (dump_option_value_in): Add TDF_DEBUG.
6564 * tree-pass.h (TDF_DEBUG, debug_p): New.
6565 * tree-scalar-evolution.c (set_scalar_evolution, get_scalar_evolution,
6566 get_scalar_evolution, add_to_evolution, set_nb_iterations_in_loop,
6567 get_loop_exit_condition, analyze_evolution_in_loop,
6568 analyze_initial_condition, analyze_scalar_evolution,
6569 instantiate_parameters, number_of_latch_executions): Use debug_p.
6570 * tree-chrec.c (chrec_apply): Use debug_p.
6571 * tree-data-ref.c: Include graphite.h.
6572 (dump_data_reference): Print also the access matrix.
6573 (analyze_array, analyze_indirect_ref, init_data_ref,
6574 analyze_offset_expr, address_analysis, object_analysis,
6575 create_data_ref, finalize_ddr_dependent,
6576 non_affine_dependence_relation, analyze_ziv_subscript,
6577 analyze_siv_subscript_cst_affine,
6578 compute_overlap_steps_for_affine_1_2, analyze_subscript_affine_affine,
6579 can_use_analyze_subscript_affine_affine, analyze_siv_subscript,
6580 analyze_miv_subscript, analyze_overlapping_iterations,
6581 build_classic_dist_vector, subscript_dependence_tester,
6582 compute_affine_dependence, analyze_all_data_dependences): Use debug_p.
6583 (build_access_matrix_with_af): No longer static.
6584 * tree-data-ref.h (scop_p): ... declaration here.
6585 (data_reference.scop): New field.
6586 (DR_SCOP, DR_ACCESS_MATRIX): New.
6587 (build_access_matrix_with_af, dr_num_subscripts): Declared.
6588 * graphite.c (print_graphite_bb): Call dump_data_references.
6589 (print_scop): Use scop_nb_loops and scop_dim_domain.
6590 (test_for_scop_bound): Use debug_p.
6591 (scan_tree_for_params): Use scop_nb_loops, scop_nb_loops and
6593 (scop_loop_index): Moved...
6594 (scop_record_loop): New.
6595 (build_scop_loop_nests): Use scop_record_loop.
6596 (build_scop_domain): Use scop_dim_domain.
6597 (build_access_matrix): Implemented.
6598 (build_scop_canonical_schedules): Use scop_nb_loops.
6599 (build_graphite_bb): Initialize GBB_SCOP.
6600 * graphite.h (scop_p): Moved...
6601 (graphite_bb.scop): New field.
6602 (graphite_bb.iteration_domain, GBB_DOMAIN, scop.nb_params,
6603 scop.nb_loops, scop.dim_domain, SCOP_NB_LOOPS, SCOP_NB_PARAMS,
6604 SCOP_DIM_DOMAIN, SCOP_STMTS): Removed.
6605 (scop_nb_params, scop_nb_loops, scop_dim_domain, gbb_dim_domain,
6606 scop_loop_index): New.
6607 * Makefile.in (tree-data-ref.o): Depends on graphite.h.
6609 2007-01-05 Sebastian Pop <sebastian.pop@inria.fr>
6611 * Merge from mainline (r117661:120450).
6613 2006-10-12 Sebastian Pop <sebastian.pop@inria.fr>
6615 * tree-scalar-evolution.c (instantiate_parameters_1): Don't stop
6616 at the first declaration outside the varying loop, instantiate as
6618 * tree-chrec.c (for_each_scev_op): New.
6619 * tree-chrec.h (for_each_scev_op): Declared.
6620 * tree-ssa-loop.c (pass_graphite_trans): Don't dump the function.
6621 * tree-data-ref.c (get_references_in_stmt,
6622 find_data_references_in_stmt): New, from trunk.
6623 (find_data_references_in_loop): Use get_references_in_stmt
6624 and find_data_references_in_loop, modified as in trunk.
6625 (build_access_matrix_with_af): New.
6626 * tree-data-ref.h (data_reference): Add a field access_matrix.
6627 (data_ref_loc): New, as in trunk.
6628 * graphite.c (print_graphite_bb, bb_in_scop_p, stmt_in_scop_p,
6629 invariant_in_scop_p, param_index, scan_tree_for_params,
6630 scop_loop_index, build_scop_loop_nests, build_scop_domain, irp_data,
6631 idx_record_param, idx_record_params, build_access_matrix,
6632 build_scop_data_accesses, build_scop_canonical_schedules,
6633 build_graphite_bb, build_scop_bbs, find_params_in_bb,
6634 build_scop_params): New.
6635 * graphite.h (graphite_bb): New.
6636 (scop): Add fields static_schedule, params, loop_nest,
6638 * lambda.h: Declare vecs of lambda_matrix.
6639 * tree-flow.h (print_loop_ir_bb): Declared.
6640 * tree-cfg.c (print_loop_ir_bb): New.
6641 (print_loop): Use print_loop_ir_bb.
6643 2006-10-12 Sebastian Pop <pop@cri.ensmp.fr>
6645 * Merge from mainline (r115016:117632).
6647 2006-10-11 Sebastian Pop <pop@cri.ensmp.fr>
6649 * graphite.c (debug_scops): Adjust definition for avoiding a bootstrap
6650 break due to a warning.
6652 2006-10-10 Sebastian Pop <pop@cri.ensmp.fr>
6654 * graphite.c (print_scops, debug_scops): New.
6655 (graphite_transform): Renamed graphite_find_transform.
6656 * graphite.h (debug_scops): Declared.
6658 2006-08-17 Sebastian Pop <pop@cri.ensmp.fr>
6660 * tree-match.c: Reformat following the GNU style.
6661 * tree-match.h: Reformat following the GNU style.
6662 * tree-pattern.h: Removed empty file.
6663 * Makefile.in: Remove references to tree-pattern.h.
6664 * tree-check.c: Reformat following the GNU style.
6665 (execute_tree_check): Move gate condition code to...
6666 (gate_tree_check): ...here. New function.
6667 (pass_check): Use the gate function.
6669 2006-07-04 Nic Volanschi <nic.volanschi@free.fr>
6671 * tree-pattern.h: New. Tree pattern matching and checking using
6673 * tree-check.c: New. Tree/CFG checking pass.
6674 * tree-match.c: New. Library for tree pattern matching.
6675 * opts.c, common.opt: Add options --ftree-check & --ftree-checks.
6676 * toplev.c, flags.h: Add globals for tree-check pass.
6677 * Makefile.in: Integrate the files in tree-check pass.
6678 * timevar.def, tree-optimize.c, tree-pass.h: Register tree-check pass.
6679 * pretty-print.c, pretty-print.h, tree-pretty-print.c, diagnostic.h:
6680 Introduce a "lazy" pretty-print mode.
6681 * tree.c, tree.h: Add tree_name.
6683 2006-07-04 Sebastian Pop <pop@cri.ensmp.fr>
6685 * doc/invoke.texi (-fgraphite): Correct typo.
6686 * tree-scalar-evolution.c (number_of_iterations_for_all_loops): Update
6687 use of print_loop_ir.
6688 * testsuite/gcc.dg/graphite/scop-1.c: New.
6689 * testsuite/gcc.dg/graphite/scop-2.c: New.
6690 * testsuite/gcc.dg/graphite/graphite.exp: New.
6691 * graphite.c: Include domwalk.h.
6692 (print_scop): Print only the entry and exit blocks.
6693 (debug_scop): No longer static.
6694 (affine_expr): Fix formating. Return also true when the expression is
6696 (stmt_simple_for_scop_p): Fix formating.
6697 (build_scops): Use domwalk.
6698 (get_loop_start, end_scop, test_for_scop_bound): New.
6699 (graphite_transform_loops): Avoid printing on stderr.
6700 * graphite.h (debug_scop): Declared.
6701 * tree-flow.h (debug_loop_ir, print_loop_ir): Update declarations.
6702 * Makefile.in (graphite.o): Depend on domwalk.h.
6703 * tree-cfg.c (print_loop, print_pred_bbs, print_succ_bbs): Remove
6704 declarations for static functions.
6705 (print_loop, print_loop_ir, debug_loop_ir): Use an extra parameter for
6706 controlling output verbosity.
6708 2006-06-26 Sebastian Pop <pop@cri.ensmp.fr>
6709 Plesco Alexandru <shurikx@gmail.com>
6711 * doc/invoke.texi (-fgraphite): Document.
6712 * tree-pass.h (pass_graphite_transforms): Declared.
6713 * timevar.def (TV_GRAPHITE_TRANSFORMS): New.
6714 * tree-ssa-loop.c (graphite_transforms, gate_graphite_transforms): New.
6715 (pass_graphite_transforms): Defined.
6716 * tree-data-ref.c (free_data_ref, data_reference): Extern.
6717 * tree-data-ref.h (free_data_ref, data_reference): Declared.
6718 * graphite.c, graphite.h: New.
6719 * common.opt (fgraphite): Declared.
6720 * tree-flow.h (graphite_transform_loops): Declared.
6721 * Makefile.in (OBJS-common): Add graphite.o.
6722 (graphite.o): New rule.
6723 * passes.c (pass_graphite_transforms): Scheduled.