From 33bcc203d1c94a764d4d6b4733f2a39ff4b30e77 Mon Sep 17 00:00:00 2001 From: Sven Verdoolaege Date: Sat, 26 Apr 2014 20:46:24 +0200 Subject: [PATCH] pet_scop_collect_domains: properly handle statements with arguments In particular, for statements with arguments, the "domain" field is not the iteration domain itself but a wrapped map with the iteration domain as domain. Signed-off-by: Sven Verdoolaege --- scop.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/scop.c b/scop.c index 145d1f2..37cef25 100644 --- a/scop.c +++ b/scop.c @@ -2730,6 +2730,8 @@ __isl_give isl_union_set *pet_scop_collect_domains(struct pet_scop *scop) for (i = 0; i < scop->n_stmt; ++i) { domain_i = isl_set_copy(scop->stmts[i]->domain); + if (scop->stmts[i]->n_arg > 0) + domain_i = isl_map_domain(isl_set_unwrap(domain_i)); domain = isl_union_set_add_set(domain, domain_i); } -- 2.11.4.GIT