summaryrefslogtreecommitdiff
path: root/gcc/graphite-sese-to-poly.c
diff options
context:
space:
mode:
authorspop <spop@138bc75d-0d04-0410-961f-82ee72b054a4>2009-08-12 14:23:01 +0000
committerspop <spop@138bc75d-0d04-0410-961f-82ee72b054a4>2009-08-12 14:23:01 +0000
commita741358d2ef4498e2c72c96fe5a45a333478489f (patch)
treeea44f243fde73312dfa71681281a6fb0189704fc /gcc/graphite-sese-to-poly.c
parent95b2e0d363a0f078a9f37c6f2f33f620eee2aa99 (diff)
downloadgcc-a741358d2ef4498e2c72c96fe5a45a333478489f.tar.gz
Restore original scattering when the transform is not legal.
2009-08-05 Sebastian Pop <sebastian.pop@amd.com> * graphite-blocking.c (scop_do_strip_mine): Call store_scattering. Early return without analyzing the data dependences if no transform has been done. Call restore_scattering if the transform is not legal. (graphite-interchange.c): Same. * graphite-poly.c (print_scattering_function): Test for PBB_TRANSFORMED. (graphite_read_transforms): Initialize PBB_TRANSFORMED. (apply_poly_transforms): Do not gcc_assert that the transform is legal. (new_poly_bb): Initialize PBB_TRANSFORMED, PBB_SAVED, and PBB_ORIGINAL. Do not initialize PBB_NB_SCATTERING_TRANSFORM, PBB_NB_LOCAL_VARIABLES, PBB_TRANSFORMED_SCATTERING, and PBB_ORIGINAL_SCATTERING. (free_poly_dr): Free PBB_TRANSFORMED, PBB_SAVED, and PBB_ORIGINAL. * graphite-poly.h (struct poly_scattering): New. (struct poly_bb): Add original, transformed, and saved fields. Remove transformed_scattering, original_scattering, nb_local_variables, and nb_scattering_transform fields. (PBB_ORIGINAL, PBB_TRANSFORMED, PBB_SAVED): New. (poly_scattering_new): New. (poly_scattering_free): New. (poly_scattering_copy): New. (store_scattering_pbb): New. (store_scattering): New. (restore_scattering_pbb): New. (restore_scattering): New. * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons): Initialize PBB_TRANSFORMED and PBB_ORIGINAL. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@150686 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/graphite-sese-to-poly.c')
-rw-r--r--gcc/graphite-sese-to-poly.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gcc/graphite-sese-to-poly.c b/gcc/graphite-sese-to-poly.c
index 4ed7ffc27d5..6204ec8e987 100644
--- a/gcc/graphite-sese-to-poly.c
+++ b/gcc/graphite-sese-to-poly.c
@@ -498,6 +498,7 @@ build_pbb_scattering_polyhedrons (ppl_Linear_Expression_t static_schedule,
value_init (v);
ppl_new_Coefficient (&c);
+ PBB_TRANSFORMED (pbb) = poly_scattering_new ();
ppl_new_C_Polyhedron_from_space_dimension
(&PBB_TRANSFORMED_SCATTERING (pbb), dim, 0);
@@ -543,8 +544,7 @@ build_pbb_scattering_polyhedrons (ppl_Linear_Expression_t static_schedule,
value_clear (v);
ppl_delete_Coefficient (c);
- ppl_new_C_Polyhedron_from_C_Polyhedron (&PBB_ORIGINAL_SCATTERING (pbb),
- PBB_TRANSFORMED_SCATTERING (pbb));
+ PBB_ORIGINAL (pbb) = poly_scattering_copy (PBB_TRANSFORMED (pbb));
}
/* Build for BB the static schedule.