summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSven Verdoolaege <skimo@kotnet.org>2012-10-01 11:18:04 +0200
committerSven Verdoolaege <skimo@kotnet.org>2012-11-14 00:33:53 +0100
commita79bde7edbf1d92ef373afe4511c392dab477fdb (patch)
tree4688b233231fa07d461d4709ba2ef2195dfc2cd8
parent461a2cd0addb0879be5eaab45832f35b780a3f9d (diff)
downloadisl-a79bde7edbf1d92ef373afe4511c392dab477fdb.tar.gz
isl-a79bde7edbf1d92ef373afe4511c392dab477fdb.tar.bz2
isl-a79bde7edbf1d92ef373afe4511c392dab477fdb.zip
isl_printer_print_space: support printing in "omega" format
In particular, print a declaration for the parameters in the space. Signed-off-by: Sven Verdoolaege <skimo@kotnet.org>
-rw-r--r--isl_output.c19
1 files changed, 17 insertions, 2 deletions
diff --git a/isl_output.c b/isl_output.c
index 452a30d3..9cbe9443 100644
--- a/isl_output.c
+++ b/isl_output.c
@@ -1969,8 +1969,8 @@ error:
return NULL;
}
-__isl_give isl_printer *isl_printer_print_space(__isl_take isl_printer *p,
- __isl_keep isl_space *dim)
+static __isl_give isl_printer *isl_printer_print_space_isl(
+ __isl_take isl_printer *p, __isl_keep isl_space *dim)
{
if (!dim)
goto error;
@@ -1993,6 +1993,21 @@ error:
return NULL;
}
+__isl_give isl_printer *isl_printer_print_space(__isl_take isl_printer *p,
+ __isl_keep isl_space *space)
+{
+ if (!p || !space)
+ return isl_printer_free(p);
+ if (p->output_format == ISL_FORMAT_ISL)
+ return isl_printer_print_space_isl(p, space);
+ else if (p->output_format == ISL_FORMAT_OMEGA)
+ return print_omega_parameters(space, p);
+
+ isl_die(isl_space_get_ctx(space), isl_error_unsupported,
+ "output format not supported for space",
+ return isl_printer_free(p));
+}
+
__isl_give isl_printer *isl_printer_print_local_space(__isl_take isl_printer *p,
__isl_keep isl_local_space *ls)
{