Commit 8c31ebfa by Sebastian Pop Committed by Sebastian Pop

Dont add unknown subscript upper bounds.

2009-08-11  Sebastian Pop  <sebastian.pop@amd.com>

	* graphite-sese-to-poly.c (pdr_add_data_dimensions): Dont add
	unknown subscript upper bounds.

	* testsuite/gcc.dg/graphite/interchange-6.c: Un-XFAIL.

From-SVN: r150693
parent fb9fb290
2009-08-12 Sebastian Pop <sebastian.pop@amd.com>
* graphite-sese-to-poly.c (pdr_add_data_dimensions): Dont add
unknown subscript upper bounds.
2009-08-12 Sebastian Pop <sebastian.pop@amd.com>
Pranav Garg <pranav.garg2107@gmail.com>
* graphite-interchange.c (gather_access_strides): Removed.
......
2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
* graphite-sese-to-poly.c (pdr_add_data_dimensions): Dont add
unknown subscript upper bounds.
* testsuite/gcc.dg/graphite/interchange-6.c: Un-XFAIL.
2009-08-11 Sebastian Pop <sebastian.pop@amd.com>
Pranav Garg <pranav.garg2107@gmail.com>
* graphite-interchange.c (gather_access_strides): Removed.
......
......@@ -1669,6 +1669,7 @@ pdr_add_data_dimensions (ppl_Polyhedron_t accesses, data_reference_p dr,
ppl_Linear_Expression_t expr;
ppl_Constraint_t cstr;
ppl_dimension_type subscript = dom_nb_dims + 1 + i;
int size;
/* 0 <= subscript */
ppl_new_Linear_Expression_with_dimension (&expr, accessp_nb_dims);
......@@ -1685,16 +1686,19 @@ pdr_add_data_dimensions (ppl_Polyhedron_t accesses, data_reference_p dr,
break;
/* subscript <= array_size */
ppl_new_Linear_Expression_with_dimension (&expr, accessp_nb_dims);
ppl_set_coef (expr, subscript, -1);
size = elt_size ? int_cst_value (array_size) / elt_size : 0;
if (size)
{
ppl_new_Linear_Expression_with_dimension (&expr, accessp_nb_dims);
ppl_set_coef (expr, subscript, -1);
if (elt_size)
ppl_set_inhomogeneous (expr, int_cst_value (array_size) / elt_size);
ppl_set_inhomogeneous (expr, size);
ppl_new_Constraint (&cstr, expr, PPL_CONSTRAINT_TYPE_GREATER_OR_EQUAL);
ppl_Polyhedron_add_constraint (accesses, cstr);
ppl_delete_Linear_Expression (expr);
ppl_delete_Constraint (cstr);
ppl_new_Constraint (&cstr, expr, PPL_CONSTRAINT_TYPE_GREATER_OR_EQUAL);
ppl_Polyhedron_add_constraint (accesses, cstr);
ppl_delete_Linear_Expression (expr);
ppl_delete_Constraint (cstr);
}
elt_size = int_cst_value (array_size);
}
......
2009-08-12 Sebastian Pop <sebastian.pop@amd.com>
* testsuite/gcc.dg/graphite/interchange-6.c: Un-XFAIL.
2009-08-12 Sebastian Pop <sebastian.pop@amd.com>
Pranav Garg <pranav.garg2107@gmail.com>
* testsuite/gcc.dg/graphite/interchange-6.c: XFAILed.
......
......@@ -13,5 +13,5 @@ int medium_loop_interchange(int A[100][200])
return A[1][1];
}
/* { dg-final { scan-tree-dump-times "will be interchanged" 1 "graphite" { xfail *-*-* } } } */
/* { dg-final { scan-tree-dump-times "will be interchanged" 1 "graphite" } } */
/* { dg-final { cleanup-tree-dump "graphite" } } */
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment